Includes unit tests to verify the logic for displaying row actions in the Media Library in certain scenarios, e.g. with and without the “Trash” or “Unattached” filter.
Follow-up to [55949].
Props costdev, kebbet, mukesh27, oglekler.
Fixes#57893.
Built from https://develop.svn.wordpress.org/trunk@56072
git-svn-id: http://core.svn.wordpress.org/trunk@55584 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Adds a new optional `$include_hidden` parameter to allow the inclusion of hidden (`.` prefixed) files.
Defaults to false for backward compatibility.
Props yani.iliev, sabernhardt, costdev, rutviksavsani, zunaid321, azaozz.
Fixes#53659.
Built from https://develop.svn.wordpress.org/trunk@56069
git-svn-id: http://core.svn.wordpress.org/trunk@55581 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This changeset adds the `plugins_list` hook, which can be use to filter the list of plugin displayed on WP Admin Plugins screen.
Props nateallen, fischfood, mukesh27, peterwilsoncc, SergeyBiryukov, audrasjb, costdev, ecorica, zunaid321.
Fixes#57278.
Built from https://develop.svn.wordpress.org/trunk@56068
git-svn-id: http://core.svn.wordpress.org/trunk@55580 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This changeset adds "Current time, "Current UTC time" and "Current Server time" under the "Server" section of Site Health debug infos. This provides the
current time, the server time, and allow for comparison if there's some time-related issues.
Props sebastienserre, Clorith, audrasjb, kebbet, robinwpdeveloper, hrrarya, mukesh27, hareesh-pillai, costdev.
Fixes#56378.
Built from https://develop.svn.wordpress.org/trunk@56056
git-svn-id: http://core.svn.wordpress.org/trunk@55568 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Register all core blocks in a new function called `register_core_block_style_handles`. This mirrors the function `wp_default_styles` where all core styles are registered in one place. This improves block registration performance, as it avoids expensive file lookups, like realpath in `register_block_style_handle`. The new function `register_core_block_style_handles` uses `glob` to get all css files in the blocks directory. This glob is cached in a transient to save lookups on subsequent requests. The function `register_block_style_handle` now checks to see if the style handle is already registered before trying to register it again.
Props mukesh27, westonruter, flixos90, joemcgill, spacedmonkey.
Fixes#58528.
Built from https://develop.svn.wordpress.org/trunk@56044
git-svn-id: http://core.svn.wordpress.org/trunk@55556 1a063a9b-81f0-0310-95a4-ce76da25c4cd
`str_contains()` was introduced in PHP 8.0 to perform a case-sensitive check indicating if the string to search in (haystack) contains the given substring (needle).
WordPress core includes a polyfill for `str_contains()` on PHP < 8.0 as of WordPress 5.9.
This commit replaces `false !== strpos( ... )` with `str_contains()` in core files, making the code more readable and consistent, as well as better aligned with modern development practices.
Follow-up to [55988], [56021].
See #58206.
Built from https://develop.svn.wordpress.org/trunk@56031
git-svn-id: http://core.svn.wordpress.org/trunk@55543 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Add a up/down arrow for visual affordance about the purpose of the button link; change button text from "Show details" to "More details".
Props krupajnanda, subrataemfluence, audrasjb, afercia, nrqsnchz, joedolson.
Fixes#44714.
Built from https://develop.svn.wordpress.org/trunk@56027
git-svn-id: http://core.svn.wordpress.org/trunk@55539 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Add a fallback condition with heading and error notice to handle a no JavaScript state for the site editor, comparable to what already exists in the post editor.
Props afercia, joedolson, fencermonir, zebaafiashama, alexstine, rudlinkon.
Fixes#56228.
Built from https://develop.svn.wordpress.org/trunk@56025
git-svn-id: http://core.svn.wordpress.org/trunk@55537 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Accessibly associate field description text with relevant input fields. Add `aria-describedby` and target IDs for each description field. Update privacy text note to better reflect relevancy to specific fields.
Props costdev, joedolson.
Fixes#58613.
Built from https://develop.svn.wordpress.org/trunk@56024
git-svn-id: http://core.svn.wordpress.org/trunk@55536 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Move the visual positioning of the posts search form into it's DOM position. Fixes an accessibility bug where the keyboard focus sequence did not match the visual order. Change the media search form in list view to match the format of other post views. Give search forms a consistent layout on mobile.
Props oglekler, sabernhardt, joedolson.
Fixes#57949.
Built from https://develop.svn.wordpress.org/trunk@56023
git-svn-id: http://core.svn.wordpress.org/trunk@55535 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Ensure that quick edit does not define a publish date if the post status is one of 'draft', 'pending', or 'auto-draft'.
Props uxtremist, SergeyBiryukov, Denis-de-Bernardy, jane, rfischmann, mista-flo, rutviksavsani, oglekler, joedolson.
Fixes#19907.
Built from https://develop.svn.wordpress.org/trunk@56022
git-svn-id: http://core.svn.wordpress.org/trunk@55534 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Add labels; change Enter new/Cancel link to a button; move focus to input when creating new field; move Add Custom Field out of fields table.
Props jane, batmoo, karmatosed, franrosa, sabernhardt, annashopina, oglekler, joedolson.
Fixes#15631.
Built from https://develop.svn.wordpress.org/trunk@56018
git-svn-id: http://core.svn.wordpress.org/trunk@55530 1a063a9b-81f0-0310-95a4-ce76da25c4cd
`str_ends_with()` was introduced in PHP 8.0 to perform a case-sensitive check indicating if the string to search in (haystack) ends with the given substring (needle).
WordPress core includes a polyfill for `str_ends_with()` on PHP < 8.0 as of WordPress 5.9.
Follow-up to [55990].
See #58220.
Built from https://develop.svn.wordpress.org/trunk@56014
git-svn-id: http://core.svn.wordpress.org/trunk@55526 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This changeset improves `update.js` by adding `is-enqueued` class to enqueued plugin updates to prevent users from asking for several updates for the same
plugin at the same time, which previously resulted to …an interesting experience.
Props bitnissen, swissspidy, MarcGuay, xkon, afercia, swissspidy, bookdude13, simonemanfre, vasilism, costdev, zunaid321.
Fixes#40966.
Built from https://develop.svn.wordpress.org/trunk@56009
git-svn-id: http://core.svn.wordpress.org/trunk@55521 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Add a show/hide toggle for new passwords in initial user creation and database access during install and setup process using the same model as on user profiles. Add a new password toggle script. Change setup config table to two columns, matching the install table layout.
Props xmarcos, matt, markjaquith, nazgul, akbigdog, intoxination, rob1n, MichaelH, empireoflight, rmccue, markoheijnen, r0uter, amansurov, bi0xid, DrewAPicture, Narthur, wpnook, markparnell, costdev, clorith, ryokuhi, sabernhardt, bgoewert, ironprogrammer, adeltahri, joedolson, mukesh27, audrasjb, sergeybiryukov.
Fixes#3534.
Built from https://develop.svn.wordpress.org/trunk@56008
git-svn-id: http://core.svn.wordpress.org/trunk@55520 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Replace use of `list` to parse array keys into variables. `list` throws errors if the keys don't exist, and many extenders will not define the new array keys. The code path already falls back effectively for empty values.
Also add translator comments to screen reader hidden text, fix a docblock, and fix an HTML error.
Follow up to [r55971].
Props kebbet, chouby, joedolson.
Fixes#32170.
Built from https://develop.svn.wordpress.org/trunk@56004
git-svn-id: http://core.svn.wordpress.org/trunk@55516 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Since the `$auto_upgrade_notice` has been added to the `update-core.php` table listing if an `$upgrade_notice` is present by virtue of the `readme.txt`
containing data in the `== Upgrade Notice ==` section, this text will appear in between the compatibility information and the auto update information.
This changeset provides a more consistent appearance in the interface.
Props afragen, costdev, zunaid321.
Fixes#57939.
Built from https://develop.svn.wordpress.org/trunk@56001
git-svn-id: http://core.svn.wordpress.org/trunk@55513 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This avoids fatal errors on PHP < 8.0 if the file is included directly outside of WordPress core, e.g. by HyperDB.
While WordPress core does include polyfills for these functions, they are not directly loaded in the `wpdb` class.
Follow-up to [54384], [55157], [55158], [55988], [55990].
Props dd32, ryelle, joedolson.
See #58206.
Built from https://develop.svn.wordpress.org/trunk@55994
git-svn-id: http://core.svn.wordpress.org/trunk@55506 1a063a9b-81f0-0310-95a4-ce76da25c4cd
`str_starts_with()` and `str_ends_with()` were introduced in PHP 8.0 to perform a case-sensitive check indicating if the string to search in (haystack) begins or ends with the given substring (needle).
WordPress core includes a polyfill for these functions on PHP < 8.0 as of WordPress 5.9.
This commit uses `str_starts_with()` and `str_ends_with()` in core files where appropriate:
* `$needle === substr( $string, 0, $length )`, where `$length` is the length of `$needle`, is replaced with `str_starts_with( $haystack, $needle )`.
* `$needle === substr( $string, $offset )`, where `$offset` is negative and the absolute value of `$offset` is the length of `$needle`, is replaced with `str_ends_with( $haystack, $needle )`.
This aims to make the code more readable and consistent, as well as better aligned with modern development practices.
Follow-up to [52039], [52040], [52326], [55703], [55710], [55987], [55988].
Props Soean, spacedmonkey, Clorith, ocean90, azaozz, sabernhardt, SergeyBiryukov.
Fixes#58220.
Built from https://develop.svn.wordpress.org/trunk@55990
git-svn-id: http://core.svn.wordpress.org/trunk@55502 1a063a9b-81f0-0310-95a4-ce76da25c4cd
`str_contains()` was introduced in PHP 8.0 to perform a case-sensitive check indicating if the string to search in (haystack) contains the given substring (needle).
WordPress core includes a polyfill for `str_contains()` on PHP < 8.0 as of WordPress 5.9.
This commit replaces `false !== strpos( ... )` with `str_contains()` in core files, making the code more readable and consistent, as well as better aligned with modern development practices.
Follow-up to [52039], [52040], [52326], [55703], [55710], [55987].
Props Soean, spacedmonkey, costdev, dingo_d, azaozz, mikeschroder, flixos90, peterwilsoncc, SergeyBiryukov.
Fixes#58206.
Built from https://develop.svn.wordpress.org/trunk@55988
git-svn-id: http://core.svn.wordpress.org/trunk@55500 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This changeset improve Dashboard screen options by stacking them vertically on small screens.
Props dhrumilk, prashantbhivsane, marybaum, dhruvishah2203, ababir, mukesh27, chiragrathod103, oglekler, tb1909, jahidcse, audrasjb.
Fixes#57977.
Built from https://develop.svn.wordpress.org/trunk@55984
git-svn-id: http://core.svn.wordpress.org/trunk@55496 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Hide the password for the "Post via e-mail" settings in writing options. Use the same password hiding mechanisms in use elsewhere in core.
Props mastrup, denis-de-bernardy, ryan, brookedot, wojtek.szkutnik, dd32, sabreuse, sergeybiryukov, costdev, peterwilsoncc, zgrkaralar, clorith, renyot, sabernhardt, boniu91, ironprogrammer, bgoewert.
Fixes#9883.
Built from https://develop.svn.wordpress.org/trunk@55974
git-svn-id: http://core.svn.wordpress.org/trunk@55486 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Implement `aria-sort` and change icon states to indicate current sort for list tables. Allow screen reader users to get context about the current sort and allow sighted users to know how the table is currently sorted.
Props afercia, rianrietveld, joedolson, alexstine, johnjamesjacoby.
Fixes#32170.
Built from https://develop.svn.wordpress.org/trunk@55971
git-svn-id: http://core.svn.wordpress.org/trunk@55483 1a063a9b-81f0-0310-95a4-ce76da25c4cd
As placeholders may introduce confusion about whether the example is the input's predefined value or not, this changeset moves the "Just another WordPress
site" historic tagline as an example quoted in the field's description.
Props Cybr, audrasjb, sabernhardt, pavanpatil1, tb1909.
Fixes#57675.
Built from https://develop.svn.wordpress.org/trunk@55969
git-svn-id: http://core.svn.wordpress.org/trunk@55481 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Change the `label` for `.check-column` inside list tables to a block filling the entire cell. Improves accessibility by increasing the target area for the control.
Props mitchoyoshitaka, lessbloat, sabernhardt, ogleker, tacoverdo, joostdevalk, karmatosed.
Fixes#21516.
Built from https://develop.svn.wordpress.org/trunk@55954
git-svn-id: http://core.svn.wordpress.org/trunk@55466 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Due to partially duplicated logic for displaying row actions in the Media Library with and without the “Unattached” filter, the “Copy URL” and “Download file” row actions were unintentionally missing with the filter applied.
This commit aims to simplify the logic and bring more consistency to the code.
Includes displaying the “Download file” row action even when the “Trash” filter is applied, giving the user one more chance to download the media file before they delete it.
Follow-up to [8901], [13100], [16227], [16229], [52842], [55198], [55221].
Props kebbet, costdev, pbiron, oglekler, SergeyBiryukov.
Fixes#57890, #57893.
Built from https://develop.svn.wordpress.org/trunk@55949
git-svn-id: http://core.svn.wordpress.org/trunk@55461 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Redirect users visiting the `wp-admin/media.php` file to the media library, `wp-admin/upload.php`. An user facing warning is displayed when the media library is reached via a deprecated link.
Follow up to [55647].
Props jorbin, audrasjb, azaozz, NekoJonez, kebbet, costdev.
Fixes#57612.
Built from https://develop.svn.wordpress.org/trunk@55943
git-svn-id: http://core.svn.wordpress.org/trunk@55455 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Adds a check to the start of `copy_dir()` that the destination directory exists and attempts to create it if it does not.
An error is returned if the directory can not be created, either due to a permissions error or the parent directory not existing.
Props caraffande, costdev, zunaid321.
Fixes#41855.
Built from https://develop.svn.wordpress.org/trunk@55938
git-svn-id: http://core.svn.wordpress.org/trunk@55450 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Change the log in link that appears after completing installation so that it does not use the button styling. Links should look like links.
Props xavortm, menakas, afercia, rianrietveld, johnbillion, drw158, joedolson.
Fixes#40470.
Built from https://develop.svn.wordpress.org/trunk@55933
git-svn-id: http://core.svn.wordpress.org/trunk@55445 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Significant restructure of the admin image editor interface, but no new functionality. Reorganize editing buttons into a common region at the top of the editor. Move image rotation tools into a pop-out menu. Add 180 degree rotation option. Add scale button to control group. Move sidebar tools next to the editing canvas to improve visual proximity between action and result. Enlarge editing canvas and crop handles. Separate activating crop functions from applying crop. Add numeric inputs for crop & scale values.
A long term goal is to move undo/redo and cancel/save into the modal title bar, but that is not feasible without significant updates to the modal framework.
Props afercia, karmatosed, nrqsnchz, antpb, chaion07, costdev, peterwilsoncc, antpb, sabernhardt, prashantbhivsane, joedolson.
Fixes#50523.
Built from https://develop.svn.wordpress.org/trunk@55919
git-svn-id: http://core.svn.wordpress.org/trunk@55431 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This changeset adds a `pre` class to "Downloading update from…" user facing strings located in `Core_Upgrader`, `Language_Pack_Upgrader`, `Plugin_Upgrader` and
`Theme_Upgrader` classes.
Follow-up to [11295].
Props sumitsingh, costdev.
Fixes#58477.
Built from https://develop.svn.wordpress.org/trunk@55899
git-svn-id: http://core.svn.wordpress.org/trunk@55411 1a063a9b-81f0-0310-95a4-ce76da25c4cd