@utilitywarehouse/hearth-react 0.28.6 → 0.29.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +34 -20
- package/SKILL.md +355 -0
- package/dist/{chunk-O7RBVBMN.cjs → chunk-LWHIBSW2.cjs} +2 -2
- package/dist/{chunk-O7RBVBMN.cjs.map → chunk-LWHIBSW2.cjs.map} +1 -1
- package/dist/{chunk-JRVYOIXR.js → chunk-MIVYZGEV.js} +2 -2
- package/dist/components/CardAccordion/CardAccordion.context.d.ts.map +1 -1
- package/dist/components/Combobox/Combobox.cjs +1 -1
- package/dist/components/Combobox/Combobox.js +1 -1
- package/dist/components/ExpandableCard/ExpandableCard.cjs +1 -1
- package/dist/components/ExpandableCard/ExpandableCard.js +1 -1
- package/dist/helpers/get-classname-styles.d.ts.map +1 -1
- package/dist/helpers/logger.d.ts.map +1 -1
- package/dist/helpers/merge-ids.d.ts.map +1 -1
- package/dist/hooks/use-ids.d.ts.map +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +1 -1
- package/package.json +18 -12
- package/public/llms/components/accordion.md +321 -0
- package/public/llms/components/alert.md +217 -0
- package/public/llms/components/avatar.md +112 -0
- package/public/llms/components/badge.md +158 -0
- package/public/llms/components/body-text.md +200 -0
- package/public/llms/components/box.md +148 -0
- package/public/llms/components/breadcrumbs.md +97 -0
- package/public/llms/components/button.md +595 -0
- package/public/llms/components/card-accordion.md +277 -0
- package/public/llms/components/card.md +985 -0
- package/public/llms/components/checkbox-group.md +193 -0
- package/public/llms/components/checkbox-tile.md +116 -0
- package/public/llms/components/checkbox.md +108 -0
- package/public/llms/components/combobox.md +360 -0
- package/public/llms/components/container.md +162 -0
- package/public/llms/components/currency-input.md +85 -0
- package/public/llms/components/date-input.md +90 -0
- package/public/llms/components/date-picker.md +159 -0
- package/public/llms/components/description-list.md +149 -0
- package/public/llms/components/detail-text.md +89 -0
- package/public/llms/components/divider.md +88 -0
- package/public/llms/components/em.md +43 -0
- package/public/llms/components/expandable-card.md +231 -0
- package/public/llms/components/flex.md +197 -0
- package/public/llms/components/grid.md +244 -0
- package/public/llms/components/heading.md +65 -0
- package/public/llms/components/helper-text.md +27 -0
- package/public/llms/components/highlight-banner.md +94 -0
- package/public/llms/components/icon-button.md +516 -0
- package/public/llms/components/icon-container.md +247 -0
- package/public/llms/components/inline-link.md +190 -0
- package/public/llms/components/label.md +28 -0
- package/public/llms/components/link.md +236 -0
- package/public/llms/components/list.md +715 -0
- package/public/llms/components/menu.md +270 -0
- package/public/llms/components/modal.md +328 -0
- package/public/llms/components/pagination.md +138 -0
- package/public/llms/components/password-input.md +93 -0
- package/public/llms/components/progress-bar.md +139 -0
- package/public/llms/components/progress-stepper.md +147 -0
- package/public/llms/components/radio-group.md +487 -0
- package/public/llms/components/search-input.md +132 -0
- package/public/llms/components/section-header.md +82 -0
- package/public/llms/components/select.md +148 -0
- package/public/llms/components/skeleton.md +282 -0
- package/public/llms/components/spinner.md +59 -0
- package/public/llms/components/strong.md +49 -0
- package/public/llms/components/switch.md +106 -0
- package/public/llms/components/table.md +230 -0
- package/public/llms/components/tabs.md +320 -0
- package/public/llms/components/text-area.md +141 -0
- package/public/llms/components/text-input.md +228 -0
- package/public/llms/components/toast.md +323 -0
- package/public/llms/components/toggle-button-card.md +513 -0
- package/public/llms/components/tooltip.md +188 -0
- package/public/llms/components/unstyled-icon-button.md +175 -0
- package/public/llms/components/validation-text.md +29 -0
- package/public/llms/components/verification-input.md +96 -0
- package/public/llms/docs/changelog.md +1430 -0
- package/public/llms/docs/common-props/align-self.md +90 -0
- package/public/llms/docs/common-props/border.md +308 -0
- package/public/llms/docs/common-props/colour.md +221 -0
- package/public/llms/docs/common-props/flex-items.md +91 -0
- package/public/llms/docs/common-props/gap.md +111 -0
- package/public/llms/docs/common-props/grid-items.md +96 -0
- package/public/llms/docs/common-props/margin.md +105 -0
- package/public/llms/docs/common-props/opacity.md +100 -0
- package/public/llms/docs/common-props/order.md +90 -0
- package/public/llms/docs/common-props/overflow.md +89 -0
- package/public/llms/docs/common-props/padding.md +102 -0
- package/public/llms/docs/common-props/position.md +92 -0
- package/public/llms/docs/common-props/size.md +93 -0
- package/public/llms/docs/common-props/spacing.md +97 -0
- package/public/llms/docs/common-props/text.md +35 -0
- package/public/llms/docs/common-props/z-index.md +88 -0
- package/public/llms/docs/design-tokens.md +72 -0
- package/public/llms/docs/getting-started.md +117 -0
- package/public/llms/docs/layout.md +135 -0
- package/public/llms/docs/migrating.md +302 -0
- package/public/llms/docs/responsive-design/breakpoints.md +119 -0
- package/public/llms/docs/responsive-design/media-queries.md +89 -0
- package/public/llms/docs/responsive-design/responsive-props.md +37 -0
- package/public/llms.txt +97 -0
- package/scripts/init-ai.js +142 -0
- package/styles.css +2 -2
- /package/dist/{chunk-JRVYOIXR.js.map → chunk-MIVYZGEV.js.map} +0 -0
|
@@ -0,0 +1,221 @@
|
|
|
1
|
+
# Colour props
|
|
2
|
+
|
|
3
|
+
## Color
|
|
4
|
+
|
|
5
|
+
The `color` prop accepts the following semantic colour values: `primary`,
|
|
6
|
+
`secondary`, `brand`, `affirmative`, `inverted`.
|
|
7
|
+
|
|
8
|
+
```tsx
|
|
9
|
+
<Box color="primary" />
|
|
10
|
+
<Box color="secondary" />
|
|
11
|
+
<Box color="brand" />
|
|
12
|
+
<Box color="affirmative" />
|
|
13
|
+
<Box color="inverted" />
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
You can also pass any of the available Hearth prefixed CSS custom properties
|
|
17
|
+
from the Hearth Tokens library.
|
|
18
|
+
You cannot pass raw strings to the `color` prop.
|
|
19
|
+
|
|
20
|
+
```tsx
|
|
21
|
+
import { Box } from '@utilitywarehouse/hearth-react' import { semantic } from '@utilitywarehouse/hearth-tokens/browser';
|
|
22
|
+
|
|
23
|
+
// token value
|
|
24
|
+
<Box color="primary" />
|
|
25
|
+
|
|
26
|
+
// Hearth prefixed CSS custom property
|
|
27
|
+
<Box color="var(--h-color-cashback-lilac-500)" />
|
|
28
|
+
|
|
29
|
+
// Hearth browser tokens
|
|
30
|
+
<Box color={semantic.feedback.positive.foreground.subtle}/>
|
|
31
|
+
|
|
32
|
+
// This will show an error as the string pixel value is not valid
|
|
33
|
+
// <Box color='rebeccapurple'/>
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
| Prop | Type | Default | Description |
|
|
37
|
+
| ----------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------- | ---------------------------------------- |
|
|
38
|
+
| `asChild` | `boolean` | — | |
|
|
39
|
+
| `display` | `Responsive<"none" \| "inline" \| "inline-block" \| "block">` | — | |
|
|
40
|
+
| `alignSelf` | `Responsive<"center" \| "start" \| "end" \| "stretch">` | — | |
|
|
41
|
+
| `backgroundColor` | `"primary" \| "secondary" \| "brand" \| `var(--h-${string})`` | — | |
|
|
42
|
+
| `borderColor` | `"strong" \| `var(--h-${string})` \| "subtle"` | — | |
|
|
43
|
+
| `borderTopColor` | `"strong" \| `var(--h-${string})` \| "subtle"` | — | |
|
|
44
|
+
| `borderRightColor` | `"strong" \| `var(--h-${string})` \| "subtle"` | — | |
|
|
45
|
+
| `borderBottomColor` | `"strong" \| `var(--h-${string})` \| "subtle"` | — | |
|
|
46
|
+
| `borderLeftColor` | `"strong" \| `var(--h-${string})` \| "subtle"` | — | |
|
|
47
|
+
| `borderRadius` | `Responsive<"none" \| "xs" \| "sm" \| "md" \| "lg" \| "xl" \| "full" \| "inherit">` | — | |
|
|
48
|
+
| `borderRadiusTopLeftNone` | `boolean` | — | |
|
|
49
|
+
| `borderRadiusTopRightNone` | `boolean` | — | |
|
|
50
|
+
| `borderRadiusBottomLeftNone` | `boolean` | — | |
|
|
51
|
+
| `borderRadiusBottomRightNone` | `boolean` | — | |
|
|
52
|
+
| `borderRadiusTopNone` | `boolean` | — | |
|
|
53
|
+
| `borderRadiusRightNone` | `boolean` | — | |
|
|
54
|
+
| `borderRadiusBottomNone` | `boolean` | — | |
|
|
55
|
+
| `borderRadiusLeftNone` | `boolean` | — | |
|
|
56
|
+
| `borderStyle` | `Responsive<"none" \| "solid">` | — | |
|
|
57
|
+
| `borderTopStyle` | `Responsive<"none" \| "solid">` | — | |
|
|
58
|
+
| `borderRightStyle` | `Responsive<"none" \| "solid">` | — | |
|
|
59
|
+
| `borderBottomStyle` | `Responsive<"none" \| "solid">` | — | |
|
|
60
|
+
| `borderLeftStyle` | `Responsive<"none" \| "solid">` | — | |
|
|
61
|
+
| `borderWidth` | `Responsive<"0" \| "1" \| "2">` | — | |
|
|
62
|
+
| `borderTopWidth` | `Responsive<"0" \| "1" \| "2">` | — | |
|
|
63
|
+
| `borderRightWidth` | `Responsive<"0" \| "1" \| "2">` | — | |
|
|
64
|
+
| `borderBottomWidth` | `Responsive<"0" \| "1" \| "2">` | — | |
|
|
65
|
+
| `borderLeftWidth` | `Responsive<"0" \| "1" \| "2">` | — | |
|
|
66
|
+
| `color` | `"primary" \| "secondary" \| "brand" \| "affirmative" \| "inverted" \| `var(--h-${string})`` | — | |
|
|
67
|
+
| `flex` | `Responsive<string>` | — | |
|
|
68
|
+
| `flexBasis` | `Responsive<string>` | — | |
|
|
69
|
+
| `flexShrink` | `Responsive<string>` | — | |
|
|
70
|
+
| `flexGrow` | `Responsive<string>` | — | |
|
|
71
|
+
| `gridColumnSpan` | `Responsive<Union<string, "1" \| "2" \| "3" \| "4" \| "5" \| "6" \| "7" \| "8" \| "9" \| "10" \| "11" \| "12">>` | — | |
|
|
72
|
+
| `gridArea` | `Responsive<string>` | — | |
|
|
73
|
+
| `gridColumn` | `Responsive<string>` | — | |
|
|
74
|
+
| `gridColumnStart` | `Responsive<string>` | — | |
|
|
75
|
+
| `gridColumnEnd` | `Responsive<string>` | — | |
|
|
76
|
+
| `gridRow` | `Responsive<string>` | — | |
|
|
77
|
+
| `gridRowStart` | `Responsive<string>` | — | |
|
|
78
|
+
| `gridRowEnd` | `Responsive<string>` | — | |
|
|
79
|
+
| `margin` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
80
|
+
| `marginTop` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
81
|
+
| `marginRight` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
82
|
+
| `marginBottom` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
83
|
+
| `marginLeft` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
84
|
+
| `marginX` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
85
|
+
| `marginY` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
86
|
+
| `opacity` | `Responsive<string>` | — | |
|
|
87
|
+
| `order` | `Responsive<string>` | — | |
|
|
88
|
+
| `overflow` | `Responsive<"hidden" \| "auto" \| "visible" \| "clip" \| "scroll">` | — | |
|
|
89
|
+
| `overflowX` | `Responsive<"hidden" \| "auto" \| "visible" \| "clip" \| "scroll">` | — | |
|
|
90
|
+
| `overflowY` | `Responsive<"hidden" \| "auto" \| "visible" \| "clip" \| "scroll">` | — | |
|
|
91
|
+
| `padding` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
92
|
+
| `paddingTop` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
93
|
+
| `paddingRight` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
94
|
+
| `paddingBottom` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
95
|
+
| `paddingLeft` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
96
|
+
| `paddingX` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
97
|
+
| `paddingY` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
98
|
+
| `position` | `Responsive<"fixed" \| "static" \| "relative" \| "absolute" \| "sticky">` | — | |
|
|
99
|
+
| `inset` | `Responsive<Union<string, "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">>` | — | |
|
|
100
|
+
| `top` | `Responsive<Union<string, "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">>` | — | |
|
|
101
|
+
| `right` | `Responsive<Union<string, "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">>` | — | |
|
|
102
|
+
| `bottom` | `Responsive<Union<string, "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">>` | — | |
|
|
103
|
+
| `left` | `Responsive<Union<string, "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">>` | — | |
|
|
104
|
+
| `width` | `Responsive<string>` | — | |
|
|
105
|
+
| `maxWidth` | `Responsive<string>` | — | |
|
|
106
|
+
| `minWidth` | `Responsive<string>` | — | |
|
|
107
|
+
| `height` | `Responsive<string>` | — | |
|
|
108
|
+
| `maxHeight` | `Responsive<string>` | — | |
|
|
109
|
+
| `minHeight` | `Responsive<string>` | — | |
|
|
110
|
+
| `textAlign` | `Responsive<"center" \| "right" \| "left">` | — | |
|
|
111
|
+
| `textTransform` | `"none" \| "uppercase" \| "lowercase" \| "capitalize"` | — | Set the text-transform on the component. |
|
|
112
|
+
| `zIndex` | `Responsive<string>` | — | |
|
|
113
|
+
| `as` | `"div" \| "span"` | — | |
|
|
114
|
+
|
|
115
|
+
## Background colour
|
|
116
|
+
|
|
117
|
+
The `backgroundColor` prop accepts the following semantic colour values: `primary`, `secondary`, `brand`.
|
|
118
|
+
|
|
119
|
+
```tsx
|
|
120
|
+
<Box backgroundColor="primary" />
|
|
121
|
+
<Box backgroundColor="secondary" />
|
|
122
|
+
<Box backgroundColor="brand" />
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
You can also pass any of the available Hearth prefixed CSS custom properties from the Hearth Tokens library.
|
|
126
|
+
You cannot pass raw strings to the `backgroundColor` prop.
|
|
127
|
+
|
|
128
|
+
```tsx
|
|
129
|
+
import { Box } from '@utilitywarehouse/hearth-react' import { semantic } from '@utilitywarehouse/hearth-tokens/browser';
|
|
130
|
+
|
|
131
|
+
// token value
|
|
132
|
+
<Box backgroundColor="primary" />
|
|
133
|
+
|
|
134
|
+
// Hearth prefixed CSS custom property
|
|
135
|
+
<Box backgroundColor="var(--h-color-cashback-lilac-200)" />
|
|
136
|
+
|
|
137
|
+
// Hearth browser tokens
|
|
138
|
+
<Box backgroundColor={semantic.feedback.positive.surface.subtle}/>
|
|
139
|
+
|
|
140
|
+
// This will show an error as the string pixel value is not valid
|
|
141
|
+
// <Box backgroundColor='rebeccapurple'/>
|
|
142
|
+
```
|
|
143
|
+
|
|
144
|
+
| Prop | Type | Default | Description |
|
|
145
|
+
| ----------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------- | ---------------------------------------- |
|
|
146
|
+
| `asChild` | `boolean` | — | |
|
|
147
|
+
| `display` | `Responsive<"none" \| "inline" \| "inline-block" \| "block">` | — | |
|
|
148
|
+
| `alignSelf` | `Responsive<"center" \| "start" \| "end" \| "stretch">` | — | |
|
|
149
|
+
| `backgroundColor` | `"primary" \| "secondary" \| "brand" \| `var(--h-${string})`` | — | |
|
|
150
|
+
| `borderColor` | `"strong" \| `var(--h-${string})` \| "subtle"` | — | |
|
|
151
|
+
| `borderTopColor` | `"strong" \| `var(--h-${string})` \| "subtle"` | — | |
|
|
152
|
+
| `borderRightColor` | `"strong" \| `var(--h-${string})` \| "subtle"` | — | |
|
|
153
|
+
| `borderBottomColor` | `"strong" \| `var(--h-${string})` \| "subtle"` | — | |
|
|
154
|
+
| `borderLeftColor` | `"strong" \| `var(--h-${string})` \| "subtle"` | — | |
|
|
155
|
+
| `borderRadius` | `Responsive<"none" \| "xs" \| "sm" \| "md" \| "lg" \| "xl" \| "full" \| "inherit">` | — | |
|
|
156
|
+
| `borderRadiusTopLeftNone` | `boolean` | — | |
|
|
157
|
+
| `borderRadiusTopRightNone` | `boolean` | — | |
|
|
158
|
+
| `borderRadiusBottomLeftNone` | `boolean` | — | |
|
|
159
|
+
| `borderRadiusBottomRightNone` | `boolean` | — | |
|
|
160
|
+
| `borderRadiusTopNone` | `boolean` | — | |
|
|
161
|
+
| `borderRadiusRightNone` | `boolean` | — | |
|
|
162
|
+
| `borderRadiusBottomNone` | `boolean` | — | |
|
|
163
|
+
| `borderRadiusLeftNone` | `boolean` | — | |
|
|
164
|
+
| `borderStyle` | `Responsive<"none" \| "solid">` | — | |
|
|
165
|
+
| `borderTopStyle` | `Responsive<"none" \| "solid">` | — | |
|
|
166
|
+
| `borderRightStyle` | `Responsive<"none" \| "solid">` | — | |
|
|
167
|
+
| `borderBottomStyle` | `Responsive<"none" \| "solid">` | — | |
|
|
168
|
+
| `borderLeftStyle` | `Responsive<"none" \| "solid">` | — | |
|
|
169
|
+
| `borderWidth` | `Responsive<"0" \| "1" \| "2">` | — | |
|
|
170
|
+
| `borderTopWidth` | `Responsive<"0" \| "1" \| "2">` | — | |
|
|
171
|
+
| `borderRightWidth` | `Responsive<"0" \| "1" \| "2">` | — | |
|
|
172
|
+
| `borderBottomWidth` | `Responsive<"0" \| "1" \| "2">` | — | |
|
|
173
|
+
| `borderLeftWidth` | `Responsive<"0" \| "1" \| "2">` | — | |
|
|
174
|
+
| `color` | `"primary" \| "secondary" \| "brand" \| "affirmative" \| "inverted" \| `var(--h-${string})`` | — | |
|
|
175
|
+
| `flex` | `Responsive<string>` | — | |
|
|
176
|
+
| `flexBasis` | `Responsive<string>` | — | |
|
|
177
|
+
| `flexShrink` | `Responsive<string>` | — | |
|
|
178
|
+
| `flexGrow` | `Responsive<string>` | — | |
|
|
179
|
+
| `gridColumnSpan` | `Responsive<Union<string, "1" \| "2" \| "3" \| "4" \| "5" \| "6" \| "7" \| "8" \| "9" \| "10" \| "11" \| "12">>` | — | |
|
|
180
|
+
| `gridArea` | `Responsive<string>` | — | |
|
|
181
|
+
| `gridColumn` | `Responsive<string>` | — | |
|
|
182
|
+
| `gridColumnStart` | `Responsive<string>` | — | |
|
|
183
|
+
| `gridColumnEnd` | `Responsive<string>` | — | |
|
|
184
|
+
| `gridRow` | `Responsive<string>` | — | |
|
|
185
|
+
| `gridRowStart` | `Responsive<string>` | — | |
|
|
186
|
+
| `gridRowEnd` | `Responsive<string>` | — | |
|
|
187
|
+
| `margin` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
188
|
+
| `marginTop` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
189
|
+
| `marginRight` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
190
|
+
| `marginBottom` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
191
|
+
| `marginLeft` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
192
|
+
| `marginX` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
193
|
+
| `marginY` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
194
|
+
| `opacity` | `Responsive<string>` | — | |
|
|
195
|
+
| `order` | `Responsive<string>` | — | |
|
|
196
|
+
| `overflow` | `Responsive<"hidden" \| "auto" \| "visible" \| "clip" \| "scroll">` | — | |
|
|
197
|
+
| `overflowX` | `Responsive<"hidden" \| "auto" \| "visible" \| "clip" \| "scroll">` | — | |
|
|
198
|
+
| `overflowY` | `Responsive<"hidden" \| "auto" \| "visible" \| "clip" \| "scroll">` | — | |
|
|
199
|
+
| `padding` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
200
|
+
| `paddingTop` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
201
|
+
| `paddingRight` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
202
|
+
| `paddingBottom` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
203
|
+
| `paddingLeft` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
204
|
+
| `paddingX` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
205
|
+
| `paddingY` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
206
|
+
| `position` | `Responsive<"fixed" \| "static" \| "relative" \| "absolute" \| "sticky">` | — | |
|
|
207
|
+
| `inset` | `Responsive<Union<string, "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">>` | — | |
|
|
208
|
+
| `top` | `Responsive<Union<string, "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">>` | — | |
|
|
209
|
+
| `right` | `Responsive<Union<string, "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">>` | — | |
|
|
210
|
+
| `bottom` | `Responsive<Union<string, "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">>` | — | |
|
|
211
|
+
| `left` | `Responsive<Union<string, "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">>` | — | |
|
|
212
|
+
| `width` | `Responsive<string>` | — | |
|
|
213
|
+
| `maxWidth` | `Responsive<string>` | — | |
|
|
214
|
+
| `minWidth` | `Responsive<string>` | — | |
|
|
215
|
+
| `height` | `Responsive<string>` | — | |
|
|
216
|
+
| `maxHeight` | `Responsive<string>` | — | |
|
|
217
|
+
| `minHeight` | `Responsive<string>` | — | |
|
|
218
|
+
| `textAlign` | `Responsive<"center" \| "right" \| "left">` | — | |
|
|
219
|
+
| `textTransform` | `"none" \| "uppercase" \| "lowercase" \| "capitalize"` | — | Set the text-transform on the component. |
|
|
220
|
+
| `zIndex` | `Responsive<string>` | — | |
|
|
221
|
+
| `as` | `"div" \| "span"` | — | |
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
# Flex items
|
|
2
|
+
|
|
3
|
+
Flex item props enable styling on components when they are children of a flexbox container.
|
|
4
|
+
|
|
5
|
+
```tsx
|
|
6
|
+
<Flex>
|
|
7
|
+
<Box flex="1 1 0%" />
|
|
8
|
+
<Box flexBasis="0" />
|
|
9
|
+
<Box flexShrink="3" />
|
|
10
|
+
<Box flexGrow={{ mobile: 0, desktop: 1 }} />
|
|
11
|
+
</Flex>
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
| Prop | Type | Default | Description |
|
|
15
|
+
| ----------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------- | ---------------------------------------- |
|
|
16
|
+
| `asChild` | `boolean` | — | |
|
|
17
|
+
| `display` | `Responsive<"none" \| "inline" \| "inline-block" \| "block">` | — | |
|
|
18
|
+
| `alignSelf` | `Responsive<"center" \| "start" \| "end" \| "stretch">` | — | |
|
|
19
|
+
| `backgroundColor` | `"primary" \| "secondary" \| "brand" \| `var(--h-${string})`` | — | |
|
|
20
|
+
| `borderColor` | `"strong" \| `var(--h-${string})` \| "subtle"` | — | |
|
|
21
|
+
| `borderTopColor` | `"strong" \| `var(--h-${string})` \| "subtle"` | — | |
|
|
22
|
+
| `borderRightColor` | `"strong" \| `var(--h-${string})` \| "subtle"` | — | |
|
|
23
|
+
| `borderBottomColor` | `"strong" \| `var(--h-${string})` \| "subtle"` | — | |
|
|
24
|
+
| `borderLeftColor` | `"strong" \| `var(--h-${string})` \| "subtle"` | — | |
|
|
25
|
+
| `borderRadius` | `Responsive<"none" \| "xs" \| "sm" \| "md" \| "lg" \| "xl" \| "full" \| "inherit">` | — | |
|
|
26
|
+
| `borderRadiusTopLeftNone` | `boolean` | — | |
|
|
27
|
+
| `borderRadiusTopRightNone` | `boolean` | — | |
|
|
28
|
+
| `borderRadiusBottomLeftNone` | `boolean` | — | |
|
|
29
|
+
| `borderRadiusBottomRightNone` | `boolean` | — | |
|
|
30
|
+
| `borderRadiusTopNone` | `boolean` | — | |
|
|
31
|
+
| `borderRadiusRightNone` | `boolean` | — | |
|
|
32
|
+
| `borderRadiusBottomNone` | `boolean` | — | |
|
|
33
|
+
| `borderRadiusLeftNone` | `boolean` | — | |
|
|
34
|
+
| `borderStyle` | `Responsive<"none" \| "solid">` | — | |
|
|
35
|
+
| `borderTopStyle` | `Responsive<"none" \| "solid">` | — | |
|
|
36
|
+
| `borderRightStyle` | `Responsive<"none" \| "solid">` | — | |
|
|
37
|
+
| `borderBottomStyle` | `Responsive<"none" \| "solid">` | — | |
|
|
38
|
+
| `borderLeftStyle` | `Responsive<"none" \| "solid">` | — | |
|
|
39
|
+
| `borderWidth` | `Responsive<"0" \| "1" \| "2">` | — | |
|
|
40
|
+
| `borderTopWidth` | `Responsive<"0" \| "1" \| "2">` | — | |
|
|
41
|
+
| `borderRightWidth` | `Responsive<"0" \| "1" \| "2">` | — | |
|
|
42
|
+
| `borderBottomWidth` | `Responsive<"0" \| "1" \| "2">` | — | |
|
|
43
|
+
| `borderLeftWidth` | `Responsive<"0" \| "1" \| "2">` | — | |
|
|
44
|
+
| `color` | `"primary" \| "secondary" \| "brand" \| "affirmative" \| "inverted" \| `var(--h-${string})`` | — | |
|
|
45
|
+
| `flex` | `Responsive<string>` | — | |
|
|
46
|
+
| `flexBasis` | `Responsive<string>` | — | |
|
|
47
|
+
| `flexShrink` | `Responsive<string>` | — | |
|
|
48
|
+
| `flexGrow` | `Responsive<string>` | — | |
|
|
49
|
+
| `gridColumnSpan` | `Responsive<Union<string, "1" \| "2" \| "3" \| "4" \| "5" \| "6" \| "7" \| "8" \| "9" \| "10" \| "11" \| "12">>` | — | |
|
|
50
|
+
| `gridArea` | `Responsive<string>` | — | |
|
|
51
|
+
| `gridColumn` | `Responsive<string>` | — | |
|
|
52
|
+
| `gridColumnStart` | `Responsive<string>` | — | |
|
|
53
|
+
| `gridColumnEnd` | `Responsive<string>` | — | |
|
|
54
|
+
| `gridRow` | `Responsive<string>` | — | |
|
|
55
|
+
| `gridRowStart` | `Responsive<string>` | — | |
|
|
56
|
+
| `gridRowEnd` | `Responsive<string>` | — | |
|
|
57
|
+
| `margin` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
58
|
+
| `marginTop` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
59
|
+
| `marginRight` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
60
|
+
| `marginBottom` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
61
|
+
| `marginLeft` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
62
|
+
| `marginX` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
63
|
+
| `marginY` | `Responsive<`var(--h-${string})` \| "0" \| "auto" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
64
|
+
| `opacity` | `Responsive<string>` | — | |
|
|
65
|
+
| `order` | `Responsive<string>` | — | |
|
|
66
|
+
| `overflow` | `Responsive<"hidden" \| "auto" \| "visible" \| "clip" \| "scroll">` | — | |
|
|
67
|
+
| `overflowX` | `Responsive<"hidden" \| "auto" \| "visible" \| "clip" \| "scroll">` | — | |
|
|
68
|
+
| `overflowY` | `Responsive<"hidden" \| "auto" \| "visible" \| "clip" \| "scroll">` | — | |
|
|
69
|
+
| `padding` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
70
|
+
| `paddingTop` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
71
|
+
| `paddingRight` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
72
|
+
| `paddingBottom` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
73
|
+
| `paddingLeft` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
74
|
+
| `paddingX` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
75
|
+
| `paddingY` | `Responsive<`var(--h-${string})` \| "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">` | — | |
|
|
76
|
+
| `position` | `Responsive<"fixed" \| "static" \| "relative" \| "absolute" \| "sticky">` | — | |
|
|
77
|
+
| `inset` | `Responsive<Union<string, "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">>` | — | |
|
|
78
|
+
| `top` | `Responsive<Union<string, "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">>` | — | |
|
|
79
|
+
| `right` | `Responsive<Union<string, "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">>` | — | |
|
|
80
|
+
| `bottom` | `Responsive<Union<string, "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">>` | — | |
|
|
81
|
+
| `left` | `Responsive<Union<string, "0" \| "25" \| "50" \| "75" \| "100" \| "150" \| "175" \| "200" \| "250" \| "300" \| "350" \| "400" \| "500" \| "600" \| "700" \| "800" \| "900" \| "1000">>` | — | |
|
|
82
|
+
| `width` | `Responsive<string>` | — | |
|
|
83
|
+
| `maxWidth` | `Responsive<string>` | — | |
|
|
84
|
+
| `minWidth` | `Responsive<string>` | — | |
|
|
85
|
+
| `height` | `Responsive<string>` | — | |
|
|
86
|
+
| `maxHeight` | `Responsive<string>` | — | |
|
|
87
|
+
| `minHeight` | `Responsive<string>` | — | |
|
|
88
|
+
| `textAlign` | `Responsive<"center" \| "right" \| "left">` | — | |
|
|
89
|
+
| `textTransform` | `"none" \| "uppercase" \| "lowercase" \| "capitalize"` | — | Set the text-transform on the component. |
|
|
90
|
+
| `zIndex` | `Responsive<string>` | — | |
|
|
91
|
+
| `as` | `"div" \| "span"` | — | |
|