flex.py 725 B

123456789101112131415161718192021222324252627282930313233
  1. """A reflexive container component."""
  2. from typing import List, Union
  3. from reflex.components.libs.chakra import ChakraComponent
  4. from reflex.vars import Var
  5. class Flex(ChakraComponent):
  6. """A reflexive container component."""
  7. tag: str = "Flex"
  8. # How to align items in the flex.
  9. align: Var[str]
  10. # Shorthand for flexBasis style prop
  11. basis: Var[str]
  12. # Shorthand for flexDirection style prop
  13. direction: Var[Union[str, List[str]]]
  14. # Shorthand for flexGrow style prop
  15. grow: Var[str]
  16. # The way to justify the items.
  17. justify: Var[str]
  18. # Shorthand for flexWrap style prop
  19. wrap: Var[Union[str, List[str]]]
  20. # Shorthand for flexShrink style prop
  21. shrink: Var[str]