@pandacss/compiler@2.0.0-beta.16
Pre-releaseMajor Changes
- ef14fc5: Remove the
syntaxconfig option and thetemplate-literalauthoring mode. Dropsyntaxfrom your config
and the--syntaxflag frompanda init, and write styles with the object syntax:css({ color: 'red' })instead of
css`color: red`.
Minor Changes
-
dea1ef5: Add a
keyframes()factory tostyled-system/cssfor inline, component-local animations.keyframes({ from: {...}, to: {...} })returns akf_…animation name and emits its@keyframesblock, tree-shaken
to what a build actually references throughanimationNameor theanimationshorthand. Object form only — a bare
animationName: 'spin'already resolves atheme.keyframesentry, so there is no named form. Shared, design-system
animations still belong intheme.keyframes. -
c58d45d: Add a
positionTry()factory tostyled-system/cssand atheme.positionTrykey for named CSS
anchor-positioning fallbacks, and removeglobalPositionTry.positionTry('bottom')orpositionTry({ top: 'anchor(bottom)' })returns the dashed-ident for
positionTryFallbacksand emits the@position-tryblock, tree-shaken to what a build uses. MoveglobalPositionTry
entries totheme.positionTryand reference them through the factory. A block that must emit unconditionally with a
hand-authored name belongs in a plain.cssfile. -
064e58f: Source transforms now handle slot recipes.
tabs({ size: 'sm' })on a config slot recipe becomes an object of class strings, one per slot.- Inline
sva()compiles even when variants style each slot differently. - Defaults, compound variants and finite conditionals fold; dynamic and responsive values stay on the runtime.
- Fix transformed recipe classes ignoring
prefixandhash. - Fix boolean compound variants in inline
cva()/sva()never matching. - Add
transform_sourcespans to--profileoutput.
Patch Changes
-
f583fb9: Merge the
cssprop over the style props beside it, so one declaration wins instead of two classes whose
winner depended on stylesheet order. Shorthands normalize first, sopaddingandpcollide the way they do at
runtime.// before: className="color_blue color_red", renders red // after: className="color_blue", renders blue <Box color="red" css={{ color: 'blue' }} />
Generated CSS can shrink: a rule whose only source was the losing side of a collision is no longer emitted.
-
6b04d94: Ignore watcher add and change events for unknown paths outside the configured source globs. Explicitly
registered and design-system sources remain refreshable. -
dfb17b2: Fix
Driver.parseFiles()retaining atoms from source files removed since the previous scan. Full-project
rescans now reconcile scan- and watcher-owned files, including recovery from dropped watcher events. -
84720fc: Re-extract files with unresolved cross-file imports when the missing module is created during watch mode.
-
d94d26c: Keep
!inside string values.css({ content: '"hello!"' })emittedcontent: "hello" !important; only a
trailing!or!importantmarks a declaration important now. -
c3702af: Treat condition props like
_hover, CSS variables, and&/@selectors as style props on JSX components,
so they become classes instead of DOM attributes. -
a46ecb4: Stop reporting a literal color inside a token reference as a missing token.
{#000/64}and{rgb(0 0 0)/64}
already resolve to acolor-mix(); only real token paths are validated now. -
ca9bb58:
parseFilesnow returns a report for every requested path. A file that cannot be read keeps its last parsed
styles and reports asource_not_foundorsource_read_failedwarning instead of being silently skipped. -
446210a: Mark transformed
cva(),sva(), andstyled()recipe factories as pure so bundlers can remove unused
definitions and their runtime helpers. -
9bdafba: Fix a config load error when a
utility.valuescallback returns nothing. Listing@pandacss/preset-baseon
its own failed withUtility values callback ... returned invalid values, becausetranslateZreads the spacing
scale and preset-base ships no tokens. The utility now simply has no preset values, and arbitrary values still work. -
f583fb9: Keep the component when transforming JSX elements listed in a recipe's
jsxoption. That list tracks
elements so their variants reach the stylesheet — the component is yours, and replacing<Button size="sm" />with a
divdropped whatever it rendered. The element and its variant props now stay put; only style props fold into
className. -
b2294ca: Resolve conditional variants in recipe calls and JSX at build time.
button({ size: cond ? 'sm' : 'lg' })
now emits a class ternary instead of applying both sizes, and several conditional variants resolve into a decision
tree that gets defaults and compound variants right. Usages that still can't resolve to one class list are left for
the runtime. -
af261f5: Fix watch CSS staying stale when a file you import a value from changes. Importers are re-extracted,
including through re-exports, and only when the imported file's content actually changed. -
9da80e1: Refresh cached cross-file exports when the resolved module itself changes, is deleted, or is recreated.
Long-lived compiler sessions no longer reuse stale direct exports when re-extracting an importer. -
ef68d33: Fix theme CSS so nesting and dark mode work. Theme variables now declare on the
[data-panda-theme]element
and inherit, instead of being re-set on every descendant.- A
gothicpanel inside amatchapage now renders gothic, whichever theme comes first in the CSS. <html class="dark" data-panda-theme="gothic">now reaches every element, anddarktoggled inside a theme works.- On-demand theme files from
styled-system/themesscope their dark rules to the theme. - A nested
basevalue inside a condition, such as_dark: { base, md }, is no longer dropped. - Warn when a theme name contains anything but letters, digits,
-or_, since it becomes adata-panda-theme
value, a_theme*condition and theThemeNametype.
- A
-
bcbcb22: Update the internal transform cache to
lru0.18.4, which fixes upstream Rust soundness issues. -
Updated dependencies [a5bab14]
-
Updated dependencies [dfb17b2]
-
Updated dependencies [dea1ef5]
-
Updated dependencies [c58d45d]
-
Updated dependencies [af261f5]
-
Updated dependencies [ef14fc5]
- @pandacss/config@2.0.0-beta.16
- @pandacss/compiler-shared@2.0.0-beta.16
- @pandacss/types@2.0.0-beta.16