โ Design Systems learning pathDesign Systems ยท Module 5 of 10
Components and variants
Components come in variants, sizes and states.
๐ Key ideas
- A button may have variants: primary, secondary, ghost, danger.
- States: default, hover, focus, active, disabled, loading.
- Sizes: small, medium, large, using tokens.
- Props or properties control variants in code and in Figma.
- Keep components small and composable (Card = header + body + footer).
๐ก Real-life example: Like a school uniform: same design, but in sizes and in summer and winter versions.
VariantA styled version of a component
StateCondition like hover or disabled
PropInput that configures a component in code
ComposableBuilt from smaller parts