Though `add_action()` and `add_filter()` are functionally equivalent internally, for proper semantics the former should be used on actions and the latter on filters.
Follow-up to [37920], [38046], [53266].
Props apermo.
Fixes#64828.
Built from https://develop.svn.wordpress.org/trunk@61866
git-svn-id: http://core.svn.wordpress.org/trunk@61153 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This changeset clarifies the error message displayed when the current user tries to change their role to one that does not allow managing other users.
Props dpknauss, audrasjb, huzaifaalmesbah, noruzzaman, r1k0.
Fixes#64690.
Built from https://develop.svn.wordpress.org/trunk@61854
git-svn-id: http://core.svn.wordpress.org/trunk@61141 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This changeset introduce a new `wp_get_image_alttext()` function that extracts Image Alt text metadata from image IPTC metadata.
Props jhmonroe, rishabhwpn, adamsilverstein, sajjad67, ozgursar, joedolson, audrasjb, huzaifaalmesbah, sabernhardt, valentingrenier, louischan, penelopeadrian, mathiaspeguet.
Fixes#63895.
Built from https://develop.svn.wordpress.org/trunk@61841
git-svn-id: http://core.svn.wordpress.org/trunk@61128 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This reverts the real time collaboration option name back to `wp_enable_real_time_collaboration` to avoid the need to turn on a checkbox in order to turn off the feature. This is to reduce the cognitive load on both users and developers of an on is off paradigm.
To ensure Real Time Collaboration is enabled prior to the upgrade routine running on multi-site installs, the option default is filtered on the `default_option_wp_enable_real_time_collaboration` hook to enable the option by default.
Developed in: https://github.com/WordPress/wordpress-develop/pull/11161
Follow up to r61828.
Props peterwilsoncc, czarate, sergeybiryukov.
Fixes#64622.
Built from https://develop.svn.wordpress.org/trunk@61833
git-svn-id: http://core.svn.wordpress.org/trunk@61120 1a063a9b-81f0-0310-95a4-ce76da25c4cd
The background behind theme actions for the active theme was still visible when no actions were available, such as with a disabled customizer. Removing the background on this container improves the design of the active theme card by simplifying the layout and prevents the appearance of an error if no actions are available.
Remove background and inset box shadow for the `.theme.active .theme-actions` container on the active theme.
Props awetz583, huzaifaalmesbah, noruzzaman, shailu25, joedolson.
Fixes#64720.
Built from https://develop.svn.wordpress.org/trunk@61831
git-svn-id: http://core.svn.wordpress.org/trunk@61118 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Connector API keys were visible in plain text on `wp-admin/options.php`
because it queries the database directly, bypassing the `get_option()`
filter that normally masks these values.
This adds masking for options matching the `connectors_*_api_key` pattern
using the existing `_wp_connectors_mask_api_key()` function, and disables
editing from this screen.
Props jorgefilipecosta, gziolo, ocean90.
Fixes#64793.
Built from https://develop.svn.wordpress.org/trunk@61829
git-svn-id: http://core.svn.wordpress.org/trunk@61116 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Set the `/blog` prefix to place the `/` correctly in RTL languages. Adjust the layout to prevent awkward wrapping in all languages on smaller viewports.
Props sabernhardt, rachid84, johnbillion, SergeyBiryukov, costdev, joedolson, afercia, ryokuhi, oglekler, sirlouen, audrasjb, huzaifaalmesbah.
Fixes#58722. See #47755.
Built from https://develop.svn.wordpress.org/trunk@61826
git-svn-id: http://core.svn.wordpress.org/trunk@61113 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Changes the Connectors screen URL from a query parameter page to a direct file, following the Settings menu naming convention used by other settings pages (`options-general.php`, `options-writing.php`, etc.).
* Adds `src/wp-admin/options-connectors.php` as a direct admin screen file.
* Adds a static submenu entry in `menu.php` at position 12 (after General).
* Removes `_wp_connectors_add_settings_menu_item()` and its `admin_menu` hook from `connectors.php`.
* Updates the `script_module_data` filter from `connectors-wp-admin` to `options-connectors-wp-admin`.
Synced from https://github.com/WordPress/gutenberg/pull/76142.
Developed in https://github.com/WordPress/wordpress-develop/pull/11157.
Follow-up to [61749], [61824].
See #64730.
Props jorgefilipecosta, gziolo.
Fixes#64790.
Built from https://develop.svn.wordpress.org/trunk@61825
git-svn-id: http://core.svn.wordpress.org/trunk@61112 1a063a9b-81f0-0310-95a4-ce76da25c4cd
* Refactor how CodeMirror is initialized so that the full settings are provided up-front. This avoids the linting from being applied twice at initialization, the first time with an incorrect configuration.
* Add initial TypeScript configuration for core with `npm run typecheck:js`.
* Add comprehensive types for code editor files: `code-editor.js`, `javascript-lint.js`, and `htmlhint-kses.js`.
* Move code editor scripts from `src/js/_enqueues/vendor/codemirror/` to `src/js/_enqueues/lib/codemirror/`. The CodeMirror library is sourced from the npm package as of r61539.
* Remove (deprecated) `esprima.js` from being committed to SVN since in r61539 it was switched to using the npm package as its source.
* Move `fakejshint.js` to `src/js/_enqueues/deprecated`.
Developed in https://github.com/WordPress/wordpress-develop/pull/10900
Follow up to r61611, r61539.
Props westonruter, jonsurrell, justlevine.
See #64662, #48456.
Fixes#64661.
Built from https://develop.svn.wordpress.org/trunk@61800
git-svn-id: http://core.svn.wordpress.org/trunk@61106 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Following [61555], the post type icons were missing from the At a Glance dashboard widget. Restore the post type class omitted from the previous commit.
Props ocean90, krokodok, karinchristen, hubersen, stefanvelthuys, ozgursar, sabernhardt, joedolson.
Fixes#43084.
Built from https://develop.svn.wordpress.org/trunk@61799
git-svn-id: http://core.svn.wordpress.org/trunk@61105 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Ensure that the black background covers the entire width of the header on large screens, ensure that the dismiss button appears on small screens.
Props peterwilsoncc, ramonopoly, huzaifaalmesbah, marc4, shailu25, ocean90, krokodok, karinchristen, hubersen, stefanvelthuys, joedolson.
Fixes#64741.
Built from https://develop.svn.wordpress.org/trunk@61798
git-svn-id: http://core.svn.wordpress.org/trunk@61104 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Update the sizing of icons in the welcome panel, bulk edit, quick edit, and admin notifications to use relative sizing, fixing alignment issues.
Update focus state for bulk edit remove buttons.
Props mohitbsf, opurockey, sabernhardt, huzaifaalmesbah, madhavishah01, r1k0, ozgursar, noruzzaman, shailu25, joedolson, mukesh27.
Fixes#64684.
Built from https://develop.svn.wordpress.org/trunk@61784
git-svn-id: http://core.svn.wordpress.org/trunk@61090 1a063a9b-81f0-0310-95a4-ce76da25c4cd
The same error message was returned whether a user attempted bulk edit without selecting an action or attempted without selecting any posts. These two situations need different messages.
Return error messages appropriate to the actual user error.
Props Presskopp, r1k0, pratiknawkar94, joedolson.
Fixes#64659.
Built from https://develop.svn.wordpress.org/trunk@61771
git-svn-id: http://core.svn.wordpress.org/trunk@61077 1a063a9b-81f0-0310-95a4-ce76da25c4cd
In General Settings, set the `remove-site-icon` class in initial state and add border for clearer control boundaries.
Props sabernhardt, noruzzaman, madhavishah01, huzaifaalmesbah, hmbashar, shailu25, joedolson.
Fixes#64736.
Built from https://develop.svn.wordpress.org/trunk@61770
git-svn-id: http://core.svn.wordpress.org/trunk@61076 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Switch the classic editor's taxonomy tabs to use the APG tablist/tabpanel structure. Add appropriate ARIA roles to tabs and panels and update JS to handle required keyboard events and selected states.
Props alh0319, mukesh27, joedolson.
Fixes#63981.
Built from https://develop.svn.wordpress.org/trunk@61764
git-svn-id: http://core.svn.wordpress.org/trunk@61070 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Following the admin reskin, community events inputs were misaligned.
Change to `flex` layout to fix alignment and improve handling for translated strings.
Props huzaifaalmesbah, hmbashar, mirmpro, shailu25, joedolson.
Fixes#64753.
Built from https://develop.svn.wordpress.org/trunk@61761
git-svn-id: http://core.svn.wordpress.org/trunk@61067 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Add a visible label with the `aria-label` value for image selection to enable voice control users to select images. Add visible labels on filters to improve access to media filters.
Props grahamarmfield, tomauger, afercia, rianrietveld, antpb, audrasjb, SirLouen, ozgursar, poojapadamad, mukesh27, alh0319, joedolson.
Fixes#23562.
Built from https://develop.svn.wordpress.org/trunk@61757
git-svn-id: http://core.svn.wordpress.org/trunk@61063 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Plugin and theme installer buttons load a dashicon during their updating and updated states. These dashicons were sized to large buttons, and caused a shift in alignment after the switch to compact buttons.
Update CSS to prevent shifts in size and alignment for installer buttons.
Props mohitbsf, peterwilsoncc, adnanhyder, huzaifaalmesbah, noruzzaman, ravichudasama01, shailu25, r1k0, joedolson.
Fixes#64687.
Built from https://develop.svn.wordpress.org/trunk@61741
git-svn-id: http://core.svn.wordpress.org/trunk@61047 1a063a9b-81f0-0310-95a4-ce76da25c4cd
The `aria-label` on post titles in list tables changes the accessible name from `{post_title}` to `"{post_title}" (Edit)`. This change increases verbosity for screen readers and creates a mismatch between the visual text and the accessible name for voice command.
Remove the extraneous `aria-label`.
Props afercia, rianrietveld, iworks, muddassirnasim, joedolson.
Fixes#33002.
Built from https://develop.svn.wordpress.org/trunk@61738
git-svn-id: http://core.svn.wordpress.org/trunk@61044 1a063a9b-81f0-0310-95a4-ce76da25c4cd
The admin reskin changed info notices to a transparent background, matching usage in Gutenberg. But with the gray background in the core admin, these notices didn't show up in an expected manner. Additionally, using a transparent background in a context where the background color is variable is risky for color contrast.
Change `.notice-info`, `.notice-info.notice-alt`, and `.login .notice, .login .message` to use white backgrounds. Reverts changes from [61731] to apply styles also to `.message` class.
Props mohitbsf, audrasjb, peterwilsoncc, pbiron, fabiankaegy, noruzzaman, joedolson.
Fixes#64678. See #64715.
Built from https://develop.svn.wordpress.org/trunk@61737
git-svn-id: http://core.svn.wordpress.org/trunk@61043 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This changeset standardizes the vertical spacing between the heading and the first content item in the “At a Glance” admin dashboard widget to match the spacing conventions used by other dashboard widgets.
Props mohitbsf, opurockey, adnanhyder.
Fixes#64682.
Built from https://develop.svn.wordpress.org/trunk@61732
git-svn-id: http://core.svn.wordpress.org/trunk@61039 1a063a9b-81f0-0310-95a4-ce76da25c4cd