Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Info badge colour #31749

Closed
calvinkarpenko opened this issue Sep 25, 2020 · 8 comments · Fixed by #31839
Closed

Info badge colour #31749

calvinkarpenko opened this issue Sep 25, 2020 · 8 comments · Fixed by #31839

Comments

@calvinkarpenko
Copy link

calvinkarpenko commented Sep 25, 2020

This is the first time I've reported something so I'm not sure if I'm doing it in the right place or not.

I note that the new info badge doesn't provide sufficient colour contrast per AA guidelines in the V5 Alpha 2.

https://v5.getbootstrap.com/docs/5.0/components/badge/

The contrast is 1.96 apparently when used with white text as seen in the docs. I use it with black text myself, which does provide the contrast required.
So the docs either need changing or the colour needs changing :)

@XhmikosR
Copy link
Member

Thanks for the issue, but please don't grab random PR URLs 😛

The v5 docs are on https://v5.getbootstrap.com/ or the main branch on https://twbs-bootstrap.netlify.app

@calvinkarpenko
Copy link
Author

Noted for future! :) I have checked on the main branch just to make sure and the issue exists on there too :)

@Mx-Glitter
Copy link

@calvinkarpenko For your information, this is already documented here: https://v5.getbootstrap.com/docs/5.0/getting-started/accessibility/#color-contrast

There are probably related issues you should find and read first to understand the rationale behind this choice before proposing to change it 😊

@calvinkarpenko
Copy link
Author

@Mx-Glitter - Thanks for the reply - I'm aware of that and was just mentioning it because it wasn't AA compliant in the docs for Alpha 2 - and figured it may have been slightly overlooked. I'm under the impression that the aim is for the docs to be AA compliant as well :)

@XhmikosR
Copy link
Member

We are working towards this, and v5 has already many improvements. I have a WIP PR we plan to land at some point, #29315 .

@calvinkarpenko
Copy link
Author

We are working towards this, and v5 has already many improvements. I have a WIP PR we plan to land at some point, #29315 .

I'm well aware and have been following with interest :) I just didn't know how else to notify you of this and was under the impression it may have been missed, that's all :)

@XhmikosR
Copy link
Member

@ffoodd don't we have another issue/PR we track this stuff already?

@ffoodd
Copy link
Member

ffoodd commented Oct 5, 2020

We do (#30548) and we somehow solved this with #31276 — however badges don't have color variants, they're only relying on our color utilites.

The info badge example should simply use .text-dark alongside .bg-info to comply, just like warning and light badges. PR incoming :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants