@ostack.tech/ui 0.15.5 → 0.16.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 (259) hide show
  1. package/dist/chunks/{en-Buw2XVWt.js → en-DT1KWQei.js} +2 -2
  2. package/dist/chunks/{en-Buw2XVWt.js.map → en-DT1KWQei.js.map} +1 -1
  3. package/dist/locales/en-GB.js +1 -1
  4. package/dist/locales/en-US.js +1 -1
  5. package/dist/locales/fr-FR.js +1 -1
  6. package/dist/locales/fr-FR.js.map +1 -1
  7. package/dist/locales/pt-PT.js +1 -1
  8. package/dist/locales/pt-PT.js.map +1 -1
  9. package/dist/ostack-ui.css +128 -85
  10. package/dist/ostack-ui.js +2155 -1784
  11. package/dist/ostack-ui.js.map +1 -1
  12. package/package.json +5 -4
  13. package/scss/_utils.scss +0 -2
  14. package/scss/components/Checkbox/_Checkbox-variables.scss +7 -4
  15. package/scss/components/Checkbox/_Checkbox.scss +34 -9
  16. package/scss/components/CheckboxGroup/_CheckboxGroup.scss +9 -0
  17. package/scss/components/Code/_Code-variables.scss +8 -4
  18. package/scss/components/DateRangeInput/_DateRangeInput.scss +1 -1
  19. package/scss/components/Feedback/_Feedback-variables.scss +28 -1
  20. package/scss/components/Feedback/_Feedback.scss +95 -2
  21. package/scss/components/Field/_Field-variables.scss +0 -1
  22. package/scss/components/Field/_Field.scss +4 -40
  23. package/scss/components/HelperText/_HelperText-variables.scss +7 -0
  24. package/scss/components/HelperText/_HelperText.scss +9 -0
  25. package/scss/components/RadioGroup/_Radio.scss +13 -0
  26. package/scss/components/RadioGroup/_RadioGroup.scss +9 -0
  27. package/scss/components/Select/_Select.scss +2 -2
  28. package/scss/index.scss +0 -2
  29. package/scss/scss/placeholders/button/_button.scss +10 -6
  30. package/scss/scss/placeholders/checkable/_checkable-variables.scss +3 -2
  31. package/scss/scss/placeholders/checkable/_checkable.scss +25 -7
  32. package/scss/scss/placeholders/checkable-group/_checkable-group-variables.scss +1 -0
  33. package/scss/scss/placeholders/checkable-group/_checkable-group.scss +15 -3
  34. package/scss/scss/placeholders/popover/_popover.scss +3 -0
  35. package/scss/scss/utils/_breakpoints.scss +1 -1
  36. package/scss/scss/utils/_declare-var.scss +1 -1
  37. package/types/components/Alert/Alert.d.ts +12 -15
  38. package/types/components/Alert/AlertTitle.d.ts +2 -2
  39. package/types/components/AlertDialog/AlertDialog.d.ts +6 -2
  40. package/types/components/AlertDialog/AlertDialogAction.d.ts +3 -3
  41. package/types/components/AlertDialog/AlertDialogBody.d.ts +3 -5
  42. package/types/components/AlertDialog/AlertDialogCancel.d.ts +3 -3
  43. package/types/components/AlertDialog/AlertDialogContent.d.ts +6 -6
  44. package/types/components/AlertDialog/AlertDialogDescription.d.ts +3 -3
  45. package/types/components/AlertDialog/AlertDialogFooter.d.ts +3 -5
  46. package/types/components/AlertDialog/AlertDialogHeader.d.ts +3 -4
  47. package/types/components/AlertDialog/AlertDialogTitle.d.ts +4 -4
  48. package/types/components/AlertDialog/AlertDialogTrigger.d.ts +3 -3
  49. package/types/components/Button/Button.d.ts +14 -15
  50. package/types/components/ButtonGroup/ButtonGroup.d.ts +3 -3
  51. package/types/components/Calendar/Calendar.d.ts +6 -6
  52. package/types/components/Calendar/CalendarDay.d.ts +1 -1
  53. package/types/components/Calendar/CalendarHeader.d.ts +1 -1
  54. package/types/components/Calendar/CalendarMonthGrid.d.ts +1 -1
  55. package/types/components/Card/Card.d.ts +3 -3
  56. package/types/components/Card/CardBody.d.ts +3 -3
  57. package/types/components/Card/CardFooter.d.ts +3 -3
  58. package/types/components/Card/CardHeader.d.ts +3 -3
  59. package/types/components/Card/CardTitle.d.ts +3 -3
  60. package/types/components/Checkbox/Checkbox.d.ts +22 -14
  61. package/types/components/CheckboxGroup/CheckboxGroup.d.ts +22 -12
  62. package/types/components/CheckboxGroup/CheckboxGroupContext.d.ts +15 -9
  63. package/types/components/CheckboxGroup/checkboxGroupUtils.d.ts +3 -0
  64. package/types/components/ClearContexts/ClearContexts.d.ts +19 -1
  65. package/types/components/CloseButton/CloseButton.d.ts +3 -4
  66. package/types/components/Code/Code.d.ts +3 -3
  67. package/types/components/Collapsible/Collapsible.d.ts +5 -3
  68. package/types/components/Collapsible/CollapsibleContent.d.ts +3 -3
  69. package/types/components/Collapsible/CollapsibleTrigger.d.ts +5 -5
  70. package/types/components/CommandMenu/CommandMenu.d.ts +18 -20
  71. package/types/components/CommandMenu/CommandMenuDialog.d.ts +6 -6
  72. package/types/components/CommandMenu/CommandMenuGroup.d.ts +3 -3
  73. package/types/components/CommandMenu/CommandMenuItem.d.ts +5 -3
  74. package/types/components/Container/Container.d.ts +3 -3
  75. package/types/components/Control/Control.d.ts +13 -13
  76. package/types/components/Control/ControlWithContainerRef.d.ts +12 -5
  77. package/types/components/Control/controlUtils.d.ts +24 -0
  78. package/types/components/ControlAddon/ControlAddon.d.ts +9 -3
  79. package/types/components/ControlCode/ControlCode.d.ts +3 -3
  80. package/types/components/DataTable/DataTable.d.ts +32 -21
  81. package/types/components/DataTable/DataTableBody.d.ts +4 -4
  82. package/types/components/DataTable/DataTableCell.d.ts +6 -4
  83. package/types/components/DataTable/DataTableColumn.d.ts +32 -11
  84. package/types/components/DataTable/DataTableColumnGroup.d.ts +31 -0
  85. package/types/components/DataTable/DataTableColumns.d.ts +14 -0
  86. package/types/components/DataTable/DataTableContent.d.ts +8 -8
  87. package/types/components/DataTable/DataTableContext.d.ts +7 -6
  88. package/types/components/DataTable/DataTableFilter.d.ts +1 -1
  89. package/types/components/DataTable/DataTableFoot.d.ts +6 -4
  90. package/types/components/DataTable/DataTableHead.d.ts +3 -4
  91. package/types/components/DataTable/DataTablePagination.d.ts +6 -6
  92. package/types/components/DataTable/DataTableRow.d.ts +3 -4
  93. package/types/components/DataTable/DataTableRowsPerPage.d.ts +3 -3
  94. package/types/components/DataTable/DataTableSelectionTrigger.d.ts +4 -4
  95. package/types/components/DataTable/PagedDataTablePagination.d.ts +3 -3
  96. package/types/components/DataTable/ScrolledDataTablePagination.d.ts +3 -3
  97. package/types/components/DataTable/__tests__/spliceWindow.test.d.ts +1 -0
  98. package/types/components/DataTable/columnUtils.d.ts +4 -3
  99. package/types/components/DataTable/index.d.ts +2 -0
  100. package/types/components/DataTable/processRows.d.ts +7 -7
  101. package/types/components/DataTable/sanitizeProps.d.ts +2 -2
  102. package/types/components/DataTable/useDataTableSelectionColumn.d.ts +2 -2
  103. package/types/components/DateInput/DateInput.d.ts +27 -18
  104. package/types/components/DateRangeInput/DateRangeInput.d.ts +37 -24
  105. package/types/components/DescriptionList/DescriptionList.d.ts +4 -4
  106. package/types/components/DescriptionList/DescriptionListItem.d.ts +4 -4
  107. package/types/components/Dialog/Dialog.d.ts +5 -1
  108. package/types/components/Dialog/DialogBody.d.ts +3 -4
  109. package/types/components/Dialog/DialogClose.d.ts +3 -3
  110. package/types/components/Dialog/DialogContent.d.ts +6 -6
  111. package/types/components/Dialog/DialogDescription.d.ts +3 -3
  112. package/types/components/Dialog/DialogFooter.d.ts +3 -4
  113. package/types/components/Dialog/DialogHeader.d.ts +5 -6
  114. package/types/components/Dialog/DialogTitle.d.ts +4 -4
  115. package/types/components/Dialog/DialogTrigger.d.ts +3 -3
  116. package/types/components/DropdownMenu/DropdownMenu.d.ts +4 -4
  117. package/types/components/DropdownMenu/DropdownMenuCheckboxItem.d.ts +5 -5
  118. package/types/components/DropdownMenu/DropdownMenuContent.d.ts +7 -7
  119. package/types/components/DropdownMenu/DropdownMenuGroup.d.ts +3 -3
  120. package/types/components/DropdownMenu/DropdownMenuItem.d.ts +4 -4
  121. package/types/components/DropdownMenu/DropdownMenuRadioGroup.d.ts +3 -3
  122. package/types/components/DropdownMenu/DropdownMenuRadioItem.d.ts +4 -4
  123. package/types/components/DropdownMenu/DropdownMenuSub.d.ts +4 -0
  124. package/types/components/DropdownMenu/DropdownMenuSubContent.d.ts +5 -5
  125. package/types/components/DropdownMenu/DropdownMenuSubTrigger.d.ts +3 -3
  126. package/types/components/DropdownMenu/DropdownMenuTrigger.d.ts +3 -3
  127. package/types/components/ErrorBoundary/ErrorBoundary.d.ts +9 -9
  128. package/types/components/Feedback/Feedback.d.ts +3 -3
  129. package/types/components/Feedback/FeedbackContext.d.ts +46 -0
  130. package/types/components/Feedback/FeedbackList.d.ts +6 -0
  131. package/types/components/Feedback/FeedbackListContext.d.ts +2 -0
  132. package/types/components/{FeedbackPopover → Feedback}/FeedbackPopover.d.ts +7 -7
  133. package/types/components/Feedback/FeedbackProvider.d.ts +13 -0
  134. package/types/components/Feedback/feedbackUtils.d.ts +19 -0
  135. package/types/components/Feedback/index.d.ts +4 -0
  136. package/types/components/Field/Field.d.ts +3 -3
  137. package/types/components/Field/FieldContext.d.ts +2 -70
  138. package/types/components/Field/fieldUtils.d.ts +7 -0
  139. package/types/components/Field/index.d.ts +1 -2
  140. package/types/components/FieldGroup/FieldGroup.d.ts +3 -3
  141. package/types/components/FieldGroup/FieldGroupBody.d.ts +3 -3
  142. package/types/components/FieldGroup/FieldGroupHeader.d.ts +4 -4
  143. package/types/components/FieldGroup/FieldGroupTitle.d.ts +2 -2
  144. package/types/components/Form/Form.d.ts +6 -6
  145. package/types/components/Form/FormContext.d.ts +1 -1
  146. package/types/components/Form/FormReset.d.ts +2 -2
  147. package/types/components/Form/FormSubmit.d.ts +2 -2
  148. package/types/components/Form/HiddenFormControl.d.ts +2 -2
  149. package/types/components/Form/useRegisterFormControl.d.ts +1 -1
  150. package/types/components/Grid/Grid.d.ts +4 -4
  151. package/types/components/Grid/GridContext.d.ts +10 -0
  152. package/types/components/Heading/Heading.d.ts +2 -2
  153. package/types/components/HelperText/HelperText.d.ts +3 -3
  154. package/types/components/HelperText/HelperTextContext.d.ts +38 -0
  155. package/types/components/HelperText/HelperTextProvider.d.ts +13 -0
  156. package/types/components/HelperText/helperTextUtils.d.ts +2 -0
  157. package/types/components/HelperText/index.d.ts +2 -0
  158. package/types/components/Icon/Icon.d.ts +3 -3
  159. package/types/components/IconButton/IconButton.d.ts +17 -17
  160. package/types/components/Input/Input.d.ts +1 -1
  161. package/types/components/Keybinds/Keybinds.d.ts +8 -3
  162. package/types/components/Keyboard/Keyboard.d.ts +3 -3
  163. package/types/components/Label/Label.d.ts +14 -14
  164. package/types/components/Label/LabelContext.d.ts +45 -0
  165. package/types/components/Label/LabelProvider.d.ts +13 -0
  166. package/types/components/Label/index.d.ts +2 -0
  167. package/types/components/Label/labelUtils.d.ts +23 -0
  168. package/types/components/Layer/Layer.d.ts +5 -5
  169. package/types/components/Link/Link.d.ts +4 -5
  170. package/types/components/Mark/Mark.d.ts +3 -3
  171. package/types/components/MenuList/MenuList.d.ts +3 -3
  172. package/types/components/MenuList/MenuListGroup.d.ts +5 -5
  173. package/types/components/MenuList/MenuListItem.d.ts +13 -14
  174. package/types/components/NumericInput/NumericInput.d.ts +5 -5
  175. package/types/components/NumericInput/numericInputUtils.d.ts +2 -2
  176. package/types/components/Output/Output.d.ts +2 -2
  177. package/types/components/Overlay/Overlay.d.ts +3 -3
  178. package/types/components/Popover/Popover.d.ts +4 -0
  179. package/types/components/Popover/PopoverAnchor.d.ts +4 -0
  180. package/types/components/Popover/PopoverClose.d.ts +5 -5
  181. package/types/components/Popover/PopoverContent.d.ts +5 -5
  182. package/types/components/Popover/PopoverTrigger.d.ts +3 -3
  183. package/types/components/Portal/Portal.d.ts +3 -3
  184. package/types/components/Printer/Printer.d.ts +1 -1
  185. package/types/components/Printer/PrinterContent.d.ts +5 -5
  186. package/types/components/Printer/PrinterTrigger.d.ts +4 -4
  187. package/types/components/RadioGroup/Radio.d.ts +23 -13
  188. package/types/components/RadioGroup/RadioGroup.d.ts +19 -16
  189. package/types/components/Root/Root.d.ts +9 -9
  190. package/types/components/Root/RootElement.d.ts +3 -3
  191. package/types/components/Select/Option.d.ts +3 -4
  192. package/types/components/Select/OptionsGroup.d.ts +3 -4
  193. package/types/components/Select/Select.d.ts +17 -13
  194. package/types/components/Select/SelectContext.d.ts +6 -12
  195. package/types/components/Select/SelectNative.d.ts +3 -3
  196. package/types/components/Select/selectUtils.d.ts +3 -0
  197. package/types/components/Separator/Separator.d.ts +3 -3
  198. package/types/components/Slot/Slot.d.ts +5 -0
  199. package/types/components/Slot/Slottable.d.ts +2 -2
  200. package/types/components/Spinner/Spinner.d.ts +3 -3
  201. package/types/components/Stack/Stack.d.ts +4 -4
  202. package/types/components/Stack/StackContext.d.ts +9 -0
  203. package/types/components/Stepper/Step.d.ts +6 -6
  204. package/types/components/Stepper/StepContent.d.ts +5 -5
  205. package/types/components/Stepper/StepList.d.ts +3 -3
  206. package/types/components/Stepper/Stepper.d.ts +6 -6
  207. package/types/components/Stepper/StepperFinishTrigger.d.ts +5 -5
  208. package/types/components/Stepper/StepperNextTrigger.d.ts +5 -5
  209. package/types/components/Stepper/StepperPreviousTrigger.d.ts +5 -5
  210. package/types/components/Table/Table.d.ts +15 -10
  211. package/types/components/Table/TableBody.d.ts +3 -3
  212. package/types/components/Table/TableCell.d.ts +3 -3
  213. package/types/components/Table/TableColumn.d.ts +29 -21
  214. package/types/components/Table/TableColumnGroup.d.ts +38 -0
  215. package/types/components/Table/TableContext.d.ts +1 -1
  216. package/types/components/Table/TableFoot.d.ts +3 -3
  217. package/types/components/Table/TableHead.d.ts +15 -7
  218. package/types/components/Table/TableRow.d.ts +3 -3
  219. package/types/components/Table/columnUtils.d.ts +11 -17
  220. package/types/components/Table/index.d.ts +1 -0
  221. package/types/components/Tabs/Tab.d.ts +7 -7
  222. package/types/components/Tabs/TabContent.d.ts +4 -4
  223. package/types/components/Tabs/TabList.d.ts +8 -8
  224. package/types/components/Tabs/Tabs.d.ts +8 -6
  225. package/types/components/Tag/Badge.d.ts +2 -2
  226. package/types/components/Tag/Tag.d.ts +10 -10
  227. package/types/components/TextArea/TextArea.d.ts +2 -2
  228. package/types/components/Toast/Toast.d.ts +13 -13
  229. package/types/components/Toast/ToastDescription.d.ts +4 -0
  230. package/types/components/Toast/ToastProvider.d.ts +2 -2
  231. package/types/components/Toast/ToastTitle.d.ts +3 -3
  232. package/types/components/Toast/ToastViewport.d.ts +3 -3
  233. package/types/components/Tooltip/Tooltip.d.ts +5 -5
  234. package/types/components/Tooltip/TooltipProvider.d.ts +4 -0
  235. package/types/components/VisuallyHidden/VisuallyHidden.d.ts +2 -2
  236. package/types/index.d.ts +1 -2
  237. package/types/providers/AlertDialogProvider/AlertDialogProviderContext.d.ts +12 -12
  238. package/types/providers/ErrorReportingProvider/ErrorReportingProvider.d.ts +1 -1
  239. package/types/providers/LocalizationProvider/LocalizationObject.d.ts +2 -3
  240. package/types/providers/ToastManagerProvider/ToastManagerContext.d.ts +6 -6
  241. package/types/utils/__tests__/combineEventHandlers.test.d.ts +1 -0
  242. package/types/utils/__tests__/cx.test.d.ts +1 -0
  243. package/types/utils/__tests__/numericStringUtils.test.d.ts +1 -0
  244. package/types/utils/__tests__/useNumericTrasformer.test.d.ts +1 -0
  245. package/types/utils/documentTitleUtils.d.ts +4 -0
  246. package/types/utils/parseChildren.d.ts +64 -0
  247. package/types/utils/polymorphicTypes.d.ts +2 -13
  248. package/types/utils/useLocation.d.ts +3 -3
  249. package/types/utils/useNumericTransformer.d.ts +9 -6
  250. package/scss/components/FeedbackList/_FeedbackList-variables.scss +0 -6
  251. package/scss/components/FeedbackList/_FeedbackList.scss +0 -32
  252. package/scss/components/FeedbackPopover/_FeedbackPopover-variables.scss +0 -26
  253. package/scss/components/FeedbackPopover/_FeedbackPopover.scss +0 -66
  254. package/types/components/FeedbackList/FeedbackList.d.ts +0 -6
  255. package/types/components/FeedbackList/FeedbackListContext.d.ts +0 -4
  256. package/types/components/FeedbackList/index.d.ts +0 -2
  257. package/types/components/FeedbackPopover/index.d.ts +0 -2
  258. package/types/components/Field/FieldProvider.d.ts +0 -13
  259. /package/types/components/{FeedbackPopover → Feedback}/FeedbackPopoverContext.d.ts +0 -0
@@ -7,6 +7,9 @@
7
7
  %#{$prefix}popover {
8
8
  $popover: &;
9
9
 
10
+ max-width: var(--radix-popover-content-available-width);
11
+ max-height: var(--radix-popover-content-available-height);
12
+
10
13
  border: $popover-border-width solid $popover-border-color;
11
14
  border-radius: $popover-border-radius;
12
15
  // These `!important`s are currently needed due to conflicts with the `Root`
@@ -22,7 +22,7 @@
22
22
  // with a dash in front.
23
23
  @function breakpoint-infix($size, $breakpoint-by-size: $breakpoint-by-size) {
24
24
  @return if(
25
- sass(breakpoint-min($size, $breakpoint-by-size) == null): "" ;
25
+ sass(breakpoint-min($size, $breakpoint-by-size) == null): "";
26
26
  else: "-#{$size}"
27
27
  );
28
28
  }
@@ -3,6 +3,6 @@
3
3
  // Declares a CSS variable when the values isn't `null`.
4
4
  @mixin declare-var($var, $value: null) {
5
5
  @if ($value != null and $value != NULL) {
6
- #{$var}: #{if(sass($value == ""): "" ; else: meta.inspect($value))};
6
+ #{$var}: #{if(sass($value == ""): ""; else: meta.inspect($value))};
7
7
  }
8
8
  }
@@ -1,7 +1,7 @@
1
- import { type ComponentPropsWithoutRef, type ComponentPropsWithRef, type ReactNode } from "react";
2
- import { CloseButton } from "../CloseButton";
3
- import { CollapsibleContent } from "../Collapsible";
4
- import { Icon, type IconProp } from "../Icon";
1
+ import { type ComponentProps, type ReactNode } from "react";
2
+ import { type CloseButtonProps } from "../CloseButton";
3
+ import { type CollapsibleContentProps } from "../Collapsible";
4
+ import { type IconProp, type IconProps } from "../Icon";
5
5
  /** Alert variants. */
6
6
  export type AlertVariant = "solid" | "subtle" | "outlined";
7
7
  /** Alert severities. */
@@ -9,7 +9,7 @@ export type AlertSeverity = "neutral" | "info" | "success" | "danger" | "warning
9
9
  /** Alert type of announcement. */
10
10
  export type AlertAnnounce = "off" | "polite" | "assertive";
11
11
  /** Properties of the alert component. */
12
- export interface AlertProps extends ComponentPropsWithoutRef<"div"> {
12
+ export interface AlertProps extends ComponentProps<"div"> {
13
13
  /**
14
14
  * Alert variant.
15
15
  *
@@ -52,10 +52,7 @@ export interface AlertProps extends ComponentPropsWithoutRef<"div"> {
52
52
  open?: boolean;
53
53
  /** Function called when the open state changes. */
54
54
  onOpenChange?: (open: boolean) => void;
55
- /**
56
- * Icon to show. The default icon is `faCircleInfo`. Each severity except
57
- * `"neutral"` has its own default icon.
58
- */
55
+ /** Icon to show. Each severity except `"neutral"` has its own default icon. */
59
56
  icon?: IconProp | null;
60
57
  /**
61
58
  * Whether to show a close button.
@@ -64,15 +61,15 @@ export interface AlertProps extends ComponentPropsWithoutRef<"div"> {
64
61
  */
65
62
  showCloseButton?: boolean;
66
63
  /** Properties to pass to the container component. */
67
- containerProps?: ComponentPropsWithRef<typeof CollapsibleContent>;
64
+ containerProps?: CollapsibleContentProps;
68
65
  /** Properties to pass to the icon component. */
69
- iconProps?: Omit<ComponentPropsWithRef<typeof Icon>, "icon">;
66
+ iconProps?: Omit<IconProps, "icon">;
70
67
  /** Properties to pass to the content component. */
71
- contentProps?: ComponentPropsWithRef<"div">;
68
+ contentProps?: ComponentProps<"div">;
72
69
  /** Properties to pass to the component containing the action/close button. */
73
- actionContainerProps?: ComponentPropsWithRef<"div">;
70
+ actionContainerProps?: ComponentProps<"div">;
74
71
  /** Properties to pass to the close button component. */
75
- closeButtonProps?: ComponentPropsWithRef<typeof CloseButton>;
72
+ closeButtonProps?: CloseButtonProps;
76
73
  }
77
74
  /**
78
75
  * The alert component can be used to attract the user's attention.
@@ -96,4 +93,4 @@ export interface AlertProps extends ComponentPropsWithoutRef<"div"> {
96
93
  * }
97
94
  * ```
98
95
  */
99
- export declare const Alert: import("react").ForwardRefExoticComponent<AlertProps & import("react").RefAttributes<HTMLDivElement>>;
96
+ export declare function Alert({ variant, severity, announce, defaultOpen, open, onOpenChange, icon, showCloseButton, action, containerProps, iconProps, contentProps, actionContainerProps, closeButtonProps, children, className, role, "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, ...otherProps }: AlertProps): import("react").JSX.Element;
@@ -1,4 +1,4 @@
1
- import type { PolymorphicComponent, PolymorphicProps } from "../../utils/polymorphicTypes.ts";
1
+ import type { PolymorphicProps } from "../../utils/polymorphicTypes.ts";
2
2
  /** Element an alert title can be rendered as. */
3
3
  export type AlertTitleAs = "div" | "span" | "h2" | "h3" | "h4" | "h5" | "h6";
4
4
  /** Properties of the alert title component. */
@@ -13,4 +13,4 @@ export interface AlertTitleOwnProps {
13
13
  asChild?: boolean;
14
14
  }
15
15
  /** Title of the alert. */
16
- export declare const AlertTitle: PolymorphicComponent<AlertTitleAs, "div", AlertTitleOwnProps>;
16
+ export declare function AlertTitle<TAs extends AlertTitleAs = "div">({ as, asChild, id, className, ref, ...otherProps }: AlertTitleProps<TAs>): import("react").JSX.Element;
@@ -1,11 +1,15 @@
1
1
  import { AlertDialog as AlertDialogPrimitive } from "radix-ui";
2
+ import type { ComponentProps } from "react";
3
+ /** Properties of the alert dialog component. */
4
+ export interface AlertDialogProps extends ComponentProps<typeof AlertDialogPrimitive.Root> {
5
+ }
2
6
  /**
3
7
  * The alert dialog component displays an important overlaid “window” to the
4
8
  * user and expects a response.
5
9
  *
6
10
  * Built on top of the [Radix Alert Dialog
7
11
  * primitive](https://www.radix-ui.com/primitives/docs/components/alert-dialog),
8
- * and the [`Card` component](?path=/docs/ostack-ui-data-display-card--docs).
12
+ * and the [`Card` component](/docs/ostack-ui-data-display-card--docs).
9
13
  *
10
14
  * It composes the following subcomponents:
11
15
  *
@@ -79,7 +83,7 @@ import { AlertDialog as AlertDialogPrimitive } from "radix-ui";
79
83
  * ```
80
84
  *
81
85
  * > **Note:** In many scenarios you might prefer to use the [`useAlertDialog`
82
- * > hook](?path=/docs/ostack-ui-overlay-alert-dialog--docs#usealertdialog-hook)
86
+ * > hook](/docs/ostack-ui-overlay-alert-dialog--docs#usealertdialog-hook)
83
87
  * > instead, which provides an imperative API for triggering “alert”, “confirm”,
84
88
  * > or “prompt” dialogs.
85
89
  */
@@ -1,10 +1,10 @@
1
1
  import { AlertDialog as AlertDialogPrimitive } from "radix-ui";
2
- import { type ComponentPropsWithoutRef } from "react";
2
+ import type { ComponentProps } from "react";
3
3
  /** Properties of the alert dialog action component. */
4
- export interface AlertDialogActionProps extends Omit<ComponentPropsWithoutRef<typeof AlertDialogPrimitive.Action>, "asChild"> {
4
+ export interface AlertDialogActionProps extends Omit<ComponentProps<typeof AlertDialogPrimitive.Action>, "asChild"> {
5
5
  }
6
6
  /**
7
7
  * Button which closes the alert dialog by accepting the action. These buttons
8
8
  * should be distinguished visually from `AlertDialogCancel` buttons.
9
9
  */
10
- export declare const AlertDialogAction: import("react").ForwardRefExoticComponent<AlertDialogActionProps & import("react").RefAttributes<HTMLButtonElement>>;
10
+ export declare function AlertDialogAction(props: AlertDialogActionProps): import("react").JSX.Element;
@@ -1,7 +1,5 @@
1
- import { type ComponentPropsWithoutRef } from "react";
2
- import { DialogBody } from "../Dialog";
1
+ import { DialogBody, type DialogBodyProps } from "../Dialog";
3
2
  /** Properties to the alert dialog body component. */
4
- export interface AlertDialogBodyProps extends ComponentPropsWithoutRef<typeof DialogBody> {
5
- }
3
+ export type AlertDialogBodyProps = DialogBodyProps;
6
4
  /** Body section of the alert dialog. */
7
- export declare const AlertDialogBody: import("react").ForwardRefExoticComponent<AlertDialogBodyProps & import("react").RefAttributes<HTMLDivElement>>;
5
+ export declare const AlertDialogBody: typeof DialogBody;
@@ -1,10 +1,10 @@
1
1
  import { AlertDialog as AlertDialogPrimitive } from "radix-ui";
2
- import { type ComponentPropsWithoutRef } from "react";
2
+ import type { ComponentProps } from "react";
3
3
  /** Properties of the alert dialog cancel component. */
4
- export interface AlertDialogCancelProps extends Omit<ComponentPropsWithoutRef<typeof AlertDialogPrimitive.Cancel>, "asChild"> {
4
+ export interface AlertDialogCancelProps extends Omit<ComponentProps<typeof AlertDialogPrimitive.Cancel>, "asChild"> {
5
5
  }
6
6
  /**
7
7
  * Button which closes the alert dialog by cancelling the action. These buttons
8
8
  * should be distinguished visually from `AlertDialogAction` buttons.
9
9
  */
10
- export declare const AlertDialogCancel: import("react").ForwardRefExoticComponent<AlertDialogCancelProps & import("react").RefAttributes<HTMLButtonElement>>;
10
+ export declare function AlertDialogCancel(props: AlertDialogCancelProps): import("react").JSX.Element;
@@ -1,7 +1,7 @@
1
1
  import { AlertDialog as AlertDialogPrimitive } from "radix-ui";
2
- import { type ComponentPropsWithoutRef, type ComponentPropsWithRef } from "react";
2
+ import type { ComponentProps } from "react";
3
3
  import type { DialogContentColor, DialogContentSize, DialogContentVariant } from "../Dialog";
4
- import { Overlay } from "../Overlay";
4
+ import { type OverlayProps } from "../Overlay";
5
5
  /** Alert dialog content variants. */
6
6
  export type AlertDialogContentVariant = DialogContentVariant;
7
7
  /** Possible alert dialog content colors. */
@@ -9,7 +9,7 @@ export type AlertDialogContentColor = DialogContentColor;
9
9
  /** Possible alert dialog content sizes. */
10
10
  export type AlertDialogContentSize = DialogContentSize;
11
11
  /** Properties of the alert dialog content component. */
12
- export interface AlertDialogContentProps extends ComponentPropsWithoutRef<typeof AlertDialogPrimitive.Content> {
12
+ export interface AlertDialogContentProps extends ComponentProps<typeof AlertDialogPrimitive.Content> {
13
13
  /**
14
14
  * Dialog content variant.
15
15
  *
@@ -37,9 +37,9 @@ export interface AlertDialogContentProps extends ComponentPropsWithoutRef<typeof
37
37
  */
38
38
  size?: AlertDialogContentSize;
39
39
  /** Properties to pass to the portal component. */
40
- portalProps?: Omit<ComponentPropsWithRef<typeof AlertDialogPrimitive.Portal>, "forceMount">;
40
+ portalProps?: Omit<ComponentProps<typeof AlertDialogPrimitive.Portal>, "forceMount">;
41
41
  /** Properties to pass to the dialog's overlay component. */
42
- overlayProps?: ComponentPropsWithRef<typeof Overlay>;
42
+ overlayProps?: OverlayProps;
43
43
  }
44
44
  /** Content to be rendered in the open alert dialog. */
45
- export declare const AlertDialogContent: import("react").ForwardRefExoticComponent<AlertDialogContentProps & import("react").RefAttributes<HTMLDivElement>>;
45
+ export declare function AlertDialogContent({ asChild, variant, mergeSections, color, size, forceMount, portalProps, overlayProps, className, children, ...otherProps }: AlertDialogContentProps): import("react").JSX.Element;
@@ -1,7 +1,7 @@
1
1
  import { AlertDialog as AlertDialogPrimitive } from "radix-ui";
2
- import { type ComponentPropsWithoutRef } from "react";
2
+ import type { ComponentProps } from "react";
3
3
  /** Properties of the alert dialog description component. */
4
- export interface AlertDialogDescriptionProps extends ComponentPropsWithoutRef<typeof AlertDialogPrimitive.Description> {
4
+ export interface AlertDialogDescriptionProps extends ComponentProps<typeof AlertDialogPrimitive.Description> {
5
5
  }
6
6
  /**
7
7
  * Optional accessible description to be announced when the alert dialog is
@@ -11,4 +11,4 @@ export interface AlertDialogDescriptionProps extends ComponentPropsWithoutRef<ty
11
11
  * the description entirely, pass `aria-describedby={undefined}` to the
12
12
  * `AlertDialogContent` and omit this component.
13
13
  */
14
- export declare const AlertDialogDescription: import("react").ForwardRefExoticComponent<AlertDialogDescriptionProps & import("react").RefAttributes<HTMLParagraphElement>>;
14
+ export declare function AlertDialogDescription({ className, ...otherProps }: AlertDialogDescriptionProps): import("react").JSX.Element;
@@ -1,7 +1,5 @@
1
- import { type ComponentPropsWithoutRef } from "react";
2
- import { DialogFooter } from "../Dialog";
1
+ import { DialogFooter, type DialogFooterProps } from "../Dialog";
3
2
  /** Properties to the alert dialog footer component. */
4
- export interface AlertDialogFooterProps extends ComponentPropsWithoutRef<typeof DialogFooter> {
5
- }
3
+ export type AlertDialogFooterProps = DialogFooterProps;
6
4
  /** Footer section of the alert dialog. */
7
- export declare const AlertDialogFooter: import("react").ForwardRefExoticComponent<AlertDialogFooterProps & import("react").RefAttributes<HTMLDivElement>>;
5
+ export declare const AlertDialogFooter: typeof DialogFooter;
@@ -1,7 +1,6 @@
1
- import { type ComponentPropsWithoutRef } from "react";
2
- import { CardHeader } from "../Card";
1
+ import { type CardHeaderProps } from "../Card";
3
2
  /** Properties of the alert dialog header component. */
4
- export interface AlertDialogHeaderProps extends ComponentPropsWithoutRef<typeof CardHeader> {
3
+ export interface AlertDialogHeaderProps extends CardHeaderProps {
5
4
  }
6
5
  /** Header section of the alert dialog. */
7
- export declare const AlertDialogHeader: import("react").ForwardRefExoticComponent<AlertDialogHeaderProps & import("react").RefAttributes<HTMLDivElement>>;
6
+ export declare function AlertDialogHeader({ className, ...otherProps }: AlertDialogHeaderProps): import("react").JSX.Element;
@@ -1,12 +1,12 @@
1
1
  import { AlertDialog as AlertDialogPrimitive } from "radix-ui";
2
- import { type ComponentPropsWithoutRef } from "react";
3
- import type { PolymorphicComponent, PolymorphicProps } from "../../utils/polymorphicTypes.ts";
2
+ import type { ComponentProps } from "react";
3
+ import type { PolymorphicProps } from "../../utils/polymorphicTypes.ts";
4
4
  /** Element an alert dialog title can be rendered as. */
5
5
  export type AlertDialogTitleAs = "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "div" | "span";
6
6
  /** Properties of the alert dialog title component. */
7
7
  export type AlertDialogTitleProps<TAs extends AlertDialogTitleAs = "h2"> = PolymorphicProps<AlertDialogTitleAs, TAs, "h2", AlertDialogTitleOwnProps>;
8
8
  /** Own properties of the alert dialog title component. */
9
- export interface AlertDialogTitleOwnProps extends Pick<ComponentPropsWithoutRef<typeof AlertDialogPrimitive.Title>, "asChild"> {
9
+ export interface AlertDialogTitleOwnProps extends Pick<ComponentProps<typeof AlertDialogPrimitive.Title>, "asChild"> {
10
10
  }
11
11
  /** Accessible title to be announced when the alert dialog is opened. */
12
- export declare const AlertDialogTitle: PolymorphicComponent<AlertDialogTitleAs, "h2", AlertDialogTitleOwnProps>;
12
+ export declare function AlertDialogTitle<TAs extends AlertDialogTitleAs = "h2">({ as, asChild, className, ...otherProps }: AlertDialogTitleProps<TAs>): import("react").JSX.Element;
@@ -1,7 +1,7 @@
1
1
  import { AlertDialog as AlertDialogPrimitive } from "radix-ui";
2
- import { type ComponentPropsWithoutRef } from "react";
2
+ import type { ComponentProps } from "react";
3
3
  /** Properties of the alert dialog trigger component. */
4
- export interface AlertDialogTriggerProps extends Omit<ComponentPropsWithoutRef<typeof AlertDialogPrimitive.Trigger>, "asChild"> {
4
+ export interface AlertDialogTriggerProps extends Omit<ComponentProps<typeof AlertDialogPrimitive.Trigger>, "asChild"> {
5
5
  }
6
6
  /** The button which, when pressed, opens the alert dialog */
7
- export declare const AlertDialogTrigger: import("react").ForwardRefExoticComponent<AlertDialogTriggerProps & import("react").RefAttributes<HTMLButtonElement>>;
7
+ export declare function AlertDialogTrigger(props: AlertDialogTriggerProps): import("react").JSX.Element;
@@ -1,11 +1,11 @@
1
- import { type ComponentPropsWithRef, type ReactElement, type ReactNode } from "react";
1
+ import { type ReactElement, type ReactNode } from "react";
2
2
  import type { AccentColor } from "../../utils/accent.ts";
3
3
  import { type KeyboardShortcutKeybinds } from "../../utils/keyboardShortcut.ts";
4
- import type { PolymorphicComponent, PolymorphicProps } from "../../utils/polymorphicTypes.ts";
5
- import { Icon, type IconProp } from "../Icon";
6
- import { Keybinds } from "../Keybinds";
7
- import { Spinner } from "../Spinner";
8
- import { Tooltip } from "../Tooltip";
4
+ import type { PolymorphicProps } from "../../utils/polymorphicTypes.ts";
5
+ import { type IconProp, type IconProps } from "../Icon";
6
+ import { type KeybindsProps } from "../Keybinds";
7
+ import { type SpinnerProps } from "../Spinner";
8
+ import { type TooltipProps } from "../Tooltip";
9
9
  /** Elements a button can be rendered as. */
10
10
  export type ButtonAs = "button" | "a";
11
11
  /** Button variants. */
@@ -82,8 +82,7 @@ export interface ButtonOwnProps {
82
82
  *
83
83
  * When `true`, the button is “soft-disabled”: it looks disabled and ignores
84
84
  * user interaction but remains focusable. By default, a spinner is shown as
85
- * the button's icon (_i.e._, `showSpinner` is set to `true` unless
86
- * overridden).
85
+ * the button's icon (i.e. `showSpinner` is set to `true` unless overridden).
87
86
  *
88
87
  * The button's content while loading can be controlled via `loadingContent`.
89
88
  * The position of the spinner may be controlled via `iconPlacement`.
@@ -131,18 +130,18 @@ export interface ButtonOwnProps {
131
130
  * readers via `aria-keyshortcuts`.
132
131
  *
133
132
  * > **Note:** This property does **not** automatically register a keyboard
134
- * > shortcut to run the button's action. This should be done manually via
135
- * > _e.g._ the `useKeyboardShortcut` hook.
133
+ * > shortcut to run the button's action. This should be done manually via e.g.
134
+ * > the `useKeyboardShortcut` hook.
136
135
  */
137
136
  keybinds?: KeyboardShortcutKeybinds;
138
137
  /** Properties to pass to the icon component. */
139
- iconProps?: Omit<ComponentPropsWithRef<typeof Icon>, "icon">;
138
+ iconProps?: Omit<IconProps, "icon">;
140
139
  /** Properties to pass to the spinner component. */
141
- spinnerProps?: ComponentPropsWithRef<typeof Spinner>;
140
+ spinnerProps?: SpinnerProps;
142
141
  /** Properties to pass to the tooltip component. */
143
- tooltipProps?: Omit<ComponentPropsWithRef<typeof Tooltip>, "content" | "children">;
142
+ tooltipProps?: Omit<TooltipProps, "content" | "children">;
144
143
  /** Properties to pass to the keybinds component. */
145
- keybindsProps?: ComponentPropsWithRef<typeof Keybinds>;
144
+ keybindsProps?: KeybindsProps;
146
145
  }
147
146
  /**
148
147
  * The button component is used to trigger actions or events, such as opening a
@@ -159,4 +158,4 @@ export interface ButtonOwnProps {
159
158
  * }
160
159
  * ```
161
160
  */
162
- export declare const Button: PolymorphicComponent<ButtonAs, "button", ButtonOwnProps>;
161
+ export declare function Button<TAs extends ButtonAs = "button">({ as, asChild, variant, color, size, vertical, icon, iconPlacement, active, disabled, loading, loadingContent, showSpinner, tooltipContent, keybinds, iconProps, spinnerProps, tooltipProps, keybindsProps, type, onClick, className, children, "aria-disabled": ariaDisabled, ...otherProps }: ButtonProps<TAs>): import("react").JSX.Element;
@@ -1,6 +1,6 @@
1
- import { type ComponentPropsWithoutRef } from "react";
1
+ import type { ComponentProps } from "react";
2
2
  /** Properties of the button group component. */
3
- export interface ButtonGroupProps extends ComponentPropsWithoutRef<"div"> {
3
+ export interface ButtonGroupProps extends ComponentProps<"div"> {
4
4
  /**
5
5
  * Change the component to the HTML tag or custom component of the only child.
6
6
  * This will merge the original component props with the props of the supplied
@@ -29,4 +29,4 @@ export interface ButtonGroupProps extends ComponentPropsWithoutRef<"div"> {
29
29
  * }
30
30
  * ```
31
31
  */
32
- export declare const ButtonGroup: import("react").ForwardRefExoticComponent<ButtonGroupProps & import("react").RefAttributes<HTMLDivElement>>;
32
+ export declare function ButtonGroup({ asChild, className, ...otherProps }: ButtonGroupProps): import("react").JSX.Element;
@@ -1,6 +1,6 @@
1
1
  import { type DayPickerProps } from "@daypicker/react";
2
- import { type ComponentPropsWithRef, type RefObject } from "react";
3
- import type { IconButton } from "../IconButton";
2
+ import { type ComponentProps, type RefObject } from "react";
3
+ import type { IconButtonProps } from "../IconButton";
4
4
  import type { SelectSingleProps } from "../Select";
5
5
  /** Mode for selecting calendar dates. */
6
6
  export type CalendarSelectionMode = "none" | "single" | "multiple" | "range" | "range-start" | "range-end";
@@ -73,13 +73,13 @@ export interface CalendarPropsBase<TValue extends Date | Date[] | DateRange | nu
73
73
  /** Reference to the calendar API. */
74
74
  apiRef?: RefObject<CalendarApi<TValue> | null>;
75
75
  /** Properties to pass to the header element. */
76
- headerProps?: ComponentPropsWithRef<"header">;
76
+ headerProps?: ComponentProps<"header">;
77
77
  /** Properties to pass to the header label element. */
78
- headerLabelProps?: ComponentPropsWithRef<"span">;
78
+ headerLabelProps?: ComponentProps<"span">;
79
79
  /** Properties to pass to the previous button component. */
80
- previousButtonProps?: ComponentPropsWithRef<typeof IconButton<"button">>;
80
+ previousButtonProps?: IconButtonProps;
81
81
  /** Properties to pass to the next button component. */
82
- nextButtonProps?: ComponentPropsWithRef<typeof IconButton<"button">>;
82
+ nextButtonProps?: IconButtonProps;
83
83
  /** Properties to pass to the month select component. */
84
84
  monthSelectProps?: Omit<SelectSingleProps, "defaultValue" | "value">;
85
85
  /** Properties to pass to the year select component. */
@@ -5,4 +5,4 @@ import { type DayProps } from "@daypicker/react";
5
5
  * wrapper over the day text which lets us style it without styling the whole
6
6
  * button.
7
7
  */
8
- export declare const CalendarDay: import("react").MemoExoticComponent<({ day: _day, modifiers, children, ...otherProps }: DayProps) => import("react").JSX.Element>;
8
+ export declare function CalendarDay({ day: _day, modifiers, children, ...otherProps }: DayProps): import("react").JSX.Element;
@@ -3,4 +3,4 @@ import { type MonthCaptionProps } from "@daypicker/react";
3
3
  * Reimplementation of the React Day Picker's caption component to provide both
4
4
  * navigation arrows and dropdown selections.
5
5
  */
6
- export declare const CalendarHeader: import("react").MemoExoticComponent<({ calendarMonth, displayIndex, ...otherProps }: MonthCaptionProps) => import("react").JSX.Element>;
6
+ export declare function CalendarHeader({ calendarMonth, displayIndex, ...otherProps }: MonthCaptionProps): import("react").JSX.Element;
@@ -1,2 +1,2 @@
1
1
  import type { MonthGridProps } from "@daypicker/react";
2
- export declare const CalendarMonthGrid: import("react").MemoExoticComponent<({ children, "aria-label": ariaLabel, ...otherProps }: MonthGridProps) => import("react").JSX.Element>;
2
+ export declare function CalendarMonthGrid({ children, "aria-label": ariaLabel, ...otherProps }: MonthGridProps): import("react").JSX.Element;
@@ -1,11 +1,11 @@
1
- import { type ComponentPropsWithoutRef } from "react";
1
+ import type { ComponentProps } from "react";
2
2
  import type { AccentColor } from "../../utils/accent.ts";
3
3
  /** Card variants. */
4
4
  export type CardVariant = "solid" | "subtle" | "outlined" | "ghost";
5
5
  /** Possible card colours. */
6
6
  export type CardColor = AccentColor;
7
7
  /** Properties of the card component. */
8
- export interface CardProps extends ComponentPropsWithoutRef<"div"> {
8
+ export interface CardProps extends ComponentProps<"div"> {
9
9
  /**
10
10
  * Change the component to the HTML tag or custom component of the only child.
11
11
  * This will merge the original component props with the props of the supplied
@@ -67,4 +67,4 @@ export interface CardProps extends ComponentPropsWithoutRef<"div"> {
67
67
  * }
68
68
  * ```
69
69
  */
70
- export declare const Card: import("react").ForwardRefExoticComponent<CardProps & import("react").RefAttributes<HTMLDivElement>>;
70
+ export declare function Card({ asChild, variant, color, mergeSections, className, ...otherProps }: CardProps): import("react").JSX.Element;
@@ -1,6 +1,6 @@
1
- import { type ComponentPropsWithoutRef } from "react";
1
+ import type { ComponentProps } from "react";
2
2
  /** Properties of the card body component. */
3
- export interface CardBodyProps extends ComponentPropsWithoutRef<"div"> {
3
+ export interface CardBodyProps extends ComponentProps<"div"> {
4
4
  /**
5
5
  * Change the component to the HTML tag or custom component of the only child.
6
6
  * This will merge the original component props with the props of the supplied
@@ -9,4 +9,4 @@ export interface CardBodyProps extends ComponentPropsWithoutRef<"div"> {
9
9
  asChild?: boolean;
10
10
  }
11
11
  /** Body section of the `Card` component. */
12
- export declare const CardBody: import("react").ForwardRefExoticComponent<CardBodyProps & import("react").RefAttributes<HTMLDivElement>>;
12
+ export declare function CardBody({ asChild, className, ...otherProps }: CardBodyProps): import("react").JSX.Element;
@@ -1,6 +1,6 @@
1
- import { type ComponentPropsWithoutRef } from "react";
1
+ import type { ComponentProps } from "react";
2
2
  /** Properties of the card footer component. */
3
- export interface CardFooterProps extends ComponentPropsWithoutRef<"div"> {
3
+ export interface CardFooterProps extends ComponentProps<"div"> {
4
4
  /**
5
5
  * Change the component to the HTML tag or custom component of the only child.
6
6
  * This will merge the original component props with the props of the supplied
@@ -9,4 +9,4 @@ export interface CardFooterProps extends ComponentPropsWithoutRef<"div"> {
9
9
  asChild?: boolean;
10
10
  }
11
11
  /** Footer section of the `Card` component. */
12
- export declare const CardFooter: import("react").ForwardRefExoticComponent<CardFooterProps & import("react").RefAttributes<HTMLDivElement>>;
12
+ export declare function CardFooter({ asChild, className, ...otherProps }: CardFooterProps): import("react").JSX.Element;
@@ -1,6 +1,6 @@
1
- import { type ComponentPropsWithoutRef } from "react";
1
+ import type { ComponentProps } from "react";
2
2
  /** Properties of the card header component. */
3
- export interface CardHeaderProps extends ComponentPropsWithoutRef<"div"> {
3
+ export interface CardHeaderProps extends ComponentProps<"div"> {
4
4
  /**
5
5
  * Change the component to the HTML tag or custom component of the only child.
6
6
  * This will merge the original component props with the props of the supplied
@@ -9,4 +9,4 @@ export interface CardHeaderProps extends ComponentPropsWithoutRef<"div"> {
9
9
  asChild?: boolean;
10
10
  }
11
11
  /** Header section of the `Card` component. */
12
- export declare const CardHeader: import("react").ForwardRefExoticComponent<CardHeaderProps & import("react").RefAttributes<HTMLDivElement>>;
12
+ export declare function CardHeader({ asChild, className, ...otherProps }: CardHeaderProps): import("react").JSX.Element;
@@ -1,7 +1,7 @@
1
- import type { PolymorphicComponent, PolymorphicProps } from "../../utils/polymorphicTypes.ts";
1
+ import type { PolymorphicProps } from "../../utils/polymorphicTypes.ts";
2
2
  /** Elements a card title can be rendered as. */
3
3
  export type CardTitleAs = "div" | "span" | "h2" | "h3" | "h4" | "h5" | "h6";
4
- /** Properties of the button component. */
4
+ /** Properties of the card title component. */
5
5
  export type CardTitleProps<TAs extends CardTitleAs = "div"> = PolymorphicProps<CardTitleAs, TAs, "div", CardTitleOwnProps>;
6
6
  /** Own properties of the card title component. */
7
7
  export interface CardTitleOwnProps {
@@ -13,4 +13,4 @@ export interface CardTitleOwnProps {
13
13
  asChild?: boolean;
14
14
  }
15
15
  /** Title of the `Card` component. */
16
- export declare const CardTitle: PolymorphicComponent<CardTitleAs, "div", CardTitleOwnProps>;
16
+ export declare function CardTitle<TAs extends CardTitleAs = "div">({ as, asChild, className, ...otherProps }: CardTitleProps<TAs>): import("react").JSX.Element;
@@ -1,16 +1,16 @@
1
1
  import { Checkbox as CheckboxPrimitive } from "radix-ui";
2
- import { type ComponentPropsWithoutRef, type ComponentPropsWithRef, type FocusEvent, type ReactNode } from "react";
2
+ import { type ComponentProps, type FocusEvent, type ReactNode } from "react";
3
3
  import { type ControlStatus, type ControlVariant } from "../Control";
4
- import { ControlCode } from "../ControlCode";
4
+ import { type ControlCodeProps } from "../ControlCode";
5
5
  import type { FormValidationMode } from "../Form";
6
6
  import { type FormControlValidateFn } from "../Form/useRegisterFormControl.ts";
7
- import { Icon } from "../Icon";
8
- import { Label } from "../Label";
9
- import { Spinner } from "../Spinner";
7
+ import { type IconProps } from "../Icon";
8
+ import { type LabelProps } from "../Label";
9
+ import { type SpinnerProps } from "../Spinner";
10
10
  /** `checked` state of a checkbox. */
11
11
  export type CheckboxChecked = CheckboxPrimitive.CheckedState;
12
12
  /** Properties of the checkbox component. */
13
- export interface CheckboxProps extends Omit<ComponentPropsWithoutRef<typeof CheckboxPrimitive.Root>, "asChild"> {
13
+ export interface CheckboxProps extends Omit<ComponentProps<typeof CheckboxPrimitive.Root>, "asChild"> {
14
14
  /**
15
15
  * Checkbox style variant. Defaults to the default variant unless when
16
16
  * rendering inside a table cell (in which case it defaults to `"cell"`).
@@ -22,12 +22,16 @@ export interface CheckboxProps extends Omit<ComponentPropsWithoutRef<typeof Chec
22
22
  code?: ReactNode;
23
23
  /** Sets the checkbox as read-only. */
24
24
  readOnly?: boolean;
25
+ /** Checkbox start adornment. */
26
+ startAdornment?: ReactNode;
27
+ /** Checkbox end adornment. */
28
+ endAdornment?: ReactNode;
25
29
  /**
26
30
  * Renders the checkbox in a **loading** state.
27
31
  *
28
32
  * When `true`, the checkbox is “soft-disabled”: it looks disabled and ignores
29
33
  * user interaction but remains focusable. By default, a spinner is shown
30
- * (_i.e._, `showSpinner` is set to `true` unless overridden).
34
+ * (i.e. `showSpinner` is set to `true` unless overridden).
31
35
  *
32
36
  * The checkbox's accessible description while loading can be controlled via
33
37
  * `loadingDescription`.
@@ -71,17 +75,21 @@ export interface CheckboxProps extends Omit<ComponentPropsWithoutRef<typeof Chec
71
75
  */
72
76
  validationMode?: FormValidationMode;
73
77
  /** Properties to pass to the root component. */
74
- rootProps?: ComponentPropsWithRef<"div">;
78
+ rootProps?: ComponentProps<"div">;
75
79
  /** Properties to pass to the container component. */
76
- containerProps?: ComponentPropsWithRef<"div">;
80
+ containerProps?: ComponentProps<"div">;
81
+ /** Properties to pass to the start container element. */
82
+ startContainerProps?: ComponentProps<"div">;
83
+ /** Properties to pass to the end container element. */
84
+ endContainerProps?: ComponentProps<"div">;
77
85
  /** Properties to pass to the code component. */
78
- codeProps?: ComponentPropsWithRef<typeof ControlCode>;
86
+ codeProps?: ControlCodeProps;
79
87
  /** Properties to pass to the indicator component. */
80
- indicatorProps?: ComponentPropsWithRef<typeof Icon>;
88
+ indicatorProps?: IconProps;
81
89
  /** Properties to pass to the label component. */
82
- labelProps?: Omit<ComponentPropsWithRef<typeof Label>, "required">;
90
+ labelProps?: Omit<LabelProps, "required">;
83
91
  /** Properties to pass to the spinner component. */
84
- spinnerProps?: Omit<ComponentPropsWithRef<typeof Spinner>, "size">;
92
+ spinnerProps?: Omit<SpinnerProps, "size">;
85
93
  }
86
94
  /**
87
95
  * The `Checkbox` component allows a user to toggle a “button” between checked
@@ -100,4 +108,4 @@ export interface CheckboxProps extends Omit<ComponentPropsWithoutRef<typeof Chec
100
108
  * }
101
109
  * ```
102
110
  */
103
- export declare const Checkbox: import("react").ForwardRefExoticComponent<CheckboxProps & import("react").RefAttributes<HTMLButtonElement>>;
111
+ export declare function Checkbox({ variant, status, code, loading, loadingDescription, showSpinner, onBlurToOutside, validate, validationMode, children, rootProps, containerProps, codeProps, indicatorProps, labelProps, spinnerProps, value, defaultChecked, checked: controlledChecked, onCheckedChange, onFocus, onBlur, id, name, className, required, disabled, readOnly, startAdornment, endAdornment, "aria-disabled": ariaDisabled, "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, "aria-describedby": ariaDescribedBy, startContainerProps, endContainerProps, ref, ...otherProps }: CheckboxProps): import("react").JSX.Element;