Based on the user agent stylesheet rules outlined in https://html.spec.whatwg.org/multipage/rendering.html#img-contain-size, images that have `sizes=auto` while applying `width: auto` or `width: fit-content` would be constrained to only 300px width.
This changeset overrides said user agent stylesheet rule with a much larger constraint, to avoid the problem.
Additionally, it introduces a filter `wp_img_tag_add_auto_sizes` which can be used to opt out of the functionality, as an additional measure.
Reviewed by desrosj, joemcgill.
Merges [59415] to the 6.7 branch.
Props joemcgill, flixos90, dooperweb, SirLouen, azaozz, mukesh27, apermo.
Fixes#62413.
See #61847, #62345.
Built from https://develop.svn.wordpress.org/branches/6.7@59435
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58821 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Improvements were made in 6.7 to ensure that salts stored in the database were primed more efficiently.
The logic added to accomplish this suffered from an edge case where array indexes were unexpectedly missing when `wp_salt()` was called recursively.
Follow up to [58837].
Reviewed by davidbaumwald.
Merges [59427] to the 6.7 branch.
Props juliobox, ankitkumarshah, dilipbheda, johnbillion, joemcgill, desrosj.
Fixes#62424.
Built from https://develop.svn.wordpress.org/branches/6.7@59434
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58820 1a063a9b-81f0-0310-95a4-ce76da25c4cd
When `load_*_textdomain()` functions are called after WordPress has already attempted just-in-time loading of translations, nothing happens.
This updates the related logic to retry translation loading when a custom path is set to ensure all translations are available.
Additionally, this also fixes cases where an `en_US.mo` file is provided with non-English strings to override the default language.
Follow up to [59157].
Reviewed by SergeyBiryukov.
Merges [59430] to the 6.7 branch.
Props swissspidy, peterwilsoncc, desrosj, apermo, sergeybiryukov, wildworks, tigriweb, twvania, looswebstudio, stimul, audrasjb, finntown, bluantinoo, timwhitlock, albigdd.
See #62337.
Built from https://develop.svn.wordpress.org/branches/6.7@59433
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58819 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Includes:
* Moving the comments directly above `wp.i18n._x()` so that they can be picked up properly.
* Simplifying the context to avoid unnecessarily translating the string twice for the same use case.
* Using the established translator comments format for consistency.
Follow-up to [59428].
Reviewed by SergeyBiryukov, desrosj.
Merges [59431 to the 6.7 branch.
Fixes#62402.
Built from https://develop.svn.wordpress.org/branches/6.7@59432
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58818 1a063a9b-81f0-0310-95a4-ce76da25c4cd
In [59138], the login screens were updated to change the `h1` heading from the logo to screen-reader hidden text. Along with that HTML change, we changed the CSS selectors from `.login h1` to `.login .wp-login-logo`. This unnecessary change increased specificity and broke the CSS selectors used by a wide variety of plugins to replace the login logo.
Commit reverts the change in selector back to using the `.login h1` pattern.
Reviewed by joedolson, desrosj.
Merges [59424] to the 6.7 branch.
Props leecollings, sabernhardt, im3dabasia1, roytanck, sailpete, joedolson.
Fixes#62410.
Built from https://develop.svn.wordpress.org/branches/6.7@59429
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58815 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Wrap three untranslatable strings in nav menus in JS translation functions.
Follow up to [59265].
Reviewed by desrosj, joedolson.
Merges 59426 to the 6.7 branch.
Props juliemoynat, swissspidy, yogeshbhutkar, sergeybiryukov, desrosj, tobifjellner, audrasjb, joedolson.
Fixes#62402.
Built from https://develop.svn.wordpress.org/branches/6.7@59428
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58814 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Support for uploading AVIF was added in [57524]. A new block of conditional logic was added determine which function should be used to create the new image file that resulted in these expensive functions being run twice.
This combines the two conditional logic to ensure the appropriate function is only run once regardless of format.
Reviewed by adamsilverstein.
Merges [59413] to the 6.7 branch.
Props adamsilverstein, glynnquelch.
Fixes#62331.
Built from https://develop.svn.wordpress.org/branches/6.7@59423
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58809 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Adjust some CSS characteristics in the customizer accordions to avoid a slight horizontal scroll, allow the chevron icon to be part of the clickable control surface, and resolve a pre-existing padding issue allowing overflow on accordion headings.
Follow up to [59224].
Reviewed by desrosj, joedolson.
Merges [59409] to the 6.7 branch.
Props laurelfulford, wildworks, domainsupport, sabernhardt, rcreators, desrosj, sainathpoojary.
Fixes#62313, #62335.
Built from https://develop.svn.wordpress.org/branches/6.7@59420
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58806 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Changeset [59399] fixed missing DOCTYPEs in normalized HTML output. It missed an edge case where public and system identifiers may contain double quotes, in which case they must be quoted with single quotes.
This commit addresses that issue and adds tests.
Follow-up to [59399].
Reviewed by cbravobernal.
Merges [59410] to the 6.7 branch.
Props jonsurrell, luisherranz, apermo.
Fixes#62396.
Built from https://develop.svn.wordpress.org/branches/6.7@59411
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58797 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Aligns on the behavior of the negation operator with directives to missing paths in client and in server.
With a directive like the following:
{{{
<div data-wp-bind--hidden="!state.missing.property">
This should be hidden by the <code>hidden</code> attribute.
</div>
}}}
Both server and client will return with this fix:
{{{
<div data-wp-bind--hidden="!state.missing.property" hidden="">
This should be hidden by the <code>hidden</code> attribute.
</div>
}}}
Reviewed by cbravobernal.
Merges [59398] to the 6.7 branch.
Props jonsurrell, luisherranz.
Fixes#62374.
Built from https://develop.svn.wordpress.org/branches/6.7@59404
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58790 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Output DOCTYPE when calling `WP_HTML_Processor::serialize` on a full document that includes a DOCTYPE.
The DOCTYPE should be included in the serialized/normalized HTML output as it has an impact in how the document is handled, in particular whether the document should be handled in quirks or no-quirks mode.
This only affects the serialization of full parsers at this time because DOCTYPE tokens are currently ignored in all possible fragments. The omission of the DOCTYPE is subtle but can change the serialized document's quirks/no-quirks mode.
Reviewed by cbravobernal.
Merges [59399] to the 6.7 branch.
Props jonsurrell.
Fixes#62396.
Built from https://develop.svn.wordpress.org/branches/6.7@59401
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58787 1a063a9b-81f0-0310-95a4-ce76da25c4cd
After the SimplePie library was updated to version `1.8.0` in [59141], an edge case has been discovered where a fatal error can encountered if the `blog_charset` option is missing or empty.
In `fetch_feed()`, this option is retrieved using `get_option()` instead of `get_bloginfo( ‘charset’ )`. The latter will detect this scenario and apply a default value of `UTF-8` and is already used interchangeably throughout Core. This switches to `get_bloginfo( ‘charset’ )` instead to prevent this edge case.
Reviewed by davidbaumwald.
Merges [59382] to the 6.7 branch.
Props david.binda, davidbaumwald, SergeyBiryukov, sabernhardt, azaozz, peterwilsoncc.
Fixes#62354.
Built from https://develop.svn.wordpress.org/branches/6.7@59383
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58769 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Removes the dimension suffix, eg `-1000x1000` from the file name of full size images automatically converted from HEIC to JPEGs by WordPress. Introduces unit tests for the default conversion of images and customized conversion settings via the `image_editor_output_format` filter.
Follow up to [58849], [58942], [59317], [59346], [59366].
Reviewed by davidbaumwald.
Merges [59379] and [59380] to the 6.7 branch.
Props mukesh27, peterwilsoncc, azaozz, apermo, flixos90, ironprogrammer.
Fixes#62359.
See #53645, #62305.
Built from https://develop.svn.wordpress.org/branches/6.7@59381
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58767 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This backport includes follow up commits to improve a variable name and improve accuracy of when an image needs to be converted.
Reviewed by peterwilsoncc.
Merges [59317], [59346], [59366] to the 6.7 branch.
Props ironprogrammer, adamsilverstein, azaozz, peterwilsoncc, apermo, flixos90.
Fixes#62305.
Built from https://develop.svn.wordpress.org/branches/6.7@59367
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58753 1a063a9b-81f0-0310-95a4-ce76da25c4cd
- Adds support for all HEIC/HEIF mime types: `image/heic`, `image/heif`, `image/heic-sequence`, and `image/heif-sequence`.
- Introduces `wp_is_heic_image_mime_type()`.
This backport includes a subsequent fix of a typo.
Reviewed by peterwilsoncc.
Merges [59315,59358] to the 6.7 branch.
Props swissspidy, adamsilverstein, debarghyabanerjee, ironprogrammer, peterwilsoncc, apermo, azaozz, mosne.
Fixes#62272.
Built from https://develop.svn.wordpress.org/branches/6.7@59360
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58746 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This fixes an issue with the usage of the new `$wp_styles->get_etag()` method in `wp-admin/load-styles.php`, where `$wp_version` is passed as the first argument instead of `$load` being used as the ''only'' argument.
Follow-up to [58935].
Reviewed by swissspidy.
Merges [59341] to the 6.7 branch.
Props justlevine, mukesh27, swissspidy, SergeyBiryukov.
See #52217, #61485.
Built from https://develop.svn.wordpress.org/branches/6.7@59343
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58729 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Reverts an earlier change to the test suite in which the PHPUnit tests could not run if the importer plugin was not available.
This update allows the test suite to run and will fail importer tests if the plugin is not available.
Follow up to r59085.
Merges [59326] to the 6.7 branch.
Props peterwilsoncc, azaozz.
See #62325.
Built from https://develop.svn.wordpress.org/branches/6.7@59327
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58713 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit fixes a regression whereby requests to global styles endpoints were not being preloaded, resulting in several requests being fired clientside unnecessarily.
For performance reasons, we preload the requests so that the data is in the editor store and ready to use straight away.
The outcome is that the editor loads more quickly.
Follow-up to [62042].
Reviewed by peterwilsoncc.
Merges [59316] to the 6.7 branch.
Props ellatrix, ramonopoly, apermo, peterwilsoncc.
Fixes #62315.
Built from https://develop.svn.wordpress.org/branches/6.7@59324
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58710 1a063a9b-81f0-0310-95a4-ce76da25c4cd
The previous approach of running `wp_allow_comment()` twice could have unintended consequences, e.g. the `check_comment_flood` action was also triggered twice, which might lead to false-positive identification of comment flood in case there is some custom callback hooked to it, which is not expecting identical data seeing twice.
This commit introduces a new function, `wp_check_comment_data()`, to specifically check for disallowed content before and after comment data is filtered.
Follow-up to [59267].
Reviewed by davidbaumwald.
Merges [59319] to the 6.7 branch.
Props david.binda, SergeyBiryukov.
Fixes#61827.
Built from https://develop.svn.wordpress.org/branches/6.7@59322
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58708 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Fixes a typo in the a11y helper text explaining how to navigate revisions. "Change revision by using the left and arrow keys" becomes "Change revision by using the left and right arrow keys".
Follow up to [59225].
Reviewed by swissspidy.
Merges [59306] to the 6.7 branch.
Props pedromendonca, sabernhardt, fierevere, swissspidy.
Fixes#62306.
Built from https://develop.svn.wordpress.org/branches/6.7@59313
git-svn-id: http://core.svn.wordpress.org/branches/6.7@58699 1a063a9b-81f0-0310-95a4-ce76da25c4cd