Skip to content

Commit

Permalink
Site Editor Sidebar: Hide horizontal scrollbar when navigating (#63194)
Browse files Browse the repository at this point in the history
* Site Editor Sidebar: Hide horizontal scrollbar when navigating

* Add `contain: content` and comment

Co-authored-by: t-hamano <wildworks@git.wordpress.org>
Co-authored-by: jsnajdr <jsnajdr@git.wordpress.org>
  • Loading branch information
3 people committed Jul 8, 2024
1 parent 98f08cf commit 048b311
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions packages/edit-site/src/components/sidebar/style.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
.edit-site-sidebar__content {
flex-grow: 1;
overflow-y: auto;
// Prevents horizontal overflow while animating screen transitions
overflow-x: hidden;
// Mark this section of the DOM as isolated, providing performance benefits
// by limiting calculations of layout, style and paint to a DOM subtree rather
// than the entire page.
contain: content;
}

@keyframes local--slide-from-right {
Expand Down

0 comments on commit 048b311

Please sign in to comment.