Commit Graph

16759 Commits

Author SHA1 Message Date
Sergey Biryukov
0ffce72ed0 Help/About: Add strings for 5.4 About page.
Props elmastudio, chanthaboune, francina, marybaum, audrasjb.
See #49295.

git-svn-id: https://develop.svn.wordpress.org/trunk@47422 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-03 21:20:45 +00:00
Jorge Costa
ae5596bf0a Editor: Update WordPress packages to make editor full-screen by default.
The following package versions were changed:
@wordpress/e2e-test-utils: 4.3.0 -> 4.3.1
@wordpress/edit-post: 3.13.3 -> 3.13.4
This commit update allows the following PR to be part of trunk https://github.com/WordPress/gutenberg/pull/20611.

Props youknowriad, mcsf, mapk.
Fixes: #49574.

git-svn-id: https://develop.svn.wordpress.org/trunk@47421 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-03 20:43:49 +00:00
Sergey Biryukov
60f78cd845 Privacy: Prevent unexpected scrolling when clicking the "Copy this section to clipboard" button on Privacy Policy Guide screen.
Props garrett-eclipse, birgire, davidbaumwald, pbiron.
Fixes #49540.

git-svn-id: https://develop.svn.wordpress.org/trunk@47420 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-03 17:49:53 +00:00
Sergey Biryukov
7dd3e6edd9 Media: Improve the appearance of image editor on small and medium screens.
This prevents the main area of Edit Media screen from being pushed down too far.

Props sabernhardt, afercia, fierevere, sathyapulse, mikeschroder, johnbillion.
Fixes #48780. See #47136.

git-svn-id: https://develop.svn.wordpress.org/trunk@47418 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-03 17:19:55 +00:00
Jorge Costa
ac4de42983 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.

git-svn-id: https://develop.svn.wordpress.org/trunk@47416 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-03 16:53:32 +00:00
Sergey Biryukov
360c98280c Site Health: Fix typo in Site Health Status dashboard widget.
Follow-up to [47063], [47413].

Props Clorith, dlh.
See #49562.

git-svn-id: https://develop.svn.wordpress.org/trunk@47415 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-03 12:20:35 +00:00
Sergey Biryukov
cd84eaac26 Docs: Correct formatting of some DocBlocks in Plugin_Upgrader and Theme_Upgrader per the documentation standards.
See #49400.

git-svn-id: https://develop.svn.wordpress.org/trunk@47414 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-03 11:38:00 +00:00
Sergey Biryukov
288f5234e9 Site Health: Improve the strings in Site Health Status dashboard widget.
Follow-up to [47063].

Props dlh.
Fixes #49562.

git-svn-id: https://develop.svn.wordpress.org/trunk@47413 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-03 11:20:00 +00:00
John Blackbourn
e45162e496 Privacy: Fix the URLs and legacy redirects for the personal data export and erasure screens.
Props Jurgen Oldenburg, garrett-eclipse

Fixes #49476

git-svn-id: https://develop.svn.wordpress.org/trunk@47412 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-03 00:48:21 +00:00
John Blackbourn
e9c74d09c8 Privacy: Reintroduce consistency to the styling of suggested privacy text from core and plugins.
Props garrett-eclipse

Fixes #49282

git-svn-id: https://develop.svn.wordpress.org/trunk@47411 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-03 00:40:27 +00:00
John Blackbourn
b20dd081ba Editor: Revert a fix for incorrect usage of ID attributes on custom fields.
This reverts [47222] due to compatibility issues with plugins which are using the `#poststuff` selector.

See #46964

git-svn-id: https://develop.svn.wordpress.org/trunk@47410 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-03 00:35:41 +00:00
John Blackbourn
0fcbdc1e2d Upgrade/Install: Improved inline docs for the plugin and theme updater maintenance mode functionality.
Props bookdude13

See #49400

git-svn-id: https://develop.svn.wordpress.org/trunk@47409 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-03 00:27:52 +00:00
Jorge Costa
8bee6a4860 Block Editor: Update WordPress Packages WordPress 5.4 RC 1.
The following package versions were changed:
@wordpress/annotations: 1.12.0 -> 1.12.1
@wordpress/block-directory: 1.5.2 -> 1.5.3
@wordpress/block-editor: 3.7.2 -> 3.7.3
@wordpress/block-library: 2.14.2 -> 2.14.3
@wordpress/blocks: 6.12.0 -> 6.12.1
@wordpress/components: 9.2.2 -> 9.2.3
@wordpress/core-data: 2.12.0 -> 2.12.1
@wordpress/data: 4.14.0 -> 4.14.1
@wordpress/data-controls: 1.8.0 -> 1.8.1
@wordpress/edit-post: 3.13.2 -> 3.13.3
@wordpress/editor: 9.12.2 -> 9.12.3
@wordpress/format-library: 1.14.2 -> 1.14.3
@wordpress/keyboard-shortcuts: 1.1.0 -> 1.1.1
@wordpress/list-reusable-blocks: 1.13.2 -> 1.13.3
@wordpress/notices: 2.0.0 -> 2.0.1
@wordpress/nux: 3.12.2 -> 3.12.3
@wordpress/priority-queue: 1.5.0 -> 1.5.1
@wordpress/rich-text: 3.12.0 -> 3.12.1
@wordpress/server-side-render: 1.8.2 -> 1.8.3
@wordpress/viewport: 2.13.0 -> 2.13.1

Props aduth.
Fixes: #49567.

git-svn-id: https://develop.svn.wordpress.org/trunk@47408 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-02 23:19:06 +00:00
John Blackbourn
ef878b59c9 Feeds: Remove an unreachable condition when generating archive feed links.
Props donmhico, pbiron

Fixes #48427

git-svn-id: https://develop.svn.wordpress.org/trunk@47406 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-02 18:50:22 +00:00
Ian Belanger
3c5d847872 Bundled Themes: Update calendar widget styles for 5.4 markup.
Fixes the alignment of month links in the calendar widget with the changes in version 5.4 for all Bundled Themes, except Twenty Thirteen, which was already fixed in #49546.

Props sabernhardt.
Fixes #49549.

git-svn-id: https://develop.svn.wordpress.org/trunk@47405 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-02 16:53:36 +00:00
Sergey Biryukov
3feb885ec3 Docs: Use more specific type in parameter descriptions for is_page(), is_single(), is_singular(), and their WP_Query counterpart methods.
Props marekdedic, shaharia.azam, shaampk1.
Fixes #48354. See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47402 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-01 17:27:03 +00:00
Sergey Biryukov
6c33566c05 Docs: Synchronize parameter descriptions for conditional tags with their WP_Query counterpart methods.
See #48354, #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47401 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-01 17:19:58 +00:00
Sergey Biryukov
f327466200 Docs: Use more specific type in parameter description for wp_unslash().
Props marekdedic.
See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47400 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-01 16:23:24 +00:00
Sergey Biryukov
a7c0d2c8fc Docs: Use more specific type in description for _WP_Dependency::$deps.
Props marekdedic.
See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47399 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-01 16:22:51 +00:00
John Blackbourn
ac6cb23470 Docs: Miscellaneous docs fixes and improvements.
See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47398 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-01 10:38:00 +00:00
John Blackbourn
78a6e4febb Docs: Use more specific types in parameter descriptions in place of mixed.
See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47397 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-01 10:36:38 +00:00
John Blackbourn
ba57b0141c Docs: Correct the parameter documentation of the request_filesystem_credentials filter.
See #48303

git-svn-id: https://develop.svn.wordpress.org/trunk@47396 602fd350-edb4-49c9-b593-d223f7449a82
2020-03-01 10:31:31 +00:00
Sergey Biryukov
5f23c79b1d Privacy: Make the progress indicator for export and erasure visible even if not hovered over.
Follow-up to [47246].

Props pbiron, garrett-eclipse.
Fixes #44264.

git-svn-id: https://develop.svn.wordpress.org/trunk@47395 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-29 23:43:57 +00:00
John Blackbourn
b7bc6f7bb0 Docs: Correct and improve the docs for some media related functions.
See #48303

git-svn-id: https://develop.svn.wordpress.org/trunk@47394 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-29 16:47:44 +00:00
Ian Belanger
b4d0da91f7 Bundled Themes: Twenty Twenty searchform.php error.
Fixes phpcs error in the searchform.php file. The variables in this file were not prefixed correctly.

Props fahimmurshed.
Fixes #49523.

git-svn-id: https://develop.svn.wordpress.org/trunk@47393 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-28 20:54:42 +00:00
Ian Belanger
a00d79a07d Bundled Themes: Twenty Thirteen update calendar widget styles for 5.4 markup.
Fixes the alignment of month links in the calendar widget with the changes in version 5.4

Props sabernhardt.
Fixes #49546.

git-svn-id: https://develop.svn.wordpress.org/trunk@47392 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-28 20:05:39 +00:00
Sergey Biryukov
b54d5925ce Docs: Improve documentation for WP_REST_Attachments_Controller.
This adds a missing DocBlock for `::register_routes()` and parameter descriptions for `::post_process_item()`.

Includes minor documenation fixes in other REST API classes for consistency.

Props dkarfa, mukesh27, SergeyBiryukov.
Fixes #48841.

git-svn-id: https://develop.svn.wordpress.org/trunk@47391 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-28 12:29:53 +00:00
Sergey Biryukov
697127203b Docs: Improve documentation for various metadata functions.
This adds a more specific description for accepted object types: `post`, `comment`, `term`, `user`, or any other object type with an associated meta table.

Props sheparddw, kraftbj, DrewAPicture, SergeyBiryukov.
Fixes #45464.

git-svn-id: https://develop.svn.wordpress.org/trunk@47390 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-28 12:12:58 +00:00
Sergey Biryukov
559ccdda0c Twenty Twenty: Replace quotation marks in starter content with HTML entities.
Props fahimmurshed.
Fixes #49534.

git-svn-id: https://develop.svn.wordpress.org/trunk@47388 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-27 21:58:54 +00:00
Sergey Biryukov
ef613db765 Docs: Add a reference to WP_Customize_Panel::__construct() for information on accepted arguments in WP_Customize_Manager::add_panel().
Synchronize the documentation between two places, use `WP_Customize_Panel::__construct()` as the canonical source.

Props iaaxpage, marekdedic.
Fixes #48344.

git-svn-id: https://develop.svn.wordpress.org/trunk@47387 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-27 20:34:49 +00:00
Sergey Biryukov
19bdff7326 Docs: Add a reference to WP_Customize_Section::__construct() for information on accepted arguments in WP_Customize_Manager::add_section().
Synchronize the documentation between two places, use `WP_Customize_Section::__construct()` as the canonical source.

Props amolv, marekdedic.
Fixes #48346.

git-svn-id: https://develop.svn.wordpress.org/trunk@47386 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-27 20:27:45 +00:00
Sergey Biryukov
33b88a7c7f Docs: Clarify the type of theme_supports argument in various Customizer classes.
Props marekdedic.
See #48347.

git-svn-id: https://develop.svn.wordpress.org/trunk@47385 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-27 20:21:35 +00:00
Sergey Biryukov
9793244c74 Docs: Add a reference to WP_Customize_Setting::__construct() for information on accepted arguments in WP_Customize_Manager::add_setting().
Synchronize the documentation between two places, use `WP_Customize_Setting::__construct()` as the canonical source.

Props tmanoilov, marekdedic.
Fixes #48347.

git-svn-id: https://develop.svn.wordpress.org/trunk@47384 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-27 20:07:31 +00:00
Sergey Biryukov
bd71eb4b74 Docs: Use a consistent description for the $manager parameter in various Customizer class constructions.
See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47383 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-26 15:31:19 +00:00
Sergey Biryukov
aab2667898 Docs: Add a @see reference to WP_Customize_Control::__construct() in child class constructors.
Follow-up to [47363], [47364].

See #48343, #48348.

git-svn-id: https://develop.svn.wordpress.org/trunk@47382 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-26 13:29:01 +00:00
Andrew Ozz
3a4faa975f Build Tools: Do not delete the (now committed) script-loader-packages.php file when running clean:js and copy it to /build. Fixes cases when running grunt watch or -dev where that file may be deleted and not recreated.
See #48154.

git-svn-id: https://develop.svn.wordpress.org/trunk@47380 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-26 05:13:05 +00:00
Jorge Costa
0975f8e79b Post WordPress 5.4 Beta 3 version bump.
git-svn-id: https://develop.svn.wordpress.org/trunk@47379 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 22:11:55 +00:00
Jorge Costa
16aa8bbcce WordPress 5.4 Beta 3.
git-svn-id: https://develop.svn.wordpress.org/trunk@47378 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 21:54:53 +00:00
Sergey Biryukov
762dc39878 Block Editor: Update wp-includes/assets/script-loader-packages.php.
Follow-up to [47352], [47354].

Props aduth, ocean90, garrett-eclipse.
Fixes #49506.

git-svn-id: https://develop.svn.wordpress.org/trunk@47377 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 21:43:57 +00:00
Sergey Biryukov
0347132f12 Privacy: Switch buttons in Next Steps column of privacy request tables to break-word for better legibility on various screen sizes.
Props garrett-eclipse, afercia, nrqsnchz.
Fixes #46304.

git-svn-id: https://develop.svn.wordpress.org/trunk@47376 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 20:59:08 +00:00
Sergey Biryukov
ccb7aec7fc Accessibility: Media: Hide the invisible "file upload button" on media views from assistive technologies.
The button is visually hidden, but was announced by screen readers in workflows unrelated to file uploading, leading to confusion.

Props afercia, audrasjb, azaozz.
Fixes #47611.

git-svn-id: https://develop.svn.wordpress.org/trunk@47375 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 20:42:19 +00:00
Sergey Biryukov
22c02a0325 General: Introduce HTML classes in get_calendar() for easier CSS targeting:
* `.wp-calendar-table` for the `<table>` element.
* `.wp-calendar-nav` for the navigation wrapper.
* `.wp-calendar-nav-prev` for the previous month link.
* `.wp-calendar-nav-next` for the next month link.

Replace `#prev` and `#next` HTML IDs with `.wp-calendar-nav-prev` and `.wp-calendar-nav-next` classes.

Props sabernhardt, BackuPs, audrasjb, jorbin.
Fixes #39763.

git-svn-id: https://develop.svn.wordpress.org/trunk@47374 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 20:28:29 +00:00
Sergey Biryukov
91878831dd Docs: In update_option(), remove an inaccurate statement about the $autoload value for new options.
If the option does not exist, it will be created with whatever was passed to the `$autoload` parameter, `'yes'` being only the default value.

Props leogermani.
Fixes #48357.

git-svn-id: https://develop.svn.wordpress.org/trunk@47373 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 20:06:32 +00:00
Sergey Biryukov
38e9142a66 Coding Standards: Use strict comparison for normalize_whitespace() checks when comparing revisions or autosaves.
Props dkarfa, itowhid06, TimothyBlynJacobs.
Fixes #47965.

git-svn-id: https://develop.svn.wordpress.org/trunk@47372 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 19:33:22 +00:00
Sergey Biryukov
f852ca2cc1 Widgets: Create a unique HTML ID for the <ul> element of Recent Comments widget if more than one instance is displayed on the page.
Props peterwilsoncc, audrasjb, birgire, justinahinon, mbrailer, desrosj.
Fixes #46747.

git-svn-id: https://develop.svn.wordpress.org/trunk@47371 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 19:27:22 +00:00
Sergey Biryukov
97d43fbff5 Bootstrap/Load: In wp_magic_quotes(), revert the type change to string for REQUEST_TIME and REQUEST_TIME_FLOAT values, which should retain their proper type.
Among other things, this preserves compatibility of WP with PHPUnit Code Coverage generation.

Props jrf, Veraxus, Rarst.
See #48605.

git-svn-id: https://develop.svn.wordpress.org/trunk@47370 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 18:31:33 +00:00
Sergey Biryukov
8dbe048737 Docs: In wp_insert_user(), correct @type for rich_editing, syntax_highlighting, comment_shortcuts, and show_admin_bar_front arguments.
Follow-up to [47368].

See #49087.

git-svn-id: https://develop.svn.wordpress.org/trunk@47369 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 18:18:26 +00:00
Sergey Biryukov
d722bdb0ac Docs: In wp_insert_user(), clarify that rich_editing, syntax_highlighting, comment_shortcuts, and show_admin_bar_front arguments accept true or false as a string literal, not boolean.
Props garrett-eclipse, audrasjb, valentinbora, bilgilabs, SergeyBiryukov.
Fixes #49087.

git-svn-id: https://develop.svn.wordpress.org/trunk@47368 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 18:15:00 +00:00
Sergey Biryukov
f1124fc1cb Docs: Clarify in WP_Customize_Manager::remove_*() methods that removing a setting, panel, section, or control does not destroy the class instance or remove its filters.
Props dlh, fgiannar, jon81, westonruter.
Fixes #48747.

git-svn-id: https://develop.svn.wordpress.org/trunk@47367 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 17:48:40 +00:00
Sergey Biryukov
a6b80a326a Comments: Restore the fourth parameter of comments_number() as $post_id, for consistency with get_comments_number_text().
The parameter was previously used as the number of comments, marked as deprecated in [5101].

Given that it's been deprecated for the last 13 years, it should be safe to undeprecate and repurpose it for a cleaner function signature, instead of adding a fifth parameter.

Follow-up to [47276].

Fixes #48772.

git-svn-id: https://develop.svn.wordpress.org/trunk@47366 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 17:32:34 +00:00
Sergey Biryukov
812773b8fc Widgets: Avoid an overflow issue in widget controls that include <select> form fields.
Props alexischenal, audrasjb, dkarfa.
Fixes #49401.

git-svn-id: https://develop.svn.wordpress.org/trunk@47365 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 17:02:27 +00:00
Sergey Biryukov
3bd4e3a075 Docs: Add a reference to WP_Customize_Control::__construct() for information on accepted arguments in WP_Customize_Manager::add_control().
Synchronize the documentation between two places, use `WP_Customize_Control::__construct()` as the canonical source.

Props hAmpzter, marekdedic, SergeyBiryukov.
Fixes #48343.

git-svn-id: https://develop.svn.wordpress.org/trunk@47364 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 16:39:36 +00:00
Sergey Biryukov
5178d29f4a Docs: Add a reference to WP_Customize_Control::__construct() for information on accepted arguments to override class property defaults in child classes.
Props marcio-zebedeu, marekdedic.
Fixes #48348.

git-svn-id: https://develop.svn.wordpress.org/trunk@47363 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 16:19:08 +00:00
K. Adam White
4e0062e5be REST API: Correctly infer empty objects passed via query parameters.
Permit passing an empty object as the string "?obj=". The type of the passed empty argument is inferred from the registered schema.

Props TimothyBlynJacobs, steffanhalv, schlessera, dd32.
Fixes #42961.


git-svn-id: https://develop.svn.wordpress.org/trunk@47362 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 15:32:27 +00:00
K. Adam White
b5190458fe REST API: Permit access to the themes controller if user can edit any post type.
Check a more exhaustive list of post type editing caps beyond "edit_post" to ensure custom user roles with access to to specific post types may still use block editor functionality depending on theme features.

Props miyauchi, TimothyBlynJacobs.
Fixes #46723.


git-svn-id: https://develop.svn.wordpress.org/trunk@47361 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 15:18:19 +00:00
K. Adam White
a0ac0ff13d REST API: Apply all relevant block rendering filters when rendering block previews.
Several filters were introduced to the render_block method since the initial implementation of the block-renderer/ endpoints, causing the output of those endpoints to diverge from the rendered content of blocks on the frontend.

Props kadamwhite, TimothyBlynJacobs, miinasikk.
Fixes #49387.


git-svn-id: https://develop.svn.wordpress.org/trunk@47360 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 15:03:57 +00:00
Sergey Biryukov
51e6228635 Script Loader: Improve performance of wp_script_is() for scripts registered with complex dependencies.
This switches `WP_Dependencies::recurse_deps()` from recursively checking the same handles over and over again to keep a flattened array of queued items and their dependencies for faster lookup in `WP_Dependencies::query()`.

Props superdav42.
Fixes #46469.

git-svn-id: https://develop.svn.wordpress.org/trunk@47359 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 13:40:52 +00:00
Sergey Biryukov
887e0a8004 Docs: Add a @since note for including delete_posts in default capabilities in get_post_type_capabilities().
Follow-up to [47357].

See #30991.

git-svn-id: https://develop.svn.wordpress.org/trunk@47358 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 12:53:35 +00:00
Sergey Biryukov
317e1c076c Posts, Post Types: Ensure delete_posts is included in default post type capabilities regardless of map_meta_cap value.
This resolves PHP notices in a few places in core where this capability is checked.

Props Mte90, johnbillion, dipesh.kakadiya, jipmoors, bamadesigner, dd32, johnjamesjacoby, xedin.unknown, flixos90, SergeyBiryukov.
Fixes #30991.

git-svn-id: https://develop.svn.wordpress.org/trunk@47357 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 12:48:11 +00:00
Sergey Biryukov
196859f90f Customize: When a menu item is removed from the menu, uncheck its source item on the available items panel.
Props donmhico, garrett-eclipse, audrasjb.
Fixes #46830.

git-svn-id: https://develop.svn.wordpress.org/trunk@47356 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 11:12:18 +00:00
Sergey Biryukov
f40c6c9ebe 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.

git-svn-id: https://develop.svn.wordpress.org/trunk@47355 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 00:57:33 +00:00
Jorge Costa
bc3850c8dc Block Editor: Update WordPress Packages WordPress 5.4 Beta 3.
The following package versions were changed:
@wordpress/block-directory: 1.5.1 -> 1.5.2
@wordpress/block-editor: 3.7.1 -> 3.7.2
@wordpress/block-library: 2.14.1 -> 2.14.2
@wordpress/components: 9.2.1 -> 9.2.2
@wordpress/edit-post: 3.13.1 -> 3.13.2
@wordpress/editor: 9.12.1 -> 9.12.2
@wordpress/format-library: 1.14.1 -> 1.14.2
@wordpress/list-reusable-blocks: 1.13.1 -> 1.13.2
@wordpress/media-utils: 1.7.1 -> 1.7.2
@wordpress/nux: 3.12.1 -> 3.12.2
@wordpress/server-side-render: 1.8.1 -> 1.8.2

Fixes #49506.

git-svn-id: https://develop.svn.wordpress.org/trunk@47354 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-25 00:16:12 +00:00
Sergey Biryukov
753ffe3968 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.

git-svn-id: https://develop.svn.wordpress.org/trunk@47353 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-24 23:05:14 +00:00
Andrew Ozz
b2d243fbe6 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.

git-svn-id: https://develop.svn.wordpress.org/trunk@47352 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-24 21:20:49 +00:00
K. Adam White
4e18f78ced REST API: Fix namespace shadowing issue in route matching logic.
Following [47260] a namespace such as "test-ns" prevents any namespace such as "test-ns/v1" from being found when matching routes.
While not best practice, this was an unintentional back-compat break; this patch restores the original behavior.

Props david.binda, TimothyBlynJacobs.
Fixes #48530.



git-svn-id: https://develop.svn.wordpress.org/trunk@47351 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-24 18:05:12 +00:00
Sergey Biryukov
74baee2f19 Menus: Introduce wp_nav_menu_item_custom_fields_customize_template action that fires at the end of the form field template for nav menu items in the customizer.
This brings parity with the `wp_nav_menu_item_custom_fields` action added in [47190] for the Menus screen.

Props celloexpressions.
Fixes #47056.

git-svn-id: https://develop.svn.wordpress.org/trunk@47350 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-24 14:56:42 +00:00
Sergey Biryukov
c2316edc3a Coding Standards: Add missing braces to if conditions and use strict comparison in js/_enqueues/wp/media/editor.js.
Props ankitmaru.
Fixes #49317.

git-svn-id: https://develop.svn.wordpress.org/trunk@47349 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-23 08:56:44 +00:00
Sergey Biryukov
2f10289ffb Docs: Use third-person singular verbs for function descriptions in wp-includes/option.php, per the documentation standards.
See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47347 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-23 01:05:28 +00:00
Sergey Biryukov
84764d4cee Docs: Add a @staticvar entry for $transports in WP_Http::_dispatch_request().
Props utsav72640.
Fixes #48774.

git-svn-id: https://develop.svn.wordpress.org/trunk@47346 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-22 19:10:47 +00:00
Sergey Biryukov
af57dcb03e I18N: Replace .htaccess with placeholders in the strings for Site Health custom rules check.
Props ramiy.
Fixes #48864.

git-svn-id: https://develop.svn.wordpress.org/trunk@47345 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-22 18:54:09 +00:00
Sergey Biryukov
74908c06bf I18N: Use a consistent wording for "Unable to write to file" strings.
Props ramiy.
Fixes #48862.

git-svn-id: https://develop.svn.wordpress.org/trunk@47344 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-22 18:31:39 +00:00
Adam Silverstein
8793357dfa Comments: improve styling on mobile for comments marked as spam.
Correct an issue where comments marked as spam in a mobile view displayed incorrectly, filling a narrow and very tall column with the notice that a comment was marked as spam. 

Props jeremyfelt, lorenzof, mukesh27, razamalik, xkon.
Fixes #48814.



git-svn-id: https://develop.svn.wordpress.org/trunk@47340 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-21 17:02:18 +00:00
Ian Belanger
bb6b0cdaa5 Bundled Themes: Twenty Nineteen text color setting in pullquote block not applied.
Fixes the pullquote color setting by adding classes that are more specific to the color options.

Props ianbelanger.
Fixes #49410.

git-svn-id: https://develop.svn.wordpress.org/trunk@47339 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-21 14:57:12 +00:00
Sergey Biryukov
3ff0ef5030 I18N: Replace upload_max_filesize, php.ini, MAX_FILE_SIZE with placeholders in upload error strings.
Props ramiy.
Fixes #48869.

git-svn-id: https://develop.svn.wordpress.org/trunk@47330 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-20 17:16:21 +00:00
Timothy Jacobs
8a62f46beb REST API: Don't assume all item schemas have properties.
All schema types, not just objects, are permitted as the base type of a resource. A future patch could add validation support for those types, but this fix only prevents a PHP warning from being issued.

Props dhavalkasvala, johnwatkins0, birgire.
Fixes #48785.


git-svn-id: https://develop.svn.wordpress.org/trunk@47328 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-20 16:56:17 +00:00
Ian Belanger
6194b3c5d2 Bundled Themes: Twenty Nineteen Update margins in editor styles to address upcoming block editor margin changes.
Fixes the margins in the block editor to address recent changes in block margins.

Props Joen, SergeyBiryukov, kjellr, jffng, allancole.
Fixes #48526.

git-svn-id: https://develop.svn.wordpress.org/trunk@47327 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-20 16:38:38 +00:00
Timothy Jacobs
be371a7431 REST API: Fix links format in OPTIONS requests for non-variable routes.
Props nsundberg, johnwatkins0, birgire.
Fixes #49149.


git-svn-id: https://develop.svn.wordpress.org/trunk@47326 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-20 00:53:43 +00:00
Timothy Jacobs
727faabe98 REST API: Warn if registering array settings without an items schema.
The documentation for register_setting has also been clarified to include all of the supported types and the flexibility of the show_in_rest parameter.

Fixes #42875.
Props perrywagle, dshanske, kadamwhite.


git-svn-id: https://develop.svn.wordpress.org/trunk@47325 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-19 22:54:03 +00:00
Sergey Biryukov
5f26580730 Docs: Add missing quote to {@see 'comment_$old_status_to_$new_status'} hook reference in wp_transition_comment_status() DocBlock.
Props coffee2code.
Fixes #49474.

git-svn-id: https://develop.svn.wordpress.org/trunk@47324 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-19 13:43:16 +00:00
Sergey Biryukov
2d73050eda Posts, Post Types: Discard tags_input parameter in wp_update_post() if it's the same as existing post tags.
This ensures that `wp_update_post()` does not unintentionally modify post tags if the post has several tags with the same name but different slugs.

Tags should only be modified if `tags_input` parameter was explicitly provided, and is different from the existing tags.

Props kaggdesign, SergeyBiryukov.
Fixes #45121.

git-svn-id: https://develop.svn.wordpress.org/trunk@47317 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-19 03:50:38 +00:00
Tammie Lister
6930542657 Bump version number to beta 2-47310
git-svn-id: https://develop.svn.wordpress.org/trunk@47310 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-18 21:27:31 +00:00
Tammie Lister
bc0847e8bd Bump version number to beta 2
git-svn-id: https://develop.svn.wordpress.org/trunk@47309 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-18 21:09:56 +00:00
Jonathan Desrosiers
9f87034879 Widgets: Revert [47307].
Even though the source URL for an attachment is stored in a variable, attachments should still be passed through the `wp_video_shortcode()` function.

Unprops desrosj, spacedmonkey.
See #46718.

git-svn-id: https://develop.svn.wordpress.org/trunk@47308 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-18 18:17:53 +00:00
Jonathan Desrosiers
0d7a5f949d Widgets: Remove unnecessary redundant conditional.
Props spacedmonkey.
Fixes #46718.

git-svn-id: https://develop.svn.wordpress.org/trunk@47307 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-18 17:50:54 +00:00
Jonathan Desrosiers
b797e91541 Site Health: Display the REST API test error codes correctly.
This change fixes an issue where the error codes associated with failed REST API tests are not being printed to the screen. In addition, the square brackets have been replaced with parentheses for consistency, and the error code (which is much less useful to end-users than the error message itself) has been moved to the end of the line.

This also clarifies the associated translator comments.

Props afercia, desrosj.
Fixes #49426.

git-svn-id: https://develop.svn.wordpress.org/trunk@47306 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-18 16:46:11 +00:00
Sergey Biryukov
6234fd90c2 Theme Editor: Disable CodeMirror CSS linting.
Being a good idea in theory, in practice it does not always work reliably, may not recognize newer CSS properties, and sometimes displays phantom errors with no particular error message.

A plugin can re-enable CSS linting via the `wp_code_editor_settings` filter.

Props skypressatx, ThemeZee, johnbillion, ianbelanger, ZanderZ, starvoters1, raoulunger, prashantvatsh, SergeyBiryukov.
Fixes #44471.

git-svn-id: https://develop.svn.wordpress.org/trunk@47305 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-18 15:49:08 +00:00
Andrea Fercia
5133f6b779 Accessibility: Improve readability by removing unnecessary italic font style.
Per Web Content Accessibility Guidelines 2.0, big chunks of italic text should be avoided.
Same applies to UI controls, since they're meant to be comfortably readable by the largest possible audience, e.g.: label elements.

Removes italic font style from:
- the Quick Edit / Bulk Edit forms
- the Recovery Mode plugin error details
- the Image Editor inline help

Props birgire, audrasjb, SergeyBiryukov, melchoyce, estelaris, sabernhardt, xkon, nrqsnchz, afercia.
See #47327.


git-svn-id: https://develop.svn.wordpress.org/trunk@47304 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-18 15:30:10 +00:00
Sergey Biryukov
002bfea745 Site Health: Prevent the Site Health Status dashboard widget from loading on network admin screen for now.
Props Clorith, pbiron.
See #47606, #47085.

git-svn-id: https://develop.svn.wordpress.org/trunk@47300 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-17 09:58:00 +00:00
Sergey Biryukov
9ac7fca92b Users: Limit the scope of admin files required in WP_REST_Users_Controller.
This requires only `wp-admin/includes/user.php` for `get_editable_roles()`, instead of `wp-admin/includes/admin.php`.

Follow-up to [43589].

Props johnwatkins0.
Fixes #49450.

git-svn-id: https://develop.svn.wordpress.org/trunk@47299 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-17 05:31:18 +00:00
Sergey Biryukov
b8993b72bd Docs: Improve inline comments for require_once calls in WP_REST_Users_Controller per the documentation standards.
Follow-up to [47295].

See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47298 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-17 03:54:11 +00:00
Sergey Biryukov
7d8b92ede9 Docs: Fix typo in a comment in WP_REST_Attachments_Controller::create_item().
See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47297 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-17 03:28:05 +00:00
Sergey Biryukov
2d9f3a1330 REST API: Restore wp-admin/includes/image.php requirement in WP_REST_Attachments_Controller::create_item().
Although the file is already included via the `::insert_attachment()` method, this addresses an inconsistency and corrects a misleading comment.

It also reduces the possibility of a future error in case `::insert_attachment()` is no longer called earlier in `::create_item()` at some point.

Follow-up to [43850] and [44206].

Props luisrivera.
Fixes #49449.

git-svn-id: https://develop.svn.wordpress.org/trunk@47296 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-17 03:22:43 +00:00
Sergey Biryukov
f8d1664544 Docs: Improve inline comments for require_once() calls in WP_REST_Attachments_Controller.
See #49449, #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47295 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-17 03:11:50 +00:00
Sergey Biryukov
96f845d1a7 Menus: Restore the title of the currently active/expanded menu item when clicking "Cancel" after editing.
Other inputs are already restored to their previous values in that case.

Props Girishpanchal, nilamacharya, JoshuaWold, welcher, SergeyBiryukov.
Fixes #43031.

git-svn-id: https://develop.svn.wordpress.org/trunk@47294 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-16 06:25:54 +00:00
Sergey Biryukov
0e52a4efc1 Themes: Correct the height of theme actions button container on various screen sizes.
Props aftabmuni, alexischenal, ideaboxcreations, audrasjb, SergeyBiryukov.
Fixes #49302.

git-svn-id: https://develop.svn.wordpress.org/trunk@47293 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-15 05:06:39 +00:00
Sergey Biryukov
45e02b9026 Widgets: Hide the "Align" legend in Image Widget display settings, since the associated controls are also hidden.
Props audrasjb, fotisps, marcelo2605.
Fixes #48931.

git-svn-id: https://develop.svn.wordpress.org/trunk@47292 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-15 02:48:28 +00:00
Sergey Biryukov
ae82bd40cc Administration: Allow wp_update_link() to update the link_owner field, for consistency with other link fields.
Props pbiron, valentinbora, nikhilgupte.
Fixes #41687.

git-svn-id: https://develop.svn.wordpress.org/trunk@47291 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-15 01:53:22 +00:00
Sergey Biryukov
1911d0db67 Administration: Correct alignment of form controls inside custom meta boxes.
Props audrasjb, dontdream, valentinbora.
Fixes #49013.

git-svn-id: https://develop.svn.wordpress.org/trunk@47289 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-14 00:50:42 +00:00
Sergey Biryukov
543944257c Coding Standards: Rename $d parameter in various date/time functions to $format for clarity.
See #49222.

git-svn-id: https://develop.svn.wordpress.org/trunk@47287 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-14 00:05:43 +00:00
Sergey Biryukov
a41b2d93d3 Docs: Update @return tag for wp_allow_comment() with trash as a possible return value.
Props oakesjosh, jeremyfelt.
Fixes #49206.

git-svn-id: https://develop.svn.wordpress.org/trunk@47286 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-13 17:48:50 +00:00
Sergey Biryukov
3dd39ffece General: Update Michel Valdrighi's website in license.txt.
Props sebastienserre.
Fixes #49130.

git-svn-id: https://develop.svn.wordpress.org/trunk@47285 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-12 11:52:11 +00:00
Sergey Biryukov
58efcbdcd6 Privacy: Only show the Privacy Policy page notice when editing the page, not on drafts list.
Props chetan200891, xkon, garrett-eclipse.
Fixes #48431.

git-svn-id: https://develop.svn.wordpress.org/trunk@47284 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-12 11:42:23 +00:00
Sergey Biryukov
a6d078c228 Privacy: Improve the appearance of privacy request email inputs on mobile.
Props garrett-eclipse, xkon.
Fixes #48189.

git-svn-id: https://develop.svn.wordpress.org/trunk@47283 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-12 11:27:27 +00:00
Jorge Costa
20849f39b4 Post WordPress 5.4 Beta 1 version bump.
git-svn-id: https://develop.svn.wordpress.org/trunk@47282 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 22:44:50 +00:00
Jorge Costa
f9fe81df19 WordPress 5.4 Beta 1.
git-svn-id: https://develop.svn.wordpress.org/trunk@47281 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 22:18:40 +00:00
Sergey Biryukov
f97a60c9b7 Privacy: Revert [47269] for now to address side effects on Multisite installations.
See #44176.

git-svn-id: https://develop.svn.wordpress.org/trunk@47280 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 21:46:54 +00:00
Sergey Biryukov
1106d82f93 Privacy: Introduce filters for the headers of all the privacy-related e-mails:
* `wp_privacy_personal_data_email_headers`
* `user_request_confirmed_email_headers`
* `user_erasure_complete_email_headers`
* `user_request_action_email_headers`

Props xkon, garrett-eclipse, zaffarn, desrosj.
Fixes #44501.

git-svn-id: https://develop.svn.wordpress.org/trunk@47279 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 21:41:26 +00:00
Sergey Biryukov
b8e935b2f2 Privacy: Add a table of contents to Personal Data Export report for easier navigation.
Props xkon, garrett-eclipse, birgire, karmatosed.
Fixes #46894.

git-svn-id: https://develop.svn.wordpress.org/trunk@47278 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 21:26:25 +00:00
Sergey Biryukov
d6352c544b Coding Standards: Use a strict in_array() check for reserved names of user data items in wp_user_personal_data_exporter().
Props azaozz.
Fixes #47509.

git-svn-id: https://develop.svn.wordpress.org/trunk@47277 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 20:53:40 +00:00
Sergey Biryukov
4020493d45 Comments: Add a $post_id parameter to get_comments_number_text() and comments_number().
This allow for using these functions outside of the loop.

Props donmhico, garrett-eclipse, Hinjiriyo, imath.
Fixes #48772.

git-svn-id: https://develop.svn.wordpress.org/trunk@47276 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 20:39:12 +00:00
Jonathan Desrosiers
c83253c7f8 Upgrade/Install: Enable maintenance mode when plugins are auto-updated.
When an attempt is made to update an active plugin automatically, there is the potential currently for two negative scenarios:

- The plugin can be deactivated if the Plugins admin screen is loaded when the plugin update is incomplete, causing a PHP error.
- The WSOD protection could be triggered, sending a false alarm email to the site administrator.

By enabling maintenance mode before an active plugin update is attempted, these scenarios can be avoided.

This change implements the same approach as the `Theme_Upgrader` class of using the `upgrader_pre_install` and `upgrader_post_install` hooks to toggle maintenance mode.

Props desrosj, SergeyBiryukov.
Fixes #49400.

git-svn-id: https://develop.svn.wordpress.org/trunk@47275 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 20:12:52 +00:00
Andrew Ozz
896de1cba2 Media: Pass through the $unfiltered param to get_attached_file() in wp_get_original_image_path().
Props ianmjones, joemcgill, azaozz.
Fixes #48421.

git-svn-id: https://develop.svn.wordpress.org/trunk@47274 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 19:45:46 +00:00
Ian Belanger
e7382153fe Bundled Themes: Twenty Sixteen text color setting in pullquote block not applied.
Fixes the pullquote color setting by moving `color` from `blockquote p` to `blockquote`. Also adds the border-left to the front-end stylesheet to match the editor. Also adds styles for rtl pullquote.

Props kokkieh, desrosj, mukesh27, khushbu19, disillusia, aliveic, abrightclearweb, SergeyBiryukov.
Fixes #47019.

git-svn-id: https://develop.svn.wordpress.org/trunk@47273 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 19:36:56 +00:00
Sergey Biryukov
c7267a039f Export: Use correct context for the Posts label on the Export screen.
The string refers to the post type name specifically, not to a generic term to identify a publication on WordPress.

Props audrasjb, jdy68.
Fixes #49306.

git-svn-id: https://develop.svn.wordpress.org/trunk@47272 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 19:33:58 +00:00
Jorge Costa
e608cd21ac Upload: Fix Plugin and Theme upload form are misaligned.
This commit makes sure that when uploading a plugin or theme file, the Install Now button is correctly aligned, and the button does not drops to the next line if filename is long.

Props seedsca, SergeyBiryukov, audrasjb.
Fixes #48859.

git-svn-id: https://develop.svn.wordpress.org/trunk@47271 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 19:16:57 +00:00
Sergey Biryukov
0ad4121c91 Privacy: Introduce wp_privacy_additional_user_data filter to make it easier to include additional user meta in a personal data export.
Props pbiron, xkon, garrett-eclipse, azaozz.
Fixes #47509.

git-svn-id: https://develop.svn.wordpress.org/trunk@47270 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 18:57:51 +00:00
Sergey Biryukov
0911aecf36 Privacy: Un-map privacy capabilities to make them available to be assigned for custom roles:
* `erase_others_personal_data`
* `export_others_personal_data`
* `manage_privacy_options`

Previously mapped to `manage_options` or `manage_network` (on Multisite), these are now added to the Administrator role separately.

Additionally, `manage_privacy_options` is added to the Editor role.

Props garrett-eclipse, xkon, pbiron, desrosj, johnbillion, flixos90, juliobox, lakenh, Ov3rfly, ianatkins.
Fixes #44176.

git-svn-id: https://develop.svn.wordpress.org/trunk@47269 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 18:34:08 +00:00
Sergey Biryukov
49b145c23f Site Health: Adjust "Database username" and "Table prefix" strings for consistency with the same strings in wp-admin/setup-config.php.
Props ramiy.
Fixes #47043.

git-svn-id: https://develop.svn.wordpress.org/trunk@47268 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 16:46:10 +00:00
Sergey Biryukov
2599e1b4fb Customize: Avoid unnecessary get_theme_mod() call and premature escaping in get_header_video_url().
The result is still escaped with `esc_url_raw()` for retrieval, and with `esc_url()` for display in `the_header_video_url()`.

Props dlh, Tkama.
Fixes #40044.

git-svn-id: https://develop.svn.wordpress.org/trunk@47267 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 16:34:09 +00:00
Andrea Fercia
5866986d74 Media: Fix bottom spacing on various Media Modal elements for non-webkit browsers.
Implementation of bottom padding in overflow content differs across browsers. See https://github.com/w3c/csswg-drafts/issues/129. To make bottom spacing consistent across browsers there's the need for an alternate CSS method.
- uses a CSS `after` pseudo element or simply a bottom margin to reserve some bottom spacing
- removes a couple leftovers from [40428]
- fixes an annoying visual glitch where the media modal content is visible behind the bottom toolbar border

Props sabernhardt, afercia.
See #40152.
Fixes #48378.


git-svn-id: https://develop.svn.wordpress.org/trunk@47266 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 16:30:13 +00:00
K. Adam White
b6dcb779ed REST API: Introduce rest_{$this->post_type}_item_schema filter to enable manipulation of schema values.
register_rest_field can be used to add properties to a schema, but no mechanism existed to alter existing properties like "content".
Running the schema through this filter lets plugins append additional sub-properties to existing schema definitions.

Props luisherranz, TimothyBlynJacobs, swissspidy, westonruter, kadamwhite.
Fixes #47779.



git-svn-id: https://develop.svn.wordpress.org/trunk@47265 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 16:26:56 +00:00
Ian Belanger
72e7742446 Bundled Themes: Twenty Twenty property border-style is overwritten - coding standard.
Fixes coding standard violations in the classic editor stylesheets.

Props ankitmaru.
Fixes #49006.

git-svn-id: https://develop.svn.wordpress.org/trunk@47264 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 16:09:50 +00:00
Sergey Biryukov
f26d4d3735 Widgets: Prevent currently active wide widget controls from being partially covered by another widget's controls.
The currently active widget controls should always be displayed on top.

Props audrasjb, fervillz, rinkuyadav999, jaydeep23290, ashokrd2013, melchoyce, pento, westonruter, SergeyBiryukov.
Fixes #42001.

git-svn-id: https://develop.svn.wordpress.org/trunk@47263 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 15:24:47 +00:00
Anthony Burchell
08b3c1d123 Media: Reset aspect ratio constraints when width and height fields fail numeric validation.
Props TBschen, valentinbora.
Fixes #49073.


git-svn-id: https://develop.svn.wordpress.org/trunk@47262 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 04:38:55 +00:00
K. Adam White
886a02686b REST API: Allow meta to be set when creating a new media record via REST.
Props TimothyBlynJacobs, apermo.
Fixes #44567.


git-svn-id: https://develop.svn.wordpress.org/trunk@47261 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 03:37:17 +00:00
K. Adam White
fc434a0c77 REST API: Match REST API routes on namespace before performing regex checks.
Rule out groups of API endpoints by simple namespace string comparison to reduce the number of regex checks necessary when matching a route.

Props TimothyBlynJacobs.
Fixes #48530.


git-svn-id: https://develop.svn.wordpress.org/trunk@47260 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 03:20:05 +00:00
azaozz
3125c21cc4 Media: Improve wording for error message on failed post-processing of uploaded images.
Props eclev91, desrosj, antpb, azaozz.
Fixes #49280.

git-svn-id: https://develop.svn.wordpress.org/trunk@47259 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 03:18:02 +00:00
K. Adam White
d06637f9b5 REST API: List all core theme feature support details in /themes endpoint response.
Fully list which first-party core theme features are supported in the /themes endpoint response. This brings the REST API themes controller's response more in line with the output of get_theme_support().

Props adamboro, apieschel, koke, spacedmonkey, TimothyBlynJacobs.
See #49037.


git-svn-id: https://develop.svn.wordpress.org/trunk@47258 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 01:58:08 +00:00
Sergey Biryukov
b364e2a072 Media: Improve the preview of transparent images in Image widget by using CSS3 to show a checkered background.
Props bahia0019.
Fixes #49237.

git-svn-id: https://develop.svn.wordpress.org/trunk@47257 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 01:45:01 +00:00
Sergey Biryukov
d9c6c5eed9 Administration: Move .has-row-actions class in Recent Comments dashboard widget next to .dashboard-comment-wrap, for consistency.
Follow-up to [47255].

See #42938.

git-svn-id: https://develop.svn.wordpress.org/trunk@47256 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 01:19:55 +00:00
Sergey Biryukov
196fc7ab60 Administration: Remove a blank space in the Recent Comments dashboard widget if avatars are disabled on Discussion Settings screen.
Props Marius84, shital-patel, GaryJ, ianbelanger, sgastard, lgrev01, donmhico, garrett-eclipse, audrasjb, SergeyBiryukov.
Fixes #42938.

git-svn-id: https://develop.svn.wordpress.org/trunk@47255 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 01:15:31 +00:00
Sergey Biryukov
8650885f85 Site Health: Improve the wording for PHP update recommendations.
Props Clorith, grafruessel, sathyapulse, wpgurudev, garrett-eclipse, marybaum, xkon, SergeyBiryukov.
Fixes #48716.

git-svn-id: https://develop.svn.wordpress.org/trunk@47254 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 00:39:11 +00:00
Sergey Biryukov
22ca3c51a6 Comments: Improve the appearance of the Status box on Edit Comment screen.
This makes the box more consistent with the Publish meta box in classic editor.

Props birgire, nfmohit, melchoyce, afercia.
Fixes #43587.

git-svn-id: https://develop.svn.wordpress.org/trunk@47252 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-11 00:05:01 +00:00
Sergey Biryukov
45cb25d4f2 Media: In media_sideload_image(), store the original attachment URL in the _source_url post meta value.
Props dshanske, joemcgill, antpb.
Fixes #48164.

git-svn-id: https://develop.svn.wordpress.org/trunk@47251 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 23:45:50 +00:00
Jorge Costa
f558f5ff37 Block Editor: Update WordPress Packages; Remove navigation block; Add social links block
The following package versions were changed:
@wordpress/annotations: 1.11.0 -> 1.12.0
@wordpress/api-fetch: 3.10.0 -> 3.11.0
@wordpress/block-directory: 1.4.0 -> 1.5.0
@wordpress/block-editor: 3.6.0 -> 3.7.0
@wordpress/block-library: 2.13.0 -> 2.14.0
@wordpress/blocks: 6.11.0 -> 6.12.0
@wordpress/components: 9.1.0 -> 9.2.0
@wordpress/core-data: 2.11.0 -> 2.12.0
@wordpress/data: 4.13.0 -> 4.14.0
@wordpress/data-controls: 1.7.0 -> 1.8.0
@wordpress/e2e-test-utils: 4.2.0 -> 4.3.0
@wordpress/edit-post: 3.12.0 -> 3.13.0
@wordpress/editor: 9.11.0 -> 9.12.0
@wordpress/format-library: 1.13.0 -> 1.14.0
@wordpress/icons: 1.0.0 -> 1.1.0
@wordpress/keyboard-shortcuts: 1.0.0 -> 1.1.0
@wordpress/list-reusable-blocks: 1.12.0 -> 1.13.0
@wordpress/media-utils: 1.6.0 -> 1.7.0
@wordpress/notices: 1.12.0 -> 2.0.0
@wordpress/nux: 3.11.0 -> 3.12.0
@wordpress/plugins: 2.11.0 -> 2.12.0
@wordpress/primitives: 1.0.0 -> 1.1.0
@wordpress/rich-text: 3.11.0 -> 3.12.0
@wordpress/server-side-render: 1.7.0 -> 1.8.0
@wordpress/url: 2.10.0 -> 2.11.0
@wordpress/viewport: 2.12.0 -> 2.13.0
The navigation block inclusion was reverted.
The social links block was included.

Props gziolo, youknowriad, mcsf, noisysocks.
Fixes #49397.

git-svn-id: https://develop.svn.wordpress.org/trunk@47250 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 22:31:13 +00:00
Sergey Biryukov
de5d82fe52 Docs: Improve documentation for the $attr parameter of wp_get_attachment_image().
Props juanfra, Mte90, DrewAPicture, joemcgill, SergeyBiryukov.
Fixes #36661.

git-svn-id: https://develop.svn.wordpress.org/trunk@47249 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 22:01:49 +00:00
Sergey Biryukov
0c07311e95 Coding Standards: Fix JSHint issues in [47246].
See #44264.

git-svn-id: https://develop.svn.wordpress.org/trunk@47248 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 21:36:53 +00:00
Sergey Biryukov
7a7c3c60d9 Privacy: Convert buttons to links visually in Privacy Export/Erasure "Next Steps" column.
With a lot of export or erasure requests, the secondary buttons were becoming overwhelming when stacked on top of each other.

Props xkon, karmatosed.
Fixes #49323.

git-svn-id: https://develop.svn.wordpress.org/trunk@47247 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 21:13:08 +00:00
Sergey Biryukov
a6a02eaca7 Privacy: Give progress indication for export and erasure.
This adds a progress indicator for "Download Personal Data" and "Erase Personal Data" row actions, which can take a while with a lot of data.

Props garrett-eclipse, allendav, dominic_ks, xkon, karmatosed, birgire.
Fixes #44264.

git-svn-id: https://develop.svn.wordpress.org/trunk@47246 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 20:17:58 +00:00
Sergey Biryukov
c0c2fd3f63 Privacy: Rename wp_get_user_request_data() to wp_get_user_request() for clarity; deprecate the old function.
The function returns an instance of the `WP_User_Request` object itself, not its `$request_data` property.

Follow-up to [44606].

Props garrett-eclipse.
Fixes #46302.

git-svn-id: https://develop.svn.wordpress.org/trunk@47245 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 19:55:51 +00:00
Ian Belanger
d4475d552c Bundled Themes: Twenty Twenty post navigation links outside of the container.
Fixes a bug where the in-page pagination does not align within the inner container.

Props ataurr, audrasjb, mukesh27.
Fixes #48979.

git-svn-id: https://develop.svn.wordpress.org/trunk@47244 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 19:23:38 +00:00
Ian Belanger
a604bba1f7 Bundled Themes: Twenty Twenty add WhatsApp to the social icon menu.
This adds WhatsApp as an option in the social icon menu.

Props rryyaanndd, audrasjb.
Fixes #49098.

git-svn-id: https://develop.svn.wordpress.org/trunk@47243 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 19:10:21 +00:00
Sergey Biryukov
f160d6a765 Twenty Nineteen: Add the missing inc/helper-functions.php file.
Follow-up to [47214].

Props kjellr, jffng.
Fixes #45984.

git-svn-id: https://develop.svn.wordpress.org/trunk@47242 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 19:05:17 +00:00
Ian Belanger
d56903d331 Bundled Themes: Twenty Twenty Author Bio/Post Meta Width in Cover Template in Mobile.
Fixes a bug where the author bio and post meta have no left or right padding in smaller viewports.

Props JarretC.
Fixes #49254.

git-svn-id: https://develop.svn.wordpress.org/trunk@47241 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 18:23:29 +00:00
Jorge Costa
437ac63d76 Block Editor: Backport inclusion of new editor settings to the core.
This commit includes in the core settings for the gradients theme API stabilized in https://github.com/WordPress/gutenberg/pull/20107, and for the image sizes required for the latest posts feature image https://github.com/WordPress/gutenberg/pull/17151/.

Props: youknowriad, ryelle.
Fixes #49389.

git-svn-id: https://develop.svn.wordpress.org/trunk@47240 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 17:50:36 +00:00
Timothy Jacobs
e7399111b4 REST API: Add support for the REDIRECT_HTTP_AUTHORIZATION header.
Previously the REST API did not account for server configurations where the Authorization header must be added using ModRewrite. This caused major DUX issues when trying to use custom authentication mechanisms.

Fixes #47077.
Props dshanske, cklosows.


git-svn-id: https://develop.svn.wordpress.org/trunk@47239 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 16:06:58 +00:00
Andrew Duthie
2c795289c8 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.


git-svn-id: https://develop.svn.wordpress.org/trunk@47238 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 15:15:07 +00:00
Sergey Biryukov
5b0be97e7c Privacy: Include session tokens in Personal Data Export.
Session tokens contain an IP address and user agent.

Props garrett-eclipse, nickylimjj, lakenh, xkon, rconde.
Fixes #45889.

git-svn-id: https://develop.svn.wordpress.org/trunk@47237 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 05:42:52 +00:00
Sergey Biryukov
8fef1b28a9 Privacy: Include community-events-location user meta value in Personal Data Export.
The value is used by the WordPress Events and News widget to show relevant WP community events.

The location information may include an IP address, location description, and latitude/longitude coordinates.

Props garrett-eclipse, coreymckrill, xkon.
Fixes #43921.

git-svn-id: https://develop.svn.wordpress.org/trunk@47236 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 05:30:03 +00:00
Sergey Biryukov
d321144c67 Site Health: Move the warning about WP_DEBUG_LOG being publicly accessible from "critical issues" to "recommended improvements" if the error log is outside of the WordPress directory.
Props afragen, Clorith, miss_jwo, mikeschroder, kubiq, xkon.
Fixes #47985.

git-svn-id: https://develop.svn.wordpress.org/trunk@47235 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 05:14:18 +00:00
Sergey Biryukov
acb845d7ea Administration: Standardize "found in Trash" messages.
Props Presskopp, audrasjb.
Fixes #38669.

git-svn-id: https://develop.svn.wordpress.org/trunk@47234 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 04:56:01 +00:00
Sergey Biryukov
023d4b2796 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.

git-svn-id: https://develop.svn.wordpress.org/trunk@47233 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 04:10:09 +00:00
Sergey Biryukov
5302cd6514 Login and Registration: Clarify the message on "Lost Password" screen.
Props pbiron, Presskopp.
Fixes #49346.

git-svn-id: https://develop.svn.wordpress.org/trunk@47232 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 03:48:45 +00:00
Sergey Biryukov
924b49cf34 Docs: Add documentation for globals in wp-settings.php.
Props chinteshprajapati.
Fixes #46253.

git-svn-id: https://develop.svn.wordpress.org/trunk@47231 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 03:32:57 +00:00
Sergey Biryukov
c80af9030d Docs: Add descriptions for some globals:
* `$wp_version`
* `$wp_local_package`
* `$required_php_version`
* `$required_mysql_version`

See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47230 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 03:28:20 +00:00
Andrew Ozz
6fd606d236 Media: Ensure imgareaselect.js is not initialized twice for the same image. May happen when uploading an image into a post and then clicking on Edit Image.
Fixes #49262.

git-svn-id: https://develop.svn.wordpress.org/trunk@47229 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 02:52:12 +00:00
Sergey Biryukov
b39db8c898 Editor: Add unique classes to .post-attributes-label-wrapper paragraphs for easier JS or CSS targeting.
Props sathyapulse, sabernhardt, garrett-eclipse, noisysocks.
Fixes #44408.

git-svn-id: https://develop.svn.wordpress.org/trunk@47228 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 02:27:23 +00:00
Sergey Biryukov
dabec45a08 Import: Remove "Blogroll" import option (for links in OPML format) from the list of popular importer plugins.
Link Manager is disabled for new installations since WordPress 3.5, so core should not encourage importing links.

See #meta4706 for the corresponding WordPress.org API change.

Props Ipstenu, hareesh-pillai, DrewAPicture, nacin, karmatosed, dd32, garrett-eclipse.
Fixes #22994. See #21307.

git-svn-id: https://develop.svn.wordpress.org/trunk@47227 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 02:10:52 +00:00
Sergey Biryukov
37a83d5a95 Login and Registration: Use CSS animation instead of old JavaScript code for "shake" animation on login failure.
Props markjaquith, valentinbora.
Fixes #48490.

git-svn-id: https://develop.svn.wordpress.org/trunk@47226 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-10 01:50:33 +00:00
Timothy Jacobs
98e5dd52de REST API: Introduce selective link embedding.
Previously the _embed flag would embed all embeddable links in a response even if only a subset of the links were necessary. Now, a list of link relations can be passed in the _embed parameter to restrict the list of embedded objects.

Props rheinardkorf, adamsilverstein, jnylen0, cklosows, chrisvanpatten, TimothyBlynJacobs.
Fixes #39696.


git-svn-id: https://develop.svn.wordpress.org/trunk@47224 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-09 20:52:06 +00:00
Aaron Jorbin
c647007a82 General: Fix HTML for get_calendar()
The <tfoot> element was allowed to precede the <tbody> element in HTML 5. However, that was changed in HTML 5.1 and <tfoot> must now follow <tbody>.

This removes the tfooot and instead uses a nav element for navigation between months.

Fixes: #39763
Props: isabel_brison, Harry Milatz, audrasjb, abhijitrakas, SergeyBiryukov


git-svn-id: https://develop.svn.wordpress.org/trunk@47223 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-09 20:42:26 +00:00
Joe Dolson
1d7cdbeab7 Editor: Fix incorrect usage of ID attributes on custom fields.
Repeated containers used for custom fields have duplicate ID attributes. Duplicate IDs are incorrect HTML, and will also cause unexpected results when trying to manipulate using JS. Duplicate IDs are changed to matching classes; CSS & JS updated to match. 

Props jankimoradiya, audrasjb, donmhico, afercia.
Fixes #46964.


git-svn-id: https://develop.svn.wordpress.org/trunk@47222 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-09 19:39:54 +00:00
Joe Dolson
3fb063f705 Toolbar: Load toolbar in wp_body_open when available.
For accessibility, the visual appearance and source order should match. Moving the toolbar to load in the new hook `wp_body_open` (5.2) fixes a long-standing source order problem.

Props jankimoradiya, afercia, SergeyBiryukov, audrasjb, ocean90, xkon, dinhtungdu.
Fixes #47053.


git-svn-id: https://develop.svn.wordpress.org/trunk@47221 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-09 18:24:41 +00:00
Sergey Biryukov
8cbfdbaa09 Coding Standards: Correct the get_plugin_page_hook() check in wp-admin/admin.php.
The condition is meant to check for a non-empty string, however `get_plugin_page_hook()` can return null, in which case the strict check doesn't work as expected.

Follow-up to [47218].

See #48455, #49222.

git-svn-id: https://develop.svn.wordpress.org/trunk@47220 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-09 17:06:55 +00:00
Sergey Biryukov
130751cda3 Coding Standards: Use Yoda conditions where appropriate.
See #49222.

git-svn-id: https://develop.svn.wordpress.org/trunk@47219 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-09 16:52:28 +00:00
Sergey Biryukov
40ffe0ef06 Coding Standards: Use Yoda conditions in some wp-admin files.
Props subrataemfluence, marcio-zebedeu, bookdude13, 1naveengiri, alishankhan.
Fixes #44365, #48455.

git-svn-id: https://develop.svn.wordpress.org/trunk@47218 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-09 16:51:22 +00:00
Andrea Fercia
43fb40739d Accessibility: Media: Make the toolbar and inline uploader visual order always match the DOM order.
Depending on the specific media view, the media UI elements are placed in a
different visual order. This change makes sure their visual order always
matches the DOM order.

Propos syhc, audrasjb, afercia.
See #37188.
Fixes #48403.


git-svn-id: https://develop.svn.wordpress.org/trunk@47217 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-09 16:30:41 +00:00
Sergey Biryukov
734bf726d7 Embeds: Add support for TikTok.
Props audrasjb, jblz, peterwilsoncc, felipeloureirosantos.
Fixes #49083.

git-svn-id: https://develop.svn.wordpress.org/trunk@47216 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-09 04:53:29 +00:00
Sergey Biryukov
ca37df8027 Site Health: Only get MySQL server information in tests where it's actually needed.
This resolves an issue with plugins like HyperDB, which doesn't have a database connection until a query is made.

Props xkon, Otto42, Clorith.
See #47606.

git-svn-id: https://develop.svn.wordpress.org/trunk@47215 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-08 20:08:31 +00:00
Sergey Biryukov
95f3bdbaac Twenty Nineteen: Improve code organization in template-functions.php by moving helper functions into their own file.
These functions are moved to `inc/helper-functions.php`:

* `twentynineteen_can_show_post_thumbnail()`
* `twentynineteen_image_filters_enabled()`
* `twentynineteen_get_avatar_size()`
* `twentynineteen_is_comment_by_post_author()`
* `twentynineteen_get_discussion_data()`
* `twentynineteen_hsl_hex()`

Additionally, `twentynineteen_add_dropdown_icons()` is moved to `inc/icon-functions.php` to join `twentynineteen_nav_menu_social_icons()`.

Props akshayar, allancole, grapplerulrich.
Fixes #45984.

git-svn-id: https://develop.svn.wordpress.org/trunk@47214 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-08 12:59:44 +00:00
Sergey Biryukov
1f8531c753 Menus: When adding a label for special pages in wp_setup_nav_menu_item(), check if get_post_states() is available, to avoid fatal errors on front end.
Fixes #49374.

git-svn-id: https://develop.svn.wordpress.org/trunk@47213 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-08 12:47:33 +00:00
Sergey Biryukov
2aecc8f3e6 Tests: Add a basic test for wp() function.
Props pbearne, donmhico.
Fixes #48844.

git-svn-id: https://develop.svn.wordpress.org/trunk@47212 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-08 05:29:54 +00:00
Sergey Biryukov
11eb80e59e Menus: Use get_post_states() to denote special pages on the added menu item accordions.
Front Page, Posts Page, or Privacy Policy Page should now be marked as such on the added menu items.

Props garrett-eclipse.
Fixes #49374.

git-svn-id: https://develop.svn.wordpress.org/trunk@47211 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-07 23:44:22 +00:00
Sergey Biryukov
dce15b92d0 Docs: Improve description for the $editor_id parameter of wp_editor() and _WP_Editors::editor().
The restictions mentioned for the parameter value should be consistenct.

Props pbiron, SergeyBiryukov.
Fixes #49384.

git-svn-id: https://develop.svn.wordpress.org/trunk@47210 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-07 23:28:22 +00:00
Sergey Biryukov
23c2257935 Accessibility: Menus: Make tab panels in Add menu items section more accessible for keyboard users.
Props audrasjb, afercia.
Fixes #49211.

git-svn-id: https://develop.svn.wordpress.org/trunk@47209 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-07 21:36:59 +00:00
Sergey Biryukov
6c7f322c71 Accessibility: Customize: Improve focus styles for color picker and media upload button in Customizer.
Props audrasjb, timhavinga, afercia, karmatosed.
Fixes #48694.

git-svn-id: https://develop.svn.wordpress.org/trunk@47208 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-07 21:09:39 +00:00
Sergey Biryukov
f8b2ff1b53 Coding Standards: Adjust coding standards to always omit parentheses for include/require statements.
These are language constructs, not function calls, so the parentheses are unnecessary.

This updates the PHPCS configuration file the enforce the sniff until it is moved from the `WordPress-Extra` ruleset to the `WordPress-Core` ruleset upstream.

Follow-up to [47198].

Props desrosj, jrf, GaryJ.
Fixes #49376.

git-svn-id: https://develop.svn.wordpress.org/trunk@47207 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-07 19:14:29 +00:00
John Blackbourn
2ce61ea2d6 Posts, Post Types: Add a parameter to the post_locked_dialog action which contains a reference to the user who holds the lock.
Fixes #48443

git-svn-id: https://develop.svn.wordpress.org/trunk@47206 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-07 17:51:09 +00:00
John Blackbourn
c7caac7289 Taxonomy: Clarify the docs for the return values of the term_exists() function.
Props dotancohen, sathyapulse

Fixes #43345

git-svn-id: https://develop.svn.wordpress.org/trunk@47205 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-07 17:46:51 +00:00
John Blackbourn
1feff0de47 Script Loader: Fix a docblock so it points to the correct page on the developer reference.
Props joyously, pbiron

Fixes #48503

git-svn-id: https://develop.svn.wordpress.org/trunk@47204 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-07 17:40:29 +00:00
John Blackbourn
7efcf03d94 Posts, Post Types: Introduce a filter which allows the addition of __trashed suffixes on post slugs to be skipped.
Fixes #46433

git-svn-id: https://develop.svn.wordpress.org/trunk@47203 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-07 17:31:52 +00:00
Andrew Ozz
112649ea92 Media: Add link to the original image in the image properties if it was scaled or rotated after uploading.
Fixes #49290.

git-svn-id: https://develop.svn.wordpress.org/trunk@47202 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-07 05:11:45 +00:00
Jorge Costa
8640eaa96e 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.

git-svn-id: https://develop.svn.wordpress.org/trunk@47199 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-06 21:01:16 +00:00
Sergey Biryukov
e72fff9cef 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.

git-svn-id: https://develop.svn.wordpress.org/trunk@47198 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-06 06:31:22 +00:00
Sergey Biryukov
b02e49c2e8 Coding Standards: Move WP_Object_Cache to wp-includes/class-wp-object-cache.php.
This ensures the file containing the `WP_Object_Cache` class conforms to the coding standards.

For backward compatibility, the new file is included from `wp-includes/cache.php`.

Fixes #49373. See #49222.

git-svn-id: https://develop.svn.wordpress.org/trunk@47197 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-06 05:51:58 +00:00
Sergey Biryukov
011962fae0 Posts, Post Types: Add default menu_icon values for built-in post types.
This allows the icons to be retrieved via `get_post_type_object()`.

Props m.usama.masood, michael.ecklund, SergeyBiryukov.
Fixes #38844.

git-svn-id: https://develop.svn.wordpress.org/trunk@47196 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-05 22:38:11 +00:00
Sergey Biryukov
3d43f46907 Posts, Post Types: Change "Featured Image" post label to use sentence case: "Featured image".
This makes it more consistent with other UI elements in the block editor.

Props mcsf.
Fixes #49371.

git-svn-id: https://develop.svn.wordpress.org/trunk@47194 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-05 19:07:33 +00:00
Ian Belanger
90a8a6adf6 Bundled Themes: Twenty Twenty Menu rendering problem Unicode (Bangla).
Fixes a bug where certain words break on to a second line in the primary and footer menus, in certain languages.

Props smallprogrammers, Shital Patel, mukesh27, audrasjb.
Fixes #48970.

git-svn-id: https://develop.svn.wordpress.org/trunk@47192 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-05 15:00:40 +00:00
Sergey Biryukov
616e4ffb4e Posts, Post Types: Wrap text submitted via Quick Draft dashboard widget in the Paragraph block.
Props audrasjb, jeroenrotty.
Fixes #48120.

git-svn-id: https://develop.svn.wordpress.org/trunk@47191 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-05 08:08:37 +00:00
Sergey Biryukov
5a5c1924fd Menus: Introduce wp_nav_menu_item_custom_fields action that fires just before the move buttons of a nav menu item in the menu editor.
Props MikeSchinkel, birgire, sebastian.pisula, desrosj, helgatheviking.
Fixes #47056. See #38904, #18584.

git-svn-id: https://develop.svn.wordpress.org/trunk@47190 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-05 07:41:08 +00:00
Sergey Biryukov
f838035c8f Docs: Correct type for $item and $args parameters in Walker_Nav_Menu_Checklist and Walker_Nav_Menu_Edit to match the parent Walker_Nav_Menu` class.
Follow-up to [38559], [45537].

See #24587, #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47189 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-05 07:23:25 +00:00
Sergey Biryukov
95b89c599f Site Health: Improve focus style for accordion items on Site Health screens.
The new style is more consistent with other elements like `.wp-core-ui` buttons.

Props audrasjb, mensmaximus, afercia, melchoyce, Clorith.
Fixes #48578.

git-svn-id: https://develop.svn.wordpress.org/trunk@47188 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-05 06:41:13 +00:00
Sergey Biryukov
658ff7a581 Docs: Add a @since note for [47186].
See #48558.

git-svn-id: https://develop.svn.wordpress.org/trunk@47187 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-05 06:31:05 +00:00
Sergey Biryukov
e4d8eac50f Taxonomy: In register_taxonomy(), return the registered taxonomy object on success, for consistency with register_post_type().
Props krynes, SergeyBiryukov.
Fixes #48558.

git-svn-id: https://develop.svn.wordpress.org/trunk@47186 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-05 06:24:16 +00:00
Sergey Biryukov
1fa5058ef3 Docs: Clarify that is_page_template() accepts a template filename, not the Template Name file header.
Props mkaz.
Fixes #49362.

git-svn-id: https://develop.svn.wordpress.org/trunk@47182 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-05 03:12:14 +00:00
Sergey Biryukov
5e8563eb6b Posts, Post Types: Fail gracefully when checking whether a single post with an unregistered post status should be displayed in WP_Query::get_posts().
If the post status is not registered, assume it's not public, but still allow access to users with edit permissions (same as for a protected post status, e.g. `draft`), so that they could recover orphaned content.

Add unit tests.

Follow-up to [47178].

Props roytanck, SergeyBiryukov.
Fixes #48653.

git-svn-id: https://develop.svn.wordpress.org/trunk@47181 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-05 01:31:38 +00:00
Sergey Biryukov
5ada288488 Posts, Post Types: Revert [47179] pending test failures investigation.
See #48653.

git-svn-id: https://develop.svn.wordpress.org/trunk@47180 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-04 23:00:53 +00:00
Sergey Biryukov
9e5c22aa09 Posts, Post Types: Fail gracefully when checking whether the post should be displayed in WP_Query::get_posts() against unregistered post status.
If the post status is not registered, assume it's not public.

Follow-up to [47178].

Props roytanck.
See #48653.

git-svn-id: https://develop.svn.wordpress.org/trunk@47179 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-04 22:20:25 +00:00
Sergey Biryukov
6f15251aa4 Posts, Post Types: Fail gracefully when checking mapped cap against unregistered post status.
With `map_meta_cap` enabled for a post type, the `read_post` capability for posts with a public status is supposed to be mapped to the post type's `read` capability.

When a post is left in the database after the post status is no longer present, and WP does a `read_post` check against it, a PHP notice was thrown, and the cap check always failed.

As a more graceful fallback, the cap is now mapped onto `edit_others_posts`, which allows highly privileged users to be able to access orphaned content.

A `_doing_it_wrong()` notice is also added, so that developers and site administrators are aware that the cap mapping is failing in the absence of the registered post status.

Follow-up to [34091], which introduced a similar approach to checking mapped caps against an unregistered post type.

Props roytanck, SergeyBiryukov.
Fixes #48653.

git-svn-id: https://develop.svn.wordpress.org/trunk@47178 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-04 22:13:15 +00:00
Sergey Biryukov
0bfacbe3b2 Coding Standards: Fix WPCS issues in [47175].
See #49361.

git-svn-id: https://develop.svn.wordpress.org/trunk@47177 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-04 21:40:27 +00:00
Jorge Costa
4bcf9be615 Block Editor: Include navigation block server logic.
Core did not include the navigation block PHP files.
This commit fixes the issue referred, and now the navigation block is executed on the frontend. The block still does not work as expected and throws an error during frontend execution. That problem is going to be fixed on the next WordPress package update.
This commit adds the file as it is on the npm package used.

Props gziolo.
Fixes #49348.

git-svn-id: https://develop.svn.wordpress.org/trunk@47176 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-04 20:14:50 +00:00
Sergey Biryukov
664e5a7568 Users: Pass the $reassign parameter to the remove_user_from_blog action.
Props Tivus.
Fixes #49361.

git-svn-id: https://develop.svn.wordpress.org/trunk@47175 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-04 19:41:41 +00:00
Sergey Biryukov
8f3f181c4e Docs: Improve description for add_user_to_blog() and remove_user_from_blog() parameters.
See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47174 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-04 19:38:12 +00:00
Sergey Biryukov
2c8da49588 Users: In remove_user_from_blog():
* Change default value of the `$blog_id` parameter to match the documented type.
* Change the type of the `$reassign` parameter for consistency with `$user_id` and `$blog_id`.
* Add documentation for the return value.

See #49361.

git-svn-id: https://develop.svn.wordpress.org/trunk@47173 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-04 19:34:27 +00:00
Sergey Biryukov
e876090344 TinyMCE: Remove duplicate keys and strings from langs/wp-langs-en.js.
Props david.binda.
Fixes #49359.

git-svn-id: https://develop.svn.wordpress.org/trunk@47172 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-04 16:41:46 +00:00
Sergey Biryukov
b26b0ccf8c Database: Add ANSI to the list of incompatible SQL modes.
Starting with MySQL 5.7.5, the `ANSI` mode implies `ONLY_FULL_GROUP_BY`, which is already listed in `wpdb` as incompatible per [27072].

When `ANSI` is enabled on MySQL 5.7.5+, `ONLY_FULL_GROUP_BY` remains enabled even after being "unset" by `wpdb::set_sql_mode()`.

To prevent this, the `ANSI` mode should also be listed as incompatible. It is not enabled on default MySQL installations.

Props jnylen0.
Fixes #48377.

git-svn-id: https://develop.svn.wordpress.org/trunk@47171 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-04 01:12:53 +00:00
Sergey Biryukov
ec83cd08eb Docs: Improve documentation for WP_Dependencies, WP_Scripts, and WP_Styles methods.
See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47170 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-03 00:17:38 +00:00
Sergey Biryukov
dd48b7f757 Canonical: When removing trailing punctuation from query string arguments, match the whole query var name.
Props daveslaughter.
Fixes #49347.

git-svn-id: https://develop.svn.wordpress.org/trunk@47169 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-03 00:12:22 +00:00
Sergey Biryukov
3f050fcf63 Plugins: Remove obsolete plugin_slugs transient from WP_Plugins_List_Table::prepare_items().
The transient is only used in the `wp_dashboard_plugins_output()` function, which is deprecated and unused since [40607].

The function itself also sets the same transient, so it can be removed from `WP_Plugins_List_Table`.

Props aftabmuni.
Fixes #49340.

git-svn-id: https://develop.svn.wordpress.org/trunk@47167 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-02 15:48:37 +00:00
Sergey Biryukov
78029013d8 REST API: Merge "not allowed to create new terms" permission error message with an existing string.
Follow-up to [39309], [39313].

See #38857.

git-svn-id: https://develop.svn.wordpress.org/trunk@47166 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-02 05:39:29 +00:00
Sergey Biryukov
4e6674c48c Docs: Fix typo in a comment with WP_DEBUG_DISPLAY description.
See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47165 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-02 05:32:35 +00:00
Sergey Biryukov
706daca6a3 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.

git-svn-id: https://develop.svn.wordpress.org/trunk@47164 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-02 04:13:25 +00:00
Sergey Biryukov
73e75195eb Docs: Add more specific description for WP_Http::processResponse() return value.
Props marekdedic, takeshifurusato.
Fixes #48351.

git-svn-id: https://develop.svn.wordpress.org/trunk@47161 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-02 03:25:57 +00:00
Sergey Biryukov
fd3083e3f5 Post Thumbnails: Make sure get_post_thumbnail_id() returns an integer, to match the documented return value.
This makes the function more consistent with `get_the_ID()` or `wp_get_post_parent_id()`, both returning an integer.

Props 0v3rth3d4wn.
Fixes #40096.

git-svn-id: https://develop.svn.wordpress.org/trunk@47160 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-02 03:06:31 +00:00
Sergey Biryukov
139fe26f1f Docs: Improve inline comments in wp-admin/options.php per the documentation standards.
See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47159 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-02 02:40:50 +00:00
Sergey Biryukov
84f0321f42 Administration: Include options page name in the "Options page not found" error message to provide better context for plugin developers.
Props tdlewis77, williampatton.
Fixes #42941.

git-svn-id: https://develop.svn.wordpress.org/trunk@47158 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-01 22:40:06 +00:00
Sergey Biryukov
5e11891a05 Docs: Correct DocBlock formatting for register_setting().
Document the full list of whitelisted option key names.

See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47157 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-01 21:59:14 +00:00
Sergey Biryukov
54c6311c96 Accessibility: Text Changes: Use sentence case for the word Error in various error messages, instead of all caps.
Using all caps should be avoided for better readability and because screen readers may pronounce all-caps words as abbreviations.

Props afercia, ryokuhi, sabernhardt, garrett-eclipse.
See #47656, #43037, #42945.

git-svn-id: https://develop.svn.wordpress.org/trunk@47156 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-01 21:36:44 +00:00
Sergey Biryukov
b3da2c99a1 Text Changes: Capitalize error messages consistently.
Props Presskopp.
Fixes #42945.

git-svn-id: https://develop.svn.wordpress.org/trunk@47154 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-01 20:53:14 +00:00
Sergey Biryukov
db8a038541 Text Changes: Add missing periods to some error messages, for consistency.
Props Presskopp.
Fixes #42735.

git-svn-id: https://develop.svn.wordpress.org/trunk@47153 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-01 20:30:20 +00:00
Sergey Biryukov
9e8a7292c1 Text Changes: Add missing periods to comment status update notices, for consistency.
Props Presskopp.
See #42735.

git-svn-id: https://develop.svn.wordpress.org/trunk@47152 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-01 20:27:28 +00:00
Sergey Biryukov
3b2ba4c2b4 Networks and Sites: Reduce max-width for user and site search inputs on Dashboard screen in Network Admin.
This ensures that the inputs don't push the buttons to the next line.

Props williampatton, bordoni.
Fixes #49043.

git-svn-id: https://develop.svn.wordpress.org/trunk@47151 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-01 17:36:35 +00:00
Sergey Biryukov
d4b892f022 Docs: Document the addition of $json_report_pathname parameter to the wp_privacy_personal_data_export_file_created action.
Follow-up to [47146].

Props xkon.
Fixes #49029.

git-svn-id: https://develop.svn.wordpress.org/trunk@47150 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-01 04:15:15 +00:00
Sergey Biryukov
637b6f5456 Site Health: Rename WP_Site_Health::initialize() introduced in [47063] to ::get_instance(), for clarity and consistency with other core classes.
Use `WP_Site_Health::get_instance()` where it's needed, instead of creating multiple instances of the class.

Props afercia, xkon, Clorith, SergeyBiryukov.
See #47606.

git-svn-id: https://develop.svn.wordpress.org/trunk@47149 602fd350-edb4-49c9-b593-d223f7449a82
2020-02-01 00:37:14 +00:00
Sergey Biryukov
f0b830e62c Privacy: Clarify bulk action labels for personal data export and removal requests.
Props garrett-eclipse, xkon, shariqkhan2012, websupporter, desrosj, JoshuaWold.
Fixes #44674.

git-svn-id: https://develop.svn.wordpress.org/trunk@47148 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-31 03:41:06 +00:00
Sergey Biryukov
df755ff8ac Accessibility: Privacy: Improve the readability of the suggested text in Privacy Policy Guide.
Per WCAG 2.0 guidelines, big chunks of italic text should be avoided for better accessibility.

Props birgire, sabernhardt, xkon, garrett-eclipse, melchoyce, karmatosed, afercia, jepperask, SergeyBiryukov.
Fixes #44621. See #47327.

git-svn-id: https://develop.svn.wordpress.org/trunk@47147 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-31 03:24:00 +00:00
Sergey Biryukov
b894d8665a Privacy: Introduce a JSON file into the personal data export.
The produced ZIP archive will now include an `export.json` file along with the current `index.html`.

Props xkon.
Fixes #49029. See #46424.

git-svn-id: https://develop.svn.wordpress.org/trunk@47146 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-31 01:34:17 +00:00
Sergey Biryukov
13a9ab716e Site Health: Add support for required WordPress and PHP versions to themes.
Follow-up to [45546] for plugins.

Props flixos90, afragen.
Fixes #44592. See #40934, #meta3718.

git-svn-id: https://develop.svn.wordpress.org/trunk@47145 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-31 01:15:32 +00:00
Sergey Biryukov
7192a8f562 Privacy: Remove user's email address from personal data export filename.
Use `wp_unique_filename()` to avoid potential collisions instead.

Props xkon, garrett-eclipse, donmhico, Ov3rfly, Clorith, allendav.
Fixes #44197.

git-svn-id: https://develop.svn.wordpress.org/trunk@47144 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-31 00:56:29 +00:00
Sergey Biryukov
8b5b3bb38c Administration: Add punctuation to "If you change this, we will send you an email" message on General Settings, Network Settings, and Profile screens.
Props kinjaldalwadi, donmhico.
Fixes #49235.

git-svn-id: https://develop.svn.wordpress.org/trunk@47143 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-31 00:26:37 +00:00
Sergey Biryukov
7d90de1772 Twenty Nineteen: Remove duplicate font-size property.
The theme does not use a `px` fallback for `rem` units anywhere else.

Follow-up to [47053] for Twenty Twenty.

See #49015.

git-svn-id: https://develop.svn.wordpress.org/trunk@47140 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-31 00:07:50 +00:00
Ian Belanger
df1c7771da Fixes PHPCS Introduced in [47135].
There was extra whitespace in the previous commit, this removes it.

See #48552

git-svn-id: https://develop.svn.wordpress.org/trunk@47139 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-30 21:53:48 +00:00
K. Adam White
547a08ee03 REST API: Reuse previously-generated embedded objects when building collection response.
Store each generated embedded object in a temporary cache when querying for linked resources so that repeated links to the same resource do not trigger repeated queries or processing.

Props TimothyBlynJacobs.
Fixes #48838.



git-svn-id: https://develop.svn.wordpress.org/trunk@47138 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-30 20:20:30 +00:00
Sergey Biryukov
10a5077524 Twenty Nineteen: Standardize the Required PHP and Tested Up To headers.
* Remove `WordPress` from `Requires at least` headers.
* Ensure the `Requires at least` and `Requires PHP` headers are present in the `style.css` file.

Follow-up to [46676], which updated `style-rtl.css`, but not `style.scss` or `style.css`.

See #48517.

git-svn-id: https://develop.svn.wordpress.org/trunk@47136 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-30 20:02:46 +00:00
Ian Belanger
b651a3cb9e Bundled Themes: Twenty Twenty add theme support for responsive embeds.
Adds the call to `responsive-embed` theme support in order to fix issues with facebook embeds not being responsive at certain screen widths.

Props williampatton, nielslange.
Fixes #48552.

git-svn-id: https://develop.svn.wordpress.org/trunk@47135 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-30 19:19:37 +00:00
Sergey Biryukov
a271f98952 Themes: Replace &mdash; with &ndash; as a separator between Monday and Friday in theme starter content.
The `ndash` standardly is the "through" indicator for showing inclusive dates and numbers, while the `mdash` is an interruptor and used as an aside.

Props mikejdent, garrett-eclipse.
Fixes #48286.

git-svn-id: https://develop.svn.wordpress.org/trunk@47134 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-30 19:15:19 +00:00
Ian Belanger
363c862b66 Bundled Themes: Twenty Twenty content font CSS selector is too important.
This makes the font family selector for `entry-content` less specific and thus easier to override.

Props alexandreb3, larrach, audrasjb.
Fixes #49318.

git-svn-id: https://develop.svn.wordpress.org/trunk@47133 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-30 18:26:22 +00:00
Sergey Biryukov
b30baca3ca Dashboard: Improve the appearance of "WordPress Events and News" dashboard widget for multi-day events.
If an upcoming event spans over several days, this information is now properly reflected in the widget.

Props imath, casiepa, iandunn, hareesh-pillai, melchoyce, mapk, desrosj, audrasjb, SergeyBiryukov.
Fixes #47798.

git-svn-id: https://develop.svn.wordpress.org/trunk@47124 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-29 02:17:41 +00:00
Sergey Biryukov
7e521e68dc Docs: Fix typos in wp-admin/includes/class-pclzip.php.
With the upstream library not updated in 10 years since the last time it was merged, it should be safe to treat it as "adopted" rather than external, and make these fixes.

Props passoniate, ottok.
Fixes #49163. See #38464.

git-svn-id: https://develop.svn.wordpress.org/trunk@47123 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-29 00:54:21 +00:00
Sergey Biryukov
cfc3b57488 Docs: Improve inline comments per the documentation standards.
Includes minor code layout fixes for better readability.

See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47122 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-29 00:43:23 +00:00
Sergey Biryukov
c9663d78cf Docs: Improve comments in js/_enqueues/wp/revisions.js per the documentation standards.
Props passoniate.
Fixes #49177.

git-svn-id: https://develop.svn.wordpress.org/trunk@47120 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-29 00:35:39 +00:00
Sergey Biryukov
6bdc961d5f Docs: Improve comments in some wp-admin files per the documentation standards.
Follow-up to [47084].

Props passoniate, apedog.
Fixes #49223, #49227.

git-svn-id: https://develop.svn.wordpress.org/trunk@47119 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-29 00:33:45 +00:00
Sergey Biryukov
c1abc8203a Docs: Fix typo in a comment in js/media/models/attachment.js.
Props wptoolsdev.
Fixes #49303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47117 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-27 14:42:37 +00:00
Sergey Biryukov
1160c97303 Customize: Fix typo in CustomHeader.prototype.initialize() DocBlock in src/js/_enqueues/wp/custom-header.js.
Props ankitmaru.
Fixes #49301.

git-svn-id: https://develop.svn.wordpress.org/trunk@47116 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-27 14:32:00 +00:00
Sergey Biryukov
50aa7f980c Coding Standards: Use strict comparison in wp-admin/user/admin.php.
Apply the case-insensitive network-site comparisons added in [27725] for `wp-admin/network/admin.php` to `wp-admin/user/admin.php` too, for consistency.

Props rimadoshi.
Fixes #49300.

git-svn-id: https://develop.svn.wordpress.org/trunk@47115 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-27 14:28:12 +00:00
Sergey Biryukov
d5e20d8ab5 Comments: Add In reply to: %s parent comment link to new comment email notifications.
This information was previously available on the Moderate Comment screen in the admin, but was missing from moderation emails.

Props imath, danieltj, andraganescu, galbaras, SergeyBiryukov.
Fixes #43805. See #43429.

git-svn-id: https://develop.svn.wordpress.org/trunk@47114 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-27 04:31:48 +00:00
Sergey Biryukov
191f798201 Docs: Remove extra trailing spaces from wp_add_privacy_policy_content() DocBlock to fix WPCS issues, apply minor formatting changes for consistency.
Follow-up to [47112].

See #49282.

git-svn-id: https://develop.svn.wordpress.org/trunk@47113 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-27 01:04:08 +00:00
Andrew Ozz
9224e14e67 Privacy: Cleanup .wp-policy-help CSS remnants and add back-compat when hiding the tutorial content before copying.
Props garrett-eclipse.
Fixes #49282.

git-svn-id: https://develop.svn.wordpress.org/trunk@47112 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-26 23:00:54 +00:00
Sergey Biryukov
ffb9ef6d52 Comments: Add In reply to %s. prefix to child comments in comments feed.
The prefix includes a link to the parent comment and the name of its author.

Props zodiac1978, imath, SergeyBiryukov.
Fixes #43429.

git-svn-id: https://develop.svn.wordpress.org/trunk@47111 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-26 22:27:08 +00:00
Sergey Biryukov
3e3b98aad7 Twenty Twenty: Remove unnecessary escaping of get_the_title() in comments.php.
For users with the `unfiltered_html` capability, titles can contain legitimate markup.

The title is filtered on saving, so the content in the database is considered safe.

Props kjellr, joyously, peterwilsoncc.
Fixes #49190.

git-svn-id: https://develop.svn.wordpress.org/trunk@47110 602fd350-edb4-49c9-b593-d223f7449a82
2020-01-25 22:04:08 +00:00