Link around badges inside HTML does not work in Markdown rendering/parsing
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
Summary
Surrounding a badge in a markdown (/readme) with a link does not work inside HTML, e.g., for centering the badges. Centering the badge without a link does work.
A badge should usually link to docs, pipelines, etc., so there is a link around them [](url)
If this is inside HTML, e.g., <div align="center">[](url)</div>
is breaks. Passing the badge without the link to the HTML works as expected.
Steps to reproduce
- Gitlab version: GitLab Community Edition v17.10.0
- Have a repo with a pipeline
- Add badges to your readme:

- Surround a badge with a markdown link (source)
- center your badge and link with ´` (source)
- Click preview (online editor) or commit and see online.
```markdown **Does work (without links)** <div align="center">      </div> **Does work (with links and without div align="center">)** [](https://scs.pages.ub.uni-bielefeld.de/cocosy/cooperative-cuisine/cooperative_cuisine.html) [](https://gitlab.ub.uni-bielefeld.de/scs/cocosy/cooperative-cuisine/-/pipelines/latest/) [](https://gitlab.ub.uni-bielefeld.de/scs/cocosy/cooperative-cuisine/-/pipelines/latest/)   **Does not work** <div align="center"> [](https://scs.pages.ub.uni-bielefeld.de/cocosy/cooperative-cuisine/cooperative_cuisine.html) [](https://gitlab.ub.uni-bielefeld.de/scs/cocosy/cooperative-cuisine/-/pipelines/latest/) [](https://gitlab.ub.uni-bielefeld.de/scs/cocosy/cooperative-cuisine/-/pipelines/latest/)   </div>
Instead of correctly parsing the markdown link inside the HTML, it is handled as normal text.
Visually: like in the image but with a link
<a href="...">
Expand for output related to GitLab environment info
(For installations with omnibus-gitlab package run and paste the output of: `sudo gitlab-rake gitlab:env:info`) (For installations from source run and paste the output of: `sudo -u git -H bundle exec rake gitlab:env:info RAILS_ENV=production`)
Expand for output related to the GitLab application check
(For installations with omnibus-gitlab package run and paste the output of:
sudo gitlab-rake gitlab:check SANITIZE=true
)(For installations from source run and paste the output of:
sudo -u git -H bundle exec rake gitlab:check RAILS_ENV=production SANITIZE=true
)(we will only investigate if the tests are passing)