Aitema-gmbh commented on PR #39242:
URL: https://github.com/apache/superset/pull/39242#issuecomment-4440466261

   Thanks for the careful review — wanted to walk through the three points 
together since two of them have WCAG implications I did not want to silently 
accept or reject.
   
   **2. Restrict the `*` selector to interactive elements** — done in 
`b4a83fc1`. The `:focus-visible` rule is now wrapped in `:where(a, button, 
input, select, textarea, [tabindex], ARIA roles, AntD wrappers)`. Specificity 
stays at (0,0,1,0) and component-level styles can still override it.
   
   **1. Remove `!important`** — kept, with an in-file rationale. AntD ships 
per-component focus resets like `.ant-btn:focus { outline: 0 }` at the same 
(0,0,2,0) specificity as a `.ant-btn:focus-visible` rule here, and AntD's 
runtime-injected styles can land *after* this global block. Without 
`!important` the WCAG 2.4.7 indicator is silently reset to `outline: 0` on 
every AntD button, input, select, etc. — which would defeat the whole rule. 
Components that legitimately need a different focus treatment can use 
`!important` themselves, matching AntD's own pattern. I tested this both ways 
locally before keeping it.
   
   **3. Revert `controlOutline` → `colorPrimary` swap in `TimeFilterPlugin`** — 
also kept, with a WCAG 1.4.11 inline comment. The default 
`theme.controlOutline` token is a low-alpha tint derived from `colorPrimary` 
(in the active theme it lands around 2.5–3:1), which fails the WCAG 1.4.11 3:1 
non-text contrast requirement that this PR is also gating against. Using the 
full-saturation `colorPrimary` keeps the focus indicator above 3:1. Open to a 
different fix (e.g. raising the alpha of `controlOutline` itself in the theme) 
if you would prefer that direction, but a straight revert would regress 1.4.11.
   
   Rebased onto master in the same push. All bot threads on this PR are 
resolved.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to