@gomeniucivan/ui 1.0.43 → 1.0.45
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.mts +4236 -0
- package/dist/index.d.ts +4236 -0
- package/dist/index.js +6073 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +6073 -0
- package/dist/index.mjs.map +1 -0
- package/package.json +1 -1
package/dist/index.d.mts
ADDED
|
@@ -0,0 +1,4236 @@
|
|
|
1
|
+
import * as react from 'react';
|
|
2
|
+
import react__default, { AnchorHTMLAttributes, HTMLAttributes, FC, Ref, ElementType, CSSProperties, ReactNode, Key, ReactElement, ComponentPropsWithRef, RefAttributes, Context, MouseEvent, ComponentProps, ChangeEvent, FocusEvent, FormEvent, FormHTMLAttributes, KeyboardEvent, ComponentType } from 'react';
|
|
3
|
+
import { FlexProps as FlexProps$1, MenuProps as MenuProps$1, MenuRef, AlertProps as AlertProps$1, AutoCompleteProps as AutoCompleteProps$1, AvatarProps as AvatarProps$1, DrawerProps as DrawerProps$1, ButtonProps as ButtonProps$1, CollapseProps as CollapseProps$1, DatePickerProps as DatePickerProps$1, InputProps as InputProps$1, InputRef, InputNumberProps as InputNumberProps$1, SegmentedProps as SegmentedProps$1, ModalProps as ModalProps$1, ImageProps as ImageProps$2, SelectProps as SelectProps$1, TagProps as TagProps$1, TabsProps as TabsProps$1, AnchorProps, SliderSingleProps } from 'antd';
|
|
4
|
+
import { LucideProps, LucideIcon } from 'lucide-react';
|
|
5
|
+
import { TooltipPopupProps, TooltipPortalProps as TooltipPortalProps$1, TooltipPositionerProps as TooltipPositionerProps$1, Tooltip as Tooltip$1, TooltipTriggerProps } from '@base-ui/react/tooltip';
|
|
6
|
+
import { Placement as Placement$1 } from '@floating-ui/react';
|
|
7
|
+
import * as _base_ui_react_menu from '@base-ui/react/menu';
|
|
8
|
+
import { MenuRootProps, MenuPopupProps, MenuPortalProps, MenuPositionerProps, MenuTriggerProps, Menu as Menu$1 } from '@base-ui/react/menu';
|
|
9
|
+
import { MenuItemType as MenuItemType$1, SubMenuType as SubMenuType$1, MenuItemGroupType as MenuItemGroupType$1, MenuDividerType as MenuDividerType$1, MenuInfo } from 'rc-menu/es/interface';
|
|
10
|
+
export { MenuInfo } from 'rc-menu/es/interface';
|
|
11
|
+
import { AlertRef } from 'antd/lib/alert/Alert';
|
|
12
|
+
import { FileDiffOptions } from '@pierre/diffs';
|
|
13
|
+
import { ItemType as ItemType$1 } from 'rc-collapse/es/interface';
|
|
14
|
+
import * as motion_react from 'motion/react';
|
|
15
|
+
import { HTMLMotionProps, Transition, TargetAndTransition } from 'motion/react';
|
|
16
|
+
import * as m from 'motion/react-m';
|
|
17
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
18
|
+
import { ConfigType } from 'dayjs';
|
|
19
|
+
import { OTPProps, OTPRef } from 'antd/es/input/OTP';
|
|
20
|
+
import { PasswordProps } from 'antd/es/input/Password';
|
|
21
|
+
import { TextAreaProps as TextAreaProps$2, TextAreaRef } from 'antd/es/input/TextArea';
|
|
22
|
+
import Inputmask from 'inputmask';
|
|
23
|
+
import { InputNumberRef } from 'rc-input-number';
|
|
24
|
+
import { Size, NumberSize } from 're-resizable';
|
|
25
|
+
import { Props as Props$1 } from 'react-rnd';
|
|
26
|
+
import { DropdownProps as DropdownProps$1 } from 'antd/es';
|
|
27
|
+
import * as _base_ui_react_autocomplete from '@base-ui/react/autocomplete';
|
|
28
|
+
import { Autocomplete, AutocompleteRootChangeEventDetails, AutocompleteRootProps } from '@base-ui/react/autocomplete';
|
|
29
|
+
import * as _base_ui_react_popover from '@base-ui/react/popover';
|
|
30
|
+
import { PopoverBackdropProps as PopoverBackdropProps$1, PopoverPopupProps as PopoverPopupProps$1, PopoverPortalProps as PopoverPortalProps$1, PopoverPositionerProps as PopoverPositionerProps$1, Popover as Popover$1, PopoverTriggerProps } from '@base-ui/react/popover';
|
|
31
|
+
import { FooterProps as FooterProps$1 } from 'rc-footer';
|
|
32
|
+
import { Switch as Switch$1 } from '@base-ui/react/switch';
|
|
33
|
+
import { BuiltinTheme } from 'shiki';
|
|
34
|
+
import { PreviewConfig } from 'antd/es/image';
|
|
35
|
+
import { GroupPreviewConfig } from 'antd/es/image/PreviewGroup';
|
|
36
|
+
import * as node_modules__base_ui_react_esm_separator_Separator from 'node_modules/@base-ui/react/esm/separator/Separator';
|
|
37
|
+
import * as _base_ui_react_select from '@base-ui/react/select';
|
|
38
|
+
import { Select as Select$1 } from '@base-ui/react/select';
|
|
39
|
+
import { Components, Options } from 'react-markdown';
|
|
40
|
+
import { Pluggable } from 'unified';
|
|
41
|
+
import { MermaidConfig } from 'mermaid';
|
|
42
|
+
import { Node } from 'unist';
|
|
43
|
+
import { Root } from 'hast';
|
|
44
|
+
import { ScrollArea as ScrollArea$1 } from '@base-ui/react/scroll-area';
|
|
45
|
+
import { TableProps as TableProps$1 } from 'antd/es/table';
|
|
46
|
+
import { GetCustomStylish, GetCustomToken, ThemeProviderProps as ThemeProviderProps$1, CustomStylishParams, CustomTokenParams, ThemeMode } from 'antd-style';
|
|
47
|
+
export { createStyles, cx, useAntdToken as useToken } from 'antd-style';
|
|
48
|
+
import { AliasToken } from 'antd/es/theme/interface';
|
|
49
|
+
import { Toast } from '@base-ui/react/toast';
|
|
50
|
+
export { ErrorBoundary, ErrorBoundaryProps } from 'react-error-boundary';
|
|
51
|
+
|
|
52
|
+
interface LobeCustomStylish {
|
|
53
|
+
active: string;
|
|
54
|
+
blur: string;
|
|
55
|
+
blurStrong: string;
|
|
56
|
+
bottomScrollbar: string;
|
|
57
|
+
disabled: string;
|
|
58
|
+
gradientAnimation: string;
|
|
59
|
+
noScrollbar: string;
|
|
60
|
+
resetLinkColor: string;
|
|
61
|
+
shadow: string;
|
|
62
|
+
variantBorderless: string;
|
|
63
|
+
variantBorderlessDanger: string;
|
|
64
|
+
variantBorderlessWithoutHover: string;
|
|
65
|
+
variantFilled: string;
|
|
66
|
+
variantFilledDanger: string;
|
|
67
|
+
variantFilledWithoutHover: string;
|
|
68
|
+
variantOutlined: string;
|
|
69
|
+
variantOutlinedDanger: string;
|
|
70
|
+
variantOutlinedWithoutHover: string;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
declare const PresetColors: readonly ["red", "volcano", "orange", "gold", "yellow", "lime", "green", "cyan", "blue", "geekblue", "purple", "magenta", "gray"];
|
|
74
|
+
declare const PresetSystemColors: readonly ["Error", "Warning", "Success", "Info"];
|
|
75
|
+
type PresetColorKey = (typeof PresetColors)[number];
|
|
76
|
+
type PresetSystemColorKey = (typeof PresetSystemColors)[number];
|
|
77
|
+
type PresetColorType = Record<PresetColorKey, string>;
|
|
78
|
+
type PresetSystemColorType = Record<PresetSystemColorKey, string>;
|
|
79
|
+
type ColorPaletteKeyIndex = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11;
|
|
80
|
+
type ColorTokenKey = 'Fill' | 'FillSecondary' | 'FillTertiary' | 'FillQuaternary' | 'Bg' | 'BgHover' | 'Border' | 'BorderSecondary' | 'BorderHover' | 'Hover' | '' | 'Active' | 'TextHover' | 'Text' | 'TextActive';
|
|
81
|
+
type SystemColorTokenKey = 'Fill' | 'FillSecondary' | 'FillTertiary' | 'FillQuaternary';
|
|
82
|
+
type ColorToken = {
|
|
83
|
+
[key in `${keyof PresetColorType}${ColorTokenKey}`]: string;
|
|
84
|
+
};
|
|
85
|
+
type SystemColorToken = {
|
|
86
|
+
[key in `color${keyof PresetSystemColorType}${SystemColorTokenKey}`]: string;
|
|
87
|
+
};
|
|
88
|
+
type ColorPalettes = {
|
|
89
|
+
[key in `${keyof PresetColorType}${ColorPaletteKeyIndex}`]: string;
|
|
90
|
+
};
|
|
91
|
+
type ColorPalettesAlpha = {
|
|
92
|
+
[key in `${keyof PresetColorType}${ColorPaletteKeyIndex}A`]: string;
|
|
93
|
+
};
|
|
94
|
+
interface LobeCustomToken extends ColorPalettes, ColorPalettesAlpha, ColorToken, SystemColorToken {
|
|
95
|
+
colorBgContainerSecondary: string;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
/**
|
|
99
|
+
* Common trigger type for components that support hover/click interactions
|
|
100
|
+
*/
|
|
101
|
+
type Trigger = 'hover' | 'click' | 'both' | ('hover' | 'click')[];
|
|
102
|
+
|
|
103
|
+
type DivProps = HTMLAttributes<HTMLDivElement>;
|
|
104
|
+
type VideoProps$2 = HTMLAttributes<HTMLVideoElement>;
|
|
105
|
+
type SvgProps = HTMLAttributes<SVGSVGElement>;
|
|
106
|
+
type ImgProps = HTMLAttributes<HTMLImageElement>;
|
|
107
|
+
type AProps = AnchorHTMLAttributes<HTMLAnchorElement>;
|
|
108
|
+
type TextAreaProps$1 = HTMLAttributes<HTMLTextAreaElement>;
|
|
109
|
+
type SpanProps = HTMLAttributes<HTMLSpanElement>;
|
|
110
|
+
|
|
111
|
+
declare const A: FC<AProps & {
|
|
112
|
+
ref?: Ref<HTMLAnchorElement>;
|
|
113
|
+
}>;
|
|
114
|
+
|
|
115
|
+
type FlexDirection = 'vertical' | 'vertical-reverse' | 'horizontal' | 'horizontal-reverse';
|
|
116
|
+
interface FlexProps extends FlexProps$1 {
|
|
117
|
+
as?: ElementType;
|
|
118
|
+
direction?: FlexDirection;
|
|
119
|
+
distribution?: CSSProperties['justifyContent'];
|
|
120
|
+
horizontal?: boolean;
|
|
121
|
+
vertical?: boolean;
|
|
122
|
+
padding?: number | string;
|
|
123
|
+
paddingBlock?: number | string;
|
|
124
|
+
paddingInline?: number | string;
|
|
125
|
+
width?: number | string;
|
|
126
|
+
height?: number | string;
|
|
127
|
+
allowShrink?: boolean;
|
|
128
|
+
visible?: boolean;
|
|
129
|
+
ref?: Ref<HTMLElement>;
|
|
130
|
+
}
|
|
131
|
+
declare const Flex: react.ForwardRefExoticComponent<Omit<FlexProps, "ref"> & react.RefAttributes<HTMLElement>>;
|
|
132
|
+
|
|
133
|
+
interface BlockProps extends FlexProps {
|
|
134
|
+
clickable?: boolean;
|
|
135
|
+
glass?: boolean;
|
|
136
|
+
ref?: Ref<HTMLDivElement>;
|
|
137
|
+
shadow?: boolean;
|
|
138
|
+
variant?: 'filled' | 'outlined' | 'borderless';
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
declare const Block: FC<BlockProps>;
|
|
142
|
+
|
|
143
|
+
interface AccordionItemProps extends Pick<BlockProps, 'padding' | 'paddingBlock' | 'paddingInline' | 'variant' | 'ref'> {
|
|
144
|
+
/**
|
|
145
|
+
* Action component that appears on hover
|
|
146
|
+
*/
|
|
147
|
+
action?: ReactNode;
|
|
148
|
+
/**
|
|
149
|
+
* Whether to allow expanding (hide indicator when false)
|
|
150
|
+
* @default true
|
|
151
|
+
*/
|
|
152
|
+
allowExpand?: boolean;
|
|
153
|
+
/**
|
|
154
|
+
* Content of the accordion item
|
|
155
|
+
*/
|
|
156
|
+
children?: ReactNode;
|
|
157
|
+
/**
|
|
158
|
+
* Custom classNames for child elements
|
|
159
|
+
*/
|
|
160
|
+
classNames?: {
|
|
161
|
+
action?: string;
|
|
162
|
+
base?: string;
|
|
163
|
+
content?: string;
|
|
164
|
+
header?: string;
|
|
165
|
+
indicator?: string;
|
|
166
|
+
title?: string;
|
|
167
|
+
};
|
|
168
|
+
/**
|
|
169
|
+
* Default expanded state (uncontrolled)
|
|
170
|
+
*/
|
|
171
|
+
defaultExpand?: boolean;
|
|
172
|
+
/**
|
|
173
|
+
* Whether the item is disabled
|
|
174
|
+
*/
|
|
175
|
+
disabled?: boolean;
|
|
176
|
+
/**
|
|
177
|
+
* Controlled expanded state
|
|
178
|
+
*/
|
|
179
|
+
expand?: boolean;
|
|
180
|
+
headerWrapper?: (header: ReactNode) => ReactNode;
|
|
181
|
+
/**
|
|
182
|
+
* Whether to hide the chevron indicator
|
|
183
|
+
* @default false
|
|
184
|
+
*/
|
|
185
|
+
hideIndicator?: boolean;
|
|
186
|
+
/**
|
|
187
|
+
* Custom indicator component or function
|
|
188
|
+
*/
|
|
189
|
+
indicator?: ReactNode | ((props: {
|
|
190
|
+
isDisabled?: boolean;
|
|
191
|
+
isOpen: boolean;
|
|
192
|
+
}) => ReactNode);
|
|
193
|
+
/**
|
|
194
|
+
* Indicator placement
|
|
195
|
+
* @default 'start'
|
|
196
|
+
*/
|
|
197
|
+
indicatorPlacement?: 'end' | 'start';
|
|
198
|
+
/**
|
|
199
|
+
* Unique identifier for the item (use as React key)
|
|
200
|
+
*/
|
|
201
|
+
itemKey: Key;
|
|
202
|
+
/**
|
|
203
|
+
* Callback when expanded state changes
|
|
204
|
+
*/
|
|
205
|
+
onExpandChange?: (expanded: boolean) => void;
|
|
206
|
+
/**
|
|
207
|
+
* Custom styles for child elements
|
|
208
|
+
*/
|
|
209
|
+
styles?: {
|
|
210
|
+
action?: CSSProperties;
|
|
211
|
+
base?: CSSProperties;
|
|
212
|
+
content?: CSSProperties;
|
|
213
|
+
header?: CSSProperties;
|
|
214
|
+
indicator?: CSSProperties;
|
|
215
|
+
title?: CSSProperties;
|
|
216
|
+
};
|
|
217
|
+
/**
|
|
218
|
+
* Title of the accordion item
|
|
219
|
+
*/
|
|
220
|
+
title: ReactNode;
|
|
221
|
+
}
|
|
222
|
+
interface AccordionProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onChange'>, Pick<BlockProps, 'variant' | 'ref'> {
|
|
223
|
+
/**
|
|
224
|
+
* Whether only one item can be expanded at a time
|
|
225
|
+
* @default false
|
|
226
|
+
*/
|
|
227
|
+
accordion?: boolean;
|
|
228
|
+
/**
|
|
229
|
+
* Accordion items
|
|
230
|
+
*/
|
|
231
|
+
children?: ReactNode;
|
|
232
|
+
/**
|
|
233
|
+
* Custom classNames for child elements
|
|
234
|
+
*/
|
|
235
|
+
classNames?: {
|
|
236
|
+
base?: string;
|
|
237
|
+
};
|
|
238
|
+
/**
|
|
239
|
+
* Default expanded keys (uncontrolled)
|
|
240
|
+
*/
|
|
241
|
+
defaultExpandedKeys?: Key[];
|
|
242
|
+
/**
|
|
243
|
+
* Disable animation
|
|
244
|
+
* @default false
|
|
245
|
+
*/
|
|
246
|
+
disableAnimation?: boolean;
|
|
247
|
+
/**
|
|
248
|
+
* Controlled expanded keys
|
|
249
|
+
*/
|
|
250
|
+
expandedKeys?: Key[];
|
|
251
|
+
/**
|
|
252
|
+
* Gap between accordion items
|
|
253
|
+
*/
|
|
254
|
+
gap?: number;
|
|
255
|
+
/**
|
|
256
|
+
* Whether to hide the chevron indicator for all items
|
|
257
|
+
* @default false
|
|
258
|
+
*/
|
|
259
|
+
hideIndicator?: boolean;
|
|
260
|
+
/**
|
|
261
|
+
* Indicator placement for all items
|
|
262
|
+
* @default 'start'
|
|
263
|
+
*/
|
|
264
|
+
indicatorPlacement?: 'end' | 'start';
|
|
265
|
+
/**
|
|
266
|
+
* Keep content mounted when collapsed
|
|
267
|
+
* @default true
|
|
268
|
+
*/
|
|
269
|
+
keepContentMounted?: boolean;
|
|
270
|
+
/**
|
|
271
|
+
* Motion props for motion animation
|
|
272
|
+
*/
|
|
273
|
+
motionProps?: any;
|
|
274
|
+
/**
|
|
275
|
+
* Callback when expanded keys change
|
|
276
|
+
*/
|
|
277
|
+
onExpandedChange?: (keys: Key[]) => void;
|
|
278
|
+
/**
|
|
279
|
+
* Whether to show dividers between items
|
|
280
|
+
* @default false
|
|
281
|
+
*/
|
|
282
|
+
showDivider?: boolean;
|
|
283
|
+
/**
|
|
284
|
+
* Custom styles for child elements
|
|
285
|
+
*/
|
|
286
|
+
styles?: {
|
|
287
|
+
base?: CSSProperties;
|
|
288
|
+
};
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
declare const Accordion: react.NamedExoticComponent<AccordionProps>;
|
|
292
|
+
|
|
293
|
+
declare const AccordionItem: react.NamedExoticComponent<AccordionItemProps>;
|
|
294
|
+
|
|
295
|
+
interface IconSizeConfig extends Pick<LucideProps, 'strokeWidth' | 'absoluteStrokeWidth'> {
|
|
296
|
+
size?: number | string;
|
|
297
|
+
}
|
|
298
|
+
type IconSizeType = 'large' | 'middle' | 'small';
|
|
299
|
+
type IconSize = number | IconSizeType | IconSizeConfig;
|
|
300
|
+
type LucideIconProps = Pick<LucideProps, 'fill' | 'fillRule' | 'fillOpacity' | 'color' | 'focusable'>;
|
|
301
|
+
interface IconProps$1 extends Omit<SpanProps, 'children'>, LucideIconProps {
|
|
302
|
+
icon: LucideIcon | FC<any> | ReactNode;
|
|
303
|
+
ref?: Ref<SVGSVGElement>;
|
|
304
|
+
size?: IconSize;
|
|
305
|
+
spin?: boolean;
|
|
306
|
+
}
|
|
307
|
+
|
|
308
|
+
type IconContentConfig = Omit<IconProps$1, 'icon' | 'ref'>;
|
|
309
|
+
declare const IconProvider: react.NamedExoticComponent<{
|
|
310
|
+
children: ReactNode;
|
|
311
|
+
config?: IconContentConfig;
|
|
312
|
+
}>;
|
|
313
|
+
|
|
314
|
+
declare const Icon: react.NamedExoticComponent<IconProps$1>;
|
|
315
|
+
|
|
316
|
+
declare const KeyMapEnum: {
|
|
317
|
+
readonly Alt: "alt";
|
|
318
|
+
readonly Backquote: "backquote";
|
|
319
|
+
readonly Backslash: "backslash";
|
|
320
|
+
readonly Backspace: "backspace";
|
|
321
|
+
readonly BracketLeft: "bracketleft";
|
|
322
|
+
readonly BracketRight: "bracketright";
|
|
323
|
+
readonly Comma: "comma";
|
|
324
|
+
readonly CommandOrControl: "commandorcontrol";
|
|
325
|
+
readonly Control: "control";
|
|
326
|
+
readonly Ctrl: "ctrl";
|
|
327
|
+
readonly Down: "down";
|
|
328
|
+
readonly Enter: "enter";
|
|
329
|
+
readonly Equal: "equal";
|
|
330
|
+
readonly Esc: "esc";
|
|
331
|
+
readonly Left: "left";
|
|
332
|
+
readonly LeftClick: "left-click";
|
|
333
|
+
readonly LeftDoubleClick: "left-double-click";
|
|
334
|
+
readonly Meta: "meta";
|
|
335
|
+
readonly MiddleClick: "middle-click";
|
|
336
|
+
readonly Minus: "minus";
|
|
337
|
+
readonly Mod: "mod";
|
|
338
|
+
readonly Period: "period";
|
|
339
|
+
readonly Plus: "equal";
|
|
340
|
+
readonly QuestionMark: "slash";
|
|
341
|
+
readonly Quote: "quote";
|
|
342
|
+
readonly Right: "right";
|
|
343
|
+
readonly RightClick: "right-click";
|
|
344
|
+
readonly RightDoubleClick: "right-double-click";
|
|
345
|
+
readonly Semicolon: "semicolon";
|
|
346
|
+
readonly Shift: "shift";
|
|
347
|
+
readonly Slash: "slash";
|
|
348
|
+
readonly Space: "space";
|
|
349
|
+
readonly Tab: "tab";
|
|
350
|
+
readonly Up: "up";
|
|
351
|
+
};
|
|
352
|
+
|
|
353
|
+
interface HotkeyProps extends Omit<FlexProps, 'children'> {
|
|
354
|
+
classNames?: {
|
|
355
|
+
kbdClassName?: string;
|
|
356
|
+
};
|
|
357
|
+
compact?: boolean;
|
|
358
|
+
inverseTheme?: boolean;
|
|
359
|
+
isApple?: boolean;
|
|
360
|
+
keys: string;
|
|
361
|
+
styles?: {
|
|
362
|
+
kbdStyle?: CSSProperties;
|
|
363
|
+
};
|
|
364
|
+
variant?: 'filled' | 'outlined' | 'borderless';
|
|
365
|
+
}
|
|
366
|
+
|
|
367
|
+
declare const Hotkey: react.NamedExoticComponent<HotkeyProps>;
|
|
368
|
+
|
|
369
|
+
declare const combineKeys: (keys: string[]) => string;
|
|
370
|
+
|
|
371
|
+
/**
|
|
372
|
+
* Base UI uses a small set of string literal unions for alignment and side.
|
|
373
|
+
* We re-declare them here to avoid importing internal/non-exported Base UI paths.
|
|
374
|
+
*/
|
|
375
|
+
type Side = 'top' | 'bottom' | 'left' | 'right' | 'inline-end' | 'inline-start';
|
|
376
|
+
type Align = 'start' | 'center' | 'end';
|
|
377
|
+
type PlacementConfig = {
|
|
378
|
+
align: Align;
|
|
379
|
+
side: Side;
|
|
380
|
+
};
|
|
381
|
+
/**
|
|
382
|
+
* All supported placement values
|
|
383
|
+
* - Unified placement names for Tooltip, Popover, and DropdownMenu
|
|
384
|
+
* - Ant Design style: topLeft, topCenter, topRight, etc.
|
|
385
|
+
* - Additional aliases: top (same as topCenter), bottom (same as bottomCenter)
|
|
386
|
+
*/
|
|
387
|
+
type Placement = 'top' | 'topLeft' | 'topCenter' | 'topRight' | 'bottom' | 'bottomLeft' | 'bottomCenter' | 'bottomRight' | 'left' | 'leftTop' | 'leftBottom' | 'right' | 'rightTop' | 'rightBottom';
|
|
388
|
+
/**
|
|
389
|
+
* Map of placement values to Base UI placement config
|
|
390
|
+
* Used by Popover and DropdownMenu components
|
|
391
|
+
*/
|
|
392
|
+
declare const placementMap: Record<Placement, PlacementConfig>;
|
|
393
|
+
/**
|
|
394
|
+
* Convert unified Placement to Floating UI placement format
|
|
395
|
+
* Used by Tooltip component which uses @floating-ui/react
|
|
396
|
+
*
|
|
397
|
+
* @param placement - Unified placement value
|
|
398
|
+
* @returns Floating UI placement (e.g., 'top-start', 'bottom-end')
|
|
399
|
+
*/
|
|
400
|
+
declare const toFloatingUIPlacement: (placement?: Placement) => Placement$1;
|
|
401
|
+
|
|
402
|
+
type TooltipPlacement = Placement;
|
|
403
|
+
/**
|
|
404
|
+
* Base UI Positioner props that can be passed through
|
|
405
|
+
*/
|
|
406
|
+
type TooltipPositionerProps = Omit<TooltipPositionerProps$1, 'className' | 'style' | 'children'>;
|
|
407
|
+
/**
|
|
408
|
+
* Base UI Trigger props that can be passed through
|
|
409
|
+
*/
|
|
410
|
+
type TooltipTriggerComponentProps = Omit<TooltipTriggerProps, 'className' | 'style' | 'children' | 'render' | 'handle' | 'payload'>;
|
|
411
|
+
/**
|
|
412
|
+
* Base UI Popup props that can be passed through
|
|
413
|
+
*/
|
|
414
|
+
type TooltipPopupComponentProps = Omit<TooltipPopupProps, 'className' | 'style' | 'children'>;
|
|
415
|
+
/**
|
|
416
|
+
* Base UI Portal props that can be passed through
|
|
417
|
+
*/
|
|
418
|
+
type TooltipPortalProps = Omit<TooltipPortalProps$1, 'children' | 'container'>;
|
|
419
|
+
interface TooltipProps {
|
|
420
|
+
/**
|
|
421
|
+
* Whether the tooltip has an arrow pointer.
|
|
422
|
+
* @default false
|
|
423
|
+
*/
|
|
424
|
+
arrow?: boolean;
|
|
425
|
+
/**
|
|
426
|
+
* Trigger element. Prefer a single React element.
|
|
427
|
+
*/
|
|
428
|
+
children: ReactElement | ReactNode;
|
|
429
|
+
/**
|
|
430
|
+
* Custom className for the tooltip floating root.
|
|
431
|
+
*/
|
|
432
|
+
className?: string;
|
|
433
|
+
/**
|
|
434
|
+
* Compatible with Ant Design `classNames` shape (subset).
|
|
435
|
+
*/
|
|
436
|
+
classNames?: {
|
|
437
|
+
arrow?: string;
|
|
438
|
+
container?: string;
|
|
439
|
+
content?: string;
|
|
440
|
+
root?: string;
|
|
441
|
+
};
|
|
442
|
+
/**
|
|
443
|
+
* Delay (in milliseconds) before closing the tooltip.
|
|
444
|
+
* Takes precedence over `mouseLeaveDelay`.
|
|
445
|
+
*/
|
|
446
|
+
closeDelay?: number;
|
|
447
|
+
/**
|
|
448
|
+
* Uncontrolled initial open state.
|
|
449
|
+
*/
|
|
450
|
+
defaultOpen?: boolean;
|
|
451
|
+
/**
|
|
452
|
+
* Disable tooltip behavior.
|
|
453
|
+
*/
|
|
454
|
+
disabled?: boolean;
|
|
455
|
+
/**
|
|
456
|
+
* An Ant Design compatible escape hatch for portal container.
|
|
457
|
+
*/
|
|
458
|
+
getPopupContainer?: (triggerNode: HTMLElement) => HTMLElement;
|
|
459
|
+
hotkey?: string;
|
|
460
|
+
hotkeyProps?: Omit<HotkeyProps, 'keys'>;
|
|
461
|
+
/**
|
|
462
|
+
* Delay (in seconds) before showing the tooltip on hover.
|
|
463
|
+
* Kept compatible with Ant Design `Tooltip`.
|
|
464
|
+
*/
|
|
465
|
+
mouseEnterDelay?: number;
|
|
466
|
+
/**
|
|
467
|
+
* Delay (in seconds) before hiding the tooltip on hover out.
|
|
468
|
+
* Kept compatible with Ant Design `Tooltip`.
|
|
469
|
+
*/
|
|
470
|
+
mouseLeaveDelay?: number;
|
|
471
|
+
/**
|
|
472
|
+
* Callback when open state changes.
|
|
473
|
+
*/
|
|
474
|
+
onOpenChange?: (open: boolean) => void;
|
|
475
|
+
/**
|
|
476
|
+
* Controlled open state.
|
|
477
|
+
*/
|
|
478
|
+
open?: boolean;
|
|
479
|
+
/**
|
|
480
|
+
* Delay (in milliseconds) before opening the tooltip.
|
|
481
|
+
* Takes precedence over `mouseEnterDelay`.
|
|
482
|
+
*/
|
|
483
|
+
openDelay?: number;
|
|
484
|
+
/**
|
|
485
|
+
* Tooltip placement. Supports Floating UI placements and Ant Design legacy placements.
|
|
486
|
+
*/
|
|
487
|
+
placement?: TooltipPlacement;
|
|
488
|
+
/**
|
|
489
|
+
* Base UI Popup 组件的 props
|
|
490
|
+
*/
|
|
491
|
+
popupProps?: TooltipPopupComponentProps;
|
|
492
|
+
/**
|
|
493
|
+
* Base UI Portal 组件的 props
|
|
494
|
+
*/
|
|
495
|
+
portalProps?: TooltipPortalProps;
|
|
496
|
+
/**
|
|
497
|
+
* Base UI Positioner 组件的 props
|
|
498
|
+
*/
|
|
499
|
+
positionerProps?: TooltipPositionerProps;
|
|
500
|
+
ref?: ComponentPropsWithRef<typeof Tooltip$1.Trigger>['ref'];
|
|
501
|
+
/**
|
|
502
|
+
* When true, this tooltip will render independently even inside a TooltipGroup,
|
|
503
|
+
* ignoring the group singleton behavior.
|
|
504
|
+
*/
|
|
505
|
+
standalone?: boolean;
|
|
506
|
+
/**
|
|
507
|
+
* Compatible with Ant Design `styles` shape (subset).
|
|
508
|
+
*/
|
|
509
|
+
styles?: {
|
|
510
|
+
arrow?: CSSProperties;
|
|
511
|
+
/**
|
|
512
|
+
* Backwards-compatible alias for the floating root style.
|
|
513
|
+
*/
|
|
514
|
+
container?: CSSProperties;
|
|
515
|
+
content?: CSSProperties;
|
|
516
|
+
root?: CSSProperties;
|
|
517
|
+
};
|
|
518
|
+
/**
|
|
519
|
+
* Tooltip content.
|
|
520
|
+
*/
|
|
521
|
+
title: ReactNode;
|
|
522
|
+
/**
|
|
523
|
+
* Base UI Trigger 组件的 props
|
|
524
|
+
*/
|
|
525
|
+
triggerProps?: TooltipTriggerComponentProps;
|
|
526
|
+
/**
|
|
527
|
+
* z-index for tooltip floating root.
|
|
528
|
+
*/
|
|
529
|
+
zIndex?: number;
|
|
530
|
+
}
|
|
531
|
+
/**
|
|
532
|
+
* Props for `TooltipGroup`.
|
|
533
|
+
*/
|
|
534
|
+
interface TooltipGroupProps {
|
|
535
|
+
arrow?: boolean;
|
|
536
|
+
children: ReactNode;
|
|
537
|
+
className?: string;
|
|
538
|
+
classNames?: TooltipProps['classNames'];
|
|
539
|
+
closeDelay?: number;
|
|
540
|
+
/**
|
|
541
|
+
* Disable the "destroy on invalid trigger (display:none / disconnected)" guard for performance.
|
|
542
|
+
* @default false
|
|
543
|
+
*/
|
|
544
|
+
disableDestroyOnInvalidTrigger?: boolean;
|
|
545
|
+
/**
|
|
546
|
+
* Disable the "hide when positioner falls back to (0,0)" visual guard for performance.
|
|
547
|
+
* @default false
|
|
548
|
+
*/
|
|
549
|
+
disableZeroOriginGuard?: boolean;
|
|
550
|
+
disabled?: boolean;
|
|
551
|
+
getPopupContainer?: TooltipProps['getPopupContainer'];
|
|
552
|
+
hotkey?: string;
|
|
553
|
+
hotkeyProps?: Omit<HotkeyProps, 'keys'>;
|
|
554
|
+
layoutAnimation?: boolean;
|
|
555
|
+
mouseEnterDelay?: number;
|
|
556
|
+
mouseLeaveDelay?: number;
|
|
557
|
+
openDelay?: number;
|
|
558
|
+
placement?: TooltipPlacement;
|
|
559
|
+
popupProps?: TooltipPopupComponentProps;
|
|
560
|
+
portalProps?: TooltipPortalProps;
|
|
561
|
+
positionerProps?: TooltipPositionerProps;
|
|
562
|
+
styles?: TooltipProps['styles'];
|
|
563
|
+
triggerProps?: TooltipTriggerComponentProps;
|
|
564
|
+
zIndex?: number;
|
|
565
|
+
}
|
|
566
|
+
|
|
567
|
+
declare const Tooltip: FC<TooltipProps>;
|
|
568
|
+
|
|
569
|
+
declare const TooltipGroup: FC<TooltipGroupProps>;
|
|
570
|
+
|
|
571
|
+
interface ActionIconSizeConfig extends IconSizeConfig {
|
|
572
|
+
blockSize?: number | string;
|
|
573
|
+
borderRadius?: number | string;
|
|
574
|
+
}
|
|
575
|
+
type ActionIconSize = number | IconSizeType | ActionIconSizeConfig;
|
|
576
|
+
interface ActionIconProps extends Partial<LucideIconProps>, Omit<FlexProps, 'title' | 'children'> {
|
|
577
|
+
active?: boolean;
|
|
578
|
+
danger?: boolean;
|
|
579
|
+
disabled?: boolean;
|
|
580
|
+
glass?: boolean;
|
|
581
|
+
icon?: IconProps$1['icon'] | ReactNode;
|
|
582
|
+
loading?: boolean;
|
|
583
|
+
ref?: Ref<HTMLDivElement>;
|
|
584
|
+
shadow?: boolean;
|
|
585
|
+
size?: ActionIconSize;
|
|
586
|
+
spin?: boolean;
|
|
587
|
+
title?: TooltipProps['title'];
|
|
588
|
+
tooltipProps?: Omit<TooltipProps, 'children' | 'title'>;
|
|
589
|
+
variant?: 'borderless' | 'filled' | 'outlined';
|
|
590
|
+
}
|
|
591
|
+
|
|
592
|
+
declare const ActionIcon: react.NamedExoticComponent<ActionIconProps>;
|
|
593
|
+
|
|
594
|
+
/**
|
|
595
|
+
* Checkbox menu item shared by DropdownMenu / ContextMenu.
|
|
596
|
+
* This is intentionally aligned with Base UI's `Menu.CheckboxItem` API we use.
|
|
597
|
+
*/
|
|
598
|
+
interface MenuCheckboxItemType {
|
|
599
|
+
checked?: boolean;
|
|
600
|
+
closeOnClick?: boolean;
|
|
601
|
+
danger?: boolean;
|
|
602
|
+
defaultChecked?: boolean;
|
|
603
|
+
disabled?: boolean;
|
|
604
|
+
extra?: ReactNode;
|
|
605
|
+
icon?: IconProps$1['icon'];
|
|
606
|
+
key: Key;
|
|
607
|
+
label?: ReactNode;
|
|
608
|
+
onCheckedChange?: (checked: boolean) => void;
|
|
609
|
+
title?: ReactNode;
|
|
610
|
+
type: 'checkbox';
|
|
611
|
+
}
|
|
612
|
+
|
|
613
|
+
/**
|
|
614
|
+
* Switch menu item shared by DropdownMenu / ContextMenu.
|
|
615
|
+
* Similar to checkbox but renders as a toggle switch.
|
|
616
|
+
*/
|
|
617
|
+
interface MenuSwitchItemType {
|
|
618
|
+
checked?: boolean;
|
|
619
|
+
closeOnClick?: boolean;
|
|
620
|
+
danger?: boolean;
|
|
621
|
+
defaultChecked?: boolean;
|
|
622
|
+
disabled?: boolean;
|
|
623
|
+
extra?: ReactNode;
|
|
624
|
+
icon?: IconProps$1['icon'];
|
|
625
|
+
key: Key;
|
|
626
|
+
label?: ReactNode;
|
|
627
|
+
onCheckedChange?: (checked: boolean) => void;
|
|
628
|
+
title?: ReactNode;
|
|
629
|
+
type: 'switch';
|
|
630
|
+
}
|
|
631
|
+
|
|
632
|
+
interface MenuItemType extends MenuItemType$1 {
|
|
633
|
+
/**
|
|
634
|
+
* Whether to close the menu when this item is clicked.
|
|
635
|
+
* Set to `false` to keep the menu open (useful for items with Upload, file picker, etc.)
|
|
636
|
+
* @default true
|
|
637
|
+
*/
|
|
638
|
+
closeOnClick?: boolean;
|
|
639
|
+
danger?: boolean;
|
|
640
|
+
icon?: IconProps$1['icon'];
|
|
641
|
+
loading?: boolean;
|
|
642
|
+
title?: string;
|
|
643
|
+
}
|
|
644
|
+
interface SubMenuType<T extends MenuItemType = MenuItemType> extends Omit<SubMenuType$1, 'children'> {
|
|
645
|
+
children: ItemType<T>[];
|
|
646
|
+
icon?: IconProps$1['icon'];
|
|
647
|
+
}
|
|
648
|
+
interface MenuItemGroupType<T extends MenuItemType = MenuItemType> extends Omit<MenuItemGroupType$1, 'children'> {
|
|
649
|
+
children?: ItemType<T>[];
|
|
650
|
+
key?: Key;
|
|
651
|
+
}
|
|
652
|
+
interface MenuDividerType extends MenuDividerType$1 {
|
|
653
|
+
dashed?: boolean;
|
|
654
|
+
key?: Key;
|
|
655
|
+
}
|
|
656
|
+
type ItemType<T extends MenuItemType = MenuItemType> = T | SubMenuType<T> | MenuItemGroupType<T> | MenuDividerType | null;
|
|
657
|
+
type GenericItemType<T = unknown> = T extends infer U extends MenuItemType ? unknown extends U ? ItemType : ItemType<U> : ItemType;
|
|
658
|
+
interface MenuProps<T = unknown> extends Omit<MenuProps$1, 'items'> {
|
|
659
|
+
compact?: boolean;
|
|
660
|
+
iconProps?: IconContentConfig;
|
|
661
|
+
items: GenericItemType<T>[];
|
|
662
|
+
ref?: Ref<MenuRef>;
|
|
663
|
+
shadow?: boolean;
|
|
664
|
+
variant?: 'filled' | 'outlined' | 'borderless';
|
|
665
|
+
}
|
|
666
|
+
|
|
667
|
+
/**
|
|
668
|
+
* Group type for Base UI driven menus (DropdownMenu / ContextMenu).
|
|
669
|
+
* Unlike MenuItemGroupType, this supports checkbox/switch items in children.
|
|
670
|
+
*/
|
|
671
|
+
interface BaseMenuItemGroupType {
|
|
672
|
+
children?: BaseMenuItemType[];
|
|
673
|
+
key?: Key;
|
|
674
|
+
label?: ReactNode;
|
|
675
|
+
type: 'group';
|
|
676
|
+
}
|
|
677
|
+
/**
|
|
678
|
+
* Submenu type for Base UI driven menus (DropdownMenu / ContextMenu).
|
|
679
|
+
* Unlike SubMenuType, this supports checkbox/switch items in children.
|
|
680
|
+
*/
|
|
681
|
+
interface BaseSubMenuType extends Omit<SubMenuType, 'children'> {
|
|
682
|
+
children?: BaseMenuItemType[];
|
|
683
|
+
}
|
|
684
|
+
/**
|
|
685
|
+
* Base item union for Base UI driven menus (DropdownMenu / ContextMenu).
|
|
686
|
+
*
|
|
687
|
+
* Note: This intentionally does NOT change `GenericItemType` itself,
|
|
688
|
+
* because `GenericItemType` maps to rc-menu/antd Menu item types.
|
|
689
|
+
*/
|
|
690
|
+
type BaseMenuItemType = MenuItemType | BaseSubMenuType | BaseMenuItemGroupType | MenuDividerType | MenuCheckboxItemType | MenuSwitchItemType | null;
|
|
691
|
+
|
|
692
|
+
declare const Menu: react.NamedExoticComponent<MenuProps<unknown>>;
|
|
693
|
+
|
|
694
|
+
type IconSpaceMode = 'global' | 'group';
|
|
695
|
+
interface RenderOptions {
|
|
696
|
+
iconSpaceMode?: IconSpaceMode;
|
|
697
|
+
indicatorOnRight?: boolean;
|
|
698
|
+
reserveIconSpace?: boolean;
|
|
699
|
+
}
|
|
700
|
+
|
|
701
|
+
declare const renderDropdownMenuItems: (items: DropdownItem[], keyPath?: string[], options?: RenderOptions) => ReactNode[];
|
|
702
|
+
|
|
703
|
+
type DropdownMenuPlacement = Placement;
|
|
704
|
+
type DropdownMenuCheckboxItem = MenuCheckboxItemType;
|
|
705
|
+
type DropdownItem = BaseMenuItemType;
|
|
706
|
+
interface DropdownMenuProps<Payload = unknown> extends Omit<MenuRootProps<Payload>, 'children'> {
|
|
707
|
+
children: ReactNode;
|
|
708
|
+
/**
|
|
709
|
+
* 图标空间保留模式
|
|
710
|
+
* - 'global': 当任何一个选项有图标时,所有 item 都保留图标位
|
|
711
|
+
* - 'group': 只有当一个分组中存在图标时,该分组才保留图标位
|
|
712
|
+
* @default 'global'
|
|
713
|
+
*/
|
|
714
|
+
iconSpaceMode?: IconSpaceMode;
|
|
715
|
+
items: DropdownItem[] | (() => DropdownItem[]);
|
|
716
|
+
nativeButton?: boolean;
|
|
717
|
+
placement?: DropdownMenuPlacement;
|
|
718
|
+
popupProps?: MenuPopupProps;
|
|
719
|
+
portalProps?: MenuPortalProps;
|
|
720
|
+
positionerProps?: MenuPositionerProps;
|
|
721
|
+
/**
|
|
722
|
+
* 触发方式
|
|
723
|
+
* @default 'click'
|
|
724
|
+
*/
|
|
725
|
+
trigger?: Trigger;
|
|
726
|
+
triggerProps?: Omit<MenuTriggerProps<Payload>, 'children'>;
|
|
727
|
+
}
|
|
728
|
+
|
|
729
|
+
declare const DROPDOWN_MENU_CONTAINER_ATTR = "data-lobe-ui-dropdown-menu-container";
|
|
730
|
+
declare const DropdownMenuRoot: typeof Menu$1.Root;
|
|
731
|
+
declare const DropdownMenuSubmenuRoot: typeof Menu$1.SubmenuRoot;
|
|
732
|
+
declare const DropdownMenuCheckboxItemIndicator: react__default.ForwardRefExoticComponent<_base_ui_react_menu.MenuCheckboxItemIndicatorProps & react__default.RefAttributes<HTMLSpanElement>>;
|
|
733
|
+
type DropdownMenuTriggerProps = Omit<react__default.ComponentPropsWithRef<typeof Menu$1.Trigger>, 'children' | 'render'> & {
|
|
734
|
+
children: react__default.ReactNode;
|
|
735
|
+
};
|
|
736
|
+
declare const DropdownMenuTrigger: {
|
|
737
|
+
({ children, className, nativeButton, ref: refProp, ...rest }: DropdownMenuTriggerProps): react_jsx_runtime.JSX.Element;
|
|
738
|
+
displayName: string;
|
|
739
|
+
};
|
|
740
|
+
type DropdownMenuPortalProps = react__default.ComponentProps<typeof Menu$1.Portal> & {
|
|
741
|
+
/**
|
|
742
|
+
* When `container` is not provided, it uses a shared container created by `usePortalContainer`.
|
|
743
|
+
*/
|
|
744
|
+
container?: HTMLElement | null;
|
|
745
|
+
};
|
|
746
|
+
declare const DropdownMenuPortal: {
|
|
747
|
+
({ container, ...rest }: DropdownMenuPortalProps): react_jsx_runtime.JSX.Element;
|
|
748
|
+
displayName: string;
|
|
749
|
+
};
|
|
750
|
+
type DropdownMenuPositionerProps = react__default.ComponentProps<typeof Menu$1.Positioner> & {
|
|
751
|
+
hoverTrigger?: boolean;
|
|
752
|
+
placement?: DropdownMenuPlacement;
|
|
753
|
+
};
|
|
754
|
+
declare const DropdownMenuPositioner: {
|
|
755
|
+
({ className, placement, hoverTrigger, align, side, sideOffset, children, ...rest }: DropdownMenuPositionerProps): react_jsx_runtime.JSX.Element;
|
|
756
|
+
displayName: string;
|
|
757
|
+
};
|
|
758
|
+
type DropdownMenuPopupProps = react__default.ComponentProps<typeof Menu$1.Popup>;
|
|
759
|
+
declare const DropdownMenuPopup: {
|
|
760
|
+
({ className, ...rest }: DropdownMenuPopupProps): react_jsx_runtime.JSX.Element;
|
|
761
|
+
displayName: string;
|
|
762
|
+
};
|
|
763
|
+
type DropdownMenuItemProps = react__default.ComponentProps<typeof Menu$1.Item> & {
|
|
764
|
+
danger?: boolean;
|
|
765
|
+
};
|
|
766
|
+
declare const DropdownMenuItem: {
|
|
767
|
+
({ className, danger, ...rest }: DropdownMenuItemProps): react_jsx_runtime.JSX.Element;
|
|
768
|
+
displayName: string;
|
|
769
|
+
};
|
|
770
|
+
type DropdownMenuCheckboxItemProps = react__default.ComponentProps<typeof Menu$1.CheckboxItem> & {
|
|
771
|
+
danger?: boolean;
|
|
772
|
+
};
|
|
773
|
+
declare const DropdownMenuCheckboxItemPrimitive: {
|
|
774
|
+
({ className, danger, ...rest }: DropdownMenuCheckboxItemProps): react_jsx_runtime.JSX.Element;
|
|
775
|
+
displayName: string;
|
|
776
|
+
};
|
|
777
|
+
type DropdownMenuSeparatorProps = react__default.ComponentProps<typeof Menu$1.Separator>;
|
|
778
|
+
declare const DropdownMenuSeparator: {
|
|
779
|
+
({ className, ...rest }: DropdownMenuSeparatorProps): react_jsx_runtime.JSX.Element;
|
|
780
|
+
displayName: string;
|
|
781
|
+
};
|
|
782
|
+
declare const DropdownMenuGroup: react__default.ForwardRefExoticComponent<_base_ui_react_menu.MenuGroupProps & react__default.RefAttributes<Element>>;
|
|
783
|
+
type DropdownMenuGroupLabelProps = react__default.ComponentProps<typeof Menu$1.GroupLabel>;
|
|
784
|
+
declare const DropdownMenuGroupLabel: {
|
|
785
|
+
({ className, ...rest }: DropdownMenuGroupLabelProps): react_jsx_runtime.JSX.Element;
|
|
786
|
+
displayName: string;
|
|
787
|
+
};
|
|
788
|
+
type DropdownMenuSubmenuTriggerProps = react__default.ComponentProps<typeof Menu$1.SubmenuTrigger> & {
|
|
789
|
+
danger?: boolean;
|
|
790
|
+
};
|
|
791
|
+
declare const DropdownMenuSubmenuTrigger: {
|
|
792
|
+
({ className, danger, ...rest }: DropdownMenuSubmenuTriggerProps): react_jsx_runtime.JSX.Element;
|
|
793
|
+
displayName: string;
|
|
794
|
+
};
|
|
795
|
+
type DropdownMenuItemContentProps = react__default.HTMLAttributes<HTMLDivElement>;
|
|
796
|
+
declare const DropdownMenuItemContent: {
|
|
797
|
+
({ className, ...rest }: DropdownMenuItemContentProps): react_jsx_runtime.JSX.Element;
|
|
798
|
+
displayName: string;
|
|
799
|
+
};
|
|
800
|
+
type DropdownMenuItemIconProps = react__default.HTMLAttributes<HTMLSpanElement>;
|
|
801
|
+
declare const DropdownMenuItemIcon: {
|
|
802
|
+
({ className, ...rest }: DropdownMenuItemIconProps): react_jsx_runtime.JSX.Element;
|
|
803
|
+
displayName: string;
|
|
804
|
+
};
|
|
805
|
+
type DropdownMenuItemLabelProps = react__default.HTMLAttributes<HTMLSpanElement>;
|
|
806
|
+
declare const DropdownMenuItemLabel: {
|
|
807
|
+
({ className, ...rest }: DropdownMenuItemLabelProps): react_jsx_runtime.JSX.Element;
|
|
808
|
+
displayName: string;
|
|
809
|
+
};
|
|
810
|
+
type DropdownMenuItemExtraProps = react__default.HTMLAttributes<HTMLSpanElement>;
|
|
811
|
+
declare const DropdownMenuItemExtra: {
|
|
812
|
+
({ className, ...rest }: DropdownMenuItemExtraProps): react_jsx_runtime.JSX.Element;
|
|
813
|
+
displayName: string;
|
|
814
|
+
};
|
|
815
|
+
type DropdownMenuSubmenuArrowProps = react__default.HTMLAttributes<HTMLSpanElement>;
|
|
816
|
+
declare const DropdownMenuSubmenuArrow: {
|
|
817
|
+
({ className, ...rest }: DropdownMenuSubmenuArrowProps): react_jsx_runtime.JSX.Element;
|
|
818
|
+
displayName: string;
|
|
819
|
+
};
|
|
820
|
+
|
|
821
|
+
declare const DropdownMenu: react.NamedExoticComponent<DropdownMenuProps<unknown>>;
|
|
822
|
+
|
|
823
|
+
type ActionIconGroupEvent = Pick<MenuInfo, 'key' | 'keyPath' | 'domEvent'>;
|
|
824
|
+
interface ActionIconGroupProps extends Omit<FlexProps, 'children'> {
|
|
825
|
+
actionIconProps?: Partial<Omit<ActionIconProps, 'icon' | 'size' | 'ref'>>;
|
|
826
|
+
disabled?: boolean;
|
|
827
|
+
glass?: boolean;
|
|
828
|
+
items?: MenuItemType[];
|
|
829
|
+
menu?: DropdownMenuProps['items'];
|
|
830
|
+
onActionClick?: (action: ActionIconGroupEvent) => void;
|
|
831
|
+
ref?: Ref<HTMLDivElement>;
|
|
832
|
+
shadow?: boolean;
|
|
833
|
+
size?: ActionIconProps['size'];
|
|
834
|
+
variant?: 'filled' | 'outlined' | 'borderless';
|
|
835
|
+
}
|
|
836
|
+
|
|
837
|
+
declare const ActionIconGroup: FC<ActionIconGroupProps>;
|
|
838
|
+
|
|
839
|
+
interface AlertProps extends Omit<AlertProps$1, 'icon' | 'type'> {
|
|
840
|
+
classNames?: {
|
|
841
|
+
alert?: string;
|
|
842
|
+
container?: string;
|
|
843
|
+
extraContent?: string;
|
|
844
|
+
};
|
|
845
|
+
colorfulText?: boolean;
|
|
846
|
+
extra?: ReactNode;
|
|
847
|
+
extraDefaultExpand?: boolean;
|
|
848
|
+
extraIsolate?: boolean;
|
|
849
|
+
glass?: boolean;
|
|
850
|
+
icon?: IconProps$1['icon'];
|
|
851
|
+
iconProps?: Omit<IconProps$1, 'icon'>;
|
|
852
|
+
ref?: Ref<AlertRef>;
|
|
853
|
+
styles?: {
|
|
854
|
+
alert?: CSSProperties;
|
|
855
|
+
container?: CSSProperties;
|
|
856
|
+
extraContent?: CSSProperties;
|
|
857
|
+
};
|
|
858
|
+
text?: {
|
|
859
|
+
detail?: string;
|
|
860
|
+
};
|
|
861
|
+
type?: 'success' | 'info' | 'warning' | 'error' | 'secondary';
|
|
862
|
+
variant?: 'filled' | 'outlined' | 'borderless';
|
|
863
|
+
}
|
|
864
|
+
|
|
865
|
+
declare const Alert: react.NamedExoticComponent<AlertProps>;
|
|
866
|
+
|
|
867
|
+
interface AutoCompleteProps extends AutoCompleteProps$1 {
|
|
868
|
+
shadow?: boolean;
|
|
869
|
+
}
|
|
870
|
+
|
|
871
|
+
declare const AutoComplete: react.NamedExoticComponent<AutoCompleteProps>;
|
|
872
|
+
|
|
873
|
+
interface AvatarProps extends AvatarProps$1 {
|
|
874
|
+
animation?: boolean;
|
|
875
|
+
avatar?: string | ReactNode;
|
|
876
|
+
background?: string;
|
|
877
|
+
bordered?: boolean;
|
|
878
|
+
borderedColor?: string;
|
|
879
|
+
emojiScaleWithBackground?: boolean;
|
|
880
|
+
loading?: boolean;
|
|
881
|
+
ref?: Ref<HTMLDivElement>;
|
|
882
|
+
shadow?: boolean;
|
|
883
|
+
shape?: 'circle' | 'square';
|
|
884
|
+
size?: number;
|
|
885
|
+
sliceText?: boolean;
|
|
886
|
+
title?: string;
|
|
887
|
+
tooltipProps?: Omit<TooltipProps, 'children' | 'title'>;
|
|
888
|
+
unoptimized?: boolean;
|
|
889
|
+
variant?: 'borderless' | 'filled' | 'outlined';
|
|
890
|
+
}
|
|
891
|
+
interface AvatarGroupItemType extends Pick<AvatarProps, 'avatar' | 'title' | 'alt' | 'onClick' | 'style' | 'className' | 'loading'> {
|
|
892
|
+
key: string;
|
|
893
|
+
}
|
|
894
|
+
interface AvatarGroupProps extends Pick<AvatarProps, 'variant' | 'bordered' | 'shadow' | 'size' | 'background' | 'animation' | 'draggable' | 'shape'>, Omit<FlexProps, 'children' | 'onClick'> {
|
|
895
|
+
classNames?: {
|
|
896
|
+
avatar?: string;
|
|
897
|
+
count?: string;
|
|
898
|
+
};
|
|
899
|
+
items: AvatarGroupItemType[];
|
|
900
|
+
max?: number;
|
|
901
|
+
onClick?: (props: {
|
|
902
|
+
item: AvatarGroupItemType;
|
|
903
|
+
key: string;
|
|
904
|
+
}) => void;
|
|
905
|
+
ref?: Ref<HTMLDivElement>;
|
|
906
|
+
styles?: {
|
|
907
|
+
avatar?: CSSProperties;
|
|
908
|
+
count?: CSSProperties;
|
|
909
|
+
};
|
|
910
|
+
zIndexReverse?: boolean;
|
|
911
|
+
}
|
|
912
|
+
|
|
913
|
+
declare const AvatarGroup: react.NamedExoticComponent<AvatarGroupProps>;
|
|
914
|
+
|
|
915
|
+
interface IAvatar {
|
|
916
|
+
(props: AvatarProps & RefAttributes<HTMLDivElement>): ReactNode;
|
|
917
|
+
Group: typeof AvatarGroup;
|
|
918
|
+
}
|
|
919
|
+
declare const Avatar: IAvatar;
|
|
920
|
+
|
|
921
|
+
interface BurgerProps {
|
|
922
|
+
className?: string;
|
|
923
|
+
drawerProps?: Partial<Omit<DrawerProps$1, 'items' | 'opened' | 'setOpened'>>;
|
|
924
|
+
fullscreen?: boolean;
|
|
925
|
+
headerHeight?: number;
|
|
926
|
+
iconProps?: Partial<ActionIconProps>;
|
|
927
|
+
items: MenuProps$1['items'];
|
|
928
|
+
onClick?: MenuProps$1['onClick'];
|
|
929
|
+
openKeys?: MenuProps$1['openKeys'];
|
|
930
|
+
opened: boolean;
|
|
931
|
+
ref?: Ref<HTMLDivElement>;
|
|
932
|
+
rootClassName?: string;
|
|
933
|
+
selectedKeys?: MenuProps$1['selectedKeys'];
|
|
934
|
+
setOpened: (state: boolean) => void;
|
|
935
|
+
size?: ActionIconProps['size'];
|
|
936
|
+
style?: CSSProperties;
|
|
937
|
+
variant?: ActionIconProps['variant'];
|
|
938
|
+
}
|
|
939
|
+
|
|
940
|
+
declare const Burger: react.NamedExoticComponent<BurgerProps>;
|
|
941
|
+
|
|
942
|
+
interface ButtonProps extends Omit<ButtonProps$1, 'icon'> {
|
|
943
|
+
glass?: boolean;
|
|
944
|
+
icon?: IconProps$1['icon'];
|
|
945
|
+
iconProps?: Partial<Omit<IconProps$1, 'icon'>>;
|
|
946
|
+
ref?: Ref<HTMLButtonElement | HTMLAnchorElement>;
|
|
947
|
+
shadow?: boolean;
|
|
948
|
+
}
|
|
949
|
+
|
|
950
|
+
declare const Button: FC<ButtonProps>;
|
|
951
|
+
|
|
952
|
+
interface TextProps extends DivProps {
|
|
953
|
+
align?: 'left' | 'center' | 'right';
|
|
954
|
+
as?: ElementType;
|
|
955
|
+
code?: boolean;
|
|
956
|
+
color?: string;
|
|
957
|
+
delete?: boolean;
|
|
958
|
+
disabled?: boolean;
|
|
959
|
+
ellipsis?: boolean | {
|
|
960
|
+
rows?: number;
|
|
961
|
+
tooltip?: boolean | string | TooltipProps;
|
|
962
|
+
tooltipWhenOverflow?: boolean;
|
|
963
|
+
};
|
|
964
|
+
fontSize?: number | string;
|
|
965
|
+
italic?: boolean;
|
|
966
|
+
/**
|
|
967
|
+
* Clamp lines with CSS line-clamp.
|
|
968
|
+
*
|
|
969
|
+
* Note: When `ellipsis` is provided, `ellipsis` takes precedence.
|
|
970
|
+
*/
|
|
971
|
+
lineClamp?: number;
|
|
972
|
+
lineHeight?: CSSProperties['lineHeight'];
|
|
973
|
+
mark?: boolean;
|
|
974
|
+
/**
|
|
975
|
+
* Whether to disable wrapping (set `white-space: nowrap`).
|
|
976
|
+
*
|
|
977
|
+
* Note: When multi-line ellipsis is enabled, it will be ignored.
|
|
978
|
+
*/
|
|
979
|
+
noWrap?: boolean;
|
|
980
|
+
ref?: Ref<HTMLDivElement>;
|
|
981
|
+
strong?: boolean;
|
|
982
|
+
textDecoration?: CSSProperties['textDecoration'];
|
|
983
|
+
textTransform?: CSSProperties['textTransform'];
|
|
984
|
+
type?: 'secondary' | 'success' | 'warning' | 'danger' | 'info';
|
|
985
|
+
underline?: boolean;
|
|
986
|
+
weight?: 'bold' | 'bolder' | number;
|
|
987
|
+
whiteSpace?: CSSProperties['whiteSpace'];
|
|
988
|
+
wordBreak?: CSSProperties['wordBreak'];
|
|
989
|
+
}
|
|
990
|
+
|
|
991
|
+
declare const Text: FC<TextProps>;
|
|
992
|
+
|
|
993
|
+
interface CheckboxProps extends Omit<DivProps, 'onChange'> {
|
|
994
|
+
backgroundColor?: string;
|
|
995
|
+
checked?: boolean;
|
|
996
|
+
classNames?: {
|
|
997
|
+
checkbox?: string;
|
|
998
|
+
text?: string;
|
|
999
|
+
wrapper?: string;
|
|
1000
|
+
};
|
|
1001
|
+
defaultChecked?: boolean;
|
|
1002
|
+
disabled?: boolean;
|
|
1003
|
+
indeterminate?: boolean;
|
|
1004
|
+
onChange?: (checked: boolean) => void;
|
|
1005
|
+
shape?: 'square' | 'circle';
|
|
1006
|
+
size?: number;
|
|
1007
|
+
styles?: {
|
|
1008
|
+
checkbox?: CSSProperties;
|
|
1009
|
+
text?: CSSProperties;
|
|
1010
|
+
wrapper?: CSSProperties;
|
|
1011
|
+
};
|
|
1012
|
+
textProps?: Omit<TextProps, 'children' | 'className' | 'style'>;
|
|
1013
|
+
}
|
|
1014
|
+
interface CheckboxGroupOption {
|
|
1015
|
+
disabled?: boolean;
|
|
1016
|
+
label: ReactNode;
|
|
1017
|
+
value: string;
|
|
1018
|
+
}
|
|
1019
|
+
interface CheckboxGroupProps extends Omit<FlexProps, 'defaultValue' | 'onChange'> {
|
|
1020
|
+
defaultValue?: string[];
|
|
1021
|
+
disabled?: boolean;
|
|
1022
|
+
onChange?: (value: string[]) => void;
|
|
1023
|
+
options: string[] | CheckboxGroupOption[];
|
|
1024
|
+
shape?: 'square' | 'circle';
|
|
1025
|
+
size?: number;
|
|
1026
|
+
textProps?: Omit<TextProps, 'children' | 'className' | 'style'>;
|
|
1027
|
+
value?: string[];
|
|
1028
|
+
}
|
|
1029
|
+
|
|
1030
|
+
declare const CheckboxGroup: FC<CheckboxGroupProps>;
|
|
1031
|
+
|
|
1032
|
+
interface ICheckbox {
|
|
1033
|
+
(props: CheckboxProps & RefAttributes<HTMLDivElement>): ReactNode;
|
|
1034
|
+
Group: typeof CheckboxGroup;
|
|
1035
|
+
}
|
|
1036
|
+
declare const Checkbox: ICheckbox;
|
|
1037
|
+
|
|
1038
|
+
type DiffViewMode = 'split' | 'unified';
|
|
1039
|
+
interface CodeDiffProps extends Omit<FlexProps, 'children'> {
|
|
1040
|
+
/**
|
|
1041
|
+
* Actions to render in the header
|
|
1042
|
+
*/
|
|
1043
|
+
actionsRender?: (props: {
|
|
1044
|
+
newContent: string;
|
|
1045
|
+
oldContent: string;
|
|
1046
|
+
originalNode: ReactNode;
|
|
1047
|
+
}) => ReactNode;
|
|
1048
|
+
/**
|
|
1049
|
+
* Custom class names for different parts
|
|
1050
|
+
*/
|
|
1051
|
+
classNames?: {
|
|
1052
|
+
body?: string;
|
|
1053
|
+
header?: string;
|
|
1054
|
+
};
|
|
1055
|
+
/**
|
|
1056
|
+
* Options for the diff component
|
|
1057
|
+
*/
|
|
1058
|
+
diffOptions?: FileDiffOptions<string>;
|
|
1059
|
+
/**
|
|
1060
|
+
* File name to display
|
|
1061
|
+
*/
|
|
1062
|
+
fileName?: string;
|
|
1063
|
+
/**
|
|
1064
|
+
* Programming language for syntax highlighting
|
|
1065
|
+
*/
|
|
1066
|
+
language?: string;
|
|
1067
|
+
/**
|
|
1068
|
+
* New content (after changes)
|
|
1069
|
+
*/
|
|
1070
|
+
newContent: string;
|
|
1071
|
+
/**
|
|
1072
|
+
* Old content (before changes)
|
|
1073
|
+
*/
|
|
1074
|
+
oldContent: string;
|
|
1075
|
+
/**
|
|
1076
|
+
* Whether to show file header
|
|
1077
|
+
* @default true
|
|
1078
|
+
*/
|
|
1079
|
+
showHeader?: boolean;
|
|
1080
|
+
/**
|
|
1081
|
+
* Custom styles for different parts
|
|
1082
|
+
*/
|
|
1083
|
+
styles?: {
|
|
1084
|
+
body?: CSSProperties;
|
|
1085
|
+
header?: CSSProperties;
|
|
1086
|
+
};
|
|
1087
|
+
/**
|
|
1088
|
+
* Visual variant
|
|
1089
|
+
* @default 'filled'
|
|
1090
|
+
*/
|
|
1091
|
+
variant?: 'filled' | 'outlined' | 'borderless';
|
|
1092
|
+
/**
|
|
1093
|
+
* View mode for diff display
|
|
1094
|
+
* @default 'split'
|
|
1095
|
+
*/
|
|
1096
|
+
viewMode?: DiffViewMode;
|
|
1097
|
+
}
|
|
1098
|
+
interface PatchDiffProps extends Omit<FlexProps, 'children'> {
|
|
1099
|
+
/**
|
|
1100
|
+
* Actions to render in the header
|
|
1101
|
+
*/
|
|
1102
|
+
actionsRender?: (props: {
|
|
1103
|
+
originalNode: ReactNode;
|
|
1104
|
+
patch: string;
|
|
1105
|
+
}) => ReactNode;
|
|
1106
|
+
/**
|
|
1107
|
+
* Custom class names for different parts
|
|
1108
|
+
*/
|
|
1109
|
+
classNames?: {
|
|
1110
|
+
body?: string;
|
|
1111
|
+
header?: string;
|
|
1112
|
+
};
|
|
1113
|
+
/**
|
|
1114
|
+
* Options for the diff component
|
|
1115
|
+
*/
|
|
1116
|
+
diffOptions?: FileDiffOptions<string>;
|
|
1117
|
+
/**
|
|
1118
|
+
* File name to display (optional, extracted from patch if not provided)
|
|
1119
|
+
*/
|
|
1120
|
+
fileName?: string;
|
|
1121
|
+
/**
|
|
1122
|
+
* Programming language for syntax highlighting
|
|
1123
|
+
*/
|
|
1124
|
+
language?: string;
|
|
1125
|
+
/**
|
|
1126
|
+
* Unified diff patch string
|
|
1127
|
+
*/
|
|
1128
|
+
patch: string;
|
|
1129
|
+
/**
|
|
1130
|
+
* Whether to show file header
|
|
1131
|
+
* @default true
|
|
1132
|
+
*/
|
|
1133
|
+
showHeader?: boolean;
|
|
1134
|
+
/**
|
|
1135
|
+
* Custom styles for different parts
|
|
1136
|
+
*/
|
|
1137
|
+
styles?: {
|
|
1138
|
+
body?: CSSProperties;
|
|
1139
|
+
header?: CSSProperties;
|
|
1140
|
+
};
|
|
1141
|
+
/**
|
|
1142
|
+
* Visual variant
|
|
1143
|
+
* @default 'filled'
|
|
1144
|
+
*/
|
|
1145
|
+
variant?: 'filled' | 'outlined' | 'borderless';
|
|
1146
|
+
/**
|
|
1147
|
+
* View mode for diff display
|
|
1148
|
+
* @default 'split'
|
|
1149
|
+
*/
|
|
1150
|
+
viewMode?: DiffViewMode;
|
|
1151
|
+
}
|
|
1152
|
+
|
|
1153
|
+
declare const CodeDiff: react.NamedExoticComponent<CodeDiffProps>;
|
|
1154
|
+
|
|
1155
|
+
declare const PatchDiff: react.NamedExoticComponent<PatchDiffProps>;
|
|
1156
|
+
|
|
1157
|
+
interface CodeEditorProps extends TextAreaProps$1, Pick<FlexProps, 'width' | 'height' | 'flex'> {
|
|
1158
|
+
classNames?: {
|
|
1159
|
+
highlight?: string;
|
|
1160
|
+
textarea?: string;
|
|
1161
|
+
};
|
|
1162
|
+
defaultValue?: string;
|
|
1163
|
+
language: string;
|
|
1164
|
+
onValueChange: (value: string) => void;
|
|
1165
|
+
placeholder?: string;
|
|
1166
|
+
ref?: Ref<HTMLTextAreaElement>;
|
|
1167
|
+
style?: CSSProperties;
|
|
1168
|
+
styles?: {
|
|
1169
|
+
highlight?: CSSProperties;
|
|
1170
|
+
textarea?: CSSProperties;
|
|
1171
|
+
};
|
|
1172
|
+
value: string;
|
|
1173
|
+
variant?: 'filled' | 'outlined' | 'borderless';
|
|
1174
|
+
}
|
|
1175
|
+
|
|
1176
|
+
declare const CodeEditor: react.NamedExoticComponent<CodeEditorProps>;
|
|
1177
|
+
|
|
1178
|
+
interface CollapseItemType extends ItemType$1 {
|
|
1179
|
+
desc?: ReactNode;
|
|
1180
|
+
icon?: IconProps$1['icon'];
|
|
1181
|
+
}
|
|
1182
|
+
interface CollapseProps extends Omit<CollapseProps$1, 'collapsible' | 'ghost' | 'items'> {
|
|
1183
|
+
classNames?: {
|
|
1184
|
+
desc?: string;
|
|
1185
|
+
header?: string;
|
|
1186
|
+
title?: string;
|
|
1187
|
+
};
|
|
1188
|
+
collapsible?: boolean;
|
|
1189
|
+
gap?: number;
|
|
1190
|
+
items: CollapseItemType[];
|
|
1191
|
+
padding?: number | string | {
|
|
1192
|
+
body?: number | string;
|
|
1193
|
+
header?: number | string;
|
|
1194
|
+
};
|
|
1195
|
+
ref?: Ref<HTMLDivElement>;
|
|
1196
|
+
styles?: {
|
|
1197
|
+
desc?: CSSProperties;
|
|
1198
|
+
header?: CSSProperties;
|
|
1199
|
+
title?: CSSProperties;
|
|
1200
|
+
};
|
|
1201
|
+
variant?: 'filled' | 'outlined' | 'borderless';
|
|
1202
|
+
}
|
|
1203
|
+
|
|
1204
|
+
declare const Collapse: react.NamedExoticComponent<CollapseProps>;
|
|
1205
|
+
|
|
1206
|
+
interface ColorSwatchesItemType {
|
|
1207
|
+
color: string;
|
|
1208
|
+
key?: Key;
|
|
1209
|
+
title?: ReactNode;
|
|
1210
|
+
}
|
|
1211
|
+
interface ColorSwatchesProps extends Omit<FlexProps, 'onChange'> {
|
|
1212
|
+
colors: ColorSwatchesItemType[];
|
|
1213
|
+
defaultValue?: string;
|
|
1214
|
+
enableColorPicker?: boolean;
|
|
1215
|
+
enableColorSwatches?: boolean;
|
|
1216
|
+
onChange?: (color?: string) => void;
|
|
1217
|
+
ref?: Ref<HTMLDivElement>;
|
|
1218
|
+
shape?: 'circle' | 'square';
|
|
1219
|
+
size?: number;
|
|
1220
|
+
texts?: {
|
|
1221
|
+
custom: string;
|
|
1222
|
+
presets: string;
|
|
1223
|
+
};
|
|
1224
|
+
value?: string;
|
|
1225
|
+
}
|
|
1226
|
+
|
|
1227
|
+
declare const ColorSwatches: FC<ColorSwatchesProps>;
|
|
1228
|
+
|
|
1229
|
+
type MotionComponentType = typeof motion_react.motion | typeof m;
|
|
1230
|
+
declare const MotionComponent: Context<MotionComponentType>;
|
|
1231
|
+
declare const MotionProvider: react.NamedExoticComponent<{
|
|
1232
|
+
children: ReactNode;
|
|
1233
|
+
motion: MotionComponentType;
|
|
1234
|
+
}>;
|
|
1235
|
+
declare const useMotionComponent: () => MotionComponentType;
|
|
1236
|
+
|
|
1237
|
+
declare const _default$8: {
|
|
1238
|
+
readonly 'sideNav.collapse': "Collapse sidebar";
|
|
1239
|
+
readonly 'sideNav.demoActiveLabel': "Active";
|
|
1240
|
+
readonly 'sideNav.demoFeatureAutoCollapseDesc': "Drag below threshold for smart collapse";
|
|
1241
|
+
readonly 'sideNav.demoFeatureAutoCollapseTitle': "Auto-collapse";
|
|
1242
|
+
readonly 'sideNav.demoFeaturePerformanceDesc': "No animation overhead for better performance";
|
|
1243
|
+
readonly 'sideNav.demoFeaturePerformanceTitle': "Performance";
|
|
1244
|
+
readonly 'sideNav.demoFeatureResizeDesc': "Drag to adjust panel width";
|
|
1245
|
+
readonly 'sideNav.demoFeatureResizeTitle': "Flexible Resize";
|
|
1246
|
+
readonly 'sideNav.demoFeatureSmartHandleDesc': "Hover to reveal toggle button";
|
|
1247
|
+
readonly 'sideNav.demoFeatureSmartHandleTitle': "Smart Handle";
|
|
1248
|
+
readonly 'sideNav.demoFeaturesTitle': "Features";
|
|
1249
|
+
readonly 'sideNav.demoHint': "Try dragging the panel edge and using the toggle button ->";
|
|
1250
|
+
readonly 'sideNav.demoSubtitle': "A workspace-style side panel with draggable resize";
|
|
1251
|
+
readonly 'sideNav.demoTitle': "DraggableSideNav Demo";
|
|
1252
|
+
readonly 'sideNav.expand': "Expand sidebar";
|
|
1253
|
+
};
|
|
1254
|
+
|
|
1255
|
+
declare const _default$7: {
|
|
1256
|
+
readonly 'messageModal.cancel': "Cancel";
|
|
1257
|
+
readonly 'messageModal.confirm': "Confirm";
|
|
1258
|
+
readonly 'messageModal.edit': "Edit";
|
|
1259
|
+
};
|
|
1260
|
+
|
|
1261
|
+
declare const _default$6: {
|
|
1262
|
+
readonly 'hotkey.conflict': "This shortcut conflicts with an existing one.";
|
|
1263
|
+
readonly 'hotkey.invalidCombination': "Shortcut must include a modifier key (Ctrl, Alt, Shift) and only one regular key.";
|
|
1264
|
+
readonly 'hotkey.placeholder': "Press keys to record shortcut";
|
|
1265
|
+
readonly 'hotkey.reset': "Reset to default";
|
|
1266
|
+
};
|
|
1267
|
+
|
|
1268
|
+
declare const _default$5: {
|
|
1269
|
+
readonly 'form.reset': "Reset";
|
|
1270
|
+
readonly 'form.submit': "Submit";
|
|
1271
|
+
readonly 'form.unsavedChanges': "Unsaved changes";
|
|
1272
|
+
readonly 'form.unsavedWarning': "You have unsaved changes. Are you sure you want to leave?";
|
|
1273
|
+
};
|
|
1274
|
+
|
|
1275
|
+
declare const _default$4: {
|
|
1276
|
+
readonly 'emojiPicker.delete': "Delete";
|
|
1277
|
+
readonly 'emojiPicker.draggerDesc': "Click or Drag image to this area to upload";
|
|
1278
|
+
readonly 'emojiPicker.emoji': "Emoji";
|
|
1279
|
+
readonly 'emojiPicker.fileTypeError': "You can only upload image file!";
|
|
1280
|
+
readonly 'emojiPicker.upload': "Upload";
|
|
1281
|
+
readonly 'emojiPicker.uploadBtn': "Crop and Upload";
|
|
1282
|
+
};
|
|
1283
|
+
|
|
1284
|
+
declare const _default$3: {
|
|
1285
|
+
readonly 'editableMessage.addProps': "Add Props";
|
|
1286
|
+
readonly 'editableMessage.delete': "Delete";
|
|
1287
|
+
readonly 'editableMessage.input': "Input";
|
|
1288
|
+
readonly 'editableMessage.inputPlaceholder': "Please enter sample input content";
|
|
1289
|
+
readonly 'editableMessage.output': "Output";
|
|
1290
|
+
readonly 'editableMessage.outputPlaceholder': "Please enter sample output content";
|
|
1291
|
+
readonly 'editableMessage.system': "System";
|
|
1292
|
+
};
|
|
1293
|
+
|
|
1294
|
+
declare const _default$2: {
|
|
1295
|
+
readonly 'common.cancel': "Cancel";
|
|
1296
|
+
readonly 'common.confirm': "Confirm";
|
|
1297
|
+
readonly 'common.delete': "Delete";
|
|
1298
|
+
readonly 'common.edit': "Edit";
|
|
1299
|
+
readonly 'common.empty': "(empty)";
|
|
1300
|
+
};
|
|
1301
|
+
|
|
1302
|
+
declare const _default$1: {
|
|
1303
|
+
readonly 'chat.avatar': "avatar";
|
|
1304
|
+
readonly 'chat.placeholder': "...";
|
|
1305
|
+
readonly 'tokenTag.overload': "Overload";
|
|
1306
|
+
readonly 'tokenTag.remained': "Remained";
|
|
1307
|
+
readonly 'tokenTag.used': "Used";
|
|
1308
|
+
};
|
|
1309
|
+
|
|
1310
|
+
type BuiltinTranslationResources = typeof _default$1 & typeof _default$2 & typeof _default$3 & typeof _default$4 & typeof _default$5 & typeof _default$6 & typeof _default$7 & typeof _default$8;
|
|
1311
|
+
type TranslationKey = keyof BuiltinTranslationResources;
|
|
1312
|
+
type TranslationValue = string;
|
|
1313
|
+
/**
|
|
1314
|
+
* A (partial) dictionary of translations.
|
|
1315
|
+
*
|
|
1316
|
+
* Note: it's intentionally Partial so feature-level modules can pass only their own keys as
|
|
1317
|
+
* fallback resources (e.g. `useTranslation(editableMessageMessages)`).
|
|
1318
|
+
*/
|
|
1319
|
+
type TranslationResources = Partial<Record<TranslationKey, TranslationValue>>;
|
|
1320
|
+
type TranslationResourcesMap = TranslationResources[] | Record<string, TranslationResources>;
|
|
1321
|
+
type TranslationResourcesInput = TranslationResourcesMap | Promise<TranslationResourcesMap>;
|
|
1322
|
+
|
|
1323
|
+
type CDN = 'aliyun' | 'unpkg';
|
|
1324
|
+
interface CdnApi {
|
|
1325
|
+
path: string;
|
|
1326
|
+
pkg: string;
|
|
1327
|
+
proxy?: CDN;
|
|
1328
|
+
version?: string;
|
|
1329
|
+
}
|
|
1330
|
+
declare const genCdnUrl: ({ pkg, version, path, proxy }: CdnApi) => string;
|
|
1331
|
+
|
|
1332
|
+
interface Config {
|
|
1333
|
+
aAs?: ElementType;
|
|
1334
|
+
customCdnFn?: CdnFn;
|
|
1335
|
+
imgAs?: ElementType;
|
|
1336
|
+
imgUnoptimized?: boolean;
|
|
1337
|
+
proxy?: CDN | 'custom';
|
|
1338
|
+
}
|
|
1339
|
+
interface ConfigProviderProps {
|
|
1340
|
+
children: ReactNode;
|
|
1341
|
+
config?: Config;
|
|
1342
|
+
locale?: string;
|
|
1343
|
+
motion: MotionComponentType;
|
|
1344
|
+
resources?: TranslationResourcesInput;
|
|
1345
|
+
}
|
|
1346
|
+
declare const ConfigProvider: react.NamedExoticComponent<ConfigProviderProps>;
|
|
1347
|
+
type CdnFn = ({ pkg, version, path }: CdnApi) => string;
|
|
1348
|
+
declare const useCdnFn: () => CdnFn;
|
|
1349
|
+
|
|
1350
|
+
type ContextMenuCheckboxItem = MenuCheckboxItemType;
|
|
1351
|
+
type ContextMenuItem = BaseMenuItemType;
|
|
1352
|
+
|
|
1353
|
+
type ContextMenuTriggerProps = {
|
|
1354
|
+
children: ReactNode;
|
|
1355
|
+
/**
|
|
1356
|
+
* Menu items to display. Supports lazy rendering via function.
|
|
1357
|
+
* When provided, context menu will be automatically shown on right-click.
|
|
1358
|
+
*/
|
|
1359
|
+
items?: ContextMenuItem[] | (() => ContextMenuItem[]);
|
|
1360
|
+
/**
|
|
1361
|
+
* Custom context menu handler. If `items` is provided, this is optional.
|
|
1362
|
+
*/
|
|
1363
|
+
onContextMenu?: (event: MouseEvent<HTMLElement>) => void;
|
|
1364
|
+
} & Omit<HTMLAttributes<HTMLElement>, 'onContextMenu' | 'children'>;
|
|
1365
|
+
declare const ContextMenuTrigger: react__default.NamedExoticComponent<ContextMenuTriggerProps>;
|
|
1366
|
+
|
|
1367
|
+
declare const ContextMenuHost: react.MemoExoticComponent<() => react_jsx_runtime.JSX.Element | null>;
|
|
1368
|
+
|
|
1369
|
+
interface ShowContextMenuOptions {
|
|
1370
|
+
iconSpaceMode?: IconSpaceMode;
|
|
1371
|
+
}
|
|
1372
|
+
declare const showContextMenu: (items: ContextMenuItem[], options?: ShowContextMenuOptions) => void;
|
|
1373
|
+
/**
|
|
1374
|
+
* Update menu items while keeping current anchor/position.
|
|
1375
|
+
* Useful for interactive menu items (e.g. checkbox) to avoid re-positioning.
|
|
1376
|
+
*/
|
|
1377
|
+
declare const updateContextMenuItems: (items: ContextMenuItem[]) => void;
|
|
1378
|
+
declare const closeContextMenu: () => void;
|
|
1379
|
+
|
|
1380
|
+
interface CopyButtonProps extends Omit<ActionIconProps, 'content'> {
|
|
1381
|
+
content: string | (() => string);
|
|
1382
|
+
}
|
|
1383
|
+
|
|
1384
|
+
declare const CopyButton: react.NamedExoticComponent<CopyButtonProps>;
|
|
1385
|
+
|
|
1386
|
+
interface DatePickerProps extends DatePickerProps$1 {
|
|
1387
|
+
shadow?: boolean;
|
|
1388
|
+
/**
|
|
1389
|
+
* Force mobile drawer / wheel UI when true; otherwise uses ThemeProvider context.
|
|
1390
|
+
*/
|
|
1391
|
+
isMobile?: boolean;
|
|
1392
|
+
/**
|
|
1393
|
+
* Lower bound for selectable dates (inclusive).
|
|
1394
|
+
*/
|
|
1395
|
+
min?: ConfigType;
|
|
1396
|
+
/**
|
|
1397
|
+
* Upper bound for selectable dates (inclusive).
|
|
1398
|
+
*/
|
|
1399
|
+
max?: ConfigType;
|
|
1400
|
+
/**
|
|
1401
|
+
* Show years in ascending order instead of the default descending order.
|
|
1402
|
+
*/
|
|
1403
|
+
revertYear?: boolean;
|
|
1404
|
+
}
|
|
1405
|
+
|
|
1406
|
+
declare const DatePicker: react.NamedExoticComponent<DatePickerProps>;
|
|
1407
|
+
|
|
1408
|
+
interface DownloadButtonProps extends ActionIconProps {
|
|
1409
|
+
blobUrl?: string;
|
|
1410
|
+
fileName?: string;
|
|
1411
|
+
fileType?: string;
|
|
1412
|
+
}
|
|
1413
|
+
|
|
1414
|
+
declare const DownloadButton: react__default.NamedExoticComponent<DownloadButtonProps>;
|
|
1415
|
+
|
|
1416
|
+
interface InputProps extends InputProps$1 {
|
|
1417
|
+
ref?: Ref<InputRef>;
|
|
1418
|
+
shadow?: boolean;
|
|
1419
|
+
}
|
|
1420
|
+
interface TextAreaProps extends TextAreaProps$2 {
|
|
1421
|
+
ref?: Ref<TextAreaRef>;
|
|
1422
|
+
resize?: boolean;
|
|
1423
|
+
shadow?: boolean;
|
|
1424
|
+
}
|
|
1425
|
+
interface InputNumberProps extends InputNumberProps$1 {
|
|
1426
|
+
ref?: Ref<InputNumberRef>;
|
|
1427
|
+
shadow?: boolean;
|
|
1428
|
+
}
|
|
1429
|
+
interface InputPasswordProps extends PasswordProps {
|
|
1430
|
+
ref?: Ref<InputRef>;
|
|
1431
|
+
shadow?: boolean;
|
|
1432
|
+
}
|
|
1433
|
+
interface InputOPTProps extends OTPProps {
|
|
1434
|
+
ref?: Ref<OTPRef>;
|
|
1435
|
+
shadow?: boolean;
|
|
1436
|
+
}
|
|
1437
|
+
interface InputMaskProps extends InputProps$1 {
|
|
1438
|
+
ref?: Ref<InputRef>;
|
|
1439
|
+
shadow?: boolean;
|
|
1440
|
+
mask: NonNullable<Inputmask.Options['mask']>;
|
|
1441
|
+
maskChar?: string | null;
|
|
1442
|
+
maskPlaceholder?: string | null;
|
|
1443
|
+
alwaysShowMask?: boolean;
|
|
1444
|
+
}
|
|
1445
|
+
|
|
1446
|
+
type SelectSize = 'large' | 'middle' | 'small';
|
|
1447
|
+
type SelectVariant = 'borderless' | 'filled' | 'outlined';
|
|
1448
|
+
type SelectBehaviorVariant = 'default' | 'item-aligned';
|
|
1449
|
+
/**
|
|
1450
|
+
* Variant for how selected items are indicated in the popup.
|
|
1451
|
+
* - `check`: Display a checkmark icon next to selected items (default)
|
|
1452
|
+
* - `bold`: Display selected items with bold text, no checkmark
|
|
1453
|
+
*/
|
|
1454
|
+
type SelectIndicatorVariant = 'check' | 'bold';
|
|
1455
|
+
interface SelectOption<Value = string> {
|
|
1456
|
+
className?: string;
|
|
1457
|
+
disabled?: boolean;
|
|
1458
|
+
label: ReactNode;
|
|
1459
|
+
style?: CSSProperties;
|
|
1460
|
+
title?: string;
|
|
1461
|
+
value: Value;
|
|
1462
|
+
}
|
|
1463
|
+
interface SelectOptionGroup<Value = string> {
|
|
1464
|
+
disabled?: boolean;
|
|
1465
|
+
label: ReactNode;
|
|
1466
|
+
options: SelectOption<Value>[];
|
|
1467
|
+
}
|
|
1468
|
+
type SelectOptions<Value = string> = Array<SelectOption<Value> | SelectOptionGroup<Value>>;
|
|
1469
|
+
interface SelectClassNames {
|
|
1470
|
+
clear?: string;
|
|
1471
|
+
dropdown?: string;
|
|
1472
|
+
empty?: string;
|
|
1473
|
+
group?: string;
|
|
1474
|
+
groupLabel?: string;
|
|
1475
|
+
icon?: string;
|
|
1476
|
+
item?: string;
|
|
1477
|
+
itemIndicator?: string;
|
|
1478
|
+
itemText?: string;
|
|
1479
|
+
list?: string;
|
|
1480
|
+
mobileClose?: string;
|
|
1481
|
+
mobileContent?: string;
|
|
1482
|
+
mobileGroupLabel?: string;
|
|
1483
|
+
mobileHeader?: string;
|
|
1484
|
+
mobileList?: string;
|
|
1485
|
+
mobileOverlay?: string;
|
|
1486
|
+
mobileOption?: string;
|
|
1487
|
+
mobileOptionCheck?: string;
|
|
1488
|
+
mobileOptionLabel?: string;
|
|
1489
|
+
mobileOptionSelected?: string;
|
|
1490
|
+
mobileSheet?: string;
|
|
1491
|
+
mobileTitle?: string;
|
|
1492
|
+
option?: string;
|
|
1493
|
+
popup?: string;
|
|
1494
|
+
prefix?: string;
|
|
1495
|
+
root?: string;
|
|
1496
|
+
search?: string;
|
|
1497
|
+
suffix?: string;
|
|
1498
|
+
trigger?: string;
|
|
1499
|
+
value?: string;
|
|
1500
|
+
}
|
|
1501
|
+
interface SelectProps<Value = string> {
|
|
1502
|
+
allowClear?: boolean;
|
|
1503
|
+
autoFocus?: boolean;
|
|
1504
|
+
/**
|
|
1505
|
+
* Behavior variant for Base UI Select.
|
|
1506
|
+
*
|
|
1507
|
+
* - `default`: regular dropdown positioning (alignItemWithTrigger=false, modal=false)
|
|
1508
|
+
* - `item-aligned`: aligns the selected item with trigger and uses modal=true
|
|
1509
|
+
* @default 'default'
|
|
1510
|
+
*/
|
|
1511
|
+
behaviorVariant?: SelectBehaviorVariant;
|
|
1512
|
+
className?: string;
|
|
1513
|
+
classNames?: SelectClassNames;
|
|
1514
|
+
defaultOpen?: boolean;
|
|
1515
|
+
defaultValue?: Value | Value[] | null;
|
|
1516
|
+
disabled?: boolean;
|
|
1517
|
+
id?: string;
|
|
1518
|
+
/**
|
|
1519
|
+
* When true, uses a mobile drawer picker (recommended for touch devices).
|
|
1520
|
+
* @default false
|
|
1521
|
+
*/
|
|
1522
|
+
isMobile?: boolean;
|
|
1523
|
+
labelRender?: (option: SelectOption<Value>) => ReactNode;
|
|
1524
|
+
/**
|
|
1525
|
+
* 设置弹窗滚动高度
|
|
1526
|
+
* @default 256
|
|
1527
|
+
*/
|
|
1528
|
+
listHeight?: number;
|
|
1529
|
+
listItemHeight?: number;
|
|
1530
|
+
loading?: boolean;
|
|
1531
|
+
mode?: 'multiple' | 'tags';
|
|
1532
|
+
name?: string;
|
|
1533
|
+
onChange?: (value: Value | Value[] | null, option?: SelectOption<Value> | SelectOption<Value>[]) => void;
|
|
1534
|
+
onOpenChange?: (open: boolean) => void;
|
|
1535
|
+
onSelect?: (value: Value, option?: SelectOption<Value>) => void;
|
|
1536
|
+
open?: boolean;
|
|
1537
|
+
optionRender?: (option: SelectOption<Value>, info: {
|
|
1538
|
+
index: number;
|
|
1539
|
+
}) => ReactNode;
|
|
1540
|
+
options?: SelectOptions<Value>;
|
|
1541
|
+
placeholder?: ReactNode;
|
|
1542
|
+
popupClassName?: string;
|
|
1543
|
+
popupMatchSelectWidth?: boolean | number;
|
|
1544
|
+
prefix?: ReactNode | IconProps$1['icon'];
|
|
1545
|
+
readOnly?: boolean;
|
|
1546
|
+
required?: boolean;
|
|
1547
|
+
/**
|
|
1548
|
+
* Variant for how selected items are indicated in the popup.
|
|
1549
|
+
* - `check`: Display a checkmark icon next to selected items (default)
|
|
1550
|
+
* - `bold`: Display selected items with bold text, no checkmark
|
|
1551
|
+
* @default 'check'
|
|
1552
|
+
*/
|
|
1553
|
+
selectedIndicatorVariant?: SelectIndicatorVariant;
|
|
1554
|
+
shadow?: boolean;
|
|
1555
|
+
showSearch?: boolean;
|
|
1556
|
+
size?: SelectSize;
|
|
1557
|
+
style?: CSSProperties;
|
|
1558
|
+
styles?: {
|
|
1559
|
+
popup?: {
|
|
1560
|
+
root?: CSSProperties;
|
|
1561
|
+
};
|
|
1562
|
+
};
|
|
1563
|
+
suffixIcon?: IconProps$1['icon'] | ReactNode;
|
|
1564
|
+
suffixIconProps?: Omit<IconProps$1, 'icon'>;
|
|
1565
|
+
tokenSeparators?: string[];
|
|
1566
|
+
value?: Value | Value[] | null;
|
|
1567
|
+
variant?: SelectVariant;
|
|
1568
|
+
virtual?: boolean;
|
|
1569
|
+
}
|
|
1570
|
+
|
|
1571
|
+
type Meridiem = 'AM' | 'PM';
|
|
1572
|
+
type TimeValue = {
|
|
1573
|
+
hour: number;
|
|
1574
|
+
minute: number;
|
|
1575
|
+
};
|
|
1576
|
+
interface TimePickerProps extends Omit<InputProps, 'defaultValue' | 'onChange' | 'type' | 'value' | 'size' | 'status' | 'addonAfter' | 'addonBefore' | 'suffix'> {
|
|
1577
|
+
allowClear?: boolean;
|
|
1578
|
+
className?: string;
|
|
1579
|
+
defaultOpen?: boolean;
|
|
1580
|
+
defaultValue?: string | null;
|
|
1581
|
+
format?: string | ((value: TimeValue | null) => string);
|
|
1582
|
+
hourStep?: number;
|
|
1583
|
+
/**
|
|
1584
|
+
* Force mobile drawer / wheel UI when true; otherwise uses ThemeProvider context.
|
|
1585
|
+
*/
|
|
1586
|
+
isMobile?: boolean;
|
|
1587
|
+
inputReadOnly?: boolean;
|
|
1588
|
+
minuteStep?: number;
|
|
1589
|
+
onChange?: (value: string | null, formatted: string) => void;
|
|
1590
|
+
onOpenChange?: (open: boolean) => void;
|
|
1591
|
+
open?: boolean;
|
|
1592
|
+
placeholder?: string;
|
|
1593
|
+
size?: SelectSize;
|
|
1594
|
+
style?: CSSProperties;
|
|
1595
|
+
use12Hours?: boolean;
|
|
1596
|
+
value?: string | null;
|
|
1597
|
+
}
|
|
1598
|
+
|
|
1599
|
+
declare const TimePicker: react.NamedExoticComponent<TimePickerProps>;
|
|
1600
|
+
|
|
1601
|
+
type DraggablePanelBodyProps = DivProps;
|
|
1602
|
+
declare const DraggablePanelBody: react.NamedExoticComponent<DivProps>;
|
|
1603
|
+
|
|
1604
|
+
type DraggablePanelContainerProps = DivProps;
|
|
1605
|
+
declare const DraggablePanelContainer: react.NamedExoticComponent<DivProps>;
|
|
1606
|
+
|
|
1607
|
+
type DraggablePanelFooterProps = DivProps;
|
|
1608
|
+
declare const DraggablePanelFooter: react.NamedExoticComponent<DivProps>;
|
|
1609
|
+
|
|
1610
|
+
interface DraggablePanelHeaderProps extends Omit<DivProps, 'children'> {
|
|
1611
|
+
pin?: boolean;
|
|
1612
|
+
position?: 'left' | 'right';
|
|
1613
|
+
setExpand?: (expand: boolean) => void;
|
|
1614
|
+
setPin?: (pin: boolean) => void;
|
|
1615
|
+
title?: string;
|
|
1616
|
+
}
|
|
1617
|
+
declare const DraggablePanelHeader: react.NamedExoticComponent<DraggablePanelHeaderProps>;
|
|
1618
|
+
|
|
1619
|
+
type PlacementType = 'right' | 'left' | 'top' | 'bottom';
|
|
1620
|
+
interface DraggablePanelProps extends DivProps {
|
|
1621
|
+
backgroundColor?: string;
|
|
1622
|
+
classNames?: {
|
|
1623
|
+
content?: string;
|
|
1624
|
+
handle?: string;
|
|
1625
|
+
};
|
|
1626
|
+
defaultExpand?: boolean;
|
|
1627
|
+
defaultSize?: Partial<Size>;
|
|
1628
|
+
destroyOnClose?: boolean;
|
|
1629
|
+
expand?: boolean;
|
|
1630
|
+
expandable?: boolean;
|
|
1631
|
+
fullscreen?: boolean;
|
|
1632
|
+
headerHeight?: number;
|
|
1633
|
+
maxHeight?: number;
|
|
1634
|
+
maxWidth?: number;
|
|
1635
|
+
minHeight?: number;
|
|
1636
|
+
minWidth?: number;
|
|
1637
|
+
mode?: 'fixed' | 'float';
|
|
1638
|
+
onExpandChange?: (expand: boolean) => void;
|
|
1639
|
+
onSizeChange?: (delta: NumberSize, size?: Size) => void;
|
|
1640
|
+
onSizeDragging?: (delta: NumberSize, size?: Size) => void;
|
|
1641
|
+
pin?: boolean;
|
|
1642
|
+
placement: PlacementType;
|
|
1643
|
+
resize?: Props$1['enableResizing'];
|
|
1644
|
+
/**
|
|
1645
|
+
* Whether to show border
|
|
1646
|
+
* @default true
|
|
1647
|
+
*/
|
|
1648
|
+
showBorder?: boolean;
|
|
1649
|
+
showHandleHighlight?: boolean;
|
|
1650
|
+
showHandleWhenCollapsed?: boolean;
|
|
1651
|
+
showHandleWideArea?: boolean;
|
|
1652
|
+
size?: Partial<Size>;
|
|
1653
|
+
styles?: {
|
|
1654
|
+
content?: CSSProperties;
|
|
1655
|
+
handle?: CSSProperties;
|
|
1656
|
+
};
|
|
1657
|
+
}
|
|
1658
|
+
|
|
1659
|
+
interface IDraggablePanel {
|
|
1660
|
+
(props: DraggablePanelProps & RefAttributes<HTMLDivElement>): ReactNode;
|
|
1661
|
+
Body: typeof DraggablePanelBody;
|
|
1662
|
+
Container: typeof DraggablePanelContainer;
|
|
1663
|
+
Footer: typeof DraggablePanelFooter;
|
|
1664
|
+
Header: typeof DraggablePanelHeader;
|
|
1665
|
+
}
|
|
1666
|
+
declare const DraggablePanel: IDraggablePanel;
|
|
1667
|
+
|
|
1668
|
+
interface DraggableSideNavProps extends Omit<DivProps, 'children' | 'onSelect'> {
|
|
1669
|
+
backgroundColor?: string;
|
|
1670
|
+
/**
|
|
1671
|
+
* Body content (main content area)
|
|
1672
|
+
* Function that receives expand state
|
|
1673
|
+
*/
|
|
1674
|
+
body: (expand: boolean) => ReactNode;
|
|
1675
|
+
/**
|
|
1676
|
+
* Classnames for internal components
|
|
1677
|
+
*/
|
|
1678
|
+
classNames?: {
|
|
1679
|
+
body?: string;
|
|
1680
|
+
container?: string;
|
|
1681
|
+
content?: string;
|
|
1682
|
+
footer?: string;
|
|
1683
|
+
handle?: string;
|
|
1684
|
+
header?: string;
|
|
1685
|
+
};
|
|
1686
|
+
/**
|
|
1687
|
+
* Whether the panel is expanded by default
|
|
1688
|
+
* @default true
|
|
1689
|
+
*/
|
|
1690
|
+
defaultExpand?: boolean;
|
|
1691
|
+
/**
|
|
1692
|
+
* Default width (number format)
|
|
1693
|
+
*/
|
|
1694
|
+
defaultWidth?: number;
|
|
1695
|
+
/**
|
|
1696
|
+
* Whether the panel is expanded (controlled)
|
|
1697
|
+
*/
|
|
1698
|
+
expand?: boolean;
|
|
1699
|
+
/**
|
|
1700
|
+
* Whether the panel can be expanded/collapsed
|
|
1701
|
+
* @default true
|
|
1702
|
+
*/
|
|
1703
|
+
expandable?: boolean;
|
|
1704
|
+
/**
|
|
1705
|
+
* Footer content
|
|
1706
|
+
* Can be a static element or a function that receives expand state
|
|
1707
|
+
*/
|
|
1708
|
+
footer?: ReactNode | ((expand: boolean) => ReactNode);
|
|
1709
|
+
/**
|
|
1710
|
+
* Header content
|
|
1711
|
+
* Can be a static element or a function that receives expand state
|
|
1712
|
+
*/
|
|
1713
|
+
header?: ReactNode | ((expand: boolean) => ReactNode);
|
|
1714
|
+
/**
|
|
1715
|
+
* Maximum width
|
|
1716
|
+
*/
|
|
1717
|
+
maxWidth?: number;
|
|
1718
|
+
/**
|
|
1719
|
+
* Minimum width when expanded (does not affect collapsed width which is always 64px)
|
|
1720
|
+
* Only applies when the panel is in expanded state
|
|
1721
|
+
* @default 64
|
|
1722
|
+
*/
|
|
1723
|
+
minWidth?: number;
|
|
1724
|
+
/**
|
|
1725
|
+
* Callback when expand state changes
|
|
1726
|
+
*/
|
|
1727
|
+
onExpandChange?: (expand: boolean) => void;
|
|
1728
|
+
/**
|
|
1729
|
+
* Callback when menu item is selected
|
|
1730
|
+
*/
|
|
1731
|
+
onSelect?: (key: string) => void;
|
|
1732
|
+
/**
|
|
1733
|
+
* Callback when width changes
|
|
1734
|
+
*/
|
|
1735
|
+
onWidthChange?: (delta: NumberSize, width: number) => void;
|
|
1736
|
+
/**
|
|
1737
|
+
* Callback when actively resizing width
|
|
1738
|
+
*/
|
|
1739
|
+
onWidthDragging?: (delta: NumberSize, width: number) => void;
|
|
1740
|
+
/**
|
|
1741
|
+
* Placement of the side nav
|
|
1742
|
+
* @default 'left'
|
|
1743
|
+
*/
|
|
1744
|
+
placement?: 'left' | 'right';
|
|
1745
|
+
/**
|
|
1746
|
+
* Whether to enable resizing
|
|
1747
|
+
* @default true
|
|
1748
|
+
*/
|
|
1749
|
+
resizable?: boolean;
|
|
1750
|
+
/**
|
|
1751
|
+
* Whether to show border
|
|
1752
|
+
* @default true
|
|
1753
|
+
*/
|
|
1754
|
+
showBorder?: boolean;
|
|
1755
|
+
/**
|
|
1756
|
+
* Whether to show handle for toggling
|
|
1757
|
+
* @default true
|
|
1758
|
+
*/
|
|
1759
|
+
showHandle?: boolean;
|
|
1760
|
+
showHandleHighlight?: boolean;
|
|
1761
|
+
/**
|
|
1762
|
+
* Whether to show handle when collapsed
|
|
1763
|
+
* @default false
|
|
1764
|
+
*/
|
|
1765
|
+
showHandleWhenCollapsed?: boolean;
|
|
1766
|
+
/**
|
|
1767
|
+
* Custom styles
|
|
1768
|
+
*/
|
|
1769
|
+
styles?: {
|
|
1770
|
+
body?: CSSProperties;
|
|
1771
|
+
container?: CSSProperties;
|
|
1772
|
+
content?: CSSProperties;
|
|
1773
|
+
footer?: CSSProperties;
|
|
1774
|
+
handle?: CSSProperties;
|
|
1775
|
+
header?: CSSProperties;
|
|
1776
|
+
};
|
|
1777
|
+
/**
|
|
1778
|
+
* Expanded width (controlled)
|
|
1779
|
+
* This represents the width when expanded, not the current displayed width
|
|
1780
|
+
* The actual displayed width will be `width` when expanded, or `minWidth` when collapsed
|
|
1781
|
+
*/
|
|
1782
|
+
width?: number;
|
|
1783
|
+
}
|
|
1784
|
+
|
|
1785
|
+
declare const DraggableSideNav: react.NamedExoticComponent<DraggableSideNavProps>;
|
|
1786
|
+
|
|
1787
|
+
interface DrawerProps extends Omit<DrawerProps$1, 'styles' | 'classNames'> {
|
|
1788
|
+
classNames?: DrawerProps$1['classNames'] & {
|
|
1789
|
+
bodyContent?: string;
|
|
1790
|
+
extra?: string;
|
|
1791
|
+
sidebar?: string;
|
|
1792
|
+
sidebarContent?: string;
|
|
1793
|
+
title?: string;
|
|
1794
|
+
};
|
|
1795
|
+
closeIconProps?: ActionIconProps;
|
|
1796
|
+
containerMaxWidth?: number | string;
|
|
1797
|
+
noHeader?: boolean;
|
|
1798
|
+
ref?: Ref<HTMLDivElement>;
|
|
1799
|
+
sidebar?: ReactNode;
|
|
1800
|
+
sidebarWidth?: number;
|
|
1801
|
+
styles?: DrawerProps$1['styles'] & {
|
|
1802
|
+
bodyContent?: CSSProperties;
|
|
1803
|
+
extra?: CSSProperties;
|
|
1804
|
+
sidebar?: CSSProperties;
|
|
1805
|
+
sidebarContent?: CSSProperties;
|
|
1806
|
+
title?: CSSProperties;
|
|
1807
|
+
};
|
|
1808
|
+
}
|
|
1809
|
+
|
|
1810
|
+
declare const Drawer: react.NamedExoticComponent<DrawerProps>;
|
|
1811
|
+
|
|
1812
|
+
interface DropdownProps extends Omit<DropdownProps$1, 'menu'> {
|
|
1813
|
+
iconProps?: IconContentConfig;
|
|
1814
|
+
menu: MenuProps;
|
|
1815
|
+
}
|
|
1816
|
+
|
|
1817
|
+
/**
|
|
1818
|
+
* @deprecated
|
|
1819
|
+
* Use `DropdownMenu` or `ContextMenu` instead
|
|
1820
|
+
* @see https://ui.lobehub.com/components/context-menu
|
|
1821
|
+
* @see https://ui.lobehub.com/components/dropdown-menu
|
|
1822
|
+
*/
|
|
1823
|
+
declare const Dropdown: react.NamedExoticComponent<DropdownProps>;
|
|
1824
|
+
|
|
1825
|
+
declare const Input: react.NamedExoticComponent<InputProps>;
|
|
1826
|
+
|
|
1827
|
+
declare const InputMask: react.NamedExoticComponent<InputMaskProps>;
|
|
1828
|
+
|
|
1829
|
+
declare const InputNumber: react.NamedExoticComponent<InputNumberProps>;
|
|
1830
|
+
|
|
1831
|
+
declare const InputOPT: react.NamedExoticComponent<InputOPTProps>;
|
|
1832
|
+
|
|
1833
|
+
declare const InputPassword: react.NamedExoticComponent<InputPasswordProps>;
|
|
1834
|
+
|
|
1835
|
+
declare const TextArea: react.NamedExoticComponent<TextAreaProps>;
|
|
1836
|
+
|
|
1837
|
+
interface ControlInputProps extends Omit<InputProps, 'onChange' | 'value' | 'onAbort'> {
|
|
1838
|
+
onChange?: (value: string) => void;
|
|
1839
|
+
onChangeEnd?: (value: string) => void;
|
|
1840
|
+
onValueChanging?: (value: string) => void;
|
|
1841
|
+
submitIcon?: ActionIconProps['icon'];
|
|
1842
|
+
texts?: {
|
|
1843
|
+
reset?: string;
|
|
1844
|
+
submit?: string;
|
|
1845
|
+
};
|
|
1846
|
+
value?: string;
|
|
1847
|
+
}
|
|
1848
|
+
|
|
1849
|
+
interface EditableTextProps extends Omit<FlexProps, 'onChange' | 'onBlur' | 'onFocus'>, Pick<ControlInputProps, 'onChange' | 'value' | 'onChangeEnd' | 'onValueChanging' | 'texts' | 'variant' | 'onBlur' | 'onFocus' | 'size'> {
|
|
1850
|
+
className?: string;
|
|
1851
|
+
classNames?: {
|
|
1852
|
+
container?: string;
|
|
1853
|
+
input?: string;
|
|
1854
|
+
};
|
|
1855
|
+
editing?: boolean;
|
|
1856
|
+
inputProps?: Omit<ControlInputProps, 'onChange' | 'value' | 'onChangeEnd' | 'onValueChanging' | 'texts' | 'className' | 'style' | 'onBlur' | 'onFocus' | 'size'>;
|
|
1857
|
+
onEditingChange?: (editing: boolean) => void;
|
|
1858
|
+
showEditIcon?: boolean;
|
|
1859
|
+
style?: CSSProperties;
|
|
1860
|
+
styles?: {
|
|
1861
|
+
container?: CSSProperties;
|
|
1862
|
+
input?: CSSProperties;
|
|
1863
|
+
};
|
|
1864
|
+
}
|
|
1865
|
+
|
|
1866
|
+
declare const EditableText: react.NamedExoticComponent<EditableTextProps>;
|
|
1867
|
+
|
|
1868
|
+
declare const EditorSlashMenuList: react__default.ForwardRefExoticComponent<Omit<_base_ui_react_autocomplete.AutocompleteListProps & react__default.RefAttributes<HTMLDivElement>, "ref"> & react__default.RefAttributes<HTMLDivElement>>;
|
|
1869
|
+
type EditorSlashMenuPortalProps = react__default.ComponentProps<typeof Autocomplete.Portal> & {
|
|
1870
|
+
/**
|
|
1871
|
+
* When `container` is not provided, it uses a shared container created by `usePortalContainer`.
|
|
1872
|
+
*/
|
|
1873
|
+
container?: HTMLElement | null;
|
|
1874
|
+
};
|
|
1875
|
+
declare const EditorSlashMenuPortal: {
|
|
1876
|
+
({ container, ...rest }: EditorSlashMenuPortalProps): react_jsx_runtime.JSX.Element;
|
|
1877
|
+
displayName: string;
|
|
1878
|
+
};
|
|
1879
|
+
type EditorSlashMenuPositionerProps = react__default.ComponentProps<typeof Autocomplete.Positioner>;
|
|
1880
|
+
declare const EditorSlashMenuPositioner: {
|
|
1881
|
+
({ className, align, positionMethod, side, sideOffset, ...rest }: EditorSlashMenuPositionerProps): react_jsx_runtime.JSX.Element;
|
|
1882
|
+
displayName: string;
|
|
1883
|
+
};
|
|
1884
|
+
type EditorSlashMenuPopupProps = react__default.ComponentProps<typeof Autocomplete.Popup>;
|
|
1885
|
+
declare const EditorSlashMenuPopup: {
|
|
1886
|
+
({ className, initialFocus, ...rest }: EditorSlashMenuPopupProps): react_jsx_runtime.JSX.Element;
|
|
1887
|
+
displayName: string;
|
|
1888
|
+
};
|
|
1889
|
+
declare const EditorSlashMenuGroup$1: react__default.ForwardRefExoticComponent<_base_ui_react_autocomplete.AutocompleteGroupProps & react__default.RefAttributes<HTMLDivElement>>;
|
|
1890
|
+
type EditorSlashMenuHiddenInputProps = react__default.ComponentProps<typeof Autocomplete.Input>;
|
|
1891
|
+
declare const EditorSlashMenuHiddenInput: {
|
|
1892
|
+
({ className, ...rest }: EditorSlashMenuHiddenInputProps): react_jsx_runtime.JSX.Element;
|
|
1893
|
+
displayName: string;
|
|
1894
|
+
};
|
|
1895
|
+
|
|
1896
|
+
type EditorSlashMenuItemValue = string;
|
|
1897
|
+
type EditorSlashMenuOption = {
|
|
1898
|
+
/** Render danger style (red) */
|
|
1899
|
+
danger?: boolean;
|
|
1900
|
+
/** Whether the item is disabled */
|
|
1901
|
+
disabled?: boolean;
|
|
1902
|
+
/** Optional extra content shown at the end */
|
|
1903
|
+
extra?: react__default.ReactNode;
|
|
1904
|
+
/** Optional icon shown at the start */
|
|
1905
|
+
icon?: react__default.ReactNode;
|
|
1906
|
+
/** Optional additional keywords for filtering */
|
|
1907
|
+
keywords?: string[];
|
|
1908
|
+
/** Visible label, also used for filtering by default */
|
|
1909
|
+
label: string;
|
|
1910
|
+
/** Unique id of the command */
|
|
1911
|
+
value: EditorSlashMenuItemValue;
|
|
1912
|
+
};
|
|
1913
|
+
type EditorSlashMenuGroup = {
|
|
1914
|
+
items: EditorSlashMenuOption[];
|
|
1915
|
+
/** Optional group title */
|
|
1916
|
+
label?: string;
|
|
1917
|
+
};
|
|
1918
|
+
type EditorSlashMenuItems = Array<EditorSlashMenuOption | EditorSlashMenuGroup>;
|
|
1919
|
+
|
|
1920
|
+
type Props = {
|
|
1921
|
+
/** Anchor for positioning (caret virtual element, dom element, ref, etc.) */
|
|
1922
|
+
anchor?: react__default.ComponentProps<typeof EditorSlashMenuPositioner>['anchor'];
|
|
1923
|
+
defaultOpen?: boolean;
|
|
1924
|
+
/** Initial query string (uncontrolled) */
|
|
1925
|
+
defaultValue?: string;
|
|
1926
|
+
/** Optional custom empty state */
|
|
1927
|
+
empty?: react__default.ReactNode;
|
|
1928
|
+
hiddenInputProps?: react__default.ComponentProps<typeof EditorSlashMenuHiddenInput>;
|
|
1929
|
+
items: EditorSlashMenuItems;
|
|
1930
|
+
listProps?: react__default.ComponentProps<typeof EditorSlashMenuList>;
|
|
1931
|
+
onOpenChange?: (open: boolean, details: AutocompleteRootChangeEventDetails) => void;
|
|
1932
|
+
onOpenChangeComplete?: (open: boolean) => void;
|
|
1933
|
+
/** Called when a command is selected. */
|
|
1934
|
+
onSelect?: (item: EditorSlashMenuOption, details: AutocompleteRootChangeEventDetails) => void;
|
|
1935
|
+
/** Called when query changes. By default, changes caused by item selection are ignored. */
|
|
1936
|
+
onValueChange?: (value: string, details: AutocompleteRootChangeEventDetails) => void;
|
|
1937
|
+
open?: boolean;
|
|
1938
|
+
popupProps?: react__default.ComponentProps<typeof EditorSlashMenuPopup>;
|
|
1939
|
+
portalProps?: Omit<react__default.ComponentProps<typeof EditorSlashMenuPortal>, 'container'> & {
|
|
1940
|
+
container?: HTMLElement | null;
|
|
1941
|
+
};
|
|
1942
|
+
positionerProps?: Omit<react__default.ComponentProps<typeof EditorSlashMenuPositioner>, 'anchor'>;
|
|
1943
|
+
/** Optional custom group label renderer */
|
|
1944
|
+
renderGroupLabel?: (label: string) => react__default.ReactNode;
|
|
1945
|
+
/** Optional custom item renderer */
|
|
1946
|
+
renderItem?: (item: EditorSlashMenuOption) => react__default.ReactNode;
|
|
1947
|
+
/** Reserve icon space even when icon is missing */
|
|
1948
|
+
reserveIconSpace?: boolean;
|
|
1949
|
+
/** Pass-through props */
|
|
1950
|
+
rootProps?: Omit<AutocompleteRootProps<EditorSlashMenuOption>, 'items' | 'value' | 'defaultValue' | 'onValueChange' | 'open' | 'defaultOpen' | 'onOpenChange' | 'onOpenChangeComplete' | 'itemToStringValue'>;
|
|
1951
|
+
/** Whether selecting an item should propagate its filled value via `onValueChange`. */
|
|
1952
|
+
updateValueOnSelect?: boolean;
|
|
1953
|
+
/** Current query string (controlled) */
|
|
1954
|
+
value?: string;
|
|
1955
|
+
/**
|
|
1956
|
+
* Render a visually-hidden input element for keyboard navigation / screen readers.
|
|
1957
|
+
* Default is `false` because slash menus usually live inside an editor input.
|
|
1958
|
+
*/
|
|
1959
|
+
withHiddenInput?: boolean;
|
|
1960
|
+
};
|
|
1961
|
+
declare const EditorSlashMenu: react__default.NamedExoticComponent<Props>;
|
|
1962
|
+
|
|
1963
|
+
declare const PopoverArrowIcon: react_jsx_runtime.JSX.Element;
|
|
1964
|
+
|
|
1965
|
+
type PopoverPlacement = Placement;
|
|
1966
|
+
type PopoverTrigger = Trigger;
|
|
1967
|
+
/**
|
|
1968
|
+
* Base UI Positioner props that can be passed through
|
|
1969
|
+
*/
|
|
1970
|
+
type PopoverPositionerProps = Omit<PopoverPositionerProps$1, 'className' | 'style' | 'children'>;
|
|
1971
|
+
/**
|
|
1972
|
+
* Base UI Trigger props that can be passed through
|
|
1973
|
+
*/
|
|
1974
|
+
type PopoverTriggerComponentProps = Omit<PopoverTriggerProps, 'className' | 'style' | 'children' | 'render' | 'nativeButton' | 'handle' | 'payload'>;
|
|
1975
|
+
/**
|
|
1976
|
+
* Base UI Popup props that can be passed through
|
|
1977
|
+
*/
|
|
1978
|
+
type PopoverPopupProps = Omit<PopoverPopupProps$1, 'className' | 'style' | 'children'>;
|
|
1979
|
+
/**
|
|
1980
|
+
* Base UI Backdrop props that can be passed through
|
|
1981
|
+
*/
|
|
1982
|
+
type PopoverBackdropProps = Omit<PopoverBackdropProps$1, 'className' | 'style'>;
|
|
1983
|
+
/**
|
|
1984
|
+
* Base UI Portal props that can be passed through
|
|
1985
|
+
*/
|
|
1986
|
+
type PopoverPortalProps = Omit<PopoverPortalProps$1, 'children' | 'container'>;
|
|
1987
|
+
interface PopoverProps {
|
|
1988
|
+
/**
|
|
1989
|
+
* 是否显示箭头, 在 `inset` 下无法使用
|
|
1990
|
+
* @default false
|
|
1991
|
+
*/
|
|
1992
|
+
arrow?: boolean;
|
|
1993
|
+
/**
|
|
1994
|
+
* Base UI Backdrop 组件的 props
|
|
1995
|
+
*/
|
|
1996
|
+
backdropProps?: PopoverBackdropProps;
|
|
1997
|
+
/**
|
|
1998
|
+
* 触发元素
|
|
1999
|
+
*/
|
|
2000
|
+
children: ReactElement | ReactNode;
|
|
2001
|
+
/**
|
|
2002
|
+
* 弹出容器类名
|
|
2003
|
+
*/
|
|
2004
|
+
className?: string;
|
|
2005
|
+
/**
|
|
2006
|
+
* 自定义类名
|
|
2007
|
+
*/
|
|
2008
|
+
classNames?: {
|
|
2009
|
+
arrow?: string;
|
|
2010
|
+
content?: string;
|
|
2011
|
+
root?: string;
|
|
2012
|
+
trigger?: string;
|
|
2013
|
+
};
|
|
2014
|
+
/**
|
|
2015
|
+
* 关闭延迟(毫秒),优先级高于 mouseLeaveDelay
|
|
2016
|
+
*/
|
|
2017
|
+
closeDelay?: number;
|
|
2018
|
+
/**
|
|
2019
|
+
* 弹出内容
|
|
2020
|
+
*/
|
|
2021
|
+
content: ReactNode;
|
|
2022
|
+
/**
|
|
2023
|
+
* 默认打开状态
|
|
2024
|
+
* @default false
|
|
2025
|
+
*/
|
|
2026
|
+
defaultOpen?: boolean;
|
|
2027
|
+
/**
|
|
2028
|
+
* 是否禁用
|
|
2029
|
+
* @default false
|
|
2030
|
+
*/
|
|
2031
|
+
disabled?: boolean;
|
|
2032
|
+
/**
|
|
2033
|
+
* 获取弹出容器
|
|
2034
|
+
*/
|
|
2035
|
+
getPopupContainer?: (triggerNode: HTMLElement) => HTMLElement;
|
|
2036
|
+
/**
|
|
2037
|
+
* 是否嵌入 trigger 内部显示
|
|
2038
|
+
* @default false
|
|
2039
|
+
*/
|
|
2040
|
+
inset?: boolean;
|
|
2041
|
+
/**
|
|
2042
|
+
* 鼠标移入延迟(秒)
|
|
2043
|
+
* @default 0.1
|
|
2044
|
+
*/
|
|
2045
|
+
mouseEnterDelay?: number;
|
|
2046
|
+
/**
|
|
2047
|
+
* 鼠标移出延迟(秒)
|
|
2048
|
+
* @default 0.1
|
|
2049
|
+
*/
|
|
2050
|
+
mouseLeaveDelay?: number;
|
|
2051
|
+
/**
|
|
2052
|
+
* 是否使用原生 button 元素作为触发器
|
|
2053
|
+
*/
|
|
2054
|
+
nativeButton?: boolean;
|
|
2055
|
+
/**
|
|
2056
|
+
* 打开状态变化回调
|
|
2057
|
+
*/
|
|
2058
|
+
onOpenChange?: (open: boolean) => void;
|
|
2059
|
+
/**
|
|
2060
|
+
* 受控的打开状态
|
|
2061
|
+
*/
|
|
2062
|
+
open?: boolean;
|
|
2063
|
+
/**
|
|
2064
|
+
* 打开延迟(毫秒),优先级高于 mouseEnterDelay
|
|
2065
|
+
*/
|
|
2066
|
+
openDelay?: number;
|
|
2067
|
+
/**
|
|
2068
|
+
* 弹出位置
|
|
2069
|
+
* @default 'top'
|
|
2070
|
+
*/
|
|
2071
|
+
placement?: PopoverPlacement;
|
|
2072
|
+
/**
|
|
2073
|
+
* Base UI Popup 组件的 props
|
|
2074
|
+
*/
|
|
2075
|
+
popupProps?: PopoverPopupProps;
|
|
2076
|
+
/**
|
|
2077
|
+
* Base UI Portal 组件的 props
|
|
2078
|
+
*/
|
|
2079
|
+
portalProps?: PopoverPortalProps;
|
|
2080
|
+
/**
|
|
2081
|
+
* Base UI Positioner 组件的 props
|
|
2082
|
+
*/
|
|
2083
|
+
positionerProps?: PopoverPositionerProps;
|
|
2084
|
+
/**
|
|
2085
|
+
* ref
|
|
2086
|
+
*/
|
|
2087
|
+
ref?: ComponentPropsWithRef<typeof Popover$1.Trigger>['ref'];
|
|
2088
|
+
/**
|
|
2089
|
+
* 当设置为 true 时,即使在 PopoverGroup 内部也会独立渲染,忽略 group 单例行为
|
|
2090
|
+
*/
|
|
2091
|
+
standalone?: boolean;
|
|
2092
|
+
/**
|
|
2093
|
+
* 自定义样式
|
|
2094
|
+
*/
|
|
2095
|
+
styles?: {
|
|
2096
|
+
arrow?: CSSProperties;
|
|
2097
|
+
content?: CSSProperties;
|
|
2098
|
+
root?: CSSProperties;
|
|
2099
|
+
};
|
|
2100
|
+
/**
|
|
2101
|
+
* 触发方式
|
|
2102
|
+
* @default 'hover'
|
|
2103
|
+
*/
|
|
2104
|
+
trigger?: Trigger;
|
|
2105
|
+
/**
|
|
2106
|
+
* Base UI Trigger 组件的 props
|
|
2107
|
+
*/
|
|
2108
|
+
triggerProps?: PopoverTriggerComponentProps;
|
|
2109
|
+
/**
|
|
2110
|
+
* z-index
|
|
2111
|
+
*/
|
|
2112
|
+
zIndex?: number;
|
|
2113
|
+
}
|
|
2114
|
+
|
|
2115
|
+
declare const PopoverRoot: typeof Popover$1.Root;
|
|
2116
|
+
declare const PopoverBackdrop: react.ForwardRefExoticComponent<_base_ui_react_popover.PopoverBackdropProps & react.RefAttributes<HTMLDivElement>>;
|
|
2117
|
+
type PopoverTriggerElementProps = Omit<ComponentPropsWithRef<typeof Popover$1.Trigger>, 'children' | 'render'> & {
|
|
2118
|
+
children: ComponentProps<typeof Popover$1.Trigger>['children'];
|
|
2119
|
+
};
|
|
2120
|
+
declare const PopoverTriggerElement: {
|
|
2121
|
+
({ children, className, nativeButton, ref: refProp, ...rest }: PopoverTriggerElementProps): react_jsx_runtime.JSX.Element;
|
|
2122
|
+
displayName: string;
|
|
2123
|
+
};
|
|
2124
|
+
type PopoverPortalAtomProps = Omit<ComponentProps<typeof Popover$1.Portal>, 'container'> & {
|
|
2125
|
+
/**
|
|
2126
|
+
* Portal container. When not provided, it uses the shared container created by `usePopoverPortalContainer`.
|
|
2127
|
+
*/
|
|
2128
|
+
container?: HTMLElement | null;
|
|
2129
|
+
/**
|
|
2130
|
+
* Root element used by `usePopoverPortalContainer` to create the default container.
|
|
2131
|
+
*/
|
|
2132
|
+
root?: HTMLElement | ShadowRoot | null;
|
|
2133
|
+
};
|
|
2134
|
+
declare const PopoverPortal: {
|
|
2135
|
+
({ container, root, children, ...rest }: PopoverPortalAtomProps): react_jsx_runtime.JSX.Element | null;
|
|
2136
|
+
displayName: string;
|
|
2137
|
+
};
|
|
2138
|
+
type PopoverPositionerAtomProps = ComponentProps<typeof Popover$1.Positioner> & {
|
|
2139
|
+
hoverTrigger?: boolean;
|
|
2140
|
+
placement?: PopoverPlacement;
|
|
2141
|
+
};
|
|
2142
|
+
declare const PopoverPositioner: {
|
|
2143
|
+
({ children, className, hoverTrigger, placement, align, side, sideOffset, ...rest }: PopoverPositionerAtomProps): react_jsx_runtime.JSX.Element;
|
|
2144
|
+
displayName: string;
|
|
2145
|
+
};
|
|
2146
|
+
type PopoverPopupAtomProps = ComponentProps<typeof Popover$1.Popup>;
|
|
2147
|
+
declare const PopoverPopup: {
|
|
2148
|
+
({ className, ...rest }: PopoverPopupAtomProps): react_jsx_runtime.JSX.Element;
|
|
2149
|
+
displayName: string;
|
|
2150
|
+
};
|
|
2151
|
+
type PopoverArrowAtomProps = ComponentProps<typeof Popover$1.Arrow>;
|
|
2152
|
+
declare const PopoverArrow: {
|
|
2153
|
+
({ className, children, ...rest }: PopoverArrowAtomProps): react_jsx_runtime.JSX.Element;
|
|
2154
|
+
displayName: string;
|
|
2155
|
+
};
|
|
2156
|
+
type PopoverViewportAtomProps = ComponentProps<typeof Popover$1.Viewport>;
|
|
2157
|
+
declare const PopoverViewport: {
|
|
2158
|
+
({ className, ...rest }: PopoverViewportAtomProps): react_jsx_runtime.JSX.Element;
|
|
2159
|
+
displayName: string;
|
|
2160
|
+
};
|
|
2161
|
+
|
|
2162
|
+
type PopoverContextValue = {
|
|
2163
|
+
close: () => void;
|
|
2164
|
+
};
|
|
2165
|
+
declare const PopoverProvider: react.NamedExoticComponent<{
|
|
2166
|
+
children: ReactNode;
|
|
2167
|
+
value: PopoverContextValue;
|
|
2168
|
+
}>;
|
|
2169
|
+
declare const usePopoverContext: () => PopoverContextValue;
|
|
2170
|
+
|
|
2171
|
+
declare const Popover: FC<PopoverProps>;
|
|
2172
|
+
|
|
2173
|
+
type PopoverGroupSharedProps = Omit<PopoverProps, 'children' | 'content' | 'defaultOpen' | 'open' | 'ref'> & {
|
|
2174
|
+
/**
|
|
2175
|
+
* @description Whether to enable content layout animation when switching triggers
|
|
2176
|
+
* @default false
|
|
2177
|
+
*/
|
|
2178
|
+
contentLayoutAnimation?: boolean;
|
|
2179
|
+
/**
|
|
2180
|
+
* Disable the "destroy on invalid trigger (display:none / disconnected)" guard for performance.
|
|
2181
|
+
* @default false
|
|
2182
|
+
*/
|
|
2183
|
+
disableDestroyOnInvalidTrigger?: boolean;
|
|
2184
|
+
/**
|
|
2185
|
+
* Disable the "hide when positioner falls back to (0,0)" visual guard for performance.
|
|
2186
|
+
* @default false
|
|
2187
|
+
*/
|
|
2188
|
+
disableZeroOriginGuard?: boolean;
|
|
2189
|
+
};
|
|
2190
|
+
|
|
2191
|
+
type PopoverGroupProps = PopoverGroupSharedProps & {
|
|
2192
|
+
children: ReactNode;
|
|
2193
|
+
};
|
|
2194
|
+
declare const PopoverGroup: FC<PopoverGroupProps>;
|
|
2195
|
+
|
|
2196
|
+
declare const POPOVER_CONTAINER_ATTR = "data-lobe-ui-popover-container";
|
|
2197
|
+
declare const usePopoverPortalContainer: (root?: HTMLElement | ShadowRoot | null) => HTMLElement | null;
|
|
2198
|
+
|
|
2199
|
+
interface AvatarUploaderProps {
|
|
2200
|
+
compressSize?: number;
|
|
2201
|
+
onChange: (avatar: string) => void;
|
|
2202
|
+
onUpload?: (file: File) => void;
|
|
2203
|
+
shape?: 'circle' | 'square';
|
|
2204
|
+
texts?: {
|
|
2205
|
+
draggerDesc?: string;
|
|
2206
|
+
fileTypeError?: string;
|
|
2207
|
+
uploadBtn?: string;
|
|
2208
|
+
};
|
|
2209
|
+
}
|
|
2210
|
+
interface EmojiPickerCustomEmoji {
|
|
2211
|
+
emojis: [
|
|
2212
|
+
{
|
|
2213
|
+
id: string;
|
|
2214
|
+
keywords?: string[];
|
|
2215
|
+
name: string;
|
|
2216
|
+
skins: {
|
|
2217
|
+
src: string;
|
|
2218
|
+
}[];
|
|
2219
|
+
}
|
|
2220
|
+
];
|
|
2221
|
+
id: string;
|
|
2222
|
+
name: string;
|
|
2223
|
+
}
|
|
2224
|
+
interface EmojiPickerCustomTab {
|
|
2225
|
+
label: ReactNode;
|
|
2226
|
+
render: (handleAvatarChange: (avatar: string) => void) => ReactNode;
|
|
2227
|
+
value: string;
|
|
2228
|
+
}
|
|
2229
|
+
interface EmojiPickerProps extends Omit<AvatarProps, 'onChange' | 'avatar'> {
|
|
2230
|
+
allowDelete?: boolean;
|
|
2231
|
+
allowUpload?: boolean | {
|
|
2232
|
+
enableEmoji?: boolean;
|
|
2233
|
+
};
|
|
2234
|
+
compressSize?: number;
|
|
2235
|
+
contentProps?: Omit<FlexProps, 'className' | 'ref' | 'style'>;
|
|
2236
|
+
customEmojis?: EmojiPickerCustomEmoji[];
|
|
2237
|
+
customRender?: (avatar: string) => ReactNode;
|
|
2238
|
+
customTabs?: EmojiPickerCustomTab[];
|
|
2239
|
+
defaultAvatar?: string;
|
|
2240
|
+
defaultOpen?: boolean;
|
|
2241
|
+
loading?: boolean;
|
|
2242
|
+
locale?: string;
|
|
2243
|
+
onChange?: (emoji: string) => void;
|
|
2244
|
+
onDelete?: () => void;
|
|
2245
|
+
onOpenChange?: (open: boolean) => void;
|
|
2246
|
+
onUpload?: AvatarUploaderProps['onUpload'];
|
|
2247
|
+
open?: boolean;
|
|
2248
|
+
popupClassName?: string;
|
|
2249
|
+
popupProps?: Omit<PopoverProps, 'onOpenChange' | 'defaultOpen' | 'content' | 'open' | 'trigger' | 'children'>;
|
|
2250
|
+
popupStyle?: CSSProperties;
|
|
2251
|
+
size?: number;
|
|
2252
|
+
texts?: AvatarUploaderProps['texts'] & {
|
|
2253
|
+
delete?: string;
|
|
2254
|
+
emoji?: string;
|
|
2255
|
+
upload?: string;
|
|
2256
|
+
};
|
|
2257
|
+
value?: string;
|
|
2258
|
+
}
|
|
2259
|
+
|
|
2260
|
+
declare const EmojiPicker: react.NamedExoticComponent<EmojiPickerProps>;
|
|
2261
|
+
|
|
2262
|
+
interface EmptyProps extends Omit<FlexProps, 'title'> {
|
|
2263
|
+
action?: ReactNode;
|
|
2264
|
+
actionProps?: Omit<FlexProps, 'children'>;
|
|
2265
|
+
description?: ReactNode;
|
|
2266
|
+
descriptionProps?: Omit<TextProps, 'children'>;
|
|
2267
|
+
emoji?: string;
|
|
2268
|
+
icon?: IconProps$1['icon'];
|
|
2269
|
+
iconColor?: IconProps$1['color'];
|
|
2270
|
+
image?: ReactNode;
|
|
2271
|
+
imageProps?: Omit<BlockProps, 'children'>;
|
|
2272
|
+
imageSize?: number;
|
|
2273
|
+
title?: ReactNode;
|
|
2274
|
+
titleProps?: Omit<TextProps, 'children'>;
|
|
2275
|
+
type?: 'default' | 'page';
|
|
2276
|
+
}
|
|
2277
|
+
|
|
2278
|
+
declare const Empty: FC<EmptyProps>;
|
|
2279
|
+
|
|
2280
|
+
type IconProps = SvgProps & DivProps;
|
|
2281
|
+
interface FileTypeIconProps extends IconProps {
|
|
2282
|
+
color?: string;
|
|
2283
|
+
filetype?: string;
|
|
2284
|
+
icon?: ReactNode;
|
|
2285
|
+
ref?: Ref<HTMLDivElement>;
|
|
2286
|
+
size?: number;
|
|
2287
|
+
type?: 'file' | 'folder';
|
|
2288
|
+
variant?: 'color' | 'mono';
|
|
2289
|
+
}
|
|
2290
|
+
|
|
2291
|
+
declare const FileTypeIcon: FC<FileTypeIconProps>;
|
|
2292
|
+
|
|
2293
|
+
type EmojiType = 'anim' | 'flat' | 'modern' | 'mono' | 'raw' | '3d';
|
|
2294
|
+
|
|
2295
|
+
interface FluentEmojiProps extends DivProps {
|
|
2296
|
+
emoji: string;
|
|
2297
|
+
ref?: Ref<HTMLImageElement>;
|
|
2298
|
+
size?: number;
|
|
2299
|
+
type?: EmojiType;
|
|
2300
|
+
unoptimized?: boolean;
|
|
2301
|
+
}
|
|
2302
|
+
|
|
2303
|
+
declare const FluentEmoji: FC<FluentEmojiProps>;
|
|
2304
|
+
|
|
2305
|
+
interface FontLoaderProps {
|
|
2306
|
+
url: string;
|
|
2307
|
+
}
|
|
2308
|
+
declare const FontLoader: react.NamedExoticComponent<FontLoaderProps>;
|
|
2309
|
+
|
|
2310
|
+
interface FooterProps extends FlexProps {
|
|
2311
|
+
bottom?: ReactNode;
|
|
2312
|
+
columns: FooterProps$1['columns'];
|
|
2313
|
+
contentMaxWidth?: number;
|
|
2314
|
+
theme?: 'light' | 'dark';
|
|
2315
|
+
}
|
|
2316
|
+
|
|
2317
|
+
declare const Footer: react.NamedExoticComponent<FooterProps>;
|
|
2318
|
+
|
|
2319
|
+
interface FormConfig<T extends Record<string, any>> {
|
|
2320
|
+
initialValues: T;
|
|
2321
|
+
onSubmit: (values: T) => void | Promise<void>;
|
|
2322
|
+
validate?: (values: T) => Partial<Record<keyof T, string>>;
|
|
2323
|
+
}
|
|
2324
|
+
interface FormState<T extends Record<string, any>> {
|
|
2325
|
+
values: T;
|
|
2326
|
+
errors: Partial<Record<keyof T, string>>;
|
|
2327
|
+
fieldErrors: Partial<Record<keyof T, string>>;
|
|
2328
|
+
touched: Partial<Record<keyof T, boolean>>;
|
|
2329
|
+
isSubmitting: boolean;
|
|
2330
|
+
isValid: boolean;
|
|
2331
|
+
validationSequence: number;
|
|
2332
|
+
}
|
|
2333
|
+
declare function useForm<T extends Record<string, any>>(config: FormConfig<T>): {
|
|
2334
|
+
readonly form: {
|
|
2335
|
+
readonly values: T;
|
|
2336
|
+
readonly errors: Partial<Record<keyof T, string>>;
|
|
2337
|
+
readonly fieldErrors: Partial<Record<keyof T, string>>;
|
|
2338
|
+
readonly touched: Partial<Record<keyof T, boolean>>;
|
|
2339
|
+
readonly validationSequence: number;
|
|
2340
|
+
readonly setFieldValue: (field: PropertyKey, value: unknown) => void;
|
|
2341
|
+
readonly setFieldError: (field: PropertyKey, error?: string) => void;
|
|
2342
|
+
readonly setFieldTouched: (field: PropertyKey, touched?: boolean) => void;
|
|
2343
|
+
readonly handleChange: (e: ChangeEvent<HTMLInputElement | HTMLTextAreaElement | HTMLSelectElement>) => void;
|
|
2344
|
+
readonly handleBlur: (e: FocusEvent<HTMLInputElement | HTMLTextAreaElement | HTMLSelectElement>) => void;
|
|
2345
|
+
readonly handleSubmit: (e?: FormEvent) => Promise<void>;
|
|
2346
|
+
readonly resetForm: () => void;
|
|
2347
|
+
readonly validateForm: () => boolean;
|
|
2348
|
+
readonly triggerValidation: () => void;
|
|
2349
|
+
readonly isSubmitting: boolean;
|
|
2350
|
+
readonly isValid: boolean;
|
|
2351
|
+
};
|
|
2352
|
+
readonly setFieldValue: (field: keyof T, value: any) => void;
|
|
2353
|
+
readonly setFieldTouched: (field: keyof T, touched?: boolean) => void;
|
|
2354
|
+
readonly setFieldError: (field: keyof T, error?: string) => void;
|
|
2355
|
+
readonly handleChange: (e: ChangeEvent<HTMLInputElement | HTMLTextAreaElement | HTMLSelectElement>) => void;
|
|
2356
|
+
readonly handleBlur: (e: FocusEvent<HTMLInputElement | HTMLTextAreaElement | HTMLSelectElement>) => void;
|
|
2357
|
+
readonly handleSubmit: (e?: FormEvent) => void;
|
|
2358
|
+
readonly resetForm: () => void;
|
|
2359
|
+
readonly validateForm: () => boolean;
|
|
2360
|
+
readonly triggerValidation: () => void;
|
|
2361
|
+
readonly values: T;
|
|
2362
|
+
readonly errors: Partial<Record<keyof T, string>>;
|
|
2363
|
+
readonly fieldErrors: Partial<Record<keyof T, string>>;
|
|
2364
|
+
readonly touched: Partial<Record<keyof T, boolean>>;
|
|
2365
|
+
readonly isSubmitting: boolean;
|
|
2366
|
+
readonly isValid: boolean;
|
|
2367
|
+
readonly validationSequence: number;
|
|
2368
|
+
};
|
|
2369
|
+
type UseFormReturn<T extends Record<string, any>> = ReturnType<typeof useForm<T>>;
|
|
2370
|
+
type FormInstance<T extends Record<string, any>> = UseFormReturn<T>['form'];
|
|
2371
|
+
|
|
2372
|
+
type FormVariant = 'borderless' | 'filled' | 'outlined';
|
|
2373
|
+
interface FormProps<T extends Record<string, any>> extends Omit<FormHTMLAttributes<HTMLFormElement>, 'onSubmit'> {
|
|
2374
|
+
children: ReactNode;
|
|
2375
|
+
onSubmit?: (values: T) => void | Promise<void>;
|
|
2376
|
+
form?: FormInstance<T>;
|
|
2377
|
+
initialValues?: T;
|
|
2378
|
+
validate?: (values: T) => Partial<Record<keyof T, string>>;
|
|
2379
|
+
className?: string;
|
|
2380
|
+
/**
|
|
2381
|
+
* Layout of form fields.
|
|
2382
|
+
* - `vertical`: label/description stacked above control (default)
|
|
2383
|
+
* - `horizontal`: label/description on the left, control on the right
|
|
2384
|
+
*/
|
|
2385
|
+
layout?: 'vertical' | 'horizontal';
|
|
2386
|
+
/**
|
|
2387
|
+
* When `layout="horizontal"`, sets the width of the label/description column.
|
|
2388
|
+
* Accepts any CSS width value (e.g., `180px`, `12rem`, `30%`).
|
|
2389
|
+
* @default '200px'
|
|
2390
|
+
*/
|
|
2391
|
+
labelWidth?: string | number;
|
|
2392
|
+
fieldMinWidth?: string | number;
|
|
2393
|
+
/**
|
|
2394
|
+
* Shared visual style for form wrappers and field components.
|
|
2395
|
+
* @default 'borderless'
|
|
2396
|
+
*/
|
|
2397
|
+
variant?: FormVariant;
|
|
2398
|
+
}
|
|
2399
|
+
interface FormGroupProps {
|
|
2400
|
+
/** Group title */
|
|
2401
|
+
title?: ReactNode;
|
|
2402
|
+
/** Group description */
|
|
2403
|
+
description?: ReactNode;
|
|
2404
|
+
/** Group icon (component or element) */
|
|
2405
|
+
icon?: any;
|
|
2406
|
+
/** Extra content on the right side of the header */
|
|
2407
|
+
extra?: ReactNode;
|
|
2408
|
+
/** Group children */
|
|
2409
|
+
children?: ReactNode;
|
|
2410
|
+
/** Additional CSS class */
|
|
2411
|
+
className?: string;
|
|
2412
|
+
/** Style object */
|
|
2413
|
+
style?: CSSProperties;
|
|
2414
|
+
/** Whether the group is collapsible */
|
|
2415
|
+
collapsible?: boolean;
|
|
2416
|
+
/** Whether the group is collapsed by default */
|
|
2417
|
+
defaultCollapsed?: boolean;
|
|
2418
|
+
/** Variant style for the group container */
|
|
2419
|
+
variant?: FormVariant;
|
|
2420
|
+
}
|
|
2421
|
+
|
|
2422
|
+
declare function Form<T extends Record<string, any>>({ children, onSubmit, form, initialValues, validate, className, style, layout, labelWidth, variant, fieldMinWidth, ...props }: FormProps<T>): react_jsx_runtime.JSX.Element;
|
|
2423
|
+
declare namespace Form {
|
|
2424
|
+
var displayName: string;
|
|
2425
|
+
}
|
|
2426
|
+
|
|
2427
|
+
type FormErrorProps = {
|
|
2428
|
+
message?: string;
|
|
2429
|
+
className?: string;
|
|
2430
|
+
style?: react__default.CSSProperties;
|
|
2431
|
+
};
|
|
2432
|
+
declare const FormError: {
|
|
2433
|
+
({ message, className, style }: FormErrorProps): react_jsx_runtime.JSX.Element | null;
|
|
2434
|
+
displayName: string;
|
|
2435
|
+
};
|
|
2436
|
+
|
|
2437
|
+
type FormInputProps<T extends Record<string, any>> = Omit<InputProps, 'name' | 'value' | 'onChange' | 'onBlur' | 'defaultValue' | 'form'> & {
|
|
2438
|
+
name: keyof T & string;
|
|
2439
|
+
label?: string;
|
|
2440
|
+
description?: react__default.ReactNode;
|
|
2441
|
+
form?: FormInstance<T>;
|
|
2442
|
+
required?: boolean;
|
|
2443
|
+
helperText?: react__default.ReactNode;
|
|
2444
|
+
onChange?: InputProps['onChange'];
|
|
2445
|
+
onBlur?: InputProps['onBlur'];
|
|
2446
|
+
rules?: FormFieldRules<T>;
|
|
2447
|
+
};
|
|
2448
|
+
type FormFieldRules<T extends Record<string, any>> = {
|
|
2449
|
+
required?: boolean | string | {
|
|
2450
|
+
message: string;
|
|
2451
|
+
};
|
|
2452
|
+
pattern?: {
|
|
2453
|
+
value: RegExp;
|
|
2454
|
+
message: string;
|
|
2455
|
+
};
|
|
2456
|
+
minLength?: {
|
|
2457
|
+
value: number;
|
|
2458
|
+
message: string;
|
|
2459
|
+
};
|
|
2460
|
+
maxLength?: {
|
|
2461
|
+
value: number;
|
|
2462
|
+
message: string;
|
|
2463
|
+
};
|
|
2464
|
+
validate?: (value: any, values: T) => string | boolean | void;
|
|
2465
|
+
} | string;
|
|
2466
|
+
declare const runRules: <T extends Record<string, any>>(rules: FormFieldRules<T> | undefined, value: any, values: T) => string | undefined;
|
|
2467
|
+
declare const FormInput: {
|
|
2468
|
+
<T extends Record<string, any>>({ name, label, description, form, required, helperText, className, id, variant: inputVariant, onChange, onBlur, rules, ...inputProps }: FormInputProps<T>): react_jsx_runtime.JSX.Element;
|
|
2469
|
+
displayName: string;
|
|
2470
|
+
};
|
|
2471
|
+
|
|
2472
|
+
type FormLabelProps = {
|
|
2473
|
+
htmlFor?: string;
|
|
2474
|
+
children: react__default.ReactNode;
|
|
2475
|
+
className?: string;
|
|
2476
|
+
description?: react__default.ReactNode;
|
|
2477
|
+
required?: boolean;
|
|
2478
|
+
};
|
|
2479
|
+
declare const FormLabel: {
|
|
2480
|
+
({ htmlFor, children, className, description, required }: FormLabelProps): react_jsx_runtime.JSX.Element;
|
|
2481
|
+
displayName: string;
|
|
2482
|
+
};
|
|
2483
|
+
|
|
2484
|
+
type FormTimePickerProps<T extends Record<string, any>> = Omit<TimePickerProps, 'name' | 'value' | 'onChange' | 'defaultValue' | 'form'> & {
|
|
2485
|
+
name: keyof T & string;
|
|
2486
|
+
label?: string;
|
|
2487
|
+
description?: react__default.ReactNode;
|
|
2488
|
+
form?: FormInstance<T>;
|
|
2489
|
+
required?: boolean;
|
|
2490
|
+
onValueChange?: (value: string | null, formatted: string) => void;
|
|
2491
|
+
rules?: FormFieldRules<T>;
|
|
2492
|
+
};
|
|
2493
|
+
declare const FormTimePicker: {
|
|
2494
|
+
<T extends Record<string, any>>({ name, label, description, form, required, className, variant: timeVariant, onValueChange, rules, ...pickerProps }: FormTimePickerProps<T>): react_jsx_runtime.JSX.Element;
|
|
2495
|
+
displayName: string;
|
|
2496
|
+
};
|
|
2497
|
+
|
|
2498
|
+
type FormCheckboxProps<T extends Record<string, any>> = Omit<CheckboxProps, 'checked' | 'defaultChecked' | 'onChange'> & {
|
|
2499
|
+
name: keyof T & string;
|
|
2500
|
+
label?: react__default.ReactNode;
|
|
2501
|
+
description?: react__default.ReactNode;
|
|
2502
|
+
form?: FormInstance<T>;
|
|
2503
|
+
rules?: FormFieldRules<T>;
|
|
2504
|
+
onChange?: (checked: boolean) => void;
|
|
2505
|
+
};
|
|
2506
|
+
declare const FormCheckbox: {
|
|
2507
|
+
<T extends Record<string, any>>({ name, label, description, form, className, rules, onChange, ...rest }: FormCheckboxProps<T>): react_jsx_runtime.JSX.Element;
|
|
2508
|
+
displayName: string;
|
|
2509
|
+
};
|
|
2510
|
+
|
|
2511
|
+
type SwitchSize = 'default' | 'small';
|
|
2512
|
+
type SwitchChangeEventHandler = (checked: boolean, event: MouseEvent<HTMLButtonElement> | KeyboardEvent<HTMLButtonElement>) => void;
|
|
2513
|
+
type SwitchClickEventHandler = SwitchChangeEventHandler;
|
|
2514
|
+
interface SwitchClassNames {
|
|
2515
|
+
content?: string;
|
|
2516
|
+
root?: string;
|
|
2517
|
+
thumb?: string;
|
|
2518
|
+
}
|
|
2519
|
+
interface SwitchStyles {
|
|
2520
|
+
content?: CSSProperties;
|
|
2521
|
+
root?: CSSProperties;
|
|
2522
|
+
thumb?: CSSProperties;
|
|
2523
|
+
}
|
|
2524
|
+
interface SwitchContextType {
|
|
2525
|
+
isChecked: boolean;
|
|
2526
|
+
isPressed: boolean;
|
|
2527
|
+
setIsChecked: (checked: boolean) => void;
|
|
2528
|
+
setIsPressed: (pressed: boolean) => void;
|
|
2529
|
+
}
|
|
2530
|
+
type SwitchRootProps = Omit<ComponentProps<typeof Switch$1.Root>, 'render'> & HTMLMotionProps<'button'> & {
|
|
2531
|
+
size?: SwitchSize;
|
|
2532
|
+
};
|
|
2533
|
+
type SwitchThumbProps = Omit<ComponentProps<typeof Switch$1.Thumb>, 'render'> & HTMLMotionProps<'span'> & {
|
|
2534
|
+
pressedAnimation?: TargetAndTransition | boolean;
|
|
2535
|
+
size?: SwitchSize;
|
|
2536
|
+
transition?: Transition;
|
|
2537
|
+
};
|
|
2538
|
+
type SwitchIconPosition = 'left' | 'right' | 'thumb';
|
|
2539
|
+
type SwitchIconProps = HTMLMotionProps<'span'> & {
|
|
2540
|
+
position: SwitchIconPosition;
|
|
2541
|
+
transition?: Transition;
|
|
2542
|
+
};
|
|
2543
|
+
interface SwitchProps {
|
|
2544
|
+
/**
|
|
2545
|
+
* Whether to set focus automatically when mounted
|
|
2546
|
+
*/
|
|
2547
|
+
autoFocus?: boolean;
|
|
2548
|
+
/**
|
|
2549
|
+
* Whether the switch is checked
|
|
2550
|
+
*/
|
|
2551
|
+
checked?: boolean;
|
|
2552
|
+
/**
|
|
2553
|
+
* Icon to show when checked (left position)
|
|
2554
|
+
*/
|
|
2555
|
+
checkedChildren?: ReactNode;
|
|
2556
|
+
/**
|
|
2557
|
+
* Custom class name
|
|
2558
|
+
*/
|
|
2559
|
+
className?: string;
|
|
2560
|
+
/**
|
|
2561
|
+
* Custom class names for each part
|
|
2562
|
+
*/
|
|
2563
|
+
classNames?: SwitchClassNames;
|
|
2564
|
+
/**
|
|
2565
|
+
* Initial checked state (uncontrolled)
|
|
2566
|
+
*/
|
|
2567
|
+
defaultChecked?: boolean;
|
|
2568
|
+
/**
|
|
2569
|
+
* Alias for `defaultChecked`
|
|
2570
|
+
*/
|
|
2571
|
+
defaultValue?: boolean;
|
|
2572
|
+
/**
|
|
2573
|
+
* Whether the switch is disabled
|
|
2574
|
+
*/
|
|
2575
|
+
disabled?: boolean;
|
|
2576
|
+
/**
|
|
2577
|
+
* Element id
|
|
2578
|
+
*/
|
|
2579
|
+
id?: string;
|
|
2580
|
+
/**
|
|
2581
|
+
* Show loading indicator
|
|
2582
|
+
*/
|
|
2583
|
+
loading?: boolean;
|
|
2584
|
+
/**
|
|
2585
|
+
* Name attribute for form submission
|
|
2586
|
+
*/
|
|
2587
|
+
name?: string;
|
|
2588
|
+
/**
|
|
2589
|
+
* Callback when the switch state changes
|
|
2590
|
+
*/
|
|
2591
|
+
onChange?: SwitchChangeEventHandler;
|
|
2592
|
+
/**
|
|
2593
|
+
* Callback when clicking the switch
|
|
2594
|
+
*/
|
|
2595
|
+
onClick?: SwitchClickEventHandler;
|
|
2596
|
+
/**
|
|
2597
|
+
* Reference to the root element
|
|
2598
|
+
*/
|
|
2599
|
+
ref?: Ref<HTMLButtonElement>;
|
|
2600
|
+
/**
|
|
2601
|
+
* Additional class name for root element
|
|
2602
|
+
*/
|
|
2603
|
+
rootClassName?: string;
|
|
2604
|
+
/**
|
|
2605
|
+
* Size of the switch
|
|
2606
|
+
* @default 'default'
|
|
2607
|
+
*/
|
|
2608
|
+
size?: SwitchSize;
|
|
2609
|
+
/**
|
|
2610
|
+
* Custom inline style
|
|
2611
|
+
*/
|
|
2612
|
+
style?: CSSProperties;
|
|
2613
|
+
/**
|
|
2614
|
+
* Custom styles for each part
|
|
2615
|
+
*/
|
|
2616
|
+
styles?: SwitchStyles;
|
|
2617
|
+
/**
|
|
2618
|
+
* Tab index for keyboard navigation
|
|
2619
|
+
*/
|
|
2620
|
+
tabIndex?: number;
|
|
2621
|
+
/**
|
|
2622
|
+
* Native title attribute
|
|
2623
|
+
*/
|
|
2624
|
+
title?: string;
|
|
2625
|
+
/**
|
|
2626
|
+
* Icon to show when unchecked (right position)
|
|
2627
|
+
*/
|
|
2628
|
+
unCheckedChildren?: ReactNode;
|
|
2629
|
+
/**
|
|
2630
|
+
* Alias for `checked`
|
|
2631
|
+
*/
|
|
2632
|
+
value?: boolean;
|
|
2633
|
+
}
|
|
2634
|
+
|
|
2635
|
+
type FormSwitchProps<T extends Record<string, any>> = Omit<SwitchProps, 'checked' | 'defaultChecked' | 'onChange' | 'value'> & {
|
|
2636
|
+
name: keyof T & string;
|
|
2637
|
+
label?: string;
|
|
2638
|
+
description?: react__default.ReactNode;
|
|
2639
|
+
form?: FormInstance<T>;
|
|
2640
|
+
rules?: FormFieldRules<T>;
|
|
2641
|
+
onChange?: (checked: boolean) => void;
|
|
2642
|
+
};
|
|
2643
|
+
declare const FormSwitch: {
|
|
2644
|
+
<T extends Record<string, any>>({ name, label, description, form, className, rules, onChange, ...rest }: FormSwitchProps<T>): react_jsx_runtime.JSX.Element;
|
|
2645
|
+
displayName: string;
|
|
2646
|
+
};
|
|
2647
|
+
|
|
2648
|
+
type FormDatePickerProps<T extends Record<string, any>> = Omit<DatePickerProps, 'name' | 'value' | 'onChange' | 'defaultValue' | 'form'> & {
|
|
2649
|
+
name: keyof T & string;
|
|
2650
|
+
label?: string;
|
|
2651
|
+
description?: react__default.ReactNode;
|
|
2652
|
+
form?: FormInstance<T>;
|
|
2653
|
+
rules?: FormFieldRules<T>;
|
|
2654
|
+
};
|
|
2655
|
+
declare const FormDatePicker: {
|
|
2656
|
+
<T extends Record<string, any>>({ name, label, description, form, className, variant: dateVariant, rules, ...rest }: FormDatePickerProps<T>): react_jsx_runtime.JSX.Element;
|
|
2657
|
+
displayName: string;
|
|
2658
|
+
};
|
|
2659
|
+
|
|
2660
|
+
type FormSelectProps<T extends Record<string, any>, Value = string> = Omit<SelectProps<Value>, 'name' | 'value' | 'onChange' | 'defaultValue' | 'form'> & {
|
|
2661
|
+
name: keyof T & string;
|
|
2662
|
+
label?: string;
|
|
2663
|
+
description?: react__default.ReactNode;
|
|
2664
|
+
form?: FormInstance<T>;
|
|
2665
|
+
rules?: FormFieldRules<T>;
|
|
2666
|
+
options?: SelectOption<Value>[];
|
|
2667
|
+
};
|
|
2668
|
+
declare const FormSelect: {
|
|
2669
|
+
<T extends Record<string, any>, Value = string>({ name, label, description, form, className, variant: selectVariant, rules, ...rest }: FormSelectProps<T, Value>): react_jsx_runtime.JSX.Element;
|
|
2670
|
+
displayName: string;
|
|
2671
|
+
};
|
|
2672
|
+
|
|
2673
|
+
interface SegmentedProps extends SegmentedProps$1 {
|
|
2674
|
+
glass?: boolean;
|
|
2675
|
+
iconProps?: Omit<IconProps$1, 'icon'>;
|
|
2676
|
+
padding?: string | number;
|
|
2677
|
+
ref?: Ref<HTMLDivElement>;
|
|
2678
|
+
shadow?: boolean;
|
|
2679
|
+
variant?: 'filled' | 'outlined' | 'borderless';
|
|
2680
|
+
}
|
|
2681
|
+
|
|
2682
|
+
type FormSegmentProps<T extends Record<string, any>> = Omit<SegmentedProps, 'name' | 'value' | 'onChange' | 'defaultValue' | 'form'> & {
|
|
2683
|
+
name: keyof T & string;
|
|
2684
|
+
label?: string;
|
|
2685
|
+
description?: react__default.ReactNode;
|
|
2686
|
+
form?: FormInstance<T>;
|
|
2687
|
+
rules?: FormFieldRules<T>;
|
|
2688
|
+
};
|
|
2689
|
+
declare const FormSegment: {
|
|
2690
|
+
<T extends Record<string, any>>({ name, label, description, form, className, rules, ...rest }: FormSegmentProps<T>): react_jsx_runtime.JSX.Element;
|
|
2691
|
+
displayName: string;
|
|
2692
|
+
};
|
|
2693
|
+
|
|
2694
|
+
declare const FormGroup: {
|
|
2695
|
+
({ title, description, icon, extra, children, className, style, collapsible, defaultCollapsed, variant: groupVariant, }: FormGroupProps): react_jsx_runtime.JSX.Element;
|
|
2696
|
+
displayName: string;
|
|
2697
|
+
};
|
|
2698
|
+
|
|
2699
|
+
type FormComponent = <T extends Record<string, any>>(props: FormProps<T> & RefAttributes<HTMLFormElement>) => ReturnType<typeof Form>;
|
|
2700
|
+
type FormCompound = FormComponent & {
|
|
2701
|
+
Input: typeof FormInput;
|
|
2702
|
+
Label: typeof FormLabel;
|
|
2703
|
+
Error: typeof FormError;
|
|
2704
|
+
TimePicker: typeof FormTimePicker;
|
|
2705
|
+
Checkbox: typeof FormCheckbox;
|
|
2706
|
+
Switch: typeof FormSwitch;
|
|
2707
|
+
DatePicker: typeof FormDatePicker;
|
|
2708
|
+
Select: typeof FormSelect;
|
|
2709
|
+
Segment: typeof FormSegment;
|
|
2710
|
+
Group: typeof FormGroup;
|
|
2711
|
+
};
|
|
2712
|
+
declare const FormComponentImpl: FormCompound;
|
|
2713
|
+
|
|
2714
|
+
type ModalProps = Omit<ModalProps$1, 'okType' | 'wrapClassName'> & {
|
|
2715
|
+
allowFullscreen?: boolean;
|
|
2716
|
+
enableResponsive?: boolean;
|
|
2717
|
+
paddings?: {
|
|
2718
|
+
desktop?: number;
|
|
2719
|
+
mobile?: number;
|
|
2720
|
+
};
|
|
2721
|
+
};
|
|
2722
|
+
type ModalContextValue = {
|
|
2723
|
+
close: () => void;
|
|
2724
|
+
setCanDismissByClickOutside: (value: boolean) => void;
|
|
2725
|
+
};
|
|
2726
|
+
type ModalInstance = ModalContextValue & {
|
|
2727
|
+
destroy: () => void;
|
|
2728
|
+
update: (nextProps: Partial<ImperativeModalProps>) => void;
|
|
2729
|
+
};
|
|
2730
|
+
type ImperativeModalProps = ModalProps;
|
|
2731
|
+
type RawModalComponentProps = {
|
|
2732
|
+
onClose: () => void;
|
|
2733
|
+
open: boolean;
|
|
2734
|
+
};
|
|
2735
|
+
type RawModalComponent<P = any> = ComponentType<P>;
|
|
2736
|
+
type RawModalOptions<OpenKey extends PropertyKey = 'open', CloseKey extends PropertyKey = 'onClose'> = {
|
|
2737
|
+
destroyDelay?: number;
|
|
2738
|
+
destroyOnClose?: boolean;
|
|
2739
|
+
onCloseKey?: CloseKey;
|
|
2740
|
+
openKey?: OpenKey;
|
|
2741
|
+
};
|
|
2742
|
+
type RawModalKeyOptions<OpenKey extends PropertyKey = 'open', CloseKey extends PropertyKey = 'onClose'> = RawModalOptions<OpenKey, CloseKey> & {
|
|
2743
|
+
onCloseKey: CloseKey;
|
|
2744
|
+
openKey: OpenKey;
|
|
2745
|
+
};
|
|
2746
|
+
type RawModalInstance<P = any, OpenKey extends PropertyKey = 'open', CloseKey extends PropertyKey = 'onClose'> = ModalContextValue & {
|
|
2747
|
+
destroy: () => void;
|
|
2748
|
+
update: (nextProps: Partial<Omit<P, Extract<OpenKey, keyof P> | Extract<CloseKey, keyof P>>>) => void;
|
|
2749
|
+
};
|
|
2750
|
+
|
|
2751
|
+
type ModalHostProps = {
|
|
2752
|
+
root?: HTMLElement | ShadowRoot | null;
|
|
2753
|
+
};
|
|
2754
|
+
declare const ModalHost: ({ root }: ModalHostProps) => react_jsx_runtime.JSX.Element | null;
|
|
2755
|
+
declare const createModal: (props: ImperativeModalProps) => ModalInstance;
|
|
2756
|
+
declare function createRawModal<P extends RawModalComponentProps>(component: RawModalComponent<P>, props: Omit<P, 'open' | 'onClose'>, options?: RawModalOptions): RawModalInstance<P>;
|
|
2757
|
+
declare function createRawModal<P, OpenKey extends keyof P, CloseKey extends keyof P>(component: RawModalComponent<P>, props: Omit<P, OpenKey | CloseKey>, options: RawModalKeyOptions<OpenKey, CloseKey>): RawModalInstance<P, OpenKey, CloseKey>;
|
|
2758
|
+
|
|
2759
|
+
declare const Modal: react.NamedExoticComponent<ModalProps>;
|
|
2760
|
+
|
|
2761
|
+
declare const ModalProvider: react.NamedExoticComponent<{
|
|
2762
|
+
children: ReactNode;
|
|
2763
|
+
value: ModalContextValue;
|
|
2764
|
+
}>;
|
|
2765
|
+
declare const useModalContext: () => ModalContextValue;
|
|
2766
|
+
|
|
2767
|
+
interface FormModalProps<T extends Record<string, any>> extends Omit<ModalProps, 'footer' | 'onOk' | 'children' | 'title'> {
|
|
2768
|
+
children: ReactNode;
|
|
2769
|
+
form?: FormInstance<T>;
|
|
2770
|
+
initialValues?: T;
|
|
2771
|
+
onSubmit?: FormProps<T>['onSubmit'];
|
|
2772
|
+
submitButtonProps?: ButtonProps;
|
|
2773
|
+
submitText?: string;
|
|
2774
|
+
title?: ReactNode;
|
|
2775
|
+
validate?: FormProps<T>['validate'];
|
|
2776
|
+
loading?: boolean;
|
|
2777
|
+
}
|
|
2778
|
+
|
|
2779
|
+
declare const FormModal: {
|
|
2780
|
+
<T extends Record<string, any>>({ children, form, initialValues, onSubmit, validate, submitText, submitButtonProps, loading, ...modalProps }: FormModalProps<T>): react_jsx_runtime.JSX.Element;
|
|
2781
|
+
displayName: string;
|
|
2782
|
+
};
|
|
2783
|
+
|
|
2784
|
+
interface GridProps extends Omit<FlexProps, 'gap'> {
|
|
2785
|
+
gap?: string | number;
|
|
2786
|
+
maxItemWidth?: string | number;
|
|
2787
|
+
ref?: Ref<HTMLDivElement>;
|
|
2788
|
+
rows?: number;
|
|
2789
|
+
}
|
|
2790
|
+
|
|
2791
|
+
declare const Grid: FC<GridProps>;
|
|
2792
|
+
|
|
2793
|
+
/**
|
|
2794
|
+
* Predefined smooth corners masks for common corner values
|
|
2795
|
+
*/
|
|
2796
|
+
declare const SMOOTH_CORNER_MASKS: {
|
|
2797
|
+
readonly circle: string;
|
|
2798
|
+
readonly ios: string;
|
|
2799
|
+
readonly sharp: string;
|
|
2800
|
+
readonly smooth: string;
|
|
2801
|
+
readonly square: string;
|
|
2802
|
+
readonly squircle: string;
|
|
2803
|
+
};
|
|
2804
|
+
|
|
2805
|
+
type AvatarItem = string | Omit<AvatarProps, 'size'>;
|
|
2806
|
+
interface GroupAvatarProps extends Omit<BlockProps, 'width' | 'height' | 'variant'> {
|
|
2807
|
+
avatarShape?: AvatarProps['shape'];
|
|
2808
|
+
avatars?: AvatarItem[];
|
|
2809
|
+
cornerShape?: keyof typeof SMOOTH_CORNER_MASKS;
|
|
2810
|
+
grid?: 2 | 3 | 'auto';
|
|
2811
|
+
ref?: Ref<HTMLDivElement>;
|
|
2812
|
+
size?: number;
|
|
2813
|
+
}
|
|
2814
|
+
|
|
2815
|
+
declare const GroupAvatar: FC<GroupAvatarProps>;
|
|
2816
|
+
|
|
2817
|
+
interface GuideCardProps extends Omit<FlexProps, 'title'> {
|
|
2818
|
+
afterClose?: () => void;
|
|
2819
|
+
alt?: string;
|
|
2820
|
+
classNames?: {
|
|
2821
|
+
content?: string;
|
|
2822
|
+
cover?: string;
|
|
2823
|
+
};
|
|
2824
|
+
closable?: boolean;
|
|
2825
|
+
closeIconProps?: Omit<ActionIconProps, 'icon' | 'onClick'>;
|
|
2826
|
+
cover?: string;
|
|
2827
|
+
coverProps?: ImgProps & ImageProps$2 & {
|
|
2828
|
+
priority?: boolean;
|
|
2829
|
+
};
|
|
2830
|
+
desc?: ReactNode;
|
|
2831
|
+
height?: number;
|
|
2832
|
+
onClose?: ActionIconProps['onClick'];
|
|
2833
|
+
ref?: Ref<HTMLDivElement>;
|
|
2834
|
+
shadow?: boolean;
|
|
2835
|
+
styles?: {
|
|
2836
|
+
content?: CSSProperties;
|
|
2837
|
+
cover?: CSSProperties;
|
|
2838
|
+
};
|
|
2839
|
+
title?: ReactNode;
|
|
2840
|
+
variant?: 'filled' | 'outlined' | 'borderless';
|
|
2841
|
+
width?: number;
|
|
2842
|
+
}
|
|
2843
|
+
|
|
2844
|
+
declare const GuideCard: react.NamedExoticComponent<GuideCardProps>;
|
|
2845
|
+
|
|
2846
|
+
interface HeaderProps extends FlexProps {
|
|
2847
|
+
actions?: ReactNode;
|
|
2848
|
+
actionsClassName?: string;
|
|
2849
|
+
actionsStyle?: CSSProperties;
|
|
2850
|
+
logo?: ReactNode;
|
|
2851
|
+
logoClassName?: string;
|
|
2852
|
+
logoStyle?: CSSProperties;
|
|
2853
|
+
nav?: ReactNode;
|
|
2854
|
+
navClassName?: string;
|
|
2855
|
+
navStyle?: CSSProperties;
|
|
2856
|
+
ref?: Ref<HTMLDivElement>;
|
|
2857
|
+
}
|
|
2858
|
+
|
|
2859
|
+
declare const Header: react.NamedExoticComponent<HeaderProps>;
|
|
2860
|
+
|
|
2861
|
+
interface HighlighterThemeItem {
|
|
2862
|
+
displayName: string;
|
|
2863
|
+
id: string;
|
|
2864
|
+
}
|
|
2865
|
+
declare const highlighterThemes: HighlighterThemeItem[];
|
|
2866
|
+
|
|
2867
|
+
interface SyntaxHighlighterProps extends DivProps {
|
|
2868
|
+
animated?: boolean;
|
|
2869
|
+
children: string;
|
|
2870
|
+
enableTransformer?: HighlighterProps['enableTransformer'];
|
|
2871
|
+
language: HighlighterProps['language'];
|
|
2872
|
+
ref?: Ref<HTMLDivElement>;
|
|
2873
|
+
theme?: HighlighterProps['theme'];
|
|
2874
|
+
variant?: HighlighterProps['variant'];
|
|
2875
|
+
}
|
|
2876
|
+
interface HighlighterProps extends Omit<FlexProps, 'children' | 'wrap'> {
|
|
2877
|
+
actionIconSize?: ActionIconProps['size'];
|
|
2878
|
+
actionsRender?: (props: {
|
|
2879
|
+
actionIconSize: ActionIconProps['size'];
|
|
2880
|
+
content: string;
|
|
2881
|
+
getContent: () => string;
|
|
2882
|
+
language: string;
|
|
2883
|
+
originalNode: ReactNode;
|
|
2884
|
+
}) => ReactNode;
|
|
2885
|
+
allowChangeLanguage?: boolean;
|
|
2886
|
+
animated?: boolean;
|
|
2887
|
+
bodyRender?: (props: {
|
|
2888
|
+
content: string;
|
|
2889
|
+
language: string;
|
|
2890
|
+
originalNode: ReactNode;
|
|
2891
|
+
}) => ReactNode;
|
|
2892
|
+
children: string;
|
|
2893
|
+
classNames?: {
|
|
2894
|
+
body?: string;
|
|
2895
|
+
content?: string;
|
|
2896
|
+
header?: string;
|
|
2897
|
+
};
|
|
2898
|
+
copyable?: boolean;
|
|
2899
|
+
defaultExpand?: boolean;
|
|
2900
|
+
enableTransformer?: boolean;
|
|
2901
|
+
fileName?: string;
|
|
2902
|
+
fullFeatured?: boolean;
|
|
2903
|
+
icon?: ReactNode;
|
|
2904
|
+
language: string;
|
|
2905
|
+
shadow?: boolean;
|
|
2906
|
+
showLanguage?: boolean;
|
|
2907
|
+
styles?: {
|
|
2908
|
+
body?: CSSProperties;
|
|
2909
|
+
content?: CSSProperties;
|
|
2910
|
+
header?: CSSProperties;
|
|
2911
|
+
};
|
|
2912
|
+
theme?: 'lobe-theme' | BuiltinTheme;
|
|
2913
|
+
variant?: 'filled' | 'outlined' | 'borderless';
|
|
2914
|
+
wrap?: boolean;
|
|
2915
|
+
}
|
|
2916
|
+
|
|
2917
|
+
declare const Highlighter: react.NamedExoticComponent<HighlighterProps>;
|
|
2918
|
+
|
|
2919
|
+
declare const SyntaxHighlighter: react.NamedExoticComponent<SyntaxHighlighterProps>;
|
|
2920
|
+
|
|
2921
|
+
/**
|
|
2922
|
+
* Preprocessing options for markdown content
|
|
2923
|
+
*/
|
|
2924
|
+
interface PreprocessOptions {
|
|
2925
|
+
citationsLength?: number;
|
|
2926
|
+
enableCustomFootnotes?: boolean;
|
|
2927
|
+
enableLatex?: boolean;
|
|
2928
|
+
}
|
|
2929
|
+
declare const preprocessMarkdownContent: (str: string, { enableCustomFootnotes, enableLatex, citationsLength }?: PreprocessOptions) => string;
|
|
2930
|
+
|
|
2931
|
+
interface HotkeyInputProps {
|
|
2932
|
+
allowReset?: boolean;
|
|
2933
|
+
className?: string;
|
|
2934
|
+
defaultValue?: string;
|
|
2935
|
+
disabled?: boolean;
|
|
2936
|
+
hotkeyConflicts?: string[];
|
|
2937
|
+
isApple?: boolean;
|
|
2938
|
+
onBlur?: InputProps$1['onBlur'];
|
|
2939
|
+
onChange?: (value: string) => void;
|
|
2940
|
+
onConflict?: (conflictKey: string) => void;
|
|
2941
|
+
onFocus?: InputProps$1['onFocus'];
|
|
2942
|
+
onReset?: (currentValue: string, resetValue: string) => void;
|
|
2943
|
+
placeholder?: string;
|
|
2944
|
+
resetValue?: string;
|
|
2945
|
+
shadow?: boolean;
|
|
2946
|
+
style?: CSSProperties;
|
|
2947
|
+
texts?: {
|
|
2948
|
+
conflicts?: string;
|
|
2949
|
+
invalidCombination?: string;
|
|
2950
|
+
reset?: string;
|
|
2951
|
+
};
|
|
2952
|
+
value?: string;
|
|
2953
|
+
variant?: 'filled' | 'borderless' | 'outlined';
|
|
2954
|
+
}
|
|
2955
|
+
|
|
2956
|
+
declare const HotkeyInput: react.NamedExoticComponent<HotkeyInputProps>;
|
|
2957
|
+
|
|
2958
|
+
interface PreviewGroupPreviewOptions extends GroupPreviewConfig {
|
|
2959
|
+
classNames?: {
|
|
2960
|
+
root?: string;
|
|
2961
|
+
};
|
|
2962
|
+
toolbarAddon?: ReactNode;
|
|
2963
|
+
}
|
|
2964
|
+
interface PreviewGroupProps {
|
|
2965
|
+
children?: ReactNode;
|
|
2966
|
+
enable?: boolean;
|
|
2967
|
+
items?: string[];
|
|
2968
|
+
preview?: boolean | PreviewGroupPreviewOptions;
|
|
2969
|
+
}
|
|
2970
|
+
interface ImagePreviewOptions extends PreviewConfig {
|
|
2971
|
+
toolbarAddon?: ReactNode;
|
|
2972
|
+
}
|
|
2973
|
+
interface ImageProps$1 extends Omit<ImageProps$2, 'preview'> {
|
|
2974
|
+
actions?: ReactNode;
|
|
2975
|
+
alwaysShowActions?: boolean;
|
|
2976
|
+
classNames?: {
|
|
2977
|
+
image?: string;
|
|
2978
|
+
wrapper?: string;
|
|
2979
|
+
};
|
|
2980
|
+
isLoading?: boolean;
|
|
2981
|
+
maxHeight?: number | string;
|
|
2982
|
+
maxWidth?: number | string;
|
|
2983
|
+
minHeight?: number | string;
|
|
2984
|
+
minWidth?: number | string;
|
|
2985
|
+
objectFit?: 'cover' | 'contain';
|
|
2986
|
+
preview?: boolean | ImagePreviewOptions;
|
|
2987
|
+
ref?: Ref<HTMLDivElement>;
|
|
2988
|
+
size?: number | string;
|
|
2989
|
+
styles?: {
|
|
2990
|
+
image?: CSSProperties;
|
|
2991
|
+
wrapper?: CSSProperties;
|
|
2992
|
+
};
|
|
2993
|
+
toolbarAddon?: ReactNode;
|
|
2994
|
+
variant?: 'borderless' | 'filled' | 'outlined';
|
|
2995
|
+
}
|
|
2996
|
+
|
|
2997
|
+
declare const PreviewGroup: react.NamedExoticComponent<PreviewGroupProps>;
|
|
2998
|
+
|
|
2999
|
+
interface IImage {
|
|
3000
|
+
(props: ImageProps$1): ReactNode;
|
|
3001
|
+
PreviewGroup: typeof PreviewGroup;
|
|
3002
|
+
}
|
|
3003
|
+
declare const Image: IImage;
|
|
3004
|
+
|
|
3005
|
+
interface ImageSelectItem {
|
|
3006
|
+
alt?: string;
|
|
3007
|
+
icon?: IconProps$1['icon'];
|
|
3008
|
+
img: string;
|
|
3009
|
+
label: ReactNode;
|
|
3010
|
+
value: string;
|
|
3011
|
+
}
|
|
3012
|
+
interface ImageSelectProps extends FlexProps {
|
|
3013
|
+
className?: string;
|
|
3014
|
+
classNames?: {
|
|
3015
|
+
img?: string;
|
|
3016
|
+
};
|
|
3017
|
+
defaultValue?: SelectProps$1['defaultValue'];
|
|
3018
|
+
height?: number;
|
|
3019
|
+
onChange?: (value: this['value']) => void;
|
|
3020
|
+
options?: ImageSelectItem[];
|
|
3021
|
+
ref?: Ref<HTMLDivElement>;
|
|
3022
|
+
style?: CSSProperties;
|
|
3023
|
+
styles?: {
|
|
3024
|
+
img?: CSSProperties;
|
|
3025
|
+
};
|
|
3026
|
+
unoptimized?: boolean;
|
|
3027
|
+
value?: SelectProps$1['value'];
|
|
3028
|
+
width?: number;
|
|
3029
|
+
}
|
|
3030
|
+
|
|
3031
|
+
declare const ImageSelect: react.NamedExoticComponent<ImageSelectProps>;
|
|
3032
|
+
|
|
3033
|
+
declare const LayoutFooter: react.NamedExoticComponent<DivProps>;
|
|
3034
|
+
|
|
3035
|
+
interface LayoutProps {
|
|
3036
|
+
asideWidth?: number;
|
|
3037
|
+
children?: ReactNode;
|
|
3038
|
+
content?: ReactNode;
|
|
3039
|
+
footer?: ReactNode;
|
|
3040
|
+
header?: ReactNode;
|
|
3041
|
+
headerHeight?: number;
|
|
3042
|
+
helmet?: ReactNode;
|
|
3043
|
+
sidebar?: ReactNode;
|
|
3044
|
+
toc?: ReactNode;
|
|
3045
|
+
tocWidth?: number;
|
|
3046
|
+
}
|
|
3047
|
+
type LayoutFooterProps = DivProps;
|
|
3048
|
+
interface LayoutHeaderProps extends DivProps {
|
|
3049
|
+
headerHeight?: number;
|
|
3050
|
+
}
|
|
3051
|
+
type LayoutMainProps = DivProps;
|
|
3052
|
+
interface LayoutSidebarProps extends DivProps {
|
|
3053
|
+
headerHeight?: number;
|
|
3054
|
+
}
|
|
3055
|
+
interface LayoutSidebarInnerProps extends DivProps {
|
|
3056
|
+
headerHeight?: number;
|
|
3057
|
+
}
|
|
3058
|
+
interface LayoutTocProps extends DivProps {
|
|
3059
|
+
tocWidth?: number;
|
|
3060
|
+
}
|
|
3061
|
+
|
|
3062
|
+
declare const LayoutHeader: react.NamedExoticComponent<LayoutHeaderProps>;
|
|
3063
|
+
|
|
3064
|
+
declare const LayoutMain: react.NamedExoticComponent<DivProps>;
|
|
3065
|
+
|
|
3066
|
+
declare const LayoutSidebar: react.NamedExoticComponent<LayoutSidebarProps>;
|
|
3067
|
+
|
|
3068
|
+
declare const LayoutSidebarInner: react.NamedExoticComponent<LayoutSidebarInnerProps>;
|
|
3069
|
+
|
|
3070
|
+
declare const LayoutToc: react.NamedExoticComponent<LayoutTocProps>;
|
|
3071
|
+
|
|
3072
|
+
interface ILayout {
|
|
3073
|
+
(props: LayoutProps): ReactNode;
|
|
3074
|
+
Footer: typeof LayoutFooter;
|
|
3075
|
+
Header: typeof LayoutHeader;
|
|
3076
|
+
Main: typeof LayoutMain;
|
|
3077
|
+
Sidebar: typeof LayoutSidebar;
|
|
3078
|
+
SidebarInner: typeof LayoutSidebarInner;
|
|
3079
|
+
Toc: typeof LayoutToc;
|
|
3080
|
+
}
|
|
3081
|
+
declare const Layout: ILayout;
|
|
3082
|
+
|
|
3083
|
+
interface ListItemProps extends Omit<FlexProps, 'title'> {
|
|
3084
|
+
actions?: ReactNode;
|
|
3085
|
+
active?: boolean;
|
|
3086
|
+
addon?: ReactNode;
|
|
3087
|
+
avatar?: ReactNode;
|
|
3088
|
+
classNames?: {
|
|
3089
|
+
actions?: string;
|
|
3090
|
+
container?: string;
|
|
3091
|
+
content?: string;
|
|
3092
|
+
date?: string;
|
|
3093
|
+
desc?: string;
|
|
3094
|
+
pin?: string;
|
|
3095
|
+
title?: string;
|
|
3096
|
+
};
|
|
3097
|
+
date?: number;
|
|
3098
|
+
description?: ReactNode;
|
|
3099
|
+
key: string;
|
|
3100
|
+
loading?: boolean;
|
|
3101
|
+
onHoverChange?: (hover: boolean) => void;
|
|
3102
|
+
pin?: boolean;
|
|
3103
|
+
ref?: Ref<HTMLDivElement>;
|
|
3104
|
+
showAction?: boolean;
|
|
3105
|
+
styles?: {
|
|
3106
|
+
actions?: CSSProperties;
|
|
3107
|
+
container?: CSSProperties;
|
|
3108
|
+
content?: CSSProperties;
|
|
3109
|
+
date?: CSSProperties;
|
|
3110
|
+
desc?: CSSProperties;
|
|
3111
|
+
pin?: CSSProperties;
|
|
3112
|
+
title?: CSSProperties;
|
|
3113
|
+
};
|
|
3114
|
+
title: ReactNode;
|
|
3115
|
+
}
|
|
3116
|
+
interface ListProps extends Omit<FlexProps, 'onClick'> {
|
|
3117
|
+
activeKey?: string;
|
|
3118
|
+
classNames?: {
|
|
3119
|
+
item?: string;
|
|
3120
|
+
} & ListItemProps['classNames'];
|
|
3121
|
+
items: ListItemProps[];
|
|
3122
|
+
onClick?: (props: {
|
|
3123
|
+
item: ListItemProps;
|
|
3124
|
+
key: ListItemProps['key'];
|
|
3125
|
+
}) => void;
|
|
3126
|
+
ref?: Ref<HTMLDivElement>;
|
|
3127
|
+
styles?: {
|
|
3128
|
+
item?: CSSProperties;
|
|
3129
|
+
} & ListItemProps['styles'];
|
|
3130
|
+
}
|
|
3131
|
+
|
|
3132
|
+
declare const ListItem: react.NamedExoticComponent<ListItemProps>;
|
|
3133
|
+
|
|
3134
|
+
interface IList {
|
|
3135
|
+
(props: ListProps & RefAttributes<HTMLDivElement>): ReactNode;
|
|
3136
|
+
Item: typeof ListItem;
|
|
3137
|
+
}
|
|
3138
|
+
declare const List: IList;
|
|
3139
|
+
|
|
3140
|
+
declare const SELECT_CONTAINER_ATTR = "data-custom-select-container";
|
|
3141
|
+
declare const CUSTOM_SELECT_CONTAINER_ATTR = "data-custom-select-container";
|
|
3142
|
+
|
|
3143
|
+
declare const SelectRoot: typeof Select$1.Root;
|
|
3144
|
+
declare const SelectBackdrop: react.ForwardRefExoticComponent<_base_ui_react_select.SelectBackdropProps & react.RefAttributes<HTMLDivElement>>;
|
|
3145
|
+
declare const SelectSeparator: react.ForwardRefExoticComponent<node_modules__base_ui_react_esm_separator_Separator.SeparatorProps & react.RefAttributes<HTMLDivElement>>;
|
|
3146
|
+
type SelectTriggerProps = Omit<ComponentPropsWithRef<typeof Select$1.Trigger>, 'children' | 'render'> & {
|
|
3147
|
+
children: ComponentProps<typeof Select$1.Trigger>['children'];
|
|
3148
|
+
shadow?: boolean;
|
|
3149
|
+
size?: SelectSize;
|
|
3150
|
+
variant?: SelectVariant;
|
|
3151
|
+
};
|
|
3152
|
+
declare const SelectTrigger: {
|
|
3153
|
+
({ children, className, nativeButton, shadow, size, variant, ref: refProp, ...rest }: SelectTriggerProps): react_jsx_runtime.JSX.Element;
|
|
3154
|
+
displayName: string;
|
|
3155
|
+
};
|
|
3156
|
+
type SelectIconProps = ComponentProps<typeof Select$1.Icon>;
|
|
3157
|
+
declare const SelectIcon: {
|
|
3158
|
+
({ className, ...rest }: SelectIconProps): react_jsx_runtime.JSX.Element;
|
|
3159
|
+
displayName: string;
|
|
3160
|
+
};
|
|
3161
|
+
type SelectValueProps = ComponentProps<typeof Select$1.Value>;
|
|
3162
|
+
declare const SelectValue: {
|
|
3163
|
+
({ className, ...rest }: SelectValueProps): react_jsx_runtime.JSX.Element;
|
|
3164
|
+
displayName: string;
|
|
3165
|
+
};
|
|
3166
|
+
type SelectPortalProps = ComponentProps<typeof Select$1.Portal> & {
|
|
3167
|
+
/**
|
|
3168
|
+
* When `container` is not provided, it uses a shared container created by `usePortalContainer`.
|
|
3169
|
+
*/
|
|
3170
|
+
container?: HTMLElement | null;
|
|
3171
|
+
};
|
|
3172
|
+
declare const SelectPortal: {
|
|
3173
|
+
({ container, ...rest }: SelectPortalProps): react_jsx_runtime.JSX.Element;
|
|
3174
|
+
displayName: string;
|
|
3175
|
+
};
|
|
3176
|
+
type SelectPositionerProps = ComponentProps<typeof Select$1.Positioner>;
|
|
3177
|
+
declare const SelectPositioner: {
|
|
3178
|
+
({ align, alignItemWithTrigger, className, side, sideOffset, ...rest }: SelectPositionerProps): react_jsx_runtime.JSX.Element;
|
|
3179
|
+
displayName: string;
|
|
3180
|
+
};
|
|
3181
|
+
type SelectPopupProps = ComponentProps<typeof Select$1.Popup>;
|
|
3182
|
+
declare const SelectPopup: {
|
|
3183
|
+
({ className, ...rest }: SelectPopupProps): react_jsx_runtime.JSX.Element;
|
|
3184
|
+
displayName: string;
|
|
3185
|
+
};
|
|
3186
|
+
type SelectListProps = ComponentProps<typeof Select$1.List>;
|
|
3187
|
+
declare const SelectList: {
|
|
3188
|
+
({ className, ...rest }: SelectListProps): react_jsx_runtime.JSX.Element;
|
|
3189
|
+
displayName: string;
|
|
3190
|
+
};
|
|
3191
|
+
type SelectItemProps = ComponentProps<typeof Select$1.Item>;
|
|
3192
|
+
declare const SelectItem: {
|
|
3193
|
+
({ className, ...rest }: SelectItemProps): react_jsx_runtime.JSX.Element;
|
|
3194
|
+
displayName: string;
|
|
3195
|
+
};
|
|
3196
|
+
type SelectItemTextProps = ComponentProps<typeof Select$1.ItemText>;
|
|
3197
|
+
declare const SelectItemText: {
|
|
3198
|
+
({ className, ...rest }: SelectItemTextProps): react_jsx_runtime.JSX.Element;
|
|
3199
|
+
displayName: string;
|
|
3200
|
+
};
|
|
3201
|
+
type SelectItemIndicatorProps = ComponentProps<typeof Select$1.ItemIndicator>;
|
|
3202
|
+
declare const SelectItemIndicator: {
|
|
3203
|
+
({ className, ...rest }: SelectItemIndicatorProps): react_jsx_runtime.JSX.Element;
|
|
3204
|
+
displayName: string;
|
|
3205
|
+
};
|
|
3206
|
+
type SelectGroupProps = ComponentProps<typeof Select$1.Group>;
|
|
3207
|
+
declare const SelectGroup: {
|
|
3208
|
+
({ className, ...rest }: SelectGroupProps): react_jsx_runtime.JSX.Element;
|
|
3209
|
+
displayName: string;
|
|
3210
|
+
};
|
|
3211
|
+
type SelectGroupLabelProps = ComponentProps<typeof Select$1.GroupLabel>;
|
|
3212
|
+
declare const SelectGroupLabel: {
|
|
3213
|
+
({ className, ...rest }: SelectGroupLabelProps): react_jsx_runtime.JSX.Element;
|
|
3214
|
+
displayName: string;
|
|
3215
|
+
};
|
|
3216
|
+
type SelectScrollUpArrowProps = ComponentProps<typeof Select$1.ScrollUpArrow>;
|
|
3217
|
+
declare const SelectScrollUpArrow: {
|
|
3218
|
+
({ className, ...rest }: SelectScrollUpArrowProps): react_jsx_runtime.JSX.Element;
|
|
3219
|
+
displayName: string;
|
|
3220
|
+
};
|
|
3221
|
+
type SelectScrollDownArrowProps = ComponentProps<typeof Select$1.ScrollDownArrow>;
|
|
3222
|
+
declare const SelectScrollDownArrow: {
|
|
3223
|
+
({ className, ...rest }: SelectScrollDownArrowProps): react_jsx_runtime.JSX.Element;
|
|
3224
|
+
displayName: string;
|
|
3225
|
+
};
|
|
3226
|
+
type SelectArrowProps = ComponentProps<typeof Select$1.Arrow>;
|
|
3227
|
+
declare const SelectArrow: {
|
|
3228
|
+
({ className, ...rest }: SelectArrowProps): react_jsx_runtime.JSX.Element;
|
|
3229
|
+
displayName: string;
|
|
3230
|
+
};
|
|
3231
|
+
|
|
3232
|
+
declare const Select: react.NamedExoticComponent<SelectProps<any>>;
|
|
3233
|
+
|
|
3234
|
+
declare const useSwitchContext: () => SwitchContextType;
|
|
3235
|
+
type SwitchRootInternalProps = Omit<SwitchRootProps, 'onCheckedChange' | 'onClick'> & {
|
|
3236
|
+
onCheckedChange?: SwitchChangeEventHandler;
|
|
3237
|
+
onClick?: SwitchChangeEventHandler;
|
|
3238
|
+
};
|
|
3239
|
+
declare const SwitchRoot: {
|
|
3240
|
+
({ checked, className, defaultChecked, onCheckedChange, onClick, size, children, disabled, readOnly, required, inputRef, id, name, ...rest }: SwitchRootInternalProps): react_jsx_runtime.JSX.Element;
|
|
3241
|
+
displayName: string;
|
|
3242
|
+
};
|
|
3243
|
+
declare const SwitchThumb: {
|
|
3244
|
+
({ className, pressedAnimation, size, transition, children, ...rest }: SwitchThumbProps): react_jsx_runtime.JSX.Element;
|
|
3245
|
+
displayName: string;
|
|
3246
|
+
};
|
|
3247
|
+
declare const SwitchIcon: {
|
|
3248
|
+
({ children, className, position, transition, ...rest }: SwitchIconProps & {
|
|
3249
|
+
children?: React.ReactNode;
|
|
3250
|
+
size?: "default" | "small";
|
|
3251
|
+
}): react_jsx_runtime.JSX.Element;
|
|
3252
|
+
displayName: string;
|
|
3253
|
+
};
|
|
3254
|
+
|
|
3255
|
+
declare const Switch: react.NamedExoticComponent<SwitchProps>;
|
|
3256
|
+
|
|
3257
|
+
interface MermaidThemeItem {
|
|
3258
|
+
background?: string;
|
|
3259
|
+
displayName: string;
|
|
3260
|
+
id: string;
|
|
3261
|
+
}
|
|
3262
|
+
declare const mermaidThemes: MermaidThemeItem[];
|
|
3263
|
+
|
|
3264
|
+
interface SyntaxMermaidProps {
|
|
3265
|
+
animated?: boolean;
|
|
3266
|
+
children: string;
|
|
3267
|
+
className?: string;
|
|
3268
|
+
fallbackClassName?: string;
|
|
3269
|
+
ref?: Ref<HTMLDivElement>;
|
|
3270
|
+
style?: CSSProperties;
|
|
3271
|
+
theme?: MermaidProps['theme'];
|
|
3272
|
+
variant?: MermaidProps['variant'];
|
|
3273
|
+
}
|
|
3274
|
+
interface MermaidProps extends DivProps {
|
|
3275
|
+
actionIconSize?: ActionIconProps['size'];
|
|
3276
|
+
actionsRender?: (props: {
|
|
3277
|
+
actionIconSize: ActionIconProps['size'];
|
|
3278
|
+
content: string;
|
|
3279
|
+
getContent: () => string;
|
|
3280
|
+
originalNode: ReactNode;
|
|
3281
|
+
}) => ReactNode;
|
|
3282
|
+
animated?: boolean;
|
|
3283
|
+
bodyRender?: (props: {
|
|
3284
|
+
content: string;
|
|
3285
|
+
originalNode: ReactNode;
|
|
3286
|
+
}) => ReactNode;
|
|
3287
|
+
children: string;
|
|
3288
|
+
classNames?: {
|
|
3289
|
+
body?: string;
|
|
3290
|
+
content?: string;
|
|
3291
|
+
header?: string;
|
|
3292
|
+
};
|
|
3293
|
+
copyable?: boolean;
|
|
3294
|
+
defaultExpand?: boolean;
|
|
3295
|
+
fileName?: string;
|
|
3296
|
+
fullFeatured?: boolean;
|
|
3297
|
+
language?: string;
|
|
3298
|
+
shadow?: boolean;
|
|
3299
|
+
showLanguage?: boolean;
|
|
3300
|
+
styles?: {
|
|
3301
|
+
body?: CSSProperties;
|
|
3302
|
+
content?: CSSProperties;
|
|
3303
|
+
header?: CSSProperties;
|
|
3304
|
+
};
|
|
3305
|
+
theme?: 'lobe-theme' | MermaidConfig['theme'];
|
|
3306
|
+
variant?: 'filled' | 'outlined' | 'borderless';
|
|
3307
|
+
}
|
|
3308
|
+
|
|
3309
|
+
declare const Mermaid: react.NamedExoticComponent<MermaidProps>;
|
|
3310
|
+
|
|
3311
|
+
declare const SyntaxMermaid: react.NamedExoticComponent<SyntaxMermaidProps>;
|
|
3312
|
+
|
|
3313
|
+
interface TagProps extends Omit<TagProps$1, 'color' | 'variant'> {
|
|
3314
|
+
color?: TagProps$1['color'] | 'info';
|
|
3315
|
+
ref?: Ref<HTMLDivElement>;
|
|
3316
|
+
size?: 'small' | 'middle' | 'large';
|
|
3317
|
+
variant?: 'filled' | 'outlined' | 'borderless';
|
|
3318
|
+
}
|
|
3319
|
+
|
|
3320
|
+
declare const Tag: FC<TagProps>;
|
|
3321
|
+
|
|
3322
|
+
type ImageProps = ImageProps$1;
|
|
3323
|
+
|
|
3324
|
+
interface CitationItem {
|
|
3325
|
+
alt?: string;
|
|
3326
|
+
summary?: string;
|
|
3327
|
+
title?: string;
|
|
3328
|
+
url: string;
|
|
3329
|
+
}
|
|
3330
|
+
|
|
3331
|
+
interface SnippetProps extends FlexProps {
|
|
3332
|
+
children: string;
|
|
3333
|
+
copyable?: boolean;
|
|
3334
|
+
language?: string;
|
|
3335
|
+
prefix?: string;
|
|
3336
|
+
ref?: Ref<HTMLDivElement>;
|
|
3337
|
+
shadow?: boolean;
|
|
3338
|
+
spotlight?: boolean;
|
|
3339
|
+
variant?: 'filled' | 'outlined' | 'borderless';
|
|
3340
|
+
}
|
|
3341
|
+
|
|
3342
|
+
declare const Snippet: FC<SnippetProps>;
|
|
3343
|
+
|
|
3344
|
+
type PreProps = HighlighterProps;
|
|
3345
|
+
|
|
3346
|
+
interface VideoProps$1 extends VideoProps$2, Pick<FlexProps, 'width' | 'height'> {
|
|
3347
|
+
autoPlay?: boolean;
|
|
3348
|
+
classNames?: {
|
|
3349
|
+
mask?: string;
|
|
3350
|
+
video?: string;
|
|
3351
|
+
wrapper?: string;
|
|
3352
|
+
};
|
|
3353
|
+
isLoading?: boolean;
|
|
3354
|
+
loop?: boolean;
|
|
3355
|
+
maxHeight?: number | string;
|
|
3356
|
+
maxWidth?: number | string;
|
|
3357
|
+
minHeight?: number | string;
|
|
3358
|
+
minWidth?: number | string;
|
|
3359
|
+
muted?: HTMLVideoElement['muted'];
|
|
3360
|
+
onEnded?: VideoProps$2['onEnded'];
|
|
3361
|
+
onMouseEnter?: VideoProps$2['onMouseEnter'];
|
|
3362
|
+
onMouseLeave?: VideoProps$2['onMouseLeave'];
|
|
3363
|
+
onPause?: VideoProps$2['onPause'];
|
|
3364
|
+
onPlay?: VideoProps$2['onPlay'];
|
|
3365
|
+
onPlaying?: VideoProps$2['onPlaying'];
|
|
3366
|
+
onProgress?: VideoProps$2['onProgress'];
|
|
3367
|
+
poster?: string;
|
|
3368
|
+
preload?: HTMLVideoElement['preload'];
|
|
3369
|
+
preview?: boolean;
|
|
3370
|
+
ref?: Ref<HTMLDivElement>;
|
|
3371
|
+
size?: number | string;
|
|
3372
|
+
src: string;
|
|
3373
|
+
styles?: {
|
|
3374
|
+
mask?: CSSProperties;
|
|
3375
|
+
video?: CSSProperties;
|
|
3376
|
+
wrapper?: CSSProperties;
|
|
3377
|
+
};
|
|
3378
|
+
variant?: 'borderless' | 'filled' | 'outlined';
|
|
3379
|
+
}
|
|
3380
|
+
declare const Video: react.NamedExoticComponent<VideoProps$1>;
|
|
3381
|
+
|
|
3382
|
+
type VideoProps = VideoProps$1;
|
|
3383
|
+
|
|
3384
|
+
interface TabsProps extends TabsProps$1 {
|
|
3385
|
+
compact?: boolean;
|
|
3386
|
+
variant?: 'square' | 'rounded' | 'point';
|
|
3387
|
+
}
|
|
3388
|
+
|
|
3389
|
+
declare const Tabs: FC<TabsProps>;
|
|
3390
|
+
|
|
3391
|
+
interface TypographyProps extends DivProps {
|
|
3392
|
+
borderRadius?: number;
|
|
3393
|
+
fontSize?: number;
|
|
3394
|
+
headerMultiple?: number;
|
|
3395
|
+
lineHeight?: number;
|
|
3396
|
+
marginMultiple?: number;
|
|
3397
|
+
ref?: Ref<HTMLDivElement>;
|
|
3398
|
+
}
|
|
3399
|
+
interface SyntaxMarkdownProps {
|
|
3400
|
+
allowHtml?: boolean;
|
|
3401
|
+
allowHtmlList?: ElementType[];
|
|
3402
|
+
animated?: boolean;
|
|
3403
|
+
children: string;
|
|
3404
|
+
citations?: CitationItem[];
|
|
3405
|
+
componentProps?: {
|
|
3406
|
+
a?: Partial<AProps & AnchorProps>;
|
|
3407
|
+
highlight?: Partial<HighlighterProps>;
|
|
3408
|
+
img?: Partial<ImageProps>;
|
|
3409
|
+
mermaid?: Partial<MermaidProps>;
|
|
3410
|
+
pre?: Partial<PreProps>;
|
|
3411
|
+
video?: Partial<VideoProps>;
|
|
3412
|
+
};
|
|
3413
|
+
components?: Components & Record<string, FC>;
|
|
3414
|
+
enableCustomFootnotes?: boolean;
|
|
3415
|
+
enableGithubAlert?: boolean;
|
|
3416
|
+
enableLatex?: boolean;
|
|
3417
|
+
enableMermaid?: boolean;
|
|
3418
|
+
enableStream?: boolean;
|
|
3419
|
+
fullFeaturedCodeBlock?: boolean;
|
|
3420
|
+
reactMarkdownProps?: Omit<Readonly<Options>, 'components' | 'rehypePlugins' | 'remarkPlugins'>;
|
|
3421
|
+
rehypePlugins?: Pluggable[];
|
|
3422
|
+
rehypePluginsAhead?: Pluggable[];
|
|
3423
|
+
remarkPlugins?: Pluggable[];
|
|
3424
|
+
remarkPluginsAhead?: Pluggable[];
|
|
3425
|
+
showFootnotes?: boolean;
|
|
3426
|
+
variant?: 'default' | 'chat';
|
|
3427
|
+
}
|
|
3428
|
+
interface MarkdownProps extends SyntaxMarkdownProps, Omit<TypographyProps, 'children'> {
|
|
3429
|
+
className?: string;
|
|
3430
|
+
customRender?: (dom: ReactNode, context: {
|
|
3431
|
+
text: string;
|
|
3432
|
+
}) => ReactNode;
|
|
3433
|
+
enableImageGallery?: boolean;
|
|
3434
|
+
onDoubleClick?: () => void;
|
|
3435
|
+
ref?: Ref<HTMLDivElement>;
|
|
3436
|
+
style?: CSSProperties;
|
|
3437
|
+
}
|
|
3438
|
+
|
|
3439
|
+
declare const Markdown: react.NamedExoticComponent<MarkdownProps>;
|
|
3440
|
+
|
|
3441
|
+
declare const Typography: react.NamedExoticComponent<TypographyProps>;
|
|
3442
|
+
|
|
3443
|
+
interface SearchResultItem {
|
|
3444
|
+
alt?: string;
|
|
3445
|
+
summary?: string;
|
|
3446
|
+
title?: string;
|
|
3447
|
+
url: string;
|
|
3448
|
+
}
|
|
3449
|
+
interface SearchResultCardsProps extends FlexProps {
|
|
3450
|
+
dataSource: string[] | SearchResultItem[];
|
|
3451
|
+
ref?: Ref<HTMLDivElement>;
|
|
3452
|
+
}
|
|
3453
|
+
declare const SearchResultCards: react.NamedExoticComponent<SearchResultCardsProps>;
|
|
3454
|
+
|
|
3455
|
+
declare const rehypeCustomFootnotes: () => (tree: any, file: any) => void;
|
|
3456
|
+
|
|
3457
|
+
declare const rehypeKatexDir: () => (tree: Node) => void;
|
|
3458
|
+
|
|
3459
|
+
declare const rehypeStreamAnimated: () => (tree: Root) => void;
|
|
3460
|
+
|
|
3461
|
+
/**
|
|
3462
|
+
* Remark plugin to handle <br> and <br/> tags in markdown text
|
|
3463
|
+
* This plugin converts <br> and <br/> tags to proper HTML elements
|
|
3464
|
+
* without requiring allowHtml to be enabled
|
|
3465
|
+
*/
|
|
3466
|
+
declare const remarkBr: () => (tree: any) => void;
|
|
3467
|
+
|
|
3468
|
+
interface RemarkColorOptions {
|
|
3469
|
+
/**
|
|
3470
|
+
* 自定义颜色验证函数
|
|
3471
|
+
*/
|
|
3472
|
+
colorValidator?: (colorString: string) => boolean;
|
|
3473
|
+
}
|
|
3474
|
+
/**
|
|
3475
|
+
* Remark plugin to handle color syntax in markdown code spans
|
|
3476
|
+
* Supports GitHub-style color visualization for HEX, RGB, and HSL colors
|
|
3477
|
+
*
|
|
3478
|
+
* @example
|
|
3479
|
+
* `#FF0000` -> renders with red color preview
|
|
3480
|
+
* `rgb(255, 0, 0)` -> renders with red color preview
|
|
3481
|
+
* `hsl(0, 100%, 50%)` -> renders with red color preview
|
|
3482
|
+
*/
|
|
3483
|
+
declare const remarkColor: (options?: RemarkColorOptions) => (tree: any) => void;
|
|
3484
|
+
|
|
3485
|
+
declare const remarkCustomFootnotes: () => (tree: any, file: any) => void;
|
|
3486
|
+
|
|
3487
|
+
interface RemarkGfmPlusOptions {
|
|
3488
|
+
allowHtmlTags?: string[];
|
|
3489
|
+
}
|
|
3490
|
+
declare const remarkGfmPlus: (options?: RemarkGfmPlusOptions) => (tree: any) => void;
|
|
3491
|
+
|
|
3492
|
+
interface RemarkVideoOptions {
|
|
3493
|
+
/**
|
|
3494
|
+
* 支持的视频标签名,默认为 ['video']
|
|
3495
|
+
*/
|
|
3496
|
+
videoTags?: string[];
|
|
3497
|
+
}
|
|
3498
|
+
/**
|
|
3499
|
+
* Remark plugin to handle <video> tags in markdown text
|
|
3500
|
+
* This plugin converts <video> tags to proper video elements
|
|
3501
|
+
* without requiring allowHtml to be enabled
|
|
3502
|
+
*
|
|
3503
|
+
* @example
|
|
3504
|
+
* <video src="https://example.com/video.mp4" />
|
|
3505
|
+
* <video src="https://example.com/video.mp4" controls width="400" height="300" />
|
|
3506
|
+
*/
|
|
3507
|
+
declare const remarkVideo: (options?: RemarkVideoOptions) => (tree: any) => void;
|
|
3508
|
+
|
|
3509
|
+
interface MaskShadowProps extends FlexProps {
|
|
3510
|
+
position?: 'top' | 'bottom' | 'left' | 'right';
|
|
3511
|
+
size?: number;
|
|
3512
|
+
visibility?: 'auto' | 'always' | 'never';
|
|
3513
|
+
}
|
|
3514
|
+
|
|
3515
|
+
declare const MaskShadow: react.NamedExoticComponent<MaskShadowProps>;
|
|
3516
|
+
|
|
3517
|
+
interface MaterialFileTypeIconProps extends DivProps {
|
|
3518
|
+
fallbackUnknownType?: boolean;
|
|
3519
|
+
filename: string;
|
|
3520
|
+
open?: boolean;
|
|
3521
|
+
size?: number;
|
|
3522
|
+
type?: 'file' | 'folder';
|
|
3523
|
+
variant?: 'raw' | 'file' | 'folder';
|
|
3524
|
+
}
|
|
3525
|
+
|
|
3526
|
+
declare const MaterialFileTypeIcon: FC<MaterialFileTypeIconProps>;
|
|
3527
|
+
|
|
3528
|
+
declare const styles: {
|
|
3529
|
+
danger: string;
|
|
3530
|
+
empty: string;
|
|
3531
|
+
extra: string;
|
|
3532
|
+
groupLabel: string;
|
|
3533
|
+
icon: string;
|
|
3534
|
+
item: string;
|
|
3535
|
+
itemContent: string;
|
|
3536
|
+
label: string;
|
|
3537
|
+
popup: string;
|
|
3538
|
+
positioner: string;
|
|
3539
|
+
separator: string;
|
|
3540
|
+
submenuArrow: string;
|
|
3541
|
+
};
|
|
3542
|
+
|
|
3543
|
+
interface I18nProviderProps {
|
|
3544
|
+
children: ReactNode;
|
|
3545
|
+
locale?: string;
|
|
3546
|
+
motion: MotionComponentType;
|
|
3547
|
+
resources?: TranslationResourcesInput;
|
|
3548
|
+
}
|
|
3549
|
+
|
|
3550
|
+
declare const I18nProvider: react.NamedExoticComponent<I18nProviderProps>;
|
|
3551
|
+
|
|
3552
|
+
declare const useTranslation: (fallbackResources?: TranslationResources) => {
|
|
3553
|
+
locale: string;
|
|
3554
|
+
t: (key: TranslationKey) => string;
|
|
3555
|
+
};
|
|
3556
|
+
|
|
3557
|
+
type ScrollAreaRootProps = react__default.ComponentProps<typeof ScrollArea$1.Root>;
|
|
3558
|
+
type ScrollAreaViewportProps = react__default.ComponentProps<typeof ScrollArea$1.Viewport> & {
|
|
3559
|
+
/**
|
|
3560
|
+
* Enable gradient scroll fade on the viewport edges.
|
|
3561
|
+
* @default false
|
|
3562
|
+
*/
|
|
3563
|
+
scrollFade?: boolean;
|
|
3564
|
+
};
|
|
3565
|
+
type ScrollAreaContentProps = react__default.ComponentProps<typeof ScrollArea$1.Content>;
|
|
3566
|
+
type ScrollAreaScrollbarProps = react__default.ComponentProps<typeof ScrollArea$1.Scrollbar>;
|
|
3567
|
+
type ScrollAreaThumbProps = react__default.ComponentProps<typeof ScrollArea$1.Thumb>;
|
|
3568
|
+
type ScrollAreaCornerProps = react__default.ComponentProps<typeof ScrollArea$1.Corner>;
|
|
3569
|
+
declare const ScrollAreaRoot: {
|
|
3570
|
+
({ className, ...rest }: ScrollAreaRootProps): react_jsx_runtime.JSX.Element;
|
|
3571
|
+
displayName: string;
|
|
3572
|
+
};
|
|
3573
|
+
declare const ScrollAreaViewport: {
|
|
3574
|
+
({ className, scrollFade, ...rest }: ScrollAreaViewportProps): react_jsx_runtime.JSX.Element;
|
|
3575
|
+
displayName: string;
|
|
3576
|
+
};
|
|
3577
|
+
declare const ScrollAreaContent: {
|
|
3578
|
+
({ className, ...rest }: ScrollAreaContentProps): react_jsx_runtime.JSX.Element;
|
|
3579
|
+
displayName: string;
|
|
3580
|
+
};
|
|
3581
|
+
declare const ScrollAreaScrollbar: {
|
|
3582
|
+
({ className, ...rest }: ScrollAreaScrollbarProps): react_jsx_runtime.JSX.Element;
|
|
3583
|
+
displayName: string;
|
|
3584
|
+
};
|
|
3585
|
+
declare const ScrollAreaThumb: {
|
|
3586
|
+
({ className, ...rest }: ScrollAreaThumbProps): react_jsx_runtime.JSX.Element;
|
|
3587
|
+
displayName: string;
|
|
3588
|
+
};
|
|
3589
|
+
declare const ScrollAreaCorner: {
|
|
3590
|
+
({ className, ...rest }: ScrollAreaCornerProps): react_jsx_runtime.JSX.Element;
|
|
3591
|
+
displayName: string;
|
|
3592
|
+
};
|
|
3593
|
+
|
|
3594
|
+
interface ScrollAreaProps extends Omit<ScrollAreaRootProps, 'children'> {
|
|
3595
|
+
children?: ReactNode;
|
|
3596
|
+
contentProps?: Omit<ScrollAreaContentProps, 'children'>;
|
|
3597
|
+
corner?: boolean;
|
|
3598
|
+
cornerProps?: ScrollAreaCornerProps;
|
|
3599
|
+
scrollFade?: boolean;
|
|
3600
|
+
scrollbarProps?: Omit<ScrollAreaScrollbarProps, 'children'>;
|
|
3601
|
+
thumbProps?: ScrollAreaThumbProps;
|
|
3602
|
+
viewportProps?: Omit<ScrollAreaViewportProps, 'children' | 'scrollFade'>;
|
|
3603
|
+
}
|
|
3604
|
+
|
|
3605
|
+
declare const ScrollArea: FC<ScrollAreaProps>;
|
|
3606
|
+
|
|
3607
|
+
interface ScrollShadowProps extends FlexProps {
|
|
3608
|
+
hideScrollBar?: boolean;
|
|
3609
|
+
isEnabled?: boolean;
|
|
3610
|
+
offset?: number;
|
|
3611
|
+
onVisibilityChange?: (visibility: {
|
|
3612
|
+
bottom?: boolean;
|
|
3613
|
+
left?: boolean;
|
|
3614
|
+
right?: boolean;
|
|
3615
|
+
top?: boolean;
|
|
3616
|
+
}) => void;
|
|
3617
|
+
orientation?: 'vertical' | 'horizontal';
|
|
3618
|
+
ref?: Ref<HTMLDivElement>;
|
|
3619
|
+
size?: number;
|
|
3620
|
+
visibility?: 'auto' | 'always' | 'never';
|
|
3621
|
+
}
|
|
3622
|
+
|
|
3623
|
+
declare const ScrollShadow: FC<ScrollShadowProps>;
|
|
3624
|
+
|
|
3625
|
+
interface SearchBarProps extends Omit<InputProps, 'styles' | 'classNames'> {
|
|
3626
|
+
classNames?: {
|
|
3627
|
+
input?: string;
|
|
3628
|
+
shortKey?: string;
|
|
3629
|
+
};
|
|
3630
|
+
defaultOpen?: boolean;
|
|
3631
|
+
defaultValue?: string;
|
|
3632
|
+
enableShortKey?: boolean;
|
|
3633
|
+
loading?: boolean;
|
|
3634
|
+
modal?: boolean;
|
|
3635
|
+
modalProps?: Omit<ModalProps, 'children' | 'open'> & {
|
|
3636
|
+
onCancel?: ModalProps['onCancel'];
|
|
3637
|
+
};
|
|
3638
|
+
modalTitle?: ReactNode;
|
|
3639
|
+
modalWidth?: number | string;
|
|
3640
|
+
modalContent?: ReactNode | ((value: string, close: () => void) => ReactNode);
|
|
3641
|
+
onInputChange?: (value: string) => void;
|
|
3642
|
+
onOpenChange?: (open: boolean) => void;
|
|
3643
|
+
onSearch?: (value: string) => void;
|
|
3644
|
+
open?: boolean;
|
|
3645
|
+
shortKey?: string;
|
|
3646
|
+
spotlight?: boolean;
|
|
3647
|
+
styles?: {
|
|
3648
|
+
input?: CSSProperties;
|
|
3649
|
+
shortKey?: CSSProperties;
|
|
3650
|
+
};
|
|
3651
|
+
value?: string;
|
|
3652
|
+
}
|
|
3653
|
+
|
|
3654
|
+
declare const SearchBar: react.NamedExoticComponent<SearchBarProps>;
|
|
3655
|
+
|
|
3656
|
+
declare const Segmented: react.NamedExoticComponent<SegmentedProps>;
|
|
3657
|
+
|
|
3658
|
+
interface SideNavProps extends FlexProps {
|
|
3659
|
+
avatar?: ReactNode;
|
|
3660
|
+
bottomActions: ReactNode;
|
|
3661
|
+
topActions?: ReactNode;
|
|
3662
|
+
}
|
|
3663
|
+
|
|
3664
|
+
declare const SideNav: react.NamedExoticComponent<SideNavProps>;
|
|
3665
|
+
|
|
3666
|
+
interface SkeletonBlockProps {
|
|
3667
|
+
active?: boolean;
|
|
3668
|
+
className?: string;
|
|
3669
|
+
height?: number | string;
|
|
3670
|
+
style?: CSSProperties;
|
|
3671
|
+
width?: number | string;
|
|
3672
|
+
}
|
|
3673
|
+
interface SkeletonTitleProps extends Omit<SkeletonBlockProps, 'height'> {
|
|
3674
|
+
fontSize?: number;
|
|
3675
|
+
height?: number;
|
|
3676
|
+
lineHeight?: number;
|
|
3677
|
+
width?: number | string;
|
|
3678
|
+
}
|
|
3679
|
+
interface SkeletonParagraphProps extends Omit<SkeletonBlockProps, 'width' | 'height'> {
|
|
3680
|
+
fontSize?: number;
|
|
3681
|
+
gap?: number;
|
|
3682
|
+
height?: number;
|
|
3683
|
+
lineHeight?: number;
|
|
3684
|
+
rows?: number;
|
|
3685
|
+
width?: number | string | (number | string)[];
|
|
3686
|
+
}
|
|
3687
|
+
interface SkeletonTagsProps extends Omit<SkeletonBlockProps, 'width'> {
|
|
3688
|
+
count?: number;
|
|
3689
|
+
gap?: number;
|
|
3690
|
+
size?: 'small' | 'middle' | 'large';
|
|
3691
|
+
width?: number | string | (number | string)[];
|
|
3692
|
+
}
|
|
3693
|
+
interface SkeletonAvatarProps extends SkeletonBlockProps {
|
|
3694
|
+
shape?: 'circle' | 'square';
|
|
3695
|
+
size?: number | string;
|
|
3696
|
+
}
|
|
3697
|
+
interface SkeletonButtonProps extends SkeletonBlockProps {
|
|
3698
|
+
block?: boolean;
|
|
3699
|
+
shape?: 'circle' | 'round' | 'default';
|
|
3700
|
+
size?: 'large' | 'small' | 'default';
|
|
3701
|
+
}
|
|
3702
|
+
interface SkeletonProps extends SkeletonBlockProps {
|
|
3703
|
+
avatar?: SkeletonAvatarProps | boolean;
|
|
3704
|
+
classNames?: {
|
|
3705
|
+
avatar?: string;
|
|
3706
|
+
paragraph?: string;
|
|
3707
|
+
root?: string;
|
|
3708
|
+
title?: string;
|
|
3709
|
+
};
|
|
3710
|
+
gap?: number;
|
|
3711
|
+
paragraph?: SkeletonParagraphProps | boolean;
|
|
3712
|
+
styles?: {
|
|
3713
|
+
avatar?: CSSProperties;
|
|
3714
|
+
paragraph?: CSSProperties;
|
|
3715
|
+
root?: CSSProperties;
|
|
3716
|
+
title?: CSSProperties;
|
|
3717
|
+
};
|
|
3718
|
+
title?: SkeletonTitleProps | boolean;
|
|
3719
|
+
}
|
|
3720
|
+
|
|
3721
|
+
declare const SkeletonAvatar: FC<SkeletonAvatarProps>;
|
|
3722
|
+
|
|
3723
|
+
declare const SkeletonBlock: FC<SkeletonBlockProps>;
|
|
3724
|
+
|
|
3725
|
+
declare const SkeletonButton: FC<SkeletonButtonProps>;
|
|
3726
|
+
|
|
3727
|
+
declare const SkeletonParagraph: FC<SkeletonParagraphProps>;
|
|
3728
|
+
|
|
3729
|
+
declare const SkeletonTags: FC<SkeletonTagsProps>;
|
|
3730
|
+
|
|
3731
|
+
declare const SkeletonTitle: FC<SkeletonTitleProps>;
|
|
3732
|
+
|
|
3733
|
+
interface ISkeleton {
|
|
3734
|
+
(props: SkeletonProps): ReactNode;
|
|
3735
|
+
Avatar: typeof SkeletonAvatar;
|
|
3736
|
+
Block: typeof SkeletonBlock;
|
|
3737
|
+
Button: typeof SkeletonButton;
|
|
3738
|
+
Paragraph: typeof SkeletonParagraph;
|
|
3739
|
+
Tags: typeof SkeletonTags;
|
|
3740
|
+
Title: typeof SkeletonTitle;
|
|
3741
|
+
}
|
|
3742
|
+
declare const Skeleton: ISkeleton;
|
|
3743
|
+
|
|
3744
|
+
interface SliderWithInputProps extends Omit<SliderSingleProps, 'classNames' | 'styles'> {
|
|
3745
|
+
changeOnWheel?: boolean;
|
|
3746
|
+
classNames?: {
|
|
3747
|
+
input?: string;
|
|
3748
|
+
slider?: string;
|
|
3749
|
+
} & SliderSingleProps['classNames'];
|
|
3750
|
+
controls?: InputNumberProps['controls'];
|
|
3751
|
+
gap?: FlexProps['gap'];
|
|
3752
|
+
size?: InputNumberProps['size'];
|
|
3753
|
+
styles?: {
|
|
3754
|
+
input?: CSSProperties;
|
|
3755
|
+
slider?: CSSProperties;
|
|
3756
|
+
} & SliderSingleProps['styles'];
|
|
3757
|
+
unlimitedInput?: boolean;
|
|
3758
|
+
variant?: InputNumberProps['variant'];
|
|
3759
|
+
}
|
|
3760
|
+
|
|
3761
|
+
declare const SliderWithInput: react.NamedExoticComponent<SliderWithInputProps>;
|
|
3762
|
+
|
|
3763
|
+
declare const DragHandle: react.NamedExoticComponent<ActionIconProps>;
|
|
3764
|
+
|
|
3765
|
+
interface SortableItemProps extends Omit<FlexProps, 'id'> {
|
|
3766
|
+
id: string | number;
|
|
3767
|
+
variant?: 'borderless' | 'filled' | 'outlined';
|
|
3768
|
+
}
|
|
3769
|
+
declare const SortableItem: react.NamedExoticComponent<SortableItemProps>;
|
|
3770
|
+
|
|
3771
|
+
interface SortableListItem {
|
|
3772
|
+
[key: string]: any;
|
|
3773
|
+
id: string | number;
|
|
3774
|
+
}
|
|
3775
|
+
interface SortableListProps extends Omit<FlexProps, 'onChange'> {
|
|
3776
|
+
items: SortableListItem[];
|
|
3777
|
+
onChange(items: SortableListItem[]): void;
|
|
3778
|
+
ref?: Ref<HTMLUListElement>;
|
|
3779
|
+
renderItem(item: SortableListItem): ReactNode;
|
|
3780
|
+
}
|
|
3781
|
+
|
|
3782
|
+
interface ISortableList {
|
|
3783
|
+
(props: SortableListProps): ReactNode;
|
|
3784
|
+
DragHandle: typeof DragHandle;
|
|
3785
|
+
Item: typeof SortableItem;
|
|
3786
|
+
}
|
|
3787
|
+
declare const SortableList: ISortableList;
|
|
3788
|
+
|
|
3789
|
+
type TableAlign = "left" | "center" | "right";
|
|
3790
|
+
type TableColumnFixed = "start" | "end" | "left" | "right" | true;
|
|
3791
|
+
type TableColumn<TData> = {
|
|
3792
|
+
key: string;
|
|
3793
|
+
title: string;
|
|
3794
|
+
item?: string;
|
|
3795
|
+
sortable?: boolean;
|
|
3796
|
+
hiddeable?: boolean;
|
|
3797
|
+
width?: number | string;
|
|
3798
|
+
align?: TableAlign;
|
|
3799
|
+
fixed?: TableColumnFixed;
|
|
3800
|
+
headerClassName?: string;
|
|
3801
|
+
cellClassName?: string;
|
|
3802
|
+
headerStyle?: react.CSSProperties;
|
|
3803
|
+
cellStyle?: react.CSSProperties;
|
|
3804
|
+
func?: (row: TData, context: {
|
|
3805
|
+
value: unknown;
|
|
3806
|
+
rowIndex: number;
|
|
3807
|
+
}) => react.ReactNode;
|
|
3808
|
+
};
|
|
3809
|
+
type TableReadConfig<TData> = {
|
|
3810
|
+
method?: "get" | "post";
|
|
3811
|
+
url?: string;
|
|
3812
|
+
get?: string;
|
|
3813
|
+
post?: string;
|
|
3814
|
+
payload?: unknown;
|
|
3815
|
+
body?: unknown;
|
|
3816
|
+
params?: Record<string, unknown>;
|
|
3817
|
+
headers?: HeadersInit;
|
|
3818
|
+
resultKey?: string;
|
|
3819
|
+
mapData?: (raw: unknown) => TData[];
|
|
3820
|
+
delay?: number;
|
|
3821
|
+
};
|
|
3822
|
+
type TableDataSource<TData> = {
|
|
3823
|
+
bind?: TData[];
|
|
3824
|
+
read?: TableReadConfig<TData>;
|
|
3825
|
+
};
|
|
3826
|
+
type TablePageSizeConfig = {
|
|
3827
|
+
visible?: boolean;
|
|
3828
|
+
count?: number;
|
|
3829
|
+
options?: number[];
|
|
3830
|
+
};
|
|
3831
|
+
type AntdTablePropsBase<TData> = Omit<TableProps$1<TData>, "columns" | "dataSource" | "pagination">;
|
|
3832
|
+
interface TableProps<TData> extends AntdTablePropsBase<TData> {
|
|
3833
|
+
data: TableDataSource<TData>;
|
|
3834
|
+
columns: TableColumn<TData>[];
|
|
3835
|
+
pagination?: boolean;
|
|
3836
|
+
sortable?: boolean;
|
|
3837
|
+
reload?: boolean;
|
|
3838
|
+
filterable?: boolean;
|
|
3839
|
+
selectable?: boolean;
|
|
3840
|
+
height?: number | string;
|
|
3841
|
+
rowHeight?: number;
|
|
3842
|
+
overscan?: number;
|
|
3843
|
+
defaultPageSize?: number;
|
|
3844
|
+
pageSize?: TablePageSizeConfig;
|
|
3845
|
+
className?: string;
|
|
3846
|
+
emptyState?: react.ReactNode;
|
|
3847
|
+
onDataChange?: (rows: TData[]) => void;
|
|
3848
|
+
}
|
|
3849
|
+
|
|
3850
|
+
declare const Table: {
|
|
3851
|
+
<TData extends object>({ data, columns, pagination, sortable, reload, filterable, selectable: selectableProp, height, defaultPageSize, pageSize, className, emptyState, onDataChange, loading: loadingProp, rowSelection: rowSelectionProp, rowKey: rowKeyProp, bordered: borderedProp, size: sizeProp, sticky: stickyProp, scroll: scrollProp, virtual: virtualProp, locale: localeProp, style: tableStyle, ...restTableProps }: TableProps<TData>): react_jsx_runtime.JSX.Element;
|
|
3852
|
+
displayName: string;
|
|
3853
|
+
};
|
|
3854
|
+
|
|
3855
|
+
declare const primaryColors: {
|
|
3856
|
+
blue: string;
|
|
3857
|
+
cyan: string;
|
|
3858
|
+
geekblue: string;
|
|
3859
|
+
gold: string;
|
|
3860
|
+
green: string;
|
|
3861
|
+
lime: string;
|
|
3862
|
+
magenta: string;
|
|
3863
|
+
orange: string;
|
|
3864
|
+
purple: string;
|
|
3865
|
+
red: string;
|
|
3866
|
+
volcano: string;
|
|
3867
|
+
yellow: string;
|
|
3868
|
+
};
|
|
3869
|
+
type PrimaryColorsObj = typeof primaryColors;
|
|
3870
|
+
type PrimaryColors = keyof PrimaryColorsObj;
|
|
3871
|
+
declare const primaryColorsSwatches: string[];
|
|
3872
|
+
declare const neutralColors: {
|
|
3873
|
+
mauve: string;
|
|
3874
|
+
olive: string;
|
|
3875
|
+
sage: string;
|
|
3876
|
+
sand: string;
|
|
3877
|
+
slate: string;
|
|
3878
|
+
};
|
|
3879
|
+
declare const neutralColorsSwatches: string[];
|
|
3880
|
+
type NeutralColorsObj = typeof neutralColors;
|
|
3881
|
+
type NeutralColors = keyof NeutralColorsObj;
|
|
3882
|
+
declare const findCustomThemeName: (type: "primary" | "neutral", value: string) => string | undefined;
|
|
3883
|
+
|
|
3884
|
+
declare const generateCustomStylish: GetCustomStylish<LobeCustomStylish>;
|
|
3885
|
+
|
|
3886
|
+
declare const staticStylish: LobeCustomStylish;
|
|
3887
|
+
|
|
3888
|
+
declare const generateCustomToken: GetCustomToken<LobeCustomToken>;
|
|
3889
|
+
|
|
3890
|
+
type colorStep = [
|
|
3891
|
+
string,
|
|
3892
|
+
string,
|
|
3893
|
+
string,
|
|
3894
|
+
string,
|
|
3895
|
+
string,
|
|
3896
|
+
string,
|
|
3897
|
+
string,
|
|
3898
|
+
string,
|
|
3899
|
+
string,
|
|
3900
|
+
string,
|
|
3901
|
+
string,
|
|
3902
|
+
string,
|
|
3903
|
+
string
|
|
3904
|
+
];
|
|
3905
|
+
interface ColorScaleItem {
|
|
3906
|
+
dark: colorStep;
|
|
3907
|
+
darkA: colorStep;
|
|
3908
|
+
light: colorStep;
|
|
3909
|
+
lightA: colorStep;
|
|
3910
|
+
}
|
|
3911
|
+
|
|
3912
|
+
declare const generateColorPalette: ({ type, scale, appearance, }: {
|
|
3913
|
+
appearance: "light" | "dark";
|
|
3914
|
+
scale: ColorScaleItem;
|
|
3915
|
+
type: "Primary" | "Success" | "Warning" | "Error" | "Info" | string;
|
|
3916
|
+
}) => Partial<AliasToken>;
|
|
3917
|
+
declare const generateColorNeutralPalette: ({ scale, appearance, }: {
|
|
3918
|
+
appearance: "light" | "dark";
|
|
3919
|
+
scale: ColorScaleItem;
|
|
3920
|
+
}) => Partial<AliasToken>;
|
|
3921
|
+
|
|
3922
|
+
declare const CLASSNAMES: {
|
|
3923
|
+
ContextTrigger: string;
|
|
3924
|
+
DropdownMenuTrigger: string;
|
|
3925
|
+
};
|
|
3926
|
+
|
|
3927
|
+
interface ThemeProviderProps extends ThemeProviderProps$1<any> {
|
|
3928
|
+
className?: string;
|
|
3929
|
+
customFonts?: string[];
|
|
3930
|
+
customStylish?: (theme: CustomStylishParams) => {
|
|
3931
|
+
[key: string]: any;
|
|
3932
|
+
};
|
|
3933
|
+
customTheme?: {
|
|
3934
|
+
neutralColor?: NeutralColors;
|
|
3935
|
+
primaryColor?: PrimaryColors;
|
|
3936
|
+
};
|
|
3937
|
+
customToken?: (theme: CustomTokenParams) => {
|
|
3938
|
+
[key: string]: any;
|
|
3939
|
+
};
|
|
3940
|
+
enableCustomFonts?: boolean;
|
|
3941
|
+
enableGlobalStyle?: boolean;
|
|
3942
|
+
/**
|
|
3943
|
+
* Global mobile mode. Components with an `isMobile` prop will default to this value.
|
|
3944
|
+
*/
|
|
3945
|
+
isMobile?: boolean;
|
|
3946
|
+
style?: CSSProperties;
|
|
3947
|
+
}
|
|
3948
|
+
interface MetaProps {
|
|
3949
|
+
description?: string;
|
|
3950
|
+
title?: string;
|
|
3951
|
+
withManifest?: boolean;
|
|
3952
|
+
}
|
|
3953
|
+
|
|
3954
|
+
declare const Meta: FC<MetaProps>;
|
|
3955
|
+
|
|
3956
|
+
declare const ThemeProvider: react.NamedExoticComponent<ThemeProviderProps>;
|
|
3957
|
+
|
|
3958
|
+
interface ThemeSwitchProps extends DivProps {
|
|
3959
|
+
labels?: {
|
|
3960
|
+
auto: string;
|
|
3961
|
+
dark: string;
|
|
3962
|
+
light: string;
|
|
3963
|
+
};
|
|
3964
|
+
onThemeSwitch: (themeMode: ThemeMode) => void;
|
|
3965
|
+
size?: ActionIconProps['size'];
|
|
3966
|
+
themeMode: ThemeMode;
|
|
3967
|
+
type?: 'icon' | 'select';
|
|
3968
|
+
variant?: ActionIconProps['variant'];
|
|
3969
|
+
}
|
|
3970
|
+
|
|
3971
|
+
declare const ThemeSwitch: FC<ThemeSwitchProps>;
|
|
3972
|
+
|
|
3973
|
+
type ToastType = 'success' | 'info' | 'warning' | 'error' | 'loading' | 'default';
|
|
3974
|
+
type ToastPosition = 'top' | 'top-left' | 'top-right' | 'bottom' | 'bottom-left' | 'bottom-right';
|
|
3975
|
+
type ToastActionVariant = 'primary' | 'secondary' | 'text' | 'danger' | 'ghost';
|
|
3976
|
+
interface ToastAction {
|
|
3977
|
+
/**
|
|
3978
|
+
* Action button label
|
|
3979
|
+
*/
|
|
3980
|
+
label: ReactNode;
|
|
3981
|
+
/**
|
|
3982
|
+
* Click handler
|
|
3983
|
+
*/
|
|
3984
|
+
onClick?: () => void;
|
|
3985
|
+
/**
|
|
3986
|
+
* Additional props for the button
|
|
3987
|
+
*/
|
|
3988
|
+
props?: Omit<React.ComponentPropsWithRef<'button'>, 'onClick'>;
|
|
3989
|
+
/**
|
|
3990
|
+
* Button variant
|
|
3991
|
+
* @default 'primary'
|
|
3992
|
+
*/
|
|
3993
|
+
variant?: ToastActionVariant;
|
|
3994
|
+
}
|
|
3995
|
+
interface ToastOptions {
|
|
3996
|
+
/**
|
|
3997
|
+
* Action button props
|
|
3998
|
+
* @deprecated Use `actions` instead
|
|
3999
|
+
*/
|
|
4000
|
+
actionProps?: React.ComponentPropsWithRef<'button'>;
|
|
4001
|
+
/**
|
|
4002
|
+
* Multiple action buttons
|
|
4003
|
+
*/
|
|
4004
|
+
actions?: ToastAction[];
|
|
4005
|
+
/**
|
|
4006
|
+
* Additional class name
|
|
4007
|
+
*/
|
|
4008
|
+
className?: string;
|
|
4009
|
+
/**
|
|
4010
|
+
* Whether the toast is closable
|
|
4011
|
+
* @default true
|
|
4012
|
+
*/
|
|
4013
|
+
closable?: boolean;
|
|
4014
|
+
/**
|
|
4015
|
+
* Custom data for the toast
|
|
4016
|
+
*/
|
|
4017
|
+
data?: Record<string, unknown>;
|
|
4018
|
+
/**
|
|
4019
|
+
* Toast description
|
|
4020
|
+
*/
|
|
4021
|
+
description?: ReactNode;
|
|
4022
|
+
/**
|
|
4023
|
+
* Custom duration in milliseconds
|
|
4024
|
+
* @default 5000
|
|
4025
|
+
*/
|
|
4026
|
+
duration?: number;
|
|
4027
|
+
/**
|
|
4028
|
+
* Hide the close button
|
|
4029
|
+
* @default false
|
|
4030
|
+
*/
|
|
4031
|
+
hideCloseButton?: boolean;
|
|
4032
|
+
/**
|
|
4033
|
+
* Custom icon
|
|
4034
|
+
*/
|
|
4035
|
+
icon?: IconProps$1['icon'];
|
|
4036
|
+
/**
|
|
4037
|
+
* Callback when toast is closed
|
|
4038
|
+
*/
|
|
4039
|
+
onClose?: () => void;
|
|
4040
|
+
/**
|
|
4041
|
+
* Callback when toast is removed
|
|
4042
|
+
*/
|
|
4043
|
+
onRemove?: () => void;
|
|
4044
|
+
/**
|
|
4045
|
+
* Toast placement, overrides global ToastHost position
|
|
4046
|
+
*/
|
|
4047
|
+
placement?: ToastPosition;
|
|
4048
|
+
/**
|
|
4049
|
+
* Additional styles
|
|
4050
|
+
*/
|
|
4051
|
+
style?: CSSProperties;
|
|
4052
|
+
/**
|
|
4053
|
+
* Toast title
|
|
4054
|
+
*/
|
|
4055
|
+
title?: ReactNode;
|
|
4056
|
+
/**
|
|
4057
|
+
* Toast type
|
|
4058
|
+
* @default 'default'
|
|
4059
|
+
*/
|
|
4060
|
+
type?: ToastType;
|
|
4061
|
+
}
|
|
4062
|
+
interface ToastInstance {
|
|
4063
|
+
/**
|
|
4064
|
+
* Close the toast
|
|
4065
|
+
*/
|
|
4066
|
+
close: () => void;
|
|
4067
|
+
/**
|
|
4068
|
+
* The toast ID
|
|
4069
|
+
*/
|
|
4070
|
+
id: string;
|
|
4071
|
+
/**
|
|
4072
|
+
* Update the toast
|
|
4073
|
+
*/
|
|
4074
|
+
update: (options: Partial<ToastOptions>) => void;
|
|
4075
|
+
}
|
|
4076
|
+
interface ToastProps {
|
|
4077
|
+
classNames?: {
|
|
4078
|
+
action?: string;
|
|
4079
|
+
actions?: string;
|
|
4080
|
+
close?: string;
|
|
4081
|
+
content?: string;
|
|
4082
|
+
description?: string;
|
|
4083
|
+
icon?: string;
|
|
4084
|
+
root?: string;
|
|
4085
|
+
title?: string;
|
|
4086
|
+
};
|
|
4087
|
+
styles?: {
|
|
4088
|
+
action?: CSSProperties;
|
|
4089
|
+
actions?: CSSProperties;
|
|
4090
|
+
close?: CSSProperties;
|
|
4091
|
+
content?: CSSProperties;
|
|
4092
|
+
description?: CSSProperties;
|
|
4093
|
+
icon?: CSSProperties;
|
|
4094
|
+
root?: CSSProperties;
|
|
4095
|
+
title?: CSSProperties;
|
|
4096
|
+
};
|
|
4097
|
+
toast: Toast.Root.ToastObject<ToastOptions>;
|
|
4098
|
+
}
|
|
4099
|
+
interface ToastPromiseOptions<T> {
|
|
4100
|
+
error: ReactNode | ((error: Error) => ReactNode) | Omit<ToastOptions, 'type'>;
|
|
4101
|
+
loading: ReactNode | Omit<ToastOptions, 'type'>;
|
|
4102
|
+
success: ReactNode | ((data: T) => ReactNode) | Omit<ToastOptions, 'type'>;
|
|
4103
|
+
}
|
|
4104
|
+
interface ToastAPI {
|
|
4105
|
+
(options: ToastOptions): ToastInstance;
|
|
4106
|
+
dismiss: (id?: string) => void;
|
|
4107
|
+
error: (options: Omit<ToastOptions, 'type'> | string) => ToastInstance;
|
|
4108
|
+
info: (options: Omit<ToastOptions, 'type'> | string) => ToastInstance;
|
|
4109
|
+
loading: (options: Omit<ToastOptions, 'type'> | string) => ToastInstance;
|
|
4110
|
+
promise: <T>(promise: Promise<T>, options: ToastPromiseOptions<T>) => Promise<T>;
|
|
4111
|
+
success: (options: Omit<ToastOptions, 'type'> | string) => ToastInstance;
|
|
4112
|
+
warning: (options: Omit<ToastOptions, 'type'> | string) => ToastInstance;
|
|
4113
|
+
}
|
|
4114
|
+
|
|
4115
|
+
declare const toast: ToastAPI;
|
|
4116
|
+
interface ToastHostProps {
|
|
4117
|
+
className?: string;
|
|
4118
|
+
/**
|
|
4119
|
+
* Default duration for toasts
|
|
4120
|
+
* @default 5000
|
|
4121
|
+
*/
|
|
4122
|
+
duration?: number;
|
|
4123
|
+
/**
|
|
4124
|
+
* Maximum number of toasts
|
|
4125
|
+
* @default 5
|
|
4126
|
+
*/
|
|
4127
|
+
limit?: number;
|
|
4128
|
+
/**
|
|
4129
|
+
* Toast position
|
|
4130
|
+
* @default 'bottom-right'
|
|
4131
|
+
*/
|
|
4132
|
+
position?: ToastPosition;
|
|
4133
|
+
/**
|
|
4134
|
+
* Root element for portal
|
|
4135
|
+
*/
|
|
4136
|
+
root?: HTMLElement | ShadowRoot | null;
|
|
4137
|
+
/**
|
|
4138
|
+
* Swipe direction to dismiss
|
|
4139
|
+
* @default ['down', 'right']
|
|
4140
|
+
*/
|
|
4141
|
+
swipeDirection?: ('left' | 'right' | 'up' | 'down') | ('left' | 'right' | 'up' | 'down')[];
|
|
4142
|
+
}
|
|
4143
|
+
declare const ToastHost: react.MemoExoticComponent<({ root, className, duration, limit, position, swipeDirection, }: ToastHostProps) => react.ReactPortal | null>;
|
|
4144
|
+
declare const useToast: () => ToastAPI;
|
|
4145
|
+
|
|
4146
|
+
interface TocItemType {
|
|
4147
|
+
children?: TocItemType[];
|
|
4148
|
+
id: string;
|
|
4149
|
+
title: string;
|
|
4150
|
+
}
|
|
4151
|
+
interface TocMobileProps {
|
|
4152
|
+
activeKey?: string;
|
|
4153
|
+
getContainer?: AnchorProps['getContainer'];
|
|
4154
|
+
headerHeight?: number;
|
|
4155
|
+
items: TocItemType[];
|
|
4156
|
+
onChange?: (activeKey: string) => void;
|
|
4157
|
+
tocWidth?: number;
|
|
4158
|
+
}
|
|
4159
|
+
interface TocProps extends TocMobileProps {
|
|
4160
|
+
isMobile?: boolean;
|
|
4161
|
+
}
|
|
4162
|
+
|
|
4163
|
+
declare const Toc: react.NamedExoticComponent<TocProps>;
|
|
4164
|
+
|
|
4165
|
+
declare const copyToClipboard: (text: string) => Promise<void>;
|
|
4166
|
+
|
|
4167
|
+
declare const preventDefault: <T extends {
|
|
4168
|
+
preventDefault: () => void;
|
|
4169
|
+
}>(event: T) => void;
|
|
4170
|
+
declare const stopPropagation: <T extends {
|
|
4171
|
+
stopPropagation: () => void;
|
|
4172
|
+
}>(event: T) => void;
|
|
4173
|
+
declare const preventDefaultAndStopPropagation: <T extends {
|
|
4174
|
+
preventBaseUIHandler?: () => void;
|
|
4175
|
+
preventDefault: () => void;
|
|
4176
|
+
stopPropagation: () => void;
|
|
4177
|
+
}>(event: T) => void;
|
|
4178
|
+
|
|
4179
|
+
declare const _default: {
|
|
4180
|
+
displayName: string;
|
|
4181
|
+
name: string;
|
|
4182
|
+
semanticHighlighting: boolean;
|
|
4183
|
+
tokenColors: ({
|
|
4184
|
+
settings: {
|
|
4185
|
+
foreground: string;
|
|
4186
|
+
fontStyle?: undefined;
|
|
4187
|
+
background?: undefined;
|
|
4188
|
+
};
|
|
4189
|
+
scope?: undefined;
|
|
4190
|
+
} | {
|
|
4191
|
+
scope: string;
|
|
4192
|
+
settings: {
|
|
4193
|
+
foreground: string;
|
|
4194
|
+
fontStyle?: undefined;
|
|
4195
|
+
background?: undefined;
|
|
4196
|
+
};
|
|
4197
|
+
} | {
|
|
4198
|
+
scope: string;
|
|
4199
|
+
settings: {
|
|
4200
|
+
fontStyle: string;
|
|
4201
|
+
foreground: string;
|
|
4202
|
+
background?: undefined;
|
|
4203
|
+
};
|
|
4204
|
+
} | {
|
|
4205
|
+
settings: {
|
|
4206
|
+
background: string;
|
|
4207
|
+
foreground: string;
|
|
4208
|
+
fontStyle?: undefined;
|
|
4209
|
+
};
|
|
4210
|
+
scope?: undefined;
|
|
4211
|
+
} | {
|
|
4212
|
+
scope: string[];
|
|
4213
|
+
settings: {
|
|
4214
|
+
foreground: string;
|
|
4215
|
+
fontStyle?: undefined;
|
|
4216
|
+
background?: undefined;
|
|
4217
|
+
};
|
|
4218
|
+
} | {
|
|
4219
|
+
scope: string[];
|
|
4220
|
+
settings: {
|
|
4221
|
+
fontStyle: string;
|
|
4222
|
+
foreground?: undefined;
|
|
4223
|
+
background?: undefined;
|
|
4224
|
+
};
|
|
4225
|
+
} | {
|
|
4226
|
+
scope: string[];
|
|
4227
|
+
settings: {
|
|
4228
|
+
fontStyle: string;
|
|
4229
|
+
foreground: string;
|
|
4230
|
+
background?: undefined;
|
|
4231
|
+
};
|
|
4232
|
+
})[];
|
|
4233
|
+
type: string;
|
|
4234
|
+
};
|
|
4235
|
+
|
|
4236
|
+
export { A, type AProps, Accordion, AccordionItem, type AccordionItemProps, type AccordionProps, ActionIcon, ActionIconGroup, type ActionIconGroupEvent, type MenuItemType as ActionIconGroupItemType, type ActionIconGroupProps, type ActionIconProps, type ActionIconSize, Alert, type AlertProps, AutoComplete, type AutoCompleteProps, Avatar, AvatarGroup, type AvatarGroupProps, type AvatarProps, type BaseMenuItemType, Block, type BlockProps, Burger, type BurgerProps, Button, type ButtonProps, type CDN, CLASSNAMES, CUSTOM_SELECT_CONTAINER_ATTR, Checkbox, CheckboxGroup, type CheckboxGroupOption, type CheckboxGroupProps, type CheckboxProps, CodeDiff, type CodeDiffProps, CodeEditor, type CodeEditorProps, Collapse, type CollapseItemType, type CollapseProps, type ColorPalettes, type ColorPalettesAlpha, ColorSwatches, type ColorSwatchesProps, type ColorToken, type Config, ConfigProvider, type ContextMenuCheckboxItem, ContextMenuHost, type ContextMenuItem, ContextMenuTrigger, CopyButton, type CopyButtonProps, DROPDOWN_MENU_CONTAINER_ATTR, DatePicker, type DatePickerProps, type DiffViewMode, type DivProps, DownloadButton, type DownloadButtonProps, DraggablePanel, DraggablePanelBody, type DraggablePanelBodyProps, DraggablePanelContainer, type DraggablePanelContainerProps, DraggablePanelFooter, type DraggablePanelFooterProps, DraggablePanelHeader, type DraggablePanelHeaderProps, type DraggablePanelProps, DraggableSideNav, type DraggableSideNavProps, Drawer, type DrawerProps, Dropdown, type DropdownItem, DropdownMenu, type DropdownMenuCheckboxItem, DropdownMenuCheckboxItemIndicator, DropdownMenuCheckboxItemPrimitive, DropdownMenuGroup, DropdownMenuGroupLabel, type DropdownMenuGroupLabelProps, DropdownMenuItem, DropdownMenuItemContent, type DropdownMenuItemContentProps, DropdownMenuItemExtra, type DropdownMenuItemExtraProps, DropdownMenuItemIcon, type DropdownMenuItemIconProps, DropdownMenuItemLabel, type DropdownMenuItemLabelProps, type DropdownMenuItemProps, type MenuItemType as DropdownMenuItemType, type DropdownMenuPlacement, DropdownMenuPopup, type DropdownMenuPopupProps, DropdownMenuPortal, type DropdownMenuPortalProps, DropdownMenuPositioner, type DropdownMenuPositionerProps, type DropdownMenuProps, DropdownMenuRoot, DropdownMenuSeparator, type DropdownMenuSeparatorProps, DropdownMenuSubmenuArrow, type DropdownMenuSubmenuArrowProps, DropdownMenuSubmenuRoot, DropdownMenuSubmenuTrigger, type DropdownMenuSubmenuTriggerProps, DropdownMenuTrigger, type DropdownMenuTriggerProps, type DropdownProps, EditableText, type EditableTextProps, EditorSlashMenu, EditorSlashMenuGroup$1 as EditorSlashMenuGroup, type EditorSlashMenuItems, type EditorSlashMenuOption, EmojiPicker, type EmojiPickerProps, Empty, type EmptyProps, FileTypeIcon, type FileTypeIconProps, Flex, type FlexDirection, type FlexProps, FluentEmoji, type FluentEmojiProps, FontLoader, type FontLoaderProps, Footer, type FooterProps, FormComponentImpl as Form, FormCheckbox, type FormConfig, FormDatePicker, FormError, type FormFieldRules, FormGroup, FormInput, type FormInstance, FormLabel, FormModal, type FormModalProps, type FormProps, FormSegment, FormSelect, type FormState, FormSwitch, FormTimePicker, type GenericItemType, Grid, type GridProps, GroupAvatar, type GroupAvatarProps, GuideCard, type GuideCardProps, Header, type HeaderProps, Highlighter, type HighlighterProps, Hotkey, HotkeyInput, type HotkeyInputProps, type HotkeyProps, I18nProvider, type I18nProviderProps, Icon, type IconProps$1 as IconProps, IconProvider, type IconSize, Image, type ImageProps$1 as ImageProps, ImageSelect, type ImageSelectItem, type ImageSelectProps, type ImgProps, type ImperativeModalProps, Input, InputMask, type InputMaskProps, InputNumber, type InputNumberProps, InputOPT, type InputOPTProps, InputPassword, type InputPasswordProps, type InputProps, type ItemType, KeyMapEnum, Layout, LayoutFooter, type LayoutFooterProps, LayoutHeader, type LayoutHeaderProps, LayoutMain, type LayoutMainProps, type LayoutProps, LayoutSidebar, LayoutSidebarInner, type LayoutSidebarInnerProps, type LayoutSidebarProps, LayoutToc, type LayoutTocProps, List, ListItem, type ListItemProps, type ListProps, type LobeCustomStylish, type LobeCustomToken, I18nProvider as LobeUIProvider, Markdown, type MarkdownProps, MaskShadow, type MaskShadowProps, MaterialFileTypeIcon, type MaterialFileTypeIconProps, Menu, type MenuCheckboxItemType, type MenuItemType, type MenuProps, Mermaid, type MermaidProps, Meta, type MetaProps, Modal, ModalHost, type ModalHostProps, type ModalInstance, type ModalProps, ModalProvider, MotionComponent, type MotionComponentType, MotionProvider, type NeutralColors, type NeutralColorsObj, POPOVER_CONTAINER_ATTR, PatchDiff, type PatchDiffProps, type Placement, type PlacementConfig, Popover, PopoverArrow, type PopoverArrowAtomProps, PopoverArrowIcon, PopoverBackdrop, type PopoverContextValue, PopoverGroup, type PopoverPlacement, PopoverPopup, type PopoverPopupAtomProps, PopoverPortal, type PopoverPortalAtomProps, PopoverPositioner, type PopoverPositionerAtomProps, type PopoverProps, PopoverProvider, PopoverRoot, type PopoverTrigger, PopoverTriggerElement, type PopoverTriggerElementProps, PopoverViewport, type PopoverViewportAtomProps, type PresetColorKey, type PresetColorType, type PresetSystemColorKey, type PresetSystemColorType, PreviewGroup, type PreviewGroupProps, type PrimaryColors, type PrimaryColorsObj, type RawModalComponent, type RawModalComponentProps, type RawModalInstance, type RawModalKeyOptions, type RawModalOptions, SELECT_CONTAINER_ATTR, ScrollArea, ScrollAreaContent, type ScrollAreaContentProps, ScrollAreaCorner, type ScrollAreaCornerProps, type ScrollAreaProps, ScrollAreaRoot, type ScrollAreaRootProps, ScrollAreaScrollbar, type ScrollAreaScrollbarProps, ScrollAreaThumb, type ScrollAreaThumbProps, ScrollAreaViewport, type ScrollAreaViewportProps, ScrollShadow, type ScrollShadowProps, SearchBar, type SearchBarProps, SearchResultCards, type SearchResultCardsProps, Segmented, type SegmentedProps, Select, SelectArrow, type SelectArrowProps, SelectBackdrop, type SelectBehaviorVariant, type SelectClassNames, SelectGroup, SelectGroupLabel, type SelectGroupLabelProps, type SelectGroupProps, SelectIcon, type SelectIconProps, type SelectIndicatorVariant, SelectItem, SelectItemIndicator, type SelectItemIndicatorProps, type SelectItemProps, SelectItemText, type SelectItemTextProps, SelectList, type SelectListProps, type SelectOption, type SelectOptionGroup, type SelectOptions, SelectPopup, type SelectPopupProps, SelectPortal, type SelectPortalProps, SelectPositioner, type SelectPositionerProps, type SelectProps, SelectRoot, SelectScrollDownArrow, type SelectScrollDownArrowProps, SelectScrollUpArrow, type SelectScrollUpArrowProps, SelectSeparator, type SelectSize, SelectTrigger, type SelectTriggerProps, SelectValue, type SelectValueProps, type SelectVariant, _default as ShikiLobeTheme, SideNav, type SideNavProps, Skeleton, SkeletonAvatar, type SkeletonAvatarProps, SkeletonBlock, type SkeletonBlockProps, SkeletonButton, type SkeletonButtonProps, SkeletonParagraph, type SkeletonParagraphProps, type SkeletonProps, SkeletonTags, type SkeletonTagsProps, SkeletonTitle, type SkeletonTitleProps, SliderWithInput, type SliderWithInputProps, Snippet, type SnippetProps, SortableList, type SortableListProps, type SpanProps, type SvgProps, Switch, type SwitchChangeEventHandler, type SwitchClassNames, type SwitchClickEventHandler, type SwitchContextType, SwitchIcon, type SwitchIconPosition, type SwitchIconProps, type SwitchProps, SwitchRoot, type SwitchRootProps, type SwitchSize, type SwitchStyles, SwitchThumb, type SwitchThumbProps, SyntaxHighlighter, type SyntaxHighlighterProps, SyntaxMermaid, type SyntaxMermaidProps, type SystemColorToken, Table, type TableColumn, type TableDataSource, type TablePageSizeConfig, type TableProps, type TableReadConfig, Tabs, type TabsProps, Tag, type TagProps, Text, TextArea, type TextAreaProps, type TextProps, ThemeProvider, type ThemeProviderProps, ThemeSwitch, type ThemeSwitchProps, TimePicker, type Meridiem as TimePickerMeridiem, type TimePickerProps, type TimeValue as TimePickerValue, type ToastAPI, ToastHost, type ToastHostProps, type ToastInstance, type ToastOptions, type ToastPosition, type ToastPromiseOptions, type ToastProps, type ToastType, Toc, type TocProps, Tooltip, TooltipGroup, type TooltipProps, type Trigger, Typography, type TypographyProps, type UseFormReturn, Video, type VideoProps$1 as VideoProps, closeContextMenu, combineKeys, copyToClipboard, createModal, createRawModal, findCustomThemeName, genCdnUrl, generateColorNeutralPalette, generateColorPalette, highlighterThemes, generateCustomStylish as lobeCustomStylish, generateCustomToken as lobeCustomToken, staticStylish as lobeStaticStylish, styles as menuSharedStyles, mermaidThemes, neutralColors, neutralColorsSwatches, placementMap, preprocessMarkdownContent, preventDefault, preventDefaultAndStopPropagation, primaryColors, primaryColorsSwatches, rehypeCustomFootnotes, rehypeKatexDir, rehypeStreamAnimated, remarkBr, remarkColor, remarkCustomFootnotes, remarkGfmPlus, remarkVideo, renderDropdownMenuItems, runRules, showContextMenu, stopPropagation, toFloatingUIPlacement, toast, updateContextMenuItems, useCdnFn, useForm, useModalContext, useMotionComponent, usePopoverContext, usePopoverPortalContainer, useSwitchContext, useToast, useTranslation };
|