43450 Commits

Author SHA1 Message Date
Sergey Biryukov
e1001678a6 Posts, Post Types: Introduce "Filter by date" and "Filter by category" as post type and taxonomy labels, respectively.
This provides a more consistent location for these strings and allows for reusing them in other places without hardcoding them in the markup.

Props nicolalaserra, audrasjb, johnjamesjacoby, SergeyBiryukov.
Fixes #42421.

git-svn-id: https://develop.svn.wordpress.org/trunk@50120 602fd350-edb4-49c9-b593-d223f7449a82
2021-02-01 14:11:57 +00:00
Sergey Biryukov
33e4802bb3 Taxonomy: Reorder some WP_Taxonomy properties for consistency.
Follow-up to [48356], [50116].

See #52142.

git-svn-id: https://develop.svn.wordpress.org/trunk@50119 602fd350-edb4-49c9-b593-d223f7449a82
2021-02-01 11:53:16 +00:00
Sergey Biryukov
51f88a4dfb Twenty Twenty-One: Correct filter name in twenty_twenty_one_get_starter_content() DocBlock.
Props sabernhardt.
Fixes #52410.

git-svn-id: https://develop.svn.wordpress.org/trunk@50118 602fd350-edb4-49c9-b593-d223f7449a82
2021-02-01 11:47:24 +00:00
Adam Silverstein
99640e3ea2 Login: Enable filtering the back to blog link.
Add a new `login_site_html_link` filter that developers can use to adjust the "Go to site" link displayed in the login page footer.

Props ebinnion, DrewAPicture, audrasjb, hellofromTonya, sabernhardt. 
Fixes #35449.



git-svn-id: https://develop.svn.wordpress.org/trunk@50117 602fd350-edb4-49c9-b593-d223f7449a82
2021-02-01 00:16:47 +00:00
John Blackbourn
66567d3191 Taxonomy: Declare and document the sort and args properties of the WP_Taxonomy class.
These properties have been in use since 2.5 and 2.6 but were never added as actual properties on the class. This fixes that.

Props gunnard, SergeyBiryukov

Fixes #52142


git-svn-id: https://develop.svn.wordpress.org/trunk@50116 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-31 23:13:50 +00:00
Joe Dolson
15d786e91a Menus: Add sticky footer to avoid duplicate save buttons.
Make the navigation menu footer sticky so a Save Menu button is always available in the viewport. Improves usability and effectiveness of the interface when in a responsive view. 

Props garrett-eclipse, audrasjb, maxpertici, sabernhardt, kburgoine, poena
Fixes #51631

git-svn-id: https://develop.svn.wordpress.org/trunk@50115 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-31 20:09:53 +00:00
Timothy Jacobs
c8f974f2f5 App Passwords: Introduce fine grained capabilities.
Previously, all permission checks for using app passwords were implemented using `edit_user`. This commit introduces a series of more fine grained meta capabilities that should be used instead: `create_app_password`, `list_app_passwords`, `read_app_password`, `edit_app_password`, `delete_app_password` and `delete_app_passwords`. These capabilities all map to `edit_user` by default, but may now be customized by developers.

Props johnbillion, TimothyBlynJacobs.
Fixes #51703.


git-svn-id: https://develop.svn.wordpress.org/trunk@50114 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-31 19:02:30 +00:00
John Blackbourn
dad20f8424 Comments: Fix a coding standards issue introduced in [50109].
See #33717


git-svn-id: https://develop.svn.wordpress.org/trunk@50113 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-31 18:16:35 +00:00
Sergey Biryukov
e5f7496f7f I18N: Correct placeholders in translator comments in wp_new_comment_notify_comment_author().
Follow-up to [42827], [45932], [50109].

See #33717.

git-svn-id: https://develop.svn.wordpress.org/trunk@50112 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-31 17:35:11 +00:00
Sergey Biryukov
e60bf778f1 Administration: Accommodate long translations of user roles in the "Role" list table column.
Follow-up to [49317].

Props Chaton666, audrasjb, kebbet.
Fixes #52184.

git-svn-id: https://develop.svn.wordpress.org/trunk@50111 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-31 16:51:26 +00:00
johnbillion
a3503bdd08 Bundled Theme: Add Twenty Twenty to the list of ignored themes in .gitignore. This brings it inline with other bundled themes.
Fixes #52265


git-svn-id: https://develop.svn.wordpress.org/trunk@50110 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-31 16:50:02 +00:00
John Blackbourn
e978de5a8d Comments: Introduce a method for commenters to opt-in to receiving an email notification when their moderated comment gets approved.
The opt-in form is shown after the comment is submitted and held for moderation.

Sorry this took five years.

Props jeffr0, swissspidy, mrahmadawais, wonderboymusic, jdgrimes, obenland, Monika, imath, garrett-eclipse, johnbillion

Fixes #33717


git-svn-id: https://develop.svn.wordpress.org/trunk@50109 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-31 12:48:24 +00:00
Sergey Biryukov
6ef5edd41f Upgrade/Install: Allow WordPress sites to opt-in to development releases.
The `WP_AUTO_UPDATE_CORE` constant now supports `development` and `branch-development` values.

This makes it possible for sites to opt-in to updating to nightly builds without having to install a plugin.

Follow-up to [49245], [49292].

Props xkon, knutsp, afragen, audrasjb, dd32.
Fixes #51978.

git-svn-id: https://develop.svn.wordpress.org/trunk@50082 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-30 10:32:10 +00:00
Jonathan Desrosiers
5e39171693 Twenty Nineteen: Update several devDependencies.
This updates the following dependencies:
- `@wordpress/browserslist-config` from `2.7.0` to `3.0.0`.
- `autoprefixer` from `9.8.5` to `9.8.6`.
- `node-sass` from `4.14.1` to `5.0.0`.
- `postcss-cli` from `7.1.1` to `7.1.2`.
- `postcss-focus-within` from `3.0.0` to `4.0.0`.
- `rtlcss` from `2.5.0` to `2.6.2`.

There are no changes after running `build`.

See #51801.

git-svn-id: https://develop.svn.wordpress.org/trunk@50081 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-29 21:10:16 +00:00
Jonathan Desrosiers
2841088ce1 Twenty Nineteen: Update the RTL stylesheet with the block-patterns tag.
Rebuilding the RTL stylesheet was missed in [49585].

See #51098, #51099.

git-svn-id: https://develop.svn.wordpress.org/trunk@50080 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-29 21:06:27 +00:00
Jonathan Desrosiers
6d08c03c6f Twenty Twenty: Update @wordpress/scripts to the latest version.
See #51801.

git-svn-id: https://develop.svn.wordpress.org/trunk@50079 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-29 20:44:07 +00:00
Felix Arntz
986ebd436e Robots: Add max-image-preview:large directive by default.
This changeset introduces a `wp_robots_max_image_preview_large()` function which is hooked into the `wp_robots` filter to include the `max-image-preview:large` directive for all sites which are configured to be indexed by search engines. The directive allows search engines to display large image previews for the site in search results.

Props adamsilverstein, Clorith, flixos90, helen, joostdevalk, tweetythierry, westonruter.
Fixes #51511.


git-svn-id: https://develop.svn.wordpress.org/trunk@50078 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-29 20:36:03 +00:00
Jonathan Desrosiers
d6c7d0010b Twenty Twenty: Update several dependencies.
This updates the following packages:
- `@wordpress/browserslist-config` from `2.6.0` to `2.7.0`.
- `autoprefixer` from `9.6.1` to `9.8.6`.
- `concurrently` from `5.2.0` to `5.3.0`.
- `postcss-cli` from `7.1.1` to `7.1.2`.
- `rtlcss` from `2.5.0` to `2.6.2`.

See #51801.

git-svn-id: https://develop.svn.wordpress.org/trunk@50077 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-29 20:25:42 +00:00
Jonathan Desrosiers
5ad5060243 Twenty Twenty: Update the RTL stylesheet with the block-patterns tag.
Rebuilding the RTL stylesheet was missed in [49585].

See #51098, #51099.

git-svn-id: https://develop.svn.wordpress.org/trunk@50076 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-29 20:08:48 +00:00
Felix Arntz
afdb88e9cf Security: Allow short-circuiting the wp_update_https_detection_errors() process.
This changeset introduces a `pre_wp_update_https_detection_errors` filter which can be used to short-circuit the default logic for detecting problems with HTTPS support for the site, by returning a `WP_Error` object.

Props timothyblynjacobs.
See #47577.


git-svn-id: https://develop.svn.wordpress.org/trunk@50075 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-29 19:58:39 +00:00
Jonathan Desrosiers
75901d9ea2 Twenty Twenty-One: Update several devDependencies.
This updates the following dependencies:
- `@wordpress/browserslist-confg` from `2.7.0` to `3.0.0`.
- `@wordpress/eslint-plugin` from `7.3.0` to `8.0.1`.
- `sass` from `1.29.0` to `1.32.5`.
- `stylelint` from `13.8.0` to `13.9.0`

There are no changes after running `build`.

See #51801.

git-svn-id: https://develop.svn.wordpress.org/trunk@50073 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-29 19:42:45 +00:00
Felix Arntz
4e0bc3bc93 Security, Site Health: Improve accuracy in messaging about HTTPS support.
Following up on [49904], this changeset focuses mainly on improving the guidance about the current state of HTTPS in Site Health.

* Correct the existing copy to indicate that both the Site Address and the WordPress Address need to be changed to fully switch to HTTPS.
* Link to the respective input fields via anchor links rather than to the overall General Settings screen.
* Show different copy if the site is using HTTPS for the WordPress Address (for example to have only the administration panel in HTTPS), but not for the Site Address.
* Inform the user about potential problems even when the site is already using HTTPS, for example if the SSL certificate was no longer valid.
* Always rely on fresh information for determining HTTPS support issues in Site Health, and therefore change the `https_status` test to become asynchronous.
* Rename the new private `wp_is_owned_html_output()` function to a more appropriate `wp_is_local_html_output()`.

Props adamsilverstein, flixos90, johnjamesjacoby, timothyblynjacobs.
See #47577.


git-svn-id: https://develop.svn.wordpress.org/trunk@50072 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-29 19:09:49 +00:00
Sergey Biryukov
b44dd453ed Docs: Switch a comment in WP_Media_List_Table::prepare_items() to multi-line format, per the documentation standards.
Follow-up to [48417].

Props pinkalbeladiya, davidbaumwald.
Fixes #52025.

git-svn-id: https://develop.svn.wordpress.org/trunk@50071 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-29 18:52:35 +00:00
Robert Anderson
8d7e7d03ff Block Editor: Add enableCustomSpacing
Adds the `enableCustomSpacing` editor setting. This enables the custom block
spacing feature from Gutenberg.

Props nosolosw, gziolo.
Fixes #51760.


git-svn-id: https://develop.svn.wordpress.org/trunk@50070 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-29 05:03:04 +00:00
Robert Anderson
507c998eac Block Editor: Add defaultEditorStyles
The `defaultEditorStyles` setting was missing from the default block
editor settings. This causes the "Use theme styles" setting which was
added in WordPress 5.6 to not function properly.

Also, the RTL version of editor styles were not being loaded. This
change has not yet been ported over from Gutenberg.

Fixes #52394.


git-svn-id: https://develop.svn.wordpress.org/trunk@50069 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-29 04:57:49 +00:00
Anthony Burchell
8aabbb6286 Media: Remove unused refresh from _requery.
In [50067] `props.cache` was removed as it was unused. This left a lingering unused `refresh` in the `_requery` function.

Props peterwilsoncc.
See #50025.


git-svn-id: https://develop.svn.wordpress.org/trunk@50068 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-29 02:40:42 +00:00
Anthony Burchell
a8b5b71590 Media: Remove caching from filter by date in media library.
Previously, newly uploaded media attachments were missing when filtering media items by date due to lack of cache invalidation.

Props adamsilverstein, teamdnk, afercia, Mista-Flo, joedolson, youknowriad, talldanwp.
Fixes #50025.


git-svn-id: https://develop.svn.wordpress.org/trunk@50067 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-29 01:34:05 +00:00
Robert Anderson
044686ac30 Editor: Move blocks/classic -> blocks/freeform
Moves src/wp-includes/blocks/classic to src/wp-includes/blocks/freeform. This
reflects the 'classic' block being renamed to 'freeform'.

Follows [50048].
See #52334.


git-svn-id: https://develop.svn.wordpress.org/trunk@50066 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-29 00:25:34 +00:00
Timothy Jacobs
e290a9b557 App Passwords: Introduce introspection endpoint.
This introduces a new endpoint, `wp/v2/users/me/application-passwords/introspect`, that will return details about the App Password being used to authenticate the current request. This allows for an application to disambiguate between multiple installations of their application which would all share the same `app_id`.

Props xkon, peterwilsoncc, TimothyBlynJacobs.
Fixes #52275.


git-svn-id: https://develop.svn.wordpress.org/trunk@50065 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-29 00:05:20 +00:00
Timothy Jacobs
09a72ba49f REST API: Refactor rest_validate_value_from_schema into separate validation functions per-type.
Props yakimun.
Fixes #52375.


git-svn-id: https://develop.svn.wordpress.org/trunk@50060 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-28 17:59:17 +00:00
Jake Spurlock
e1beaec1be Site Health: Update the language around how PHP should be updated.
Follow-up to [50042].

Props SergeyBiryukov.

See #52327.


git-svn-id: https://develop.svn.wordpress.org/trunk@50058 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-28 17:21:48 +00:00
Sergey Biryukov
151787f21c Docs: Update documentation for WP_Application_Passwords::application_name_exists_for_user() per the documentation standards.
Follow-up to [50030].

See #51941.

git-svn-id: https://develop.svn.wordpress.org/trunk@50057 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-28 13:09:10 +00:00
Sergey Biryukov
2efb3ad330 Privacy: Add newlines to the index.php file in wp-personal-data-exports directory, for consistency with other similar files.
Follow-up to [50037].

See #52299.

git-svn-id: https://develop.svn.wordpress.org/trunk@50055 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-28 12:58:01 +00:00
Sergey Biryukov
d8b7a219b3 Docs: Update documentation for wp_is_site_protected_by_basic_auth() per the documentation standards.
Follow-up to [49752], [50006].

See #52066.

git-svn-id: https://develop.svn.wordpress.org/trunk@50053 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-28 11:04:08 +00:00
Sergey Biryukov
919019865a Docs: Revert documentation change for wp_get_attachment_metadata().
This more accurately describes the behavior of the function, and is more consistent with the documentation for other post and attachment functions.

Follow-up to [50039].

Props Mista-Flo.
See #52196.

git-svn-id: https://develop.svn.wordpress.org/trunk@50051 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-28 10:40:31 +00:00
Sergey Biryukov
988bbf67bb Coding Standards: Simplify a long condition in WP_Site_Health_Auto_Updates::test_wp_version_check_attached() for better readability.
Follow-up to [50035].

See #52135.

git-svn-id: https://develop.svn.wordpress.org/trunk@50049 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-28 10:34:29 +00:00
Robert Anderson
bc405697b0 Editor: Update @wordpress npm packages
Update @wordpress npm packages to the latest published versions. This means that
the block editor includes functionality that exists in Gutenberg 9.8.

See #52334.
Props isabel_brison.


git-svn-id: https://develop.svn.wordpress.org/trunk@50048 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-28 02:01:50 +00:00
Jake Spurlock
8bfe823278 Site Health: Update php update strings to not overpromise performance.
Fixes #52327.

Props chanthaboune, SergeyBiryukov, audrasjb, Clorith, whyisjake.



git-svn-id: https://develop.svn.wordpress.org/trunk@50041 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-28 00:16:21 +00:00
Jake Spurlock
7447e215b7 Media: Ensure that wp_get_attachment_metadata can return values from the global $post, if avaiable.
In [49084] (for #50679), wp_get_attachment_metadata() was changed to improve performance, but it had the side effect of eliminating the ability to call it with no arguments and have it default to using the global $post.

This change restores that ability, while keeping the performance improvements from the original change.

Fixes #52196.

Props cfinke, hellofromTonya, mukesh27, dilipbheda, Mista-Flo, audrasjb, SergeyBiryukov, whyisjake.



git-svn-id: https://develop.svn.wordpress.org/trunk@50039 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-28 00:07:21 +00:00
Jake Spurlock
a76f895146 Privacy: Ensure that exported user data reports can't be found with directory listings.
By moving from `.html` to `.php` files, we can prevent directory listings, and ensure that WordPress can load.

Fixes #52299.

Props lucasbustamante, xkon, freewebmentor, SergeyBiryukov, whyisjake. 


git-svn-id: https://develop.svn.wordpress.org/trunk@50037 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-27 23:45:29 +00:00
Jake Spurlock
448dd9d63c Site Health: Only run the version checks on the main site.
The version checks that are setup in `wp-includes/update.php` do set up the action, but only for the main site.

Fixes #52135.

Props audrasjb, SergeyBiryukov, maxpertici, aaribaud.
 


git-svn-id: https://develop.svn.wordpress.org/trunk@50035 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-27 23:25:55 +00:00
Joe Dolson
8023f34a6a Revisions: Generate correct number of columns in wp_text_diff.
The function `wp_text_diff` generated an invalid table structure if the $args parameter contained any values. This patch corrects the structure generated by `wp_text_diff` and related usages so that the column count matches the data generated. Additionally, this patch passes arguments to the Revisions screen so that the screen has column headings that reflect the content in each column. Improves the accessibility and usability of the Revisions table.

Props joedolson, mehulkaklotar, afercia, adamsilverstein, zodiac1978, jeremyfelt
Fixes #25473

git-svn-id: https://develop.svn.wordpress.org/trunk@50034 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-27 21:52:10 +00:00
Joe Dolson
bc3177153d Twenty Twenty: Remove aria-expanded on search modal close button.
The Twenty Twenty search modal uses aria-expanded correctly on the Search button, but toggles the aria-expanded value on the 'close' button. The close button is a different control, however, so the attribute value toggling is uneven. The close button does not toggle any behavior; it only closes a control that has already been opened.

Props alexstine, audrasjb
Fixes #52355

git-svn-id: https://develop.svn.wordpress.org/trunk@50033 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-27 21:31:42 +00:00
Joe Dolson
482a549085 Administration: Remove italic text to improve readability.
Italicized text can be difficult to read for some people with dyslexia or related forms of reading disorders. This removes italics on a number of larger blocks onpm run grunt rpf text in the admin. This has been a task 5.3; this commit closes the task. Further instances of italicized text should be addressed individually.

Props afercia, xkon, audrasjb
Fixes #47327

git-svn-id: https://develop.svn.wordpress.org/trunk@50032 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-27 21:02:12 +00:00
Timothy Jacobs
e1c98a744b App Passwords: Improve validation and sanitization of the application name.
Application names are now required to be unique and cannot contain solely whitespace characters. Additionally, invalid characters are now stripped from the application name using `sanitize_text_field()`.

Props Boniu91, hellofromTonya, engahmeds3ed, xkon, francina.
Fixes #51941.


git-svn-id: https://develop.svn.wordpress.org/trunk@50030 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-27 19:03:42 +00:00
Anthony Burchell
52d751751a Media: Reintroduce caching for Media Library query.
In [50021], caching was removed causing unintended classic block media flows to fail.

Reverts [50021].
See #50025.


git-svn-id: https://develop.svn.wordpress.org/trunk@50029 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-27 14:49:56 +00:00
Sergey Biryukov
fa1288d20c Accessibility: Administration: Respect the prefers-reduced-motion media query for update icon spinner animations.
The update icon rotation should not occur when the user has opted to reduce motion, for example by selecting the "Reduce motion" option in macOS' preferences or unselecting "Show animations in Windows" in Windows' preferences.

Follow-up to [47813], [50027].

Props xkon, audrasjb, johnbillion.
Fixes #52263. See #51476.

git-svn-id: https://develop.svn.wordpress.org/trunk@50028 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-27 11:39:50 +00:00
Sergey Biryukov
7a5a5a7939 Plugins: Rotate the Updates icon in the admin bar when performing inline updates on the Plugins screen.
This provides better indication within the viewport about ongoing processes on the page when updating several plugins at the same time, but without using the bulk updater.

Props ravipatel, audrasjb, johnjamesjacoby, paaljoachim, hellofromTonya, sabernhardt, mdwolinski, karmatosed, SergeyBiryukov.
Fixes #51476.

git-svn-id: https://develop.svn.wordpress.org/trunk@50027 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-27 10:57:43 +00:00
Sergey Biryukov
4ea42e3a71 Twenty Twenty-One: Correct colors for the Menu button.
As per design, the background should be transparent and the text should be dark grey, not vice versa.

Follow-up to [49987].

Props poena.
Fixes #52374. See #51927.

git-svn-id: https://develop.svn.wordpress.org/trunk@50026 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-26 18:58:08 +00:00
Kelly Choyce-Dwan
9f03cdadcb Administration: Standardize colors used in CSS to a single palette.
This is part of a larger project in cleaning up core's admin CSS. This collapses all colors used in the CSS to one of 12 blues, greens, reds, and yellows, 13 grays, pure black, and pure white. The colors are perceptually uniform from light to dark, half of each range has a 4.5 or higher contrast against white, the other half has a 4.5 or higher contrast against black.

Standardizing on this set of colors will help contributors make consistent, accessible design decisions. The full color palette can be seen here: https://codepen.io/ryelle/full/WNGVEjw

Props notlaura, danfarrow, kburgoine, drw158, audrasjb, Joen, hedgefield, ibdz, melchoyce.
See #49999.



git-svn-id: https://develop.svn.wordpress.org/trunk@50025 602fd350-edb4-49c9-b593-d223f7449a82
2021-01-26 18:53:55 +00:00