Repository navigation
Script Loader: Add an API for filtering inline style attributes #13250
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
Sukhendu2002
wants to merge
75
commits into
WordPress:trunk
Choose a base branch
from
Sukhendu2002:ticket/51325-inline-style-attributes
base: trunk
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+689
−50
Open
Changes from all commits
Commits
Show all changes
75 commits
Select commit
Hold shift + click to select a range
86ceeea
feat(styles): filter inline style attributes
Sukhendu2002 0ef5802
Merge branch 'trunk' into ticket/51325-inline-style-attributes
Sukhendu2002 c5e0b64
Merge branch 'trunk' into ticket/51325-inline-style-attributes
Sukhendu2002 1eb9b67
refactor: tighten inline style API types
Sukhendu2002 3ba1389
Merge branch 'trunk' into ticket/51325-inline-style-attributes
westonruter b3c0fa5
Address PHPStan errors in tests
westonruter 0468fec
Make inline style tag tests less brittle
westonruter 9461b76
Document inline style tag attribute values as string|bool
westonruter 7167a17
Filter attributes of hoisted extra block library inline style
westonruter 0b080ef
Avoid recomputing inline style when printing a stylesheet
westonruter b2d9c62
Use inline style tag API for other core STYLE tags
westonruter 2f547ec
Restore theme features after inline style tag tests
westonruter cee3db6
Use inline style tag API in default wp_die() handler
westonruter 3de2648
Use inline style tag API for interim login style
westonruter b727644
Use inline style tag API on Multisite signup and activation
westonruter 4a2c1d0
Use inline style tag API for plugin information banner
westonruter d810194
Use inline style tag API for site icon preview in General Settings
westonruter a6799e8
Use inline style tag API in Customizer
westonruter 5ac7b82
Use inline style tag API for site icon crop preview template
westonruter dfa73a5
Use inline style tag API for default gallery styles
westonruter b290c96
Use inline style tag API for Legacy Widget previews
westonruter 1a312c6
Use inline style tag API in deprecated functions
westonruter db14096
Use inline style tag API in theme compat header
westonruter 8dc2425
Use nowdoc for one-line CSS in deprecated functions
westonruter bd7687b
Use nowdoc for one-line CSS in interim login and Recent Comments widget
westonruter a976fe2
Use esc_url_raw() for plugin banner URLs in inline style
westonruter a6ee044
Use esc_url_raw() for site icon URL in General Settings inline style
westonruter 7c51302
Use esc_url_raw() for theme compat background URL
westonruter a0b5382
Use double quotes for site icon URL in Customizer control template
westonruter 14902b9
Escape URLs late inside inline style heredocs
westonruter ee5df21
Restore display context for theme compat background URL
westonruter aca233e
Escape percent signs in graceful_fail() inline style tag
westonruter 22a99e2
Revert inline style tag API change in Legacy Widget block
westonruter e47bd44
Merge branch 'trunk' of https://github.com/WordPress/wordpress-develo…
westonruter f6b0261
Twenty Ten: Use inline style tag API when available
westonruter b8387e4
Twenty Eleven: Use inline style tag API when available
westonruter 46f8f2b
Twenty Twelve: Use inline style tag API when available
westonruter e1f061c
Twenty Thirteen: Use inline style tag API when available
westonruter 8e419cb
Twenty Fourteen: Use inline style tag API when available
westonruter bcf2f8a
Twenty Fifteen: Use inline style tag API when available
westonruter f2866da
Twenty Sixteen: Use inline style tag API when available
westonruter 445b585
Twenty Seventeen: Use inline style tag API when available
westonruter 35242b3
Twenty Nineteen: Use inline style tag API when available
westonruter 4d63462
Twenty Twenty-One: Use inline style tag API when available
westonruter e965370
Avoid fatal error for non-string inline style data
westonruter 37b6bab
Print inline style via WP_Styles::print_inline_style() when not conca…
westonruter a7e0bb8
Fix PHPStan errors in changed themes lines
westonruter a958ba2
Sanitize header text color for CSS instead of escaping as attribute
westonruter 7a6b8e4
Validate header text color inline in Twenty Thirteen and Twenty Fourteen
westonruter 595418c
Validate header text color in Twenty Eleven and Twenty Twelve
westonruter f503337
Twenty Twenty-One: Escape dark mode labels as CSS strings
westonruter c67e40c
Twenty Twenty-One: Escape dark mode labels late inside heredoc
westonruter 45739df
Escape late inside heredocs in bundled theme header styles
westonruter b56f432
Merge branch 'trunk' into ticket/51325-inline-style-attributes
westonruter dc2267b
Limit this change to the inline style tag API
westonruter bfdccf9
Trim all CSS whitespace from inline style tag data
westonruter af978bd
Test whitespace normalization of inline style tag data
westonruter 1aa54cc
Remove redundant test for filtered inline style attributes
westonruter 9fb547f
Narrow types
westonruter 770dc4e
Pass escaped CSS to the inline style attributes filter
Sukhendu2002 95faaff
Merge branch 'trunk' into ticket/51325-inline-style-attributes
Sukhendu2002 82ae44d
Merge branch 'trunk' into ticket/51325-inline-style-attributes
westonruter 6655639
Tests: Use MockAction to capture inline style attributes filter args.
westonruter d028d71
Script Loader: Remove unreachable failure branch from `wp_get_inline_…
westonruter 8841042
Script Loader: Ignore a non-array return from the `wp_inline_style_at…
westonruter 8db7a9c
Script Loader: Keep hoisted block library inline style consistent wit…
westonruter 243adb5
Revert "Script Loader: Ignore a non-array return from the `wp_inline_…
westonruter ea09b6e
Script Loader: Locate the hoisting placeholder STYLE tags by their CS…
westonruter aa46626
Script Loader: Preserve existing attributes when rebuilding the hoist…
westonruter 1434399
Docs: Note that `wp_inline_style_attributes` may run more than once f…
westonruter 44dfa2b
Script Loader: Stop reading STYLE contents once all hoisting placehol…
westonruter 58fc960
Revert "Script Loader: Stop reading STYLE contents once all hoisting …
westonruter d1adb85
Revert "Script Loader: Locate the hoisting placeholder STYLE tags by …
westonruter 269304a
Script Loader: Prevent the `wp_inline_style_attributes` filter from c…
westonruter c159a88
Script Loader: Locate the block library inline style by its ID again …
westonruter File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.