Since some locales may differentiate "Posts" generic post type name (works for both posts, pages, and custom post types) and "Posts" when speaking about blogposts, this change aims to contextualize the use of the "Posts" string in the "Users" admin screen. This change reuses the string used for the "Posts" post type registration, to avoid introducing any new string to translate.
Props audrasjb, jdy68, SergeyBiryukov.
Fixes#54712.
Built from https://develop.svn.wordpress.org/trunk@52426
git-svn-id: http://core.svn.wordpress.org/trunk@52018 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This updates the regular expression in the test to retrieve the date of the first, instead of the last, GA release for the recommended MySQL branch, in order to properly track the EOL date.
Additionally, as the currently recommended MySQL 5.7 branch moved from active support to extended support on 2020-10-21, and WordPress core is not fully compatible with MySQL 8.0 at this time, this commit increases the “supported” period from 5 to 8 years to include extended support.
Follow-up to [31291], [35759], [meta11407], [52420].
See #41490.
Built from https://develop.svn.wordpress.org/trunk@52421
git-svn-id: http://core.svn.wordpress.org/trunk@52013 1a063a9b-81f0-0310-95a4-ce76da25c4cd
* MySQL 5.6 has reached EOL (“End of Life”) in February 2021. The recommended minimum is bumped to 5.7 for now.
* MariaDB 10.1 has reached EOL in October 2020. The recommended minimum is bumped to 10.2 for now.
Follow-up to [31291], [35759], [52319], [52358], [meta11407].
Props JavierCasares, SergeyBiryukov.
See #41490, #meta5999.
Built from https://develop.svn.wordpress.org/trunk@52420
git-svn-id: http://core.svn.wordpress.org/trunk@52012 1a063a9b-81f0-0310-95a4-ce76da25c4cd
In WordPress 5.9, when a block theme is being used, the `Appearance → Customize` admin menu item is not present unless a plugin uses the Customizer.
The Customize admin bar node should be shown on the front end if any plugins are using the Customizer, even if the current theme is a block theme.
This commit mirrors a similar check in the admin menu to determine if the Customize link should be displayed.
Follow-up to [52069], [52134], [52158], [52178].
Props pbiron, audrasjb, sabernhardt, costdev.
Fixes#54683.
Built from https://develop.svn.wordpress.org/trunk@52414
git-svn-id: http://core.svn.wordpress.org/trunk@52006 1a063a9b-81f0-0310-95a4-ce76da25c4cd
The `dealerdirect/phpcodesniffer-composer-installer` Composer plugin is used to register external PHPCS standards with PHPCS.
As of Composer 2.2, Composer plugins need to be explicitly allowed to run. This commit adds the necessary configuration for that to prevent Composer asking every single time `composer install` or `composer update` is run.
Reference: [https://blog.packagist.com/composer-2-2/#more-secure-plugin-execution Composer 2.2: More secure plugin execution].
Props jrf, johnbillion.
Fixes#54686.
Built from https://develop.svn.wordpress.org/trunk@52412
git-svn-id: http://core.svn.wordpress.org/trunk@52004 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This ensures that default template area settings are displayed when editing a template in the post/page editor, which previously got lost during backporting for 5.9.
Follow-up to [52232].
Props Mamaduka, costdev, gziolo.
Fixes#54679.
Built from https://develop.svn.wordpress.org/trunk@52409
git-svn-id: http://core.svn.wordpress.org/trunk@52001 1a063a9b-81f0-0310-95a4-ce76da25c4cd
[52232] relocated the Theme Editor menu item from Appearance to Tools for block themes. This commit relocates the Plugin Editor menu item from Plugins to Tools for block themes for a consistent workflow.
Both the Theme Editor and Plugin Editor menu items are renamed to "Theme File Editor" and "Plugin File Editor" respectively. Why? To better identify their purpose, i.e. to directly edit the code in the theme or plugin files. The rename is not limited to only block themes.
Follow-up to [52232].
Props poena, annezazu, audrasjb, clorith, courane01, costdev, dryanpress, desrosj, hellofromTonya, ipstenu, jameskoster, joen, johnbillion, joyously, manfcarlo, marybaum, pbiron, SergeyBiryukov, walbo, youknowriad.
Fixes#54382.
Built from https://develop.svn.wordpress.org/trunk@52406
git-svn-id: http://core.svn.wordpress.org/trunk@51998 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This change introduces the `display_login_language_dropdown` filter which allows to disable the Login screen language dropdown.
Follow-up to [52058].
Props rickcurran, audrasjb, ocean90, hellofromtonya, costdev, johnbillion.
Fixes#54675.
Built from https://develop.svn.wordpress.org/trunk@52404
git-svn-id: http://core.svn.wordpress.org/trunk@51996 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Update packages with these bug fixes from Gutenberg:
Navigation: Remove hardcoded typography units
Handle parsed request
Navigation: Refactor modal padding to be simpler and more flexible
Show notice on save in site editor
Add aria-pressed true/false to Toggle navigation button based on state
Components FontSizePicker: Use incremental sequence of numbers
Custom keys from theme.json: fix kebabCase conversion
Template Part: Fix 'isMissing' condition check
Multi-Entity Saving: Decode HTML entities in item titles
Font sizes: update default values
Query Loop: Add useBlockPreview, fix Query Loop wide alignment
Only add dialog role to navigation when modal is open
Fix navigation appender
Show a UI warning when user does not have permission to update/edit a Navigation block
Block editor: Fix Enter handling for nested blocks
Update: Use subtitle styles for the palette names
Allow publishing a post while not saving changes to non-post entities
Update: Block top level useSetting paths
Fix Site Logo block alignment issues
Editor: when Toggle navigation receives state false, focus
ToolsPanel: Allow items to register when panelId is null
Block Support Panels - Make block support tools panels compatible
Gallery: Fix block registration hook priority
Navigation: Fix page list issues in overlay
Ensure the overlay menu works when inserting navigation block pattern
Restrict Navigation permissions and show UI warning if cannot create
Add block gap support for group blocks
Try cascading nav styles through classnames
Fix: Impossible to edit theme and default colors
Fix: Color editor discards colors with default name
Site Editor: Fix template author avatar check
Template Editing Mode: Fix options dropdown
Avoid undo issues when reset parent blocks for controlled blocks
Add comment-form and comment-list to html5 theme support and fix comment layout
Props hellofromtonya.
See #54487.
Built from https://develop.svn.wordpress.org/trunk@52402
git-svn-id: http://core.svn.wordpress.org/trunk@51994 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Regex changes from [52376] are reverted to restore the original regex patterns. Why? [52376] used an include characters pattern, which was too limiting. It did not account for localized characters, such as `é`, or other valid directory name characters.
The original theme directory regex pattern, i.e. `[^.\/]+(?:\/[^.\/]+)?` excluded the period `.` character. Removing the `.` character resolves the reported issue by allowing matching for `themes/theme-dirname-1.0/` or `themes/<subdirname>/theme-dirname-1.0/`.
As the pattern used an exclude approach, all characters are valid for matching except for `/`. However, not all characters are cross-platform valid for directory names. For example, the characters `/:<>*?"|` are not valid on Windows OS. The pattern now excludes those characters.
The theme's directory (or subdirectory) name pattern matching is now used in `WP_REST_Global_Styles_Controller`, `WP_REST_Templates_Controller`, and `WP_REST_Themes_Controller`.
Follow-up to [51003], [52051], [52275], [52376].
Props costdev, hellofromTonya, spacedmonkey, TimothyBlynJacobs, bijayyadav, kafleg.
Fixes#54596.
Built from https://develop.svn.wordpress.org/trunk@52399
git-svn-id: http://core.svn.wordpress.org/trunk@51991 1a063a9b-81f0-0310-95a4-ce76da25c4cd
When `add_filter( 'wp_is_application_passwords_available', '__return_false' )` exists, HTTPS requirement message is shown even if HTTPS is enabled on the site. This happens because `wp_is_application_passwords_available_for_user()` first invokes `wp_is_application_passwords_available()` which is filterable. The situation could happen if the `'wp_is_application_passwords_available_for_user'` filter returns `false`.
To fix this, the check for HTTPS (or if in a 'local' environment) is moved to a new function called `wp_is_application_passwords_supported()`. Then the return from this function is used as an OR condition for the Application Passwords section and for displaying the HTTPS required message.
Tests are included for both `wp_is_application_passwords_supported()` and `wp_is_application_passwords_available()`.
Follow-up to [51980], [51988].
Props davidbinda, SergeyBiryukov, ocean90, felipeelia, costdev, hellofromTonya.
Fixes#53658.
Built from https://develop.svn.wordpress.org/trunk@52398
git-svn-id: http://core.svn.wordpress.org/trunk@51990 1a063a9b-81f0-0310-95a4-ce76da25c4cd
The `$post_types` and `$area` properties are assigned in the `_build_block_template_result_from_file()` and `_build_block_template_result_from_post()` functions. However, neither property was explicitly declared in the `WP_Block_Template` class.
This commit explicitly declares both properties in the class. Why? (1) To make the code more readable and maintainable; (2) to avoid a `Deprecated: Creation of dynamic property WP_Block_Template::$post_types is deprecated` deprecation when PHP 8.2 is released.
Ref:
* PHP 8.2 Deprecate dynamic properties https://wiki.php.net/rfc/deprecate_dynamic_properties
Follow-up to [52062].
Props jrf.
Fixes#54670.
Built from https://develop.svn.wordpress.org/trunk@52397
git-svn-id: http://core.svn.wordpress.org/trunk@51989 1a063a9b-81f0-0310-95a4-ce76da25c4cd
`wp_list_bookmarks()` arguments include `'link_rel'`, but not `'rel'`. This commit fixes this argument in the test datasets. It also adds an expected `'rel=""'` result check, i.e. instead of only checking for `'noopener'`.
Follow-up to [52395].
Props davidbinda.
Fixes#53839.
Built from https://develop.svn.wordpress.org/trunk@52396
git-svn-id: http://core.svn.wordpress.org/trunk@51988 1a063a9b-81f0-0310-95a4-ce76da25c4cd
When installing a multisite, there is a potential access to a non-existent database table that needs to be skipped to avoid warnings/errors. This fix checks is WordPress is not installing before getting the `'can_compress_scripts'` option.
Props schlessera.
Fixes#54634.
Built from https://develop.svn.wordpress.org/trunk@52395
git-svn-id: http://core.svn.wordpress.org/trunk@51987 1a063a9b-81f0-0310-95a4-ce76da25c4cd
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], and [52375]. It updates the theme's font size presets and fixes an issue with query padding.
To view the full set of changes, visit 623a4d7982...d6cb56cce4.
Props schlessera, williampatton, hellofromtonya, kjellr.
See #54318.
Built from https://develop.svn.wordpress.org/trunk@52392
git-svn-id: http://core.svn.wordpress.org/trunk@51984 1a063a9b-81f0-0310-95a4-ce76da25c4cd
As these tests are intended for the `_add_default_theme_supports()` function rather than `WP_Theme` class methods, the `tests/theme.php` file is a more logical place for them than `tests/theme/wpTheme.php`.
Follow-up to [52369], [52383].
See #54597.
Built from https://develop.svn.wordpress.org/trunk@52386
git-svn-id: http://core.svn.wordpress.org/trunk@51978 1a063a9b-81f0-0310-95a4-ce76da25c4cd
In [50829] infinite scrolling was removed from the Media Library and modal which introduced unintended behavior for featured images where only the selected image shows when opening the library. This change reverts only the logic that caused this and applies a proper fix when opening the library.
Props benitolopez, hellofromTonya, joedolson, peterwilsoncc, circlecube, danielbachhuber, PieWP, sabernhardt, szaqal21, dariak, sergeybiryukov.
Fixes#53765.
Built from https://develop.svn.wordpress.org/trunk@52384
git-svn-id: http://core.svn.wordpress.org/trunk@51976 1a063a9b-81f0-0310-95a4-ce76da25c4cd
By default, block themes should have a few theme supports enabled:
* `post-thumbnails`
* `responsive-embeds`
* `editor-styles`
* `html5` for `comment-form`, `comment-list`, `style`, `script`
* `automatic-feed-links`
They should also load core block assets only when the blocks are rendered. This commit adds the associated tests.
Follow-up to [52369].
Props costdev.
See #54597.
Built from https://develop.svn.wordpress.org/trunk@52383
git-svn-id: http://core.svn.wordpress.org/trunk@51975 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This aims to speed up the tests and minimize unrelated failures by avoiding an unnecessary external HTTP request, while still performing the intended functionality checks.
Update similar helpers in some other tests to use more consistent terminology.
Follow-up to [37907], [46175], [51626].
See #54420, #53363.
Built from https://develop.svn.wordpress.org/trunk@52382
git-svn-id: http://core.svn.wordpress.org/trunk@51974 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Additionally:
* Move the test for `WP_REST_Server::add_active_theme_link_to_index()` to a more logical place.
* Replace `assertEquals()` with `assertSame()` in site icon test to also check the type of the value.
* Use a more consistent pattern for the tests.
Follow-up to [51241], [52080].
Props ignatggeorgiev, desrosj, SergeyBiryukov.
Fixes#53516. See #53363.
Built from https://develop.svn.wordpress.org/trunk@52381
git-svn-id: http://core.svn.wordpress.org/trunk@51973 1a063a9b-81f0-0310-95a4-ce76da25c4cd
As of PHP 8.1, explode() does not permit null as its second argument. This results in warnings being spat out on every page because of a usage of this in wp-includes/block-supports/layout.php.
See #53635.
Props noisysocks.
Built from https://develop.svn.wordpress.org/trunk@52380
git-svn-id: http://core.svn.wordpress.org/trunk@51972 1a063a9b-81f0-0310-95a4-ce76da25c4cd