Commit Graph

689 Commits

Author SHA1 Message Date
David Baumwald
68134e22c1 Docs: Add @since to wp_enqueue_classic_theme_styles() docblock.
Follow-up to [54358].

Props kebbet.
See #55646.

git-svn-id: https://develop.svn.wordpress.org/trunk@54359 602fd350-edb4-49c9-b593-d223f7449a82
2022-09-29 19:14:00 +00:00
David Baumwald
81d5f405ff Editor: Reintroduce styles that were removed for classic themes.
After block CSS was merged with `theme.json` styles in [https://github.com/WordPress/gutenberg/pull/34180 Gutenberg PR #34180], this removed some existing, default styling for some elements, including buttons.  This change re-adds the removed styles by enqueueing `classic.css` for classic themes.

Merges [https://github.com/WordPress/gutenberg/pull/44334 Gutenberg PR #44334] into trunk.

Follow-up to [54257].

Props scruffian, oandregal, ramonopoly, aristath, andrewserong, get_dave, bernhard-reiter.
See #56467.

git-svn-id: https://develop.svn.wordpress.org/trunk@54358 602fd350-edb4-49c9-b593-d223f7449a82
2022-09-29 18:53:57 +00:00
Jonathan Desrosiers
8bef14f1a3 External Libraries: Update MediaElement.js to version 4.2.17.
This is a minor bug fix release and the latest in the 4.x branch.

A full list of changes can be found on the library’s GitHub: https://github.com/mediaelement/mediaelement/releases/tag/4.2.17.

While this is not the latest version (the 5.x branch is), further testing needs to be done to confirm compatibility in WordPress. #56320 has been opened to explore this.

Props cdbessig, desrosj.
Fixes #56319.

git-svn-id: https://develop.svn.wordpress.org/trunk@54354 602fd350-edb4-49c9-b593-d223f7449a82
2022-09-29 14:19:38 +00:00
Greg Ziółkowski
108c92d8dd Build: Improve how combined assets are generated
Allows to revert changes applied in [54277] - temporary workaround for the failing Test NPM CI check on Windows.

Improvements included:
- generate combined asset files for both production and development
- store in the repository only the production version of the combined assets for packages, we use everything else only in development
- to make unit tests work, ensure that they ignore react fast refresh and use the production version of combined assets that are present in the source code

Props bernhard-reiter, jsnajdr, clorith, wildworks.
Fixes #56615.



git-svn-id: https://develop.svn.wordpress.org/trunk@54289 602fd350-edb4-49c9-b593-d223f7449a82
2022-09-23 08:25:45 +00:00
John Blackbourn
17954e7778 Docs: Various improvements and corrections to inline docs.
See #55646


git-svn-id: https://develop.svn.wordpress.org/trunk@54267 602fd350-edb4-49c9-b593-d223f7449a82
2022-09-20 20:30:03 +00:00
Sergey Biryukov
beeb5a4a97 Coding Standards: Rename WordPress Dependencies API class files.
The current coding standards note that the name of the class files should be based on the class name with `class-` prepended, and the underscores replaced by hyphens (see the [https://developer.wordpress.org/coding-standards/wordpress-coding-standards/php/#naming-conventions Naming Conventions] section in the handbook), except for the three legacy files: `class.wp-dependencies.php`, `class.wp-scripts.php`, `class.wp-styles.php`.

To bring more consistency to the codebase and make it easier to implement autoloading in the future, this commit renames those three legacy files to conform to the coding standards:

* `wp-includes/class.wp-dependencies.php` → `wp-includes/class-wp-dependencies.php`
* `wp-includes/class.wp-scripts.php` → `wp-includes/class-wp-scripts.php`
* `wp-includes/class.wp-styles.php` → `wp-includes/class-wp-styles.php`

Includes:
* Loading the new files from the old ones, for anyone that may have been including the files directly.
* Replacing references to the old filenames with the new filenames.

Follow-up to [7970], [45654], [45662], [45663], [45678], [47197], [52026], [53749].

Props afragen, schlessera, swissspidy, dingo_d, hellofromTonya, SergeyBiryukov.
Fixes #37861. See #55647.

git-svn-id: https://develop.svn.wordpress.org/trunk@54254 602fd350-edb4-49c9-b593-d223f7449a82
2022-09-20 14:15:25 +00:00
Jonathan Desrosiers
2225a352e5 Coding Standards: Applying an alignment fix from running composer format.
Follow up to [54214].

See #56467.

git-svn-id: https://develop.svn.wordpress.org/trunk@54238 602fd350-edb4-49c9-b593-d223f7449a82
2022-09-20 01:40:56 +00:00
Jb Audras
c7baffbbc3 Editor: Backport block supports filter callback, registrations and tests to 6.1.
This changeset backports the following changes:

- Implement [https://github.com/WordPress/gutenberg/pull/42880 gutenberg#42880]: Backport script loader: enqueue stored block supports styles
- Allow a way to bypass `SCRIPT_DEBUG` in tests. See [https://github.com/WordPress/wordpress-develop/pull/3259#issuecomment-1250403735 comment] and the related [https://github.com/WordPress/gutenberg/pull/44248 Gutenberg pull request]

Props ramonopoly, gziolo, bernhard-reiter, audrasjb, costdev.
See #56467.


git-svn-id: https://develop.svn.wordpress.org/trunk@54214 602fd350-edb4-49c9-b593-d223f7449a82
2022-09-19 20:54:20 +00:00
Jonathan Desrosiers
5d05191bdc External Libraries: Update the jQuery UI library to version 1.13.2.
This is a bug fix release. For more information on the changes included, see https://jqueryui.com/changelog/1.13.2/.

Props Clorith, monolithon, desrosj.
Fixes #56239.

git-svn-id: https://develop.svn.wordpress.org/trunk@54209 602fd350-edb4-49c9-b593-d223f7449a82
2022-09-19 18:02:11 +00:00
Tonya Mork
c5c1f37e0d Editor: Fix function name case in wp_default_packages_inline_scripts().
Fixes function name typo by changing from uppercase `get_current_user_ID()` to lowercase `get_current_user_id()`.

>Note: Function names are case-insensitive for the ASCII characters A to Z, though it is usually good form to call functions as they appear in their declaration.
[https://www.php.net/manual/en/functions.user-defined.php As per the PHP manual], PHP functions are case-insensitive, meaning the code runs. However, this fix is necessary for consistency, maintainability, and future-proofing.

Follow-up to [54182].

Unprop hellofromTonya.
See #56467.

git-svn-id: https://develop.svn.wordpress.org/trunk@54204 602fd350-edb4-49c9-b593-d223f7449a82
2022-09-19 14:18:18 +00:00
Jonathan Desrosiers
bbb02f69ad External Libraries: Update the jQuery library to version 3.6.1.
This is a maintenance release. For more information on the changs included, see https://blog.jquery.com/2022/08/26/jquery-3-6-1-maintenance-release/.

Props tobiasbg.
See #56451.

git-svn-id: https://develop.svn.wordpress.org/trunk@54202 602fd350-edb4-49c9-b593-d223f7449a82
2022-09-19 14:14:54 +00:00
Sergey Biryukov
14e54b5d20 Editor: Finalize the theme_json_get_style_nodes hook name.
This consolidates the name of a filter introduced earlier in the 6.1 cycle, renaming it from `get_style_nodes` to `theme_json_get_style_nodes` as to be more coherent with the other hooks introduced in 6.1 as well.

This commit backports the original PR from Gutenberg repository:
* [https://github.com/WordPress/gutenberg/pull/44189 #44189 Use prefix 'theme_json_' in hooks related to theme.json]

Reference: [https://github.com/WordPress/wordpress-develop/pull/3247 #3247 Add hooks to filter theme.json data].

Follow-up to [54118].

Props oandregal, scruffian, bernhard-reiter.
See #56467.

git-svn-id: https://develop.svn.wordpress.org/trunk@54183 602fd350-edb4-49c9-b593-d223f7449a82
2022-09-15 20:26:13 +00:00
Tonya Mork
fc6bc030d4 Editor: Persist preferences in user meta.
Adds a new feature to persist editor UI preferences between page loads and browsers.

* Adds a new preferences persistence API.
* Saves editor preferences in user meta instead of in browser's local storage.

Why?
Due to the transient nature of browser storage, this persistence is not as sticky as it is expected to be, including: switching browsers (unique storage between browsers), or using private browsing tabs (storage cleared between sessions), or the same user across a network of sites (storage unique by domain).

This is a backport from Gutenberg.[https://github.com/WordPress/gutenberg/pull/39795 See WordPress/gutenberg PR 39795].

Props talldanwp, youknowriad, noisysocks, mamaduka, costdev, ironprogrammer, hellofromTonya.
See #56467.

git-svn-id: https://develop.svn.wordpress.org/trunk@54182 602fd350-edb4-49c9-b593-d223f7449a82
2022-09-15 16:43:39 +00:00
Greg Ziółkowski
3381f05fa2 Blocks: Allow registering multiple items for all supported asset types
Follow-up #54337, [52069]. Part of https://github.com/WordPress/gutenberg/issues/41236. More details in https://github.com/WordPress/gutenberg/issues/33542.

Allow passing more than one script per block for `editorScript`, `script`, and `viewScript` fields in the `block.json` metadata file. This aligns with the previously added changes for `style` and `editorStyle` fields.

This change impacts the `WP_Block_Type` class and the REST API endpoint for block types. To ensure backward compatibiliy old names were soft deprecated in favor of new fields that work with array values and have `_handles` suffix.

Props zieladam, dlh, timothyblynjacobs, aristath, bernhard-reiter.
Fixes #56408.



git-svn-id: https://develop.svn.wordpress.org/trunk@54155 602fd350-edb4-49c9-b593-d223f7449a82
2022-09-14 10:50:26 +00:00
Sergey Biryukov
438822aa5b Editor: Backport Elements API updates.
This commit backports the original PRs from Gutenberg repository:

* [https://github.com/WordPress/gutenberg/pull/40260 #40260 Add support for button elements to theme.json]
* [https://github.com/WordPress/gutenberg/pull/40889 #40889 Theme Json: Don't output double selectors for elements inside blocks]
* [https://github.com/WordPress/gutenberg/pull/41140 #41140 Global Styles: Add support for caption elements]
* [https://github.com/WordPress/gutenberg/pull/41160 #41160 Global Styles: Load block CSS conditionally]
* [https://github.com/WordPress/gutenberg/pull/41240 #41240 Global Styles: Button Element: update button element selector]
* [https://github.com/WordPress/gutenberg/pull/41335 #41335 Duotone: Fix CSS Selectors rendered by theme.json duotone/filter settings for blocks on public pages]
* [https://github.com/WordPress/gutenberg/pull/41446 #41446 Block styles: Account for style block nodes that have no name]
* [https://github.com/WordPress/gutenberg/pull/41696 #41696 Global Styles: Allow references to values in other locations in the tree]
* [https://github.com/WordPress/gutenberg/pull/41753 #41753 Elements: Add an API make it easier to get class names]
* [https://github.com/WordPress/gutenberg/pull/41786 #41786 Support pseudo selectors on elements in theme json]
* [https://github.com/WordPress/gutenberg/pull/41822 #41822 Elements: Button - Fix element selectors]
* [https://github.com/WordPress/gutenberg/pull/41981 #41981 Global Styles: Add support for heading elements]
* [https://github.com/WordPress/gutenberg/pull/42072 #42072 Fix link element hover bleeding into button element default styles]
* [https://github.com/WordPress/gutenberg/pull/42096 #42096 Add visited to link element allowed pseudo selector list]
* [https://github.com/WordPress/gutenberg/pull/42669 #42669 Link elements: Add a :where selector to the :not to lower specificity]
* [https://github.com/WordPress/gutenberg/pull/42776 #42776 Theme JSON: Add a static $blocks_metadata data definition to the Gutenberg instance of WP_Theme_JSON]
* [https://github.com/WordPress/gutenberg/pull/43088 #43088 Pseudo elements supports on button elements]
* [https://github.com/WordPress/gutenberg/pull/43167 #43167 Theme_JSON: Use existing append_to_selector for pseudo elements]
* [https://github.com/WordPress/gutenberg/pull/43988 #43988 Styles API: Fixed selectors for nested elements]

Props onemaggie, bernhard-reiter, cbravobernal, mmaattiiaass, scruffian, andraganescu, dpcalhoun, get_dave, Mamaduka, SergeyBiryukov.
See #56467.

git-svn-id: https://develop.svn.wordpress.org/trunk@54118 602fd350-edb4-49c9-b593-d223f7449a82
2022-09-10 12:37:00 +00:00
Robert Anderson
bb0cbe3f55 Script Loader: Pass startOfWeek setting to @wordpress/date
Allows the block editor to respect the site's Week Starts On setting by defining
`i10n.startOfWeek` when initialising the `@wordpress/date` module.

This is a backport of https://github.com/WordPress/gutenberg/pull/41648.

See #56467.
Props andrewserong.


git-svn-id: https://develop.svn.wordpress.org/trunk@54079 602fd350-edb4-49c9-b593-d223f7449a82
2022-09-06 02:50:35 +00:00
Jonathan Desrosiers
ef326a6545 Script Loader: Allow a priority to be passed to wp_enqueue_block_support_styles().
`wp_enqueue_block_support_styles()` attaches inline styles to the `wp_head` or `wp_footer` actions. This adds a priority parameter to the function to allow the styles to be given a loading order when necessary.

Props bernhard-reiter, ramonopoly.
See #56467.

git-svn-id: https://develop.svn.wordpress.org/trunk@54048 602fd350-edb4-49c9-b593-d223f7449a82
2022-09-01 15:43:25 +00:00
Robert Anderson
3d168f6150 Editor: Ensure that timezone.offset passed to @wordpress/date is a float
Fixes inconsistent type of `timezone.offset` passed to `@wordpress/date`. It
should always be a float, never a string.

Props talldanwp.
Fixes #56459.


git-svn-id: https://develop.svn.wordpress.org/trunk@53956 602fd350-edb4-49c9-b593-d223f7449a82
2022-08-30 01:02:46 +00:00
Jonathan Desrosiers
2437ef5130 External Libraries: Update the Moment library to version 2.29.4.
This is a minor bug fix release.

Props dilipbheda.
Fixes #56031.

git-svn-id: https://develop.svn.wordpress.org/trunk@53725 602fd350-edb4-49c9-b593-d223f7449a82
2022-07-19 19:41:12 +00:00
Jonathan Desrosiers
6d63251316 External Libraries: Update the Moment library to version 2.29.3.
This is a minor bug fix release.

Props dilipbheda.
Fixes #56031.

git-svn-id: https://develop.svn.wordpress.org/trunk@53662 602fd350-edb4-49c9-b593-d223f7449a82
2022-07-05 15:19:42 +00:00
Jonathan Desrosiers
db6b186865 External Libraries: Update the Underscore library to version 1.13.4.
This is a minor documentation and bug fix release.

Props christinavoudouris, dilipbheda.
Fixes #56030.

git-svn-id: https://develop.svn.wordpress.org/trunk@53660 602fd350-edb4-49c9-b593-d223f7449a82
2022-07-05 14:59:17 +00:00
Sergey Biryukov
b316c8b25f General: Replace all esc_url_raw() calls in core with sanitize_url().
This aims to improve performance by calling `sanitize_url()` directly, instead of the `esc_url_raw()` wrapper. As of WordPress 6.1, `sanitize_url()` is the recommended function for sanitizing a URL for database or redirect usage.

Follow-up to [11383], [13096], [51597], [53452].

Props benjgrolleau, peterwilsoncc, SergeyBiryukov.
Fixes #55852.

git-svn-id: https://develop.svn.wordpress.org/trunk@53455 602fd350-edb4-49c9-b593-d223f7449a82
2022-06-01 18:12:25 +00:00
Sergey Biryukov
50f2d7da7d Docs: Remove @return void from various DocBlocks.
Per the documentation standards, it should not be used outside of the default bundled themes.

Follow-up to [38767], [47055], [49697], [50956], [51003], [52069], [53255].

See #54729.

git-svn-id: https://develop.svn.wordpress.org/trunk@53331 602fd350-edb4-49c9-b593-d223f7449a82
2022-05-02 13:11:07 +00:00
Peter Wilson
c70c7ad811 Install: Prevent DB errors caused by web fonts API.
Bypass checking `theme.json` for web fonts during the installation of WordPress.

During installation the active theme is considered to be Twenty Twenty-Two (the default theme). As a block theme this prompts a database call when the web fonts API checks the `theme.json` settings, this triggers a database error during installation as the database tables do not exist.

Props chouby, costdev, peterwilsoncc, sergeybiryukov.
Fixes #55632.



git-svn-id: https://develop.svn.wordpress.org/trunk@53306 602fd350-edb4-49c9-b593-d223f7449a82
2022-04-29 03:48:48 +00:00
Jonathan Desrosiers
65a2a4fac7 External Libraries: Update the underscore library to version 1.13.3.
This is a minor bug fix release.

Fixes #55547.

git-svn-id: https://develop.svn.wordpress.org/trunk@53296 602fd350-edb4-49c9-b593-d223f7449a82
2022-04-27 14:37:09 +00:00
Tonya Mork
12d8066d39 Themes: Remove 'gutenberg' as translation context in _wp_theme_json_webfonts_handler().
Follow-up to [53282].

Props kebbet.

See #55567, #46370.

git-svn-id: https://develop.svn.wordpress.org/trunk@53288 602fd350-edb4-49c9-b593-d223f7449a82
2022-04-26 15:35:13 +00:00
Tonya Mork
02414638ce Themes: Add internal-only theme.json's webfonts handler (stopgap).
Adds `_wp_theme_json_webfonts_handler()` for handling `fontFace` declarations in a theme's `theme.json` file to generate the `@font-face` styles for both the editor and front-end.

Design notes:
* It is not a public API, but rather an internal, Core-only handler.
* It is a stopgap implementation that will be replaced when the public Webfonts API is introduced in Core.
* The code design is intentional, albeit funky, with the purpose of avoiding backwards-compatibility issues when the public Webfonts API is introduced in Core.
   * It hides the inter-workings.
   * Does not exposing API ins and outs for external consumption.
   * Only works for `theme.json`.
   * Does not provide registration or enqueuing access for plugins.

For more context on the decision to include this stopgap and the Webfonts API, see:
* Core's PR 40493 https://github.com/WordPress/gutenberg/pull/40493
* Gutenberg's tracking issue 40472 https://github.com/WordPress/gutenberg/issues/40472

Props aristath, hellofromTonya, peterwilsoncc, costdev, jffng, zieladam, gziolo, bph, jonoaldersonwp, desrosj.

See #55567, #46370.

git-svn-id: https://develop.svn.wordpress.org/trunk@53282 602fd350-edb4-49c9-b593-d223f7449a82
2022-04-26 14:46:37 +00:00
Jb Audras
c63de7818e Docs: Docs: Use third-person singular verbs for function descriptions in wp-includes/blocks.php and wp-includes/script-loader.php, per the documentation standards.
See #54729.


git-svn-id: https://develop.svn.wordpress.org/trunk@53235 602fd350-edb4-49c9-b593-d223f7449a82
2022-04-20 14:07:53 +00:00
Jb Audras
84f3b34e2d Editor: Move wp_enqueue_block_style() to wp-includes/script-loader.php, for better consistency.
As a result of [52741] and [52743], `wp_enqueue_block_support_styles()` was moved to `wp-includes/script-loader.php`. However, `wp_enqueue_block_style()` was still defined in `wp-includes/blocks.php`. This changeset also moves `wp_enqueue_block_support_styles()` to `wp-includes/script-loader.php` for better consistency.

Follow-up to [52741], [52743].

Props SergeyBiryukov, mukesh27, audrasjb.
Fixes #55182.
See #55148.


git-svn-id: https://develop.svn.wordpress.org/trunk@53234 602fd350-edb4-49c9-b593-d223f7449a82
2022-04-20 13:51:21 +00:00
Jonathan Desrosiers
ea239d33e7 Script Loader: Specify the version of the clipboard library included when registering.
For external libraries, the current version included with WordPress should be specified when registering scripts.

Props elifvish.
Fixes #55565.

git-svn-id: https://develop.svn.wordpress.org/trunk@53173 602fd350-edb4-49c9-b593-d223f7449a82
2022-04-13 15:56:23 +00:00
Jonathan Desrosiers
81f603ea4f External Libraries: Update polyfill libraries.
This updates two polyfill libraries to their latest versions.

- `polyfill-library` from `3.105.0` to `4.0.0`.
- `formdata-polyfill` from `4.0.0` to `4.0.10`.

This will affect the following script handles:
- `wp-polyfill-formdata`
- `wp-polyfill-node-contains`
- `wp-polyfill-dom-rect`

These polyfills are no longer used by WordPress Core, but are kept up to date as a courtesy for any plugins or themes still requiring them.

See #55547.

git-svn-id: https://develop.svn.wordpress.org/trunk@53165 602fd350-edb4-49c9-b593-d223f7449a82
2022-04-12 17:33:54 +00:00
Jonathan Desrosiers
7bb55a033f External Libraries: Update some external libraries.
This updates three external libraries to their latest versions:

- `backbone` from `1.4.0` to `1.4.1`.
- `underscore` from `1.13.1` to `1.13.2`.
- `clipboard` from `2.0.8` to `2.0.10`.

These are all minor updates containing bug fixes and documentation improvements.

See #55547.

git-svn-id: https://develop.svn.wordpress.org/trunk@53164 602fd350-edb4-49c9-b593-d223f7449a82
2022-04-12 17:15:15 +00:00
Jonathan Desrosiers
8bb8bc92a4 External Libraries: Update moment to version 2.29.2.
See #55547.

git-svn-id: https://develop.svn.wordpress.org/trunk@53163 602fd350-edb4-49c9-b593-d223f7449a82
2022-04-12 16:50:07 +00:00
Greg Ziółkowski
1d086c57d5 Editor: Use block settings to pass assets for the iframed editor
Backports changes applied in Gutenberg in https://github.com/WordPress/gutenberg/pull/37193.

Props zieladam.
See #55505.
Follow-up for [53157].



git-svn-id: https://develop.svn.wordpress.org/trunk@53160 602fd350-edb4-49c9-b593-d223f7449a82
2022-04-12 15:59:47 +00:00
Greg Ziółkowski
b726922bb9 Build: Enable React Fast Refresh for block development
Brings the same functionality introduced in the Gutenberg plugin with https://github.com/WordPress/gutenberg/pull/28273. In effect, it brings React Fast Refresh support to WordPress core for block development with `@wordpress/scripts`.

Props walbo, antonvlasenko.
See #51750, #55505.
Follow-up [53135].



git-svn-id: https://develop.svn.wordpress.org/trunk@53140 602fd350-edb4-49c9-b593-d223f7449a82
2022-04-11 16:08:12 +00:00
Peter Wilson
63d1383a59 Plugins: Update item count when plugin deleted.
Update the item count, "N items", on the plugin list when a plugin is deleted. This matches the live updating of various other counts on the screen.

Props mitogh, costdev, azouamauriac, swissspidy, kebbet.
Fixes #55316.



git-svn-id: https://develop.svn.wordpress.org/trunk@53124 602fd350-edb4-49c9-b593-d223f7449a82
2022-04-11 04:49:29 +00:00
Peter Wilson
c4545fde8d Script loader: Add wp-a11y as dependency of wp-ajax-response.
Ensure `wp.a11y.speak()` is available when called in `wp-ajax-response`.

Follow up to [52170].

Props afercia.
Fixes #55544.
See #42937.


git-svn-id: https://develop.svn.wordpress.org/trunk@53103 602fd350-edb4-49c9-b593-d223f7449a82
2022-04-08 05:58:09 +00:00
Sergey Biryukov
8277055e37 Docs: Add missing description for $pagenow global in various functions.
See #54729, #55499.

git-svn-id: https://develop.svn.wordpress.org/trunk@53060 602fd350-edb4-49c9-b593-d223f7449a82
2022-04-04 18:24:18 +00:00
Jb Audras
33e8be0976 Customizer: Accessibility fixes following [53024].
This changeset fixes a few issues spotted after [53024].

- Remove target blank on HelpHub link
- Remove duplicate information in `aria-label`
- Small i18n fixes

Follow-up to [53024].

Props joedolson, audrasjb, pbiron.
Fixes #54939.


git-svn-id: https://develop.svn.wordpress.org/trunk@53025 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-29 19:55:32 +00:00
Jb Audras
81ebc7c712 Customizer: When a block theme is active, add an information about Site Editor in the Customizer.
This change adds an information notice to the customizer when a block theme is active and the customizer is also available (for example when a plugin activates it), to encourage people to use the Site Editor for the best full site customization experience.

Props ironprogrammer, antonvlasenko, Clorith, audrasjb, psmits1567, tobifjellner, costdev, webcommsat.
Fixes #54939.


git-svn-id: https://develop.svn.wordpress.org/trunk@53024 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-29 19:07:15 +00:00
Jb Audras
82c0591117 Editor: Change location of block support styles in wp_head.
Backports changes from https://github.com/WordPress/gutenberg/pull/39164.

Props ndiego, alexstine, cbravobernal, mamaduka.
See #55474.


git-svn-id: https://develop.svn.wordpress.org/trunk@53015 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-29 13:26:38 +00:00
David Baumwald
68cfd584ab External Libraries: Update Jcrop to version 0.9.15.
For a full list of changes, see https://github.com/tapmodo/Jcrop/compare/v0.9.12...v0.9.15.

This change also adds a comment in `script-loader.php` indicating that this library is no longer used by core.

Follow-up to [10846], [10863], [11015], [21633], [25549].

Props hareesh-pillai, karpstrucking, SergeyBiryukov.
Fixes #54035.

git-svn-id: https://develop.svn.wordpress.org/trunk@52989 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-24 20:05:40 +00:00
Jb Audras
6c270d0d17 Administration: Replace contracted verb forms for better consistency.
This changeset replaces contracted verb forms like `doesn't`, `can't`, or `isn't` with non-contracted forms like `does not`, `cannot`, or `is not`, for better consistency across the WordPress administration. It also updates some corresponding unit tests strings.

Props Presskopp, socalchristina, aandrewdixon, francina, SergeyBiryukov, JeffPaul, audrasjb, hellofromTonya.
Fixes #38913.
See #39176.


git-svn-id: https://develop.svn.wordpress.org/trunk@52978 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-22 16:23:32 +00:00
Jb Audras
6adff3d989 jquery-query
git-svn-id: https://develop.svn.wordpress.org/trunk@52844 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-10 18:52:20 +00:00
David Baumwald
d238f31fab Media: Add a "Copy URL to clipboard" function to the list table view.
Previously, a button was added to the modal view for a single media item in the "grid" view to copy the file URL to the user's clipboard.  This change adds a similar function to the "list" view for each media item.

Follow-up to [48232].

Props pbiron, ravipatel, alexstine, afercia.
Fixes #54426.

git-svn-id: https://develop.svn.wordpress.org/trunk@52842 602fd350-edb4-49c9-b593-d223f7449a82
2022-03-10 18:22:57 +00:00
Tonya Mork
a3cbbc419d Editor: Automatically apply global styles duotone filters to render in post editor.
Global styles duotone filters were not rendering in the post editor. This fixes that by adding `wp_global_styles_render_svg_filters` to the `in_admin_header` so it renders in the body before the editor.

Follow-up [52757].

Props ajlende, abhanonstopnewsuk.
Fixes #55190.

git-svn-id: https://develop.svn.wordpress.org/trunk@52768 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-17 20:43:39 +00:00
Dominik Schilling
fcd5d3b495 Script Loader: Prevent normalizing data URIs in _wp_normalize_relative_css_links().
This prevents making data URIs as in `mask-image:url('data:image/svg+xml;utf8,<svg...` relative to the WordPress installation.

Props staatic.
See #54243.
Fixes #55177.

git-svn-id: https://develop.svn.wordpress.org/trunk@52754 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-17 14:45:53 +00:00
Jorge Costa
8ec1cb83e3 Script Loader: Improvements to the load block support styles mechanism.
This commit applies feedback given to commit 52741. It changes the new function name, the file where it is located, and improves its documentation and marks.

Follow-up to [52741].
Props hellofromtonya, swissspidy, oandregal.
See #55148.

git-svn-id: https://develop.svn.wordpress.org/trunk@52743 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-16 22:18:33 +00:00
Jb Audras
6dc1e0ed3b Script Loader: Load block themes styles in the head section.
Previously, some logic was added to load the global stylesheet in the bottom of `<body>` for classic themes that opted-in into loading individual block styles instead of a single stylesheet for them all. At the time, block themes always loaded the global stylesheet in the `<head>`. When block themes landed in core during WordPress 5.9 this logic wasn’t updated to consider them, hence the global stylesheet loaded in the `<body>` for them. This changeset fixes this.

Props oandregal, aristath.
Fixes #55148.


git-svn-id: https://develop.svn.wordpress.org/trunk@52738 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-16 10:34:20 +00:00
Jb Audras
b8f97013df Script Loader: Prevent normalizing HTML IDs in _wp_normalize_relative_css_links().
This change fixes an issue where `_wp_normalize_relative_css_links()` was not only matching urls, but also HTML IDs.

Follow-up to [52036].

Props mahype, costdev, audrasjb, SergeyBiryukov.
Fixes #54922.


git-svn-id: https://develop.svn.wordpress.org/trunk@52695 602fd350-edb4-49c9-b593-d223f7449a82
2022-02-08 23:39:32 +00:00