SAPC-APCA
a11y-color-tokens
SAPC-APCA | a11y-color-tokens | |
---|---|---|
11 | 3 | |
402 | 158 | |
- | - | |
7.3 | 3.3 | |
1 day ago | 7 months ago | |
CSS | JavaScript | |
GNU General Public License v3.0 or later | ISC License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
SAPC-APCA
- Why the New Contrast Method APCA
-
How Americans of different ages spend their time on weekdays [OC]
Why the New Contrast Method APCA
-
Change the colour of grey text back to black on website using poor contrast text
For a more future oriented version (as setting a font to black wont work with dark pages), check out the CSS Color Module Level 5 spec for color-contrast(), which will automatically choose a color that has a proper contrast ratio: https://www.w3.org/TR/css-color-5/#funcdef-color-contrast
One caveat is it's currently only supported in Safari technical preview.
Another thing worth mentioning is the relative brightness algo used in the repo for the linked plugin is using the WCAG 2 formula for relative luminance. This works pretty well in light mode for non-colored backgrounds, but doesn't incorporate perceived luminosity differences of different hues very well. A better algorithm to use here is the Advanced Perceptual Contrast Algorithm (APCA), which is the one used in the WCAG 3 working spec. It more accurately accounts for hue: https://github.com/Myndex/SAPC-APCA
-
Please Stop Using Grey Text
Note the licensing note in the repository[1] of the APCA™ index the author’s company[2] promotes:
> The files currently in this repository are presently considered pre-release, and as such do not have a permanent license attached. In this repositiory, all files present are under a time-barred beta license, and intended for use with web-based content only, and not for any other use without written permission.
The non-pre-release stuff[3] offered to W3C is better but still seems to be intended to end up non-FOSS:
> Files in this repository are licensed to the W3/AGWG under their cooperative agreement for use with WCAG accessibility guidelines for web-based content only, and not for any other use.
(The question being, of course, how much of this is copyrightable at all.)
[1] https://github.com/Myndex/SAPC-APCA/
[2] https://www.myndex.com/CVD/
[3] https://github.com/Myndex/apca-w3/
-
WCAG 3 and updated contrast checkers?
Second: There are a number of contrast checkers that use APCA technology. The canonical "official" one is https://www.myndex.com/APCA/ but I want to mention it is an open public beta, and is not backwards compatible with WCAG_2 (this is in part because WCAG_2 is not perceptually accurate and thus the areas where WCAG_2 incorrectly fails pairs that APCA will pass is at issue).
- WCAG 3 will use a new color contrast method called APCA
-
I made a tool to check the contrast between two colours using the new contrast algorithm being drafted for WCAG 3 — also includes fun rgb/hsl/lch sliders and buttons to adjust either colour to a desired contrast!
Andrew Somers W3 AGWG Invited Expert Color Science Researcher Myndex Perception Research Inventor APCA/co-author WCAG3
a11y-color-tokens
-
Build Tools and Extensions I Use In Front-End Projects
I've also created a package to help me with developing accessible color palettes called a11y-color-tokens which I use for more complex projects.
-
Nevertheless, 5t3ph Coded and (Mostly) Conquered Imposter Syndrome
Eleventy let me boilerplate certain aspects, and I created additional tools to help me create color palettes and social share images. Those freed me to focus on architecting my idea and preparing content and design and ensuring accessibility. Then - out the door it went!
-
Generate Accessible UI Colors with a11y-color-tokens
Additionally, an optional Markdown document is generated with contrast cross-compatibility between all available color tokens.
What are some alternatives?
web-skills - A visual overview of useful skills to learn as a web developer
style-dictionary - A build system for creating cross-platform styles.
CCAe - The Colour Contrast Analyser (CCA) helps you determine the legibility of text and the contrast of visual elements, such as graphical controls and visual indicators.
buttonbuddy - Learn about accessible button contrast then generate your own accessible button color palette
validate-access - Parse a & Validate a given directory with multiple entries
chakra-ui-vue - ⚡️ Build scalable and accessible Vue.js applications with ease.
luminosity-css - 💡 Duo of customizable CSS classes to define a light source location and cast dynamic shadows off elements based on their relative position. Themable and customizable with CSS variables
11ty-sass-skeleton - Featuring absolutely nothing beyond a base HTML5 template and the essential setup to watch and compile your Sass alongside 11ty.
feedback - Public feedback discussions for: GitHub for Mobile, GitHub Discussions, GitHub Codespaces, GitHub Sponsors, GitHub Issues and more! [Moved to: https://github.com/github-community/community]
Discord-Tokens-Checker - A small script to check if your discord tokens are functional or not
dark-background-light-text-
tinycolors - Color names supported by all browsers.