Skip to content

Commit

Permalink
Movers: Add bigger visible focus rectangle.
Browse files Browse the repository at this point in the history
This PR makes the focus rectangle the same size as the button itself.
  • Loading branch information
Joen A authored and jasmussen committed Aug 5, 2020
1 parent 65258a0 commit f951e6a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 9 deletions.
2 changes: 1 addition & 1 deletion packages/block-editor/src/components/block-list/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -600,7 +600,7 @@
&:focus::before {
left: 0 !important;
min-width: 0;
width: 28px;
width: calc(100% + #{ $border-width });
}
}
}
Expand Down
17 changes: 9 additions & 8 deletions packages/block-editor/src/components/block-mover/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@
// Focus style.
// Overrides .components-toolbar-group styles
&::before {
left: $grid-unit-10 !important;
right: $grid-unit-10 !important;
left: 0 !important;
right: 0 !important;
}
}

Expand All @@ -47,7 +47,7 @@
// Focus style.
&::before {
bottom: 0;
height: calc(100% - #{ $grid-unit-10 });
height: 100%;
}
}

Expand All @@ -60,7 +60,7 @@
// Focus style.
&::before {
top: 0;
height: calc(100% - #{ $grid-unit-10 });
height: 100%;
}
}

Expand All @@ -76,8 +76,8 @@

// Focus style.
&::before {
top: $grid-unit-10;
bottom: $grid-unit-10;
top: 0;
bottom: 0;
min-width: 0;
width: auto;
height: auto;
Expand All @@ -95,7 +95,7 @@
// Focus style.
// Overrides .components-toolbar-group styles
&::before {
left: $grid-unit-10 !important;
left: 0 !important;
right: 0 !important;
}
}
Expand All @@ -111,7 +111,8 @@
// Overrides .components-toolbar-group styles
&::before {
left: 0 !important;
right: $grid-unit-10 !important;
right: 0 !important;
width: calc(100% + #{ $border-width });
}
}
}
Expand Down

0 comments on commit f951e6a

Please sign in to comment.