{
  "test_case_id": "A11Y-KBD-003",
  "title": "No keyboard trap",
  "category": "keyboard_only",
  "procedure_version": "2026.08.27-rc.9",
  "rule_type": "atomic",
  "wcag_criteria": [
    "2.1.2"
  ],
  "level": "A",
  "risk": "medium",
  "risk_basis": "Detect components that trap keyboard focus or fail to tell users how to leave with the keyboard. People most likely affected: people who use a keyboard, switch control, voice input or another keyboard-interface device. A trapped user may be unable to reach later content, return to earlier content or complete the task. In the recorded web-desktop-cross-browser environment, prioritise modal layers, composite widgets, validation and recovery paths, where unreachable controls, an illogical focus sequence or a keyboard trap can stop task completion.",
  "review_status": "draft",
  "reviewed_at": "",
  "review_note": "Template content is subject to a hash-bound internal consistency review. Formal assessment claims require competent execution, current evidence and the applicable legal, participant and organisational authority.",
  "method_label": "Keyboard journey",
  "tester_level": "General QA tester",
  "estimated_duration": "Typically 40–58 minutes for the stated single-target assumptions; use the component breakdown when estimating a real sample.",
  "execution_class": "manual_with_automation_support",
  "automation_support": "supporting_evidence_only",
  "simulation_policy": "simulation_may_support_but_not_replace_manual_execution",
  "plain_summary": "Move keyboard focus into and out of each component, including documented non-standard exit methods.",
  "objective": "Detect components that trap keyboard focus or fail to tell users how to leave with the keyboard.",
  "test_subject": "Every component in the selected scope that can receive keyboard focus internally.",
  "test_targets": [
    "Each component boundary entered by keyboard, including dialogs, embedded content, editors, menus, composite widgets and media players."
  ],
  "applicability": "Apply when keyboard focus can enter a component. Test both forward and reverse entry and every mode that changes the exit method.",
  "applicability_questions": [
    "Can keyboard focus enter the component?",
    "Can focus move away using only a keyboard interface?",
    "If leaving requires more than standard unmodified arrow, Tab or other standard exit methods, is the method advised before or when focus enters?"
  ],
  "inapplicability_conditions": [
    "No component in the selected subject accepts internal keyboard focus."
  ],
  "assumptions": [
    "The selected scope identifies the product version, technologies, states and important user journeys being evaluated.",
    "The tester knows how to use this method and any required assistive technology.",
    "Known browser or assistive-technology limitations are recorded instead of being assigned to the product without evidence."
  ],
  "accessibility_support_assumptions": [
    "The result covers only the browsers, platforms, readers and assistive technologies that were actually tested.",
    "Do not apply a result from one technology combination to an untested combination or to every user."
  ],
  "prerequisites": [
    "The product area and test targets are agreed before testing starts.",
    "The operating system, browser, viewport and input method are recorded.",
    "Test data is safe to use and does not expose unnecessary personal information."
  ],
  "required_environment_fields": [
    "operating_system",
    "operating_system_version",
    "browser",
    "browser_version",
    "viewport_css_pixels",
    "input_method"
  ],
  "steps": [
    {
      "step_id": "S1",
      "title": "Define one component boundary and exit contract",
      "phase": "prepare",
      "scenario_purpose": "Select one component and document how keyboard users are expected to enter and leave it.",
      "user_impact": "Unclear boundaries make traps difficult to reproduce and can hide loss of navigation control.",
      "test_target": "One dialog, embedded frame, editor, menu, composite widget, media player or full-screen component.",
      "required_state": "Closed/default state plus the exact open or editing state to be tested.",
      "tool_or_command": "Keyboard-only inventory; component documentation where a non-standard exit is designed.",
      "action": "Record the component identifier, trigger, first internal focus target, expected standard exit keys and any documented non-standard exit sequence.",
      "expected": "One reproducible component/state and its exit contract are recorded.",
      "failure_observation": "The tester groups unrelated components together or cannot identify an entry and expected exit path.",
      "evidence_to_record": "Component ID, route, trigger, state, entry point and expected exit method.",
      "decision_rules": {
        "passed": "The selected boundary and expected exit are unambiguous.",
        "failed": "The boundary or exit contract cannot be identified from product behaviour or supplied instructions.",
        "not_applicable": "No component in the agreed sample accepts keyboard focus internally.",
        "blocked": "The component cannot be reached in the authorised build or state."
      },
      "decision_effect": "Passed: The selected boundary and expected exit are unambiguous. Failed: The boundary or exit contract cannot be identified from product behaviour or supplied instructions.",
      "recovery_or_repeat": "Restore the component to its closed state and repeat one boundary at a time.",
      "novice_guidance": "Restore the component to its closed state and repeat one boundary at a time.",
      "limitations_and_claim_boundary": "This preparation scenario does not by itself show that a keyboard trap exists."
    },
    {
      "step_id": "S2",
      "title": "Enter the component with forward navigation",
      "phase": "test",
      "scenario_purpose": "Verify forward sequential navigation crosses into the selected boundary predictably.",
      "user_impact": "Unexpected entry can disorient keyboard and switch users.",
      "test_target": "The component selected in S1.",
      "required_state": "Focus on the immediately preceding focusable control; component in its recorded start state.",
      "tool_or_command": "Physical keyboard; press Tab or the platform's recorded forward-navigation key once at a time.",
      "action": "Move focus forward until it enters the component. Record the first internal focus target and every key pressed.",
      "expected": "Focus enters the expected first target without an unrelated context change.",
      "failure_observation": "Focus skips the component, enters an unexpected internal target, disappears or triggers an unrequested change.",
      "evidence_to_record": "Key sequence, start target, first internal target and focus indicator capture.",
      "decision_rules": {
        "passed": "Focus enters predictably and remains perceivable.",
        "failed": "Entry itself is broken; record separately from an exit trap.",
        "not_applicable": "The component is intentionally not part of sequential focus and has another documented keyboard entry method.",
        "blocked": "A platform or product error prevents reaching the preceding control."
      },
      "decision_effect": "Passed: Focus enters predictably and remains perceivable. Failed: Entry itself is broken; record separately from an exit trap.",
      "recovery_or_repeat": "Reload, restore the recorded start state and retry once; if still blocked preserve the last reachable focus target.",
      "novice_guidance": "Reload, restore the recorded start state and retry once; if still blocked preserve the last reachable focus target.",
      "limitations_and_claim_boundary": "This scenario assesses forward entry only, not reverse entry or exit."
    },
    {
      "step_id": "S3",
      "title": "Leave the component with forward navigation",
      "phase": "test",
      "scenario_purpose": "Verify the standard forward method can move focus beyond the boundary.",
      "user_impact": "A user trapped inside a component cannot reach later content or finish the journey.",
      "test_target": "The same component in the same mode used in S2.",
      "required_state": "Focus on the first internal target after successful forward entry.",
      "tool_or_command": "Physical keyboard; use only documented in-component keys and Tab until focus should leave.",
      "action": "Navigate through the component and continue forward using its standard keyboard interaction until focus reaches the next external control.",
      "expected": "Focus reaches a predictable control outside the component without pointer input.",
      "failure_observation": "Focus cycles indefinitely, disappears, returns to the same internal targets or requires an undocumented pointer action.",
      "evidence_to_record": "Full key sequence, internal focus sequence, expected next control, actual final focus and video or focus log when permitted.",
      "decision_rules": {
        "passed": "Focus leaves with a standard or timely documented method.",
        "failed": "Focus cannot leave using the permitted keyboard method.",
        "not_applicable": "The component contains no internal keyboard focus after S1 review.",
        "blocked": "The environment crashes or the next external target is unavailable because of unrelated build failure."
      },
      "decision_effect": "Passed: Focus leaves with a standard or timely documented method. Failed: Focus cannot leave using the permitted keyboard method.",
      "recovery_or_repeat": "Try the documented cancellation or completion path once; do not use developer tools or a pointer to manufacture an exit.",
      "novice_guidance": "Try the documented cancellation or completion path once; do not use developer tools or a pointer to manufacture an exit.",
      "limitations_and_claim_boundary": "A modal dialog may intentionally contain focus while open; it passes only if a keyboard method closes it and restores focus appropriately."
    },
    {
      "step_id": "S4",
      "title": "Enter the component with reverse navigation",
      "phase": "test",
      "scenario_purpose": "Check that approaching the same boundary from the following control does not expose a direction-specific trap.",
      "user_impact": "Reverse navigation is essential for users who overshoot or review previous controls.",
      "test_target": "The component selected in S1.",
      "required_state": "Focus on the immediately following external control; component in its recorded start state.",
      "tool_or_command": "Physical keyboard; Shift+Tab or the recorded reverse-navigation command.",
      "action": "Move focus backward until it enters the component. Record the first internal target reached from this direction.",
      "expected": "Reverse navigation enters at a predictable boundary target.",
      "failure_observation": "Focus disappears, skips required content or enters an internal loop before the boundary can be understood.",
      "evidence_to_record": "Reverse key sequence, start target, first internal target and state.",
      "decision_rules": {
        "passed": "Reverse entry is predictable.",
        "failed": "Reverse entry exposes a broken path that prevents subsequent exit.",
        "not_applicable": "No following focusable control exists and the component cannot be approached in reverse within the journey.",
        "blocked": "The following control cannot be reached because of an unrelated blocker."
      },
      "decision_effect": "Passed: Reverse entry is predictable. Failed: Reverse entry exposes a broken path that prevents subsequent exit.",
      "recovery_or_repeat": "Use a safe deep link or prior journey step only if it is part of the approved test plan; record any alternative setup.",
      "novice_guidance": "Use a safe deep link or prior journey step only if it is part of the approved test plan; record any alternative setup.",
      "limitations_and_claim_boundary": "A not-applicable reverse path does not override a failed forward exit."
    },
    {
      "step_id": "S5",
      "title": "Leave the component with reverse navigation",
      "phase": "test",
      "scenario_purpose": "Verify reverse sequential navigation can cross back out of the boundary.",
      "user_impact": "Direction-specific loops can strand users who navigate backward.",
      "test_target": "The same component after successful reverse entry.",
      "required_state": "Focus on the first internal target reached in S4.",
      "tool_or_command": "Physical keyboard; Shift+Tab or the component's documented reverse/cancel command.",
      "action": "Navigate backward using permitted keys until focus reaches the preceding external control.",
      "expected": "Focus leaves the component and lands predictably outside it.",
      "failure_observation": "Focus loops internally, disappears or requires pointer input or an undisclosed key sequence.",
      "evidence_to_record": "Key sequence, internal focus order and actual external landing target.",
      "decision_rules": {
        "passed": "Focus leaves predictably in reverse.",
        "failed": "Focus cannot leave by the permitted keyboard path.",
        "not_applicable": "Reverse entry was legitimately not applicable in S4.",
        "blocked": "The state becomes unavailable for reasons unrelated to keyboard operation."
      },
      "decision_effect": "Passed: Focus leaves predictably in reverse. Failed: Focus cannot leave by the permitted keyboard path.",
      "recovery_or_repeat": "Restore and repeat from S4 once; retain both runs if behaviour is intermittent.",
      "novice_guidance": "Restore and repeat from S4 once; retain both runs if behaviour is intermittent.",
      "limitations_and_claim_boundary": "This scenario covers reverse exit only."
    },
    {
      "step_id": "S6",
      "title": "Verify any non-standard exit instruction",
      "phase": "test",
      "scenario_purpose": "Ensure a required non-standard escape sequence is disclosed before it is needed and actually works.",
      "user_impact": "Undisclosed commands leave users trapped even when a technical escape exists.",
      "test_target": "A component whose designed exit is not a standard platform keyboard method.",
      "required_state": "Before focus enters, and again while focus is inside the component.",
      "tool_or_command": "Keyboard plus accessibility-tree or DOM inspection for the instruction relationship.",
      "action": "Locate the exit instruction before entry or when focus enters. Confirm it names the exact command, is programmatically available, then execute it once.",
      "expected": "The timely instruction is understandable and the exact command moves focus outside.",
      "failure_observation": "The instruction is absent, appears only after a failed attempt, is not programmatically associated, names the wrong command or the command does not exit.",
      "evidence_to_record": "Instruction text and relationship, timing, command used and resulting focus target.",
      "decision_rules": {
        "passed": "Instruction is timely, available and effective.",
        "failed": "Any instruction or command requirement is unmet.",
        "not_applicable": "The selected component uses only standard keyboard exit methods.",
        "blocked": "The instruction cannot be exposed because the build or inspection environment is unavailable."
      },
      "decision_effect": "Passed: Instruction is timely, available and effective. Failed: Any instruction or command requirement is unmet.",
      "recovery_or_repeat": "Do not guess hidden shortcuts; request the documented interaction contract and mark blocked until available.",
      "novice_guidance": "Do not guess hidden shortcuts; request the documented interaction contract and mark blocked until available.",
      "limitations_and_claim_boundary": "Passing this scenario does not excuse a trap in another component state or direction."
    }
  ],
  "expectations": [
    {
      "expectation_id": "E1",
      "statement": "Focus can leave each entered component using only a keyboard interface.",
      "outcome_if_unmet": "failed"
    }
  ],
  "exceptions": [
    "Use only an exception stated in the relevant standard, or an agreed out-of-scope decision. Record the reason and evidence.",
    "A tool limitation, lack of time or unavailable assistive technology is a limitation or incomplete result, not a pass."
  ],
  "outcome_definitions": {
    "passed": "The applicable test target meets every expectation in this rule or procedure.",
    "failed": "The applicable test target does not meet at least one expectation in this rule or procedure.",
    "inapplicable": "The test subject contains no target that matches this rule or procedure's applicability.",
    "cantTell": "The tester cannot fully determine applicability or whether every expectation is met.",
    "untested": "The test subject or target was not evaluated using this rule or procedure."
  },
  "examples": [
    {
      "example_id": "A11Y-KBD-003-EX-PASSED",
      "outcome": "passed",
      "scenario": "Representative calibration example, not client evidence. Procedure: No keyboard trap. Target: One dialog, embedded frame, editor, menu, composite widget, media player or full-screen component. Action: Record the component identifier, trigger, first internal focus target, expected standard exit keys and any documented non-standard exit sequence. Evidence: Component ID, route, trigger, state, entry point and expected exit method. Observed result: One reproducible component/state and its exit contract are recorded."
    },
    {
      "example_id": "A11Y-KBD-003-EX-FAILED",
      "outcome": "failed",
      "scenario": "Representative calibration example, not client evidence. Procedure: No keyboard trap. Target: One dialog, embedded frame, editor, menu, composite widget, media player or full-screen component. The tester completes the recorded action, but the captured evidence does not demonstrate: One reproducible component/state and its exit contract are recorded. The failed target and state remain separate from unexecuted targets."
    },
    {
      "example_id": "A11Y-KBD-003-EX-INAPPLICABLE",
      "outcome": "inapplicable",
      "scenario": "Representative scope example, not client evidence. No selected component accepts internal keyboard focus. The completed inventory is retained as the basis for the inapplicable outcome."
    },
    {
      "example_id": "A11Y-KBD-003-EX-CANTTELL",
      "outcome": "cantTell",
      "scenario": "Representative unresolved example, not client evidence. The component's standard interaction contract or actual focus location cannot be determined after reasonable investigation. The record identifies the conflicting evidence and the expertise or comparison needed to resolve it."
    },
    {
      "example_id": "A11Y-KBD-003-EX-UNTESTED",
      "outcome": "untested",
      "scenario": "Representative execution-gap example, not client evidence. The target is applicable, but a required state, environment, action or evidence item was not completed. The missing action, state or environment remains open and is not converted to a pass."
    }
  ],
  "sampling_rule": "Run each selected critical journey from start to finish, including its main error and recovery paths. Record which journeys and states were included.",
  "complete_process_requirement": "If this check is part of a user journey, test the selected journey from start to finish, including relevant errors and recovery. Record any path that was not tested.",
  "pass_criteria": "Keyboard focus can be moved away from the component using only a keyboard interface; when a non-standard exit method is required, the user is advised of that method before or when focus enters.",
  "fail_criteria": "Keyboard focus enters the component but cannot leave using a keyboard interface, or a non-standard exit method works but is not advised at the required time.",
  "evidence_requirements": [
    "Component, mode, entry directions and expected exit method.",
    "Exact keystrokes, focus sequence, exit target and pointer-free result.",
    "Non-standard exit instruction, timing and programmatic exposure where used.",
    "Any operational block, affected scope, alternative environment and remaining requirement."
  ],
  "official_source_ids": [
    "W3C-WCAG22",
    "W3C-ARIA-APG",
    "MICROSOFT-EDGE-A11Y",
    "W3C-WCAG22-TECHNIQUES"
  ],
  "act_rule_mapping": {
    "format_alignment": "This is a project-authored manual procedure, not a W3C Approved ACT Rule.",
    "approved_rule_ids": [],
    "approved_rules": [],
    "mapping_status": "No supporting ACT rule selected",
    "registry_reviewed_at": "2026-08-27",
    "registry_source_id": "W3C-ACT-RULES",
    "mapping_rationale": "An ACT result can support only the part of this procedure covered by that rule. It does not replace the remaining manual or assistive-technology checks."
  },
  "technique_traceability": [
    {
      "wcag_criterion": "2.1.2",
      "understanding_url": "https://www.w3.org/WAI/WCAG22/Understanding/no-keyboard-trap.html",
      "techniques_registry_source_id": "W3C-WCAG22-TECHNIQUES",
      "technique_ids_applied": [],
      "failure_ids_applied": [],
      "selection_status": "Select relevant techniques during the test",
      "selection_note": "Techniques are examples, not extra requirements. Record any technique or common failure used, but decide the result against the success criterion."
    }
  ],
  "platform_ids": [
    "web-desktop-cross-browser"
  ],
  "review_requirement": "A qualified accessibility reviewer must confirm the scope, evidence and result before it is reported as final.",
  "known_issues": [
    "Check relevant browser, tool or assistive-technology release notes before assigning unexpected behaviour to the product.",
    "If responsibility is unclear, record the reproducible behaviour and use cannot tell until it is resolved."
  ],
  "change_log": [
    {
      "version": "2026.08.27-rc.9",
      "change": "Reworked for plain language, case-focused steps, scoped evidence and transparent draft review status."
    },
    {
      "version": "2026.08.27-rc.9",
      "change": "Case-specific specialist content, evidence and platform boundaries completed for hash-bound agent verification."
    },
    {
      "version": "2026.08.27-rc.9",
      "change": "Individually authored reference-procedure content prepared for competent review and execution."
    },
    {
      "version": "2026.08.27-rc.9",
      "change": "Removed administrative filler steps, added contextual risk and result boundaries, and prepared the concise worksheet flow for internal consistency review."
    }
  ],
  "tags": [
    "critical-journey",
    "keyboard",
    "keyboard_only"
  ],
  "status": "draft",
  "authoring_readiness": "content_complete",
  "short_title": "Leave every keyboard component",
  "catalogue_version": "2026.08.27-rc.9",
  "identity": {
    "stable_case_id": "A11Y-KBD-003",
    "procedure_title": "No keyboard trap",
    "short_user_centred_title": "Leave every keyboard component",
    "procedure_version": "2026.08.27-rc.9",
    "catalogue_version": "2026.08.27-rc.9",
    "status": "draft",
    "category": "keyboard_only",
    "procedure_type": "atomic",
    "execution_class": "manual_with_automation_support",
    "intended_tester_expertise": "General QA tester",
    "effort_model": {
      "model": "component_effort_v2",
      "small_scope_minutes": {
        "minimum": 40,
        "maximum": 58
      },
      "warning": "Add a new per-target execution and evidence allowance for each additional target class or state that could produce a different result. Add setup time for each distinct environment.",
      "calculation_guidance": "Add the recorded setup, per-target execution, evidence and technical-review components; then apply the stated variation rule.",
      "unit": "minutes",
      "setup": {
        "typical": 12,
        "includes": "Confirm scope and target, prepare safe data, establish the required state and record the tool or environment version."
      },
      "per_target_execution": {
        "typical": 12,
        "includes": "Perform the procedure once for one target in its selected states; this excludes remediation and retesting."
      },
      "evidence_capture": {
        "typical": 8,
        "includes": "Capture, name and cross-reference the minimum reproducible evidence while removing unnecessary personal or secret data."
      },
      "technical_review": {
        "typical": 8,
        "includes": "Check applicability, observations, outcome logic, evidence sufficiency and report wording before issue publication."
      },
      "typical_total_range": {
        "minimum": 40,
        "maximum": 58
      },
      "assumptions": "one short journey with up to ten focusable controls; complex widgets and dialogs add separate scenario runs",
      "variation": "Add a new per-target execution and evidence allowance for each additional target class or state that could produce a different result. Add setup time for each distinct environment.",
      "excludes": "Client coordination, inaccessible-environment recovery, recruitment, legal review, remediation implementation and waiting time unless the procedure states otherwise."
    },
    "related_procedures": [
      "A11Y-WCAG-022"
    ],
    "replaces": [],
    "replaced_by": []
  },
  "purpose_and_user_impact": {
    "barrier_detected": "Detect components that trap keyboard focus or fail to tell users how to leave with the keyboard.",
    "people_likely_affected": [
      "People who use a keyboard, switch control, voice input or another keyboard-interface device."
    ],
    "functionality_or_information_at_risk": "A trapped user may be unable to reach later content, return to earlier content or complete the task.",
    "result_scope": "atomic_conformance_check",
    "claim_boundary": "This No keyboard trap procedure determines whether the recorded targets meet WCAG 2.1.2 on web-desktop-cross-browser in the tested states. A broader conformance decision must also account for every applicable target in the declared scope, complete processes, accessibility-supported use and the other WCAG conformance requirements.",
    "why_it_matters": "A trapped user may be unable to reach later content, return to earlier content or complete the task. The procedure is necessary because detect components that trap keyboard focus or fail to tell users how to leave with the keyboard and the result can otherwise conceal a material barrier for the affected people named here."
  },
  "requirement_mappings": [
    {
      "source_id": "W3C-WCAG22",
      "requirement_id": "2.1.2",
      "requirement_level": "A",
      "requirement_type": "conformance",
      "coverage_type": "full",
      "canonical_source": "https://www.w3.org/TR/WCAG22/",
      "source_status": "W3C Recommendation",
      "source_version_or_publication_date": "WCAG 2.2; 12 December 2024 Recommendation",
      "date_verified": "2026-08-27",
      "reviewer_notes": "Primary conformance mapping for the precise focus-entry and focus-exit condition in WCAG 2.1.2.",
      "limitations": "This atomic check does not establish that every function is keyboard operable under WCAG 2.1.1 or that focus order is meaningful under WCAG 2.4.3.",
      "dependent_fields": [
        "applicability_model",
        "normative_exceptions",
        "steps",
        "decision_logic"
      ]
    },
    {
      "source_id": "W3C-ARIA-APG",
      "requirement_id": "W3C-ARIA-APG",
      "requirement_level": "informative",
      "requirement_type": "advisory",
      "coverage_type": "supporting",
      "canonical_source": "https://www.w3.org/WAI/ARIA/apg/",
      "source_status": "living_guidance",
      "source_version_or_publication_date": "Current ARIA Authoring Practices Guide",
      "date_verified": "2026-08-27",
      "reviewer_notes": "Supporting source. Procedure-level content review remains recorded separately.",
      "limitations": "This source does not override WCAG or create an additional WCAG conformance requirement.",
      "dependent_fields": [
        "prerequisites",
        "environment",
        "steps"
      ]
    },
    {
      "source_id": "MICROSOFT-EDGE-A11Y",
      "requirement_id": "MICROSOFT-EDGE-A11Y",
      "requirement_level": "informative",
      "requirement_type": "advisory",
      "coverage_type": "supporting",
      "canonical_source": "https://learn.microsoft.com/en-us/microsoft-edge/devtools/accessibility/reference",
      "source_status": "vendor_guidance",
      "source_version_or_publication_date": "Current first-party publication; exact version pending source review",
      "date_verified": "2026-08-27",
      "reviewer_notes": "Supporting source. Procedure-level content review remains recorded separately.",
      "limitations": "This source does not override WCAG or create an additional WCAG conformance requirement.",
      "dependent_fields": [
        "prerequisites",
        "environment",
        "steps"
      ]
    },
    {
      "source_id": "W3C-WCAG22-TECHNIQUES",
      "requirement_id": "W3C-WCAG22-TECHNIQUES",
      "requirement_level": "informative",
      "requirement_type": "advisory",
      "coverage_type": "supporting",
      "canonical_source": "https://www.w3.org/WAI/WCAG22/Techniques/",
      "source_status": "living_guidance",
      "source_version_or_publication_date": "Techniques for WCAG 2.2",
      "date_verified": "2026-08-27",
      "reviewer_notes": "Supporting source. Procedure-level content review remains recorded separately.",
      "limitations": "This source does not override WCAG or create an additional WCAG conformance requirement.",
      "dependent_fields": [
        "prerequisites",
        "environment",
        "steps"
      ]
    }
  ],
  "applicability_model": {
    "test_subject": "Every component in the selected scope that can receive keyboard focus internally.",
    "test_targets": [
      "Each component boundary entered by keyboard, including dialogs, embedded content, editors, menus, composite widgets and media players."
    ],
    "objective_questions": [
      "Can keyboard focus enter the component?",
      "Can focus move away using only a keyboard interface?",
      "If leaving requires more than standard unmodified arrow, Tab or other standard exit methods, is the method advised before or when focus enters?"
    ],
    "subjective_judgements": [
      "Determine which exit keys are standard for the component and platform; use the component's documented interaction contract and record any ambiguity."
    ],
    "inapplicability_conditions": [
      "No component in the selected subject accepts internal keyboard focus."
    ],
    "scope_exclusions": [
      "Focus containment inside an open modal dialog is not automatically a trap if the dialog provides a keyboard-operable close or completion path."
    ],
    "required_states_and_variations": [
      "Forward and reverse entry.",
      "Default, open, editing, full-screen, validation, interruption and recovery modes that can change focus containment."
    ],
    "complete_process_dependencies": "Exercise each selected component within its critical process, including cancellation and recovery paths.",
    "conforming_alternate_version_considerations": "A conforming alternate version can affect a WCAG report only when all WCAG conformance conditions are verified separately. It does not erase a platform or usability observation."
  },
  "normative_exceptions": [
    {
      "name": "Non-standard exit method is advised",
      "decision_condition": "Focus can be moved away using the keyboard, but doing so requires more than unmodified arrow or Tab keys or another standard exit method; the user is advised of the method before or when the component receives focus.",
      "evidence_needed": "Exact exit keys, successful exit sequence, and the programmatically and visibly available instruction with its timing.",
      "common_misinterpretation": "A hidden help page, undocumented Escape key or pointer-only close control does not satisfy the condition.",
      "official_source": "https://www.w3.org/WAI/WCAG22/Understanding/no-keyboard-trap.html",
      "scope_of_exception": "Only the component and mode requiring the non-standard exit method."
    }
  ],
  "normative_exceptions_absent_reason": "",
  "environment": {
    "required_tester_expertise": "General QA tester",
    "required_platforms": [
      "web-desktop-cross-browser"
    ],
    "minimum_environment_fields": [
      "operating_system",
      "operating_system_version",
      "browser",
      "browser_version",
      "viewport_css_pixels",
      "input_method"
    ],
    "product_and_content_version_required": true,
    "viewport_and_orientation_required": true,
    "input_mode_required": true,
    "relevant_settings": [
      "Keyboard layout",
      "Browser caret-browsing setting",
      "Operating-system sticky/filter key settings",
      "Input method"
    ],
    "known_platform_limitations": [
      "This keyboard journey does not establish compatibility with every switch device or speech-input system.",
      "Check relevant browser, tool or assistive-technology release notes before assigning unexpected behaviour to the product.",
      "If responsibility is unclear, record the reproducible behaviour and use cannot tell until it is resolved."
    ],
    "clean_state_requirements": [
      "Complete a known-good calibration in the same environment before product testing.",
      "Start from a recorded clean or known state and preserve any prior preferences, extensions, cache or profile settings that can affect output."
    ],
    "test_data_and_privacy_constraints": [
      "Use authorised synthetic or controlled data.",
      "Do not record credentials, secrets or unnecessary personal data."
    ],
    "coverage_boundary": "This keyboard journey does not establish compatibility with every switch device or speech-input system."
  },
  "decision_logic": {
    "target_passed": "Keyboard focus can be moved away from the component using only a keyboard interface; when a non-standard exit method is required, the user is advised of that method before or when focus enters.",
    "target_failed": "Keyboard focus enters the component but cannot leave using a keyboard interface, or a non-standard exit method works but is not advised at the required time.",
    "target_inapplicable": "No selected component accepts internal keyboard focus.",
    "target_cant_tell": "The component's standard interaction contract or actual focus location cannot be determined after reasonable investigation.",
    "target_untested": "The target is applicable, but a required state, environment, action or evidence item was not completed.",
    "aggregation": "Preserve one result per component, entry direction and material mode. Any failure prevents a passed aggregate; cantTell and untested remain unresolved.",
    "wcag_requirement_decision": "This atomic check can fully address its target condition, but a WCAG 2.1.2 decision still depends on complete scope coverage and WCAG conformance requirements.",
    "conforming_alternate_version_effect": "Apply a conforming alternate version only after its WCAG definition and every conformance condition have been verified and recorded; otherwise it does not change the decision.",
    "passed_automation_follow_up": "Automation may identify focusable elements but cannot prove that a user can leave every component mode or that non-standard instructions are timely.",
    "platform_responsibility": "When responsibility is unclear, preserve the reproducible behaviour and environment evidence and use cantTell until a qualified reviewer resolves it.",
    "claim_readiness": "A complete result may become ready_for_review. Schema validity, a passed target or a tool result cannot make it ready_for_scoped_claim without the independent evidence and governance gates."
  },
  "evidence_specification": [
    {
      "evidence_id": "EV1",
      "method": "component_inventory",
      "record": "Component, mode, entry directions and expected exit method.",
      "review_purpose": "Review the selected component coverage.",
      "privacy_and_security": "Use a redacted extract or evidence reference. Do not include credentials, secrets or unnecessary personal data.",
      "required_for_formal_result": true
    },
    {
      "evidence_id": "EV2",
      "method": "focus_sequence",
      "record": "Exact keystrokes, focus sequence, exit target and pointer-free result.",
      "review_purpose": "Reproduce the keyboard interaction.",
      "privacy_and_security": "Use a redacted extract or evidence reference. Do not include credentials, secrets or unnecessary personal data.",
      "required_for_formal_result": true
    },
    {
      "evidence_id": "EV3",
      "method": "instruction_evidence",
      "record": "Non-standard exit instruction, timing and programmatic exposure where used.",
      "review_purpose": "Review the conditional normative branch.",
      "privacy_and_security": "Use a redacted extract or evidence reference. Do not include credentials, secrets or unnecessary personal data.",
      "required_for_formal_result": true
    },
    {
      "evidence_id": "EV4",
      "method": "execution_state",
      "record": "Any operational block, affected scope, alternative environment and remaining requirement.",
      "review_purpose": "Distinguish blocked execution from a failed rule outcome.",
      "privacy_and_security": "Use a redacted extract or evidence reference. Do not include credentials, secrets or unnecessary personal data.",
      "required_for_formal_result": true
    }
  ],
  "calibration_examples": [
    {
      "example_id": "A11Y-KBD-003-EX-PASSED",
      "outcome": "passed",
      "scenario": "Focus enters a rich editor; a programmatically exposed instruction says “Press Control+M to leave editor”, and that command moves focus to the following control.",
      "explanation": "The non-standard advised-exit condition is met.",
      "fixture_id": "keyboard-trap-advised-pass",
      "fixture_version": "1.0.0",
      "machine_testable": true
    },
    {
      "example_id": "A11Y-KBD-003-EX-FAILED",
      "outcome": "failed",
      "scenario": "Tab and Shift+Tab cycle inside an embedded player, Escape has no effect, and no keyboard exit is available.",
      "explanation": "Focus entered and cannot leave by keyboard.",
      "fixture_id": "keyboard-trap-fail",
      "fixture_version": "1.0.0",
      "machine_testable": true
    },
    {
      "example_id": "A11Y-KBD-003-EX-INAPPLICABLE",
      "outcome": "inapplicable",
      "scenario": "The selected static view has no component that accepts internal keyboard focus.",
      "explanation": "No component target matches applicability.",
      "fixture_id": "",
      "fixture_version": "",
      "machine_testable": false
    },
    {
      "example_id": "A11Y-KBD-003-EX-CANTTELL",
      "outcome": "cantTell",
      "scenario": "A remote desktop layer obscures the actual focus location and platform key interception cannot be isolated.",
      "explanation": "The focus result cannot be determined defensibly.",
      "fixture_id": "",
      "fixture_version": "",
      "machine_testable": false
    },
    {
      "example_id": "A11Y-KBD-003-EX-UNTESTED",
      "outcome": "untested",
      "scenario": "Default dialog mode was tested, but its selected full-screen editor mode was not entered.",
      "explanation": "A required component mode remains untested.",
      "fixture_id": "",
      "fixture_version": "",
      "machine_testable": false
    }
  ],
  "review_record": {
    "author": "",
    "method_reviewer": "",
    "independent_standards_reviewer": "",
    "accessibility_ui_reviewer": "",
    "author_date": "",
    "method_review_date": "",
    "standards_review_date": "",
    "ui_review_date": "",
    "source_versions_reviewed": [],
    "exceptions_reviewed": false,
    "known_limitations": [
      "This is a source-checked reference implementation subject to independent method and standards agent verification; formal approval remains separate."
    ],
    "open_issues": [
      "Independent method and standards review and keyboard calibration execution remain required before status promotion."
    ],
    "decision": "pending",
    "next_review_date": "",
    "status_transition_reason": "",
    "release_gate_id": "",
    "release_gate_completed_at": "",
    "approval_authority": "",
    "approval_date": ""
  },
  "privacy_and_security": {
    "browser_storage": "Worksheet data is stored only in this browser's local storage until the user exports or clears it.",
    "network_transmission": "The static library does not upload worksheet data.",
    "data_minimisation": "Record only evidence necessary to reproduce and review the decision.",
    "redaction": "Remove credentials, secrets and unnecessary personal or participant data before export or sharing.",
    "retention_and_deletion": "Apply the engagement retention schedule and clear local browser data when it is no longer required."
  },
  "version_history": [
    {
      "version": "2026.08.27-rc.9",
      "change": "Reworked for plain language, case-focused steps, scoped evidence and transparent draft review status."
    },
    {
      "version": "2026.08.27-rc.9",
      "change": "Migrated to professional catalogue schema v3 with separated outcomes, structured authority, applicability, evidence, decision and review records."
    },
    {
      "version": "2026.08.27-rc.9",
      "change": "Specialist procedure mapped to its task family and current first-party platform guidance and checked for internal consistency; competent review and real execution remain separate."
    },
    {
      "version": "2026.08.27-rc.9",
      "change": "Replaced migrated boilerplate with a case-specific reference implementation and completed independent agent content verification."
    },
    {
      "version": "2026.08.27-rc.9",
      "change": "Rewritten as an atomic professional-delivery flagship with component effort guidance and a complete representative worked example."
    },
    {
      "version": "2026.08.27-rc.9",
      "change": "Procedure guidance and presentation simplified without changing draft governance status."
    }
  ],
  "migration": {
    "from_schema": "accessibility-test-catalog.v2",
    "from_procedure_version": "2026.08.04.1",
    "migrated_at": "2026-08-27",
    "content_review_state": "flagship_operational_rewrite_agent_verified",
    "stable_identifier_preserved": true,
    "legacy_url_preserved": true,
    "delivery_model": "professional_delivery_v2",
    "agent_content_validation": {
      "status": "complete",
      "method": "case_specific_semantic_and_operational_checks_v1",
      "checked_fields": [
        "target",
        "state",
        "tool",
        "action",
        "expected_observation",
        "failure_observation",
        "evidence",
        "outcome_rules",
        "claim_boundary",
        "compact_examples"
      ],
      "human_approval_effect": "none"
    }
  },
  "test_type": "conformance",
  "related_procedures": [
    "A11Y-WCAG-022"
  ],
  "platform_validation": {
    "required": false,
    "evidence_status": "not_executed",
    "real_device_or_at_claimed": false,
    "required_environment_ids": [
      "web-desktop-cross-browser"
    ],
    "calibration_required": true,
    "evidence_refs": [],
    "limitations": "This keyboard journey does not establish compatibility with every switch device or speech-input system."
  },
  "library_layer": "atomic",
  "effort_guidance": {
    "unit": "minutes",
    "setup": {
      "typical": 12,
      "includes": "Confirm scope and target, prepare safe data, establish the required state and record the tool or environment version."
    },
    "per_target_execution": {
      "typical": 12,
      "includes": "Perform the procedure once for one target in its selected states; this excludes remediation and retesting."
    },
    "evidence_capture": {
      "typical": 8,
      "includes": "Capture, name and cross-reference the minimum reproducible evidence while removing unnecessary personal or secret data."
    },
    "technical_review": {
      "typical": 8,
      "includes": "Check applicability, observations, outcome logic, evidence sufficiency and report wording before issue publication."
    },
    "typical_total_range": {
      "minimum": 40,
      "maximum": 58
    },
    "assumptions": "one short journey with up to ten focusable controls; complex widgets and dialogs add separate scenario runs",
    "variation": "Add a new per-target execution and evidence allowance for each additional target class or state that could produce a different result. Add setup time for each distinct environment.",
    "excludes": "Client coordination, inaccessible-environment recovery, recruitment, legal review, remediation implementation and waiting time unless the procedure states otherwise."
  },
  "worked_examples": [
    {
      "example_id": "A11Y-KBD-003-WORKED-001",
      "example_kind": "representative_synthetic_example",
      "context": "Synthetic Civic Benefits Portal eligibility-help modal on the claim form.",
      "inspected": "Forward and reverse entry/exit in the open modal with only Tab, Shift+Tab and Escape.",
      "observed_output": "After the last link, Tab cycled to the close button as intended. Escape closed the modal and restored focus. Shift+Tab from the first control also cycled within the modal until Escape was used; the on-screen instruction named Escape.",
      "evidence_captured": [
        "EVD-REF-004 focus sequence log",
        "EVD-REF-005 video with focus indicator",
        "EVD-REF-006 instruction/accessibility-tree extract"
      ],
      "tester_reasoning": "Focus containment is appropriate while the modal is open because an available, disclosed keyboard command closes it and restores focus. The internal loop alone is not a trap.",
      "decision": "passed",
      "completed_finding": {
        "finding_id": "OBS-REF-001",
        "title": "Modal keyboard containment works as documented",
        "severity": "none",
        "user_impact": "Keyboard users can close the modal and return to the triggering control.",
        "evidence_refs": [
          "EVD-REF-004",
          "EVD-REF-005",
          "EVD-REF-006"
        ]
      },
      "remediation_advice": "Retain the visible and programmatically available Escape instruction and the focus-restoration regression test.",
      "reviewer_feedback": "Reviewer removed a false failure based solely on focus being contained inside an open modal and required evidence that Escape was disclosed before use.",
      "final_client_report_wording": "No keyboard trap was found in the sampled eligibility-help modal. Escape was disclosed, closed the modal and returned focus to the Help trigger in both forward and reverse navigation checks.",
      "retest_outcome": "RT-REF-002: no code change required; repeat on build CBP-2026.08.2 produced the same passing focus sequence.",
      "claim_boundary": "This is a representative, synthetic worked example for training and calibration. It is not evidence from a client product, participant or real assistive-technology execution."
    }
  ]
}
