From f822d7e50e5a1392e9ba2d0368b15ec311afe43c Mon Sep 17 00:00:00 2001 From: Arukuen Date: Wed, 2 Sep 2026 11:17:46 +0800 Subject: [PATCH] fix: update sass breakpoints with wordpress 7 --- gulpfile.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/gulpfile.js b/gulpfile.js index a4c6ec743..94b00421d 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -575,8 +575,11 @@ gulp.task( 'style-editor', function() { // src/styles/breakpoints.scss, we do it here because there are various // files that use the breakpoints and it's easier to override it here. .pipe( sassVariables( { - '$desktop-width': 781, - '$tablet-width': 361, + // Match the Block Editor's fixed preview widths. getMediaQuery subtracts 1, + // so these default values target 781px tablet and 479px mobile in WordPress 7.0. + // https://github.com/WordPress/gutenberg/pull/74339 + '$desktop-width': 782, + '$tablet-width': 480, } ) ) .pipe( sass( sassOptions ).on( 'error', sass.logError ) ) .pipe( concat( 'editor_blocks.css' ) )