@wistia/ui 0.10.3 → 0.10.4-beta.36362cd1.2b96fcb
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.cjs +26 -7
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +16 -2
- package/dist/index.d.ts +16 -2
- package/dist/index.mjs +25 -7
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -550,6 +550,7 @@ declare const Avatar: {
|
|
|
550
550
|
displayName: string;
|
|
551
551
|
};
|
|
552
552
|
|
|
553
|
+
type BadgeVariants = 'default' | 'outline';
|
|
553
554
|
type BadgeProps = ComponentPropsWithoutRef<'div'> & {
|
|
554
555
|
/**
|
|
555
556
|
* Sets the [color scheme](../?path=/docs/docs-color-schemes--docs)
|
|
@@ -563,6 +564,10 @@ type BadgeProps = ComponentPropsWithoutRef<'div'> & {
|
|
|
563
564
|
* The text to display in the `Badge`
|
|
564
565
|
*/
|
|
565
566
|
label: ReactNode;
|
|
567
|
+
/**
|
|
568
|
+
* The variant of the `Badge`
|
|
569
|
+
*/
|
|
570
|
+
variant?: BadgeVariants;
|
|
566
571
|
};
|
|
567
572
|
/**
|
|
568
573
|
* A `Badge` is a compact label, with optional icon, to convey status or context.
|
|
@@ -580,6 +585,10 @@ declare const Badge: react.ForwardRefExoticComponent<Omit<react.DetailedHTMLProp
|
|
|
580
585
|
* The text to display in the `Badge`
|
|
581
586
|
*/
|
|
582
587
|
label: ReactNode;
|
|
588
|
+
/**
|
|
589
|
+
* The variant of the `Badge`
|
|
590
|
+
*/
|
|
591
|
+
variant?: BadgeVariants;
|
|
583
592
|
} & react.RefAttributes<HTMLDivElement>>;
|
|
584
593
|
|
|
585
594
|
type UnknownRecord = Record<string, unknown>;
|
|
@@ -3303,6 +3312,11 @@ declare const List: {
|
|
|
3303
3312
|
displayName: string;
|
|
3304
3313
|
};
|
|
3305
3314
|
|
|
3315
|
+
type ComboboxOptionProps = {
|
|
3316
|
+
value: string;
|
|
3317
|
+
children: ReactNode;
|
|
3318
|
+
};
|
|
3319
|
+
declare const ComboboxOption: ({ value, children }: ComboboxOptionProps) => react_jsx_runtime.JSX.Element;
|
|
3306
3320
|
type ComboboxProps = {
|
|
3307
3321
|
/**
|
|
3308
3322
|
* If true, the combox will fill the width of its parent
|
|
@@ -3325,7 +3339,7 @@ type ComboboxProps = {
|
|
|
3325
3339
|
*/
|
|
3326
3340
|
searchValue: string;
|
|
3327
3341
|
/**
|
|
3328
|
-
*
|
|
3342
|
+
* Callback that fires when a value is selected
|
|
3329
3343
|
*/
|
|
3330
3344
|
onChange: (value: string[]) => void;
|
|
3331
3345
|
/**
|
|
@@ -3335,4 +3349,4 @@ type ComboboxProps = {
|
|
|
3335
3349
|
};
|
|
3336
3350
|
declare const Combobox: ({ placeholder, value, onChange, searchValue, onSearchValueChange, children, fullWidth, }: ComboboxProps) => react_jsx_runtime.JSX.Element;
|
|
3337
3351
|
|
|
3338
|
-
export { ActionButton, type ActionButtonProps, Avatar, type AvatarProps, type AvatarStatus, Badge, type BadgeProps, Box, type BoxProps, Breadcrumb, type BreadcrumbProps, Breadcrumbs, type BreadcrumbsProps, Button, ButtonGroup, type ButtonProps, Card, type CardProps, Center, type CenterProps, Checkbox, CheckboxGroup, CheckboxMenuItem, ClickRegion, type ClickRegionProps, Collapsible, CollapsibleContent, type CollapsibleProps, CollapsibleTrigger, type ColorSchemeTypes, ColorSchemeWrapper, type ColorSchemeWrapperProps, Combobox, type ComboboxProps, DataCard, type DataCardProps, DataCardTrend, type DataCardTrendProps, DataCards, type DataCardsProps, Divider, EditableHeading, type EditableHeadingProps, Ellipsis, type EllipsisProps, Form, FormErrorSummary, FormField, type FormFieldProps, FormGroup, type FormGroupProps, type FormProps, Heading, type HeadingProps, Icon, IconButton, type IconButtonProps, type IconNameType, Image, type ImageProps, Input, InputClickToCopy, type InputClickToCopyProps, type InputProps, type KeyboardKeys, KeyboardShortcut, Label, type LabelProps, Link, type LinkProps, List, type ListProps, Menu, MenuItem, MenuItemDescription, MenuItemLabel, MenuLabel, MenuRadioGroup, Modal, type ModalProps, Popover, type PopoverProps, ProgressBar, type ProgressBarProps, Radio, RadioGroup, RadioMenuItem, type RadioProps, ScreenReaderOnly, SegmentedControl, SegmentedControlItem, type SegmentedControlItemProps, type SegmentedControlProps, Select, SelectOption, SelectOptionGroup, type SelectOptionGroupProps, type SelectOptionProps, type SelectProps, Stack, SubMenu, Switch, type SwitchProps, Table, TableBody, type TableBodyProps, TableCell, type TableCellProps, TableFoot, type TableFootProps, TableHead, type TableHeadProps, type TableProps, TableRow, type TableRowProps, Tabs, TabsContent, TabsList, TabsTrigger, Tag, type TagProps, Text, type TextProps, Thumbnail, ThumbnailBadge, type ThumbnailBadgeProps, ThumbnailCollage, type ThumbnailCollageProps, type ThumbnailProps, Tooltip, type TooltipProps, UIProvider, type UseToastProps, WistiaLogo, colorSchemeOptions, copyToClipboard, dateTime, iconSizeMap, mergeRefs, mq, useActiveMq, useAriaLive, useBoolean, useClipboard, useElementObserver, useFocusTrap, useForceUpdate, useFormState, useIsHovered, useKey, useLocalStorage, useLockBodyScroll, useMq, useOnClickOutside, usePreviousValue, useToast, useWindowSize };
|
|
3352
|
+
export { ActionButton, type ActionButtonProps, Avatar, type AvatarProps, type AvatarStatus, Badge, type BadgeProps, Box, type BoxProps, Breadcrumb, type BreadcrumbProps, Breadcrumbs, type BreadcrumbsProps, Button, ButtonGroup, type ButtonProps, Card, type CardProps, Center, type CenterProps, Checkbox, CheckboxGroup, CheckboxMenuItem, ClickRegion, type ClickRegionProps, Collapsible, CollapsibleContent, type CollapsibleProps, CollapsibleTrigger, type ColorSchemeTypes, ColorSchemeWrapper, type ColorSchemeWrapperProps, Combobox, ComboboxOption, type ComboboxOptionProps, type ComboboxProps, DataCard, type DataCardProps, DataCardTrend, type DataCardTrendProps, DataCards, type DataCardsProps, Divider, EditableHeading, type EditableHeadingProps, Ellipsis, type EllipsisProps, Form, FormErrorSummary, FormField, type FormFieldProps, FormGroup, type FormGroupProps, type FormProps, Heading, type HeadingProps, Icon, IconButton, type IconButtonProps, type IconNameType, Image, type ImageProps, Input, InputClickToCopy, type InputClickToCopyProps, type InputProps, type KeyboardKeys, KeyboardShortcut, Label, type LabelProps, Link, type LinkProps, List, type ListProps, Menu, MenuItem, MenuItemDescription, MenuItemLabel, MenuLabel, MenuRadioGroup, Modal, type ModalProps, Popover, type PopoverProps, ProgressBar, type ProgressBarProps, Radio, RadioGroup, RadioMenuItem, type RadioProps, ScreenReaderOnly, SegmentedControl, SegmentedControlItem, type SegmentedControlItemProps, type SegmentedControlProps, Select, SelectOption, SelectOptionGroup, type SelectOptionGroupProps, type SelectOptionProps, type SelectProps, Stack, SubMenu, Switch, type SwitchProps, Table, TableBody, type TableBodyProps, TableCell, type TableCellProps, TableFoot, type TableFootProps, TableHead, type TableHeadProps, type TableProps, TableRow, type TableRowProps, Tabs, TabsContent, TabsList, TabsTrigger, Tag, type TagProps, Text, type TextProps, Thumbnail, ThumbnailBadge, type ThumbnailBadgeProps, ThumbnailCollage, type ThumbnailCollageProps, type ThumbnailProps, Tooltip, type TooltipProps, UIProvider, type UseToastProps, WistiaLogo, colorSchemeOptions, copyToClipboard, dateTime, iconSizeMap, mergeRefs, mq, useActiveMq, useAriaLive, useBoolean, useClipboard, useElementObserver, useFocusTrap, useForceUpdate, useFormState, useIsHovered, useKey, useLocalStorage, useLockBodyScroll, useMq, useOnClickOutside, usePreviousValue, useToast, useWindowSize };
|
package/dist/index.d.ts
CHANGED
|
@@ -550,6 +550,7 @@ declare const Avatar: {
|
|
|
550
550
|
displayName: string;
|
|
551
551
|
};
|
|
552
552
|
|
|
553
|
+
type BadgeVariants = 'default' | 'outline';
|
|
553
554
|
type BadgeProps = ComponentPropsWithoutRef<'div'> & {
|
|
554
555
|
/**
|
|
555
556
|
* Sets the [color scheme](../?path=/docs/docs-color-schemes--docs)
|
|
@@ -563,6 +564,10 @@ type BadgeProps = ComponentPropsWithoutRef<'div'> & {
|
|
|
563
564
|
* The text to display in the `Badge`
|
|
564
565
|
*/
|
|
565
566
|
label: ReactNode;
|
|
567
|
+
/**
|
|
568
|
+
* The variant of the `Badge`
|
|
569
|
+
*/
|
|
570
|
+
variant?: BadgeVariants;
|
|
566
571
|
};
|
|
567
572
|
/**
|
|
568
573
|
* A `Badge` is a compact label, with optional icon, to convey status or context.
|
|
@@ -580,6 +585,10 @@ declare const Badge: react.ForwardRefExoticComponent<Omit<react.DetailedHTMLProp
|
|
|
580
585
|
* The text to display in the `Badge`
|
|
581
586
|
*/
|
|
582
587
|
label: ReactNode;
|
|
588
|
+
/**
|
|
589
|
+
* The variant of the `Badge`
|
|
590
|
+
*/
|
|
591
|
+
variant?: BadgeVariants;
|
|
583
592
|
} & react.RefAttributes<HTMLDivElement>>;
|
|
584
593
|
|
|
585
594
|
type UnknownRecord = Record<string, unknown>;
|
|
@@ -3303,6 +3312,11 @@ declare const List: {
|
|
|
3303
3312
|
displayName: string;
|
|
3304
3313
|
};
|
|
3305
3314
|
|
|
3315
|
+
type ComboboxOptionProps = {
|
|
3316
|
+
value: string;
|
|
3317
|
+
children: ReactNode;
|
|
3318
|
+
};
|
|
3319
|
+
declare const ComboboxOption: ({ value, children }: ComboboxOptionProps) => react_jsx_runtime.JSX.Element;
|
|
3306
3320
|
type ComboboxProps = {
|
|
3307
3321
|
/**
|
|
3308
3322
|
* If true, the combox will fill the width of its parent
|
|
@@ -3325,7 +3339,7 @@ type ComboboxProps = {
|
|
|
3325
3339
|
*/
|
|
3326
3340
|
searchValue: string;
|
|
3327
3341
|
/**
|
|
3328
|
-
*
|
|
3342
|
+
* Callback that fires when a value is selected
|
|
3329
3343
|
*/
|
|
3330
3344
|
onChange: (value: string[]) => void;
|
|
3331
3345
|
/**
|
|
@@ -3335,4 +3349,4 @@ type ComboboxProps = {
|
|
|
3335
3349
|
};
|
|
3336
3350
|
declare const Combobox: ({ placeholder, value, onChange, searchValue, onSearchValueChange, children, fullWidth, }: ComboboxProps) => react_jsx_runtime.JSX.Element;
|
|
3337
3351
|
|
|
3338
|
-
export { ActionButton, type ActionButtonProps, Avatar, type AvatarProps, type AvatarStatus, Badge, type BadgeProps, Box, type BoxProps, Breadcrumb, type BreadcrumbProps, Breadcrumbs, type BreadcrumbsProps, Button, ButtonGroup, type ButtonProps, Card, type CardProps, Center, type CenterProps, Checkbox, CheckboxGroup, CheckboxMenuItem, ClickRegion, type ClickRegionProps, Collapsible, CollapsibleContent, type CollapsibleProps, CollapsibleTrigger, type ColorSchemeTypes, ColorSchemeWrapper, type ColorSchemeWrapperProps, Combobox, type ComboboxProps, DataCard, type DataCardProps, DataCardTrend, type DataCardTrendProps, DataCards, type DataCardsProps, Divider, EditableHeading, type EditableHeadingProps, Ellipsis, type EllipsisProps, Form, FormErrorSummary, FormField, type FormFieldProps, FormGroup, type FormGroupProps, type FormProps, Heading, type HeadingProps, Icon, IconButton, type IconButtonProps, type IconNameType, Image, type ImageProps, Input, InputClickToCopy, type InputClickToCopyProps, type InputProps, type KeyboardKeys, KeyboardShortcut, Label, type LabelProps, Link, type LinkProps, List, type ListProps, Menu, MenuItem, MenuItemDescription, MenuItemLabel, MenuLabel, MenuRadioGroup, Modal, type ModalProps, Popover, type PopoverProps, ProgressBar, type ProgressBarProps, Radio, RadioGroup, RadioMenuItem, type RadioProps, ScreenReaderOnly, SegmentedControl, SegmentedControlItem, type SegmentedControlItemProps, type SegmentedControlProps, Select, SelectOption, SelectOptionGroup, type SelectOptionGroupProps, type SelectOptionProps, type SelectProps, Stack, SubMenu, Switch, type SwitchProps, Table, TableBody, type TableBodyProps, TableCell, type TableCellProps, TableFoot, type TableFootProps, TableHead, type TableHeadProps, type TableProps, TableRow, type TableRowProps, Tabs, TabsContent, TabsList, TabsTrigger, Tag, type TagProps, Text, type TextProps, Thumbnail, ThumbnailBadge, type ThumbnailBadgeProps, ThumbnailCollage, type ThumbnailCollageProps, type ThumbnailProps, Tooltip, type TooltipProps, UIProvider, type UseToastProps, WistiaLogo, colorSchemeOptions, copyToClipboard, dateTime, iconSizeMap, mergeRefs, mq, useActiveMq, useAriaLive, useBoolean, useClipboard, useElementObserver, useFocusTrap, useForceUpdate, useFormState, useIsHovered, useKey, useLocalStorage, useLockBodyScroll, useMq, useOnClickOutside, usePreviousValue, useToast, useWindowSize };
|
|
3352
|
+
export { ActionButton, type ActionButtonProps, Avatar, type AvatarProps, type AvatarStatus, Badge, type BadgeProps, Box, type BoxProps, Breadcrumb, type BreadcrumbProps, Breadcrumbs, type BreadcrumbsProps, Button, ButtonGroup, type ButtonProps, Card, type CardProps, Center, type CenterProps, Checkbox, CheckboxGroup, CheckboxMenuItem, ClickRegion, type ClickRegionProps, Collapsible, CollapsibleContent, type CollapsibleProps, CollapsibleTrigger, type ColorSchemeTypes, ColorSchemeWrapper, type ColorSchemeWrapperProps, Combobox, ComboboxOption, type ComboboxOptionProps, type ComboboxProps, DataCard, type DataCardProps, DataCardTrend, type DataCardTrendProps, DataCards, type DataCardsProps, Divider, EditableHeading, type EditableHeadingProps, Ellipsis, type EllipsisProps, Form, FormErrorSummary, FormField, type FormFieldProps, FormGroup, type FormGroupProps, type FormProps, Heading, type HeadingProps, Icon, IconButton, type IconButtonProps, type IconNameType, Image, type ImageProps, Input, InputClickToCopy, type InputClickToCopyProps, type InputProps, type KeyboardKeys, KeyboardShortcut, Label, type LabelProps, Link, type LinkProps, List, type ListProps, Menu, MenuItem, MenuItemDescription, MenuItemLabel, MenuLabel, MenuRadioGroup, Modal, type ModalProps, Popover, type PopoverProps, ProgressBar, type ProgressBarProps, Radio, RadioGroup, RadioMenuItem, type RadioProps, ScreenReaderOnly, SegmentedControl, SegmentedControlItem, type SegmentedControlItemProps, type SegmentedControlProps, Select, SelectOption, SelectOptionGroup, type SelectOptionGroupProps, type SelectOptionProps, type SelectProps, Stack, SubMenu, Switch, type SwitchProps, Table, TableBody, type TableBodyProps, TableCell, type TableCellProps, TableFoot, type TableFootProps, TableHead, type TableHeadProps, type TableProps, TableRow, type TableRowProps, Tabs, TabsContent, TabsList, TabsTrigger, Tag, type TagProps, Text, type TextProps, Thumbnail, ThumbnailBadge, type ThumbnailBadgeProps, ThumbnailCollage, type ThumbnailCollageProps, type ThumbnailProps, Tooltip, type TooltipProps, UIProvider, type UseToastProps, WistiaLogo, colorSchemeOptions, copyToClipboard, dateTime, iconSizeMap, mergeRefs, mq, useActiveMq, useAriaLive, useBoolean, useClipboard, useElementObserver, useFocusTrap, useForceUpdate, useFormState, useIsHovered, useKey, useLocalStorage, useLockBodyScroll, useMq, useOnClickOutside, usePreviousValue, useToast, useWindowSize };
|
package/dist/index.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
2
|
/*
|
|
3
|
-
* @license @wistia/ui v0.10.
|
|
3
|
+
* @license @wistia/ui v0.10.4-beta.36362cd1.2b96fcb
|
|
4
4
|
*
|
|
5
5
|
* Copyright (c) 2024-2025, Wistia, Inc. and its affiliates.
|
|
6
6
|
*
|
|
@@ -7691,6 +7691,7 @@ var StyledBadge = styled10.div`
|
|
|
7691
7691
|
${({ $colorScheme }) => getColorScheme($colorScheme)};
|
|
7692
7692
|
align-items: center;
|
|
7693
7693
|
background-color: var(--wui-color-bg-surface-secondary);
|
|
7694
|
+
box-shadow: ${({ $variant }) => $variant === "outline" ? "inset 0 0 0 1px var(--wui-color-border)" : "none"};
|
|
7694
7695
|
border-radius: var(--wui-border-radius-rounded);
|
|
7695
7696
|
color: var(--wui-color-text);
|
|
7696
7697
|
display: inline-flex;
|
|
@@ -7698,17 +7699,21 @@ var StyledBadge = styled10.div`
|
|
|
7698
7699
|
font-weight: var(--wui-typography-label-4-weight);
|
|
7699
7700
|
gap: var(--wui-space-01);
|
|
7700
7701
|
justify-content: center;
|
|
7702
|
+
line-height: var(--wui-typography-label-3-line-height);
|
|
7701
7703
|
padding: var(--wui-space-01) var(--wui-space-02);
|
|
7702
7704
|
width: fit-content;
|
|
7703
7705
|
|
|
7704
|
-
/* Icon component size */
|
|
7705
|
-
|
|
7706
|
-
|
|
7707
|
-
|
|
7706
|
+
/* Icon component size and color */
|
|
7707
|
+
&& {
|
|
7708
|
+
svg {
|
|
7709
|
+
color: var(--wui-color-icon);
|
|
7710
|
+
height: 12px;
|
|
7711
|
+
width: 12px;
|
|
7712
|
+
}
|
|
7708
7713
|
}
|
|
7709
7714
|
`;
|
|
7710
7715
|
var Badge = forwardRef4(
|
|
7711
|
-
({ colorScheme = "inherit", label, icon, ...props }, ref) => {
|
|
7716
|
+
({ colorScheme = "inherit", label, icon, variant = "default", ...props }, ref) => {
|
|
7712
7717
|
const hasIcon = isNotNil9(icon);
|
|
7713
7718
|
return /* @__PURE__ */ jsxs11(
|
|
7714
7719
|
StyledBadge,
|
|
@@ -7717,6 +7722,7 @@ var Badge = forwardRef4(
|
|
|
7717
7722
|
...props,
|
|
7718
7723
|
$colorScheme: colorScheme,
|
|
7719
7724
|
$hasIcon: hasIcon,
|
|
7725
|
+
$variant: variant,
|
|
7720
7726
|
children: [
|
|
7721
7727
|
hasIcon ? icon : null,
|
|
7722
7728
|
/* @__PURE__ */ jsx200("span", { children: label })
|
|
@@ -9773,7 +9779,6 @@ var StyledForm = styled34.form`
|
|
|
9773
9779
|
--form-default-width: 690px;
|
|
9774
9780
|
|
|
9775
9781
|
max-width: ${({ $fullWidth }) => $fullWidth ? "auto" : "var(--form-default-width)"};
|
|
9776
|
-
align-items: ${({ $fullWidth }) => $fullWidth ? "stretch" : "flex-start"};
|
|
9777
9782
|
`;
|
|
9778
9783
|
var FormContext = createContext4({
|
|
9779
9784
|
values: {},
|
|
@@ -9854,6 +9859,7 @@ var FormComponent = ({
|
|
|
9854
9859
|
...props,
|
|
9855
9860
|
ref,
|
|
9856
9861
|
$fullWidth: fullWidth,
|
|
9862
|
+
alignItems: fullWidth ? "stretch" : "flex-start",
|
|
9857
9863
|
as: StyledForm,
|
|
9858
9864
|
gap: "space-05",
|
|
9859
9865
|
id,
|
|
@@ -13730,6 +13736,17 @@ var NoResults = styled78.div`
|
|
|
13730
13736
|
gap: var(--wui-space-02);
|
|
13731
13737
|
`;
|
|
13732
13738
|
var POPOVER_WIDTH_OFFSET = 20;
|
|
13739
|
+
var ComboboxOption = ({ value, children }) => {
|
|
13740
|
+
return /* @__PURE__ */ jsx277(
|
|
13741
|
+
ComboboxItem2,
|
|
13742
|
+
{
|
|
13743
|
+
className: "combobox-item",
|
|
13744
|
+
focusOnHover: true,
|
|
13745
|
+
value,
|
|
13746
|
+
children
|
|
13747
|
+
}
|
|
13748
|
+
);
|
|
13749
|
+
};
|
|
13733
13750
|
var extractOptions = (children) => {
|
|
13734
13751
|
const options = {};
|
|
13735
13752
|
Children6.forEach(children, (child) => {
|
|
@@ -13864,6 +13881,7 @@ export {
|
|
|
13864
13881
|
CollapsibleTrigger,
|
|
13865
13882
|
ColorSchemeWrapper,
|
|
13866
13883
|
Combobox2 as Combobox,
|
|
13884
|
+
ComboboxOption,
|
|
13867
13885
|
DataCard,
|
|
13868
13886
|
DataCardTrend,
|
|
13869
13887
|
DataCards,
|