chore(code-connect): test setup & basic implementation #11326
+3,040
−60
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.
Towards #11313
This PR explores basic setup config for code connect between Figma & @patternfly/react-core components. Questions & progress will be tracked here but may be moved to parent epic or new issue as needed.
Completed:
Setup
Components
Icons
TODO:
Code connect questions:
npx figma connect
executes with no errors but does not create any output. Manually hitting the API seems to return every component instance/example rather than just the list of total components?Component questions
icon: figma.children(['IconWrapper', 'Icon']),
which renders an empty propicon={}
if no icons passed, how can we just not render this prop? Could potentially cue off boolean if it existed to use nested properties?icon: figma.children(['IconWrapper', 'Icon']),
which works perfectly if state=default but not otherwise; we're only checking state to setisDisabled
so unclear what's different causing other examples to add empty react fragment wrapper and not render icon?cannot use “in” operator to search for “kind” in null