Skip to content

Commit d20fa0a

Browse files
Merge branch 'trunk' into ticket/30854
2 parents 7929ba6 + adcc2d3 commit d20fa0a

302 files changed

Lines changed: 28450 additions & 7646 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.gitignore‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ wp-tests-config.php
5353
!/src/wp-content/themes/twentynineteen
5454
!/src/wp-content/themes/twentytwenty
5555
!/src/wp-content/themes/twentytwentyone
56+
!/src/wp-content/themes/twentytwentytwo
5657
/src/wp-content/upgrade
5758
/src/wp-content/uploads
5859
/src/wp-content/advanced-cache.php
@@ -92,4 +93,4 @@ wp-tests-config.php
9293
/docker-compose.override.yml
9394

9495
# Visual regression test diffs
95-
tests/visual-regression/specs/__image_snapshots__
96+
tests/visual-regression/specs/__image_snapshots__

‎Gruntfile.js‎

Lines changed: 16 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1549,6 +1549,9 @@ module.exports = function(grunt) {
15491549
* @ticket 46218
15501550
*/
15511551
grunt.registerTask( 'verify:source-maps', function() {
1552+
const ignoredFiles = [
1553+
'build/wp-includes/js/dist/components.js'
1554+
];
15521555
const files = buildFiles.reduce( ( acc, path ) => {
15531556
// Skip excluded paths and any path that isn't a file.
15541557
if ( '!' === path[0] || '**' !== path.substr( -2 ) ) {
@@ -1563,18 +1566,20 @@ module.exports = function(grunt) {
15631566
'No JavaScript files found in the build directory.'
15641567
);
15651568

1566-
files.forEach( function( file ) {
1567-
const contents = fs.readFileSync( file, {
1568-
encoding: 'utf8',
1569-
} );
1570-
// `data:` URLs are allowed:
1571-
const match = contents.match( /sourceMappingURL=((?!data:).)/ );
1569+
files
1570+
.filter(file => ! ignoredFiles.includes( file) )
1571+
.forEach( function( file ) {
1572+
const contents = fs.readFileSync( file, {
1573+
encoding: 'utf8',
1574+
} );
1575+
// `data:` URLs are allowed:
1576+
const match = contents.match( /sourceMappingURL=((?!data:).)/ );
15721577

1573-
assert(
1574-
match === null,
1575-
`The ${ file } file must not contain a sourceMappingURL.`
1576-
);
1577-
} );
1578+
assert(
1579+
match === null,
1580+
`The ${ file } file must not contain a sourceMappingURL.`
1581+
);
1582+
} );
15781583
} );
15791584

15801585
grunt.registerTask( 'build', function() {

‎package-lock.json‎

Lines changed: 4065 additions & 3999 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎package.json‎

Lines changed: 70 additions & 69 deletions
Original file line numberDiff line numberDiff line change
@@ -24,14 +24,14 @@
2424
"last 2 Opera versions"
2525
],
2626
"devDependencies": {
27-
"@wordpress/babel-preset-default": "6.2.1",
28-
"@wordpress/custom-templated-path-webpack-plugin": "2.0.5",
29-
"@wordpress/dependency-extraction-webpack-plugin": "3.1.4",
30-
"@wordpress/e2e-test-utils": "5.4.3",
31-
"@wordpress/library-export-default-webpack-plugin": "2.0.5",
32-
"@wordpress/scripts": "16.1.5",
33-
"autoprefixer": "^9.8.6",
34-
"chalk": "4.1.1",
27+
"@wordpress/babel-preset-default": "6.3.4",
28+
"@wordpress/custom-templated-path-webpack-plugin": "2.1.0",
29+
"@wordpress/dependency-extraction-webpack-plugin": "3.2.1",
30+
"@wordpress/e2e-test-utils": "5.4.6",
31+
"@wordpress/library-export-default-webpack-plugin": "2.2.0",
32+
"@wordpress/scripts": "19.1.0",
33+
"autoprefixer": "^9.8.8",
34+
"chalk": "4.1.2",
3535
"check-node-version": "4.1.0",
3636
"copy-webpack-plugin": "^5.1.2",
3737
"cssnano": "4.1.11",
@@ -40,12 +40,12 @@
4040
"grunt": "~1.4.1",
4141
"grunt-banner": "^0.6.0",
4242
"grunt-contrib-clean": "~2.0.0",
43-
"grunt-contrib-concat": "1.0.1",
43+
"grunt-contrib-concat": "2.0.0",
4444
"grunt-contrib-copy": "~1.0.0",
4545
"grunt-contrib-cssmin": "~4.0.0",
4646
"grunt-contrib-imagemin": "~4.0.0",
47-
"grunt-contrib-jshint": "3.0.0",
48-
"grunt-contrib-qunit": "^4.0.0",
47+
"grunt-contrib-jshint": "3.1.1",
48+
"grunt-contrib-qunit": "^5.1.1",
4949
"grunt-contrib-uglify": "~5.0.1",
5050
"grunt-contrib-watch": "~1.1.0",
5151
"grunt-file-append": "0.0.7",
@@ -64,72 +64,73 @@
6464
"jest-image-snapshot": "3.0.1",
6565
"matchdep": "~2.0.0",
6666
"prettier": "npm:wp-prettier@2.0.5",
67-
"qunit": "~2.16.0",
68-
"sass": "^1.34.1",
69-
"sinon": "~11.1.1",
70-
"sinon-test": "~3.1.0",
67+
"qunit": "~2.17.2",
68+
"sass": "^1.43.4",
69+
"sinon": "~12.0.1",
70+
"sinon-test": "~3.1.1",
7171
"source-map-loader": "^1.1.3",
72-
"uglify-js": "^3.13.9",
72+
"uglify-js": "^3.14.3",
7373
"uglifyjs-webpack-plugin": "2.2.0",
7474
"uuid": "8.3.2",
75-
"wait-on": "5.3.0",
75+
"wait-on": "6.0.0",
7676
"webpack": "4.43.0",
7777
"webpack-dev-server": "3.11.2",
7878
"webpack-livereload-plugin": "2.3.0"
7979
},
8080
"dependencies": {
81-
"@wordpress/a11y": "3.1.2",
82-
"@wordpress/annotations": "2.1.6",
83-
"@wordpress/api-fetch": "5.1.2",
84-
"@wordpress/autop": "3.1.2",
85-
"@wordpress/blob": "3.1.2",
86-
"@wordpress/block-directory": "2.1.21",
87-
"@wordpress/block-editor": "6.1.14",
88-
"@wordpress/block-library": "3.2.19",
89-
"@wordpress/block-serialization-default-parser": "4.1.2",
90-
"@wordpress/blocks": "9.1.8",
91-
"@wordpress/components": "14.1.11",
92-
"@wordpress/compose": "4.1.6",
93-
"@wordpress/core-data": "3.1.12",
94-
"@wordpress/customize-widgets": "1.0.20",
95-
"@wordpress/data": "5.1.6",
96-
"@wordpress/data-controls": "2.1.6",
97-
"@wordpress/date": "4.1.2",
98-
"@wordpress/deprecated": "3.1.2",
99-
"@wordpress/dom": "3.1.5",
100-
"@wordpress/dom-ready": "3.1.2",
101-
"@wordpress/edit-post": "4.1.21",
102-
"@wordpress/edit-widgets": "2.1.21",
103-
"@wordpress/editor": "10.1.17",
104-
"@wordpress/element": "3.1.2",
105-
"@wordpress/escape-html": "2.1.2",
106-
"@wordpress/format-library": "2.1.14",
107-
"@wordpress/hooks": "3.1.1",
108-
"@wordpress/html-entities": "3.1.2",
109-
"@wordpress/i18n": "4.1.2",
110-
"@wordpress/icons": "4.0.3",
111-
"@wordpress/interface": "3.1.12",
112-
"@wordpress/is-shallow-equal": "4.1.1",
113-
"@wordpress/keyboard-shortcuts": "2.1.7",
114-
"@wordpress/keycodes": "3.1.2",
115-
"@wordpress/list-reusable-blocks": "2.1.11",
116-
"@wordpress/media-utils": "2.1.2",
117-
"@wordpress/notices": "3.1.6",
118-
"@wordpress/nux": "4.1.11",
119-
"@wordpress/plugins": "3.1.6",
120-
"@wordpress/primitives": "2.1.2",
121-
"@wordpress/priority-queue": "2.1.2",
122-
"@wordpress/redux-routine": "4.1.2",
123-
"@wordpress/reusable-blocks": "2.1.17",
124-
"@wordpress/rich-text": "4.1.6",
125-
"@wordpress/server-side-render": "2.1.12",
126-
"@wordpress/shortcode": "3.1.2",
127-
"@wordpress/token-list": "2.1.1",
128-
"@wordpress/url": "3.1.2",
129-
"@wordpress/viewport": "3.1.6",
130-
"@wordpress/warning": "2.1.2",
131-
"@wordpress/widgets": "1.1.19",
132-
"@wordpress/wordcount": "3.1.2",
81+
"@wordpress/a11y": "3.2.3",
82+
"@wordpress/annotations": "2.2.6",
83+
"@wordpress/api-fetch": "5.2.5",
84+
"@wordpress/autop": "3.2.2",
85+
"@wordpress/blob": "3.2.1",
86+
"@wordpress/block-directory": "3.0.5",
87+
"@wordpress/block-editor": "8.0.0",
88+
"@wordpress/block-library": "6.0.3",
89+
"@wordpress/block-serialization-default-parser": "4.2.2",
90+
"@wordpress/blocks": "11.1.3",
91+
"@wordpress/components": "19.0.1",
92+
"@wordpress/compose": "5.0.5",
93+
"@wordpress/core-data": "4.0.5",
94+
"@wordpress/customize-widgets": "2.0.5",
95+
"@wordpress/data": "6.1.3",
96+
"@wordpress/data-controls": "2.2.6",
97+
"@wordpress/date": "4.2.2",
98+
"@wordpress/deprecated": "3.2.2",
99+
"@wordpress/dom": "3.2.6",
100+
"@wordpress/dom-ready": "3.2.2",
101+
"@wordpress/edit-post": "5.0.5",
102+
"@wordpress/edit-site": "3.0.5",
103+
"@wordpress/edit-widgets": "3.1.0",
104+
"@wordpress/editor": "12.0.2",
105+
"@wordpress/element": "4.0.3",
106+
"@wordpress/escape-html": "2.2.2",
107+
"@wordpress/format-library": "3.0.5",
108+
"@wordpress/hooks": "3.2.1",
109+
"@wordpress/html-entities": "3.2.2",
110+
"@wordpress/i18n": "4.2.3",
111+
"@wordpress/icons": "6.1.0",
112+
"@wordpress/interface": "4.1.3",
113+
"@wordpress/is-shallow-equal": "4.2.0",
114+
"@wordpress/keyboard-shortcuts": "3.0.5",
115+
"@wordpress/keycodes": "3.2.3",
116+
"@wordpress/list-reusable-blocks": "3.0.5",
117+
"@wordpress/media-utils": "3.0.4",
118+
"@wordpress/notices": "3.2.6",
119+
"@wordpress/nux": "5.0.5",
120+
"@wordpress/plugins": "4.0.5",
121+
"@wordpress/primitives": "3.0.3",
122+
"@wordpress/priority-queue": "2.2.2",
123+
"@wordpress/redux-routine": "4.2.1",
124+
"@wordpress/reusable-blocks": "3.0.5",
125+
"@wordpress/rich-text": "5.0.5",
126+
"@wordpress/server-side-render": "3.0.5",
127+
"@wordpress/shortcode": "3.2.2",
128+
"@wordpress/token-list": "2.2.1",
129+
"@wordpress/url": "3.3.0",
130+
"@wordpress/viewport": "4.0.5",
131+
"@wordpress/warning": "2.2.2",
132+
"@wordpress/widgets": "2.0.5",
133+
"@wordpress/wordcount": "3.2.2",
133134
"backbone": "1.4.0",
134135
"clipboard": "2.0.8",
135136
"core-js-url-browser": "3.6.4",

‎src/js/media/controllers/library.js‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ Library = wp.media.controller.State.extend(/** @lends wp.media.controller.Librar
196196
isImageAttachment: function( attachment ) {
197197
// If uploading, we know the filename but not the mime type.
198198
if ( attachment.get('uploading') ) {
199-
return /\.(jpe?g|png|gif)$/i.test( attachment.get('filename') );
199+
return /\.(jpe?g|png|gif|webp)$/i.test( attachment.get('filename') );
200200
}
201201

202202
return attachment.get('type') === 'image';

‎src/js/media/views/uploader/inline.js‎

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -106,16 +106,21 @@ UploaderInline = View.extend(/** @lends wp.media.view.UploaderInline.prototype *
106106
$placeholder;
107107

108108
if ( this.controller.uploader ) {
109-
$placeholder = this.$('.browser');
109+
$placeholder = this.$('.browser-container');
110110

111111
// Check if we've already replaced the placeholder.
112112
if ( $placeholder[0] === $browser[0] ) {
113113
return;
114114
}
115115

116-
$browser.detach().text( $placeholder.text() );
117-
$browser[0].className = $placeholder[0].className;
118-
$browser[0].setAttribute( 'aria-labelledby', $browser[0].id + ' ' + $placeholder[0].getAttribute('aria-labelledby') );
116+
var browserLabel = $placeholder.find( 'label' );
117+
var browserInput = $placeholder.find( 'input' );
118+
119+
browserLabel.attr( 'for', $browser[0].id );
120+
browserInput.attr( 'id', $browser[0].id );
121+
$browser.removeAttr( 'id' );
122+
123+
$browser.append( browserLabel ).append( browserInput );
119124
$placeholder.replaceWith( $browser.show() );
120125
}
121126

‎src/js/media/views/uploader/window.js‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ UploaderWindow = wp.media.View.extend(/** @lends wp.media.view.UploaderWindow.pr
2727
initialize: function() {
2828
var uploader;
2929

30-
this.$browser = $( '<button type="button" class="browser" />' ).hide().appendTo( 'body' );
30+
this.$browser = $( '<div class="browser-container">' ).hide().appendTo( 'body' );
3131

3232
uploader = this.options.uploader = _.defaults( this.options.uploader || {}, {
3333
dropzone: this.$el,

‎src/wp-admin/css/login.css‎

Lines changed: 50 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,7 @@ p {
281281

282282
#login {
283283
width: 320px;
284-
padding: 8% 0 0;
284+
padding: 5% 0 0;
285285
margin: auto;
286286
}
287287

@@ -321,7 +321,7 @@ p {
321321
.login .privacy-policy-page-link {
322322
text-align: center;
323323
width: 100%;
324-
margin: 5em 0 2em;
324+
margin: 3em 0 2em;
325325
}
326326

327327
.login form .input,
@@ -409,10 +409,46 @@ input::-ms-reveal {
409409
display: none;
410410
}
411411

412+
#language-switcher {
413+
padding: 0;
414+
overflow: visible;
415+
background: none;
416+
border: none;
417+
box-shadow: none;
418+
}
419+
420+
#language-switcher select {
421+
margin-right: 0.25em;
422+
}
423+
424+
.language-switcher {
425+
margin: 0 auto;
426+
padding: 0 0 24px;
427+
text-align: center;
428+
}
429+
430+
.language-switcher label {
431+
margin-right: 0.25em;
432+
}
433+
434+
.language-switcher label .dashicons {
435+
width: auto;
436+
height: auto;
437+
}
438+
439+
.login .language-switcher .button-primary {
440+
float: none;
441+
margin-bottom: 0;
442+
}
443+
412444
@media screen and (max-height: 550px) {
413445
#login {
414446
padding: 20px 0;
415447
}
448+
449+
#language-switcher {
450+
margin-top: 0;
451+
}
416452
}
417453

418454

@@ -427,4 +463,16 @@ input::-ms-reveal {
427463
height: 1.3125rem;
428464
margin: -0.1875rem 0 0 -0.25rem;
429465
}
466+
467+
#language-switcher label,
468+
#language-switcher select {
469+
margin-right: 0;
470+
}
471+
}
472+
473+
@media screen and (max-width: 400px) {
474+
.login .language-switcher .button-primary {
475+
display: block;
476+
margin: 5px auto 0;
477+
}
430478
}

‎src/wp-admin/customize.php‎

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -188,16 +188,8 @@
188188
<?php
189189
$compatible_wp = is_wp_version_compatible( $wp_customize->theme()->get( 'RequiresWP' ) );
190190
$compatible_php = is_php_version_compatible( $wp_customize->theme()->get( 'RequiresPHP' ) );
191-
$fse_safe = true;
192-
193-
// Check if the theme requires the Gutenberg plugin to work correctly.
194-
$theme_tags = $wp_customize->theme()->get( 'Tags' );
195-
196-
if ( ! empty( $theme_tags ) && in_array( 'full-site-editing', $theme_tags, true ) && ! function_exists( 'gutenberg_is_fse_theme' ) ) {
197-
$fse_safe = false;
198-
}
199191
?>
200-
<?php if ( $compatible_wp && $compatible_php && $fse_safe ) : ?>
192+
<?php if ( $compatible_wp && $compatible_php ) : ?>
201193
<?php $save_text = $wp_customize->is_theme_active() ? __( 'Publish' ) : __( 'Activate &amp; Publish' ); ?>
202194
<div id="customize-save-button-wrapper" class="customize-save-button-wrapper" >
203195
<?php submit_button( $save_text, 'primary save', 'save', false ); ?>
@@ -241,9 +233,16 @@
241233
<button type="button" class="customize-help-toggle dashicons dashicons-editor-help" aria-expanded="false"><span class="screen-reader-text"><?php _e( 'Help' ); ?></span></button>
242234
</div>
243235
<div class="customize-panel-description">
244-
<?php
245-
_e( 'The Customizer allows you to preview changes to your site before publishing them. You can navigate to different pages on your site within the preview. Edit shortcuts are shown for some editable elements.' );
246-
?>
236+
<p>
237+
<?php
238+
_e( 'The Customizer allows you to preview changes to your site before publishing them. You can navigate to different pages on your site within the preview. Edit shortcuts are shown for some editable elements.' );
239+
?>
240+
</p>
241+
<p>
242+
<?php
243+
_e( '<a href="https://wordpress.org/support/article/appearance-customize-screen/">Documentation on Customizer</a>' );
244+
?>
245+
</p>
247246
</div>
248247
</div>
249248

0 commit comments

Comments
 (0)