@prismicio/editor-ui 0.4.12 → 0.4.14

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 (167) hide show
  1. package/dist/components/ActionList/ActionList.d.ts +2 -2
  2. package/dist/components/Alert/Alert.d.ts +1 -1
  3. package/dist/components/Alert/AlertContext.d.ts +3 -3
  4. package/dist/components/Alert/index.d.ts +1 -1
  5. package/dist/components/AnimatedElement/AnimatedElement.css.d.ts +1 -0
  6. package/dist/components/AnimatedElement/AnimatedElement.d.ts +4 -4
  7. package/dist/components/AnimatedElement/index.d.ts +1 -1
  8. package/dist/components/AnimatedList/AnimatedList.d.ts +4 -4
  9. package/dist/components/AnimatedList/DragPreview.d.ts +2 -2
  10. package/dist/components/AnimatedList/autoScroll.d.ts +1 -1
  11. package/dist/components/AnimatedList/dnd.d.ts +8 -8
  12. package/dist/components/AnimatedList/layout.d.ts +1 -1
  13. package/dist/components/Avatar/Avatar.css.d.ts +3 -0
  14. package/dist/components/Avatar/Avatar.d.ts +7 -0
  15. package/dist/components/Avatar/Avatar.stories.d.ts +10 -0
  16. package/dist/components/Avatar/index.d.ts +1 -0
  17. package/dist/components/Badge/Badge.css.d.ts +2 -1
  18. package/dist/components/Badge/Badge.d.ts +6 -2
  19. package/dist/components/Badge/Badge.stories.d.ts +5 -2
  20. package/dist/components/BaseInput/BaseInput.css.d.ts +2 -1
  21. package/dist/components/BaseInput/BaseInput.d.ts +5 -1
  22. package/dist/components/BlankSlate/BlankSlate.css.d.ts +1 -0
  23. package/dist/components/BlankSlate/BlankSlate.d.ts +5 -2
  24. package/dist/components/Box/Box.d.ts +23 -21
  25. package/dist/components/Box/Box.stories.d.ts +2 -124
  26. package/dist/components/Button/Button.d.ts +4 -2
  27. package/dist/components/ButtonGroup/ButtonGroup.d.ts +1 -1
  28. package/dist/components/Calendar/Calendar.d.ts +3 -2
  29. package/dist/components/Calendar/Calendar.stories.d.ts +3 -0
  30. package/dist/components/Calendar/CalendarCell.css.d.ts +1 -0
  31. package/dist/components/Calendar/CalendarCell.d.ts +4 -4
  32. package/dist/components/Calendar/CalendarGrid.d.ts +2 -2
  33. package/dist/components/Card/Card.d.ts +16 -16
  34. package/dist/components/Card/Card.stories.d.ts +2 -14
  35. package/dist/components/Carousel/Carousel.css.d.ts +0 -2
  36. package/dist/components/Carousel/CarouselItem.d.ts +2 -2
  37. package/dist/components/CircledIcon/CircledIcon.d.ts +1 -1
  38. package/dist/components/ColorInput/ColorArea.d.ts +1 -1
  39. package/dist/components/ColorInput/ColorInput.d.ts +1 -1
  40. package/dist/components/ColorInput/ColorSlider.d.ts +1 -1
  41. package/dist/components/Cropper/Cropper.d.ts +1 -1
  42. package/dist/components/CropperControls/CropperControls.d.ts +5 -5
  43. package/dist/components/DateInput/DateInput.d.ts +12 -6
  44. package/dist/components/DateInput/DateInput.stories.d.ts +2 -14
  45. package/dist/components/DateInput/DateSegments.d.ts +1 -1
  46. package/dist/components/Dialog/Dialog.css.d.ts +4 -0
  47. package/dist/components/Dialog/Dialog.d.ts +4 -1
  48. package/dist/components/Dialog/Dialog.stories.d.ts +3 -0
  49. package/dist/components/Dialog/FullscreenDialog.d.ts +1 -1
  50. package/dist/components/Dialog/Options/DialogOptions.d.ts +1 -1
  51. package/dist/components/DocumentCard/DocumentCard.css.d.ts +1 -0
  52. package/dist/components/DocumentCard/DocumentCard.d.ts +2 -0
  53. package/dist/components/DocumentStatusBar/DocumentStatusBar.d.ts +1 -1
  54. package/dist/components/DocumentStatusDot/DocumentStatusDot.d.ts +1 -1
  55. package/dist/components/DropdownMenu/DropdownMenu.d.ts +1 -1
  56. package/dist/components/Embed/EmbedPreview.d.ts +1 -1
  57. package/dist/components/Embed/EmptyEmbed.d.ts +1 -1
  58. package/dist/components/Embed/Icon.d.ts +1 -1
  59. package/dist/components/ErrorBoundary/ErrorBoundary.d.ts +3 -3
  60. package/dist/components/Field/Field.d.ts +1 -1
  61. package/dist/components/FieldSet/FieldSet.d.ts +4 -4
  62. package/dist/components/FieldSet/FieldSet.stories.d.ts +1 -6
  63. package/dist/components/FieldSet/FieldSet.utils.d.ts +4 -0
  64. package/dist/components/FieldSet/index.d.ts +1 -0
  65. package/dist/components/FileUpload/FileDropZone/FileDropZone.d.ts +1 -1
  66. package/dist/components/FileUpload/FileUpload.utils.d.ts +5 -1
  67. package/dist/components/FilterField/FilterField.d.ts +2 -2
  68. package/dist/components/FilterField/useFilterField.d.ts +2 -1
  69. package/dist/components/Form/Form.d.ts +2 -0
  70. package/dist/components/Form/FormDateInput.d.ts +14 -0
  71. package/dist/components/Form/FormField.css.d.ts +7 -0
  72. package/dist/components/Form/FormField.d.ts +14 -0
  73. package/dist/components/Form/FormInput.css.d.ts +4 -6
  74. package/dist/components/Form/FormInput.d.ts +5 -5
  75. package/dist/components/Form/index.d.ts +1 -0
  76. package/dist/components/Gradient/Gradient.d.ts +1 -1
  77. package/dist/components/HairlineButton/HairlineButton.d.ts +2 -2
  78. package/dist/components/Icon/Icon.d.ts +3 -1
  79. package/dist/components/Icon/iconNames.d.ts +2 -2
  80. package/dist/components/Image/Image.d.ts +4 -5
  81. package/dist/components/Image/Image.stories.d.ts +2 -22
  82. package/dist/components/Image/index.d.ts +1 -1
  83. package/dist/components/InvisibleButton/InvisibleButton.d.ts +1 -1
  84. package/dist/components/LazyRender/LazyRender.d.ts +21 -0
  85. package/dist/components/LazyRender/LazyRender.stories.d.ts +7 -0
  86. package/dist/components/LazyRender/index.d.ts +1 -0
  87. package/dist/components/LinkImageCard/LinkImageCard.d.ts +8 -0
  88. package/dist/components/LinkImageCard/LinkImageCard.stories.d.ts +11 -0
  89. package/dist/components/LinkImageCard/index.d.ts +1 -0
  90. package/dist/components/Masonry/Masonry.d.ts +1 -1
  91. package/dist/components/Masonry/MasonryFile.css.d.ts +2 -0
  92. package/dist/components/Masonry/MasonryFile.d.ts +8 -0
  93. package/dist/components/Masonry/MasonryMedia.d.ts +1 -2
  94. package/dist/components/Masonry/index.d.ts +2 -1
  95. package/dist/components/NumberInput/NumberInput.d.ts +2 -1
  96. package/dist/components/Popover/Popover.d.ts +8 -3
  97. package/dist/components/Popover/Popover.stories.d.ts +2 -20
  98. package/dist/components/Popover/index.d.ts +1 -1
  99. package/dist/components/Radio/RadioButton.css.d.ts +3 -0
  100. package/dist/components/Radio/RadioButton.d.ts +10 -0
  101. package/dist/components/Radio/RadioCard.css.d.ts +1 -0
  102. package/dist/components/Radio/RadioCard.d.ts +5 -0
  103. package/dist/components/Radio/RadioGroup.css.d.ts +1 -0
  104. package/dist/components/Radio/RadioGroup.d.ts +18 -0
  105. package/dist/components/Radio/RadioGroup.stories.d.ts +9 -0
  106. package/dist/components/Radio/RadioItem.css.d.ts +10 -0
  107. package/dist/components/Radio/RadioItem.d.ts +8 -0
  108. package/dist/components/Radio/index.d.ts +3 -0
  109. package/dist/components/ScrollArea/ScrollArea.d.ts +4 -5
  110. package/dist/components/ScrollArea/ScrollArea.stories.d.ts +2 -14
  111. package/dist/components/SearchInput/SearchInput.d.ts +1 -1
  112. package/dist/components/Select/Select.css.d.ts +4 -0
  113. package/dist/components/Select/Select.d.ts +7 -2
  114. package/dist/components/SelectButton/SelectButton.d.ts +1 -1
  115. package/dist/components/SelectCard/SelectButton.stories.d.ts +12 -0
  116. package/dist/components/SelectCard/SelectCard.css.d.ts +1 -0
  117. package/dist/components/SelectCard/SelectCard.d.ts +7 -0
  118. package/dist/components/SelectCard/index.d.ts +1 -0
  119. package/dist/components/Separator/Separator.d.ts +11 -5
  120. package/dist/components/Skeleton/Skeleton.d.ts +1 -1
  121. package/dist/components/Slice/Slice.stories.d.ts +2 -2
  122. package/dist/components/Slice/SliceCard.d.ts +1 -0
  123. package/dist/components/Slice/{SliceVariationCard.css.d.ts → SliceSelectCard.css.d.ts} +2 -0
  124. package/dist/components/Slice/SliceSelectCard.d.ts +12 -0
  125. package/dist/components/Slice/index.d.ts +1 -1
  126. package/dist/components/Slider/Slider.d.ts +1 -1
  127. package/dist/components/StoryCard.d.ts +12 -0
  128. package/dist/components/Table/Table.css.d.ts +9 -0
  129. package/dist/components/Table/Table.d.ts +24 -0
  130. package/dist/components/Table/Table.stories.d.ts +6 -0
  131. package/dist/components/Table/index.d.ts +1 -0
  132. package/dist/components/TagField/TagField.css.d.ts +0 -5
  133. package/dist/components/TagField/TagFieldHeader.css.d.ts +6 -0
  134. package/dist/components/TagField/TagFieldHeader.d.ts +21 -0
  135. package/dist/components/TagField/useTagField.d.ts +5 -31
  136. package/dist/components/TagField/useTagFieldHeader.d.ts +24 -0
  137. package/dist/components/Text/Text.css.d.ts +3 -0
  138. package/dist/components/Text/Text.d.ts +4 -3
  139. package/dist/components/Text/index.d.ts +1 -1
  140. package/dist/components/TextArea/TextArea.d.ts +2 -1
  141. package/dist/components/TextInput/TextInput.d.ts +4 -1
  142. package/dist/components/TextLink/TextLink.css.d.ts +2 -0
  143. package/dist/components/TextLink/TextLink.d.ts +3 -1
  144. package/dist/components/Toast/Toast.d.ts +2 -2
  145. package/dist/components/Toast/Toast.stories.d.ts +2 -2
  146. package/dist/components/Toast/ToastContext.d.ts +1 -1
  147. package/dist/components/ToggleButtonGroup/ToggleButtonGroup.d.ts +2 -2
  148. package/dist/components/Toolbar/Toolbar.d.ts +6 -5
  149. package/dist/components/Tooltip/Tooltip.d.ts +14 -1
  150. package/dist/components/Video/Video.d.ts +2 -1
  151. package/dist/components/Video/Video.stories.d.ts +2 -1
  152. package/dist/components/Video/index.d.ts +1 -1
  153. package/dist/index.d.ts +18 -12
  154. package/dist/index.es.js +15679 -16180
  155. package/dist/style.css +1 -1
  156. package/dist/theme/colors.d.ts +65 -65
  157. package/dist/theme/mediaQueries.d.ts +5 -0
  158. package/dist/theme/selectors.d.ts +21 -21
  159. package/dist/theme/sprinkles.css.d.ts +8324 -536
  160. package/dist/theme/util.d.ts +12 -2
  161. package/dist/theme/vars.css.d.ts +137 -73
  162. package/package.json +16 -14
  163. package/dist/components/DocumentVersions/DocumentVersions.css.d.ts +0 -4
  164. package/dist/components/DocumentVersions/DocumentVersions.d.ts +0 -16
  165. package/dist/components/DocumentVersions/DocumentVersions.stories.d.ts +0 -31
  166. package/dist/components/DocumentVersions/index.d.ts +0 -1
  167. package/dist/components/Slice/SliceVariationCard.d.ts +0 -8
@@ -1,5 +1,5 @@
1
1
  import { type MouseEvent } from "react";
2
- import { IconName } from "../Icon";
2
+ import { type IconName } from "../Icon";
3
3
  import type { variant } from "../Text/Text.css";
4
4
  import * as styles from "./InvisibleButton.css";
5
5
  export interface InvisibleButtonProps {
@@ -0,0 +1,21 @@
1
+ import { type ReactNode } from "react";
2
+ import { type BoxFlexDisplayProps, type BoxProps } from "../Box/Box";
3
+ /**
4
+ * Lazily renders a child the first time it intersects with the viewport.
5
+ * Works with any vertical scrolling ancestor (direct or not).
6
+ */
7
+ export interface LazyRenderProps {
8
+ /**
9
+ * The children to display when LazyRender intersects with the viewport.
10
+ */
11
+ children: ReactNode;
12
+ /**
13
+ * A rough estimate of the children's height so that not too many or too few LazyRender components are visible at once.
14
+ * Getting this right is not critical.
15
+ * A heightEstimate of 0 means nothing will lazily render as everything is immediately visible.
16
+ * On the other hand, a huge heightEstimate means it will be hard to see and load the content after the first item.
17
+ */
18
+ heightEstimate?: number;
19
+ box?: BoxProps & BoxFlexDisplayProps;
20
+ }
21
+ export declare function LazyRender(props: LazyRenderProps): JSX.Element;
@@ -0,0 +1,7 @@
1
+ declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, import("./LazyRender").LazyRenderProps>;
2
+ export default _default;
3
+ export declare const Default: {
4
+ render: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("./LazyRender").LazyRenderProps>;
5
+ args: {};
6
+ name: string;
7
+ };
@@ -0,0 +1 @@
1
+ export { LazyRender } from "./LazyRender";
@@ -0,0 +1,8 @@
1
+ export interface LinkImageCardProps {
2
+ url: string;
3
+ title: string;
4
+ subTitle: string;
5
+ onEdit?: () => void;
6
+ onUnlink?: () => void;
7
+ }
8
+ export declare function LinkImageCard(props: LinkImageCardProps): JSX.Element;
@@ -0,0 +1,11 @@
1
+ declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, import("./LinkImageCard").LinkImageCardProps>;
2
+ export default _default;
3
+ export declare const Default: {
4
+ render: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("./LinkImageCard").LinkImageCardProps>;
5
+ args: {
6
+ url: string;
7
+ title: string;
8
+ subTitle: string;
9
+ };
10
+ name: string;
11
+ };
@@ -0,0 +1 @@
1
+ export { LinkImageCard } from "./LinkImageCard";
@@ -1,4 +1,4 @@
1
- import { CSSProperties, Key, ReactElement, ReactNode } from "react";
1
+ import { type CSSProperties, type Key, type ReactElement, type ReactNode } from "react";
2
2
  export interface ItemInfo {
3
3
  key: Key;
4
4
  aspectRatio: number;
@@ -0,0 +1,2 @@
1
+ export declare const root: string;
2
+ export declare const iconContainer: string;
@@ -0,0 +1,8 @@
1
+ import type { FC } from "react";
2
+ interface MasonryFile {
3
+ extension: string;
4
+ filename: string;
5
+ onClick?: () => void;
6
+ }
7
+ export declare const MasonryFile: FC<MasonryFile>;
8
+ export {};
@@ -1,7 +1,6 @@
1
- import type { FC } from "react";
2
1
  interface MasonryMediaProps {
3
2
  url: string;
4
3
  onClick?: () => void;
5
4
  }
6
- export declare const MasonryMedia: FC<MasonryMediaProps>;
5
+ export declare function MasonryMedia(props: MasonryMediaProps): JSX.Element;
7
6
  export {};
@@ -1,3 +1,4 @@
1
- export { type ItemInfo as MasonryItemInfo, Masonry } from "./Masonry";
1
+ export { Masonry, type ItemInfo as MasonryItemInfo } from "./Masonry";
2
+ export { MasonryFile } from "./MasonryFile";
2
3
  export { MasonryMedia } from "./MasonryMedia";
3
4
  export { MasonrySkeleton } from "./MasonrySkeleton";
@@ -1,6 +1,6 @@
1
+ import type { SX } from "../../theme/util";
1
2
  export interface NumberInputProps {
2
3
  autoComplete?: string;
3
- className?: string;
4
4
  id?: string;
5
5
  max?: number;
6
6
  min?: number;
@@ -9,6 +9,7 @@ export interface NumberInputProps {
9
9
  readOnly?: boolean;
10
10
  value?: number;
11
11
  onValueChange?: (value: number | undefined) => void;
12
+ sx?: SX;
12
13
  }
13
14
  export declare function NumberInput(props: NumberInputProps): JSX.Element;
14
15
  export declare function isValidDraftValue(value: string): boolean;
@@ -1,13 +1,18 @@
1
- import { PopoverContentProps } from "@radix-ui/react-popover";
1
+ import { type PopoverContentProps } from "@radix-ui/react-popover";
2
2
  import type { ReactNode } from "react";
3
- export declare type PopoverProps = {
3
+ export interface PopoverProps {
4
4
  anchor: ReactNode;
5
5
  children?: ReactNode;
6
6
  focusOnEnter?: boolean;
7
7
  open?: boolean;
8
8
  openDelay?: number;
9
9
  closeDelay?: number;
10
+ align?: "start" | "center" | "end";
11
+ sideOffset?: number;
10
12
  onOpenChange?: (open: boolean) => void;
11
13
  onMouseOverChange?: (isMouseOver: boolean) => void;
12
- } & Pick<PopoverContentProps, "onInteractOutside" | "onEscapeKeyDown" | "align" | "sideOffset">;
14
+ onInteractOutside?: (event: PopoverInteractOutsideEvent) => void;
15
+ onEscapeKeyDown?: (event: KeyboardEvent) => void;
16
+ }
17
+ export type PopoverInteractOutsideEvent = Parameters<NonNullable<PopoverContentProps["onInteractOutside"]>>[0];
13
18
  export declare function Popover(props: PopoverProps): JSX.Element;
@@ -1,25 +1,7 @@
1
- declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, {
2
- anchor: import("react").ReactNode;
3
- children?: import("react").ReactNode;
4
- focusOnEnter?: boolean | undefined;
5
- open?: boolean | undefined;
6
- openDelay?: number | undefined;
7
- closeDelay?: number | undefined;
8
- onOpenChange?: ((open: boolean) => void) | undefined;
9
- onMouseOverChange?: ((isMouseOver: boolean) => void) | undefined;
10
- } & Pick<import("@radix-ui/react-popover").PopoverContentProps, "align" | "onInteractOutside" | "onEscapeKeyDown" | "sideOffset">>;
1
+ declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, import("./Popover").PopoverProps>;
11
2
  export default _default;
12
3
  export declare const Default: {
13
- render: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, {
14
- anchor: import("react").ReactNode;
15
- children?: import("react").ReactNode;
16
- focusOnEnter?: boolean | undefined;
17
- open?: boolean | undefined;
18
- openDelay?: number | undefined;
19
- closeDelay?: number | undefined;
20
- onOpenChange?: ((open: boolean) => void) | undefined;
21
- onMouseOverChange?: ((isMouseOver: boolean) => void) | undefined;
22
- } & Pick<import("@radix-ui/react-popover").PopoverContentProps, "align" | "onInteractOutside" | "onEscapeKeyDown" | "sideOffset">>;
4
+ render: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("./Popover").PopoverProps>;
23
5
  argTypes: {
24
6
  children: {
25
7
  control: {
@@ -1 +1 @@
1
- export { Popover } from "./Popover";
1
+ export { Popover, type PopoverInteractOutsideEvent } from "./Popover";
@@ -0,0 +1,3 @@
1
+ export declare const root: string;
2
+ export declare const circle: string;
3
+ export declare const indicator: string;
@@ -0,0 +1,10 @@
1
+ export interface RadioButtonProps {
2
+ label?: string;
3
+ disabled?: boolean;
4
+ /**
5
+ * Whether this RadioButton is only included for decoration purposes
6
+ * or is the actual Radio Group Item.
7
+ */
8
+ decorative?: boolean;
9
+ }
10
+ export declare function RadioButton(props: RadioButtonProps): JSX.Element;
@@ -0,0 +1 @@
1
+ export declare const root: string;
@@ -0,0 +1,5 @@
1
+ export interface RadioCardProps {
2
+ title: string;
3
+ disabled?: boolean;
4
+ }
5
+ export declare function RadioCard(props: RadioCardProps): JSX.Element;
@@ -0,0 +1 @@
1
+ export declare const root: string;
@@ -0,0 +1,18 @@
1
+ import { type ReactNode } from "react";
2
+ import { type SX } from "../../theme/util";
3
+ export interface RadioGroupProps<VALUE extends string> {
4
+ values: readonly VALUE[];
5
+ selectedValue: VALUE;
6
+ evenItemSize?: boolean;
7
+ disabled?: boolean;
8
+ sx?: SX;
9
+ renderItem: (value: VALUE) => ReactNode;
10
+ onChange: (value: VALUE) => void;
11
+ }
12
+ export declare function RadioGroup<VALUE extends string>(props: RadioGroupProps<VALUE>): JSX.Element;
13
+ interface RadioItemContextValue {
14
+ value: string;
15
+ evenItemSize: boolean;
16
+ }
17
+ export declare function useRadioItem(): RadioItemContextValue;
18
+ export {};
@@ -0,0 +1,9 @@
1
+ declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, import("./RadioGroup").RadioGroupProps<string>>;
2
+ export default _default;
3
+ export declare const Default: {
4
+ render: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("./RadioGroup").RadioGroupProps<string>>;
5
+ args: {
6
+ items: string[];
7
+ };
8
+ name: string;
9
+ };
@@ -0,0 +1,10 @@
1
+ export declare const radioItem: string;
2
+ export declare const evenSize: string;
3
+ export declare const selectors: {
4
+ lightModeChecked: string;
5
+ darkModeChecked: string;
6
+ lightModeHover: string;
7
+ darkModeHover: string;
8
+ focusVisible: string;
9
+ disabled: string;
10
+ };
@@ -0,0 +1,8 @@
1
+ import type { ReactNode } from "react";
2
+ /** Private component */
3
+ interface RadioItemProps {
4
+ disabled: boolean;
5
+ children: ReactNode;
6
+ }
7
+ export declare function RadioItem(props: RadioItemProps): JSX.Element;
8
+ export {};
@@ -0,0 +1,3 @@
1
+ export { RadioButton } from "./RadioButton";
2
+ export { RadioCard } from "./RadioCard";
3
+ export { RadioGroup } from "./RadioGroup";
@@ -1,11 +1,10 @@
1
- import { CSSProperties, FC, ReactNode } from "react";
1
+ import { type CSSProperties, type ReactNode } from "react";
2
2
  import * as styles from "./ScrollArea.css";
3
- declare type ScrollAreaProps = Readonly<{
3
+ export interface ScrollAreaProps {
4
4
  children?: ReactNode;
5
5
  className?: string;
6
6
  direction?: keyof typeof styles.direction;
7
7
  style?: CSSProperties;
8
8
  onScrollToBottom?: () => void;
9
- }>;
10
- export declare const ScrollArea: FC<ScrollAreaProps>;
11
- export {};
9
+ }
10
+ export declare function ScrollArea(props: ScrollAreaProps): JSX.Element;
@@ -1,19 +1,7 @@
1
- declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, Readonly<{
2
- children?: import("react").ReactNode;
3
- className?: string | undefined;
4
- direction?: "horizontal" | "vertical" | undefined;
5
- style?: import("react").CSSProperties | undefined;
6
- onScrollToBottom?: (() => void) | undefined;
7
- }>>;
1
+ declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, import("./ScrollArea").ScrollAreaProps>;
8
2
  export default _default;
9
3
  export declare const Default: {
10
- render: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, Readonly<{
11
- children?: import("react").ReactNode;
12
- className?: string | undefined;
13
- direction?: "horizontal" | "vertical" | undefined;
14
- style?: import("react").CSSProperties | undefined;
15
- onScrollToBottom?: (() => void) | undefined;
16
- }>>;
4
+ render: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("./ScrollArea").ScrollAreaProps>;
17
5
  args: {
18
6
  children: JSX.Element[];
19
7
  direction: string;
@@ -1,4 +1,4 @@
1
- declare type Props = Readonly<{
1
+ type Props = Readonly<{
2
2
  value: string;
3
3
  onValueChange: (value: string) => void;
4
4
  placeholder?: string;
@@ -1,4 +1,8 @@
1
1
  export declare const trigger: string;
2
+ export declare const triggerTextVariant: {
3
+ normal: string;
4
+ bold: string;
5
+ };
2
6
  export declare const triggerIcon: string;
3
7
  export declare const content: string;
4
8
  export declare const constrainContentWidth: string;
@@ -1,6 +1,7 @@
1
1
  import type { ReactNode } from "react";
2
+ import { type SX } from "../../theme/util";
2
3
  import type * as buttonStyles from "../Button/Button.css";
3
- import { IconName } from "../Icon";
4
+ import { type IconName } from "../Icon";
4
5
  export interface SelectProps<VALUE extends string> {
5
6
  disabled?: boolean;
6
7
  id?: string;
@@ -17,10 +18,14 @@ export interface SelectProps<VALUE extends string> {
17
18
  value?: VALUE;
18
19
  onValueChange?: (value: VALUE) => void;
19
20
  constrainContentWidth?: boolean;
20
- position?: "item-aligned" | "popper";
21
21
  side?: "bottom" | "top" | "left" | "right";
22
22
  sideOffset?: number;
23
23
  flexContent?: boolean;
24
+ /**
25
+ * Prominent selects should have bold text for better visibility.
26
+ */
27
+ boldTriggerText?: boolean;
28
+ sx?: SX;
24
29
  }
25
30
  export declare function Select<VALUE extends string>(props: SelectProps<VALUE>): JSX.Element;
26
31
  interface RenderTriggerParams {
@@ -1,5 +1,5 @@
1
1
  import type { colors } from "../../theme/colors";
2
- import { IconName } from "../Icon";
2
+ import { type IconName } from "../Icon";
3
3
  export interface SelectButtonProps {
4
4
  textContent: string;
5
5
  onSelect: () => void;
@@ -0,0 +1,12 @@
1
+ declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, import("./SelectCard").SelectCardProps>;
2
+ export default _default;
3
+ export declare const Default: {
4
+ render: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("./SelectCard").SelectCardProps>;
5
+ args: {
6
+ title: string;
7
+ subtitle: string;
8
+ selected: boolean;
9
+ onSelect: () => null;
10
+ };
11
+ name: string;
12
+ };
@@ -0,0 +1 @@
1
+ export declare const card: Record<"default" | "selected", string>;
@@ -0,0 +1,7 @@
1
+ import type { ReactNode } from "react";
2
+ export interface SelectCardProps {
3
+ selected: boolean;
4
+ onSelect: () => void;
5
+ children: ReactNode;
6
+ }
7
+ export declare function SelectCard(props: SelectCardProps): JSX.Element;
@@ -0,0 +1 @@
1
+ export { SelectCard } from "./SelectCard";
@@ -1,8 +1,14 @@
1
- import * as SeparatorPrimitive from "@radix-ui/react-separator";
2
- import { SX } from "../../theme/util";
3
- export interface SeparatorProps extends RadixProps {
1
+ import { type SX } from "../../theme/util";
2
+ export interface SeparatorProps {
3
+ /**
4
+ * Either `vertical` or `horizontal`. Defaults to `horizontal`.
5
+ */
6
+ orientation?: "horizontal" | "vertical";
7
+ /**
8
+ * Whether or not the component is purely decorative. When true, accessibility-related attributes
9
+ * are updated so that that the rendered element is removed from the accessibility tree.
10
+ */
11
+ decorative?: boolean;
4
12
  sx?: SX;
5
13
  }
6
- declare type RadixProps = Pick<SeparatorPrimitive.SeparatorProps, "decorative" | "orientation">;
7
14
  export declare function Separator(props: SeparatorProps): JSX.Element;
8
- export {};
@@ -1,5 +1,5 @@
1
1
  import { type CSSProperties } from "react";
2
- import { SX } from "../../theme/util";
2
+ import { type SX } from "../../theme/util";
3
3
  import * as styles from "./Skeleton.css";
4
4
  export interface Props {
5
5
  component?: "span";
@@ -27,8 +27,8 @@ export declare const SliceCardStory: {
27
27
  };
28
28
  name: string;
29
29
  };
30
- export declare const SliceVariationCardStory: {
31
- render: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("./SliceVariationCard").SliceVariationCardProps>;
30
+ export declare const SliceSelectCardStory: {
31
+ render: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("./SliceSelectCard").SliceSelectCardProps>;
32
32
  args: {
33
33
  slice: string;
34
34
  variation: string;
@@ -1,5 +1,6 @@
1
1
  import type { ReactNode } from "react";
2
2
  export interface SliceCardProps {
3
+ id?: string;
3
4
  title: string;
4
5
  subTitle: string;
5
6
  index: number;
@@ -1,5 +1,7 @@
1
1
  export declare const card: string;
2
2
  export declare const innerContent: string;
3
+ export declare const innerContentFixedHeight: string;
3
4
  export declare const text: string;
4
5
  export declare const children: string;
6
+ export declare const childrenFixedHeight: string;
5
7
  export declare const plusIcon: string;
@@ -0,0 +1,12 @@
1
+ import type { ReactNode } from "react";
2
+ export interface SliceSelectCardProps {
3
+ /**
4
+ * Whether the card should have a fixed height or not. Defaults to `true`.
5
+ */
6
+ fixedHeight?: boolean;
7
+ label: string;
8
+ variation?: string;
9
+ children: ReactNode;
10
+ onClick: () => void;
11
+ }
12
+ export declare function SliceSelectCard(props: SliceSelectCardProps): JSX.Element;
@@ -1,2 +1,2 @@
1
1
  export { SliceCard } from "./SliceCard";
2
- export { SliceVariationCard } from "./SliceVariationCard";
2
+ export { SliceSelectCard } from "./SliceSelectCard";
@@ -1,4 +1,4 @@
1
1
  import * as SliderPrimitive from "@radix-ui/react-slider";
2
- declare type Props = Readonly<Pick<SliderPrimitive.SliderProps, "min" | "max" | "step" | "value" | "onValueChange">>;
2
+ type Props = Readonly<Pick<SliderPrimitive.SliderProps, "min" | "max" | "step" | "value" | "onValueChange">>;
3
3
  export declare const Slider: ({ value, ...props }: Props) => JSX.Element;
4
4
  export {};
@@ -0,0 +1,12 @@
1
+ import type { ReactNode } from "react";
2
+ import { type BoxFlexDisplayProps, type BoxProps } from "./Box/Box";
3
+ /**
4
+ * A basic card with a title for Storybook stories that showcase multiple component variants.
5
+ */
6
+ interface StoryCardProps {
7
+ title: string;
8
+ children: ReactNode;
9
+ box?: BoxProps & BoxFlexDisplayProps;
10
+ }
11
+ export declare function StoryCard(props: StoryCardProps): JSX.Element;
12
+ export {};
@@ -0,0 +1,9 @@
1
+ export declare const root: string;
2
+ export declare const table: string;
3
+ export declare const head: string;
4
+ export declare const body: string;
5
+ export declare const row: string;
6
+ export declare const bodyRow: string;
7
+ export declare const rowClickable: string;
8
+ export declare const cell: string;
9
+ export declare const cellContent: string;
@@ -0,0 +1,24 @@
1
+ import { type MouseEventHandler, type ReactNode } from "react";
2
+ export interface TableProps {
3
+ children: ReactNode;
4
+ }
5
+ export declare function Table({ children }: TableProps): JSX.Element;
6
+ export interface TableHeadProps {
7
+ children: ReactNode;
8
+ }
9
+ export declare function TableHead({ children }: TableHeadProps): JSX.Element;
10
+ export interface TableBodyProps {
11
+ children: ReactNode;
12
+ }
13
+ export declare function TableBody({ children }: TableBodyProps): JSX.Element;
14
+ export interface TableRowProps {
15
+ children: ReactNode;
16
+ onClick?: MouseEventHandler<HTMLTableRowElement>;
17
+ }
18
+ export declare function TableRow(props: TableRowProps): JSX.Element;
19
+ export interface TableCellProps {
20
+ children?: ReactNode;
21
+ /** How to align the content in the cell. Note that undefined defaults to start */
22
+ align?: "center" | "end";
23
+ }
24
+ export declare function TableCell(props: TableCellProps): JSX.Element;
@@ -0,0 +1,6 @@
1
+ declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, import("./Table").TableProps>;
2
+ export default _default;
3
+ export declare const Default: {
4
+ render: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("./Table").TableProps>;
5
+ name: string;
6
+ };
@@ -0,0 +1 @@
1
+ export { Table, TableBody, TableCell, TableHead, TableRow } from "./Table";
@@ -1,18 +1,13 @@
1
1
  export declare const gapBetweenTags = 8;
2
- export declare const maxInputContainerSize = 225;
3
2
  export declare const root: string;
4
3
  export declare const overlayMode: {
5
4
  open: string;
6
5
  closed: string;
7
6
  };
8
- export declare const inputContainer: string;
9
- export declare const invisibleBorder: string;
10
- export declare const input: string;
11
7
  export declare const footer: string;
12
8
  export declare const footerTitle: string;
13
9
  export declare const optionsContainer: string;
14
10
  export declare const tagsSkeleton: string;
15
- export declare const extraTagContainer: string;
16
11
  export declare const footerButton: string;
17
12
  export declare const tagErrorContainer: string;
18
13
  export declare const tagErrorLeft: string;
@@ -0,0 +1,6 @@
1
+ export declare const gapBetweenTags = 8;
2
+ export declare const maxInputContainerSize = 225;
3
+ export declare const inputContainer: string;
4
+ export declare const invisibleBorder: string;
5
+ export declare const input: string;
6
+ export declare const extraTagContainer: string;
@@ -0,0 +1,21 @@
1
+ import { type RefObject } from "react";
2
+ import { type LastItemLocation } from "./useTagFieldHeader";
3
+ interface TagFieldHeaderProps {
4
+ selectedValues: Set<string>;
5
+ searchText: string;
6
+ setSearchText: (searchText: string) => void;
7
+ open: boolean;
8
+ setOpen: (open: boolean) => void;
9
+ isDisabled: boolean | undefined;
10
+ onSelectedValuesChange: (selectedValues: Set<string>) => void;
11
+ onCreateTag: () => void;
12
+ fieldRef: RefObject<HTMLDivElement>;
13
+ }
14
+ export declare function TagFieldHeader(props: TagFieldHeaderProps): JSX.Element;
15
+ interface TagsContainerProps {
16
+ displayedTags: string[];
17
+ extraTags: number;
18
+ removeSelectedValue: (valueToDelete: string | LastItemLocation) => void;
19
+ }
20
+ export declare function TagFieldHeaderContent({ displayedTags, extraTags, removeSelectedValue }: TagsContainerProps): JSX.Element;
21
+ export {};
@@ -1,40 +1,14 @@
1
- import { type RefObject, KeyboardEvent } from "react";
2
- import type { TagFieldProps } from "./TagField";
3
- interface UseTagFieldProps extends TagFieldProps {
4
- fieldRef: RefObject<HTMLDivElement>;
5
- tagsContainerRef: RefObject<HTMLDivElement>;
6
- open: boolean;
1
+ import { type RefObject } from "react";
2
+ interface UseTagFieldProps {
3
+ selectedValues: Set<string>;
7
4
  setOpen: (open: boolean) => void;
5
+ fieldRef: RefObject<HTMLDivElement>;
6
+ onSelectedValuesChange: (selectedValues: Set<string>) => void;
8
7
  }
9
8
  export declare function useTagField(props: UseTagFieldProps): {
10
9
  searchText: string;
11
10
  setSearchText: import("react").Dispatch<import("react").SetStateAction<string>>;
12
11
  onCreateTag: () => void;
13
12
  addItemToSelectedValues: (valueToAdd: string) => void;
14
- updateSelectedValue: (newValues: string[]) => void;
15
- removeSelectedValue: (valueToDelete: string | LastItemLocation) => void;
16
- };
17
- interface UseTagFieldHeaderProps extends TagFieldProps {
18
- fieldRef: RefObject<HTMLDivElement>;
19
- tagsContainerRef: RefObject<HTMLDivElement>;
20
- open: boolean;
21
- setOpen: (open: boolean) => void;
22
- updateSelectedValue(newValues: string[]): void;
23
- }
24
- export declare function useTagFieldHeader(props: UseTagFieldHeaderProps): {
25
- displayedSelectedValues: string[];
26
- extraTags: number;
27
- };
28
- export declare type LastItemLocation = -1;
29
- interface UseHandleKeyboardEntriesProps {
30
- fieldRef: RefObject<HTMLDivElement>;
31
- inputRef: RefObject<HTMLDivElement>;
32
- searchText: string;
33
- setOpen: (open: boolean) => void;
34
- onCreateTag: () => void;
35
- removeSelectedValue: (valueToDelete: string | -1) => void;
36
- }
37
- export declare function useHandleKeyboardEntries(props: UseHandleKeyboardEntriesProps): {
38
- onKeyDown: (evt: KeyboardEvent) => void;
39
13
  };
40
14
  export {};