@dinofront/design_system 1.0.0 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (106) hide show
  1. package/dist/components/Accordion/Accordion.types.d.ts +4 -0
  2. package/dist/components/Badge/Badge.types.d.ts +11 -0
  3. package/dist/components/Breadcrumb/Breadcrumb.d.ts +2 -0
  4. package/dist/components/Breadcrumb/Breadcrumb.types.d.ts +19 -0
  5. package/dist/components/Breadcrumb/index.d.ts +2 -0
  6. package/dist/components/CardGroup/CardGroup.d.ts +2 -0
  7. package/dist/components/CardGroup/CardGroup.types.d.ts +19 -0
  8. package/dist/components/CardGroup/index.d.ts +2 -0
  9. package/dist/components/Copy/Copy.d.ts +2 -0
  10. package/dist/components/Copy/Copy.types.d.ts +17 -0
  11. package/dist/components/Copy/index.d.ts +2 -0
  12. package/dist/components/Counter/Counter.d.ts +2 -0
  13. package/dist/components/Counter/Counter.types.d.ts +20 -0
  14. package/dist/components/Counter/index.d.ts +2 -0
  15. package/dist/components/DistributionBar/DistributionBar.d.ts +2 -0
  16. package/dist/components/DistributionBar/DistributionBar.types.d.ts +20 -0
  17. package/dist/components/DistributionBar/index.d.ts +2 -0
  18. package/dist/components/Drawer/Drawer.types.d.ts +4 -0
  19. package/dist/components/DropdownMenu/DropdownMenu.types.d.ts +22 -2
  20. package/dist/components/Empty/Empty.d.ts +2 -0
  21. package/dist/components/Empty/Empty.types.d.ts +12 -0
  22. package/dist/components/Empty/index.d.ts +2 -0
  23. package/dist/components/FormContainer/FormContainer.d.ts +2 -0
  24. package/dist/components/FormContainer/FormContainer.types.d.ts +18 -0
  25. package/dist/components/FormContainer/index.d.ts +2 -0
  26. package/dist/components/FormField/FormField.d.ts +2 -0
  27. package/dist/components/FormField/FormField.types.d.ts +22 -0
  28. package/dist/components/FormField/index.d.ts +2 -0
  29. package/dist/components/Input/Input.types.d.ts +2 -0
  30. package/dist/components/Link/Link.d.ts +2 -0
  31. package/dist/components/Link/Link.types.d.ts +15 -0
  32. package/dist/components/Link/index.d.ts +2 -0
  33. package/dist/components/MultiSelect/MultiSelect.types.d.ts +8 -0
  34. package/dist/components/Popover/Popover.d.ts +2 -0
  35. package/dist/components/Popover/Popover.types.d.ts +29 -0
  36. package/dist/components/Popover/index.d.ts +2 -0
  37. package/dist/components/ReadMore/ReadMore.d.ts +2 -0
  38. package/dist/components/ReadMore/ReadMore.types.d.ts +17 -0
  39. package/dist/components/ReadMore/index.d.ts +2 -0
  40. package/dist/components/Select/Select.types.d.ts +2 -0
  41. package/dist/components/StepIndicator/StepIndicator.d.ts +2 -0
  42. package/dist/components/StepIndicator/StepIndicator.types.d.ts +24 -0
  43. package/dist/components/StepIndicator/index.d.ts +2 -0
  44. package/dist/components/Tabs/Tabs.types.d.ts +16 -1
  45. package/dist/components/Text/Text.types.d.ts +2 -0
  46. package/dist/components/TextArea/TextArea.types.d.ts +2 -0
  47. package/dist/components/ThemeSwitch/ThemeSwitch.d.ts +2 -0
  48. package/dist/components/ThemeSwitch/ThemeSwitch.types.d.ts +7 -0
  49. package/dist/components/ThemeSwitch/index.d.ts +2 -0
  50. package/dist/components/UnderConstruction/UnderConstruction.d.ts +2 -0
  51. package/dist/components/UnderConstruction/UnderConstruction.types.d.ts +12 -0
  52. package/dist/components/UnderConstruction/index.d.ts +2 -0
  53. package/dist/components/Upload/Upload.types.d.ts +31 -2
  54. package/dist/components/Upload/index.d.ts +1 -1
  55. package/dist/hooks/index.d.ts +9 -0
  56. package/dist/hooks/useEscapeKey.d.ts +4 -0
  57. package/dist/hooks/useFormContext.d.ts +6 -0
  58. package/dist/hooks/useFormProps.d.ts +9 -0
  59. package/dist/hooks/useHideBodyScroll.d.ts +6 -0
  60. package/dist/hooks/useIsMobile.d.ts +9 -0
  61. package/dist/hooks/useOnOutsideClick.d.ts +6 -0
  62. package/dist/hooks/useStepper.d.ts +27 -0
  63. package/dist/icons/brands/AppleIcon.d.ts +1 -0
  64. package/dist/icons/brands/FacebookIcon.d.ts +1 -0
  65. package/dist/icons/brands/GoogleIcon.d.ts +1 -0
  66. package/dist/icons/brands/InstagramIcon.d.ts +1 -0
  67. package/dist/icons/brands/LinkedinIcon.d.ts +1 -0
  68. package/dist/icons/brands/MediumIcon.d.ts +1 -0
  69. package/dist/icons/brands/TelegramIcon.d.ts +1 -0
  70. package/dist/icons/brands/TwitterIcon.d.ts +1 -0
  71. package/dist/icons/brands/YoutubeIcon.d.ts +1 -0
  72. package/dist/icons/brands/index.d.ts +9 -0
  73. package/dist/icons/createIcon.d.ts +28 -0
  74. package/dist/icons/currency/AmdIcon.d.ts +1 -0
  75. package/dist/icons/currency/EurIcon.d.ts +1 -0
  76. package/dist/icons/currency/RubIcon.d.ts +1 -0
  77. package/dist/icons/currency/UsdIcon.d.ts +1 -0
  78. package/dist/icons/currency/index.d.ts +4 -0
  79. package/dist/icons/domain/BudgetTransferIcon.d.ts +1 -0
  80. package/dist/icons/domain/ContractCardIcon.d.ts +1 -0
  81. package/dist/icons/domain/HandOpenHeartIcon.d.ts +1 -0
  82. package/dist/icons/domain/OnlyEmployeeIcon.d.ts +1 -0
  83. package/dist/icons/domain/ProjectProductIcon.d.ts +1 -0
  84. package/dist/icons/domain/UnitsEmployeeIcon.d.ts +1 -0
  85. package/dist/icons/domain/VacationIcon.d.ts +1 -0
  86. package/dist/icons/domain/index.d.ts +7 -0
  87. package/dist/icons/flags/FlagAmIcon.d.ts +1 -0
  88. package/dist/icons/flags/FlagGbIcon.d.ts +1 -0
  89. package/dist/icons/flags/FlagRuIcon.d.ts +1 -0
  90. package/dist/icons/flags/FlagUsIcon.d.ts +1 -0
  91. package/dist/icons/flags/index.d.ts +4 -0
  92. package/dist/icons/index.d.ts +4 -0
  93. package/dist/icons.d.ts +2 -0
  94. package/dist/icons.js +342 -0
  95. package/dist/icons.js.map +1 -0
  96. package/dist/index.d.ts +15 -0
  97. package/dist/index.js +2283 -1158
  98. package/dist/index.js.map +1 -1
  99. package/dist/lib/FormContext.d.ts +22 -0
  100. package/dist/lib/mergeRefs.d.ts +4 -0
  101. package/dist/lib/motion.d.ts +11 -0
  102. package/dist/lib/useAnchoredPosition.d.ts +31 -0
  103. package/dist/lib/useFloatingPosition.d.ts +29 -0
  104. package/dist/lib/useMountTransition.d.ts +21 -0
  105. package/dist/styles.css +328 -0
  106. package/package.json +25 -4
@@ -9,6 +9,10 @@ export interface AccordionProps extends HTMLAttributes<HTMLDivElement>, BaseProp
9
9
  /** Controlled open value(s). Pass alongside `onValueChange` to fully control which item(s) are open. */
10
10
  value?: string | string[];
11
11
  onValueChange?: (value: string | string[]) => void;
12
+ /** Animates each panel open/closed. Set `false` for the pre-1.x instant toggle (also restores the plain `hidden` attribute instead of the animated grid wrapper). */
13
+ animated?: boolean;
14
+ /** Renders a Divider between each item's header and its panel content. */
15
+ showDivider?: boolean;
12
16
  children: ReactNode;
13
17
  }
14
18
  export interface AccordionItemProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title'>, BaseProps {
@@ -3,12 +3,23 @@ import { BaseProps } from '../../types';
3
3
  export type BadgeVariant = 'neutral' | 'brand' | 'success' | 'warning' | 'danger' | 'info' | 'privacy';
4
4
  export type BadgeStyle = 'filled' | 'outline' | 'accent';
5
5
  export type BadgeSize = 'lg' | 'md' | 'sm' | 'xs';
6
+ export type BadgeShape = 'rounded' | 'pill';
6
7
  export interface BadgeProps extends HTMLAttributes<HTMLSpanElement>, BaseProps {
7
8
  variant?: BadgeVariant;
8
9
  appearance?: BadgeStyle;
9
10
  size?: BadgeSize;
11
+ /** `'pill'` is fully rounded; `'rounded'` (default) uses the size's own corner radius. */
12
+ shape?: BadgeShape;
10
13
  leftIcon?: ReactNode;
11
14
  rightIcon?: ReactNode;
12
15
  /** Renders a trailing dismiss button (replacing `rightIcon`) that calls this on click. */
13
16
  onDismiss?: () => void;
17
+ /** Renders as a standalone status dot instead of a labeled badge. Ignores `children`, icons, and `onDismiss`. */
18
+ dot?: boolean;
19
+ /** Renders a leading status dot before `children`, in place of `leftIcon`. */
20
+ withDot?: boolean;
21
+ /** Dims the badge and blocks pointer/keyboard interaction, including `onDismiss`. */
22
+ disabled?: boolean;
23
+ /** Adds hover/active states, a focus ring, `role="button"`, and Enter/Space activation for `onClick`. */
24
+ interactive?: boolean;
14
25
  }
@@ -0,0 +1,2 @@
1
+ import { BreadcrumbProps } from './Breadcrumb.types';
2
+ export declare const Breadcrumb: import('react').ForwardRefExoticComponent<BreadcrumbProps & import('react').RefAttributes<HTMLElement>>;
@@ -0,0 +1,19 @@
1
+ import { HTMLAttributes, ReactNode } from 'react';
2
+ import { BaseProps } from '../../types';
3
+ export type BreadcrumbSize = 'md' | 'sm';
4
+ export interface BreadcrumbItem {
5
+ value: string | number;
6
+ label: ReactNode;
7
+ /** Renders the crumb as an `<a>` instead of a `<button>`. */
8
+ href?: string;
9
+ disabled?: boolean;
10
+ }
11
+ export interface BreadcrumbProps extends Omit<HTMLAttributes<HTMLElement>, 'onSelect'>, BaseProps {
12
+ items: BreadcrumbItem[];
13
+ /** Value of the current-page crumb, rendered as plain text with `aria-current="page"`. Defaults to the last item. */
14
+ currentValue?: string | number;
15
+ onSelect?: (value: string | number) => void;
16
+ /** Rendered between crumbs, hidden from assistive tech. Default `'/'`. */
17
+ separator?: ReactNode;
18
+ size?: BreadcrumbSize;
19
+ }
@@ -0,0 +1,2 @@
1
+ export { Breadcrumb } from './Breadcrumb';
2
+ export type { BreadcrumbItem, BreadcrumbProps, BreadcrumbSize } from './Breadcrumb.types';
@@ -0,0 +1,2 @@
1
+ import { CardGroupProps } from './CardGroup.types';
2
+ export declare const CardGroup: import('react').ForwardRefExoticComponent<CardGroupProps & import('react').RefAttributes<HTMLDivElement>>;
@@ -0,0 +1,19 @@
1
+ import { HTMLAttributes, ReactNode } from 'react';
2
+ import { BaseProps } from '../../types';
3
+ export type CardGroupTitleColor = 'brand' | 'blue' | 'purple' | 'pink' | 'yellow' | 'gray';
4
+ export type CardGroupTitlePlacement = 'top' | 'left' | 'right';
5
+ export interface CardGroupTitle {
6
+ text: ReactNode;
7
+ /** Default `'gray'`. */
8
+ color?: CardGroupTitleColor;
9
+ /** Default `'left'`. `'left'`/`'right'` render a vertical rail along that edge; `'top'` renders a horizontal bar. */
10
+ placement?: CardGroupTitlePlacement;
11
+ }
12
+ export interface CardGroupProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title'>, BaseProps {
13
+ title?: CardGroupTitle;
14
+ /** Extra content beside the title, rendered as the first divided section. */
15
+ header?: ReactNode;
16
+ children?: ReactNode;
17
+ /** Disables the automatic divider between the header and each child. */
18
+ noDivider?: boolean;
19
+ }
@@ -0,0 +1,2 @@
1
+ export { CardGroup } from './CardGroup';
2
+ export type { CardGroupProps, CardGroupTitle, CardGroupTitleColor, CardGroupTitlePlacement, } from './CardGroup.types';
@@ -0,0 +1,2 @@
1
+ import { CopyProps } from './Copy.types';
2
+ export declare const Copy: import('react').ForwardRefExoticComponent<CopyProps & import('react').RefAttributes<HTMLButtonElement>>;
@@ -0,0 +1,17 @@
1
+ import { ReactNode } from 'react';
2
+ import { BaseProps } from '../../types';
3
+ import { ButtonProps } from '../Button';
4
+ export interface CopyProps extends Omit<ButtonProps, 'children' | 'onClick' | 'leftIcon' | 'rightIcon' | 'onCopy'>, BaseProps {
5
+ /** Text copied to the clipboard on click. */
6
+ text: string;
7
+ /** Feedback shown in the popover after copying. Default `'Copied'`. */
8
+ copiedLabel?: string;
9
+ /** Accessible name for the button (it has no visible text). Default `'Copy to clipboard'`. */
10
+ label?: string;
11
+ /** Milliseconds before the feedback clears. Default `1500`. */
12
+ timeout?: number;
13
+ /** Overrides the default copy icon. */
14
+ icon?: ReactNode;
15
+ onCopy?: (text: string) => void;
16
+ onError?: (error: unknown) => void;
17
+ }
@@ -0,0 +1,2 @@
1
+ export { Copy } from './Copy';
2
+ export type { CopyProps } from './Copy.types';
@@ -0,0 +1,2 @@
1
+ import { CounterProps } from './Counter.types';
2
+ export declare const Counter: import('react').ForwardRefExoticComponent<CounterProps & import('react').RefAttributes<HTMLInputElement>>;
@@ -0,0 +1,20 @@
1
+ import { InputHTMLAttributes, ReactNode } from 'react';
2
+ import { BaseProps } from '../../types';
3
+ import { InputSize } from '../Input';
4
+ export interface CounterProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size' | 'type' | 'value' | 'defaultValue' | 'onChange' | 'min' | 'max' | 'step'>, BaseProps {
5
+ /** Controlled value. */
6
+ value?: number;
7
+ /** Uncontrolled initial value. Default `0`. */
8
+ defaultValue?: number;
9
+ /** Fires on every committed change — button press, or blur after typing. Not native `onChange`, since a button press isn't a `ChangeEvent`. */
10
+ onValueChange?: (value: number) => void;
11
+ min?: number;
12
+ max?: number;
13
+ step?: number;
14
+ size?: InputSize;
15
+ label?: ReactNode;
16
+ helperText?: ReactNode;
17
+ errorText?: ReactNode;
18
+ error?: boolean;
19
+ wrapperClassName?: string;
20
+ }
@@ -0,0 +1,2 @@
1
+ export { Counter } from './Counter';
2
+ export type { CounterProps } from './Counter.types';
@@ -0,0 +1,2 @@
1
+ import { DistributionBarProps } from './DistributionBar.types';
2
+ export declare const DistributionBar: import('react').ForwardRefExoticComponent<DistributionBarProps & import('react').RefAttributes<HTMLDivElement>>;
@@ -0,0 +1,20 @@
1
+ import { HTMLAttributes, ReactNode } from 'react';
2
+ import { BaseProps } from '../../types';
3
+ export type DistributionColor = 'brand' | 'blue' | 'purple' | 'pink' | 'yellow' | 'red' | 'gray';
4
+ export type DistributionBarSize = 'sm' | 'lg';
5
+ export interface DistributionSegment {
6
+ label: ReactNode;
7
+ value: number;
8
+ color: DistributionColor;
9
+ /** Suffix appended after the formatted value in the legend, e.g. `'AMD'`. */
10
+ unit?: string;
11
+ /** Still counted in the bar's proportions, just omitted from the legend list. */
12
+ hideFromLegend?: boolean;
13
+ }
14
+ export interface DistributionBarProps extends HTMLAttributes<HTMLDivElement>, BaseProps {
15
+ segments: DistributionSegment[];
16
+ hideLegend?: boolean;
17
+ /** Default: `Intl.NumberFormat().format`. */
18
+ formatValue?: (value: number) => string;
19
+ size?: DistributionBarSize;
20
+ }
@@ -0,0 +1,2 @@
1
+ export { DistributionBar } from './DistributionBar';
2
+ export type { DistributionBarProps, DistributionBarSize, DistributionColor, DistributionSegment, } from './DistributionBar.types';
@@ -19,5 +19,9 @@ export interface DrawerProps extends BaseProps {
19
19
  closeOnOverlayClick?: boolean;
20
20
  /** Whether the built-in close (X) button is rendered. */
21
21
  showClose?: boolean;
22
+ /** Slides/fades the drawer in and out. Set `false` for the pre-1.x instant mount/unmount. */
23
+ animated?: boolean;
24
+ /** Extra controls in the header, left of the close button — e.g. a pin or back button. */
25
+ headerActions?: ReactNode;
22
26
  className?: string;
23
27
  }
@@ -1,6 +1,9 @@
1
- import { ButtonHTMLAttributes, HTMLAttributes, ReactElement, ReactNode } from 'react';
1
+ import { ButtonHTMLAttributes, HTMLAttributes, ReactElement, ReactNode, RefObject } from 'react';
2
2
  import { BaseProps } from '../../types';
3
- export type DropdownContentAlign = 'start' | 'end';
3
+ import { AnchoredAlign, AnchoredSide } from '../../lib/useAnchoredPosition';
4
+ export type DropdownContentAlign = AnchoredAlign;
5
+ export type DropdownContentSide = AnchoredSide;
6
+ export type DropdownContentStrategy = 'fixed' | 'absolute';
4
7
  export interface DropdownMenuProps extends HTMLAttributes<HTMLDivElement>, BaseProps {
5
8
  children: ReactNode;
6
9
  /** Uncontrolled initial open state. */
@@ -8,6 +11,8 @@ export interface DropdownMenuProps extends HTMLAttributes<HTMLDivElement>, BaseP
8
11
  /** Controlled open state. Pass alongside `onOpenChange` to fully control the menu. */
9
12
  open?: boolean;
10
13
  onOpenChange?: (open: boolean) => void;
14
+ /** Anchor the panel to an element the consumer owns instead of `<DropdownTrigger>`'s child. */
15
+ anchorRef?: RefObject<HTMLElement | null>;
11
16
  }
12
17
  export interface DropdownTriggerProps {
13
18
  /** A single element cloned with the click handler and `aria-haspopup`/`aria-expanded` that open the menu. */
@@ -17,6 +22,19 @@ export interface DropdownContentProps extends HTMLAttributes<HTMLDivElement>, Ba
17
22
  children: ReactNode;
18
23
  /** Horizontal alignment of the panel relative to the trigger. */
19
24
  align?: DropdownContentAlign;
25
+ /** `'fixed'` portals the panel to `document.body` so it can never be clipped by an
26
+ * `overflow: hidden` ancestor. `'absolute'` is the pre-1.x behaviour, kept as an escape
27
+ * hatch for consumers who positioned the panel themselves via `className`. */
28
+ strategy?: DropdownContentStrategy;
29
+ /** Preferred vertical side. Auto-flips when there isn't room, unless `flip` is false. Only applies when `strategy="fixed"`. */
30
+ side?: DropdownContentSide;
31
+ sideOffset?: number;
32
+ flip?: boolean;
33
+ shift?: boolean;
34
+ /** Sets the panel's min-width to the trigger's/anchor's width. */
35
+ matchTriggerWidth?: boolean;
36
+ /** Closes the menu when any ancestor scrolls. */
37
+ closeOnScroll?: boolean;
20
38
  }
21
39
  export interface DropdownItemProps extends ButtonHTMLAttributes<HTMLButtonElement>, BaseProps {
22
40
  children: ReactNode;
@@ -29,6 +47,8 @@ export interface DropdownItemProps extends ButtonHTMLAttributes<HTMLButtonElemen
29
47
  destructive?: boolean;
30
48
  /** Renders a leading check mark when `true`; reserves the space (unchecked) when `false`. Omit entirely for items with no check state. */
31
49
  checked?: boolean;
50
+ /** Secondary line rendered under the label. */
51
+ meta?: ReactNode;
32
52
  }
33
53
  export interface DropdownSeparatorProps extends HTMLAttributes<HTMLDivElement>, BaseProps {
34
54
  }
@@ -0,0 +1,2 @@
1
+ import { EmptyProps } from './Empty.types';
2
+ export declare const Empty: import('react').ForwardRefExoticComponent<EmptyProps & import('react').RefAttributes<HTMLDivElement>>;
@@ -0,0 +1,12 @@
1
+ import { HTMLAttributes, ReactNode } from 'react';
2
+ import { BaseProps } from '../../types';
3
+ export type EmptySize = 'lg' | 'sm';
4
+ export interface EmptyProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title'>, BaseProps {
5
+ size?: EmptySize;
6
+ title?: ReactNode;
7
+ description?: ReactNode;
8
+ /** Defaults to a `SearchX` icon in an `IconTile` circle — pass your own illustration node to override. */
9
+ illustration?: ReactNode;
10
+ /** Slot for a call-to-action, e.g. a `<Button>`. */
11
+ action?: ReactNode;
12
+ }
@@ -0,0 +1,2 @@
1
+ export { Empty } from './Empty';
2
+ export type { EmptyProps, EmptySize } from './Empty.types';
@@ -0,0 +1,2 @@
1
+ import { FormContainerProps } from './FormContainer.types';
2
+ export declare const FormContainer: import('react').ForwardRefExoticComponent<FormContainerProps & import('react').RefAttributes<HTMLFormElement>>;
@@ -0,0 +1,18 @@
1
+ import { FormHTMLAttributes, ReactNode } from 'react';
2
+ import { FieldValues, FormState, Mode } from 'react-hook-form';
3
+ import { ObjectSchema } from 'yup';
4
+ import { BaseProps } from '../../types';
5
+ import { ButtonProps } from '../Button';
6
+ export interface FormContainerProps extends Omit<FormHTMLAttributes<HTMLFormElement>, 'onSubmit'>, BaseProps {
7
+ children?: ReactNode;
8
+ /** A yup object schema — resolved via `@hookform/resolvers/yup`. */
9
+ validationSchema: ObjectSchema<FieldValues>;
10
+ defaultValues: FieldValues;
11
+ /** Rendered as a row of `Button`s below `children` — omit and render your own footer instead. */
12
+ buttons?: ButtonProps[];
13
+ mode?: Mode;
14
+ shouldUnregister?: boolean;
15
+ shouldFocusError?: boolean;
16
+ formId?: string;
17
+ onSubmit?: (data: FieldValues, formState: FormState<FieldValues>) => void;
18
+ }
@@ -0,0 +1,2 @@
1
+ export { FormContainer } from './FormContainer';
2
+ export type { FormContainerProps } from './FormContainer.types';
@@ -0,0 +1,2 @@
1
+ import { FormFieldProps } from './FormField.types';
2
+ export declare const FormField: import('react').ForwardRefExoticComponent<FormFieldProps & import('react').RefAttributes<HTMLDivElement>>;
@@ -0,0 +1,22 @@
1
+ import { HTMLAttributes, ReactElement } from 'react';
2
+ import { RefCallBack } from 'react-hook-form';
3
+ import { BaseProps } from '../../types';
4
+ /** Deliberately untyped `value`/`onChange`: this render prop feeds whichever
5
+ * input the consumer wires up (native `value`, Select's `string`, Checkbox's
6
+ * `boolean`, ...). */
7
+ export interface FormFieldRenderProps {
8
+ name: string;
9
+ value: any;
10
+ onChange: (...event: any[]) => void;
11
+ onBlur: () => void;
12
+ ref: RefCallBack;
13
+ error: boolean;
14
+ errorText?: string;
15
+ dataTestId?: string;
16
+ }
17
+ export interface FormFieldProps extends Omit<HTMLAttributes<HTMLDivElement>, 'defaultValue'>, BaseProps {
18
+ name: string;
19
+ defaultValue?: unknown;
20
+ /** Render prop — receives field bindings plus `error`/`errorText`, e.g. `(p) => <Input {...p} label="Email" />`. */
21
+ render: (props: FormFieldRenderProps) => ReactElement;
22
+ }
@@ -0,0 +1,2 @@
1
+ export { FormField } from './FormField';
2
+ export type { FormFieldProps, FormFieldRenderProps } from './FormField.types';
@@ -3,6 +3,8 @@ import { BaseProps } from '../../types';
3
3
  export type InputSize = 'lg' | 'md' | 'sm';
4
4
  export interface InputProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size'>, BaseProps {
5
5
  label?: ReactNode;
6
+ /** Content rendered on the label row, right of the label text and required marker — e.g. an info tooltip trigger. Rendered as a sibling of the `<label>`, not a child, so an interactive addon never steals focus into the field. */
7
+ labelAddons?: ReactNode;
6
8
  helperText?: ReactNode;
7
9
  errorText?: ReactNode;
8
10
  size?: InputSize;
@@ -0,0 +1,2 @@
1
+ import { LinkProps } from './Link.types';
2
+ export declare const Link: import('react').ForwardRefExoticComponent<LinkProps & import('react').RefAttributes<HTMLAnchorElement>>;
@@ -0,0 +1,15 @@
1
+ import { AnchorHTMLAttributes, ReactNode } from 'react';
2
+ import { BaseProps } from '../../types';
3
+ import { TextColor, TextVariant, TextWeight } from '../Text';
4
+ export type LinkUnderline = 'hover' | 'always' | 'none';
5
+ export interface LinkProps extends AnchorHTMLAttributes<HTMLAnchorElement>, BaseProps {
6
+ /** Typography variant, same scale as `Text`. Default `'p-std'`. */
7
+ variant?: TextVariant;
8
+ weight?: TextWeight;
9
+ /** Semantic text color, same scale as `Text`. Default `'brand'`. */
10
+ color?: TextColor;
11
+ underline?: LinkUnderline;
12
+ leftIcon?: ReactNode;
13
+ rightIcon?: ReactNode;
14
+ truncate?: boolean;
15
+ }
@@ -0,0 +1,2 @@
1
+ export { Link } from './Link';
2
+ export type { LinkProps, LinkUnderline } from './Link.types';
@@ -18,6 +18,10 @@ export interface MultiSelectProps extends BaseProps {
18
18
  /** Selected option values (controlled). */
19
19
  value: string[];
20
20
  onChange: (values: string[]) => void;
21
+ /** Called with the option that was just added, alongside `onChange` (never instead of it). */
22
+ onAdd?: (option: MultiSelectOption) => void;
23
+ /** Called with the value that was just removed, alongside `onChange` (never instead of it). */
24
+ onRemove?: (value: string) => void;
21
25
  size?: MultiSelectSize;
22
26
  placeholder?: string;
23
27
  /** Placeholder once at least one chip exists. Defaults to "Add another…". */
@@ -25,6 +29,8 @@ export interface MultiSelectProps extends BaseProps {
25
29
  disabled?: boolean;
26
30
  error?: boolean;
27
31
  label?: ReactNode;
32
+ /** Content rendered on the label row, right of the label text and required marker — e.g. an info tooltip trigger. Rendered as a sibling of the `<label>`, not a child, so an interactive addon never steals focus into the field. */
33
+ labelAddons?: ReactNode;
28
34
  helperText?: ReactNode;
29
35
  errorText?: ReactNode;
30
36
  required?: boolean;
@@ -32,6 +38,8 @@ export interface MultiSelectProps extends BaseProps {
32
38
  lockedValues?: string[];
33
39
  /** Cap on how many can be selected (default: unlimited). */
34
40
  max?: number;
41
+ /** Renders an Avatar on every chip and dropdown row, falling back to initials derived from the option's `label` when it has no `avatarSrc`. Default `false` — avatars still render for options that already set `avatarSrc` regardless. */
42
+ showAvatars?: boolean;
35
43
  /** Set false for a click-to-open picker with no text filter. */
36
44
  searchable?: boolean;
37
45
  /** Dropdown header shown when the query is empty. */
@@ -0,0 +1,2 @@
1
+ import { PopoverProps } from './Popover.types';
2
+ export declare function Popover({ content, children, side, align, offset, open, defaultOpen, onOpenChange, flip, showArrow, closeOnScroll, autoFocus, container, className, dataTestId, }: PopoverProps): import("react").JSX.Element;
@@ -0,0 +1,29 @@
1
+ import { ReactElement, ReactNode } from 'react';
2
+ import { BaseProps } from '../../types';
3
+ import { FloatingAlign, FloatingSide } from '../../lib/useFloatingPosition';
4
+ export type PopoverSide = FloatingSide;
5
+ export type PopoverAlign = FloatingAlign;
6
+ export interface PopoverProps extends BaseProps {
7
+ /** Bubble content. May contain interactive elements — unlike `Tooltip`, the bubble is not `pointer-events-none`. */
8
+ content: ReactNode;
9
+ /** Single trigger element; `Popover` attaches an `onClick` (composed with any the child already has) plus `aria-expanded`/`aria-haspopup`. */
10
+ children: ReactElement;
11
+ side?: PopoverSide;
12
+ align?: PopoverAlign;
13
+ /** Gap between the trigger and the bubble, in px. Default `8`. */
14
+ offset?: number;
15
+ /** Controlled open state. Pass alongside `onOpenChange` to fully control the popover. */
16
+ open?: boolean;
17
+ defaultOpen?: boolean;
18
+ onOpenChange?: (open: boolean) => void;
19
+ /** Flips to the opposite side on the same axis when there isn't room. Default `true`. */
20
+ flip?: boolean;
21
+ showArrow?: boolean;
22
+ /** Closes the popover when any ancestor scrolls. Default `true`. */
23
+ closeOnScroll?: boolean;
24
+ /** Moves focus into the bubble on open, restoring it to the trigger on close. Default `false` — there is no focus trap in v1, so use sparingly for content that's genuinely keyboard-operable. */
25
+ autoFocus?: boolean;
26
+ className?: string;
27
+ /** Portal target. Defaults to `document.body`. */
28
+ container?: HTMLElement | null;
29
+ }
@@ -0,0 +1,2 @@
1
+ export { Popover } from './Popover';
2
+ export type { PopoverAlign, PopoverProps, PopoverSide } from './Popover.types';
@@ -0,0 +1,2 @@
1
+ import { ReadMoreProps } from './ReadMore.types';
2
+ export declare const ReadMore: import('react').ForwardRefExoticComponent<ReadMoreProps & import('react').RefAttributes<HTMLDivElement>>;
@@ -0,0 +1,17 @@
1
+ import { HTMLAttributes, ReactNode } from 'react';
2
+ import { BaseProps } from '../../types';
3
+ import { TextProps } from '../Text';
4
+ export interface ReadMoreProps extends Omit<HTMLAttributes<HTMLDivElement>, 'children'>, BaseProps {
5
+ children: ReactNode;
6
+ /** Lines shown while collapsed. Default `3`. Ignored when `collapsedContent` supplies its own text. */
7
+ clamp?: number;
8
+ /** Escape hatch for collapsed copy that genuinely differs from `children`, rather than just clamping it. */
9
+ collapsedContent?: ReactNode;
10
+ expandLabel?: ReactNode;
11
+ collapseLabel?: ReactNode;
12
+ defaultExpanded?: boolean;
13
+ expanded?: boolean;
14
+ onExpandedChange?: (expanded: boolean) => void;
15
+ /** Typography passed through to the underlying `Text`. */
16
+ textProps?: Pick<TextProps, 'variant' | 'weight' | 'color'>;
17
+ }
@@ -0,0 +1,2 @@
1
+ export { ReadMore } from './ReadMore';
2
+ export type { ReadMoreProps } from './ReadMore.types';
@@ -13,6 +13,8 @@ export interface SelectProps extends BaseProps {
13
13
  onChange?: (value: string) => void;
14
14
  placeholder?: string;
15
15
  label?: ReactNode;
16
+ /** Content rendered on the label row, right of the label text — e.g. an info tooltip trigger. Rendered as a sibling of the `<label>`, not a child, so an interactive addon never steals focus into the trigger. */
17
+ labelAddons?: ReactNode;
16
18
  helperText?: ReactNode;
17
19
  errorText?: ReactNode;
18
20
  error?: boolean;
@@ -0,0 +1,2 @@
1
+ import { StepIndicatorProps } from './StepIndicator.types';
2
+ export declare const StepIndicator: import('react').ForwardRefExoticComponent<StepIndicatorProps & import('react').RefAttributes<HTMLOListElement>>;
@@ -0,0 +1,24 @@
1
+ import { HTMLAttributes, ReactNode } from 'react';
2
+ import { BaseProps } from '../../types';
3
+ export type StepIndicatorStatus = 'upcoming' | 'active' | 'completed' | 'rejected';
4
+ export type StepIndicatorMarker = 'number' | 'dot' | 'icon';
5
+ export type StepIndicatorOrientation = 'horizontal' | 'vertical';
6
+ export type StepIndicatorSize = 'lg' | 'sm';
7
+ export interface StepIndicatorItem {
8
+ value: string | number;
9
+ label: ReactNode;
10
+ description?: ReactNode;
11
+ status?: StepIndicatorStatus;
12
+ /** Halo ring around the marker — an orthogonal emphasis flag, independent of `status` (e.g. a completed step still awaiting review). */
13
+ highlighted?: boolean;
14
+ }
15
+ export interface StepIndicatorProps extends Omit<HTMLAttributes<HTMLOListElement>, 'children'>, BaseProps {
16
+ steps: StepIndicatorItem[];
17
+ /** Marks the matching step `aria-current="step"`. */
18
+ activeValue?: string | number;
19
+ /** Wraps each marker in a `<button>` when set. Omit to render a non-interactive indicator. */
20
+ onStepSelect?: (value: string | number) => void;
21
+ marker?: StepIndicatorMarker;
22
+ orientation?: StepIndicatorOrientation;
23
+ size?: StepIndicatorSize;
24
+ }
@@ -0,0 +1,2 @@
1
+ export { StepIndicator } from './StepIndicator';
2
+ export type { StepIndicatorItem, StepIndicatorMarker, StepIndicatorOrientation, StepIndicatorProps, StepIndicatorSize, StepIndicatorStatus, } from './StepIndicator.types';
@@ -1,5 +1,6 @@
1
1
  import { ButtonHTMLAttributes, HTMLAttributes, ReactNode } from 'react';
2
2
  import { BaseProps } from '../../types';
3
+ import { BadgeProps } from '../Badge';
3
4
  export type TabsVariant = 'underline' | 'pills' | 'boxed';
4
5
  export type TabsSize = 'lg' | 'md' | 'sm';
5
6
  export interface TabsProps extends HTMLAttributes<HTMLDivElement>, BaseProps {
@@ -10,8 +11,12 @@ export interface TabsProps extends HTMLAttributes<HTMLDivElement>, BaseProps {
10
11
  onValueChange?: (value: string) => void;
11
12
  variant?: TabsVariant;
12
13
  size?: TabsSize;
14
+ /** Disables every tab in the bar at once. OR'd with each `Tab`'s own `disabled`. */
15
+ disabled?: boolean;
13
16
  }
14
17
  export interface TabListProps extends HTMLAttributes<HTMLDivElement>, BaseProps {
18
+ /** Horizontally scrolls the bar when tabs overflow, instead of wrapping. */
19
+ scrollable?: boolean;
15
20
  }
16
21
  export interface TabProps extends ButtonHTMLAttributes<HTMLButtonElement>, BaseProps {
17
22
  /** Unique identifier matched against the parent `Tabs`'s active value. */
@@ -19,8 +24,18 @@ export interface TabProps extends ButtonHTMLAttributes<HTMLButtonElement>, BaseP
19
24
  icon?: ReactNode;
20
25
  /** Count/indicator rendered after the label. Hidden when `undefined`, `null`, or `false`. */
21
26
  badge?: ReactNode;
27
+ /** Styles `badge` through `Badge` instead of the default fixed-style count pill. Omit to keep the default. */
28
+ badgeProps?: Pick<BadgeProps, 'variant' | 'appearance' | 'size'>;
29
+ /** Trailing icon rendered as its own button — e.g. a close-tab X. Rendered as a sibling of the tab button, not a nested one (nesting a button inside a button is invalid HTML). */
30
+ rightIcon?: ReactNode;
31
+ /** Called with this tab's `value` when `rightIcon` is clicked. Does not activate the tab. */
32
+ onRightIconClick?: (value: string) => void;
33
+ /** Accessible name for the `rightIcon` button. Required when `rightIcon` is set. */
34
+ rightIconLabel?: string;
22
35
  }
23
36
  export interface TabPanelProps extends HTMLAttributes<HTMLDivElement>, BaseProps {
24
- /** Matched against the parent `Tabs`'s active value; renders nothing (unmounted) when not active. */
37
+ /** Matched against the parent `Tabs`'s active value; hidden (or unmounted, depending on `keepMounted`) when not active. */
25
38
  value: string;
39
+ /** Keeps the panel mounted (hidden via the `hidden` attribute) while inactive, instead of unmounting it — preserves scroll position and in-panel state across tab switches. */
40
+ keepMounted?: boolean;
26
41
  }
@@ -12,4 +12,6 @@ export interface TextProps extends HTMLAttributes<HTMLElement>, BaseProps {
12
12
  as?: ElementType;
13
13
  /** Truncate to a single line with ellipsis. */
14
14
  truncate?: boolean;
15
+ /** Truncate to this many lines with ellipsis (CSS line-clamp). Ignored when `truncate` is set. */
16
+ clamp?: number;
15
17
  }
@@ -2,6 +2,8 @@ import { TextareaHTMLAttributes, ReactNode } from 'react';
2
2
  import { BaseProps } from '../../types';
3
3
  export interface TextAreaProps extends TextareaHTMLAttributes<HTMLTextAreaElement>, BaseProps {
4
4
  label?: ReactNode;
5
+ /** Content rendered on the label row, right of the label text and required marker — e.g. an info tooltip trigger. Rendered as a sibling of the `<label>`, not a child, so an interactive addon never steals focus into the field. */
6
+ labelAddons?: ReactNode;
5
7
  helperText?: ReactNode;
6
8
  errorText?: ReactNode;
7
9
  error?: boolean;
@@ -0,0 +1,2 @@
1
+ import { ThemeSwitchProps } from './ThemeSwitch.types';
2
+ export declare const ThemeSwitch: import('react').ForwardRefExoticComponent<ThemeSwitchProps & import('react').RefAttributes<HTMLInputElement>>;
@@ -0,0 +1,7 @@
1
+ import { InputHTMLAttributes, ReactNode } from 'react';
2
+ import { BaseProps } from '../../types';
3
+ export interface ThemeSwitchProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size' | 'type'>, BaseProps {
4
+ /** `true` renders the "dark" thumb position. Purely presentational — `ThemeSwitch` owns no theme state; wire `onChange` to your own theme toggle. */
5
+ checked?: boolean;
6
+ label?: ReactNode;
7
+ }
@@ -0,0 +1,2 @@
1
+ export { ThemeSwitch } from './ThemeSwitch';
2
+ export type { ThemeSwitchProps } from './ThemeSwitch.types';
@@ -0,0 +1,2 @@
1
+ import { UnderConstructionProps } from './UnderConstruction.types';
2
+ export declare const UnderConstruction: import('react').ForwardRefExoticComponent<UnderConstructionProps & import('react').RefAttributes<HTMLDivElement>>;
@@ -0,0 +1,12 @@
1
+ import { HTMLAttributes, ReactNode } from 'react';
2
+ import { BaseProps } from '../../types';
3
+ export type UnderConstructionSize = 'lg' | 'sm';
4
+ export interface UnderConstructionProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title'>, BaseProps {
5
+ size?: UnderConstructionSize;
6
+ /** Defaults to "We'll be back soon" — pass a translated string for other locales. */
7
+ title?: ReactNode;
8
+ /** Defaults to a generic maintenance message — pass a translated string for other locales. */
9
+ description?: ReactNode;
10
+ /** Defaults to a `Construction` icon in an `IconTile` circle — pass your own illustration node to override. */
11
+ illustration?: ReactNode;
12
+ }
@@ -0,0 +1,2 @@
1
+ export { UnderConstruction } from './UnderConstruction';
2
+ export type { UnderConstructionProps, UnderConstructionSize } from './UnderConstruction.types';