Fix the enter key in profile form fields moving focus to the application password input instead of submitting the profile update for. Replace the submit button type used for application passwords with `button type="button"` and ensure that the enter key's native behavior isn't overwritten.
props audrasjb, alexstine, promz, sabernhardt.
Fixes#52849.
Built from https://develop.svn.wordpress.org/trunk@51086
git-svn-id: http://core.svn.wordpress.org/trunk@50695 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Add accessible names to several theme controls so provide better context for screen reader users. Change theme details element into a button that can receive focus. Ensure focus is set back on existing theme when theme details modal is closed.
props alexstine, poena.
Fixes#52649.
Built from https://develop.svn.wordpress.org/trunk@51083
git-svn-id: http://core.svn.wordpress.org/trunk@50692 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Fix the link returned by `get_comment_reply_link()` so the link points to the correct page of comments when links are paginated. While this link is normally overridden by the comment-reply script, if that script is disabled, the link would point to a location that did not exist when comments were paginated.
props MrPauloEn, paaggeli, alexstine, engahmeds3ed.
Fixes#51189.
Built from https://develop.svn.wordpress.org/trunk@51081
git-svn-id: http://core.svn.wordpress.org/trunk@50690 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Technically, this is redundant, as the `comment_author`, `comment_author_email`, and `comment_author_url` fields are already escaped via `get_comment_to_edit()` before the form is displayed.
However, this brings some consistency with the `comment_author` and `comment_author_url` fields being escaped in the same form.
Follow-up to [11721].
Props utsav72640.
Fixes#53349.
Built from https://develop.svn.wordpress.org/trunk@51080
git-svn-id: http://core.svn.wordpress.org/trunk@50689 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This ensures that not only the return values match the expected results, but also that their type is the same.
Going forward, stricter type checking by using `assertSame()` should generally be preferred to `assertEquals()` where appropriate, to make the tests more reliable.
Follow-up to [50380], [50959], [50960], [50973], [50993], [51003], [51051], [51054].
See #52482.
Built from https://develop.svn.wordpress.org/trunk@51079
git-svn-id: http://core.svn.wordpress.org/trunk@50688 1a063a9b-81f0-0310-95a4-ce76da25c4cd
The recovery mode email is sent from within the WP_Recovery_Mode::handle_error() method, but that method is only called by the fatal error handler if WP_Recovery_Mode has been initialized. This adjusts the message to only say the email has been sent if it can be sent.
Props reynhartono, stevegrunwell for initial plan.
Fixes#52560.
Built from https://develop.svn.wordpress.org/trunk@51076
git-svn-id: http://core.svn.wordpress.org/trunk@50685 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Switch the display to flex. The action items use their intrinsic space, rather than a fixed grid, which prevents too much space between items on larger mobile screens.
Props arunsathiya, sabernhardt, danfarrow, notlaura, aliveic, y_kolev
Fixes#48546, #47895.
Built from https://develop.svn.wordpress.org/trunk@51073
git-svn-id: http://core.svn.wordpress.org/trunk@50682 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Adds new hooks (rest_save_sidebar, rest_delete_widget, rest_after_save_widget)
to the widgets REST API and uses them to delete the fresh_site option when
updating widgets via the REST API. This ensures that starter content isn't
loaded in the Customizer after a user makes changes.
Fixes#53317.
Props kevin940726, garrett-eclipse, andraganescu, hellofromtonya.
Built from https://develop.svn.wordpress.org/trunk@51068
git-svn-id: http://core.svn.wordpress.org/trunk@50677 1a063a9b-81f0-0310-95a4-ce76da25c4cd
By the time the tests run, both `wp_is_site_protected_by_basic_auth()` and `rest_url()` functions are available, so there is no need to check for their existence.
Follow-up to [44986], [51057].
Props Clorith, costdev, SergeyBiryukov.
Fixes#52642.
Built from https://develop.svn.wordpress.org/trunk@51066
git-svn-id: http://core.svn.wordpress.org/trunk@50675 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Adds the `'sidebar_admin-setup'`, `'sidebar_admin_page'`, and
`current_theme_supports( 'widgets' )` check to the widgets block editor so that
the block editor screen is more compatible with the classic screen.
Fixes#53288.
Props isabel_brison.
Built from https://develop.svn.wordpress.org/trunk@51061
git-svn-id: http://core.svn.wordpress.org/trunk@50670 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Adds a new 'widget_block_content' filter to the widget block and hooks
`run_shortcode`, `autoembed`, `do_blocks`, and `do_shortcode` into it by
default. This is simlar to `widget_text_content.`
Fixes#51566.
Props talldanwp.
Built from https://develop.svn.wordpress.org/trunk@51058
git-svn-id: http://core.svn.wordpress.org/trunk@50667 1a063a9b-81f0-0310-95a4-ce76da25c4cd
The test to confirm if Authorization headers can be used and recognized by WordPress needs to include a username and password combination that WordPress can compare against during the testing phase. The inclusion of credentials here would unfortunately also invalidate any existing basic auth session for the site, for example if the user had added this as an extra layer of security on their back-end.
This test is now skipped if the `wp_is_site_protected_by_basic_auth()` function detects that basic auth is being used, since the act of using basic auth to access the site confirms that this feature is working as expected in the first place.
Props WebDragon, TimothyBlynJacobs, costdev.
Fixes#52642.
Built from https://develop.svn.wordpress.org/trunk@51057
git-svn-id: http://core.svn.wordpress.org/trunk@50666 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This ensures correct load order when style concatenation is used, e.g. when `SCRIPT_DEBUG` is off.
Additionally, make sure the `WP_CONTENT_DIR` constant is defined for use in `get_theme_root()` via `get_stylesheet_directory()`.
Follow-up to [50992], [51001], [51013].
Props nosolosw.
See #53175.
Built from https://develop.svn.wordpress.org/trunk@51056
git-svn-id: http://core.svn.wordpress.org/trunk@50665 1a063a9b-81f0-0310-95a4-ce76da25c4cd
In core, you can run `tests/gutenberg/run.js` script to run the Gutenberg e2e tests
against Core with the plugin being disabled. This test ensures that the integration
of the block editor with Core is working properly.
This commit updates the Gutenberg base branch to be used for the tests to be wp/trunk
which corresponds to the latest packages that are included in Core.
See #52991.
Built from https://develop.svn.wordpress.org/trunk@51052
git-svn-id: http://core.svn.wordpress.org/trunk@50661 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Clarify that as of WordPress 4.7, the `$urls` parameter can accept arrays of specific HTML attributes as its child elements, in addition to URLs.
Follow-up to [37920], [38826].
Props vanyukov, Rahmohn, desrosj, peterwilsoncc, SergeyBiryukov.
Fixes#52842.
Built from https://develop.svn.wordpress.org/trunk@51048
git-svn-id: http://core.svn.wordpress.org/trunk@50657 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Since the function only checks the raw, non-parsed post content, reusable blocks are just a `core/block` type and nothing more at that point.
In order to also check reusable blocks, the content needs to be parsed using `parse_blocks()` first.
Props vyskoczilova, peterwilsoncc.
Fixes#53140.
Built from https://develop.svn.wordpress.org/trunk@51046
git-svn-id: http://core.svn.wordpress.org/trunk@50655 1a063a9b-81f0-0310-95a4-ce76da25c4cd
"Tested up to" is not displayed on the theme directory or within the WordPress dashboard, but should be updated to be accurate for anyone reading the theme's source code.
Props akabarikalpesh, francina, mukesh27.
Fixes#53276.
Built from https://develop.svn.wordpress.org/trunk@51042
git-svn-id: http://core.svn.wordpress.org/trunk@50651 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This updates the following dependencies:
- `chalk` from `4.1.0` to `4.1.1`.
- `dotenv` from `8.2.0` to `10.0.0`.
- `grunt` from `1.4.0` to `1.4.1`.
- `sass` from `1.32.12` to `1.34.0`.
- `sinon` from `10.0.0` to `11.1.1`.
- `uglify-js` from `3.13.6` to `3.13.8`.
See #52624.
Built from https://develop.svn.wordpress.org/trunk@51040
git-svn-id: http://core.svn.wordpress.org/trunk@50649 1a063a9b-81f0-0310-95a4-ce76da25c4cd
The logic to enable or disabled colors, gradients, and font sizes missed a negative operator, so when things should be enabled they weren't and they should be disabled they were enabled. This commit fixes the logic.
Props ntsekouras.
See #53175.
Built from https://develop.svn.wordpress.org/trunk@51031
git-svn-id: http://core.svn.wordpress.org/trunk@50640 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Returns the test suite with the addition of defining a URL in the RSS widget within `WP_Test_REST_Widgets_Controller::test_get_items()` to work around an infinite loop in `WP_Widget_RSS` on PHP 8 if the URL is unset or empty.
Reverts [51020].
Props peterwilsoncc, TimothyBlynJacobs.
See #41683.
Built from https://develop.svn.wordpress.org/trunk@51029
git-svn-id: http://core.svn.wordpress.org/trunk@50638 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Add `$status` parameter to `post_exists()` to allow developers to specify a post type, date and status to ensure they hit the `wp_posts` table's `type_status_date` index when determining if a post exists.
Props apokalyptik, boonebgorges, brettshumaker, DrewAPicture, MikeHansenMe, peterwilsoncc, whyisjake.
Fixes#34012.
Built from https://develop.svn.wordpress.org/trunk@51027
git-svn-id: http://core.svn.wordpress.org/trunk@50636 1a063a9b-81f0-0310-95a4-ce76da25c4cd
By default, a post most contain any of the requested terms to be included in the response. This commit adds a new `operator` property that can be set to `AND` to require a post to contain all of the requested terms.
For example, `/wp/v2/posts?tags[terms]=1,2,3&tags[operator]=AND` will return posts that have tags with the ids of 1, 2, and 3.
Props dlh, earnjam, Clorith, jnylen0, sebbb.
Fixes#41287.
Built from https://develop.svn.wordpress.org/trunk@51026
git-svn-id: http://core.svn.wordpress.org/trunk@50635 1a063a9b-81f0-0310-95a4-ce76da25c4cd
The styles for the Privacy settings page were based on the Site Health section. These were duplicated into `edit.css` in #49264. This change merges the selectors from Site Health into the Privacy section, to reduce that duplicate code.
Props xkon, notlaura, clorith.
See #52429.
Built from https://develop.svn.wordpress.org/trunk@51025
git-svn-id: http://core.svn.wordpress.org/trunk@50634 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Adds a button to the media upload page to make copying the url possible on the same page when a media item upload is successful.
Props anotia, ryokuhi, Mista-Flo, lukecarbis, antpb, claytoncollie, shaunandrews, joedolson.
Fixes#51754.
Built from https://develop.svn.wordpress.org/trunk@51023
git-svn-id: http://core.svn.wordpress.org/trunk@50632 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Add an endpoint for fetching block patterns from WordPress.org, and load the block patterns from this new API. Remove the block patterns that have already been moved to WordPress.org/patterns.
Props ryelle, iandunn, youknowriad, timothyblynjacobs.
Fixes#53246.
Built from https://develop.svn.wordpress.org/trunk@51021
git-svn-id: http://core.svn.wordpress.org/trunk@50630 1a063a9b-81f0-0310-95a4-ce76da25c4cd
In `wp_get_document_title(), the returned value is currently passed directly through `wptexturize()`, `convert_chars()`, and `capital_P_dangit()`, and is done so after the `document_title_parts` filter is run.
This makes it impossible to fully control the output of `wp_get_document_title()` and is inconsistent with how other similar text is processed with these functions.
This commit introduces the `document_title` filter, which is run immediately before returning the results of the `wp_get_document_title()` function and moves the three formatting functions mentioned above to the new filter hook. This allows developers to further modify the title after being prepared by WordPress, or to modify the functions hooked to this filter as they wish.
Props dragunoff, jeremyfelt, paaggeli, audrasjb.
Fixes#51643.
Built from https://develop.svn.wordpress.org/trunk@51019
git-svn-id: http://core.svn.wordpress.org/trunk@50628 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This improves performance for sites with persistent cache backend having a lot of pages requested via the `get_pages() function, by taking advantage of `wp_cache_get_multiple()` instead of fetching each individual page from the backend cache server one by one.
It also matches the behaviour of `get_pages()` when the pages are retrieved from the database.
Props david.binda, hellofromTonya.
Fixes#51469.
Built from https://develop.svn.wordpress.org/trunk@51018
git-svn-id: http://core.svn.wordpress.org/trunk@50627 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This makes it easier to run `phpunit` Grunt tasks without having to figure out how and which PHPUnit version needs to be installed.
It also more closely matches the `format:php` task.
Follow-up to [47881].
Props ocean90.
Fixes#53015.
Built from https://develop.svn.wordpress.org/trunk@51016
git-svn-id: http://core.svn.wordpress.org/trunk@50625 1a063a9b-81f0-0310-95a4-ce76da25c4cd
The `customize_changeset`, `wp_block`, and `wp_template` post types are not displayed in the admin menu or in the admin bar.
If they do get added, the labels can just fall back to `name` and `singular_name` until separate strings are required for more flexible translations.
Follow-up to [38810], [44146], [51003].
See #53176.
Built from https://develop.svn.wordpress.org/trunk@51015
git-svn-id: http://core.svn.wordpress.org/trunk@50624 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This provides direct links to install and activate the plugin, if the user has the capabilities to do so, instead of just linking to plugin search results.
It also matches more closely the message about installing the Classic Editor plugin for meta boxes incompatible with the block editor.
Follow-up to [22855], [44280], [45657].
Props tw2113, peterwilsoncc, SergeyBiryukov.
Fixes#52669.
Built from https://develop.svn.wordpress.org/trunk@51011
git-svn-id: http://core.svn.wordpress.org/trunk@50620 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This updates the phpass library from version `0.3` to the latest version of `0.5`. This is a minor update that includes some adjustments to be more friendly with newer versions of PHP.
The changes made in [30466] have also been applied to the new version of the library. This should now be the only WordPress specific modification do this library.
Props ayeshrajans, dd32, otto42, desrosj.
Fixes#51549.
Built from https://develop.svn.wordpress.org/trunk@51008
git-svn-id: http://core.svn.wordpress.org/trunk@50617 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Adds an option to bulk delete menu items from the core Navigation Menus screen, offering a considerable usability benefit when making significant changes to navigation menus.
Uses the bulk select pattern found in post and media lists for consistency with other core management screens, rather than the rapid delete pattern found in menus in the customizer.
Props wphound, welcher, melchoyce, maxpertici, audrasjb
Fixes#21603.
Built from https://develop.svn.wordpress.org/trunk@51006
git-svn-id: http://core.svn.wordpress.org/trunk@50615 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This adds a new parameter to the action and filter hooks found in `wp_insert_user()` to pass the raw user data received through `$userdata` to hooked functions.
This will allow hooked functions to perform more contextual adjustments to new users, and makes supplying custom user meta fields possible.
Props johnbillion, audrasjb.
Fixes#53110.
Built from https://develop.svn.wordpress.org/trunk@51005
git-svn-id: http://core.svn.wordpress.org/trunk@50614 1a063a9b-81f0-0310-95a4-ce76da25c4cd
In IE11, the floated icon causes the "Howdy, username" to wrap to a second line, preventing access to help tabs and possibly affecting the frontend. Changing the display fixes the layout, and prevents the wrap.
Props bhwebworks, 5um17, sabernhardt, boniu91, audrasjb.
Fixes#26933.
Built from https://develop.svn.wordpress.org/trunk@51004
git-svn-id: http://core.svn.wordpress.org/trunk@50613 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This makes it easier to view the post on the front end of the site when moderating comments, without having to open the editor first.
Props trejder, audrasjb, vladytimy, lukecarbis, ayeshrajans, chaion07, paaljoachim, hareesh-pillai, SergeyBiryukov.
Fixes#52353.
Built from https://develop.svn.wordpress.org/trunk@50999
git-svn-id: http://core.svn.wordpress.org/trunk@50608 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Moves the widgets block editor from Gutenberg into WordPress Core.
- Adds @wordpress/edit-widgets, @wordpress/customize-widgets and
@wordpress/widgets.
- Modifies wp-admin/widgets.php to branch between the old editor and new editor
depending on wp_use_widgets_block_editor().
- Modifies WP_Customize_Widgets to branch between the old editor control and new
editor control depending on wp_use_widgets_block_editor().
Follows [50996] which was missing these files.
See #51506.
Props isabel_brison, TimothyBlynJacobs, andraganescu, kevin940726, talldanwp.
Built from https://develop.svn.wordpress.org/trunk@50997
git-svn-id: http://core.svn.wordpress.org/trunk@50606 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Moves the widgets block editor from Gutenberg into WordPress Core.
- Adds @wordpress/edit-widgets, @wordpress/customize-widgets and
@wordpress/widgets.
- Modifies wp-admin/widgets.php to branch between the old editor and new editor
depending on wp_use_widgets_block_editor().
- Modifies WP_Customize_Widgets to branch between the old editor control and new
editor control depending on wp_use_widgets_block_editor().
Fixes#51506.
Props isabel_brison, TimothyBlynJacobs, andraganescu, kevin940726, talldanwp.
Built from https://develop.svn.wordpress.org/trunk@50996
git-svn-id: http://core.svn.wordpress.org/trunk@50605 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Historically, the block editor has been opinionated about the size of the canvas and the alignments.
Themes with theme.json will have to define a "layout" in their settings and the classic stylesheet won't be loaded anymore for this.
Props nosolosw.
See #53175.
Built from https://develop.svn.wordpress.org/trunk@50992
git-svn-id: http://core.svn.wordpress.org/trunk@50601 1a063a9b-81f0-0310-95a4-ce76da25c4cd
The PHPUnit 7.5+ method `assertEqualsWithDelta()` was polyfilled for PHPUnit < 7.5, but also overloaded for PHPUnit 7.5 itself, which was not necessary and created a higher chance of signature conflicts, especially when the WP test suite is used as a basis for integration tests with plugins/themes.
This change removes the unnecessary overloading for PHPUnit 7.5+ and simplifies the overloaded method for PHPUnit < 7.5, including removing the `IsEqual()` class alias declaration, no longer needed.
Follow-up to [48952].
Props jrf.
See #52625.
Built from https://develop.svn.wordpress.org/trunk@50986
git-svn-id: http://core.svn.wordpress.org/trunk@50595 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Always test for newer class names first and fall back to the older.
This improves compatibility when running PHPUnit via a phar while there is also a Composer-installed version of PHPUnit on the system.
Props jrf.
See #52625.
Built from https://develop.svn.wordpress.org/trunk@50982
git-svn-id: http://core.svn.wordpress.org/trunk@50591 1a063a9b-81f0-0310-95a4-ce76da25c4cd
The `update_user_option()` function is a way to update a user meta value after adding a blog’s prefix to the beginning of the meta key. But when the fourth parameter is `true`, the behavior is exactly the same as calling `update_user_meta()` directly.
This replaces all instances of `update_user_option()` when the fourth parameter is `true` in Core with a direct call to `update_user_meta()` to prevent an unnecessary call to `update_user_option()`.
Props johnjamesjacoby, zkancs, obenland, desrosj.
Fixes#43339.
Built from https://develop.svn.wordpress.org/trunk@50981
git-svn-id: http://core.svn.wordpress.org/trunk@50590 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This shows the parent theme name in a child theme's metadata section in the list table, in a similar way it is displayed in the theme details modal on the single site Themes screen.
Props dpik, Mista-Flo, seanchayes, poena, johnbillion, jeremyfelt, bradt, jacklenox, helen, Travel_girl, karmatosed, Presskopp, joyously, SergeyBiryukov.
Fixes#30240.
Built from https://develop.svn.wordpress.org/trunk@50978
git-svn-id: http://core.svn.wordpress.org/trunk@50587 1a063a9b-81f0-0310-95a4-ce76da25c4cd
The `px` unit added in [50388] to prevent invalid values when using `calc` functions was inadvertently removed in [50972].
This re-adds the unit to ensure the issue reported in #52564 remains fixed. The same stylelint rule adjustment made in [50388] to `.stylelintrc-css.json` has also been copied over to `stylelintrc.json` file, which is the configuration file used when linting `.scss` files.
Props ocean90.
See #52624, #52564.
Built from https://develop.svn.wordpress.org/trunk@50975
git-svn-id: http://core.svn.wordpress.org/trunk@50584 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This updates several `devDependencies` to their latest versions.
The deprecated `stylelint-config-wordpress` package has also been replaced with the `@wordpress/stylelint-config` package.
This commit also includes several minor adjustments to `.scss` files to decrease the number of coding standards warnings produced when running `lint:scss`.
See #52624.
Built from https://develop.svn.wordpress.org/trunk@50972
git-svn-id: http://core.svn.wordpress.org/trunk@50581 1a063a9b-81f0-0310-95a4-ce76da25c4cd
* Add missing `@since` tags.
* Update some DocBlocks per the documentation standards.
* Rename test files and classes per the naming conventions.
* Fix some code alignment issues reported by WPCS.
Follow-up to [50959], [50960].
See #52991, #53175.
Built from https://develop.svn.wordpress.org/trunk@50967
git-svn-id: http://core.svn.wordpress.org/trunk@50576 1a063a9b-81f0-0310-95a4-ce76da25c4cd
* Update the function DocBlock per the documentation standards.
* Move the unit tests to a more appropriate place.
* Rename and reorder the tests for consistency with `_wp_array_get()` tests.
Follow-up to [50958], [50962], [50964].
See #53175, #52625.
Built from https://develop.svn.wordpress.org/trunk@50965
git-svn-id: http://core.svn.wordpress.org/trunk@50574 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This reverts the changes to `id_base` from [50953] due to backward compatibility concerns, and instead focuses on the `id` and `class` attributes specifically.
With this change, any backslashes in the `id` or `class` attributes for a namespaced widget class are converted to underscores, making it easier to style the output or target the widget with JavaScript.
Follow-up to [50953].
Fixes#44098.
Built from https://develop.svn.wordpress.org/trunk@50961
git-svn-id: http://core.svn.wordpress.org/trunk@50570 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This is the first piece of landing the theme.json processing in WordPress core.
It allows themes to configure the different editor settings, allow cusomizations and define presets in theme.json file.
Props jorgefilipecosta, nosolosw.
See #53175.
Built from https://develop.svn.wordpress.org/trunk@50959
git-svn-id: http://core.svn.wordpress.org/trunk@50568 1a063a9b-81f0-0310-95a4-ce76da25c4cd
It is going to be used on the new widgets editor screen. This patch also introduced a new class WP_Block_Editor_Context that is going to be used with revised block editor filters to let extenders to keep their existing behavior. It should also allow to provide more settings through the context class as new screens get introduced like the navigation editor.
Props azaozz, chrisvanpatten, timothyblynjacobs, youknowriad.
Fixes#52920.
Built from https://develop.svn.wordpress.org/trunk@50956
git-svn-id: http://core.svn.wordpress.org/trunk@50565 1a063a9b-81f0-0310-95a4-ce76da25c4cd
When the XML-RPC endpoint is enabled, always return a HTTP `200 OK` status code in accordance with the XML-RPC specification. Continue to return an HTTP `405 Method Not Allowed` status code when the endpoint is disabled.
Props ariskataoka, johnbillion.
Fixes#52958.
Built from https://develop.svn.wordpress.org/trunk@50954
git-svn-id: http://core.svn.wordpress.org/trunk@50563 1a063a9b-81f0-0310-95a4-ce76da25c4cd
The `id_base` value is used for the widget's `id` and `class` attributes and also for the option name which stores the widget settings (unless the widget specifies a custom `option_name` value).
With this change, any backslashes in the `id_base` for a namespaced widget class are converted to hyphens, making it easier to style the output or target the widget with JavaScript.
This also avoids a `preg_match(): Compilation failed` PHP warning from `next_widget_id_number()` on the Widgets screen, previously caused by unescaped backslashes.
Props Mte90, hermpheus, rogerlos, welcher, SergeyBiryukov.
Fixes#44098.
Built from https://develop.svn.wordpress.org/trunk@50953
git-svn-id: http://core.svn.wordpress.org/trunk@50562 1a063a9b-81f0-0310-95a4-ce76da25c4cd
* Update the filter DocBlock per the documentation standards.
* Use a shorter variable name for consistency with the surrounding code.
* Delete the test file before performing assertions to avoid leftovers in case the test fails.
Follow-up to [50943].
See #52867.
Built from https://develop.svn.wordpress.org/trunk@50951
git-svn-id: http://core.svn.wordpress.org/trunk@50560 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Add a new `wp_{$post_type}_revisions_to_keep` filter that makes it convenient to filter the number of revisions created for a specific post type.
Overrides both the value of WP_POST_REVISIONS and the `wp_revisions_to_keep` filter.
Props dlh.
Fixes#51550.
Built from https://develop.svn.wordpress.org/trunk@50949
git-svn-id: http://core.svn.wordpress.org/trunk@50558 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This restores "That's all, stop editing!" line to its previous format, to avoid breaking external integrations looking for that format specifically.
Follow up to [50915], [50917], [50918].
Props swissspidy, schlessera.
Fixes#37199.
Built from https://develop.svn.wordpress.org/trunk@50946
git-svn-id: http://core.svn.wordpress.org/trunk@50555 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This also includes:
- The removal of the Post Author block.
- Renaming build_query_vars_from_query_block function.
- Update the block supports.
Props gziolo.
See #52991.
-This line, and those below, will be ignored--
M package-lock.json
M package.json
M src/wp-includes/assets/script-loader-packages.php
M src/wp-includes/block-supports/colors.php
AM src/wp-includes/block-supports/elements.php
D src/wp-includes/block-supports/padding.php
AM src/wp-includes/block-supports/spacing.php
M src/wp-includes/block-supports/typography.php
M src/wp-includes/blocks/column/block.json
M src/wp-includes/blocks/index.php
D src/wp-includes/blocks/post-author
D src/wp-includes/blocks/post-author.php
M src/wp-includes/blocks/post-content.php
M src/wp-includes/blocks/post-featured-image.php
M src/wp-includes/blocks/query/block.json
M src/wp-includes/blocks/query-loop/block.json
M src/wp-includes/blocks/query-loop.php
M src/wp-includes/blocks/query-pagination/block.json
M src/wp-includes/blocks/query-pagination-next.php
M src/wp-includes/blocks/query-pagination-numbers.php
M src/wp-includes/blocks/site-tagline/block.json
M src/wp-includes/blocks/site-title/block.json
M src/wp-includes/blocks.php
M src/wp-settings.php
M tests/phpunit/tests/blocks/block.php
M tools/webpack/packages.js
Built from https://develop.svn.wordpress.org/trunk@50945
git-svn-id: http://core.svn.wordpress.org/trunk@50554 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This change introduces the `image_editor_output_format` filter, which fires as sub size images are generated allowing to define a default image MIME type for those items.
Props adamsilverstein, williampatton, spacedmonkey, mikeschroder, hellofromTonya, justinahinon, Boniu91, antpb, SergeyBiryukov.
Fixes#52867.
Built from https://develop.svn.wordpress.org/trunk@50943
git-svn-id: http://core.svn.wordpress.org/trunk@50552 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This change fixes a false positive that would appear during scheduled events, by only running the REST test when a user visits the Site Health page, meaning an active session is available.
The test checking if the REST API is available, includes a parameter for `context=edit` to make sure the block editor can function properly. This means a user session with editor capabilities is required for the test to pass, which is not the case during a scheduled event.
Props szaqal21, TimothyBlynJacobs, hermpheus.
Fixes#52112.
Built from https://develop.svn.wordpress.org/trunk@50939
git-svn-id: http://core.svn.wordpress.org/trunk@50548 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Previously, these properties could be unexpectedly converted to strings in some contexts.
This applies to the following function:
* `sanitize_bookmark_field()`
and the following properties:
* `$bookmark::link_id`
* `$bookmark::link_rating`
Follow-up to [50935].
See #53235.
Built from https://develop.svn.wordpress.org/trunk@50936
git-svn-id: http://core.svn.wordpress.org/trunk@50545 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Previously, these properties could be unexpectedly converted to strings in some contexts.
This applies to the following functions:
* `sanitize_post_field()`
* `sanitize_term_field()`
* `sanitize_user_field()`
and the following properties:
* `WP_Post::ID`
* `WP_Post::post_parent`
* `WP_Post::menu_order`
* `WP_Term::term_id`
* `WP_Term::term_taxonomy_id`
* `WP_Term::parent`
* `WP_Term::count`
* `WP_Term::term_group`
* `WP_User::ID`
Props grantmkin, SergeyBiryukov.
Fixes#53235. See #52995.
Built from https://develop.svn.wordpress.org/trunk@50935
git-svn-id: http://core.svn.wordpress.org/trunk@50544 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This change removes the inline JavaScript attached to the `wp-polyfill` script responsible for loading polyfill libraries included specifically for Internet Explorer support.
Support for the final version of IE supported in WordPress Core (IE11) was removed in [50784] and will on longer be supported when the next version of WordPress is released.
These scripts are still registered and available to be enqueued, but WordPress will no longer load them by default.
For more information, see https://wordpress.org/news/2021/05/dropping-support-for-internet-explorer-11/.
Props youknowriad, gziolo, sergiomdgomes, desrosj.
Fixes#53078.
Built from https://develop.svn.wordpress.org/trunk@50934
git-svn-id: http://core.svn.wordpress.org/trunk@50543 1a063a9b-81f0-0310-95a4-ce76da25c4cd