`active` and `paused` props don't work
See original GitHub issueI have smoothly animating dialogs that fade in and fade out.
All the examples assume that the dialogs have no intro or outro animations.
I’ve forked the repository and converted the “demo-defaults” example into a test case example of what I need FocusTrap to be able to do: https://github.com/Dan503/focus-trap-react/blob/master/demo/js/demo-defaults.js#L36
There are active
and paused
props according to the index.d.ts file but when I try to use them, I get this error:
Uncaught Error: Your focus-trap must have at least one container with at least one tabbable node in it at all times
Basically this is what I’m asking for (in pseudo code terms):
if ( `active` prop equals `true` ) {
activate the focus-trap
}
else if ( `active` prop equals `false` ) {
deactivate the focus-trap
}
if ( `paused` prop equals `true` ) {
pause the focus-trap
}
else if ( `paused` prop equals `false` ) {
resume the focus-trap
}
Issue Analytics
- State:
- Created 3 years ago
- Reactions:2
- Comments:12 (12 by maintainers)
Top Results From Across the Web
How to pause using React Player without using controler prop
my playSvg is working properly but I would like to add when you click on the second time the play button svg appears...
Read more >React Spring - GitHub Pages
The pause prop literally freezes animations in time. When used in a declarative update, the declared animation is paused until the pause prop...
Read more >How to Play and Pause CSS Animations with CSS Custom ...
Hint: it involves CSS custom properties. The importance of pausing animations. Recently, while working on the CSS-powered slideshow you'll see ...
Read more >react-native-video - npm
All platforms now auto-play. Previously, on Android ExoPlayer if the paused prop was not set, the media would not automatically start playing.
Read more >How To Debug React Components Using React Developer ...
When you are on a page that does not have any React components, ... Now that you've tried out React Developer Tools on...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This was ultimately fixed with #394 that was published in v8.6.0.
Pull request created for focus-trap: https://github.com/focus-trap/focus-trap/pull/407