Commit Graph

24124 Commits

Author SHA1 Message Date
Sergey Biryukov 072c0afc53 Editor: Check `get_user_count()` instead of `get_users()` for the locked post notice.
This aims to avoid slowing down the post editing by using a cached value instead of calling `get_users()`, which can be slow when plugins add various filters to all `get_users()` calls, especially with meta value comparisons on large `user_meta` tables.

Follow-up to [24304], [24543], [41829], [53011], [53018].

Props berislav.grgicak, bor0, costdev.
See .
Built from https://develop.svn.wordpress.org/trunk@59522


git-svn-id: http://core.svn.wordpress.org/trunk@58908 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-16 23:51:25 +00:00
desrosj 2b5ee6e41c Build/Test Tools: Update the Codecov GitHub Action.
This updates the `codecov/codecov-action` to from version `4.6.0` to `5.1.1`.

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


git-svn-id: http://core.svn.wordpress.org/trunk@58907 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-16 20:06:23 +00:00
desrosj 50aeb23800 Build/Test Tools: Support manual runs for the test old branch workflow.
This is the only workflow that does not currently support manually running.

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


git-svn-id: http://core.svn.wordpress.org/trunk@58906 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-16 19:40:27 +00:00
desrosj 4fdd73689f Build/Test Tools: Update `slackapi/slack-github-action`.
This makes the necessary changes to update the Slack GitHub Action to the latest version, currently `2.0.0`.

Most notably this update provides more control over how attempts re retried when rate limiting is encountered.

Reverts [59209].

See , .
Built from https://develop.svn.wordpress.org/trunk@59519


git-svn-id: http://core.svn.wordpress.org/trunk@58905 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-16 19:29:24 +00:00
Felix Arntz f7d4ea3ceb Site Health: Remove use of deprecated function from `wp_is_https_supported()`.
Follow up to [56664].

Props peter8nss, debarghyabanerjee, sebastienserre, geekofshire, swissspidy, desrosj.
Fixes .
See .

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


git-svn-id: http://core.svn.wordpress.org/trunk@58903 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-16 14:08:24 +00:00
Sergey Biryukov 15f2879461 Tests: Clean up `convert_smilies()` tests.
Includes:
* Removing redundant `use_smilies` option switches, as it is set to 1 by default.
* Restoring the `$wpsmiliestrans` array before performing assertions, not after.
* Moving most of the `smilies_init()` calls to a `set_up()` method.

Follow-up to [409/tests], [26191], [28717].

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


git-svn-id: http://core.svn.wordpress.org/trunk@58902 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-15 23:24:23 +00:00
Sergey Biryukov 57e024a157 Formatting: Check the result of `preg_split()` in `convert_smilies()`.
This aims to avoid a fatal error from `count()` when `preg_split()` fails on large input.

Includes:
* Optimizing the regular expression used to split the input by tags to avoid unlimited backtracking for better performance.
* Adjusting the function logic for better readability.

Follow-up to [340], [4380], [26191].

Props podpirate, nathkrill, rajinsharwar, dmsnell, bjorsch, q0rban, audrasjb, rupw, Ov3rfly, jorbin, nhrrob, chaion07, mcqueen22, azaozz, narenin, roybellingan, SergeyBiryukov.
See .
Built from https://develop.svn.wordpress.org/trunk@59515


git-svn-id: http://core.svn.wordpress.org/trunk@58901 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-14 23:53:24 +00:00
joedolson cc3c3bf4e6 Comments: Avoid reverting comment reply when context menu is open.
Fix a bug where a comment reply would be discarded if `esc` was pressed to dismiss the context menu in Safari or Firefox.

Checks whether the contextmenu is open and ignores the `esc` key if it is.

Props yellowafterlife, yogeshbhutkar, joedolson.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59514


git-svn-id: http://core.svn.wordpress.org/trunk@58900 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-14 01:32:18 +00:00
audrasjb 880bce2ad5 Themes: Replace "Active" wording with "Installed" in the theme install checks page.
When reinstalling a theme by uploading a ZIP file, the wording used in some strings referred to the "active" theme even though it's not the currrently active theme. This changeset replaces these strings to refer to the "installed" theme, which is more accurate.

Follow-up to [52610], [52580].

Props afercia, ankitkumarshah, abcd95, yogeshbhutkar, parthvataliya, sainathpoojary, virgar, gaellebesson, nuryko, guillaumeturpin, maximemeganck, sabrineg.
Fixes .
See , 



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


git-svn-id: http://core.svn.wordpress.org/trunk@58899 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-13 23:53:17 +00:00
Sergey Biryukov afde562494 Coding Standards: Use strict comparison in `get_blog_id_from_url()`.
Follow-up to [https://mu.trac.wordpress.org/changeset/1538 mu:1538].

Props debarghyabanerjee.
See .
Built from https://develop.svn.wordpress.org/trunk@59512


git-svn-id: http://core.svn.wordpress.org/trunk@58898 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-13 23:17:17 +00:00
joedolson e25f6d7e2f Editor: Hide 'Skip to Editor' if editor not supported.
Wrap the classic editor 'Skip to Editor' link in a conditional to prevent it from rendering on post types that do not have editor support.

Props wildworks, parthvataliya, narenin, sainathpoojary, ankitkumarshah, parthvataliya, im3dabasia1.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59511


git-svn-id: http://core.svn.wordpress.org/trunk@58897 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-13 21:53:15 +00:00
joedolson ac54a93332 Customize: Remove unnecessary `height: 100%` on accordion button.
Remove CSS that could occasionally trigger the accordion buttons to be 100% the height of the accordion container.

Props dhewercorus, im3dabasia1, sabernhardt, rvoigt, ghinamt, vishy-moghan, frankbiganski, redkite.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59510


git-svn-id: http://core.svn.wordpress.org/trunk@58896 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-13 21:10:20 +00:00
desrosj 26335af1ac Build/Test Tools: Update `devDependencies`.
This updates the following `devDependencies`:

- `dotenv` from `16.4.5` to `16.4.7`
- `dotenv-expand` from `11.0.6` to `12.0.1`
- `postcss` from `8.4.47` to `8.4.49`
- `qunit` from `2.22.0` to `2.23.1`
- `sass` from `1.79.4` to `1.79.6`
- `terser-webpack-plugin` from `5.3.10` to `5.3.11`
- `uglify-js` from `3.17.4` to `3.19.3`
- `uuid` from `9.0.1` to `11.0.3`
- `webpack` from `5.90.2` to `5.97.1`

Additionally, `npm audit fix` has been run.

Follow up to [58585].

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


git-svn-id: http://core.svn.wordpress.org/trunk@58895 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-13 19:06:24 +00:00
desrosj 4efa589165 Build/Test Tools: Trim down the upgrade testing matrix.
The upgrade testing workflow is currently at ~978 jobs spawned from the strategy matrix. While it's great to test all possible combinations, GitHub's UI cannot keep up with tracking that number of jobs, often taking 30-45 minutes to accurately report the outcome even though the jobs themselves all complete in under 5 minutes.

This is 2x the total number of concurrent jobs allowed for the entire organization (which creates a backlog and slows everything down even more).

This trims down the number of combinations included in the testing matrices to be a bit more thoughtful following the following methodology:

- The last two releases of WordPress are tested against all PHP and MySQL LTS version combinations and the most recent innovation release.
- The next 6 oldest versions of WordPress are tested against both the oldest and newest releases of PHP currently supported for both PHP 7 & 8 along with the oldest and newest MySQL LTS versions currently supported (no innovation releases).
- For the remaining versions of WordPress receiving security updates, they are only included if the database version was different that the previous major release.
- The oldest version of WordPress receiving security updates should always be tested against the same full list of combinations as the last two releases.

When choosing which MySQL versions to test against:

- Only the most recent innovation release should be included in testing.
- Even though MySQL >= 5.5.5 is currently supported, there are no 5.5.x Docker containers available that work on modern architectures.
- 5.6.x Docker containers are available and work, but 5.6 only accounts for ~2.3% of installs as of 12/6/2024.defaults:
- 5.7.x accounts for ~20% of installs, so this is used below instead.

With these changes, the total number of jobs is reduced by ~58%.

Props johnbillion, mukesh27.
See .
Built from https://develop.svn.wordpress.org/trunk@59508


git-svn-id: http://core.svn.wordpress.org/trunk@58894 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-13 15:34:14 +00:00
desrosj d3d4603b99 Build/Test Tools: Remove repository specific logic from callable workflows.
Because reusable workflows could be called from any other repository in a variety of contexts, repository specific `if` conditions should not be present.

Instead, this logic should be included in the calling workflows only.

Props johnbillion.
See .
Built from https://develop.svn.wordpress.org/trunk@59507


git-svn-id: http://core.svn.wordpress.org/trunk@58893 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-13 14:59:14 +00:00
Sergey Biryukov 56f776835d Filesystem API: Check `PHP_OS_FAMILY` instead of `php_uname()` in PclZip.
The `php_uname()` function can be disabled on some hosts, in which case the call fails.

The `PHP_OS_FAMILY` constant indicates the operating system family PHP was built for, and is available as of PHP 7.2.0.

Reference: [https://www.php.net/manual/en/reserved.constants.php#constant.php-os-family PHP Manual: Predefined Constants: PHP_OS_FAMILY].

Follow-up to [6779], [57985], [58678], [58684].

Props daymobrew, costdev, desrosj.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59506


git-svn-id: http://core.svn.wordpress.org/trunk@58892 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-12 22:23:16 +00:00
Sergey Biryukov caaf759d21 Docs: Correct formatting for script module data filter documentation examples.
Follow-up to [58579].

Props jonsurrell.
See .
Built from https://develop.svn.wordpress.org/trunk@59505


git-svn-id: http://core.svn.wordpress.org/trunk@58891 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-11 15:20:18 +00:00
Sergey Biryukov d1058355a5 Twenty Twenty-Two: Fix PHPCS issues in `functions.php`.
* Inline comments must end in full stops, exclamation marks, or question marks.
* There must be exactly one blank line after the file comment.

Follow-up to [52081].

Props pitamdey, mukesh27.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59504


git-svn-id: http://core.svn.wordpress.org/trunk@58890 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-10 23:22:16 +00:00
gziolo 04a6ab1c8d HTML API: Remove nullable from get_breadcrumbs return type
Follow-up [58713]
Props jonsurrell, westonruter, gziolo.
Fixes .


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


git-svn-id: http://core.svn.wordpress.org/trunk@58889 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-10 11:41:16 +00:00
gziolo 70af002cdb HTML API: Prevent bookmarks from being set on virtual tokens
Fixes the issue when an HTML_Processor bookmark was set at a virtual token (a node in the resulting document that does not correspond to an HTML token present in the input string), seek behavior was unreliable.

Props jonsurrell, gziolo.
Fixes .



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


git-svn-id: http://core.svn.wordpress.org/trunk@58888 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-10 09:13:20 +00:00
Sergey Biryukov cfb0b131dc REST API: Correct description for the `humanized_updated` block directory property.
Follow-up to [48242], [51676].

Props mujuonly, mukesh27.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59501


git-svn-id: http://core.svn.wordpress.org/trunk@58887 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-09 22:45:19 +00:00
gziolo e8b5d1a702 HTML API: Step past closing HTML, BODY tags
The HTML specification does not close HTML or BODY tags (pop them off the stack of open elements) when their tag closers are encountered. The HTML processor correctly handled this behavior, however it incorrectly "paused" by returning true from the step functions. 

Props jonsurrell, dmsnell, gziolo.
Fixes .


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


git-svn-id: http://core.svn.wordpress.org/trunk@58886 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-09 12:44:17 +00:00
isabel_brison 833417c545 Editor: Update docblocks for `wp_get_global_stylesheet` and `WP_Theme_JSON::get_stylesheet`.
Updates docblocks to account for new use of the `custom-css` string in their `$types` parameters and adds information to deprecation of `wp_get_global_styles_custom_css`.

Props justlevine, isabel_brison, ramonopoly.
Fixes .

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


git-svn-id: http://core.svn.wordpress.org/trunk@58885 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-09 02:55:18 +00:00
Sergey Biryukov f60edf3667 Coding Standards: Use strict comparison in `wp-includes/comment-template.php`.
Follow-up to [162], [2685], [4494], [8878], [8961], [55660].

Props aristath, poena, afercia, SergeyBiryukov.
See .
Built from https://develop.svn.wordpress.org/trunk@59498


git-svn-id: http://core.svn.wordpress.org/trunk@58884 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-08 23:43:21 +00:00
Sergey Biryukov 708282ecaf Coding Standards: Use strict comparison in `media_upload_form_handler()`.
Follow-up to [10390].

Props deepakrohilla, iflairwebtechnologies, mukesh27, dingguodong, aristath.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59497


git-svn-id: http://core.svn.wordpress.org/trunk@58883 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-07 22:08:19 +00:00
Sergey Biryukov c10dbc8434 Coding Standards: Use correct escaping function for `wp_http_referer`.
Follow-up to [58069].

Props yogeshbhutkar, sainathpoojary, PcTevree, knutsp, siliconforks, stromhalm, shanemuir.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59496


git-svn-id: http://core.svn.wordpress.org/trunk@58882 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-06 17:07:22 +00:00
Sergey Biryukov ebce351835 Docs: Add missing `@var` tag for `WP_Query::$query_vars_changed`.
Follow-up to [17552].

Props marian1, jigar-bhanushali, martin.krcho, parthvataliya.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59495


git-svn-id: http://core.svn.wordpress.org/trunk@58881 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-05 22:05:20 +00:00
Pascal Birchler 03a5e578d8 I18N: Add new `WP_Locale::get_month_genitive()` method.
Complements existing helper methods such as `WP_Locale::get_month_abbrev()`.

Props ankitkumarshah, Tkama, SergeyBiryukov.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59494


git-svn-id: http://core.svn.wordpress.org/trunk@58880 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-05 21:37:20 +00:00
Pascal Birchler c24a5b9062 Embeds: ensure correct thumbnail height.
Use height 0 instead of 9999 to avoid unnecessarily using the full size version.

Props colinleroy, swissspidy.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59493


git-svn-id: http://core.svn.wordpress.org/trunk@58879 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-05 21:21:17 +00:00
desrosj 61b026c27f Build/Test Tools: Introduce workflow for testing the local Docker environment.
While the PHPUnit workflow currently relies on the local Docker environment and provides some safety checks that the environment works as expected, this may not always be true and does not test all of the available commands related to the environment.

This introduces a basic workflow for testing the related scripts for the various supported combinations of PHP and database software with the environment to confirm everything is working as expected.

Ideally this would also be run on Windows and MacOS to catch platform specific bugs. Unfortunately, Docker is not supported within the GitHub Action runner images, so not all bugs will be caught by this workflow.

Props johnbillion, Clorith.
See .
Built from https://develop.svn.wordpress.org/trunk@59492


git-svn-id: http://core.svn.wordpress.org/trunk@58878 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-05 18:34:19 +00:00
desrosj fb36f6223b Build/Test Tools: Support `trunk` as a version.
`trunk` is used interchangeably with `nightly`, so should be an accepted value when determining which version of WordPress is being tested.

Follow up to [59452], [59483].

Props johnbillion.
See .
Built from https://develop.svn.wordpress.org/trunk@59491


git-svn-id: http://core.svn.wordpress.org/trunk@58877 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-05 18:23:22 +00:00
desrosj 1784ccff5b Build/Test Tools: Use newer versions for `include` jobs.
The `include` part of the strategy for the PHPUnit testing workflow defines a few testing configurations outside of the matrix. The versions of PHP and MySQL used in these have not been updated for some time. This was mostly due to various incompatibilities that have since been resolved.

Props peterwilsoncc, johnbillion.
See .
Built from https://develop.svn.wordpress.org/trunk@59490


git-svn-id: http://core.svn.wordpress.org/trunk@58876 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-05 15:56:20 +00:00
desrosj 73353051af Build/Test Tools: Properly escape `$` characters in Docker compose file.
This fixes an invalid interpolation format error that can be encountered in the `mysql` container’s healthcheck test command.

Follow up to [59484].

Props afercia.
See .
Built from https://develop.svn.wordpress.org/trunk@59489


git-svn-id: http://core.svn.wordpress.org/trunk@58875 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-05 15:37:17 +00:00
Pascal Birchler cbca77642b Plugins: Load `wp-admin/includes/plugin.php` earlier.
Partially reverts [59479] and [59461], which previously tried to move some functions from `wp-admin/includes/plugin.php` to `wp-includes/functions.php` so they are available early, so that `get_plugin_data()` can be used.

However, other functions from that file are often used by plugins without necessarily checking whether they are available, easily causing fatal errors. Requiring this file directly is a safer approach to avoid such errors.

Props peterwilsoncc, dd32, swissspidy, johnbillion.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59488


git-svn-id: http://core.svn.wordpress.org/trunk@58874 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-05 12:13:17 +00:00
Sergey Biryukov 9c031458c8 Docs: Remove blank line at the end of `wp_prepare_attachment_for_js()` DocBlock.
Follow-up to [21680], [49281].

Props nareshbheda.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59486


git-svn-id: http://core.svn.wordpress.org/trunk@58872 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-04 23:38:17 +00:00
desrosj 6342cd3c2b Build/Test Tools: Run install tests when JSON reading workflow is changed.
Because the installation testing workflow relies on the reusable workflow that reads the JSON support files, it should be run when that file is changed to confirm there are no issues.

This is currently only configured for `pull_request` events, but should also be true for `push`.

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


git-svn-id: http://core.svn.wordpress.org/trunk@58871 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-04 15:27:15 +00:00
desrosj 14ec385f12 Build/Test Tools: Support older MariaDB versions in local Docker environment.
Older versions of MariaDB did not contain the `mariadb-admin` command. This command is configured as the `healthcheck` used by the local Docker environment to confirm that the database container has successfully started and is reporting as “healthy”. The current result is a failure when starting the environment while using one of the affected older versions.

For MariaDB versions 10.3 and earlier, the `mysqladmin` command was used instead. Since WordPress still technically supports back to MariaDB 5.5, the local environment should support running these versions. This updates the environment configuration to take this into account when performing a `healthcheck` test.

The README file is also updated to reflect that the same workaround added in [57568] for MySQL <= 5.7 is required when using MariaDB 5.5 on an Apple silicon machine.

Props johnbillion.
See .
Built from https://develop.svn.wordpress.org/trunk@59484


git-svn-id: http://core.svn.wordpress.org/trunk@58870 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-04 15:18:19 +00:00
desrosj 99fb518290 Build/Test Tools: Add `repository` input to support JSON reading workflow.
`actions/checkout` will always checkout the current repository unless the `repository` input is specified. This updates the `reusable-support-json-reader-v1.yml` workflow to always default to reading the JSON files from `wordpress-develop`.

A `repository` has also been added to the workflow to allow a different set of JSON files to be read if desired.

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


git-svn-id: http://core.svn.wordpress.org/trunk@58869 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-04 14:43:19 +00:00
Bernhard Reiter 859a39a5f9 Block Hooks: Fix context in `update_ignored_hooked_blocks_postmeta`.
Ensure that the `$context` arg passed from `update_ignored_hooked_blocks_postmeta` to `apply_block_hooks_to_content` (and from there, to filters such as `hooked_block_types` and `hooked_block`) has the correct type (`WP_Post`).

Filters hooked to `hooked_block_types` etc can typically include checks that conditionally insert a hooked block depending on `$context`. Prior to this changeset, a check like `if ( $context instanceof WP_Post )` would incorrectly fail, as `$context` would be a `stdClass` instance rather than a `WP_Post`. As a consequence, a hooked block inside of a Navigation post object that was modified by the user would not be marked as ignored by `update_ignored_hooked_blocks_postmeta`, and thus be erroneosly re-inserted by the Block Hooks algorithm.

Props bernhard-reiter.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59482


git-svn-id: http://core.svn.wordpress.org/trunk@58868 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-04 12:07:17 +00:00
Sergey Biryukov a319916e26 External Libraries: Upgrade PHPMailer to version 6.9.3.
This is a maintenance release, adding support for the release version of PHP 8.4, and experimental support for PHP 8.5.

References:
* [https://github.com/PHPMailer/PHPMailer/releases/tag/v6.9.3 PHPMailer 6.9.3 release notes]
* [https://github.com/PHPMailer/PHPMailer/compare/v6.9.2...v6.9.3 Full list of changes in PHPMailer 6.9.3]

Follow-up to [50628], [50799], [51169], [51634], [51635], [52252], [52749], [52811], [53500], [53535], [53917], [54427], [54937], [55557], [56484], [57137], [59246].

Props desrosj, yogeshbhutkar, ayeshrajans.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59481


git-svn-id: http://core.svn.wordpress.org/trunk@58867 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-03 15:22:18 +00:00
Sergey Biryukov ab2697f8bf Customize: Begin HTML markup before Customizer script hooks.
This prevents printing styles and scripts before the `<!DOCTYPE>`.

The `_wp_admin_html_begin()` function should precede Customizer script hooks, in case a plugin prints markup inside a hook such as `admin_enqueue_scripts`.

Follow-up to [19995], [27907].

Props sabernhardt.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59480


git-svn-id: http://core.svn.wordpress.org/trunk@58866 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-02 23:36:18 +00:00
Pascal Birchler 789d1d9c2e Plugins: Make more plugin-related functions available early on.
This is a follow-up to [59461], which moved `get_plugin_data()` from `wp-admin/includes/plugin.php` to `wp-includes/functions.php` so it's available during the plugin loading process.

Related functions like `is_plugin_active()` are often used together and should therefore be moved as well, to improve backward compatibility for plugins which load `wp-admin/includes/plugin.php` only conditionally.

Props johnbillion, dd32, swissspidy.
See .
Built from https://develop.svn.wordpress.org/trunk@59479


git-svn-id: http://core.svn.wordpress.org/trunk@58865 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-02 17:10:15 +00:00
Pascal Birchler 8f08a8e2e1 I18N: Load admin translations for auto update emails.
As a follow-up to [59460], make sure that admin strings are loaded when switching locales for auto update notification emails, as those strings are in a separate translation file.

Props benniledl, swissspidy.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59478


git-svn-id: http://core.svn.wordpress.org/trunk@58864 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-02 17:08:20 +00:00
gziolo 369a675488 Interactivity API: Support length property on strings and arrays on the server
The Interactivity API tries to align client and server rendering so that the behavior is the same. Adds missing handling for `.length` to directives processing on the server on strings and numeric arrays which is inherently supported through JavaScript language on the client.

Props jonsurrell, gziolo, luisherranz.
Fixes .


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


git-svn-id: http://core.svn.wordpress.org/trunk@58863 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-02 08:10:17 +00:00
poena 8f8ffaab84 Twenty Thirteen & Twenty Sixteen: Correct the border of the latest comments block in the editor.
This change hides the top border of the first comment in the latest comments block, so that the design
in the editor and the front looks the same.

Props viralsampat, sabernhardt, aishwarryapande, parthvataliya, imranhasanraaz.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59476


git-svn-id: http://core.svn.wordpress.org/trunk@58862 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-02 05:44:19 +00:00
Sergey Biryukov e6f29b4c0e Date/Time: Add `d.m.Y` to date format presets on General Settings screen.
This gives users another option when selecting how dates are displayed on their site. This change is relevant for better localization, providing more date format choices for users in regions where this format is common.

The `array_unique()` call ensures that if this format was already added by a plugin or theme, it won't be duplicated.

Follow-up to [9131], [22299], [28820], [28848].

Props Daedalon, pbearne, fierevere, im3dabasia1, SergeyBiryukov.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59475


git-svn-id: http://core.svn.wordpress.org/trunk@58861 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-12-01 18:39:20 +00:00
Sergey Biryukov 0749661c97 Docs: Correct DocBlock formatting for `WP_Theme_JSON::FONT_FAMILY_SCHEMA`.
Follow-up to [57496].

Props marian1.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59474


git-svn-id: http://core.svn.wordpress.org/trunk@58860 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-11-30 13:53:20 +00:00
Adam Silverstein c08c2e28cc Media: improve filter to enable setting output quality by image size.
Add a new $size parameter to the  wp_editor_set_quality filter. $size is an array with 'width' and 'height' keys. Developers can use this information to set image quality based on the image size.

Props adamsilverstein, joemcgill, Mte90, codekraft, birgire, azaozz, sppramodh.
Fixes .



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


git-svn-id: http://core.svn.wordpress.org/trunk@58859 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-11-29 23:48:15 +00:00
Sergey Biryukov 47bb776fd7 Editor: Add description for Banners block pattern category.
Follow-up to [55098].

Props parinpanjari, youknowriad, Joen, dhruvang21, apermo, mukesh27.
Fixes .
Built from https://develop.svn.wordpress.org/trunk@59472


git-svn-id: http://core.svn.wordpress.org/trunk@58858 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-11-29 22:46:21 +00:00
Sergey Biryukov dd967e2a2e Coding Standards: Cast `gmdate( 'w' )` to `int` before using as integer.
This addresses several instances of `gmdate( 'w' )` being used directly as an integer, when it's actually a numeric string. The issue is remediated by casting the value to `int` before use.

Affected functions:
* `get_calendar()`
* `get_weekstartend()`

Follow-up to [508], [1632].

Props justlevine.
See .
Built from https://develop.svn.wordpress.org/trunk@59471


git-svn-id: http://core.svn.wordpress.org/trunk@58857 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-11-28 22:52:17 +00:00