Styles
API
counterweight.styles.Style
counterweight.styles.Flex
position
class-attribute
instance-attribute
align_self
class-attribute
instance-attribute
align_self: Literal[
"none", "start", "center", "end", "stretch"
] = "none"
justify_children
class-attribute
instance-attribute
justify_children: Literal[
"start",
"center",
"end",
"space-between",
"space-around",
"space-evenly",
] = "start"
align_children
class-attribute
instance-attribute
align_children: Literal[
"start", "center", "end", "stretch"
] = "start"
counterweight.styles.Span
counterweight.styles.Margin
counterweight.styles.Border
edges
class-attribute
instance-attribute
counterweight.styles.Padding
counterweight.styles.Typography
counterweight.styles.Color
counterweight.styles.CellStyle
counterweight.styles.Relative
Relative positioning is relative to the parent element's content box. Elements occupy space and are laid out next to their siblings according to the parent's layout direction.
counterweight.styles.Absolute
Absolute positioning is relative to the parent element's content box, but the element does not occupy space in the layout.
The inset
property determines which corner of the
parent element's content box this element is positioned relative to.