Skip to content

Commit

Permalink
improve style
Browse files Browse the repository at this point in the history
  • Loading branch information
gigitux committed Oct 30, 2024
1 parent 9806534 commit ca3b59b
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 30 deletions.
1 change: 1 addition & 0 deletions packages/base-styles/_z-index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,7 @@ $z-layers: (
".editor-action-modal": 1000001,
".editor-post-template__swap-template-modal": 1000001,
".edit-site-template-panel__replace-template-modal": 1000001,
".fields-controls__template-modal": 1000001,

// Note: The ConfirmDialog component's z-index is being set to 1000001 in packages/components/src/confirm-dialog/styles.ts
// because it uses emotion and not sass. We need it to render on top its parent popover.
Expand Down
3 changes: 1 addition & 2 deletions packages/edit-site/src/style.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
@import "../../dataviews/src/style.scss";
@import "../../fields/src/styles.scss";
@import "../../fields/src/fields/featured-image/style.scss";
@import "../../fields/src/style.scss";

@import "./components/add-new-template/style.scss";
@import "./components/block-editor/style.scss";
Expand Down
28 changes: 3 additions & 25 deletions packages/fields/src/fields/template/style.scss
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
.editor-post-template__swap-template-modal {
z-index: z-index(".editor-post-template__swap-template-modal");
.fields-controls__template-modal {
z-index: z-index(".fields-controls__template-modal");
}

.editor-post-template__swap-template-modal-content
.block-editor-block-patterns-list {
.fields-controls__template-content .block-editor-block-patterns-list {
column-count: 2;
column-gap: $grid-unit-30;

Expand All @@ -22,24 +21,3 @@
break-inside: avoid-column;
}
}

.editor-post-template__dropdown {
.components-popover__content {
min-width: 240px;
}
.components-button.is-pressed,
.components-button.is-pressed:hover {
background: inherit;
color: inherit;
}
}

.editor-post-template__create-form {
@include break-medium() {
width: $grid-unit * 40;
}
}

.editor-post-template__classic-theme-dropdown {
padding: $grid-unit-10;
}
4 changes: 2 additions & 2 deletions packages/fields/src/fields/template/template-edit.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -204,10 +204,10 @@ export const TemplateEdit = ( {
<Modal
title={ __( 'Choose a template' ) }
onRequestClose={ () => setShowModal( false ) }
overlayClassName="editor-post-template__swap-template-modal"
overlayClassName="fields-controls__template-modal"
isFullScreen
>
<div className="editor-post-template__swap-template-modal-content">
<div className="fields-controls__template-content">
<BlockPatternsList
label={ __( 'Templates' ) }
blockPatterns={ templatesAsPatterns }
Expand Down
3 changes: 3 additions & 0 deletions packages/fields/src/style.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@import "./fields/slug/style.scss";
@import "./fields/featured-image/style.scss";
@import "./fields/template/style.scss";
1 change: 0 additions & 1 deletion packages/fields/src/styles.scss

This file was deleted.

0 comments on commit ca3b59b

Please sign in to comment.