Align Properties in Figma and Storybook/Code #1093
thrbnhrtmnn
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hey everybody 👋
I would like to discuss if we should align properties in Figma and Storybook/Code.
We already invested some time to align the properties in Storybook/Code. We made sure, that properties which do the same have the same name in all our components. We also categorised the properties in different clusters like "Appearance", "Content/Settings" or "States" to only name a few. Lastly we made sure that the categories and the properties within the categories are always listed in the same order for each component.
What we did not do is align this also with the properties that exist in Figma.
From my understanding Figma properties also function differently than component properties in code. For example the different states of a component are also properties in Figma, but in code these are completely integrated into the code and define how a component works. States are not something that you should just be able to change via a prop in the coded component.
On the other hand we have properties in Figma, which function exactly like the properties in code. For example for the Button Text component we have a property in Figma to change the size and we have a property to change the variant, exactly like in code, but the names are different. In code we name it sizeVariant, in Figma we name it Size. In code we name it variant, in Figma we name it Emphasis.
Another difference between Figma and Storybook/code is how components can be nested within each other. When I add an icon component to the Button Text component in Figma, I can change the properties of the icon component like anywhere else. In code we do not allow this. In code we define exactly which size the icon will have, based on the size of the Button Text component.
Here is a List of possible changes for the properties in Figma (ignoring the States property):
Suggestions
Beta Was this translation helpful? Give feedback.
All reactions