Skip to content

Commit

Permalink
Fix the border radius in the site editor. (#27986)
Browse files Browse the repository at this point in the history
* Fix the border radius in the site editor.

* Fix typos
  • Loading branch information
jasmussen authored Jan 5, 2021
1 parent b937487 commit ec810c1
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions packages/block-editor/src/components/block-list/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@
// Everything else.
// 2px outside.
box-shadow: 0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);
border-radius: $radius-block-ui - $border-width; // Border is outset, so so subtract the width to achieve correct radius.
border-radius: $radius-block-ui - $border-width; // Border is outset, so subtract the width to achieve correct radius.

// Windows High Contrast mode will show this outline.
outline: 2px solid transparent;
Expand Down Expand Up @@ -185,7 +185,7 @@

// 2px outside.
box-shadow: 0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);
border-radius: $radius-block-ui - $border-width; // Border is outset, so so subtract the width to achieve correct radius.
border-radius: $radius-block-ui - $border-width; // Border is outset, so subtract the width to achieve correct radius.

// Show a light color for dark themes.
.is-dark-theme & {
Expand All @@ -201,6 +201,7 @@
left: $border-width;
right: $border-width;
bottom: $border-width;
border-radius: $radius-block-ui - $border-width; // Border is outset, so subtract the width to achieve correct radius.
}

&:focus {
Expand All @@ -219,6 +220,7 @@
right: $border-width;
bottom: $border-width;
box-shadow: 0 0 0 $border-width var(--wp-admin-theme-color);
border-radius: $radius-block-ui - $border-width; // Border is outset, so subtract the width to achieve correct radius.
}
}

Expand Down Expand Up @@ -589,7 +591,7 @@

// Block UI appearance.
box-shadow: 0 0 0 $border-width $gray-900;
border-radius: $radius-block-ui - $border-width; // Border is outset, so so subtract the width to achieve correct radius.
border-radius: $radius-block-ui - $border-width; // Border is outset, so subtract the width to achieve correct radius.
background-color: $white;

// When button is focused, it receives a box-shadow instead of the border.
Expand Down

0 comments on commit ec810c1

Please sign in to comment.