From 31a76e520b0f5c36e0d462f9cac95e36c616ca1b Mon Sep 17 00:00:00 2001 From: audrasjb Date: Mon, 29 Nov 2021 22:03:59 +0000 Subject: [PATCH] Twenty Twenty: Restore Editor post title styles after Gutenberg 11.4.0 updates. This change restores the Editor post title alignement and font styles in Twenty Twenty after Gutenberg 11.4.0 updates on the editor markup. Props shireling, mai21, hilayt24, desrosj, sabernhardt. Fixes #54056. Built from https://develop.svn.wordpress.org/trunk@52271 git-svn-id: http://core.svn.wordpress.org/trunk@51863 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- .../assets/css/editor-style-block-rtl.css | 12 ++++++++++++ .../twentytwenty/assets/css/editor-style-block.css | 12 ++++++++++++ .../class-twentytwenty-non-latin-languages.php | 2 +- wp-includes/version.php | 2 +- 4 files changed, 26 insertions(+), 2 deletions(-) diff --git a/wp-content/themes/twentytwenty/assets/css/editor-style-block-rtl.css b/wp-content/themes/twentytwenty/assets/css/editor-style-block-rtl.css index fe56bd3389..98c02c4819 100644 --- a/wp-content/themes/twentytwenty/assets/css/editor-style-block-rtl.css +++ b/wp-content/themes/twentytwenty/assets/css/editor-style-block-rtl.css @@ -120,6 +120,7 @@ Inter variable font. Usage: } .editor-post-title__block .editor-post-title__input, +.editor-styles-wrapper .wp-block-post-title, .editor-styles-wrapper .wp-block h1, .editor-styles-wrapper .wp-block h2, .editor-styles-wrapper .wp-block h3, @@ -136,6 +137,7 @@ Inter variable font. Usage: @supports ( font-variation-settings: normal ) { .editor-post-title__block .editor-post-title__input, + .editor-styles-wrapper .wp-block-post-title, .editor-styles-wrapper .wp-block h1, .editor-styles-wrapper .wp-block h2, .editor-styles-wrapper .wp-block h3, @@ -235,6 +237,7 @@ Inter variable font. Usage: } .editor-post-title__block .editor-post-title__input, +.editor-styles-wrapper .wp-block-post-title, .editor-styles-wrapper .wp-block h1, .editor-styles-wrapper .wp-block h2, .editor-styles-wrapper .wp-block h3, @@ -251,6 +254,7 @@ Inter variable font. Usage: } .editor-post-title__block .editor-post-title__input, +.editor-styles-wrapper .wp-block-post-title, .editor-styles-wrapper .wp-block h1 { font-size: 36px; font-weight: 800; @@ -287,6 +291,12 @@ Inter variable font. Usage: /* POST TITLE */ +.editor-styles-wrapper .wp-block-post-title { + max-width: 1000px; + margin: 0 auto; + text-align: center; +} + .wp-block.editor-post-title__block { max-width: 1000px; } @@ -1217,6 +1227,7 @@ hr.wp-block-separator.is-style-dots::before { /* TYPOGRAPHY */ .editor-post-title__block .editor-post-title__input, + .editor-styles-wrapper .wp-block-post-title, .editor-styles-wrapper .wp-block h1 { font-size: 64px; } @@ -1395,6 +1406,7 @@ hr.wp-block-separator.is-style-dots::before { /* TYPOGRAPHY */ .editor-post-title__block .editor-post-title__input, + .editor-styles-wrapper .wp-block-post-title, .editor-styles-wrapper .wp-block h1 { font-size: 84px; } diff --git a/wp-content/themes/twentytwenty/assets/css/editor-style-block.css b/wp-content/themes/twentytwenty/assets/css/editor-style-block.css index 1fac49c182..ed613946c4 100644 --- a/wp-content/themes/twentytwenty/assets/css/editor-style-block.css +++ b/wp-content/themes/twentytwenty/assets/css/editor-style-block.css @@ -120,6 +120,7 @@ Inter variable font. Usage: } .editor-post-title__block .editor-post-title__input, +.editor-styles-wrapper .wp-block-post-title, .editor-styles-wrapper .wp-block h1, .editor-styles-wrapper .wp-block h2, .editor-styles-wrapper .wp-block h3, @@ -136,6 +137,7 @@ Inter variable font. Usage: @supports ( font-variation-settings: normal ) { .editor-post-title__block .editor-post-title__input, + .editor-styles-wrapper .wp-block-post-title, .editor-styles-wrapper .wp-block h1, .editor-styles-wrapper .wp-block h2, .editor-styles-wrapper .wp-block h3, @@ -235,6 +237,7 @@ Inter variable font. Usage: } .editor-post-title__block .editor-post-title__input, +.editor-styles-wrapper .wp-block-post-title, .editor-styles-wrapper .wp-block h1, .editor-styles-wrapper .wp-block h2, .editor-styles-wrapper .wp-block h3, @@ -251,6 +254,7 @@ Inter variable font. Usage: } .editor-post-title__block .editor-post-title__input, +.editor-styles-wrapper .wp-block-post-title, .editor-styles-wrapper .wp-block h1 { font-size: 36px; font-weight: 800; @@ -287,6 +291,12 @@ Inter variable font. Usage: /* POST TITLE */ +.editor-styles-wrapper .wp-block-post-title { + max-width: 1000px; + margin: 0 auto; + text-align: center; +} + .wp-block.editor-post-title__block { max-width: 1000px; } @@ -1217,6 +1227,7 @@ hr.wp-block-separator.is-style-dots::before { /* TYPOGRAPHY */ .editor-post-title__block .editor-post-title__input, + .editor-styles-wrapper .wp-block-post-title, .editor-styles-wrapper .wp-block h1 { font-size: 64px; } @@ -1395,6 +1406,7 @@ hr.wp-block-separator.is-style-dots::before { /* TYPOGRAPHY */ .editor-post-title__block .editor-post-title__input, + .editor-styles-wrapper .wp-block-post-title, .editor-styles-wrapper .wp-block h1 { font-size: 84px; } diff --git a/wp-content/themes/twentytwenty/classes/class-twentytwenty-non-latin-languages.php b/wp-content/themes/twentytwenty/classes/class-twentytwenty-non-latin-languages.php index 0c4951ef48..731064eda3 100644 --- a/wp-content/themes/twentytwenty/classes/class-twentytwenty-non-latin-languages.php +++ b/wp-content/themes/twentytwenty/classes/class-twentytwenty-non-latin-languages.php @@ -119,7 +119,7 @@ if ( ! class_exists( 'TwentyTwenty_Non_Latin_Languages' ) ) { 'twentytwenty_get_localized_font_family_elements', array( 'front-end' => array( 'body', 'input', 'textarea', 'button', '.button', '.faux-button', '.wp-block-button__link', '.wp-block-file__button', '.has-drop-cap:not(:focus)::first-letter', '.entry-content .wp-block-archives', '.entry-content .wp-block-categories', '.entry-content .wp-block-cover-image', '.entry-content .wp-block-latest-comments', '.entry-content .wp-block-latest-posts', '.entry-content .wp-block-pullquote', '.entry-content .wp-block-quote.is-large', '.entry-content .wp-block-quote.is-style-large', '.entry-content .wp-block-archives *', '.entry-content .wp-block-categories *', '.entry-content .wp-block-latest-posts *', '.entry-content .wp-block-latest-comments *', '.entry-content p', '.entry-content ol', '.entry-content ul', '.entry-content dl', '.entry-content dt', '.entry-content cite', '.entry-content figcaption', '.entry-content .wp-caption-text', '.comment-content p', '.comment-content ol', '.comment-content ul', '.comment-content dl', '.comment-content dt', '.comment-content cite', '.comment-content figcaption', '.comment-content .wp-caption-text', '.widget_text p', '.widget_text ol', '.widget_text ul', '.widget_text dl', '.widget_text dt', '.widget-content .rssSummary', '.widget-content cite', '.widget-content figcaption', '.widget-content .wp-caption-text' ), - 'block-editor' => array( '.editor-styles-wrapper > *', '.editor-styles-wrapper p', '.editor-styles-wrapper ol', '.editor-styles-wrapper ul', '.editor-styles-wrapper dl', '.editor-styles-wrapper dt', '.editor-post-title__block .editor-post-title__input', '.editor-styles-wrapper .wp-block h1', '.editor-styles-wrapper .wp-block h2', '.editor-styles-wrapper .wp-block h3', '.editor-styles-wrapper .wp-block h4', '.editor-styles-wrapper .wp-block h5', '.editor-styles-wrapper .wp-block h6', '.editor-styles-wrapper .has-drop-cap:not(:focus)::first-letter', '.editor-styles-wrapper cite', '.editor-styles-wrapper figcaption', '.editor-styles-wrapper .wp-caption-text' ), + 'block-editor' => array( '.editor-styles-wrapper > *', '.editor-styles-wrapper p', '.editor-styles-wrapper ol', '.editor-styles-wrapper ul', '.editor-styles-wrapper dl', '.editor-styles-wrapper dt', '.editor-post-title__block .editor-post-title__input', '.editor-styles-wrapper .wp-block-post-title', '.editor-styles-wrapper .wp-block h1', '.editor-styles-wrapper .wp-block h2', '.editor-styles-wrapper .wp-block h3', '.editor-styles-wrapper .wp-block h4', '.editor-styles-wrapper .wp-block h5', '.editor-styles-wrapper .wp-block h6', '.editor-styles-wrapper .has-drop-cap:not(:focus)::first-letter', '.editor-styles-wrapper cite', '.editor-styles-wrapper figcaption', '.editor-styles-wrapper .wp-caption-text' ), 'classic-editor' => array( 'body#tinymce.wp-editor', 'body#tinymce.wp-editor p', 'body#tinymce.wp-editor ol', 'body#tinymce.wp-editor ul', 'body#tinymce.wp-editor dl', 'body#tinymce.wp-editor dt', 'body#tinymce.wp-editor figcaption', 'body#tinymce.wp-editor .wp-caption-text', 'body#tinymce.wp-editor .wp-caption-dd', 'body#tinymce.wp-editor cite', 'body#tinymce.wp-editor table' ), ) ); diff --git a/wp-includes/version.php b/wp-includes/version.php index 6f55c529af..3dc09060a0 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '5.9-alpha-52270'; +$wp_version = '5.9-alpha-52271'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.