Skip to content

[css-mixins] Make @apply and @contents rules StyleRuleGroups#61433

Merged
chromium-wpt-export-bot merged 1 commit into
masterfrom
chromium-export-cl-8114919
Jul 21, 2026
Merged

[css-mixins] Make @apply and @contents rules StyleRuleGroups#61433
chromium-wpt-export-bot merged 1 commit into
masterfrom
chromium-export-cl-8114919

Conversation

@chromium-wpt-export-bot

@chromium-wpt-export-bot chromium-wpt-export-bot commented Jul 20, 2026

Copy link
Copy Markdown
Collaborator

@apply and @contents carry child rules but extended StyleRuleBase,
stashing them on a throwaway "fake parent" StyleRule. This CL makes them
extend StyleRuleGroup, owning their children directly and joining
DowncastTraits<StyleRuleGroup> and continuing the work from CL:7755161.

This is a behavior-preserving refactor. A web test was added confirming
that an empty @apply --foo {} block suppresses the mixin's @contents
fallback, while @apply --foo; still lets it apply.

Change-Id: I033b0d0b0e6d399152cb6ce3e1ac4dfd0c563c48
Fixed: 502048295
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/8114919
Commit-Queue: Stephanie Zhang <stephanie.zhang@microsoft.com>
Reviewed-by: Kevin Babbitt <kbabbitt@microsoft.com>
Cr-Commit-Position: refs/heads/main@{#1665525}

@apply and @contents carry child rules but extended StyleRuleBase,
stashing them on a throwaway "fake parent" StyleRule. This CL makes them
extend StyleRuleGroup, owning their children directly and joining
DowncastTraits<StyleRuleGroup> and continuing the work from CL:7755161.

This is a behavior-preserving refactor. A web test was added confirming
that an empty `@apply --foo {}` block suppresses the mixin's @contents
fallback, while `@apply --foo;` still lets it apply.

Change-Id: I033b0d0b0e6d399152cb6ce3e1ac4dfd0c563c48
Fixed: 502048295
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/8114919
Commit-Queue: Stephanie Zhang <stephanie.zhang@microsoft.com>
Reviewed-by: Kevin Babbitt <kbabbitt@microsoft.com>
Cr-Commit-Position: refs/heads/main@{#1665525}

@wpt-pr-bot wpt-pr-bot left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The review process for this patch is being conducted in the Chromium project.

@chromium-wpt-export-bot
chromium-wpt-export-bot merged commit 7aae0c9 into master Jul 21, 2026
27 checks passed
@chromium-wpt-export-bot
chromium-wpt-export-bot deleted the chromium-export-cl-8114919 branch July 21, 2026 17:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants