Tools & Workflow / Design practice
Check accessible colour in real states
Follow a component through focus and error to find colour problems a palette sheet cannot show.
A design file can show a clean set of accessible colour pairs and still miss the moment when somebody tabs into an invalid field. The error border and the focus outline may blend together. A light warning panel may sit on a surface the palette was never checked against. Test colour where an action changes the page, with the component in its actual surroundings.
Rehearse the states people can reach
Take a fictional newsletter form. Start with an empty field, move to it with Tab, enter an incomplete address and submit. Then return to the field to correct it. That last step matters: invalid and focused can happen together, though a design board may show them in separate frames. Check the combined state in the browser, including on any tinted panel or dark theme that actually hosts the form.
For each step, write down what needs to be seen. The label names the field. The focus indicator marks where keystrokes go. The error explains what to correct. This gives you a list of things to measure and tells you why each one matters.
Measure the pair that appears on the page
WCAG 2.2 Level AA sets a 4.5:1 minimum for ordinary text, with a 3:1 minimum for qualifying large text. Its non-text criterion calls for at least 3:1 against adjacent colours for visual information needed to identify active controls and their states, subject to the criterion's exceptions. Check the error copy as text, and check the focus indicator against the adjacent colour it needs to stand out from.
Use the effective colours, not just the names of the tokens. For a hypothetical solid warning panel, ordinary text in #777777 on #FFF4E5 comes out to about 4.12:1. Changing the text to #595959 raises that pair to about 6.45:1. If the warning fill is translucent, calculate against its composited background instead. For a gradient, check the least favourable area behind the text.
Fix the meaning as well as the ratio
Imagine the example field signals an error only by turning its border red. Darkening the red may improve a contrast reading, but it still asks the reader to infer the problem from hue. Add visible copy such as 'Enter an email address with a domain, such as name@example.com' and associate that message with the field in the markup. Give focus its own outline, separated from the border so the error and the current position can both be seen.
Retest by tabbing away and back. Does the outline remain visible without hiding the error cue? Can you still locate the field in the narrower layout? A grayscale preview can expose cues that depend entirely on hue, but it does not replace the contrast measurements or the keyboard check.
Record what passed and what you changed
Save the component state, surface, measured pairs and corrective action together. Put the combined focus and error state in the component's examples so a later token change can be checked against it. The useful record isn't 'red passed'. It's which signal remained visible, against which background, while a reader was correcting the form.
Make a map of the states that coexist
Imagine a fictional community hall booking calendar. A visitor has selected Thursday evening and tabs to Friday to compare availability. The two dates now have different jobs: Thursday shows the existing selection, while Friday shows where the next keystroke will go. Draw those jobs in separate columns of a review sheet. Then make a state with both on the same date. A palette preview with one swatch per state won't show whether the signals continue to make sense together.
Use brief sentences to define what needs to be visible: 'This date is selected', 'I am on this control' and 'This session has no places'. Try them as you step through the calendar. If both focus and selection use the same bold green fill, changing the shade of one may not teach anyone which state it represents. Try a visible selection mark or words, and keep a distinct treatment for focus that remains visible when the two coincide.
Choose only combinations the component can reach, but include the transitions that produce them. For example, a date that becomes unavailable while selected needs an explanation and a clear path to choose another. It isn't enough to show a muted cell in the isolated unavailable example. Check the combined screen: what happened to the previous choice, which date can the visitor act on and where is the message about the change?
If the calendar offers a simpler list view, review the same jobs in that view. The visual treatment can differ as long as the distinction survives. A legend for a coloured grid isn't necessarily the best answer in a list that already has room for plain status text. Keep the two versions' words consistent where they describe the same state, so a visitor doesn't have to learn a new set of terms.
Measure the neighbours that define the cue
On the fictional calendar, imagine a selected date has a coloured tile on a tinted week row. Its focus outline sits just outside the tile. Look at what actually touches the outline around the sides and corners. A swatch measurement against the tile may not describe what someone sees when most of the line is against the tinted row. List the pairs and mark which boundary each one describes before changing the token.
If a ring runs across different backgrounds, inspect the places where its visibility is weakest. You could try giving the ring a consistent backing or changing the placement so it has a clear relationship with the control. Compare those changes to making the ring darker everywhere. A stronger colour on the pale side could be less visible on the dark side. Use the real tile arrangement to judge the proposed remedy.
Separate the numerical result from whether the line is present. A proposed outline may contrast adequately with a neighbouring colour and still be partly hidden by the calendar's scrolling edge. Reach the last date in view with the keyboard and inspect the whole indicator, with the week heading still present if it can overlap the dates. If the line is cut off, fix its placement or surrounding layout; a different colour won't restore an edge that isn't drawn on screen.
Keep a separate check for the date label and any availability words inside the tile. Those details can become harder to read when the selection fill changes, even when the new outline is clear. Mark which pair you measured for each purpose. A single approved pair for 'calendar green' is not enough information to decide whether a future theme can use that colour for the label, boundary and selection.
Give the status and the action separate jobs
Say the booking opens an availability panel. A selected time is held while the visitor enters their details. A tinted panel could indicate a pending hold, a confirmed booking or an error depending on its words and controls. Put plain status text next to the specific time and venue. Keep the action visually identifiable in each version. A visitor returning from another window may not remember which shade was there before, so the panel should make sense without that comparison.
For a pending hold, decide what someone can do while waiting and what they should do if the hold fails. Place any explanatory text where the actual next action is offered. If the main action becomes temporarily unavailable, don't let the only readable explanation disappear with it. Compare the appearance of the inactive control with the still useful surrounding text. Muting an entire panel for a single unavailable command may also mute the information needed to recover.
Consider two different failure causes in the fixture: a time someone else has just taken, and a request the service couldn't complete. The first may require another time; the second may offer a retry of the same one. Both panels could share a warning treatment, but the words and actions should identify the difference. Check whether the focus indicator on the next action stays distinct on each warning surface.
Review the point at which the state changes. If a person is already on a control when a warning appears above it, try the next navigation step rather than judging the alert in isolation. Confirm that the reader can find the explanation and a usable next step. A numerical result against the intended backdrop is valuable, but it doesn't say whether a newly inserted cue got overlooked.
Use colour where it helps scanning without making it carry the instructions
Picture the calendar filled with short sessions that use different tones to group rooms. The tones can help give the week a rhythm, but the visitor still needs to identify the room in a date they can actually book. In each cell or adjacent detail, keep its name or an unmistakable text label. Check how it reads when the date is also selected. One colour assigned to a room and another assigned to a booking state can otherwise compete for the same patch of background.
Try a version that moves the room colour to a small accent and reserves the main surface for states. The visitor may then be able to compare available sessions and still find the room without reading a distant legend. If the panel becomes noisier, try grouping the entries under plain room names instead. A good check asks someone to identify the correct session and room from the actual arrangement. It doesn't ask them which of two decorative shades they prefer.
Use a deliberately similar pair of fixtures, such as 'Studio, Thursday evening' and 'Main hall, Thursday evening'. Find the selected one, then change it using the keyboard. In a narrow view, make sure the room name hasn't been replaced by an unexplained dot. Where space is tight, reorganise the content or choose a clear shorter label with the editor rather than making the colour the only remaining distinction.
Document where colour is useful but optional. The room accent can survive as decoration if the words do the work, while the visible focus indicator has a different job. Keeping those decisions apart makes subsequent theme changes easier. The designer can adjust the palette accent without having to renegotiate the meaning of the date's current state.
Compare a theme change one affected state at a time
Suppose the hall site moves the calendar from a white page to a pale coloured booking panel. Start with one selected date and one unselected date, then run the combined focus state and the unavailable state inside that new panel. Compare the affected colours as rendered. Reusing a label token elsewhere is no reason to trust it here. Name the relevant adjacent surfaces in the record, especially if a card, row and tile can differ.
For a dark variant, take the same route through the fixture rather than assembling an entirely different set of examples. Use the same date and status so you can compare jobs, not merely colours. If a selection mark is visible but looks like part of the date label, try a placement change. If the text and outline both stand out but the selected tile disappears into the row, check whether the words and selection mark already distinguish it before adding another border.
Where your intended audience uses a system appearance or colour override that the team can test, include it as its own viewing condition. Observe the reachable state rather than guessing from the palette. For example, check that the booking choice and keyboard position still look different. If one of the coloured fills isn't present in that view, the visible state marker should still help. Record exactly which viewing condition you used and avoid generalising from it.
Reject a fix that simply trades one unclear state for another. If a local rule makes the error message very visible but causes secondary text in ordinary bookings to fade, reduce the change to the treatment that belongs to the message. Then recheck one ordinary booking alongside the error. This comparison helps a reviewer see whether the improvement came from a deliberate treatment or an incidental change to everything on the panel.
Save a state sequence rather than a palette verdict
For the calendar, store a short fixture with two rooms, one unavailable time and a visible choice. Keep a repeatable route through it: choose the studio, move to the hall, then let the chosen time become unavailable in the fixture. Identify which text, marker and focus boundary you checked at each step. If you attach a measurement, include the precise pair and reason it matters. A crop that shows the affected control and its immediate surface will help reviewers find the pair again.
Make the expected distinction explicit in a review note. For example, say that the keyboard marker is visible on the unselected hall time while the studio's selection mark remains, or that the pending hold text stays readable when the main booking action is unavailable. These are examples of observations to make, not records of a completed audit. Report an unresolved or untested combination as such so later editors know where evidence ends.
Keep failures in separate categories. A low measured contrast pair, a marker cropped at the edge and a status communicated only by hue may all affect the same element. Each has a different remedy and deserves its own retest. Repeating the calculation after changing the token doesn't establish that the outline has room or that the message is now understandable. Revisit the actual interaction after each significant change.
Begin your next review with a control in two states at once. Choose one where the distinction matters to a real action, write what a person needs to notice and try reaching it without a pointer. Measure the colours you encounter, then use the action to check whether the meanings stay distinct. That small review will tell you which examples belong in the component's permanent documentation.