Install
This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.
Install straight from GitHub with WP-CLI:
wp plugin install https://github.com/ttldsgn/wordpress-accessible-color-palette/archive/refs/heads/main.zipA lightweight, high-performance WordPress admin utility that adds an interactive WCAG 2.2 AA compliant color generation dashboard to the Tools menu. Built specifically for theme designers and web developers, this plugin provides a real-time, split-screen playground to test light-mode brand identifiers and instantly map out contrast-optimized dark-mode equivalents.
Key Features
- 60fps Fluid Dragging Feedback: Architected with a non-destructive DOM state observer. Color properties shift instantly across the entire dashboard while dragging inside the color picker canvas—eliminating native browser reload stutter or window focus freezing.
- Automated Perceptual Dark-Mode Generation: Input a single light-mode accent or background color; the plugin automatically isolates the active brand hue and translates it to a perfectly balanced dark-mode companion.
- Layout-Driven Contrast Proofing: Unlike automated tools that evaluate swatches strictly "on paper" in isolated blocks, this utility dynamically applies contrast-corrected values directly to native layout text blocks (Headings, Subheadings, Body copy, Links, and Buttons).
- Direct Clipboard Interactivity: Click on any role-based container card or calculated hex string within the live comparison panel to instantly copy the safe, normalized hex code directly to your clipboard.
Internal Math & Validation Layer
The underlying color logic strictly adheres to official W3C web compliance equations:
- Luminance Linearization: Extracts un-multiplied channels to compute exact relative luminance values: $$C{\text{linear}} = \left(\frac{C{\text{srgb}}}{255} \le 0.03928\right) ? \frac{C{\text{srgb}}}{12.92} : \left(\frac{C{\text{srgb}} + 0.055}{1.055}\right)^{2.4}$$
- Perceptual Weighting: Evaluates luminance cross-checked with the standard human eye sensitivity spectrum ($0.2126R + 0.7152G + 0.0722B$).
- Adaptive Lightness Traversal: If a combination drops below target thresholds ($4.5:1$ for fine text, $3.0:1$ for layout borders), an internal search loop shifts the HSL lightness parameters dynamically until the closest mathematically sound color is achieved.
Upcoming Standalone Update: WCAG 3.0 & APCA Integration
Note: This feature set will be released as a separate, distinct update/addon.
To support the future of digital accessibility standards, a major upcoming release will shift the calculation engine from legacy relative luminance ratios to the Advanced Predictive Contrast Algorithm (APCA).
What's Coming in the APCA Update:
- Perceptual Contrast Modeling (Lc): Replaces rigid ratio scoring with dynamic Lightness Contrast scores ranging from
-108to106, accounting for screen polarity differences (light text on dark screens vs. dark text on light screens). - Spatial Frequency Matrices: Evaluates compliance based on the physical size and weight of your typography. The algorithm will dynamically reference font scaling rules so bold headings and body paragraphs are verified independently.
- Architectural Isolation: Thanks to the clean data separation within this current plugin, the upcoming upgrade will be deployed as a drop-in mathematical replacement inside the state pipeline—ensuring your existing configurations, WordPress admin layout, and theme workflows require zero modifications.
License
This project is open-source software licensed under the MIT License.
Releases
1 release.
These releases are tags only. The author does not attach a packaged zip, so there are no download counts to report.