@ostack.tech/ui 0.1.2 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunks/en-lyNzumTm.js +105 -0
- package/dist/chunks/en-lyNzumTm.js.map +1 -0
- package/dist/locales/en-GB.js +16 -0
- package/dist/locales/en-GB.js.map +1 -0
- package/dist/locales/en-US.js +16 -0
- package/dist/locales/en-US.js.map +1 -0
- package/dist/locales/fr.js +110 -0
- package/dist/locales/fr.js.map +1 -0
- package/dist/locales/pt.js +110 -0
- package/dist/locales/pt.js.map +1 -0
- package/dist/ostack-ui.js +6151 -6401
- package/dist/ostack-ui.js.map +1 -1
- package/dist/types/components/Alert/Alert.d.ts +9 -9
- package/dist/types/components/Alert/AlertTitle.d.ts +3 -3
- package/dist/types/components/AlertDialog/AlertDialogAction.d.ts +3 -3
- package/dist/types/components/AlertDialog/AlertDialogBody.d.ts +3 -3
- package/dist/types/components/AlertDialog/AlertDialogCancel.d.ts +3 -3
- package/dist/types/components/AlertDialog/AlertDialogContent.d.ts +5 -5
- package/dist/types/components/AlertDialog/AlertDialogDescription.d.ts +3 -3
- package/dist/types/components/AlertDialog/AlertDialogFooter.d.ts +3 -3
- package/dist/types/components/AlertDialog/AlertDialogHeader.d.ts +3 -3
- package/dist/types/components/AlertDialog/AlertDialogTitle.d.ts +3 -3
- package/dist/types/components/AlertDialog/AlertDialogTrigger.d.ts +3 -3
- package/dist/types/components/Button/Button.d.ts +7 -7
- package/dist/types/components/ButtonGroup/ButtonGroup.d.ts +3 -3
- package/dist/types/components/Calendar/Calendar.d.ts +6 -6
- package/dist/types/components/Calendar/CalendarContext.d.ts +1 -2
- package/dist/types/components/Calendar/CalendarDay.d.ts +2 -3
- package/dist/types/components/Calendar/CalendarMonthCaption.d.ts +2 -3
- package/dist/types/components/Card/Card.d.ts +3 -3
- package/dist/types/components/Card/CardBody.d.ts +3 -3
- package/dist/types/components/Card/CardFooter.d.ts +3 -3
- package/dist/types/components/Card/CardHeader.d.ts +3 -3
- package/dist/types/components/Card/CardTitle.d.ts +3 -3
- package/dist/types/components/Checkbox/Checkbox.d.ts +11 -11
- package/dist/types/components/CheckboxGroup/CheckboxGroup.d.ts +9 -9
- package/dist/types/components/CheckboxGroup/CheckboxGroupContext.d.ts +1 -2
- package/dist/types/components/ClearContexts/ClearContexts.d.ts +3 -3
- package/dist/types/components/CloseButton/CloseButton.d.ts +3 -3
- package/dist/types/components/Code/Code.d.ts +3 -3
- package/dist/types/components/Collapsible/Collapsible.d.ts +3 -3
- package/dist/types/components/Collapsible/CollapsibleContent.d.ts +3 -3
- package/dist/types/components/Collapsible/CollapsibleContext.d.ts +1 -2
- package/dist/types/components/Collapsible/CollapsibleTrigger.d.ts +4 -4
- package/dist/types/components/CommandMenu/CommandMenu.d.ts +11 -11
- package/dist/types/components/CommandMenu/CommandMenuDialog.d.ts +7 -7
- package/dist/types/components/CommandMenu/CommandMenuGroup.d.ts +4 -4
- package/dist/types/components/CommandMenu/CommandMenuItem.d.ts +3 -3
- package/dist/types/components/Container/Container.d.ts +3 -3
- package/dist/types/components/ControlAddon/ControlAddon.d.ts +3 -3
- package/dist/types/components/ControlCode/ControlCode.d.ts +4 -4
- package/dist/types/components/DataTable/DataTable.d.ts +11 -11
- package/dist/types/components/DataTable/DataTableApi.d.ts +2 -2
- package/dist/types/components/DataTable/DataTableBody.d.ts +4 -4
- package/dist/types/components/DataTable/DataTableCell.d.ts +4 -4
- package/dist/types/components/DataTable/DataTableColumn.d.ts +4 -4
- package/dist/types/components/DataTable/DataTableContent.d.ts +9 -9
- package/dist/types/components/DataTable/DataTableContext.d.ts +19 -19
- package/dist/types/components/DataTable/DataTableFilter.d.ts +3 -3
- package/dist/types/components/DataTable/DataTableFoot.d.ts +3 -3
- package/dist/types/components/DataTable/DataTableHead.d.ts +3 -3
- package/dist/types/components/DataTable/DataTablePagination.d.ts +4 -4
- package/dist/types/components/DataTable/DataTableRow.d.ts +3 -3
- package/dist/types/components/DataTable/DataTableRowsPerPage.d.ts +4 -4
- package/dist/types/components/DataTable/DataTableSelectionTrigger.d.ts +5 -5
- package/dist/types/components/DataTable/PagedDataTablePagination.d.ts +3 -3
- package/dist/types/components/DataTable/ScrolledDataTablePagination.d.ts +3 -3
- package/dist/types/components/DataTable/getRowKey.d.ts +2 -2
- package/dist/types/components/DateInput/DateInput.d.ts +5 -5
- package/dist/types/components/DatePicker/DatePicker.d.ts +2 -2
- package/dist/types/components/DateRangeInput/DateRangeInput.d.ts +19 -19
- package/dist/types/components/DateRangePicker/DateRangePicker.d.ts +2 -2
- package/dist/types/components/Dialog/DialogBody.d.ts +3 -3
- package/dist/types/components/Dialog/DialogClose.d.ts +3 -3
- package/dist/types/components/Dialog/DialogContent.d.ts +5 -5
- package/dist/types/components/Dialog/DialogDescription.d.ts +3 -3
- package/dist/types/components/Dialog/DialogFooter.d.ts +3 -3
- package/dist/types/components/Dialog/DialogHeader.d.ts +4 -4
- package/dist/types/components/Dialog/DialogTitle.d.ts +3 -3
- package/dist/types/components/Dialog/DialogTrigger.d.ts +3 -3
- package/dist/types/components/DropdownMenu/DropdownMenu.d.ts +3 -3
- package/dist/types/components/DropdownMenu/DropdownMenuCheckboxItem.d.ts +4 -4
- package/dist/types/components/DropdownMenu/DropdownMenuContent.d.ts +6 -6
- package/dist/types/components/DropdownMenu/DropdownMenuGroup.d.ts +3 -3
- package/dist/types/components/DropdownMenu/DropdownMenuItem.d.ts +3 -3
- package/dist/types/components/DropdownMenu/DropdownMenuRadioGroup.d.ts +3 -3
- package/dist/types/components/DropdownMenu/DropdownMenuRadioItem.d.ts +4 -4
- package/dist/types/components/DropdownMenu/DropdownMenuSubContent.d.ts +4 -4
- package/dist/types/components/DropdownMenu/DropdownMenuSubTrigger.d.ts +3 -3
- package/dist/types/components/DropdownMenu/DropdownMenuTrigger.d.ts +3 -3
- package/dist/types/components/ErrorBoundary/ErrorBoundary.d.ts +10 -10
- package/dist/types/components/Feedback/Feedback.d.ts +4 -4
- package/dist/types/components/FeedbackList/FeedbackList.d.ts +3 -3
- package/dist/types/components/FeedbackList/FeedbackListContext.d.ts +1 -2
- package/dist/types/components/FeedbackPopover/FeedbackPopover.d.ts +6 -6
- package/dist/types/components/FeedbackPopover/FeedbackPopoverContext.d.ts +1 -2
- package/dist/types/components/Field/Field.d.ts +3 -3
- package/dist/types/components/Field/FieldContext.d.ts +5 -5
- package/dist/types/components/FieldGroup/FieldGroup.d.ts +3 -3
- package/dist/types/components/FieldGroup/FieldGroupBody.d.ts +3 -3
- package/dist/types/components/FieldGroup/FieldGroupContext.d.ts +4 -4
- package/dist/types/components/FieldGroup/FieldGroupHeader.d.ts +6 -6
- package/dist/types/components/FieldGroup/FieldGroupTitle.d.ts +3 -3
- package/dist/types/components/Grid/Grid.d.ts +3 -3
- package/dist/types/components/Heading/Heading.d.ts +3 -3
- package/dist/types/components/HelperText/HelperText.d.ts +3 -3
- package/dist/types/components/Icon/Icon.d.ts +4 -4
- package/dist/types/components/IconButton/IconButton.d.ts +9 -9
- package/dist/types/components/Input/Input.d.ts +14 -14
- package/dist/types/components/Input/InputWithContainerRef.d.ts +4 -4
- package/dist/types/components/Keyboard/Keyboard.d.ts +3 -3
- package/dist/types/components/Label/Label.d.ts +10 -10
- package/dist/types/components/Link/Link.d.ts +4 -4
- package/dist/types/components/Link/LinkContext.d.ts +1 -2
- package/dist/types/components/Mark/Mark.d.ts +3 -3
- package/dist/types/components/MenuList/MenuList.d.ts +3 -3
- package/dist/types/components/MenuList/MenuListContext.d.ts +1 -2
- package/dist/types/components/MenuList/MenuListGroup.d.ts +7 -7
- package/dist/types/components/MenuList/MenuListItem.d.ts +13 -13
- package/dist/types/components/NumericInput/NumericInput.d.ts +3 -3
- package/dist/types/components/Output/Output.d.ts +3 -3
- package/dist/types/components/Overlay/Overlay.d.ts +3 -3
- package/dist/types/components/Popover/PopoverClose.d.ts +3 -3
- package/dist/types/components/Popover/PopoverContent.d.ts +5 -5
- package/dist/types/components/Popover/PopoverTrigger.d.ts +3 -3
- package/dist/types/components/Portal/Portal.d.ts +3 -3
- package/dist/types/components/Portal/PortalContext.d.ts +1 -2
- package/dist/types/components/RadioGroup/Radio.d.ts +10 -10
- package/dist/types/components/RadioGroup/RadioGroup.d.ts +10 -10
- package/dist/types/components/Root/Root.d.ts +14 -10
- package/dist/types/components/Root/RootContext.d.ts +1 -2
- package/dist/types/components/Root/RootElement.d.ts +9 -0
- package/dist/types/components/Root/index.d.ts +1 -1
- package/dist/types/components/Select/Option.d.ts +3 -3
- package/dist/types/components/Select/OptionsGroup.d.ts +3 -3
- package/dist/types/components/Select/Select.d.ts +11 -11
- package/dist/types/components/Select/SelectContext.d.ts +6 -6
- package/dist/types/components/Separator/Separator.d.ts +3 -3
- package/dist/types/components/Slot/Slottable.d.ts +3 -3
- package/dist/types/components/Spinner/Spinner.d.ts +3 -3
- package/dist/types/components/Stack/Stack.d.ts +8 -8
- package/dist/types/components/Stepper/Step.d.ts +5 -5
- package/dist/types/components/Stepper/StepContent.d.ts +3 -3
- package/dist/types/components/Stepper/StepList.d.ts +3 -3
- package/dist/types/components/Stepper/Stepper.d.ts +5 -5
- package/dist/types/components/Stepper/StepperContext.d.ts +1 -2
- package/dist/types/components/Table/Table.d.ts +5 -5
- package/dist/types/components/Table/TableBody.d.ts +3 -3
- package/dist/types/components/Table/TableCell.d.ts +4 -4
- package/dist/types/components/Table/TableColumn.d.ts +14 -14
- package/dist/types/components/Table/TableContext.d.ts +4 -5
- package/dist/types/components/Table/TableFoot.d.ts +3 -3
- package/dist/types/components/Table/TableHead.d.ts +4 -4
- package/dist/types/components/Table/TableRow.d.ts +3 -3
- package/dist/types/components/Tabs/Tab.d.ts +4 -4
- package/dist/types/components/Tabs/TabContent.d.ts +3 -3
- package/dist/types/components/Tabs/TabList.d.ts +5 -5
- package/dist/types/components/Tabs/Tabs.d.ts +3 -3
- package/dist/types/components/Tabs/TabsContext.d.ts +1 -2
- package/dist/types/components/Tag/Tag.d.ts +7 -7
- package/dist/types/components/TextArea/TextArea.d.ts +3 -3
- package/dist/types/components/Toast/Toast.d.ts +11 -11
- package/dist/types/components/Toast/ToastProvider.d.ts +2 -2
- package/dist/types/components/Toast/ToastTitle.d.ts +3 -3
- package/dist/types/components/Toast/ToastViewport.d.ts +3 -3
- package/dist/types/components/Tooltip/Tooltip.d.ts +7 -7
- package/dist/types/index.d.ts +1 -1
- package/dist/types/locales/en-GB.d.ts +3 -0
- package/dist/types/locales/en-US.d.ts +3 -0
- package/dist/types/{locale → locales}/en.d.ts +1 -1
- package/dist/types/locales/fr.d.ts +3 -0
- package/dist/types/locales/index.d.ts +4 -0
- package/dist/types/locales/pt.d.ts +3 -0
- package/dist/types/providers/AlertDialogProvider/AlertDialogProvider.d.ts +2 -2
- package/dist/types/providers/AlertDialogProvider/AlertDialogProviderContext.d.ts +17 -17
- package/dist/types/providers/DocumentTitleProvider/DocumentTitle.d.ts +2 -2
- package/dist/types/providers/DocumentTitleProvider/DocumentTitleProvider.d.ts +2 -2
- package/dist/types/providers/DocumentTitleProvider/DocumentTitleProviderContext.d.ts +2 -3
- package/dist/types/providers/ErrorReportingProvider/ErrorReport.d.ts +2 -2
- package/dist/types/providers/ErrorReportingProvider/ErrorReportingContext.d.ts +3 -3
- package/dist/types/providers/ErrorReportingProvider/ErrorReportingProvider.d.ts +2 -2
- package/dist/types/providers/ErrorReportingProvider/useErrorReporter.d.ts +1 -2
- package/dist/types/providers/LocalizationProvider/LocalizationContext.d.ts +6 -4
- package/dist/types/{locale → providers/LocalizationProvider}/LocalizationObject.d.ts +18 -18
- package/dist/types/providers/LocalizationProvider/LocalizationProvider.d.ts +13 -5
- package/dist/types/providers/LocalizationProvider/index.d.ts +1 -0
- package/dist/types/providers/LocalizationProvider/useLocale.d.ts +6 -3
- package/dist/types/providers/PrefixProvider/PrefixContext.d.ts +1 -4
- package/dist/types/providers/PrefixProvider/PrefixProvider.d.ts +3 -3
- package/dist/types/providers/PrefixProvider/defaultPrefix.d.ts +12 -0
- package/dist/types/providers/PrefixProvider/index.d.ts +1 -0
- package/dist/types/providers/PrefixProvider/usePrefix.d.ts +1 -1
- package/dist/types/providers/ToastManagerProvider/ToastManagerContext.d.ts +7 -7
- package/dist/types/providers/ToastManagerProvider/ToastManagerProvider.d.ts +2 -2
- package/dist/types/utils/control.d.ts +1 -2
- package/dist/types/utils/useCombinedRef.d.ts +2 -2
- package/dist/types/utils/useControllableState.d.ts +2 -2
- package/dist/types/utils/useLayoutEffect.d.ts +2 -2
- package/package.json +20 -4
- package/dist/ostack-ui.cjs +0 -11095
- package/dist/ostack-ui.cjs.map +0 -1
- package/dist/types/locale/defaultLocale.d.ts +0 -3
- package/dist/types/locale/en-GB.d.ts +0 -3
- package/dist/types/locale/en-US.d.ts +0 -3
- package/dist/types/locale/fr-FR.d.ts +0 -3
- package/dist/types/locale/index.d.ts +0 -6
- package/dist/types/locale/pt-PT.d.ts +0 -3
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { type ComponentPropsWithoutRef, type Key, type MouseEvent, type ReactNode } from "react";
|
|
2
2
|
import { Button } from "../Button";
|
|
3
3
|
/** Properties of the data table selection trigger component. */
|
|
4
|
-
export interface DataTableSelectionTriggerProps extends Omit<
|
|
4
|
+
export interface DataTableSelectionTriggerProps extends Omit<ComponentPropsWithoutRef<typeof Button>, "onClick"> {
|
|
5
5
|
/**
|
|
6
6
|
* Whether the button should be displayed when no rows are selected.
|
|
7
7
|
*
|
|
@@ -14,8 +14,8 @@ export interface DataTableSelectionTriggerProps extends Omit<React.ComponentProp
|
|
|
14
14
|
* @param selectedRows Rows currently selected.
|
|
15
15
|
* @param event Original click event.
|
|
16
16
|
*/
|
|
17
|
-
onClick: (selectedRows:
|
|
18
|
-
children:
|
|
17
|
+
onClick: (selectedRows: Key[], event: MouseEvent) => void;
|
|
18
|
+
children: ReactNode;
|
|
19
19
|
}
|
|
20
20
|
/** Trigger used to run an action over selected rows. */
|
|
21
|
-
export declare const DataTableSelectionTrigger:
|
|
21
|
+
export declare const DataTableSelectionTrigger: import("react").ForwardRefExoticComponent<DataTableSelectionTriggerProps & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { type ComponentPropsWithoutRef } from "react";
|
|
2
2
|
import { type DataTablePaginationProps } from "./DataTablePagination.tsx";
|
|
3
3
|
/** Properties of the scrolled data table pagination. */
|
|
4
|
-
export interface PagedDataTablePaginationProps extends
|
|
4
|
+
export interface PagedDataTablePaginationProps extends ComponentPropsWithoutRef<"div">, Pick<DataTablePaginationProps, "rowsRange" | "previousPageButtonLabel" | "nextPageButtonLabel"> {
|
|
5
5
|
}
|
|
6
6
|
/** Pagination component of the scrolled data table. */
|
|
7
|
-
export declare const PagedDataTablePagination:
|
|
7
|
+
export declare const PagedDataTablePagination: import("react").ForwardRefExoticComponent<PagedDataTablePaginationProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { type ComponentPropsWithoutRef } from "react";
|
|
2
2
|
import { type DataTablePaginationProps } from "./DataTablePagination.tsx";
|
|
3
3
|
/** Properties of the scrolled data table pagination. */
|
|
4
|
-
export interface ScrolledDataTablePaginationProps extends
|
|
4
|
+
export interface ScrolledDataTablePaginationProps extends ComponentPropsWithoutRef<"div">, Pick<DataTablePaginationProps, "rowsRange"> {
|
|
5
5
|
}
|
|
6
6
|
/** Pagination component of the scrolled data table. */
|
|
7
|
-
export declare const ScrolledDataTablePagination:
|
|
7
|
+
export declare const ScrolledDataTablePagination: import("react").ForwardRefExoticComponent<ScrolledDataTablePaginationProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type
|
|
1
|
+
import { type Key } from "react";
|
|
2
2
|
import { type DataTableProps } from "./DataTable.tsx";
|
|
3
3
|
/** Returns the key of a row. */
|
|
4
|
-
export declare function getRowKey<T = unknown>(row: T, rowKey: DataTableProps<T>["rowKey"]):
|
|
4
|
+
export declare function getRowKey<T = unknown>(row: T, rowKey: DataTableProps<T>["rowKey"]): Key;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { type Locale } from "date-fns";
|
|
2
|
-
import
|
|
2
|
+
import { type ComponentPropsWithoutRef, type ComponentPropsWithRef } from "react";
|
|
3
3
|
import { DatePicker } from "../DatePicker";
|
|
4
4
|
import { type Input } from "../Input";
|
|
5
5
|
import { PopoverContent } from "../Popover";
|
|
6
6
|
/** Properties of the date input component. */
|
|
7
|
-
export interface DateInputProps extends Omit<
|
|
7
|
+
export interface DateInputProps extends Omit<ComponentPropsWithoutRef<typeof Input>, "defaultValue" | "value" | "onValueChange"> {
|
|
8
8
|
/** Date input's default value. */
|
|
9
9
|
defaultValue?: string | Date | null;
|
|
10
10
|
/** Date input's controlled value. */
|
|
@@ -54,9 +54,9 @@ export interface DateInputProps extends Omit<React.ComponentPropsWithoutRef<type
|
|
|
54
54
|
/** Function called whenever the popover's open state changes. */
|
|
55
55
|
onPopoverOpenChange?: (open: boolean) => void;
|
|
56
56
|
/** Properties to pass to the date picker component. */
|
|
57
|
-
datePickerProps?: Omit<
|
|
57
|
+
datePickerProps?: Omit<ComponentPropsWithRef<typeof DatePicker>, "value" | "defaultValue" | "minDate" | "maxDate" | "minMonth" | "maxMonth" | "minYear" | "maxYear" | "locale">;
|
|
58
58
|
/** Properties to pass to the popover content component. */
|
|
59
|
-
popoverContentProps?:
|
|
59
|
+
popoverContentProps?: ComponentPropsWithRef<typeof PopoverContent>;
|
|
60
60
|
}
|
|
61
61
|
/** Representations of the date value. */
|
|
62
62
|
export interface DateValueRepresentations {
|
|
@@ -84,4 +84,4 @@ export interface DateValueRepresentations {
|
|
|
84
84
|
* }
|
|
85
85
|
* ```
|
|
86
86
|
*/
|
|
87
|
-
export declare const DateInput:
|
|
87
|
+
export declare const DateInput: import("react").ForwardRefExoticComponent<DateInputProps & import("react").RefAttributes<HTMLInputElement>>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { type ComponentPropsWithoutRef } from "react";
|
|
2
2
|
import { Calendar } from "../Calendar";
|
|
3
3
|
/** Properties of the date picker component. */
|
|
4
|
-
export interface DatePickerProps extends
|
|
4
|
+
export interface DatePickerProps extends ComponentPropsWithoutRef<typeof Calendar> {
|
|
5
5
|
/** Default date value. */
|
|
6
6
|
defaultValue?: Date | null;
|
|
7
7
|
/** Controlled selected date value. */
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type Locale } from "date-fns";
|
|
2
|
-
import
|
|
2
|
+
import { type ComponentPropsWithoutRef, type ComponentPropsWithRef, type CSSProperties, type FocusEvent, type ReactNode } from "react";
|
|
3
3
|
import { type ControlStatus, type ControlVariant } from "../../utils/control.ts";
|
|
4
4
|
import { type Responsive } from "../../utils/useResponsiveValues.ts";
|
|
5
5
|
import { CloseButton } from "../CloseButton";
|
|
@@ -14,7 +14,7 @@ export interface StringRange {
|
|
|
14
14
|
end: string;
|
|
15
15
|
}
|
|
16
16
|
/** Properties of the date-range input component. */
|
|
17
|
-
export interface DateRangeInputProps extends Omit<
|
|
17
|
+
export interface DateRangeInputProps extends Omit<ComponentPropsWithoutRef<"div">, "defaultValue"> {
|
|
18
18
|
/**
|
|
19
19
|
* Date-range input's style variant. Defaults to the default variant unless
|
|
20
20
|
* when rendering inside a table cell (in which it defaults to `"cell"`).
|
|
@@ -23,7 +23,7 @@ export interface DateRangeInputProps extends Omit<React.ComponentPropsWithoutRef
|
|
|
23
23
|
/** Sets the status of the date-range input. */
|
|
24
24
|
status?: ControlStatus;
|
|
25
25
|
/** Date-range input code. */
|
|
26
|
-
code?:
|
|
26
|
+
code?: ReactNode;
|
|
27
27
|
/** Default date-range value. */
|
|
28
28
|
defaultValue?: DateRange | StringRange;
|
|
29
29
|
/** Date-range value. */
|
|
@@ -75,11 +75,11 @@ export interface DateRangeInputProps extends Omit<React.ComponentPropsWithoutRef
|
|
|
75
75
|
*/
|
|
76
76
|
endLoading?: boolean;
|
|
77
77
|
/** Sets the inputs' text align. */
|
|
78
|
-
align?: Responsive<
|
|
78
|
+
align?: Responsive<CSSProperties["textAlign"]>;
|
|
79
79
|
/** Date-range input's start adornment. */
|
|
80
|
-
startAdornment?:
|
|
80
|
+
startAdornment?: ReactNode;
|
|
81
81
|
/** Date-range input's end adornment. */
|
|
82
|
-
endAdornment?:
|
|
82
|
+
endAdornment?: ReactNode;
|
|
83
83
|
/**
|
|
84
84
|
* Whether to show buttons to clear the start/end inputs when they have
|
|
85
85
|
* content.
|
|
@@ -137,29 +137,29 @@ export interface DateRangeInputProps extends Omit<React.ComponentPropsWithoutRef
|
|
|
137
137
|
* This is useful when there is a need to know when the user stops interacting
|
|
138
138
|
* with the control.
|
|
139
139
|
*/
|
|
140
|
-
onBlurToOutside?: (event:
|
|
140
|
+
onBlurToOutside?: (event: FocusEvent) => void;
|
|
141
141
|
/** Properties to pass to the code component. */
|
|
142
|
-
codeProps?:
|
|
142
|
+
codeProps?: ComponentPropsWithRef<typeof ControlCode>;
|
|
143
143
|
/** Properties to pass to the popover anchor component. */
|
|
144
|
-
popoverAnchorProps?:
|
|
144
|
+
popoverAnchorProps?: ComponentPropsWithRef<typeof PopoverAnchor>;
|
|
145
145
|
/** Properties to pass to the start container element. */
|
|
146
|
-
startContainerProps?:
|
|
146
|
+
startContainerProps?: ComponentPropsWithRef<"div">;
|
|
147
147
|
/** Properties to pass to the end container element. */
|
|
148
|
-
endContainerProps?:
|
|
148
|
+
endContainerProps?: ComponentPropsWithRef<"div">;
|
|
149
149
|
/** Properties to pass to the input component representing the start date. */
|
|
150
|
-
startInputProps?:
|
|
150
|
+
startInputProps?: ComponentPropsWithRef<"input">;
|
|
151
151
|
/** Properties to pass to the input component representing the end date. */
|
|
152
|
-
endInputProps?:
|
|
152
|
+
endInputProps?: ComponentPropsWithRef<"input">;
|
|
153
153
|
/** Properties to pass to the button component that clears the start date. */
|
|
154
|
-
startClearButtonProps?:
|
|
154
|
+
startClearButtonProps?: ComponentPropsWithRef<typeof CloseButton>;
|
|
155
155
|
/** Properties to pass to the button component that clears the end date. */
|
|
156
|
-
endClearButtonProps?:
|
|
156
|
+
endClearButtonProps?: ComponentPropsWithRef<typeof CloseButton>;
|
|
157
157
|
/** Properties to pass to the spinner component. */
|
|
158
|
-
spinnerProps?: Omit<
|
|
158
|
+
spinnerProps?: Omit<ComponentPropsWithRef<typeof Spinner>, "size">;
|
|
159
159
|
/** Properties to pass to the date-range picker component. */
|
|
160
|
-
dateRangePickerProps?: Omit<
|
|
160
|
+
dateRangePickerProps?: Omit<ComponentPropsWithRef<typeof DateRangePicker>, "value" | "defaultValue" | "minDate" | "maxDate" | "minMonth" | "maxMonth" | "minYear" | "maxYear" | "locale">;
|
|
161
161
|
/** Properties to pass to the popover content component. */
|
|
162
|
-
popoverContentProps?:
|
|
162
|
+
popoverContentProps?: ComponentPropsWithRef<typeof PopoverContent>;
|
|
163
163
|
}
|
|
164
164
|
/** Representations of the date-range value. */
|
|
165
165
|
export interface DateRangeValueRepresentations {
|
|
@@ -194,4 +194,4 @@ export interface DateRangeValueRepresentations {
|
|
|
194
194
|
* }
|
|
195
195
|
* ```
|
|
196
196
|
*/
|
|
197
|
-
export declare const DateRangeInput:
|
|
197
|
+
export declare const DateRangeInput: import("react").ForwardRefExoticComponent<DateRangeInputProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { type ComponentPropsWithoutRef } from "react";
|
|
2
2
|
import { Calendar } from "../Calendar";
|
|
3
3
|
/** A range of dates from a start date to an end date. */
|
|
4
4
|
export interface DateRange {
|
|
@@ -8,7 +8,7 @@ export interface DateRange {
|
|
|
8
8
|
/** Mode specifying which end of the range the user is controlling. */
|
|
9
9
|
export type DateRangePickerSelectionMode = "start" | "end" | "both";
|
|
10
10
|
/** Properties of the date-range picker component. */
|
|
11
|
-
export interface DateRangePickerProps extends
|
|
11
|
+
export interface DateRangePickerProps extends ComponentPropsWithoutRef<typeof Calendar> {
|
|
12
12
|
/** Default date-range value. */
|
|
13
13
|
defaultValue?: DateRange;
|
|
14
14
|
/** Controlled selected date-range value. */
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { type ComponentPropsWithoutRef } from "react";
|
|
2
2
|
import { CardBody } from "../Card";
|
|
3
3
|
/** Properties of the dialog body component. */
|
|
4
|
-
export interface DialogBodyProps extends
|
|
4
|
+
export interface DialogBodyProps extends ComponentPropsWithoutRef<typeof CardBody> {
|
|
5
5
|
}
|
|
6
6
|
/** Body section of the dialog. */
|
|
7
|
-
export declare const DialogBody:
|
|
7
|
+
export declare const DialogBody: import("react").ForwardRefExoticComponent<DialogBodyProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Dialog as DialogPrimitive } from "radix-ui";
|
|
2
|
-
import
|
|
2
|
+
import { type ComponentPropsWithoutRef } from "react";
|
|
3
3
|
/** Properties of the dialog close component. */
|
|
4
|
-
export interface DialogCloseProps extends Omit<
|
|
4
|
+
export interface DialogCloseProps extends Omit<ComponentPropsWithoutRef<typeof DialogPrimitive.Close>, "asChild"> {
|
|
5
5
|
}
|
|
6
6
|
/** Button which closes the dialog. */
|
|
7
|
-
export declare const DialogClose:
|
|
7
|
+
export declare const DialogClose: import("react").ForwardRefExoticComponent<DialogCloseProps & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Dialog as DialogPrimitive } from "radix-ui";
|
|
2
|
-
import
|
|
2
|
+
import { type ComponentPropsWithoutRef, type ComponentPropsWithRef } from "react";
|
|
3
3
|
import { type CardColor, type CardVariant } from "../Card";
|
|
4
4
|
import { Overlay } from "../Overlay";
|
|
5
5
|
/** Dialog content variants. */
|
|
@@ -9,7 +9,7 @@ export type DialogContentColor = CardColor;
|
|
|
9
9
|
/** Possible dialog content sizes. */
|
|
10
10
|
export type DialogContentSize = "sm" | "md" | "lg" | "xl";
|
|
11
11
|
/** Properties of the dialog content component. */
|
|
12
|
-
export interface DialogContentProps extends
|
|
12
|
+
export interface DialogContentProps extends ComponentPropsWithoutRef<typeof DialogPrimitive.Content> {
|
|
13
13
|
/**
|
|
14
14
|
* Dialog content variant.
|
|
15
15
|
*
|
|
@@ -37,9 +37,9 @@ export interface DialogContentProps extends React.ComponentPropsWithoutRef<typeo
|
|
|
37
37
|
*/
|
|
38
38
|
size?: DialogContentSize;
|
|
39
39
|
/** Properties to pass to the portal component. */
|
|
40
|
-
portalProps?: Omit<
|
|
40
|
+
portalProps?: Omit<ComponentPropsWithRef<typeof DialogPrimitive.Portal>, "forceMount">;
|
|
41
41
|
/** Properties to pass to the `Overlay` component. */
|
|
42
|
-
overlayProps?:
|
|
42
|
+
overlayProps?: ComponentPropsWithRef<typeof Overlay>;
|
|
43
43
|
}
|
|
44
44
|
/** Content to be rendered in the open dialog. */
|
|
45
|
-
export declare const DialogContent:
|
|
45
|
+
export declare const DialogContent: import("react").ForwardRefExoticComponent<DialogContentProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Dialog as DialogPrimitive } from "radix-ui";
|
|
2
|
-
import
|
|
2
|
+
import { type ComponentPropsWithoutRef } from "react";
|
|
3
3
|
/** Properties of the dialog description component. */
|
|
4
|
-
export interface DialogDescriptionProps extends
|
|
4
|
+
export interface DialogDescriptionProps extends ComponentPropsWithoutRef<typeof DialogPrimitive.Description> {
|
|
5
5
|
}
|
|
6
6
|
/**
|
|
7
7
|
* Optional accessible description to be announced when the dialog is opened.
|
|
@@ -10,4 +10,4 @@ export interface DialogDescriptionProps extends React.ComponentPropsWithoutRef<t
|
|
|
10
10
|
* the description entirely, pass `aria-describedby={undefined}` to the
|
|
11
11
|
* `DialogContent` and omit this component.
|
|
12
12
|
*/
|
|
13
|
-
export declare const DialogDescription:
|
|
13
|
+
export declare const DialogDescription: import("react").ForwardRefExoticComponent<DialogDescriptionProps & import("react").RefAttributes<HTMLParagraphElement>>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { type ComponentPropsWithoutRef } from "react";
|
|
2
2
|
import { CardFooter } from "../Card";
|
|
3
3
|
/** Properties of the dialog footer component. */
|
|
4
|
-
export interface DialogFooterProps extends
|
|
4
|
+
export interface DialogFooterProps extends ComponentPropsWithoutRef<typeof CardFooter> {
|
|
5
5
|
}
|
|
6
6
|
/** Footer section of the dialog. */
|
|
7
|
-
export declare const DialogFooter:
|
|
7
|
+
export declare const DialogFooter: import("react").ForwardRefExoticComponent<DialogFooterProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { type ComponentPropsWithoutRef, type ComponentPropsWithRef } from "react";
|
|
2
2
|
import { CardHeader } from "../Card";
|
|
3
3
|
import { CloseButton } from "../CloseButton";
|
|
4
4
|
/** Properties of the dialog header component. */
|
|
5
|
-
export interface DialogHeaderProps extends
|
|
5
|
+
export interface DialogHeaderProps extends ComponentPropsWithoutRef<typeof CardHeader> {
|
|
6
6
|
/**
|
|
7
7
|
* Whether to show a close button.
|
|
8
8
|
*
|
|
@@ -10,7 +10,7 @@ export interface DialogHeaderProps extends React.ComponentPropsWithoutRef<typeof
|
|
|
10
10
|
*/
|
|
11
11
|
showCloseButton?: boolean;
|
|
12
12
|
/** Properties to pass to the close button component. */
|
|
13
|
-
closeButtonProps?:
|
|
13
|
+
closeButtonProps?: ComponentPropsWithRef<typeof CloseButton>;
|
|
14
14
|
}
|
|
15
15
|
/** Header section of the dialog. */
|
|
16
|
-
export declare const DialogHeader:
|
|
16
|
+
export declare const DialogHeader: import("react").ForwardRefExoticComponent<DialogHeaderProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Dialog as DialogPrimitive } from "radix-ui";
|
|
2
|
-
import
|
|
2
|
+
import { type ComponentPropsWithoutRef } from "react";
|
|
3
3
|
/** Properties of the dialog title component. */
|
|
4
|
-
export interface DialogTitleProps extends
|
|
4
|
+
export interface DialogTitleProps extends ComponentPropsWithoutRef<typeof DialogPrimitive.Title> {
|
|
5
5
|
}
|
|
6
6
|
/** Accessible title to be announced when the dialog is opened. */
|
|
7
|
-
export declare const DialogTitle:
|
|
7
|
+
export declare const DialogTitle: import("react").ForwardRefExoticComponent<DialogTitleProps & import("react").RefAttributes<HTMLHeadingElement>>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Dialog as DialogPrimitive } from "radix-ui";
|
|
2
|
-
import
|
|
2
|
+
import { type ComponentPropsWithoutRef } from "react";
|
|
3
3
|
/** Properties of the dialog trigger component. */
|
|
4
|
-
export interface DialogTriggerProps extends Omit<
|
|
4
|
+
export interface DialogTriggerProps extends Omit<ComponentPropsWithoutRef<typeof DialogPrimitive.Trigger>, "asChild"> {
|
|
5
5
|
}
|
|
6
6
|
/** The button which, when pressed, opens the dialog. */
|
|
7
|
-
export declare const DialogTrigger:
|
|
7
|
+
export declare const DialogTrigger: import("react").ForwardRefExoticComponent<DialogTriggerProps & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { DropdownMenu as DropdownMenuPrimitive } from "radix-ui";
|
|
2
|
-
import type
|
|
2
|
+
import { type ComponentPropsWithoutRef, type ComponentType } from "react";
|
|
3
3
|
/** Properties of the dropdown menu component. */
|
|
4
|
-
export interface DropdownMenuProps extends Omit<
|
|
4
|
+
export interface DropdownMenuProps extends Omit<ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.Root>, "dir"> {
|
|
5
5
|
}
|
|
6
6
|
/**
|
|
7
7
|
* Menu displayed within a dropdown, containing a set of actions.
|
|
@@ -62,4 +62,4 @@ export interface DropdownMenuProps extends Omit<React.ComponentPropsWithoutRef<t
|
|
|
62
62
|
* }
|
|
63
63
|
* ```
|
|
64
64
|
*/
|
|
65
|
-
export declare const DropdownMenu:
|
|
65
|
+
export declare const DropdownMenu: ComponentType<DropdownMenuProps>;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { DropdownMenu as DropdownMenuPrimitive } from "radix-ui";
|
|
2
|
-
import
|
|
2
|
+
import { type ComponentPropsWithoutRef, type ComponentPropsWithRef } from "react";
|
|
3
3
|
import { type CheckboxChecked } from "../Checkbox";
|
|
4
4
|
import { Icon } from "../Icon";
|
|
5
5
|
import { type MenuListItemProps } from "../MenuList";
|
|
6
6
|
/** Properties of the dropdown menu checkbox item. */
|
|
7
|
-
export interface DropdownMenuCheckboxItemProps extends Omit<
|
|
7
|
+
export interface DropdownMenuCheckboxItemProps extends Omit<ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.CheckboxItem>, "asChild" | "color">, Pick<MenuListItemProps, "color" | "loading" | "enabledWhenLoading" | "loadingContent" | "iconPlacement" | "actionProps" | "contentProps" | "iconProps" | "spinnerProps"> {
|
|
8
8
|
/**
|
|
9
9
|
* Whether to show the checkbox.
|
|
10
10
|
*
|
|
@@ -18,7 +18,7 @@ export interface DropdownMenuCheckboxItemProps extends Omit<React.ComponentProps
|
|
|
18
18
|
*/
|
|
19
19
|
onCheckedChange?: (value: CheckboxChecked) => void;
|
|
20
20
|
/** Properties to pass to the checkbox indicator component. */
|
|
21
|
-
indicatorProps?: Omit<
|
|
21
|
+
indicatorProps?: Omit<ComponentPropsWithRef<typeof Icon>, "icon">;
|
|
22
22
|
}
|
|
23
23
|
/** A dropdown menu item that can be controlled and rendered like a checkbox. */
|
|
24
|
-
export declare const DropdownMenuCheckboxItem:
|
|
24
|
+
export declare const DropdownMenuCheckboxItem: import("react").ForwardRefExoticComponent<DropdownMenuCheckboxItemProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { DropdownMenu as DropdownMenuPrimitive } from "radix-ui";
|
|
2
|
-
import
|
|
2
|
+
import { type ComponentPropsWithoutRef, type ComponentPropsWithRef } from "react";
|
|
3
3
|
import { MenuList, type MenuListProps } from "../MenuList";
|
|
4
4
|
/** Properties of the dropdown menu content component. */
|
|
5
|
-
export interface DropdownMenuContentProps extends Omit<
|
|
5
|
+
export interface DropdownMenuContentProps extends Omit<ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.Content>, "asChild">, Pick<MenuListProps, "variant" | "iconPlacement"> {
|
|
6
6
|
/**
|
|
7
7
|
* Whether to show an arrow pointing to the anchor.
|
|
8
8
|
*
|
|
@@ -10,11 +10,11 @@ export interface DropdownMenuContentProps extends Omit<React.ComponentPropsWitho
|
|
|
10
10
|
*/
|
|
11
11
|
showArrow?: boolean;
|
|
12
12
|
/** Properties to pass to the portal component. */
|
|
13
|
-
portalProps?: Omit<
|
|
13
|
+
portalProps?: Omit<ComponentPropsWithRef<typeof DropdownMenuPrimitive.Portal>, "forceMount">;
|
|
14
14
|
/** Properties to pass to the arrow component. */
|
|
15
|
-
arrowProps?:
|
|
15
|
+
arrowProps?: ComponentPropsWithRef<typeof DropdownMenuPrimitive.Arrow>;
|
|
16
16
|
/** Properties to pass to the menu list component. */
|
|
17
|
-
menuListProps?: Omit<
|
|
17
|
+
menuListProps?: Omit<ComponentPropsWithRef<typeof MenuList>, "variant" | "iconPlacement" | "asChild">;
|
|
18
18
|
}
|
|
19
19
|
/** The component that pops out when the dropdown menu is open. */
|
|
20
|
-
export declare const DropdownMenuContent:
|
|
20
|
+
export declare const DropdownMenuContent: import("react").ForwardRefExoticComponent<DropdownMenuContentProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { DropdownMenu as DropdownMenuPrimitive } from "radix-ui";
|
|
2
|
-
import
|
|
2
|
+
import { type ComponentPropsWithoutRef } from "react";
|
|
3
3
|
import { type MenuListGroupProps } from "../MenuList/MenuListGroup.tsx";
|
|
4
4
|
/** Properties of the dropdown menu group. */
|
|
5
|
-
export interface DropdownMenuGroupProps extends Omit<
|
|
5
|
+
export interface DropdownMenuGroupProps extends Omit<ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.Group>, "asChild">, Pick<MenuListGroupProps, "label" | "itemProps" | "labelProps"> {
|
|
6
6
|
}
|
|
7
7
|
/** Component used to group multiple dropdown menu items. */
|
|
8
|
-
export declare const DropdownMenuGroup:
|
|
8
|
+
export declare const DropdownMenuGroup: import("react").ForwardRefExoticComponent<DropdownMenuGroupProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { DropdownMenu as DropdownMenuPrimitive } from "radix-ui";
|
|
2
|
-
import
|
|
2
|
+
import { type ComponentPropsWithoutRef } from "react";
|
|
3
3
|
import { type MenuListItemProps } from "../MenuList";
|
|
4
4
|
/** Properties of the dropdown menu item. */
|
|
5
|
-
export interface DropdownMenuItemProps extends Omit<
|
|
5
|
+
export interface DropdownMenuItemProps extends Omit<ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.Item>, "asChild" | "color">, Pick<MenuListItemProps, "selected" | "color" | "loading" | "enabledWhenLoading" | "loadingContent" | "icon" | "iconPlacement" | "href" | "target" | "rel" | "actionProps" | "contentProps" | "iconProps" | "spinnerProps"> {
|
|
6
6
|
/**
|
|
7
7
|
* Render the item as a link. When set, you can pass `href`, `target`, and
|
|
8
8
|
* `rel` properties to the item.
|
|
@@ -12,4 +12,4 @@ export interface DropdownMenuItemProps extends Omit<React.ComponentPropsWithoutR
|
|
|
12
12
|
asLink?: boolean;
|
|
13
13
|
}
|
|
14
14
|
/** Component containing a dropdown menu item. */
|
|
15
|
-
export declare const DropdownMenuItem:
|
|
15
|
+
export declare const DropdownMenuItem: import("react").ForwardRefExoticComponent<DropdownMenuItemProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { DropdownMenu as DropdownMenuPrimitive } from "radix-ui";
|
|
2
|
-
import
|
|
2
|
+
import { type ComponentPropsWithoutRef } from "react";
|
|
3
3
|
import { type MenuListGroupProps } from "../MenuList/MenuListGroup.tsx";
|
|
4
4
|
/** Properties of the dropdown menu radio group. */
|
|
5
|
-
export interface DropdownMenuRadioGroupProps extends Omit<
|
|
5
|
+
export interface DropdownMenuRadioGroupProps extends Omit<ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.RadioGroup>, "asChild">, Pick<MenuListGroupProps, "label" | "itemProps" | "labelProps"> {
|
|
6
6
|
}
|
|
7
7
|
/** Component used to group multiple dropdown menu radio items. */
|
|
8
|
-
export declare const DropdownMenuRadioGroup:
|
|
8
|
+
export declare const DropdownMenuRadioGroup: import("react").ForwardRefExoticComponent<DropdownMenuRadioGroupProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { DropdownMenu as DropdownMenuPrimitive } from "radix-ui";
|
|
2
|
-
import
|
|
2
|
+
import { type ComponentPropsWithoutRef, type ComponentPropsWithRef } from "react";
|
|
3
3
|
import { type MenuListItemProps } from "../MenuList";
|
|
4
4
|
/** Properties of the dropdown menu radio item. */
|
|
5
|
-
export interface DropdownMenuRadioItemProps extends Omit<
|
|
5
|
+
export interface DropdownMenuRadioItemProps extends Omit<ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.RadioItem>, "asChild" | "color">, Pick<MenuListItemProps, "color" | "loading" | "enabledWhenLoading" | "loadingContent" | "iconPlacement" | "actionProps" | "contentProps" | "iconProps" | "spinnerProps"> {
|
|
6
6
|
/**
|
|
7
7
|
* Whether to show the radio.
|
|
8
8
|
*
|
|
@@ -10,7 +10,7 @@ export interface DropdownMenuRadioItemProps extends Omit<React.ComponentPropsWit
|
|
|
10
10
|
*/
|
|
11
11
|
showRadio?: boolean;
|
|
12
12
|
/** Properties to pass to the indicator component. */
|
|
13
|
-
indicatorProps?:
|
|
13
|
+
indicatorProps?: ComponentPropsWithRef<typeof DropdownMenuPrimitive.ItemIndicator>;
|
|
14
14
|
}
|
|
15
15
|
/** A dropdown menu item that can be controlled and rendered like a radio. */
|
|
16
|
-
export declare const DropdownMenuRadioItem:
|
|
16
|
+
export declare const DropdownMenuRadioItem: import("react").ForwardRefExoticComponent<DropdownMenuRadioItemProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { DropdownMenu as DropdownMenuPrimitive } from "radix-ui";
|
|
2
|
-
import
|
|
2
|
+
import { type ComponentPropsWithoutRef, type ComponentPropsWithRef } from "react";
|
|
3
3
|
import { MenuList, type MenuListProps } from "../MenuList";
|
|
4
4
|
/** Properties of the dropdown menu sub content component. */
|
|
5
|
-
export interface DropdownMenuSubContentProps extends Omit<
|
|
5
|
+
export interface DropdownMenuSubContentProps extends Omit<ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.SubContent>, "asChild">, Pick<MenuListProps, "variant" | "iconPlacement"> {
|
|
6
6
|
/** Properties to pass to the menu list component. */
|
|
7
|
-
menuListProps?: Omit<
|
|
7
|
+
menuListProps?: Omit<ComponentPropsWithRef<typeof MenuList>, "variant" | "iconPlacement" | "asChild">;
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
10
|
* The component that pops out when a submenu is open. Must be rendered inside
|
|
11
11
|
* `DropdownMenuSub`.
|
|
12
12
|
*/
|
|
13
|
-
export declare const DropdownMenuSubContent:
|
|
13
|
+
export declare const DropdownMenuSubContent: import("react").ForwardRefExoticComponent<DropdownMenuSubContentProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { DropdownMenu as DropdownMenuPrimitive } from "radix-ui";
|
|
2
|
-
import
|
|
2
|
+
import { type ComponentPropsWithoutRef } from "react";
|
|
3
3
|
import { type MenuListItemProps } from "../MenuList";
|
|
4
4
|
/** Properties of the dropdown menu submenu trigger. */
|
|
5
|
-
export interface DropdownMenuSubTriggerProps extends Omit<
|
|
5
|
+
export interface DropdownMenuSubTriggerProps extends Omit<ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.SubTrigger>, "asChild" | "color">, Pick<MenuListItemProps, "color" | "icon" | "disabled" | "actionProps" | "contentProps" | "iconProps"> {
|
|
6
6
|
}
|
|
7
7
|
/**
|
|
8
8
|
* A dropdown menu item that opens a submenu. Must be rendered within a
|
|
9
9
|
* `DropdownMenuSub`.
|
|
10
10
|
*/
|
|
11
|
-
export declare const DropdownMenuSubTrigger:
|
|
11
|
+
export declare const DropdownMenuSubTrigger: import("react").ForwardRefExoticComponent<DropdownMenuSubTriggerProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { DropdownMenu as DropdownMenuPrimitive } from "radix-ui";
|
|
2
|
-
import
|
|
2
|
+
import { type ComponentPropsWithoutRef } from "react";
|
|
3
3
|
/** Properties of the dropdown menu trigger component. */
|
|
4
|
-
export interface DropdownMenuTriggerProps extends Omit<
|
|
4
|
+
export interface DropdownMenuTriggerProps extends Omit<ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.Trigger>, "asChild"> {
|
|
5
5
|
}
|
|
6
6
|
/** Trigger component for the dropdown menu. */
|
|
7
|
-
export declare const DropdownMenuTrigger:
|
|
7
|
+
export declare const DropdownMenuTrigger: import("react").ForwardRefExoticComponent<DropdownMenuTriggerProps & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { type ComponentPropsWithoutRef, type ComponentPropsWithRef, type ComponentType, type ReactNode } from "react";
|
|
2
2
|
import { ErrorBoundary as ReactErrorBoundary } from "react-error-boundary";
|
|
3
3
|
import { Alert } from "../Alert";
|
|
4
4
|
import { IconButton } from "../IconButton";
|
|
@@ -14,7 +14,7 @@ export interface FallbackProps {
|
|
|
14
14
|
resetErrorBoundary: (...args: unknown[]) => void;
|
|
15
15
|
}
|
|
16
16
|
/** Properties of the error boundary component. */
|
|
17
|
-
export interface ErrorBoundaryProps extends Pick<
|
|
17
|
+
export interface ErrorBoundaryProps extends Pick<ComponentPropsWithoutRef<typeof ReactErrorBoundary>, "resetKeys" | "onError" | "onReset"> {
|
|
18
18
|
/**
|
|
19
19
|
* Fallback component to render in the event of an error while rendering
|
|
20
20
|
* `children`.
|
|
@@ -26,7 +26,7 @@ export interface ErrorBoundaryProps extends Pick<React.ComponentPropsWithoutRef<
|
|
|
26
26
|
* By default, a “danger” `Alert` is displayed with a message (specified via
|
|
27
27
|
* `fallbackMessage`) or the error that occurred when `showError` is set.
|
|
28
28
|
*/
|
|
29
|
-
fallback?:
|
|
29
|
+
fallback?: ReactNode | ComponentType<FallbackProps> | ((props: FallbackProps) => ReactNode);
|
|
30
30
|
/**
|
|
31
31
|
* Whether to show the error that occurred in the default fallback `Alert`.
|
|
32
32
|
*
|
|
@@ -47,7 +47,7 @@ export interface ErrorBoundaryProps extends Pick<React.ComponentPropsWithoutRef<
|
|
|
47
47
|
*
|
|
48
48
|
* By default, the locale's message is used.
|
|
49
49
|
*/
|
|
50
|
-
fallbackTitle?:
|
|
50
|
+
fallbackTitle?: ReactNode | ((error?: unknown) => ReactNode);
|
|
51
51
|
/**
|
|
52
52
|
* Message to display in the default fallback `Alert` component in the event
|
|
53
53
|
* of an error occurring while rendering `children`. This property is ignored
|
|
@@ -55,21 +55,21 @@ export interface ErrorBoundaryProps extends Pick<React.ComponentPropsWithoutRef<
|
|
|
55
55
|
*
|
|
56
56
|
* By default, the locale's message is used.
|
|
57
57
|
*/
|
|
58
|
-
fallbackMessage?:
|
|
58
|
+
fallbackMessage?: ReactNode | ((error?: unknown) => ReactNode);
|
|
59
59
|
/**
|
|
60
60
|
* Label of the button used to reset the error boundary.
|
|
61
61
|
*
|
|
62
62
|
* By default, the locale's label is used.
|
|
63
63
|
*/
|
|
64
|
-
resetButtonLabel?:
|
|
64
|
+
resetButtonLabel?: ReactNode;
|
|
65
65
|
/** Properties to pass to the default fallback `Alert` component. */
|
|
66
|
-
fallbackProps?:
|
|
66
|
+
fallbackProps?: ComponentPropsWithRef<typeof Alert>;
|
|
67
67
|
/**
|
|
68
68
|
* Properties to pass to the `IconButton` component used to reset the error
|
|
69
69
|
* boundary.
|
|
70
70
|
*/
|
|
71
|
-
resetButtonProps?:
|
|
72
|
-
children?:
|
|
71
|
+
resetButtonProps?: ComponentPropsWithRef<typeof IconButton>;
|
|
72
|
+
children?: ReactNode;
|
|
73
73
|
}
|
|
74
74
|
/**
|
|
75
75
|
* Generic error boundary which, by default, when an error occurs while
|
|
@@ -94,4 +94,4 @@ export interface ErrorBoundaryProps extends Pick<React.ComponentPropsWithoutRef<
|
|
|
94
94
|
* }
|
|
95
95
|
* ```
|
|
96
96
|
*/
|
|
97
|
-
export declare const ErrorBoundary:
|
|
97
|
+
export declare const ErrorBoundary: import("react").ForwardRefExoticComponent<ErrorBoundaryProps & import("react").RefAttributes<ReactErrorBoundary>>;
|