-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: Enhance Overlay State Management and Prevent Duplicate Entries (#53
) * fix: Ensure unique overlay ID and maintain overlay state on close/reopen - Added check to prevent adding an overlay with a duplicate ID if it already exists and is open. - Modified `overLayOrderList` to filter out existing overlay ID before adding it to ensure proper state management when closing and reopening overlays. - Improved error handling to throw an error if the same overlay ID is attempted to be added. Co-authored-by: jgjgill <[email protected]> Co-authored-by: Jeongjin Oh <[email protected]> * fix: Enhance overlay state management and prevent duplicate entries - Added `current` state to track the current overlay in `OverlayProvider` and `ContentOverlayController`. - Implemented logic to maintain overlay state correctly when an overlay is closed and reopened without unmounting. * Create tall-flowers-trade.md * Update packages/src/context/reducer.ts Co-authored-by: Jeongjin Oh <[email protected]> --------- Co-authored-by: jgjgill <[email protected]> Co-authored-by: Jeongjin Oh <[email protected]> Co-authored-by: Jeongjin Oh <[email protected]>
- Loading branch information
1 parent
7ca5087
commit 6f3c26a
Showing
3 changed files
with
35 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
--- | ||
"overlay-kit": patch | ||
--- | ||
|
||
fix: Enhance Overlay State Management and Prevent Duplicate Entries | ||
|
||
This change enhances the overlay state management to ensure overlays maintain the correct state when closed and reopened, and prevents duplicate overlay entries. | ||
It addresses issues with the overlay's `current` state not updating correctly in certain scenarios. | ||
|
||
**Related Issue:** Fixes # 46 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters