45284 Commits

Author SHA1 Message Date
Jb Audras
bde79ae542 Upgrade/Install: Typo correction in a Core_Upgrader class inline comment.
Follow-up to [45046].

Props kebbet.
Fixes #54821.


git-svn-id: https://develop.svn.wordpress.org/trunk@52576 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-14 15:12:32 +00:00
Jb Audras
10817e6a20 XML-RPC: Fix typos in some XMLRPC related docblocks.
Props kebbet, shreyasikhar26.
Fixes #54820.


git-svn-id: https://develop.svn.wordpress.org/trunk@52575 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-14 14:43:38 +00:00
Jb Audras
8631739e5d Media: Add a missing / in post thumbnail lazy loading regex.
This change avoids a warning thrown by a missing slash in a post thumbnail lazyload related regular expression.

Follow-up to [52065].

Props SierraTR, audrasjb, costdev.
Fixes #54815.


git-svn-id: https://develop.svn.wordpress.org/trunk@52574 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-14 11:00:35 +00:00
Jb Audras
ea1fe31f02 Media: Typo correction in wp_image_maybe_exif_rotate docblock.
Follow-up to [46202].

Props mitogh.
Fixes #54816.


git-svn-id: https://develop.svn.wordpress.org/trunk@52573 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-13 19:12:42 +00:00
Sergey Biryukov
7f2ddd0ae6 Docs: Correct description for two HTTP API functions:
* `wp_remote_retrieve_response_code()`
* `wp_remote_retrieve_response_message()`

If incorrect parameter value is given, these functions return an empty string, not an empty array.

Follow-up to [8516].

Props chesio, johnbillion.
Fixes #54796.

git-svn-id: https://develop.svn.wordpress.org/trunk@52572 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-13 01:03:01 +00:00
Jb Audras
b38c2fb5e9 Administration: Fix an erroneous translators comment after changeset [52569].
This change also fixes the indentation of the translators comment.

Fixes #54798.


git-svn-id: https://develop.svn.wordpress.org/trunk@52571 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-12 23:43:56 +00:00
Jb Audras
aaf689a48f Tests: Trac ticket number correction after changeset [52569].
Follow-up to [52569].

See #54798.


git-svn-id: https://develop.svn.wordpress.org/trunk@52570 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-12 23:29:03 +00:00
Jb Audras
3685f95eb6 Administration: Ensure an integer is used for menu priority in add_menu_page().
This change adds a verification of the `$position` parameter in `add_menu_page()` to ensure an integer is used. If not, the function informs developers of the wrong parameter type via a `_doing_it_wrong` message. This brings consistency with a similar check used in `add_submenu_page()`.

This change also typecasts any floating number to string to ensure that in case a float value was passed, at least it doesn't override existing menus.

Follow-up to [46570].

Props kirtan95.
Fixes #54798. See #48249.


git-svn-id: https://develop.svn.wordpress.org/trunk@52569 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-12 23:23:41 +00:00
Sergey Biryukov
0b010f16c9 Coding Standards: Remove an extra variable in get_author_posts_url().
This fixes a `Variable "$auth_ID" is not in valid snake_case format` WPCS warning by using the existing `$author_id` variable, and brings consistency with a similar fragment in `get_author_feed_link()`.

Follow-up to [979], [5087], [6364], [6365].

See #54728.

git-svn-id: https://develop.svn.wordpress.org/trunk@52568 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-12 11:15:15 +00:00
Kelly Choyce-Dwan
7bec2e6c5a Help/About: Update the About section for 5.9.
Use the correct Field Guide link. Update the SVGs used on Freedoms and Privacy. Add more spacing between sections on the About page, fixed spacing between rows on Freedoms page.

Props critterverse, audrasjb, versusbassz.
See #54270.



git-svn-id: https://develop.svn.wordpress.org/trunk@52563 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-11 18:34:34 +00:00
Kelly Choyce-Dwan
1c54371c45 Administration: Update design of the Dashboard welcome panel.
Tone down the brightness of the dashboard panel by using a white background behind the main text, and use the highlight color from each color scheme for the main background. This also introduces a `$scheme-name` SCSS variable to allow overrides for specific color schemes.

Props critterverse, sabernhardt, joedolson, audrasjb.
See #54489.



git-svn-id: https://develop.svn.wordpress.org/trunk@52562 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-11 18:25:38 +00:00
David Baumwald
f44030b140 Script Loader: Fix a variable typo in wp_enqueue_block_style.
In `wp_enqueue_block_style` when `rtl` versions of CSS files are detected, `wp_style_add_data` is called to add the metadata to the registered sheet.  However, the stylesheet `handle` argument is misspelled as `hanle`.  This change corrects the argument name.

Props omaeyusuke.
Fixes #54786.

git-svn-id: https://develop.svn.wordpress.org/trunk@52558 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-11 17:14:54 +00:00
Tonya Mork
1e7d559444 Editor: Fix enqueueing additional styles in wp_enqueue_block_style() to print only when blocks render.
In a block theme, additional block styles registered using the `wp_enqueue_block_style` function should only get printed when the block exists on a page. However, they currently always get rendered.

This commit is a backport from Gutenberg that fixes the issue by printing the styles when a block renders.

Follow-up to [52069].

Props poena, aristath, Mamaduka.
Fixes #54787.

git-svn-id: https://develop.svn.wordpress.org/trunk@52556 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-11 15:57:09 +00:00
Jeff Ong
0c516fc131 Twenty Twenty-Two: Sync updates from GitHub for RC 2.
This commit syncs changes for the default theme from its active development repository to core.

This is a follow up to [52081], [52107], [52164], [52222], [52283], [52335], [52375], [52392], and [52430]. It includes fixes to the theme's spacing and adds a search template.

To view the full set of changes, visit 8564fd281f...f0346e1ad2.

Props richtabor, kjellr, danieldudzic, scruffian.


git-svn-id: https://develop.svn.wordpress.org/trunk@52555 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-11 15:56:25 +00:00
Tonya Mork
d085349cf5 Site Editor: Fix typo in home template translatable description.
The home template's description should be: "Displays as the site's home page, or as the Posts page when a static home page isn't set." This commit fixes the typo changing "it" to "isn't".

Follow-up to [52331].

Props kharisblank, talldanwp.
Fixes #54787.

git-svn-id: https://develop.svn.wordpress.org/trunk@52554 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-11 15:16:37 +00:00
Sergey Biryukov
6dc3ff47d2 Database: Add missing AS after INNER JOIN in some queries.
While `AS` is an optional keyword in SQL, it is commonly considered best practice to include it for better readability and compatibility. This also makes the queries more consistent with other queries using aliases in core.

Follow-up to [6359], [30238].

Props costdev, domainsupport.
Fixes #54769.

git-svn-id: https://develop.svn.wordpress.org/trunk@52553 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-11 04:10:03 +00:00
Robert Anderson
5820220945 Update packages to include these bug fixes from Gutenberg:
- [Block Library - Query Pagination Next]: Hide block if custom query has no results
- [WP 5.9] Fix: HTML tags like inline images in nav links break submenu layout
- Check for nextpage to display page links for paginated posts
- Navigation: Set the default for --navigation-layout-align to "flex-start" when using vertical orientation
- [Block Library - Query Loop]: Use gap for the grid view
- Update page list flex variables to match navigation.
- Site logo: Fix range control on landscape logo
- Restore canvas padding for classic themes
- RichText: Fix dead key input on Windows
- Fix: Impossible to clear colors if color palettes are removed.
- Gallery block: pass any custom attributes through the gallery v2 migration script
- Reduce specificity of legacy font sizes defined by core
- Update: Improve escaping on the search block

See #54487.
Props isabel_brison.



git-svn-id: https://develop.svn.wordpress.org/trunk@52551 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-11 03:11:06 +00:00
Jorge Costa
2aff2a60fc Fix: Update some default presets in use by default themes to the new format.
Themes that use the same preset slugs as WordPress uses need to be updated.
From the devnote https://make.wordpress.org/core/2022/01/08/updates-for-settings-styles-and-theme-json/
The CSS for some of the presets defined by WordPress (font sizes, colors, and gradients) was loaded twice for most themes in WordPress 5.8: in the block-library stylesheet plus in the global stylesheet. Additionally, there were slight differences in the CSS in both places.
In WordPress 5.9 those were consolidated into a single place, the global stylesheet whose name is global-styles-inline-css that is now loaded for all themes in the front-end.
For themes to override the default values they can use the theme.json and provide the same slug. Themes that do not use a theme.json can still override the default values by enqueuing some CSS that sets the corresponding CSS Custom Property. This commit does the second for the twenty twenty theme.

Props oandregal.
Fixes #54782.

git-svn-id: https://develop.svn.wordpress.org/trunk@52549 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-10 18:27:45 +00:00
Jorge Costa
16e0165cf0 Fix: WordPress default presets aren't loaded for all themes.
The default preset styles of WordPress (font sizes, colors, gradients) are now provided via the global stylesheet to avoid duplication of styles. This stylesheet can be found in the front-end with the name global-styles-inline-css.
The default presets are important to support old content that may use them and also patterns, that can use cross-theme styles.

Props oandregal.
Fixes #54781.

git-svn-id: https://develop.svn.wordpress.org/trunk@52547 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-10 17:27:46 +00:00
David Baumwald
df3f14819c Build/Test Tools: Re-enable E2E tests for the 5.8 branch.
After the 5.9 branch was created, [52449] updated the workflow for testing old branches to include 5.9.  However, the E2E tests `-branch` condition was updated to 5.9 instead of adding an additional branch condition for 5.9.  This commit re-enables the E2E tests for 5.8.

Props desrosj, hellofromTonya.
Fixes #54749.

git-svn-id: https://develop.svn.wordpress.org/trunk@52546 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-10 16:43:54 +00:00
Jb Audras
07fcd416b8 Help/About: Correction in "Managing Themes" HelpHub Docs link.
This change updates the HelpHub Documentation link to "Managing Themes" to make it more consistent with other Help tabs.

Props SergeyBiryukov, jdy68.
Fixes #54707.


git-svn-id: https://develop.svn.wordpress.org/trunk@52545 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-10 08:48:37 +00:00
Sergey Biryukov
42b4e39c6d Coding Standards: Correct alignment in get_block_editor_settings().
This fixes an `Array double arrow not aligned correctly` WPCS warning.

Follow-up to [52054].

See #54728.

git-svn-id: https://develop.svn.wordpress.org/trunk@52544 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-10 01:54:24 +00:00
Jb Audras
52cc52a8f4 Help/About: Change the HTML title of Themes Screen and add related HelpHub Docs link.
This change replaces the title of the Appearance Themes Screen to make it consistent with the main heading of the screen and with other Admin screens. It also adds a link to the related HelpHub Documentation in the Help tab of the screen.

Props jdy68.
Fixes #54707.


git-svn-id: https://develop.svn.wordpress.org/trunk@52543 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-09 23:12:06 +00:00
Sergey Biryukov
34edb06d59 Coding Standards: Use strict comparison in wp-admin/themes.php.
Follow-up to [15646], [30697].

See #54728.

git-svn-id: https://develop.svn.wordpress.org/trunk@52540 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-08 01:20:13 +00:00
David Baumwald
6ef47e555f Upgrade/Install: Fix parameter count in error call when an automatic core upgrade fails.
During automatic core upgrades, if installation results in a `WP_Error`, the `error` method is called on the skin with the details.  However, in this case, two parameters are passed to `$skin->error`, but only one is accepted.  This change passes only the running `WP_Error` instance as the sole parameter to `$skin->error`.

Also, this change adds an additional error to `$upgrade_result` before finally being passed to `$skin->error`, indicating that the installation failed.  This adds additional context to the failure.

Props desrosj, sainthkh, devutpol, SergeyBiryukov.
Fixes #53284.

git-svn-id: https://develop.svn.wordpress.org/trunk@52539 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-07 17:53:27 +00:00
Sergey Biryukov
25073cf976 Coding Standards: Use strict comparison in wp-admin/revision.php.
Follow-up to [7913], [12751].

See #54728.

git-svn-id: https://develop.svn.wordpress.org/trunk@52538 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-07 16:45:24 +00:00
Jb Audras
d831c042d6 Taxonomy: Typo correction in context used for the navigation link block title.
This change fixes a wrong translation context on the navigation link block title.

Follow-up to [50527].

Props Chouby.
Fixes #54566.


git-svn-id: https://develop.svn.wordpress.org/trunk@52537 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-07 11:19:08 +00:00
Jb Audras
482936752a Tests: Update qUnit test fixtures after [52535].
See #54745.


git-svn-id: https://develop.svn.wordpress.org/trunk@52536 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-06 23:23:23 +00:00
Jb Audras
d1ef2e431f REST API: Typo correction in a link description object.
This change fixes a wrong punctuation in a link description object of the menu items controller endpoint.

Props la-geek, audrasjb, tobifjellner, hellofromtonya.
Fixes #54745.


git-svn-id: https://develop.svn.wordpress.org/trunk@52535 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-06 22:57:06 +00:00
Sergey Biryukov
b9bb489d1d Coding Standards: Use strict comparison in wp-admin/plugin-install.php.
Follow-up to [11366].

See #54728.

git-svn-id: https://develop.svn.wordpress.org/trunk@52534 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-06 21:17:39 +00:00
Jonathan Desrosiers
6223e0cf1e Formatting: Correctly encode ASCII characters in post slugs.
Props zieladam, whyisjake, xknown, peterwilsoncc, desrosj, iandunn.

git-svn-id: https://develop.svn.wordpress.org/trunk@52457 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-06 17:08:18 +00:00
Jonathan Desrosiers
bc34e6fb13 Upgrade/Install: Avoid using unserialize() unnecessarily.
Props vortfu, xknown, dd32.

git-svn-id: https://develop.svn.wordpress.org/trunk@52456 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-06 17:04:51 +00:00
Jonathan Desrosiers
8dd5aec97f Query: Improve sanitization within WP_Meta_Query.
Props vortfu, xknown, dd32.

git-svn-id: https://develop.svn.wordpress.org/trunk@52455 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-06 17:03:14 +00:00
Jonathan Desrosiers
e0ff6d86f4 Query: Improve sanitization within WP_Tax_Query.
Props dd32, xknown, peterwilsoncc, ehtis.

git-svn-id: https://develop.svn.wordpress.org/trunk@52454 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-06 17:01:11 +00:00
Jb Audras
1ae653ef36 Help/About: Change the Learn WP link in the about page.
The workshops page doesn't specifically show 5.9 content at this stage (and likely won't until much later), so it needs to be changed to learn.wordpress.org homepage.

Props hlashbrooke, audrasjb, davidbaumwald.
Fixes #54755.


git-svn-id: https://develop.svn.wordpress.org/trunk@52453 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-06 09:16:48 +00:00
Jb Audras
0c9d7c645c Help/About: Correction on the documentation link about adding new themes.
In the Themes Screen Help Tab, the "Documentation on Adding New Themes" link previously targeted the "Using Themes" HelpHub post whereas it had to target the "Install Themes" section of "Appearance Themes Screen" HelpHub post, which is more relevant.

Props jdy68.
Fixes #54709.


git-svn-id: https://develop.svn.wordpress.org/trunk@52452 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-05 22:13:43 +00:00
Sergey Biryukov
0cd255c856 Upgrade/Install: Make first comment URLs translatable.
This allows translators to localize the `https://wordpress.org/` and `https://gravatar.com/` URLs in the first comment on a new installation.

Follow-up to [2409], [37888], [37921].

Props kebbet, desrosj.
Fixes #54535.

git-svn-id: https://develop.svn.wordpress.org/trunk@52451 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-05 21:05:12 +00:00
David Baumwald
580e57a6e0 Login and Registration: Remove aria-expanded from "Generate Password" button.
During password resets, the 'Generate Password" button has a `aria-expanded="true"` attribute, but the button itself does not expand or collapse anything.  This change adds a `skip-aria-expanded` class to the button which is referenced in JavaScript to skip updating the `aria-expanded` attribute on the button itself when clicked.  

This change also resets the `aria-expanded` attribute to `false` for the parent form after it's submitted.

Props alexstine, johnjamesjacoby, sabernhardt.
Fixes #54538.

git-svn-id: https://develop.svn.wordpress.org/trunk@52450 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-05 17:35:44 +00:00
Tonya Mork
6ca73cb648 Build/Test Tools: Add the 5.9 branch to the workflow for testing branches.
git-svn-id: https://develop.svn.wordpress.org/trunk@52449 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-04 21:29:57 +00:00
Sergey Biryukov
1ba5187119 Trunk is now 6.0-alpha.
git-svn-id: https://develop.svn.wordpress.org/trunk@52448 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-04 20:52:38 +00:00
Sergey Biryukov
96713b9292 Post WordPress 5.9 RC1 version bump.
git-svn-id: https://develop.svn.wordpress.org/trunk@52446 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-04 20:39:55 +00:00
Sergey Biryukov
5d03c091fc WordPress 5.9 RC1.
git-svn-id: https://develop.svn.wordpress.org/trunk@52445 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-04 20:13:33 +00:00
Tonya Mork
c6e3bf9c9f Help/About: Use "refactoring" noun form in WordPress 5.9 About Page.
Follow-up to [52438].

Props tobifjellner, costdev, marybaum.
See #54270.

git-svn-id: https://develop.svn.wordpress.org/trunk@52444 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-04 19:48:21 +00:00
Kelly Choyce-Dwan
35fe153695 Administration: Add missing texture image for Welcome panel & About page.
See #54489, #54270.



git-svn-id: https://develop.svn.wordpress.org/trunk@52443 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-04 19:16:03 +00:00
Kelly Choyce-Dwan
e6a82a7561 Administration: Refresh the Dashboard Welcome panel.
With its last major update in 3.5, the welcome panel was feeling stale. This bright new design showcases links to recent features, including patterns, the site editor, and styles, depending on whether you have a block theme active.

Props jameskoster, desrosj, noisysocks, critterverse, karmatosed, hellofromtonya, smit08, melchoyce, poena, audrasjb, webcommsat, marybaum.
See #54489.



git-svn-id: https://develop.svn.wordpress.org/trunk@52442 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-04 19:11:24 +00:00
David Baumwald
7009488561 HTTP API: Improve docs for wp_remote_retrieve_header function return value.
This change updates the `@return` docs for `wp_remote_retrieve_header` to specify that an array can also be returned if the requested header key has multiple values.

Props robtarr, johnjamesjacoby, felipeelia, hellofromTonya, costdev.
Fixes #51736.

git-svn-id: https://develop.svn.wordpress.org/trunk@52441 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-04 18:52:43 +00:00
Tonya Mork
7d4b63b317 Coding Standard: Remove empty space at end of inline comment in _add_default_theme_supports().
Follow-up to [52439].

See #54731.

git-svn-id: https://develop.svn.wordpress.org/trunk@52440 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-04 18:47:42 +00:00
Tonya Mork
ba7d3a52b1 Themes: Make block themes support HTML5 by default.
For block themes, [52369] added HTML5 support for `'comment-list'`, `'comment-form'`, `'style'`, and `'script'`. However, when sites upgrade to 5.9 with non-block content such as a gallery and caption, the markup was not HTML5. 

This commit adds full HTML5 theme feature support for block themes. Non-block content such as a `[gallery]` and `[caption]` shortcodes will natively be in HMTL5 markup without block themes needing to specifically add `add_theme_support( 'html5, .. )` to the theme. 

Follow-up to [24417], [27302], [34261], [52369], [52383], [52386].

Props @joyously, costdev, hellofromTonya, audrasjb, Mamaduka, ocean90.
Fixes #54731. See #54597.

git-svn-id: https://develop.svn.wordpress.org/trunk@52439 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-04 18:38:52 +00:00
Kelly Choyce-Dwan
e1e9bd5657 Help/About: WordPress 5.9 About Page.
Introducing the new About page for 5.9.

Props dansoschin, critterverse, webcommsat, marybaum, nalininonstopnewsuk, sabernhardt, costdev, chanthaboune, cbringmann, mkaz, davidbaumwald, ryelle, melchoyce, annezazu, paaljoachim, audrasjb, hellofromtonya, walbo, tobifjellner, mitogh



git-svn-id: https://develop.svn.wordpress.org/trunk@52438 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-04 18:33:42 +00:00
Jb Audras
107050f7a3 Embeds: Fix oEmbed host script enqueueing on block-based themes.
This change fixes oEmbed host script enqueueing on front-end when using block themes.

It deprecates `wp_oembed_add_host_js` in favor of `wp_maybe_enqueue_oembed_host_js`. The action is still triggered in `default-filters.php` to ensure backward compatibility for websites that are removing the action. There is now a `has_action()` check in `wp_maybe_enqueue_oembed_host_js()` to see if `wp_oembed_add_host_js()` has not been unhooked from running at the `wp_head` action.

Follow-up to [52132], [52151], [52153], [52325].

Props swissspidy, westonruter, flixos90, kafleg.
Fixes #44632.


git-svn-id: https://develop.svn.wordpress.org/trunk@52437 602fd350-edb4-49c9-b593-d223f7449a82
2022-01-04 15:22:40 +00:00