diff options
author | 2025-05-28 20:32:36 +0530 | |
---|---|---|
committer | 2025-05-28 20:32:36 +0530 | |
commit | 2fb1e6b1004480700c35c8dd7e42f999eb8bb7bc (patch) | |
tree | de862838ceb94f38e4f36a679f4ad259d50f0da0 /frontend/src/components/theme-provider.tsx | |
parent | 92ab3f26c4492e7786fc57f4bb47fd24e6d5ab40 (diff) | |
download | blcklst-2fb1e6b1004480700c35c8dd7e42f999eb8bb7bc.tar.gz blcklst-2fb1e6b1004480700c35c8dd7e42f999eb8bb7bc.tar.bz2 blcklst-2fb1e6b1004480700c35c8dd7e42f999eb8bb7bc.zip |
fix: Applied for React 19 Scroll Handling Error
- Added isMounted state to prevent hydration mismatches
- Server-side renders a simplified header without Sheet component
- Client-side renders full functionality after mounting
- Added global error handler to catch and suppress scroll-related errors
- Specifically targets "parameter 1 is not of type 'Node'" errors
- Prevents error propagation while maintaining functionality
- Added proper ref management with sheetRef
- Prevented auto-focus events that can trigger scroll issues
- Added graceful error handling for escape key and pointer events
- Enhanced event handling with try-catch blocks
- `onOpenAutoFocus` and `onCloseAutoFocus` prevented to avoid focus issues
- `onEscapeKeyDown` and `onPointerDownOutside` with error handling
- Cleanup function in useEffect to remove event listeners
- Updated `@radix-ui/react-dialog` to latest version
- Ensured `react-remove-scroll` is at latest version for React 19 compatibility
Diffstat (limited to 'frontend/src/components/theme-provider.tsx')
0 files changed, 0 insertions, 0 deletions