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

Is there a way to circumvent the Fails WCAG SC 1.4.4 error? #11

Closed
kobe-f8 opened this issue Apr 25, 2024 · 8 comments
Closed

Is there a way to circumvent the Fails WCAG SC 1.4.4 error? #11

kobe-f8 opened this issue Apr 25, 2024 · 8 comments

Comments

@kobe-f8
Copy link

kobe-f8 commented Apr 25, 2024

I get this error on my latest project where i'm working with a lot of large font size that have to be reduced to a much smaller font size on mobile. Like this case for example: ~text-sm/4xl.

But that gives me this error:

/* not fluid from 0.875rem at 40rem to 2.25rem at 80rem: Fails WCAG SC 1.4.4 at i.e. 200rem */

I'm I doing something wrong or could this be a bug?

@barvian
Copy link
Owner

barvian commented Apr 25, 2024

Hey, thanks for filing. The warning is there because that text wouldn't enlarge to 2x its size if someone tried to 5x zoom the page at a screen width of i.e. 100rem, which would create the accessibility violation.

That being said, it'd probably be good to be able to opt out of these warnings. I'll think about this and keep this open for now!

@kobe-f8
Copy link
Author

kobe-f8 commented Apr 25, 2024

Thank you for looking into it and for the quick response 🙌🏻

@peterpalkovic
Copy link

That being said, it'd probably be good to be able to opt out of these warnings.

This would be useful in some scenarios.

@barvian
Copy link
Owner

barvian commented May 1, 2024

@kobe-f8 @peterpalkovic I'm thinking of adding an option you could pass to the plugin that would warn about these issues on the console but still output the fluid code. Would that work for your use cases or were you hoping for a different approach?

@kobe-f8
Copy link
Author

kobe-f8 commented May 2, 2024

Sounds good to me!

@krstivoja
Copy link

@barvian any update on this? This would be really good for some design cases.

@barvian
Copy link
Owner

barvian commented May 8, 2024

@krstivoja Working on this feature for v0.2.0! Here's a preview of the docs

barvian added a commit that referenced this issue May 8, 2024
@barvian
Copy link
Owner

barvian commented May 8, 2024

This feature is now live in v0.2.0 (see #15)! Feel free to comment in the discussion or open another issue if you find a bug. Thanks for the feedback 🙂

@barvian barvian closed this as completed May 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants