Skip to content

fix(core): expand CSS shorthands registered after the stylesheet was parsed - #11553

Open
triniwiz wants to merge 1 commit into
mainfrom
fix/late-css-shorthands
Open

triniwiz wants to merge 1 commit into
mainfrom
fix/late-css-shorthands

Conversation

@triniwiz

Copy link
Copy Markdown
Member

Shorthands are expanded into longhands while the CSS is parsed. One registered later (a plugin, or core's own flex/flex-flow, which load with FlexboxLayout) stayed unexpanded:

  • every view re-ran its converter on each apply
  • when such a rule stopped matching, all its longhands were unset, including ones another rule still set

Each rule now expands late shorthands once, on first use. A registration counter keeps the per-view cost to one integer compare. Rules without late shorthands are unchanged.

Tests: 3 new specs in css-selector.spec.ts; core suite passes.

…parsed

A shorthand registered after the app CSS was parsed stayed unexpanded, so every
view re-ran its converter on each apply and the cascade mixed it with longhands.
Rules now expand it once, on first use.
@nx-cloud

nx-cloud Bot commented Oct 19, 2026 •

Copy link
Copy Markdown

View your CI Pipeline Execution ↗ for commit 05f6c7d

Command Status Duration Result
nx run-many -t build -p core,webpack5,vite ✅ Succeeded 25s View ↗

💡 Verify your cache is correct by running tasks in a sandbox. Read docs ↗


☁️ Nx Cloud last updated this comment at 2026-10-19 04:29:47 UTC

@pkg-pr-new

pkg-pr-new Bot commented Oct 19, 2026

Copy link
Copy Markdown

Open in StackBlitz

npm i https://pkg.pr.new/@nativescript/core@11553
npm i https://pkg.pr.new/@nativescript/vite@11553
npm i https://pkg.pr.new/@nativescript/webpack@11553

commit: 05f6c7d

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant