Skip to content

Releases: facebook/astryx

v0.1.1

26 Jun 22:53
a514b99

Choose a tag to compare

This release continues removing the xds naming from the public API, alongside component fixes and a new astryx build CLI workflow.

@astryxdesign/core

Breaking Changes

  • Rename xdsTokenDefaults export to tokenDefaults (exported from @astryxdesign/core/theme). Update imports accordingly. Part of removing xds naming from the public API.

Fixes

  • ChatLayoutScrollButton: widen trailing inline padding when a label (e.g. "New messages") is shown so the text isn't cramped against the pill's rounded corner. The icon-only collapsed state is unchanged.
  • DateInput: no longer crashes the page while typing an incomplete date. Typing a leading 0 or 1 could coerce the in-progress value into an invalid date (year 0) and throw a RangeError. Partial input is now treated as incomplete instead of being parsed.
  • Selector: remove doubled focus ring. The inner combobox button drew its own :focus-visible outline on top of the wrapper's :focus-within ring. The button now defers to the wrapper's focus ring, matching TextInput and NumberInput.
  • Layout: <Layout>…</Layout> no longer renders a blank page. Children now render as a shorthand for the content slot (<Layout>{main}</Layout><Layout content={main} />); an explicit content prop still wins when both are provided.
  • ToggleButton: pressedChangeAction now runs inside an interruptible transition with optimistic pressed state (matching Switch), so the loading spinner appears and the action's lifecycle is respected. The optimistic state flips immediately, the spinner is debounced, the action is interruptible, and synchronous suspending handlers are supported. pressedChangeAction now accepts void | Promise<void>.

@astryxdesign/cli

New Features

  • astryx build: new command for page composition with natural-language search ranking. build "<idea>" returns an agent-ready composition kit grouped by role — a START line (scaffold vs compose), the closest PAGE template, always-on FRAME (page shell) and FOUNDATION (layout/typography/action) primitives, idea-specific BLOCKS and DOMAIN COMPONENTS, and a SETUP reminder. Always-on FRAME/FOUNDATION groups raised measured component recall from 15% → 71% on an agent-grounded eval. build with no args prints the how-to-build playbook.
  • Build-first agent docs: generated CLAUDE.md now leads with the build workflow and includes a required-CSS setup note (reset.css + astryx.css) so components never render unstyled. init points agents at astryx build/astryx search.
  • Denser, tailored agent docs: generated CLAUDE.md/AGENTS.md block tightened from ~48 → ~26 lines (same information), with styling guidance tailored to the project's configured system (StyleX xstyle, Tailwind utility classes, or plain style/className with var(--token)).

Fixes

  • npx astryx now works when the CLI is installed as a real npm package. The bin resolves sibling modules via its real path (realpath of import.meta.url), fixing ERR_MODULE_NOT_FOUND when invoked via the node_modules/.bin/astryx symlink. Non-interactive init/theme errors now say astryx <command> instead of the stale xds <command>.
  • v0.1.0 upgrade codemod: migrate legacy @xds/* module specifiers and config surfaces to the Astryx v0.1.0 names. [breaking] Remove legacy astryx.versionFile update-hint support from package.json.

Documentation

  • Theme System guide: add an npm install step to Quick Start so import {neutralTheme} from '@astryxdesign/theme-neutral' doesn't fail with Cannot find module (#3082).

@astryxdesign/build

Breaking Changes

  • Rename Vite integration exports off the xds name: xdsStylexastryxStylex, and option types XDSVitePluginOptions / XDSVitePluginLegacyOptionsAstryxVitePluginOptions / AstryxVitePluginLegacyOptions. Update imports from @astryxdesign/build/vite.
  • Rename Next.js helper withXDSwithAstryx (exported from @astryxdesign/build/next). Update next.config.mjs: import {withAstryx} from '@astryxdesign/build/next'.

Contributors

Thanks to everyone who contributed to this release: @cixzhang, @ejhammond, @joeyfarina, @josephfarina, @nynexman4464

Full Changelog: v0.1.0...v0.1.1