Web Development Pro | Lesson 044 | An Accessibility Review That Finds Barriers
Web Development Pro · Lesson 44 of 60
Module 5: Quality, accessibility, and security
In this lesson
Prerequisites and learning outcomes
Complete lesson 43 first. This lesson builds on keyboard, zoom, labels, and contrast checks. By the end, you can combine automated observations with manual checks and prioritize concrete barriers. Plan 10–15 minutes for the core explanation and additional time for the worked practice.
Review a journey instead of chasing a score
Accessibility asks whether people can perceive, understand, navigate, and operate the site. A single automated score cannot answer every part. Our review follows a visitor who opens the directory, finds a repair event, reads its location, and checks the access information. Each step can reveal a practical barrier.
Start with a defined page version and environment. Record browser, operating system, viewport, zoom, and any assistive technology used. If you did not use a screen reader, leave that field untested. A documented partial review is useful; an undocumented claim of complete compliance can conceal the very barriers the review is meant to find.
Inspect structure and names
Read the HTML first. The example has a language declaration, distinct page title, skip link, navigation, main landmark, and a clear heading hierarchy. A visible label is programmatically associated with the search input. Buttons describe their actions, and ordinary links describe their destinations. These choices give browsers meaningful native semantics.
A static parser can identify missing labels or duplicate ids, but it cannot decide whether every name is helpful. “Click here” may be a valid link with poor context. Repeating “Learn more” for several different workshops may leave navigation ambiguous. Prefer a label such as “Read access information” that still makes sense when encountered separately.
<a class="skip" href="#main">Skip to main content</a>
<main id="main" tabindex="-1">
<h1>Find a workshop</h1>
<label for="query">Search workshop titles</label>
<input id="query" type="search">
</main>
The main target's negative tabindex permits programmatic focus without adding an extra regular tab stop. The skip-link journey still needs a manual browser check. Do not assume that the presence of an anchor proves the target receives useful focus in every relevant environment.
Walk the keyboard path
Set aside the mouse. Use Tab and Shift+Tab to visit interactive elements in both directions. Activate buttons with expected native keys and follow links. Check that focus is visible, follows a logical sequence, and is not trapped. Every required task should remain possible without dragging or precise pointing.
Avoid positive tabindex values to force a preferred order. They can create a navigation sequence unrelated to document order and become fragile as controls are added. Put content in a sensible source order and use normal native controls. Styling may arrange columns, but visual rearrangement should not confuse the reading or keyboard sequence.
When results update, usually keep focus on the control the visitor used and announce the new count politely. Moving focus into every fresh result can make typing or repeated filtering disorienting. If an interface genuinely needs a focus move, define its purpose and test how the visitor returns to their previous task.
Check enlargement and narrow layouts
Increase browser zoom and inspect text, controls, and navigation. Check a narrow layout too, because enlarged content has less effective space. Look for clipped labels, overlapping text, fixed-width controls, and horizontal scrolling that makes ordinary reading difficult. Some content, such as a large data table, may need a different treatment from paragraphs.
The sample stylesheet allows navigation to wrap and fields to fit available width. It includes a visible focus outline and a skip link that becomes visible when focused. These are source-level intentions until someone observes the rendered result. A CSS declaration can be overridden or clipped by surrounding layout.
Do not remove content merely to make a small screen fit. A visitor on a phone still needs the venue and access information. Reflow, wrap, and simplify the layout before hiding useful material. Test actual text, including longer event names, rather than relying only on short placeholder words.
Evaluate contrast and nonvisual meaning
Text contrast depends on foreground and background colors as actually displayed. WCAG's common minimum is 4.5:1 for ordinary text and 3:1 for qualifying large text, subject to the criterion's exceptions. Use a suitable contrast calculation or tool, then inspect states such as hover, focus, disabled controls, and errors separately.
The supplied color calculation checks only the sample's solid text/background pair. It does not analyze transparency, gradients, images, every UI component, or the whole site. A numerical result for body text cannot certify focus visibility or a pale error border. State exactly which pair was measured.
Do not convey a full event only by changing its card to red. Add a visible word such as “Full” so meaning does not depend on color perception. Alternative text should communicate an image's purpose in context; decorative imagery can have empty alt text when the surrounding content already conveys the meaning.
Prioritize findings by user impact
Write findings as barriers: “At narrow width, the search button is clipped and cannot be reached without sideways scrolling.” Include reproduction, affected task, expected behavior, and a proposed correction. “Accessibility needs work” is too vague to act on. Give blocking navigation problems priority over minor cosmetic differences.
After a correction, retest the failing step and nearby steps that may be affected. A larger focus outline can fix visibility but become clipped by an overflow container. Keep the evidence file honest about what was observed, what failed, and what remains untested. This lesson is a first review, not a certification of full accessibility conformance.
Worked practice
Worked exercise 1: Repair a vague label
Task: Three workshop links all say “More.” Worked answer: give each a meaningful accessible name, such as “Bike basics details,” while keeping visible text clear. Check the names in context and in link navigation so a visitor can distinguish destinations.
Worked exercise 2: Investigate lost focus
Task: Applying search removes the focused button and rebuilds the whole form. Worked answer: preserve the stable controls and rerender only results where possible. Then verify keyboard focus remains useful and the changed count is communicated without repeatedly moving focus.
Worked exercise 3: Scope a contrast pass
Task: Body text passes a contrast calculation. Worked answer: record that exact foreground/background pair as checked. Review links, status messages, focus indicators, and other states separately; one pair does not establish the accessibility of the whole interface.
Knowledge check
Question 1
What is the best starting unit for this review? A) A real task through a specific page version. B) A tool score without the tested version or journey. C) A count of valid elements without the tasks they support. D) A count of ARIA attributes without checking their meanings.
Check question 1: answer and explanation
Answer: A. A journey connects observations to actual user barriers.
Question 2
Why avoid positive tabindex for routine ordering? A) It gives every control a negative tab index. B) It may create an order disconnected from document structure. C) It always aligns focus with a CSS-reordered visual layout. D) It guarantees consistent order even after controls are added.
Check question 2: answer and explanation
Answer: B. Native document order is usually more coherent and maintainable.
Question 3
What can source inspection establish? A) Actual screen-reader announcements. B) Every zoomed layout. C) The presence of associated label markup. D) Every rendered contrast combination.
Check question 3: answer and explanation
Answer: C. Runtime experiences require additional observation.
Question 4
How should “Full” be communicated? A) Only with red background. B) Only with reduced opacity. C) Only through hover styling. D) With readable text, optionally supported by color.
Check question 4: answer and explanation
Answer: D. Important meaning must not depend on color alone.
Question 5
What follows a successful fix? A) Retest the affected journey and record remaining gaps. B) Declare all pages compliant. C) Delete the reproduction. D) Assume other states share the result.
Check question 5: answer and explanation
Answer: A. A local correction supplies limited evidence, not universal assurance.