Commit Graph

21234 Commits

Author SHA1 Message Date
Jb Audras
ac2ddd82f2 Docs: Various improvements in ms-blogs.php function descriptions, as per docblocks standards.
See #56792.


git-svn-id: https://develop.svn.wordpress.org/trunk@55123 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-24 12:55:14 +00:00
Jb Audras
7db8ca56de Twenty Twenty-Two: Remove color reference from pattern names.
This changeset removes color names from pattern names to make them less opinionated, and avoid mismatching when the user changes related colors. It does not update filenames for now, as they are not directly exposed to end users.

Props poena, mukesh27.
Fixes #56720.


git-svn-id: https://develop.svn.wordpress.org/trunk@55122 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-24 08:49:47 +00:00
Jb Audras
0ed98f98f2 Themes: Support additional link related pseudo classes in theme.json.
This changeset adds support for `:link` and `:any-link` in `theme.json`, using the `VALID_ELEMENT_PSEUDO_SELECTORS` array. `:link` can be used to style unvisited links and `:any-link` can be used to style any link containing an `href` attribute.

Props peterwilsoncc, whaze, audrasjb, costdev, mukesh27.
Fixes #57053.


git-svn-id: https://develop.svn.wordpress.org/trunk@55121 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-24 08:09:21 +00:00
Sergey Biryukov
698c003a64 Code Modernization: Rename parameters that use reserved keywords in phpunit/tests/shortcode.php.
While using reserved PHP keywords as parameter name labels is allowed, in the context of function calls using named parameters in PHP 8.0+, this will easily lead to confusion. To avoid that, it is recommended not to use reserved keywords as function parameter names.

This commit:
* Renames the `$return` parameter to `$output` in:
 * `Tests_Shortcode::filter_pre_do_shortcode_tag_attr()`
 * `Tests_Shortcode::filter_do_shortcode_tag_replace()`
 * `Tests_Shortcode::filter_do_shortcode_tag_generate()`
 * `Tests_Shortcode::filter_do_shortcode_tag_attr()`
* Amends the `$return` parameter of the `pre_do_shortcode_tag` filter for consistency.

Follow-up to [52946], [52996], [52997], [52998], [53003], [53014], [53029], [53039], [53116], [53117], [53137], [53174], [53184], [53185], [53192], [53193], [53198], [53203], [53207], [53215], [53216], [53220], [53230], [53232], [53236], [53239], [53240], [53242], [53243], [53245], [53246], [53257], [53269], [53270], [53271], [53272], [53273], [53274], [53275], [53276], [53277], [53281], [53283], [53284], [53285], [53287], [53364], [53365], [54927], [54929], [54930], [54931], [54932], [54933], [54938], [54943], [54944], [54945], [54946], [54947], [54948], [54950], [54951], [54952], [54956], [54959], [54960], [54961], [54962], [54964], [54965], [54969], [54970], [54971], [54972], [54996], [55000], [55011], [55013], [55014], [55015], [55016], [55017], [55020], [55021], [55023], [55027], [55028], [55034], [55036], [55037], [55038], [55039], [55049], [55050], [55060], [55062], [55064], [55065], [55076], [55077], [55078], [55081], [55090], [55100], [55104], [55112], [55115], [55116], [55117].

Props jrf, aristath, poena, justinahinon, SergeyBiryukov.
See #56788.

git-svn-id: https://develop.svn.wordpress.org/trunk@55119 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-23 16:33:57 +00:00
Sergey Biryukov
005cfdbf4e Code Modernization: Rename parameters that use reserved keywords in wp-includes/functions.php.
While using reserved PHP keywords as parameter name labels is allowed, in the context of function calls using named parameters in PHP 8.0+, this will easily lead to confusion. To avoid that, it is recommended not to use reserved keywords as function parameter names.

This commit:
* Renames the `$array` parameter to `$input_array` in `wp_recursive_ksort()`.
* Moves the function next to other array-related functions for consistency.

Follow-up to [53129], [54929].

Props jrf, aristath, poena, justinahinon, SergeyBiryukov.
See #56788.

git-svn-id: https://develop.svn.wordpress.org/trunk@55117 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-23 15:52:18 +00:00
Jb Audras
c6f3ee4fd9 Bundled Themes: Fix Separator block "Dots" style variation on various themes.
This changeset fixes an issue with the "Dots" style of the Separator block on multiple bundled themes. It adds `max-width: 100%` to this style variation on the following themes: Twenty Eleven, Twenty Thirteen, Twenty Fourteen, Twenty Fifteen, and Twenty Sixteen.

Props umesh84, sabernhardt, audrasjb, amin7, esratpopy, multidots1896.
Fixes #56114.


git-svn-id: https://develop.svn.wordpress.org/trunk@55114 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-22 20:05:38 +00:00
Jb Audras
9bbef09035 Posts, Post Types: Increase the input field's width in the Slug metabox.
This changeset adds a `large-text` attribute and removes the `size` attribute of the text input field located in the Slug metabox. It improves its usability, at least for as long as the Slug metabox is available in the Classic Editor.

Props ABTOP, nacin, helen, sabernhardt, abitofmind, tyxla, audrasjb.
Fixes #16346.


git-svn-id: https://develop.svn.wordpress.org/trunk@55113 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-22 11:10:00 +00:00
Sergey Biryukov
9822010bb8 Docs: Further clarify the wp_ajax_save_attachment filter parameters description.
Follow-up to [55106].

See #23148.

git-svn-id: https://develop.svn.wordpress.org/trunk@55111 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-21 15:56:09 +00:00
Jb Audras
02a08585ae Upgrade/Install: Disable spellcheck for password field on Setup screen.
This changeset adds `spellcheck="false"` attribute to Database Password field on the Database Setup screen.

Follow-up to [55094], [55095], [55096].

See #56763.


git-svn-id: https://develop.svn.wordpress.org/trunk@55110 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-21 09:05:14 +00:00
Jb Audras
d8368e7e0a Menus: Hide the "Remove selected item" from Menus screen when no item is selected.
This changeset removes the "Remove selected item" from the classic Navigation Menus screen when no item is selected, and makes it non focusable from assistive technologies.

Plus, this changeset fixes a small unrelated coding standard issue in `nav-menus.css`.

Props kebbet, joedolson, audrasjb.
Fixes #56942.


git-svn-id: https://develop.svn.wordpress.org/trunk@55109 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-20 22:04:12 +00:00
Jb Audras
9705e4e72e Quick/Bulk Edit: Add an action hook on bulk_edit_posts().
This changeset introduces the `bulk_edit_posts` action hook, triggered after processing the post data for bulk edit and before it returns its results. For example, it allows developers to save additional data without having to perform any `.ajax()` call.

Props helgatheviking, helen, Mte90, afercia, mrasharirfan, desrosj, itowhid06, pento, mensmaximus, audrasjb, costdev.
Fixes #28112.


git-svn-id: https://develop.svn.wordpress.org/trunk@55108 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-20 21:41:26 +00:00
Joe Dolson
2ff0e8a3c2 Plugins: Add visible focus on plugin modal close button.
Change the focus and hover state of the plugin modal close button to use `#f0f0f1` with visible outline to be visible against modal overlay.

Props dperonne, viralsampat, jeawhanlee, mukesh27, sabernhardt, joedolson.
Fixes #56604.

git-svn-id: https://develop.svn.wordpress.org/trunk@55107 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-20 21:26:44 +00:00
Jb Audras
c12992dc9a Media: Add an action hook on wp_ajax_save_attachment().
This changeset introduces the `wp_ajax_save_attachment` action hook, triggered after an attachment has been updated and before the JSON response is sent. For example, it allows developers to update any additional attachment fields that have been rendered by extending the `media.view.Attachment.Details` subview.

Props griffinjt, bradyvercher, pputzer, antpb, sc0ttkclark, audrasjb, costdev, hellofromTonya.
Fixes #23148.


git-svn-id: https://develop.svn.wordpress.org/trunk@55106 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-20 14:15:42 +00:00
Sergey Biryukov
675fe390b9 Code Modernization: Use correct property in IXR_Message::tag_open().
The `IXR_Message` class declares a property `_currentTag`, which is never assigned or used. It does assign to `currentTag` instead, which outside of that one assignment is never used either.

Since there are various other underscore-prefixed properties declared on the class, including one named `_currentTagContents` which is used in several places, it appears that the declared property is correct and the assignment is a typo.

This commit resolves a notice on PHP 8.2:
{{{
Deprecated: Creation of dynamic property IXR_Message::$currentTag is deprecated
}}}

Follow-up to [1346].

Props bjorsch, kraftbj, jrf, mukesh27, SergeyBiryukov.
See #56790.

git-svn-id: https://develop.svn.wordpress.org/trunk@55105 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-20 01:34:41 +00:00
Sergey Biryukov
d6afa281b6 Code Modernization: Rename parameters that use reserved keywords in phpunit/tests/rest-api/rest-*-controller.php.
While using reserved PHP keywords as parameter name labels is allowed, in the context of function calls using named parameters in PHP 8.0+, this will easily lead to confusion. To avoid that, it is recommended not to use reserved keywords as function parameter names.

This commit:
* Renames the `$object` parameter to `$response_data` in:
 * `WP_Test_REST_Attachments_Controller::additional_field_get_callback()`
 * `WP_Test_REST_Autosaves_Controller::additional_field_get_callback()`
 * `WP_Test_REST_Categories_Controller::additional_field_get_callback()`
 * `WP_Test_REST_Comments_Controller::additional_field_get_callback()`
 * `WP_Test_REST_Post_Statuses_Controller::additional_field_get_callback()`
 * `WP_Test_REST_Post_Types_Controller::additional_field_get_callback()`
 * `WP_Test_REST_Posts_Controller::additional_field_get_callback()`
 * `WP_Test_REST_Revisions_Controller::additional_field_get_callback()`
 * `WP_Test_REST_Tags_Controller::additional_field_get_callback()`
 * `WP_Test_REST_Users_Controller::additional_field_get_callback()`
* Amends the `$data` and `$prepared` parameters for consistency in:
 * `WP_REST_Controller::add_additional_fields_to_object()`
 * `WP_REST_Controller::filter_response_by_context()`
 * `rest_filter_response_by_context()`

Follow-up to [52946], [52996], [52997], [52998], [53003], [53014], [53029], [53039], [53116], [53117], [53137], [53174], [53184], [53185], [53192], [53193], [53198], [53203], [53207], [53215], [53216], [53220], [53230], [53232], [53236], [53239], [53240], [53242], [53243], [53245], [53246], [53257], [53269], [53270], [53271], [53272], [53273], [53274], [53275], [53276], [53277], [53281], [53283], [53284], [53285], [53287], [53364], [53365], [54927], [54929], [54930], [54931], [54932], [54933], [54938], [54943], [54944], [54945], [54946], [54947], [54948], [54950], [54951], [54952], [54956], [54959], [54960], [54961], [54962], [54964], [54965], [54969], [54970], [54971], [54972], [54996], [55000], [55011], [55013], [55014], [55015], [55016], [55017], [55020], [55021], [55023], [55027], [55028], [55034], [55036], [55037], [55038], [55039], [55049], [55050], [55060], [55062], [55064], [55065], [55076], [55077], [55078], [55081], [55090], [55100].

Props jrf, aristath, poena, justinahinon, SergeyBiryukov.
See #56788.

git-svn-id: https://develop.svn.wordpress.org/trunk@55104 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-20 00:19:09 +00:00
Jb Audras
b0f853f580 Permalinks: Remove floating on Permalinks settings screen.
This changeset replaces floating elements with `flex` CSS positioning, while the markup stays the same to keep the elements' semantic value.

Follow-up to [53706].

Props sabernhardt, kebbet, audrasjb.
Fixes #56673.
See #55498.


git-svn-id: https://develop.svn.wordpress.org/trunk@55103 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-19 22:55:10 +00:00
Jb Audras
a9bd7719db Twenty Twenty-One: Fix obsolete navigation block styles for better Global Styles support.
This changeset removes some CSS custom properties that targets navigation menu items to avoid preventing the block from inheriting padding values set by the Global Styles system.

Props Joen, desrosj, poena, audrasjb, hellofromtonya, SergeyBiryukov.
Fixes #53220.


git-svn-id: https://develop.svn.wordpress.org/trunk@55101 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-19 17:39:10 +00:00
Pascal Birchler
157a23382d I18N: Allow installing new translations when changing the user locale on the profile page.
Up until now, new translations could only be installed via Settings -> General.
When editing the user profile, one could only select locales that were already installed.

This change allows also installing new translations if the editing user has the necessary capabilities.

Props barryceelen, johnbillion, ocean90, swissspidy.
Fixes #38664.

git-svn-id: https://develop.svn.wordpress.org/trunk@55099 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-19 14:11:08 +00:00
Riad Benguella
9599b39a5a Editor: Updated the bundled block pattern categories.
This adds descriptions to the existing pattern categories.
It also updates backports the new pattern categories: 
banner, call to action, posts, team, testimonials, services,
portfolio and contact.

Fixes #57479.


git-svn-id: https://develop.svn.wordpress.org/trunk@55098 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-19 12:19:51 +00:00
Riad Benguella
48342a279d Editor: Allow block pattern categories to have descriptions.
Updates the corresponding REST API endpoint and unit test.

Fixes #57478.


git-svn-id: https://develop.svn.wordpress.org/trunk@55097 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-19 12:11:57 +00:00
Jb Audras
134c05d698 Application Passwords: Disable spellcheck for password field.
This changeset adds `spellcheck="false"` attribute to application password field.

Follow-up to [55094], [55095].

Props Spaceshipone.
Fixes #56763.


git-svn-id: https://develop.svn.wordpress.org/trunk@55096 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-19 11:46:47 +00:00
Jb Audras
adc62118f7 Twenty Twenty-One: Disable spellcheck for post password field.
This changeset adds `spellcheck="false"` attribute to various password fields.

Follow-up to [55094].

Props dziudek, audrasjb, gainesm, fosuahmed.
See #56763.


git-svn-id: https://develop.svn.wordpress.org/trunk@55095 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-19 09:10:19 +00:00
Jb Audras
2b831ffa1f Login and Registration: Disable spellcheck for password fields.
This changeset adds `spellcheck="false"` attribute to various password fields.

The spellcheck global attribute defines whether the element may be checked for spelling errors. The `false` value indicates that the element should not be checked for spelling errors, which is relevant for a password field.

Furthermore, and as per MDN specs, using spellchecking can have consequences for users' security and privacy. The specification does not regulate how spellchecking is done and the content of the element may be sent to a third party for spellchecking results. Thus, it is recommended to set `spellcheck` attribute to `false` for elements that can contain sensitive information. Which is the case for password fields.

Props dziudek, audrasjb, gainesm, fosuahmed.
Fixes #56763.


git-svn-id: https://develop.svn.wordpress.org/trunk@55094 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-19 08:51:41 +00:00
Felix Arntz
65caf62944 Media: Allow for customization of lazy-loading featured images.
When lazy-loading images was introduced, in [52065] the check for `wp_lazy_loading_enabled()` was omitted by accident in the logic to set the attribute with its default value on `img` tags from `get_the_post_thumbnail()`. Without this check, it is impossible for third-party developers to modify the behavior for featured images.

This changeset fixes the problem by introducing the check.

Props flixos90, joemcgill, mukesh27.
Fixes #57490.


git-svn-id: https://develop.svn.wordpress.org/trunk@55093 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-19 07:32:28 +00:00
Tonya Mork
84bb54d618 Themes: Revert caching from r55086.
Calls to `wp-admin/load-styles.php` do not include the loading of `wp_cache_*()` functions. With [55086], this caused a fatal error:

{{{
Fatal error: Uncaught Error: Call to undefined function wp_cache_get() in /wp-includes/global-styles-and-settings.php on line 285
}}}

In some production and local environments running `trunk`, the admin area looked broken as the styling was not loaded as there were no HTTP requests.

This commit reverts the caching from [55086] to restore sites running `trunk` until a solution is found.

Follow-up to [55086].

Props Otto42, dmsnell, costdev.
See #56975.

git-svn-id: https://develop.svn.wordpress.org/trunk@55092 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-18 21:58:00 +00:00
Joe Dolson
e57e0e80b9 Media: Prevent hidden overflow on uploaded image names.
Allow the image upload notification to expand height and display the full image name when uploaded. Primarily effects mobile devices, where the available space for image names is narrow.

Props sumitsingh.
Fixes #54812.

git-svn-id: https://develop.svn.wordpress.org/trunk@55091 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-18 18:49:19 +00:00
Jb Audras
8d56405c59 Twenty Twenty-One: Revert [55088].
[55088] introduced some issues with the "Test Default Themes & Create ZIPs" workflow on GitHub Actions. This changeset reverts it to leave time to figure out what failed and why.

See #53220.


git-svn-id: https://develop.svn.wordpress.org/trunk@55089 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-18 14:50:29 +00:00
Jb Audras
27cf88122d Twenty Twenty-One: Fix obsolete navigation block styles for better Global Styles support.
This changeset removes CSS custom properties that targets navigation menu items to avoid preventing the block from inheriting padding values set by the Global Styles system.

Props Joen, desrosj, poena.
Fixes #53220.


git-svn-id: https://develop.svn.wordpress.org/trunk@55088 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-18 13:31:16 +00:00
Tonya Mork
6a9e92dc76 Themes: Introduce wp_theme_has_theme_json() for public consumption.
Adds `wp_theme_has_theme_json()` for public consumption, to replace the private internal Core-only `WP_Theme_JSON_Resolver::theme_has_support()` method. This new global function checks if a theme or its parent has a `theme.json` file.

For performance, results are cached as an integer `1` or `0` in the `'theme_json'` group with `'wp_theme_has_theme_json'` key. This is a non-persistent cache. Why? To make the derived data from `theme.json` is always fresh from the potential modifications done via hooks that can use dynamic data (modify the stylesheet depending on some option, settings depending on user permissions, etc.).

Also adds a new public function `wp_clean_theme_json_cache()` to clear the cache on `'switch_theme'` and `start_previewing_theme'`.

References:
* [https://github.com/WordPress/gutenberg/pull/45168 Gutenberg PR 45168] Add `wp_theme_has_theme_json` as a public API to know whether a theme has a `theme.json`.
* [https://github.com/WordPress/gutenberg/pull/45380 Gutenberg PR 45380] Deprecate `WP_Theme_JSON_Resolver:theme_has_support()`.
* [https://github.com/WordPress/gutenberg/pull/46150 Gutenberg PR 46150] Make `theme.json` object caches non-persistent.
* [https://github.com/WordPress/gutenberg/pull/45979 Gutenberg PR 45979] Don't check if constants set by `wp_initial_constants()` are defined.
* [https://github.com/WordPress/gutenberg/pull/45950 Gutenberg PR 45950] Cleaner logic in `wp_theme_has_theme_json`.

Follow-up to [54493], [53282], [52744], [52049], [50959].

Props oandregal, afragen, alexstine, aristath, azaozz, costdev, flixos90, hellofromTonya, mamaduka, mcsf, ocean90, spacedmonkey.
Fixes #56975.

git-svn-id: https://develop.svn.wordpress.org/trunk@55086 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-18 11:38:16 +00:00
Jonny Harris
410889469f Posts, Post Types: Use persistent caching in get_adjacent_post function.
The function `get_adjacent_post` cached the results of database query in the cache group `counts`. This is a none persistent group and meant cache would not persist on the next request. Change cache to save to the `posts` cache group. Cache invalidation is done by using get last changed value of the `posts` and `terms` group as a salt for the cache key. 

Props spacedmonkey, peterwilsoncc, johnbillion, boonebgorges, mukesh27, dd32.
Fixes #41131.

git-svn-id: https://develop.svn.wordpress.org/trunk@55085 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-18 11:18:36 +00:00
Riad Benguella
15b5159d49 Editor: Add inert attribute polyfill.
The new Gutenberg packages are using the inert attribute
to disable some parts of the HTML tree in an accessible way.

Props ntsekouras.
Fixes #57492.


git-svn-id: https://develop.svn.wordpress.org/trunk@55084 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-18 11:14:33 +00:00
Jonny Harris
ec6b2f2045 Taxonomy: Remove placeholder from WP_Term_Query cache key.
Remove escape placeholder from query cache key, as placeholders are on a based on a unique id on every request. This meant that it is impossible for a cache to be reused, making queries that use escape placeholders such as searches, meta queries or using the `description__like` / `name__like` parameters were unable to be cached.  
 
Follow on from [54634]. 

Props spacedmonkey, peterwilsoncc.
Fixes #57298.

git-svn-id: https://develop.svn.wordpress.org/trunk@55083 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-18 09:56:55 +00:00
Jb Audras
7f788f38c8 Administration: Use a consistent capitalization in Privacy Policy related strings.
This changeset fixes a few use case:
- When referring to the Privacy Policy page, "Privacy Policy" should use capitalization on "Privacy Policy", but "page" should remain lowercase;
- When referring to the fact that a website needs, let's say "a relevant privacy policy", "privacy policy" should stay lowercase.

This changeset also updates other small capitalization issues.

Props aravindajith, audrasjb, sarathar, nithi22, costdev.
Fixes #57226.


git-svn-id: https://develop.svn.wordpress.org/trunk@55082 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-17 21:32:42 +00:00
Jb Audras
d9ec8536f7 Docs: Remove unused post_modified and post_modified_gmt params from wp_insert_post() docblock.
Props dshanske, mehulkaklotar.
Fixes #57473.
See #56792.


git-svn-id: https://develop.svn.wordpress.org/trunk@55080 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-16 20:37:19 +00:00
Felix Arntz
659694d2c6 Editor: Update packages to unblock lazy-loading issues.
Fixing the issue that featured images are always lazy-loaded in block themes required an upstream Gutenberg change https://github.com/WordPress/gutenberg/pull/45534. This changeset updates packages in order to unblock the remainder of the fix in `trunk`.

Props mamaduka.
See #56930.


git-svn-id: https://develop.svn.wordpress.org/trunk@55079 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-16 19:57:29 +00:00
Jb Audras
78f6ac9c29 Docs: Various docblock fixes in Multisite WordPress API related functions.
Follow-up to [55074].

See #56792.


git-svn-id: https://develop.svn.wordpress.org/trunk@55075 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-15 17:50:13 +00:00
Jb Audras
253b2db06b Docs: Add a missing quote to wp_is_large_network() Docblock params.
Props lanacodes.
Fixes #57468.
See #56792.


git-svn-id: https://develop.svn.wordpress.org/trunk@55074 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-15 17:16:02 +00:00
Jb Audras
682c579436 Docs: Typo correction in POP3 class send_cmd() inline docs.
Props nitman43, manojkpatil, kebbet.
Fixes #57449.
See #56792.


git-svn-id: https://develop.svn.wordpress.org/trunk@55073 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-15 15:22:04 +00:00
Jb Audras
61074b97e7 Docs: Use third-person singular verbs for Script Loader related function descriptions, as per docblocks standards.
See #56792.


git-svn-id: https://develop.svn.wordpress.org/trunk@55072 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-15 14:55:19 +00:00
Jb Audras
124a4a9773 Docs: Improve wp_style_add_data() function description.
This changeset removes an extra apostrophe in `wp_style_add_data()` DocBlock.

Props lanacodes, ashrafulsarkar, SergeyBiryukov.
Fixes #57466.
See #56792.


git-svn-id: https://develop.svn.wordpress.org/trunk@55071 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-15 14:48:03 +00:00
John Blackbourn
b223ec07ed HTTP API: Correct the name of a filter referenced in the docs for wp_redirect() and wp_safe_redirect().
Props pbiron, audrasjb, SergeyBiryukov 

Fixes #57464


git-svn-id: https://develop.svn.wordpress.org/trunk@55069 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-15 00:59:52 +00:00
Jb Audras
f434da3dec Embeds: Update Mixcloud oEmbed URL to the new domain.
Replaces `https://www.mixcloud.com/oembed` with `https://app.mixcloud.com/oembed`.
Mixcloud plan to redirect old URLs to the new endpoint.

Props matclayton, peterwilsoncc, audrasjb, ayeshrajans.
Fixes #57376.


git-svn-id: https://develop.svn.wordpress.org/trunk@55068 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-14 10:47:40 +00:00
Jb Audras
cb87135103 Themes: Add opt-in Appearance Tools support for Classic Themes.
This changeset merges the following changes from Gutenberg repository: 

- Allow themes without `theme.json` to opt-in to appearance tools via `add_theme_support( 'appearance-tools' );`
- Update `wpThemeJsonResolver` unit tests accordingly

See the following pull request for more info: https://github.com/WordPress/gutenberg/pull/43337

Props ironprogrammer, audrasjb.
Fixes #57460.


git-svn-id: https://develop.svn.wordpress.org/trunk@55067 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-14 09:34:55 +00:00
John Blackbourn
1c9f84f963 HTTP API: Correct the documentation for the https_ssl_verify and https_local_ssl_verify filters.
The value for both these filters can also contain a string path to a CA file used to authenticate the identity of the remote server.

Props chesio, mcaskill

Fixes #54803


git-svn-id: https://develop.svn.wordpress.org/trunk@55063 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-13 14:20:46 +00:00
Jb Audras
9d48ae36c3 Bundled Themes: Add Mastodon domains for menu item icons.
This changeset adds the top 10 Mastodon domains by popularity to Twenty Twenty and Twenty Twenty-One Social icon feature.

Note: other Mastodon domains can be added to the array of domain mapping using `twentytwenty_social_icons_map` and `twenty_twenty_one_social_icons_map` filters.

Props triumvirate, sabernhardt, audrasjb, peterwilsoncc, rryyaanndd, ianbelanger.
Fixes #57293, #49099.


git-svn-id: https://develop.svn.wordpress.org/trunk@55061 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-13 13:17:45 +00:00
Andrew Ozz
515d3fe69f Menus: Compare $menu_item->ID and $menu_item->menu_item_parent as strings and avoid moidifying them. Plugins may change the ID to a string.
Props Chouby, peterwilsoncc, Chrystl, manooweb, azaozz.
Fixes #57169.

git-svn-id: https://develop.svn.wordpress.org/trunk@55059 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-12 23:23:01 +00:00
Sergey Biryukov
9dcb8f97c9 Docs: Correct the type of the $user_id parameter in wp_set_password action.
Follow-up to [6600], [55056].

See #57436.

git-svn-id: https://develop.svn.wordpress.org/trunk@55057 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-12 13:12:44 +00:00
Jb Audras
344c4dce68 Users: Add an action hook on wp_set_password().
This changeset introduces the `wp_set_password` action hook, triggered after a password is set for a given user. As several plugins are calling `wp_set_password()` directly, adding an action to the end of the function will help plugin authors to catch all instances of password setting.

Props tanner-m, audrasjb.
Fixes #57436.


git-svn-id: https://develop.svn.wordpress.org/trunk@55056 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-12 09:03:29 +00:00
Sergey Biryukov
5836a43808 Upgrade/Install: Revert a temporary conditional for testing the Rollbacks feature project.
The [https://make.wordpress.org/core/2021/02/19/feature-plugin-rollback-update-failure/ Rollback Update Failure feature project] has been split into two plugins for testing:
 * [https://github.com/afragen/faster-updates Faster Updates] speeds up plugin or theme updates by moving files rather than copying them, thus decreasing the memory usage and reducing the chance of timeouts or running out of disk space during updates.
 * [https://wordpress.org/plugins/rollback-update-failure/ Rollback Update Failure] creates a temporary backup of plugins and themes before updating. This aims to make the update process more reliable and ensure that if a plugin or theme update fails, the previous version can be safely restored.

The current priority of the feature project is to test the new `move_dir()` function, which offers better performance than `copy_dir()`. Instead of copying a directory in a recursive manner file by file from one location to another, `move_dir()` uses the `rename()` PHP function to speed up the process, which is instrumental in updating large plugins without a delay. If the renaming failed, it falls back to the `copy_dir()` WP function.

The `move_dir()` function is self-contained in the Faster Updates plugin and does not require any special hooks in core, so the conditional previously added to `WP_Upgrader::install_package()` to facilitate testing is no longer needed and can be removed.

Follow-up to [53578], [54484], [54643].

Props afragen, costdev, peterwilsoncc.
See #56057, #57375, #57386.

git-svn-id: https://develop.svn.wordpress.org/trunk@55055 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-12 00:17:45 +00:00
Jb Audras
55c34595d0 Date/Time: Prevent errors in current_time() when using timestamp and no value for gmt_offset.
This changeset moves typecasting to affect the `get_option` value, which ensures that when math is done it does not generate any error. In PHP 7.4 and earlier the previous implementation was dismissed as a warning, but in PHP 8+ it would have throw a fatal error.

Follow-up to [45856].

Props Nick_theGeek, SergeyBiryukov, johnbillion.
Fixes #57035.


git-svn-id: https://develop.svn.wordpress.org/trunk@55054 602fd350-edb4-49c9-b593-d223f7449a82
2023-01-11 23:18:12 +00:00