فهرست منبع

Blockbase: fixing separator block ddots option (#5964)

Matias Benedetto 3 سال پیش
والد
کامیت
9b03958b77
2فایلهای تغییر یافته به همراه17 افزوده شده و 1 حذف شده
  1. 7 0
      blockbase/assets/ponyfill.css
  2. 10 1
      blockbase/sass/blocks/_separator.scss

+ 7 - 0
blockbase/assets/ponyfill.css

@@ -921,6 +921,13 @@ div.wp-block-query-pagination .wp-block-query-pagination-numbers .current {
 .wp-block-separator:not(.is-style-wide) {
 .wp-block-separator:not(.is-style-wide) {
   width: var(--wp--custom--separator--width);
   width: var(--wp--custom--separator--width);
 }
 }
+.wp-block-separator.is-style-dots {
+  /*
+  	We can solve this using including the Gutenberg block styles with: add_theme_support( 'wp-block-styles' )
+  	but we decided not to add those styles to blockbase because of potential broad impact of those styles.
+  */
+  width: 100%;
+}
 
 
 p.wp-block-site-tagline {
 p.wp-block-site-tagline {
   margin: 0;
   margin: 0;

+ 10 - 1
blockbase/sass/blocks/_separator.scss

@@ -1,6 +1,15 @@
 .wp-block-separator {
 .wp-block-separator {
 	opacity: var(--wp--custom--separator--opacity); // Mirror controls that Gutenberg theme.css offers: https://github.com/WordPress/gutenberg/blob/trunk/packages/block-library/src/separator/theme.scss - See: https://github.com/WordPress/gutenberg/issues/34637
 	opacity: var(--wp--custom--separator--opacity); // Mirror controls that Gutenberg theme.css offers: https://github.com/WordPress/gutenberg/blob/trunk/packages/block-library/src/separator/theme.scss - See: https://github.com/WordPress/gutenberg/issues/34637
-	&:not(.is-style-wide){
+	&:not(.is-style-wide) {
 		width: var(--wp--custom--separator--width); // See https://github.com/WordPress/gutenberg/issues/34638
 		width: var(--wp--custom--separator--width); // See https://github.com/WordPress/gutenberg/issues/34638
 	}
 	}
+
+	&.is-style-dots {
+
+		/*
+			We can solve this using including the Gutenberg block styles with: add_theme_support( 'wp-block-styles' )
+			but we decided not to add those styles to blockbase because of potential broad impact of those styles.
+		*/
+		width: 100%;
+	}
 }
 }