@central-ui/react 0.2.0 → 0.4.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 (79) hide show
  1. package/dist/components/accordion/index.d.ts +14 -14
  2. package/dist/components/accordion/index.js +19 -19
  3. package/dist/components/autocomplete/index.d.ts +57 -49
  4. package/dist/components/autocomplete/index.js +69 -60
  5. package/dist/components/avatar/index.d.ts +7 -6
  6. package/dist/components/avatar/index.js +9 -9
  7. package/dist/components/banner/index.js +1 -1
  8. package/dist/components/carousel/index.d.ts +189 -0
  9. package/dist/components/carousel/index.js +303 -0
  10. package/dist/components/checkbox/index.d.ts +12 -11
  11. package/dist/components/checkbox/index.js +21 -21
  12. package/dist/components/combobox/index.d.ts +67 -71
  13. package/dist/components/combobox/index.js +80 -72
  14. package/dist/components/datepicker/index.d.ts +8 -9
  15. package/dist/components/datepicker/index.js +13 -13
  16. package/dist/components/dialog/index.d.ts +18 -18
  17. package/dist/components/dialog/index.js +22 -21
  18. package/dist/components/drawer/index.d.ts +24 -24
  19. package/dist/components/drawer/index.js +28 -27
  20. package/dist/components/empty/index.d.ts +2 -1
  21. package/dist/components/empty/index.js +2 -1
  22. package/dist/components/exception/index.d.ts +98 -0
  23. package/dist/components/exception/index.js +116 -0
  24. package/dist/components/fileupload/index.d.ts +8 -8
  25. package/dist/components/input/index.d.ts +14 -14
  26. package/dist/components/input/index.js +27 -27
  27. package/dist/components/menu/index.d.ts +37 -37
  28. package/dist/components/menu/index.js +47 -47
  29. package/dist/components/numberinput/index.d.ts +22 -22
  30. package/dist/components/numberinput/index.js +35 -35
  31. package/dist/components/otpinput/index.d.ts +12 -12
  32. package/dist/components/otpinput/index.js +21 -21
  33. package/dist/components/passwordinput/index.d.ts +15 -15
  34. package/dist/components/passwordinput/index.js +27 -27
  35. package/dist/components/popover/index.d.ts +16 -16
  36. package/dist/components/popover/index.js +20 -19
  37. package/dist/components/radio/index.d.ts +12 -12
  38. package/dist/components/radio/index.js +25 -25
  39. package/dist/components/ratinginput/index.d.ts +1 -1
  40. package/dist/components/ratinginput/index.js +3 -3
  41. package/dist/components/select/index.d.ts +32 -29
  42. package/dist/components/select/index.js +45 -35
  43. package/dist/components/slider/index.d.ts +20 -20
  44. package/dist/components/slider/index.js +27 -27
  45. package/dist/components/stepper/index.d.ts +8 -7
  46. package/dist/components/stepper/index.js +4 -2
  47. package/dist/components/switch/index.d.ts +9 -9
  48. package/dist/components/switch/index.js +17 -17
  49. package/dist/components/table/index.d.ts +2 -2
  50. package/dist/components/table/index.js +16 -16
  51. package/dist/components/tabs/index.d.ts +10 -10
  52. package/dist/components/tabs/index.js +11 -11
  53. package/dist/components/textarea/index.d.ts +13 -13
  54. package/dist/components/textarea/index.js +25 -25
  55. package/dist/components/toast/index.d.ts +11 -11
  56. package/dist/components/toast/index.js +11 -11
  57. package/dist/components/toggle/index.d.ts +7 -7
  58. package/dist/components/toggle/index.js +9 -9
  59. package/dist/components/tooltip/index.d.ts +6 -6
  60. package/dist/components/tooltip/index.js +6 -7
  61. package/dist/components/tour/index.d.ts +2 -2
  62. package/dist/components/tour/index.js +5 -4
  63. package/dist/index.d.ts +2 -0
  64. package/dist/index.js +2 -0
  65. package/dist/utils/icons.d.ts +92 -23
  66. package/dist/utils/icons.js +3 -3
  67. package/package.json +69 -67
  68. package/src/presets/shopify-polaris/shopify-polaris-accordion.css +28 -28
  69. package/src/presets/shopify-polaris/shopify-polaris-carousel.css +62 -0
  70. package/src/presets/shopify-polaris/shopify-polaris-exception.css +40 -0
  71. package/src/presets/shopify-polaris/shopify-polaris.css +2 -0
  72. package/src/presets/shopify-polaris-legacy/shopify-polaris-legacy-accordion.css +28 -28
  73. package/src/presets/shopify-polaris-legacy/shopify-polaris-legacy-carousel.css +55 -0
  74. package/src/presets/shopify-polaris-legacy/shopify-polaris-legacy-exception.css +40 -0
  75. package/src/presets/shopify-polaris-legacy/shopify-polaris-legacy.css +2 -0
  76. package/dist/types/Tone.d.ts +0 -3
  77. package/dist/types/Tone.js +0 -1
  78. package/dist/utils/Tone.d.ts +0 -2
  79. package/dist/utils/Tone.js +0 -6
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { Checkbox as BaseCheckbox } from '@base-ui/react/checkbox';
3
3
  import { CheckboxGroup as BaseCheckboxGroup } from '@base-ui/react/checkbox-group';
4
- import { createContext, forwardRef, useContext, useEffect, useId, useState, } from 'react';
4
+ import { createContext, useContext, useEffect, useId, useState, } from 'react';
5
5
  import { Check, Minus } from "../../utils/icons.js";
6
6
  import { readValidation, validationAttributes, validationMessageContent } from "../../utils/Validation.js";
7
7
  /**
@@ -62,20 +62,20 @@ export function Root({ children, id, validation, ...coreProps }) {
62
62
  }, children: children }));
63
63
  }
64
64
  /** Optional: controls multiple checkboxes as a native array of checked values. Put individual Roots inside and give each child a value. For a select-all checkbox, use parent on its Root and provide allValues on this controlled group; Base UI derives checked and indeterminate automatically. */
65
- export const CheckboxGroup = /* @__PURE__ */ forwardRef(function CheckboxGroup({ disableStyle, className, ...props }, ref) {
65
+ export function CheckboxGroup({ disableStyle, className, ref, ...props }) {
66
66
  return (_jsx(BaseCheckboxGroup, { ...props, ref: ref, "data-component": "checkbox-checkboxgroup", "data-style-disabled": disableStyle ? '' : undefined, className: className }));
67
- });
68
- export const Container = /* @__PURE__ */ forwardRef(function Container({ disableStyle, className, ...props }, ref) {
67
+ }
68
+ export function Container({ disableStyle, className, ref, ...props }) {
69
69
  return (_jsx("div", { ...props, ref: ref, "data-component": "checkbox-container", "data-style-disabled": disableStyle ? '' : undefined, className: className }));
70
- });
71
- export const Button = /* @__PURE__ */ forwardRef(function Button({ disableStyle, className, ...props }, ref) {
70
+ }
71
+ export function Button({ disableStyle, className, ref, ...props }) {
72
72
  const context = useCheckboxContext();
73
73
  return (_jsx(BaseCheckbox.Root, { ...props, ...context.coreProps, ref: ref, ...validationAttributes(context.validation), "aria-invalid": context.validation.state === 'error' || props['aria-invalid'] || undefined, "aria-describedby": [props['aria-describedby'], ...context.messageIds]
74
74
  .filter(Boolean)
75
75
  .join(' ') || undefined, "data-component": "checkbox-button", "data-style-disabled": disableStyle ? '' : undefined, className: className, render: (buttonProps, state) => (_jsx(CheckboxButtonSurface, { ...buttonProps, state: state })) }));
76
- });
76
+ }
77
77
  /** Tracks the surrounding item state automatically. Keep it mounted; do not add your own visibility condition. Use the supplied default visual unless customization is needed. */
78
- export const Indicator = /* @__PURE__ */ forwardRef(function Indicator({ disableStyle, className, ...props }, ref) {
78
+ export function Indicator({ disableStyle, className, ref, ...props }) {
79
79
  return (_jsx(BaseCheckbox.Indicator, { ...props, ref: ref, "data-component": "checkbox-indicator", "data-style-disabled": disableStyle ? '' : undefined, className: className, render: (indicatorProps, state) => (_jsx("span", { ...indicatorProps, children: (() => {
80
80
  if (state.indeterminate)
81
81
  return _jsx(Minus, { "aria-hidden": true, strokeWidth: 3.5, "data-component": "checkbox-indicator-1" });
@@ -83,37 +83,37 @@ export const Indicator = /* @__PURE__ */ forwardRef(function Indicator({ disable
83
83
  return _jsx(Check, { "aria-hidden": true, strokeWidth: 3.5, "data-component": "checkbox-indicator-2" });
84
84
  return null;
85
85
  })() })) }));
86
- });
86
+ }
87
87
  /** Labels the associated control automatically. Supply the visible text; do not wire a second label association. */
88
- export const Label = /* @__PURE__ */ forwardRef(function Label({ disableStyle, className, ...props }, ref) {
88
+ export function Label({ disableStyle, className, ref, ...props }) {
89
89
  const context = useCheckboxContext();
90
90
  return (_jsx("label", { ...usePartAttributes(), ...props, ref: ref, htmlFor: context.coreProps.id, "data-component": "checkbox-label", "data-style-disabled": disableStyle ? '' : undefined, className: className }));
91
- });
92
- export const Description = /* @__PURE__ */ forwardRef(function Description({ disableStyle, className, id, ...props }, ref) {
91
+ }
92
+ export function Description({ disableStyle, className, id, ref, ...props }) {
93
93
  const messageId = useMessageId(id);
94
94
  return (_jsx("span", { ...usePartAttributes(), ...props, ref: ref, id: messageId, "data-component": "checkbox-description", "data-style-disabled": disableStyle ? '' : undefined, className: className }));
95
- });
95
+ }
96
96
  /** Shows itself only while Root's validation is `'error'`: with no children it shows the message from `['error', message]`, a function children formats that message, and other children replace it. */
97
- export const Error = /* @__PURE__ */ forwardRef(function Error({ children, ...props }, ref) {
97
+ export function Error({ children, ref, ...props }) {
98
98
  const context = useCheckboxContext();
99
99
  const content = validationMessageContent(context.validation, 'error', children);
100
100
  if (content === undefined)
101
101
  return null;
102
102
  return _jsx(Message, { ...props, ref: ref, role: "alert", component: "checkbox-error", children: content });
103
- });
103
+ }
104
104
  /** Shows itself only while Root's validation is `'success'`: with no children it shows the message from `['success', message]`, a function children formats that message, and other children replace it. */
105
- export const Success = /* @__PURE__ */ forwardRef(function Success({ children, ...props }, ref) {
105
+ export function Success({ children, ref, ...props }) {
106
106
  const context = useCheckboxContext();
107
107
  const content = validationMessageContent(context.validation, 'success', children);
108
108
  if (content === undefined)
109
109
  return null;
110
110
  return _jsx(Message, { ...props, ref: ref, role: "status", component: "checkbox-success", children: content });
111
- });
111
+ }
112
112
  // The shared body of Error and Success, mounted only while they show, so only visible messages describe the checkbox
113
- const Message = /* @__PURE__ */ forwardRef(function Message({ disableStyle, className, id, component, ...props }, ref) {
113
+ function Message({ disableStyle, className, id, component, ref, ...props }) {
114
114
  const messageId = useMessageId(id);
115
115
  return _jsx("span", { "aria-atomic": "true", ...usePartAttributes(), ...props, ref: ref, id: messageId, "data-component": component, "data-style-disabled": disableStyle ? '' : undefined, className: className });
116
- });
116
+ }
117
117
  const CheckboxContext = /* @__PURE__ */ createContext(null);
118
118
  function useCheckboxContext() {
119
119
  const context = useContext(CheckboxContext);
@@ -133,7 +133,7 @@ function usePartAttributes() {
133
133
  };
134
134
  }
135
135
  // Rendered by Base UI as the checkbox element, it reports Base UI's live state back to Root's mirror
136
- const CheckboxButtonSurface = /* @__PURE__ */ forwardRef(function CheckboxButtonSurface({ state, ...props }, ref) {
136
+ function CheckboxButtonSurface({ state, ref, ...props }) {
137
137
  const context = useCheckboxContext();
138
138
  useEffect(() => {
139
139
  context.setState({
@@ -152,7 +152,7 @@ const CheckboxButtonSurface = /* @__PURE__ */ forwardRef(function CheckboxButton
152
152
  context.setState,
153
153
  ]);
154
154
  return _jsx("span", { ...props, ref: ref });
155
- });
155
+ }
156
156
  // Registering a message part's id in Button's aria-describedby while the part is mounted
157
157
  function useMessageId(id) {
158
158
  const generatedId = useId();
@@ -3,6 +3,10 @@ import { Combobox as BaseCombobox } from '@base-ui/react/combobox';
3
3
  import type { ValidationProps } from '../../types/Validation.ts';
4
4
  import type { ComponentProps, ComponentPropsWithRef, ReactElement, ReactNode } from 'react';
5
5
  import type { ValidationMessageChildren } from '../../utils/Validation.ts';
6
+ type IconProps = Omit<SVGIconProps, 'strokeWidth'> & {
7
+ /** @default 1.5 */
8
+ strokeWidth?: SVGIconProps['strokeWidth'];
9
+ };
6
10
  type StyleProps = {
7
11
  /**
8
12
  * Disables preset styling for this element.
@@ -208,14 +212,14 @@ export type RootProps<T extends readonly GroupShape[], Multiple extends boolean
208
212
  */
209
213
  export declare function Root<T extends readonly GroupShape[], Multiple extends boolean | undefined = false>({ children, id, validation, defaultOpen, onOpenChange, ...props }: RootProps<T, Multiple>): import("react").JSX.Element;
210
214
  /** Use for the standard stacked layout, or omit when supplying your own layout. */
211
- export declare const Container: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & StyleProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
215
+ export declare function Container({ disableStyle, className, ref, ...props }: ComponentProps<'div'> & StyleProps): import("react").JSX.Element;
212
216
  /** Labels the input automatically using Root's id. Supply the visible label as children; no htmlFor needed. */
213
- export declare const Label: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").DetailedHTMLProps<import("react").LabelHTMLAttributes<HTMLLabelElement>, HTMLLabelElement>, "htmlFor"> & StyleProps, "ref"> & import("react").RefAttributes<HTMLLabelElement>>;
217
+ export declare function Label({ disableStyle, className, ref, ...props }: Omit<ComponentProps<'label'>, 'htmlFor'> & StyleProps): import("react").JSX.Element;
214
218
  /** Search input with built-in filtering and selected-label display. Its id is managed by Root. Inside ChipsList, the preset automatically uses the compact chip-input sizing. */
215
- export declare const Input: import("react").ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").AutocompleteInputProps, "className" | "id"> & {
219
+ export declare function Input({ disableStyle, className, 'aria-describedby': describedBy, ref, ...props }: (Omit<BaseCombobox.Input.Props, 'id' | 'className' | 'render'> & {
216
220
  className?: string;
217
- } & StyleProps, "ref"> & import("react").RefAttributes<HTMLInputElement>>;
218
- export type ChipsListProps<Item extends ItemShape = ItemShape> = Omit<ComponentPropsWithRef<typeof BaseCombobox.Chips>, 'children' | 'className'> & {
221
+ }) & StyleProps): import("react").JSX.Element;
222
+ export type ChipsListProps<Item extends ItemShape = ItemShape> = Omit<ComponentPropsWithRef<typeof BaseCombobox.Chips>, 'children' | 'className' | 'render'> & {
219
223
  className?: string;
220
224
  /**
221
225
  * Keep Input after the chips so keyboard navigation can move between them.
@@ -251,16 +255,16 @@ export type ChipsListProps<Item extends ItemShape = ItemShape> = Omit<ComponentP
251
255
  * </Combobox.ChipsList>
252
256
  * </Combobox.InputGroup>
253
257
  */
254
- export declare const ChipsList: <Item extends ItemShape = ItemShape>(props: ChipsListProps<Item>) => ReactElement;
258
+ export declare function ChipsList<Item extends ItemShape = ItemShape>({ disableStyle, children, className, ref, ...props }: ChipsListProps<Item>): import("react").JSX.Element;
255
259
  /** Reads Base UI selection without rendering its own element. Use its children callback only when you need a custom selection display; Input already displays the selected label automatically. */
256
260
  export declare const Value: typeof BaseCombobox.Value;
257
- export type ScrollAreaProps = Omit<ComponentPropsWithRef<typeof BaseCombobox.List>, 'children' | 'className'> & {
261
+ export type ScrollAreaProps = Omit<ComponentPropsWithRef<typeof BaseCombobox.List>, 'children' | 'className' | 'render'> & {
258
262
  className?: string;
259
263
  /** Required groups composition. Use GroupsList rather than another listbox primitive. */
260
264
  children?: ReactNode;
261
265
  } & StyleProps;
262
266
  /** Required listbox and scroll viewport inside Popup. Place GroupsList inside it. Owns keyboard/listbox semantics; do not nest another listbox primitive. */
263
- export declare const ScrollArea: import("react").ForwardRefExoticComponent<Omit<ScrollAreaProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
267
+ export declare function ScrollArea({ disableStyle, className, ref, ...props }: ScrollAreaProps): import("react").JSX.Element;
264
268
  export type GroupsListProps<Group extends GroupShape = GroupShape> = Omit<ComponentPropsWithRef<'div'>, 'children'> & {
265
269
  /**
266
270
  * Return Group with its ItemsList; the collection already performs filtering.
@@ -284,21 +288,21 @@ export type ItemsListProps<Item extends ItemShape = ItemShape> = Omit<ComponentP
284
288
  } & StyleProps;
285
289
  /** Required items container inside Group. A children callback receives the filtered items belonging to that Group; do not repeat filtering yourself. Manually annotate item with Combobox.ItemType<typeof rootItems>, using the exact items variable passed to Root. */
286
290
  export declare function ItemsList<Item extends ItemShape = ItemShape>({ disableStyle, children, className, ...props }: ItemsListProps<Item>): import("react").JSX.Element;
287
- export type GroupProps<Item extends ItemShape = ItemShape> = Omit<ComponentPropsWithRef<typeof BaseCombobox.Group>, 'items' | 'className'> & {
291
+ export type GroupProps<Item extends ItemShape = ItemShape> = Omit<ComponentPropsWithRef<typeof BaseCombobox.Group>, 'items' | 'className' | 'render'> & {
288
292
  className?: string;
289
293
  /** Items for this group; pass group.items from GroupsList. Required even for a flat list. */
290
294
  items: readonly Item[];
291
295
  } & StyleProps;
292
296
  /** Required wrapper around ItemsList, even for a visually flat list. Pass group.items. A GroupLabel is optional; omit it when the group has an empty label. */
293
297
  export declare function Group<Item extends ItemShape = ItemShape>({ disableStyle, className, ...props }: GroupProps<Item>): import("react").JSX.Element;
294
- export type ItemProps<Item extends ItemShape = ItemShape> = Omit<ComponentPropsWithRef<typeof BaseCombobox.Item>, 'value' | 'className'> & {
298
+ export type ItemProps<Item extends ItemShape = ItemShape> = Omit<ComponentPropsWithRef<typeof BaseCombobox.Item>, 'value' | 'className' | 'render'> & {
295
299
  className?: string;
296
300
  /** Pass the item supplied by ItemsList so selection can match it by item.value. */
297
301
  value: Item;
298
302
  } & StyleProps;
299
303
  /** Required selectable row inside ItemsList. Pass the complete item object as value, with ItemText and ItemIndicator inside. Selection, highlighting, and keyboard behavior are built in. */
300
304
  export declare function Item<Item extends ItemShape = ItemShape>({ disableStyle, className, ...props }: ItemProps<Item>): import("react").JSX.Element;
301
- export type PopupProps = Omit<ComponentPropsWithRef<typeof BaseCombobox.Popup>, 'className'> & {
305
+ export type PopupProps = Omit<ComponentPropsWithRef<typeof BaseCombobox.Popup>, 'className' | 'render'> & {
302
306
  className?: string;
303
307
  } & Pick<BaseCombobox.Portal.Props, 'container' | 'keepMounted'> & Pick<BaseCombobox.Positioner.Props, 'anchor' | 'positionMethod' | 'alignOffset' | 'collisionBoundary' | 'collisionPadding' | 'sticky' | 'arrowPadding' | 'disableAnchorTracking' | 'collisionAvoidance'> & {
304
308
  /** Preferred popup side; collision handling may choose another side. @default 'bottom' */
@@ -311,105 +315,97 @@ export type PopupProps = Omit<ComponentPropsWithRef<typeof BaseCombobox.Popup>,
311
315
  /** Popup containing Empty, an optional Loading message, and ScrollArea, in that order. Already includes the portal and positioner: do not add either yourself. Defaults to bottom/start with a 5px gap. Core available-space and anchor-width inline styles stay active when preset styling is disabled. */
312
316
  export declare function Popup({ disableStyle, container, keepMounted, anchor, positionMethod, side, sideOffset, align, alignOffset, collisionBoundary, collisionPadding, sticky, arrowPadding, disableAnchorTracking, collisionAvoidance, className, style, ...props }: PopupProps): import("react").JSX.Element;
313
317
  /** Optional decorative popup arrow. Place inside Popup; the SVG and direction handling are supplied. No children needed. */
314
- export declare const Arrow: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").SVGProps<SVGSVGElement>, "children" | "dangerouslySetInnerHTML"> & StyleProps, "ref"> & import("react").RefAttributes<SVGSVGElement>>;
318
+ export declare function Arrow({ disableStyle, className, style, ref, ...props }: Omit<ComponentProps<'svg'>, 'children' | 'dangerouslySetInnerHTML'> & StyleProps): import("react").JSX.Element;
315
319
  /** Optional input adornment container inside InputGroup. Wraps icons, text, or buttons without adding trigger behavior. */
316
- export declare const Addon: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & {
320
+ export declare function Addon({ disableStyle, variant, className, ref, ...props }: (ComponentProps<'div'> & {
317
321
  /** Preset adornment appearance. Does not add button behavior. @default 'normal' */
318
- variant?: "normal" | "emphasized";
319
- } & StyleProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
322
+ variant?: 'normal' | 'emphasized';
323
+ }) & StyleProps): import("react").JSX.Element;
320
324
  /** Clones one supplied icon element, forwarding its ref and preserving its classes. Decorative only; does not open the popup or perform an action. */
321
- export declare const AddonIcon: import("react").ForwardRefExoticComponent<Omit<Omit<SVGIconProps, "strokeWidth"> & {
322
- /** @default 1.5 */
323
- strokeWidth?: SVGIconProps["strokeWidth"];
324
- } & {
325
+ export declare function AddonIcon({ disableStyle, children, className, strokeWidth, ref, ...props }: (IconProps & {
325
326
  /** One icon element to clone. Its own className is preserved. */
326
327
  children: ReactElement<SVGIconProps>;
327
- } & StyleProps, "ref"> & import("react").RefAttributes<SVGSVGElement>>;
328
+ }) & StyleProps): ReactElement<SVGIconProps & {
329
+ 'data-component'?: string;
330
+ 'data-style-disabled'?: string;
331
+ }, string | import("react").JSXElementConstructor<any>>;
328
332
  /** Optional general-purpose button inside Addon. Supply its action yourself. Automatically disabled when Root is disabled or readOnly; defaults to type="button". */
329
- export declare const AddonButton: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "type" | "disabled"> & {
333
+ export declare function AddonButton({ disableStyle, className, disabled, type, ref, ...props }: Omit<ComponentProps<'button'>, 'type' | 'disabled'> & {
330
334
  /** Button type. @default 'button' */
331
- type?: ComponentProps<"button">["type"];
335
+ type?: ComponentProps<'button'>['type'];
332
336
  /** Disables this button. Root disabled or readOnly also disables it automatically. */
333
- disabled?: ComponentProps<"button">["disabled"];
334
- } & StyleProps, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
337
+ disabled?: ComponentProps<'button'>['disabled'];
338
+ } & StyleProps): import("react").JSX.Element;
335
339
  /** Input control wrapper. Place Input (or ChipsList containing Input) and optional Addon controls inside. Root validation controls its preset validation border. */
336
- export declare const InputGroup: import("react").ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").ComboboxInputGroupProps, "className"> & {
340
+ export declare function InputGroup({ disableStyle, className, ref, ...props }: (Omit<BaseCombobox.InputGroup.Props, 'className' | 'render'> & {
337
341
  className?: string;
338
- } & StyleProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
342
+ }) & StyleProps): import("react").JSX.Element;
339
343
  /** Displays one selected item inside ChipsList. Keep chips in selected-item order so Base UI can remove the matching item. Supply the item label and an optional removal control. */
340
- export declare const Chip: import("react").ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").ComboboxChipProps, "className"> & {
344
+ export declare function Chip({ disableStyle, className, ref, ...props }: (Omit<BaseCombobox.Chip.Props, 'className' | 'render'> & {
341
345
  className?: string;
342
- } & StyleProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
346
+ }) & StyleProps): import("react").JSX.Element;
343
347
  /** Removes the surrounding Chip from selection automatically; no onClick handler needed. Supply its content, normally ChipRemoveButtonIcon, and an accessible label. */
344
- export declare const ChipRemoveButton: import("react").ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").ComboboxChipRemoveProps, "className"> & {
348
+ export declare function ChipRemoveButton({ disableStyle, className, ref, ...props }: (Omit<BaseCombobox.ChipRemove.Props, 'className' | 'render'> & {
345
349
  className?: string;
346
- } & StyleProps, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
350
+ }) & StyleProps): import("react").JSX.Element;
347
351
  /** Opens and closes the popup automatically; no click handler needed. Supply its content, normally AddonOpenButtonIcon, and an accessible label. */
348
- export declare const AddonOpenButton: import("react").ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").ComboboxTriggerProps, "className"> & {
352
+ export declare function AddonOpenButton({ disableStyle, className, ref, ...props }: (Omit<BaseCombobox.Trigger.Props, 'className' | 'render'> & {
349
353
  className?: string;
350
- } & StyleProps, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
354
+ }) & StyleProps): import("react").JSX.Element;
351
355
  /** Clears the selection automatically; no click handler needed. Supply its content, normally AddonClearButtonIcon, and an accessible label. */
352
- export declare const AddonClearButton: import("react").ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").AutocompleteClearProps, "className"> & {
356
+ export declare function AddonClearButton({ disableStyle, className, ref, ...props }: (Omit<BaseCombobox.Clear.Props, 'className' | 'render'> & {
353
357
  className?: string;
354
- } & StyleProps, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
358
+ }) & StyleProps): import("react").JSX.Element;
355
359
  /** Optional heading inside Group. Supply group.label as children. Omit this part for an empty label; always keep Group and ItemsList. */
356
- export declare const GroupLabel: import("react").ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").AutocompleteGroupLabelProps, "className"> & {
360
+ export declare function GroupLabel({ disableStyle, className, ref, ...props }: (Omit<BaseCombobox.GroupLabel.Props, 'className' | 'render'> & {
357
361
  className?: string;
358
- } & StyleProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
362
+ }) & StyleProps): import("react").JSX.Element;
359
363
  /** Required empty-results message inside Popup, before optional Loading and ScrollArea. Keep mounted statically: Base UI renders its children only when no items match. Do not manually toggle, hide, or conditionally mount it. */
360
- export declare const Empty: import("react").ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").AutocompleteEmptyProps, "className"> & {
364
+ export declare function Empty({ disableStyle, className, ref, ...props }: (Omit<BaseCombobox.Empty.Props, 'className' | 'render'> & {
361
365
  className?: string;
362
- } & StyleProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
366
+ }) & StyleProps): import("react").JSX.Element;
363
367
  /** Optional visual separator inside the popup. Does not replace Group or any required list containers. */
364
- export declare const Separator: import("react").ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").ComboboxSeparatorProps, "className"> & {
368
+ export declare function Separator({ disableStyle, className, ref, ...props }: (Omit<BaseCombobox.Separator.Props, 'className' | 'render'> & {
365
369
  className?: string;
366
- } & StyleProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
370
+ }) & StyleProps): import("react").JSX.Element;
367
371
  /** Required label content inside Item. Supply item.label as children; does not derive text from the item automatically. */
368
- export declare const ItemText: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLSpanElement> & import("react").HTMLAttributes<HTMLSpanElement> & StyleProps, "ref"> & import("react").RefAttributes<HTMLSpanElement>>;
372
+ export declare function ItemText({ disableStyle, className, ref, ...props }: ComponentProps<'span'> & StyleProps): import("react").JSX.Element;
369
373
  /** Optional decorative text inside Addon. Supply the text as children. */
370
- export declare const AddonText: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLSpanElement> & import("react").HTMLAttributes<HTMLSpanElement> & StyleProps, "ref"> & import("react").RefAttributes<HTMLSpanElement>>;
374
+ export declare function AddonText({ disableStyle, className, ref, ...props }: ComponentProps<'span'> & StyleProps): import("react").JSX.Element;
371
375
  /** Text content inside Empty. Supply your empty-result message; Empty handles its visibility automatically. */
372
- export declare const EmptyText: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & StyleProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
376
+ export declare function EmptyText({ disableStyle, className, ref, ...props }: ComponentProps<'div'> & StyleProps): import("react").JSX.Element;
373
377
  /** Optional supporting text. Supply its content; it describes the input to screen readers automatically. */
374
- export declare const Description: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & StyleProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
378
+ export declare function Description({ disableStyle, className, id, ref, ...props }: ComponentProps<'div'> & StyleProps): import("react").JSX.Element;
375
379
  type MessageProps = Omit<ComponentProps<'div'>, 'children'> & StyleProps & {
376
380
  children?: ValidationMessageChildren;
377
381
  };
378
382
  /** Shows itself only while Root's validation is `'error'`: with no children it shows the message from `['error', message]`, a function children formats that message, and other children replace it. */
379
- export declare const Error: import("react").ForwardRefExoticComponent<Omit<MessageProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
383
+ export declare function Error({ children, ref, ...props }: MessageProps): import("react").JSX.Element | null;
380
384
  /** Shows itself only while Root's validation is `'success'`: with no children it shows the message from `['success', message]`, a function children formats that message, and other children replace it. */
381
- export declare const Success: import("react").ForwardRefExoticComponent<Omit<MessageProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
382
- /** Built-in decorative open-button icon. Place inside AddonOpenButton; no children needed. Defaults to strokeWidth 1.5. */
383
- export declare const AddonOpenButtonIcon: import("react").ForwardRefExoticComponent<Omit<Omit<SVGIconProps, "strokeWidth"> & {
384
- /** @default 1.5 */
385
- strokeWidth?: SVGIconProps["strokeWidth"];
386
- } & StyleProps, "ref"> & import("react").RefAttributes<SVGSVGElement>>;
387
- /** Built-in decorative clear icon. Place inside AddonClearButton; no children needed. Defaults to strokeWidth 1.5. */
388
- export declare const AddonClearButtonIcon: import("react").ForwardRefExoticComponent<Omit<Omit<SVGIconProps, "strokeWidth"> & {
389
- /** @default 1.5 */
390
- strokeWidth?: SVGIconProps["strokeWidth"];
391
- } & StyleProps, "ref"> & import("react").RefAttributes<SVGSVGElement>>;
392
- /** Built-in decorative removal icon. Place inside ChipRemoveButton; no children needed. Defaults to strokeWidth 1.5. */
393
- export declare const ChipRemoveButtonIcon: import("react").ForwardRefExoticComponent<Omit<Omit<SVGIconProps, "strokeWidth"> & {
394
- /** @default 1.5 */
395
- strokeWidth?: SVGIconProps["strokeWidth"];
396
- } & StyleProps, "ref"> & import("react").RefAttributes<SVGSVGElement>>;
385
+ export declare function Success({ children, ref, ...props }: MessageProps): import("react").JSX.Element | null;
386
+ type BuiltInIconProps = Omit<IconProps, 'children'> & StyleProps & {
387
+ /** Omit for the supplied default icon; pass a child icon only to replace it. */
388
+ children?: ReactElement<SVGIconProps>;
389
+ };
390
+ /** Built-in decorative open-button icon. Place inside AddonOpenButton. Omit children for the supplied default icon; pass an icon only to replace it. Defaults to strokeWidth 1.5. */
391
+ export declare function AddonOpenButtonIcon({ ref, ...props }: BuiltInIconProps): import("react").JSX.Element;
392
+ /** Built-in decorative clear icon. Place inside AddonClearButton. Omit children for the supplied default icon; pass an icon only to replace it. Defaults to strokeWidth 1.5. */
393
+ export declare function AddonClearButtonIcon({ ref, ...props }: BuiltInIconProps): import("react").JSX.Element;
394
+ /** Built-in decorative removal icon. Place inside ChipRemoveButton. Omit children for the supplied default icon; pass an icon only to replace it. Defaults to strokeWidth 1.5. */
395
+ export declare function ChipRemoveButtonIcon({ ref, ...props }: BuiltInIconProps): import("react").JSX.Element;
397
396
  /** Optional spinner inside Addon. Does not detect requests: you decide when to render it. Defaults to strokeWidth 1.5. */
398
- export declare const AddonLoadingIcon: import("react").ForwardRefExoticComponent<Omit<Omit<SVGIconProps, "strokeWidth"> & {
399
- /** @default 1.5 */
400
- strokeWidth?: SVGIconProps["strokeWidth"];
401
- } & StyleProps, "ref"> & import("react").RefAttributes<SVGSVGElement>>;
397
+ export declare function AddonLoadingIcon({ ref, ...props }: BuiltInIconProps): import("react").JSX.Element;
402
398
  /** Required selection indicator inside Item. Visibility is automatic and a checkmark is supplied: no children or selection condition needed. Pass children only to replace the built-in checkmark. */
403
- export declare const ItemIndicator: import("react").ForwardRefExoticComponent<Omit<Omit<SVGIconProps, "children"> & Pick<import("@base-ui/react").ComboboxItemIndicatorProps, "keepMounted"> & {
399
+ export declare function ItemIndicator({ disableStyle, children, keepMounted, ref, ...props }: Omit<SVGIconProps, 'children'> & Pick<BaseCombobox.ItemIndicator.Props, 'keepMounted'> & {
404
400
  /** Optional replacement SVG icon. It receives this indicator's props and ref. */
405
401
  children?: ReactElement<SVGIconProps>;
406
- } & StyleProps, "ref"> & import("react").RefAttributes<SVGSVGElement>>;
402
+ } & StyleProps): import("react").JSX.Element;
407
403
  /** Optional async status inside Popup, below Empty and above ScrollArea. Omit entirely for synchronous items. For async items, keep Loading mounted and conditionally render only LoadingIcon and LoadingText from your request state. Does not detect requests or manage visibility. */
408
- export declare const Loading: import("react").ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").AutocompleteStatusProps, "className"> & {
404
+ export declare function Loading({ disableStyle, className, ref, ...props }: (Omit<BaseCombobox.Status.Props, 'className' | 'render'> & {
409
405
  className?: string;
410
- } & StyleProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
406
+ }) & StyleProps): import("react").JSX.Element;
411
407
  /** Text inside Loading. Supply the message only while your request is loading; this part does not detect request state. */
412
- export declare const LoadingText: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & StyleProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
408
+ export declare function LoadingText({ disableStyle, className, ref, ...props }: ComponentProps<'div'> & StyleProps): import("react").JSX.Element;
413
409
  /** Built-in decorative spinner for Loading. No children needed; you control when it is rendered. */
414
- export declare const LoadingIcon: import("react").ForwardRefExoticComponent<Omit<SVGIconProps & StyleProps, "ref"> & import("react").RefAttributes<SVGSVGElement>>;
410
+ export declare function LoadingIcon({ disableStyle, className, strokeWidth, ref, ...props }: SVGIconProps & StyleProps): import("react").JSX.Element;
415
411
  export {};