@bcgov/design-system-react-components 0.7.0 → 0.8.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/dist/index.d.ts CHANGED
@@ -1,20 +1,22 @@
1
- import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { DisclosureProps, DisclosureGroupProps, DialogProps as DialogProps$1, ButtonProps as ButtonProps$1, CalendarProps, DateValue, CheckboxProps, CheckboxGroupProps as CheckboxGroupProps$1, ValidationResult, DatePickerProps as DatePickerProps$1, FormProps, HeadingProps as HeadingProps$1, LinkProps as LinkProps$1, ModalOverlayProps, ProgressBarProps as ProgressBarProps$1, RadioProps, RadioGroupProps as RadioGroupProps$1, SelectProps as SelectProps$1, ListBoxItemProps as ListBoxItemProps$1, Key, SeparatorProps as SeparatorProps$1, TagProps as TagProps$1, TagGroupProps as TagGroupProps$1, TagListProps as TagListProps$1, TextProps as TextProps$1, TextFieldProps as TextFieldProps$1, TimeValue, TimeFieldProps as TimeFieldProps$1, ToggleButtonProps as ToggleButtonProps$1, ToggleButtonGroupProps as ToggleButtonGroupProps$1, SwitchProps as SwitchProps$1, TooltipProps, NumberFieldProps as NumberFieldProps$1 } from 'react-aria-components';
3
- export { DialogTrigger, TooltipTrigger } from 'react-aria-components';
4
- import { PropsWithChildren } from 'react';
1
+ import * as react from 'react';
2
+ import react__default, { PropsWithChildren } from 'react';
3
+ import { DisclosureProps, DisclosureGroupProps, DialogProps as DialogProps$1, ButtonProps as ButtonProps$1, CalendarProps, DateValue, CheckboxProps, CheckboxGroupProps as CheckboxGroupProps$1, ValidationResult, DatePickerProps as DatePickerProps$1, FormProps, HeadingProps as HeadingProps$1, LinkProps as LinkProps$1, MenuItemProps as MenuItemProps$1, MenuItemRenderProps, MenuProps as MenuProps$1, Key, PopoverProps, ModalOverlayProps, ProgressBarProps as ProgressBarProps$1, RadioProps, RadioGroupProps as RadioGroupProps$1, TagProps as TagProps$1, SelectProps as SelectProps$1, ListBoxItemProps as ListBoxItemProps$1, SeparatorProps as SeparatorProps$1, TagGroupProps as TagGroupProps$1, TagListProps as TagListProps$1, TextProps as TextProps$1, TextFieldProps as TextFieldProps$1, TimeValue, TimeFieldProps as TimeFieldProps$1, ToggleButtonProps as ToggleButtonProps$1, ToggleButtonGroupProps as ToggleButtonGroupProps$1, SwitchProps as SwitchProps$1, TooltipProps, NumberFieldProps as NumberFieldProps$1 } from 'react-aria-components';
4
+ export { DialogTrigger, MenuSection, Header as MenuSectionHeader, MenuTrigger, SubmenuTrigger, TooltipTrigger } from 'react-aria-components';
5
5
 
6
6
  interface AccordionProps extends DisclosureProps {
7
7
  label?: string;
8
8
  }
9
- declare function Accordion({ label, children, ...props }: AccordionProps): react_jsx_runtime.JSX.Element;
9
+ declare function Accordion({ label, children, ...props }: AccordionProps): react.JSX.Element;
10
10
 
11
11
  interface AccordionGroupProps extends DisclosureGroupProps {
12
12
  title?: string;
13
13
  titleElement?: "h1" | "h2" | "h3" | "h4" | "h5" | "h6";
14
14
  }
15
- declare function AccordionGroup({ title, titleElement, children, ...props }: AccordionGroupProps): react_jsx_runtime.JSX.Element;
15
+ declare function AccordionGroup({ title, titleElement, children, ...props }: AccordionGroupProps): react.JSX.Element;
16
16
 
17
17
  interface AlertBannerProps extends React.PropsWithChildren {
18
+ size?: "small" | "medium";
19
+ layout?: "fixed" | "fluid";
18
20
  variant?: "info" | "success" | "warning" | "danger" | "black";
19
21
  isIconHidden?: boolean;
20
22
  isCloseable?: boolean;
@@ -22,7 +24,7 @@ interface AlertBannerProps extends React.PropsWithChildren {
22
24
  customIcon?: React.ReactNode;
23
25
  onClose?: () => void;
24
26
  }
25
- declare function AlertBanner({ variant, isIconHidden, isCloseable, role, onClose, children, customIcon, ...props }: AlertBannerProps): react_jsx_runtime.JSX.Element;
27
+ declare function AlertBanner({ variant, size, layout, isIconHidden, isCloseable, role, onClose, children, customIcon, ...props }: AlertBannerProps): react.JSX.Element;
26
28
 
27
29
  interface AlertDialogProps extends DialogProps$1 {
28
30
  variant?: "info" | "confirmation" | "warning" | "error" | "destructive";
@@ -31,7 +33,7 @@ interface AlertDialogProps extends DialogProps$1 {
31
33
  isCloseable?: boolean;
32
34
  buttons?: React.ReactNode;
33
35
  }
34
- declare function AlertDialog({ children, variant, role, title, isCloseable, isIconHidden, buttons, ...props }: AlertDialogProps): react_jsx_runtime.JSX.Element;
36
+ declare function AlertDialog({ children, variant, role, title, isCloseable, isIconHidden, buttons, ...props }: AlertDialogProps): react.JSX.Element;
35
37
 
36
38
  interface ButtonProps extends ButtonProps$1 {
37
39
  /**
@@ -51,16 +53,16 @@ interface ButtonProps extends ButtonProps$1 {
51
53
  */
52
54
  isIconButton?: boolean;
53
55
  }
54
- declare function Button({ size, variant, danger, isIconButton, ...props }: ButtonProps): react_jsx_runtime.JSX.Element;
56
+ declare function Button({ size, variant, danger, isIconButton, ...props }: ButtonProps): react.JSX.Element;
55
57
 
56
58
  interface ButtonGroupProps extends React.PropsWithChildren {
57
59
  orientation?: "horizontal" | "vertical";
58
60
  alignment?: "start" | "center" | "end";
59
61
  ariaLabel?: string | undefined;
60
62
  }
61
- declare function ButtonGroup({ orientation, alignment, ariaLabel, children, ...props }: ButtonGroupProps): react_jsx_runtime.JSX.Element;
63
+ declare function ButtonGroup({ orientation, alignment, ariaLabel, children, ...props }: ButtonGroupProps): react.JSX.Element;
62
64
 
63
- declare function Calendar({ visibleDuration, ...props }: CalendarProps<DateValue>): react_jsx_runtime.JSX.Element;
65
+ declare function Calendar({ visibleDuration, ...props }: CalendarProps<DateValue>): react.JSX.Element;
64
66
 
65
67
  interface CalloutProps extends React.PropsWithChildren {
66
68
  variant?: "lightGrey" | "lightBlue" | "lightGold" | "Blue" | "Grey" | "Black";
@@ -70,9 +72,9 @@ interface CalloutProps extends React.PropsWithChildren {
70
72
  role?: React.AriaRole | undefined;
71
73
  isLeftBorderDisabled?: boolean;
72
74
  }
73
- declare function Callout({ variant, title, description, buttons, role, isLeftBorderDisabled, children, ...props }: CalloutProps): react_jsx_runtime.JSX.Element;
75
+ declare function Callout({ variant, title, description, buttons, role, isLeftBorderDisabled, children, ...props }: CalloutProps): react.JSX.Element;
74
76
 
75
- declare function Checkbox({ value, children, ...props }: CheckboxProps): react_jsx_runtime.JSX.Element;
77
+ declare function Checkbox({ value, children, ...props }: CheckboxProps): react.JSX.Element;
76
78
 
77
79
  interface CheckboxGroupProps extends CheckboxGroupProps$1 {
78
80
  orientation?: "horizontal" | "vertical";
@@ -82,7 +84,7 @@ interface CheckboxGroupProps extends CheckboxGroupProps$1 {
82
84
  /** `flex-wrap` style property, defaults to `nowrap` */
83
85
  flexWrap?: "nowrap" | "wrap" | "wrap-reverse";
84
86
  }
85
- declare function CheckboxGroup({ orientation, label, description, errorMessage, flexWrap, children, ...props }: CheckboxGroupProps): react_jsx_runtime.JSX.Element;
87
+ declare function CheckboxGroup({ orientation, label, description, errorMessage, flexWrap, children, ...props }: CheckboxGroupProps): react.JSX.Element;
86
88
 
87
89
  interface DatePickerProps<T extends DateValue> extends DatePickerProps$1<T> {
88
90
  size?: "small" | "medium";
@@ -94,12 +96,12 @@ interface DatePickerProps<T extends DateValue> extends DatePickerProps$1<T> {
94
96
  isBrowserLocaleUsed?: boolean;
95
97
  }
96
98
 
97
- declare function DatePicker<T extends DateValue>({ size, label, description, errorMessage, showFormatHelpText, isRequired, isCalendarDisabled, isBrowserLocaleUsed, ...props }: DatePickerProps<T>): react_jsx_runtime.JSX.Element;
99
+ declare function DatePicker<T extends DateValue>({ size, label, description, errorMessage, showFormatHelpText, isRequired, isCalendarDisabled, isBrowserLocaleUsed, ...props }: DatePickerProps<T>): react.JSX.Element;
98
100
 
99
101
  interface DialogProps extends DialogProps$1 {
100
102
  isCloseable?: boolean;
101
103
  }
102
- declare function Dialog({ isCloseable, role, children, ...props }: DialogProps): react_jsx_runtime.JSX.Element;
104
+ declare function Dialog({ isCloseable, role, children, ...props }: DialogProps): react.JSX.Element;
103
105
 
104
106
  interface FooterLinksProps {
105
107
  /**
@@ -117,7 +119,7 @@ interface FooterLinksProps {
117
119
  * @param {FooterLinksProps} props
118
120
  * @returns {React.ReactElement}
119
121
  */
120
- declare function FooterLinks({ title, links }: FooterLinksProps): react_jsx_runtime.JSX.Element;
122
+ declare function FooterLinks({ title, links }: FooterLinksProps): react.JSX.Element;
121
123
  interface FooterProps {
122
124
  /**
123
125
  * Land acknowledgement block (defaults to Gov.bc.ca land acknowledgement)
@@ -161,9 +163,9 @@ interface FooterProps {
161
163
  * @param {FooterProps} props
162
164
  * @returns {React.ReactElement}
163
165
  */
164
- declare function Footer({ children, acknowledgement, logo, contact, links, copyright, hideAcknowledgement, hideLogoAndLinks, hideCopyright, }: React.PropsWithChildren<FooterProps>): react_jsx_runtime.JSX.Element;
166
+ declare function Footer({ children, acknowledgement, logo, contact, links, copyright, hideAcknowledgement, hideLogoAndLinks, hideCopyright, }: React.PropsWithChildren<FooterProps>): react.JSX.Element;
165
167
 
166
- declare function Form({ ...props }: FormProps): react_jsx_runtime.JSX.Element;
168
+ declare function Form({ ...props }: FormProps): react.JSX.Element;
167
169
 
168
170
  interface HeaderProps {
169
171
  /**
@@ -191,13 +193,13 @@ interface HeaderProps {
191
193
  */
192
194
  titleElement?: "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "span" | "p";
193
195
  }
194
- declare function Header({ children, logoLinkElement, logoImage, skipLinks, title, titleElement, }: PropsWithChildren<HeaderProps>): react_jsx_runtime.JSX.Element;
196
+ declare function Header({ children, logoLinkElement, logoImage, skipLinks, title, titleElement, }: PropsWithChildren<HeaderProps>): react.JSX.Element;
195
197
 
196
198
  interface HeadingProps extends HeadingProps$1 {
197
199
  color?: "primary" | "primaryInvert" | "secondary" | "secondaryInvert" | "disabled" | "danger";
198
200
  isUnstyled?: boolean;
199
201
  }
200
- declare function Heading({ color, isUnstyled, ...props }: HeadingProps): react_jsx_runtime.JSX.Element;
202
+ declare function Heading({ color, isUnstyled, ...props }: HeadingProps): react.JSX.Element;
201
203
 
202
204
  interface InlineAlertProps extends React.PropsWithChildren {
203
205
  variant?: "info" | "success" | "warning" | "danger";
@@ -210,7 +212,7 @@ interface InlineAlertProps extends React.PropsWithChildren {
210
212
  role?: React.AriaRole | undefined;
211
213
  onClose?: () => void;
212
214
  }
213
- declare function InlineAlert({ variant, title, description, isIconHidden, isCloseable, role, customIcon, buttons, children, onClose, ...props }: InlineAlertProps): react_jsx_runtime.JSX.Element;
215
+ declare function InlineAlert({ variant, title, description, isIconHidden, isCloseable, role, customIcon, buttons, children, onClose, ...props }: InlineAlertProps): react.JSX.Element;
214
216
 
215
217
  interface LinkProps extends LinkProps$1 {
216
218
  children?: React.ReactNode;
@@ -223,21 +225,51 @@ interface LinkProps extends LinkProps$1 {
223
225
  iconLeft?: React.ReactElement;
224
226
  iconRight?: React.ReactElement;
225
227
  }
226
- declare function Link({ children, size, danger, isButton, buttonVariant, isUnstyled, iconLeft, iconRight, ariaLabel, ...props }: LinkProps): react_jsx_runtime.JSX.Element;
228
+ declare function Link({ children, size, danger, isButton, buttonVariant, isUnstyled, iconLeft, iconRight, ariaLabel, ...props }: LinkProps): react.JSX.Element;
229
+
230
+ interface MenuItemProps extends MenuItemProps$1 {
231
+ label?: string;
232
+ description?: string;
233
+ size?: "small" | "medium";
234
+ iconLeft?: React.ReactElement;
235
+ children?: React.ReactNode | ((props: MenuItemRenderProps & {
236
+ defaultChildren: React.ReactNode;
237
+ }) => React.ReactNode);
238
+ }
239
+ declare function MenuItem({ size, label, description, iconLeft, ...props }: MenuItemProps): react.JSX.Element;
227
240
 
228
- declare function Modal({ children, ...props }: ModalOverlayProps): react_jsx_runtime.JSX.Element;
241
+ interface MenuSectionProps {
242
+ id: Key;
243
+ header?: string;
244
+ items: MenuItemProps[];
245
+ }
246
+ interface MenuProps<T extends MenuItemProps> extends MenuProps$1<T> {
247
+ itemSize?: "small" | "medium";
248
+ items?: T[];
249
+ sections?: MenuSectionProps[];
250
+ placement?: PopoverProps["placement"];
251
+ }
252
+ declare function Menu<T extends MenuItemProps>({ itemSize, children, items, sections, placement, ...props }: MenuProps<T>): react.JSX.Element;
253
+
254
+ declare function Modal({ children, ...props }: ModalOverlayProps): react.JSX.Element;
255
+
256
+ interface SubheaderProps extends react__default.HTMLAttributes<HTMLElement> {
257
+ size?: "small" | "medium";
258
+ ariaLabel?: string;
259
+ }
260
+ declare function Subheader({ size, ariaLabel, children, ...props }: SubheaderProps): react__default.JSX.Element;
229
261
 
230
262
  interface ProgressBarProps extends ProgressBarProps$1 {
231
263
  size?: "small" | "medium" | "large";
232
264
  }
233
- declare function ProgressBar({ size, valueLabel, ...props }: ProgressBarProps): react_jsx_runtime.JSX.Element;
265
+ declare function ProgressBar({ size, valueLabel, ...props }: ProgressBarProps): react.JSX.Element;
234
266
 
235
267
  interface ProgressCircleProps extends ProgressBarProps$1 {
236
268
  size?: "small" | "medium" | "large";
237
269
  }
238
- declare function ProgressCircle({ size, valueLabel, ...props }: ProgressCircleProps): react_jsx_runtime.JSX.Element;
270
+ declare function ProgressCircle({ size, valueLabel, ...props }: ProgressCircleProps): react.JSX.Element;
239
271
 
240
- declare function Radio({ value, children, ...props }: RadioProps): react_jsx_runtime.JSX.Element;
272
+ declare function Radio({ value, children, ...props }: RadioProps): react.JSX.Element;
241
273
 
242
274
  interface RadioGroupProps extends RadioGroupProps$1 {
243
275
  children?: React.ReactNode;
@@ -248,7 +280,27 @@ interface RadioGroupProps extends RadioGroupProps$1 {
248
280
  /** `flex-wrap` style property, defaults to `nowrap` */
249
281
  flexWrap?: "nowrap" | "wrap" | "wrap-reverse";
250
282
  }
251
- declare function RadioGroup({ orientation, label, description, children, errorMessage, flexWrap, ...props }: RadioGroupProps): react_jsx_runtime.JSX.Element;
283
+ declare function RadioGroup({ orientation, label, description, children, errorMessage, flexWrap, ...props }: RadioGroupProps): react.JSX.Element;
284
+
285
+ interface TagProps extends TagProps$1 {
286
+ /**
287
+ * Icon that appears to the left of the `textValue` field
288
+ */
289
+ icon?: React.ReactNode;
290
+ /**
291
+ * Background color
292
+ */
293
+ color?: "bc-blue" | "bc-gold" | "blue" | "dark" | "gray" | "grey" | "green" | "red" | "yellow";
294
+ /**
295
+ * tagStyle
296
+ */
297
+ tagStyle?: "rectangular" | "circular";
298
+ /**
299
+ * size
300
+ */
301
+ size?: "xsmall" | "small" | "medium";
302
+ }
303
+ declare function Tag({ color, tagStyle, size, icon, id, textValue, ...props }: TagProps): react.JSX.Element;
252
304
 
253
305
  interface ListBoxItemProps extends ListBoxItemProps$1 {
254
306
  /** Text label for the option. Provide an `id` if this is not unique. */
@@ -261,6 +313,10 @@ interface ListBoxItemProps extends ListBoxItemProps$1 {
261
313
  iconLeft?: React.ReactElement;
262
314
  /** Right icon slot */
263
315
  iconRight?: React.ReactElement;
316
+ /** Optional color token forwarded to selected tags */
317
+ color?: TagProps["color"];
318
+ /** Optional style token forwarded to selected tags */
319
+ tagStyle?: TagProps["tagStyle"];
264
320
  }
265
321
  interface SelectionSectionProps {
266
322
  id: Key;
@@ -269,7 +325,7 @@ interface SelectionSectionProps {
269
325
  /** Flat list of options within the section */
270
326
  items: ListBoxItemProps[];
271
327
  }
272
- interface SelectProps<T extends object> extends SelectProps$1<T> {
328
+ interface SelectProps<T extends object, M extends "single" | "multiple" = "single"> extends SelectProps$1<T, M> {
273
329
  /** Use `items` for a flat list of options */
274
330
  items?: ListBoxItemProps[];
275
331
  /** Use `sections` for a sectioned list with `items` options in each section */
@@ -284,116 +340,104 @@ interface SelectProps<T extends object> extends SelectProps$1<T> {
284
340
  description?: string;
285
341
  /** Used for data validation and error handling */
286
342
  errorMessage?: string | ((validation: ValidationResult) => string);
343
+ /** Overflow behaviour */
344
+ overflow?: "wrap" | "scroll";
287
345
  }
288
- /** Select displays a collapsible list of options and allows a user to select one of them. */
289
- declare function Select<T extends object>({ items, sections, label, description, placeholder, size, errorMessage, ...props }: SelectProps<T>): react_jsx_runtime.JSX.Element;
346
+ /** Select displays a collapsible list of options and allows a user to select one or more of them. */
347
+ declare function Select<T extends object, M extends "single" | "multiple" = "single">({ items, sections, label, description, placeholder, size, errorMessage, selectionMode, overflow, ...props }: SelectProps<T, M>): react.JSX.Element;
290
348
 
291
349
  interface SeparatorProps extends SeparatorProps$1 {
292
350
  size?: "small" | "medium" | "large";
293
351
  }
294
- declare function Separator({ size, ...props }: SeparatorProps): react_jsx_runtime.JSX.Element;
352
+ declare function Separator({ size, ...props }: SeparatorProps): react.JSX.Element;
295
353
 
296
354
  declare function SvgBcLogo({ id }: {
297
355
  id?: string | undefined;
298
- }): react_jsx_runtime.JSX.Element;
356
+ }): react.JSX.Element;
299
357
 
300
358
  declare function SvgBcOutlineIcon({ id }: {
301
359
  id?: string | undefined;
302
- }): react_jsx_runtime.JSX.Element;
360
+ }): react.JSX.Element;
303
361
 
304
362
  declare function SvgBetaIcon({ id }: {
305
363
  id?: string | undefined;
306
- }): react_jsx_runtime.JSX.Element;
364
+ }): react.JSX.Element;
307
365
 
308
366
  declare function SvgCalendarIcon({ ...props }: {
309
367
  [x: string]: any;
310
- }): react_jsx_runtime.JSX.Element;
368
+ }): react.JSX.Element;
311
369
 
312
370
  declare function SvgCheckIcon({ id }: {
313
371
  id?: string | undefined;
314
- }): react_jsx_runtime.JSX.Element;
372
+ }): react.JSX.Element;
315
373
 
316
374
  declare function SvgCheckCircleIcon({ id }: {
317
375
  id?: string | undefined;
318
- }): react_jsx_runtime.JSX.Element;
376
+ }): react.JSX.Element;
319
377
 
320
378
  declare function SvgChevronUpIcon({ id }: {
321
379
  id?: string | undefined;
322
- }): react_jsx_runtime.JSX.Element;
380
+ }): react.JSX.Element;
323
381
 
324
382
  declare function SvgChevronDownIcon({ id }: {
325
383
  id?: string | undefined;
326
- }): react_jsx_runtime.JSX.Element;
384
+ }): react.JSX.Element;
327
385
 
328
386
  declare function SvgChevronLeftIcon({ id }: {
329
387
  id?: string | undefined;
330
- }): react_jsx_runtime.JSX.Element;
388
+ }): react.JSX.Element;
331
389
 
332
390
  declare function SvgChevronRightIcon({ id }: {
333
391
  id?: string | undefined;
334
- }): react_jsx_runtime.JSX.Element;
392
+ }): react.JSX.Element;
335
393
 
336
394
  declare function SvgDashIcon$1({ id }: {
337
395
  id?: string | undefined;
338
- }): react_jsx_runtime.JSX.Element;
396
+ }): react.JSX.Element;
339
397
 
340
398
  declare function SvgExclamationIcon({ id }: {
341
399
  id?: string | undefined;
342
- }): react_jsx_runtime.JSX.Element;
400
+ }): react.JSX.Element;
343
401
 
344
402
  declare function SvgExclamationCircleIcon({ id, }: {
345
403
  id?: string | undefined;
346
- }): react_jsx_runtime.JSX.Element;
404
+ }): react.JSX.Element;
347
405
 
348
406
  declare function SvgCloseIcon({ id }: {
349
407
  id?: string | undefined;
350
- }): react_jsx_runtime.JSX.Element;
408
+ }): react.JSX.Element;
351
409
 
352
410
  declare function SvgInfoIcon({ id }: {
353
411
  id?: string | undefined;
354
- }): react_jsx_runtime.JSX.Element;
412
+ }): react.JSX.Element;
355
413
 
356
414
  declare function SvgDashIcon({ id }: {
357
415
  id?: string | undefined;
358
- }): react_jsx_runtime.JSX.Element;
416
+ }): react.JSX.Element;
417
+
418
+ interface SvgPlaceholderIconProps {
419
+ /** Width and height of the placeholder icon, defaults to 20 */
420
+ size?: number;
421
+ }
422
+ declare function SvgPlaceholderIcon({ size, ...props }: SvgPlaceholderIconProps): react.JSX.Element;
359
423
 
360
424
  declare function SvgPlusIcon({ id }: {
361
425
  id?: string | undefined;
362
- }): react_jsx_runtime.JSX.Element;
426
+ }): react.JSX.Element;
363
427
 
364
428
  declare function SvgTooltipArrowUp({ id }: {
365
429
  id?: string | undefined;
366
- }): react_jsx_runtime.JSX.Element;
430
+ }): react.JSX.Element;
367
431
 
368
432
  interface SvgUpRightFromSquareIconProps {
369
433
  size?: 16 | 20;
370
434
  id?: string;
371
435
  }
372
- declare function SvgUpRightFromSquareIcon({ size, id, }: SvgUpRightFromSquareIconProps): react_jsx_runtime.JSX.Element;
436
+ declare function SvgUpRightFromSquareIcon({ size, id, }: SvgUpRightFromSquareIconProps): react.JSX.Element;
373
437
 
374
438
  declare function SvgReactAriaIcon({ id }: {
375
439
  id?: string | undefined;
376
- }): react_jsx_runtime.JSX.Element;
377
-
378
- interface TagProps extends TagProps$1 {
379
- /**
380
- * Icon that appears to the left of the `textValue` field
381
- */
382
- icon?: React.ReactNode;
383
- /**
384
- * Background color
385
- */
386
- color?: "bc-blue" | "bc-gold" | "blue" | "dark" | "gray" | "grey" | "green" | "red" | "yellow";
387
- /**
388
- * tagStyle
389
- */
390
- tagStyle?: "rectangular" | "circular";
391
- /**
392
- * size
393
- */
394
- size?: "small" | "medium";
395
- }
396
- declare function Tag({ color, tagStyle, size, icon, id, textValue, }: TagProps): react_jsx_runtime.JSX.Element;
440
+ }): react.JSX.Element;
397
441
 
398
442
  interface TagGroupProps extends TagGroupProps$1 {
399
443
  /**
@@ -409,7 +453,7 @@ interface TagGroupProps extends TagGroupProps$1 {
409
453
  */
410
454
  errorMessage?: string;
411
455
  }
412
- declare function TagGroup({ children, label, description, errorMessage, ...props }: TagGroupProps): react_jsx_runtime.JSX.Element;
456
+ declare function TagGroup({ children, label, description, errorMessage, ...props }: TagGroupProps): react.JSX.Element;
413
457
 
414
458
  interface TagListProps<T> extends Pick<TagListProps$1<T>, "children" | "renderEmptyState"> {
415
459
  items: TagProps[];
@@ -418,21 +462,21 @@ interface TagListProps<T> extends Pick<TagListProps$1<T>, "children" | "renderEm
418
462
  */
419
463
  orientation?: "horizontal" | "vertical";
420
464
  }
421
- declare function TagList<T extends object>({ items, orientation, renderEmptyState, ...props }: TagListProps<T>): react_jsx_runtime.JSX.Element;
465
+ declare function TagList<T extends object>({ items, orientation, renderEmptyState, ...props }: TagListProps<T>): react.JSX.Element;
422
466
 
423
467
  interface TextProps extends TextProps$1 {
424
468
  size?: "small" | "medium" | "large";
425
469
  color?: "primary" | "primaryInvert" | "secondary" | "secondaryInvert" | "disabled" | "danger";
426
470
  isUnstyled?: boolean;
427
471
  }
428
- declare function Text({ elementType, size, color, isUnstyled, ...props }: TextProps): react_jsx_runtime.JSX.Element;
472
+ declare function Text({ elementType, size, color, isUnstyled, ...props }: TextProps): react.JSX.Element;
429
473
 
430
474
  interface TextAreaProps extends TextFieldProps$1 {
431
475
  label?: string;
432
476
  description?: string;
433
477
  errorMessage?: string | ((validation: ValidationResult) => string);
434
478
  }
435
- declare function TextArea({ label, description, errorMessage, maxLength, onChange, value, ...props }: TextAreaProps): react_jsx_runtime.JSX.Element;
479
+ declare function TextArea({ label, description, errorMessage, maxLength, onChange, value, ...props }: TextAreaProps): react.JSX.Element;
436
480
 
437
481
  interface TextFieldProps extends TextFieldProps$1 {
438
482
  size?: "medium" | "small";
@@ -442,7 +486,7 @@ interface TextFieldProps extends TextFieldProps$1 {
442
486
  iconLeft?: React.ReactElement;
443
487
  iconRight?: React.ReactElement;
444
488
  }
445
- declare function TextField({ size, label, description, errorMessage, iconLeft, iconRight, ...props }: TextFieldProps): react_jsx_runtime.JSX.Element;
489
+ declare function TextField({ size, label, description, errorMessage, iconLeft, iconRight, ...props }: TextFieldProps): react.JSX.Element;
446
490
 
447
491
  interface TimeFieldProps<T extends TimeValue> extends TimeFieldProps$1<T> {
448
492
  size?: "medium" | "small";
@@ -450,26 +494,26 @@ interface TimeFieldProps<T extends TimeValue> extends TimeFieldProps$1<T> {
450
494
  description?: string;
451
495
  errorMessage?: string | ((validation: ValidationResult) => string);
452
496
  }
453
- declare function TimeField<T extends TimeValue>({ size, label, description, errorMessage, isRequired, ...props }: TimeFieldProps<T>): react_jsx_runtime.JSX.Element;
497
+ declare function TimeField<T extends TimeValue>({ size, label, description, errorMessage, isRequired, ...props }: TimeFieldProps<T>): react.JSX.Element;
454
498
 
455
499
  interface ToggleButtonProps extends ToggleButtonProps$1 {
456
500
  size?: "small" | "medium";
457
501
  isIconButton?: boolean;
458
502
  }
459
- declare function ToggleButton({ size, children, isIconButton, ...props }: ToggleButtonProps): react_jsx_runtime.JSX.Element;
503
+ declare function ToggleButton({ size, children, isIconButton, ...props }: ToggleButtonProps): react.JSX.Element;
460
504
 
461
505
  interface ToggleButtonGroupProps extends ToggleButtonGroupProps$1 {
462
506
  label?: string;
463
507
  size?: "small" | "medium";
464
508
  }
465
- declare function ToggleButtonGroup({ label, size, children, ...props }: ToggleButtonGroupProps): react_jsx_runtime.JSX.Element;
509
+ declare function ToggleButtonGroup({ label, size, children, ...props }: ToggleButtonGroupProps): react.JSX.Element;
466
510
 
467
511
  interface SwitchProps extends SwitchProps$1 {
468
512
  labelPosition?: "left" | "right";
469
513
  }
470
- declare function Switch({ labelPosition, children, ...props }: SwitchProps): react_jsx_runtime.JSX.Element;
514
+ declare function Switch({ labelPosition, children, ...props }: SwitchProps): react.JSX.Element;
471
515
 
472
- declare function Tooltip(props: TooltipProps): react_jsx_runtime.JSX.Element;
516
+ declare function Tooltip(props: TooltipProps): react.JSX.Element;
473
517
 
474
518
  interface NumberFieldProps extends NumberFieldProps$1 {
475
519
  size?: "small" | "medium";
@@ -477,6 +521,6 @@ interface NumberFieldProps extends NumberFieldProps$1 {
477
521
  description?: string;
478
522
  errorMessage?: string | ((validation: ValidationResult) => string);
479
523
  }
480
- declare function NumberField({ size, label, description, errorMessage, ...props }: NumberFieldProps): react_jsx_runtime.JSX.Element;
524
+ declare function NumberField({ size, label, description, errorMessage, ...props }: NumberFieldProps): react.JSX.Element;
481
525
 
482
- export { Accordion, AccordionGroup, AlertBanner, AlertDialog, Button, ButtonGroup, Calendar, Callout, Checkbox, CheckboxGroup, DatePicker, Dialog, Footer, FooterLinks, Form, Header, Heading, InlineAlert, Link, Modal, NumberField, ProgressBar, ProgressCircle, Radio, RadioGroup, Select, Separator, SvgBcLogo, SvgBcOutlineIcon, SvgBetaIcon, SvgCalendarIcon, SvgCheckCircleIcon, SvgCheckIcon, SvgChevronDownIcon, SvgChevronLeftIcon, SvgChevronRightIcon, SvgChevronUpIcon, SvgCloseIcon, SvgDashIcon$1 as SvgDashIcon, SvgExclamationCircleIcon, SvgExclamationIcon, SvgInfoIcon, SvgDashIcon as SvgMinusIcon, SvgPlusIcon, SvgReactAriaIcon, SvgTooltipArrowUp, SvgUpRightFromSquareIcon, Switch, Tag, TagGroup, TagList, Text, TextArea, TextField, TimeField, ToggleButton, ToggleButtonGroup, Tooltip };
526
+ export { Accordion, AccordionGroup, AlertBanner, AlertDialog, Button, ButtonGroup, Calendar, Callout, Checkbox, CheckboxGroup, DatePicker, Dialog, Footer, FooterLinks, Form, Header, Heading, InlineAlert, Link, Menu, MenuItem, Modal, NumberField, ProgressBar, ProgressCircle, Radio, RadioGroup, Select, Separator, Subheader, SvgBcLogo, SvgBcOutlineIcon, SvgBetaIcon, SvgCalendarIcon, SvgCheckCircleIcon, SvgCheckIcon, SvgChevronDownIcon, SvgChevronLeftIcon, SvgChevronRightIcon, SvgChevronUpIcon, SvgCloseIcon, SvgDashIcon$1 as SvgDashIcon, SvgExclamationCircleIcon, SvgExclamationIcon, SvgInfoIcon, SvgDashIcon as SvgMinusIcon, SvgPlaceholderIcon, SvgPlusIcon, SvgReactAriaIcon, SvgTooltipArrowUp, SvgUpRightFromSquareIcon, Switch, Tag, TagGroup, TagList, Text, TextArea, TextField, TimeField, ToggleButton, ToggleButtonGroup, Tooltip };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bcgov/design-system-react-components",
3
- "version": "0.7.0",
3
+ "version": "0.8.0",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/bcgov/design-system.git",
@@ -42,8 +42,10 @@
42
42
  "dist/cjs"
43
43
  ],
44
44
  "dependencies": {
45
- "@bcgov/design-tokens": "3.2.0",
46
- "react-aria-components": "1.16.0"
45
+ "@bcgov/design-tokens": "5.0.0",
46
+ "@react-aria/datepicker": "3.17.1",
47
+ "@react-aria/i18n": "3.13.1",
48
+ "react-aria-components": "1.17.0"
47
49
  },
48
50
  "peerDependencies": {
49
51
  "@bcgov/bc-sans": "^2.1.0",
@@ -51,48 +53,56 @@
51
53
  "react-dom": "^16.14.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0"
52
54
  },
53
55
  "devDependencies": {
54
- "@react-stately/data": "3.15.0",
55
- "@rollup/plugin-commonjs": "29.0.0",
56
+ "@eslint/js": "10.0.1",
57
+ "@figma/code-connect": "1.4.8",
58
+ "@react-stately/data": "3.16.1",
59
+ "@rollup/plugin-commonjs": "29.0.3",
56
60
  "@rollup/plugin-json": "6.1.0",
57
61
  "@rollup/plugin-node-resolve": "16.0.3",
58
62
  "@rollup/plugin-typescript": "12.3.0",
59
- "@storybook/addon-a11y": "10.3.3",
60
- "@storybook/addon-docs": "10.3.3",
61
- "@storybook/addon-links": "10.3.3",
62
- "@storybook/addon-vitest": "10.3.3",
63
- "@storybook/react-vite": "10.3.3",
63
+ "@storybook/addon-a11y": "10.4.6",
64
+ "@storybook/addon-docs": "10.4.6",
65
+ "@storybook/addon-links": "10.4.6",
66
+ "@storybook/addon-vitest": "10.4.6",
67
+ "@storybook/react-vite": "10.4.6",
64
68
  "@testing-library/jest-dom": "6.9.1",
65
- "@testing-library/react": "16.3.1",
66
- "@types/react": "19.2.7",
69
+ "@testing-library/react": "16.3.2",
70
+ "@types/node": "25.9.3",
71
+ "@types/react": "19.2.17",
67
72
  "@types/react-dom": "19.2.3",
68
- "@typescript-eslint/eslint-plugin": "8.50.1",
69
- "@typescript-eslint/parser": "8.50.1",
70
- "@vitejs/plugin-react": "5.1.2",
71
- "@vitest/browser-playwright": "4.0.14",
72
- "@vitest/coverage-v8": "4.0.14",
73
+ "@typescript-eslint/eslint-plugin": "8.61.0",
74
+ "@typescript-eslint/parser": "8.61.0",
75
+ "@vitejs/plugin-react": "6.0.2",
76
+ "@vitest/browser-playwright": "4.1.9",
77
+ "@vitest/coverage-v8": "4.1.9",
73
78
  "axe-playwright": "2.2.2",
74
- "eslint": "9.39.2",
75
- "eslint-plugin-react-hooks": "7.0.1",
76
- "eslint-plugin-react-refresh": "0.4.26",
77
- "eslint-plugin-storybook": "10.3.3",
78
- "globals": "16.5.0",
79
- "jsdom": "27.4.0",
80
- "playwright": "1.57.0",
81
- "prettier": "3.8.1",
82
- "rollup": "4.60.1",
79
+ "eslint": "10.5.0",
80
+ "eslint-plugin-react-hooks": "7.1.1",
81
+ "eslint-plugin-react-refresh": "0.5.3",
82
+ "eslint-plugin-storybook": "10.4.6",
83
+ "globals": "17.6.0",
84
+ "jsdom": "29.1.1",
85
+ "playwright": "1.61.0",
86
+ "prettier": "3.8.4",
87
+ "rollup": "4.62.0",
83
88
  "rollup-plugin-dts": "6.4.1",
84
89
  "rollup-plugin-peer-deps-external": "2.2.4",
85
90
  "rollup-plugin-postcss": "4.0.2",
86
- "storybook": "10.3.3",
91
+ "storybook": "10.4.6",
87
92
  "tslib": "2.8.1",
88
- "typescript": "5.9.3",
89
- "typescript-eslint": "8.50.1",
90
- "vite": "7.3.0",
91
- "vitest": "4.0.14"
93
+ "typescript": "6.0.3",
94
+ "typescript-eslint": "8.61.0",
95
+ "vite": "8.0.16",
96
+ "vitest": "4.1.9"
92
97
  },
93
98
  "optionalDependencies": {
94
99
  "@rollup/rollup-linux-x64-gnu": "*"
95
100
  },
101
+ "overrides": {
102
+ "eslint-plugin-react-hooks": {
103
+ "zod-validation-error": "^4.0.0"
104
+ }
105
+ },
96
106
  "author": "Tyler Krys <Tyler.Krys@gov.bc.ca>",
97
107
  "license": "Apache-2.0",
98
108
  "bugs": {