@bixlab/mtone 0.11.1 → 0.13.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.
- package/dist/index.d.ts +175 -99
- package/dist/index.js +5006 -4590
- package/dist/styles.css +1 -1
- package/llms.txt +144 -65
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -7,6 +7,7 @@ import * as _rc_component_table_es_Footer_Row from '@rc-component/table/es/Foote
|
|
|
7
7
|
import * as _rc_component_table_es_Footer_Summary from '@rc-component/table/es/Footer/Summary';
|
|
8
8
|
import { TableProps as TableProps$1, ColumnType, ExpandableConfig, Reference } from '@rc-component/table';
|
|
9
9
|
import { ToastManagerAddOptions, ToastManagerUpdateOptions, ToastObject } from '@base-ui/react/toast';
|
|
10
|
+
import { Tooltip as Tooltip$1 } from '@base-ui/react/tooltip';
|
|
10
11
|
|
|
11
12
|
interface InputOTPProps extends Omit<React.HTMLAttributes<HTMLDivElement>, "onChange" | "defaultValue"> {
|
|
12
13
|
/** Number of cells, clamped to 1–32. */
|
|
@@ -367,19 +368,12 @@ interface SelectTagsProps extends Omit<SelectMultipleProps, "mode"> {
|
|
|
367
368
|
mode: "tags";
|
|
368
369
|
}
|
|
369
370
|
type SelectProps = SelectSingleProps | SelectPopupSearchProps | SelectMultipleProps | SelectTagsProps;
|
|
370
|
-
/** @deprecated Use SelectMultipleProps and Select with mode="multiple". */
|
|
371
|
-
type MultiSelectProps = Omit<SelectMultipleProps, "mode">;
|
|
372
371
|
declare function Select(props: SelectProps): React__default.JSX.Element;
|
|
373
372
|
declare namespace Select {
|
|
374
373
|
var formValueType: (props: {
|
|
375
374
|
mode?: unknown;
|
|
376
375
|
}) => "array" | "select-single";
|
|
377
376
|
}
|
|
378
|
-
/** @deprecated Use <Select mode="multiple" />. */
|
|
379
|
-
declare function MultiSelect(props: MultiSelectProps): React__default.JSX.Element;
|
|
380
|
-
declare namespace MultiSelect {
|
|
381
|
-
var formValueType: "array";
|
|
382
|
-
}
|
|
383
377
|
|
|
384
378
|
declare const accentNames: readonly ["neutral", "blue", "green", "orange", "red", "purple", "teal", "coral"];
|
|
385
379
|
/** Shared theme accent keys, backed by the matching --mt-accent-* properties. */
|
|
@@ -427,6 +421,42 @@ interface TabsProps extends Omit<React__default.HTMLAttributes<HTMLDivElement>,
|
|
|
427
421
|
}
|
|
428
422
|
declare const Tabs: React__default.ForwardRefExoticComponent<TabsProps & React__default.RefAttributes<HTMLDivElement>>;
|
|
429
423
|
|
|
424
|
+
interface TooltipProviderProps {
|
|
425
|
+
children?: React.ReactNode;
|
|
426
|
+
delay?: number;
|
|
427
|
+
closeDelay?: number;
|
|
428
|
+
timeout?: number;
|
|
429
|
+
}
|
|
430
|
+
type TooltipTrigger = "hover" | "focus" | "click" | "contextMenu";
|
|
431
|
+
type TooltipPart = "trigger" | "positioner" | "popup" | "arrow";
|
|
432
|
+
interface TooltipProps extends OpenProps {
|
|
433
|
+
children: React.ReactElement;
|
|
434
|
+
content: React.ReactNode;
|
|
435
|
+
side?: "top" | "bottom" | "left" | "right";
|
|
436
|
+
align?: "start" | "center" | "end";
|
|
437
|
+
trigger?: TooltipTrigger;
|
|
438
|
+
delay?: number;
|
|
439
|
+
closeDelay?: number;
|
|
440
|
+
offset?: number;
|
|
441
|
+
alignOffset?: number;
|
|
442
|
+
avoidCollisions?: boolean;
|
|
443
|
+
shift?: boolean;
|
|
444
|
+
arrow?: boolean;
|
|
445
|
+
arrowPadding?: number;
|
|
446
|
+
disabled?: boolean;
|
|
447
|
+
keepMounted?: boolean;
|
|
448
|
+
container?: Tooltip$1.Portal.Props["container"];
|
|
449
|
+
zIndex?: number;
|
|
450
|
+
tone?: "default" | MtoneAccent;
|
|
451
|
+
classNames?: Partial<Record<TooltipPart, string>>;
|
|
452
|
+
styles?: Partial<Record<TooltipPart, React.CSSProperties>>;
|
|
453
|
+
/** Enables a focusable wrapper for a child explicitly passed disabled. */
|
|
454
|
+
wrapDisabledTrigger?: boolean;
|
|
455
|
+
}
|
|
456
|
+
/** Shares the hover delays and adjacent transition behavior of Base UI Tooltip. */
|
|
457
|
+
declare function TooltipProvider({ children, delay, closeDelay, timeout }: TooltipProviderProps): React.JSX.Element;
|
|
458
|
+
declare function Tooltip(props: TooltipProps): React.JSX.Element;
|
|
459
|
+
|
|
430
460
|
type ToastPosition = "top-right" | "bottom-right" | "top-left" | "bottom-left" | "top-center" | "bottom-center" | "center" | "center-top";
|
|
431
461
|
type ToastType = "success" | "error" | "info" | "loading";
|
|
432
462
|
type Presentation = {
|
|
@@ -612,9 +642,7 @@ declare function PopoverRoot(props: PopoverProps): React__default.JSX.Element;
|
|
|
612
642
|
declare const Popover: typeof PopoverRoot & {
|
|
613
643
|
Menu: typeof PopoverMenu;
|
|
614
644
|
};
|
|
615
|
-
|
|
616
|
-
children: React__default.ReactElement;
|
|
617
|
-
}): React__default.JSX.Element;
|
|
645
|
+
|
|
618
646
|
interface DialogFrameProps extends OpenProps {
|
|
619
647
|
title: React__default.ReactNode;
|
|
620
648
|
description?: React__default.ReactNode;
|
|
@@ -981,11 +1009,22 @@ interface BreadcrumbProps extends Omit<React.HTMLAttributes<HTMLElement>, "child
|
|
|
981
1009
|
}
|
|
982
1010
|
declare function Breadcrumb({ items, separator, "aria-label": label, ...props }: BreadcrumbProps): React.JSX.Element;
|
|
983
1011
|
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
1012
|
+
interface TableProps extends React.ComponentPropsWithoutRef<"table"> {
|
|
1013
|
+
/** Adds an outer border and vertical cell dividers. */
|
|
1014
|
+
bordered?: boolean;
|
|
1015
|
+
/** Adds a subtle alternating background to body rows. */
|
|
1016
|
+
striped?: boolean;
|
|
1017
|
+
/** Highlights body rows under the pointer. */
|
|
1018
|
+
highlightOnHover?: boolean;
|
|
1019
|
+
}
|
|
1020
|
+
/** A styled native table. Supply the caption, sections, rows and cells as children. */
|
|
1021
|
+
declare const Table: React.ForwardRefExoticComponent<TableProps & React.RefAttributes<HTMLTableElement>>;
|
|
1022
|
+
|
|
1023
|
+
type DataTableRef = Reference;
|
|
1024
|
+
type DataTableSortOrder = "ascend" | "descend" | null;
|
|
1025
|
+
type DataTableFilterValue = React.Key | boolean;
|
|
1026
|
+
type DataTableFilters = Record<string, DataTableFilterValue[] | null>;
|
|
1027
|
+
type DataTableState = {
|
|
989
1028
|
sort?: {
|
|
990
1029
|
key: string;
|
|
991
1030
|
direction: "asc" | "desc";
|
|
@@ -994,15 +1033,15 @@ type TableState = {
|
|
|
994
1033
|
page: number;
|
|
995
1034
|
pageSize: number;
|
|
996
1035
|
};
|
|
997
|
-
type
|
|
1036
|
+
type DataTableFilterItem = {
|
|
998
1037
|
text: React.ReactNode;
|
|
999
|
-
value:
|
|
1000
|
-
children?:
|
|
1038
|
+
value: DataTableFilterValue;
|
|
1039
|
+
children?: DataTableFilterItem[];
|
|
1001
1040
|
};
|
|
1002
|
-
type
|
|
1041
|
+
type DataTableFilterDropdownProps = {
|
|
1003
1042
|
prefixCls: string;
|
|
1004
|
-
selectedKeys:
|
|
1005
|
-
setSelectedKeys: (keys:
|
|
1043
|
+
selectedKeys: DataTableFilterValue[];
|
|
1044
|
+
setSelectedKeys: (keys: DataTableFilterValue[]) => void;
|
|
1006
1045
|
confirm: (options?: {
|
|
1007
1046
|
closeDropdown?: boolean;
|
|
1008
1047
|
}) => void;
|
|
@@ -1011,52 +1050,52 @@ type TableFilterDropdownProps = {
|
|
|
1011
1050
|
closeDropdown?: boolean;
|
|
1012
1051
|
}) => void;
|
|
1013
1052
|
close: () => void;
|
|
1014
|
-
filters?:
|
|
1053
|
+
filters?: DataTableFilterItem[];
|
|
1015
1054
|
visible: boolean;
|
|
1016
1055
|
};
|
|
1017
|
-
type
|
|
1018
|
-
column?:
|
|
1019
|
-
order?:
|
|
1020
|
-
field?:
|
|
1056
|
+
type DataTableSortResult<T> = {
|
|
1057
|
+
column?: DataTableColumn<T>;
|
|
1058
|
+
order?: DataTableSortOrder;
|
|
1059
|
+
field?: DataTableColumn<T>["dataIndex"];
|
|
1021
1060
|
columnKey?: React.Key;
|
|
1022
1061
|
};
|
|
1023
|
-
type
|
|
1062
|
+
type DataTableColumnTitleProps<T> = {
|
|
1024
1063
|
sortColumns: {
|
|
1025
|
-
column:
|
|
1026
|
-
order:
|
|
1064
|
+
column: DataTableColumn<T>;
|
|
1065
|
+
order: DataTableSortOrder;
|
|
1027
1066
|
}[];
|
|
1028
|
-
filters:
|
|
1067
|
+
filters: DataTableFilters;
|
|
1029
1068
|
};
|
|
1030
|
-
type
|
|
1069
|
+
type DataTableColumn<T> = Omit<ColumnType<T>, "title" | "dataIndex"> & {
|
|
1031
1070
|
dataIndex?: keyof T | string | number | (string | number)[];
|
|
1032
|
-
title?: React.ReactNode | ((props:
|
|
1033
|
-
children?:
|
|
1071
|
+
title?: React.ReactNode | ((props: DataTableColumnTitleProps<T>) => React.ReactNode);
|
|
1072
|
+
children?: DataTableColumn<T>[];
|
|
1034
1073
|
sortable?: boolean;
|
|
1035
1074
|
filterable?: boolean;
|
|
1036
|
-
sorter?: boolean | ((a: T, b: T, order?:
|
|
1037
|
-
compare?: (a: T, b: T, order?:
|
|
1075
|
+
sorter?: boolean | ((a: T, b: T, order?: DataTableSortOrder) => number) | {
|
|
1076
|
+
compare?: (a: T, b: T, order?: DataTableSortOrder) => number;
|
|
1038
1077
|
multiple?: number;
|
|
1039
1078
|
};
|
|
1040
|
-
sortOrder?:
|
|
1041
|
-
defaultSortOrder?:
|
|
1042
|
-
sortDirections?: Exclude<
|
|
1079
|
+
sortOrder?: DataTableSortOrder;
|
|
1080
|
+
defaultSortOrder?: DataTableSortOrder;
|
|
1081
|
+
sortDirections?: Exclude<DataTableSortOrder, null>[];
|
|
1043
1082
|
sortIcon?: (props: {
|
|
1044
|
-
sortOrder:
|
|
1083
|
+
sortOrder: DataTableSortOrder;
|
|
1045
1084
|
}) => React.ReactNode;
|
|
1046
1085
|
showSorterTooltip?: boolean | {
|
|
1047
1086
|
title?: React.ReactNode;
|
|
1048
1087
|
target?: "full-header" | "sorter-icon";
|
|
1049
1088
|
};
|
|
1050
|
-
filters?:
|
|
1051
|
-
filteredValue?:
|
|
1052
|
-
defaultFilteredValue?:
|
|
1089
|
+
filters?: DataTableFilterItem[];
|
|
1090
|
+
filteredValue?: DataTableFilterValue[] | null;
|
|
1091
|
+
defaultFilteredValue?: DataTableFilterValue[] | null;
|
|
1053
1092
|
filtered?: boolean;
|
|
1054
1093
|
filterMultiple?: boolean;
|
|
1055
1094
|
filterMode?: "menu" | "tree";
|
|
1056
|
-
filterSearch?: boolean | ((input: string, item:
|
|
1095
|
+
filterSearch?: boolean | ((input: string, item: DataTableFilterItem) => boolean);
|
|
1057
1096
|
filterResetToDefaultFilteredValue?: boolean;
|
|
1058
1097
|
filterOnClose?: boolean;
|
|
1059
|
-
filterDropdown?: React.ReactNode | ((props:
|
|
1098
|
+
filterDropdown?: React.ReactNode | ((props: DataTableFilterDropdownProps) => React.ReactNode);
|
|
1060
1099
|
filterIcon?: React.ReactNode | ((filtered: boolean) => React.ReactNode);
|
|
1061
1100
|
filterDropdownProps?: {
|
|
1062
1101
|
open?: boolean;
|
|
@@ -1064,17 +1103,17 @@ type TableColumn<T> = Omit<ColumnType<T>, "title" | "dataIndex"> & {
|
|
|
1064
1103
|
className?: string;
|
|
1065
1104
|
style?: React.CSSProperties;
|
|
1066
1105
|
};
|
|
1067
|
-
onFilter?: (value:
|
|
1106
|
+
onFilter?: (value: DataTableFilterValue, record: T) => boolean;
|
|
1068
1107
|
responsive?: ("xs" | "sm" | "md" | "lg" | "xl" | "xxl")[];
|
|
1069
1108
|
};
|
|
1070
|
-
type
|
|
1071
|
-
type
|
|
1072
|
-
type
|
|
1109
|
+
type DataTableColumnsType<T> = DataTableColumn<T>[];
|
|
1110
|
+
type DataTableSelectionType = "all" | "none" | "invert" | "single" | "multiple";
|
|
1111
|
+
type DataTableRowSelection<T> = {
|
|
1073
1112
|
type?: "checkbox" | "radio";
|
|
1074
1113
|
selectedRowKeys?: React.Key[];
|
|
1075
1114
|
defaultSelectedRowKeys?: React.Key[];
|
|
1076
1115
|
onChange?: (keys: React.Key[], rows: T[], info: {
|
|
1077
|
-
type:
|
|
1116
|
+
type: DataTableSelectionType;
|
|
1078
1117
|
}) => void;
|
|
1079
1118
|
onSelect?: (record: T, selected: boolean, rows: T[], event: Event) => void;
|
|
1080
1119
|
onSelectAll?: (selected: boolean, rows: T[], changeRows: T[]) => void;
|
|
@@ -1098,7 +1137,7 @@ type TableRowSelection<T> = {
|
|
|
1098
1137
|
onSelect: (keys: React.Key[]) => void;
|
|
1099
1138
|
})[];
|
|
1100
1139
|
};
|
|
1101
|
-
type
|
|
1140
|
+
type DataTablePagination = {
|
|
1102
1141
|
page?: number;
|
|
1103
1142
|
current?: number;
|
|
1104
1143
|
defaultCurrent?: number;
|
|
@@ -1121,7 +1160,7 @@ type TablePagination = {
|
|
|
1121
1160
|
className?: string;
|
|
1122
1161
|
style?: React.CSSProperties;
|
|
1123
1162
|
};
|
|
1124
|
-
type
|
|
1163
|
+
type DataTableLocale = {
|
|
1125
1164
|
emptyText?: React.ReactNode;
|
|
1126
1165
|
filterTitle?: string;
|
|
1127
1166
|
filterConfirm?: string;
|
|
@@ -1143,20 +1182,20 @@ type TableLocale = {
|
|
|
1143
1182
|
};
|
|
1144
1183
|
type RcSemantics = NonNullable<TableProps$1["classNames"]>;
|
|
1145
1184
|
type RcStyles = NonNullable<TableProps$1["styles"]>;
|
|
1146
|
-
type
|
|
1185
|
+
type DataTableClassNames = RcSemantics & {
|
|
1147
1186
|
root?: string;
|
|
1148
1187
|
pagination?: string;
|
|
1149
1188
|
};
|
|
1150
|
-
type
|
|
1189
|
+
type DataTableStyles = RcStyles & {
|
|
1151
1190
|
root?: React.CSSProperties;
|
|
1152
1191
|
pagination?: React.CSSProperties;
|
|
1153
1192
|
};
|
|
1154
|
-
type
|
|
1193
|
+
type DataTableProps<T> = Omit<TableProps$1<T>, "data" | "columns" | "children" | "onChange" | "scroll" | "classNames" | "styles" | "emptyText"> & {
|
|
1155
1194
|
data?: T[];
|
|
1156
1195
|
dataSource?: T[];
|
|
1157
|
-
columns?:
|
|
1196
|
+
columns?: DataTableColumn<T>[];
|
|
1158
1197
|
children?: React.ReactNode;
|
|
1159
|
-
column?: Partial<
|
|
1198
|
+
column?: Partial<DataTableColumn<T>>;
|
|
1160
1199
|
manual?: boolean;
|
|
1161
1200
|
loading?: boolean | {
|
|
1162
1201
|
spinning?: boolean;
|
|
@@ -1164,58 +1203,40 @@ type TableProps<T> = Omit<TableProps$1<T>, "data" | "columns" | "children" | "on
|
|
|
1164
1203
|
delay?: number;
|
|
1165
1204
|
indicator?: React.ReactNode;
|
|
1166
1205
|
};
|
|
1167
|
-
onChange?: (state:
|
|
1168
|
-
onTableChange?: (pagination:
|
|
1206
|
+
onChange?: (state: DataTableState) => void;
|
|
1207
|
+
onTableChange?: (pagination: DataTablePagination, filters: DataTableFilters, sorter: DataTableSortResult<T> | DataTableSortResult<T>[], extra: {
|
|
1169
1208
|
currentDataSource: T[];
|
|
1170
1209
|
action: "paginate" | "sort" | "filter";
|
|
1171
1210
|
}) => void;
|
|
1172
|
-
sort?:
|
|
1211
|
+
sort?: DataTableState["sort"];
|
|
1173
1212
|
filters?: Record<string, string>;
|
|
1174
1213
|
selectable?: boolean;
|
|
1175
1214
|
selectedKeys?: React.Key[];
|
|
1176
1215
|
onSelectionChange?: (keys: React.Key[]) => void;
|
|
1177
|
-
rowSelection?:
|
|
1178
|
-
pagination?: false |
|
|
1216
|
+
rowSelection?: DataTableRowSelection<T>;
|
|
1217
|
+
pagination?: false | DataTablePagination;
|
|
1218
|
+
/** Toolbar inside the table frame, before top pagination and rows. */
|
|
1219
|
+
toolbar?: React.ReactNode;
|
|
1179
1220
|
empty?: React.ReactNode;
|
|
1180
|
-
locale?:
|
|
1221
|
+
locale?: DataTableLocale;
|
|
1181
1222
|
size?: "small" | "middle" | "medium" | "large";
|
|
1182
1223
|
bordered?: boolean;
|
|
1183
|
-
sortDirections?: Exclude<
|
|
1184
|
-
showSorterTooltip?:
|
|
1224
|
+
sortDirections?: Exclude<DataTableSortOrder, null>[];
|
|
1225
|
+
showSorterTooltip?: DataTableColumn<T>["showSorterTooltip"];
|
|
1185
1226
|
getPopupContainer?: (trigger: HTMLElement) => HTMLElement;
|
|
1186
1227
|
scroll?: NonNullable<TableProps$1<T>["scroll"]> & {
|
|
1187
1228
|
scrollToFirstRowOnChange?: boolean;
|
|
1188
1229
|
};
|
|
1189
1230
|
virtual?: boolean;
|
|
1190
1231
|
virtualItemHeight?: number;
|
|
1191
|
-
classNames?:
|
|
1192
|
-
props:
|
|
1193
|
-
}) =>
|
|
1194
|
-
styles?:
|
|
1195
|
-
props:
|
|
1196
|
-
}) =>
|
|
1197
|
-
};
|
|
1198
|
-
type
|
|
1199
|
-
|
|
1200
|
-
declare function Column<T>(_props: TableColumn<T>): null;
|
|
1201
|
-
declare function ColumnGroup<T>(_props: Omit<TableColumn<T>, "children"> & {
|
|
1202
|
-
children: React.ReactNode;
|
|
1203
|
-
}): null;
|
|
1204
|
-
declare const Table: (<T>(props: TableProps<T> & React.RefAttributes<Reference>) => React.ReactElement) & {
|
|
1205
|
-
Column: typeof Column;
|
|
1206
|
-
ColumnGroup: typeof ColumnGroup;
|
|
1207
|
-
Summary: React.FC<React.PropsWithChildren<_rc_component_table_es_Footer_Summary.SummaryProps>> & {
|
|
1208
|
-
Row: React.FC<React.PropsWithChildren<_rc_component_table_es_Footer_Row.FooterRowProps>>;
|
|
1209
|
-
Cell: React.FC<React.PropsWithChildren<_rc_component_table_es_Footer_Cell.SummaryCellProps>>;
|
|
1210
|
-
};
|
|
1211
|
-
EXPAND_COLUMN: {};
|
|
1212
|
-
SELECTION_COLUMN: Readonly<{
|
|
1213
|
-
key: "__mt_selection_column";
|
|
1214
|
-
}>;
|
|
1215
|
-
SELECTION_ALL: "all";
|
|
1216
|
-
SELECTION_INVERT: "invert";
|
|
1217
|
-
SELECTION_NONE: "none";
|
|
1218
|
-
};
|
|
1232
|
+
classNames?: DataTableClassNames | ((info: {
|
|
1233
|
+
props: DataTableProps<T>;
|
|
1234
|
+
}) => DataTableClassNames);
|
|
1235
|
+
styles?: DataTableStyles | ((info: {
|
|
1236
|
+
props: DataTableProps<T>;
|
|
1237
|
+
}) => DataTableStyles);
|
|
1238
|
+
};
|
|
1239
|
+
type DataTableExpandableConfig<T> = ExpandableConfig<T>;
|
|
1219
1240
|
|
|
1220
1241
|
type TreeKey = string | number;
|
|
1221
1242
|
/** Legacy items retain id/label; normalized treeData uses the same shape. */
|
|
@@ -1581,6 +1602,26 @@ declare const Splitter: typeof SplitterRoot & {
|
|
|
1581
1602
|
Panel: typeof SplitterPanel;
|
|
1582
1603
|
};
|
|
1583
1604
|
|
|
1605
|
+
declare function Column<T>(_props: DataTableColumn<T>): null;
|
|
1606
|
+
declare function ColumnGroup<T>(_props: Omit<DataTableColumn<T>, "children"> & {
|
|
1607
|
+
children: React.ReactNode;
|
|
1608
|
+
}): null;
|
|
1609
|
+
declare const DataTable: (<T>(props: DataTableProps<T> & React.RefAttributes<Reference>) => React.ReactElement) & {
|
|
1610
|
+
Column: typeof Column;
|
|
1611
|
+
ColumnGroup: typeof ColumnGroup;
|
|
1612
|
+
Summary: React.FC<React.PropsWithChildren<_rc_component_table_es_Footer_Summary.SummaryProps>> & {
|
|
1613
|
+
Row: React.FC<React.PropsWithChildren<_rc_component_table_es_Footer_Row.FooterRowProps>>;
|
|
1614
|
+
Cell: React.FC<React.PropsWithChildren<_rc_component_table_es_Footer_Cell.SummaryCellProps>>;
|
|
1615
|
+
};
|
|
1616
|
+
EXPAND_COLUMN: {};
|
|
1617
|
+
SELECTION_COLUMN: Readonly<{
|
|
1618
|
+
key: "__mt_selection_column";
|
|
1619
|
+
}>;
|
|
1620
|
+
SELECTION_ALL: "all";
|
|
1621
|
+
SELECTION_INVERT: "invert";
|
|
1622
|
+
SELECTION_NONE: "none";
|
|
1623
|
+
};
|
|
1624
|
+
|
|
1584
1625
|
/** Extract boundary-delimited mentions from plain text; does not validate membership in options. */
|
|
1585
1626
|
declare function getMentions(value: string, config?: {
|
|
1586
1627
|
prefix?: string | string[];
|
|
@@ -2231,8 +2272,6 @@ interface DataListSearch<T> {
|
|
|
2231
2272
|
value?: string;
|
|
2232
2273
|
defaultValue?: string;
|
|
2233
2274
|
onChange?: (value: string) => void;
|
|
2234
|
-
placeholder?: string;
|
|
2235
|
-
label?: string;
|
|
2236
2275
|
/** Client-side matcher. Remote lists ignore it. */
|
|
2237
2276
|
match?: (item: T, query: string) => boolean;
|
|
2238
2277
|
}
|
|
@@ -2268,6 +2307,13 @@ interface DataListBatchContext {
|
|
|
2268
2307
|
selectedKeys: readonly DataListKey[];
|
|
2269
2308
|
clearSelection: () => void;
|
|
2270
2309
|
}
|
|
2310
|
+
interface DataListSearchProps {
|
|
2311
|
+
label?: string;
|
|
2312
|
+
placeholder?: string;
|
|
2313
|
+
}
|
|
2314
|
+
interface DataListSelectionProps {
|
|
2315
|
+
children?: (context: DataListBatchContext) => React.ReactNode;
|
|
2316
|
+
}
|
|
2271
2317
|
interface DataListProps<T> extends Omit<React.HTMLAttributes<HTMLElement>, "children"> {
|
|
2272
2318
|
items: readonly T[];
|
|
2273
2319
|
/** Unique stable string or finite number. */
|
|
@@ -2279,17 +2325,22 @@ interface DataListProps<T> extends Omit<React.HTMLAttributes<HTMLElement>, "chil
|
|
|
2279
2325
|
search?: DataListSearch<T>;
|
|
2280
2326
|
/** Client-side predicate. Remote lists ignore it. */
|
|
2281
2327
|
filter?: (item: T) => boolean;
|
|
2282
|
-
|
|
2328
|
+
/** Explicit top slot. Compose a Toolbar and connected controls if needed. */
|
|
2283
2329
|
toolbar?: React.ReactNode;
|
|
2284
2330
|
pagination?: DataListPagination;
|
|
2285
2331
|
selection?: DataListSelection<T>;
|
|
2286
2332
|
expansion?: DataListExpansion<T>;
|
|
2287
2333
|
renderActions?: (item: T) => React.ReactNode;
|
|
2288
|
-
renderBatchActions?: (context: DataListBatchContext) => React.ReactNode;
|
|
2289
2334
|
loading?: boolean;
|
|
2290
2335
|
empty?: React.ReactNode;
|
|
2291
2336
|
}
|
|
2292
|
-
declare function
|
|
2337
|
+
declare function DataListSearchField({ label, placeholder }: DataListSearchProps): React.JSX.Element | null;
|
|
2338
|
+
declare function DataListSelectionControl({ children }: DataListSelectionProps): React.JSX.Element | null;
|
|
2339
|
+
declare function DataListRoot<T>({ items, getKey, getLabel, renderItem, search, filter, toolbar, pagination, selection, expansion, renderActions, loading, empty, className, ...props }: DataListProps<T>): React.JSX.Element;
|
|
2340
|
+
declare const DataList: typeof DataListRoot & {
|
|
2341
|
+
Search: typeof DataListSearchField;
|
|
2342
|
+
Selection: typeof DataListSelectionControl;
|
|
2343
|
+
};
|
|
2293
2344
|
|
|
2294
2345
|
type CardGroupBreakpoint = "xs" | "sm" | "md" | "lg" | "xl" | "xxl";
|
|
2295
2346
|
type CardGroupResponsive = number | Partial<Record<CardGroupBreakpoint, number>>;
|
|
@@ -2626,8 +2677,10 @@ interface ToolbarProps extends Omit<React.ComponentPropsWithoutRef<"div">, "chil
|
|
|
2626
2677
|
start?: React.ReactNode;
|
|
2627
2678
|
/** Controls aligned at the logical end. */
|
|
2628
2679
|
end?: React.ReactNode;
|
|
2629
|
-
/** Surface color resolved from the active mtone theme. */
|
|
2680
|
+
/** Surface color resolved from the active mtone theme; defaults to gray. */
|
|
2630
2681
|
background?: "white" | "gray";
|
|
2682
|
+
/** Gray surfaces default to borderless Button and Select chrome; white stays standard. */
|
|
2683
|
+
controlStyle?: "default" | "borderless";
|
|
2631
2684
|
}
|
|
2632
2685
|
/** Standalone presentation for search, filters and actions. */
|
|
2633
2686
|
declare const Toolbar: React.ForwardRefExoticComponent<ToolbarProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -2661,4 +2714,27 @@ interface FloatingWindowProps {
|
|
|
2661
2714
|
}
|
|
2662
2715
|
declare function FloatingWindow({ title, children, trigger, open: controlledOpen, defaultOpen, onOpenChange, initialPosition, initialSize, minWidth, minHeight, maxWidth, maxHeight, draggable, resizable, minimizable, minimizedIcon, zIndex, }: FloatingWindowProps): React.JSX.Element;
|
|
2663
2716
|
|
|
2664
|
-
|
|
2717
|
+
interface ShortcutOptions {
|
|
2718
|
+
enabled?: boolean;
|
|
2719
|
+
allowInInputs?: boolean;
|
|
2720
|
+
preventDefault?: boolean;
|
|
2721
|
+
}
|
|
2722
|
+
interface ShortcutsProviderProps {
|
|
2723
|
+
children?: React.ReactNode;
|
|
2724
|
+
}
|
|
2725
|
+
interface ShortcutScopeProps extends ShortcutsProviderProps {
|
|
2726
|
+
active?: boolean;
|
|
2727
|
+
priority?: number;
|
|
2728
|
+
}
|
|
2729
|
+
type Platform = "mac" | "other";
|
|
2730
|
+
type Shortcut = string | readonly string[] | false;
|
|
2731
|
+
type Callback = (event: KeyboardEvent) => void;
|
|
2732
|
+
declare function formatShortcut(shortcut: string, platform?: Platform): string;
|
|
2733
|
+
/** One document listener per root provider; nested providers reuse that root. */
|
|
2734
|
+
declare function ShortcutsProvider({ children }: ShortcutsProviderProps): React.JSX.Element;
|
|
2735
|
+
/** Activates or suspends shortcut registrations for the React subtree (including its portals). */
|
|
2736
|
+
declare function ShortcutScope({ children, active, priority }: ShortcutScopeProps): React.JSX.Element;
|
|
2737
|
+
/** Registers one exact chord or alternatives in the nearest active shortcut scope. */
|
|
2738
|
+
declare function useShortcut(shortcut: Shortcut, callback: Callback, options?: ShortcutOptions): void;
|
|
2739
|
+
|
|
2740
|
+
export { AdminLayout, type AdminLayoutContentProps, type AdminLayoutHeaderProps, type AdminLayoutProps, type AdminLayoutSiderProps, Affix, type AffixProps, type AiActivityProps, type AiActivityStatus, type AiActivityStep, AiChat, type AiChatProps, AiCheckpoint, type AiCheckpointProps, AiConfirmation, type AiConfirmationProps, AiContext, type AiContextProps, type AiEvidenceAppearance, type AiFileNode, AiFileTree, type AiFileTreeProps, AiInlineCitation, type AiInlineCitationProps, AiMessage, type AiMessageProps, type AiModelOption, AiModelSelector, type AiModelSelectorProps, AiPlan, type AiPlanProps, type AiPromptAttachment, AiPromptInput, type AiPromptInputProps, type AiPromptStatus, type AiPromptSubmission, AiQueue, type AiQueueProps, AiReasoning, type AiReasoningProps, type AiSource, AiSources, type AiSourcesProps, type AiStackFrame, AiStackTrace, type AiStackTraceProps, AiSubagent, type AiSubagentProps, AiSuggestion, type AiSuggestionProps, AiTask, type AiTaskProps, AiTerminal, type AiTerminalProps, type AiTerminalStatus, type AiTestResult, AiTestResults, type AiTestResultsProps, type AiTestStatus, AiTool, type AiToolProps, Alert, AutoComplete, type AutoCompleteGroup, type AutoCompleteOption, type AutoCompleteProps, Avatar, type AvatarBreakpoint, AvatarGroup, type AvatarGroupProps, type AvatarProps, type AvatarSize, Blockquote, type BlockquoteProps, Breadcrumb, type BreadcrumbItem, type BreadcrumbProps, Button, ButtonGroup, type ButtonGroupProps, type ButtonProps, type ButtonSize, type ButtonToggleOptions, Calendar, type CalendarCellInfo, type CalendarHeaderInfo, type CalendarMode, type CalendarProps, type CalendarSelectInfo, type CalendarSemanticSlot, Card, type CardGridProps, CardGroup, type CardGroupBreakpoint, type CardGroupItemProps, type CardGroupProps, type CardGroupResponsive, type CardMetaProps, type CardMetaSemantic, type CardProps, type CardSemantic, type CardTabItem, type CardTokens, Cascader, type CascaderKey, type CascaderOption, CascaderPanel, type CascaderPanelProps, type CascaderPath, type CascaderProps, CheckCard, type CheckCardGroupProps, type CheckCardOption, type CheckCardProps, type CheckCardSize, Checkbox, type CheckboxProps, ConfirmDialog, type ConfirmDialogProps, ContextMenu, DataList, type DataListBatchContext, type DataListExpansion, type DataListKey, type DataListLocalPagination, type DataListPagination, type DataListProps, type DataListRemotePagination, type DataListSearch, type DataListSearchProps, type DataListSelection, type DataListSelectionProps, DataTable, type DataTableClassNames, type DataTableColumn, type DataTableColumnTitleProps, type DataTableColumnsType, type DataTableExpandableConfig, type DataTableFilterDropdownProps, type DataTableFilterItem, type DataTableFilterValue, type DataTableFilters, type DataTableLocale, type DataTablePagination, type DataTableProps, type DataTableRef, type DataTableRowSelection, type DataTableSelectionType, type DataTableSortOrder, type DataTableSortResult, type DataTableState, type DataTableStyles, DatePicker, type DatePickerProps, Dialog, type DialogProps, Divider, type DividerProps, DocumentCard, type DocumentItem, DocumentList, Drawer, Empty, Fieldset, type FieldsetProps, FloatingWindow, type FloatingWindowProps, Form, type FormFieldProps, type FormInstance, type FormProps, type FormRule, type FormValidateTrigger, type FormValidationError, type FormValues, GlobalNotice, type GlobalNoticeProps, HoverCard, type HoverCardProps, Image, ImageGroup, type ImageGroupProps, type ImageItem, ImagePreview, type ImagePreviewProps, type ImageProps, Input, type InputControlSize, type InputOTPProps, type InputPasswordProps, type InputProps, type InputSearchProps, type InputTextAreaProps, type InputVariant, Link, type LinkProps, List, type ListHandle, ListItem, type ListItemProps, type ListProps, type ListScrollTarget, type ListSortHandleProps, LoadingOverlay, type LoadingOverlayProps, type Locale, type MentionOption, Mentions, type MentionsProps, type MentionsRef, type MentionsSemantic, Menu, type MenuCheckboxItem, type MenuDivider, type MenuEntry, type MenuGroup, type MenuItem, type MenuProps, type MenuRadioGroup, Menubar, type MenubarMenu, type MenubarProps, type MtoneAccent, MtoneProvider, type MtoneProviderProps, MtoneScope, type MtoneScopeProps, type MtoneTheme, NavGroup, type NavGroupProps, NavItem, type NavItemAction, type NavItemButtonProps, type NavItemLinkProps, type NavItemProps, NavSubmenu, type NavSubmenuProps, NumberInput, type NumberInputProps, type OpenProps, type Option, PageLayout, type PageLayoutProps, Pagination, type PaginationProps, Paragraph, type ParagraphProps, Popconfirm, type PopconfirmPlacement, type PopconfirmProps, Popover, type PopoverMenuProps, type PopoverProps, Progress, type ProgressColor, type ProgressProps, type ProgressStatus, type ProgressType, PropertyItem, PropertyList, Questionnaire, type QuestionnaireAnswer, type QuestionnaireAnswers, type QuestionnaireChoice, type QuestionnaireItem, type QuestionnaireProps, RadioGroup, type RadioGroupProps, Rate, type RateCharacterInfo, type RateProps, Result, type ResultProps, type ResultSemantic, type ResultStatus, SectionGroup, type SectionGroupProps, type SectionGroupSectionProps, Select, type SelectMultipleProps, type SelectOption, type SelectOptionGroup, type SelectPopupSearchProps, type SelectProps, type SelectSingleProps, type SelectTagsProps, type ShortcutOptions, ShortcutScope, type ShortcutScopeProps, ShortcutsProvider, type ShortcutsProviderProps, Sidebar, type SidebarProps, type SidebarTabsOptions, Skeleton, Slider, type SliderProps, Spinner, Splitter, type SplitterPanelProps, type SplitterProps, type SplitterSize, Spotlight, type SpotlightAction, type SpotlightProps, Status, Switch, type TabItem, Table, TableOfContents, type TableOfContentsHandle, type TableOfContentsItem, type TableOfContentsProps, type TableProps, Tabs, type TabsIndicatorColor, type TabsProps, Tag, type TagProps, TagSelect, type TagSelectOption, type TagSelectProps, Text, type TextProps, Timeline, type TimelineItem, type TimelinePlacement, type TimelineProps, type TimelineSemantic, Title, type TitleProps, type ToastOptions, type ToastPosition, type ToastPromiseOptions, ToastProvider, type ToastProviderProps, type ToastType, type ToastUpdateOptions, type Tokens, type Tone, Toolbar, type ToolbarProps, Tooltip, type TooltipPart, type TooltipProps, TooltipProvider, type TooltipProviderProps, type TooltipTrigger, Transfer, type TransferDirection, type TransferItem, type TransferListContext, type TransferProps, Tree, type TreeCheckedKeys, type TreeDropInfo, type TreeItem, type TreeKey, type TreeNode, type TreeNodeInfo, type TreeProps, type TreeRef, TreeSelect, type TreeSelectCommonProps, type TreeSelectProps, Typography, type TypographyCodeProps, type TypographyCopyable, type TypographyEditable, type TypographyEllipsis, type TypographyTone, Upload, type UploadAdapter, type UploadContext, type UploadFile, type UploadProps, cn, formatShortcut, getMentions, useMtone, useShortcut, useToast };
|