@lets-events/react 10.0.1 → 10.1.1
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/.eslintrc.json +2 -2
- package/.turbo/turbo-build.log +19 -18
- package/CHANGELOG.md +12 -0
- package/dist/index.d.mts +426 -1
- package/dist/index.d.ts +426 -1
- package/dist/index.js +340 -20
- package/dist/index.mjs +331 -19
- package/package.json +3 -1
- package/src/components/Alert.tsx +303 -303
- package/src/components/Avatar.tsx +55 -55
- package/src/components/Badge.tsx +128 -128
- package/src/components/Box.tsx +3 -3
- package/src/components/Button/index.tsx +12 -12
- package/src/components/Button/styledComponents.ts +250 -250
- package/src/components/ButtonGroup.tsx +484 -484
- package/src/components/Calendar/index.tsx +136 -136
- package/src/components/Calendar/styledComponents.ts +208 -208
- package/src/components/Card.tsx +69 -69
- package/src/components/CheckboxGroup.tsx +214 -214
- package/src/components/Container.tsx +39 -39
- package/src/components/Dropdown.tsx +167 -167
- package/src/components/Filter.tsx +164 -164
- package/src/components/Flex.tsx +118 -118
- package/src/components/Grid.tsx +137 -137
- package/src/components/Icon.tsx +47 -47
- package/src/components/Modal.tsx +90 -90
- package/src/components/RadioGroup.tsx +210 -210
- package/src/components/Section.tsx +33 -33
- package/src/components/Step.tsx +164 -164
- package/src/components/Switch.tsx +108 -108
- package/src/components/Text.tsx +30 -30
- package/src/components/TextField.tsx +299 -299
- package/src/components/TextareaField.tsx +101 -101
- package/src/components/TimePicker.tsx +280 -239
- package/src/components/Toast/components/ToastItem.tsx +41 -0
- package/src/components/Toast/components/ToastProvider.tsx +63 -0
- package/src/components/Toast/hooks/useToast.ts +12 -0
- package/src/components/Toast/index.tsx +5 -0
- package/src/components/Toast/styles/index.ts +135 -0
- package/src/components/Toast/types/index.ts +46 -0
- package/src/components/Tooltip/index.tsx +67 -0
- package/src/components/Tooltip/styles.ts +78 -0
- package/src/hooks/useOnClickOutside.tsx +20 -20
- package/src/index.tsx +33 -31
- package/src/styles/index.ts +38 -38
- package/src/types/typographyValues.ts +178 -178
- package/tsconfig.json +3 -3
|
@@ -1,214 +1,214 @@
|
|
|
1
|
-
import { ComponentProps } from 'react'
|
|
2
|
-
import { styled } from '../styles'
|
|
3
|
-
import { CheckboxGroup as CheckboxGroupRadix } from "@radix-ui/themes";
|
|
4
|
-
import { typographyLabelValues } from "../types/typographyValues";
|
|
5
|
-
|
|
6
|
-
export const CheckboxGroupStyled = styled(CheckboxGroupRadix.Root, {
|
|
7
|
-
fontFamily: '$default',
|
|
8
|
-
'svg': {
|
|
9
|
-
display: 'none'
|
|
10
|
-
},
|
|
11
|
-
'label': {
|
|
12
|
-
display: 'flex',
|
|
13
|
-
alignItems: 'center',
|
|
14
|
-
gap: '$8',
|
|
15
|
-
cursor: 'pointer',
|
|
16
|
-
'&:focus button, &:hover button': {
|
|
17
|
-
transition: 'all 300ms ease-out',
|
|
18
|
-
boxShadow: '0px 0px 0px 4px rgba(56, 129, 255, 0.50)'
|
|
19
|
-
}
|
|
20
|
-
},
|
|
21
|
-
'label button': {
|
|
22
|
-
backgroundColor: '$white',
|
|
23
|
-
borderRadius: '2px',
|
|
24
|
-
height: '$16',
|
|
25
|
-
width: '$16',
|
|
26
|
-
position: 'relative',
|
|
27
|
-
border: '2px solid $dark300',
|
|
28
|
-
cursor: 'pointer',
|
|
29
|
-
},
|
|
30
|
-
'label button[data-state=checked]:before': {
|
|
31
|
-
backgroundColor: '$dark50',
|
|
32
|
-
content: '',
|
|
33
|
-
width: '8px',
|
|
34
|
-
height: '8px',
|
|
35
|
-
position: 'absolute',
|
|
36
|
-
top: '2px',
|
|
37
|
-
right: '2px',
|
|
38
|
-
zIndex: 2,
|
|
39
|
-
},
|
|
40
|
-
'label button[data-state=checked]:after': {
|
|
41
|
-
backgroundColor: '$brand500',
|
|
42
|
-
content: '',
|
|
43
|
-
height: '$16',
|
|
44
|
-
width: '$16',
|
|
45
|
-
position: 'absolute',
|
|
46
|
-
top: '-2px',
|
|
47
|
-
right: '-2px',
|
|
48
|
-
borderRadius: '2px',
|
|
49
|
-
zIndex: 1,
|
|
50
|
-
},
|
|
51
|
-
|
|
52
|
-
variants: {
|
|
53
|
-
color: {
|
|
54
|
-
success: {
|
|
55
|
-
'label': {
|
|
56
|
-
'&:focus button, &:hover button': {
|
|
57
|
-
boxShadow: '0px 0px 0px 4px rgba(38, 167, 67, 0.50)',
|
|
58
|
-
}
|
|
59
|
-
},
|
|
60
|
-
'label button': {
|
|
61
|
-
borderColor: '$green500',
|
|
62
|
-
backgroundColor: '$dark50',
|
|
63
|
-
},
|
|
64
|
-
'label button[data-state=checked]:after': {
|
|
65
|
-
backgroundColor: '$green500',
|
|
66
|
-
},
|
|
67
|
-
},
|
|
68
|
-
blue: {},
|
|
69
|
-
error: {
|
|
70
|
-
'label': {
|
|
71
|
-
'&:focus button, &:hover button': {
|
|
72
|
-
boxShadow: '0px 0px 0px 4px rgba(225, 86, 98, 0.50)'
|
|
73
|
-
}
|
|
74
|
-
},
|
|
75
|
-
'label button': {
|
|
76
|
-
borderColor: '$error400',
|
|
77
|
-
backgroundColor: '$dark50',
|
|
78
|
-
},
|
|
79
|
-
'label button[data-state=checked]:after': {
|
|
80
|
-
backgroundColor: '$error600',
|
|
81
|
-
},
|
|
82
|
-
}
|
|
83
|
-
},
|
|
84
|
-
disabled: {
|
|
85
|
-
true: {
|
|
86
|
-
'label': {
|
|
87
|
-
cursor: 'not-allowed',
|
|
88
|
-
opacity: 0.5,
|
|
89
|
-
'&:focus button, &:hover button': {
|
|
90
|
-
boxShadow: 'none',
|
|
91
|
-
}
|
|
92
|
-
},
|
|
93
|
-
'label button': {
|
|
94
|
-
cursor: 'not-allowed',
|
|
95
|
-
}
|
|
96
|
-
},
|
|
97
|
-
false: {}
|
|
98
|
-
},
|
|
99
|
-
typography: typographyLabelValues,
|
|
100
|
-
fontWeight: {
|
|
101
|
-
regular: { fontWeight: '$regular' },
|
|
102
|
-
medium: { fontWeight: '$medium' },
|
|
103
|
-
semibold: { fontWeight: '$semibold' },
|
|
104
|
-
bold: { fontWeight: '$bold' },
|
|
105
|
-
},
|
|
106
|
-
},
|
|
107
|
-
|
|
108
|
-
compoundVariants: [
|
|
109
|
-
|
|
110
|
-
{
|
|
111
|
-
color: 'blue',
|
|
112
|
-
disabled: false,
|
|
113
|
-
css: {
|
|
114
|
-
'label': {
|
|
115
|
-
'&:focus button, &:hover button': {
|
|
116
|
-
boxShadow: '0px 0px 0px 4px rgba(56, 129, 255, 0.50)'
|
|
117
|
-
}
|
|
118
|
-
},
|
|
119
|
-
'label button': {
|
|
120
|
-
borderColor: '$dark300',
|
|
121
|
-
},
|
|
122
|
-
'label button[data-state=checked]:after': {
|
|
123
|
-
backgroundColor: '$brand500',
|
|
124
|
-
},
|
|
125
|
-
}
|
|
126
|
-
},
|
|
127
|
-
|
|
128
|
-
{
|
|
129
|
-
color: 'blue',
|
|
130
|
-
disabled: true,
|
|
131
|
-
css: {
|
|
132
|
-
'label button': {
|
|
133
|
-
borderColor: '$brand100',
|
|
134
|
-
backgroundColor: '$dark50',
|
|
135
|
-
},
|
|
136
|
-
'label button[data-state=checked]:after': {
|
|
137
|
-
backgroundColor: '$brand100',
|
|
138
|
-
},
|
|
139
|
-
}
|
|
140
|
-
},
|
|
141
|
-
|
|
142
|
-
{
|
|
143
|
-
color: 'success',
|
|
144
|
-
disabled: true,
|
|
145
|
-
css: {
|
|
146
|
-
'label button': {
|
|
147
|
-
borderColor: '$success100',
|
|
148
|
-
backgroundColor: '$dark50',
|
|
149
|
-
},
|
|
150
|
-
'label button[data-state=checked]:after': {
|
|
151
|
-
backgroundColor: '$success100',
|
|
152
|
-
}
|
|
153
|
-
}
|
|
154
|
-
},
|
|
155
|
-
|
|
156
|
-
{
|
|
157
|
-
color: 'error',
|
|
158
|
-
disabled: true,
|
|
159
|
-
css: {
|
|
160
|
-
'label button': {
|
|
161
|
-
borderColor: '$error100',
|
|
162
|
-
backgroundColor: '$dark50',
|
|
163
|
-
},
|
|
164
|
-
'label button[data-state=checked]:after': {
|
|
165
|
-
backgroundColor: '$error100',
|
|
166
|
-
}
|
|
167
|
-
}
|
|
168
|
-
}
|
|
169
|
-
],
|
|
170
|
-
defaultVariants: {
|
|
171
|
-
color: 'blue',
|
|
172
|
-
disabled: false
|
|
173
|
-
}
|
|
174
|
-
})
|
|
175
|
-
|
|
176
|
-
export type CheckboxGroupProps = ComponentProps<typeof CheckboxGroupStyled> & {
|
|
177
|
-
placeholder?: string
|
|
178
|
-
children?: React.ReactNode
|
|
179
|
-
color?: string
|
|
180
|
-
disabled?: boolean
|
|
181
|
-
}
|
|
182
|
-
|
|
183
|
-
export type CheckboxItemProps = {
|
|
184
|
-
children?: React.ReactNode
|
|
185
|
-
value: string,
|
|
186
|
-
style?: React.CSSProperties
|
|
187
|
-
}
|
|
188
|
-
|
|
189
|
-
export function CheckboxGroup({
|
|
190
|
-
children,
|
|
191
|
-
|
|
192
|
-
...props
|
|
193
|
-
}: CheckboxGroupProps) {
|
|
194
|
-
return (
|
|
195
|
-
<CheckboxGroupStyled {...props}>
|
|
196
|
-
{children}
|
|
197
|
-
</CheckboxGroupStyled>
|
|
198
|
-
)
|
|
199
|
-
}
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
export function CheckboxItem({
|
|
203
|
-
children,
|
|
204
|
-
|
|
205
|
-
...props
|
|
206
|
-
}: CheckboxItemProps) {
|
|
207
|
-
return (
|
|
208
|
-
<CheckboxGroupRadix.Item {...props}>
|
|
209
|
-
{children}
|
|
210
|
-
</CheckboxGroupRadix.Item>
|
|
211
|
-
)
|
|
212
|
-
}
|
|
213
|
-
|
|
214
|
-
|
|
1
|
+
import { ComponentProps } from 'react'
|
|
2
|
+
import { styled } from '../styles'
|
|
3
|
+
import { CheckboxGroup as CheckboxGroupRadix } from "@radix-ui/themes";
|
|
4
|
+
import { typographyLabelValues } from "../types/typographyValues";
|
|
5
|
+
|
|
6
|
+
export const CheckboxGroupStyled = styled(CheckboxGroupRadix.Root, {
|
|
7
|
+
fontFamily: '$default',
|
|
8
|
+
'svg': {
|
|
9
|
+
display: 'none'
|
|
10
|
+
},
|
|
11
|
+
'label': {
|
|
12
|
+
display: 'flex',
|
|
13
|
+
alignItems: 'center',
|
|
14
|
+
gap: '$8',
|
|
15
|
+
cursor: 'pointer',
|
|
16
|
+
'&:focus button, &:hover button': {
|
|
17
|
+
transition: 'all 300ms ease-out',
|
|
18
|
+
boxShadow: '0px 0px 0px 4px rgba(56, 129, 255, 0.50)'
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
'label button': {
|
|
22
|
+
backgroundColor: '$white',
|
|
23
|
+
borderRadius: '2px',
|
|
24
|
+
height: '$16',
|
|
25
|
+
width: '$16',
|
|
26
|
+
position: 'relative',
|
|
27
|
+
border: '2px solid $dark300',
|
|
28
|
+
cursor: 'pointer',
|
|
29
|
+
},
|
|
30
|
+
'label button[data-state=checked]:before': {
|
|
31
|
+
backgroundColor: '$dark50',
|
|
32
|
+
content: '',
|
|
33
|
+
width: '8px',
|
|
34
|
+
height: '8px',
|
|
35
|
+
position: 'absolute',
|
|
36
|
+
top: '2px',
|
|
37
|
+
right: '2px',
|
|
38
|
+
zIndex: 2,
|
|
39
|
+
},
|
|
40
|
+
'label button[data-state=checked]:after': {
|
|
41
|
+
backgroundColor: '$brand500',
|
|
42
|
+
content: '',
|
|
43
|
+
height: '$16',
|
|
44
|
+
width: '$16',
|
|
45
|
+
position: 'absolute',
|
|
46
|
+
top: '-2px',
|
|
47
|
+
right: '-2px',
|
|
48
|
+
borderRadius: '2px',
|
|
49
|
+
zIndex: 1,
|
|
50
|
+
},
|
|
51
|
+
|
|
52
|
+
variants: {
|
|
53
|
+
color: {
|
|
54
|
+
success: {
|
|
55
|
+
'label': {
|
|
56
|
+
'&:focus button, &:hover button': {
|
|
57
|
+
boxShadow: '0px 0px 0px 4px rgba(38, 167, 67, 0.50)',
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
'label button': {
|
|
61
|
+
borderColor: '$green500',
|
|
62
|
+
backgroundColor: '$dark50',
|
|
63
|
+
},
|
|
64
|
+
'label button[data-state=checked]:after': {
|
|
65
|
+
backgroundColor: '$green500',
|
|
66
|
+
},
|
|
67
|
+
},
|
|
68
|
+
blue: {},
|
|
69
|
+
error: {
|
|
70
|
+
'label': {
|
|
71
|
+
'&:focus button, &:hover button': {
|
|
72
|
+
boxShadow: '0px 0px 0px 4px rgba(225, 86, 98, 0.50)'
|
|
73
|
+
}
|
|
74
|
+
},
|
|
75
|
+
'label button': {
|
|
76
|
+
borderColor: '$error400',
|
|
77
|
+
backgroundColor: '$dark50',
|
|
78
|
+
},
|
|
79
|
+
'label button[data-state=checked]:after': {
|
|
80
|
+
backgroundColor: '$error600',
|
|
81
|
+
},
|
|
82
|
+
}
|
|
83
|
+
},
|
|
84
|
+
disabled: {
|
|
85
|
+
true: {
|
|
86
|
+
'label': {
|
|
87
|
+
cursor: 'not-allowed',
|
|
88
|
+
opacity: 0.5,
|
|
89
|
+
'&:focus button, &:hover button': {
|
|
90
|
+
boxShadow: 'none',
|
|
91
|
+
}
|
|
92
|
+
},
|
|
93
|
+
'label button': {
|
|
94
|
+
cursor: 'not-allowed',
|
|
95
|
+
}
|
|
96
|
+
},
|
|
97
|
+
false: {}
|
|
98
|
+
},
|
|
99
|
+
typography: typographyLabelValues,
|
|
100
|
+
fontWeight: {
|
|
101
|
+
regular: { fontWeight: '$regular' },
|
|
102
|
+
medium: { fontWeight: '$medium' },
|
|
103
|
+
semibold: { fontWeight: '$semibold' },
|
|
104
|
+
bold: { fontWeight: '$bold' },
|
|
105
|
+
},
|
|
106
|
+
},
|
|
107
|
+
|
|
108
|
+
compoundVariants: [
|
|
109
|
+
|
|
110
|
+
{
|
|
111
|
+
color: 'blue',
|
|
112
|
+
disabled: false,
|
|
113
|
+
css: {
|
|
114
|
+
'label': {
|
|
115
|
+
'&:focus button, &:hover button': {
|
|
116
|
+
boxShadow: '0px 0px 0px 4px rgba(56, 129, 255, 0.50)'
|
|
117
|
+
}
|
|
118
|
+
},
|
|
119
|
+
'label button': {
|
|
120
|
+
borderColor: '$dark300',
|
|
121
|
+
},
|
|
122
|
+
'label button[data-state=checked]:after': {
|
|
123
|
+
backgroundColor: '$brand500',
|
|
124
|
+
},
|
|
125
|
+
}
|
|
126
|
+
},
|
|
127
|
+
|
|
128
|
+
{
|
|
129
|
+
color: 'blue',
|
|
130
|
+
disabled: true,
|
|
131
|
+
css: {
|
|
132
|
+
'label button': {
|
|
133
|
+
borderColor: '$brand100',
|
|
134
|
+
backgroundColor: '$dark50',
|
|
135
|
+
},
|
|
136
|
+
'label button[data-state=checked]:after': {
|
|
137
|
+
backgroundColor: '$brand100',
|
|
138
|
+
},
|
|
139
|
+
}
|
|
140
|
+
},
|
|
141
|
+
|
|
142
|
+
{
|
|
143
|
+
color: 'success',
|
|
144
|
+
disabled: true,
|
|
145
|
+
css: {
|
|
146
|
+
'label button': {
|
|
147
|
+
borderColor: '$success100',
|
|
148
|
+
backgroundColor: '$dark50',
|
|
149
|
+
},
|
|
150
|
+
'label button[data-state=checked]:after': {
|
|
151
|
+
backgroundColor: '$success100',
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
},
|
|
155
|
+
|
|
156
|
+
{
|
|
157
|
+
color: 'error',
|
|
158
|
+
disabled: true,
|
|
159
|
+
css: {
|
|
160
|
+
'label button': {
|
|
161
|
+
borderColor: '$error100',
|
|
162
|
+
backgroundColor: '$dark50',
|
|
163
|
+
},
|
|
164
|
+
'label button[data-state=checked]:after': {
|
|
165
|
+
backgroundColor: '$error100',
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
],
|
|
170
|
+
defaultVariants: {
|
|
171
|
+
color: 'blue',
|
|
172
|
+
disabled: false
|
|
173
|
+
}
|
|
174
|
+
})
|
|
175
|
+
|
|
176
|
+
export type CheckboxGroupProps = ComponentProps<typeof CheckboxGroupStyled> & {
|
|
177
|
+
placeholder?: string
|
|
178
|
+
children?: React.ReactNode
|
|
179
|
+
color?: string
|
|
180
|
+
disabled?: boolean
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
export type CheckboxItemProps = {
|
|
184
|
+
children?: React.ReactNode
|
|
185
|
+
value: string,
|
|
186
|
+
style?: React.CSSProperties
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
export function CheckboxGroup({
|
|
190
|
+
children,
|
|
191
|
+
|
|
192
|
+
...props
|
|
193
|
+
}: CheckboxGroupProps) {
|
|
194
|
+
return (
|
|
195
|
+
<CheckboxGroupStyled {...props}>
|
|
196
|
+
{children}
|
|
197
|
+
</CheckboxGroupStyled>
|
|
198
|
+
)
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
|
|
202
|
+
export function CheckboxItem({
|
|
203
|
+
children,
|
|
204
|
+
|
|
205
|
+
...props
|
|
206
|
+
}: CheckboxItemProps) {
|
|
207
|
+
return (
|
|
208
|
+
<CheckboxGroupRadix.Item {...props}>
|
|
209
|
+
{children}
|
|
210
|
+
</CheckboxGroupRadix.Item>
|
|
211
|
+
)
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
|
|
@@ -1,40 +1,40 @@
|
|
|
1
|
-
import { ComponentProps, ElementType } from 'react';
|
|
2
|
-
import { styled } from '../styles';
|
|
3
|
-
import { Container as ContainerRadix } from '@radix-ui/themes';
|
|
4
|
-
|
|
5
|
-
export const ContainerStyled = styled(ContainerRadix, {
|
|
6
|
-
variants: {
|
|
7
|
-
size: {
|
|
8
|
-
xs: { maxWidth: '576px' },
|
|
9
|
-
sm: { minWidth: '577px', maxWidth: '767px' },
|
|
10
|
-
md: { mixWidth: '768px', maxWidth: '991px' },
|
|
11
|
-
lg: { mixWidth: '992px', maxWidth: '1199px' },
|
|
12
|
-
xl: { mixWidth: '1200px', maxWidth: '1399px' },
|
|
13
|
-
xxl: { mixWidth: '1400px' },
|
|
14
|
-
responsive: { width: '100%', maxWidth: '100%', minWidth: '100%' }
|
|
15
|
-
},
|
|
16
|
-
display: {
|
|
17
|
-
none: { display: 'none' },
|
|
18
|
-
initial: { display: 'initial' },
|
|
19
|
-
},
|
|
20
|
-
align: {
|
|
21
|
-
left: { marginLeft: 0, marginRight: 'auto' },
|
|
22
|
-
center: { marginLeft: 'auto', marginRight: 'auto' },
|
|
23
|
-
right: { marginLeft: 'auto', marginRight: 0 },
|
|
24
|
-
},
|
|
25
|
-
},
|
|
26
|
-
defaultVariants: {
|
|
27
|
-
size: 'md',
|
|
28
|
-
align: 'left',
|
|
29
|
-
display: 'initial'
|
|
30
|
-
},
|
|
31
|
-
});
|
|
32
|
-
|
|
33
|
-
export type ContainerProps = ComponentProps<typeof ContainerStyled> & {
|
|
34
|
-
as?: ElementType;
|
|
35
|
-
children: React.ReactNode;
|
|
36
|
-
};
|
|
37
|
-
|
|
38
|
-
export function Container({ children, ...props }: ContainerProps) {
|
|
39
|
-
return <ContainerStyled {...props}>{children}</ContainerStyled>;
|
|
1
|
+
import { ComponentProps, ElementType } from 'react';
|
|
2
|
+
import { styled } from '../styles';
|
|
3
|
+
import { Container as ContainerRadix } from '@radix-ui/themes';
|
|
4
|
+
|
|
5
|
+
export const ContainerStyled = styled(ContainerRadix, {
|
|
6
|
+
variants: {
|
|
7
|
+
size: {
|
|
8
|
+
xs: { maxWidth: '576px' },
|
|
9
|
+
sm: { minWidth: '577px', maxWidth: '767px' },
|
|
10
|
+
md: { mixWidth: '768px', maxWidth: '991px' },
|
|
11
|
+
lg: { mixWidth: '992px', maxWidth: '1199px' },
|
|
12
|
+
xl: { mixWidth: '1200px', maxWidth: '1399px' },
|
|
13
|
+
xxl: { mixWidth: '1400px' },
|
|
14
|
+
responsive: { width: '100%', maxWidth: '100%', minWidth: '100%' }
|
|
15
|
+
},
|
|
16
|
+
display: {
|
|
17
|
+
none: { display: 'none' },
|
|
18
|
+
initial: { display: 'initial' },
|
|
19
|
+
},
|
|
20
|
+
align: {
|
|
21
|
+
left: { marginLeft: 0, marginRight: 'auto' },
|
|
22
|
+
center: { marginLeft: 'auto', marginRight: 'auto' },
|
|
23
|
+
right: { marginLeft: 'auto', marginRight: 0 },
|
|
24
|
+
},
|
|
25
|
+
},
|
|
26
|
+
defaultVariants: {
|
|
27
|
+
size: 'md',
|
|
28
|
+
align: 'left',
|
|
29
|
+
display: 'initial'
|
|
30
|
+
},
|
|
31
|
+
});
|
|
32
|
+
|
|
33
|
+
export type ContainerProps = ComponentProps<typeof ContainerStyled> & {
|
|
34
|
+
as?: ElementType;
|
|
35
|
+
children: React.ReactNode;
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
export function Container({ children, ...props }: ContainerProps) {
|
|
39
|
+
return <ContainerStyled {...props}>{children}</ContainerStyled>;
|
|
40
40
|
}
|