Commit Graph

29255 Commits

Author SHA1 Message Date
Sergey Biryukov
4bfc4070b8 Docs: Improve description for get_blog_post().
Props stevenlinx.
Fixes #50655.
Built from https://develop.svn.wordpress.org/trunk@48467


git-svn-id: http://core.svn.wordpress.org/trunk@48236 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-14 11:06:08 +00:00
Sergey Biryukov
258bbe75cd Tests: Ignore EOL differences in some tests using multiline string assertions.
Unix vs. Windows EOL style mismatches can cause misleading failures in tests using the heredoc syntax (`<<<`) or multiline strings as the expected result.

Follow-up to [46612], [48443].

See #31432.
Built from https://develop.svn.wordpress.org/trunk@48466


git-svn-id: http://core.svn.wordpress.org/trunk@48235 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-14 01:42:04 +00:00
Andrew Ozz
02d1cc0fea Administration: Attempt to even-out the new Up/Down arrows in metabox headings and make them look a bit better. Also group them a little closer together in an attempt to reduce confusion of having two down arrows next to one another. Move the focus outline to the button instead of only the icon.
Fixes #39074.
Built from https://develop.svn.wordpress.org/trunk@48465


git-svn-id: http://core.svn.wordpress.org/trunk@48234 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-14 01:37:02 +00:00
Sergey Biryukov
a386eaebf3 Tests: Replace hardcoded /tmp/ references with get_temp_dir().
This allows more tests to pass on Windows.

Props danielhuesken, DJPaul, christophherr, joemcgill, netweb, davidbaumwald, SergeyBiryukov.
Fixes #40856, #39975.
Built from https://develop.svn.wordpress.org/trunk@48464


git-svn-id: http://core.svn.wordpress.org/trunk@48233 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-14 01:30:02 +00:00
Sergey Biryukov
fdc8c8d784 Tests: Copy themes from tests/phpunit/data to wp-content/themes, instead of creating a symlink.
This allows the theme file tests in `phpunit/tests/link/themeFile.php` to run on Windows without requiring administrative privileges.

Follow-up to [42812], [42819].

Props danielhuesken, christophherr, davidbaumwald, SergeyBiryukov.
See #40856, #39975.
Built from https://develop.svn.wordpress.org/trunk@48463


git-svn-id: http://core.svn.wordpress.org/trunk@48232 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-14 00:34:03 +00:00
John Blackbourn
6b21db7fb9 Docs: Miscellaneous docblock corrections and improvements.
See #49572
Built from https://develop.svn.wordpress.org/trunk@48462


git-svn-id: http://core.svn.wordpress.org/trunk@48231 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-13 22:10:07 +00:00
whyisjake
ac2a1c341d Customize: Ensure that widgets and nav-menus can be closed after entering content.
Previously, the ⌧ button would close the search panel, or remove the results. This restores that, in addition pressing escape will do the same.

Fixes #48198.

Props garrett-eclipse, tobifjellner, afercia, JavierCasares.


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


git-svn-id: http://core.svn.wordpress.org/trunk@48230 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-13 20:15:06 +00:00
Andrea Fercia
c7617838b1 Accessibility: Improve reordering of the post boxes in the block editor meta boxes area.
Follow-up to [48373].
- ignores hidden "sortables" areas 
- hides the reorder buttons when there's only one post box 
- makes the reorder buttons slightly bigger to match the side of the toggle button

Fixes #39074.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48229 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-13 18:03:05 +00:00
whyisjake
f83664c487 Bundled Themes: Add custom color pallettes for block editor.
Gutenberg 7.9 added support for themes to bundle their own custom styles in to the editor. These changes have been added to 2010 - 2016.

See #50120. 

Props kjellr, sabernhardt, ianbelanger. 


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


git-svn-id: http://core.svn.wordpress.org/trunk@48228 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-13 17:08:03 +00:00
Sergey Biryukov
5b107f65c8 Tests: Download Chromium for e2e and JS tests only.
This reduces the chance of random failures due to network timeouts and avoids the overhead of unnecessarily downloading ~120 MB for PHP tests.

Follow-up to [47449], [47459], [47867], [48177].

Fixes #50649.
Built from https://develop.svn.wordpress.org/trunk@48458


git-svn-id: http://core.svn.wordpress.org/trunk@48227 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-13 15:20:04 +00:00
Sergey Biryukov
af5c8f316c Docs: Improve description of the $text parameter in cancel_comment_reply_link().
Props stevenlinx.
Fixes #50642.
Built from https://develop.svn.wordpress.org/trunk@48457


git-svn-id: http://core.svn.wordpress.org/trunk@48226 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-13 14:42:03 +00:00
desrosj
5121beae78 Administration: Update Dashicons to the latest version.
This update introduces the following new icons:

- `.dashicons-align-pull-left (f10a)`
- `.dashicons-align-pull-right (f10b)`
- `.dashicons-block-default (f12b)`
- `.dashicons-cloud-saved (f137)`
- `.dashicons-cloud-upload (f13b)`
- `.dashicons-columns (f13c)`
- `.dashicons-cover-image (f13d)`
- `.dashicons-embed-audio (f13e)`
- `.dashicons-embed-generic (f13f)`
- `.dashicons-embed-photo (f144)`
- `.dashicons-embed-post (f146)`
- `.dashicons-embed-video (f149)`
- `.dashicons-exit (f14a)`
- `.dashicons-html (f14b)`
- `.dashicons-info-outline (f14c)`
- `.dashicons-insert-after (f14d)`
- `.dashicons-insert-before (f14e)`
- `.dashicons-remove (f14f)`
- `.dashicons-shortcode (f150)`
- `.dashicons-table-col-after (f151)`
- `.dashicons-table-col-before (f152)`
- `.dashicons-table-col-delete (f15a)`
- `.dashicons-table-row-after (f15b)`
- `.dashicons-table-row-before (f15c)`
- `.dashicons-table-row-delete (f15d)`
- `.dashicons-saved (f15e)`
- `.dashicons-airplane (f15f)`
- `.dashicons-amazon (f162)`
- `.dashicons-bank (f16a)`
- `.dashicons-beer (f16c)`
- `.dashicons-bell (f16d)`
- `.dashicons-calculator (f16e)`
- `.dashicons-coffee (f16f)`
- `.dashicons-database-add (f170)`
- `.dashicons-database-export (f17a)`
- `.dashicons-database-import (f17b)`
- `.dashicons-database-remove (f17c)`
- `.dashicons-database-view (f17d)`
- `.dashicons-database (f17e)`
- `.dashicons-drumstick (f17f)`
- `.dashicons-edit-page (f186)`
- `.dashicons-food (f187)`
- `.dashicons-fullscreen-alt (f188)`
- `.dashicons-fullscreen-exit-alt (f189)`
- `.dashicons-games (f18a)`
- `.dashicons-google (f18b)`
- `.dashicons-hourglass (f18c)`
- `.dashicons-linkedin (f18d)`
- `.dashicons-money-alt (f18e)`
- `.dashicons-open-folder (f18f)`
- `.dashicons-pdf (f190)`
- `.dashicons-pets (f191)`
- `.dashicons-pinterest (f192)`
- `.dashicons-printer (f193)`
- `.dashicons-privacy (f194)`
- `.dashicons-reddit (f195)`
- `.dashicons-spotify (f196)`
- `.dashicons-superhero-alt (f197)`
- `.dashicons-superhero (f198)`
- `.dashicons-twitch (f199)`
- `.dashicons-whatsapp (f19a)`
- `.dashicons-youtube (f19b)`
- `.dashicons-car (f16b)`
- `.dashicons-podio (f19c)`
- `.dashicons-xing (f19d)`


This update is the final planned update of the Dashicons font. Moving forward, the more modern approach of using SVG icons directly (as the block editor currently does) will be explored. More information on the future of Dashicons can be found on the Make Design blog: https://make.wordpress.org/design/2020/04/20/next-steps-for-dashicons/.

Props joen, johnjamesjacoby, empireoflight, youknowriad, netweb, zodiac1978, desrosj, automaton, chrisvanpatten.
Fixes #49913.
Built from https://develop.svn.wordpress.org/trunk@48456


git-svn-id: http://core.svn.wordpress.org/trunk@48225 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-13 14:26:04 +00:00
Sergey Biryukov
7c09c153d5 Upgrade/Install: Simplify compatibility checks for uploaded plugins and themes for better readability.
Use `$new_plugin_data` and `$new_theme_data` as a shorthand for the corresponding `$this->upgrader` properties.

Follow-up to [48390], [48448].

Props afragen.
See #9757.
Built from https://develop.svn.wordpress.org/trunk@48455


git-svn-id: http://core.svn.wordpress.org/trunk@48224 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-13 13:35:05 +00:00
Andrew Ozz
618c32686e Media: Fix wp_image_file_matches_image_meta() to also match when the original image URL is used.
Also refreshes and fixes some of the unit tests for media, and replaces test-image-large.png with test-image-large.jpg which is larger to allow testing of `original_image` in the image meta.

Fixes #50628.


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


git-svn-id: http://core.svn.wordpress.org/trunk@48223 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 21:20:03 +00:00
Andrew Ozz
63a2cb3060 Upgrade/Install: Use wp_strip_all_tags() for the fields in the compare table on the "Update theme/plugin from uploaded zip" screen. Some may contain HTML.
See #9757.
Built from https://develop.svn.wordpress.org/trunk@48453


git-svn-id: http://core.svn.wordpress.org/trunk@48222 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 20:00:03 +00:00
TimothyBlynJacobs
df2b9b1689 REST API: Add Content-Disposition, Content-MD5 and X-WP-Nonce as allowed cors headers.
The Content-Disposition and Content-MD5 headers allow for easier file uploading across domains by using a File/Blob object directly. The X-WP-Nonce header is allowed for making cross-origin and same-origin authenticated requests consistent.

Additionally a filter is introduced, "rest_allowed_cors_headers", to simplify the process of allowing additional request headers.

Props rmccue, TimothyBlynJacobs.
Fixes #41696.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48221 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 19:37:12 +00:00
Sergey Biryukov
9848b6b3e9 Plugins: Make delete plugin message less scary.
This adds a check if the plugin actually has an uninstall routine before saying that its data will be deleted too.

Props samful, joostdevalk, joyously, Chouby, SergeyBiryukov.
Fixes #50346.
Built from https://develop.svn.wordpress.org/trunk@48451


git-svn-id: http://core.svn.wordpress.org/trunk@48220 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 13:22:04 +00:00
Sergey Biryukov
c4543704e2 Administration: Restore the excerpt key for the Extended view mode for backward compatibility for now.
Props Offereins.
See #49715.
Built from https://develop.svn.wordpress.org/trunk@48450


git-svn-id: http://core.svn.wordpress.org/trunk@48219 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 11:36:04 +00:00
Sergey Biryukov
1556ecc000 Docs: Add a @since entry for the $hook_extra parameter added to WP_Upgrader::download_package().
Follow-up to [48399].

See #49686.
Built from https://develop.svn.wordpress.org/trunk@48449


git-svn-id: http://core.svn.wordpress.org/trunk@48218 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 11:02:03 +00:00
Sergey Biryukov
707534c2d8 Upgrade/Install: Use is_php_version_compatible() and is_wp_version_compatible() in plugin and theme requirement checks.
Follow-up to [48390].

Props afragen.
See #9757.
Built from https://develop.svn.wordpress.org/trunk@48448


git-svn-id: http://core.svn.wordpress.org/trunk@48217 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 10:55:03 +00:00
Sergey Biryukov
f83b8775b3 I18N: Move the "WordPress Backups" support URL to its own translatable string.
Follow-up to [48390].

See #9757.
Built from https://develop.svn.wordpress.org/trunk@48447


git-svn-id: http://core.svn.wordpress.org/trunk@48216 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 10:34:05 +00:00
Sergey Biryukov
3f1650122a Docs: Miscellaneous DocBlock corrections for plugin and theme updates.
See #49572.
Built from https://develop.svn.wordpress.org/trunk@48446


git-svn-id: http://core.svn.wordpress.org/trunk@48215 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 01:19:03 +00:00
Sergey Biryukov
cecf7b9823 Administration: Handle the result of Plugin_Upgrader::bulk_upgrade() for a plugin that is already at the latest version in the same way it is handled for themes.
This corrects a fragile check of the result in `wp_ajax_update_plugin()` that depended on the internal array pointer, and brings some consistency with `wp_ajax_update_theme()`.

Follow-up to [37714], [48401].
See #50448.
Built from https://develop.svn.wordpress.org/trunk@48445


git-svn-id: http://core.svn.wordpress.org/trunk@48214 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 01:16:05 +00:00
Sergey Biryukov
81a001117c Docs: Improve documentation for sanitize_user(), sanitize_title(), sanitize_title_with_dashes().
See #49572.
Built from https://develop.svn.wordpress.org/trunk@48444


git-svn-id: http://core.svn.wordpress.org/trunk@48213 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 01:13:02 +00:00
Sergey Biryukov
ea718c3f40 Tests: Ignore EOL differences in email tests using multiline string assertions.
Unix vs. Windows EOL style mismatches can cause misleading failures in tests using the heredoc syntax (`<<<`) or multiline strings as the expected result.

Follow-up to [46612], [48033].

Props davidbaumwald.
See #31432, #41750.
Built from https://develop.svn.wordpress.org/trunk@48443


git-svn-id: http://core.svn.wordpress.org/trunk@48212 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-11 23:29:03 +00:00
Sergey Biryukov
2123efcc12 Docs: Correct comments in tests/formatting/WPSlash.php per the documentation standards.
See #49572.
Built from https://develop.svn.wordpress.org/trunk@48442


git-svn-id: http://core.svn.wordpress.org/trunk@48211 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-11 22:52:05 +00:00
Sergey Biryukov
c38f99df9a Docs: Synchronize @since notes for add_magic_quotes() and wp_slash().
Follow-up to [48205], [48433].

See #49572.
Built from https://develop.svn.wordpress.org/trunk@48441


git-svn-id: http://core.svn.wordpress.org/trunk@48210 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-11 22:48:07 +00:00
Sergey Biryukov
f2a7a5e154 Bootstrap/Load: Adjust the logic in add_magic_quotes() for better readability.
Follow-up to [48205].

See #48605.
Built from https://develop.svn.wordpress.org/trunk@48440


git-svn-id: http://core.svn.wordpress.org/trunk@48209 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-11 22:44:05 +00:00
Sergey Biryukov
b640c0692e Menus: Simplify the test for wp_update_nav_menu_item() with special characters in category name.
The `menu-item-title` value is saved as a `post_title` property, so the resulting property can be checked directly, without a callback.

Follow-up to [48416].

See #48011.
Built from https://develop.svn.wordpress.org/trunk@48439


git-svn-id: http://core.svn.wordpress.org/trunk@48208 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-11 21:48:04 +00:00
Sergey Biryukov
f718b4b6ec Revisions: Restore the return value of wp_get_post_autosave() to the documented type of WP_Post for backward compatibility.
Follow-up to [48422].

See #34560.
Built from https://develop.svn.wordpress.org/trunk@48438


git-svn-id: http://core.svn.wordpress.org/trunk@48207 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-11 21:15:06 +00:00
TimothyBlynJacobs
a59fb4e50f REST API: Sanitize block renderer attributes.
In [48069] the Block Renderer was changed to register a single route for all dynamic blocks. Validation was dynamically applied based on the requested block, but sanitization was not. This commit adds the same sanitization back to the block attributes.

Props manooweb.
Fixes #50620. See #48079.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48206 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-11 20:34:05 +00:00
Sergey Biryukov
7b61df725e Revisions: Replace array_shift() with reset() in register_and_do_post_meta_boxes() for better performance.
Follow-up to [31829], [48422].

See #34560.
Built from https://develop.svn.wordpress.org/trunk@48436


git-svn-id: http://core.svn.wordpress.org/trunk@48205 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-11 12:30:02 +00:00
Sergey Biryukov
463644fc6d Coding Standards: Use strict type check for in_array() in wp-includes/feed.php.
Additionally:
* Correct inline comments per the documentation standards.
* Correct the `@ticket` reference in `tests/feed/atom.php`.

Follow-up to [48429].

See #33591.
Built from https://develop.svn.wordpress.org/trunk@48435


git-svn-id: http://core.svn.wordpress.org/trunk@48204 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-11 12:14:06 +00:00
whyisjake
5ccd0f963c Build/Test Tools: Bump lodash as part of an npm audit.
lodash 4.17.17 👉 4.17.19

See #49768.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48203 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-11 00:36:23 +00:00
whyisjake
7448ce4839 Formatting: Prevent wp_slash from returning non-strings as strings.
If a bool/float/int is passed into wp_slash it will be coerced into a string.

This changes the behavior to only slash strings. At the same time, handles recursion a little nicer by calling array_map for arrays.

Fixes #42195, #24106.

Props johnbillion, andizer, jrf, ryotasakamoto, SergeyBiryukov, donmhico, TobiasBg, markoheijnen, ryan, nacin, devesine, whyisjake.


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


git-svn-id: http://core.svn.wordpress.org/trunk@48202 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-11 00:13:04 +00:00
whyisjake
919729508c Formatting: Improve the docblock for sanitize_title().
Since sanitize title is largely used for html attributes, or post slugs, make note that accents will be removed and that the string will be limited to alphanumeric characters, underscores, and dashes.

Fixes #33756.
Props ericlewis, swissspidy, wonderboymusic, psdtohtmlguru, DrewAPicture, SergeyBiryukov, sjmur, gma992, shulard, ebinnion, whyisjake.


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


git-svn-id: http://core.svn.wordpress.org/trunk@48201 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 23:28:04 +00:00
whyisjake
5e4d204023 Coding Standards: Ensure strict type check.
See [48429], #33591.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48200 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 23:15:04 +00:00
Andrew Ozz
af35cbeee8 Media: Tiny logic fix in wp_image_file_matches_image_meta() after [48329]. No need to look in sizes if the full size image path/URL matches.
See #50543.
Built from https://develop.svn.wordpress.org/trunk@48430


git-svn-id: http://core.svn.wordpress.org/trunk@48199 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 23:06:04 +00:00
whyisjake
f06e883d01 Feeds: Ensure that enclosures produce valid XML.
Metadata that is stored on newlines has the possibility of missing values, so rather then coercing values, we can check for them and then implicity set the values.

Fixes #33591.
Props jonnybot, stevenkword, vtieu, birgire, SergeyBiryukov, davidbaumwald, rebasaurus, whyisjake.


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


git-svn-id: http://core.svn.wordpress.org/trunk@48198 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 22:23:04 +00:00
Sergey Biryukov
a6fed0173d Themes: Correct closing tag for the "Enable auto-updates" button in the JS template for theme auto-update setting.
Follow-up to [48418].

See #50516.
Built from https://develop.svn.wordpress.org/trunk@48428


git-svn-id: http://core.svn.wordpress.org/trunk@48197 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 22:03:04 +00:00
Sergey Biryukov
4645084c09 Docs: Improve description for the JS function that hides the update button for expired plugin or theme uploads.
Add missing `@since` tag.

Follow-up to [48417].

See #50612.
Built from https://develop.svn.wordpress.org/trunk@48427


git-svn-id: http://core.svn.wordpress.org/trunk@48196 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 21:15:03 +00:00
Sergey Biryukov
8ef38d34fc Docs: Improve @return tags for various conditional tags.
Props stevenlinx, SergeyBiryukov.
Fixes #50626.
Built from https://develop.svn.wordpress.org/trunk@48426


git-svn-id: http://core.svn.wordpress.org/trunk@48195 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 20:23:06 +00:00
Sergey Biryukov
376435ac9a Sitemaps: Remove some extra space from WP_Sitemaps_Stylesheet::get_stylesheet_css().
Follow-up to [48414].

See #50449.
Built from https://develop.svn.wordpress.org/trunk@48425


git-svn-id: http://core.svn.wordpress.org/trunk@48194 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 16:12:03 +00:00
Sergey Biryukov
51856d435b Administration: Bring some consistency to handling list table view modes.
* Remove duplicate variables and DocBlocks.
* Add missing description for the `$mode` global.
* Use sentence case for "Compact view" and "Extended view" labels.

Follow-up to [48398], [48423].

Props afercia, Offereins, SergeyBiryukov.
See #49715.
Built from https://develop.svn.wordpress.org/trunk@48424


git-svn-id: http://core.svn.wordpress.org/trunk@48193 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 16:04:05 +00:00
Sergey Biryukov
0f92086ca0 Administration: Make some adjustments to WP_Screen::render_view_mode():
* Restore the `$mode` global for backward compatibility.
* Remove redundant check, as `$mode` is already set at this point, and already defaults to `list` via `get_user_setting()`'s second argument.
* Use sentence case for "View mode" and "Extended view" labels.

Follow-up to [48398].

See #49715.
Built from https://develop.svn.wordpress.org/trunk@48423


git-svn-id: http://core.svn.wordpress.org/trunk@48192 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 16:02:05 +00:00
Adam Silverstein
7d0162bc2e Revisions: optimize performance when post has large number of revisions.
Improve speed and reduce the memory footprint when loading posts with many revisions.

* Use a direct query in `wp_get_post_autosave` to avoid loading all revisions.
* Query for IDs vs full objects in `register_and_do_post_meta_boxes`.

Props pdfernhout, johnnyb, miqrogroove, ocean90, senatorman, DBrumbaugh10Up, martijn-van-der-kooij, pavelevap, mackensen, mikeyarce, whyisjake.
Fixes #34560.


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


git-svn-id: http://core.svn.wordpress.org/trunk@48191 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 15:13:07 +00:00
Sergey Biryukov
3df6964fc8 Coding Standards: Use strict comparison in WP_List_Util::filter().
Correct comments per the documentation standards.

See #49542, #49572.
Built from https://develop.svn.wordpress.org/trunk@48421


git-svn-id: http://core.svn.wordpress.org/trunk@48190 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 12:46:09 +00:00
Sergey Biryukov
b03053eb2a Docs: Correct documentation for customize_controls_head hook and _customizer_mobile_viewport_meta() function.
Follow-up to [48412].

See #47369.
Built from https://develop.svn.wordpress.org/trunk@48420


git-svn-id: http://core.svn.wordpress.org/trunk@48189 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 11:36:07 +00:00
whyisjake
edb4943a9d Administration: Better align labels on the discussion options page.
The labels for Comment Moderation, and Comment Blocklist are now aligned properly with the adjacent text.

Fixes #37384.
Props ankit-k-gupta, karmatosed, FolioVision, desrosj, valentinbora, samful, whyisjake.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48188 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 06:48:06 +00:00
whyisjake
28a390c2b2 Upgrade/Install: Use ARIA button class on plugin and theme auto-updates action links
According to the [accesability guidelines](https://developer.wordpress.org/coding-standards/wordpress-coding-standards/accessibility/#semantics-for-controls), the control should be a link when JavaScript is not available and a button the rest of the time.

In addition, handlers were added for spacebar usage, and some changes to the a11y speak verbiage.

Fixes #50516.
Props ryokuhi, audrasjb, afercia, whyisjake/



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


git-svn-id: http://core.svn.wordpress.org/trunk@48187 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 06:18:04 +00:00
whyisjake
836ad98276 Upgrade/Install: Ensure cleanup after canceled update.
Ensure that the uploaded zip is hidden from the media library, where a task will remove failed installs after two hours.

Fixes #50612.

Props psykro, desrosj, joyously, azaozz, noisysocks, whyisjake. 

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


git-svn-id: http://core.svn.wordpress.org/trunk@48186 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 06:08:06 +00:00
whyisjake
2c3672d2d1 Menus: Ensure that category menus with special characters can be updated.
Slashes and HTML encoding could cause some menus not to be updated.

Fixes #48011.

Props zaheerahmad, achyuthajoy, desrosj, pento, SergeyBiryukov, donmhico, audrasjb, birgire, mikeschroder.


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


git-svn-id: http://core.svn.wordpress.org/trunk@48185 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 06:00:08 +00:00
whyisjake
9397ad46ba Coding Standards: Some missed code formatting.
Unprops: whyisjake.


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


git-svn-id: http://core.svn.wordpress.org/trunk@48184 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 01:01:03 +00:00
whyisjake
68e56464c4 Sitemaps: Add better support for RTL sites.
While the URLs are intended to be machine readable, they should always be LTR, while other data would be RTL in the sitemap.

Fixes #50449.

Props joyously, SergeyBiryukov, pbiron. apedog, ramiy.


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


git-svn-id: http://core.svn.wordpress.org/trunk@48183 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 00:50:04 +00:00
whyisjake
35257c2e2d Formatting: Ensure that wp_filter_object_list() will return an array when being passed an object with magic methods.
Fixes #50095.

Props johnjamesjacoby.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48182 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 00:31:06 +00:00
whyisjake
1158166d9c Administration: Remove multiple viewport meta tags from mobile pages.
In addition, add the `wp_admin_viewport_meta()` function, paired to the `admin_viewport_meta` filter to control attributes of the meta tag.

Fixes #47369.
Props BettyJJ, mukesh27, SergeyBiryukov, ajayghaghretiya1, msaggiorato, talldanwp, davidbaumwald, donmhico, audrasjb.


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


git-svn-id: http://core.svn.wordpress.org/trunk@48181 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-09 23:29:08 +00:00
Sergey Biryukov
d322fb66de Docs: Synchronize and correct documentation for various metadata functions and filters.
Follow-up to [47390], [47611], [48192], [48402].

See #49572, #43941, #45464.
Built from https://develop.svn.wordpress.org/trunk@48411


git-svn-id: http://core.svn.wordpress.org/trunk@48180 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-09 11:26:07 +00:00
Sergey Biryukov
c4a2b9a9e4 Widgets: Adjust formatting for displaying the closing </nav> tag in widgets for consistency with the opening tag.
Follow-up to [48349].

See #48170.
Built from https://develop.svn.wordpress.org/trunk@48410


git-svn-id: http://core.svn.wordpress.org/trunk@48179 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-08 13:44:04 +00:00
Sergey Biryukov
6fc76c162d Widgets: Correct the logic for displaying the after_widget parameter of the Archives widget.
Follow-up to [48349].

Props mukesh27, joyously.
Fixes #50609.
Built from https://develop.svn.wordpress.org/trunk@48409


git-svn-id: http://core.svn.wordpress.org/trunk@48178 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-08 13:28:03 +00:00
Sergey Biryukov
6bf6bc451f Docs: Miscellaneous DocBlock corrections.
See #49572.
Built from https://develop.svn.wordpress.org/trunk@48408


git-svn-id: http://core.svn.wordpress.org/trunk@48177 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-08 13:15:03 +00:00
Sergey Biryukov
755766f286 Docs: Further improve documentation for have_posts() and have_comments().
Follow-up to [48406]

Props stevenlinx.
See #50610.
Built from https://develop.svn.wordpress.org/trunk@48407


git-svn-id: http://core.svn.wordpress.org/trunk@48176 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-08 11:15:04 +00:00
Sergey Biryukov
3311bc8783 Docs: Improve documentation for have_posts(), have_comments(), and their WP_Query counterparts.
Props stevenlinx.
Fixes #50610.
Built from https://develop.svn.wordpress.org/trunk@48406


git-svn-id: http://core.svn.wordpress.org/trunk@48175 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-08 11:11:04 +00:00
Sergey Biryukov
c358ba7112 Upgrade/Install: Prevent the upgrade routine for updating the comment_type field in the comments table from running twice.
Follow-up to [47597], [48400].

See #50413, #49236.
Built from https://develop.svn.wordpress.org/trunk@48405


git-svn-id: http://core.svn.wordpress.org/trunk@48174 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-08 10:58:05 +00:00
Sergey Biryukov
acee95fc07 Post WordPress 5.5 Beta 1 version bump.
Built from https://develop.svn.wordpress.org/trunk@48404


git-svn-id: http://core.svn.wordpress.org/trunk@48173 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 21:53:03 +00:00
Sergey Biryukov
354d8b90b8 WordPress 5.5 Beta 1.
Built from https://develop.svn.wordpress.org/trunk@48403


git-svn-id: http://core.svn.wordpress.org/trunk@48172 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 21:01:05 +00:00
TimothyBlynJacobs
13b10697bf REST API, Meta: Introduce support for default metadata values.
The `register_meta()` API now officially supports specifying a default metadata value. When `get_metadata()` is called for a meta key that does not yet exist for the object, this default value will be returned instead of an empty string.

A new function is introduced `get_metadata_raw` to retrieve the raw metadata value from the database, without applying the registered default.

Props spacedmonkey, flixos90, rmccue, kadamwhite, mnelson4, johnbillion, chrisvanpatten, TimothyBlynJacobs.
Fixes #43941.


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


git-svn-id: http://core.svn.wordpress.org/trunk@48171 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 20:47:05 +00:00
desrosj
500508884e Administration: Fix failing tests as a result of [48397].
Because of changes to how PHP handles arrays used in `foreach()` loops in PHP >= 7.0, [48397] resulted in a failing test for PHP 5.6.

This calls `reset()` after using the `$results` array in the `foreach()` to ensure the array is treated the same and as expected.

Props azaozz, desrosj, SergeyBiryukov, xknown.
See #50448.
Built from https://develop.svn.wordpress.org/trunk@48401


git-svn-id: http://core.svn.wordpress.org/trunk@48170 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 20:38:03 +00:00
desrosj
a8521d48ac Upgrade/Install: Prevent some 5.5.0 upgrade routines from running twice.
This will prevent the options renamed for 5.5.0 from being converted twice. If a new update routine is added before 5.5 is released, the option values would be erased for anyone running `trunk` or nightlies without this change.

Props azaozz, desrosj, SergeyBiryukov, whyisjake.
Fixes #50413.
Built from https://develop.svn.wordpress.org/trunk@48400


git-svn-id: http://core.svn.wordpress.org/trunk@48169 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 19:21:06 +00:00
desrosj
8381fad76e Upgrade/Install: Add hook_extra parameter to the upgrader_pre_download filter.
This provides additional context to code running on this hook, including which plugin or theme update will be downloaded. It also brings consistency to this filter with others throughout the upgrade process.

Props obliviousharmony, desrosj.
Fixes #49686.
Built from https://develop.svn.wordpress.org/trunk@48399


git-svn-id: http://core.svn.wordpress.org/trunk@48168 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 19:15:06 +00:00
whyisjake
dcdabb5bb3 Administration: Introduce extensibility to posts and comments list table views, for accessibility purposes.
At default, expands the excerpt view to become an extended view. Includes a new `table_view_mode` filter to allow further configuration.

Fixes #49715.
Props joedolson, audrasjb, afercia, whyisjake.


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


git-svn-id: http://core.svn.wordpress.org/trunk@48167 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 19:12:03 +00:00
desrosj
48da753ff0 Administration: Prevent repeat emails for identical plugin or theme auto-update attempt failures.
This change adds a throttle mechanism to plugin and theme auto-update failure emails using similar logic to the email sent for a Core auto-update.

The first time a plugin or theme auto-update fails, the package and `new_version` will be tracked in the `auto_plugin_theme_update_emails` option. An email for this specific update attempt will not be resent.

However, if this update fails again and non-repeat failures or successful updates are also present, then the failure information will be included in that email (an email needs to be sent for the new events regardless).

Props johnbillion, arpitgshah, desrosj, audrasjb, pbiron, earnjam.
Fixes #50448.
Built from https://develop.svn.wordpress.org/trunk@48397


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

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


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

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


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

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


git-svn-id: http://core.svn.wordpress.org/trunk@48163 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 18:31:05 +00:00
Sergey Biryukov
ca1b6f324c Comments: Allow passing a custom class to the form container element in comment_form().
Props cjbj, yahil, mayankmajeji, andraganescu, SergeyBiryukov.
Fixes #41009.
Built from https://develop.svn.wordpress.org/trunk@48393


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

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


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

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


git-svn-id: http://core.svn.wordpress.org/trunk@48160 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 18:02:05 +00:00
Andrew Ozz
49bbff551b Upgrade/install: Allow plugin and theme updates from a uploaded .zip file.
Props mariovalney, cyberhobo, imath, shaunandrews, mariovalney, earnjam, desrosj, dd32, folletto, swissspidy, melchoyce, pento, joshuawold, psykro, clorith, ahortin, galbaras, pingram3541, joyously, doobeedoo, karmatosed, poena, whyisjake, earnjam, sergeybiryukov, audrasjb, azaozz.

Fixes #9757.
Built from https://develop.svn.wordpress.org/trunk@48390


git-svn-id: http://core.svn.wordpress.org/trunk@48159 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 17:49:05 +00:00
Andrea Fercia
bc15db7b97 Accessibility: Widgets: Further improve spacing between Widgets checkboxes and radio buttons in the admin interface.
Follow-up to [47598]:
- further improves the spacing after [47598] by better scoping the CSS to avoid layout glitches for custom widgets
- changes the RSS widget form to wrap the checkboxes in one single paragraph

Ideally, multiple related checkboxes and radio buttons should be grouped within a fieldset element with a legend. This will be addressed in a new Trac ticket.

Props mukesh27, SergeyBiryukov, sabernhardt.
Fixes #49228.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48158 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 17:29:04 +00:00
Andrea Fercia
a5721358e1 Docs: Reference the documentation of the new navigation_widgets_format filter instead of repeating it.
Follow-up to [48349].

Props johnbillion.
Fixes #48170.

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


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

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


git-svn-id: http://core.svn.wordpress.org/trunk@48156 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 17:01:06 +00:00
Andrew Ozz
d1dc207128 Media, REST API: Allow media edit endpoint to find remote files.
Props jonsurrell.
Fixes #50595.
Built from https://develop.svn.wordpress.org/trunk@48386


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

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


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

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


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

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


git-svn-id: http://core.svn.wordpress.org/trunk@48152 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 16:10:05 +00:00
youknowriad
ef78b5ba5a Block Editor: Add a script to run Gutenberg end 2 end tests on Core.
The script is not part of CI yet because the job takes 40mn to run
and it's not useful in all PRs/commits.

Fixes #50469.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48151 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 16:08:28 +00:00
TimothyBlynJacobs
0615a9ab37 REST API: Use new rest_get_route_for_post() in the post search handler.
In [48273] the rest_get_route_for_post function was introduced. This simplifies determining the REST API route for any given post object and adds a filter for custom controllers.

Props ravatparmar.
Fixes #50529.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48150 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 15:31:02 +00:00
John Blackbourn
3c41801c5c Administration: Reinstate the description for the admin_xml_ns hook which was accidentally removed in [47771].
See #46015.
Built from https://develop.svn.wordpress.org/trunk@48380


git-svn-id: http://core.svn.wordpress.org/trunk@48149 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 14:57:02 +00:00
ellatrix
c3e3c7ed6c Editor: update packages
Fixes #50589.


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


git-svn-id: http://core.svn.wordpress.org/trunk@48148 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 14:43:35 +00:00
Sergey Biryukov
30747fab22 Themes: Allow passing a custom class to post and comment pagination functions.
This affects:
* `get_the_post_navigation()`
* `get_the_posts_navigation()`
* `get_the_posts_pagination()`
* `get_the_comments_navigation()`
* `get_the_comments_pagination()`

Props jfarthing84, markparnell, davidbaumwald, SergeyBiryukov.
Fixes #39378.
Built from https://develop.svn.wordpress.org/trunk@48378


git-svn-id: http://core.svn.wordpress.org/trunk@48147 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 14:16:03 +00:00
John Blackbourn
913f5aaab9 Docs: Correct some @since entries added in 5.5.
See #49572
Built from https://develop.svn.wordpress.org/trunk@48377


git-svn-id: http://core.svn.wordpress.org/trunk@48146 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 14:14:04 +00:00
youknowriad
b3f1fa4edc Administration: Fix remove links color.
Fix regression introduced in [48332] where the specificity
of the admin scheme link colors was higher than the remove link colors.

Props afercia.
Fixes #50536.

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


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

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

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


git-svn-id: http://core.svn.wordpress.org/trunk@48144 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 13:45:02 +00:00
Sergey Biryukov
181717c9ab Plugins: Make sure the HTML ID attributes in plugin action links are unique.
Follow-up to [47588].

Props mukesh27, roytanck, SergeyBiryukov.
Fixes #49916.
Built from https://develop.svn.wordpress.org/trunk@48374


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

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

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

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


git-svn-id: http://core.svn.wordpress.org/trunk@48142 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 13:00:02 +00:00
Sergey Biryukov
3ba7789829 Bootstrap/Load: Set WP_DEBUG to true by default on development environments.
Props johnbillion, kraftbj, Clorith, joostdevalk, dlh.
Fixes #33161.
Built from https://develop.svn.wordpress.org/trunk@48372


git-svn-id: http://core.svn.wordpress.org/trunk@48141 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 12:57:04 +00:00
youknowriad
4fbd235b25 Customizer: Adapt the colors to the selected admin scheme colors.
Uses the $highlight-color variable to override the hardcoded colors used in the customizer UI.

Props dlh, joen.
Fixes #50547.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48140 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 11:30:01 +00:00
Sergey Biryukov
4518255c93 Themes: Allow template loading functions to pass additional arguments to the template via the $args parameter.
This affects:
* `get_header()`
* `get_footer()`
* `get_sidebar()`
* `get_template_part()`
* `locate_template()`
* `load_template()`

Note: `get_search_form()` already passes additional arguments to the template as of [44956].

Props enrico.sorcinelli, sc0ttkclark, scribu, nacin, wonderboymusic, GeertDD, beatpanda, amaschas, mintindeed, ysalame, caiocrcosta, bigdawggi, julianm, eddiemoya, shawnz, sayedwp, shamai, mboynes, mihai2u, guidobras, Mte90, apedog, stuffradio, overclokk, johnbillion, joyously, afercia, audrasjb, justlevine, SergeyBiryukov.
See #21676.
Built from https://develop.svn.wordpress.org/trunk@48370


git-svn-id: http://core.svn.wordpress.org/trunk@48139 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 11:01:59 +00:00
Sergey Biryukov
82d9974f8c Upload: Introduce pre_wp_unique_filename_file_list filter to allow for short-circuiting the scandir() call in wp_unique_filename().
This allows plugins to override the file fetching behavior to provide performance improvements for large directories.

Props joehoyle.
Fixes #50587.
Built from https://develop.svn.wordpress.org/trunk@48369


git-svn-id: http://core.svn.wordpress.org/trunk@48138 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 10:20:03 +00:00
Andrea Fercia
afa6bb4f1a Accessibility: Improve color contrast for the blue links :hover state.
For a number of years, WordPress has been using a `#00a0d2` blue shade for the links `:hover` state. This blue shade doesn't have a sufficient color contrast with the various (too many) background colors used in the admin interface.

The new `#006799` blue shade is part of the official WordPress color palette and does have a sufficient color contrast with most of the admin backgrounds.

Props ryokuhi, audrasjb, joedolson, mapk.
See #47682.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48137 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 10:11:05 +00:00
Sergey Biryukov
24ed3a9a30 REST API: Correct the check for $version argument in rest_handle_doing_it_wrong().
Move `WP_REST_Response` and `WP_Error` class names out of the translatable string.

Follow-up to [48327], [48361].

See #36271.
Built from https://develop.svn.wordpress.org/trunk@48367


git-svn-id: http://core.svn.wordpress.org/trunk@48136 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 09:56:02 +00:00
Sergey Biryukov
371dbf6dcf Docs: Miscellaneous DocBlock corrections.
See #49572.
Built from https://develop.svn.wordpress.org/trunk@48365


git-svn-id: http://core.svn.wordpress.org/trunk@48134 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 09:30:04 +00:00
Sergey Biryukov
156fcc21be Docs: Improve DocBlocks in wp-includes/nav-menu-template.php per the documentation standards.
See #49572.
Built from https://develop.svn.wordpress.org/trunk@48364


git-svn-id: http://core.svn.wordpress.org/trunk@48133 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 09:28:01 +00:00
Sergey Biryukov
adb9f003ed Site Health: Correct translator comment for the message displayed after clicking "remind me later" on the admin email confirmation.
Adjust the logic for displaying the message for better readability.

Follow-up to [48359].

See #48333.
Built from https://develop.svn.wordpress.org/trunk@48363


git-svn-id: http://core.svn.wordpress.org/trunk@48132 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 09:20:02 +00:00
Andrea Fercia
b7ed7cb184 Administration: Fix typo in forms.css after [46866].
A stray `e` made browsers ignore a CSS ruleset preventing select elements from changing color on hover.

Props ryokuhi.
See #48420.
Fixes #50580.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48131 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 07:05:03 +00:00
whyisjake
ad1c6c9586 REST API: Trigger _doing_it_wrong() if wp_send_json() is used on a REST API request
In addition to triggering the `_doing_it_wrong()` logging, also adds a `X-WP-DoingItWrong` header.

Fixes #36271.

Props rmccue, TimothyBlynJacobs.


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


git-svn-id: http://core.svn.wordpress.org/trunk@48130 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 05:01:07 +00:00
whyisjake
93b69e27d4 Administration: Ensure that disabled buttons look disabled.
This change removes the disabled state from the admin scheme specific styles.

Fixes #48709.

Props drw158, SergeyBiryukov, afercia, kennethroberson5556, melchoyce, joedolson, valentinbora, audrasjb, larrach, nrqsnchz, youknowriad.


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


git-svn-id: http://core.svn.wordpress.org/trunk@48129 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 04:21:07 +00:00
whyisjake
aad1fa48ea Site Health: Ensure that the user will be notified after a successful snooze action.
After clicking remind me later, the user is shown an admin notification.

Fixes #48333.

Props desrosj, sathyapulse, Clorith, azaozz, audrasjb, afragen, whyisjake.
 

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


git-svn-id: http://core.svn.wordpress.org/trunk@48128 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 03:59:02 +00:00
whyisjake
6542769c56 Coding standards: Fix a few phpcs errors to get tests passing.
See [48356], #43517.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48127 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 03:55:02 +00:00
TimothyBlynJacobs
d76e635459 REST API: Add support for the uniqueItems keyword.
Props sorenbronsted.
Fixes #48821.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48126 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 03:22:03 +00:00
whyisjake
49d23a2bbe Taxonomy: Add support for default terms for custom taxonomies.
The new default_term argument is added to `register_taxonomy()` allowing a user to define the default term `name` and optionally `slug` and `description`. 

Fixes #43517.

Props enrico.sorcinelli, SergeyBiryukov, desrosj, davidbaumwald, whyisjake.


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


git-svn-id: http://core.svn.wordpress.org/trunk@48125 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 00:55:03 +00:00
whyisjake
a7ad4e288e Bundled theme: Ensure appropriate title for author archives for that don't have posts.
Rather then displaying `Author: `, show `Nothing Found`.

Fixes #50421.

Props SGr33n, williampatton, ianbelanger, rebasaurus, priyomukul, virginienacci, audrasjb.


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


git-svn-id: http://core.svn.wordpress.org/trunk@48124 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 23:12:03 +00:00
whyisjake
216ea50a03 Coding Standards: Add newlines to package files.
See [48353].


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


git-svn-id: http://core.svn.wordpress.org/trunk@48123 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 23:03:05 +00:00
whyisjake
8dfe21b246 Coding standards: Revert the changes from [48352] to package.json and package-lock.json.
These changes were included accidentally. 

See [48352].

Unprops: whyisjake.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48122 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 22:09:19 +00:00
whyisjake
81b809e3d6 Administration: Move more table strings to sentence casing.
WordPress as a project has moved largely to sentence casing for UI elements in the admin. This commit moves several string$

* Move to trash
* Mark as spam
* Permanently delete comment
* Approve comment
* In response to
* Bulk actions
* Not spam
* Sumitted on
* Delete permanently
* Add media
* Upload files
* Upload images
* Add media
* Bulk select
* Restore from trash
* Search media
* Attachment details
* Create gallery
* Edit gallery
* Cancel gallery
* Add to gallery
* Image details
* Replace image
* Cancel edit
* Edit image
* Choose image
* Select and crop
* Skip cropping
* Crop image
* Audio details
* Replace audio
* Add audio source
* Video details
* Replace video
* Add video source
* Select poster image
* Add subtitles
* Create audio playlist
* Edit audio playlist.
* Cancel audio playlist
* Create video playlist
* Edit video playlist
* Add to video playlist
* Filter media


Fixes #40244.
Props afercia, bhargavbhandari90, rcutmore, webzunft, manojlovic, jeremyfelt, desrosj, lschuyler, SergeyBiryukov, whyisjake. 


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


git-svn-id: http://core.svn.wordpress.org/trunk@48121 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 21:52:21 +00:00
Dominik Schilling
93662e1d32 I18N: Fix typo in [48348].
Props swizzzpidy.
See #50578.
Built from https://develop.svn.wordpress.org/trunk@48351


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

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


git-svn-id: http://core.svn.wordpress.org/trunk@48119 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 21:00:03 +00:00
Andrea Fercia
04921ffd45 Accessibility: Widgets: Add theme support to make widgets output list of links wrapped within a <nav> element.
Widgets that output list of links can now be wrapped within `<nav>` elements to improve semantics and accessibility.

The `<nav>` elements are also native landmark regions, which helps assistive technology users to navigate through them. Themes can opt-in to this new behavior by declaring support for the new `html5` feature `navigation-widgets`.

Props joedolson, simonjanin, audrasjb, afercia.
Fixes #48170.

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


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

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


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

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


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

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


git-svn-id: http://core.svn.wordpress.org/trunk@48115 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 19:35:07 +00:00
desrosj
bc7de32645 Coding Standards: Correct two coding standards issues introduced in [48277] and [48334].
See #50504, #50550.
Built from https://develop.svn.wordpress.org/trunk@48345


git-svn-id: http://core.svn.wordpress.org/trunk@48114 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 19:23:02 +00:00
desrosj
77af0e5982 Docs: Correct instances of “auto update” with “auto-update” for consistency.
See #49572.
Built from https://develop.svn.wordpress.org/trunk@48344


git-svn-id: http://core.svn.wordpress.org/trunk@48113 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 19:15:03 +00:00
desrosj
ef0881750c Docs: Correct typo introduced in [48288].
See #42775.
Built from https://develop.svn.wordpress.org/trunk@48343


git-svn-id: http://core.svn.wordpress.org/trunk@48112 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 19:10:02 +00:00
youknowriad
1fd50f7b2d Administration: Adapts the secondary buttons colors to the admin schemes.
The admin schemes that don't meet the contrast guidelines are excluded from this change.

Props mapk, michaelarestad, mcsf, ocean90.
Closes #50537.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48111 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 19:00:04 +00:00
Sergey Biryukov
ecd07ddada Tests: Temporarily skip PDF tests if they fail due to ImageMagick permission errors.
See #50573.
Built from https://develop.svn.wordpress.org/trunk@48341


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

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

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


git-svn-id: http://core.svn.wordpress.org/trunk@48109 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 18:03:02 +00:00
Sergey Biryukov
5ad2cf365e Coding Standards: Fix JSHint issue in js/_enqueues/lib/auth-check.js
See #49573.
Built from https://develop.svn.wordpress.org/trunk@48339


git-svn-id: http://core.svn.wordpress.org/trunk@48108 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 16:27:02 +00:00
Sergey Biryukov
b99cce4e7a Tests: Add some assertions to PDF tests for better debugging.
Props enrico.sorcinelli.
See #50573.
Built from https://develop.svn.wordpress.org/trunk@48338


git-svn-id: http://core.svn.wordpress.org/trunk@48107 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 16:16:02 +00:00
Andrew Ozz
b93b409976 Heartbeat: Do not disable the login prompts when the user needs to log in again but has closed the log in modal. Add a 5 minutes timeout before asking them to log in again.
Props dsixinetu, adamsilverstein, azaozz.
Fixes #49573.
Built from https://develop.svn.wordpress.org/trunk@48337


git-svn-id: http://core.svn.wordpress.org/trunk@48106 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 16:14:04 +00:00
youknowriad
f867b02772 Block Editor: Requires title and content when registering block patterns.
Props poena.
See #50550.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48105 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 12:04:02 +00:00
youknowriad
4fa05e90e8 Block Editor: Remove the Testimonials block pattern.
This ensures we have the same patterns used in the Gutenberg plugin.

Props poena.
See #50550.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48104 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 11:19:04 +00:00
youknowriad
777872bdb1 Block Editor: Add the initial set of block patterns.
Included patterns:

text-two-columns
two-buttons
two-images
text-two-columns-with-images
text-three-columns-buttons
large-header
large-header-paragraph
three-buttons
quote
testimonials

Props mcsf, nrqsnchz.
See #50550.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48103 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 10:50:02 +00:00
Sergey Biryukov
c69101301b Tests: Correct hardcoded "3 months ago" assertion in tests/rest-api/rest-block-directory-controller.php.
Now that more than 3 months have passed since 2020-03-23, this was causing test failures.

Follow-up to [48242].

See #50321.
Built from https://develop.svn.wordpress.org/trunk@48333


git-svn-id: http://core.svn.wordpress.org/trunk@48102 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 09:51:03 +00:00
youknowriad
82487d4b29 Administration: Fix link colors for admin schemes that personalize it using the $link SASS variable.
The new "moderne" admin scheme color personalizes the link color using the $link SASS variable.
The link color doesn't apply consistently in the admin to all links, especiall button links.

Fixes #50536.

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


git-svn-id: http://core.svn.wordpress.org/trunk@48101 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 09:25:02 +00:00
Sergey Biryukov
234d0aff5c Coding Standards: Fix WPCS issues in tests/media.php.
See #50543.
Built from https://develop.svn.wordpress.org/trunk@48331


git-svn-id: http://core.svn.wordpress.org/trunk@48100 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 09:19:05 +00:00
Sergey Biryukov
8a815f22e7 Privacy: Simplify the logic for updating the meta values for personal data export requests from absolute to relative paths.
Follow-up to [48127].

See #44038.
Built from https://develop.svn.wordpress.org/trunk@48330


git-svn-id: http://core.svn.wordpress.org/trunk@48099 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 00:34:04 +00:00
Andrew Ozz
08dbc4c3bb Media:
- Introduce `wp_image_file_matches_image_meta()` utility function to check whether the image meta (retrieved by attachment ID) matches an image path or URI. A mismatch may happen in some cases, for example after the posts have been exported from one website and imported in another.
- Add unit tests for the new function.
- Improve `wp_image_src_get_dimensions()` a bit and use the new function to prevent these edge cases.

Fixes #50543.
Built from https://develop.svn.wordpress.org/trunk@48329


git-svn-id: http://core.svn.wordpress.org/trunk@48098 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-05 23:32:03 +00:00
Sergey Biryukov
4e3bad1770 Query: Make sure the found_posts property of WP_Query is always an integer, to match the documented type.
This makes the property consistent with similar properties of other classes:
* `WP_Comment_Query::$found_comments`
* `WP_Network_Query::$found_networks`
* `WP_Site_Query::$found_sites`
* `WP_User_Query::$total_users`

Props birgire, PressLabs.
Fixes #42469.
Built from https://develop.svn.wordpress.org/trunk@48328


git-svn-id: http://core.svn.wordpress.org/trunk@48097 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-05 21:34:02 +00:00
Sergey Biryukov
69e7e7681b Plugins: Consistently use an empty string as the default value for $replacement and $message parameters in:
* `_deprecated_function()`
* `_deprecated_constructor()`
* `_deprecated_file()`
* `_deprecated_argument()`
* `_deprecated_hook()`
* `apply_filters_deprecated()`
* `do_action_deprecated()`

This matches the documented type of `string` for these parameters and removes unnecessarily strict `! is_null()` checks.

Follow-up to [46792].

Props jignesh.nakrani, renathoc, SergeyBiryukov.
Fixes #49698.
Built from https://develop.svn.wordpress.org/trunk@48327


git-svn-id: http://core.svn.wordpress.org/trunk@48096 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-05 21:09:03 +00:00
Sergey Biryukov
87f464c283 Plugins: Use include_once instead of include in uninstall_plugin(), in case the plugin file is already included.
Props valchovski, pcfreak30.
Fixes #47796.
Built from https://develop.svn.wordpress.org/trunk@48326


git-svn-id: http://core.svn.wordpress.org/trunk@48095 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-05 20:32:03 +00:00
Sergey Biryukov
514ba95009 Docs: Fix typos in comments in tests/dependencies/jquery.php.
Props hareesh-pillai.
See #49572.
Built from https://develop.svn.wordpress.org/trunk@48325


git-svn-id: http://core.svn.wordpress.org/trunk@48094 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-05 20:29:00 +00:00
Andrew Ozz
e0d2307ec5 Build/Test Tools: update PHPUnit tests after [48323]. Disable and keep the specific jQuery Migrate dependency tests for use in WP 5.6.
See #37110.
Built from https://develop.svn.wordpress.org/trunk@48324


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

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


git-svn-id: http://core.svn.wordpress.org/trunk@48092 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-05 18:28:04 +00:00
Sergey Biryukov
f14f0c1ddf XML-RPC: Explicitly unset the reference to the parser resource after calling xml_parser_free() to avoid memory leaks in PHP 7.0.0 or higher.
Props procifer, ayeshrajans.
Fixes #49700.
Built from https://develop.svn.wordpress.org/trunk@48322


git-svn-id: http://core.svn.wordpress.org/trunk@48091 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-05 15:22:01 +00:00
Sergey Biryukov
b0703f3749 Options, Meta APIs: Introduce register_setting and unregister_setting actions.
Props Howdy_McGee, Pionect.
Fixes #37245.
Built from https://develop.svn.wordpress.org/trunk@48321


git-svn-id: http://core.svn.wordpress.org/trunk@48090 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-05 15:07:06 +00:00
Sergey Biryukov
93abb3b3d0 Docs: Improve documentation for various option functions.
Props andfinally, david.binda, SergeyBiryukov.
Fixes #49566.
Built from https://develop.svn.wordpress.org/trunk@48320


git-svn-id: http://core.svn.wordpress.org/trunk@48089 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-05 14:46:03 +00:00
Dominik Schilling
310db57c48 Administration: Add delete_count to wp_removable_query_args().
It's a single-use URL parameter that does not need to be passed to canonical URLs in the admin.

Props opurockey.
Fixes #50464.
Built from https://develop.svn.wordpress.org/trunk@48319


git-svn-id: http://core.svn.wordpress.org/trunk@48088 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-05 13:57:03 +00:00
Dominik Schilling
56afcf2d68 Posts: Provide a HiDPI version for the avatar used in post locked dialogs.
Props wpdesk, audrasjb, ocean90.
Fixes #39633.
Built from https://develop.svn.wordpress.org/trunk@48318


git-svn-id: http://core.svn.wordpress.org/trunk@48087 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-05 13:00:07 +00:00
Sergey Biryukov
618eeabba8 Tests: Remove ja_JP locale from Tests_DB::test_locale_floats().
This test is only relevant for locales using a comma as a decimal separator, while `ja_JP` uses a dot.

Props gh640, johnjamesjacoby, SergeyBiryukov.
Fixes #49690.
Built from https://develop.svn.wordpress.org/trunk@48317


git-svn-id: http://core.svn.wordpress.org/trunk@48086 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-05 12:52:04 +00:00