Add badges to docs
- Closes https://gitlab.com/gitlab-com/gitlab-docs/issues/173
- For https://gitlab.com/gitlab-org/gitlab-ce/issues/42631
- TEST EE-MR for preview: https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/5233
- Followup CE and EE MRs (adding badges): https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/18408, https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/5381
How it works
For every place we want to add the badge, we use a magic Markdown syntax: **[BADGE_TYPE]**
- Core:
**[CORE]**
- Starter:
**[STARTER]**
- Premium:
**[PREMIUM]**
- Ultimate:
**[ULTIMATE]**
Each one imply on the gitlab-dot-com equivalent, as well, so by setting core
you also get free
.
If you want to restrict only for on-premise, you need to specify a modifier ONLY
:
**[CORE ONLY]**
**[STARTER ONLY]**
**[PREMIUM ONLY]**
**[ULTIMATE ONLY]**
On hover, it shows the availability.
How it renders on the docs site:
Review apps:
- Test with all badges: http://badges.178.62.207.141.xip.io/ee/test.html
- Real files:
How it renders in GitLab markdown:
Preview: https://gitlab.com/gitlab-org/gitlab-ee/blob/a929fdcf352047f26c738503519df1c593216727/doc/test.md
How noisy the markdown file gets:
Preview: https://gitlab.com/gitlab-org/gitlab-ee/blob/a929fdcf352047f26c738503519df1c593216727/doc/test.md
### Lorem ipsum dolor sit h3 **[PREMIUM]**
Lorem ipsum dolor sit amet, consectetur adipisicing elit. **[PREMIUM]**
- **[PREMIUM]** Lorem ipsum dolor sit amet, consectetur adipisicing elit. Omnis, nulla. 1
- **[ULTIMATE ONLY]** Lorem ipsum dolor sit amet, consectetur adipisicing elit. Omnis, nulla. 3
Todos
-
Fix alignment for <h5>
,<h6>
,<li>
and<p>
-
Keep title clean from HTML or Markdown -
GitLab.com off -
Fix tooltips for .dotcom-false
-
Fix layout on mobile -
FE Review -
Revert .gitlab-ci.yml
tomaster
-
Document how to use it https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/18408/diffs?commit_id=2654905ad5da4bb7cbcb0052fffd266d6c6cc36d
Edited by Marcia Ramos