@atom-learning/components 2.61.2 → 2.63.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/CHANGELOG.md +3 -3
- package/dist/components/accordion/AccordionTrigger.js +1 -1
- package/dist/components/action-icon/ActionIcon.js +1 -1
- package/dist/components/avatar/AvatarInitial.js +1 -1
- package/dist/components/banner/BannerContext.js +1 -1
- package/dist/components/banner/banner-regular/BannerRegularActions.js +1 -1
- package/dist/components/banner/banner-regular/BannerRegularButton.js +1 -1
- package/dist/components/banner/banner-regular/BannerRegularContent.js +1 -1
- package/dist/components/button/Button.js +1 -1
- package/dist/components/calendar/Calendar.js +1 -1
- package/dist/components/carousel/CarouselSlide.js +1 -1
- package/dist/components/checkbox/Checkbox.js +1 -1
- package/dist/components/chip/Chip.d.ts +1 -3
- package/dist/components/chip/Chip.js +1 -1
- package/dist/components/chip/Chip.js.map +1 -1
- package/dist/components/chip/ChipGroup.js +1 -1
- package/dist/components/chip-dismissible-group/ChipDismissibleGroupItem.d.ts +447 -1
- package/dist/components/chip-dismissible-group/ChipDismissibleGroupRoot.js +1 -1
- package/dist/components/chip-toggle-group/ChipToggleGroupItem.d.ts +447 -1
- package/dist/components/chip-toggle-group/ChipToggleGroupItem.js +1 -1
- package/dist/components/chip-toggle-group/ChipToggleGroupItem.js.map +1 -1
- package/dist/components/combobox/Combobox.js +1 -1
- package/dist/components/combobox/ComboboxInput.d.ts +5 -1
- package/dist/components/combobox/ComboboxInput.js +1 -1
- package/dist/components/combobox/ComboboxInput.js.map +1 -1
- package/dist/components/create-password-field/CreatePasswordField.d.ts +1 -1
- package/dist/components/create-password-field/CreatePasswordField.js +1 -1
- package/dist/components/create-password-field/CreatePasswordField.js.map +1 -1
- package/dist/components/data-table/DataTableBody.js +1 -1
- package/dist/components/data-table/DataTableGlobalFilter.js +1 -1
- package/dist/components/data-table/DataTableLoading.js +1 -1
- package/dist/components/data-table/DataTableRowSelectionCheckbox.js +1 -1
- package/dist/components/data-table/DataTableSelectAllRowsCheckbox.js +1 -1
- package/dist/components/data-table/drag-and-drop/DragAndDropTableBody.js +1 -1
- package/dist/components/data-table/useSorting.js +1 -1
- package/dist/components/date-input/DateInput.d.ts +2 -2
- package/dist/components/date-input/DateInput.js +1 -1
- package/dist/components/date-input/DateInput.js.map +1 -1
- package/dist/components/dismissible/DismissibleRoot.js +1 -1
- package/dist/components/dismissible/DismissibleTrigger.js +1 -1
- package/dist/components/divider/Divider.js +1 -1
- package/dist/components/field-wrapper/FieldDescription.js +1 -1
- package/dist/components/field-wrapper/InlineFieldWrapper.js +1 -1
- package/dist/components/grid/Grid.js +1 -1
- package/dist/components/icon/Icon.js +1 -1
- package/dist/components/inline-message/InlineMessage.js +1 -1
- package/dist/components/input/Input.d.ts +1 -1
- package/dist/components/input/Input.js +1 -1
- package/dist/components/input/Input.js.map +1 -1
- package/dist/components/label/Label.js +1 -1
- package/dist/components/link/Link.js +1 -1
- package/dist/components/list/List.js +1 -1
- package/dist/components/markdown-content/MarkdownContent.js +1 -1
- package/dist/components/markdown-content/components/MarkdownCode.js +1 -1
- package/dist/components/markdown-content/components/MarkdownEmphasis.js +1 -1
- package/dist/components/markdown-content/components/MarkdownImage.js +1 -1
- package/dist/components/markdown-content/components/MarkdownInlineCode.js +1 -1
- package/dist/components/markdown-content/components/MarkdownListItem.js +1 -1
- package/dist/components/markdown-content/components/MarkdownParagraph.js +1 -1
- package/dist/components/markdown-content/components/MarkdownStrong.js +1 -1
- package/dist/components/markdown-content/components/MarkdownThematicBreak.js +1 -1
- package/dist/components/number-input/NumberInput.d.ts +1 -1
- package/dist/components/number-input/NumberInput.js +1 -1
- package/dist/components/number-input/NumberInput.js.map +1 -1
- package/dist/components/number-input/NumberInputStepper.js +1 -1
- package/dist/components/number-input/NumberInputStepper.js.map +1 -1
- package/dist/components/number-input-field/NumberInputField.js +1 -1
- package/dist/components/pagination/PaginationItem.js +1 -1
- package/dist/components/password-field/PasswordField.js +1 -1
- package/dist/components/password-input/PasswordInput.js +1 -1
- package/dist/components/password-input/PasswordInput.js.map +1 -1
- package/dist/components/popover/PopoverContent.js +1 -1
- package/dist/components/radio-button-field/RadioButtonField.js +1 -1
- package/dist/components/radio-button-field/RadioField.js +1 -1
- package/dist/components/radio-card/RadioCardGroup.js +1 -1
- package/dist/components/search-input/SearchInput.d.ts +1 -1
- package/dist/components/search-input/SearchInput.js +1 -1
- package/dist/components/search-input/SearchInput.js.map +1 -1
- package/dist/components/section-message/SectionMessageDescription.js +1 -1
- package/dist/components/section-message/SectionMessageIcon.js +1 -1
- package/dist/components/select/Select.d.ts +1 -1
- package/dist/components/select/Select.js +1 -1
- package/dist/components/select/Select.js.map +1 -1
- package/dist/components/select-field/SelectField.js +1 -1
- package/dist/components/sortable/SortableHandle.js +1 -1
- package/dist/components/stepper/StepperStepBack.js +1 -1
- package/dist/components/stepper/StepperStepForward.js +1 -1
- package/dist/components/table/TableHeader.js +1 -1
- package/dist/components/table/TableRow.js +1 -1
- package/dist/components/tabs/Tabs.js +1 -1
- package/dist/components/tabs/TabsTrigger.js +1 -1
- package/dist/components/text/Text.js +1 -1
- package/dist/components/tile/Tile.d.ts +1 -2
- package/dist/components/tile/Tile.js +1 -1
- package/dist/components/tile/Tile.js.map +1 -1
- package/dist/components/tile-interactive/TileInteractive.d.ts +2 -3
- package/dist/components/tile-interactive/TileInteractive.js +1 -1
- package/dist/components/tile-interactive/TileInteractive.js.map +1 -1
- package/dist/components/tile-toggle-group/TileToggleGroupItem.d.ts +2 -3
- package/dist/components/tile-toggle-group/TileToggleGroupItem.js +1 -1
- package/dist/components/tile-toggle-group/TileToggleGroupItem.js.map +1 -1
- package/dist/components/toast/Toast.js +1 -1
- package/dist/components/toast/ToastProvider.js +1 -1
- package/dist/components/toggle-group/ToggleGroupButton.js +1 -1
- package/dist/components/video/Video.js +1 -1
- package/dist/docgen.json +1 -1
- package/dist/index.cjs.js +1 -1
- package/dist/index.cjs.js.map +1 -1
- package/dist/utilities/hooks/useCallbackRef.js +1 -1
- package/dist/utilities/style/get-icon-size.d.ts +1 -0
- package/dist/utilities/style/get-icon-size.js +2 -0
- package/dist/utilities/style/get-icon-size.js.map +1 -0
- package/dist/utilities/style/index.d.ts +1 -0
- package/package.json +1 -1
|
@@ -1,6 +1,452 @@
|
|
|
1
1
|
import * as ToggleGroup from '@radix-ui/react-toggle-group';
|
|
2
2
|
import * as React from 'react';
|
|
3
|
-
declare const StyledChipToggleGroupItem: import("@stitches/react/types/styled-component").StyledComponent<React.ForwardRefExoticComponent<
|
|
3
|
+
declare const StyledChipToggleGroupItem: import("@stitches/react/types/styled-component").StyledComponent<React.ForwardRefExoticComponent<Omit<Omit<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
4
|
+
ref?: ((instance: HTMLDivElement | null) => void) | React.RefObject<HTMLDivElement> | null | undefined;
|
|
5
|
+
}, "css"> & import("@stitches/react/types/styled-component").TransformProps<{}, {
|
|
6
|
+
sm: string;
|
|
7
|
+
md: string;
|
|
8
|
+
lg: string;
|
|
9
|
+
xl: string;
|
|
10
|
+
reducedMotion: string;
|
|
11
|
+
allowMotion: string;
|
|
12
|
+
hover: string;
|
|
13
|
+
}> & {
|
|
14
|
+
css?: import("@stitches/react/types/css-util").CSS<{
|
|
15
|
+
sm: string;
|
|
16
|
+
md: string;
|
|
17
|
+
lg: string;
|
|
18
|
+
xl: string;
|
|
19
|
+
reducedMotion: string;
|
|
20
|
+
allowMotion: string;
|
|
21
|
+
hover: string;
|
|
22
|
+
}, {
|
|
23
|
+
colors: {
|
|
24
|
+
textForeground: any;
|
|
25
|
+
textSubtle: any;
|
|
26
|
+
textPlaceholder: any;
|
|
27
|
+
background: any;
|
|
28
|
+
backgroundAccent: any;
|
|
29
|
+
grey100: any;
|
|
30
|
+
grey200: any;
|
|
31
|
+
grey300: any;
|
|
32
|
+
grey400: any;
|
|
33
|
+
grey500: any;
|
|
34
|
+
grey600: any;
|
|
35
|
+
grey700: any;
|
|
36
|
+
grey800: any;
|
|
37
|
+
grey900: any;
|
|
38
|
+
grey1000: any;
|
|
39
|
+
grey1100: any;
|
|
40
|
+
grey1200: any;
|
|
41
|
+
blue100: any;
|
|
42
|
+
blue200: any;
|
|
43
|
+
blue300: any;
|
|
44
|
+
blue400: any;
|
|
45
|
+
blue500: any;
|
|
46
|
+
blue600: any;
|
|
47
|
+
blue700: any;
|
|
48
|
+
blue800: any;
|
|
49
|
+
blue900: any;
|
|
50
|
+
blue1000: any;
|
|
51
|
+
blue1100: any;
|
|
52
|
+
blue1200: any;
|
|
53
|
+
purple100: any;
|
|
54
|
+
purple200: any;
|
|
55
|
+
purple300: any;
|
|
56
|
+
purple400: any;
|
|
57
|
+
purple500: any;
|
|
58
|
+
purple600: any;
|
|
59
|
+
purple700: any;
|
|
60
|
+
purple800: any;
|
|
61
|
+
purple900: any;
|
|
62
|
+
purple1000: any;
|
|
63
|
+
purple1100: any;
|
|
64
|
+
purple1200: any;
|
|
65
|
+
tonal50: any;
|
|
66
|
+
tonal100: any;
|
|
67
|
+
tonal200: any;
|
|
68
|
+
tonal300: any;
|
|
69
|
+
tonal400: any;
|
|
70
|
+
tonal500: any;
|
|
71
|
+
tonal600: any;
|
|
72
|
+
alpha100: any;
|
|
73
|
+
alpha150: any;
|
|
74
|
+
alpha200: any;
|
|
75
|
+
alpha250: any;
|
|
76
|
+
alpha600: any;
|
|
77
|
+
primaryLight: any;
|
|
78
|
+
primary: any;
|
|
79
|
+
primaryMid: any;
|
|
80
|
+
primaryDark: any;
|
|
81
|
+
secondary: any;
|
|
82
|
+
brandRed: any;
|
|
83
|
+
brandRedAccent: any;
|
|
84
|
+
brandGreen: any;
|
|
85
|
+
brandGreenAccent: any;
|
|
86
|
+
brandPurple: any;
|
|
87
|
+
brandPurpleAccent: any;
|
|
88
|
+
brandYellow: any;
|
|
89
|
+
brandYellowAccent: any;
|
|
90
|
+
successLight: any;
|
|
91
|
+
success: any;
|
|
92
|
+
successMid: any;
|
|
93
|
+
successDark: any;
|
|
94
|
+
dangerLight: any;
|
|
95
|
+
danger: any;
|
|
96
|
+
dangerMid: any;
|
|
97
|
+
dangerDark: any;
|
|
98
|
+
warningLight: any;
|
|
99
|
+
warning: any;
|
|
100
|
+
warningMid: any;
|
|
101
|
+
warningDark: any;
|
|
102
|
+
warningText: any;
|
|
103
|
+
subjectEnglish: any;
|
|
104
|
+
subjectMaths: any;
|
|
105
|
+
subjectScience: any;
|
|
106
|
+
subjectVerbalReasoning: any;
|
|
107
|
+
subjectNonVerbalReasoning: any;
|
|
108
|
+
subjectCreativeWriting: any;
|
|
109
|
+
subjectExamSkills: any;
|
|
110
|
+
};
|
|
111
|
+
space: {
|
|
112
|
+
"0": any;
|
|
113
|
+
"1": any;
|
|
114
|
+
"2": any;
|
|
115
|
+
"3": any;
|
|
116
|
+
"4": any;
|
|
117
|
+
"5": any;
|
|
118
|
+
"6": any;
|
|
119
|
+
"7": any;
|
|
120
|
+
"8": any;
|
|
121
|
+
"9": any;
|
|
122
|
+
"24": any;
|
|
123
|
+
};
|
|
124
|
+
fontSizes: {
|
|
125
|
+
xs: any;
|
|
126
|
+
sm: any;
|
|
127
|
+
md: any;
|
|
128
|
+
lg: any;
|
|
129
|
+
xl: any;
|
|
130
|
+
"2xl": any;
|
|
131
|
+
"3xl": any;
|
|
132
|
+
"4xl": any;
|
|
133
|
+
};
|
|
134
|
+
fonts: {
|
|
135
|
+
sans: any;
|
|
136
|
+
mono: any;
|
|
137
|
+
display: any;
|
|
138
|
+
body: any;
|
|
139
|
+
};
|
|
140
|
+
sizes: {
|
|
141
|
+
"0": any;
|
|
142
|
+
"1": any;
|
|
143
|
+
"2": any;
|
|
144
|
+
"3": any;
|
|
145
|
+
"4": any;
|
|
146
|
+
"5": any;
|
|
147
|
+
"6": any;
|
|
148
|
+
"7": any;
|
|
149
|
+
"8": any;
|
|
150
|
+
};
|
|
151
|
+
radii: {
|
|
152
|
+
"0": any;
|
|
153
|
+
"1": any;
|
|
154
|
+
"2": any;
|
|
155
|
+
"3": any;
|
|
156
|
+
round: any;
|
|
157
|
+
};
|
|
158
|
+
shadows: {
|
|
159
|
+
"0": any;
|
|
160
|
+
"1": any;
|
|
161
|
+
"2": any;
|
|
162
|
+
"3": any;
|
|
163
|
+
};
|
|
164
|
+
ratios: {
|
|
165
|
+
"16-9": any;
|
|
166
|
+
"3-2": any;
|
|
167
|
+
"4-3": any;
|
|
168
|
+
"1-1": any;
|
|
169
|
+
"3-4": any;
|
|
170
|
+
};
|
|
171
|
+
}, import("@stitches/react/types/config").DefaultThemeMap, {
|
|
172
|
+
bg: (value: import("@stitches/react/types/css-util").WithPropertyValue<"background">) => {
|
|
173
|
+
background: import("@stitches/react/types/css-util").WithPropertyValue<"background">;
|
|
174
|
+
};
|
|
175
|
+
size: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"size">) => {
|
|
176
|
+
height: string | number | import("@stitches/react/types/css-util").WithScaleValue<"size">;
|
|
177
|
+
width: string | number | import("@stitches/react/types/css-util").WithScaleValue<"size">;
|
|
178
|
+
};
|
|
179
|
+
p: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
180
|
+
padding: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
181
|
+
};
|
|
182
|
+
pt: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
183
|
+
paddingTop: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
184
|
+
};
|
|
185
|
+
pr: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
186
|
+
paddingRight: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
187
|
+
};
|
|
188
|
+
pb: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
189
|
+
paddingBottom: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
190
|
+
};
|
|
191
|
+
pl: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
192
|
+
paddingLeft: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
193
|
+
};
|
|
194
|
+
px: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
195
|
+
paddingLeft: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
196
|
+
paddingRight: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
197
|
+
};
|
|
198
|
+
py: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
199
|
+
paddingTop: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
200
|
+
paddingBottom: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
201
|
+
};
|
|
202
|
+
m: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
203
|
+
margin: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
204
|
+
};
|
|
205
|
+
mt: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
206
|
+
marginTop: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
207
|
+
};
|
|
208
|
+
mr: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
209
|
+
marginRight: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
210
|
+
};
|
|
211
|
+
mb: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
212
|
+
marginBottom: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
213
|
+
};
|
|
214
|
+
ml: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
215
|
+
marginLeft: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
216
|
+
};
|
|
217
|
+
mx: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
218
|
+
marginLeft: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
219
|
+
marginRight: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
220
|
+
};
|
|
221
|
+
my: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
222
|
+
marginTop: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
223
|
+
marginBottom: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
224
|
+
};
|
|
225
|
+
}> | undefined;
|
|
226
|
+
}, "size" | "css"> & import("@stitches/react/types/styled-component").TransformProps<{
|
|
227
|
+
size?: "sm" | "md" | "lg" | undefined;
|
|
228
|
+
}, {
|
|
229
|
+
sm: string;
|
|
230
|
+
md: string;
|
|
231
|
+
lg: string;
|
|
232
|
+
xl: string;
|
|
233
|
+
reducedMotion: string;
|
|
234
|
+
allowMotion: string;
|
|
235
|
+
hover: string;
|
|
236
|
+
}> & {
|
|
237
|
+
css?: import("@stitches/react/types/css-util").CSS<{
|
|
238
|
+
sm: string;
|
|
239
|
+
md: string;
|
|
240
|
+
lg: string;
|
|
241
|
+
xl: string;
|
|
242
|
+
reducedMotion: string;
|
|
243
|
+
allowMotion: string;
|
|
244
|
+
hover: string;
|
|
245
|
+
}, {
|
|
246
|
+
colors: {
|
|
247
|
+
textForeground: any;
|
|
248
|
+
textSubtle: any;
|
|
249
|
+
textPlaceholder: any;
|
|
250
|
+
background: any;
|
|
251
|
+
backgroundAccent: any;
|
|
252
|
+
grey100: any;
|
|
253
|
+
grey200: any;
|
|
254
|
+
grey300: any;
|
|
255
|
+
grey400: any;
|
|
256
|
+
grey500: any;
|
|
257
|
+
grey600: any;
|
|
258
|
+
grey700: any;
|
|
259
|
+
grey800: any;
|
|
260
|
+
grey900: any;
|
|
261
|
+
grey1000: any;
|
|
262
|
+
grey1100: any;
|
|
263
|
+
grey1200: any;
|
|
264
|
+
blue100: any;
|
|
265
|
+
blue200: any;
|
|
266
|
+
blue300: any;
|
|
267
|
+
blue400: any;
|
|
268
|
+
blue500: any;
|
|
269
|
+
blue600: any;
|
|
270
|
+
blue700: any;
|
|
271
|
+
blue800: any;
|
|
272
|
+
blue900: any;
|
|
273
|
+
blue1000: any;
|
|
274
|
+
blue1100: any;
|
|
275
|
+
blue1200: any;
|
|
276
|
+
purple100: any;
|
|
277
|
+
purple200: any;
|
|
278
|
+
purple300: any;
|
|
279
|
+
purple400: any;
|
|
280
|
+
purple500: any;
|
|
281
|
+
purple600: any;
|
|
282
|
+
purple700: any;
|
|
283
|
+
purple800: any;
|
|
284
|
+
purple900: any;
|
|
285
|
+
purple1000: any;
|
|
286
|
+
purple1100: any;
|
|
287
|
+
purple1200: any;
|
|
288
|
+
tonal50: any;
|
|
289
|
+
tonal100: any;
|
|
290
|
+
tonal200: any;
|
|
291
|
+
tonal300: any;
|
|
292
|
+
tonal400: any;
|
|
293
|
+
tonal500: any;
|
|
294
|
+
tonal600: any;
|
|
295
|
+
alpha100: any;
|
|
296
|
+
alpha150: any;
|
|
297
|
+
alpha200: any;
|
|
298
|
+
alpha250: any;
|
|
299
|
+
alpha600: any;
|
|
300
|
+
primaryLight: any;
|
|
301
|
+
primary: any;
|
|
302
|
+
primaryMid: any;
|
|
303
|
+
primaryDark: any;
|
|
304
|
+
secondary: any;
|
|
305
|
+
brandRed: any;
|
|
306
|
+
brandRedAccent: any;
|
|
307
|
+
brandGreen: any;
|
|
308
|
+
brandGreenAccent: any;
|
|
309
|
+
brandPurple: any;
|
|
310
|
+
brandPurpleAccent: any;
|
|
311
|
+
brandYellow: any;
|
|
312
|
+
brandYellowAccent: any;
|
|
313
|
+
successLight: any;
|
|
314
|
+
success: any;
|
|
315
|
+
successMid: any;
|
|
316
|
+
successDark: any;
|
|
317
|
+
dangerLight: any;
|
|
318
|
+
danger: any;
|
|
319
|
+
dangerMid: any;
|
|
320
|
+
dangerDark: any;
|
|
321
|
+
warningLight: any;
|
|
322
|
+
warning: any;
|
|
323
|
+
warningMid: any;
|
|
324
|
+
warningDark: any;
|
|
325
|
+
warningText: any;
|
|
326
|
+
subjectEnglish: any;
|
|
327
|
+
subjectMaths: any;
|
|
328
|
+
subjectScience: any;
|
|
329
|
+
subjectVerbalReasoning: any;
|
|
330
|
+
subjectNonVerbalReasoning: any;
|
|
331
|
+
subjectCreativeWriting: any;
|
|
332
|
+
subjectExamSkills: any;
|
|
333
|
+
};
|
|
334
|
+
space: {
|
|
335
|
+
"0": any;
|
|
336
|
+
"1": any;
|
|
337
|
+
"2": any;
|
|
338
|
+
"3": any;
|
|
339
|
+
"4": any;
|
|
340
|
+
"5": any;
|
|
341
|
+
"6": any;
|
|
342
|
+
"7": any;
|
|
343
|
+
"8": any;
|
|
344
|
+
"9": any;
|
|
345
|
+
"24": any;
|
|
346
|
+
};
|
|
347
|
+
fontSizes: {
|
|
348
|
+
xs: any;
|
|
349
|
+
sm: any;
|
|
350
|
+
md: any;
|
|
351
|
+
lg: any;
|
|
352
|
+
xl: any;
|
|
353
|
+
"2xl": any;
|
|
354
|
+
"3xl": any;
|
|
355
|
+
"4xl": any;
|
|
356
|
+
};
|
|
357
|
+
fonts: {
|
|
358
|
+
sans: any;
|
|
359
|
+
mono: any;
|
|
360
|
+
display: any;
|
|
361
|
+
body: any;
|
|
362
|
+
};
|
|
363
|
+
sizes: {
|
|
364
|
+
"0": any;
|
|
365
|
+
"1": any;
|
|
366
|
+
"2": any;
|
|
367
|
+
"3": any;
|
|
368
|
+
"4": any;
|
|
369
|
+
"5": any;
|
|
370
|
+
"6": any;
|
|
371
|
+
"7": any;
|
|
372
|
+
"8": any;
|
|
373
|
+
};
|
|
374
|
+
radii: {
|
|
375
|
+
"0": any;
|
|
376
|
+
"1": any;
|
|
377
|
+
"2": any;
|
|
378
|
+
"3": any;
|
|
379
|
+
round: any;
|
|
380
|
+
};
|
|
381
|
+
shadows: {
|
|
382
|
+
"0": any;
|
|
383
|
+
"1": any;
|
|
384
|
+
"2": any;
|
|
385
|
+
"3": any;
|
|
386
|
+
};
|
|
387
|
+
ratios: {
|
|
388
|
+
"16-9": any;
|
|
389
|
+
"3-2": any;
|
|
390
|
+
"4-3": any;
|
|
391
|
+
"1-1": any;
|
|
392
|
+
"3-4": any;
|
|
393
|
+
};
|
|
394
|
+
}, import("@stitches/react/types/config").DefaultThemeMap, {
|
|
395
|
+
bg: (value: import("@stitches/react/types/css-util").WithPropertyValue<"background">) => {
|
|
396
|
+
background: import("@stitches/react/types/css-util").WithPropertyValue<"background">;
|
|
397
|
+
};
|
|
398
|
+
size: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"size">) => {
|
|
399
|
+
height: string | number | import("@stitches/react/types/css-util").WithScaleValue<"size">;
|
|
400
|
+
width: string | number | import("@stitches/react/types/css-util").WithScaleValue<"size">;
|
|
401
|
+
};
|
|
402
|
+
p: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
403
|
+
padding: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
404
|
+
};
|
|
405
|
+
pt: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
406
|
+
paddingTop: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
407
|
+
};
|
|
408
|
+
pr: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
409
|
+
paddingRight: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
410
|
+
};
|
|
411
|
+
pb: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
412
|
+
paddingBottom: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
413
|
+
};
|
|
414
|
+
pl: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
415
|
+
paddingLeft: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
416
|
+
};
|
|
417
|
+
px: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
418
|
+
paddingLeft: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
419
|
+
paddingRight: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
420
|
+
};
|
|
421
|
+
py: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
422
|
+
paddingTop: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
423
|
+
paddingBottom: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
424
|
+
};
|
|
425
|
+
m: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
426
|
+
margin: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
427
|
+
};
|
|
428
|
+
mt: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
429
|
+
marginTop: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
430
|
+
};
|
|
431
|
+
mr: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
432
|
+
marginRight: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
433
|
+
};
|
|
434
|
+
mb: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
435
|
+
marginBottom: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
436
|
+
};
|
|
437
|
+
ml: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
438
|
+
marginLeft: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
439
|
+
};
|
|
440
|
+
mx: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
441
|
+
marginLeft: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
442
|
+
marginRight: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
443
|
+
};
|
|
444
|
+
my: (value: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">) => {
|
|
445
|
+
marginTop: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
446
|
+
marginBottom: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
447
|
+
};
|
|
448
|
+
}> | undefined;
|
|
449
|
+
}> & {
|
|
4
450
|
Content: ({ children, ...rest }: {
|
|
5
451
|
[x: string]: any;
|
|
6
452
|
children: any;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{Ok as
|
|
1
|
+
import{Ok as m}from"@atom-learning/icons";import*as n from"@radix-ui/react-toggle-group";import*as o from"react";import{Chip as r}from"../chip/Chip.js";import"../chip/ChipGroup.js";import{Icon as s}from"../icon/Icon.js";import{styled as e}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import"../../utilities/no-overflow-wrapper/NoOverflowWrapper.js";import"color2k";import{focusVisibleStyleBlock as p}from"../../utilities/style/focus-visible-style-block.js";import"../../utilities/style/keyframe-animations.js";const i=e(s,{display:"none"}),c=e.withConfig({shouldForwardStitchesProp:t=>["as"].includes(t)})(r,{"&:not([disabled])":{cursor:"pointer","&:hover":{bg:"$tonal100",color:"$tonal600",borderColor:"currentColor"},"&:focus-visible":{...p()},'&[data-state="on"]':{"&:hover":{bg:"$white",color:"$primaryDark"}}},'&[data-state="off"]':{color:"$tonal400",bg:"$tonal50",borderColor:"$tonal200"},'&[data-state="on"]':{[`& ${i}`]:{display:"block"}}}),d=({size:t="md",children:l,...a})=>o.createElement(n.Item,{...a,asChild:!0},o.createElement(c,{as:"button"},o.createElement(i,{is:m,size:t==="lg"?"md":"sm"}),o.createElement(r.Content,null,l)));export{d as ChipToggleGroupItem};
|
|
2
2
|
//# sourceMappingURL=ChipToggleGroupItem.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ChipToggleGroupItem.js","sources":["../../../src/components/chip-toggle-group/ChipToggleGroupItem.tsx"],"sourcesContent":["import { Ok } from '@atom-learning/icons'\nimport * as ToggleGroup from '@radix-ui/react-toggle-group'\nimport * as React from 'react'\n\nimport { Chip } from '~/components/chip'\nimport { Icon } from '~/components/icon'\nimport { styled } from '~/stitches'\nimport { focusVisibleStyleBlock } from '~/utilities'\n\nconst StyledChipToggleIcon = styled(Icon, {\n display: 'none'\n})\n\nconst StyledChipToggleGroupItem = styled(Chip, {\n '&:not([disabled])': {\n cursor: 'pointer',\n '&:hover': {\n bg: '$tonal100',\n color: '$tonal600',\n borderColor: 'currentColor'\n },\n '&:focus-visible': {\n ...focusVisibleStyleBlock()\n },\n '&[data-state=\"on\"]': {\n '&:hover': {\n bg: '$white',\n color: '$primaryDark'\n }\n }\n },\n '&[data-state=\"off\"]': {\n color: '$tonal400',\n bg: '$tonal50',\n borderColor: '$tonal200'\n },\n '&[data-state=\"on\"]': {\n [`& ${StyledChipToggleIcon}`]: {\n display: 'block'\n }\n }\n})\n\ntype TChipToggleGroupItem = React.ComponentProps<typeof ToggleGroup.Item> &\n React.ComponentProps<typeof StyledChipToggleGroupItem>\n\nexport const ChipToggleGroupItem: React.FC<TChipToggleGroupItem> = ({\n size = 'md',\n children,\n ...rest\n}) => {\n return (\n <ToggleGroup.Item {...rest} asChild>\n <StyledChipToggleGroupItem
|
|
1
|
+
{"version":3,"file":"ChipToggleGroupItem.js","sources":["../../../src/components/chip-toggle-group/ChipToggleGroupItem.tsx"],"sourcesContent":["import { Ok } from '@atom-learning/icons'\nimport * as ToggleGroup from '@radix-ui/react-toggle-group'\nimport * as React from 'react'\n\nimport { Chip } from '~/components/chip'\nimport { Icon } from '~/components/icon'\nimport { styled } from '~/stitches'\nimport { focusVisibleStyleBlock } from '~/utilities'\n\nconst StyledChipToggleIcon = styled(Icon, {\n display: 'none'\n})\n\nconst StyledChipToggleGroupItem = styled.withConfig({\n shouldForwardStitchesProp: (propName) => ['as'].includes(propName)\n})(Chip, {\n '&:not([disabled])': {\n cursor: 'pointer',\n '&:hover': {\n bg: '$tonal100',\n color: '$tonal600',\n borderColor: 'currentColor'\n },\n '&:focus-visible': {\n ...focusVisibleStyleBlock()\n },\n '&[data-state=\"on\"]': {\n '&:hover': {\n bg: '$white',\n color: '$primaryDark'\n }\n }\n },\n '&[data-state=\"off\"]': {\n color: '$tonal400',\n bg: '$tonal50',\n borderColor: '$tonal200'\n },\n '&[data-state=\"on\"]': {\n [`& ${StyledChipToggleIcon}`]: {\n display: 'block'\n }\n }\n})\n\ntype TChipToggleGroupItem = React.ComponentProps<typeof ToggleGroup.Item> &\n React.ComponentProps<typeof StyledChipToggleGroupItem>\n\nexport const ChipToggleGroupItem: React.FC<TChipToggleGroupItem> = ({\n size = 'md',\n children,\n ...rest\n}) => {\n return (\n <ToggleGroup.Item {...rest} asChild>\n <StyledChipToggleGroupItem as=\"button\">\n <StyledChipToggleIcon is={Ok} size={size === 'lg' ? 'md' : 'sm'} />\n <Chip.Content>{children}</Chip.Content>\n </StyledChipToggleGroupItem>\n </ToggleGroup.Item>\n )\n}\n"],"names":["StyledChipToggleIcon","styled","Icon","StyledChipToggleGroupItem","propName","Chip","focusVisibleStyleBlock","ChipToggleGroupItem","size","children","rest","React","ToggleGroup","Ok"],"mappings":"2hBASA,MAAMA,EAAuBC,EAAOC,EAAM,CACxC,QAAS,MACX,CAAC,EAEKC,EAA4BF,EAAO,WAAW,CAClD,0BAA4BG,GAAa,CAAC,IAAI,EAAE,SAASA,CAAQ,CACnE,CAAC,EAAEC,EAAM,CACP,oBAAqB,CACnB,OAAQ,UACR,UAAW,CACT,GAAI,YACJ,MAAO,YACP,YAAa,cACf,EACA,kBAAmB,CACjB,GAAGC,GACL,EACA,qBAAsB,CACpB,UAAW,CACT,GAAI,SACJ,MAAO,cACT,CACF,CACF,EACA,sBAAuB,CACrB,MAAO,YACP,GAAI,WACJ,YAAa,WACf,EACA,qBAAsB,CACpB,CAAC,KAAKN,KAAyB,CAC7B,QAAS,OACX,CACF,CACF,CAAC,EAKYO,EAAsD,CAAC,CAClE,KAAAC,EAAO,KACP,SAAAC,KACGC,CACL,IAEIC,EAAA,cAACC,EAAY,KAAZ,CAAkB,GAAGF,EAAM,QAAO,EAAA,EACjCC,EAAA,cAACR,EAAA,CAA0B,GAAG,UAC5BQ,EAAA,cAACX,EAAA,CAAqB,GAAIa,EAAI,KAAML,IAAS,KAAO,KAAO,IAAA,CAAM,EACjEG,EAAA,cAACN,EAAK,QAAL,KAAcI,CAAS,CAC1B,CACF"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{Combobox as t,ComboboxOptionText as b}from"@reach/combobox";import*as r from"react";import{globalCss as p,styled as i}from"../../stitches.js";import{ComboboxInput as
|
|
1
|
+
import{Combobox as t,ComboboxOptionText as b}from"@reach/combobox";import*as r from"react";import{globalCss as p,styled as i}from"../../stitches.js";import{ComboboxInput as e}from"./ComboboxInput.js";import{ComboboxList as x}from"./ComboboxList.js";import{ComboboxOption as n}from"./ComboboxOption.js";import{ComboboxPopover as s}from"./ComboboxPopover.js";p({":root":{"--reach-combobox":1}})();const C=i(t,{}),o=m=>r.createElement(C,{...m});o.displayName="Combobox",o.Option=n,o.Input=e,o.Popover=s,o.List=x,o.OptionText=b;export{o as Combobox};
|
|
2
2
|
//# sourceMappingURL=Combobox.js.map
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
export declare const StyledComboboxInput: import("@stitches/react/types/styled-component").StyledComponent<import("@reach/utils/dist/declarations/src/polymorphic").ForwardRefComponent<"input", import("@reach/combobox").ComboboxInputProps>, {
|
|
3
|
+
size?: "sm" | "md" | "lg" | undefined;
|
|
2
4
|
state?: "error" | undefined;
|
|
3
5
|
}, {
|
|
4
6
|
sm: string;
|
|
@@ -220,3 +222,5 @@ export declare const ComboboxInput: import("@stitches/react/types/styled-compone
|
|
|
220
222
|
marginBottom: string | number | import("@stitches/react/types/css-util").WithScaleValue<"space">;
|
|
221
223
|
};
|
|
222
224
|
}>>;
|
|
225
|
+
export declare type ComboboxInputProps = React.ComponentProps<typeof StyledComboboxInput>;
|
|
226
|
+
export declare const ComboboxInput: React.FC<ComboboxInputProps>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{ComboboxInput as
|
|
1
|
+
import{ComboboxInput as i}from"@reach/combobox";import*as o from"react";import{styled as a,theme as l}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import"../../utilities/no-overflow-wrapper/NoOverflowWrapper.js";import{encodeBackgroundIcon as d}from"../../utilities/style/encode-background-icon.js";import"../../utilities/style/keyframe-animations.js";const e=a(i,{boxShadow:"none",appearance:"none",backgroundImage:d(l.colors.tonal300.value,"chevron"),backgroundPosition:"right $space$3 top 50%, 0 0",backgroundRepeat:"no-repeat, repeat",backgroundSize:"20px auto, 100%",border:"1px solid $tonal300",borderRadius:"$0",boxSizing:"border-box",color:"$tonal600",cursor:"text",display:"block",fontFamily:"$body",height:"$4",pl:"$3",pr:"$6",transition:"all 100ms ease-out",width:"100%","&::placeholder":{color:"$tonal300",opacity:1},"&:focus-within":{borderColor:"$primary",outline:"none"},"&[disabled]":{backgroundColor:"$tonal100",color:"$tonal400",cursor:"not-allowed"},variants:{size:{sm:{height:"$3",fontSize:"$sm",lineHeight:1.7},md:{height:"$4",fontSize:"$md",lineHeight:2},lg:{height:"$5",fontSize:"$md",lineHeight:2}},state:{error:{border:"1px solid $danger"}}}}),p=o.forwardRef(({size:r="md",...t},n)=>o.createElement(e,{size:r,...t,ref:n}));export{p as ComboboxInput,e as StyledComboboxInput};
|
|
2
2
|
//# sourceMappingURL=ComboboxInput.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ComboboxInput.js","sources":["../../../src/components/combobox/ComboboxInput.tsx"],"sourcesContent":["import { ComboboxInput as BaseComboboxInput } from '@reach/combobox'\n\nimport { styled, theme } from '~/stitches'\nimport { encodeBackgroundIcon } from '~/utilities'\n\nexport const
|
|
1
|
+
{"version":3,"file":"ComboboxInput.js","sources":["../../../src/components/combobox/ComboboxInput.tsx"],"sourcesContent":["import { ComboboxInput as BaseComboboxInput } from '@reach/combobox'\nimport * as React from 'react'\n\nimport { styled, theme } from '~/stitches'\nimport { encodeBackgroundIcon } from '~/utilities'\nimport { Override } from '~/utilities/types'\n\nexport const StyledComboboxInput = styled(BaseComboboxInput, {\n boxShadow: 'none', // prevent default iOS default styling\n appearance: 'none',\n backgroundImage: encodeBackgroundIcon(theme.colors.tonal300.value, 'chevron'),\n backgroundPosition: 'right $space$3 top 50%, 0 0',\n backgroundRepeat: 'no-repeat, repeat',\n backgroundSize: '20px auto, 100%',\n border: '1px solid $tonal300',\n borderRadius: '$0',\n boxSizing: 'border-box',\n color: '$tonal600',\n cursor: 'text',\n display: 'block',\n fontFamily: '$body',\n height: '$4',\n pl: '$3',\n pr: '$6',\n transition: 'all 100ms ease-out',\n width: '100%',\n '&::placeholder': {\n color: '$tonal300',\n opacity: 1\n },\n '&:focus-within': {\n borderColor: '$primary',\n outline: 'none'\n },\n '&[disabled]': {\n backgroundColor: '$tonal100',\n color: '$tonal400',\n cursor: 'not-allowed'\n },\n variants: {\n size: {\n sm: {\n height: '$3',\n fontSize: '$sm',\n lineHeight: 1.7\n },\n md: {\n height: '$4',\n fontSize: '$md',\n lineHeight: 2\n },\n lg: {\n height: '$5',\n fontSize: '$md',\n lineHeight: 2\n }\n },\n state: {\n error: {\n border: '1px solid $danger'\n }\n }\n }\n})\n\nexport type ComboboxInputProps = React.ComponentProps<\n typeof StyledComboboxInput\n>\n\nexport const ComboboxInput: React.FC<ComboboxInputProps> = React.forwardRef(\n ({ size = 'md', ...rest }, ref) => {\n return <StyledComboboxInput size={size} {...rest} ref={ref} />\n }\n)\n"],"names":["StyledComboboxInput","styled","BaseComboboxInput","encodeBackgroundIcon","theme","ComboboxInput","React","size","rest","ref"],"mappings":"6XAOO,MAAMA,EAAsBC,EAAOC,EAAmB,CAC3D,UAAW,OACX,WAAY,OACZ,gBAAiBC,EAAqBC,EAAM,OAAO,SAAS,MAAO,SAAS,EAC5E,mBAAoB,8BACpB,iBAAkB,oBAClB,eAAgB,kBAChB,OAAQ,sBACR,aAAc,KACd,UAAW,aACX,MAAO,YACP,OAAQ,OACR,QAAS,QACT,WAAY,QACZ,OAAQ,KACR,GAAI,KACJ,GAAI,KACJ,WAAY,qBACZ,MAAO,OACP,iBAAkB,CAChB,MAAO,YACP,QAAS,CACX,EACA,iBAAkB,CAChB,YAAa,WACb,QAAS,MACX,EACA,cAAe,CACb,gBAAiB,YACjB,MAAO,YACP,OAAQ,aACV,EACA,SAAU,CACR,KAAM,CACJ,GAAI,CACF,OAAQ,KACR,SAAU,MACV,WAAY,GACd,EACA,GAAI,CACF,OAAQ,KACR,SAAU,MACV,WAAY,CACd,EACA,GAAI,CACF,OAAQ,KACR,SAAU,MACV,WAAY,CACd,CACF,EACA,MAAO,CACL,MAAO,CACL,OAAQ,mBACV,CACF,CACF,CACF,CAAC,EAMYC,EAA8CC,EAAM,WAC/D,CAAC,CAAE,KAAAC,EAAO,QAASC,CAAK,EAAGC,IAClBH,EAAA,cAACN,EAAA,CAAoB,KAAMO,EAAO,GAAGC,EAAM,IAAKC,EAAK,CAEhE"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import type { CSS } from '../../stitches';
|
|
3
|
+
import { Override } from '../../utilities';
|
|
3
4
|
import { FieldElementWrapperProps } from '../field-wrapper';
|
|
4
5
|
import { PasswordInput } from '../password-input';
|
|
5
|
-
import { Override } from '../../utilities';
|
|
6
6
|
declare type ValidationResult = Record<string, boolean>;
|
|
7
7
|
declare type CreatePasswordFieldProps = Override<React.ComponentProps<typeof PasswordInput> & FieldElementWrapperProps, {
|
|
8
8
|
label?: string;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import j from"invariant";import*as a from"react";import{useFormContext as E}from"react-hook-form";import{throttle as k}from"throttle-debounce";import{Box as P}from"../box/Box.js";import{Flex as S}from"../flex/Flex.js";import{InlineMessage as
|
|
1
|
+
import j from"invariant";import*as a from"react";import{useFormContext as E}from"react-hook-form";import{throttle as k}from"throttle-debounce";import{Box as P}from"../box/Box.js";import{Flex as S}from"../flex/Flex.js";import{InlineMessage as B}from"../inline-message/InlineMessage.js";import{PasswordField as D}from"../password-field/PasswordField.js";const c=({validate:d,defaultValidation:u,messageDirection:p="row",label:f="Create a password",name:r="password",css:v,validation:b,...w})=>{var s;const{formState:l}=E(),[i,n]=a.useState(!1),[C,m]=a.useState(u),F=l.touched[r],g=((s=l.errors[r])==null?void 0:s.type)==="validate",o=a.useCallback(async e=>{const t=await d(e);return t?(j(typeof t=="object","The validate function must return an object"),m(t),Object.values(t).every(h=>h)):!1},[m]),x=a.useCallback(k(500,o),[o]),y=(e,t)=>e?"success":t?"neutral":"error";return a.createElement(P,{css:v},a.createElement(D,{label:f,name:r,onChange:e=>x(e.target.value),onBlur:()=>n(!1),onFocus:()=>n(!0),validation:{...b,validate:o},...w}),(F||i||g)&&a.createElement(S,{css:{mt:"$2",gap:"$2",flexWrap:"wrap",flexDirection:p}},Object.entries(C).map(([e,t])=>a.createElement(B,{key:e,theme:y(t,i)},e))))};c.displayName="CreatePasswordField";export{c as CreatePasswordField};
|
|
2
2
|
//# sourceMappingURL=CreatePasswordField.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CreatePasswordField.js","sources":["../../../src/components/create-password-field/CreatePasswordField.tsx"],"sourcesContent":["import invariant from 'invariant'\nimport * as React from 'react'\nimport { useFormContext } from 'react-hook-form'\nimport { throttle } from 'throttle-debounce'\n\nimport type { CSS } from '~/stitches'\n\nimport { Box } from '../box'\nimport { FieldElementWrapperProps } from '../field-wrapper'\nimport { Flex } from '../flex'\nimport { InlineMessage } from '../inline-message'\nimport { PasswordField } from '../password-field'\nimport { PasswordInput } from '../password-input'\
|
|
1
|
+
{"version":3,"file":"CreatePasswordField.js","sources":["../../../src/components/create-password-field/CreatePasswordField.tsx"],"sourcesContent":["import invariant from 'invariant'\nimport * as React from 'react'\nimport { useFormContext } from 'react-hook-form'\nimport { throttle } from 'throttle-debounce'\n\nimport type { CSS } from '~/stitches'\nimport { Override } from '~/utilities'\n\nimport { Box } from '../box'\nimport { FieldElementWrapperProps } from '../field-wrapper'\nimport { Flex } from '../flex'\nimport { InlineMessage } from '../inline-message'\nimport { PasswordField } from '../password-field'\nimport { PasswordInput } from '../password-input'\n\ntype ValidationResult = Record<string, boolean>\n\ntype CreatePasswordFieldProps = Override<\n React.ComponentProps<typeof PasswordInput> & FieldElementWrapperProps,\n {\n label?: string\n name?: string\n validate: (\n password: string\n ) => Promise<ValidationResult | undefined> | ValidationResult\n defaultValidation: ValidationResult\n messageDirection?: CSS['flexDirection']\n }\n>\n\nexport const CreatePasswordField = ({\n validate,\n defaultValidation,\n messageDirection = 'row',\n label = 'Create a password',\n name = 'password',\n css,\n validation,\n ...remainingProps\n}: CreatePasswordFieldProps) => {\n const { formState } = useFormContext()\n const [isFocused, setIsFocused] = React.useState<boolean>(false)\n const [validationResult, setValidationResult] =\n React.useState<ValidationResult>(defaultValidation)\n\n const touched = formState.touched[name]\n const error = formState.errors[name]?.type === 'validate'\n\n const validatePassword = React.useCallback(\n async (password: string) => {\n const result = await validate(password)\n\n if (result) {\n invariant(\n typeof result === 'object',\n 'The validate function must return an object'\n )\n\n setValidationResult(result)\n return Object.values(result).every((isValid) => isValid)\n }\n\n return false\n },\n [setValidationResult]\n )\n\n const handleChange = React.useCallback(throttle(500, validatePassword), [\n validatePassword\n ])\n\n const getMessageTheme = (result: boolean, isFocused: boolean) => {\n if (result) return 'success'\n\n return isFocused ? 'neutral' : 'error'\n }\n\n return (\n <Box css={css}>\n <PasswordField\n label={label}\n name={name}\n onChange={(e) => handleChange(e.target.value)}\n onBlur={() => setIsFocused(false)}\n onFocus={() => setIsFocused(true)}\n validation={{ ...validation, validate: validatePassword }}\n {...remainingProps}\n />\n {(touched || isFocused || error) && (\n <Flex\n css={{\n mt: '$2',\n gap: '$2',\n flexWrap: 'wrap',\n flexDirection: messageDirection\n }}\n >\n {Object.entries(validationResult).map(([message, result]) => (\n <InlineMessage\n key={message}\n theme={getMessageTheme(result, isFocused)}\n >\n {message}\n </InlineMessage>\n ))}\n </Flex>\n )}\n </Box>\n )\n}\n\nCreatePasswordField.displayName = 'CreatePasswordField'\n"],"names":["CreatePasswordField","validate","defaultValidation","messageDirection","label","name","css","validation","remainingProps","_a","formState","useFormContext","isFocused","setIsFocused","React","validationResult","setValidationResult","touched","error","validatePassword","password","result","invariant","isValid","handleChange","throttle","getMessageTheme","Box","PasswordField","Flex","message","InlineMessage"],"mappings":"gWA8Ba,MAAAA,EAAsB,CAAC,CAClC,SAAAC,EACA,kBAAAC,EACA,iBAAAC,EAAmB,MACnB,MAAAC,EAAQ,oBACR,KAAAC,EAAO,WACP,IAAAC,EACA,WAAAC,KACGC,CACL,IAAgC,CAvChC,IAAAC,EAwCE,KAAM,CAAE,UAAAC,CAAU,EAAIC,EAAAA,EAChB,CAACC,EAAWC,CAAY,EAAIC,EAAM,SAAkB,EAAK,EACzD,CAACC,EAAkBC,CAAmB,EAC1CF,EAAM,SAA2BZ,CAAiB,EAE9Ce,EAAUP,EAAU,QAAQL,GAC5Ba,IAAQT,EAAAC,EAAU,OAAOL,KAAjB,KAAA,OAAAI,EAAwB,QAAS,WAEzCU,EAAmBL,EAAM,YAC7B,MAAOM,GAAqB,CAC1B,MAAMC,EAAS,MAAMpB,EAASmB,CAAQ,EAEtC,OAAIC,GACFC,EACE,OAAOD,GAAW,SAClB,6CACF,EAEAL,EAAoBK,CAAM,EACnB,OAAO,OAAOA,CAAM,EAAE,MAAOE,GAAYA,CAAO,GAGlD,EACT,EACA,CAACP,CAAmB,CACtB,EAEMQ,EAAeV,EAAM,YAAYW,EAAS,IAAKN,CAAgB,EAAG,CACtEA,CACF,CAAC,EAEKO,EAAkB,CAACL,EAAiBT,IACpCS,EAAe,UAEZT,EAAY,UAAY,QAGjC,OACEE,EAAA,cAACa,EAAA,CAAI,IAAKrB,CAAAA,EACRQ,EAAA,cAACc,EAAA,CACC,MAAOxB,EACP,KAAMC,EACN,SAAW,GAAMmB,EAAa,EAAE,OAAO,KAAK,EAC5C,OAAQ,IAAMX,EAAa,EAAK,EAChC,QAAS,IAAMA,EAAa,EAAI,EAChC,WAAY,CAAE,GAAGN,EAAY,SAAUY,CAAiB,EACvD,GAAGX,CAAAA,CACN,GACES,GAAWL,GAAaM,IACxBJ,EAAA,cAACe,EAAA,CACC,IAAK,CACH,GAAI,KACJ,IAAK,KACL,SAAU,OACV,cAAe1B,CACjB,CAAA,EAEC,OAAO,QAAQY,CAAgB,EAAE,IAAI,CAAC,CAACe,EAAST,CAAM,IACrDP,EAAA,cAACiB,EAAA,CACC,IAAKD,EACL,MAAOJ,EAAgBL,EAAQT,CAAS,CAEvCkB,EAAAA,CACH,CACD,CACH,CAEJ,CAEJ,EAEA9B,EAAoB,YAAc"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import*as
|
|
1
|
+
import*as r from"react";import{Table as m}from"../table/Table.js";import{useDataTable as p}from"./DataTableContext.js";import{DataTable as i}from"./DataTable.js";const l=({striped:t=!1,...o})=>{const{getRowModel:a}=p();return r.createElement(m.Body,{...o,striped:t},a().rows.map(e=>r.createElement(i.Row,{row:e,key:e.id})))};export{l as DataTableBody};
|
|
2
2
|
//# sourceMappingURL=DataTableBody.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import*as
|
|
1
|
+
import*as e from"react";import{debounce as f}from"throttle-debounce";import{OptionallyVisuallyHiddenContainer as d}from"../../utilities/optionally-visually-hidden-container/OptionallyVisuallyHiddenContainer.js";import{Label as g}from"../label/Label.js";import{SearchInput as h}from"../search-input/SearchInput.js";import{AsyncDataState as D}from"./DataTable.types.js";import{useDataTable as E}from"./DataTableContext.js";const F=({onChange:a,label:t,hideLabel:r=!1,...n})=>{const{setGlobalFilter:o,getState:m,resetPagination:i,getTotalRows:s,asyncDataState:c}=E(),{globalFilter:u}=m();if(c!==D.PENDING&&s()===0)return null;const b=f(250,l=>{const{target:{value:p}}=l;a==null||a(l),i(),o(p)});return e.createElement(e.Fragment,null,e.createElement(d,{hidden:r},e.createElement(g,{css:{mb:"$3"},htmlFor:t},t)),e.createElement(h,{...n,defaultValue:u,onChange:b,name:t}))};export{F as DataTableGlobalFilter};
|
|
2
2
|
//# sourceMappingURL=DataTableGlobalFilter.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import*as a from"react";import{styled as
|
|
1
|
+
import*as a from"react";import{styled as e}from"../../stitches.js";import{Loader as r}from"../loader/Loader.js";import{AsyncDataState as m}from"./DataTable.types.js";import{useDataTable as n}from"./DataTableContext.js";const s=e(r,{position:"absolute",left:"50%",top:"50%",transform:"translate(-50%, -50%)",zIndex:1}),l=t=>{const{asyncDataState:o}=n();return o!==m.PENDING?null:a.createElement(s,{...t})};export{l as DataTableLoading};
|
|
2
2
|
//# sourceMappingURL=DataTableLoading.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import*as n from"@radix-ui/react-visually-hidden";import*as e from"react";import{Checkbox as c}from"../checkbox/Checkbox.js";import{Label as m}from"../label/Label.js";import{useDataTable as h}from"./DataTableContext.js";const i=({rowId:
|
|
1
|
+
import*as n from"@radix-ui/react-visually-hidden";import*as e from"react";import{Checkbox as c}from"../checkbox/Checkbox.js";import{Label as m}from"../label/Label.js";import{useDataTable as h}from"./DataTableContext.js";const i=({rowId:o,checked:r,onCheckedChange:a,label:l=`Row ${o} selection`})=>{const{tableId:t}=h();return e.createElement(e.Fragment,null,e.createElement(n.Root,null,e.createElement(m,{htmlFor:`${t}_row_${o}_selection`},l)),e.createElement(c,{checked:r,onCheckedChange:a,name:`${t}_row_${o}_selection`}))};export{i as DataTableRowSelectionCheckbox};
|
|
2
2
|
//# sourceMappingURL=DataTableRowSelectionCheckbox.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import*as c from"@radix-ui/react-visually-hidden";import*as e from"react";import{Checkbox as s}from"../checkbox/Checkbox.js";import{Label as i}from"../label/Label.js";import{useDataTable as g}from"./DataTableContext.js";const b=({label:r="All rows selection"})=>{const{getIsAllPageRowsSelected:
|
|
1
|
+
import*as c from"@radix-ui/react-visually-hidden";import*as e from"react";import{Checkbox as s}from"../checkbox/Checkbox.js";import{Label as i}from"../label/Label.js";import{useDataTable as g}from"./DataTableContext.js";const b=({label:r="All rows selection"})=>{const{getIsAllPageRowsSelected:l,getIsSomePageRowsSelected:t,toggleAllPageRowsSelected:o,tableId:a}=g(),m=()=>t()?"indeterminate":!!l(),n=()=>t()?o(!1):o(!l());return e.createElement(e.Fragment,null,e.createElement(c.Root,null,e.createElement(i,{htmlFor:`${a}_all_rows_selection`},r)),e.createElement(s,{checked:m(),onCheckedChange:n,name:`${a}_allRowsSelection`}))};export{b as DataTableSelectAllRowsCheckbox};
|
|
2
2
|
//# sourceMappingURL=DataTableSelectAllRowsCheckbox.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import*as
|
|
1
|
+
import*as o from"react";import{Table as d}from"../../table/Table.js";import{useDataTable as i}from"../DataTableContext.js";import{DragAndDropTableRow as p}from"./DragAndDropTableRow.js";const l=({striped:r=!1,idColumn:t="id",...m})=>{const{getRowModel:a}=i();return o.createElement(d.Body,{...m,striped:r},a().rows.map(e=>o.createElement(p,{row:e,key:e.id,idColumn:t})))};export{l as DragAndDropTableBody};
|
|
2
2
|
//# sourceMappingURL=DragAndDropTableBody.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import
|
|
1
|
+
import t from"react";const i=e=>{const[o,s]=t.useState(!1),[r,n]=t.useState(e?[{id:e.column,desc:e.direction==="desc"}]:[]);return{isSortable:o,setIsSortable:s,sorting:r,setSorting:n}};export{i as useSortByColumn};
|
|
2
2
|
//# sourceMappingURL=useSorting.js.map
|