Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Use@layer properties for@property polyfills#17506

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
philipp-spiess merged 1 commit intomainfromfix/layer-properties
Apr 2, 2025

Conversation

philipp-spiess
Copy link
Member

@philipp-spiessphilipp-spiess commentedApr 2, 2025
edited
Loading

This PR changes how polyfills for@property are inserted. The main motivation is to remove the need to rely on the correct placement of@layer base;—Something that's not really required right not in Tailwind CSS v4 and we'd like to keep it this way.

The idea is that the polyfills are inserted for you automatically. To ensure they always take precedence, we insert an empty@layer properties; at the top of the CSS file so that later, when we emit all@property rules and their fallback, we can use this new named layer to ensure the rules have a higher order.

Unfortunately, just putting@layer properties; at the beginning of a file would not work aslightningcss incorrectly hoists all content into the first occurrence of a layer name meaning these rules might be insertedbefore eventual external imports:

image

To work around this, we have to insert that layer name after any eventual remaining external@imports for now.

Test plan

@philipp-spiessphilipp-spiess merged commit4484192 intomainApr 2, 2025
7 checks passed
@philipp-spiessphilipp-spiess deleted the fix/layer-properties branchApril 2, 2025 16:16
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@RobinMalfaitRobinMalfaitRobinMalfait approved these changes

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

2 participants
@philipp-spiess@RobinMalfait

[8]ページ先頭

©2009-2025 Movatter.jp