You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Let me know if I can help you replicate the issue!
I've implemented a fix that only renders the cropper if the tab is active but this feels like logic that belongs in the library if it is really needed:
// React Advanced Cropper crashes if loaded in a hidden tabconst[isTabActive,setIsTabActive]=useState(!document.hidden);useEffect(()=>{functionupdateVisibility(){setIsTabActive(!document.hidden);}document.addEventListener('visibilitychange',updateVisibility);return()=>{document.removeEventListener('visibilitychange',updateVisibility);};},[]);
Hey! This is such a sweet library that fits our use case really well :D
However, we are noticing an annoying crash when we render the cropper in a background/hidden tab.
The flow is as follows:
We are running the following setup:
Let me know if I can help you replicate the issue!
I've implemented a fix that only renders the cropper if the tab is active but this feels like logic that belongs in the library if it is really needed:
cc @bryanlohjy
The text was updated successfully, but these errors were encountered: