fix(a11y): preserve bounded report focus indicators - #928
Conversation
Adds `outline: none;` on `:focus` to interactive `<summary>` and scrollable `<pre>` elements in HTML reports to remove default browser outlines on mouse clicks, while retaining accessibility outlines via `:focus-visible` for keyboard users.
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
|
Important Review skippedAuto incremental reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (3)
Included review availability: Your plan includes up to 1 review per rolling hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe change suppresses default focus outlines for selected HTML report elements. Existing ChangesFocus outline styling
Estimated code review effort: 1 (Trivial) | ~2 minutes Merge Risk: ⚪ Minimal · up to This localized styling change removes unintended mouse-click outlines while preserving keyboard focus indication, and no actionable merge-blocking risk remains after normal checks and review. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Adds `outline: none;` on `:focus` to interactive `<summary>` and scrollable `<pre>` elements in HTML reports to remove default browser outlines on mouse clicks, while retaining accessibility outlines via `:focus-visible` for keyboard users.
|
Lifecycle correction after fresh overlap/evidence review: this branch is not Ready yet. Exact head |
I have reverted the |
Adds `outline: none;` on `:focus` to interactive `<summary>` elements in HTML reports to remove default browser outlines on mouse clicks, while retaining accessibility outlines via `:focus-visible` for keyboard users.
|
Treat this as the current-head design-review repair for The current source-only regression locks a broad Write the regression first and prove it fails on the current head. The final regression must require the three Add a bounded doctoring record with APA 7 references and claim limits for:
Record that pointer-only ring suppression is not whole-product WCAG conformance and that pointer users may still benefit from focus indication. Add an Unreleased CHANGELOG entry. Validate the focused regression, complete supported test suite, production statement/branch coverage 100%, public docstrings 100%, |
Pull request was converted to draft
Understood. I have rewritten the pointer-only focus suppression rules using the fail-safe |
Replaces bare `:focus { outline: none; }` rules with `:focus:not(:focus-visible)` for interactive `<summary>`, `.table-wrap`, and `<pre>` elements in HTML reports. This prevents jarring browser outlines on mouse clicks while safely falling back to user-agent defaults if `:focus-visible` is unsupported.
|
Exact-current-head accessibility review request for CI, Security Scan, and Semgrep are terminal-success; the generated journal delta is absent. Review the bounded @opencode-agent review Read-only review. Do not update the branch, change report numerics, weaken coverage, synthesize author approval, or merge. |
🧩 Analysis chain🏁 Script executed: #!/bin/bash
set -euo pipefail
base="fb67ced09d8ee00542c05d56374537a9a7239751"
head="a6782a153938488ca64783882e81063cd33b7462"
echo "== Repository guidance =="
fd -HI -t f -a '(^|/)(AGENTS|CONTRIBUTING|CODEOWNERS|README|CHANGELOG|pyproject)\.(md|txt)$|^pyproject\.toml$|\.coderabbit\.ya?ml$' . \
| sed -n '1,160p'
echo
echo "== Exact diff summary =="
git diff --stat "$base" "$head"
git diff --name-status "$base" "$head"
echo
echo "== Exact diff =="
git diff --find-renames --find-copies --unified=80 "$base" "$head" -- \
'python/fast_mlsirm/report.py' \
'python/fast_mlsirm/scoring/essay/report_html.py' \
'python/**/test*.py' \
'python/**/*test*.py' \
'CHANGELOG*' \
'.Jules/palette.md' \
'docs/**' \
'*.md'
echo
echo "== Affected Python structure =="
ast-grep outline python/fast_mlsirm/report.py --items all 2>/dev/null || true
ast-grep outline python/fast_mlsirm/scoring/essay/report_html.py --items all 2>/dev/null || true
echo
echo "== Focus selector and focused-test references =="
rg -n -C 5 --glob '*.py' --glob '*.md' --glob 'CHANGELOG*' \
'focus-visible|focus:not|outline:\s*none|skip-link|table-wrap|exact-values|export' \
python .Jules CHANGELOG* 2>/dev/null || true
echo
echo "== Commit identity =="
git show -s --format='HEAD=%H%nParents=%P%nSubject=%s' "$head"Length of output: 84519 🏁 Script executed: #!/bin/bash
set -euo pipefail
base="fb67ced09d8ee00542c05d56374537a9a7239751"
head="a6782a153938488ca64783882e81063cd33b7462"
echo "== Repository instructions =="
cat AGENTS.md
printf '\n== CodeRabbit configuration ==\n'
cat .coderabbit.yaml
echo
echo "== Test file structures =="
ast-grep outline tests/test_report.py --items all
ast-grep outline tests/test_report_focus_contrast.py --items all
echo
echo "== Exact changed test content =="
git diff --unified=120 "$base" "$head" -- \
tests/test_report.py \
tests/test_report_focus_contrast.py
echo
echo "== Complete focused regression =="
cat -n tests/test_report_focus_contrast.py
printf '\n== Related report tests ==\n'
rg -n -C 12 --glob 'test_report.py' \
'focus|skip-link|table-wrap|exact-values|export-block|_css|render_diagnostics_report' \
tests
echo
echo "== Renderer and CSS slices =="
sed -n '60,115p;225,270p;350,410p;510,610p;750,910p' \
python/fast_mlsirm/report.py
echo
echo "== CSS bare focus outline removals in report stylesheet =="
python - <<'PY'
from pathlib import Path
text = Path("python/fast_mlsirm/report.py").read_text(encoding="utf-8")
start = text.index("def _css()")
print(text[start:].count("outline: none"))
PY
rg -n -U -P '(?s)[^{]+\:focus(?![-\w(])[^{]*\{[^}]*outline:\s*none' \
python/fast_mlsirm/report.py || trueLength of output: 51636 🏁 Script executed: #!/bin/bash
set -euo pipefail
base="fb67ced09d8ee00542c05d56374537a9a7239751"
head="a6782a153938488ca64783882e81063cd33b7462"
echo "== Base ancestry =="
git merge-base --is-ancestor "$base" "$head"
echo "base-is-ancestor=yes"
printf 'merge-base='
git merge-base "$base" "$head"
echo
echo "== Changed paths at exact comparison =="
git diff --name-only "$base" "$head" | sort
echo
echo "== Diff whitespace validation =="
git diff --check "$base" "$head"
echo
echo "== Target selector inventory =="
git show "$head:python/fast_mlsirm/report.py" \
| sed -n '/def _css()/,$p' \
| grep -nE '(^|[ ,])(\.table-wrap|\.exact-values > summary|\.export-block > summary|\.export-block pre|\.skip-link)(:focus|:focus-visible|:focus:not)|outline: (none|3px solid)'
echo
echo "== Changed-file line counts =="
git diff --numstat "$base" "$head"
echo
echo "== Generated journal change check =="
if git diff --name-only "$base" "$head" | grep -E '(^|/)\.Jules/|(^|/)palette\.md$'; then
echo "unexpected-journal-delta"
exit 1
fi
echo "no-generated-journal-delta"Length of output: 2502
The exact head descends from The three target surfaces use The doctoring states the compatibility boundary and does not claim whole-product WCAG conformance. I did not execute tests in this read-only inspection environment. The reported CI, Security Scan, and Semgrep status provides the execution evidence.
|
Replaces bare `:focus { outline: none; }` rules with `:focus:not(:focus-visible)` for interactive `<summary>`, `.table-wrap`, and `<pre>` elements in HTML reports. This prevents jarring browser outlines on mouse clicks while safely falling back to user-agent defaults if `:focus-visible` is unsupported.
|
Exact-head semantic review requested after removing generated journal drift and binding the compatibility rationale to current W3C primary sources in the doctoring record. @opencode-agent |
Replaces bare `:focus { outline: none; }` rules with `:focus:not(:focus-visible)` for interactive `<summary>`, `.table-wrap`, and `<pre>` elements in HTML reports. This prevents jarring browser outlines on mouse clicks while safely falling back to user-agent defaults if `:focus-visible` is unsupported.
# Conflicts: # CHANGELOG.md
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
There was a problem hiding this comment.
Pull request overview
OpenCode cannot approve yet because required coverage evidence did not pass.
Review outcome
1. HIGH .github/workflows/opencode-review.yml:1 - Coverage evidence did not prove required test/docstring evidence
-
Problem: The required coverage-evidence job result was
failure, so OpenCode cannot establish approval sufficiency for this head. -
Root cause: Automated approval is only valid when the same-head coverage-evidence job proves supported repository test suites passed and configured docstring gates passed or were advisory, or reports not applicable because no supported source files or package manifests exist. Missing, failed, skipped, unavailable, or unsupported-tooling test evidence is a blocker.
-
Fix: Install or configure the repository test/docstring evidence tooling when source files or package manifests exist, rerun the current-head coverage-evidence job, and approve only after it reports
successwith required evidence or explicit no-source not-applicable evidence. -
Regression test: Keep the approval branch checking
needs.coverage-evidence.result == successbefore posting APPROVE, and publish REQUEST_CHANGES when coverage-evidence blocker states such as cancelled, skipped, failed, unsupported-tooling, or below-100 evidence are present. -
Result: REQUEST_CHANGES
-
Reason: coverage-evidence result was
failure, so required test/docstring evidence was not proven for current head6afe5a8f27b026af646e5fb46bd52e6185949423. -
Head SHA:
6afe5a8f27b026af646e5fb46bd52e6185949423 -
Workflow run: 32035463051
-
Workflow attempt: 1
Coverage evidence
Coverage evidence job did not run or did not publish coverage evidence.
Changed-File Evidence Map
flowchart LR
PR["PR changed files"] --> Evidence["OpenCode bounded evidence"]
Evidence --> S1["Changed file (3 files)"]
S1 --> I1["repository behavior"]
I1 --> R1["Review risk: Changed file (3 files)"]
R1 --> V1["required checks"]
Evidence --> S2["Docs: release-0.8.0-cut.md"]
S2 --> I2["operator or user guidance"]
I2 --> R2["Review risk: Docs: release-0.8.0-cut.md"]
R2 --> V2["docs review"]
Evidence --> S3["Test (2 files)"]
S3 --> I3["regression suite"]
I3 --> R3["Review risk: Test (2 files)"]
R3 --> V3["targeted test run"]
OpenCode Review Overview
Pull request overviewOpenCode cannot approve yet because required coverage evidence did not pass. Review outcome1. HIGH .github/workflows/opencode-review.yml:1 - Coverage evidence did not prove required test/docstring evidence
Coverage evidenceCoverage evidence job did not run or did not publish coverage evidence. Changed-File Evidence Mapflowchart LR
PR["PR changed files"] --> Evidence["OpenCode bounded evidence"]
Evidence --> S1["Changed file (3 files)"]
S1 --> I1["repository behavior"]
I1 --> R1["Review risk: Changed file (3 files)"]
R1 --> V1["required checks"]
Evidence --> S2["Docs: release-0.8.0-cut.md"]
S2 --> I2["operator or user guidance"]
I2 --> R2["Review risk: Docs: release-0.8.0-cut.md"]
R2 --> V2["docs review"]
Evidence --> S3["Test (2 files)"]
S3 --> I3["regression suite"]
I3 --> R3["Review risk: Test (2 files)"]
R3 --> V3["targeted test run"]
|
There was a problem hiding this comment.
Pull request overview
OpenCode cannot approve yet because required coverage evidence did not pass.
Review outcome
1. HIGH .github/workflows/opencode-review.yml:1 - Coverage evidence did not prove required test/docstring evidence
-
Problem: The required coverage-evidence job result was
failure, so OpenCode cannot establish approval sufficiency for this head. -
Root cause: Automated approval is only valid when the same-head coverage-evidence job proves supported repository test suites passed and configured docstring gates passed or were advisory, or reports not applicable because no supported source files or package manifests exist. Missing, failed, skipped, unavailable, or unsupported-tooling test evidence is a blocker.
-
Fix: Install or configure the repository test/docstring evidence tooling when source files or package manifests exist, rerun the current-head coverage-evidence job, and approve only after it reports
successwith required evidence or explicit no-source not-applicable evidence. -
Regression test: Keep the approval branch checking
needs.coverage-evidence.result == successbefore posting APPROVE, and publish REQUEST_CHANGES when coverage-evidence blocker states such as cancelled, skipped, failed, unsupported-tooling, or below-100 evidence are present. -
Result: REQUEST_CHANGES
-
Reason: coverage-evidence result was
failure, so required test/docstring evidence was not proven for current head6afe5a8f27b026af646e5fb46bd52e6185949423. -
Head SHA:
6afe5a8f27b026af646e5fb46bd52e6185949423 -
Workflow run: 32035463051
-
Workflow attempt: 2
Coverage evidence
Coverage evidence job did not run or did not publish coverage evidence.
Changed-File Evidence Map
flowchart LR
PR["PR changed files"] --> Evidence["OpenCode bounded evidence"]
Evidence --> S1["Changed file (3 files)"]
S1 --> I1["repository behavior"]
I1 --> R1["Review risk: Changed file (3 files)"]
R1 --> V1["required checks"]
Evidence --> S2["Docs: release-0.8.0-cut.md"]
S2 --> I2["operator or user guidance"]
I2 --> R2["Review risk: Docs: release-0.8.0-cut.md"]
R2 --> V2["docs review"]
Evidence --> S3["Test (2 files)"]
S3 --> I3["regression suite"]
I3 --> R3["Review risk: Test (2 files)"]
R3 --> V3["targeted test run"]
There was a problem hiding this comment.
Pull request overview
OpenCode cannot approve yet because required coverage evidence did not pass.
Review outcome
1. HIGH .github/workflows/opencode-review.yml:1 - Coverage evidence did not prove required test/docstring evidence
-
Problem: The required coverage-evidence job result was
failure, so OpenCode cannot establish approval sufficiency for this head. -
Root cause: Automated approval is only valid when the same-head coverage-evidence job proves supported repository test suites passed and configured docstring gates passed or were advisory, or reports not applicable because no supported source files or package manifests exist. Missing, failed, skipped, unavailable, or unsupported-tooling test evidence is a blocker.
-
Fix: Install or configure the repository test/docstring evidence tooling when source files or package manifests exist, rerun the current-head coverage-evidence job, and approve only after it reports
successwith required evidence or explicit no-source not-applicable evidence. -
Regression test: Keep the approval branch checking
needs.coverage-evidence.result == successbefore posting APPROVE, and publish REQUEST_CHANGES when coverage-evidence blocker states such as cancelled, skipped, failed, unsupported-tooling, or below-100 evidence are present. -
Result: REQUEST_CHANGES
-
Reason: coverage-evidence result was
failure, so required test/docstring evidence was not proven for current head6afe5a8f27b026af646e5fb46bd52e6185949423. -
Head SHA:
6afe5a8f27b026af646e5fb46bd52e6185949423 -
Workflow run: 32035463051
-
Workflow attempt: 3
Coverage evidence
Coverage evidence job did not run or did not publish coverage evidence.
Changed-File Evidence Map
flowchart LR
PR["PR changed files"] --> Evidence["OpenCode bounded evidence"]
Evidence --> S1["Changed file (3 files)"]
S1 --> I1["repository behavior"]
I1 --> R1["Review risk: Changed file (3 files)"]
R1 --> V1["required checks"]
Evidence --> S2["Docs: release-0.8.0-cut.md"]
S2 --> I2["operator or user guidance"]
I2 --> R2["Review risk: Docs: release-0.8.0-cut.md"]
R2 --> V2["docs review"]
Evidence --> S3["Test (2 files)"]
S3 --> I3["regression suite"]
I3 --> R3["Review risk: Test (2 files)"]
R3 --> V3["targeted test run"]
|
Closing this merge vehicle without merging. Fresh live inspection shows the current head |
Buyer-visible gap
Standalone diagnostics reports provide keyboard-focusable scroll regions and disclosure summaries. Pointer activation could show both the browser's default outline and the report's interaction treatment, but removing every
:focusoutline would also remove the fallback indicator in user agents that do not understand:focus-visible.Current bounded change
:focus:not(:focus-visible)on the named table wrapper, report summaries, and export block;:focus { outline: none; }rules;:focus-visibleindicators on every affected component;:focusreveal behavior;.Jules/palette.mdexactly to protectedmainso generated journal metadata is absent from the effective diff;Compatibility boundary
Selectors Level 4 requires unsupported pseudo-classes to invalidate the selector. A browser without usable
:focus-visiblesupport therefore ignores the entire bounded:focus:not(:focus-visible)rule instead of applying an unconditional outline removal, leaving its native fallback treatment available. Pointer-only suppression remains narrow presentation polish; pointer users may also benefit from a visible indicator.Exact candidate
main@fb67ced09d8ee00542c05d56374537a9a723975169f5fbc33c483ef27fcbb6fcdcbecb0201d24a1a.Jules/palette.mddelta: absentStandards and claim boundary
The doctoring record traces the decision to WCAG 2.2, WAI Technique C45, the WCAG Focus Visible understanding document, and Selectors Level 4 in APA 7 form. This bounded source-level change does not claim browser, forced-colors, assistive-technology, pointer-modality, zoom, print, Focus Appearance AAA, or whole-product WCAG conformance.
Merge boundary
Require a qualifying independent current-head approval, zero valid unresolved findings, every live organization/repository check, and ordinary protected integration without bypass. Queued, predecessor-head, automated-only, model-only, status-only, or author-only evidence is non-authorizing.