49233 Commits

Author SHA1 Message Date
John Blackbourn
e1e8ba1760 WordPress 6.5.2.
git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57978 602fd350-edb4-49c9-b593-d223f7449a82
2024-04-09 21:03:42 +00:00
John Blackbourn
d3256149ae WordPress 6.5.1.
git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57959 602fd350-edb4-49c9-b593-d223f7449a82
2024-04-09 14:07:20 +00:00
John Blackbourn
292b2497d7 Editor: Update npm packages for the 6.5 branch.
Updates the editor npm packages to the latest patch versions for 6.5.1.


git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57950 602fd350-edb4-49c9-b593-d223f7449a82
2024-04-09 11:01:52 +00:00
Joe McGill
38b3f6f25c Themes: Avoid errors in some environments from _get_block_templates_paths.
This adds an is_dir() check in _get_block_templates_paths before trying to run a RecursiveDirectoryIterator to avoid errors being reported in New Relic even thought the errors should be handled by a try/catch block.

Follow-up to [57215].

Reviewed by jorbin.
Merges [57928] to the to the 6.5 branch.

Props iCaleb, sean212, mukesh27, joemcgill.
Fixes #60915.


git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57947 602fd350-edb4-49c9-b593-d223f7449a82
2024-04-09 01:23:21 +00:00
Sergey Biryukov
b2d70cc5ba Tests: Use an image on WordPress.org CDN in external HTTP tests.
Due to some changes on the WP.com side to compress the requested images on the fly, the exact image size in the response could be different between platforms.

This commit aims to make the affected tests more reliable.

Follow-up to [139/tests], [31258], [34568], [47142], [57903], [57904], [57924].

Reviewed by jorbin.
Merges [57931] to the 6.5 branch.

Props peterwilsoncc, jorbin.
See #60865.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57935 602fd350-edb4-49c9-b593-d223f7449a82
2024-04-06 14:19:35 +00:00
Jonathan Desrosiers
7a7180a0f5 Build/Test Tools: Migrate to Docker Compose V2.
Compose V2, which was first released in 2020, is included with all currently supported versions of Docker Desktop. Compose V1 stopped receiving updates in July 2023.

The biggest difference is that the command to interact with Compose changed from `docker-compose` to `docker compose`.

GitHub has now started removing V1 from Ubuntu & Windows images, which caused all Docker-based GitHub Actions workflows to fail.

This change migrates to the new `docker compose` command to address these failures.

Merges [57918] to the 6.5 branch.

Props swissspidy, thelovekesh.
See #60901.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57927 602fd350-edb4-49c9-b593-d223f7449a82
2024-04-04 18:10:44 +00:00
Jb Audras
02c16c49a6 Post WordPress 6.5 version bump.
The 6.5 branch is now 6.5.1-alpha.





git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57914 602fd350-edb4-49c9-b593-d223f7449a82
2024-04-02 18:55:09 +00:00
Jb Audras
8fcdef779f WordPress 6.5.
git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57912 602fd350-edb4-49c9-b593-d223f7449a82
2024-04-02 18:08:14 +00:00
Jb Audras
444e8bca77 Tests: Update expectations in wp_remote_head() and wp_remote_get() tests.
It appears that something has changed on the WP.com side to compress the requested images on the fly, which interfered with the previous expectations in these tests.

Follow-up to [139/tests], [31258], [47142].

Reviewed by audrasjb.
Merges [57903] and [57904] to the 6.5 branch.
Props dextorlobo, swissspidy, davidbaumwald, SergeyBiryukov.
Fixes #60865.




git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57908 602fd350-edb4-49c9-b593-d223f7449a82
2024-04-01 17:16:55 +00:00
Jb Audras
e79624f1d0 Docs: Improve the docblock for _wp_filter_font_directory().
Removes the recommended use section as this is a private use only function.

Reviewed by davidbaumwald.
Merges [57902] to the 6.5 branch.
Props peterwilsoncc, swissspidy, azaozz.
Fixes #60652.




git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57907 602fd350-edb4-49c9-b593-d223f7449a82
2024-04-01 16:53:25 +00:00
David Baumwald
f41c8dd1b8 Upgrade/Install: Update the $_old_files array for 6.5.
Reviewed by audrasjb.
Merges [57905] to the 6.5 branch.

Props audrasjb, huzaifaalmesbah, swissspidy.
See #60648.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57906 602fd350-edb4-49c9-b593-d223f7449a82
2024-04-01 16:49:11 +00:00
Jb Audras
b99ef66268 Post WordPress 6.5 RC4 version bump.
git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57894 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-28 16:29:35 +00:00
Jb Audras
abda5e2305 WordPress 6.5 RC4.
git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57893 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-28 16:11:27 +00:00
Pascal Birchler
900c90b63a Editor: Merge Editor bug fixes ahead of 6.5 RC4.
This merges several high priority bug fixes for the editor ahead of WordPress 6.5:
- https://github.com/WordPress/gutenberg/pull/60180
- https://github.com/WordPress/gutenberg/pull/60093
- https://github.com/WordPress/gutenberg/pull/60071
- https://github.com/WordPress/gutenberg/pull/60130
- https://github.com/WordPress/gutenberg/pull/59959
- https://github.com/WordPress/gutenberg/pull/60167

Reviewed by jorbin, swissspidy.
Merges [57888] to the 6.5 branch.

Props youknowriad, annezazu, mcsf, jsnajdr, mmaattiiaass, get_dave, scruffian, mikachan, grantmkin, andraganescu, scruffian, antosguillamot, fabiankaegy, huzaifaalmesbah, krupajnanda, colorful-tones, liviopv, mamaduka, kim88, poena, peterwilsoncc, wildworks, swissspidy, desrosj, jorbin.
Fixes #60315.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57891 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-28 08:28:45 +00:00
Pascal Birchler
d960162aa8 Bundled Themes: Bump default theme versions for release with 6.5.
This updates the version of each default theme to the following versions:
- Twenty Ten: `4.1`
- Twenty Eleven: `4.6`
- Twenty Twelve: `4.2`
- Twenty Thirteen: `4.1`
- Twenty Fourteen: `3.9`
- Twenty Fifteen: `3.7`
- Twenty Sixteen: `3.2`
- Twenty Seventeen: `3.6`
- Twenty Nineteen: `2.8`
- Twenty Twenty: `2.6`
- Twenty Twenty-One: `2.2`
- Twenty Twenty-Two: `1.7`
- Twenty Twenty-Three: `1.4`
- Twenty Twenty-Four: `1.1`

These versions will released in coordination with WordPress 6.5.

Reviewed by swissspidy.
Merges [57886] to the 6.5 branch.

Props sabernhardt, desrosj, kushang78, mukesh27, huzaifaalmesbah, shailu25, poena.
Fixes #59816.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57890 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-28 08:27:28 +00:00
Pascal Birchler
cc6a03a101 Editor: disable shadow.defaultPresets for classic themes.
With this change default shadow presets are never shown for classic themes, and classic themes have no options for adding custom ones.
This essentially reverts [57717] and [57827] / [57828], which had unintended consequences.

Reviewed by audrasjb.
Merges [57885] to the 6.5 branch.

Props ajlende, oandregal, madhudollu, swissspidy, get_dave, andrewserong, desrosj.
Fixes #60815.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57889 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-28 08:24:19 +00:00
Joe Dolson
3a99c2a6a3 Media: Fix CSS issue preventing inserting images on smaller viewports.
Addresses a regression introduced in [57605] where the “Select” button in the media modal was not clickable anymore due to an overlaid element.

Props ramonopoly, swissspidy, freewebmentor.
Reviewed by joedolson.
Merges [57881] to the 6.5 branch.
Fixes #33049.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57884 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-27 15:34:22 +00:00
Pascal Birchler
f779e19e4c Editor: Relocate font files uploads to the uploads directory.
Relocate the upload of font files uploaded via the Font Library feature to the `wp-content/uploads/fonts` (or multisite equivalent) directory.

This accounts for immutable file systems in which directories are unable to be created within `wp-content` and deploy processes which require special consideration of the `uploads` directory to ensure it remains persistent between deploys.

Reviewed by davidbaumwald.
Merges [57878] to the 6.5 branch.

Props azaozz, burnuser, cbirdsong, christopherplus, costdev, davidbaumwald, desrosj, elrae, euthelup, get_dave, grantmkin, hellofromtonya, janthiel, jazzs3quence, johnbillion, jorbin, justlevine, kraftner, matveb, mcsf, mmaattiiaass, nico23, peterwilsoncc, priethor, rmccue, samuelsidler, swissspidy, youknowriad.
Fixes #60845.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57880 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-26 09:25:20 +00:00
Pascal Birchler
821eda2c9c Editor: Prevent font folder naive filtering causing infinite loops.
This modifies the font directory API to more closely reflect the upload directory API to help account for naive filtering when uploading fonts.

This moves the protection of infinite loops to the new function `_wp_filter_font_directory()` to allow developers extending and maintaining the font library to apply the filter without the need for a closure.

These changes also ensure both the `upload_dir` and `font_dir` filter are applied consistently when both creating and deleting fonts faces. Prior to this commit the `upload_dir` filter was only fired when creating fonts faces via the REST API.

Applying the font directory filter to the `upload_dir` filter is now done by adding the `_wp_filter_font_directory` function rather than `wp_get_font_dir()`. Developers who have previously modified the font upload directory using the `font_dir` filter will NOT need to upload their code.

Extenders wishing to upload files to the font directory can do so via the code:

{{{#!php
<?php
add_filter( 'upload_dir', '_wp_filter_font_directory' );
// Your code to upload or sideload a font file.
remove_filter( 'upload_dir', '_wp_filter_font_directory' );
}}}

Introduces:

* `wp_font_dir()`: Attempt to create and retrieve the font upload directory. The equivalent to `wp_upload_dir()`.
* `_wp_filter_font_directory()`: To run on the `upload_dir` filter, this sets the default destination of the fonts directory and fires the `font_dir` filter. 

`wp_get_font_dir()` has been modified to be a lightweight getter for the font directory. It returns the location without attempting to create it. The equivalent to `wp_get_upload_dir()`.

Follow up to [57740].

Reviewed by swissspidy.
Merges [57868] to the 6.5 branch.

Props peterwilsoncc, mukesh27, mikachan, costdev, mmaattiiaass, swissspidy, youknowriad, dd32, grantmkin.
Fixes #60652.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57879 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-26 09:22:48 +00:00
Pascal Birchler
0bde51f7ee Editor: Update the Google Fonts font collection URL to the latest version for 6.5.
Reviewed by peterwilsoncc.
Merges [57871] to the 6.5 branch.

Props mmaattiiaass.
Fixes #60819.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57875 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-25 11:06:37 +00:00
Pascal Birchler
576572dab2 Help/About: Update the About page for 6.5.
Updates the font size for `<code>` tags and updates several translatable strings.

Reviewed by davidbaumwald.
Merges [57870] to the to the 6.5 branch.

Props sabernhardt, laurlittle, SergeyBiryukov.
See #60303.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57872 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-23 13:08:55 +00:00
Pascal Birchler
87774d920a Editor: Check if mb_strtolower exists before using it in the font library.
Prevents an error when uploading fonts on certain systems, because the `mbstring` extension can be missing and thus the function may not be available.

Reviewed by jorbin.
Merges [57865] to the to the 6.5 branch.

Props mujuonly, swissspidy, peterwilsoncc.
Fixes #60823.
See #55603.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57869 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-23 09:15:28 +00:00
Jb Audras
72469660df I18n: Ensure "Patterns" menu item is translatable.
This changeset updates a translation string to ensure the "Patterns" menu item introduced in [57543] is translatable.
This quickfix simply removes the erroneous `context` parameter so no new string is introduced during WP 6.5 string freeze period. A follow-up changeset will be needed to replace the current `__()` function with `_x()` and put back the `context` parameter.

Follow-up to [57543].

Reviewed by swissspidy.
Merges [57864] to the to the 6.5 branch.

Props jdy68, audrasjb, kebbet, swissspidy.
Fixes #60825.




git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57866 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-22 15:24:43 +00:00
Jb Audras
359570422b Post WordPress 6.5 RC3 version bump.
git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57856 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-19 16:16:08 +00:00
Jb Audras
a108e43806 WordPress 6.5 RC3.
git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57855 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-19 16:06:14 +00:00
Greg Ziółkowski
69bcc049d0 Editor: Update Packages with the latest bug fixes for 6.5 RC 3
It includes all the backports from this Gutenberg PR https://github.com/WordPress/gutenberg/pull/59949/

Props get_dave, youknowriad, gziolo.
Reviewed by youknowriad.
Merges [57851] to the 6.5 branch.
See #60315.



git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57852 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-19 09:23:20 +00:00
Joe Dolson
ba1b4c755a Media: Fall back to available icons if SVG media icons not found.
Follow up to [57687]. If no icons of the preferred type are available, then the icon array should return the collection of valid icons found, rather than an empty array.

Props dglingren, sabernhardt, swissspidy, sabernhardt, antpb, joedolson.
Reviewed by swissspidy.
Merges [57845] to the 6.5 branch.
Fixes #60740.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57846 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-15 20:56:20 +00:00
Pascal Birchler
c28cdd6bbf Script Loader: Add new script_module_loader_src filter for the script module src.
Ensures parity with the `script_loader_src` filter for regular scripts, allowing the URL to be filtered, for example to load them from a CDN or alter query parameters.

Reviewed by swissspidy.
Merges [57840] to the to the 6.5 branch.

Props dd32, peterwilsoncc, westonruter.
Fixes #60742.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57844 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-15 14:59:10 +00:00
Pascal Birchler
0d75b981df Interactivity API: Do not print state if it’s an empty array.
This prunes stores and configurations that are empty arrays, as stores are expected to be JSON objects.
By not printing empty configurations, less redundant data is serialized into the HTML.

Reviewed by gziolo.
Merges [57841] to the to the 6.5 branch.

Props jonsurrell, luisherranz, darerodz, gziolo, swissspidy.
Fixes #60761.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57843 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-15 14:57:47 +00:00
Pascal Birchler
dabf8e8c76 I18N: Improve translation file cache group & expiration.
Adds an explicit 1 hour expiration for the translation file cache introduced in [57287] / #58919.
This prevents stale caches when a site does not use the regular way of installing language packs, for example when an atomic filesystem is involved.
Also configures the translation_files group as a global cache group on multisite.

Reviewed by swissspidy.
Merges [57831] to the to the 6.5 branch.

Props dd32.
Fixes #60764.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57838 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-15 11:17:54 +00:00
Pascal Birchler
38250b923d Interactivity API: Prevent warning when using a bind directive with a short attribute name.
Adds new tests and improves existing ones by using `assertSame` to do type comparison as well.

Reviewed by gziolo.
Merges [57835] to the to the 6.5 branch.

Props jonsurrell, cbravobernal, swissspidy, gziolo.
Fixes #60758.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57837 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-15 11:15:56 +00:00
Pascal Birchler
43c6e548a4 Interactivity API: Do not propagate context from void tags to its siblings.
Resolves an issue where context on a void tag element such as `<img>` was incorrectly passed to following elements.
Adds tests.

Reviewed by gziolo.
Merges [57832] to the to the 6.5 branch.

Props santosguillamot, luisherranz, cbravobernal, dmsnell, gziolo, swissspidy.
Fixes #60768.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57834 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-14 15:10:55 +00:00
Pascal Birchler
833d14c847 Interactivity API: Increase hook priority for processing directives.
Use a priority of 100 to ensure that other filters can add additional directives before the processing starts.
This way, directives will be processed even if the $parsed_block variable is edited by a filter.

Reviewed by gziolo.
Merges [57826] to the to the 6.5 branch.

Props cbravobernal, swissspidy, flixos90, joemcgill, gziolo.
Fixes #60743.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57830 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-14 08:57:48 +00:00
Pascal Birchler
893bf88e25 Editor: disable shadow.defaultPresets in default theme.json.
This is a follow-up to [57717] to ensure that classic themes without a `theme.json` file or without `appearanceTools: true` in `theme.json` do not have shadow controls by default.

Reviewed by youknowriad.
Merges [57827] to the to the 6.5 branch.

Props wildworks, vcanales, madhudollu, swissspidy, youknowriad.
Fixes #60633

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57828 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-13 11:22:26 +00:00
Pascal Birchler
53c4ed4aed Interactivity API: Do not process directives when there aren't any.
Short-circuits directive processing when the markup does not actually contain any `data-wp-*` attributes.
This reduces function calls and memory usage for the best case scenario due to not involving `WP_HTML_Tag_Processor`.

Reviewed by gziolo, swissspidy.
Merges [57824] to the to the 6.5 branch.

Props joemcgill, swissspidy, gziolo, cbravobernal, flixos90.
Fixes #60749.


git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57825 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-13 10:42:32 +00:00
Pascal Birchler
e5f428ed82 HTML API: Trigger active format reconstruction when reaching text nodes.
When encountering text nodes in an HTML document, the HTML parser needs
to run the active format reconstruction algorithm, even if it doesn't
stop to visit those text nodes. This is because the formats, which might
need reconstructing, will impact the breadcrumbs of all downstream nodes
from the text node.
In this patch, this process is triggered, which properly triggers the
active format reconstruction. It also enables the visiting of other token
types as is possible in the Tag Processor.

Developed in https://github.com/WordPress/wordpress-develop/pull/6054
Discussed in https://core.trac.wordpress.org/ticket/60170

Reviewed by swissspidy.
Merges [57806] to the to the 6.5 branch.

Props: dmsnell, jonsurrell, westonruter.
Fixes: #60455.
Follow-up to: [57348].


git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57823 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-13 09:28:48 +00:00
Tonya Mork
e327f6beaf Post WordPress 6.5 RC2 correct version number bump.
This commit is a follow-up to fix the RC2 version number to match its changeset's number.

[57820] had the wrong version number, as it used the next changeset number on the build.trac.wordpress.org rather than Core Trac, i.e. https://build.trac.wordpress.org/changeset/57320.

Follow-up to [57820].

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57821 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-12 17:15:40 +00:00
Tonya Mork
65debf2c4e Post WordPress 6.5 RC2 version bump.
git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57820 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-12 16:53:20 +00:00
Tonya Mork
4f7c07701d WordPress 6.5 RC2.
git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57819 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-12 16:37:31 +00:00
Jb Audras
14da39819c Help/About: Update the About page for WP 6.5 RC2.
Updates a translatable string to use a placeholder for the “Requires Plugins” string used in it.

Reviewed by audrasjb.
Merges [57817] to the to the 6.5 branch.

Props swissspidy, sergeybiryukov, presskopp.
See #60303.





git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57818 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-12 14:54:17 +00:00
Pascal Birchler
5b71cfc11a Editor: Update Packages with the latest bug fixes for 6.5 RC 2
It includes all the backports from this Gutenberg PR https://github.com/WordPress/gutenberg/pull/59756/

Reviewed by swissspidy.
Merges [57814] to the to the 6.5 branch.

Props get_dave, swissspidy, bernhard-reiter, youknowriad.
See #60315.


git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57816 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-12 14:28:15 +00:00
Jb Audras
8defd38975 HTML API: Defer applying attribute updates until necessary.
When making repeated updates to a document, the Tag Processor will end
up copying the entire document once for every update. This can lead to
catastrophic behavior in the worse case.

However, when batch-applying updates it's able to copy chunks of the
document in one thread and only end up copying the entire document once
for the entire batch.

Previously the Tag Processor has been eagerly applying udpates, but in
this patch it defers applying those updates as long as is possible.
Developed in https://github.com/WordPress/wordpress-develop/pull/6120
Discussed in https://core.trac.wordpress.org/ticket/60697

Follow-up to [55706], [56941], [57348].

Reviewed by swissspidy.
Merges [57805] to the to the 6.5 branch.

Props dmsnell, bernhard-reiter, jonsurrell, westonruter.
Fixes #60697.





git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57815 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-12 14:25:30 +00:00
Jb Audras
ac6b1d8256 REST API: Remove unnecessary upload overrides in font face controller.
This removes settings that are the default value or required for side-loading from the `WP_REST_Font_Faces_Controller::handle_font_file_upload()`.

This is to harden the endpoint and future proof against any changes to `wp_handle_upload()` and related functions/security checks.

Reviewed by swissspidy, audrasjb.
Merges [57804] to the to the 6.5 branch.

Props peterwilsoncc, dd32.
Fixes #60741.





git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57813 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-12 13:33:26 +00:00
Sergey Biryukov
1d89704033 Plugins: Remove extra space in a translatable string.
Follow-up to [57545].

Reviewed by swissspidy.
Merges [57791] to the to the 6.5 branch.

Props Presskopp, afragen.
Fixes #60730.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57812 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-12 12:19:08 +00:00
Jb Audras
0b3141764f Help/About: Update the About page for WP 6.5 RC2.
This changeset removes the "Pattern overrides" section from features.
Also updates the field guide link, this link should redirect correctly once the post is published.

Follow-up to [57715], [57767].

Reviewed by audrasjb.
Merges [57809] to the to the 6.5 branch.

Props ryelle, benjamin_zekavica, richtabor, laurlittle.
See #60303.





git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57810 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-12 10:48:32 +00:00
Jb Audras
982a0be08c Toolbar: Fix dropdown admin menu styles on front-end.
This changeset switches back the admin menu items `height` property to `px` unit to prevent issues with themes using `html { font-size: 62.5%; }`.

Follow-up to [57765].

Reviewed by swissspidy.
Merges [57792] to the to the 6.5 branch.

Props bgnicolepaschen, sabernhardt, huzaifaalmesbah, ironprogrammer, shailu25, mohonchandra.
Fixes #60707.
See #43633.





git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57808 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-12 09:54:13 +00:00
bernhard-reiter
d289e7500e Block Hooks: Remove filter global reset from test teardown.
Resetting the `$wp_current_filter` global during test teardown is unnecessary, as it is taken care of by the unit test's base class.

This changeset removes the reset accordingly.

Follow-up [57790].

Reviewed by swissspidy.
Merges [57799] to the to the 6.5 branch.

Props swissspidy, timothyblynjacobs.
See #60671.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57803 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-11 14:15:58 +00:00
bernhard-reiter
12656dd226 Block Hooks: Use new Templates Controller filter instead of action.
This changeset adds a new `rest_pre_insert_{$this->post_type}` filter in the `WP_REST_Templates_Controller`, where it is applied to the return value of the `prepare_item_for_database` method. (This is consistent with the `WP_REST_Post_Controller`, where that filter has existed before.)

The new filter is then used to inject hooked blocks into the template (or template part) content received via the endpoint, prior to persisting it to the database.

This supersedes the previous mechanism, which was using the `rest_after_insert_{$this->post_type}` ''action'', from which it performed an additional `wp_update_post` call to update the template (part) content with the hooked blocks injected. The new technique eschews that additional call and the resulting extra revision it created, as well as a problem with regard to duplicated escaping and sanitization, which had caused some special characters to be garbled.

Reviewed by swissspidy.
Merges [57790] to the to the 6.5 branch.

Props tomjcafferkey, gziolo, swissspidy, karolmanijak.
Fixes #60671.

git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57802 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-11 14:12:20 +00:00
David Baumwald
0c1507c2e6 Branch 6.5
git-svn-id: https://develop.svn.wordpress.org/branches/6.5@57781 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-05 17:12:09 +00:00
Jb Audras
dadca45ae0 Post WordPress 6.5 RC1 version bump.
git-svn-id: https://develop.svn.wordpress.org/trunk@57778 602fd350-edb4-49c9-b593-d223f7449a82
2024-03-05 16:23:49 +00:00