Skip to content

Commit

Permalink
bring back the pinned area items for settings and styles in the site …
Browse files Browse the repository at this point in the history
…editor mobile views (#53412)
  • Loading branch information
draganescu authored Aug 8, 2023
1 parent cf44056 commit 57c4a6e
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,9 @@
overflow: hidden;

// Offset the layout based on the width of the ⌘K label. This ensures the title is centrally aligned.
padding-left: $grid-unit-40;
@include break-small() {
padding-left: $grid-unit-40;
}

&:hover {
color: var(--wp-block-synced-color);
Expand Down Expand Up @@ -95,6 +97,10 @@
.edit-site-document-actions__shortcut {
color: $gray-800;
min-width: $grid-unit-40;
display: none;
@include break-small() {
display: initial;
}
}

.edit-site-document-actions__back.components-button.has-icon.has-text {
Expand Down
9 changes: 0 additions & 9 deletions packages/edit-site/src/components/header-edit-mode/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -88,15 +88,6 @@ $header-toolbar-min-width: 335px;
@include break-small() {
gap: $grid-unit-10;
}

// Pinned items.
.interface-pinned-items {
display: none;

@include break-medium() {
display: inline-flex;
}
}
}

.edit-site-header-edit-mode__preview-options {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ export default function DefaultSidebar( {
scope="core/edit-site"
identifier={ identifier }
title={ title }
smallScreenTitle={ title }
icon={ icon }
closeLabel={ closeLabel }
header={ header }
Expand Down
22 changes: 12 additions & 10 deletions packages/interface/src/components/pinned-items/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,19 @@

// We intentionally hide pinned items (plugins) on mobile, and unhide them at desktop breakpoints.
// Otherwise the list can wreak havoc on the layout.
.components-button:not(:first-child) {
.components-button {
display: none;
margin: 0;

&:nth-last-child(1),
&:nth-last-child(2) {
display: flex;
}

svg {
max-width: $icon-size;
max-height: $icon-size;
}

@include break-small() {
display: flex;
Expand All @@ -16,13 +27,4 @@

// Account for larger grid from parent container gap.
margin-right: -$grid-unit-05;

.components-button {
margin: 0;

svg {
max-width: $icon-size;
max-height: $icon-size;
}
}
}

0 comments on commit 57c4a6e

Please sign in to comment.