@atom-learning/components 2.24.0 → 2.25.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.
Files changed (96) hide show
  1. package/CHANGELOG.md +207 -0
  2. package/dist/components/accordion/AccordionContent.js +1 -1
  3. package/dist/components/accordion/AccordionItem.js +1 -1
  4. package/dist/components/alert-dialog/AlertDialogContent.js +1 -1
  5. package/dist/components/avatar/Avatar.js +1 -1
  6. package/dist/components/button/Button.js +1 -1
  7. package/dist/components/calendar/Calendar.js +1 -1
  8. package/dist/components/carousel/CarouselArrows.js +1 -1
  9. package/dist/components/carousel/CarouselSlide.js +1 -1
  10. package/dist/components/checkbox-field/CheckboxField.js +1 -1
  11. package/dist/components/chip/Chip.js +1 -1
  12. package/dist/components/chip/ChipGroup.js +1 -1
  13. package/dist/components/chip-dismissible-group/ChipDismissibleGroupRoot.js +1 -1
  14. package/dist/components/data-table/DataTable.d.ts +24 -2
  15. package/dist/components/data-table/DataTable.js +1 -1
  16. package/dist/components/data-table/DataTable.types.d.ts +28 -0
  17. package/dist/components/data-table/DataTable.types.js +1 -0
  18. package/dist/components/data-table/DataTableBody.js +1 -1
  19. package/dist/components/data-table/DataTableContext.d.ts +13 -11
  20. package/dist/components/data-table/DataTableContext.js +1 -1
  21. package/dist/components/data-table/DataTableDataCell.js +1 -1
  22. package/dist/components/data-table/DataTableError.d.ts +7 -0
  23. package/dist/components/data-table/DataTableError.js +1 -0
  24. package/dist/components/data-table/DataTableGlobalFilter.js +1 -1
  25. package/dist/components/data-table/DataTableLoading.d.ts +273 -0
  26. package/dist/components/data-table/DataTableLoading.js +1 -0
  27. package/dist/components/data-table/DataTableRow.js +1 -1
  28. package/dist/components/data-table/DataTableTable.js +1 -1
  29. package/dist/components/data-table/getNewAsyncData.d.ts +3 -0
  30. package/dist/components/data-table/getNewAsyncData.js +1 -0
  31. package/dist/components/data-table/pagination/Pagination.d.ts +1 -3
  32. package/dist/components/data-table/pagination/Pagination.js +1 -1
  33. package/dist/components/data-table/pagination/PaginationButtons.d.ts +1 -0
  34. package/dist/components/data-table/pagination/PaginationButtons.js +1 -1
  35. package/dist/components/dialog/DialogContent.js +1 -1
  36. package/dist/components/dismissible/DismissibleRoot.js +1 -1
  37. package/dist/components/dismissible/DismissibleTrigger.js +1 -1
  38. package/dist/components/dropdown-menu/DropdownMenuLinkItem.js +1 -1
  39. package/dist/components/field-wrapper/FieldDescription.js +1 -1
  40. package/dist/components/field-wrapper/InlineFieldWrapper.js +1 -1
  41. package/dist/components/file-input/FileInput.js +1 -1
  42. package/dist/components/grid/Grid.js +1 -1
  43. package/dist/components/heading/Heading.js +1 -1
  44. package/dist/components/icon/Icon.js +1 -1
  45. package/dist/components/index.d.ts +11 -11
  46. package/dist/components/inline-message/InlineMessage.js +1 -1
  47. package/dist/components/label/Label.js +1 -1
  48. package/dist/components/link/Link.js +1 -1
  49. package/dist/components/loader/Loader.js +1 -1
  50. package/dist/components/markdown-content/components/MarkdownEmphasis.d.ts +266 -0
  51. package/dist/components/markdown-content/components/MarkdownEmphasis.js +1 -1
  52. package/dist/components/markdown-content/components/MarkdownHeading.d.ts +0 -2
  53. package/dist/components/markdown-content/components/MarkdownHeading.js +1 -1
  54. package/dist/components/markdown-content/components/MarkdownImage.js +1 -1
  55. package/dist/components/markdown-content/components/MarkdownInlineCode.js +1 -1
  56. package/dist/components/markdown-content/components/MarkdownLink.js +1 -1
  57. package/dist/components/markdown-content/components/MarkdownListItem.js +1 -1
  58. package/dist/components/markdown-content/components/MarkdownParagraph.d.ts +0 -2
  59. package/dist/components/markdown-content/components/MarkdownParagraph.js +1 -1
  60. package/dist/components/markdown-content/components/MarkdownStrong.js +1 -1
  61. package/dist/components/markdown-content/components/MarkdownThematicBreak.js +1 -1
  62. package/dist/components/markdown-content/components/index.d.ts +1 -1
  63. package/dist/components/navigation/NavigationMenuDropdownContent.d.ts +2 -7
  64. package/dist/components/navigation/NavigationMenuDropdownContent.js +1 -1
  65. package/dist/components/navigation/NavigationMenuDropdownTrigger.js +1 -1
  66. package/dist/components/navigation/NavigationMenuLink.js +1 -1
  67. package/dist/components/notification-badge/NotificationBadge.js +1 -1
  68. package/dist/components/number-input/NumberInput.js +1 -1
  69. package/dist/components/number-input-field/NumberInputField.js +1 -1
  70. package/dist/components/popover/PopoverContent.js +1 -1
  71. package/dist/components/radio-button/RadioButton.js +1 -1
  72. package/dist/components/radio-button-field/RadioButtonField.js +1 -1
  73. package/dist/components/radio-button-field/RadioField.js +1 -1
  74. package/dist/components/radio-card/RadioCardGroup.js +1 -1
  75. package/dist/components/search-input/SearchInput.js +1 -1
  76. package/dist/components/select-field/SelectField.js +1 -1
  77. package/dist/components/sidedrawer/SidedrawerAccordion/SidedrawerAccordionContent.js +1 -1
  78. package/dist/components/sidedrawer/SidedrawerContent.js +1 -1
  79. package/dist/components/slider-field/SliderField.js +1 -1
  80. package/dist/components/stack-content/StackContent.js +1 -1
  81. package/dist/components/stepper/StepperStepBack.js +1 -1
  82. package/dist/components/table/TableHeader.js +1 -1
  83. package/dist/components/tabs/Tabs.js +1 -1
  84. package/dist/components/tabs/utils.js +1 -1
  85. package/dist/components/text/Text.js +1 -1
  86. package/dist/components/toast/Toast.js +1 -1
  87. package/dist/components/toast/ToastProvider.js +1 -1
  88. package/dist/components/toggle-group/ToggleGroupButton.js +1 -1
  89. package/dist/components/tooltip/TooltipContent.js +1 -1
  90. package/dist/components/video/Video.js +1 -1
  91. package/dist/docgen.json +1 -1
  92. package/dist/docs/DataTable.mdx +86 -1
  93. package/dist/index.cjs.js +1 -1
  94. package/dist/index.js +1 -1
  95. package/dist/utilities/hooks/useCallbackRef.js +1 -1
  96. package/package.json +1 -1
@@ -4,5 +4,271 @@ declare type MarkdownEmphasisProps = {
4
4
  node: Emphasis;
5
5
  handleNode: (node: Content) => React.ReactElement;
6
6
  };
7
+ export declare const StyledMarkdownEmphasis: import("@stitches/react/types/styled-component").StyledComponent<"em", {}, {
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
+ warningText: any;
68
+ subjectEnglish: any;
69
+ subjectMaths: any;
70
+ subjectScience: any;
71
+ subjectVerbalReasoning: any;
72
+ subjectNonVerbalReasoning: any;
73
+ subjectCreativeWriting: any;
74
+ subjectExamSkills: any;
75
+ };
76
+ space: {
77
+ "0": any;
78
+ "1": any;
79
+ "2": any;
80
+ "3": any;
81
+ "4": any;
82
+ "5": any;
83
+ "6": any;
84
+ "7": any;
85
+ "8": any;
86
+ "9": any;
87
+ };
88
+ fontSizes: {
89
+ xs: any;
90
+ sm: any;
91
+ md: any;
92
+ lg: any;
93
+ xl: any;
94
+ "2xl": any;
95
+ "3xl": any;
96
+ "4xl": any;
97
+ };
98
+ fonts: {
99
+ sans: any;
100
+ mono: any;
101
+ display: any;
102
+ body: any;
103
+ };
104
+ sizes: {
105
+ "0": any;
106
+ "1": any;
107
+ "2": any;
108
+ "3": any;
109
+ "4": any;
110
+ "5": any;
111
+ "6": any;
112
+ "7": any;
113
+ "8": any;
114
+ };
115
+ radii: {
116
+ "0": any;
117
+ "1": any;
118
+ "2": any;
119
+ "3": any;
120
+ round: any;
121
+ };
122
+ shadows: {
123
+ "0": any;
124
+ "1": any;
125
+ "2": any;
126
+ "3": any;
127
+ };
128
+ }, import("@stitches/react/types/config").DefaultThemeMap, {
129
+ bg: (value: {
130
+ readonly [$$PropertyValue]: "background";
131
+ }) => {
132
+ background: {
133
+ readonly [$$PropertyValue]: "background";
134
+ };
135
+ };
136
+ inset: (value: string | number | {
137
+ readonly [$$ScaleValue]: "space";
138
+ }) => {
139
+ top: string | number | {
140
+ readonly [$$ScaleValue]: "space";
141
+ };
142
+ right: string | number | {
143
+ readonly [$$ScaleValue]: "space";
144
+ };
145
+ bottom: string | number | {
146
+ readonly [$$ScaleValue]: "space";
147
+ };
148
+ left: string | number | {
149
+ readonly [$$ScaleValue]: "space";
150
+ };
151
+ };
152
+ size: (value: string | number | {
153
+ readonly [$$ScaleValue]: "size";
154
+ }) => {
155
+ height: string | number | {
156
+ readonly [$$ScaleValue]: "size";
157
+ };
158
+ width: string | number | {
159
+ readonly [$$ScaleValue]: "size";
160
+ };
161
+ };
162
+ p: (value: string | number | {
163
+ readonly [$$ScaleValue]: "space";
164
+ }) => {
165
+ padding: string | number | {
166
+ readonly [$$ScaleValue]: "space";
167
+ };
168
+ };
169
+ pt: (value: string | number | {
170
+ readonly [$$ScaleValue]: "space";
171
+ }) => {
172
+ paddingTop: string | number | {
173
+ readonly [$$ScaleValue]: "space";
174
+ };
175
+ };
176
+ pr: (value: string | number | {
177
+ readonly [$$ScaleValue]: "space";
178
+ }) => {
179
+ paddingRight: string | number | {
180
+ readonly [$$ScaleValue]: "space";
181
+ };
182
+ };
183
+ pb: (value: string | number | {
184
+ readonly [$$ScaleValue]: "space";
185
+ }) => {
186
+ paddingBottom: string | number | {
187
+ readonly [$$ScaleValue]: "space";
188
+ };
189
+ };
190
+ pl: (value: string | number | {
191
+ readonly [$$ScaleValue]: "space";
192
+ }) => {
193
+ paddingLeft: string | number | {
194
+ readonly [$$ScaleValue]: "space";
195
+ };
196
+ };
197
+ px: (value: string | number | {
198
+ readonly [$$ScaleValue]: "space";
199
+ }) => {
200
+ paddingLeft: string | number | {
201
+ readonly [$$ScaleValue]: "space";
202
+ };
203
+ paddingRight: string | number | {
204
+ readonly [$$ScaleValue]: "space";
205
+ };
206
+ };
207
+ py: (value: string | number | {
208
+ readonly [$$ScaleValue]: "space";
209
+ }) => {
210
+ paddingTop: string | number | {
211
+ readonly [$$ScaleValue]: "space";
212
+ };
213
+ paddingBottom: string | number | {
214
+ readonly [$$ScaleValue]: "space";
215
+ };
216
+ };
217
+ m: (value: string | number | {
218
+ readonly [$$ScaleValue]: "space";
219
+ }) => {
220
+ margin: string | number | {
221
+ readonly [$$ScaleValue]: "space";
222
+ };
223
+ };
224
+ mt: (value: string | number | {
225
+ readonly [$$ScaleValue]: "space";
226
+ }) => {
227
+ marginTop: string | number | {
228
+ readonly [$$ScaleValue]: "space";
229
+ };
230
+ };
231
+ mr: (value: string | number | {
232
+ readonly [$$ScaleValue]: "space";
233
+ }) => {
234
+ marginRight: string | number | {
235
+ readonly [$$ScaleValue]: "space";
236
+ };
237
+ };
238
+ mb: (value: string | number | {
239
+ readonly [$$ScaleValue]: "space";
240
+ }) => {
241
+ marginBottom: string | number | {
242
+ readonly [$$ScaleValue]: "space";
243
+ };
244
+ };
245
+ ml: (value: string | number | {
246
+ readonly [$$ScaleValue]: "space";
247
+ }) => {
248
+ marginLeft: string | number | {
249
+ readonly [$$ScaleValue]: "space";
250
+ };
251
+ };
252
+ mx: (value: string | number | {
253
+ readonly [$$ScaleValue]: "space";
254
+ }) => {
255
+ marginLeft: string | number | {
256
+ readonly [$$ScaleValue]: "space";
257
+ };
258
+ marginRight: string | number | {
259
+ readonly [$$ScaleValue]: "space";
260
+ };
261
+ };
262
+ my: (value: string | number | {
263
+ readonly [$$ScaleValue]: "space";
264
+ }) => {
265
+ marginTop: string | number | {
266
+ readonly [$$ScaleValue]: "space";
267
+ };
268
+ marginBottom: string | number | {
269
+ readonly [$$ScaleValue]: "space";
270
+ };
271
+ };
272
+ }>>;
7
273
  export declare const MarkdownEmphasis: React.FC<MarkdownEmphasisProps>;
8
274
  export {};
@@ -1 +1 @@
1
- import*as t from"react";import{styled as r}from"../../../stitches.js";const l=r("em",{fontStyle:"italic"}),a=({node:e,handleNode:n})=>{var o;return t.createElement(l,null,(o=e.children)==null?void 0:o.map(n))};export{a as MarkdownEmphasis};
1
+ import*as l from"react";import{styled as n}from"../../../stitches.js";const o=n("em",{fontStyle:"italic"}),a=({node:t,handleNode:r})=>{var e;return l.createElement(o,null,(e=t.children)==null?void 0:e.map(r))};export{a as MarkdownEmphasis,o as StyledMarkdownEmphasis};
@@ -1,10 +1,8 @@
1
1
  import { Content, Heading as HeadingType } from 'mdast';
2
2
  import * as React from 'react';
3
- import { CSS } from '../../../stitches';
4
3
  declare type MarkdownHeadingProps = {
5
4
  node: HeadingType;
6
5
  handleNode: (node: Content) => React.ReactElement;
7
- css?: CSS;
8
6
  };
9
7
  export declare const MarkdownHeading: React.FC<MarkdownHeadingProps>;
10
8
  export {};
@@ -1 +1 @@
1
- import*as i from"react";import{Heading as o}from"../../heading/Heading.js";const c=s=>{switch(s){case 1:return{size:"xl",as:"h1"};case 2:return{size:"lg",as:"h2"};case 3:return{size:"md",as:"h3"};case 4:return{size:"sm",as:"h4"};case 5:return{size:"xs",as:"h5"};default:return{size:"xs",as:"h6"}}},d=({node:s,handleNode:r,css:a})=>{var e;const{as:n,size:t}=c(s.depth);return i.createElement(o,{as:n,size:t,css:{color:"inherit",...a}},(e=s.children)==null?void 0:e.map(r))};export{d as MarkdownHeading};
1
+ import*as i from"react";import{Heading as d}from"../../heading/Heading.js";const o=e=>{switch(e){case 1:return{size:"xl",as:"h1"};case 2:return{size:"lg",as:"h2"};case 3:return{size:"md",as:"h3"};case 4:return{size:"sm",as:"h4"};case 5:return{size:"xs",as:"h5"};default:return{size:"xs",as:"h6"}}},c=({node:e,handleNode:r,...a})=>{var s;const{as:t,size:n}=o(e.depth);return i.createElement(d,{as:t,size:n,...a},(s=e.children)==null?void 0:s.map(r))};export{c as MarkdownHeading};
@@ -1 +1 @@
1
- import*as e from"react";import{Image as t}from"../../image/Image.js";const m=({node:r,css:a})=>{var o;return e.createElement(t,{src:r.url,alt:(o=r.alt)!=null?o:void 0,css:a})};export{m as MarkdownImage};
1
+ import*as e from"react";import{Image as o}from"../../image/Image.js";const m=({node:r,css:a})=>{var t;return e.createElement(o,{src:r.url,alt:(t=r.alt)!=null?t:void 0,css:a})};export{m as MarkdownImage};
@@ -1 +1 @@
1
- import*as e from"react";import{styled as n}from"../../../stitches.js";import{Box as r}from"../../box/Box.js";const t=n(r,{bg:"$tonal100",borderRadius:"$0",color:"$tonal600",display:"inline-block",fontFamily:"$mono",fontSize:"85%",p:"$0 $1"}),l=({node:o})=>e.createElement(t,{as:"code"},o.value);export{l as MarkdownInlineCode};
1
+ import*as e from"react";import{styled as n}from"../../../stitches.js";import{Box as t}from"../../box/Box.js";const r=n(t,{bg:"$tonal100",borderRadius:"$0",color:"$tonal600",display:"inline-block",fontFamily:"$mono",fontSize:"85%",p:"$0 $1"}),l=({node:o})=>e.createElement(r,{as:"code"},o.value);export{l as MarkdownInlineCode};
@@ -1 +1 @@
1
- import*as l from"react";import{Link as i}from"../../link/Link.js";const n=({node:e,handleNode:t})=>{var r,o;return l.createElement(i,{title:(r=e.title)!=null?r:void 0,href:e.url},(o=e.children)==null?void 0:o.map(t))};export{n as MarkdownLink};
1
+ import*as l from"react";import{Link as i}from"../../link/Link.js";const n=({node:e,handleNode:o})=>{var r,t;return l.createElement(i,{title:(r=e.title)!=null?r:void 0,href:e.url},(t=e.children)==null?void 0:t.map(o))};export{n as MarkdownLink};
@@ -1 +1 @@
1
- import*as r from"react";import{List as n}from"../../list/List.js";const m=({node:t,handleNode:o})=>{var e;return r.createElement(n.Item,null,(e=t.children)==null?void 0:e.map(o))};export{m as MarkdownListItem};
1
+ import*as o from"react";import{List as n}from"../../list/List.js";const m=({node:e,handleNode:r})=>{var t;return o.createElement(n.Item,null,(t=e.children)==null?void 0:t.map(r))};export{m as MarkdownListItem};
@@ -1,10 +1,8 @@
1
1
  import { Content, Paragraph } from 'mdast';
2
2
  import * as React from 'react';
3
- import { CSS } from '../../../stitches';
4
3
  declare type MarkdownParagraphProps = {
5
4
  node: Paragraph;
6
5
  handleNode: (node: Content) => React.ReactElement;
7
- css?: CSS;
8
6
  };
9
7
  export declare const MarkdownParagraph: React.FC<MarkdownParagraphProps>;
10
8
  export {};
@@ -1 +1 @@
1
- import*as n from"react";import{Text as t}from"../../text/Text.js";const c=({node:o,handleNode:e,css:a})=>{var r;return n.createElement(t,{css:{color:"inherit",...a}},(r=o.children)==null?void 0:r.map(e))};export{c as MarkdownParagraph};
1
+ import*as t from"react";import{Text as n}from"../../text/Text.js";const d=({node:e,handleNode:a,...o})=>{var r;return t.createElement(n,{...o},(r=e.children)==null?void 0:r.map(a))};export{d as MarkdownParagraph};
@@ -1 +1 @@
1
- import*as t from"react";import{styled as e}from"../../../stitches.js";const d=e("strong",{fontWeight:600}),l=({node:n,handleNode:r})=>{var o;return t.createElement(d,null,(o=n.children)==null?void 0:o.map(r))};export{l as MarkdownStrong};
1
+ import*as r from"react";import{styled as e}from"../../../stitches.js";const d=e("strong",{fontWeight:600}),l=({node:t,handleNode:n})=>{var o;return r.createElement(d,null,(o=t.children)==null?void 0:o.map(n))};export{l as MarkdownStrong};
@@ -1 +1 @@
1
- import*as e from"react";import{Divider as o}from"../../divider/Divider.js";const t=({css:r})=>e.createElement(o,{css:{width:"100%",...r}});export{t as MarkdownThematicBreak};
1
+ import*as t from"react";import{Divider as e}from"../../divider/Divider.js";const o=({css:r})=>t.createElement(e,{css:{width:"100%",...r}});export{o as MarkdownThematicBreak};
@@ -1,5 +1,5 @@
1
1
  export { MarkdownCode } from './MarkdownCode';
2
- export { MarkdownEmphasis } from './MarkdownEmphasis';
2
+ export { MarkdownEmphasis, StyledMarkdownEmphasis } from './MarkdownEmphasis';
3
3
  export { MarkdownHeading } from './MarkdownHeading';
4
4
  export { MarkdownInlineCode } from './MarkdownInlineCode';
5
5
  export { MarkdownImage } from './MarkdownImage';
@@ -1,7 +1,2 @@
1
- /// <reference types="react" />
2
- export declare const NavigationMenuDropdownContent: {
3
- ({ children }: {
4
- children: any;
5
- }): JSX.Element;
6
- displayName: string;
7
- };
1
+ import React from 'react';
2
+ export declare const NavigationMenuDropdownContent: React.FC;
@@ -1 +1 @@
1
- import*as p from"@radix-ui/react-navigation-menu";import t from"react";import{styled as o}from"../../stitches.js";const r=o("ul",{listStyle:"none"}),a=o(p.Content,{p:"$3",bg:"white",mt:"4px",boxShadow:"0px 3px 6px rgba(51, 51, 51, 0.15), 0px 3px 6px rgba(51, 51, 51, 0.2)",borderRadius:"$1"}),e=({children:n})=>t.createElement(a,null,t.createElement(r,null,n));e.displayName="NavigationMenuDropdownContent";export{e as NavigationMenuDropdownContent};
1
+ import*as r from"@radix-ui/react-navigation-menu";import t from"react";import{styled as e}from"../../stitches.js";const i=e("ul",{listStyle:"none",m:0,p:0}),l=e(r.Content,{p:"$3",bg:"white",mt:"4px",boxShadow:"$1",borderRadius:"$1"}),o=({children:n})=>t.createElement(l,null,t.createElement(i,null,n));o.displayName="NavigationMenuDropdownContent";export{o as NavigationMenuDropdownContent};
@@ -1 +1 @@
1
- import{ChevronDown as i}from"@atom-learning/icons";import*as s from"@radix-ui/react-navigation-menu";import e from"react";import{styled as m}from"../../stitches.js";import{Icon as p}from"../icon/Icon.js";import{navigationMenuBaseItemStyles as d,navigationMenuActiveItemStyles as c}from"./NavigationMenu.styles.js";const f=m(s.Trigger,d,{display:"flex",alignItems:"center",borderRadius:"$1",justifyContent:"space-between",gap:"$1",'&[data-state="open"]':{background:"$tonal100"},variants:{active:{true:{...c}}}}),t=e.forwardRef(({children:r,active:o,...a},n)=>e.createElement(f,{active:o,...a,ref:n},r,e.createElement(p,{is:i,css:{"[data-state=open] &":{transform:"rotate(-180deg)"},"@media (prefers-reduced-motion: no-preference)":{transition:"transform .2s ease"}},size:"sm"})));t.displayName="NavigationMenuDropdownTrigger";export{t as NavigationMenuDropdownTrigger};
1
+ import{ChevronDown as i}from"@atom-learning/icons";import*as s from"@radix-ui/react-navigation-menu";import e from"react";import{styled as m}from"../../stitches.js";import{Icon as d}from"../icon/Icon.js";import{navigationMenuBaseItemStyles as p,navigationMenuActiveItemStyles as c}from"./NavigationMenu.styles.js";const f=m(s.Trigger,p,{display:"flex",alignItems:"center",borderRadius:"$1",justifyContent:"space-between",'&[data-state="open"]':{background:"$tonal100"},variants:{active:{true:{...c}}}}),t=e.forwardRef(({children:r,active:o,...a},n)=>e.createElement(f,{active:o,...a,ref:n},r,e.createElement(d,{is:i,css:{ml:"$1","[data-state=open] &":{transform:"rotate(-180deg)"},"@media (prefers-reduced-motion: no-preference)":{transition:"transform .2s ease"}},size:"sm"})));t.displayName="NavigationMenuDropdownTrigger";export{t as NavigationMenuDropdownTrigger};
@@ -1 +1 @@
1
- import*as o from"@radix-ui/react-navigation-menu";import e from"react";import{styled as t}from"../../stitches.js";import{navigationMenuBaseItemStyles as n,navigationMenuDisabledItemStyles as p,navigationMenuActiveItemStyles as v}from"./NavigationMenu.styles.js";const u=t("button",{...n,...p}),y=t(o.Item),f=t(o.Link,n,{display:"block",textDecoration:"none",lineHeight:1,variants:{elementType:{dropdownItem:{"&[data-active]":{background:"$primaryLight",color:"$primary","*":{color:"$primary"},"&:hover":{background:"$tonal50"},"&:active":{background:"$tonal100"},"&:focus-visible":{boxShadow:"0 0 0 2px $colors$primary"}}},link:{"&[data-active]":{...v}}}}}),r=e.forwardRef(({children:a,href:l,disabled:m,css:s,variant:c="link",...i},d)=>m?e.createElement(u,{disabled:!0,...i},a):e.createElement(y,null,e.createElement(f,{href:l,ref:d,elementType:c,css:s,...i},a)));r.displayName="NavigationMenuLink";export{r as NavigationMenuLink};
1
+ import*as n from"@radix-ui/react-navigation-menu";import e from"react";import{styled as t}from"../../stitches.js";import{navigationMenuBaseItemStyles as o,navigationMenuDisabledItemStyles as p,navigationMenuActiveItemStyles as v}from"./NavigationMenu.styles.js";const u=t("button",{...o,...p}),y=t(n.Item),f=t(n.Link,o,{display:"block",textDecoration:"none",lineHeight:1,variants:{elementType:{dropdownItem:{"&[data-active]":{background:"$primaryLight",color:"$primary","*":{color:"$primary"},"&:hover":{background:"$tonal50"},"&:active":{background:"$tonal100"},"&:focus-visible":{boxShadow:"0 0 0 2px $colors$primary"}}},link:{"&[data-active]":{...v}}}}}),r=e.forwardRef(({children:a,href:l,disabled:m,css:s,variant:c="link",...i},d)=>e.createElement(y,null,m?e.createElement(u,{disabled:!0,...i},a):e.createElement(f,{href:l,ref:d,elementType:c,css:s,...i},a)));r.displayName="NavigationMenuLink";export{r as NavigationMenuLink};
@@ -1 +1 @@
1
- import o from"react";import{styled as e}from"../../stitches.js";import{Box as i}from"../box/Box.js";import{Flex as n}from"../flex/Flex.js";const l=e(i,{position:"relative"}),a=e(n,{fontFamily:"$body",fontSize:"$sm",flexDirection:"column",justifyContent:"center",position:"absolute",top:"0",right:"0",transform:"translate(calc($sizes$2 / 2), -50%)",borderRadius:"$round",p:"$2",height:"$2",minWidth:"$2",textAlign:"center",color:"#fff",bg:"$primary"}),m=({value:t,children:r})=>o.createElement(l,null,!!t&&o.createElement(a,{role:"status"},t),r);export{m as NotificationBadge};
1
+ import e from"react";import{styled as o}from"../../stitches.js";import{Box as i}from"../box/Box.js";import{Flex as n}from"../flex/Flex.js";const l=o(i,{position:"relative"}),a=o(n,{fontFamily:"$body",fontSize:"$sm",flexDirection:"column",justifyContent:"center",position:"absolute",top:"0",right:"0",transform:"translate(calc($sizes$2 / 2), -50%)",borderRadius:"$round",p:"$2",height:"$2",minWidth:"$2",textAlign:"center",color:"#fff",bg:"$primary"}),m=({value:t,children:r})=>e.createElement(l,null,!!t&&e.createElement(a,{role:"status"},t),r);export{m as NotificationBadge};
@@ -1 +1 @@
1
- import{Minus as $,Plus as B}from"@atom-learning/icons";import*as n from"react";import{Flex as F}from"../flex/Flex.js";import{Input as H}from"../input/Input.js";import{NumberInputStepper as x}from"./NumberInputStepper.js";const N=n.forwardRef((g,k)=>{const{name:E,min:o=0,max:l=Number.MAX_SAFE_INTEGER,step:s=1,initialValue:y=0,disabled:u=!1,readonly:m=!1,size:v="md",onChange:C,stepperButtonLabels:T,disabledTooltipContent:A,css:I,...L}=g,[r,M]=n.useState(y),i=n.useRef(null);n.useImperativeHandle(k,()=>i.current);const w={increment:"increment",decrement:"decrement",...T},R={decrement:`Cannot enter values below ${o}`,increment:`Cannot enter values above ${l}`,...A},d=r>=l,c=r<=o,p=n.useCallback(e=>Math.min(Math.max(e,o),l),[l,o]),a=n.useCallback(e=>{M(e),C==null||C(Number(e))},[C]),z=n.useCallback(e=>{const t=e.target.value.replace(/\D/g,"");a(t)},[a]),b=n.useCallback(()=>{var e;if(d||m)return;(e=i==null?void 0:i.current)==null||e.focus();let t;r===""?t=s:t=Number(r)+s,a(p(t))},[p,d,m,s,a,r]),f=n.useCallback(()=>{var e;if(c||m)return;(e=i==null?void 0:i.current)==null||e.focus();let t;r===""?t=o:t=Number(r)-s,a(p(t))},[p,c,m,o,s,a,r]),D=n.useCallback(e=>{if(e.nativeEvent.isComposing)return;const t=e.key,h={ArrowUp:b,ArrowRight:b,ArrowDown:f,ArrowLeft:f,Home:()=>a(o),End:()=>a(l)}[t];h&&(e.preventDefault(),h(e))},[b,f,a,o,l]),S={name:E,type:"number",value:r,...L,onChange:z,onKeyDown:D,size:v,css:{borderRadius:"0px",width:"$6","&:disabled":{opacity:.3,pointerEvents:"none"}},ref:i,readOnly:m,disabled:u,"aria-valuemin":o,"aria-valuemax":l,"aria-valuenow":Number(r),role:"spinbutton"};return n.createElement(F,{css:I},n.createElement(x,{onClick:f,icon:$,css:{borderRight:"none",borderTopRightRadius:"0px",borderBottomRightRadius:"0px"},size:v,disabled:c||u,showTooltip:c&&!u,disabledTooltipContent:R.decrement,label:w.decrement}),n.createElement(H,{...S}),n.createElement(x,{onClick:b,icon:B,css:{borderLeft:"none",borderTopLeftRadius:"0px",borderBottomLeftRadius:"0px"},size:v,disabled:d||u,showTooltip:d&&!u,disabledTooltipContent:R.increment,label:w.increment}))});N.displayName="NumberInput";export{N as NumberInput};
1
+ import{Minus as B,Plus as $}from"@atom-learning/icons";import*as t from"react";import{Flex as F}from"../flex/Flex.js";import{Input as H}from"../input/Input.js";import{NumberInputStepper as x}from"./NumberInputStepper.js";const N=t.forwardRef((g,k)=>{const{name:E,min:o=0,max:l=Number.MAX_SAFE_INTEGER,step:s=1,initialValue:y=0,disabled:u=!1,readonly:m=!1,size:v="md",onChange:C,stepperButtonLabels:T,disabledTooltipContent:A,css:I,...L}=g,[r,M]=t.useState(y),i=t.useRef(null);t.useImperativeHandle(k,()=>i.current);const w={increment:"increment",decrement:"decrement",...T},R={decrement:`Cannot enter values below ${o}`,increment:`Cannot enter values above ${l}`,...A},d=r>=l,c=r<=o,p=t.useCallback(e=>Math.min(Math.max(e,o),l),[l,o]),a=t.useCallback(e=>{M(e),C==null||C(Number(e))},[C]),z=t.useCallback(e=>{const n=e.target.value.replace(/\D/g,"");a(n)},[a]),b=t.useCallback(()=>{var e;if(d||m)return;(e=i==null?void 0:i.current)==null||e.focus();let n;r===""?n=s:n=Number(r)+s,a(p(n))},[p,d,m,s,a,r]),f=t.useCallback(()=>{var e;if(c||m)return;(e=i==null?void 0:i.current)==null||e.focus();let n;r===""?n=o:n=Number(r)-s,a(p(n))},[p,c,m,o,s,a,r]),D=t.useCallback(e=>{if(e.nativeEvent.isComposing)return;const n=e.key,h={ArrowUp:b,ArrowRight:b,ArrowDown:f,ArrowLeft:f,Home:()=>a(o),End:()=>a(l)}[n];h&&(e.preventDefault(),h(e))},[b,f,a,o,l]),S={name:E,type:"number",value:r,...L,onChange:z,onKeyDown:D,size:v,css:{borderRadius:"0px",width:"$6","&:disabled":{opacity:.3,pointerEvents:"none"}},ref:i,readOnly:m,disabled:u,"aria-valuemin":o,"aria-valuemax":l,"aria-valuenow":Number(r),role:"spinbutton"};return t.createElement(F,{css:I},t.createElement(x,{onClick:f,icon:B,css:{borderRight:"none",borderTopRightRadius:"0px",borderBottomRightRadius:"0px"},size:v,disabled:c||u,showTooltip:c&&!u,disabledTooltipContent:R.decrement,label:w.decrement}),t.createElement(H,{...S}),t.createElement(x,{onClick:b,icon:$,css:{borderLeft:"none",borderTopLeftRadius:"0px",borderBottomLeftRadius:"0px"},size:v,disabled:d||u,showTooltip:d&&!u,disabledTooltipContent:R.increment,label:w.increment}))});N.displayName="NumberInput";export{N as NumberInput};
@@ -1 +1 @@
1
- import*as i from"react";import{useFormContext as c}from"react-hook-form";import{FieldWrapper as f}from"../field-wrapper/FieldWrapper.js";import"../field-wrapper/InlineFieldWrapper.js";import"../form/Form.js";import{useFieldError as b}from"../form/useFieldError.js";import{NumberInput as F}from"../number-input/NumberInput.js";const m=({css:p,label:n,name:r,validation:e,prompt:a,description:l,...d})=>{const{register:o,trigger:s}=c(),{error:t}=b(r),u=e?o(e):o;return i.createElement(f,{css:p,description:l,error:t,fieldId:r,label:n,prompt:a,required:Boolean(e==null?void 0:e.required)},i.createElement(F,{id:r,name:r,ref:u,...t&&{state:"error","aria-invalid":!0},...d,onChange:s}))};m.displayName="NumberInputField";export{m as NumberInputField};
1
+ import*as i from"react";import{useFormContext as c}from"react-hook-form";import{FieldWrapper as f}from"../field-wrapper/FieldWrapper.js";import"../field-wrapper/InlineFieldWrapper.js";import"../form/Form.js";import{useFieldError as b}from"../form/useFieldError.js";import{NumberInput as F}from"../number-input/NumberInput.js";const m=({css:p,label:n,name:r,validation:e,prompt:a,description:l,...d})=>{const{register:t,trigger:s}=c(),{error:o}=b(r),u=e?t(e):t;return i.createElement(f,{css:p,description:l,error:o,fieldId:r,label:n,prompt:a,required:Boolean(e==null?void 0:e.required)},i.createElement(F,{id:r,name:r,ref:u,...o&&{state:"error","aria-invalid":!0},...d,onChange:s}))};m.displayName="NumberInputField";export{m as NumberInputField};
@@ -1 +1 @@
1
- import{Close as r}from"@atom-learning/icons";import{Content as l,Arrow as p,Close as h}from"@radix-ui/react-popover";import*as e from"react";import{POPOVER_Z_INDEX as c}from"../../constants/zIndices.js";import{styled as t}from"../../stitches.js";import{ActionIcon as f}from"../action-icon/ActionIcon.js";import{Icon as $}from"../icon/Icon.js";import{slideDownAndFade as x,slideLeftAndFade as g,slideUpAndFade as w,slideRightAndFade as z}from"../../utilities/style/keyframe-animations.js";const b=t(l,{bg:"white",borderRadius:"$1",boxShadow:"$2",maxWidth:"90vw",p:"$sizes$2",pr:"$6",position:"relative",zIndex:c,"@allowMotion":{animationDuration:"75ms",animationTimingFunction:"cubic-bezier(0.16, 1, 0.3, 1)",willChange:"transform, opacity",'&[data-state="open"]':{'&[data-side="top"]':{animationName:x},'&[data-side="right"]':{animationName:g},'&[data-side="bottom"]':{animationName:w},'&[data-side="left"]':{animationName:z}}},variants:{size:{sm:{maxWidth:"200px"},md:{maxWidth:"400px"},lg:{maxWidth:"600px"}}}}),C=t(p,{fill:"white",zIndex:1,'[data-align="end"] &':{mr:"$sizes$2"},'[data-align="start"] &':{ml:"$sizes$2"}}),u=({children:i,side:o="top",sideOffset:a=8,closePopoverText:s="Close popover",showCloseButton:n=!0,size:m="md",...d})=>e.createElement(b,{size:m,side:o,sideOffset:a,...d},n&&e.createElement(f,{as:h,css:{position:"absolute",right:"$0",top:"$0"},label:s,size:"md",theme:"neutral"},e.createElement($,{is:r})),i,e.createElement(C,{width:16,height:8}));export{u as PopoverContent};
1
+ import{Close as r}from"@atom-learning/icons";import{Content as l,Arrow as p,Close as h}from"@radix-ui/react-popover";import*as e from"react";import{POPOVER_Z_INDEX as c}from"../../constants/zIndices.js";import{styled as t}from"../../stitches.js";import{ActionIcon as f}from"../action-icon/ActionIcon.js";import{Icon as x}from"../icon/Icon.js";import{slideDownAndFade as $,slideLeftAndFade as g,slideUpAndFade as w,slideRightAndFade as z}from"../../utilities/style/keyframe-animations.js";const b=t(l,{bg:"white",borderRadius:"$1",boxShadow:"$2",maxWidth:"90vw",p:"$sizes$2",pr:"$6",position:"relative",zIndex:c,"@allowMotion":{animationDuration:"75ms",animationTimingFunction:"cubic-bezier(0.16, 1, 0.3, 1)",willChange:"transform, opacity",'&[data-state="open"]':{'&[data-side="top"]':{animationName:$},'&[data-side="right"]':{animationName:g},'&[data-side="bottom"]':{animationName:w},'&[data-side="left"]':{animationName:z}}},variants:{size:{sm:{maxWidth:"200px"},md:{maxWidth:"400px"},lg:{maxWidth:"600px"}}}}),C=t(p,{fill:"white",zIndex:1,'[data-align="end"] &':{mr:"$sizes$2"},'[data-align="start"] &':{ml:"$sizes$2"}}),u=({children:i,side:o="top",sideOffset:a=8,closePopoverText:s="Close popover",showCloseButton:n=!0,size:m="md",...d})=>e.createElement(b,{size:m,side:o,sideOffset:a,...d},n&&e.createElement(f,{as:h,css:{position:"absolute",right:"$0",top:"$0"},label:s,size:"md",theme:"neutral"},e.createElement(x,{is:r})),i,e.createElement(C,{width:16,height:8}));export{u as PopoverContent};
@@ -1 +1 @@
1
- import*as o from"@radix-ui/react-radio-group";import*as r from"react";import{styled as e}from"../../stitches.js";const n=e(o.Item,{alignItems:"center",appearance:"none",backgroundColor:"transparent",border:"1px solid $tonal400",borderRadius:"$round",color:"white",cursor:"pointer",display:"flex",justifyContent:"center",p:0,size:"$1",transition:"all 50ms ease-out","&:focus":{outline:"2px solid $primary",outlineOffset:"1px"},'&[data-state="checked"]':{backgroundColor:"$primary",borderColor:"$primary"},"&[disabled]":{backgroundColor:"$tonal100",borderColor:"$tonal400",color:"$tonal400",cursor:"not-allowed"}}),l=e(o.Indicator,{size:"6px",borderRadius:"$round",backgroundColor:"currentcolor",position:"absolute"}),t=a=>r.createElement(n,{...a},r.createElement(l,null));t.displayName="RadioButton";export{t as RadioButton};
1
+ import*as o from"@radix-ui/react-radio-group";import*as r from"react";import{styled as t}from"../../stitches.js";const n=t(o.Item,{alignItems:"center",appearance:"none",backgroundColor:"transparent",border:"1px solid $tonal400",borderRadius:"$round",color:"white",cursor:"pointer",display:"flex",justifyContent:"center",p:0,size:"$1",transition:"all 50ms ease-out","&:focus":{outline:"2px solid $primary",outlineOffset:"1px"},'&[data-state="checked"]':{backgroundColor:"$primary",borderColor:"$primary"},"&[disabled]":{backgroundColor:"$tonal100",borderColor:"$tonal400",color:"$tonal400",cursor:"not-allowed"}}),l=t(o.Indicator,{size:"6px",borderRadius:"$round",backgroundColor:"currentcolor",position:"absolute"}),e=a=>r.createElement(n,{...a},r.createElement(l,null));e.displayName="RadioButton";export{e as RadioButton};
@@ -1 +1 @@
1
- import*as e from"react";import{useFormContext as F,Controller as g}from"react-hook-form";import{Description as C}from"../field-wrapper/FieldDescription.js";import"../form/Form.js";import{useFieldError as V}from"../form/useFieldError.js";import{Label as b}from"../label/Label.js";import"../radio-button/RadioButton.js";import{RadioButtonGroup as h}from"../radio-button/RadioButtonGroup.js";import{InlineMessage as v}from"../inline-message/InlineMessage.js";import{styled as B}from"../../stitches.js";import{RadioField as R}from"./RadioField.js";const $=B("fieldset",{all:"unset"}),r=({children:s,css:d,direction:u="column",defaultValue:t,description:l,label:c,name:n,validation:o,onValueChange:a})=>{const{control:p}=F(),{error:m}=V(n);return e.createElement($,{css:d},e.createElement(b,{as:"legend",css:{p:0,mb:"$3"},required:Boolean(o==null?void 0:o.required)},c),l&&e.createElement(C,{css:{mb:"$3"}},l),e.createElement(g,{control:p,name:n,rules:o,defaultValue:t,render:({onChange:f,value:E})=>e.createElement(h,{direction:u,defaultValue:t,onValueChange:i=>{f(i),a==null||a(i)},value:E},s)}),m&&e.createElement(v,{css:{mt:"$2"}},m))};r.Item=R,r.displayName="RadioButtonField";export{r as RadioButtonField};
1
+ import*as e from"react";import{useFormContext as F,Controller as g}from"react-hook-form";import{Description as C}from"../field-wrapper/FieldDescription.js";import"../form/Form.js";import{useFieldError as V}from"../form/useFieldError.js";import{Label as b}from"../label/Label.js";import"../radio-button/RadioButton.js";import{RadioButtonGroup as h}from"../radio-button/RadioButtonGroup.js";import{InlineMessage as v}from"../inline-message/InlineMessage.js";import{styled as B}from"../../stitches.js";import{RadioField as R}from"./RadioField.js";const q=B("fieldset",{all:"unset"}),t=({children:s,css:d,direction:u="column",defaultValue:r,description:l,label:c,name:n,validation:o,onValueChange:a})=>{const{control:p}=F(),{error:m}=V(n);return e.createElement(q,{css:d},e.createElement(b,{as:"legend",css:{p:0,mb:"$3"},required:Boolean(o==null?void 0:o.required)},c),l&&e.createElement(C,{css:{mb:"$3"}},l),e.createElement(g,{control:p,name:n,rules:o,defaultValue:r,render:({onChange:f,value:E})=>e.createElement(h,{direction:u,defaultValue:r,onValueChange:i=>{f(i),a==null||a(i)},value:E},s)}),m&&e.createElement(v,{css:{mt:"$2"}},m))};t.Item=R,t.displayName="RadioButtonField";export{t as RadioButtonField};
@@ -1 +1 @@
1
- import*as e from"react";import"../field-wrapper/FieldWrapper.js";import{InlineFieldWrapper as t}from"../field-wrapper/InlineFieldWrapper.js";import{RadioButton as m}from"../radio-button/RadioButton.js";import"../radio-button/RadioButtonGroup.js";const o=({css:a,label:i,value:l,...r})=>e.createElement(t,{css:a,label:i},e.createElement(m,{value:l,...r}));o.displayName="RadioField";export{o as RadioField};
1
+ import*as e from"react";import"../field-wrapper/FieldWrapper.js";import{InlineFieldWrapper as r}from"../field-wrapper/InlineFieldWrapper.js";import{RadioButton as m}from"../radio-button/RadioButton.js";import"../radio-button/RadioButtonGroup.js";const o=({css:t,label:a,value:i,...l})=>e.createElement(r,{css:t,label:a},e.createElement(m,{value:i,...l}));o.displayName="RadioField";export{o as RadioField};
@@ -1 +1 @@
1
- import*as d from"@radix-ui/react-radio-group";import*as e from"react";import{Stack as p}from"../stack/Stack.js";import{RadioCard as c}from"./RadioCard.js";const f=({css:t,children:r,size:o,isFullWidth:l,align:a,gap:s="3",justify:m,...n})=>e.createElement(d.Root,{...n},e.createElement(p,{direction:"row",justify:m,gap:s,css:t},e.Children.map(r,i=>e.isValidElement(i)&&(i==null?void 0:i.type)===c?e.cloneElement(i,{size:o,isFullWidth:l,align:a}):i)));export{f as RadioCardGroup};
1
+ import*as d from"@radix-ui/react-radio-group";import*as t from"react";import{Stack as p}from"../stack/Stack.js";import{RadioCard as c}from"./RadioCard.js";const f=({css:e,children:r,size:l,isFullWidth:o,align:a,gap:s="3",justify:m,...n})=>t.createElement(d.Root,{...n},t.createElement(p,{direction:"row",justify:m,gap:s,css:e},t.Children.map(r,i=>t.isValidElement(i)&&(i==null?void 0:i.type)===c?t.cloneElement(i,{size:l,isFullWidth:o,align:a}):i)));export{f as RadioCardGroup};
@@ -1 +1 @@
1
- import{Search as z,Close as y}from"@atom-learning/icons";import*as t from"react";import{ActionIcon as H}from"../action-icon/ActionIcon.js";import{Box as I}from"../box/Box.js";import{Icon as l}from"../icon/Icon.js";import{Input as k}from"../input/Input.js";import{styled as p}from"../../stitches.js";import{useCallbackRef as L}from"../../utilities/hooks/useCallbackRef.js";var $=(e=>(e.SEARCH="SEARCH",e.CLEAR="CLEAR",e))($||{});const x=p(l,{color:"$tonal300",position:"absolute",pointerEvents:"none",variants:{size:{sm:{top:"$2",right:"$2",size:"$1"},md:{top:10,right:10,size:20}}}}),O=p(k,{'&::-webkit-search-decoration, &::-webkit-search-cancel-button, &::-webkit-search-results-button, & input[type="search"]::-webkit-search-results-decoration':{display:"none"}}),u=t.forwardRef(({size:e="md",css:m,value:n,clearText:E="Clear",onChange:a,...h},b)=>{const[i,f]=L(),[v,C]=t.useState(n||""),[d,R]=t.useState(n?"CLEAR":"SEARCH");t.useImperativeHandle(b,()=>i.current);const A=()=>{var r,c;const o=i.current;if(!o)return;const s=(r=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"value"))==null?void 0:r.set;(c=s==null?void 0:s.call)==null||c.call(s,o,"");const w=new Event("input",{bubbles:!0});o.dispatchEvent(w),o.focus()},S=r=>{C(r.target.value),R(r.target.value?"CLEAR":"SEARCH"),a==null||a(r)},g=()=>d==="SEARCH"?t.createElement(x,{is:z,size:e,css:{size:e=="sm"?"$1":20}}):t.createElement(H,{label:E,theme:"neutral",size:e,css:{position:"absolute",top:"0",right:"$1"},onClick:A},t.createElement(l,{is:y}));return t.createElement(I,{css:{position:"relative",...m}},t.createElement(O,{ref:f,size:e,type:"search",...h,value:v,onChange:S,css:{pr:e==="sm"?"$5":"$6"}}),g())});u.displayName="SearchInput";export{u as SearchInput};
1
+ import{Search as $,Close as z}from"@atom-learning/icons";import*as t from"react";import{ActionIcon as y}from"../action-icon/ActionIcon.js";import{Box as H}from"../box/Box.js";import{Icon as l}from"../icon/Icon.js";import{Input as I}from"../input/Input.js";import{styled as p}from"../../stitches.js";import{useCallbackRef as k}from"../../utilities/hooks/useCallbackRef.js";var L=(e=>(e.SEARCH="SEARCH",e.CLEAR="CLEAR",e))(L||{});const x=p(l,{color:"$tonal300",position:"absolute",pointerEvents:"none",variants:{size:{sm:{top:"$2",right:"$2",size:"$1"},md:{top:10,right:10,size:20}}}}),O=p(I,{'&::-webkit-search-decoration, &::-webkit-search-cancel-button, &::-webkit-search-results-button, & input[type="search"]::-webkit-search-results-decoration':{display:"none"}}),u=t.forwardRef(({size:e="md",css:m,value:n,clearText:E="Clear",onChange:a,...h},b)=>{const[i,f]=k(),[v,C]=t.useState(n||""),[d,R]=t.useState(n?"CLEAR":"SEARCH");t.useImperativeHandle(b,()=>i.current);const A=()=>{var r,c;const o=i.current;if(!o)return;const s=(r=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"value"))==null?void 0:r.set;(c=s==null?void 0:s.call)==null||c.call(s,o,"");const w=new Event("input",{bubbles:!0});o.dispatchEvent(w),o.focus()},S=r=>{C(r.target.value),R(r.target.value?"CLEAR":"SEARCH"),a==null||a(r)},g=()=>d==="SEARCH"?t.createElement(x,{is:$,size:e,css:{size:e=="sm"?"$1":20}}):t.createElement(y,{label:E,theme:"neutral",size:e,css:{position:"absolute",top:"0",right:"$1"},onClick:A},t.createElement(l,{is:z}));return t.createElement(H,{css:{position:"relative",...m}},t.createElement(O,{ref:f,size:e,type:"search",...h,value:v,onChange:S,css:{pr:e==="sm"?"$5":"$6"}}),g())});u.displayName="SearchInput";export{u as SearchInput};
@@ -1 +1 @@
1
- import*as t from"react";import{useFormContext as u}from"react-hook-form";import{FieldWrapper as F}from"../field-wrapper/FieldWrapper.js";import"../field-wrapper/InlineFieldWrapper.js";import"../form/Form.js";import{useFieldError as b}from"../form/useFieldError.js";import{Select as h}from"../select/Select.js";const l=({css:m=void 0,children:d,name:e,label:p,validation:r,prompt:a,description:n,hideLabel:s,...c})=>{const{register:o}=u(),{error:i}=b(e),f=r?o(r):o;return t.createElement(F,{css:m,description:n,error:i,fieldId:e,label:p,prompt:a,required:Boolean(r==null?void 0:r.required),hideLabel:s},t.createElement(h,{name:e,id:e,...c,ref:f,...i&&{state:"error"}},d))};l.displayName="SelectField";export{l as SelectField};
1
+ import*as i from"react";import{useFormContext as u}from"react-hook-form";import{FieldWrapper as F}from"../field-wrapper/FieldWrapper.js";import"../field-wrapper/InlineFieldWrapper.js";import"../form/Form.js";import{useFieldError as b}from"../form/useFieldError.js";import{Select as h}from"../select/Select.js";const l=({css:m=void 0,children:d,name:e,label:p,validation:r,prompt:a,description:n,hideLabel:s,...c})=>{const{register:o}=u(),{error:t}=b(e),f=r?o(r):o;return i.createElement(F,{css:m,description:n,error:t,fieldId:e,label:p,prompt:a,required:Boolean(r==null?void 0:r.required),hideLabel:s},i.createElement(h,{name:e,id:e,...c,ref:f,...t&&{state:"error"}},d))};l.displayName="SelectField";export{l as SelectField};
@@ -1 +1 @@
1
- import t from"react";import{Content as i}from"@radix-ui/react-accordion";import{Box as n}from"../../box/Box.js";import{keyframes as o,styled as m}from"../../../stitches.js";const c=o({from:{height:0},to:{height:"var(--radix-accordion-content-height)"}}),d=o({from:{height:"var(--radix-accordion-content-height)"},to:{height:0}}),h=m(i,{bg:"white",overflow:"hidden","@allowMotion":{'&[data-state="open"]':{animation:`${c} 300ms ease-out`},'&[data-state="closed"]':{animation:`${d} 300ms ease-out`}}}),s=({children:e,...a})=>t.createElement(h,{...a},t.Children.map(e,r=>t.createElement(n,{css:{"> a":{px:"$6"},"> button":{px:"$6"}}},r)));export{s as SidedrawerAccordionContent};
1
+ import t from"react";import{Content as i}from"@radix-ui/react-accordion";import{Box as n}from"../../box/Box.js";import{keyframes as e,styled as m}from"../../../stitches.js";const c=e({from:{height:0},to:{height:"var(--radix-accordion-content-height)"}}),d=e({from:{height:"var(--radix-accordion-content-height)"},to:{height:0}}),h=m(i,{bg:"white",overflow:"hidden","@allowMotion":{'&[data-state="open"]':{animation:`${c} 300ms ease-out`},'&[data-state="closed"]':{animation:`${d} 300ms ease-out`}}}),s=({children:o,...a})=>t.createElement(h,{...a},t.Children.map(o,r=>t.createElement(n,{css:{"> a":{px:"$6"},"> button":{px:"$6"}}},r)));export{s as SidedrawerAccordionContent};
@@ -1 +1 @@
1
- import{Content as a,Portal as i}from"@radix-ui/react-dialog";import e from"react";import{MAX_Z_INDEX as r}from"../../constants/zIndices.js";import{styled as n}from"../../stitches.js";import{SidedrawerOverlay as d}from"./SidedrawerOverlay.js";import{slideInLeft as l,slideOutLeft as m}from"../../utilities/style/keyframe-animations.js";const s=n(a,{bg:"white",boxShadow:"$2",display:"flex",flexDirection:"column",position:"fixed",top:0,left:0,height:"100%",maxWidth:"304px",width:"100%",zIndex:r,"@allowMotion":{'&[data-state="open"]':{animation:`${l} 250ms ease-out`},'&[data-state="closed"]':{animation:`${m} 250ms ease-out`}}}),f=({children:t,...o})=>e.createElement(i,null,e.createElement(d,{"data-testid":"sidedrawer_overlay"}),e.createElement(s,{role:"navigation",...o},t));export{f as SidedrawerContent};
1
+ import{Content as a,Portal as i}from"@radix-ui/react-dialog";import t from"react";import{MAX_Z_INDEX as r}from"../../constants/zIndices.js";import{styled as n}from"../../stitches.js";import{SidedrawerOverlay as d}from"./SidedrawerOverlay.js";import{slideInLeft as l,slideOutLeft as m}from"../../utilities/style/keyframe-animations.js";const s=n(a,{bg:"white",boxShadow:"$2",display:"flex",flexDirection:"column",position:"fixed",top:0,left:0,height:"100%",maxWidth:"304px",width:"100%",zIndex:r,"@allowMotion":{'&[data-state="open"]':{animation:`${l} 250ms ease-out`},'&[data-state="closed"]':{animation:`${m} 250ms ease-out`}}}),f=({children:e,...o})=>t.createElement(i,null,t.createElement(d,{"data-testid":"sidedrawer_overlay"}),t.createElement(s,{role:"navigation",...o},e));export{f as SidedrawerContent};
@@ -1 +1 @@
1
- import e from"react";import{useFormContext as x,Controller as E}from"react-hook-form";import{FieldWrapper as V}from"../field-wrapper/FieldWrapper.js";import"../field-wrapper/InlineFieldWrapper.js";import{Slider as l}from"../slider/Slider.js";const n=({css:u,label:i,name:t,defaultValue:a,outputLabel:p,min:r=0,max:m=100,steps:d=[],...s})=>{const{control:c}=x();return e.createElement(V,{css:u,fieldId:t,label:i},e.createElement(E,{control:c,name:t,defaultValue:a,render:({onChange:f,value:o})=>e.createElement(l,{name:t,defaultValue:a,onValueChange:f,value:o,min:r,max:m,...s},e.createElement(l.Steps,{min:r,max:m,steps:d}),e.createElement(l.Value,{value:o||a,outputLabel:p}))}))};n.displayName="SliderField";export{n as SliderField};
1
+ import e from"react";import{useFormContext as x,Controller as E}from"react-hook-form";import{FieldWrapper as V}from"../field-wrapper/FieldWrapper.js";import"../field-wrapper/InlineFieldWrapper.js";import{Slider as l}from"../slider/Slider.js";const o=({css:u,label:i,name:t,defaultValue:a,outputLabel:p,min:r=0,max:m=100,steps:d=[],...s})=>{const{control:c}=x();return e.createElement(V,{css:u,fieldId:t,label:i},e.createElement(E,{control:c,name:t,defaultValue:a,render:({onChange:f,value:n})=>e.createElement(l,{name:t,defaultValue:a,onValueChange:f,value:n,min:r,max:m,...s},e.createElement(l.Steps,{min:r,max:m,steps:d}),e.createElement(l.Value,{value:n||a,outputLabel:p}))}))};o.displayName="SliderField";export{o as SliderField};
@@ -1 +1 @@
1
- import*as t from"react";import{styled as r}from"../../stitches.js";import{StyledDivider as e}from"../divider/Divider.js";import{StyledHeading as d}from"../heading/Heading.js";import{StyledImage as a}from"../image/Image.js";import{StyledList as l}from"../list/List.js";import{StyledText as c}from"../text/Text.js";const f=r("div",{"& > *":{"&:not(:first-child)":{mt:"$5"},"&:not(:last-child)":{mb:"$5"}},[`& > ${d}`]:{maxWidth:"65ch"},[`& > ${c}`]:{maxWidth:"75ch"},[`& > ${l}`]:{maxWidth:"75ch"},[`& > ${e}`]:{my:"$5"},[`& > ${a}`]:{display:"block","&:not(:first-child)":{mt:"$6"},"&:not(:last-child)":{mb:"$6"}}}),o=t.forwardRef((m,i)=>t.createElement(f,{ref:i,...m}));o.displayName="StackContent";export{o as StackContent};
1
+ import*as t from"react";import{styled as r}from"../../stitches.js";import{StyledDivider as e}from"../divider/Divider.js";import{StyledHeading as d}from"../heading/Heading.js";import{StyledImage as a}from"../image/Image.js";import{StyledList as l}from"../list/List.js";import{StyledText as c}from"../text/Text.js";const f=r("div",{"& > *":{"&:not(:first-child)":{mt:"$5"},"&:not(:last-child)":{mb:"$5"}},[`& > ${d}`]:{maxWidth:"65ch"},[`& > ${c}`]:{maxWidth:"75ch"},[`& > ${l}`]:{maxWidth:"75ch"},[`& > ${e}`]:{my:"$5"},[`& > ${a}`]:{display:"block","&:not(:first-child)":{mt:"$6"},"&:not(:last-child)":{mb:"$6"}}}),m=t.forwardRef((o,i)=>t.createElement(f,{ref:i,...o}));m.displayName="StackContent";export{m as StackContent};
@@ -1 +1 @@
1
- import*as i from"react";import{Button as n}from"../button/Button.js";import{useStepper as a}from"./stepper-context/StepperContext.js";const l=({label:e,children:t,...r})=>{const{activeStep:o,goToPreviousStep:p}=a();return i.createElement(n,{size:"sm",appearance:"outline",...r,disabled:o===0,onClick:p},t||(e==null?void 0:e(o)))};export{l as StepperStepBack};
1
+ import*as i from"react";import{Button as n}from"../button/Button.js";import{useStepper as a}from"./stepper-context/StepperContext.js";const l=({label:e,children:o,...r})=>{const{activeStep:t,goToPreviousStep:p}=a();return i.createElement(n,{size:"sm",appearance:"outline",...r,disabled:t===0,onClick:p},o||(e==null?void 0:e(t)))};export{l as StepperStepBack};
@@ -1 +1 @@
1
- import o from"react";import{styled as l}from"../../stitches.js";import{TableHeaderCell as e}from"./TableHeaderCell.js";const r={PRIMARY:"primary",PRIMARY_DARK:"primaryDark",LIGHT:"light"},i=l("thead",{variants:{theme:{[r.PRIMARY]:{[`${e}`]:{bg:"$primary"}},[r.PRIMARY_DARK]:{[`${e}`]:{bg:"$primaryDark"}},[r.LIGHT]:{[`${e}`]:{bg:"$tonal50",color:"$tonal600"}}}}}),a=({theme:t="primaryDark",...m})=>o.createElement(i,{theme:t,...m});a.displayName="TableHeader";export{r as TABLE_HEADER_THEMES,a as TableHeader};
1
+ import l from"react";import{styled as o}from"../../stitches.js";import{TableHeaderCell as e}from"./TableHeaderCell.js";const r={PRIMARY:"primary",PRIMARY_DARK:"primaryDark",LIGHT:"light"},i=o("thead",{variants:{theme:{[r.PRIMARY]:{[`${e}`]:{bg:"$primary"}},[r.PRIMARY_DARK]:{[`${e}`]:{bg:"$primaryDark"}},[r.LIGHT]:{[`${e}`]:{bg:"$tonal50",color:"$tonal600"}}}}}),a=({theme:t="primaryDark",...m})=>l.createElement(i,{theme:t,...m});a.displayName="TableHeader";export{r as TABLE_HEADER_THEMES,a as TableHeader};
@@ -1 +1 @@
1
- import{Root as l,Content as n}from"@radix-ui/react-tabs";import*as p from"react";import{styled as e}from"../../stitches.js";import{TriggerListWrapper as t}from"./TabsTriggerList.js";import{TabTrigger as s}from"./TabTrigger.js";import{passPropsToChildren as g}from"./utils.js";const h=e(l,{display:"flex",flexDirection:"column",variants:{theme:{light:{color:"$primary"},dark:{color:"white"}}}}),i=e(n,{flexGrow:1,fontFamily:"$body",variants:{theme:{light:{color:"$textForeground"},dark:{bg:"$primaryDark",color:"white"}}}}),r=({theme:o="light",children:m,...a})=>p.createElement(h,{theme:o,...a},g(m,{theme:o},[t,i]));r.TriggerList=t,r.Trigger=s,r.Content=i,r.displayName="Tabs";export{r as Tabs};
1
+ import{Root as l,Content as n}from"@radix-ui/react-tabs";import*as p from"react";import{styled as e}from"../../stitches.js";import{TriggerListWrapper as o}from"./TabsTriggerList.js";import{TabTrigger as s}from"./TabTrigger.js";import{passPropsToChildren as g}from"./utils.js";const h=e(l,{display:"flex",flexDirection:"column",variants:{theme:{light:{color:"$primary"},dark:{color:"white"}}}}),i=e(n,{flexGrow:1,fontFamily:"$body",variants:{theme:{light:{color:"$textForeground"},dark:{bg:"$primaryDark",color:"white"}}}}),r=({theme:t="light",children:m,...a})=>p.createElement(h,{theme:t,...a},g(m,{theme:t},[o,i]));r.TriggerList=o,r.Trigger=s,r.Content=i,r.displayName="Tabs";export{r as Tabs};
@@ -1 +1 @@
1
- import o from"react";const t=(n,e,i=[])=>o.Children.map(n,l=>o.isValidElement(l)&&i.includes(l==null?void 0:l.type)?o.cloneElement(l,{...e}):l);export{t as passPropsToChildren};
1
+ import n from"react";const i=(o,t,e=[])=>n.Children.map(o,l=>n.isValidElement(l)&&e.includes(l==null?void 0:l.type)?n.cloneElement(l,{...t}):l);export{i as passPropsToChildren};
@@ -1 +1 @@
1
- import*as n from"react";import{styled as l}from"../../stitches.js";import{capsize as e}from"../../utilities/style/capsize.js";const f="md",t={size:{xs:{fontSize:"$xs",lineHeight:1.6,...e(.4364)},sm:{fontSize:"$sm",lineHeight:1.53,...e(.4056)},md:{fontSize:"$md",lineHeight:1.5,...e(.3864)},lg:{fontSize:"$lg",lineHeight:1.52,...e(.3983)},xl:{fontSize:"$xl",lineHeight:1.42,...e(.3506)}},noCapsize:{true:{"&::before, &::after":{display:"none"}}}},m=({size:i,noCapsize:o})=>({...t.size[i],...t.noCapsize[`${o}`]}),a=l("p",{color:"$tonal600",fontFamily:"$body",fontWeight:400,margin:0,"& > &":{"&:before, &:after":{display:"none"}},variants:t}),s=n.forwardRef(({size:i=f,...o},r)=>n.createElement(a,{size:i,...o,ref:r}));s.displayName="Text";export{a as StyledText,s as Text,m as getTextVariant,t as textVariants};
1
+ import*as o from"react";import{styled as f}from"../../stitches.js";import{capsize as e}from"../../utilities/style/capsize.js";const i={size:{xs:{fontSize:"$xs",lineHeight:1.6,...e(.4364)},sm:{fontSize:"$sm",lineHeight:1.53,...e(.4056)},md:{fontSize:"$md",lineHeight:1.5,...e(.3864)},lg:{fontSize:"$lg",lineHeight:1.52,...e(.3983)},xl:{fontSize:"$xl",lineHeight:1.42,...e(.3506)}},noCapsize:{true:{"&::before, &::after":{display:"none"}}}},l=({size:t,noCapsize:n})=>({...i.size[t],...i.noCapsize[`${n}`]}),a=f("p",{fontFamily:"$body",fontWeight:400,margin:0,"& > &":{"&:before, &:after":{display:"none"}},variants:i}),s=o.forwardRef(({size:t="md",...n},r)=>o.createElement(a,{size:t,...n,ref:r}));s.displayName="Text";export{a as StyledText,s as Text,l as getTextVariant,i as textVariants};
@@ -1 +1 @@
1
- import{Error as g,Close as h}from"@atom-learning/icons";import*as t from"react";import{toast as $}from"react-hot-toast";import{keyframes as i,styled as a}from"../../stitches.js";import{ActionIcon as v}from"../action-icon/ActionIcon.js";import{Icon as s}from"../icon/Icon.js";import{Loader as y}from"../loader/Loader.js";import{Text as w}from"../text/Text.js";const n=400,x=i({"0%":{transform:"translate3d(0,-100%,0)",opacity:0},"100%":{transform:"translate3d(0,0,0)",opacity:1}}),E=i({"0%":{transform:"translate3d(0,0,0)",opacity:1},"100%":{transform:"translate3d(0,-100%,0)",opacity:0}}),k=a("div",{position:"absolute",width:"100%",variants:{visible:{true:{"@allowMotion":{animation:`${x} 250ms cubic-bezier(0.22, 1, 0.36, 1)`}},false:{opacity:0,"@allowMotion":{animation:`${E} 250ms cubic-bezier(0.22, 1, 0.36, 1)`}}}}}),I=a("div",{pointerEvents:"auto",alignItems:"center",borderRadius:"$0",boxShadow:"$1",boxSizing:"border-box",color:"white",display:"flex",minHeight:"$5",pl:"$4",position:"relative",pr:"$6",py:"$4",transition:"background-color 50ms ease-out",width:"100%","@sm":{width:n},"@allowMotion":{transition:"background-color 50ms ease-out, transform 150ms ease-out"},variants:{status:{blank:{bg:"$primary"},error:{bg:"$danger"},loading:{bg:"$primary"},success:{bg:"$success"}}}}),T=t.memo(({ariaLive:l,height:m,id:e,message:c,role:p,type:o="blank",visible:d,calculateOffset:u,updateHeight:b})=>{const f=u(e,{reverseOrder:!0,margin:8});return t.createElement(k,{visible:d},t.createElement(I,{ref:r=>{r&&m===void 0&&b(e,r.getBoundingClientRect().height)},status:o,role:p,"aria-live":l,style:{transform:`translateY(${f}px)`}},o==="error"&&t.createElement(s,{size:"sm",css:{mr:"$3",flex:"0 0 auto"},is:g}),t.createElement(w,{css:{color:"inherit"}},c),o==="loading"?t.createElement(y,{css:{flex:"0 0 auto",ml:"auto"}}):t.createElement(v,{css:{position:"absolute",top:"$2",right:"$2",color:"white","&:hover,&:focus":{color:"white",opacity:.5}},label:"Close alert",onClick:()=>$.dismiss(e)},t.createElement(s,{is:h}))))});export{n as TOAST_WIDTH,T as Toast};
1
+ import{Error as g,Close as h}from"@atom-learning/icons";import*as t from"react";import{toast as v}from"react-hot-toast";import{keyframes as a,styled as i}from"../../stitches.js";import{ActionIcon as y}from"../action-icon/ActionIcon.js";import{Icon as s}from"../icon/Icon.js";import{Loader as $}from"../loader/Loader.js";import{Text as w}from"../text/Text.js";const n=400,x=a({"0%":{transform:"translate3d(0,-100%,0)",opacity:0},"100%":{transform:"translate3d(0,0,0)",opacity:1}}),E=a({"0%":{transform:"translate3d(0,0,0)",opacity:1},"100%":{transform:"translate3d(0,-100%,0)",opacity:0}}),k=i("div",{position:"absolute",width:"100%",variants:{visible:{true:{"@allowMotion":{animation:`${x} 250ms cubic-bezier(0.22, 1, 0.36, 1)`}},false:{opacity:0,"@allowMotion":{animation:`${E} 250ms cubic-bezier(0.22, 1, 0.36, 1)`}}}}}),I=i("div",{pointerEvents:"auto",alignItems:"center",borderRadius:"$0",boxShadow:"$1",boxSizing:"border-box",color:"white",display:"flex",minHeight:"$5",pl:"$4",position:"relative",pr:"$6",py:"$4",transition:"background-color 50ms ease-out",width:"100%","@sm":{width:n},"@allowMotion":{transition:"background-color 50ms ease-out, transform 150ms ease-out"},variants:{status:{blank:{bg:"$primary"},error:{bg:"$danger"},loading:{bg:"$primary"},success:{bg:"$success"}}}}),T=t.memo(({ariaLive:l,height:m,id:e,message:c,role:p,type:o="blank",visible:d,calculateOffset:u,updateHeight:b})=>{const f=u(e,{reverseOrder:!0,margin:8});return t.createElement(k,{visible:d},t.createElement(I,{ref:r=>{r&&m===void 0&&b(e,r.getBoundingClientRect().height)},status:o,role:p,"aria-live":l,style:{transform:`translateY(${f}px)`}},o==="error"&&t.createElement(s,{size:"sm",css:{mr:"$3",flex:"0 0 auto"},is:g}),t.createElement(w,null,c),o==="loading"?t.createElement($,{css:{flex:"0 0 auto",ml:"auto"}}):t.createElement(y,{css:{position:"absolute",top:"$2",right:"$2",color:"white","&:hover,&:focus":{color:"white",opacity:.5}},label:"Close alert",onClick:()=>v.dismiss(e)},t.createElement(s,{is:h}))))});export{n as TOAST_WIDTH,T as Toast};
@@ -1 +1 @@
1
- import*as t from"react";import{useToaster as p}from"react-hot-toast";import{default as _}from"react-hot-toast";import{styled as c}from"../../stitches.js";import{TOAST_WIDTH as d,Toast as f}from"./Toast.js";import{MAX_Z_INDEX as u}from"../../constants/zIndices.js";const T=c("div",{left:"$2",position:"fixed",top:"$2",right:"$2",zIndex:u,"@sm":{top:"$3",right:"auto",left:`calc(50% - ${d/2}px)`}}),o=({children:a})=>{const{toasts:r,handlers:s}=p(),{startPause:i,endPause:m,calculateOffset:n,updateHeight:l}=s;return t.createElement(t.Fragment,null,t.createElement(T,{onMouseEnter:i,onMouseLeave:m},r.map(e=>t.createElement(f,{key:e.id,calculateOffset:n,updateHeight:l,...e}))),a)};o.displayName="ToastProvider";export{o as ToastProvider,_ as toast};
1
+ import*as t from"react";import{useToaster as p}from"react-hot-toast";import{default as P}from"react-hot-toast";import{styled as c}from"../../stitches.js";import{TOAST_WIDTH as d,Toast as f}from"./Toast.js";import{MAX_Z_INDEX as u}from"../../constants/zIndices.js";const T=c("div",{left:"$2",position:"fixed",top:"$2",right:"$2",zIndex:u,"@sm":{top:"$3",right:"auto",left:`calc(50% - ${d/2}px)`}}),o=({children:a})=>{const{toasts:r,handlers:s}=p(),{startPause:i,endPause:m,calculateOffset:n,updateHeight:l}=s;return t.createElement(t.Fragment,null,t.createElement(T,{onMouseEnter:i,onMouseLeave:m},r.map(e=>t.createElement(f,{key:e.id,calculateOffset:n,updateHeight:l,...e}))),a)};o.displayName="ToastProvider";export{o as ToastProvider,P as toast};
@@ -1 +1 @@
1
- import*as n from"react";import{styled as g}from"../../stitches.js";import{StyledIcon as f,Icon as r}from"../icon/Icon.js";import{StyledItem as h}from"./ToggleGroupItem.js";const t={sm:"32px",md:"40px",lg:"48px"},$={sm:"$4",md:"$5",lg:"$5"},u={sm:"$2",md:"$3",lg:"$3"},l=i=>({fontSize:`$${i}`,px:$[i],minHeight:t[i],"& > *:not(:last-child)":{mr:u[i]}}),d=g(h,{flexGrow:1,display:"flex",alignItems:"center",justifyContent:"center",fontWeight:600,lineHeight:1,py:"$1",[`& ${f}`]:{flexShrink:0},variants:{size:{sm:l("sm"),md:l("md"),lg:l("lg")},isIconOnly:{true:{}}},compoundVariants:[{isIconOnly:!0,size:"sm",css:{minWidth:t.sm,p:0}},{isIconOnly:!0,size:"md",css:{minWidth:t.md,p:0}},{isIconOnly:!0,size:"lg",css:{minWidth:t.lg,p:0}}]}),x=n.forwardRef(({size:i="md",children:p,...c},a)=>{var o;const s=n.Children.toArray(p),m=s.length<=1,y=m&&n.isValidElement(s[0])&&((o=s[0])==null?void 0:o.type)===r;return n.createElement(d,{ref:a,size:i,isIconOnly:y,...c},s.map(e=>!m&&typeof e=="string"?n.createElement("span",{key:e},e):n.isValidElement(e)&&(e==null?void 0:e.type)===r?n.cloneElement(e,{...e.props,size:i}):e))});export{d as StyledButton,x as ToggleGroupButton};
1
+ import*as n from"react";import{styled as g}from"../../stitches.js";import{StyledIcon as f,Icon as r}from"../icon/Icon.js";import{StyledItem as h}from"./ToggleGroupItem.js";const s={sm:"32px",md:"40px",lg:"48px"},u={sm:"$4",md:"$5",lg:"$5"},x={sm:"$2",md:"$3",lg:"$3"},l=i=>({fontSize:`$${i}`,px:u[i],minHeight:s[i],"& > *:not(:last-child)":{mr:x[i]}}),d=g(h,{flexGrow:1,display:"flex",alignItems:"center",justifyContent:"center",fontWeight:600,lineHeight:1,py:"$1",[`& ${f}`]:{flexShrink:0},variants:{size:{sm:l("sm"),md:l("md"),lg:l("lg")},isIconOnly:{true:{}}},compoundVariants:[{isIconOnly:!0,size:"sm",css:{minWidth:s.sm,p:0}},{isIconOnly:!0,size:"md",css:{minWidth:s.md,p:0}},{isIconOnly:!0,size:"lg",css:{minWidth:s.lg,p:0}}]}),I=n.forwardRef(({size:i="md",children:p,...c},a)=>{var m;const t=n.Children.toArray(p),o=t.length<=1,y=o&&n.isValidElement(t[0])&&((m=t[0])==null?void 0:m.type)===r;return n.createElement(d,{ref:a,size:i,isIconOnly:y,...c},t.map(e=>!o&&typeof e=="string"?n.createElement("span",{key:e},e):n.isValidElement(e)&&(e==null?void 0:e.type)===r?n.cloneElement(e,{...e.props,size:i}):e))});export{d as StyledButton,I as ToggleGroupButton};
@@ -1 +1 @@
1
- import{Content as m,Arrow as l}from"@radix-ui/react-tooltip";import*as a from"react";import{TOOLTIP_Z_INDEX as r}from"../../constants/zIndices.js";import{styled as t}from"../../stitches.js";import{slideDownAndFade as s,slideLeftAndFade as p,slideUpAndFade as f,slideRightAndFade as c}from"../../utilities/style/keyframe-animations.js";const h=t(m,{backgroundColor:"$tonal500",borderRadius:"$0",boxShadow:"$0",color:"white",fontFamily:"$body",fontSize:"$sm",lineHeight:1.5,whiteSpace:"normal",px:"$3",py:"$2",zIndex:r,"@allowMotion":{animationDuration:"75ms",animationTimingFunction:"cubic-bezier(0.16, 1, 0.3, 1)",willChange:"transform, opacity",'&[data-state="delayed-open"]':{'&[data-side="top"]':{animationName:s},'&[data-side="right"]':{animationName:p},'&[data-side="bottom"]':{animationName:f},'&[data-side="left"]':{animationName:c}}},variants:{size:{sm:{maxWidth:"100px"},md:{maxWidth:"250px"},lg:{maxWidth:"400px"}}}}),x=t(l,{fill:"$tonal500",'[data-align="end"] &':{mr:"$2"},'[data-align="start"] &':{ml:"$2"}}),$=({children:i,side:e="top",sideOffset:o=4,size:n="md",...d})=>a.createElement(h,{side:e,sideOffset:o,size:n,...d},i,a.createElement(x,null));export{$ as TooltipContent};
1
+ import{Content as m,Arrow as l}from"@radix-ui/react-tooltip";import*as t from"react";import{TOOLTIP_Z_INDEX as r}from"../../constants/zIndices.js";import{styled as a}from"../../stitches.js";import{slideDownAndFade as s,slideLeftAndFade as p,slideUpAndFade as f,slideRightAndFade as c}from"../../utilities/style/keyframe-animations.js";const h=a(m,{backgroundColor:"$tonal500",borderRadius:"$0",boxShadow:"$0",color:"white",fontFamily:"$body",fontSize:"$sm",lineHeight:1.5,whiteSpace:"normal",px:"$3",py:"$2",zIndex:r,"@allowMotion":{animationDuration:"75ms",animationTimingFunction:"cubic-bezier(0.16, 1, 0.3, 1)",willChange:"transform, opacity",'&[data-state="delayed-open"]':{'&[data-side="top"]':{animationName:s},'&[data-side="right"]':{animationName:p},'&[data-side="bottom"]':{animationName:f},'&[data-side="left"]':{animationName:c}}},variants:{size:{sm:{maxWidth:"100px"},md:{maxWidth:"250px"},lg:{maxWidth:"400px"}}}}),x=a(l,{fill:"$tonal500",'[data-align="end"] &':{mr:"$2"},'[data-align="start"] &':{ml:"$2"}}),$=({children:i,side:e="top",sideOffset:o=4,size:n="md",...d})=>t.createElement(h,{side:e,sideOffset:o,size:n,...d},i,t.createElement(x,null));export{$ as TooltipContent};
@@ -1 +1 @@
1
- import*as e from"react";import m from"react-player/vimeo";import{Box as p}from"../box/Box.js";import{styled as a}from"../../stitches.js";import{CSSWrapper as l}from"../../utilities/css-wrapper/CSSWrapper.js";const f=a(m,{}),o=e.forwardRef(({id:r,ratio:t=9/16,css:i,...s},d)=>e.createElement(l,{css:i},e.createElement(p,{css:{borderRadius:"$0",position:"relative",paddingTop:`${t*100}%`,overflow:"hidden",height:0,width:"100%"}},e.createElement(f,{...s,role:"figure",url:`https://player.vimeo.com/video/${r}`,height:"100%",width:"100%",css:{position:"absolute",top:0,left:0},ref:d}))));o.displayName="Video";export{o as Video};
1
+ import*as e from"react";import m from"react-player/vimeo";import{Box as p}from"../box/Box.js";import{styled as a}from"../../stitches.js";import{CSSWrapper as l}from"../../utilities/css-wrapper/CSSWrapper.js";const f=a(m,{}),o=e.forwardRef(({id:t,ratio:r=9/16,css:i,...s},d)=>e.createElement(l,{css:i},e.createElement(p,{css:{borderRadius:"$0",position:"relative",paddingTop:`${r*100}%`,overflow:"hidden",height:0,width:"100%"}},e.createElement(f,{...s,role:"figure",url:`https://player.vimeo.com/video/${t}`,height:"100%",width:"100%",css:{position:"absolute",top:0,left:0},ref:d}))));o.displayName="Video";export{o as Video};