@wistia/ui 0.0.10 → 0.0.12
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 +896 -695
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +43 -1
- package/dist/index.d.ts +43 -1
- package/dist/index.mjs +795 -595
- package/dist/index.mjs.map +1 -1
- package/package.json +16 -16
package/dist/index.d.mts
CHANGED
|
@@ -56,6 +56,39 @@ type AriaLiveContextType = {
|
|
|
56
56
|
};
|
|
57
57
|
declare const useAriaLive: () => AriaLiveContextType;
|
|
58
58
|
|
|
59
|
+
type AvatarInstanceType = 'image' | 'initials';
|
|
60
|
+
type AvatarProps = ComponentPropsWithoutRef<'div'> & {
|
|
61
|
+
/**
|
|
62
|
+
* The height and width of the avatar (overrides size prop)
|
|
63
|
+
*/
|
|
64
|
+
heightAndWidth?: number;
|
|
65
|
+
/**
|
|
66
|
+
* The URL of the image to display
|
|
67
|
+
*/
|
|
68
|
+
imageUrl?: string | null;
|
|
69
|
+
/**
|
|
70
|
+
* A string that will deterministically set the initials & background color of the avatar
|
|
71
|
+
*
|
|
72
|
+
* _note: only first initial shown regardless of characters provided_
|
|
73
|
+
*/
|
|
74
|
+
name?: string | null;
|
|
75
|
+
/**
|
|
76
|
+
* A predefined size for the avatar
|
|
77
|
+
*/
|
|
78
|
+
size?: 'lg' | 'md' | 'sm';
|
|
79
|
+
/**
|
|
80
|
+
* A callback that is invoked after the image has loaded or failed to load
|
|
81
|
+
*/
|
|
82
|
+
onImageLoad?: (avatarType: AvatarInstanceType) => void;
|
|
83
|
+
};
|
|
84
|
+
/**
|
|
85
|
+
* An avatar uses a photo, initials or icon to represent an entity
|
|
86
|
+
*/
|
|
87
|
+
declare const Avatar: {
|
|
88
|
+
({ imageUrl, heightAndWidth, name, size, onImageLoad, ...otherProps }: AvatarProps): JSX.Element;
|
|
89
|
+
displayName: string;
|
|
90
|
+
};
|
|
91
|
+
|
|
59
92
|
declare const colorSchemeOptions: readonly ["inherit", "default", "info", "success", "warning", "error", "blue", "green", "orange", "pink", "purple", "yellow"];
|
|
60
93
|
type ColorSchemeTypes = (typeof colorSchemeOptions)[number];
|
|
61
94
|
type ColorSchemeWrapperProps = ComponentPropsWithoutRef<'div'> & {
|
|
@@ -975,6 +1008,9 @@ type TextProps = ComponentPropsWithoutRef<'div'> & {
|
|
|
975
1008
|
* Text prominence affects color. Use 'highContrast' for main non-interactive text, 'vibrant' for interactive elements, and 'secondary' for less important or supplementary content.
|
|
976
1009
|
*/
|
|
977
1010
|
prominence?: keyof typeof prominenceMap;
|
|
1011
|
+
/**
|
|
1012
|
+
* This will inherit the jsdoc block from PolymorphicComponent
|
|
1013
|
+
*/
|
|
978
1014
|
renderAs?: ElementType$1;
|
|
979
1015
|
/**
|
|
980
1016
|
* The text style to display
|
|
@@ -1023,6 +1059,9 @@ declare const Text: (<C = "div">(props: PolymorphicComponentProps<C, TextProps>)
|
|
|
1023
1059
|
* Text prominence affects color. Use 'highContrast' for main non-interactive text, 'vibrant' for interactive elements, and 'secondary' for less important or supplementary content.
|
|
1024
1060
|
*/
|
|
1025
1061
|
prominence?: keyof typeof prominenceMap;
|
|
1062
|
+
/**
|
|
1063
|
+
* This will inherit the jsdoc block from PolymorphicComponent
|
|
1064
|
+
*/
|
|
1026
1065
|
renderAs?: ElementType$1;
|
|
1027
1066
|
/**
|
|
1028
1067
|
* The text style to display
|
|
@@ -1067,6 +1106,9 @@ declare const Text: (<C = "div">(props: PolymorphicComponentProps<C, TextProps>)
|
|
|
1067
1106
|
* Text prominence affects color. Use 'highContrast' for main non-interactive text, 'vibrant' for interactive elements, and 'secondary' for less important or supplementary content.
|
|
1068
1107
|
*/
|
|
1069
1108
|
prominence?: keyof typeof prominenceMap;
|
|
1109
|
+
/**
|
|
1110
|
+
* This will inherit the jsdoc block from PolymorphicComponent
|
|
1111
|
+
*/
|
|
1070
1112
|
renderAs?: ElementType$1;
|
|
1071
1113
|
/**
|
|
1072
1114
|
* The text style to display
|
|
@@ -1155,4 +1197,4 @@ declare const WistiaLogo: {
|
|
|
1155
1197
|
displayName: string;
|
|
1156
1198
|
};
|
|
1157
1199
|
|
|
1158
|
-
export { Badge, type BadgeProps, Box, type BoxProps, Button, ButtonGroup, type ButtonProps, type ColorSchemeTypes, ColorSchemeWrapper, type ColorSchemeWrapperProps, Divider, Ellipsis, Heading, type HeadingProps, Icon, IconButton, type IconButtonProps, type IconNameType, Label, type LabelProps, Link, type LinkProps, ScreenReaderOnly, Stack, Text, type TextProps, Tooltip, type TooltipProps, UIProvider, WistiaLogo, colorSchemeOptions, copyToClipboard, ellipsisFlexParentStyle, ellipsisStyle, iconSizeMap, mq, useActiveMq, useAriaLive, useMq, useWindowSize };
|
|
1200
|
+
export { Avatar, type AvatarInstanceType, type AvatarProps, Badge, type BadgeProps, Box, type BoxProps, Button, ButtonGroup, type ButtonProps, type ColorSchemeTypes, ColorSchemeWrapper, type ColorSchemeWrapperProps, Divider, Ellipsis, Heading, type HeadingProps, Icon, IconButton, type IconButtonProps, type IconNameType, Label, type LabelProps, Link, type LinkProps, ScreenReaderOnly, Stack, Text, type TextProps, Tooltip, type TooltipProps, UIProvider, WistiaLogo, colorSchemeOptions, copyToClipboard, ellipsisFlexParentStyle, ellipsisStyle, iconSizeMap, mq, useActiveMq, useAriaLive, useMq, useWindowSize };
|
package/dist/index.d.ts
CHANGED
|
@@ -56,6 +56,39 @@ type AriaLiveContextType = {
|
|
|
56
56
|
};
|
|
57
57
|
declare const useAriaLive: () => AriaLiveContextType;
|
|
58
58
|
|
|
59
|
+
type AvatarInstanceType = 'image' | 'initials';
|
|
60
|
+
type AvatarProps = ComponentPropsWithoutRef<'div'> & {
|
|
61
|
+
/**
|
|
62
|
+
* The height and width of the avatar (overrides size prop)
|
|
63
|
+
*/
|
|
64
|
+
heightAndWidth?: number;
|
|
65
|
+
/**
|
|
66
|
+
* The URL of the image to display
|
|
67
|
+
*/
|
|
68
|
+
imageUrl?: string | null;
|
|
69
|
+
/**
|
|
70
|
+
* A string that will deterministically set the initials & background color of the avatar
|
|
71
|
+
*
|
|
72
|
+
* _note: only first initial shown regardless of characters provided_
|
|
73
|
+
*/
|
|
74
|
+
name?: string | null;
|
|
75
|
+
/**
|
|
76
|
+
* A predefined size for the avatar
|
|
77
|
+
*/
|
|
78
|
+
size?: 'lg' | 'md' | 'sm';
|
|
79
|
+
/**
|
|
80
|
+
* A callback that is invoked after the image has loaded or failed to load
|
|
81
|
+
*/
|
|
82
|
+
onImageLoad?: (avatarType: AvatarInstanceType) => void;
|
|
83
|
+
};
|
|
84
|
+
/**
|
|
85
|
+
* An avatar uses a photo, initials or icon to represent an entity
|
|
86
|
+
*/
|
|
87
|
+
declare const Avatar: {
|
|
88
|
+
({ imageUrl, heightAndWidth, name, size, onImageLoad, ...otherProps }: AvatarProps): JSX.Element;
|
|
89
|
+
displayName: string;
|
|
90
|
+
};
|
|
91
|
+
|
|
59
92
|
declare const colorSchemeOptions: readonly ["inherit", "default", "info", "success", "warning", "error", "blue", "green", "orange", "pink", "purple", "yellow"];
|
|
60
93
|
type ColorSchemeTypes = (typeof colorSchemeOptions)[number];
|
|
61
94
|
type ColorSchemeWrapperProps = ComponentPropsWithoutRef<'div'> & {
|
|
@@ -975,6 +1008,9 @@ type TextProps = ComponentPropsWithoutRef<'div'> & {
|
|
|
975
1008
|
* Text prominence affects color. Use 'highContrast' for main non-interactive text, 'vibrant' for interactive elements, and 'secondary' for less important or supplementary content.
|
|
976
1009
|
*/
|
|
977
1010
|
prominence?: keyof typeof prominenceMap;
|
|
1011
|
+
/**
|
|
1012
|
+
* This will inherit the jsdoc block from PolymorphicComponent
|
|
1013
|
+
*/
|
|
978
1014
|
renderAs?: ElementType$1;
|
|
979
1015
|
/**
|
|
980
1016
|
* The text style to display
|
|
@@ -1023,6 +1059,9 @@ declare const Text: (<C = "div">(props: PolymorphicComponentProps<C, TextProps>)
|
|
|
1023
1059
|
* Text prominence affects color. Use 'highContrast' for main non-interactive text, 'vibrant' for interactive elements, and 'secondary' for less important or supplementary content.
|
|
1024
1060
|
*/
|
|
1025
1061
|
prominence?: keyof typeof prominenceMap;
|
|
1062
|
+
/**
|
|
1063
|
+
* This will inherit the jsdoc block from PolymorphicComponent
|
|
1064
|
+
*/
|
|
1026
1065
|
renderAs?: ElementType$1;
|
|
1027
1066
|
/**
|
|
1028
1067
|
* The text style to display
|
|
@@ -1067,6 +1106,9 @@ declare const Text: (<C = "div">(props: PolymorphicComponentProps<C, TextProps>)
|
|
|
1067
1106
|
* Text prominence affects color. Use 'highContrast' for main non-interactive text, 'vibrant' for interactive elements, and 'secondary' for less important or supplementary content.
|
|
1068
1107
|
*/
|
|
1069
1108
|
prominence?: keyof typeof prominenceMap;
|
|
1109
|
+
/**
|
|
1110
|
+
* This will inherit the jsdoc block from PolymorphicComponent
|
|
1111
|
+
*/
|
|
1070
1112
|
renderAs?: ElementType$1;
|
|
1071
1113
|
/**
|
|
1072
1114
|
* The text style to display
|
|
@@ -1155,4 +1197,4 @@ declare const WistiaLogo: {
|
|
|
1155
1197
|
displayName: string;
|
|
1156
1198
|
};
|
|
1157
1199
|
|
|
1158
|
-
export { Badge, type BadgeProps, Box, type BoxProps, Button, ButtonGroup, type ButtonProps, type ColorSchemeTypes, ColorSchemeWrapper, type ColorSchemeWrapperProps, Divider, Ellipsis, Heading, type HeadingProps, Icon, IconButton, type IconButtonProps, type IconNameType, Label, type LabelProps, Link, type LinkProps, ScreenReaderOnly, Stack, Text, type TextProps, Tooltip, type TooltipProps, UIProvider, WistiaLogo, colorSchemeOptions, copyToClipboard, ellipsisFlexParentStyle, ellipsisStyle, iconSizeMap, mq, useActiveMq, useAriaLive, useMq, useWindowSize };
|
|
1200
|
+
export { Avatar, type AvatarInstanceType, type AvatarProps, Badge, type BadgeProps, Box, type BoxProps, Button, ButtonGroup, type ButtonProps, type ColorSchemeTypes, ColorSchemeWrapper, type ColorSchemeWrapperProps, Divider, Ellipsis, Heading, type HeadingProps, Icon, IconButton, type IconButtonProps, type IconNameType, Label, type LabelProps, Link, type LinkProps, ScreenReaderOnly, Stack, Text, type TextProps, Tooltip, type TooltipProps, UIProvider, WistiaLogo, colorSchemeOptions, copyToClipboard, ellipsisFlexParentStyle, ellipsisStyle, iconSizeMap, mq, useActiveMq, useAriaLive, useMq, useWindowSize };
|