Commit Graph

2432 Commits

Author SHA1 Message Date
gziolo
8df663cbfa Editor: Enqueue script and style assets only for blocks present on the page
Adds styles for individual core blocks to make it possible to render only styles for those blocks that are rendered on the page (frontend). This is optinal functionality for start that can be controlled with the new `separate_core_block_assets` filter.

In addition to that, styles can be inlined when `path` is passed when registering an individual styles. This functionality can be changed with the new `styles_inline_size_limit` filter. The maximum size of inlined styles in bytes defaults to 20 000.

Props aristath, aduth, westonruter, mcsf.
Fixes #50328, #52620.


Built from https://develop.svn.wordpress.org/trunk@50836


git-svn-id: http://core.svn.wordpress.org/trunk@50445 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-05-11 09:43:08 +00:00
desrosj
9d2315b409 External Libraries: Update Moment.js to the latest version.
This updates the `moment` script from version `2.27.0` to `2.29.1`.

Props shital-patel, hareesh-pillai.
Fixes #52853.
Built from https://develop.svn.wordpress.org/trunk@50773


git-svn-id: http://core.svn.wordpress.org/trunk@50382 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-04-20 19:15:21 +00:00
gziolo
ad48a15387 Editor: Update WordPress packages to use with WordPress 5.8
In the response to the discussion during the Dev Chat, I'm doing a first pass to keep WordPress packages up to date in the WordPress 5.8 release cycle.

See https://github.com/WordPress/wordpress-develop/pull/1176 for more details.

Props youknowriad, aristath, andraganescu.
See #52991.


Built from https://develop.svn.wordpress.org/trunk@50761


git-svn-id: http://core.svn.wordpress.org/trunk@50370 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-04-15 15:19:43 +00:00
gziolo
b31964a44b Blocks: Add is_default handling to server side block styles registry
Ensures that register_block_style lets developer pass `is_default` flag to mark one of the block style variations as the default one.

Props mukesh27, xavivars.
Fixes #53006.


Built from https://develop.svn.wordpress.org/trunk@50703


git-svn-id: http://core.svn.wordpress.org/trunk@50312 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-04-13 08:04:13 +00:00
Sergey Biryukov
3697386083 Editor: Consolidate enqueueing block editor assets in wp-includes/default-filters.php.
Follow-up to [44157], [46111], [48537], [50620].

See #52920.
Built from https://develop.svn.wordpress.org/trunk@50629


git-svn-id: http://core.svn.wordpress.org/trunk@50241 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-04-01 11:46:09 +00:00
gziolo
6d42a21103 Editor: Enqueue assets for format library for the block editor
Ensures that `wp-format-library` assets are always loaded for the block editor. Otherwise, they have to be loaded individually for every screen that needs it. It's similar to how `wp-block-directory` assets are handled.

Props ellatrix.
See #52920.


Built from https://develop.svn.wordpress.org/trunk@50620


git-svn-id: http://core.svn.wordpress.org/trunk@50233 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-03-31 05:52:10 +00:00
desrosj
5c451da5e9 External Libraries: Update polyfill versions in the script loader.
Follow up to [50615, 50617].

See #52854.
Built from https://develop.svn.wordpress.org/trunk@50619


git-svn-id: http://core.svn.wordpress.org/trunk@50232 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-03-30 17:57:05 +00:00
Peter Wilson
a66cb4bb18 Script Loader: Escape HTML5 boolean attribute names.
Add escaping of boolean attribute names in `wp_sanitize_script_attributes()` for themes supporting HTML5 script elements.

Props tmatsuur, johnbillion, joyously.
Fixes #52894.

Built from https://develop.svn.wordpress.org/trunk@50575


git-svn-id: http://core.svn.wordpress.org/trunk@50188 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-03-25 00:27:06 +00:00
Sergey Biryukov
b65d83b872 External Libraries: Further fix jQuery deprecations in WordPress core.
This includes many minor adjustments to a wide array of core files to replace shorthands with full declarations.

Follow-up to [50001], [50270], [50367].

Props Clorith, hellofromTonya, peterwilsoncc, adamsilverstein, aristath.
See #51812.
Built from https://develop.svn.wordpress.org/trunk@50420


git-svn-id: http://core.svn.wordpress.org/trunk@50031 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-02-23 19:45:04 +00:00
Peter Wilson
c463e94a33 Security: move Content-Security-Policy script loaders.
Move `wp_get_script_tag()`, `wp_print_script_tag()`, `wp_print_inline_script_tag()` and `wp_get_inline_script_tag()` functions from `functions.php` to `script-loader.php`.

Relocate related tests to `dependencies` sub-directory.

Follow up to [50167].
Props adamsilverstein, hellofromTonya, SergeyBiryukov.
Fixes #39941.

Built from https://develop.svn.wordpress.org/trunk@50409


git-svn-id: http://core.svn.wordpress.org/trunk@50020 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-02-23 02:00:06 +00:00
Peter Wilson
d0cf9db65c Site Health: Update site-health script dependencies.
Add `wp-hooks` and `wp-i18n` to Site Health JavaScript dependencies.

Props gmariani405, Clorith, mukesh27.
Fixes #52483.

Built from https://develop.svn.wordpress.org/trunk@50294


git-svn-id: http://core.svn.wordpress.org/trunk@49939 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-02-12 00:10:04 +00:00
Sergey Biryukov
19ce835654 Docs: Update some recently added inline comments per the documentation standards.
Follow-up to [50256], [50258], [50259].

See #51800.
Built from https://develop.svn.wordpress.org/trunk@50264


git-svn-id: http://core.svn.wordpress.org/trunk@49909 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-02-09 12:34:06 +00:00
noisysocks
c6ec6cdc88 Fix wp.i18n.isRTL()
Fixes a bug causing wp.i18n.isRTL() to return false in RTL langauges by manually
loading the translated 'ltr' string for the i18n dependency. This ports over an
identical fix that was made in Gutenberg.

Fixes #52441.
Props @jonsurrell @youknowriad.

Built from https://develop.svn.wordpress.org/trunk@50259


git-svn-id: http://core.svn.wordpress.org/trunk@49904 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-02-08 23:51:10 +00:00
Sergey Biryukov
9dac2542aa Block Editor: Drop Noto Serif in favor of system fonts.
This aims to improve privacy and performance of the editor.

Follow-up to [37361].

Props Joen, hellofromTonya, garrett-eclipse, aristath, noisysocks, hedgefield, pento, sabernhardt, joyously, yannkozon.
Fixes #46169.
Built from https://develop.svn.wordpress.org/trunk@50155


git-svn-id: http://core.svn.wordpress.org/trunk@49834 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-02-02 18:37:04 +00:00
desrosj
230c1c5c8a Coding Standards: Fix several minor coding standards issues.
These are made by running `composer format`.

Follow up to [50124], [50129], [50143].

See #49961, #52192, #34281.
Built from https://develop.svn.wordpress.org/trunk@50152


git-svn-id: http://core.svn.wordpress.org/trunk@49831 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-02-02 18:04:03 +00:00
Adam Silverstein
315b1c185d Users: enable admins to send users a reset password link.
Add a feature so Admins can send users a 'password reset' email. This doesn't change the password or force a password change. It only emails the user the password reset link.

The feature appears in several places:
* A "Send Reset Link" button on user profile screen.
* A "Send password reset" option in the user list bulk action dropdown.
* A "Send password reset" quick action when hovering over a username in the user list.

Props Ipstenu, DrewAPicture, eventualo, wonderboymusic, knutsp, ericlewis, afercia, JoshuaWold, johnbillion, paaljoachim, hedgefield.
Fixes #34281.


Built from https://develop.svn.wordpress.org/trunk@50129


git-svn-id: http://core.svn.wordpress.org/trunk@49808 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-02-01 22:13:03 +00:00
noisysocks
43e36a3541 Editor: Update @wordpress npm packages
Update @wordpress npm packages to the latest published versions. This means that
the block editor includes functionality that exists in Gutenberg 9.8.

See #52334.
Props isabel_brison.

Built from https://develop.svn.wordpress.org/trunk@50048


git-svn-id: http://core.svn.wordpress.org/trunk@49749 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-01-28 02:04:13 +00:00
TimothyBlynJacobs
c3b40f7f80 Site Health, App Passwords: Ensure REST API responses are properly translated.
The REST API requests in Site Health and App Passwords now include `_locale=user` in the request URL to ensure the user's locale is used instead of the site locale. Additionally, the `apiRequest` library now sends a JSON `Accept` header which is required by `determine_locale()` to respect the `_locale` query parameter.

The Site Health REST API controllers now manually load the default admin textdomain if not `is_admin()`. This allows for the Site Health tests to be translated even though the translations are part of the administration project and the REST API is not.

Props oglekler, kebbet, Clorith, TimothyBlynJacobs, ocean90, SergeyBiryukov, adamsilverstein.
Fixes #51871.

Built from https://develop.svn.wordpress.org/trunk@49716


git-svn-id: http://core.svn.wordpress.org/trunk@49439 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-12-01 03:44:05 +00:00
Andrew Ozz
e261cf0d1e External Libraries: Update jQuery Migrate to 3.3.2.
Props mgol, azaozz.
Fixes #50564.
Built from https://develop.svn.wordpress.org/trunk@49649


git-svn-id: http://core.svn.wordpress.org/trunk@49386 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-11-18 09:06:06 +00:00
Sergey Biryukov
7712866212 Script Loader: Correct version for jQuery Migrate.
Follow-up to [49338].

See #51621, #50564.
Built from https://develop.svn.wordpress.org/trunk@49615


git-svn-id: http://core.svn.wordpress.org/trunk@49353 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-11-16 21:36:05 +00:00
TimothyBlynJacobs
74969e7fbe App Passwords: Further accessibility improvements.
- Add a label to the readonly password input.
- Handle focus loss after revoking app passwords.
- Handle focus loss after dismissing notices.
- Mark app name as `aria-required`.
- Use `aria-label` for detailed revoke button text instead of `title`.
- Use `-1` for `tabindex` instead of `0`.

Props alexstine, afercia, sabernhardt, audrasjb, joedolson, TimothyBlynJacobs.
Fixes #51580.

Built from https://develop.svn.wordpress.org/trunk@49549


git-svn-id: http://core.svn.wordpress.org/trunk@49287 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-11-09 18:05:08 +00:00
desrosj
3c1961faa1 External Libraries: Update React, ReactDOM and Lodash.
This updates:
- `react` and `react-dom` from `16.9.0` to `16.13.1`.
- `lodash from `4.17.15` to `4.17.19`.

Props isabel_brison.
Fixes #51505.
Built from https://develop.svn.wordpress.org/trunk@49165


git-svn-id: http://core.svn.wordpress.org/trunk@48927 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-10-15 23:08:26 +00:00
TimothyBlynJacobs
039ce3f16f Site Health, REST API: Move async tests to REST API endpoints.
This provides more flexibility when writing tests and benefits from running in a front-end context which is necessary for some tests like checking that updates are supported. Additionally, this provides a more robust interface for developers who want to integrate with Site Health tests.

Because the `wp/v2` endpoint is reserved for modeling core entities, site health is registered in its own `wp-site-health/v1` namespace.

The existing ajax actions have been maintained for backward compatibility.

Props Clorith, chrisvanpatten, afragen, pokhriyal, TimothyBlynJacobs.
Fixes #48105.

Built from https://develop.svn.wordpress.org/trunk@49154


git-svn-id: http://core.svn.wordpress.org/trunk@48916 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-10-15 02:00:08 +00:00
Dominik Schilling
c6f7e0f155 I18N: Use wp.i18n for translatable strings in wp-admin/js/dashboard.js.
* Deprecate the `l10n` property on `communityEventsData`.
* Introduce `version` parameter for `deprecateL10nObject` and backfill the version for deprecated objects in 5.5.0.
* Add a noop version of `deprecateL10nObject` for QUnit testing.

Fixes #51498.
Built from https://develop.svn.wordpress.org/trunk@49151


git-svn-id: http://core.svn.wordpress.org/trunk@48913 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-10-14 21:13:08 +00:00
iandunn
bb67dde689 Community Events: Apply coding standards.
The previous commits intentionally didn't include these, because it would have added an unreasonable amount of diff noise.

See #51130

Built from https://develop.svn.wordpress.org/trunk@49147


git-svn-id: http://core.svn.wordpress.org/trunk@48909 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-10-14 18:23:04 +00:00
iandunn
5bf0005827 Community Events: Display dates and times in the user's time zone.
Fixes #51130
Props sippis, hlashbrooke, audrasjb, Rarst, iandunn

Built from https://develop.svn.wordpress.org/trunk@49146


git-svn-id: http://core.svn.wordpress.org/trunk@48908 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-10-14 18:21:06 +00:00
TimothyBlynJacobs
d5ebe12f11 REST API: Introduce Application Passwords for API authentication.
In WordPress 4.4 the REST API was first introduced. A few releases later in WordPress 4.7, the Content API endpoints were added, paving the way for Gutenberg and countless in-site experiences. In the intervening years, numerous plugins have built on top of the REST API. Many developers shared a common frustration, the lack of external authentication to the REST API.

This commit introduces Application Passwords to allow users to connect to external applications to their WordPress website. Users can generate individual passwords for each application, allowing for easy revocation and activity monitoring. An authorization flow is introduced to make the connection flow simple for users and application developers.

Application Passwords uses Basic Authentication, and by default is only available over an SSL connection.

Props georgestephanis, kasparsd, timothyblynjacobs, afercia, akkspro, andraganescu, arippberger, aristath, austyfrosty, ayesh, batmoo, bradyvercher, brianhenryie, helen, ipstenu, jeffmatson, jeffpaul, joostdevalk, joshlevinson, kadamwhite, kjbenk, koke, michael-arestad, Otto42, pekz0r, salzano, spacedmonkey, valendesigns.
Fixes #42790.

Built from https://develop.svn.wordpress.org/trunk@49109


git-svn-id: http://core.svn.wordpress.org/trunk@48871 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-10-08 22:14:06 +00:00
noisysocks
92f3ef5980 Tests: Fix dependency tests
Fixes test_block_styles_for_editing_with_theme_support and
test_block_styles_for_viewing_with_theme_support by partially reverting [49102]
and only calling wp_should_load_block_editor_scripts_and_styles() when on an
admin screen.

Props TimothyBlynJacobs.
See #51330.

Built from https://develop.svn.wordpress.org/trunk@49104


git-svn-id: http://core.svn.wordpress.org/trunk@48866 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-10-08 03:36:04 +00:00
noisysocks
0dc073e589 Editor: Only call should_load_block_editor_scripts_and_styles on admin screens
Do not call the should_load_block_editor_scripts_and_styles filter on non-admin
screens. This makes it less likely that one will accidentally call
get_current_screen() when it doesn't exist.

Follow-up to [49080].
Props noahtallen.
See #51330.

Built from https://develop.svn.wordpress.org/trunk@49102


git-svn-id: http://core.svn.wordpress.org/trunk@48864 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-10-08 01:21:07 +00:00
Andrew Ozz
5cee7eced0 Update jQuery step two:
- Add jquery-migrate.js v.3.3.1 to core and load it in debug mode when `SCRIPT_DEBUG` is true.
- Add jquery.min.js, update jquery.js to 3.5.1 non-minified. This should help when debugging.
- Rebuild jQuery UI 1.12.1 and add it to core.
- Fix/adjust tests to match the above changes.

See #50564.
Built from https://develop.svn.wordpress.org/trunk@49101


git-svn-id: http://core.svn.wordpress.org/trunk@48863 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-10-07 16:33:25 +00:00
noisysocks
274cb9718d Editor: Rename _should_load_block_editor_scripts_and_styles to wp_should_load_block_editor_scripts_and_styles
Follow-up to [49080].
Props zieladam, frank-klein.
See #51330.

Built from https://develop.svn.wordpress.org/trunk@49093


git-svn-id: http://core.svn.wordpress.org/trunk@48855 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-10-06 04:18:10 +00:00
Helen Hou-Sandí
e9d572f431 WP Date: Add timezone abbreviation to wp-date settings.
Props mkaz.
Fixes #50624.

Built from https://develop.svn.wordpress.org/trunk@49083


git-svn-id: http://core.svn.wordpress.org/trunk@48845 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-10-01 17:43:08 +00:00
Sergey Biryukov
0d52ba511c Docs: Add missing @since entry for _should_load_block_editor_scripts_and_styles().
Follow-up to [49080].

See #51330.
Built from https://develop.svn.wordpress.org/trunk@49081


git-svn-id: http://core.svn.wordpress.org/trunk@48843 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-10-01 01:14:04 +00:00
noisysocks
96f963a2b9 Editor: Add should_load_block_editor_scripts_and_styles
Adds a new should_load_block_editor_scripts_and_styles filter which can be used
by plugins including Gutenberg to more precisely customise when block editor
scripts and styles should be loaded by script-loader.php. Previously, plugins
had to fiddle with $current_screen->is_block_editor(). 

Props zieladam.
See #51330.

Built from https://develop.svn.wordpress.org/trunk@49080


git-svn-id: http://core.svn.wordpress.org/trunk@48842 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-10-01 00:39:04 +00:00
Sergey Biryukov
ca7063fd60 Script Loader: Update versions for MediaElement.js and related files.
Follow-up to [49070].

See #51315.
Built from https://develop.svn.wordpress.org/trunk@49079


git-svn-id: http://core.svn.wordpress.org/trunk@48841 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-10-01 00:04:05 +00:00
Sergey Biryukov
d5b8d282e8 Docs: Update the URL for PHP date formats table in translator comments.
Props hareesh-pillai, iandunn.
Fixes #51332.
Built from https://develop.svn.wordpress.org/trunk@48991


git-svn-id: http://core.svn.wordpress.org/trunk@48753 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-09-18 10:37:08 +00:00
Sergey Biryukov
68dfbf51d9 Script Loader: Add backward compatibility for JavaScript i18n globals and properties deprecated in WordPress 5.5.
The recommended approach for any plugins using these globals or properties is to switch to the newer `wp.i18n` functions.

In the meantime, this ensures that accessing any of these globals does not break the rest of the code on the page, and an appropriate warning message is logged to the JavaScript console.

Follow-up to: https://core.trac.wordpress.org/query?summary=~wp.i18n&milestone=5.5

Props omarreiss, peterwilsoncc, kbjohnson90, johnbillion, TimothyBlynJacobs, joostdevalk, ocean90, desrosj, SergeyBiryukov.
Fixes #51123.
Built from https://develop.svn.wordpress.org/trunk@48923


git-svn-id: http://core.svn.wordpress.org/trunk@48685 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-31 20:30:03 +00:00
Sergey Biryukov
4c4952d3f9 Script Loader: Change the jquery handle back to an alias for jquery-core.
This ensures that `wp_localize_script( 'jquery', ... )` continues to work as expected, since `WP_Scripts::localize()` rewrites the `jquery` handle to `jquery-core` internally.

Follow-up to [48323].

Props mukesh27, rajeshsingh520, johnbillion, TimothyBlynJacobs, TobiasBg.
Fixes #50919.
Built from https://develop.svn.wordpress.org/trunk@48890


git-svn-id: http://core.svn.wordpress.org/trunk@48652 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-27 20:33:04 +00:00
Andrew Ozz
283f841dac Script Loader: Remove the jquery-migrate-compat-5.5 temporary script handle for now. Can be re-added later if there is a compelling use case. For now it doesn't seem necessary.
See #37110.
Built from https://develop.svn.wordpress.org/trunk@48754


git-svn-id: http://core.svn.wordpress.org/trunk@48516 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-07 18:30:06 +00:00
Sergey Biryukov
ddcf09ace3 Script Loader: Add a temporary jquery-migrate-compat-5.5 script handle.
This is intended as an easy way for plugins and themes to still be able to load jQuery with jQuery Migrate in WordPress 5.5.

Once jQuery is updated to 3.x, this temporary script handle will be removed. This means plugins and themes still using it at that point will fail to load their scripts (as a dependency will be missing), but will not cause "fatal errors" breaking the rest of JS.

Follow-up to [48323], [48324].

Props azaozz, desrosj, apedog, Clorith, jorbin.
Fixes #37110.
Built from https://develop.svn.wordpress.org/trunk@48753


git-svn-id: http://core.svn.wordpress.org/trunk@48515 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-07 16:51:06 +00:00
John Blackbourn
1fbcdb2213 Docs: Various corrections to inline docblocks.
See #49572
Built from https://develop.svn.wordpress.org/trunk@48573


git-svn-id: http://core.svn.wordpress.org/trunk@48335 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-23 00:48:06 +00:00
desrosj
3dda74c337 Editor: Ensure the required assets for the block directory are enqueued.
This fixes an issue where the block directory appears unstyled due to the stylesheets not being enqueued.

Props ryelle, timothyblynjacobs, earnjam.
Fixes #50661.
Built from https://develop.svn.wordpress.org/trunk@48537


git-svn-id: http://core.svn.wordpress.org/trunk@48299 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-21 15:38:03 +00:00
Dominik Schilling
4377e9a44e I18N: Use wp.i18n for translatable strings in wp-admin/js/set-post-thumbnail.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90.
See #20491.
Fixes #50605.
Built from https://develop.svn.wordpress.org/trunk@48396


git-svn-id: http://core.svn.wordpress.org/trunk@48165 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 18:55:04 +00:00
Dominik Schilling
0dc81cc24f I18N: Use wp.i18n for translatable strings in wp-admin/js/comment.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90.
See #20491.
Fixes #50604.
Built from https://develop.svn.wordpress.org/trunk@48395


git-svn-id: http://core.svn.wordpress.org/trunk@48164 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 18:40:05 +00:00
Dominik Schilling
291f3d76ec I18N: Use wp.i18n for translatable strings in wp-admin/js/nav-menu.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90.
See #20491.
Fixes #50603.
Built from https://develop.svn.wordpress.org/trunk@48394


git-svn-id: http://core.svn.wordpress.org/trunk@48163 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 18:31:05 +00:00
Dominik Schilling
ac4f93a5be I18N: Use wp.i18n for translatable strings in wp-admin/js/plugin-install.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90.
See #20491.
Fixes #50602.
Built from https://develop.svn.wordpress.org/trunk@48392


git-svn-id: http://core.svn.wordpress.org/trunk@48161 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 18:15:03 +00:00
Dominik Schilling
daf060bbd2 I18N: Use wp.i18n for translatable strings in wp-admin/js/inline-edit-post.js and wp-admin/js/inline-edit-tax.js.
This removes the usage of `wp_localize_script()` for passing translations to the scripts and instead adds the translatable strings in the scripts directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90.
See #20491.
Fixes #50601.
Built from https://develop.svn.wordpress.org/trunk@48391


git-svn-id: http://core.svn.wordpress.org/trunk@48160 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 18:02:05 +00:00
Dominik Schilling
4a21cda313 I18N: Use wp.i18n for translatable strings in wp-admin/js/widgets.js.
This removes the usage of `$scripts->add_inline_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Fixes #50600.
Built from https://develop.svn.wordpress.org/trunk@48387


git-svn-id: http://core.svn.wordpress.org/trunk@48156 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 17:01:06 +00:00
Dominik Schilling
2b32883f8b I18N: Use wp.i18n for translatable strings in wp-admin/js/post.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90.
See #20491.
Fixes #50599.
Built from https://develop.svn.wordpress.org/trunk@48385


git-svn-id: http://core.svn.wordpress.org/trunk@48154 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 16:49:05 +00:00
Dominik Schilling
964c506fb3 I18N: Use wp.i18n for translatable strings in wp-admin/js/media.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90.
See #20491.
Fixes #50597.
Built from https://develop.svn.wordpress.org/trunk@48384


git-svn-id: http://core.svn.wordpress.org/trunk@48153 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 16:14:06 +00:00
Dominik Schilling
7e7b70cd1a I18N: Use wp.i18n for translatable strings in wp-admin/js/color-picker.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90.
See #20491.
Fixes #50596.
Built from https://develop.svn.wordpress.org/trunk@48383


git-svn-id: http://core.svn.wordpress.org/trunk@48152 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 16:10:05 +00:00
Andrea Fercia
aee4324b9e Accessibility: Media: Improve accessibility of the status and error messages in the Image Editor.
- improves focus management by moving focus to the notices, if any, or to the first "tabbable" element
- this avoids a focus loss and helps Braille-only and screen magnification users to be aware of the messages
- adds an ARIA role `alert` to all the notices 
- uses `wp.a11y.speak()` to announce messages to assistive technology
- this way, all visual users will see the messages while assistive technology users will get an audible message
- uses `wp.i18n` for translatable strings in `wp-admin/js/image-edit.js`

Props anevins, ryanshoover, antpb, SergeyBiryukov, afercia.
See #20491.
Fixes #47147.

Built from https://develop.svn.wordpress.org/trunk@48375


git-svn-id: http://core.svn.wordpress.org/trunk@48144 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 13:45:02 +00:00
Andrea Fercia
22d0cd6c96 Accessibility: Allow post boxes on the Dashboard and Classic Editor pages to be reordered by using the keyboard.
So far, it has been possible to rearrange into a new order the post boxes (also known as "widgets" on the Dashboard and "meta boxes" on the Edit post page) only by using a pointing device, for example a mouse.

This change adds new controls and functionality to allow the boxes to be rearranged also with the keyboard. Additionally, audible messages are sent to the admin ARIA live region to notify screen reader users of the reorder action result.

Props joedolson, anevins, antpb, audrasjb, xkon, MarcoZ, karmatosed, afercia.
Fixes #39074.

Built from https://develop.svn.wordpress.org/trunk@48373


git-svn-id: http://core.svn.wordpress.org/trunk@48142 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 13:00:02 +00:00
Dominik Schilling
3d95a45675 I18N: Use wp.i18n for translatable strings in wp-admin/js/tags-box.js and wp-admin/js/tags-suggest.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90.
See #20491.
Fixes #50579.
Built from https://develop.svn.wordpress.org/trunk@48350


git-svn-id: http://core.svn.wordpress.org/trunk@48119 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 21:00:03 +00:00
Dominik Schilling
1145607a85 I18N: Use wp.i18n for translatable strings in wp-admin/js/edit-comments.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90.
See #20491.
Fixes #50578.
Built from https://develop.svn.wordpress.org/trunk@48348


git-svn-id: http://core.svn.wordpress.org/trunk@48117 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 20:17:02 +00:00
Dominik Schilling
31d93c553a I18N: Use wp.i18n for translatable strings in wp-admin/js/tags.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90.
See #20491.
Fixes #50577.
Built from https://develop.svn.wordpress.org/trunk@48347


git-svn-id: http://core.svn.wordpress.org/trunk@48116 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 19:47:03 +00:00
Dominik Schilling
163e0ac228 I18N: Use wp.i18n for translatable strings in wp-admin/js/theme-plugin-editor.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Fixes #50576.
Built from https://develop.svn.wordpress.org/trunk@48346


git-svn-id: http://core.svn.wordpress.org/trunk@48115 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 19:35:07 +00:00
Andrea Fercia
454dab13c1 Accessibility: Administration: Improve the sortable postboxes areas on the Dashboard and Classic Editor pages.
- makes the postboxes areas in the Dashboard visible also on large screens 
- uses a more meaningful text when all postboxes areas are empty instead of "Drag boxes here"
- restores the ability to drag boxes to the "advanced" area in the Classic Editor page
- makes the postboxes areas in the Classic Editor page visible while dragging so that users have a clue what the available areas are
- improves the color contrast of the postboxes areas while dragging
- uses `wp.i18n` for translatable strings in `wp-admin/js/postbox.js`

Props xkon, karmatosed, audrasjb, ocean90, joedolson, afercia, azaozz.
See #20491.
Fixes #49288, #47541.

Built from https://develop.svn.wordpress.org/trunk@48340


git-svn-id: http://core.svn.wordpress.org/trunk@48109 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 18:03:02 +00:00
Andrew Ozz
bc54b15893 External Libraries: First step of updating jQuery. Disable jQuery Migrate 1.4.1, keep jQuery at 1.12.4-wp, and UI at 1.11.4. Also keep the jquery-core script handle for full backwards compatibility.
Props jorbin, adamsilverstein, westonruter, retlehs, pento, onokazu, galbaras, netweb, zakkath, dmethvin, LittleBigThing, markgoho, iandunn, remzicavdar, bigcloudmedia, jacklinkers, levdbas, a4jpcom, azaozz.

See #37110.
Built from https://develop.svn.wordpress.org/trunk@48323


git-svn-id: http://core.svn.wordpress.org/trunk@48092 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-05 18:28:04 +00:00
Andrew Ozz
86317e3e85 Media: Show an error message when a .heic file is uploaded that this type of files cannot be displayed in a web browser and suggesting to convert to JPEG. The message is shown by using filters, plugins that want to handle uploading of .heic files can remove it.
Props mattheweppelsheimer, mikeschroder, jeffr0, andraganescu, desrosj, azaozz.
Fixes #42775.
Built from https://develop.svn.wordpress.org/trunk@48288


git-svn-id: http://core.svn.wordpress.org/trunk@48057 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-03 23:15:03 +00:00
Dominik Schilling
718626a8ce I18N: Use wp.i18n for translatable strings in wp-includes/js/wp-auth-check.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90.
See #20491.
Fixes #50553.
Built from https://develop.svn.wordpress.org/trunk@48285


git-svn-id: http://core.svn.wordpress.org/trunk@48054 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-03 19:05:03 +00:00
Sergey Biryukov
25fb9a9d3a Script Loader: Restore correct versions for Masonry and imagesLoaded.
These libraries were previously updated in [48038], but some changes were accidentally reverted in [48267].

Props kebbet.
See #50526.
Built from https://develop.svn.wordpress.org/trunk@48276


git-svn-id: http://core.svn.wordpress.org/trunk@48045 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-02 13:10:08 +00:00
Sergey Biryukov
07d2c8a4e9 I18N: Use wp.i18n for translatable strings in wp-admin/js/privacy-tools.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90, afercia.
See #20491.
Fixes #50535.
Built from https://develop.svn.wordpress.org/trunk@48274


git-svn-id: http://core.svn.wordpress.org/trunk@48043 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-02 11:11:06 +00:00
Dominik Schilling
2fab13ae3e I18N: Use wp.i18n for translatable strings in wp-admin/js/user-profile.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90.
See #20491.
Fixes #50527.
Built from https://develop.svn.wordpress.org/trunk@48270


git-svn-id: http://core.svn.wordpress.org/trunk@48039 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-01 20:38:01 +00:00
Andrea Fercia
87756494cc Media: Enable JavaScript translations for the media-views script after [48232].
See #48463.

Built from https://develop.svn.wordpress.org/trunk@48268


git-svn-id: http://core.svn.wordpress.org/trunk@48037 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-01 20:21:06 +00:00
Dominik Schilling
77b2440f9f I18N: Use wp.i18n for translatable strings in wp-admin/js/common.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90.
See #20491.
Fixes #50526.
Built from https://develop.svn.wordpress.org/trunk@48267


git-svn-id: http://core.svn.wordpress.org/trunk@48036 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-01 19:50:02 +00:00
Dominik Schilling
d686fa266b I18N: Use wp.i18n for translatable strings in wp-includes/js/wp-pointer.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90.
See #20491.
Fixes #50525.
Built from https://develop.svn.wordpress.org/trunk@48266


git-svn-id: http://core.svn.wordpress.org/trunk@48035 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-01 19:30:02 +00:00
Andrea Fercia
45d19872fc Accessibility: Media: Fix the Image Editor mismatching keyboard focus order and visual reading order.
Swaps the DOM order of the two main columns within the admin Image Editor.

When the sequence in which content is presented affects its meaning and the navigation sequences affect meaning or operation, visual order and DOM order must match. See WCAG 2.1 Success Criterion 1.3.2 Meaningful Sequence and Success Criterion 2.4.3 Focus Order.

Props sabernhardt, anevins, audrasjb, afercia.
Fixes #47136.

Built from https://develop.svn.wordpress.org/trunk@48265


git-svn-id: http://core.svn.wordpress.org/trunk@48034 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-01 14:29:01 +00:00
Andrea Fercia
eebf187963 Accessibility: Media: Add a "Copy URL" button to the attachment File URL fields.
For a number of years, various screens in the WordPress admin provided users with a readonly input field to copy the attachment file URL. Manually copying from a readonly field is an annoying task at best even for mouser users. It's a usability and accessibility issue at the same time. 
These fields now have a new "Copy URL" button that is easy to use and accessible to everyone.

Props theolg, markdubois, vabrashev, sajjad67, xkon, nrqsnchz, melchoyce, audrasjb, afercia.
See #41612, #50322, #50335.
Fixes #48463.

Built from https://develop.svn.wordpress.org/trunk@48232


git-svn-id: http://core.svn.wordpress.org/trunk@48001 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-06-30 13:16:04 +00:00
desrosj
c5b1a12a55 General: Rename (add|remove)_option_allowed_list() to (add|remove)_allowed_option().
The new names make the purpose more clear. It also adds consistency with the `$allowed_options` global variable.

Also in this change, the `wp-deprecated` dependency has been removed from the password strength meter in favor of a `window.console.log()` call to avoid adding 3 dependencies for one deprecated notice.

Props SergeyBiryukov, ocean90, desrosj
Fixes #50413.
Built from https://develop.svn.wordpress.org/trunk@48142


git-svn-id: http://core.svn.wordpress.org/trunk@47911 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-06-23 18:54:16 +00:00
desrosj
4b60af1a6a General: Remove “whitelist” and “blacklist” in favor of more clear and inclusive language.
“The WordPress open source community cares about diversity. We strive to maintain a welcoming environment where everyone can feel included.”

With this commit, all occurrences of “whitelist” and “blacklist” (with the single exception of the `$new_whitelist_options` global variable) are removed. A new ticket has been opened to explore renaming the `$new_whitelist_options` variable (#50434).

Changing to more specific names or rewording sentences containing these terms not only makes the code more inclusive, but also helps provide clarity. These terms are often ambiguous. What is being blocked or allowed is not always immediately clear. This can make it more difficult for non-native English speakers to read through the codebase.

Words matter. If one contributor feels more welcome because these terms are removed, this was worth the effort.

Props strangerstudios, jorbin, desrosj, joemcgill, timothyblynjacobs, ocean90, ayeshrajans, davidbaumwald, earnjam.
See #48900, #50434.
Fixes #50413.
Built from https://develop.svn.wordpress.org/trunk@48121


git-svn-id: http://core.svn.wordpress.org/trunk@47890 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-06-22 17:26:13 +00:00
Sergey Biryukov
d81302511d External Libraries: Update Moment.js to 2.26.0.
Changelog: https://github.com/moment/moment/compare/2.22.2...2.26.0

This commit also fixes a deprecation warning regarding the usage of `moment.locale()` to set locale properties.

As of Moment.js 2.12.0, `moment.locale()` is deprecated and `moment.updateLocale()` should be used instead.

Additionally, minimize `moment.js` as part of build process to remove the source map reference.

This avoids a `sourceMappingURL` being in the minified file, as we don't ship source maps.

Props yoancutillas, SergeyBiryukov.
Fixes #50408.
Built from https://develop.svn.wordpress.org/trunk@48075


git-svn-id: http://core.svn.wordpress.org/trunk@47842 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-06-17 17:40:27 +00:00
Sergey Biryukov
de59ad23a4 Docs: Consistently include an empty line between @since tag and @see, @link, or @global, per the documentation standards.
See #49572.
Built from https://develop.svn.wordpress.org/trunk@48067


git-svn-id: http://core.svn.wordpress.org/trunk@47834 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-06-16 21:07:14 +00:00
whyisjake
bdb1fe0d7e Administration: Remove wp-auth-check from the Heartbeat API.
As of [27153], wp-auth-check is returned on all heartbeats without the need for data from client-side. This also means that the timing and scheduling of this request data is ineffectual.

Fixes #50305.

Props dsixinetu, azaozz, whyisjake.


Built from https://develop.svn.wordpress.org/trunk@48056


git-svn-id: http://core.svn.wordpress.org/trunk@47823 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-06-16 07:09:09 +00:00
Sergey Biryukov
e6ee3f742e External Libraries: Update Masonry to 4.2.2 and imagesLoaded to 4.1.4.
Notable changes include dropping support for IE 8 & 9, which are no longer supported by WordPress core either.

Release notes:
https://github.com/desandro/masonry/releases
https://github.com/desandro/imagesloaded/releases

Changelogs:
https://github.com/desandro/masonry/compare/v3.3.2...v4.2.2
https://github.com/desandro/imagesloaded/compare/v3.2.0...v4.1.4

Props pierlo, hareesh-pillai, grapplerulrich, pderksen, desrosj, garrett-eclipse, SergeyBiryukov.
Fixes #37675, #48031.
Built from https://develop.svn.wordpress.org/trunk@48038


git-svn-id: http://core.svn.wordpress.org/trunk@47805 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-06-13 18:53:27 +00:00
Dominik Schilling
ba92ed7615 I18N: Use wp.i18n for translatable strings in wp-admin/js/updates.js.
This removes the usage of `wp_localize_script()` for passing translations to the script and instead adds the translatable strings in the script directly through the use of `wp.i18n` and its utilities.

Props swissspidy, ocean90.
See #20491.
Fixes #50235.
Built from https://develop.svn.wordpress.org/trunk@47884


git-svn-id: http://core.svn.wordpress.org/trunk@47658 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-06-01 21:41:09 +00:00
whyisjake
661b929e1e Security: Add user interface to auto-update themes and plugins.
Building on core update mechanisms, this adds the ability to enable automatic updates for themes and plugins to the WordPress admin. 

Fixes: #50052.
Props: afercia, afragen, audrasjb, azaozz, bookdude13, davidperonne, desrosj, gmays, gmays, javiercasares, karmatosed, knutsp, mapk, mukesh27, netweb, nicolaskulka, nielsdeblaauw, paaljoachim, passoniate, pbiron, pedromendonca, whodunitagency, whyisjake, wpamitkumar, and xkon.

Built from https://develop.svn.wordpress.org/trunk@47835


git-svn-id: http://core.svn.wordpress.org/trunk@47611 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-05-20 18:49:09 +00:00
Dominik Schilling
7ded6c2d2a Administration: Remove any CSS related to Internet Explorer versions 6 – 10.
In WordPress 3.2 support for IE6 was dropped, IE7 followed a few versions later. With the 4.8 release, WordPress officially ended support for Internet Explorer versions 8, 9, and 10. Yet, we still have shipped CSS for the unsupported IE versions....until now! Goodbye to ie.css and star hacks!

* Removes ie.css and `ie` style handle.
* Removes IE specific class names and any related CSS.
* Drops support for IE8 and older in `wp_customize_support_script()`.
* Updates compatibility mode for CSS minification to `ie11`.

Props ayeshrajans, isabel_brison, afercia, netweb, peterwilsoncc, ocean90.
Fixes #17232, #46015.
Built from https://develop.svn.wordpress.org/trunk@47771


git-svn-id: http://core.svn.wordpress.org/trunk@47547 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-05-06 20:15:07 +00:00
Sergey Biryukov
87b3b38242 Privacy: Add an indication when the Copy action in Privacy Policy Guide is complete.
This adds a "Copied!" text near the "Copy this section to clipboard" button to provide direct feedback that the action was completed.

Props garrett-eclipse, nickylimjj, xkon, desrosj, birgire.
Fixes #44588.
Built from https://develop.svn.wordpress.org/trunk@47572


git-svn-id: http://core.svn.wordpress.org/trunk@47347 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-04-12 14:26:11 +00:00
jorgefilipecosta
cf40905ada Scripts: Use core-js url as polyfill for window.URL.
URL polyfill from the polyfill-library library is not spec-conformant, in a way which negatively impacts its usability for pending revisions to the block editor. Specifically, there were revisions to the implementation of the wp-url script to detect URL validity by relying on thrown errors from the URL constructor, but this specific behavior is not implemented in this version of the polyfill.
There was another issue in r47238, which is that the test used to check whether the polyfill should be included is not accurate. This commit uses a different check and fixes the issue.

Props aduth.
Fixes: #49360.
Built from https://develop.svn.wordpress.org/trunk@47416


git-svn-id: http://core.svn.wordpress.org/trunk@47203 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-03-03 16:55:07 +00:00
Sergey Biryukov
556c6d80d8 Script Loader: Remove unnecessary reference sign from function definitions in script loader.
This resolves PHP warnings when extensions like `php_uopz` or `php_tideways_xhprof` are in use.

Object variables in PHP 5+ contain a reference to the object, and it's the reference that's passed around.

Props jqz, killerbishop, Mte90, TJNowell, jorbin, pento, pcarvalho, valentinbora, SergeyBiryukov.
Fixes #44979.
Built from https://develop.svn.wordpress.org/trunk@47355


git-svn-id: http://core.svn.wordpress.org/trunk@47142 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-25 00:59:06 +00:00
Sergey Biryukov
3209729f5f Accessibility: Widgets: Restore missing string in script loader.
The string was previously added in [42794] and accidentally removed in [44163].

Props garrett-eclipse, audrasjb.
Fixes #49505.
Built from https://develop.svn.wordpress.org/trunk@47353


git-svn-id: http://core.svn.wordpress.org/trunk@47140 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-24 23:07:09 +00:00
Andrew Ozz
50be657d81 Build Tools:
- Update the DependencyExtractionWebpackPlugin to 2.3.0 and set it to output a single assets file.
- Grunt: copy the assets file to both `SOURCE_DIR` and `BUILD_DIR` as `wp-includes/assets/script-loader-packages.php`.
- "Unignore" the `wp-includes/assets` directory. Its content will be committed similarly to `wp-includes/blocks`.
- Update `wp_default_packages_scripts()` to use the above file. This also removes the hard-coded lists of packages and packages with translations.

Props gziolo, pbearne, johnbillion, isabel_brison, ocean90, azaozz.
Fixes #48154.
Built from https://develop.svn.wordpress.org/trunk@47352


git-svn-id: http://core.svn.wordpress.org/trunk@47139 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-24 21:22:08 +00:00
Andrew Ozz
3d126b2dc7 Media: Improve wording for error message on failed post-processing of uploaded images.
Props eclev91, desrosj, antpb, azaozz.
Fixes #49280.
Built from https://develop.svn.wordpress.org/trunk@47259


git-svn-id: http://core.svn.wordpress.org/trunk@47059 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-11 03:20:06 +00:00
aduth
4bff827833 Script Loader: Add polyfill for window.URL, window.DOMRect.
Pending block editor revisions for WordPress 5.4 will make use of `window.URL` and `window.DOMRect`. These are not available in Internet Explorer (or pre-Chromium Edge for `DOMRect`) and must be polyfilled to avoid script errors.

The changes make use of the existing polyfill pattern, and existing `polyfill-library` dependency. The dependency is bumped to the latest version, since the previous version did not include the `DOMRect` polyfill.

Props jorgefilipecosta.
Fixes #49360.

Built from https://develop.svn.wordpress.org/trunk@47238


git-svn-id: http://core.svn.wordpress.org/trunk@47038 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-10 15:17:07 +00:00
Sergey Biryukov
a6949956d1 Administration: Capitalize Trash consistently in various messages and comments.
When used as a noun referring to the "virtual" place, `Trash` should be capitalized.

Props garrett-eclipse, aandrewdixon, Presskopp.
Fixes #45317.
Built from https://develop.svn.wordpress.org/trunk@47233


git-svn-id: http://core.svn.wordpress.org/trunk@47033 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-10 04:12:07 +00:00
Sergey Biryukov
641c632b0c Coding Standards: Use Yoda conditions where appropriate.
See #49222.
Built from https://develop.svn.wordpress.org/trunk@47219


git-svn-id: http://core.svn.wordpress.org/trunk@47019 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-09 16:55:09 +00:00
jorgefilipecosta
d69005e1d8 Block Editor: Update WordPress Packages.
The following package versions were changed:
@wordpress/a11y: 2.6.0 -> 2.7.0
@wordpress/annotations: 1.10.0 -> 1.11.0
@wordpress/api-fetch: 3.9.0 -> 3.10.0
@wordpress/autop: 2.5.1 -> 2.6.0
@wordpress/blob: 2.6.0 -> 2.7.0
@wordpress/block-directory: 1.3.0 -> 1.4.0
@wordpress/block-editor: 3.5.0 -> 3.6.0
@wordpress/block-library: 2.12.0 -> 2.13.0
@wordpress/block-serialization-default-parser: 3.4.1 -> 3.5.0
@wordpress/blocks: 6.10.0 -> 6.11.0
@wordpress/components: 9.0.0 -> 9.1.0
@wordpress/compose: 3.10.0 -> 3.11.0
@wordpress/core-data: 2.10.0 -> 2.11.0
@wordpress/custom-templated-path-webpack-plugin: 1.5.0 -> 1.6.0
@wordpress/data: 4.12.0 -> 4.13.0
@wordpress/data-controls: 1.6.0 -> 1.7.0
@wordpress/date: 3.7.0 -> 3.8.0
@wordpress/dependency-extraction-webpack-plugin: 2.1.0 -> 2.2.0
@wordpress/deprecated: 2.6.1 -> 2.7.0
@wordpress/dom: 2.7.0 -> 2.8.0
@wordpress/dom-ready: 2.6.0 -> 2.7.0
@wordpress/e2e-test-utils: 4.1.0 -> 4.2.0
@wordpress/edit-post: 3.11.0 -> 3.12.0
@wordpress/editor: 9.10.0 -> 9.11.0
@wordpress/element: 2.10.0 -> 2.11.0
@wordpress/escape-html: 1.6.0 -> 1.7.0
@wordpress/format-library: 1.12.0 -> 1.13.0
@wordpress/hooks: 2.6.0 -> 2.7.0
@wordpress/html-entities: 2.5.0 -> 2.6.0
@wordpress/i18n: 3.8.0 -> 3.9.0
@wordpress/is-shallow-equal: 1.7.0 -> 1.8.0
@wordpress/keyboard-shortcuts: 0.2.0 -> 1.0.0
@wordpress/keycodes: 2.8.0 -> 2.9.0
@wordpress/library-export-default-webpack-plugin: 1.5.0 -> 1.6.0
@wordpress/list-reusable-blocks: 1.11.0 -> 1.12.0
@wordpress/media-utils: 1.5.0 -> 1.6.0
@wordpress/notices: 1.11.0 -> 1.12.0
@wordpress/nux: 3.10.0 -> 3.11.0
@wordpress/plugins: 2.10.0 -> 2.11.0
@wordpress/priority-queue: 1.4.0 -> 1.5.0
@wordpress/redux-routine: 3.6.2 -> 3.7.0
@wordpress/rich-text: 3.10.0 -> 3.11.0
@wordpress/scripts: 6.2.0 -> 7.0.0
@wordpress/server-side-render: 1.6.0 -> 1.7.0
@wordpress/shortcode: 2.5.0 -> 2.6.0
@wordpress/token-list: 1.8.0 -> 1.9.0
@wordpress/url: 2.9.0 -> 2.10.0
@wordpress/viewport: 2.11.0 -> 2.12.0
@wordpress/wordcount: 2.6.2 -> 2.7.0
Added these new packages:
@wordpress/warning
@wordpress/primitives
@wordpress/icons
Re-added keyboard-shortcuts to script loader removed by mistake on revision 47198.

Props gziolo, itsjonq, youknowriad, mcsf, andraganescu.
Fixes #49358.
Built from https://develop.svn.wordpress.org/trunk@47199


git-svn-id: http://core.svn.wordpress.org/trunk@46999 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-06 21:03:31 +00:00
Sergey Biryukov
47ed56f38f Code Modernization: Replace dirname( __FILE__ ) calls with __DIR__ magic constant.
This avoids the performance overhead of the function call every time `dirname( __FILE__ )` was used instead of `__DIR__`.

This commit also includes:

* Removing unnecessary parentheses from `include`/`require` statements. These are language constructs, not function calls.
* Replacing `include` statements for several files with `require_once`, for consistency:
 * `wp-admin/admin-header.php`
 * `wp-admin/admin-footer.php`
 * `wp-includes/version.php`

Props ayeshrajans, desrosj, valentinbora, jrf, joostdevalk, netweb.
Fixes #48082.
Built from https://develop.svn.wordpress.org/trunk@47198


git-svn-id: http://core.svn.wordpress.org/trunk@46998 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-06 06:33:11 +00:00
Sergey Biryukov
11fb46d4c6 Editor: Remove back-compat stub for Classic Editor's old distraction-free writing mode.
The original script was deprecated in [30338] and removed in [32677].

Props Presskopp, ketuchetan.
Fixes #39448.
Built from https://develop.svn.wordpress.org/trunk@47164


git-svn-id: http://core.svn.wordpress.org/trunk@46964 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-02 04:15:03 +00:00
Sergey Biryukov
001ffe81fb Docs: Improve inline comments per the documentation standards.
Includes minor code layout fixes for better readability.

See #48303.
Built from https://develop.svn.wordpress.org/trunk@47122


git-svn-id: http://core.svn.wordpress.org/trunk@46922 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-29 00:45:18 +00:00
jorgefilipecosta
48299521c6 Block Editor: Update WordPress Packages.
The following package versions were changed:
@wordpress/a11y: 2.5.1 -> 2.6.0
@wordpress/annotations: 1.9.0 -> 1.10.0
@wordpress/api-fetch: 3.8.0 -> 3.9.0
@wordpress/blob: 2.5.1 -> 2.6.0
@wordpress/block-directory: 1.2.0 -> 1.3.0
@wordpress/block-editor: 3.4.0 -> 3.5.0
@wordpress/block-library: 2.11.0 -> 2.12.0
@wordpress/blocks: 6.9.0 -> 6.10.0
@wordpress/components: 8.5.0 -> 9.0.0
@wordpress/compose: 3.9.0 -> 3.10.0
@wordpress/core-data: 2.9.0 -> 2.10.0
@wordpress/data: 4.11.0 -> 4.12.0
@wordpress/data-controls: 1.5.0 -> 1.6.0
@wordpress/dom: 2.6.0 -> 2.7.0
@wordpress/dom-ready: 2.5.1 -> 2.6.0
@wordpress/e2e-test-utils: 4.0.0 -> 4.1.0
@wordpress/edit-post: 3.10.0 -> 3.11.0
@wordpress/editor: 9.9.0 -> 9.10.0
@wordpress/format-library: 1.11.0 -> 1.12.0
@wordpress/i18n: 3.7.0 -> 3.8.0
@wordpress/is-shallow-equal: 1.6.1 -> 1.7.0
@wordpress/keycodes: 2.7.0 -> 2.8.0
@wordpress/list-reusable-blocks: 1.10.0 -> 1.11.0
@wordpress/media-utils: 1.4.0 -> 1.5.0
@wordpress/notices: 1.10.0 -> 1.11.0
@wordpress/nux: 3.9.0 -> 3.10.0
@wordpress/plugins: 2.9.0 -> 2.10.0
@wordpress/priority-queue: 1.3.1 -> 1.4.0
@wordpress/rich-text: 3.9.0 -> 3.10.0
@wordpress/scripts: 6.1.1 -> 6.2.0
@wordpress/server-side-render: 1.5.0 -> 1.6.0
@wordpress/viewport: 2.10.0 -> 2.11.0
The following package was added:
@wordpress/keyboard-shortcuts

Props gziolo.
Fixes #49204.
Built from https://develop.svn.wordpress.org/trunk@47106


git-svn-id: http://core.svn.wordpress.org/trunk@46906 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-22 22:06:21 +00:00
Sergey Biryukov
6730b3f716 I18N: Synchronize MediaElement.js translation strings with the currently bundled version.
Some strings were previously removed in [43345] and accidentally reintroduced in [44163].

Props ramiy.
Fixes #49249. See #42139, #37453.
Built from https://develop.svn.wordpress.org/trunk@47094


git-svn-id: http://core.svn.wordpress.org/trunk@46894 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-21 02:21:05 +00:00
Sergey Biryukov
2900bb8ea7 Docs: Update links to https://secure.php.net/, they now redirect to https://www.php.net/.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47088


git-svn-id: http://core.svn.wordpress.org/trunk@46888 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-20 03:14:06 +00:00
gziolo
572f1725d9 Build Tools: do not include assets for JS dependencies that do not exist.
This is a follow-up for #48154, where we started including *.asset.php files to declare package dependencies.
This works well but creates warnings in environments where the package does not exist because WordPress was not fully built.

Props jeherve, swissspidy.

Fixes #49144.


Built from https://develop.svn.wordpress.org/trunk@47048


git-svn-id: http://core.svn.wordpress.org/trunk@46848 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-07 15:28:05 +00:00
Dominik Schilling
c89dab8c98 Media: After [46375], enable JavaScript translations for the media-views script.
See #49134.
Built from https://develop.svn.wordpress.org/trunk@47040


git-svn-id: http://core.svn.wordpress.org/trunk@46840 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-05 13:11:04 +00:00
gziolo
355c05ea71 Build Tools: Integrate DependencyExtractionWebpackPlugin in the JS build.
This patch integrates DependencyExtractionWebpackPlugin which was battle-tested in Gutenberg. 

This will greatly simplify the process of upgrading npm packages which change after every Gutenberg release. It might even useful during the WordPress release cycle as we might need to publish more often as we discover critical bugs and regressions.

Props jonsurrell, adamsilverstein, youknowriad, ocean90, netweb.

Fixes #48154. 


Built from https://develop.svn.wordpress.org/trunk@47035


git-svn-id: http://core.svn.wordpress.org/trunk@46835 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-03 13:17:24 +00:00
Sergey Biryukov
694913d65f I18N: Make the minimum input length to start searching posts in the "Insert/edit link" modal localizable.
Props Toro_Unit, birgire, miyauchi, swissspidy, ocean90.
Fixes #44662.
Built from https://develop.svn.wordpress.org/trunk@46988


git-svn-id: http://core.svn.wordpress.org/trunk@46788 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-18 01:15:03 +00:00
Sergey Biryukov
ee58f3f3d3 Coding Standards: Fix WPCS and JSHint issues in [46872].
See #47069.
Built from https://develop.svn.wordpress.org/trunk@46874


git-svn-id: http://core.svn.wordpress.org/trunk@46674 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-10 01:34:01 +00:00
Andrew Ozz
d617011afd Fix the admin toolbar js when jQuery is not present and replace the jQuery based hoverIntent.js with a native implementation. Introduces the "hoverintent" (no dependencies) package.
Props dinhtungdu, audrasjb, azaozz.
Fixes #47069.
Built from https://develop.svn.wordpress.org/trunk@46872


git-svn-id: http://core.svn.wordpress.org/trunk@46672 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-10 01:03:02 +00:00
Sergey Biryukov
a227c231a2 Block Editor: Bug fixes targeted for WordPress 5.3.1.
The list of included fixes:

- Edge scrolling issues https://github.com/WordPress/gutenberg/pull/17707
- Intermittent JavaScript issues https://github.com/WordPress/gutenberg/pull/18559
- Remove embed CollegeHumor https://github.com/WordPress/gutenberg/pull/18591 

Updated packages:

- @wordpress/block-directory@1.0.6
- @wordpress/block-editor@3.2.5
- @wordpress/block-library@2.9.6
- @wordpress/core-data@2.7.5
- @wordpress/edit-post@3.8.6
- @wordpress/editor@9.7.6
- @wordpress/format-library@1.9.5

Props youknowriad, ellatrix, epiqueras, audrasjb, gziolo, mcsf, kyliesabra.
Fixes #48884.
Built from https://develop.svn.wordpress.org/trunk@46860


git-svn-id: http://core.svn.wordpress.org/trunk@46660 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-09 17:37:10 +00:00
Sergey Biryukov
1fceddf46b Script Loader: In wp_default_packages_inline_scripts(), make sure the root URL middleware is registered before using the media middleware.
This allows for requests to retry post-processing large images using the `post-process` REST API endpoint to work as expected.

Props azaozz, mikeschroder, TimothyBlynJacobs, epiqueras, johnbillion, youknowriad.
Fixes #48542.
Built from https://develop.svn.wordpress.org/trunk@46703


git-svn-id: http://core.svn.wordpress.org/trunk@46503 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-11-11 15:10:02 +00:00
John Blackbourn
9716848c87 Block Editor: Revert [46663] which was itself an erroneous revert.
See #48502

Built from https://develop.svn.wordpress.org/trunk@46664


git-svn-id: http://core.svn.wordpress.org/trunk@46464 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-11-05 21:59:03 +00:00
John Blackbourn
13f3142222 Block Editor: Bug fixes targeted for WordPress 5.3 RC4.
Merges [46656] to the 5.3 branch.
Fixes #48502

Built from https://develop.svn.wordpress.org/trunk@46663


git-svn-id: http://core.svn.wordpress.org/trunk@46463 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-11-05 21:53:03 +00:00
jorgefilipecosta
6cdb9d0a37 Block Editor: Bug fixes targeted for WordPress 5.3 RC4.
The list of included fixes is:

https://github.com/WordPress/gutenberg/pull/18183
https://github.com/WordPress/gutenberg/pull/18194
https://github.com/WordPress/gutenberg/pull/18230
https://github.com/WordPress/gutenberg/pull/18275
https://github.com/WordPress/gutenberg/pull/18287

Updated packages:
 - @wordpress/block-editor@3.2.4
 - @wordpress/block-library@2.9.5
 - @wordpress/edit-post@3.8.5
 - @wordpress/editor@9.7.5
 - @wordpress/format-library@1.9.4

Props @aduth, @mcsf, @youknowriad, @johnbillion.
Fixes #48502.
Built from https://develop.svn.wordpress.org/trunk@46656


git-svn-id: http://core.svn.wordpress.org/trunk@46456 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-11-05 19:36:07 +00:00
desrosj
44db7e4f6f External Libraries: Revert [46634-46635].
On further investigation, Plupload changed it’s license to a non-GPL compatible license. The newest, GPL compatible version is being used already in Core.

Unprops desrosj.
See #48277.
Built from https://develop.svn.wordpress.org/trunk@46638


git-svn-id: http://core.svn.wordpress.org/trunk@46438 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-11-03 17:09:02 +00:00
desrosj
d825155631 External Libraries: Update Plupload from 2.1.9 to 2.3.6.
This change also updates the MoxieJS dependency from 1.3.5 to 1.5.7, converts Plupload to a dependency in NPM, and integrates all relevant parts into the build process.

For a full list of upstream changes, see https://github.com/moxiecode/plupload/compare/v2.1.9...v2.3.6.

Props desrosj, hareesh-pillai.
Fixes #48277.
Built from https://develop.svn.wordpress.org/trunk@46634


git-svn-id: http://core.svn.wordpress.org/trunk@46434 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-11-03 15:31:02 +00:00
John Blackbourn
057f661ce3 Docs: Miscellaneous docblock corrections.
See #48303

Built from https://develop.svn.wordpress.org/trunk@46610


git-svn-id: http://core.svn.wordpress.org/trunk@46407 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-10-28 19:48:01 +00:00
youknowriad
6a713e53bc Block Editor: Bug fixes targetted for WordPress 5.3 RC3.
The list of included fixes is:

- https://github.com/WordPress/gutenberg/pull/18108
- https://github.com/WordPress/gutenberg/pull/18051
- https://github.com/WordPress/gutenberg/pull/18106
- https://github.com/WordPress/gutenberg/pull/18102

Updated packages:
 - @wordpress/api-fetch@3.6.4
 - @wordpress/block-directory@1.0.4
 - @wordpress/block-library@2.9.4
 - @wordpress/core-data@2.7.4
 - @wordpress/data-controls@1.3.4
 - @wordpress/edit-post@3.8.4
 - @wordpress/editor@9.7.4
 - @wordpress/list-reusable-blocks@1.8.4
 - @wordpress/media-utils@1.2.4
 - @wordpress/server-side-render@1.3.4

Props desrosj.
See #48447.

Built from https://develop.svn.wordpress.org/trunk@46606


git-svn-id: http://core.svn.wordpress.org/trunk@46403 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-10-28 14:13:09 +00:00
youknowriad
21bf3bf8dd Block Editor: Update Packages that include WP 5.3 RC2 fixes.
Updated packages:
 - @wordpress/api-fetch@3.6.3
 - @wordpress/block-directory@1.0.3
 - @wordpress/block-editor@3.2.3
 - @wordpress/block-library@2.9.3
 - @wordpress/core-data@2.7.3
 - @wordpress/data-controls@1.3.3
 - @wordpress/e2e-test-utils@2.4.3
 - @wordpress/e2e-tests@1.7.3
 - @wordpress/edit-post@3.8.3
 - @wordpress/editor@9.7.3
 - @wordpress/format-library@1.9.3
 - @wordpress/list-reusable-blocks@1.8.3
 - @wordpress/media-utils@1.2.3
 - @wordpress/server-side-render@1.3.3
 - @wordpress/url@2.8.2

Props gziolo.
Fixes #48381.

Built from https://develop.svn.wordpress.org/trunk@46562


git-svn-id: http://core.svn.wordpress.org/trunk@46359 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-10-21 14:02:07 +00:00
Andrea Fercia
02810533c4 Accessibility: Script Loader: Remove jQuery as dependency of admin-bar after [46440].
A better approach needs to be explored, as there are valid concerns for potential conflicts between different jQuery versions added by themes or plugins.

See #47069.

Built from https://develop.svn.wordpress.org/trunk@46550


git-svn-id: http://core.svn.wordpress.org/trunk@46347 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-10-15 17:23:04 +00:00
jorgefilipecosta
16571b1bfb Block Editor: Update the WordPress Packages to the ones used in the Gutenberg 6.8 release.
Updated packages:
@wordpress/a11y@2.5.1
@wordpress/annotations@1.7.2
@wordpress/api-fetch@3.6.2
@wordpress/autop@2.5.1
@wordpress/babel-preset-default@4.6.2
@wordpress/blob@2.5.1
@wordpress/block-directory@1.0.2
@wordpress/block-editor@3.2.2
@wordpress/block-library@2.9.2
@wordpress/block-serialization-default-parser@3.4.1
@wordpress/block-serialization-spec-parser@3.3.1
@wordpress/blocks@6.7.2
@wordpress/components@8.3.2
@wordpress/compose@3.7.2
@wordpress/core-data@2.7.2
@wordpress/data-controls@1.3.2
@wordpress/data@4.9.2
@wordpress/deprecated@2.6.1
@wordpress/dom-ready@2.5.1
@wordpress/dom@2.5.2
@wordpress/e2e-test-utils@2.4.2
@wordpress/e2e-tests@1.7.2
@wordpress/edit-post@3.8.2
@wordpress/editor@9.7.2
@wordpress/element@2.8.2
@wordpress/escape-html@1.5.1
@wordpress/format-library@1.9.2
@wordpress/is-shallow-equal@1.6.1
@wordpress/keycodes@2.6.2
@wordpress/list-reusable-blocks@1.8.2
@wordpress/media-utils@1.2.2
@wordpress/notices@1.8.2
@wordpress/nux@3.7.2
@wordpress/plugins@2.7.2
@wordpress/priority-queue@1.3.1
@wordpress/redux-routine@3.6.2
@wordpress/rich-text@3.7.2
@wordpress/scripts@5.1.0
@wordpress/server-side-render@1.3.2
@wordpress/url@2.8.1
@wordpress/viewport@2.8.2
@wordpress/wordcount@2.6.2

Props gziolo, youknowriad.
Fixes: #48310
Built from https://develop.svn.wordpress.org/trunk@46546


git-svn-id: http://core.svn.wordpress.org/trunk@46343 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-10-15 16:17:12 +00:00
Andrea Fercia
a0a037db4d Accessibility: Script Loader: Add jQuery as dependency of admin-bar.
On the front end, themes that don't use jQuery make the admin bar fallback to the non-jQuery implementation. Some important features miss from the non-jQuery `admin-bar.js` part, for example `hoverintent` and, most importantly, the touch events for the mobile menu don't work at all.

Enqueueing jQuery is the simplest option for now. For the future, a complete rewriting of `admin-bar.js` in plain JavaScript is highly recommended.

See #47069.

Built from https://develop.svn.wordpress.org/trunk@46440


git-svn-id: http://core.svn.wordpress.org/trunk@46238 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-10-08 17:21:13 +00:00
Adam Silverstein
9fb51e962a External Libraries: upgrade mediaelement to version 4.2.13.
Upgrade `mediaelement` to the latest version. Includes a variety of bug fixes made since the 4.2.6 release; see https://github.com/mediaelement/mediaelement/releases.

Props danieliser, Hareesh Pillai.
Fixes #46681.


Built from https://develop.svn.wordpress.org/trunk@46436


git-svn-id: http://core.svn.wordpress.org/trunk@46234 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-10-08 16:06:02 +00:00
whyisjake
ea5d76fbb2 Privacy: Ensure that sending email, and remove data follow the same user experience.
Both personal data request processes should follow the same convention.

Fixes: #43974.
Props: garrett-eclipse, kjellr, Kerfred, birgire, marybaum, SergeyBiryukov.



Built from https://develop.svn.wordpress.org/trunk@46412


git-svn-id: http://core.svn.wordpress.org/trunk@46210 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-10-06 06:56:02 +00:00
Joe McGill
d89be1ff55 Media: Ensure medialement scripts are loaded in the footer.
This fixes a regression in [41877] which caused `mediaelement` scripts to load in the header.

Props Themezly.
Fixes #44484.

Built from https://develop.svn.wordpress.org/trunk@46379


git-svn-id: http://core.svn.wordpress.org/trunk@46178 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-10-03 16:06:59 +00:00
Andrea Fercia
b1cd71c2d2 Accessibility: Media: Add more headings in the Media Modal.
Headings are the predominant mechanism for screen reader users to find information in a page. They also help all users to better identify the main sections of user interfaces.

- adds three new headings within the media modal 
- improves plural form translation for "item selected" by using `wp.i18n`
- horizontally centers the media modal menu in the responsive view

Props kjellr, karmatosed, melchoyce, afercia.
See #47149.
Fixes #47610.

Built from https://develop.svn.wordpress.org/trunk@46375


git-svn-id: http://core.svn.wordpress.org/trunk@46174 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-10-03 12:10:57 +00:00
desrosj
30d8319aa9 Block Editor: Update WordPress packages to include the latest bug fixes.
Updated packages:

@wordpress/annotations@1.7.1
@wordpress/api-fetch@3.6.1
@wordpress/babel-plugin-makepot@3.2.1
@wordpress/babel-preset-default@4.6.1
@wordpress/block-directory@1.0.1
@wordpress/block-editor@3.2.1
@wordpress/block-library@2.9.1
@wordpress/blocks@6.7.1
@wordpress/components@8.3.1
@wordpress/compose@3.7.1
@wordpress/core-data@2.7.1
@wordpress/data-controls@1.3.1
@wordpress/data@4.9.1
@wordpress/docgen@1.4.1
@wordpress/dom@2.5.1
@wordpress/e2e-test-utils@2.4.1
@wordpress/e2e-tests@1.7.1
@wordpress/edit-post@3.8.1
@wordpress/editor@9.7.1
@wordpress/element@2.8.1
@wordpress/format-library@1.9.1
@wordpress/i18n@3.6.1
@wordpress/jest-console@3.3.1
@wordpress/jest-preset-default@5.1.1
@wordpress/keycodes@2.6.1
@wordpress/library-export-default-webpack-plugin@1.4.1
@wordpress/list-reusable-blocks@1.8.1
@wordpress/media-utils@1.2.1
@wordpress/notices@1.8.1
@wordpress/nux@3.7.1
@wordpress/plugins@2.7.1
@wordpress/redux-routine@3.6.1
@wordpress/rich-text@3.7.1
@wordpress/scripts@5.0.1
@wordpress/server-side-render@1.3.1
@wordpress/shortcode@2.4.1
@wordpress/token-list@1.6.1
@wordpress/viewport@2.8.1
@wordpress/wordcount@2.6.1 

Props epiqueras, youknowriad, donmhico, jorgefilipecosta, soean, mcsf, noisysocks, andraganescu, gziolo, talldanwp, iseulde, nrqsnchz, mapk, karmatosed, joen, afercia, kjellr, desrosj.
Fixes #48186.
Built from https://develop.svn.wordpress.org/trunk@46364


git-svn-id: http://core.svn.wordpress.org/trunk@46163 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-30 20:07:06 +00:00
gziolo
bd344c19ea Block Editor: Align the version of React with the one used in Gutenberg plugin
Gutenberg 6.5 works with react and react-dom set to v16.9.0. This change aligns both.

Props youknowriad.
Fixes #48121.



Built from https://develop.svn.wordpress.org/trunk@46289


git-svn-id: http://core.svn.wordpress.org/trunk@46101 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-25 08:20:57 +00:00
Ella Iseulde Van Dorpe
fbcc75a5d6 r46253: Use implode instead of join, see #47746
Built from https://develop.svn.wordpress.org/trunk@46257


git-svn-id: http://core.svn.wordpress.org/trunk@46069 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-23 18:09:58 +00:00
Ella Iseulde Van Dorpe
22ae908ede Editor: Add Nonce Endpoint
This is a follow up to #47843, implementing a PHP endpoint and inline scripts 
after the editor package updates. The action was originally added in
https://github.com/WordPress/gutenberg/pull/16683.

Fixes #48076.



Built from https://develop.svn.wordpress.org/trunk@46253


git-svn-id: http://core.svn.wordpress.org/trunk@46065 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-23 17:47:56 +00:00
Andrea Fercia
9e26d98d7e Accessibility: Media: Make screen readers announce the Media search results.
- adds audible messages via `wp.a11y.speak()` to announce the search results 
- removes a `keyup` event that was there only to support old browsers 
- removes `aria-modal="true"` from the media modal dialog as it prevents the ARIA live regions to be perceived by screen readers
- triggers the search only after 2 ASCII characters have been typed

Props anevins, antpb, aduth, loreleiaurora, afercia.
Fixes #47146.

Built from https://develop.svn.wordpress.org/trunk@46239


git-svn-id: http://core.svn.wordpress.org/trunk@46051 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-23 12:19:56 +00:00
gziolo
03390f00c5 Block Editor: Update the WordPress Packages to the ones used in the Gutenberg 6.5 release
Updated Packages:

In version 6.2:

@wordpress/a11y@2.5.0
@wordpress/annotations@1.5.0
@wordpress/api-fetch@3.4.0
@wordpress/autop@2.4.0
@wordpress/babel-plugin-import-jsx-pragma@2.3.0
@wordpress/babel-plugin-makepot@3.2.0
@wordpress/babel-preset-default@4.4.0
@wordpress/blob@2.5.0
@wordpress/block-editor@3.0.0
@wordpress/block-library@2.7.0
@wordpress/block-serialization-default-parser@3.3.0
@wordpress/block-serialization-spec-parser@3.2.0
@wordpress/blocks@6.5.0
@wordpress/browserslist-config@2.6.0
@wordpress/components@8.1.0
@wordpress/compose@3.5.0
@wordpress/core-data@2.5.0
@wordpress/custom-templated-path-webpack-plugin@1.5.0
@wordpress/data-controls@1.1.0
@wordpress/data@4.7.0
@wordpress/date@3.4.0
@wordpress/dependency-extraction-webpack-plugin@1.1.0
@wordpress/deprecated@2.5.0
@wordpress/docgen@1.3.0
@wordpress/dom-ready@2.5.0
@wordpress/dom@2.4.0
@wordpress/e2e-test-utils@2.2.0
@wordpress/e2e-tests@1.4.0
@wordpress/edit-post@3.6.0
@wordpress/editor@9.5.0
@wordpress/element@2.6.0
@wordpress/escape-html@1.5.0
@wordpress/eslint-plugin@2.4.0
@wordpress/format-library@1.7.0
@wordpress/hooks@2.5.0
@wordpress/html-entities@2.5.0
@wordpress/i18n@3.6.0
@wordpress/is-shallow-equal@1.5.0
@wordpress/jest-console@3.2.0
@wordpress/jest-preset-default@4.3.0
@wordpress/jest-puppeteer-axe@1.2.0
@wordpress/keycodes@2.5.0
@wordpress/library-export-default-webpack-plugin@1.4.0
@wordpress/list-reusable-blocks@1.6.0
@wordpress/media-utils@1.0.0
@wordpress/notices@1.6.0
@wordpress/npm-package-json-lint-config@2.1.0
@wordpress/nux@3.5.0
@wordpress/plugins@2.5.0
@wordpress/postcss-themes@2.2.0
@wordpress/priority-queue@1.3.0
@wordpress/redux-routine@3.5.0
@wordpress/rich-text@3.5.0
@wordpress/scripts@3.4.0
@wordpress/server-side-render@1.1.0
@wordpress/shortcode@2.4.0
@wordpress/token-list@1.5.0
@wordpress/url@2.7.0
@wordpress/viewport@2.6.0
@wordpress/wordcount@2.5.0

In version 6.4:
@wordpress/annotations@1.6.0
@wordpress/api-fetch@3.5.0
@wordpress/autop@2.5.0
@wordpress/babel-preset-default@4.5.0
@wordpress/block-editor@3.1.0
@wordpress/block-library@2.8.0
@wordpress/block-serialization-default-parser@3.4.0
@wordpress/block-serialization-spec-parser@3.3.0
@wordpress/blocks@6.6.0
@wordpress/components@8.2.0
@wordpress/compose@3.6.0
@wordpress/core-data@2.6.0
@wordpress/data-controls@1.2.0
@wordpress/data@4.8.0
@wordpress/date@3.5.0
@wordpress/dependency-extraction-webpack-plugin@1.2.0
@wordpress/deprecated@2.6.0
@wordpress/docgen@1.4.0
@wordpress/dom@2.5.0
@wordpress/e2e-test-utils@2.3.0
@wordpress/e2e-tests@1.5.0
@wordpress/edit-post@3.7.0
@wordpress/editor@9.6.0
@wordpress/element@2.7.0
@wordpress/eslint-plugin@3.0.0
@wordpress/format-library@1.8.0
@wordpress/hooks@2.6.0
@wordpress/is-shallow-equal@1.6.0
@wordpress/jest-console@3.3.0
@wordpress/jest-preset-default@5.0.0
@wordpress/jest-puppeteer-axe@1.3.0
@wordpress/keycodes@2.6.0
@wordpress/list-reusable-blocks@1.7.0
@wordpress/media-utils@1.1.0
@wordpress/notices@1.7.0
@wordpress/nux@3.6.0
@wordpress/plugins@2.6.0
@wordpress/project-management-automation@1.0.0
@wordpress/redux-routine@3.6.0
@wordpress/rich-text@3.6.0
@wordpress/scripts@4.0.0
@wordpress/server-side-render@1.2.0
@wordpress/token-list@1.6.0
@wordpress/viewport@2.7.0
@wordpress/wordcount@2.6.0

In version 6.5:
@wordpress/annotations@1.7.0
@wordpress/api-fetch@3.6.0
@wordpress/babel-preset-default@4.6.0
@wordpress/block-directory@1.0.0
@wordpress/block-editor@3.2.0
@wordpress/block-library@2.9.0
@wordpress/blocks@6.7.0
@wordpress/components@8.3.0
@wordpress/compose@3.7.0
@wordpress/core-data@2.7.0
@wordpress/data-controls@1.3.0
@wordpress/data@4.9.0
@wordpress/dependency-extraction-webpack-plugin@2.0.0
@wordpress/e2e-test-utils@2.4.0
@wordpress/e2e-tests@1.7.0
@wordpress/edit-post@3.8.0
@wordpress/editor@9.7.0
@wordpress/element@2.8.0
@wordpress/eslint-plugin@3.1.0
@wordpress/format-library@1.9.0
@wordpress/list-reusable-blocks@1.8.0
@wordpress/media-utils@1.2.0
@wordpress/notices@1.8.0
@wordpress/nux@3.7.0
@wordpress/plugins@2.7.0
@wordpress/rich-text@3.7.0
@wordpress/scripts@5.0.0
@wordpress/server-side-render@1.3.0
@wordpress/url@2.8.0
@wordpress/viewport@2.8.0

Props youknowriad desrosj noisysocks pento jorgefilipecosta iseulde

Fixes: #47843


Built from https://develop.svn.wordpress.org/trunk@46189


git-svn-id: http://core.svn.wordpress.org/trunk@46001 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-19 15:19:18 +00:00
Andrea Fercia
a4daffb0b4 Script Loader: Remove old wp-a11y from the loaded scripts after [46167] and [46169].
Props garrett-eclipse, sstoqnov.
See #45066.
Fixes #48071.

Built from https://develop.svn.wordpress.org/trunk@46179


git-svn-id: http://core.svn.wordpress.org/trunk@45991 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-19 09:54:55 +00:00
Sergey Biryukov
252628652e Script Loader: Introduce HTML5 support for scripts and styles.
When a theme declares HTML5 support for script and styles via `add_theme_support( 'html5', array( 'script', 'style' ) )`, the `type="text/javascript"` and `type="text/css"` attributes are omitted.

These attributes are unnecessary in HTML5 and cause warnings in the W3C Markup Validation Service.

Props sasiddiqui, swissspidy, knutsp, SergeyBiryukov.
See #42804.
Built from https://develop.svn.wordpress.org/trunk@46164


git-svn-id: http://core.svn.wordpress.org/trunk@45976 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-18 14:50:56 +00:00
Adam Silverstein
0cb3860138 External Libraries: Update Backbone.js to 1.4.0.
Upgrade Backbone to the latest stable version. Fix some issues in Media with `listenTo` which changed in this version, see https://backbonejs.org/#changelog.

Props desrosj, priyankkpatel, pierlo.
Fixes #47478.


Built from https://develop.svn.wordpress.org/trunk@46157


git-svn-id: http://core.svn.wordpress.org/trunk@45969 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-17 17:19:54 +00:00
jorgefilipecosta
b7fbf7d373 Block Editor: Backport block styles server functions from block editor.
This commit backports the block styles functionality added to the block editor in https://github.com/WordPress/gutenberg/pull/16356.

Props: youknowriad, aduth, swissspidy.
Fixes #48039.
Built from https://develop.svn.wordpress.org/trunk@46111


git-svn-id: http://core.svn.wordpress.org/trunk@45923 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-14 18:21:54 +00:00
Sergey Biryukov
cc6e23e4dc External Libraries: Update jQuery Color plugin to 2.1.2.
Props desrosj, hareesh-pillai, lovememore.
Fixes #31511.
Built from https://develop.svn.wordpress.org/trunk@46095


git-svn-id: http://core.svn.wordpress.org/trunk@45907 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-12 12:41:54 +00:00
Sergey Biryukov
86a10090a0 Accessibility: Comments: Replace @ with at in the displayed date format.
The `@` symbol makes sense in the context of email addresses, but does not have a universal meaning in the context of dates.

Props birgire, afercia, audrasjb, SergeyBiryukov.
Fixes #47893.
Built from https://develop.svn.wordpress.org/trunk@46084


git-svn-id: http://core.svn.wordpress.org/trunk@45896 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-08 23:53:55 +00:00
Sergey Biryukov
f8ba775d7c Accessibility: Posts, Post Types: Replace @ with at in the displayed date format.
The `@` symbol makes sense in the context of email addresses, but does not have a universal meaning in the context of dates.

Props birgire, afercia, audrasjb, SergeyBiryukov.
Fixes #47832.
Built from https://develop.svn.wordpress.org/trunk@46083


git-svn-id: http://core.svn.wordpress.org/trunk@45895 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-08 23:24:56 +00:00
Andrew Ozz
630bad3a4f Uploads: Improve the error message shown when all attempts to create image sub-sizes fail.
Props afercia.
See #47872.
Built from https://develop.svn.wordpress.org/trunk@46075


git-svn-id: http://core.svn.wordpress.org/trunk@45887 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-06 23:48:55 +00:00
whyisjake
f4562e5516 Remove the extra call for wp-sanitize from the script loader.
Fixes #47986

Built from https://develop.svn.wordpress.org/trunk@46073


git-svn-id: http://core.svn.wordpress.org/trunk@45885 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-06 21:49:59 +00:00
whyisjake
90d9bdc54c Update wp.a11y.speak() to sanitize HTML before display.
Props iandunn, adamsilverstein, sstoqnov, peterwilsoncc

Built from https://develop.svn.wordpress.org/trunk@45979


git-svn-id: http://core.svn.wordpress.org/trunk@45790 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-04 17:13:21 +00:00
Andrew Ozz
e313498193 Uploads: After an image is uploaded and PHP times out or runs out of memory during post-processing (the server response is HTTP 500 error), try to resize it three more times. Then, if all attempts fail, do a cleanup of any sub-sizes that may have been created and show an error message asking the user to scale the image and upload it again.
See #47872.
Built from https://develop.svn.wordpress.org/trunk@45934


git-svn-id: http://core.svn.wordpress.org/trunk@45745 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-04 01:11:54 +00:00
Sergey Biryukov
e199663322 I18N: Capitalize translator comments consistently, add trailing punctuation.
Includes minor code layout fixes.

See #44360.
Built from https://develop.svn.wordpress.org/trunk@45932


git-svn-id: http://core.svn.wordpress.org/trunk@45743 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-03 00:41:05 +00:00
Sergey Biryukov
16b8d91baa I18N: Improve translator comments.
* Add missing translator comments.
* Fix placement of some translator comments. Translator comments should be on the line directly above the line containing the translation function call for optimal compatibility with various `.pot` file generation tools. The CS auto-fixing, which changed some inconsistent function calls to multi-line function calls, is part of the reason why this was no longer the case for a select group of translator comments.

Includes minor code layout fixes.

Polyglots, rejoice! All WordPress core files now have translator comments for all strings with placeholders!

Props jrf, subrataemfluence, GaryJ, webdados, Dency, swissspidy, alvarogois, marcomartins, mihaiiceyro, vladwtz, niq1982, flipkeijzer, michielatyoast, chandrapatel, thrijith, joshuanoyce, FesoVik, tessak22, bhaktirajdev, cleancoded, dhavalkasvala, garrett-eclipse, bibliofille, socalchristina, priyankkpatel, 5hel2l2y, adamsilverstein, JeffPaul, pierlo, SergeyBiryukov.
Fixes #44360.
Built from https://develop.svn.wordpress.org/trunk@45926


git-svn-id: http://core.svn.wordpress.org/trunk@45737 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-01 17:13:59 +00:00
Sergey Biryukov
6da93732e7 Docs: Add missing description for $current_screen global.
Props mukesh27.
Fixes #45604. See #47110.
Built from https://develop.svn.wordpress.org/trunk@45740


git-svn-id: http://core.svn.wordpress.org/trunk@45551 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-08-04 02:03:55 +00:00
Sergey Biryukov
e0311b76c7 Docs: Add missing description for $wp_locale global.
Props mukesh27.
See #45604, #47110.
Built from https://develop.svn.wordpress.org/trunk@45737


git-svn-id: http://core.svn.wordpress.org/trunk@45548 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-08-04 01:46:55 +00:00
Aaron Jorbin
c377191858 PHP 7.4 compatibility fix / accessing arrays/string using curly brace syntax
PHP used to allow both square brackets and curly braces to be used interchangeably for accessing array elements and string offsets. The curly bracket syntax is only allowed in a limited set of cases and can be confusing for people not used to it.
PHP 7.4 will deprecate the curly brace syntax for accessing array elements and string offsets and it is expected that support will be completely removed in PHP 8.0.
Ref: https://wiki.php.net/rfc/deprecate_curly_braces_array_access

See #47751.
Props jrf.


Built from https://develop.svn.wordpress.org/trunk@45730


git-svn-id: http://core.svn.wordpress.org/trunk@45541 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-08-03 20:21:55 +00:00
Sergey Biryukov
ccba6c4aec Upgrade/Install: Bring some consistency to installation screen styles.
* Include `forms.css` and `l10n.css`, for consistency with login screen and other admin screens.
* Remove redundant `@import` directives from `login.css` for files already declared as dependencies.
* Adjust margin on password strength meter for consistency with other fields.
* Increase font size for "You will need this password to log in" notice.
* Fix misaligned icon on "Hide" button for the password.

Props iseulde, dan@micamedia.com, bassgang, cdog, johnbillion, nmenescardi, mukesh27, SergeyBiryukov.
Fixes #35776, #47757, #47758.
Built from https://develop.svn.wordpress.org/trunk@45673


git-svn-id: http://core.svn.wordpress.org/trunk@45484 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-07-25 19:11:55 +00:00
Sergey Biryukov
3a57fee891 Script Loader: Remove unnecessary jquery dependency for wp-sanitize.js.
The file is written in plain JavaScript.

Props sstoqnov.
Fixes #47324.
Built from https://develop.svn.wordpress.org/trunk@45593


git-svn-id: http://core.svn.wordpress.org/trunk@45404 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-07-04 00:33:57 +00:00
Felix Arntz
3c40573f77 Bundled Theme: Load Google fonts with display=fallback parameter for better UX in case the font cannot be loaded.
Providing this query parameter ensures the stylesheet contains the `font-display: fallback` rule. This changeset also updates the Open Sans font used by core accordingly.

Props westonruter.
Fixes #47282.

Built from https://develop.svn.wordpress.org/trunk@45485


git-svn-id: http://core.svn.wordpress.org/trunk@45296 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-31 10:10:54 +00:00
youknowriad
ebb0b92081 Block Editor: Update packages to the ones slated for WP5.2.2
- Fix the template validation notice
 - Fix for focus jumps when typing in meta attributes

Packages updated:

 - @wordpress/block-editor@2.0.3
 - @wordpress/block-library@2.4.6
 - @wordpress/e2e-tests@1.1.6
 - @wordpress/edit-post@3.3.6
 - @wordpress/editor@9.2.6
 - @wordpress/format-library@1.4.6

Props aduth, desrosj.
Fixes #47429.

Built from https://develop.svn.wordpress.org/trunk@45481


git-svn-id: http://core.svn.wordpress.org/trunk@45292 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-30 15:41:57 +00:00
Andrew Ozz
311527b41d Fix previous WPCS errors in script-loader.php triggered by [45456].
See #45346.
Built from https://develop.svn.wordpress.org/trunk@45457


git-svn-id: http://core.svn.wordpress.org/trunk@45268 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-28 03:32:52 +00:00
Andrew Ozz
6de52463a7 Script loader: prevent sorting of the load array in the query string when passing the script handles to load-scripts.php and load-styles.php.
Fixes #45346 #26886.
Built from https://develop.svn.wordpress.org/trunk@45456


git-svn-id: http://core.svn.wordpress.org/trunk@45267 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-28 02:43:55 +00:00
Andrew Ozz
87acdab81d Privacy tools: Organize privacy functions into logical files and classes.
Props xkon, birgire, desrosj, garrett-eclipse, azaozz.
See #43895.
Built from https://develop.svn.wordpress.org/trunk@45448


git-svn-id: http://core.svn.wordpress.org/trunk@45259 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-26 20:50:53 +00:00
Sergey Biryukov
47720de1c2 Text Changes: Use consistent question wording for discarding unpublished changes in Customizer.
Props ramiy.
Fixes #47258.
Built from https://develop.svn.wordpress.org/trunk@45434


git-svn-id: http://core.svn.wordpress.org/trunk@45245 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-26 15:19:50 +00:00
Andrew Ozz
80aee4ae87 jQuery: bring jquery.js back into the WordPress SVN repo and backport the patch from 3.4.0.
Props MikeNGarrett, peterwilsoncc, azaozz.
Fixes #47020 for trunk.
Built from https://develop.svn.wordpress.org/trunk@45342


git-svn-id: http://core.svn.wordpress.org/trunk@45153 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-17 04:25:54 +00:00
aduth
3c44f9e15a Block Editor: Upgrade WordPress packages to the latest versions.
Updated packages:

 - @wordpress/annotations@1.2.3
 - @wordpress/block-editor@2.0.2
 - @wordpress/block-library@2.4.5
 - @wordpress/blocks@6.2.5
 - @wordpress/components@7.3.2
 - @wordpress/dom@2.2.5
 - @wordpress/e2e-tests@1.1.5
 - @wordpress/edit-post@3.3.5
 - @wordpress/editor@9.2.5
 - @wordpress/format-library@1.4.5
 - @wordpress/list-reusable-blocks@1.3.5
 - @wordpress/nux@3.2.5
 - @wordpress/rich-text@3.2.3

Props: youknowriad, gwwar, iseulde, tfrommen, gziolo.

Fixes #47284.

Built from https://develop.svn.wordpress.org/trunk@45319


git-svn-id: http://core.svn.wordpress.org/trunk@45130 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-16 18:08:00 +00:00
aduth
0feb55f633 Editor: Update packages to apply bugfixes from Gutenberg 5.5.
- @wordpress/block-editor@2.0.1
- @wordpress/block-library@2.4.4
- @wordpress/blocks@6.2.4
- @wordpress/components@7.3.1
- @wordpress/dom@2.2.4
- @wordpress/e2e-tests@1.1.4
- @wordpress/edit-post@3.3.4
- @wordpress/editor@9.2.4
- @wordpress/format-library@1.4.4
- @wordpress/list-reusable-blocks@1.3.4
- @wordpress/nux@3.2.4

Props iseulde, kjellr, aduth, get_dave, talldanwp, jorgefilipecosta, afercia, nosolosw, jasmussen, netweb .

See https://github.com/WordPress/gutenberg/pull/14987 .
See https://github.com/WordPress/gutenberg/pull/15020 .
Fixes #46951 .

Built from https://develop.svn.wordpress.org/trunk@45255


git-svn-id: http://core.svn.wordpress.org/trunk@45064 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-04-22 12:40:04 +00:00
Dominik Schilling
bfc2be39e6 Site Health: Enable JavaScript translations for the site-health script.
See #46683.
Built from https://develop.svn.wordpress.org/trunk@45244


git-svn-id: http://core.svn.wordpress.org/trunk@45053 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-04-18 15:41:51 +00:00
Sergey Biryukov
d2ccaacedf Docs: Correct spelling in various comments and DocBlocks, per the conventions in Core Contributor Handbook.
Props man4toman, samanehmirrajabi.
Fixes #45857.
Built from https://develop.svn.wordpress.org/trunk@45232


git-svn-id: http://core.svn.wordpress.org/trunk@45041 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-04-17 13:26:51 +00:00
Sergey Biryukov
1ae11820fc Site Health: i18n audit, take 2.
* Use `wp.i18n` to translate JavaScript strings.
* Use `_n()` for proper plural forms support.

Props TimothyBlynJacobs, ocean90, afercia.
Fixes #46683.
Built from https://develop.svn.wordpress.org/trunk@45178


git-svn-id: http://core.svn.wordpress.org/trunk@44987 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-04-12 20:34:51 +00:00
desrosj
21da589622 Site Health: Ensure Site Health pages are correctly displayed for RTL locales.
Props: ebrahimzadeh, afercia, mohadeseghasemi.
Fixes #46868.
Built from https://develop.svn.wordpress.org/trunk@45168


git-svn-id: http://core.svn.wordpress.org/trunk@44977 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-04-12 16:39:52 +00:00
Gary Pendergast
95df8fa792 Block Editor: Update packages to bring a selection of bugfixes in.
Props iseulde, kjellr, aduth, 0mirka00, mcsf, nosolosw, gziolo, jasmussen, talldanwp, notnownikki, swissspidy, jorgefilipecosta, noisysocks.
See https://github.com/WordPress/gutenberg/pull/14796.
Fixes #46801.


Built from https://develop.svn.wordpress.org/trunk@45138


git-svn-id: http://core.svn.wordpress.org/trunk@44947 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-04-08 06:37:57 +00:00
Gary Pendergast
65f7cdbce0 Site Health: Improve the "Copy to clipboard" button.
The previous method for copying the debug report to the clipboard involved having a hidden `<textarea>`, but this shows up in screen readers and can't be reliably hidden.

To work around this, the button now uses the `clipboard.js` library, which automatically handles browser differences in the Clipboard API, and can load the text to copy from a `data-` attribute on the button.

Props pento, hedgefield, afercia.
Fixes #46647.


Built from https://develop.svn.wordpress.org/trunk@45044


git-svn-id: http://core.svn.wordpress.org/trunk@44853 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-03-27 22:31:52 +00:00
Gary Pendergast
0a9d61ab63 Admin: Introduce the Site Health screens.
The Site Health tool serves two purposes:
- Provide site owners with information to improve the performance, reliability, and security of their site.
- Collect comprehensive debug information about the site.

By encouraging site owners to maintain their site and adhere to modern best practices, we ultimately improve the software hygeine of both the WordPress ecosystem, and the open internet as a whole.

Props Clorith, hedgefield, melchoyce, xkon, karmatosed, jordesign, earnjam, ianbelanger, wpscholar, desrosj, pedromendonca, peterbooker, jcastaneda, garyj, soean, pento, timothyblynjacobs, zodiac1978, dgroddick, garrett-eclipse, netweb, tobifjellner, pixolin, afercia, joedolson, birgire.
See #46573.

Built from https://develop.svn.wordpress.org/trunk@44986


git-svn-id: http://core.svn.wordpress.org/trunk@44817 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-03-23 03:55:53 +00:00
Ella Iseulde Van Dorpe
2aa1b8ff48 Block Editor: Update the WordPress Packages from Gutenberg 5.3
- @wordpress/a11y@2.2.0
 - @wordpress/annotations@1.2.0
 - @wordpress/api-fetch@3.1.0
 - @wordpress/autop@2.2.0
 - @wordpress/babel-plugin-import-jsx-pragma@2.1.0
 - @wordpress/babel-preset-default@4.1.0
 - @wordpress/blob@2.3.0
 - @wordpress/block-editor@1.1.0
 - @wordpress/block-library@2.4.0
 - @wordpress/block-serialization-default-parser@3.1.0
 - @wordpress/blocks@6.2.0
 - @wordpress/components@7.2.0
 - @wordpress/compose@3.2.0
 - @wordpress/core-data@2.2.0
 - @wordpress/data@4.4.0
 - @wordpress/date@3.2.0
 - @wordpress/deprecated@2.2.0
 - @wordpress/docgen@1.1.0
 - @wordpress/dom-ready@2.2.0
 - @wordpress/dom@2.2.0
 - @wordpress/e2e-test-utils@1.1.0
 - @wordpress/e2e-tests@1.1.0
 - @wordpress/edit-post@3.3.0
 - @wordpress/edit-widgets@0.2.0
 - @wordpress/editor@9.2.0
 - @wordpress/element@2.3.0
 - @wordpress/escape-html@1.2.0
 - @wordpress/eslint-plugin@2.1.0
 - @wordpress/format-library@1.4.0
 - @wordpress/hooks@2.2.0
 - @wordpress/html-entities@2.2.0
 - @wordpress/i18n@3.3.0
 - @wordpress/keycodes@2.2.0
 - @wordpress/list-reusable-blocks@1.3.0
 - @wordpress/notices@1.3.0
 - @wordpress/nux@3.2.0
 - @wordpress/plugins@2.2.0
 - @wordpress/priority-queue@1.1.0
 - @wordpress/redux-routine@3.2.0
 - @wordpress/rich-text@3.2.0
 - @wordpress/scripts@3.1.0
 - @wordpress/shortcode@2.2.0
 - @wordpress/url@2.5.0
 - @wordpress/viewport@2.3.0
 - @wordpress/wordcount@2.2.0


Built from https://develop.svn.wordpress.org/trunk@44960


git-svn-id: http://core.svn.wordpress.org/trunk@44791 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-03-21 12:48:00 +00:00
aduth
9cf4ee65a7 Scripts: Assign api-fetch nonce with corrected rest_nonce.
As of `@wordpress/api-fetch@3.0.0` (introduced in 44812), the `apiFetch` nonce middleware must have its nonce value assigned explicitly, and will no longer listen for heartbeat ticks automatically. This changeset adds an inline script for the default registration of the `api-fetch` script handle to assign the nonce value in response to the heartbeat action. In doing so, it removes the now-unused, misnamed `rest-nonce` property from the heartbeat response, whose original introduction served as temporary compatibility with earlier versions of `@wordpress/api-fetch`.

See https://github.com/WordPress/gutenberg/pull/13451
See #45113

Props adamsilverstein, nerrad .
Fixes #46107 .

Built from https://develop.svn.wordpress.org/trunk@44949


git-svn-id: http://core.svn.wordpress.org/trunk@44780 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-03-20 20:53:50 +00:00
youknowriad
c32464d7f1 Block Editor: Fix unit tests after new blocks addition.
- Regenerate the REST API fixtures.
 - Remove the block registration hooks in the unit tests.

Refs #46429.

Built from https://develop.svn.wordpress.org/trunk@44812


git-svn-id: http://core.svn.wordpress.org/trunk@44644 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-03-07 11:54:51 +00:00
youknowriad
2d58d57e38 Block Editor: Update the WordPress Packages from Gutenberg 5.2.
Updated Packages:

 - @wordpress/a11y@2.1.0
 - @wordpress/annotations@1.1.0
 - @wordpress/api-fetch@3.0.0
 - @wordpress/autop@2.1.0
 - @wordpress/babel-plugin-import-jsx-pragma@2.0.0
 - @wordpress/babel-plugin-makepot@3.0.0
 - @wordpress/babel-preset-default@4.0.0
 - @wordpress/blob@2.2.0
 - @wordpress/block-editor@1.0.0
 - @wordpress/block-library@2.3.0
 - @wordpress/block-serialization-default-parser@3.0.0
 - @wordpress/block-serialization-spec-parser@3.0.0
 - @wordpress/blocks@6.1.0
 - @wordpress/browserslist-config@2.3.0
 - @wordpress/components@7.1.0
 - @wordpress/compose@3.1.0
 - @wordpress/core-data@2.1.0
 - @wordpress/custom-templated-path-webpack-plugin@1.2.0
 - @wordpress/data@4.3.0
 - @wordpress/date@3.1.0
 - @wordpress/deprecated@2.1.0
 - @wordpress/docgen@1.0.0
 - @wordpress/dom-ready@2.1.0
 - @wordpress/dom@2.1.0
 - @wordpress/e2e-test-utils@1.0.0
 - @wordpress/e2e-tests@1.0.0
 - @wordpress/edit-post@3.2.0
 - @wordpress/editor@9.1.0
 - @wordpress/element@2.2.0
 - @wordpress/escape-html@1.1.0
 - @wordpress/eslint-plugin@2.0.0
 - @wordpress/format-library@1.3.0
 - @wordpress/hooks@2.1.0
 - @wordpress/html-entities@2.1.0
 - @wordpress/i18n@3.2.0
 - @wordpress/is-shallow-equal@1.2.0
 - @wordpress/jest-console@3.0.0
 - @wordpress/jest-preset-default@4.0.0
 - @wordpress/jest-puppeteer-axe@1.0.0
 - @wordpress/keycodes@2.1.0
 - @wordpress/library-export-default-webpack-plugin@1.1.0
 - @wordpress/list-reusable-blocks@1.2.0
 - @wordpress/notices@1.2.0
 - @wordpress/npm-package-json-lint-config@1.2.0
 - @wordpress/nux@3.1.0
 - @wordpress/plugins@2.1.0
 - @wordpress/postcss-themes@2.0.0
 - @wordpress/priority-queue@1.0.0
 - @wordpress/redux-routine@3.1.0
 - @wordpress/rich-text@3.1.0
 - @wordpress/scripts@3.0.0
 - @wordpress/shortcode@2.1.0
 - @wordpress/token-list@1.2.0
 - @wordpress/url@2.4.0
 - @wordpress/viewport@2.2.0
 - @wordpress/wordcount@2.1.0

This also includes the update to the scripts dependencies and the new widgets php files.

Props iseulde.
Fixes #46429.

Built from https://develop.svn.wordpress.org/trunk@44808


git-svn-id: http://core.svn.wordpress.org/trunk@44640 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-03-07 09:09:59 +00:00
Aaron Jorbin
029fcf7791 Script Loader: Load fakejshint as jshint due to "good and evil".
Originally fixed in [42547]. Broken in [44163]. We've been here before. I recognize that tree.

Fixes #46299

Built from https://develop.svn.wordpress.org/trunk@44762


git-svn-id: http://core.svn.wordpress.org/trunk@44594 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-02-21 21:19:50 +00:00
youknowriad
a89b6c042d Block Editor: Update WordPress Packages to solve PHP 5.2.2 parser incompatibility.
Updated:

 - @wordpress/block-library@2.2.16
 - @wordpress/block-serialization-default-parser@2.0.5
 - @wordpress/blocks@6.0.7
 - @wordpress/edit-post@3.1.11
 - @wordpress/editor@9.0.11
 - @wordpress/format-library@1.2.14

Props pento.
Fixes #46200.

Built from https://develop.svn.wordpress.org/trunk@44729


git-svn-id: http://core.svn.wordpress.org/trunk@44560 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-02-07 09:02:49 +00:00
youknowriad
3c7a623f85 Block Editor: Update WordPress Packages to the latest versions.
Updated Packages:

 - @wordpress/annotations@1.0.8
 - @wordpress/block-library@2.2.15
 - @wordpress/components@7.0.8
 - @wordpress/edit-post@3.1.10
 - @wordpress/editor@9.0.10
 - @wordpress/format-library@1.2.13
 - @wordpress/list-reusable-blocks@1.1.21
 - @wordpress/nux@3.0.9
 - @wordpress/rich-text@3.0.7

Fixes list block indentation and Crowdsignal embed block.

Props iseulde.
Fixes #46137.


Built from https://develop.svn.wordpress.org/trunk@44711


git-svn-id: http://core.svn.wordpress.org/trunk@44542 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-01-29 18:23:55 +00:00
Dominik Schilling
8af55f1578 Script Loader: Add missing semicolon.
Fixes #46131.
Built from https://develop.svn.wordpress.org/trunk@44709


git-svn-id: http://core.svn.wordpress.org/trunk@44540 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-01-28 21:59:49 +00:00
Gary Pendergast
445209c9eb Menus: Remove error styling when the user addresses the error.
An error is triggered if a Menu Name isn't given when the user attempts to create a menu. When they go back and add a name, the error styling can be removed.

Props ashokrd2013, piyush9100, welcher, afercia.
Fixes #42321.


Built from https://develop.svn.wordpress.org/trunk@44680


git-svn-id: http://core.svn.wordpress.org/trunk@44511 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-01-21 22:10:49 +00:00
Andrew Ozz
b7897c5761 TinyMCE: retire wp-tinymce.php and remove pre-compression of wp-tinymce.js.
Fixes #45645.
Built from https://develop.svn.wordpress.org/trunk@44651


git-svn-id: http://core.svn.wordpress.org/trunk@44482 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-01-18 19:51:53 +00:00
Gary Pendergast
14c44ad703 Block Editor: Upgrade the @wordpress/ packages.
This brings the block editor in core up to date with the Gutenberg 4.8 plugin release.

Props aduth, gziolo, youknowriad, mkaz, jorgefilipecosta, swissspidy, iseulde, soean, noisysocks, joen, brentswisher, dekervit, dimadin, zebulan, johnny5, nosolosw, netweb, ryelle, etoledom, mzorz, desrosj, mmtr86, tinkerbelly, ocean90, earnjam, ajitbohra, talldanwp, notnownikki, mcsf, afercia, adamsilverstein, gutendev, naoki0h, miyauchi, aldavigdis.
Fixes #45885.


Built from https://develop.svn.wordpress.org/trunk@44533


git-svn-id: http://core.svn.wordpress.org/trunk@44364 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-01-10 01:54:56 +00:00
Dominik Schilling
f34e1dbad1 I18N: Make domain argument optional in wp_set_script_translations() / WP_Scripts::set_translations().
Props swissspidy.
Fixes #45489.
Built from https://develop.svn.wordpress.org/trunk@44395


git-svn-id: http://core.svn.wordpress.org/trunk@44225 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-01-04 21:12:50 +00:00
Dominik Schilling
d31335da85 Script Loader: Load unminified package vendor scripts when SCRIPT_DEBUG is set.
The unminified package vendor scripts are bundled with the release package thus the value of the `SCRIPT_DEBUG` constant should be honored.

Props earnjam.
See #45535.
Built from https://develop.svn.wordpress.org/trunk@44391


git-svn-id: http://core.svn.wordpress.org/trunk@44221 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-01-04 20:27:49 +00:00
desrosj
0ee1a0e4e1 Block Editor: Upgrade @WordPress packages to the latest versions.
Updated packages:

- @wordpress/annotations@1.0.5
- @wordpress/api-fetch@2.2.7
- @wordpress/block-library@2.2.12
- @wordpress/block-serialization-default-parser@2.0.3
- @wordpress/blocks@6.0.5
- @wordpress/components@7.0.5
- @wordpress/core-data@2.0.16
- @wordpress/data@4.2.0
- @wordpress/deprecated@2.0.4
- @wordpress/dom@2.0.8
- @wordpress/edit-post@3.1.7
- @wordpress/editor@9.0.7
- @wordpress/format-library@1.2.10
- @wordpress/hooks@2.0.4
- @wordpress/list-reusable-blocks@1.1.18
- @wordpress/notices@1.1.2
- @wordpress/nux@3.0.6
- @wordpress/plugins@2.0.10
- @wordpress/rich-text@3.0.4
- @wordpress/url@2.3.3
- @wordpress/viewport@2.1.0

Props: youknowriad, gziolo, desrosj.

Fixes #45814.
Built from https://develop.svn.wordpress.org/trunk@44389


git-svn-id: http://core.svn.wordpress.org/trunk@44219 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-01-04 19:38:57 +00:00
Sergey Biryukov
413050b191 Block Editor: Upgrade @WordPress packages to the latest version (4.7.1)
Updated packages:

 - @wordpress/block-library@2.2.11
 - @wordpress/edit-post@3.1.6
 - @wordpress/editor@9.0.6
 - @wordpress/format-library@1.2.9

Props youknowriad, pento.
Merges [44287] to trunk.
Fixes #45637.
Built from https://develop.svn.wordpress.org/trunk@44319


git-svn-id: http://core.svn.wordpress.org/trunk@44149 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-19 03:35:38 +00:00
desrosj
75dfa5f7f6 Script Loader: Pass the suffix to package style handles to ensure correct file names for minified RTL stylesheets.
Props ocean90.

Merges [44231] into trunk.

See #45547.
Built from https://develop.svn.wordpress.org/trunk@44314


git-svn-id: http://core.svn.wordpress.org/trunk@44144 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-19 03:31:29 +00:00
desrosj
7da2e20f4d Script Loader: Misplaced parenthesis when wp-tinymce-lists is added.
A closing parenthesis was misplaced in the `$scripts->add( 'wp-tinymce-lists' )` call, causing the dependencies and version to be incorrectly passed to `includes_url()` instead.

Also, Remove an incorrect parameter sent to `wp_get_script_polyfill()`. `wp_get_script_polyfill()` only accepts two parameters, but this call was passing a third.

Props volodymyrkolesnykov, swissspidy.

Merges [44208] and [44211] into trunk.

Fixes: #45506, #45472.
Built from https://develop.svn.wordpress.org/trunk@44308


git-svn-id: http://core.svn.wordpress.org/trunk@44138 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-19 03:26:37 +00:00
desrosj
d6e8d93412 Block Editor: Upgrade @wordpress packages to match version 4.7.1.
Updated packages:

- `@wordpress/annotations
- `@wordpress/api-fetch
- `@wordpress/block-library@2.2.10
- `@wordpress/block-serialization-default-parser@2.0.2`
- `@wordpress/block-serialization-spec-parser@2.0.2`
- `@wordpress/blocks@6.0.4`
- `@wordpress/components@7.0.4`
- `@wordpress/core-data@2.0.15`
- `@wordpress/data@4.1.0`
- `@wordpress/date@3.0.1`
- `@wordpress/edit-post@3.1.5`
- `@wordpress/editor@9.0.5`
- `@wordpress/eslint-plugin@1.0.0`
- `@wordpress/format-library@1.2.8`
- `@wordpress/html-entities@2.0.4`
- `@wordpress/list-reusable-blocks@1.1.17`
- `@wordpress/notices@1.1.1`
- `@wordpress/nux@3.0.5`
- `@wordpress/rich-text@3.0.3`
- `@wordpress/url@2.3.2`
- `@wordpress/viewport@2.0.13`

This also includes the updates the Core blocks.

The script loader is updated to match the Gutenberg repository as well.

Props atimmer, gziolo, joen, youknowriad.

Merges [44183] to trunk.

Fixes #45442, #45637.
Built from https://develop.svn.wordpress.org/trunk@44296


git-svn-id: http://core.svn.wordpress.org/trunk@44126 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-19 03:16:48 +00:00
Sergey Biryukov
985bed281c Scripts: Ensure sub-directory WordPress installs can load polyfill scripts.
`wp_get_script_polyfill()` bypasses `WP_Scripts::do_item()`, so didn't transform the script path into its fully qualified URL.

Props swissspidy, ocean90.
Merges [43960] to trunk.
Fixes #45469.
Built from https://develop.svn.wordpress.org/trunk@44286


git-svn-id: http://core.svn.wordpress.org/trunk@44116 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-18 04:05:48 +00:00
desrosj
077e2c5fcf Block Editor: Update @wordpress package dependencies.
Updates the following packages:

block-library, block-serialization-default-parser, block-serialization-spec-parser, blocks, edit-post, editor, format-library.

Merges [43955] to trunk.

Props youknowriad.

Fixes #45145.
Built from https://develop.svn.wordpress.org/trunk@44281


git-svn-id: http://core.svn.wordpress.org/trunk@44111 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 21:59:54 +00:00
desrosj
e188e2d3a3 Block Editor: Fix the WordPress packages and vendor script registration.
The version is set properly and the scripts are automatically loaded in the footer.

This patch also includes a revert for the reusable blocks enqueue script.

Props pento, swissspidy, youknowriad.

Merges [43942] into trunk.

Fixes #45402.
See #45396.
Built from https://develop.svn.wordpress.org/trunk@44277


git-svn-id: http://core.svn.wordpress.org/trunk@44107 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 19:34:52 +00:00
desrosj
03262a191f Block Editor: Refresh nonces used by wp.apiFetch.
Adds heartbeat nonces refreshing support to `wp.apiFetch` requests.

Props pento, adamsilverstein, dd32, desrosj, youknowriad.

Merges [43939] into trunk.

Fixes #45113. 
Built from https://develop.svn.wordpress.org/trunk@44275


git-svn-id: http://core.svn.wordpress.org/trunk@44105 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 19:28:51 +00:00
desrosj
36158d7909 Block Editor: Update @wordpress package dependencies.
Update packages include:

- block-library
- components
- edit-post
- editor
- format-library
- list-reusable-blocks
- nux

Other changes:

- Fix a translator comment in `edit-form-blocks.php`.
- Rename the `gutenberg_` functions in `blocks/latest-comments.php`.

Props noisy socks, youknowriad, pinto, swissspidy.

Merges [43935] and [43949-43951] into trunk.

See #45145.
Built from https://develop.svn.wordpress.org/trunk@44273


git-svn-id: http://core.svn.wordpress.org/trunk@44103 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 19:06:59 +00:00
desrosj
820f643bff Core Editor: Specify script versions for the WordPress packages and their vendor dependencies.
Using the `package.json` versions of the NPM dependencies as versions when registering the WordPress scripts.

Props dimadin, dd32, youknowriad.

Merges [43925] to trunk.

Fixes #45187.
Built from https://develop.svn.wordpress.org/trunk@44271


git-svn-id: http://core.svn.wordpress.org/trunk@44101 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 18:19:50 +00:00
desrosj
2899f355a9 TinyMCE: Run the filters for the Classic block.
The `wp_editor_settings` and `disable_captions` filters need to be run for the Classic Block.

This fixes possible regressions in plugins that use these filters, and plugins that use them to add filters for the buttons, external plugins, etc.

Props azaozz.

Merges [43914] into trunk.

Fixes #45348.
Built from https://develop.svn.wordpress.org/trunk@44265


git-svn-id: http://core.svn.wordpress.org/trunk@44095 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 17:03:51 +00:00
desrosj
4f86a03258 Block Editor: Update @wordpress dependencies to match Gutenberg 4.5.1.
- Update the annotations, api-fetch, block-library, blocks, components, compose, core-data, data, date, dom, edit-post, editor, element, format-library, html-entities, i18n, jest-console, jest-preset-default, keycodes, list-reusable-blocks, notices, nux, plugins, rich-text, scripts, token-lists, url, viewport packages.
- Upgrades React from 16.5.2 to 16.6.3.
- Adds a missing `wp-date` dependency to the editor script.
- Updates changed dependencies in `script-loader.php`.
- Fixes undefined notices in some blocks.
- Removes incorrect `gutenberg` textdomain.

Merges [43891], [43903], and [43919] to trunk.

Props atimmer, aduth, youknowriad, danielbachhuber.
See #45145.
Built from https://develop.svn.wordpress.org/trunk@44262


git-svn-id: http://core.svn.wordpress.org/trunk@44092 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 15:37:00 +00:00
desrosj
9d7aa3436e Block Editor: Update @wordpress dependencies.
Changes of note:

- Includes the new Annotations API package.
- `wp-polyfill-ecmascript.js` is renamed to `wp-polyfill.js`.
- `strip_dynamic_blocks()` has been removed in favor of `excerpt_remove_blocks()`.
- The PHP block parser is now syncing from the `block-serialization-default-parser` package.
- `do_blocks()` uses the new parser.
- The `do_block` filter has been removed from `do_blocks()`, in favor of a `render_block` filter in `render_block()`.

Also, a little cleanup to `render_block()`. Always normalize `$block['attrs’]` to array in `’render_block’` filter.
Props pento, azaozz.

Merges [43884] and [43888] to trunk.

See #45145, #45190, #45264, #45282.
Built from https://develop.svn.wordpress.org/trunk@44261


git-svn-id: http://core.svn.wordpress.org/trunk@44091 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 04:52:00 +00:00
desrosj
bbe9a37b6c Editor: Add custom fields meta box support in the block editor.
This brings support for the custom fields meta box into the new block editor.

The `webpack` and `copy-webpack-plugin` packages have also been updated.

This does not bump the `@wordpress` packages like in [43861] because of conflicts with package versions already installed in `trunk`. The packages will be brought up to date in a subsequent merge.

Merges [43861] and [43863] into trunk.

See #45145.
Fixes #45257.
Built from https://develop.svn.wordpress.org/trunk@44260


git-svn-id: http://core.svn.wordpress.org/trunk@44090 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 03:52:51 +00:00
Sergey Biryukov
07ce537eb8 Build Tools: Minify the package CSS when building.
CSS coming from the `@wordpress` packages wasn't being minified in the build. This had the noteable side effect of causing RTL CSS to not be loaded when `SCRIPT_DEBUG` was set to `false`.

Props websupporter.
Merges [43905] to trunk.
Fixes #45330.
Built from https://develop.svn.wordpress.org/trunk@44252


git-svn-id: http://core.svn.wordpress.org/trunk@44082 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 03:28:06 +00:00
Sergey Biryukov
dbc692fb84 Block Editor: Load TinyMCE inline scripts later.
Previously, the TinyMCE inline scripts were added on the `init` action in the block editor. In the classic editor, however, these scripts are loaded when the TinyMCE window is printed, and some plugins rely on them being loaded later, so they can attach to the appropriate filters.

Props pento.
Merges [43901] to trunk.
Fixes #45338.
Built from https://develop.svn.wordpress.org/trunk@44251


git-svn-id: http://core.svn.wordpress.org/trunk@44081 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 03:27:12 +00:00
Sergey Biryukov
909cddb3b8 Scripts: Fix a PHP error in admin-ajax calls.
When making an ajax request, `wp_enqueue_registered_block_scripts_and_styles()` checked if `is_admin()` was true before accessing `$current_screen`, rather than checking if `$current_screen` was defined. This is usually fine, execept for in ajax requests.

Props ocean90, foreverpinetree, pento.
Merges [43893] and [43894] to trunk.
Fixes #45302.
Built from https://develop.svn.wordpress.org/trunk@44249


git-svn-id: http://core.svn.wordpress.org/trunk@44079 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 03:25:31 +00:00
Sergey Biryukov
e8cbdf9405 Block Editor: Fix the TinyMCE wordpress plugin to handle hiding/showing of toolbars in the classic block. Change the classic block toolbar to use the (now fixed) wp_adv button.
Props azaozz.
Merges [43889] and [43890] to trunk.
Fixes #45264.
Built from https://develop.svn.wordpress.org/trunk@44247


git-svn-id: http://core.svn.wordpress.org/trunk@44077 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 03:23:55 +00:00
Sergey Biryukov
9e54ec265c I18N: Set translations for all WordPress packages scripts.
Calls `wp_set_script_translations` for all packages scripts that have translations. Also correctly sets the domain on the translations.

Props omarreiss, pento, ocean90.
Merges [43878] to trunk.
Fixes #45161.
Built from https://develop.svn.wordpress.org/trunk@44239


git-svn-id: http://core.svn.wordpress.org/trunk@44069 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 03:17:04 +00:00
Sergey Biryukov
030b1ba144 PHPCS: Fix errors introduced in [44236].
See #45221.
Built from https://develop.svn.wordpress.org/trunk@44238


git-svn-id: http://core.svn.wordpress.org/trunk@44068 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 03:16:12 +00:00
Sergey Biryukov
86bff28a19 Script Loader: Ensure default packages are registered when loaded via load-scripts.php.
Props CantoThemes, ocean90.
Merges [43877] to trunk.
Fixes #45271.
Built from https://develop.svn.wordpress.org/trunk@44237


git-svn-id: http://core.svn.wordpress.org/trunk@44067 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 03:15:20 +00:00
Sergey Biryukov
c72f02aa49 TinyMCE:
- Fix parsing of the init array in script-loader.
- Do not JSON encode the options object when outputting it from PHP.
- Remove JSON decoding of TinyMCE's `style_formats` option.

Props azaozz.
Merges [43867] to trunk.
Fixes #45221.
Built from https://develop.svn.wordpress.org/trunk@44236


git-svn-id: http://core.svn.wordpress.org/trunk@44066 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 03:14:31 +00:00
atimmer
cc13a1f3a0 General: Fix code formatting issues.
Fix code formatting after [44174] and [44177].

Built from https://develop.svn.wordpress.org/trunk@44178


git-svn-id: http://core.svn.wordpress.org/trunk@44008 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-14 11:02:53 +00:00
atimmer
a603510b73 Build Tools: Upgrade @wordpress packages to the latest version.
This also includes the new @wordpress/format-library and @wordpress/notices packages.

package-lock.json has been completely regenerated in this commit.

Props pento.
Merges [43840] to trunk.
See #45145.

Built from https://develop.svn.wordpress.org/trunk@44177


git-svn-id: http://core.svn.wordpress.org/trunk@44007 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-14 10:55:01 +00:00
Gary Pendergast
5b16eb19a8 Script Loader: Add translator comments and remove textdomains.
The inline script for `wp-date` incorrectly included a textdomain, and lacked translator comments.

Merges [43831] from the 5.0 branch to trunk.

Props mukesh27.
Fixes #45191, #45162.


Built from https://develop.svn.wordpress.org/trunk@44171


git-svn-id: http://core.svn.wordpress.org/trunk@44001 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-14 05:58:52 +00:00
Gary Pendergast
47b6c4e0d7 Scripts: Revert some functions being incorrectly removed in [44163].
Built from https://develop.svn.wordpress.org/trunk@44164


git-svn-id: http://core.svn.wordpress.org/trunk@43994 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-14 04:53:54 +00:00
Gary Pendergast
bffe848347 Build Tools: Update the @wordpress/* packages.
Merges [43801,43803] from the 5.0 branch to trunk.

See #45145.


Built from https://develop.svn.wordpress.org/trunk@44163


git-svn-id: http://core.svn.wordpress.org/trunk@43993 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-14 04:44:01 +00:00
desrosj
ca80466039 Scripts: Add a missing date format to the wp-date config.
`wp-date` recently added the `datetimeAbbreviated` format, but the config wasn't sending it on page load.

Props pento.

Merges [43818] to trunk.

Fixes #45158.
Built from https://develop.svn.wordpress.org/trunk@44162


git-svn-id: http://core.svn.wordpress.org/trunk@43992 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-14 04:41:57 +00:00
desrosj
ed941d9ed4 General: Fix some code formatting issues.
A handful of code formatting issues were introduced in [44159], runs the auto-fixer on them.
Built from https://develop.svn.wordpress.org/trunk@44160


git-svn-id: http://core.svn.wordpress.org/trunk@43990 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-14 04:35:40 +00:00
Gary Pendergast
e4b570f8fb Build Tools: Copy package JavaScript and CSS into wp-includes.
- `grunt webpack:dev` now copies packages JS into `/src/wp-includes/js/dist`, and CSS into `/src/wp-includes/css/dist`.
- `grunt webpack:prod` does the same, but into `/build` instead of `/src`.
- `grunt build` now runs the `webpack:prod` task.

Merges [43760] from the 5.0 branch to trunk.

Props atimmer, pento.
Fixes #45119.


Built from https://develop.svn.wordpress.org/trunk@44159


git-svn-id: http://core.svn.wordpress.org/trunk@43989 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-14 04:11:47 +00:00
desrosj
102b13cdb9 Styles: Add helper functions for loading block styles.
Blocks are able to register styles that used in the editor and the frontend, or only in the editor. These functions ensure the correct styles are loaded in the correct place.

Props pento.

Merges [43812] to trunk.

See #45065.
Built from https://develop.svn.wordpress.org/trunk@44157


git-svn-id: http://core.svn.wordpress.org/trunk@43987 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-14 03:36:38 +00:00
Gary Pendergast
63ac8f65d8 Script Loader: Fix metadata being registered as an inline script.
[43723] included script metadata for the `wp-polyfill` script that was being registered as an inline script.

Merges [43802] from the 5.0 branch to trunk.

See #45065.


Built from https://develop.svn.wordpress.org/trunk@44143


git-svn-id: http://core.svn.wordpress.org/trunk@43973 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-14 02:02:37 +00:00
Jeremy Felt
f93e24ca8e REST API: Render response in user locale with ?_locale=user.
Introduces new `determine_locale()` function for deciding the proper locale to use for a response. Default value is `get_user_locale()` in the admin, and `get_locale()` on the frontend. Because REST API requests are considered frontend requests, `?_locale=user` can be used to render the response in the user's locale.

Also updates `wp-login.php?wp_lang` implementation to benefit from this abstraction.

Merges [43776] from the 5.0 branch to trunk.

Props flixos90, mnelson4, swissspidy, TimothyBlynJacobs.
Fixes #44758.

Built from https://develop.svn.wordpress.org/trunk@44134


git-svn-id: http://core.svn.wordpress.org/trunk@43964 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-14 01:32:39 +00:00
desrosj
6d620cd5e5 Script loading: Fix regression after [43738].
After [43738], TinyMCE would be loaded earlier than before, which makes filters run at a different time relative to the loading of TinyMCE. Fix this by calling `wp_print_scripts` at the location where TinyMCE would previously be inserted as a `<script>` tag in the page.

Also, an TinyMCE translation related `<script>` that was mistakenly removed in [44115].

Props azaozz, omarreiss, swisspidy, atimmer.

Merges [43753], [43754] to trunk.

Fixes #45065.
Built from https://develop.svn.wordpress.org/trunk@44119


git-svn-id: http://core.svn.wordpress.org/trunk@43949 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-13 22:23:17 +00:00
desrosj
5db34748e6 Script loader: Adjust JS packages registration.
Adjusts the packages registration after [43723]:

    Combine the different registration functions into one `wp_default_packages` function. To reach this goal move the prefix logic into a function so it can be called from different locations. Use a static variable there to prevent duplicate inclusion of `version.php`.

    Call this function from the `wp_default_scripts` action by registering it as a default filter.

    Combine some of the logic in `_WP_Editors::print_tinymce_scripts` into `wp_register_tinymce_scripts`. The logic to force an uncompressed TinyMCE script file stays in `_WP_Editors::force_uncompressed_tinymce` because that logic is very specific to the classic editor.

    The script handle `wp-tinymce` is now a dependency of the editor script handle. In combination with the previous item, this makes the classic editor work.

    Adjust the syntax of the script paths to be more consistent with other WordPress code.

    Always use "production" mode for the media files to prevent people from inadvertently committing development files.

Props pento, omarreiss, atimmer.

Merges [43738] into trunk.

Fixes #45065.
Built from https://develop.svn.wordpress.org/trunk@44115


git-svn-id: http://core.svn.wordpress.org/trunk@43945 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-13 17:27:38 +00:00
desrosj
4862c4aa96 Script loader: Register @wordpress scripts.
This allows the packages to be consumed by plugins and core itself.
The code has been based on the work done in the Gutenberg plugin.

We've added an array with all the packages and the vendor packages to
loop through. This sets a convention so all packages will be
registered in the same way. This array can eventually be generated by
a webpack plugin.

We need to register TinyMCE explicitly. Previously TinyMCE was used
by inserting custom `<script>` tags into the relevant admin pages.
This is not suitable for the new editor, so we need to explicitly
register TinyMCE. We could, in the future, refactor the custom
`<script>` tags to use the registered TinyMCE script instead.

Polyfills are inserted into the page only when necessary using
`document.write`.

Props omarreiss, herregroen, youknowriad, gziolo, atimmer.

Merges [43723] to trunk.

Fixes #45065.
Built from https://develop.svn.wordpress.org/trunk@44114


git-svn-id: http://core.svn.wordpress.org/trunk@43944 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-13 16:50:36 +00:00
Gary Pendergast
56c162fbc9 Coding Standards: Upgrade WPCS to 1.0.0
WPCS 1.0.0 includes a bunch of new auto-fixers, which drops the number of coding standards issues across WordPress significantly. Prior to running the auto-fixers, there were 15,312 issues detected. With this commit, we now drop to 4,769 issues.

This change includes three notable additions:
- Multiline function calls must now put each parameter on a new line.
- Auto-formatting files is now part of the `grunt precommit` script. 
- Auto-fixable coding standards issues will now cause Travis failures.

Fixes #44600.


Built from https://develop.svn.wordpress.org/trunk@43571


git-svn-id: http://core.svn.wordpress.org/trunk@43400 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-08-17 01:51:36 +00:00
Sergey Biryukov
6172dab7c1 I18N: Remove unused MediaElement.js strings.
Props metodiew.
See #42139. Fixes #37453.
Built from https://develop.svn.wordpress.org/trunk@43345


git-svn-id: http://core.svn.wordpress.org/trunk@43173 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-06-28 02:29:24 +00:00
Sergey Biryukov
8bc4e6d94f Privacy: Use the terms "erase"/"erasure" instead of "remove"/"removal" for personal data.
Props allendav.
Fixes #43920.
Built from https://develop.svn.wordpress.org/trunk@43175


git-svn-id: http://core.svn.wordpress.org/trunk@43004 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-05-07 16:45:22 +00:00
Andrew Ozz
b044b4053e Privacy: add means to export personal data by username or email address. Generate a zipped export file containing all data. First run.
Props allendav.
See #43546.
Built from https://develop.svn.wordpress.org/trunk@43012


git-svn-id: http://core.svn.wordpress.org/trunk@42841 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-04-27 19:54:21 +00:00
Andrew Ozz
b4fdb9ebf2 Privacy: add means to erase personal data by username or email address. First run.
Props allendav, coreymckrill, ericdaams, azaozz.
See #43637, #43602.
Built from https://develop.svn.wordpress.org/trunk@42986


git-svn-id: http://core.svn.wordpress.org/trunk@42815 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-04-18 22:30:22 +00:00
Andrea Fercia
ffedf3d752 Accessibility: Widgets: Make the "Available Widgets" section operable with a keyboard.
For a number of years, the "Available Widgets" section has been off-limits for
keyboard users. Now it can be used also with the keyboard. This change introduces
also some improvements for assistive technologies.

- makes the widget toggles focusable and adds an `aria-expanded` attribute to indicate their state
- improves the toggles labelling to clarify context (add/edit)
- changes the controls to choose a sidebar from list items to buttons
- adds an `aria-label` attribute to the buttons to clarify their purpose
- adds an `aria-pressed` attribute to the buttons to indicate which one is selected
- improves color contrast of the selected button
- uses a `wp.a11y.speak()` message to announce to screen reader users when a widget has been added to a sidebar
- moves focus back to the toggle button when closing a widget

See #40677.

Built from https://develop.svn.wordpress.org/trunk@42794


git-svn-id: http://core.svn.wordpress.org/trunk@42624 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-03-07 22:27:31 +00:00
Peter Wilson
e6ccdf161f General: Further improve error messages following [42648].
Props kristastevens, melchoyce.
Fixes #38332 for trunk.


Built from https://develop.svn.wordpress.org/trunk@42719


git-svn-id: http://core.svn.wordpress.org/trunk@42547 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-02-19 02:13:32 +00:00
Peter Wilson
0d39b35c11 General: Replace Cheatin’ uh? with friendlier error messages.
While intended as a playful error message, `Cheatin’ uh?` can be interpreted as insulting or accusatory in an already stressful situation. This replaces Cheatin’ with more meaningful error messages, depending on the error that occurs.

Props ElectricFeet, EricMeyer, karmatosed, dd32, BandonRandon, melchoyce for language; dmsnell for original patch; peterwilsoncc.
Fixes #38332.


Built from https://develop.svn.wordpress.org/trunk@42648


git-svn-id: http://core.svn.wordpress.org/trunk@42477 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-02-05 02:30:34 +00:00
Adam Silverstein
39575cede2 Correct the version term_search_min_chars changed. Ammends r42614.
Built from https://develop.svn.wordpress.org/trunk@42616


git-svn-id: http://core.svn.wordpress.org/trunk@42445 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-01-30 00:30:30 +00:00
Adam Silverstein
86434ebca4 Taxonomy: Use REST API for ajax tag search.
Deprecate wp_ajax_ajax_tag_search and switch to using the REST API when searching tags in the tags meta box.

Props nacin, chriscct7, afercia, swissspidy, jnylen0, rmccue, ryelle.
Fixes #38922.


Built from https://develop.svn.wordpress.org/trunk@42614


git-svn-id: http://core.svn.wordpress.org/trunk@42443 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-01-30 00:17:31 +00:00
Aaron Jorbin
9efeb545c0 Remove JSHint due to license compatibility
JSHint inherits a license from JSLint that includes the clause  "The Software shall be used for Good, not Evil." WordPress's license specifically allows grants the freedom to run the program, for any purpose. Please note, this is not an encouragement of evil. Rather than doing something evil, how about learning to love those around you. Instead of tweeting lies and saying people are "Not Good!", help your neighbor. In the words of Lin Manual Miranda, "Love is love is love is love is love is love is love is love, cannot be killed or swept aside." 

This replaces JSHint with esprima, a part of the larger jQuery project, and a custom wrapper for some basic error checking within codemirror.

The existing JSHint configuration is kept in place in case someone wants to use that, but they can only do so for Good.

Fixes #42850
Props netweb for a spelling fix on a comment.


Built from https://develop.svn.wordpress.org/trunk@42547


git-svn-id: http://core.svn.wordpress.org/trunk@42376 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-01-23 01:29:32 +00:00
Gary Pendergast
aaf99e6913 Code is Poetry.
WordPress' code just... wasn't.
This is now dealt with.

Props jrf, pento, netweb, GaryJ, jdgrimes, westonruter, Greg Sherwood from PHPCS, and everyone who's ever contributed to WPCS and PHPCS.
Fixes #41057.


Built from https://develop.svn.wordpress.org/trunk@42343


git-svn-id: http://core.svn.wordpress.org/trunk@42172 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-11-30 23:11:00 +00:00
John Blackbourn
d8a995fc15 Media: Further improvements to the handling of language codes that get passed to MediaElement.
This change means that only the leading portion of a locale code gets passed to MediaElement, removing problems that arise from locales such as `de_DE_formal` and `pt_PT_ao90`.

Props erich_k4wp, blobfolio, flixos90, ocean90, joemcgill, SergeyBiryukov.

Fixes #42574

Built from https://develop.svn.wordpress.org/trunk@42251


git-svn-id: http://core.svn.wordpress.org/trunk@42080 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-11-28 14:52:51 +00:00
Weston Ruter
4e320fe008 I18N: Fix passing singular/plural strings to JS.
This is a temporary solution while waiting for full I18N support in JS.

Props ocean90, dd32, westonruter, Mirucon for testing.
Amends [41376], [41721], [41389],
See #20491.
Fixes #42510 for trunk.

Built from https://develop.svn.wordpress.org/trunk@42163


git-svn-id: http://core.svn.wordpress.org/trunk@41994 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-11-13 07:08:47 +00:00
Weston Ruter
ca84147401 Customize: Allow 0:00-0:59 in date/time control when 24-hour time used.
* Let min hour be 0 and max be 23 in 24-hour time; let min hour be 1 and max be 12 in 12-hour time.
* Show error notification when an invalid date value is provided, not just when not a future date.
* Fix translation of custom validity message.
* Start checking for validity after all inputs have been initially populated.
* Remove support for being able to enter 24:00.
* Cease forcing date input elements from being casted to integers, to allow for invalid inputs to be detected.

Props westonruter, Presskopp, peterwilsoncc, atachibana for testing.
See #39896, #28721.
Fixes #42373.

Built from https://develop.svn.wordpress.org/trunk@42042


git-svn-id: http://core.svn.wordpress.org/trunk@41876 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-30 16:40:47 +00:00
Weston Ruter
a6af74ec32 Customize: Register the Publish Settings section in JS to ensure it does not get unregistered via PHP.
The `publish_settings` section is a fundamental dependency for Customizer, so it must be guaranteed to be registered.

Also unconditionally register core types for panels, sections, and controls in case plugin unhooks all `customize_register` actions.

See #39896.
Fixes #42337.

Built from https://develop.svn.wordpress.org/trunk@42025


git-svn-id: http://core.svn.wordpress.org/trunk@41859 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-25 21:45:49 +00:00
Sergey Biryukov
29d5ee851c I18N: Use a consistent pattern for translator comments for placeholders in some more Customizer strings.
See #41974.
Built from https://develop.svn.wordpress.org/trunk@42006


git-svn-id: http://core.svn.wordpress.org/trunk@41840 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-24 22:47:46 +00:00
Sergey Biryukov
f156f90ff5 I18N: Add a context for remaining "Schedule" strings.
Props Mirucon.
Fixes #42165.
Built from https://develop.svn.wordpress.org/trunk@42005


git-svn-id: http://core.svn.wordpress.org/trunk@41839 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-24 22:35:47 +00:00
Weston Ruter
6737643773 Customize: Prevent theme installation and deletion in Customizer while SFTP credentials need to be requested.
This is a temporary measure while we wait for credentials to be able to be supplied in the Customizer.

Amends [41788].
See #42184, #37661, #42126.

Built from https://develop.svn.wordpress.org/trunk@41997


git-svn-id: http://core.svn.wordpress.org/trunk@41831 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-24 19:06:47 +00:00
Weston Ruter
c364743d35 Code Editor: Add underscore as a dependency for the code-editor script.
Amends [41376].
See #12423.

Built from https://develop.svn.wordpress.org/trunk@41977


git-svn-id: http://core.svn.wordpress.org/trunk@41811 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-23 20:38:47 +00:00
Weston Ruter
81c87e7d5e Code Editor: Improve ability to create Customizer CodeEditorControl instances in JS, lessening PHP dependencies.
Allow `CodeEditorControl` to be instantiated with a `editor_settings` param which is merged with `wp.codeEditor.defaultSettings`.

Also:

* Turn redundant "CSS Code" control label into screen reader text for Additional CSS.
* Remove `code-editor` as script dependency for `custom-html-widgets` since enqueueing is determined by `wp_enqueue_code_editor()`.
* Remove useless exporting of `code_type` param to JS in `WP_Customize_Code_Editor_Control`.
* Add `disabled` class to Custom HTML widget's Save button when linting errors are present.
* Remove redundant `span` inside CodeEditorControl's `label`.

See #41897, #12423, #41872.

Built from https://develop.svn.wordpress.org/trunk@41957


git-svn-id: http://core.svn.wordpress.org/trunk@41791 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-20 16:39:48 +00:00
Sergey Biryukov
82dd23d36f I18N: Make context for "Schedule" string added in [41898] more accurate.
Props ocean90.
Fixes #42165.
Built from https://develop.svn.wordpress.org/trunk@41905


git-svn-id: http://core.svn.wordpress.org/trunk@41739 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-18 15:39:52 +00:00
Sergey Biryukov
97bab0459a I18N: Add a context for "Schedule" string.
Props Mirucon.
Fixes #42165.
Built from https://develop.svn.wordpress.org/trunk@41898


git-svn-id: http://core.svn.wordpress.org/trunk@41732 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-18 14:45:51 +00:00
Weston Ruter
dce5306603 Media: Use user locale as ME.js language in admin and add mejsL10n inline script before mediaelement-core so WP-exported translation strings are used.
See #39686.
Fixes #42241.

Built from https://develop.svn.wordpress.org/trunk@41889


git-svn-id: http://core.svn.wordpress.org/trunk@41723 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-18 00:08:45 +00:00
John Blackbourn
24783cfc3e Media: Allow the unminified mediaelement script to be enqueued when SCRIPT_DEBUG is true.
Props dsawardekar
Fixes #42229

Built from https://develop.svn.wordpress.org/trunk@41879


git-svn-id: http://core.svn.wordpress.org/trunk@41713 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-16 18:15:47 +00:00
Andrea Fercia
575e60e96c Administration: Improve consistency of the "not found" strings.
Partially reverts [41608] restoring the original strings without the word `query`.

See #37430.
Fixes #42231.

Built from https://develop.svn.wordpress.org/trunk@41878


git-svn-id: http://core.svn.wordpress.org/trunk@41712 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-16 18:14:48 +00:00
Weston Ruter
2e602a8560 Media: Add MediaElement.js 2.2 back-compat for MediaElement.js 4.2
* Introduces `mediaelement-migrate.js`.
* Upgrades ME.js from 4.2.5-74e01a40 to 4.2.6-78496d1.

Props rafa8626, bradyvercher.
See #39686.
Fixes #42189.

Built from https://develop.svn.wordpress.org/trunk@41877


git-svn-id: http://core.svn.wordpress.org/trunk@41711 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-16 18:07:52 +00:00
Andrea Fercia
4085a1b266 Accessibility: Improve the File Editors interstitial warning.
The warning displayed upon first visit on the File Editors introduced in [41774]
needs to be the only perceivable content in the page for users of assistive
technologies. It looks like a modal but it's not exactly an ARIA dialog, not an
ARIA alert either, and needs some special treatment.

- constrains tabbing within the modal
- uses `wp.a11y.speak()` to make screen readers announce the modal message
- hides all the other page content from assistive technologies using `aria-hidden="true"`

This way, even if users miss the speak message, the warning is actually the only
perceivable content in the page.

Fixes #42110.

Built from https://develop.svn.wordpress.org/trunk@41876


git-svn-id: http://core.svn.wordpress.org/trunk@41710 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-16 17:59:52 +00:00
Gary Pendergast
af83fe7fb9 Editor: Improve the accuracy of the list of shortcodes that the word count ignores.
Previously, shortcodes were being counted when the `init` action fired, even though it's possible for shortcodes to be registered later than that.

By leaving the counting until just before the script is printed, we get a more accurate list of shortcodes.

Props ocean90.
Fixes #41917.


Built from https://develop.svn.wordpress.org/trunk@41844


git-svn-id: http://core.svn.wordpress.org/trunk@41678 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-12 05:10:50 +00:00
Weston Ruter
434e3aba82 Customize: Add changeset locking in Customizer to prevent users from overriding each other's changes.
* Customization locking is checked when changesets are saved and when heartbeat ticks.
* Lock is lifted immediately upon a user closing the Customizer.
* Heartbeat is introduced into Customizer.
* Changes made to user after it was locked by another user are stored as an autosave revision for restoration.
* Lock notification displays link to preview the other user's changes on the frontend.
* A user loading a locked Customizer changeset will be presented with an option to take over.
* Autosave revisions attached to a published changeset are converted into auto-drafts so that they will be presented to users for restoration.
* Focus constraining is improved in overlay notifications.
* Escape key is stopped from propagating in overlay notifications, and it dismisses dismissible overlay notifications.
* Introduces `changesetLocked` state which is used to disable the Save button and suppress the AYS dialog when leaving the Customizer.
* Fixes bug where users could be presented with each other's autosave revisions.

Props sayedwp, westonruter, melchoyce.
See #31436, #31897, #39896.
Fixes #42024.

Built from https://develop.svn.wordpress.org/trunk@41839


git-svn-id: http://core.svn.wordpress.org/trunk@41673 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-12 04:01:46 +00:00
Weston Ruter
1a22fb3b60 File Editor: Increase robustness of fatal error checking when saving PHP file edits.
* Increase PHP execution time limit prior to issuing loopback requests where are themselves given timeouts to ensure PHP file can be reverted.
* Output scrape messages on success and failure so that absence of either can also be flagged as an error condition.
* Forward browser's HTTP Basic Auth credentials in loopback requests to admin and home URL.
* Display more helpful message when loopback request fails.

Amends [41721].
See #21622.
Fixes #42102.

Built from https://develop.svn.wordpress.org/trunk@41805


git-svn-id: http://core.svn.wordpress.org/trunk@41639 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-10 05:27:49 +00:00
Weston Ruter
35b5c9e762 Customize: Eliminate use of customize-loader in core so Customizer is opened consistently in top window.
* Open the door for future browser history feature in #28536, which is currently not feasible when customize-loader is used.
* Remove customizer-loader from being used on admin screens for Dashboard, Themes, non-shiny theme install/update.
* Keep the customize-loader functionality available for plugins, for the time being. It may become deprecated.
* Ensure `return` param in customizer links in Themes screen update to reflect `search` updated by `pushState`.
* Persist `return` when reloading Customizer due to theme switch, autosave restoration, or changeset trashing.
* Use `location.replace()` instead of changing `location.href` when trashing.
* Hide theme browser while Themes screen is loading when there is a `search` to prevent flash of unfiltered themes.
* Use throttling instead of debouncing when searching themes to ensure that screen is updated immediately on page load.
* Fix encoding and decoding of `search` param between URL and search field.
* Add support for dismissing autosaves when closing customize-loader, when it is used by plugins.
* Skip sending changeset UUID to customize-loader for population in browser location if changeset branching is not enabled.

See #28536.
Fixes #40254.

Built from https://develop.svn.wordpress.org/trunk@41797


git-svn-id: http://core.svn.wordpress.org/trunk@41631 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-09 16:04:48 +00:00
Dominik Schilling
3bee2912ea Customize: Use a consistent translator comment for the same strings.
See #21492.
Built from https://develop.svn.wordpress.org/trunk@41791


git-svn-id: http://core.svn.wordpress.org/trunk@41625 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-08 16:23:46 +00:00
Weston Ruter
a01ae9a8c3 Customize: Fix confusion related to visibility of Themes panel with drafted/scheduled changesets.
* Prevent autoloading an existing draft/future changeset when theme not active.
* Add missing notifications container to Themes panel.
* Remove deactivation of themes panel when selected status is not publish.
* Show notification in Themes panel when themes cannot be previewed and disable preview buttons.
* Reject installTheme call when theme preview not available.
* Return promise from installTheme and eliminate use of global events in favor of promises.

Props westonruter, melchoyce, zoonini.
See #37661, #39896.
Fixes #42126.


Built from https://develop.svn.wordpress.org/trunk@41788


git-svn-id: http://core.svn.wordpress.org/trunk@41622 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-07 06:00:54 +00:00
Weston Ruter
9d6134a88c Customize: Add default control template for standard input types.
Re-use default template instead of introducing custom one for the Discard Changes button.

See #30738.

Built from https://develop.svn.wordpress.org/trunk@41771


git-svn-id: http://core.svn.wordpress.org/trunk@41605 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-05 02:56:47 +00:00
Adam Silverstein
0a431ea356 Revert "Add wp.hooks - JavaScript actions and filters."
Revert `wp.hooks` for now as we continue to refine and test. 

Reverts [41375].

Built from https://develop.svn.wordpress.org/trunk@41751


git-svn-id: http://core.svn.wordpress.org/trunk@41585 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-04 20:25:49 +00:00
Weston Ruter
f5bc1d1f52 Customize: Allow controls to be created with pre-instantiated Setting object(s), or even with plain Value object(s).
* Allow passing settings in keyed object (e.g. `settings: { default: 'id' }  ), or as an array (e.g. `settings: [ 'id' ]`) with first being default; again, `Setting`/`Value` objects may be supplied instead of IDs.
* Allow a single setting to be supplied with just a single `setting` param, either a string or a `Setting`/`Value` object.
* Update `changeset_status` and `scheduled_changeset_date` to be added dynamically with JS and simply passing of `api.state()` instances as `setting`.
* Introduce a `data-customize-setting-key-link` attribute which, unlike `data-customize-setting-link`, allows passing the setting key (e.g. `default`) as opposed to the setting ID.
* Allow `WP_Customize_Control::get_link()` to return `data-customize-setting-key-link` when setting is not registered.
* Eliminate `default_value` from `WP_Customize_Date_Time_Control` since now comes from supplied `Value`.
* Export status choices as `wp.customize.settings.changeset.statusChoices`.
* Export date and time formats as `wp.customize.settings.dateFormat` and `wp.customize.settings.timeFormat` respectively.

Props westonruter, sayedwp.
See #39896, #30738, #30741, #42083.
Fixes #37964, #36167.

Built from https://develop.svn.wordpress.org/trunk@41750


git-svn-id: http://core.svn.wordpress.org/trunk@41584 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-04 20:02:49 +00:00
Weston Ruter
5f7a5c1246 File Editors: Introduce sandboxed live editing of PHP files with rollbacks for both themes and plugins.
* Edits to active plugins which cause PHP fatal errors will no longer auto-deactivate the plugin. Supersedes #39766.
* Introduce sandboxed PHP file edits for active themes, preventing accidental whitescreening of a user's site when introducing a fatal error.
* After writing a change to a PHP file for an active theme or plugin, perform loopback requests on the file editor admin screens and the homepage to check for fatal errors. If a fatal error is encountered, roll back the edited file and display the error to the user to fix and try again.
* Introduce a secure way to scrape PHP fatal errors from a site via `wp_start_scraping_edited_file_errors()` and `wp_finalize_scraping_edited_file_errors()`.
* Moves file modifications from `theme-editor.php` and `plugin-editor.php` to common `wp_edit_theme_plugin_file()` function.
* Refactor themes and plugin editors to submit file changes via Ajax instead of doing full page refreshes when JS is available.
* Use `get` method for theme/plugin dropdowns.
* Improve styling of plugin editors, including width of plugin/theme dropdowns.
* Improve notices API for theme/plugin editor JS component.
* Strip common base directory from plugin file list. See #24048.
* Factor out functions to list editable file types in `wp_get_theme_file_editable_extensions()` and `wp_get_plugin_file_editable_extensions()`.
* Scroll to line in editor that has linting error when attempting to save. See #41886.
* Add checkbox to dismiss lint errors to proceed with saving. See #41887.
* Only style the Update File button as disabled instead of actually disabling it for accessibility reasons.
* Ensure that value from CodeMirror is used instead of `textarea` when CodeMirror is present.
* Add "Are you sure?" check when leaving editor when there are unsaved changes.

Supersedes [41560].
See #39766, #24048, #41886.
Props westonruter, Clorith, melchoyce, johnbillion, jjj, jdgrimes, azaozz.
Fixes #21622, #41887.

Built from https://develop.svn.wordpress.org/trunk@41721


git-svn-id: http://core.svn.wordpress.org/trunk@41555 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-04 00:20:45 +00:00
Weston Ruter
8d79246606 Customize: Add button in Publish Settings to discard unsaved changes (including drafted and scheduled), reverting Customizer to the last published state.
Props westonruter, melchoyce.
Amends [41667].
See #39896, #21666.

Built from https://develop.svn.wordpress.org/trunk@41694


git-svn-id: http://core.svn.wordpress.org/trunk@41528 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-03 00:22:49 +00:00
Weston Ruter
728e44ab5a Customize: Add infrastructure for trashing/reverting of unpublished changes; introduce full-screen OverlayNotification for trashing and theme install/preview.
* Introduce a new `wp.customize.previewer.trash()` JS API to trash the current changeset, along with logic to `WP_Customize_Manager` to handle deleting changeset drafts.
* Add `trashing` to `wp.customize.state` which is then used to update the UI.
* UI for trashing is pending design feedback. One possibility is to add a new trash button to Publish Settings section that invokes `wp.customize.previewer.trash()`.
* Improve logic for managing the visibility and disabled states for publish buttons.
* Prevent attempting `requestChangesetUpdate` while processing and bump processing while doing `save`.
* Update `changeset_date` state only if sent in save response.
* Merge `ThemesSection#loadThemePreview()` into `ThemesPanel#loadThemePreview()`.
* Remove unused `autosaved` state.
* Start autosaving and prompting at beforeunload after a change first happens. This is key for theme previews since even if a user did not make any changes, there were still dirty settings which would get stored in an auto-draft unexpectedly.
* Allow `Notification` to accept additional `classes` to be added to `container`.
* Introduce `OverlayNotification` and use for theme installing, previewing, and trashing. Such overlay notifications take over the entire window.

Props westonruter, celloexpressions.
See #37661, #39896, #21666, #35210.

Built from https://develop.svn.wordpress.org/trunk@41667


git-svn-id: http://core.svn.wordpress.org/trunk@41501 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-02 03:37:46 +00:00
Sergey Biryukov
10c46f5751 I18N: Use a consistent pattern for translator comments for placeholders in Customizer and widget strings.
Props danieltj, Rahmohn.
Fixes #41974.
Built from https://develop.svn.wordpress.org/trunk@41640


git-svn-id: http://core.svn.wordpress.org/trunk@41474 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-09-29 11:42:48 +00:00
Weston Ruter
8043c2d8e5 Customize: Introduce drafting and scheduling for Customizer changesets.
* Incorporates code from the Customize Snapshots and Customize Posts feature plugins.
* Adds a new Publish Settings section for managing the changeset status, scheduled date, and frontend preview link.
* Updates Publish button to reflect the status selected in the Publish Settings (including Save Draft and Schedule).
* Deactivates the Themes section when a non-publish status selected, and deactivates the Publish Settings section when previewing a theme switch.
* Introduces an `outer` section type (`wp.customize.OuterSection` in JS) for the Publish Settings section to use and for available widgets and available nav menu panels to use in the future. These sections can be expanded while other sections are expanded.
* Introduces `WP_Customize_Date_Time_Control` in PHP and `wp.customize.DateTimeControl` in JS for managing a date/time value.
* Keeps track of scheduled time and proactively publish from the client when the time arrives, as opposed to waiting for WP Cron.
* Auto-publishes a scheduled changeset when attempting to access one that missed its schedule.
* Starts a new changeset if attempting to save a changeset that was previously publish.
* Adds `force` arg to `requestChangesetUpdate()` to force an update request even when there are no pending changes.
* Adds utils methods for `getCurrentTimestamp` and `getRemainingTime`.
* Adds new state values for `selectedChangesetStatus`, `changesetDate`, `selectedChangesetDate`.
* Fixes logic for when to short-circuit check to close Customizer when there are unsaved changes.
* Adds getter methods for `autosaved` and `branching` parameters, with the latter applying the `customize_changeset_branching` filter.
* Call to `establish_loaded_changeset` on the fly when `changeset_uuid()` is called if no changeset UUID was specififed.
* De-duplicates logic for dismissing auto-draft changesets.
* Includes unit tests.

Builds on [41597].
Props sayedwp, westonruter, melchoyce, JoshuaWold, folletto, stubgo, karmatosed, dlh, paaljoachim, afercia, johnregan3, utkarshpatel, valendesigns.
See #30937.
Fixes #39896, #28721, #39275.

Built from https://develop.svn.wordpress.org/trunk@41626


git-svn-id: http://core.svn.wordpress.org/trunk@41461 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-09-27 22:25:46 +00:00
Pascal Birchler
1f5c7470fb Plugins: Improve error messages on plugins screen.
This unifies the layout and wording of error messages on both the plugins screen and the themes screen.

Props tinkerbelly, juhise, Ankit K Gupta, m1tk00, swissspidy, mrahmadawais, danieltj.
Fixes #37430.

Built from https://develop.svn.wordpress.org/trunk@41608


git-svn-id: http://core.svn.wordpress.org/trunk@41443 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-09-27 08:46:45 +00:00