浏览代码

Dyad 2: Fix nest alignwide/full blocks on frontend.

Allan Cole 5 年之前
父节点
当前提交
1601b7a047
共有 1 个文件被更改,包括 22 次插入0 次删除
  1. 22 0
      dyad-2/css/blocks.css

+ 22 - 0
dyad-2/css/blocks.css

@@ -34,6 +34,23 @@ Description: Used to style Gutenberg Blocks.
 		margin-right: -20%;
 		width: auto;
 	}
+
+	body:not(.has-post-thumbnail) .alignfull .wp-block-group__inner-container .alignwide {
+		margin-left: auto;
+		margin-right: auto;
+		max-width: calc(700px + 40%);
+	}
+
+	body:not(.has-post-thumbnail) .wp-block-group__inner-container .alignwide {
+		margin-left: auto;
+		margin-right: auto;
+	}
+
+	body:not(.has-post-thumbnail) .wp-block-group__inner-container > *:not(.alignwide):not(.alignfull) {
+		margin-left: auto;
+		margin-right: auto;
+		max-width: 700px;
+	}
 }
 
 body:not(.has-post-thumbnail) .alignfull {
@@ -42,6 +59,11 @@ body:not(.has-post-thumbnail) .alignfull {
 	width: auto;
 }
 
+body:not(.has-post-thumbnail) .wp-block-group__inner-container .alignfull {
+	margin-left: 0;
+	margin-right: 0;
+}
+
 /* Make non image-based blocks a bit narrower, so they don't get cut off. */
 
 body:not(.has-post-thumbnail) .wp-block-columns.alignfull,