-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(chat-custom-width/window-resizing): Optimize responsive widt…
…h adjustment - Improve the responsive width adjustment logic: - The resize event listener is now added only when chat width settings differ from defaults. - Full-width behavior on resize applies only if chat width settings have been modified. - If the user resets the widths, the resize listener is removed. - The code automatically detects changes to chat width settings by comparing with default values, eliminating the need for manual flags. Changes summary: - Optimized the responsive width adjustment logic: - Reduced unnecessary event listeners by adding the resize listener only when chat width settings deviate from defaults. - Ensured full-width behavior on resize is triggered only when chat width settings have been intentionally modified by the user. - Removed the resize listener when the user resets the widths, reducing redundant code execution. - Implemented automatic detection of changes to chat width settings by comparing with default values, simplifying the logic and improving performanc
- Loading branch information
1 parent
6e89b63
commit 1340445
Showing
1 changed file
with
34 additions
and
19 deletions.
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