chore: add figma code connect coverage guard to lint pipeline#751
Merged
Conversation
# Conflicts: # libs/core/scripts/check-component-status.mjs
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 85ef4b7. Configure here.
Register @pine-ds/figma as a workspace project and declare an implicit dependency from core so figma-only PRs still schedule lint.figma, and add waiver/mapping paths to core lint inputs so Nx cache invalidates when those files change.
pixelflips
approved these changes
Jun 5, 2026
pixelflips
left a comment
Member
There was a problem hiding this comment.
Ran local check and no issues found. LGTM! 👍🏼
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Description
Adds a CI-gated check that every top-level
pds-*component is either mapped (haslibs/figma/components/<name>.figma.ts) or explicitly waived in a new machine-readablelibs/figma/code-connect-waivers.json. Prevents a new component from silently shipping with no Code Connect mapping and no deliberate decision, and flags redundant waivers (component since mapped) and orphaned waivers (component removed) so the waiver list cannot rot.Seeded the waiver file with the 15 top-level components that currently have no
.figma.ts(notes carried over fromCODE_CONNECT_COVERAGE.md). No.figma.tsfiles were authored here — real mappings need Figma node URLs from design and are a paired follow-up; waiving keeps the gap honest and tracked.Extracts a shared component-enumeration helper (
libs/core/scripts/lib/components.mjs) used by both this guard and the component-status guard so their globbing logic can't diverge.Stacked on #750 (component-status guard) for the shared helper. Review/merge #750 first; this will auto-retarget to
main.Why no workflow changes: gated via
lint.figmainrun-p lint.*, which the existingnx affected --target=lintjob already runs.Note for #736 author: once
CODE_CONNECT_COVERAGE.mdlands onmain, that doc and this JSON both list the 15 gaps. The clean end-state is rendering the doc from this JSON (single source of truth) — flagged as a follow-up in the JSON's$comment.New dependencies: none.
Fixes #(no-issue)
Type of change
How Has This Been Tested?
Passes on current state (21 mapped, 15 waived, 35 components).
Verified it fails for an uncovered component (dropped
pds-tooltipwaiver), a redundant waiver (pds-button, already mapped), and an orphaned waiver (pds-ghost), then confirmed clean after restore.Confirmed the component-status guard still passes after the shared-helper refactor.
run-p lint.*enumerateslint.eslint, lint.figma, lint.status, lint.styles.unit tests
e2e tests
accessibility tests
tested manually
other: self-validating checks run against real + simulated drift
Test Configuration:
Checklist:
Note
Low Risk
Tooling-only change to lint/CI inputs; no runtime component or auth behavior is modified.
Overview
Adds a Figma Code Connect coverage guard to the existing
@pine-ds/corelint pipeline so every top-levelpds-*component must either havelibs/figma/components/<name>.figma.tsor an explicit entry in newlibs/figma/code-connect-waivers.json. The check also fails on redundant waivers (component already mapped) and orphaned waivers (component removed).Wires it as
lint.figmaunderrun-p lint.*(no CI workflow changes). Nx gets animplicitDependencieslink from core to@pine-ds/figmaand extra lint inputs for waivers and.figma.tsfiles so figma-only changes still run core lint and cache invalidates correctly.Refactors component discovery into shared
libs/core/scripts/lib/components.mjs, used by both the new guard andcheck-component-status.mjs. Seeds the waiver file with the 15 currently unmapped components and registers the private@pine-ds/figmaworkspace package.Reviewed by Cursor Bugbot for commit ba14f2d. Bugbot is set up for automated code reviews on this repo. Configure here.