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

[Feature Request] Helper Functions to Directly Check Accessibility Contrast #18

Open
iocouto opened this issue Nov 16, 2021 · 0 comments
Labels
enhancement New feature or request

Comments

@iocouto
Copy link

iocouto commented Nov 16, 2021

It would be super useful to have some helper functions that directly check whether two colours pass certain specified accessibility rating - i.e., 'aa', 'aaa', 'aaLarge' and 'aaaLarge'.

Right now, to do that we have to define the colours in question in a blueprint, then use the toReadabilityReport() method to generate an array, then search the array for the results. I'd love to be able to do the checks by simply getting a boolean from something like isAA($colour1, $colour2), or isAAALarge($colour1, $colour2).

@nilshoerrmann nilshoerrmann added the enhancement New feature or request label Nov 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants