Skip to content

Commit

Permalink
Use padding top/bottom instead of before/after for top/bottom frame
Browse files Browse the repository at this point in the history
  • Loading branch information
jeryj committed Oct 10, 2024
1 parent 28e4dd0 commit 03ed997
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions packages/block-editor/src/components/iframe/content.scss
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,11 @@
$total-frame-height: calc(2 * #{$frame-size} / #{$scale});
$total-height: calc(#{$extra-content-height} + #{$total-frame-height} + 2px);
margin-bottom: calc(-1 * #{$total-height});

&::before,
&::after {
height: calc(#{$frame-size} / #{$scale});
}
// Add the top/bottom frame size. We use scaling to account for the left/right, as
// the padding left/right causes the contents to reflow, which breaks the 1:1 scaling
// of the content.
padding-top: calc(#{$frame-size} / #{$scale});
padding-bottom: calc(#{$frame-size} / #{$scale});

body {
min-height: calc((#{$inner-height} - #{$total-frame-height}) / #{$scale});
Expand Down

0 comments on commit 03ed997

Please sign in to comment.