Skip to content

fix(CommandPalette): forward BaseProps pass-through attributes to Dialog#4288

Open
cixzhang wants to merge 1 commit into
mainfrom
fix/component-audit-2026-07-24
Open

fix(CommandPalette): forward BaseProps pass-through attributes to Dialog#4288
cixzhang wants to merge 1 commit into
mainfrom
fix/component-audit-2026-07-24

Conversation

@cixzhang

Copy link
Copy Markdown
Contributor

CommandPalette extends BaseProps<HTMLDialogElement> but had no ...rest capture in its destructure. Consumer pass-through attributes (className, style, xstyle, data-testid, aria-describedby, id, etc.) were silently dropped.

This adds a rest capture and forwards it to the underlying Dialog, so BaseProps attributes reach the DOM as expected.

Needs Review

ContextMenu and DropdownMenu share the same pattern (discriminated union props with no rest forwarding). Those are more complex to fix cleanly because of the union type and the two-element render split. Filed as a note for a future pass.

Night Watch — Component Auditor

CommandPalette extends BaseProps but previously had no ...rest capture,
silently dropping consumer pass-through attributes (className, style,
xstyle, data-testid, aria-describedby, etc.). Capture and forward them
to the underlying Dialog element.
@cixzhang cixzhang added the hardening Component hardening and quality sweep label Jul 24, 2026
@vercel

vercel Bot commented Jul 24, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
astryx Ready Ready Preview, Comment Jul 24, 2026 10:24am

Request Review

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Meta Open Source bot. label Jul 24, 2026
github-actions Bot added a commit that referenced this pull request Jul 24, 2026
@github-actions

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

CommandPalette · View in Storybook
Metric Before After Delta
Bundle Size (ESM) N/A N/A N/A
Lines of Code N/A 983 -
Complexity N/A Very High (110) -

Bundle Size Summary

Package Size (ESM) Size (CJS) Gzipped
@astryxdesign/core N/A 4.7KB 0B

Accessibility Audit

Status: No accessibility violations detected.


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

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. hardening Component hardening and quality sweep

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant