microsoft / fluentui

Fluent UI web represents a collection of utilities, React components, and web components for building web applications.
https://react.fluentui.dev
Other
18.52k stars 2.73k forks source link

[Bug]: HC mode > Focus indicator is not visible for pressed toggle button #26062

Closed kolaps33 closed 1 year ago

kolaps33 commented 1 year ago

Library

React Northstar / v0 (@fluentui/react-northstar)

System Info

System:
    OS: Windows 10 10.0.22621
    CPU: (12) x64 Intel(R) Xeon(R) E-2176M  CPU @ 2.70GHz
    Memory: 17.39 GB / 31.74 GB
  Browsers:
    Edge: Spartan (44.22621.963.0), Chromium (108.0.1462.54)
    Internet Explorer: 11.0.22621.1

Are you reporting Accessibility issue?

no

Reproduction

https://codesandbox.io/s/ovbmp8?file=/example.tsx

Bug Description

  1. Change Windows HC mode into "aquatic"
  2. Press toggle button(s) into pressed state
  3. Navigate to the toggle button which has "pressed" state https://react.fluentui.dev/?path=/docs/components-button-togglebutton--default#shape

Actual Behavior

image image

Expected Behavior

focused button should has visible focus indicator

Logs

No response

Requested priority

Normal

Products/sites affected

No response

Are you willing to submit a PR to fix?

no

Validations

smhigley commented 1 year ago

This is the same root cause as the bugs fixed in #26089, but the issue is still present even with that fix, because ToggleButton uses forced-color-adjust: none and relies on both outline-style and outline-color to correctly show the focus outline.