Skip to content

fix(eslint-plugin): match bare component names after unprefixing#3027

Merged
ejhammond merged 1 commit into
mainfrom
navi/docs/scrub-internal-stale-xds
Jun 24, 2026
Merged

fix(eslint-plugin): match bare component names after unprefixing#3027
ejhammond merged 1 commit into
mainfrom
navi/docs/scrub-internal-stale-xds

Conversation

@ejhammond

@ejhammond ejhammond commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

Summary

Fixes the internal ESLint plugin's rules, which silently broke after the component unprefixing. The rules keyed their allowlists / matchers on XDS*-prefixed names, but core is now bare (Badge, BaseProps, Link.tsx, …) — so the matching no longer fired.

Functional fixes

  • presentational-component: PRESENTATIONAL_COMPONENTS set XDS* → bare (rule now matches Badge, Card, … again).
  • shared: COMPONENT_RULE_ALLOWED set (XDSBaseProps, XDSIconProps, XDSTooltipProps, … → bare).
  • require-base-props / require-ref-prop: dropped the startsWith('XDS') gate (component props are bare *Props now) and match BaseProps instead of XDSBaseProps.
  • no-hardcoded-anchor: ALLOWED_FILES skip-list XDSLink.tsx/XDSLinkProvider.tsx/useXDSLinkComponent.tsLink.tsx/LinkProvider.tsx/useLinkComponent.ts, so the Link infrastructure files are correctly exempt.

Also

  • boolean-prop-naming illustrative comments + rule test fixtures (XDS*Props*Props) and the plugin README/docblock examples, so they exercise the real (bare) surface.

Scope

Product-name "XDS" in rule descriptions/categories left as-is (prose branding decision). Internal package — no changeset. All rule files pass node --check; check:sync + check:package-boundaries green.

@vercel

vercel Bot commented Jun 24, 2026

Copy link
Copy Markdown

@ejhammond must be a member of the Meta Open Source team on Vercel to deploy.
- Click here to add @ejhammond to the team.
- If you initiated this build, request access.

Learn more about collaboration on Vercel and other options here.

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Meta Open Source bot. label Jun 24, 2026
@github-actions

github-actions Bot commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

🚀 Vercel Preview Deployment

Status ✅ Deployed
Preview Open Preview
Commit 2d7fde8
Inspect Vercel Dashboard
Workflow View Logs

No authentication required — anyone with the link can view the preview.

@github-actions

github-actions Bot commented Jun 24, 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.

No new or modified components detected.

Bundle Size Summary

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

Accessibility Audit

Status: No accessibility violations detected.


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

@vercel

vercel Bot commented Jun 24, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
astryx Error Error Jun 24, 2026 7:10pm

Request Review

The internal ESLint rules keyed their allowlists/matchers on XDS*-prefixed
names, but core was unprefixed (Badge, BaseProps, Link.tsx, ...) — so the
rules silently stopped matching. Update the functional matching:

- presentational-component: PRESENTATIONAL_COMPONENTS set XDS* -> bare.
- shared: COMPONENT_RULE_ALLOWED set (XDSBaseProps/XDSIconProps/... -> bare).
- require-base-props / require-ref-prop: drop the startsWith('XDS') gate (props
  are bare *Props now), match XDSBaseProps -> BaseProps.
- no-hardcoded-anchor: ALLOWED_FILES skip-list XDSLink.tsx/... -> Link.tsx/... so
  the Link infrastructure files are exempt again.
- boolean-prop-naming + presentational comments/messages, and rule test fixtures
  (XDS*Props -> *Props) so they exercise the real surface.

Product-name 'XDS' in rule descriptions/categories left as-is (prose). Internal
package; no changeset.
@ejhammond ejhammond force-pushed the navi/docs/scrub-internal-stale-xds branch from 70b7022 to 2d7fde8 Compare June 24, 2026 19:10
@ejhammond ejhammond merged commit 0c01b0b into main Jun 24, 2026
16 of 17 checks passed
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.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants