Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve detection of empty figma components #10

Merged
merged 4 commits into from
Mar 21, 2023

Conversation

bradmering
Copy link
Contributor

This creates default tokens in the sass/projects folder and includes them both in the sass/main.scss for the project, the templates/main.scss for the previews, and in the installer/template/templates/main.scss so they get included with new builds for the templates.

This will solve both the fetch problem where we can't build templates if the tokens cannot be found, plus it solves the static build where the templates cannot be found.

It introduces a new prop for the component pages called componentFound: boolean; that allows us to return a not found page. The componentNotFound component accepts the arguments for a normal page, and renders a not found page with the metadata for a normal page. We can customize that component as needed.

This PR also filters the menu, so if a component is in the menu, but no components are found from figma, it won't show even if the menu says it should. This will make the default menu behavior more sane.

@bradmering bradmering requested review from Natko, a user and tomislavmihic March 16, 2023 21:38
@bradmering bradmering changed the title Convhand 197 improve detection of empty components Improve detection of empty figma components Mar 16, 2023
@bradmering bradmering merged commit e7a0554 into main Mar 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant