-
-
Notifications
You must be signed in to change notification settings - Fork 582
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix split view splitters being offset by sidebar #4088
base: dev
Are you sure you want to change the base?
Fix split view splitters being offset by sidebar #4088
Conversation
+ if (this._sidebarResizeObserver) { | ||
+ this._sidebarResizeObserver.disconnect(); | ||
+ } | ||
+ this._sidebarResizeObserver = new ResizeObserver(async () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I dont think we should add an observer, I believe there are better ways...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I found an easier solution by simply moving the splitview-overlay and wrapper into the tabbrowser so the inset % will be correct based on the tabpanels width.
I think it makes more sense for splitview overlay to be nested within the tabpanel so its always the correct size vs. doing extra calculations. I also removed the xhtml file since it seemed to be the occurrence
This issue #4680 |
Fixes #2761
Splitters were calculated using the entire split view overlay which results in an incorrect inset % when a sidebar is present.
Recording.2024-12-30.203029.mp4
A padding-left or padding-right (depending on sidebar position) equal to the sidebar width is added to the overlay for the inset % to be correct. This padding is recalculated under the following actions
splitview.mp4