Commit Graph

22053 Commits

Author SHA1 Message Date
Jb Audras
488e431aaa I18n: Move translator comments inside sprintf for tagline field description.
Props costdev.
Fixes #57675.




git-svn-id: https://develop.svn.wordpress.org/trunk@56203 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-11 05:53:19 +00:00
Isabel Brison
a02886a868 Editor: opt out of Navigation fallback.
Allows developers to opt out of the auto-creation of the Navigation fallback through a filter.

Props get_dave, spacedmonkey, ramonopoly.
Fixes #58750.


git-svn-id: https://develop.svn.wordpress.org/trunk@56202 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-11 05:39:33 +00:00
Isabel Brison
eea94adc54 General: fix botched file move in r56199.
Moves `src/wp-admin/includes/theme-previews.php` to `src/wp-includes/theme-previews.php`.

Props peterwilsoncc.
See #58712.


git-svn-id: https://develop.svn.wordpress.org/trunk@56201 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-11 05:17:56 +00:00
Isabel Brison
444bdf49bc Editor: update string incorrectly marked for translation in Chrome.
Update the Pattern post type `edit_item` label to be `Edit Block Pattern` instead of `Edit Pattern` so Chrome doesn’t open the translation modal.

Props andrewserong,, ramonopoly, eric.7186, audrasjb, wildworks, Toro_Unit.
Fixes #58716.


git-svn-id: https://develop.svn.wordpress.org/trunk@56200 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-11 05:08:50 +00:00
Isabel Brison
7813524023 General: add nonce for block theme preview activation.
Adds a nonce so that activation works for block theme previews. Temporary fix until there is a REST API endpoint for activating themes.

Props scruffian, peterwilsoncc, nithins53, nithi22, jomonthomaslobo1, poena, syamraj24, vivekawsm, mrinal013.
Fixes #58712.


git-svn-id: https://develop.svn.wordpress.org/trunk@56199 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-11 05:01:05 +00:00
Jb Audras
d7ddda1bbf Docs: Replace multiple single line comments with multi-line comments.
This changeset updates various comments as per WordPress PHP Inline Documentation Standards.
See https://developer.wordpress.org/coding-standards/inline-documentation-standards/php/#5-inline-comments.

Follow-up to [56174], [56175], [56176], [56177], [56178], [56179], [56180], [56191], [56192], [56193], [56194], [56195].

Props costdev, audrasjb.
See #58459.




git-svn-id: https://develop.svn.wordpress.org/trunk@56196 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-10 23:19:12 +00:00
Jb Audras
f80f37b320 Docs: Replace multiple single line comments with multi-line comments.
This changeset updates various comments as per WordPress PHP Inline Documentation Standards.
See https://developer.wordpress.org/coding-standards/inline-documentation-standards/php/#5-inline-comments.

Follow-up to [56174], [56175], [56176], [56177], [56178], [56179], [56180], [56191], [56192], [56193], [56194].

Props costdev, audrasjb.
See #58459.




git-svn-id: https://develop.svn.wordpress.org/trunk@56195 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-10 23:17:05 +00:00
Jb Audras
74d34d0879 Docs: Replace multiple single line comments with multi-line comments.
This changeset updates various comments as per WordPress PHP Inline Documentation Standards.
See https://developer.wordpress.org/coding-standards/inline-documentation-standards/php/#5-inline-comments.

Follow-up to [56174], [56175], [56176], [56177], [56178], [56179], [56180], [56191], [56192], [56193].

Props costdev, audrasjb.
See #58459.




git-svn-id: https://develop.svn.wordpress.org/trunk@56194 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-10 23:09:16 +00:00
Jb Audras
add61a8d7c Docs: Replace multiple single line comments with multi-line comments.
This changeset updates various comments as per WordPress PHP Inline Documentation Standards.
See https://developer.wordpress.org/coding-standards/inline-documentation-standards/php/#5-inline-comments.

Follow-up to [56174], [56175], [56176], [56177], [56178], [56179], [56180], [56191], [56192].

Props costdev, audrasjb.
See #58459.




git-svn-id: https://develop.svn.wordpress.org/trunk@56193 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-10 22:58:33 +00:00
Jb Audras
2a66e49e96 Docs: Replace multiple single line comments with multi-line comments.
This changeset updates various comments as per WordPress PHP Inline Documentation Standards.
See https://developer.wordpress.org/coding-standards/inline-documentation-standards/php/#5-inline-comments.

Follow-up to [56174], [56175], [56176], [56177], [56178], [56179], [56180], [56191].

Props costdev, audrasjb.
See #58459.




git-svn-id: https://develop.svn.wordpress.org/trunk@56192 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-10 22:46:22 +00:00
Jb Audras
3666c0e31b Docs: Replace multiple single line comments with multi-line comments.
This changeset updates various comments as per WordPress PHP Inline Documentation Standards.
See https://developer.wordpress.org/coding-standards/inline-documentation-standards/php/#5-inline-comments.

Follow-up to [56174], [56175], [56176], [56177], [56178], [56179], [56180].

Props costdev, audrasjb.
See #58459.




git-svn-id: https://develop.svn.wordpress.org/trunk@56191 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-10 22:36:06 +00:00
Jb Audras
a5352c3680 Twenty Twenty-Three: Add a border to Quote block.
This changeset adds a border to the Quote block on front-end, in order to be consistent with the Editor styles.

Props nidhidhandhukiya, poena, akrocks, sabernhardt, nithins53, zoonini.
Fixes #57506.




git-svn-id: https://develop.svn.wordpress.org/trunk@56190 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-10 22:18:27 +00:00
Joe Dolson
bdc7d56955 Media: Fix responsive views in image editor
Adjust breakpoints for mid-range responsive views to prevent the save panel from overflowing other sections.

Props wildworks, mikinc860, mukesh27, sabernhardt, dhrumilk.
Fixes #58692.

git-svn-id: https://develop.svn.wordpress.org/trunk@56189 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-10 22:09:21 +00:00
Jb Audras
57ab21fb51 Twenty Seventeen: Use wp_register_script() to register HTML5 Shiv script.
This replaces `wp_register_style()` with `wp_register_script()`.

Props sabernhardt.
Fixes #56699.




git-svn-id: https://develop.svn.wordpress.org/trunk@56188 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-10 22:02:31 +00:00
Joe Dolson
b1775f327d Editor: Fix layout of no-js state in site editor.
Remove padding and adjust classes to match current state of editor.

Props afercia, andraganescu, poena.
Fixes #56228.

git-svn-id: https://develop.svn.wordpress.org/trunk@56187 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-10 21:20:15 +00:00
Andrew Ozz
8b8afa1299 Filesystem API: Ensure wp_tempnam() does not produce file names longer than 255 characters as this is the limit on most filesystems.
Props: costdev, doems, mikeschroder, oglekler, mrinal013.
Fixes: #35755.

git-svn-id: https://develop.svn.wordpress.org/trunk@56186 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-10 20:31:35 +00:00
Jonny Harris
a92f7bf8cb Themes: Improved caching in wp_theme_has_theme_json().
Improve logic in `wp_theme_has_theme_json()` to improve caching soo it takes into account that a theme can be switched. Before this function would overly cache if the current theme has a theme.json file. Now it use the value of `get_stylesheet()` as a key to an array. This way, if the value of stylesheet is changed, by either a filter or in a unit test, a new check to see if the file exists is run. For this reason, the workaround to check if unit tests are running by checking if  `WP_RUN_CORE_TESTS` constant exists can be removed.

Props westonruter, spacedmonkey, flixos90.
Fixes #58758.

git-svn-id: https://develop.svn.wordpress.org/trunk@56185 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-10 19:15:36 +00:00
Sergey Biryukov
f933aa3616 Coding Standards: Use strict comparison in wp-includes/class-wp-user.php.
Follow-up to [15919], [21866], [41624].

Props aristath, poena, afercia, SergeyBiryukov.
See #57839.

git-svn-id: https://develop.svn.wordpress.org/trunk@56184 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-10 12:51:51 +00:00
Jb Audras
03ff5a4f22 Editor: Ensure blocks registered within parent theme are available when child theme is activated.
This changeset fixes both `register_block_script_handle()` and `register_block_style_handle()` functions, allowing for child themes to access and utilise 
blocks defined in parent themes.

Previously these functions could not handle blocks registered in Parent themes. This changeset fixes the issue by determining whether the given asset path 
belongs to either of the template or stylesheet directories (Parent and Child themes respectively) as opposed to just checking using 
`get_theme_file_path('')`.

Props jacknotman, Levdbas, audrasjb, guillaumeturpin, leprincenoir, whaze, isabel_brison.
Fixes #57566.

 --Cette ligne, et les suivantes ci-dessous, seront ignorées--

M    trunk/src/wp-includes/blocks.php


git-svn-id: https://develop.svn.wordpress.org/trunk@56183 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-10 06:34:37 +00:00
Jb Audras
65381c986b Editor: Typo correction in Author block template description.
Follow-up to [56145].

Props kebbet.




git-svn-id: https://develop.svn.wordpress.org/trunk@56182 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-09 22:24:16 +00:00
Jb Audras
c23d9a72b7 General: Fix an error introduced in [56179].
Follow-up to [56179].

Unprops audrasjb.




git-svn-id: https://develop.svn.wordpress.org/trunk@56181 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-09 22:15:41 +00:00
Jb Audras
a39e9774c3 Docs: Replace multiple single line comments with multi-line comments.
This changeset updates various comments as per WordPress PHP Inline Documentation Standards.
See https://developer.wordpress.org/coding-standards/inline-documentation-standards/php/#5-inline-comments.

Follow-up to [56174], [56175], [56176], [56177], [56178], [56179].

Props costdev, audrasjb.
See #58459.




git-svn-id: https://develop.svn.wordpress.org/trunk@56180 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-09 21:46:24 +00:00
Jb Audras
16041a3913 Docs: Replace multiple single line comments with multi-line comments.
This changeset updates various comments as per WordPress PHP Inline Documentation Standards.
See https://developer.wordpress.org/coding-standards/inline-documentation-standards/php/#5-inline-comments.

Follow-up to [56174], [56175], [56176], [56177], [56178].

Props costdev, audrasjb.
See #58459.




git-svn-id: https://develop.svn.wordpress.org/trunk@56179 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-09 21:38:35 +00:00
Jb Audras
bf911a96a8 Docs: Replace multiple single line comments with multi-line comments.
This changeset updates various comments as per WordPress PHP Inline Documentation Standards.
See https://developer.wordpress.org/coding-standards/inline-documentation-standards/php/#5-inline-comments.

Follow-up to [56174], [56175], [56176], [56177].

Props costdev, audrasjb.
See #58459.




git-svn-id: https://develop.svn.wordpress.org/trunk@56178 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-09 21:23:34 +00:00
Jb Audras
3b68269941 Docs: Replace multiple single line comments with multi-line comments.
This changeset updates various comments as per WordPress PHP Inline Documentation Standards.
See https://developer.wordpress.org/coding-standards/inline-documentation-standards/php/#5-inline-comments.

Follow-up to [56174], [56175], [56176].

Props costdev, audrasjb.
See #58459.




git-svn-id: https://develop.svn.wordpress.org/trunk@56177 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-09 20:15:03 +00:00
Jb Audras
792f77b6a6 Docs: Replace multiple single line comments with multi-line comments.
This changeset updates various comments as per WordPress PHP Inline Documentation Standards.
See https://developer.wordpress.org/coding-standards/inline-documentation-standards/php/#5-inline-comments.

Follow-up to [56174], [56175].

Props costdev, audrasjb.
See #58459.




git-svn-id: https://develop.svn.wordpress.org/trunk@56176 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-09 20:05:43 +00:00
Jb Audras
05fd462d1c Docs: Replace multiple single line comments with multi-line comments.
This changeset updates various comments as per WordPress PHP Inline Documentation Standards.
See https://developer.wordpress.org/coding-standards/inline-documentation-standards/php/#5-inline-comments.

Follow-up to [56174].

Props costdev, audrasjb.
See #58459.




git-svn-id: https://develop.svn.wordpress.org/trunk@56175 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-09 19:54:42 +00:00
Jb Audras
13b571eeac Docs: Replace multiple single line comments with multi-line comments.
This changeset updates various comments as per WordPress PHP Inline Documentation Standards.
See https://developer.wordpress.org/coding-standards/inline-documentation-standards/php/#5-inline-comments.

Props costdev, audrasjb.
See #58459.




git-svn-id: https://develop.svn.wordpress.org/trunk@56174 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-09 19:50:52 +00:00
Jb Audras
a240f12e80 Twenty Twenty-Three: Fix Separator Block default styling.
This changeset sets default width to `100px` for the Separator block, and sets the Separator block located in the Call to Action block pattern to `wide`.

Props haritpanchal, audrasjb, sakibmd, poena, Rahmohn, mikachan.
Fixes #57667.




git-svn-id: https://develop.svn.wordpress.org/trunk@56173 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-09 17:21:21 +00:00
Jb Audras
7a7c23fea0 Twenty Twenty-One: Add b and strong elements to editor styles.
Sets `font-weight: 700` for these elements in the editor, in order to match the front end styles. It overrides the default admin `font-weight` of `600` for 
these HTML elements.

Props nkeller15, audrasjb, sabernhardt, pavanpatil1, iamfarhan09, poena.
Fixes #58383.




git-svn-id: https://develop.svn.wordpress.org/trunk@56172 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-09 15:48:00 +00:00
Jb Audras
890f982250 Help/About: Add Help text for Rollback feature.
This changeset adds a new Help text for Rollback feature in the WordPress Updates screen. Also adds a link to the "Common Errors" HelpHub documentation page.

Follow-up to [51857].

Props costdev, afragen, audrasjb, kebbet, marybaum.
Fixes #58199.




git-svn-id: https://develop.svn.wordpress.org/trunk@56171 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-09 14:47:22 +00:00
Jb Audras
8f2c73e971 Twenty Twenty-One: Replace the experimental link color theme support.
This replaces `add_theme_support( 'experimental-link-color' )` with `add_theme_support( 'link-color' )`, to provide the feature to Twenty Twenty-One users, but 
also to avoid throwing a "doing it wrong" message when Gutenberg version 16.2 is active.

Follow-up to [58597].

Props poena.
Fixes #58702.




git-svn-id: https://develop.svn.wordpress.org/trunk@56170 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-09 14:29:16 +00:00
Sergey Biryukov
a6895dff86 Coding Standards: Use strict comparison in wp-includes/class-wp-user-query.php.
Follow-up to [31669], [47808].

Props aristath, poena, afercia, SergeyBiryukov.
See #57839.

git-svn-id: https://develop.svn.wordpress.org/trunk@56169 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-09 09:57:16 +00:00
Jb Audras
e62dfe87ce Docs: Docblock correction in WP_REST_Attachments_Controller::upload_from_data().
The `$data` parameter in `WP_REST_Attachments_Controller::upload_from_data()` is passed and treated only as `string`, not `array`.

Props costdev.
See #57840.




git-svn-id: https://develop.svn.wordpress.org/trunk@56168 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-08 21:57:17 +00:00
Jb Audras
07d58c1356 Docs: Update link to MovableType docs (on Internet Archive).
Follow-up to [56165].

Props SergeyBiryukov.
Fixes #58760.
See #57840.




git-svn-id: https://develop.svn.wordpress.org/trunk@56167 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-08 13:19:31 +00:00
Sergey Biryukov
e91908aeb6 Coding Standards: Use strict comparison in wp-includes/class-wp-tax-query.php.
Follow-up to [16413], [16849].

Props aristath, poena, afercia, SergeyBiryukov.
See #57839.

git-svn-id: https://develop.svn.wordpress.org/trunk@56166 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-08 10:46:20 +00:00
Jb Audras
a357b7adc8 Docs: Update link to MovableType documentation.
Props mujuonly.
Fixes #58760.
See #57840.




git-svn-id: https://develop.svn.wordpress.org/trunk@56165 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-08 07:41:09 +00:00
Felix Arntz
96c64cd42d Media: Avoid programmatically created images within post content from incorrectly receiving fetchpriority="high".
Follow-up to [56037], as that changeset accidentally did not consider the changes made in [55825]: Images that are programmatically injected into post content (e.g. through a block, or shortcode, or any hook calling a function like `wp_get_attachment_image()`) must be treated as part of the whole post content blob since otherwise the heuristics for applying `fetchpriority="high"` and `loading="lazy"` are skewed by parsing certain images before others rather than sequentially parsing the entire post content. [55825] addressed that for lazy-loading, but when [56037] introduced `fetchpriority` support, the related refactor missed making the same consideration for that attribute.

Props flixos90, spacedmonkey, thekt12, mukesh27.
Fixes #58235.
See #58089.


git-svn-id: https://develop.svn.wordpress.org/trunk@56164 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-07 18:06:49 +00:00
Adam Silverstein
9781ffbca5 Revisions: return existing autosave after saving with unchanged data.
Correctly return the existing autosave when an unchanged autosave is saved, instead of returning an error.

Fix regressions after r55154 where an error and not the original autosave was returned when saving with unchanged data (for example, clicking the preview button repeatedly). Returning the autosave (ID) is the expected behavior for the endpoint.

Follow up to [55154]

Props Mamaduka, jeroenrotty, mrfoxtalbot.
Fixes #58739.



git-svn-id: https://develop.svn.wordpress.org/trunk@56163 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-07 17:51:11 +00:00
Isabel Brison
7035b615c4 Editor: rename sync_status and move it to top level.
Renames sync_status to wp_pattern_sync_status and moves it to top level field of wp_block post type.

Props glendaviesnz, aaronrobertshaw, mukesh27, peterwilsoncc.
Fixes 58677.


git-svn-id: https://develop.svn.wordpress.org/trunk@56160 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-07 07:27:53 +00:00
Isabel Brison
f47b9a2075 Editor: update npm packages with bug fixes and blessed tasks.
Includes miscellaneous bug fixes and enhancements to the Library task (#58579) and to the Command Palette task (#58643).

See #58745.


git-svn-id: https://develop.svn.wordpress.org/trunk@56159 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-07 07:18:46 +00:00
Sergey Biryukov
d113821dbb Coding Standards: Use strict comparison in wp-includes/class-wp-simplepie-file.php.
Follow-up to [10687].

Props aristath, poena, afercia, SergeyBiryukov.
See #57839.

git-svn-id: https://develop.svn.wordpress.org/trunk@56158 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-07 06:40:11 +00:00
John Blackbourn
a7de2a8e26 Docs: Correct the formatting of various filter documentation.
See #57840


git-svn-id: https://develop.svn.wordpress.org/trunk@56157 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-07 00:34:26 +00:00
John Blackbourn
82302c4ffb REST API: Correct some filter docblocks.
See #57752


git-svn-id: https://develop.svn.wordpress.org/trunk@56156 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-06 23:21:34 +00:00
Jb Audras
9ad2859721 Twenty Twenty: Fix left margin in Latest Posts & Latest Comments blocks.
This fixes a bug where the `margin-left: auto` property was being overwritten to `margin-left: 0` causing an inconsistency in the alignment of these blocks.

Follow-up to [56034], [56039], [56040].

Props sabernhardt. 
Fixes #58396.




git-svn-id: https://develop.svn.wordpress.org/trunk@56155 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-06 22:00:53 +00:00
Felix Arntz
21490c6ba4 Media: Ensure that the image widget supports loading optimization attributes.
This changeset adds support for loading optimization attributes such as `loading="lazy"` and `fetchpriority="high"` to the image widget. A new context `widget_media_image` is introduced for that purpose.

Props spacedmonkey, thekt12, mukesh27, westonruter.
Fixes #58704.
See #58235.


git-svn-id: https://develop.svn.wordpress.org/trunk@56154 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-06 16:31:02 +00:00
Jb Audras
e9d0712b49 Docs: Use third-person singular verbs in various function descriptions of load.php, as per docblocks standards.
See #57840.



git-svn-id: https://develop.svn.wordpress.org/trunk@56153 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-06 14:15:00 +00:00
Jb Audras
d2993600fe Boostrap/Load: Incorrect condition in wp_check_php_mysql_versions().
This changeset adds a check for the existence of `db.php` at the default path `ABSPATH . 'wp-content/db.php'`, even if `WP_CONTENT_DIR` is defined and `db.php` 
is placed in `WP_CONTENT_DIR`.

Follow-up to [49161].

Props mikeyzm, SergeyBiryukov, hztyfoon, 
Fixes #58201.




git-svn-id: https://develop.svn.wordpress.org/trunk@56152 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-06 13:52:56 +00:00
Jb Audras
c49225f9be Coding Standards: Add missing newline at the end of wp-admin/user.php.
Follow-up to [56150].

See #58194.




git-svn-id: https://develop.svn.wordpress.org/trunk@56151 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-06 12:52:59 +00:00
Jb Audras
b71668fc40 Users: Remove password reset links when the feature is not allowed for a specific user.
This also introduces `wp_is_password_reset_allowed_for_user()` which returns `false` when password reset is not allowed for a specific user. This can be 
filtered by developers using the existing `allow_password_reset` hook.

Props ocean90, cshark, robinwpdeveloper, tahmina1du, kraftbj.
Fixes #58194.




git-svn-id: https://develop.svn.wordpress.org/trunk@56150 602fd350-edb4-49c9-b593-d223f7449a82
2023-07-06 12:45:45 +00:00