Summary: | AX: "(inverted-colors)" match sometimes fails on change | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | James Craig <jcraig> | ||||||
Component: | CSS | Assignee: | Dean Jackson <dino> | ||||||
Status: | NEW --- | ||||||||
Severity: | Normal | CC: | webkit-bug-importer | ||||||
Priority: | P2 | Keywords: | InRadar | ||||||
Version: | WebKit Nightly Build | ||||||||
Hardware: | All | ||||||||
OS: | All | ||||||||
Bug Depends on: | 163564 | ||||||||
Bug Blocks: | |||||||||
Attachments: |
|
Description
James Craig
2017-02-16 19:16:30 PST
Same test case from bug 163564: https://bugs.webkit.org/attachment.cgi?id=291870 Also reproducible in desktop contexts. The change event won't fire initially, but does when another queryable layout change happens (e.g. resizing the window). Created attachment 306608 [details]
test case
1. Load attached test case on Mac.
2. Toggle "Reduce Motion" setting in SysPrefs > Accessibility > Display.
3. Notice the on/off indicator does not change immediately.
4. Resize the window a bit.
5. Notice "prefers reduced motion" value is updated then.
Workaround identified. If you put an empty CSS @media block in, the JavaScript works as expected. @media (prefers-reduced-motion) { /* Empty block workaround */ } Including both test cases with and without the workaround. Created attachment 306669 [details]
test case with workaround
|