Comments (6)
Badge tested using npm run badge https://img.shields.io/badge/Open%20Hub-white.svg?logo=data:image/svg%2bxml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAxOSAxMyI+PHRleHQgeT0iMTIiIGZpbGw9IiM1YTJhODEiIGZvbnQtZmFtaWx5PSJOaW1idXMgU2FucyBOYXJyb3ciIGZvbnQtd2VpZ2h0PSI4MDAiPk9IPC90ZXh0Pjwvc3ZnPg==
Output is available here
from shields.
This is true in a GitHub issue, but if you put
<picture>
<source srcset="https://img.shields.io/badge/Open%20Hub-white.svg?logo=data:image/svg%2bxml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAxOSAxMyI+PHRleHQgeT0iMTIiIGZpbGw9IiM1YTJhODEiIGZvbnQtZmFtaWx5PSJOaW1idXMgU2FucyBOYXJyb3ciIGZvbnQtd2VpZ2h0PSI4MDAiPk9IPC90ZXh0Pjwvc3ZnPg==" />
<img />
</picture>
in a HTML file it works as expected.
If you look at what GitHub is actually rendering in those two cases, it is
<source srcset="..." data-canonical-src="https://img.shields.io/badge/Open%20Hub-white.svg?logo=data:image/svg%2bxml;base64">
and
<img src="..." data-canonical-src="https://img.shields.io/badge/Open%20Hub-white.svg?logo=data:image/svg%2bxml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAxOSAxMyI+PHRleHQgeT0iMTIiIGZpbGw9IiM1YTJhODEiIGZvbnQtZmFtaWx5PSJOaW1idXMgU2FucyBOYXJyb3ciIGZvbnQtd2VpZ2h0PSI4MDAiPk9IPC90ZXh0Pjwvc3ZnPg==">
so there is something stripping the part after the comma in the first case, but it is not us.
This isn't something we can do anything about.
from shields.
Thanks, I've created a ticket with GitHub. We shall see.
from shields.
GitHub support guy confirmed it and sent it to engineering.
from shields.
OK. Cheers for following up. If it has been acknowledged as a problem on GitHub's side, I think we can close this one here.
from shields.
Yep, and for posterity, here's a minimal PoC:
❯ echo '<picture><img src="Foo,Bar" /></picture>' | curl -s -L -X POST --data-binary @- --header "Content-Type:text/x-markdown" https://api.github.com/markdown/raw | grep -o 'src="[^"]*"'
src="Foo,Bar"
❯ echo '<picture><source srcset="Foo,Bar"> /><img /></picture>' | curl -s -L -X POST --data-binary @- --header "Content-Type:text/x-markdown" https://api.github.com/markdown/raw | grep -o 'srcset="[^"]*"'
srcset="Foo"
from shields.
Related Issues (20)
- Discord Embed not rendering HOT 3
- Azure DevOps - Build Badge - PAT Token not used on private projects HOT 1
- Chrome Web Store Version “not found” HOT 4
- On conda, the displayed badge version is outdated. HOT 2
- GitLab badges are not working HOT 5
- GitLab stars does not working anymore HOT 1
- llm trainning framework and libraries HOT 2
- GitLab top language
- Gitea workflow badge
- github/last-commit is looking at the authored date and not the commit date HOT 3
- crates.io dependents
- 🚀 SimpleIcons 12
- 404 Badge Not Found HOT 2
- Badge Request: GitHub Check ignore pending builds HOT 2
- Discord Badge has rate limit error HOT 5
- Docker Image Size arch error HOT 1
- Improve Docusaurus Dependabot setup
- Allowing on-prem azure devops repos
- OSS Lifecycle GitLab HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.