Skip to content

Commit

Permalink
Move margins to theme.scss (#43813)
Browse files Browse the repository at this point in the history
  • Loading branch information
scruffian authored Sep 6, 2022
1 parent ee52971 commit fd3b08b
Show file tree
Hide file tree
Showing 11 changed files with 27 additions and 27 deletions.
5 changes: 0 additions & 5 deletions packages/block-library/src/audio/block.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,6 @@
"supports": {
"anchor": true,
"align": true,
"__experimentalStyle": {
"spacing": {
"margin": "0 0 1em 0"
}
},
"spacing": {
"margin": true,
"padding": true
Expand Down
4 changes: 4 additions & 0 deletions packages/block-library/src/audio/theme.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
.wp-block-audio figcaption {
@include caption-style-theme();
}

.wp-block-audio {
margin: 0 0 1em 0;
}
7 changes: 7 additions & 0 deletions packages/block-library/src/common.scss
Original file line number Diff line number Diff line change
Expand Up @@ -154,3 +154,10 @@ html :where(img[class*="wp-image-"]) {
height: auto;
max-width: 100%;
}

/**
* Reset user agent styles for figure element margins.
*/
figure {
margin: 0 0 1em 0;
}
7 changes: 1 addition & 6 deletions packages/block-library/src/embed/block.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,7 @@
}
},
"supports": {
"align": true,
"__experimentalStyle": {
"spacing": {
"margin": "0 0 1em 0"
}
}
"align": true
},
"editorStyle": "wp-block-embed-editor",
"style": "wp-block-embed"
Expand Down
4 changes: 4 additions & 0 deletions packages/block-library/src/embed/theme.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
.wp-block-embed figcaption {
@include caption-style-theme();
}

.wp-block-embed {
margin: 0 0 1em 0;
}
5 changes: 0 additions & 5 deletions packages/block-library/src/image/block.json
Original file line number Diff line number Diff line change
Expand Up @@ -100,11 +100,6 @@
"radius": true,
"width": true
}
},
"__experimentalStyle": {
"spacing": {
"margin": "0 0 1em 0"
}
}
},
"styles": [
Expand Down
4 changes: 4 additions & 0 deletions packages/block-library/src/image/theme.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
.wp-block-image figcaption {
@include caption-style-theme();
}

.wp-block-image {
margin: 0 0 1em 0;
}
7 changes: 1 addition & 6 deletions packages/block-library/src/table/block.json
Original file line number Diff line number Diff line change
Expand Up @@ -160,12 +160,7 @@
"width": true
}
},
"__experimentalSelector": ".wp-block-table > table",
"__experimentalStyle": {
"spacing": {
"margin": "0 0 1em 0"
}
}
"__experimentalSelector": ".wp-block-table > table"
},
"styles": [
{
Expand Down
2 changes: 2 additions & 0 deletions packages/block-library/src/table/theme.scss
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
.wp-block-table {
margin: "0 0 1em 0";

thead {
border-bottom: 3px solid;
}
Expand Down
5 changes: 0 additions & 5 deletions packages/block-library/src/video/block.json
Original file line number Diff line number Diff line change
Expand Up @@ -80,11 +80,6 @@
"spacing": {
"margin": true,
"padding": true
},
"__experimentalStyle": {
"spacing": {
"margin": "0 0 1em 0"
}
}
},
"editorStyle": "wp-block-video-editor",
Expand Down
4 changes: 4 additions & 0 deletions packages/block-library/src/video/theme.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
.wp-block-video figcaption {
@include caption-style-theme();
}

.wp-block-video {
margin: 0 0 1em 0;
}

0 comments on commit fd3b08b

Please sign in to comment.