@atom-learning/components 1.0.0-rc.3 → 1.0.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/CHANGELOG.md +16 -0
- package/dist/components/action-icon/ActionIcon.d.ts +129 -43
- package/dist/components/alert-dialog/AlertDialog.d.ts +128 -42
- package/dist/components/alert-dialog/AlertDialogContent.d.ts +128 -42
- package/dist/components/alert-dialog/AlertDialogContent.js +1 -1
- package/dist/components/box/Box.d.ts +128 -42
- package/dist/components/button/Button.d.ts +128 -42
- package/dist/components/button/Button.js +1 -1
- package/dist/components/carousel/Carousel.js +1 -1
- package/dist/components/carousel/CarouselPagination.d.ts +128 -42
- package/dist/components/carousel/CarouselSlide.d.ts +128 -42
- package/dist/components/carousel/CarouselSlider.d.ts +128 -42
- package/dist/components/checkbox/Checkbox.d.ts +128 -42
- package/dist/components/combobox/Combobox.d.ts +128 -42
- package/dist/components/combobox/ComboboxInput.d.ts +128 -42
- package/dist/components/combobox/ComboboxInput.js +1 -1
- package/dist/components/combobox/ComboboxList.d.ts +128 -42
- package/dist/components/combobox/ComboboxOption.d.ts +128 -42
- package/dist/components/combobox/ComboboxPopover.d.ts +128 -42
- package/dist/components/dialog/Dialog.d.ts +128 -42
- package/dist/components/dialog/DialogClose.d.ts +128 -42
- package/dist/components/dialog/DialogContent.d.ts +128 -42
- package/dist/components/dialog/DialogContent.js +1 -1
- package/dist/components/divider/Divider.d.ts +134 -43
- package/dist/components/divider/Divider.js +1 -1
- package/dist/components/dropdown-menu/DropdownMenu.d.ts +128 -42
- package/dist/components/dropdown-menu/DropdownMenuContent.d.ts +128 -42
- package/dist/components/dropdown-menu/DropdownMenuContent.js +1 -1
- package/dist/components/dropdown-menu/DropdownMenuItem.d.ts +130 -45
- package/dist/components/dropdown-menu/DropdownMenuItem.js +1 -1
- package/dist/components/dropdown-menu/DropdownMenuSeparator.d.ts +128 -42
- package/dist/components/dropdown-menu/DropdownMenuSeparator.js +1 -1
- package/dist/components/dropdown-menu/DropdownMenuTrigger.d.ts +128 -42
- package/dist/components/field-wrapper/InlineFieldWrapper.d.ts +1 -1
- package/dist/components/field-wrapper/InlineFieldWrapper.js +1 -1
- package/dist/components/flex/Flex.d.ts +128 -42
- package/dist/components/form/Form.d.ts +128 -42
- package/dist/components/grid/Grid.d.ts +128 -42
- package/dist/components/heading/Heading.d.ts +128 -42
- package/dist/components/heading/Heading.js +1 -1
- package/dist/components/icon/Icon.d.ts +128 -42
- package/dist/components/image/Image.d.ts +128 -42
- package/dist/components/index.d.ts +5 -4
- package/dist/components/input/Input.d.ts +128 -42
- package/dist/components/label/Label.d.ts +129 -43
- package/dist/components/label/Label.js +1 -1
- package/dist/components/link/Link.d.ts +128 -42
- package/dist/components/list/List.d.ts +288 -116
- package/dist/components/popover/Popover.d.ts +128 -42
- package/dist/components/popover/PopoverContent.d.ts +128 -42
- package/dist/components/popover/PopoverContent.js +1 -1
- package/dist/components/progress-bar/ProgressBar.d.ts +128 -42
- package/dist/components/radio-button/RadioButton.d.ts +275 -0
- package/dist/components/radio-button/RadioButton.js +1 -0
- package/dist/components/radio-button/RadioButtonGroup.d.ts +269 -0
- package/dist/components/{radio → radio-button}/RadioButtonGroup.js +0 -0
- package/dist/components/{radio → radio-button}/index.d.ts +0 -0
- package/dist/components/{radio-field/RadioGroupField.d.ts → radio-button-field/RadioButtonField.d.ts} +2 -2
- package/dist/components/radio-button-field/RadioButtonField.js +1 -0
- package/dist/components/{radio-field → radio-button-field}/RadioField.d.ts +1 -1
- package/dist/components/radio-button-field/RadioField.js +1 -0
- package/dist/components/radio-button-field/index.d.ts +1 -0
- package/dist/components/radio-card/RadioCard.d.ts +274 -0
- package/dist/components/radio-card/RadioCard.js +1 -0
- package/dist/components/radio-card/RadioCardGroup.d.ts +9 -0
- package/dist/components/radio-card/RadioCardGroup.js +1 -0
- package/dist/components/radio-card/index.d.ts +2 -0
- package/dist/components/select/Select.d.ts +128 -42
- package/dist/components/select/Select.js +1 -1
- package/dist/components/stack/Stack.d.ts +128 -42
- package/dist/components/stack-content/StackContent.d.ts +128 -42
- package/dist/components/switch/Switch.d.ts +128 -42
- package/dist/components/switch/Switch.js +1 -1
- package/dist/components/table/Table.d.ts +128 -42
- package/dist/components/table/TableBody.d.ts +128 -42
- package/dist/components/table/TableCell.d.ts +128 -42
- package/dist/components/table/TableCell.js +1 -1
- package/dist/components/table/TableFooter.d.ts +128 -42
- package/dist/components/table/TableFooterCell.d.ts +128 -42
- package/dist/components/table/TableFooterCell.js +1 -1
- package/dist/components/table/TableHeader.d.ts +128 -42
- package/dist/components/table/TableHeaderCell.d.ts +128 -42
- package/dist/components/table/TableRow.d.ts +128 -42
- package/dist/components/tabs/TabTrigger.d.ts +128 -42
- package/dist/components/tabs/TabTrigger.js +1 -1
- package/dist/components/tabs/Tabs.d.ts +432 -174
- package/dist/components/text/Text.d.ts +128 -42
- package/dist/components/text/Text.js +1 -1
- package/dist/components/textarea/Textarea.d.ts +128 -42
- package/dist/components/toast/Toast.d.ts +128 -42
- package/dist/components/toast/Toast.js +1 -1
- package/dist/components/tooltip/Tooltip.js +1 -1
- package/dist/components/tooltip/TooltipContent.d.ts +128 -42
- package/dist/components/tooltip/TooltipContent.js +1 -1
- package/dist/components/video/Video.d.ts +128 -42
- package/dist/docgen.json +1 -1
- package/dist/docs/Divider.mdx +6 -2
- package/dist/docs/DropdownMenu.mdx +5 -3
- package/dist/docs/RadioButtonField.mdx +19 -0
- package/dist/docs/RadioCard.mdx +62 -0
- package/dist/index.cjs.js +1 -1
- package/dist/index.js +1 -1
- package/dist/stitches.d.ts +610 -200
- package/dist/stitches.js +1 -1
- package/dist/types/navigatorActions.types.d.ts +2 -5
- package/dist/utilities/css-wrapper/CSSWrapper.d.ts +1 -1
- package/dist/utilities/css-wrapper/CSSWrapper.js +1 -1
- package/dist/utilities/style/index.d.ts +3 -2
- package/dist/utilities/style/keyframe-animations.d.ts +24 -0
- package/dist/utilities/style/keyframe-animations.js +1 -0
- package/package.json +21 -20
- package/dist/components/radio/RadioButton.d.ts +0 -189
- package/dist/components/radio/RadioButton.js +0 -1
- package/dist/components/radio/RadioButtonGroup.d.ts +0 -183
- package/dist/components/radio-field/RadioField.js +0 -1
- package/dist/components/radio-field/RadioGroupField.js +0 -1
- package/dist/components/radio-field/index.d.ts +0 -1
- package/dist/docs/RadioField.mdx +0 -19
|
@@ -0,0 +1,274 @@
|
|
|
1
|
+
import * as RadioGroup from '@radix-ui/react-radio-group';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
export declare const StyledRadioCard: import("@stitches/react/types/styled-component").StyledComponent<React.ForwardRefExoticComponent<RadioGroup.RadioGroupItemProps & React.RefAttributes<HTMLButtonElement>>, {
|
|
4
|
+
align?: "left" | "right" | undefined;
|
|
5
|
+
size?: "md" | "lg" | undefined;
|
|
6
|
+
isFullWidth?: boolean | "true" | "false" | undefined;
|
|
7
|
+
}, {
|
|
8
|
+
sm: string;
|
|
9
|
+
md: string;
|
|
10
|
+
lg: string;
|
|
11
|
+
xl: string;
|
|
12
|
+
reducedMotion: string;
|
|
13
|
+
allowMotion: string;
|
|
14
|
+
hover: string;
|
|
15
|
+
}, import("@stitches/react/types/css-util").CSS<{
|
|
16
|
+
sm: string;
|
|
17
|
+
md: string;
|
|
18
|
+
lg: string;
|
|
19
|
+
xl: string;
|
|
20
|
+
reducedMotion: string;
|
|
21
|
+
allowMotion: string;
|
|
22
|
+
hover: string;
|
|
23
|
+
}, {
|
|
24
|
+
colors: {
|
|
25
|
+
textForeground: any;
|
|
26
|
+
textSubtle: any;
|
|
27
|
+
textPlaceholder: any;
|
|
28
|
+
background: any;
|
|
29
|
+
backgroundAccent: any;
|
|
30
|
+
tonal50: any;
|
|
31
|
+
tonal100: any;
|
|
32
|
+
tonal200: any;
|
|
33
|
+
tonal300: any;
|
|
34
|
+
tonal400: any;
|
|
35
|
+
tonal500: any;
|
|
36
|
+
tonal600: any;
|
|
37
|
+
alpha100: any;
|
|
38
|
+
alpha150: any;
|
|
39
|
+
alpha200: any;
|
|
40
|
+
alpha250: any;
|
|
41
|
+
alpha600: any;
|
|
42
|
+
primaryLight: any;
|
|
43
|
+
primary: any;
|
|
44
|
+
primaryMid: any;
|
|
45
|
+
primaryDark: any;
|
|
46
|
+
secondary: any;
|
|
47
|
+
brandRed: any;
|
|
48
|
+
brandRedAccent: any;
|
|
49
|
+
brandGreen: any;
|
|
50
|
+
brandGreenAccent: any;
|
|
51
|
+
brandPurple: any;
|
|
52
|
+
brandPurpleAccent: any;
|
|
53
|
+
brandYellow: any;
|
|
54
|
+
brandYellowAccent: any;
|
|
55
|
+
successLight: any;
|
|
56
|
+
success: any;
|
|
57
|
+
successMid: any;
|
|
58
|
+
successDark: any;
|
|
59
|
+
dangerLight: any;
|
|
60
|
+
danger: any;
|
|
61
|
+
dangerMid: any;
|
|
62
|
+
dangerDark: any;
|
|
63
|
+
warningLight: any;
|
|
64
|
+
warning: any;
|
|
65
|
+
warningMid: any;
|
|
66
|
+
warningDark: any;
|
|
67
|
+
subjectEnglish: any;
|
|
68
|
+
subjectMaths: any;
|
|
69
|
+
subjectScience: any;
|
|
70
|
+
subjectVerbalReasoning: any;
|
|
71
|
+
subjectNonVerbalReasoning: any;
|
|
72
|
+
subjectCreativeWriting: any;
|
|
73
|
+
subjectExamSkills: any;
|
|
74
|
+
};
|
|
75
|
+
space: {
|
|
76
|
+
"0": any;
|
|
77
|
+
"1": any;
|
|
78
|
+
"2": any;
|
|
79
|
+
"3": any;
|
|
80
|
+
"4": any;
|
|
81
|
+
"5": any;
|
|
82
|
+
"6": any;
|
|
83
|
+
"7": any;
|
|
84
|
+
"8": any;
|
|
85
|
+
"9": any;
|
|
86
|
+
};
|
|
87
|
+
fontSizes: {
|
|
88
|
+
xs: any;
|
|
89
|
+
sm: any;
|
|
90
|
+
md: any;
|
|
91
|
+
lg: any;
|
|
92
|
+
xl: any;
|
|
93
|
+
"2xl": any;
|
|
94
|
+
"3xl": any;
|
|
95
|
+
"4xl": any;
|
|
96
|
+
};
|
|
97
|
+
fonts: {
|
|
98
|
+
sans: any;
|
|
99
|
+
mono: any;
|
|
100
|
+
display: any;
|
|
101
|
+
body: any;
|
|
102
|
+
};
|
|
103
|
+
sizes: {
|
|
104
|
+
"0": any;
|
|
105
|
+
"1": any;
|
|
106
|
+
"2": any;
|
|
107
|
+
"3": any;
|
|
108
|
+
"4": any;
|
|
109
|
+
"5": any;
|
|
110
|
+
"6": any;
|
|
111
|
+
"7": any;
|
|
112
|
+
"8": any;
|
|
113
|
+
};
|
|
114
|
+
radii: {
|
|
115
|
+
"0": any;
|
|
116
|
+
"1": any;
|
|
117
|
+
"2": any;
|
|
118
|
+
"3": any;
|
|
119
|
+
round: any;
|
|
120
|
+
};
|
|
121
|
+
shadows: {
|
|
122
|
+
"0": any;
|
|
123
|
+
"1": any;
|
|
124
|
+
"2": any;
|
|
125
|
+
"3": any;
|
|
126
|
+
};
|
|
127
|
+
}, import("@stitches/react/types/config").DefaultThemeMap, {
|
|
128
|
+
bg: (value: {
|
|
129
|
+
readonly [$$PropertyValue]: "background";
|
|
130
|
+
}) => {
|
|
131
|
+
background: {
|
|
132
|
+
readonly [$$PropertyValue]: "background";
|
|
133
|
+
};
|
|
134
|
+
};
|
|
135
|
+
inset: (value: string | number | {
|
|
136
|
+
readonly [$$ScaleValue]: "space";
|
|
137
|
+
}) => {
|
|
138
|
+
top: string | number | {
|
|
139
|
+
readonly [$$ScaleValue]: "space";
|
|
140
|
+
};
|
|
141
|
+
right: string | number | {
|
|
142
|
+
readonly [$$ScaleValue]: "space";
|
|
143
|
+
};
|
|
144
|
+
bottom: string | number | {
|
|
145
|
+
readonly [$$ScaleValue]: "space";
|
|
146
|
+
};
|
|
147
|
+
left: string | number | {
|
|
148
|
+
readonly [$$ScaleValue]: "space";
|
|
149
|
+
};
|
|
150
|
+
};
|
|
151
|
+
size: (value: string | number | {
|
|
152
|
+
readonly [$$ScaleValue]: "size";
|
|
153
|
+
}) => {
|
|
154
|
+
height: string | number | {
|
|
155
|
+
readonly [$$ScaleValue]: "size";
|
|
156
|
+
};
|
|
157
|
+
width: string | number | {
|
|
158
|
+
readonly [$$ScaleValue]: "size";
|
|
159
|
+
};
|
|
160
|
+
};
|
|
161
|
+
p: (value: string | number | {
|
|
162
|
+
readonly [$$ScaleValue]: "space";
|
|
163
|
+
}) => {
|
|
164
|
+
padding: string | number | {
|
|
165
|
+
readonly [$$ScaleValue]: "space";
|
|
166
|
+
};
|
|
167
|
+
};
|
|
168
|
+
pt: (value: string | number | {
|
|
169
|
+
readonly [$$ScaleValue]: "space";
|
|
170
|
+
}) => {
|
|
171
|
+
paddingTop: string | number | {
|
|
172
|
+
readonly [$$ScaleValue]: "space";
|
|
173
|
+
};
|
|
174
|
+
};
|
|
175
|
+
pr: (value: string | number | {
|
|
176
|
+
readonly [$$ScaleValue]: "space";
|
|
177
|
+
}) => {
|
|
178
|
+
paddingRight: string | number | {
|
|
179
|
+
readonly [$$ScaleValue]: "space";
|
|
180
|
+
};
|
|
181
|
+
};
|
|
182
|
+
pb: (value: string | number | {
|
|
183
|
+
readonly [$$ScaleValue]: "space";
|
|
184
|
+
}) => {
|
|
185
|
+
paddingBottom: string | number | {
|
|
186
|
+
readonly [$$ScaleValue]: "space";
|
|
187
|
+
};
|
|
188
|
+
};
|
|
189
|
+
pl: (value: string | number | {
|
|
190
|
+
readonly [$$ScaleValue]: "space";
|
|
191
|
+
}) => {
|
|
192
|
+
paddingLeft: string | number | {
|
|
193
|
+
readonly [$$ScaleValue]: "space";
|
|
194
|
+
};
|
|
195
|
+
};
|
|
196
|
+
px: (value: string | number | {
|
|
197
|
+
readonly [$$ScaleValue]: "space";
|
|
198
|
+
}) => {
|
|
199
|
+
paddingLeft: string | number | {
|
|
200
|
+
readonly [$$ScaleValue]: "space";
|
|
201
|
+
};
|
|
202
|
+
paddingRight: string | number | {
|
|
203
|
+
readonly [$$ScaleValue]: "space";
|
|
204
|
+
};
|
|
205
|
+
};
|
|
206
|
+
py: (value: string | number | {
|
|
207
|
+
readonly [$$ScaleValue]: "space";
|
|
208
|
+
}) => {
|
|
209
|
+
paddingTop: string | number | {
|
|
210
|
+
readonly [$$ScaleValue]: "space";
|
|
211
|
+
};
|
|
212
|
+
paddingBottom: string | number | {
|
|
213
|
+
readonly [$$ScaleValue]: "space";
|
|
214
|
+
};
|
|
215
|
+
};
|
|
216
|
+
m: (value: string | number | {
|
|
217
|
+
readonly [$$ScaleValue]: "space";
|
|
218
|
+
}) => {
|
|
219
|
+
margin: string | number | {
|
|
220
|
+
readonly [$$ScaleValue]: "space";
|
|
221
|
+
};
|
|
222
|
+
};
|
|
223
|
+
mt: (value: string | number | {
|
|
224
|
+
readonly [$$ScaleValue]: "space";
|
|
225
|
+
}) => {
|
|
226
|
+
marginTop: string | number | {
|
|
227
|
+
readonly [$$ScaleValue]: "space";
|
|
228
|
+
};
|
|
229
|
+
};
|
|
230
|
+
mr: (value: string | number | {
|
|
231
|
+
readonly [$$ScaleValue]: "space";
|
|
232
|
+
}) => {
|
|
233
|
+
marginRight: string | number | {
|
|
234
|
+
readonly [$$ScaleValue]: "space";
|
|
235
|
+
};
|
|
236
|
+
};
|
|
237
|
+
mb: (value: string | number | {
|
|
238
|
+
readonly [$$ScaleValue]: "space";
|
|
239
|
+
}) => {
|
|
240
|
+
marginBottom: string | number | {
|
|
241
|
+
readonly [$$ScaleValue]: "space";
|
|
242
|
+
};
|
|
243
|
+
};
|
|
244
|
+
ml: (value: string | number | {
|
|
245
|
+
readonly [$$ScaleValue]: "space";
|
|
246
|
+
}) => {
|
|
247
|
+
marginLeft: string | number | {
|
|
248
|
+
readonly [$$ScaleValue]: "space";
|
|
249
|
+
};
|
|
250
|
+
};
|
|
251
|
+
mx: (value: string | number | {
|
|
252
|
+
readonly [$$ScaleValue]: "space";
|
|
253
|
+
}) => {
|
|
254
|
+
marginLeft: string | number | {
|
|
255
|
+
readonly [$$ScaleValue]: "space";
|
|
256
|
+
};
|
|
257
|
+
marginRight: string | number | {
|
|
258
|
+
readonly [$$ScaleValue]: "space";
|
|
259
|
+
};
|
|
260
|
+
};
|
|
261
|
+
my: (value: string | number | {
|
|
262
|
+
readonly [$$ScaleValue]: "space";
|
|
263
|
+
}) => {
|
|
264
|
+
marginTop: string | number | {
|
|
265
|
+
readonly [$$ScaleValue]: "space";
|
|
266
|
+
};
|
|
267
|
+
marginBottom: string | number | {
|
|
268
|
+
readonly [$$ScaleValue]: "space";
|
|
269
|
+
};
|
|
270
|
+
};
|
|
271
|
+
}>>;
|
|
272
|
+
declare type RadioCardProps = React.ComponentProps<typeof StyledRadioCard>;
|
|
273
|
+
export declare const RadioCard: React.FC<RadioCardProps>;
|
|
274
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const i=["children","isFullWidth","size","align"];import{Item as r,Indicator as t}from"@radix-ui/react-radio-group";import{createElement as e}from"react";import{styled as l}from"../../stitches.js";import{Box as n}from"../box/Box.js";const o=l(r,{alignItems:"center",bg:"white",border:"1px solid $tonal200",borderRadius:"$0",cursor:"pointer",display:"flex",textAlign:"left",'&[data-state="checked"]':{outline:"2px solid $primary",outlineOffset:"-2px"},variants:{align:{left:{flexDirection:"row"},right:{flexDirection:"row-reverse"}},size:{md:{px:"$4",py:"$3"},lg:{px:"$5",py:"$4"}},isFullWidth:{true:{width:"100%"},false:{width:"max-content"}}}}),a=l("div",{alignItems:"center",appearance:"none",backgroundColor:"transparent",border:"1px solid $tonal500",borderRadius:"$round",display:"flex",flexShrink:0,justifyContent:"center",p:0,size:"$1",transition:"all 50ms ease-out",'[data-state="checked"] &':{backgroundColor:"$primary",borderColor:"$primary"},variants:{containerIsFullWidth:{true:{},false:{}},align:{left:{mr:"$4"},right:{}}},compoundVariants:[{containerIsFullWidth:!0,align:"right",css:{ml:"auto"}},{containerIsFullWidth:!1,align:"right",css:{ml:"$4"}}]}),s=l(t,{backgroundColor:"white",borderRadius:"$round",position:"absolute",size:"6px"}),d=r=>{let{children:t,isFullWidth:l=!1,size:d="md",align:u="left"}=r,c=function(i,r){if(null==i)return{};var t,e,l={},n=Object.keys(i);for(e=0;e<n.length;e++)t=n[e],r.indexOf(t)>=0||(l[t]=i[t]);return l}(r,i);return e(o,Object.assign({},c,{align:u,isFullWidth:l,size:d}),e(a,{align:u,containerIsFullWidth:l},e(s,null)),e(n,null,t))};export{d as RadioCard,o as StyledRadioCard};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import * as RadioGroup from '@radix-ui/react-radio-group';
|
|
2
|
+
import type * as Stitches from '@stitches/react';
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import type { Override } from '../../utilities';
|
|
5
|
+
import { Stack } from '../stack/Stack';
|
|
6
|
+
import { StyledRadioCard } from './RadioCard';
|
|
7
|
+
declare type RadioCardGroupProps = Override<Pick<React.ComponentProps<typeof Stack>, 'justify' | 'gap' | 'css'> & Stitches.VariantProps<typeof StyledRadioCard>, React.ComponentProps<typeof RadioGroup.Root>>;
|
|
8
|
+
export declare const RadioCardGroup: React.FC<RadioCardGroupProps>;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const i=["css","children","size","isFullWidth","align","gap","justify"];import{Root as r}from"@radix-ui/react-radio-group";import{createElement as t,Children as s,isValidElement as e,cloneElement as o}from"react";import{Stack as n}from"../stack/Stack.js";import{RadioCard as a}from"./RadioCard.js";const l=l=>{let{css:c,children:u,size:d,isFullWidth:f,align:p,gap:g="3",justify:m}=l,j=function(i,r){if(null==i)return{};var t,s,e={},o=Object.keys(i);for(s=0;s<o.length;s++)t=o[s],r.indexOf(t)>=0||(e[t]=i[t]);return e}(l,i);return t(r,Object.assign({},j),t(n,{direction:"row",justify:m,gap:g,css:c},s.map(u,(i=>e(i)&&(null==i?void 0:i.type)===a?o(i,{size:d,isFullWidth:f,align:p}):i))))};export{l as RadioCardGroup};
|
|
@@ -9,6 +9,7 @@ declare const StyledSelect: import("@stitches/react/types/styled-component").Sty
|
|
|
9
9
|
lg: string;
|
|
10
10
|
xl: string;
|
|
11
11
|
reducedMotion: string;
|
|
12
|
+
allowMotion: string;
|
|
12
13
|
hover: string;
|
|
13
14
|
}, import("@stitches/react/types/css-util").CSS<{
|
|
14
15
|
sm: string;
|
|
@@ -16,6 +17,7 @@ declare const StyledSelect: import("@stitches/react/types/styled-component").Sty
|
|
|
16
17
|
lg: string;
|
|
17
18
|
xl: string;
|
|
18
19
|
reducedMotion: string;
|
|
20
|
+
allowMotion: string;
|
|
19
21
|
hover: string;
|
|
20
22
|
}, {
|
|
21
23
|
colors: {
|
|
@@ -122,64 +124,148 @@ declare const StyledSelect: import("@stitches/react/types/styled-component").Sty
|
|
|
122
124
|
"3": any;
|
|
123
125
|
};
|
|
124
126
|
}, import("@stitches/react/types/config").DefaultThemeMap, {
|
|
125
|
-
bg: (value:
|
|
126
|
-
|
|
127
|
+
bg: (value: {
|
|
128
|
+
readonly [$$PropertyValue]: "background";
|
|
129
|
+
}) => {
|
|
130
|
+
background: {
|
|
131
|
+
readonly [$$PropertyValue]: "background";
|
|
132
|
+
};
|
|
127
133
|
};
|
|
128
|
-
inset: (value: string | number |
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
134
|
+
inset: (value: string | number | {
|
|
135
|
+
readonly [$$ScaleValue]: "space";
|
|
136
|
+
}) => {
|
|
137
|
+
top: string | number | {
|
|
138
|
+
readonly [$$ScaleValue]: "space";
|
|
139
|
+
};
|
|
140
|
+
right: string | number | {
|
|
141
|
+
readonly [$$ScaleValue]: "space";
|
|
142
|
+
};
|
|
143
|
+
bottom: string | number | {
|
|
144
|
+
readonly [$$ScaleValue]: "space";
|
|
145
|
+
};
|
|
146
|
+
left: string | number | {
|
|
147
|
+
readonly [$$ScaleValue]: "space";
|
|
148
|
+
};
|
|
133
149
|
};
|
|
134
|
-
size: (value: string | number |
|
|
135
|
-
|
|
136
|
-
|
|
150
|
+
size: (value: string | number | {
|
|
151
|
+
readonly [$$ScaleValue]: "size";
|
|
152
|
+
}) => {
|
|
153
|
+
height: string | number | {
|
|
154
|
+
readonly [$$ScaleValue]: "size";
|
|
155
|
+
};
|
|
156
|
+
width: string | number | {
|
|
157
|
+
readonly [$$ScaleValue]: "size";
|
|
158
|
+
};
|
|
137
159
|
};
|
|
138
|
-
p: (value: string | number |
|
|
139
|
-
|
|
160
|
+
p: (value: string | number | {
|
|
161
|
+
readonly [$$ScaleValue]: "space";
|
|
162
|
+
}) => {
|
|
163
|
+
padding: string | number | {
|
|
164
|
+
readonly [$$ScaleValue]: "space";
|
|
165
|
+
};
|
|
140
166
|
};
|
|
141
|
-
pt: (value: string | number |
|
|
142
|
-
|
|
167
|
+
pt: (value: string | number | {
|
|
168
|
+
readonly [$$ScaleValue]: "space";
|
|
169
|
+
}) => {
|
|
170
|
+
paddingTop: string | number | {
|
|
171
|
+
readonly [$$ScaleValue]: "space";
|
|
172
|
+
};
|
|
143
173
|
};
|
|
144
|
-
pr: (value: string | number |
|
|
145
|
-
|
|
174
|
+
pr: (value: string | number | {
|
|
175
|
+
readonly [$$ScaleValue]: "space";
|
|
176
|
+
}) => {
|
|
177
|
+
paddingRight: string | number | {
|
|
178
|
+
readonly [$$ScaleValue]: "space";
|
|
179
|
+
};
|
|
146
180
|
};
|
|
147
|
-
pb: (value: string | number |
|
|
148
|
-
|
|
181
|
+
pb: (value: string | number | {
|
|
182
|
+
readonly [$$ScaleValue]: "space";
|
|
183
|
+
}) => {
|
|
184
|
+
paddingBottom: string | number | {
|
|
185
|
+
readonly [$$ScaleValue]: "space";
|
|
186
|
+
};
|
|
149
187
|
};
|
|
150
|
-
pl: (value: string | number |
|
|
151
|
-
|
|
188
|
+
pl: (value: string | number | {
|
|
189
|
+
readonly [$$ScaleValue]: "space";
|
|
190
|
+
}) => {
|
|
191
|
+
paddingLeft: string | number | {
|
|
192
|
+
readonly [$$ScaleValue]: "space";
|
|
193
|
+
};
|
|
152
194
|
};
|
|
153
|
-
px: (value: string | number |
|
|
154
|
-
|
|
155
|
-
|
|
195
|
+
px: (value: string | number | {
|
|
196
|
+
readonly [$$ScaleValue]: "space";
|
|
197
|
+
}) => {
|
|
198
|
+
paddingLeft: string | number | {
|
|
199
|
+
readonly [$$ScaleValue]: "space";
|
|
200
|
+
};
|
|
201
|
+
paddingRight: string | number | {
|
|
202
|
+
readonly [$$ScaleValue]: "space";
|
|
203
|
+
};
|
|
156
204
|
};
|
|
157
|
-
py: (value: string | number |
|
|
158
|
-
|
|
159
|
-
|
|
205
|
+
py: (value: string | number | {
|
|
206
|
+
readonly [$$ScaleValue]: "space";
|
|
207
|
+
}) => {
|
|
208
|
+
paddingTop: string | number | {
|
|
209
|
+
readonly [$$ScaleValue]: "space";
|
|
210
|
+
};
|
|
211
|
+
paddingBottom: string | number | {
|
|
212
|
+
readonly [$$ScaleValue]: "space";
|
|
213
|
+
};
|
|
160
214
|
};
|
|
161
|
-
m: (value: string | number |
|
|
162
|
-
|
|
215
|
+
m: (value: string | number | {
|
|
216
|
+
readonly [$$ScaleValue]: "space";
|
|
217
|
+
}) => {
|
|
218
|
+
margin: string | number | {
|
|
219
|
+
readonly [$$ScaleValue]: "space";
|
|
220
|
+
};
|
|
163
221
|
};
|
|
164
|
-
mt: (value: string | number |
|
|
165
|
-
|
|
222
|
+
mt: (value: string | number | {
|
|
223
|
+
readonly [$$ScaleValue]: "space";
|
|
224
|
+
}) => {
|
|
225
|
+
marginTop: string | number | {
|
|
226
|
+
readonly [$$ScaleValue]: "space";
|
|
227
|
+
};
|
|
166
228
|
};
|
|
167
|
-
mr: (value: string | number |
|
|
168
|
-
|
|
229
|
+
mr: (value: string | number | {
|
|
230
|
+
readonly [$$ScaleValue]: "space";
|
|
231
|
+
}) => {
|
|
232
|
+
marginRight: string | number | {
|
|
233
|
+
readonly [$$ScaleValue]: "space";
|
|
234
|
+
};
|
|
169
235
|
};
|
|
170
|
-
mb: (value: string | number |
|
|
171
|
-
|
|
236
|
+
mb: (value: string | number | {
|
|
237
|
+
readonly [$$ScaleValue]: "space";
|
|
238
|
+
}) => {
|
|
239
|
+
marginBottom: string | number | {
|
|
240
|
+
readonly [$$ScaleValue]: "space";
|
|
241
|
+
};
|
|
172
242
|
};
|
|
173
|
-
ml: (value: string | number |
|
|
174
|
-
|
|
243
|
+
ml: (value: string | number | {
|
|
244
|
+
readonly [$$ScaleValue]: "space";
|
|
245
|
+
}) => {
|
|
246
|
+
marginLeft: string | number | {
|
|
247
|
+
readonly [$$ScaleValue]: "space";
|
|
248
|
+
};
|
|
175
249
|
};
|
|
176
|
-
mx: (value: string | number |
|
|
177
|
-
|
|
178
|
-
|
|
250
|
+
mx: (value: string | number | {
|
|
251
|
+
readonly [$$ScaleValue]: "space";
|
|
252
|
+
}) => {
|
|
253
|
+
marginLeft: string | number | {
|
|
254
|
+
readonly [$$ScaleValue]: "space";
|
|
255
|
+
};
|
|
256
|
+
marginRight: string | number | {
|
|
257
|
+
readonly [$$ScaleValue]: "space";
|
|
258
|
+
};
|
|
179
259
|
};
|
|
180
|
-
my: (value: string | number |
|
|
181
|
-
|
|
182
|
-
|
|
260
|
+
my: (value: string | number | {
|
|
261
|
+
readonly [$$ScaleValue]: "space";
|
|
262
|
+
}) => {
|
|
263
|
+
marginTop: string | number | {
|
|
264
|
+
readonly [$$ScaleValue]: "space";
|
|
265
|
+
};
|
|
266
|
+
marginBottom: string | number | {
|
|
267
|
+
readonly [$$ScaleValue]: "space";
|
|
268
|
+
};
|
|
183
269
|
};
|
|
184
270
|
}>>;
|
|
185
271
|
export declare type SelectProps = Override<React.ComponentProps<typeof StyledSelect>, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const e=["placeholder","children","size"];import{forwardRef as o,createElement as r}from"react";import{styled as t,theme as i}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import{encodeBackgroundIcon as
|
|
1
|
+
const e=["placeholder","children","size"];import{forwardRef as o,createElement as r}from"react";import{styled as t,theme as i}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import{encodeBackgroundIcon as a}from"../../utilities/style/encode-background-icon.js";import"../../utilities/style/keyframe-animations.js";const n=t("select",{appearance:"none",backgroundColor:"white",backgroundImage:a(i.colors.tonal300.value,"chevron"),backgroundRepeat:"no-repeat, repeat",border:"1px solid $tonal300",borderRadius:"$0",color:"$tonal600",display:"block",fontFamily:"$body",fontWeight:400,lineHeight:1.4,transition:"all 75ms ease-out",width:"100%","&:hover":{cursor:"pointer"},"&:focus":{borderColor:"$primary",outline:"none"},"&::-ms-expand":{display:"none"},"&[disabled], > option[disabled]":{backgroundColor:"$tonal100",color:"$tonal400",cursor:"not-allowed"},variants:{size:{sm:{backgroundPosition:"right $space$2 top 50%, 0 0",backgroundSize:"18px auto, 100%",fontSize:"$sm",height:"$3",pl:"$2",pr:"$5"},md:{backgroundPosition:"right $space$3 top 50%, 0 0",backgroundSize:"20px auto, 100%",fontSize:"$md",height:"$4",pl:"$3",pr:"$6"}},state:{error:{border:"1px solid $danger"}}}}),l=o(((o,t)=>{let{placeholder:i,children:a,size:l="md"}=o,s=function(e,o){if(null==e)return{};var r,t,i={},a=Object.keys(e);for(t=0;t<a.length;t++)r=a[t],o.indexOf(r)>=0||(i[r]=e[r]);return i}(o,e);return r(n,Object.assign({size:l,defaultValue:""},s,{ref:t}),i&&r("option",{disabled:!0,hidden:!0,value:""},i),a)}));l.displayName="Select";export{l as Select};
|