Comments (1)
You could argue of course that it's the responsibility of the parent shadow root to apply the polyfill, but that would not be an easy and straigthforward migration path for our consumers (not as easy as importing a polyfill); it's easily forgotten.
Alternatively, you could recursively apply applyFocusVisiblePolyfill
to all shadowRoots found from the document. I don't know what the performance implication would be, but you probably run again into the risk of handling the same root multiple times in case you encounter components already applying this?
Also, you would need to keep track of newly created shadowRoots, so that would probably be undoable (or just way too costly...)
from focus-visible.
Related Issues (20)
- Don't enable polyfill if browser supports ":focus-visible" HOT 5
- List a `module` export in package.json` HOT 3
- .focus-visible skips elements on Safari HOT 4
- How to add declaration when importing as module in Rollup + Typescript? HOT 3
- Conditional Application? HOT 1
- Focus visible... but for aria-activedescendant? HOT 1
- Managed Focus in Safari
- Keyboard escape hides focus on Button ContextMenu HOT 3
- Always applies focus-visible to inputs in React even when click HOT 3
- Add hint to documentation about ES6 import
- :focus-visible's "hidden focus" artifact can result in user UI confusion on Mac HOT 13
- Default to polyfill off in Web Native cases?
- Warning when building HOT 2
- Applying :focus-visible state after programmatically moving focus only on initial page landing
- `:focus-visible` should match when focus is programmatically moved to inside a dialog HOT 3
- Memory leaks when applyFocusVisiblePolyfill is applied then the element is removed HOT 3
- Remove source map for minified build in releases
- Readme/polyfill HOT 5
- [Bug] focusVisible status is not added correctly when user interacts with keyboard and mouse
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from focus-visible.