Skip to content

feat(core)!: remove deprecated APIs for 0.6 - #6118

Merged
cixzhang merged 2 commits into
mainfrom
cleanup/060-deprecated-apis
Sep 7, 2026
Merged

cixzhang merged 2 commits into
mainfrom
cleanup/060-deprecated-apis

Conversation

@cixzhang

@cixzhang cixzhang commented Sep 7, 2026

Copy link
Copy Markdown
Contributor

Summary

Remove the explicitly deprecated Core APIs selected for the Astryx 0.6 breaking window:

  • UseGridFocusOptions.isRtl and UseListFocusOptions.isRtl; both hooks now rely exclusively on their existing lazy container-direction detection.
  • isImeKeyEvent from @astryxdesign/core/hooks; the canonical @astryxdesign/core/utils and package-root exports remain.
  • minSizePx and maxSizePx; numeric minSize and maxSize preserve pixel semantics, including maxSize: Infinity.

All first-party callers, examples, stories, and docs are migrated. AST-010 and the Resizable contract now describe the shipped 0.6 surface.

Migration

Run before updating:

npx astryx upgrade --apply

Three staged next-release transforms:

  1. Remove static isRtl options from inline useGridFocus / useListFocus calls.
  2. Move isImeKeyEvent imports from core/hooks to core/utils.
  3. Rename inline useResizable minSizePx / maxSizePx keys, including multi-region configs.

The transforms preserve side-effect imports, handle existing value/type-only/namespace imports safely, respect lexical shadowing, preserve shorthand values, and keep the released new-key-wins conflict behavior.

Compatibility

This is intentionally breaking relative to Core 0.5.4 and carries a [breaking] Core changeset (minor bump while Astryx is 0.x). The CLI codemods carry a separate patch changeset.

Testing

  • 197 focused tests pass across the three codemods, both focus hooks, public API removal checks, useResizable, and ResizeHandle.
  • pnpm -F @astryxdesign/core typecheck
  • pnpm -F @astryxdesign/cli typecheck:strict
  • pnpm -F @astryxdesign/core build
  • pnpm check:repo
  • Strict lint on all changed JS/TS files: no errors (one pre-existing template warning).
  • Independent read-only review and post-fix re-review: green, no blockers.

@vercel

vercel Bot commented Sep 7, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
astryx Ready Ready Preview Sep 7, 2026 3:26pm UTC

Request Review

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Meta Open Source bot. label Sep 7, 2026
@github-actions github-actions Bot added the needs:design-review Affects visuals — Design should review label Sep 7, 2026
@github-actions github-actions Bot added the needs:spec-owner-review Current knowledge records await owner approval label Sep 7, 2026
github-actions Bot added a commit that referenced this pull request Sep 7, 2026
@github-actions

github-actions Bot commented Sep 7, 2026

Copy link
Copy Markdown
Contributor

PR Analysis Report

📚 Storybook Preview

View Storybook for this PR
GitHub Pages may take up to a minute to hydrate after deploy.

🧪 Sandbox Preview

View Sandbox for this PR
GitHub Pages may take up to a minute to hydrate after deploy.

Modified Components

BottomSheet (@astryxdesign/core) · View in Storybook
Metric Before After Delta
Bundle Size (ESM) N/A N/A N/A
Lines of Code N/A 3191 -
Complexity N/A Very High (258) -
Layout (@astryxdesign/core) · View in Storybook
Metric Before After Delta
Bundle Size (ESM) N/A N/A N/A
Lines of Code N/A 1487 -
Complexity N/A Very High (86) -
Resizable (@astryxdesign/core) · View in Storybook
Metric Before After Delta
Bundle Size (ESM) N/A N/A N/A
Lines of Code N/A 1276 -
Complexity N/A Very High (106) -
SideNav (@astryxdesign/core) · View in Storybook
Metric Before After Delta
Bundle Size (ESM) N/A N/A N/A
Lines of Code N/A 2049 -
Complexity N/A Very High (213) -

Bundle Size Summary

Package Size (ESM) Size (CJS) Gzipped
@astryxdesign/core N/A 4.8KB 1.2KB

Accessibility Audit

Status: No accessibility violations detected.

Visual Regression

Status: Skipped — Broad stable scope is deferred to the daily release gate. It covers 380 trusted baseline shots instead of recapturing them for this PR. View the report


Generated by PR Enrichment workflow | Storybook | Sandbox | View full report

@cixzhang

cixzhang commented Sep 7, 2026

Copy link
Copy Markdown
Contributor Author

/approve-spec 47a182f

@github-actions github-actions Bot removed the needs:spec-owner-review Current knowledge records await owner approval label Sep 7, 2026
@cixzhang
cixzhang merged commit 3c50fcc into main Sep 7, 2026
27 checks passed
cixzhang added a commit that referenced this pull request Sep 7, 2026
Nine commits, no conflicts. Two touched files this branch also changes, both
auto-merged cleanly and re-read by hand:

- ci.yml gained a tooling_only lane (#6112, #6113) and moved the heavier test
  lane to a larger runner (#6080). The tooling lane is an exact two-file
  allowlist in change-scope.cjs, so it cannot claim this PR, and the
  accessibility additions — the widened check-components filter, the a11y-spec
  typecheck step, and the test:a11y-contract step in pr-a11y — all survived the
  merge intact;
- deploy.yml's a11y-spec typecheck step is intact.

The 0.6 breaking change (#6118) removes deprecated focus-hook options, an
isImeKeyEvent re-export, and useResizable pixel bounds. Nothing under Switch,
the stories, or internal/a11y-spec references any of them.
@github-actions
github-actions Bot deleted the cleanup/060-deprecated-apis branch September 8, 2026 06:22

This branch was successfully deployed

1 active deployment
Preview — 47a182f1 Deployed Sep 7, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Meta Open Source bot. needs:design-review Affects visuals — Design should review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant