@lucasvu/scope-ui 0.1.1 → 0.1.4
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/AI_SETUP.md +1 -1
- package/README.md +186 -3
- package/bin/scope-ui-init.mjs +275 -212
- package/dist/index.d.cts +1058 -107
- package/dist/index.d.ts +1058 -107
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -8,17 +8,62 @@ export { ColorMode, ROOT_CLIENT_THEME_ATTRIBUTE, ROOT_COLOR_MODE_ATTRIBUTE, UiAi
|
|
|
8
8
|
|
|
9
9
|
type ComponentSize = 'sm' | 'md' | 'lg';
|
|
10
10
|
interface SharedComponentProps {
|
|
11
|
+
/**
|
|
12
|
+
* Nhãn hiển thị phía trên component hoặc control.
|
|
13
|
+
* Visible label rendered above the component or control.
|
|
14
|
+
* 显示在组件或控件上方的标签。
|
|
15
|
+
*/
|
|
11
16
|
label?: ReactNode;
|
|
17
|
+
/**
|
|
18
|
+
* Nội dung hỗ trợ nằm dưới control khi không có lỗi.
|
|
19
|
+
* Helper content shown below the control when there is no error.
|
|
20
|
+
* 没有错误时显示在控件下方的辅助说明。
|
|
21
|
+
*/
|
|
12
22
|
helperText?: ReactNode;
|
|
23
|
+
/**
|
|
24
|
+
* Nội dung lỗi hiển thị ưu tiên dưới control.
|
|
25
|
+
* Error content displayed below the control with higher priority.
|
|
26
|
+
* 优先显示在控件下方的错误信息。
|
|
27
|
+
*/
|
|
13
28
|
errorMessage?: ReactNode;
|
|
29
|
+
/**
|
|
30
|
+
* Trạng thái đang xử lý dữ liệu hoặc gọi API.
|
|
31
|
+
* Loading state while the component is processing or waiting for data.
|
|
32
|
+
* 组件处理中或等待数据时的加载状态。
|
|
33
|
+
*/
|
|
14
34
|
loading?: boolean;
|
|
35
|
+
/**
|
|
36
|
+
* Trạng thái vô hiệu hóa tương tác.
|
|
37
|
+
* Disables user interaction with the component.
|
|
38
|
+
* 禁用组件交互。
|
|
39
|
+
*/
|
|
15
40
|
disabled?: boolean;
|
|
41
|
+
/**
|
|
42
|
+
* Kích thước hiển thị chung của component.
|
|
43
|
+
* Shared visual size of the component.
|
|
44
|
+
* 组件的通用显示尺寸。
|
|
45
|
+
*/
|
|
16
46
|
size?: ComponentSize;
|
|
47
|
+
/**
|
|
48
|
+
* Class bổ sung để mở rộng style từ bên ngoài.
|
|
49
|
+
* Extra class names for extending styles from the outside.
|
|
50
|
+
* 用于从外部扩展样式的额外 class。
|
|
51
|
+
*/
|
|
17
52
|
className?: string;
|
|
53
|
+
/**
|
|
54
|
+
* Inline style áp trực tiếp vào wrapper gốc của component.
|
|
55
|
+
* Inline styles applied directly to the component root wrapper.
|
|
56
|
+
* 直接作用于组件根容器的内联样式。
|
|
57
|
+
*/
|
|
18
58
|
style?: CSSProperties;
|
|
19
59
|
}
|
|
20
60
|
declare const spinnerSizes: Record<'xs' | 'sm' | 'md' | 'lg', string>;
|
|
21
61
|
interface LoadingSpinnerProps extends SVGProps<SVGSVGElement> {
|
|
62
|
+
/**
|
|
63
|
+
* Kích thước của icon loading.
|
|
64
|
+
* Visual size of the loading spinner icon.
|
|
65
|
+
* 加载图标的显示尺寸。
|
|
66
|
+
*/
|
|
22
67
|
size?: keyof typeof spinnerSizes;
|
|
23
68
|
}
|
|
24
69
|
|
|
@@ -61,14 +106,49 @@ interface BadgeProps extends SharedComponentProps {
|
|
|
61
106
|
declare function Badge({ variant, size, label, helperText, errorMessage, loading, disabled, className, style, text, children, ...props }: BadgeProps): react_jsx_runtime.JSX.Element;
|
|
62
107
|
|
|
63
108
|
type BreadcrumbItem = {
|
|
109
|
+
/**
|
|
110
|
+
* Nội dung hiển thị của breadcrumb item.
|
|
111
|
+
* Visible content of the breadcrumb item.
|
|
112
|
+
* 面包屑项的显示内容。
|
|
113
|
+
*/
|
|
64
114
|
label: ReactNode;
|
|
115
|
+
/**
|
|
116
|
+
* Callback khi người dùng click item dạng button.
|
|
117
|
+
* Callback fired when the item is clicked as a button.
|
|
118
|
+
* 当该项以按钮形式点击时触发的回调。
|
|
119
|
+
*/
|
|
65
120
|
onClick?: () => void;
|
|
121
|
+
/**
|
|
122
|
+
* URL điều hướng nếu item là link.
|
|
123
|
+
* Navigation URL when the item behaves as a link.
|
|
124
|
+
* 当该项作为链接时的跳转地址。
|
|
125
|
+
*/
|
|
66
126
|
href?: string;
|
|
127
|
+
/**
|
|
128
|
+
* Đánh dấu item là vị trí hiện tại.
|
|
129
|
+
* Marks the item as the current location.
|
|
130
|
+
* 标记该项为当前位置。
|
|
131
|
+
*/
|
|
67
132
|
current?: boolean;
|
|
68
133
|
};
|
|
69
134
|
type BreadcrumbProps = {
|
|
135
|
+
/**
|
|
136
|
+
* Danh sách item của breadcrumb.
|
|
137
|
+
* List of breadcrumb items.
|
|
138
|
+
* 面包屑项列表。
|
|
139
|
+
*/
|
|
70
140
|
items: BreadcrumbItem[];
|
|
141
|
+
/**
|
|
142
|
+
* Class bổ sung cho thẻ `nav`.
|
|
143
|
+
* Extra class names for the `nav` element.
|
|
144
|
+
* `nav` 元素的额外 class。
|
|
145
|
+
*/
|
|
71
146
|
className?: string;
|
|
147
|
+
/**
|
|
148
|
+
* Ký tự hoặc node dùng để ngăn cách các item.
|
|
149
|
+
* Character or node used to separate items.
|
|
150
|
+
* 用于分隔各项的字符或节点。
|
|
151
|
+
*/
|
|
72
152
|
separator?: ReactNode;
|
|
73
153
|
};
|
|
74
154
|
declare function Breadcrumb({ items, className, separator, }: BreadcrumbProps): react_jsx_runtime.JSX.Element;
|
|
@@ -412,21 +492,66 @@ type PaginationProps = {
|
|
|
412
492
|
declare const Pagination: ({ page, pageSize, total, onChange, pageSizeOptions, onPageSizeChange, className, showFirstLast, label, }: PaginationProps) => react_jsx_runtime.JSX.Element;
|
|
413
493
|
|
|
414
494
|
type PageTitleProps = {
|
|
495
|
+
/**
|
|
496
|
+
* Tiêu đề chính của trang.
|
|
497
|
+
* Main title of the page.
|
|
498
|
+
* 页面主标题。
|
|
499
|
+
*/
|
|
415
500
|
title: string;
|
|
501
|
+
/**
|
|
502
|
+
* Mô tả ngắn nằm dưới tiêu đề.
|
|
503
|
+
* Short description shown below the title.
|
|
504
|
+
* 显示在标题下方的简短描述。
|
|
505
|
+
*/
|
|
416
506
|
subtitle?: string;
|
|
507
|
+
/**
|
|
508
|
+
* Mật độ hiển thị của header trang.
|
|
509
|
+
* Visual density of the page header.
|
|
510
|
+
* 页面头部的显示密度。
|
|
511
|
+
*/
|
|
417
512
|
size?: 'default' | 'compact';
|
|
418
|
-
|
|
513
|
+
/**
|
|
514
|
+
* Slot hiển thị bên phải phần header.
|
|
515
|
+
* Slot rendered on the right side of the header.
|
|
516
|
+
* 显示在头部右侧的插槽。
|
|
517
|
+
*/
|
|
518
|
+
rightSlot?: ReactNode;
|
|
419
519
|
};
|
|
420
520
|
declare function PageTitle$1({ title, subtitle, size, rightSlot, }: PageTitleProps): react_jsx_runtime.JSX.Element;
|
|
421
521
|
|
|
422
|
-
type SectionTitleProps
|
|
522
|
+
type SectionTitleProps = {
|
|
523
|
+
/**
|
|
524
|
+
* Tiêu đề chính của section.
|
|
525
|
+
* Main title of the section.
|
|
526
|
+
* 区块主标题。
|
|
527
|
+
*/
|
|
423
528
|
title: string;
|
|
529
|
+
/**
|
|
530
|
+
* Mô tả ngắn giải thích section.
|
|
531
|
+
* Short description that explains the section.
|
|
532
|
+
* 用于说明该区块的简短描述。
|
|
533
|
+
*/
|
|
424
534
|
subtitle?: string;
|
|
535
|
+
/**
|
|
536
|
+
* Icon hiển thị bên trái title.
|
|
537
|
+
* Icon displayed to the left of the title.
|
|
538
|
+
* 显示在标题左侧的图标。
|
|
539
|
+
*/
|
|
425
540
|
icon?: ReactNode;
|
|
541
|
+
/**
|
|
542
|
+
* Class tùy chỉnh cho wrapper của icon.
|
|
543
|
+
* Custom class for the icon wrapper.
|
|
544
|
+
* 图标容器的自定义 class。
|
|
545
|
+
*/
|
|
426
546
|
iconClassName?: string;
|
|
547
|
+
/**
|
|
548
|
+
* Slot hiển thị bên phải section title.
|
|
549
|
+
* Slot rendered on the right side of the section title.
|
|
550
|
+
* 显示在区块标题右侧的插槽。
|
|
551
|
+
*/
|
|
427
552
|
rightSlot?: ReactNode;
|
|
428
553
|
};
|
|
429
|
-
declare function SectionTitle$1({ title, subtitle, icon, iconClassName, rightSlot, }: SectionTitleProps
|
|
554
|
+
declare function SectionTitle$1({ title, subtitle, icon, iconClassName, rightSlot, }: SectionTitleProps): react_jsx_runtime.JSX.Element;
|
|
430
555
|
|
|
431
556
|
interface TabItem {
|
|
432
557
|
value: string;
|
|
@@ -453,13 +578,53 @@ declare function Loading({ label, size, className, ...props }: LoadingProps): re
|
|
|
453
578
|
type TooltipSide$2 = 'top' | 'right' | 'bottom' | 'left';
|
|
454
579
|
type TooltipAlign$2 = 'start' | 'center' | 'end';
|
|
455
580
|
type TooltipProps = {
|
|
581
|
+
/**
|
|
582
|
+
* Nội dung tooltip hiển thị khi hover/focus.
|
|
583
|
+
* Tooltip content shown on hover or focus.
|
|
584
|
+
* 悬停或聚焦时显示的 tooltip 内容。
|
|
585
|
+
*/
|
|
456
586
|
content: ReactNode;
|
|
587
|
+
/**
|
|
588
|
+
* Phần tử trigger của tooltip.
|
|
589
|
+
* Trigger element for the tooltip.
|
|
590
|
+
* tooltip 的触发元素。
|
|
591
|
+
*/
|
|
457
592
|
children: ReactNode;
|
|
593
|
+
/**
|
|
594
|
+
* Vị trí tooltip so với trigger.
|
|
595
|
+
* Tooltip side relative to the trigger.
|
|
596
|
+
* tooltip 相对触发元素的位置。
|
|
597
|
+
*/
|
|
458
598
|
side?: TooltipSide$2;
|
|
599
|
+
/**
|
|
600
|
+
* Cách canh tooltip theo trục phụ.
|
|
601
|
+
* Tooltip alignment on the secondary axis.
|
|
602
|
+
* tooltip 在次轴上的对齐方式。
|
|
603
|
+
*/
|
|
459
604
|
align?: TooltipAlign$2;
|
|
605
|
+
/**
|
|
606
|
+
* Class bổ sung cho wrapper của trigger.
|
|
607
|
+
* Extra class names for the trigger wrapper.
|
|
608
|
+
* 触发器容器的额外 class。
|
|
609
|
+
*/
|
|
460
610
|
className?: string;
|
|
611
|
+
/**
|
|
612
|
+
* Class bổ sung cho panel tooltip.
|
|
613
|
+
* Extra class names for the tooltip panel.
|
|
614
|
+
* tooltip 面板的额外 class。
|
|
615
|
+
*/
|
|
461
616
|
contentClassName?: string;
|
|
617
|
+
/**
|
|
618
|
+
* Cho phép nội dung tooltip xuống dòng.
|
|
619
|
+
* Allows tooltip content to wrap onto multiple lines.
|
|
620
|
+
* 是否允许 tooltip 内容换行。
|
|
621
|
+
*/
|
|
462
622
|
wrap?: boolean;
|
|
623
|
+
/**
|
|
624
|
+
* Render tooltip bằng portal ra `document.body`.
|
|
625
|
+
* Renders the tooltip through a portal into `document.body`.
|
|
626
|
+
* 通过 portal 将 tooltip 渲染到 `document.body`。
|
|
627
|
+
*/
|
|
463
628
|
portal?: boolean;
|
|
464
629
|
};
|
|
465
630
|
declare function Tooltip({ content, children, side, align, className, contentClassName, wrap, portal, }: TooltipProps): react_jsx_runtime.JSX.Element;
|
|
@@ -500,32 +665,152 @@ type TruncatedTextProps = {
|
|
|
500
665
|
declare function TruncatedText({ email, }: TruncatedTextProps): react_jsx_runtime.JSX.Element;
|
|
501
666
|
|
|
502
667
|
type SidebarItem$1 = {
|
|
668
|
+
/**
|
|
669
|
+
* Định danh duy nhất của item.
|
|
670
|
+
* Unique identifier of the sidebar item.
|
|
671
|
+
* 侧边栏项的唯一标识。
|
|
672
|
+
*/
|
|
503
673
|
id: string;
|
|
674
|
+
/**
|
|
675
|
+
* Tiêu đề hiển thị trực tiếp trên menu.
|
|
676
|
+
* Title rendered directly in the menu.
|
|
677
|
+
* 菜单中直接显示的标题。
|
|
678
|
+
*/
|
|
504
679
|
title?: string;
|
|
680
|
+
/**
|
|
681
|
+
* Khóa i18n nếu title sẽ được dịch ở tầng ngoài.
|
|
682
|
+
* i18n key when the title is translated outside this component.
|
|
683
|
+
* 当标题由外部国际化处理时使用的 i18n key。
|
|
684
|
+
*/
|
|
505
685
|
titleKey?: string;
|
|
686
|
+
/**
|
|
687
|
+
* Icon của item, có thể là ReactNode hoặc component.
|
|
688
|
+
* Item icon, either a ReactNode or a component type.
|
|
689
|
+
* 菜单项图标,可传 ReactNode 或组件类型。
|
|
690
|
+
*/
|
|
506
691
|
icon?: ReactNode | ElementType;
|
|
692
|
+
/**
|
|
693
|
+
* Đường dẫn điều hướng khi click item.
|
|
694
|
+
* Navigation target when the item is clicked.
|
|
695
|
+
* 点击菜单项后的跳转地址。
|
|
696
|
+
*/
|
|
507
697
|
href?: string;
|
|
698
|
+
/**
|
|
699
|
+
* Quyền yêu cầu để item được hiển thị.
|
|
700
|
+
* Required permission(s) for the item to be visible.
|
|
701
|
+
* 显示该菜单项所需的权限。
|
|
702
|
+
*/
|
|
508
703
|
permission?: string | string[];
|
|
704
|
+
/**
|
|
705
|
+
* Danh sách item con.
|
|
706
|
+
* Nested child items.
|
|
707
|
+
* 子菜单项列表。
|
|
708
|
+
*/
|
|
509
709
|
children?: SidebarItem$1[];
|
|
510
710
|
};
|
|
511
711
|
type PermissionChecker = (permission: string | string[] | undefined, userPermissions?: string[]) => boolean;
|
|
512
712
|
interface SidebarProps extends HTMLAttributes<HTMLElement> {
|
|
713
|
+
/**
|
|
714
|
+
* Cấu hình toàn bộ item sẽ render trong sidebar.
|
|
715
|
+
* Full item tree rendered inside the sidebar.
|
|
716
|
+
* 侧边栏中要渲染的完整菜单树。
|
|
717
|
+
*/
|
|
513
718
|
items: SidebarItem$1[];
|
|
719
|
+
/**
|
|
720
|
+
* Danh sách quyền hiện tại của người dùng.
|
|
721
|
+
* Current permission list of the active user.
|
|
722
|
+
* 当前用户的权限列表。
|
|
723
|
+
*/
|
|
514
724
|
userPermissions?: string[];
|
|
725
|
+
/**
|
|
726
|
+
* Hàm kiểm tra quyền tùy chỉnh.
|
|
727
|
+
* Custom permission checking function.
|
|
728
|
+
* 自定义权限校验函数。
|
|
729
|
+
*/
|
|
515
730
|
permissionChecker?: PermissionChecker;
|
|
731
|
+
/**
|
|
732
|
+
* `id` của item đang active.
|
|
733
|
+
* `id` of the currently active item.
|
|
734
|
+
* 当前激活菜单项的 `id`。
|
|
735
|
+
*/
|
|
516
736
|
activeItemId?: string;
|
|
737
|
+
/**
|
|
738
|
+
* Callback khi người dùng click vào item.
|
|
739
|
+
* Callback fired when the user clicks an item.
|
|
740
|
+
* 用户点击菜单项时触发的回调。
|
|
741
|
+
*/
|
|
517
742
|
onItemClick?: (item: SidebarItem$1) => void;
|
|
743
|
+
/**
|
|
744
|
+
* Class bổ sung cho danh sách cấp 1.
|
|
745
|
+
* Extra class names for the top-level list.
|
|
746
|
+
* 顶层列表的额外 class。
|
|
747
|
+
*/
|
|
518
748
|
listClassName?: string;
|
|
749
|
+
/**
|
|
750
|
+
* Class bổ sung cho danh sách lồng nhau.
|
|
751
|
+
* Extra class names for nested lists.
|
|
752
|
+
* 嵌套列表的额外 class。
|
|
753
|
+
*/
|
|
519
754
|
nestedListClassName?: string;
|
|
755
|
+
/**
|
|
756
|
+
* Class bổ sung cho từng item.
|
|
757
|
+
* Extra class names applied to each item.
|
|
758
|
+
* 每个菜单项的额外 class。
|
|
759
|
+
*/
|
|
520
760
|
itemClassName?: string;
|
|
761
|
+
/**
|
|
762
|
+
* Khoảng thụt lề cho mỗi cấp con.
|
|
763
|
+
* Indentation size for each nested level.
|
|
764
|
+
* 每一级嵌套的缩进宽度。
|
|
765
|
+
*/
|
|
521
766
|
indentSize?: number;
|
|
767
|
+
/**
|
|
768
|
+
* Nhãn trợ năng cho phần tử `nav`.
|
|
769
|
+
* Accessibility label for the `nav` element.
|
|
770
|
+
* `nav` 元素的无障碍标签。
|
|
771
|
+
*/
|
|
522
772
|
ariaLabel?: string;
|
|
773
|
+
/**
|
|
774
|
+
* Cho phép thu gọn hoặc mở rộng sidebar.
|
|
775
|
+
* Enables collapsing and expanding the sidebar.
|
|
776
|
+
* 是否允许侧边栏折叠/展开。
|
|
777
|
+
*/
|
|
523
778
|
collapsible?: boolean;
|
|
779
|
+
/**
|
|
780
|
+
* Trạng thái thu gọn có kiểm soát từ bên ngoài.
|
|
781
|
+
* Controlled collapsed state from the parent.
|
|
782
|
+
* 由外部控制的折叠状态。
|
|
783
|
+
*/
|
|
524
784
|
collapsed?: boolean;
|
|
785
|
+
/**
|
|
786
|
+
* Trạng thái thu gọn mặc định khi dùng uncontrolled mode.
|
|
787
|
+
* Default collapsed state in uncontrolled mode.
|
|
788
|
+
* 非受控模式下的默认折叠状态。
|
|
789
|
+
*/
|
|
525
790
|
defaultCollapsed?: boolean;
|
|
791
|
+
/**
|
|
792
|
+
* Callback khi trạng thái thu gọn thay đổi.
|
|
793
|
+
* Callback fired when the collapsed state changes.
|
|
794
|
+
* 折叠状态变化时触发的回调。
|
|
795
|
+
*/
|
|
526
796
|
onCollapseChange?: (collapsed: boolean) => void;
|
|
797
|
+
/**
|
|
798
|
+
* Chiều rộng sidebar khi đang thu gọn.
|
|
799
|
+
* Sidebar width when collapsed.
|
|
800
|
+
* 折叠时的侧边栏宽度。
|
|
801
|
+
*/
|
|
527
802
|
collapsedWidth?: number | string;
|
|
803
|
+
/**
|
|
804
|
+
* Chiều rộng sidebar khi đang mở rộng.
|
|
805
|
+
* Sidebar width when expanded.
|
|
806
|
+
* 展开时的侧边栏宽度。
|
|
807
|
+
*/
|
|
528
808
|
expandedWidth?: number | string;
|
|
809
|
+
/**
|
|
810
|
+
* Nhãn trợ năng cho nút collapse/expand.
|
|
811
|
+
* Accessibility label for the collapse/expand button.
|
|
812
|
+
* 折叠/展开按钮的无障碍标签。
|
|
813
|
+
*/
|
|
529
814
|
collapseButtonLabel?: string;
|
|
530
815
|
}
|
|
531
816
|
|
|
@@ -552,11 +837,350 @@ type ArgonSidebarHeaderRender = (state: {
|
|
|
552
837
|
hoverExpanded: boolean;
|
|
553
838
|
}) => React.ReactNode;
|
|
554
839
|
type ArgonSidebarProps = SidebarProps & {
|
|
840
|
+
/**
|
|
841
|
+
* Callback khi trạng thái hover mở rộng thay đổi.
|
|
842
|
+
* Callback fired when hover-expansion state changes.
|
|
843
|
+
* 悬停展开状态变化时触发的回调。
|
|
844
|
+
*/
|
|
555
845
|
onHoverChange?: (hovered: boolean) => void;
|
|
846
|
+
/**
|
|
847
|
+
* Nội dung header hoặc hàm render header động.
|
|
848
|
+
* Header content or a render function for dynamic header content.
|
|
849
|
+
* 头部内容,或用于动态渲染头部的函数。
|
|
850
|
+
*/
|
|
556
851
|
header?: React.ReactNode | ArgonSidebarHeaderRender;
|
|
557
852
|
};
|
|
558
853
|
declare function ArgonSidebar({ items, userPermissions, permissionChecker, activeItemId, onItemClick, listClassName, nestedListClassName, itemClassName, indentSize, ariaLabel, className, collapsible, collapsed, defaultCollapsed, onCollapseChange, collapsedWidth, expandedWidth, collapseButtonLabel, style, onHoverChange, header, ...rest }: ArgonSidebarProps): react_jsx_runtime.JSX.Element;
|
|
559
854
|
|
|
855
|
+
type MainFePageTitleProps = {
|
|
856
|
+
/**
|
|
857
|
+
* Tiêu đề chính của trang.
|
|
858
|
+
* Main title of the page.
|
|
859
|
+
* 页面主标题。
|
|
860
|
+
*/
|
|
861
|
+
title: string;
|
|
862
|
+
/**
|
|
863
|
+
* Mô tả ngắn nằm dưới tiêu đề.
|
|
864
|
+
* Short description shown below the title.
|
|
865
|
+
* 显示在标题下方的简短描述。
|
|
866
|
+
*/
|
|
867
|
+
subtitle?: string;
|
|
868
|
+
/**
|
|
869
|
+
* Mật độ hiển thị của header trang.
|
|
870
|
+
* Visual density of the page header.
|
|
871
|
+
* 页面头部的显示密度。
|
|
872
|
+
*/
|
|
873
|
+
size?: 'default' | 'compact';
|
|
874
|
+
/**
|
|
875
|
+
* Slot hiển thị phía trên title, thường dùng cho breadcrumb hoặc status.
|
|
876
|
+
* Slot rendered above the title, commonly used for breadcrumbs or status tags.
|
|
877
|
+
* 显示在标题上方的插槽,常用于面包屑或状态标签。
|
|
878
|
+
*/
|
|
879
|
+
topSlot?: ReactNode;
|
|
880
|
+
/**
|
|
881
|
+
* Slot hiển thị phía bên phải phần header.
|
|
882
|
+
* Slot rendered on the right side of the header.
|
|
883
|
+
* 显示在头部右侧的插槽。
|
|
884
|
+
*/
|
|
885
|
+
rightSlot?: ReactNode;
|
|
886
|
+
};
|
|
887
|
+
declare function PageTitle({ title, subtitle, size, topSlot, rightSlot, }: MainFePageTitleProps): react_jsx_runtime.JSX.Element;
|
|
888
|
+
|
|
889
|
+
type MainFeSectionTitleProps = {
|
|
890
|
+
/**
|
|
891
|
+
* Tiêu đề chính của section.
|
|
892
|
+
* Main title of the section.
|
|
893
|
+
* 区块主标题。
|
|
894
|
+
*/
|
|
895
|
+
title: string;
|
|
896
|
+
/**
|
|
897
|
+
* Mô tả ngắn giải thích section.
|
|
898
|
+
* Short description that explains the section.
|
|
899
|
+
* 用于说明该区块的简短描述。
|
|
900
|
+
*/
|
|
901
|
+
subtitle?: string;
|
|
902
|
+
/**
|
|
903
|
+
* Icon hiển thị bên trái title.
|
|
904
|
+
* Icon displayed to the left of the title.
|
|
905
|
+
* 显示在标题左侧的图标。
|
|
906
|
+
*/
|
|
907
|
+
icon?: ReactNode;
|
|
908
|
+
/**
|
|
909
|
+
* Class tùy chỉnh cho wrapper của icon.
|
|
910
|
+
* Custom class for the icon wrapper.
|
|
911
|
+
* 图标容器的自定义 class。
|
|
912
|
+
*/
|
|
913
|
+
iconClassName?: string;
|
|
914
|
+
/**
|
|
915
|
+
* Slot hiển thị bên phải section title.
|
|
916
|
+
* Slot rendered on the right side of the section title.
|
|
917
|
+
* 显示在区块标题右侧的插槽。
|
|
918
|
+
*/
|
|
919
|
+
rightSlot?: ReactNode;
|
|
920
|
+
};
|
|
921
|
+
declare function SectionTitle({ title, subtitle, icon, iconClassName, rightSlot, }: MainFeSectionTitleProps): react_jsx_runtime.JSX.Element;
|
|
922
|
+
|
|
923
|
+
type MultiTabItem = {
|
|
924
|
+
/**
|
|
925
|
+
* Nhãn hiển thị trên tab.
|
|
926
|
+
* Visible label rendered on the tab.
|
|
927
|
+
* Tab 上显示的标签文本。
|
|
928
|
+
*/
|
|
929
|
+
label: ReactNode;
|
|
930
|
+
/**
|
|
931
|
+
* Giá trị định danh của tab.
|
|
932
|
+
* Identifier value of the tab.
|
|
933
|
+
* Tab 的标识值。
|
|
934
|
+
*/
|
|
935
|
+
value: string;
|
|
936
|
+
};
|
|
937
|
+
interface MultiTabsProps {
|
|
938
|
+
/**
|
|
939
|
+
* Danh sách tab cần render.
|
|
940
|
+
* List of tabs to render.
|
|
941
|
+
* 需要渲染的 tab 列表。
|
|
942
|
+
*/
|
|
943
|
+
items: MultiTabItem[];
|
|
944
|
+
/**
|
|
945
|
+
* Giá trị tab đang được chọn.
|
|
946
|
+
* Currently selected tab value.
|
|
947
|
+
* 当前选中的 tab 值。
|
|
948
|
+
*/
|
|
949
|
+
value: string;
|
|
950
|
+
/**
|
|
951
|
+
* Callback khi người dùng đổi tab.
|
|
952
|
+
* Callback fired when the user switches tabs.
|
|
953
|
+
* 用户切换 tab 时触发的回调。
|
|
954
|
+
*/
|
|
955
|
+
onChange: (value: string) => void;
|
|
956
|
+
/**
|
|
957
|
+
* Class bổ sung cho wrapper của nhóm tab.
|
|
958
|
+
* Extra class names for the tab group wrapper.
|
|
959
|
+
* tab 组容器的额外 class。
|
|
960
|
+
*/
|
|
961
|
+
className?: string;
|
|
962
|
+
/**
|
|
963
|
+
* Inline style cho wrapper của nhóm tab.
|
|
964
|
+
* Inline styles for the tab group wrapper.
|
|
965
|
+
* tab 组容器的内联样式。
|
|
966
|
+
*/
|
|
967
|
+
style?: CSSProperties;
|
|
968
|
+
}
|
|
969
|
+
declare function MultiTabs({ items, value, onChange, className, style, }: MultiTabsProps): react_jsx_runtime.JSX.Element;
|
|
970
|
+
|
|
971
|
+
type StatTone = 'emerald' | 'sky' | 'violet' | 'rose';
|
|
972
|
+
type StatCardProps = {
|
|
973
|
+
/**
|
|
974
|
+
* Nhãn mô tả ý nghĩa của chỉ số.
|
|
975
|
+
* Label describing what the metric represents.
|
|
976
|
+
* 用于说明指标含义的标签。
|
|
977
|
+
*/
|
|
978
|
+
label: ReactNode;
|
|
979
|
+
/**
|
|
980
|
+
* Giá trị chính cần nhấn mạnh.
|
|
981
|
+
* Primary value that should be emphasized.
|
|
982
|
+
* 需要重点展示的主数值。
|
|
983
|
+
*/
|
|
984
|
+
value: ReactNode;
|
|
985
|
+
/**
|
|
986
|
+
* Tông màu chủ đạo của card.
|
|
987
|
+
* Primary visual tone of the card.
|
|
988
|
+
* 卡片的主视觉色调。
|
|
989
|
+
*/
|
|
990
|
+
tone?: StatTone;
|
|
991
|
+
/**
|
|
992
|
+
* Icon hiển thị ở góc phải card.
|
|
993
|
+
* Icon displayed in the right corner of the card.
|
|
994
|
+
* 显示在卡片右侧的图标。
|
|
995
|
+
*/
|
|
996
|
+
icon?: ReactNode;
|
|
997
|
+
/**
|
|
998
|
+
* Class bổ sung cho wrapper của card.
|
|
999
|
+
* Extra class names for the card wrapper.
|
|
1000
|
+
* 卡片容器的额外 class。
|
|
1001
|
+
*/
|
|
1002
|
+
className?: string;
|
|
1003
|
+
};
|
|
1004
|
+
declare function StatCard({ label, value, tone, icon, className, }: StatCardProps): react_jsx_runtime.JSX.Element;
|
|
1005
|
+
|
|
1006
|
+
type RemoteLoadingProps = {
|
|
1007
|
+
/**
|
|
1008
|
+
* Class bổ sung cho wrapper loading toàn trang.
|
|
1009
|
+
* Extra class names for the full-page loading wrapper.
|
|
1010
|
+
* 全页加载容器的额外 class。
|
|
1011
|
+
*/
|
|
1012
|
+
className?: string;
|
|
1013
|
+
};
|
|
1014
|
+
declare function RemoteLoading({ className }: RemoteLoadingProps): react_jsx_runtime.JSX.Element;
|
|
1015
|
+
|
|
1016
|
+
type DateRangePickerValue = {
|
|
1017
|
+
/**
|
|
1018
|
+
* Ngày bắt đầu ở dạng string/ISO.
|
|
1019
|
+
* Start date in string or ISO format.
|
|
1020
|
+
* 字符串/ISO 格式的开始日期。
|
|
1021
|
+
*/
|
|
1022
|
+
startDate?: string | null;
|
|
1023
|
+
/**
|
|
1024
|
+
* Ngày kết thúc ở dạng string/ISO.
|
|
1025
|
+
* End date in string or ISO format.
|
|
1026
|
+
* 字符串/ISO 格式的结束日期。
|
|
1027
|
+
*/
|
|
1028
|
+
endDate?: string | null;
|
|
1029
|
+
};
|
|
1030
|
+
interface DateRangePickerProps {
|
|
1031
|
+
/**
|
|
1032
|
+
* Khoảng ngày hiện tại của component.
|
|
1033
|
+
* Current date range value of the component.
|
|
1034
|
+
* 组件当前的日期区间值。
|
|
1035
|
+
*/
|
|
1036
|
+
value?: DateRangePickerValue;
|
|
1037
|
+
/**
|
|
1038
|
+
* Callback khi người dùng xác nhận khoảng ngày mới.
|
|
1039
|
+
* Callback fired when the user confirms a new date range.
|
|
1040
|
+
* 用户确认新的日期区间时触发的回调。
|
|
1041
|
+
*/
|
|
1042
|
+
onChange: (next: Required<DateRangePickerValue>) => void;
|
|
1043
|
+
/**
|
|
1044
|
+
* Nhãn hiển thị phía trên picker.
|
|
1045
|
+
* Label shown above the picker.
|
|
1046
|
+
* 显示在选择器上方的标签。
|
|
1047
|
+
*/
|
|
1048
|
+
label?: string;
|
|
1049
|
+
/**
|
|
1050
|
+
* Placeholder khi chưa chọn ngày.
|
|
1051
|
+
* Placeholder shown before a range is selected.
|
|
1052
|
+
* 未选择日期时显示的占位文本。
|
|
1053
|
+
*/
|
|
1054
|
+
placeholder?: string;
|
|
1055
|
+
/**
|
|
1056
|
+
* Class bổ sung cho wrapper của picker.
|
|
1057
|
+
* Extra class names for the picker wrapper.
|
|
1058
|
+
* 选择器容器的额外 class。
|
|
1059
|
+
*/
|
|
1060
|
+
className?: string;
|
|
1061
|
+
}
|
|
1062
|
+
declare function DateRangePicker({ value, onChange, label, placeholder, className, }: DateRangePickerProps): react_jsx_runtime.JSX.Element;
|
|
1063
|
+
|
|
1064
|
+
type QuickOption = {
|
|
1065
|
+
/**
|
|
1066
|
+
* Nhãn hiển thị của lựa chọn nhanh.
|
|
1067
|
+
* Visible label of the quick option.
|
|
1068
|
+
* 快捷选项的显示标签。
|
|
1069
|
+
*/
|
|
1070
|
+
label: string;
|
|
1071
|
+
/**
|
|
1072
|
+
* Giá trị sẽ được áp vào picker khi chọn nhanh.
|
|
1073
|
+
* Value applied to the picker when the quick option is chosen.
|
|
1074
|
+
* 选择快捷项时写入 picker 的值。
|
|
1075
|
+
*/
|
|
1076
|
+
value: string;
|
|
1077
|
+
};
|
|
1078
|
+
interface DateTimePickerProps {
|
|
1079
|
+
/**
|
|
1080
|
+
* Nhãn hiển thị phía trên picker.
|
|
1081
|
+
* Label shown above the picker.
|
|
1082
|
+
* 显示在选择器上方的标签。
|
|
1083
|
+
*/
|
|
1084
|
+
label?: ReactNode;
|
|
1085
|
+
/**
|
|
1086
|
+
* Placeholder khi chưa có giá trị.
|
|
1087
|
+
* Placeholder shown when no value is set.
|
|
1088
|
+
* 未设置值时显示的占位文本。
|
|
1089
|
+
*/
|
|
1090
|
+
placeholder?: string;
|
|
1091
|
+
/**
|
|
1092
|
+
* Giá trị hiện tại của picker.
|
|
1093
|
+
* Current value of the picker.
|
|
1094
|
+
* picker 当前值。
|
|
1095
|
+
*/
|
|
1096
|
+
value?: string;
|
|
1097
|
+
/**
|
|
1098
|
+
* Callback khi giá trị ngày giờ thay đổi.
|
|
1099
|
+
* Callback fired when the date-time value changes.
|
|
1100
|
+
* 日期时间值变化时触发的回调。
|
|
1101
|
+
*/
|
|
1102
|
+
onChange: (value: string) => void;
|
|
1103
|
+
/**
|
|
1104
|
+
* Vô hiệu hóa toàn bộ picker.
|
|
1105
|
+
* Disables the entire picker.
|
|
1106
|
+
* 禁用整个选择器。
|
|
1107
|
+
*/
|
|
1108
|
+
disabled?: boolean;
|
|
1109
|
+
/**
|
|
1110
|
+
* Thông báo lỗi hiển thị dưới field.
|
|
1111
|
+
* Error message shown below the field.
|
|
1112
|
+
* 显示在字段下方的错误信息。
|
|
1113
|
+
*/
|
|
1114
|
+
errorMessage?: string;
|
|
1115
|
+
/**
|
|
1116
|
+
* Class bổ sung cho wrapper của picker.
|
|
1117
|
+
* Extra class names for the picker wrapper.
|
|
1118
|
+
* 选择器容器的额外 class。
|
|
1119
|
+
*/
|
|
1120
|
+
className?: string;
|
|
1121
|
+
/**
|
|
1122
|
+
* Format dùng để parse `value` đầu vào.
|
|
1123
|
+
* Format used to parse the incoming `value`.
|
|
1124
|
+
* 用于解析输入 `value` 的格式。
|
|
1125
|
+
*/
|
|
1126
|
+
parseFormat?: string;
|
|
1127
|
+
/**
|
|
1128
|
+
* Format dùng để trả dữ liệu ra ngoài qua `onChange`.
|
|
1129
|
+
* Format used for outgoing values passed to `onChange`.
|
|
1130
|
+
* 通过 `onChange` 输出时使用的格式。
|
|
1131
|
+
*/
|
|
1132
|
+
outputFormat?: string;
|
|
1133
|
+
/**
|
|
1134
|
+
* Format hiển thị cho phần text trong trigger.
|
|
1135
|
+
* Display format for the text shown in the trigger.
|
|
1136
|
+
* 触发器中显示文本所使用的格式。
|
|
1137
|
+
*/
|
|
1138
|
+
displayFormat?: string;
|
|
1139
|
+
/**
|
|
1140
|
+
* Mốc ngày giờ nhỏ nhất được phép chọn.
|
|
1141
|
+
* Minimum selectable date-time.
|
|
1142
|
+
* 可选择的最小日期时间。
|
|
1143
|
+
*/
|
|
1144
|
+
minDateTime?: Date;
|
|
1145
|
+
/**
|
|
1146
|
+
* Danh sách lựa chọn nhanh.
|
|
1147
|
+
* List of quick-select options.
|
|
1148
|
+
* 快捷选择项列表。
|
|
1149
|
+
*/
|
|
1150
|
+
quickOptions?: QuickOption[];
|
|
1151
|
+
/**
|
|
1152
|
+
* Callback khi người dùng chọn một quick option.
|
|
1153
|
+
* Callback fired when a quick option is selected.
|
|
1154
|
+
* 用户选择快捷项时触发的回调。
|
|
1155
|
+
*/
|
|
1156
|
+
onQuickSelect?: (value: string) => void;
|
|
1157
|
+
/**
|
|
1158
|
+
* Callback khi người dùng xóa giá trị hiện tại.
|
|
1159
|
+
* Callback fired when the current value is cleared.
|
|
1160
|
+
* 用户清空当前值时触发的回调。
|
|
1161
|
+
*/
|
|
1162
|
+
onClear?: () => void;
|
|
1163
|
+
/**
|
|
1164
|
+
* Tiêu đề cho nhóm quick ranges.
|
|
1165
|
+
* Title for the quick-range section.
|
|
1166
|
+
* 快捷范围分组标题。
|
|
1167
|
+
*/
|
|
1168
|
+
quickRangesLabel?: string;
|
|
1169
|
+
/**
|
|
1170
|
+
* Nhãn hiển thị cho hành động clear.
|
|
1171
|
+
* Label shown for the clear action.
|
|
1172
|
+
* 清空操作显示的标签。
|
|
1173
|
+
*/
|
|
1174
|
+
clearLabel?: string;
|
|
1175
|
+
/**
|
|
1176
|
+
* Render panel bằng portal ra ngoài layout hiện tại.
|
|
1177
|
+
* Renders the picker panel in a portal outside the current layout.
|
|
1178
|
+
* 通过 portal 在当前布局外渲染面板。
|
|
1179
|
+
*/
|
|
1180
|
+
portal?: boolean;
|
|
1181
|
+
}
|
|
1182
|
+
declare function DateTimePicker({ label, placeholder, value, onChange, disabled, errorMessage, className, parseFormat, outputFormat, displayFormat, minDateTime, quickOptions, onQuickSelect, onClear, quickRangesLabel, clearLabel, portal, }: DateTimePickerProps): react_jsx_runtime.JSX.Element;
|
|
1183
|
+
|
|
560
1184
|
declare const buttonVariants: (props?: ({
|
|
561
1185
|
variant?: "link" | "default" | "destructive" | "outline" | "confirm" | "secondary" | "ghost" | "create" | null | undefined;
|
|
562
1186
|
size?: "sm" | "md" | "lg" | "icon" | null | undefined;
|
|
@@ -564,164 +1188,499 @@ declare const buttonVariants: (props?: ({
|
|
|
564
1188
|
type ButtonVariant = VariantProps<typeof buttonVariants>['variant'];
|
|
565
1189
|
type ButtonSize = 'sm' | 'md' | 'lg' | 'icon';
|
|
566
1190
|
interface ButtonProps extends Omit<SharedComponentProps, 'size'>, Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'size' | 'className'> {
|
|
1191
|
+
/**
|
|
1192
|
+
* Biến thể giao diện của button.
|
|
1193
|
+
* Visual variant of the button.
|
|
1194
|
+
* 按钮的视觉变体。
|
|
1195
|
+
*/
|
|
567
1196
|
variant?: ButtonVariant;
|
|
1197
|
+
/**
|
|
1198
|
+
* Kích thước hiển thị của button.
|
|
1199
|
+
* Visual size of the button.
|
|
1200
|
+
* 按钮的显示尺寸。
|
|
1201
|
+
*/
|
|
568
1202
|
size?: ButtonSize;
|
|
1203
|
+
/**
|
|
1204
|
+
* Icon hiển thị trước nội dung chính.
|
|
1205
|
+
* Icon rendered before the main content.
|
|
1206
|
+
* 显示在主要内容前面的图标。
|
|
1207
|
+
*/
|
|
569
1208
|
startIcon?: ReactNode;
|
|
1209
|
+
/**
|
|
1210
|
+
* Icon hiển thị sau nội dung chính.
|
|
1211
|
+
* Icon rendered after the main content.
|
|
1212
|
+
* 显示在主要内容后面的图标。
|
|
1213
|
+
*/
|
|
570
1214
|
endIcon?: ReactNode;
|
|
1215
|
+
/**
|
|
1216
|
+
* Nội dung custom của button.
|
|
1217
|
+
* Custom button content.
|
|
1218
|
+
* 按钮的自定义内容。
|
|
1219
|
+
*/
|
|
571
1220
|
children?: ReactNode;
|
|
572
1221
|
}
|
|
573
1222
|
declare const Button: react.ForwardRefExoticComponent<ButtonProps & react.RefAttributes<HTMLButtonElement>>;
|
|
574
1223
|
|
|
575
|
-
declare function Card({ className, ...props }: react.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
576
|
-
declare function CardHeader({ className, ...props }: react.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
577
|
-
declare function CardTitle({ className, ...props }: react.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
578
|
-
declare function CardDescription({ className, ...props }: react.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
579
|
-
declare function CardAction({ className, ...props }: react.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
580
|
-
declare function CardContent({ className, ...props }: react.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
581
|
-
declare function CardFooter({ className, ...props }: react.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
582
|
-
|
|
583
|
-
type SectionTitleProps = {
|
|
584
|
-
title: string;
|
|
585
|
-
subtitle?: string;
|
|
586
|
-
icon?: ReactNode;
|
|
587
|
-
iconClassName?: string;
|
|
588
|
-
rightSlot?: ReactNode;
|
|
589
|
-
};
|
|
590
|
-
declare function SectionTitle({ title, subtitle, icon, iconClassName, rightSlot, }: SectionTitleProps): react_jsx_runtime.JSX.Element;
|
|
591
|
-
|
|
592
1224
|
declare const inputVariants: (props?: ({
|
|
593
1225
|
variant?: "default" | "outline" | "ghost" | null | undefined;
|
|
594
1226
|
size?: "sm" | "md" | "lg" | null | undefined;
|
|
595
1227
|
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
596
1228
|
type InputVariant = VariantProps<typeof inputVariants>['variant'];
|
|
597
1229
|
interface InputProps extends SharedComponentProps, Omit<InputHTMLAttributes<HTMLInputElement>, 'className' | 'size' | 'prefix'> {
|
|
1230
|
+
/**
|
|
1231
|
+
* Biến thể giao diện của input.
|
|
1232
|
+
* Visual variant of the input.
|
|
1233
|
+
* 输入框的视觉变体。
|
|
1234
|
+
*/
|
|
598
1235
|
variant?: InputVariant;
|
|
1236
|
+
/**
|
|
1237
|
+
* Nội dung hiển thị ở mép trái input.
|
|
1238
|
+
* Content rendered on the left side of the input.
|
|
1239
|
+
* 显示在输入框左侧的内容。
|
|
1240
|
+
*/
|
|
599
1241
|
prefix?: ReactNode;
|
|
1242
|
+
/**
|
|
1243
|
+
* Nội dung hiển thị ở mép phải input.
|
|
1244
|
+
* Content rendered on the right side of the input.
|
|
1245
|
+
* 显示在输入框右侧的内容。
|
|
1246
|
+
*/
|
|
600
1247
|
suffix?: ReactNode;
|
|
1248
|
+
/**
|
|
1249
|
+
* Class áp trực tiếp lên thẻ `<input>`.
|
|
1250
|
+
* Class names applied directly to the `<input>` element.
|
|
1251
|
+
* 直接作用于 `<input>` 元素的 class。
|
|
1252
|
+
*/
|
|
601
1253
|
inputClassName?: string;
|
|
1254
|
+
/**
|
|
1255
|
+
* Callback trả về giá trị string hiện tại của input.
|
|
1256
|
+
* Callback that returns the current string value of the input.
|
|
1257
|
+
* 返回当前输入字符串值的回调。
|
|
1258
|
+
*/
|
|
602
1259
|
onValueChange?: (value: string) => void;
|
|
1260
|
+
/**
|
|
1261
|
+
* Bật hoặc tắt nút hiện/ẩn mật khẩu khi `type="password"`.
|
|
1262
|
+
* Enables or disables the password visibility toggle when `type="password"`.
|
|
1263
|
+
* 当 `type="password"` 时启用或禁用密码显隐切换按钮。
|
|
1264
|
+
*/
|
|
603
1265
|
showPasswordToggle?: boolean;
|
|
604
1266
|
}
|
|
605
1267
|
declare const Input: react.ForwardRefExoticComponent<InputProps & react.RefAttributes<HTMLInputElement>>;
|
|
606
1268
|
|
|
607
1269
|
type ComboboxOption = {
|
|
1270
|
+
/**
|
|
1271
|
+
* Nhãn hiển thị trong input và dropdown.
|
|
1272
|
+
* Visible label shown in the input and dropdown.
|
|
1273
|
+
* 显示在输入框和下拉列表中的标签。
|
|
1274
|
+
*/
|
|
608
1275
|
label: string;
|
|
1276
|
+
/**
|
|
1277
|
+
* Giá trị thật của option.
|
|
1278
|
+
* Actual value of the option.
|
|
1279
|
+
* 选项的实际值。
|
|
1280
|
+
*/
|
|
609
1281
|
value: string | number;
|
|
1282
|
+
/**
|
|
1283
|
+
* Mô tả phụ của option nếu UI muốn hiển thị thêm.
|
|
1284
|
+
* Secondary description for the option when the UI needs extra context.
|
|
1285
|
+
* 当界面需要更多说明时可显示的次级描述。
|
|
1286
|
+
*/
|
|
610
1287
|
description?: string;
|
|
1288
|
+
/**
|
|
1289
|
+
* Giá trị dùng riêng cho việc tìm kiếm.
|
|
1290
|
+
* Alternate value used specifically for searching.
|
|
1291
|
+
* 专门用于搜索匹配的值。
|
|
1292
|
+
*/
|
|
611
1293
|
searchValue?: string;
|
|
1294
|
+
/**
|
|
1295
|
+
* Đánh dấu option không thể chọn.
|
|
1296
|
+
* Marks the option as unavailable for selection.
|
|
1297
|
+
* 标记该选项不可选。
|
|
1298
|
+
*/
|
|
612
1299
|
disabled?: boolean;
|
|
613
1300
|
};
|
|
614
1301
|
type ComboboxAsyncConfig = {
|
|
1302
|
+
/**
|
|
1303
|
+
* Callback tìm kiếm từ xa mỗi khi người dùng nhập.
|
|
1304
|
+
* Remote search callback fired when the user types.
|
|
1305
|
+
* 用户输入时触发的远程搜索回调。
|
|
1306
|
+
*/
|
|
615
1307
|
onSearch?: (value: string) => void;
|
|
1308
|
+
/**
|
|
1309
|
+
* Callback tải thêm dữ liệu khi dropdown chạm cuối.
|
|
1310
|
+
* Callback for loading more data when the dropdown reaches the end.
|
|
1311
|
+
* 下拉列表滚动到底部时加载更多数据的回调。
|
|
1312
|
+
*/
|
|
616
1313
|
onLoadMore?: () => void;
|
|
1314
|
+
/**
|
|
1315
|
+
* Cho biết còn dữ liệu để tải thêm hay không.
|
|
1316
|
+
* Indicates whether more remote data is available.
|
|
1317
|
+
* 是否还有更多远程数据可加载。
|
|
1318
|
+
*/
|
|
617
1319
|
hasMore?: boolean;
|
|
1320
|
+
/**
|
|
1321
|
+
* Có reset từ khóa tìm kiếm khi focus lại hay không.
|
|
1322
|
+
* Whether to reset the search term when the field is focused again.
|
|
1323
|
+
* 再次聚焦时是否重置搜索词。
|
|
1324
|
+
*/
|
|
618
1325
|
resetSearchOnFocus?: boolean;
|
|
1326
|
+
/**
|
|
1327
|
+
* Có khôi phục option đã chọn khi blur mà chưa chọn mới hay không.
|
|
1328
|
+
* Whether to restore the selected option on blur if nothing new is chosen.
|
|
1329
|
+
* 失焦且未选择新值时是否恢复已选项。
|
|
1330
|
+
*/
|
|
619
1331
|
restoreSelectedOnBlur?: boolean;
|
|
620
1332
|
};
|
|
621
1333
|
interface ComboboxProps extends SharedComponentProps {
|
|
1334
|
+
/**
|
|
1335
|
+
* Danh sách option hiển thị trong dropdown.
|
|
1336
|
+
* Option list rendered in the dropdown.
|
|
1337
|
+
* 下拉列表中渲染的选项列表。
|
|
1338
|
+
*/
|
|
622
1339
|
options: ComboboxOption[];
|
|
1340
|
+
/**
|
|
1341
|
+
* Giá trị đang được chọn.
|
|
1342
|
+
* Currently selected value.
|
|
1343
|
+
* 当前选中的值。
|
|
1344
|
+
*/
|
|
623
1345
|
value?: string | number;
|
|
1346
|
+
/**
|
|
1347
|
+
* Placeholder hiển thị khi chưa có giá trị.
|
|
1348
|
+
* Placeholder shown when no value is selected.
|
|
1349
|
+
* 未选择值时显示的占位文本。
|
|
1350
|
+
*/
|
|
624
1351
|
placeholder?: string;
|
|
1352
|
+
/**
|
|
1353
|
+
* Callback khi người dùng chọn một option.
|
|
1354
|
+
* Callback fired when the user selects an option.
|
|
1355
|
+
* 用户选择某个选项时触发的回调。
|
|
1356
|
+
*/
|
|
625
1357
|
onChange?: (value: ComboboxOption['value']) => void;
|
|
1358
|
+
/**
|
|
1359
|
+
* Callback khi nội dung nhập thay đổi.
|
|
1360
|
+
* Callback fired when the input text changes.
|
|
1361
|
+
* 输入内容变化时触发的回调。
|
|
1362
|
+
*/
|
|
626
1363
|
onInputChange?: (value: string) => void;
|
|
1364
|
+
/**
|
|
1365
|
+
* Callback tải thêm thủ công ở cuối danh sách.
|
|
1366
|
+
* Manual callback for loading more items at the end of the list.
|
|
1367
|
+
* 列表末尾手动加载更多的回调。
|
|
1368
|
+
*/
|
|
627
1369
|
onLoadMore?: () => void;
|
|
1370
|
+
/**
|
|
1371
|
+
* Cho biết còn dữ liệu để load thêm hay không.
|
|
1372
|
+
* Indicates whether more data can be loaded.
|
|
1373
|
+
* 是否还有更多数据可加载。
|
|
1374
|
+
*/
|
|
628
1375
|
hasMore?: boolean;
|
|
1376
|
+
/**
|
|
1377
|
+
* Cấu hình cho chế độ async/remote search.
|
|
1378
|
+
* Configuration for async or remote-search behavior.
|
|
1379
|
+
* 异步/远程搜索模式的配置。
|
|
1380
|
+
*/
|
|
629
1381
|
asyncConfig?: ComboboxAsyncConfig;
|
|
1382
|
+
/**
|
|
1383
|
+
* Trạng thái đang tải dữ liệu.
|
|
1384
|
+
* Loading state while data is being fetched.
|
|
1385
|
+
* 数据加载中的状态。
|
|
1386
|
+
*/
|
|
630
1387
|
loading?: boolean;
|
|
1388
|
+
/**
|
|
1389
|
+
* Vô hiệu hóa toàn bộ combobox.
|
|
1390
|
+
* Disables the entire combobox.
|
|
1391
|
+
* 禁用整个 combobox。
|
|
1392
|
+
*/
|
|
631
1393
|
disabled?: boolean;
|
|
1394
|
+
/**
|
|
1395
|
+
* Placeholder dành riêng cho ô search.
|
|
1396
|
+
* Placeholder specifically for the search input.
|
|
1397
|
+
* 搜索输入框专用的占位文本。
|
|
1398
|
+
*/
|
|
632
1399
|
searchPlaceholder?: string;
|
|
1400
|
+
/**
|
|
1401
|
+
* `id` dùng cho helper text để liên kết accessibility.
|
|
1402
|
+
* `id` used by helper text for accessibility linkage.
|
|
1403
|
+
* 用于辅助文本无障碍关联的 `id`。
|
|
1404
|
+
*/
|
|
633
1405
|
helperId?: string;
|
|
1406
|
+
/**
|
|
1407
|
+
* `id` dùng cho error text để liên kết accessibility.
|
|
1408
|
+
* `id` used by error text for accessibility linkage.
|
|
1409
|
+
* 用于错误文本无障碍关联的 `id`。
|
|
1410
|
+
*/
|
|
634
1411
|
errorId?: string;
|
|
1412
|
+
/**
|
|
1413
|
+
* Cho phép hiển thị nút xóa giá trị hiện tại.
|
|
1414
|
+
* Enables a button for clearing the current value.
|
|
1415
|
+
* 是否显示清空当前值的按钮。
|
|
1416
|
+
*/
|
|
635
1417
|
allowClear?: boolean;
|
|
1418
|
+
/**
|
|
1419
|
+
* Callback khi người dùng bấm xóa giá trị.
|
|
1420
|
+
* Callback fired when the current value is cleared.
|
|
1421
|
+
* 用户清空当前值时触发的回调。
|
|
1422
|
+
*/
|
|
636
1423
|
onClear?: () => void;
|
|
1424
|
+
/**
|
|
1425
|
+
* Render dropdown bằng portal ra ngoài layout hiện tại.
|
|
1426
|
+
* Renders the dropdown in a portal outside the current layout.
|
|
1427
|
+
* 通过 portal 在当前布局外渲染下拉层。
|
|
1428
|
+
*/
|
|
637
1429
|
portal?: boolean;
|
|
1430
|
+
/**
|
|
1431
|
+
* Class bổ sung cho dropdown menu.
|
|
1432
|
+
* Extra class names for the dropdown menu.
|
|
1433
|
+
* 下拉菜单的额外 class。
|
|
1434
|
+
*/
|
|
638
1435
|
dropdownClassName?: string;
|
|
639
|
-
/**
|
|
1436
|
+
/**
|
|
1437
|
+
* Ghi đè chiều cao tối đa của dropdown.
|
|
1438
|
+
* Overrides the maximum height of the dropdown.
|
|
1439
|
+
* 覆盖下拉层的最大高度。
|
|
1440
|
+
*/
|
|
640
1441
|
dropdownMaxHeight?: number;
|
|
641
|
-
/**
|
|
1442
|
+
/**
|
|
1443
|
+
* Giữ style lỗi nhưng không render dòng error bên dưới field.
|
|
1444
|
+
* Keeps error styling without rendering the error text below the field.
|
|
1445
|
+
* 保留错误样式,但不在字段下方渲染错误文本。
|
|
1446
|
+
*/
|
|
642
1447
|
hideErrorMessage?: boolean;
|
|
643
1448
|
}
|
|
644
1449
|
declare const Combobox: react.ForwardRefExoticComponent<ComboboxProps & react.RefAttributes<HTMLInputElement>>;
|
|
645
1450
|
|
|
646
|
-
interface SwitchProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'type' | 'size' | 'className' | 'onChange'> {
|
|
647
|
-
className?: string;
|
|
648
|
-
trackClassName?: string;
|
|
649
|
-
thumbClassName?: string;
|
|
650
|
-
onCheckedChange?: (checked: boolean) => void;
|
|
651
|
-
}
|
|
652
|
-
declare const Switch: react.ForwardRefExoticComponent<SwitchProps & react.RefAttributes<HTMLInputElement>>;
|
|
653
|
-
|
|
654
|
-
type MultiTabItem = {
|
|
655
|
-
label: ReactNode;
|
|
656
|
-
value: string;
|
|
657
|
-
};
|
|
658
|
-
interface MultiTabsProps {
|
|
659
|
-
items: MultiTabItem[];
|
|
660
|
-
value: string;
|
|
661
|
-
onChange: (value: string) => void;
|
|
662
|
-
className?: string;
|
|
663
|
-
style?: CSSProperties;
|
|
664
|
-
}
|
|
665
|
-
declare function MultiTabs({ items, value, onChange, className, style, }: MultiTabsProps): react_jsx_runtime.JSX.Element;
|
|
666
|
-
|
|
667
|
-
type StatTone = 'emerald' | 'sky' | 'violet' | 'rose';
|
|
668
|
-
type StatCardProps = {
|
|
669
|
-
label: ReactNode;
|
|
670
|
-
value: ReactNode;
|
|
671
|
-
tone?: StatTone;
|
|
672
|
-
icon?: ReactNode;
|
|
673
|
-
className?: string;
|
|
674
|
-
};
|
|
675
|
-
declare function StatCard({ label, value, tone, icon, className, }: StatCardProps): react_jsx_runtime.JSX.Element;
|
|
676
|
-
|
|
677
1451
|
type DataTableSortDirection = 'asc' | 'desc';
|
|
678
1452
|
type DataTableAlign = 'left' | 'center' | 'right';
|
|
679
1453
|
type DataTableSortState = {
|
|
1454
|
+
/**
|
|
1455
|
+
* `key` của column đang được sort.
|
|
1456
|
+
* `key` of the column currently being sorted.
|
|
1457
|
+
* 当前参与排序的列 `key`。
|
|
1458
|
+
*/
|
|
680
1459
|
key: string;
|
|
1460
|
+
/**
|
|
1461
|
+
* Hướng sắp xếp hiện tại.
|
|
1462
|
+
* Current sort direction.
|
|
1463
|
+
* 当前排序方向。
|
|
1464
|
+
*/
|
|
681
1465
|
direction: DataTableSortDirection;
|
|
682
1466
|
};
|
|
683
1467
|
type DataTableColumn<T> = {
|
|
1468
|
+
/**
|
|
1469
|
+
* Khóa định danh duy nhất của column.
|
|
1470
|
+
* Unique identifier of the column.
|
|
1471
|
+
* 列的唯一标识键。
|
|
1472
|
+
*/
|
|
684
1473
|
key: string;
|
|
1474
|
+
/**
|
|
1475
|
+
* Nội dung header hiển thị của column.
|
|
1476
|
+
* Visible header content of the column.
|
|
1477
|
+
* 列头显示内容。
|
|
1478
|
+
*/
|
|
685
1479
|
title: ReactNode;
|
|
1480
|
+
/**
|
|
1481
|
+
* Tên field trong record dùng để lấy dữ liệu mặc định.
|
|
1482
|
+
* Record field used as the default data source.
|
|
1483
|
+
* 默认取值时对应 record 的字段名。
|
|
1484
|
+
*/
|
|
686
1485
|
dataIndex?: keyof T;
|
|
1486
|
+
/**
|
|
1487
|
+
* Chiều rộng cố định hoặc tương đối của column.
|
|
1488
|
+
* Fixed or relative width of the column.
|
|
1489
|
+
* 列的固定或相对宽度。
|
|
1490
|
+
*/
|
|
687
1491
|
width?: number | string;
|
|
1492
|
+
/**
|
|
1493
|
+
* Hàm custom render cell.
|
|
1494
|
+
* Custom renderer for the cell content.
|
|
1495
|
+
* 单元格内容的自定义渲染函数。
|
|
1496
|
+
*/
|
|
688
1497
|
render?: (value: T[keyof T] | undefined, record: T, index: number) => ReactNode;
|
|
1498
|
+
/**
|
|
1499
|
+
* Bật hoặc tắt khả năng sort cho column.
|
|
1500
|
+
* Enables or disables sorting for the column.
|
|
1501
|
+
* 是否启用该列排序。
|
|
1502
|
+
*/
|
|
689
1503
|
sortable?: boolean;
|
|
1504
|
+
/**
|
|
1505
|
+
* Hàm so sánh custom khi sort client-side.
|
|
1506
|
+
* Custom comparator used for client-side sorting.
|
|
1507
|
+
* 客户端排序时使用的自定义比较函数。
|
|
1508
|
+
*/
|
|
690
1509
|
sorter?: (a: T, b: T) => number;
|
|
1510
|
+
/**
|
|
1511
|
+
* Hàm lấy giá trị dùng riêng cho sort.
|
|
1512
|
+
* Function that returns a dedicated value for sorting.
|
|
1513
|
+
* 专门用于排序的取值函数。
|
|
1514
|
+
*/
|
|
691
1515
|
sortValue?: (record: T) => string | number | Date | null | undefined;
|
|
1516
|
+
/**
|
|
1517
|
+
* Canh lề riêng cho header của column này.
|
|
1518
|
+
* Per-column header alignment override.
|
|
1519
|
+
* 该列表头的单独对齐方式。
|
|
1520
|
+
*/
|
|
692
1521
|
headerAlign?: DataTableAlign;
|
|
1522
|
+
/**
|
|
1523
|
+
* Canh lề riêng cho cell của column này.
|
|
1524
|
+
* Per-column cell alignment override.
|
|
1525
|
+
* 该列单元格的单独对齐方式。
|
|
1526
|
+
*/
|
|
693
1527
|
cellAlign?: DataTableAlign;
|
|
694
1528
|
};
|
|
695
1529
|
type DataTablePagination = {
|
|
1530
|
+
/**
|
|
1531
|
+
* Trang hiện tại.
|
|
1532
|
+
* Current page.
|
|
1533
|
+
* 当前页码。
|
|
1534
|
+
*/
|
|
696
1535
|
page: number;
|
|
1536
|
+
/**
|
|
1537
|
+
* Số dòng trên mỗi trang.
|
|
1538
|
+
* Number of rows per page.
|
|
1539
|
+
* 每页行数。
|
|
1540
|
+
*/
|
|
697
1541
|
pageSize: number;
|
|
1542
|
+
/**
|
|
1543
|
+
* Tổng số bản ghi.
|
|
1544
|
+
* Total number of records.
|
|
1545
|
+
* 总记录数。
|
|
1546
|
+
*/
|
|
698
1547
|
total: number;
|
|
1548
|
+
/**
|
|
1549
|
+
* Callback đổi trang.
|
|
1550
|
+
* Callback fired when the page changes.
|
|
1551
|
+
* 页码变化时触发的回调。
|
|
1552
|
+
*/
|
|
699
1553
|
onChange: (page: number) => void;
|
|
1554
|
+
/**
|
|
1555
|
+
* Danh sách page size cho dropdown.
|
|
1556
|
+
* Page-size options shown in the dropdown.
|
|
1557
|
+
* 下拉中展示的分页大小选项。
|
|
1558
|
+
*/
|
|
700
1559
|
pageSizeOptions?: number[];
|
|
1560
|
+
/**
|
|
1561
|
+
* Callback đổi số dòng trên mỗi trang.
|
|
1562
|
+
* Callback fired when page size changes.
|
|
1563
|
+
* 每页行数变化时触发的回调。
|
|
1564
|
+
*/
|
|
701
1565
|
onPageSizeChange?: (pageSize: number) => void;
|
|
702
1566
|
};
|
|
703
1567
|
type RowKey = string | number;
|
|
704
1568
|
type DataTableRowSelection = {
|
|
1569
|
+
/**
|
|
1570
|
+
* Danh sách row key đang được chọn.
|
|
1571
|
+
* Row keys that are currently selected.
|
|
1572
|
+
* 当前已选中的行 key 列表。
|
|
1573
|
+
*/
|
|
705
1574
|
selectedRowKeys: Array<RowKey>;
|
|
1575
|
+
/**
|
|
1576
|
+
* Callback khi tập row được chọn thay đổi.
|
|
1577
|
+
* Callback fired when the selected rows change.
|
|
1578
|
+
* 已选行集合变化时触发的回调。
|
|
1579
|
+
*/
|
|
706
1580
|
onChange: (selectedRowKeys: Array<RowKey>) => void;
|
|
707
1581
|
};
|
|
708
1582
|
type DataTableProps<T> = {
|
|
1583
|
+
/**
|
|
1584
|
+
* Cấu hình các cột của bảng.
|
|
1585
|
+
* Column configuration of the table.
|
|
1586
|
+
* 表格列配置。
|
|
1587
|
+
*/
|
|
709
1588
|
columns: Array<DataTableColumn<T>>;
|
|
1589
|
+
/**
|
|
1590
|
+
* Dữ liệu nguồn của bảng.
|
|
1591
|
+
* Source data rendered by the table.
|
|
1592
|
+
* 表格渲染的数据源。
|
|
1593
|
+
*/
|
|
710
1594
|
data: T[];
|
|
1595
|
+
/**
|
|
1596
|
+
* Cách lấy khóa duy nhất cho mỗi dòng.
|
|
1597
|
+
* How to resolve a unique key for each row.
|
|
1598
|
+
* 为每一行生成唯一 key 的方式。
|
|
1599
|
+
*/
|
|
711
1600
|
rowKey: keyof T | ((record: T) => RowKey);
|
|
1601
|
+
/**
|
|
1602
|
+
* Trạng thái loading của bảng.
|
|
1603
|
+
* Loading state of the table.
|
|
1604
|
+
* 表格的加载状态。
|
|
1605
|
+
*/
|
|
712
1606
|
loading?: boolean;
|
|
1607
|
+
/**
|
|
1608
|
+
* Nội dung hiển thị khi bảng rỗng.
|
|
1609
|
+
* Content shown when the table has no data.
|
|
1610
|
+
* 表格无数据时显示的内容。
|
|
1611
|
+
*/
|
|
713
1612
|
emptyText?: ReactNode;
|
|
1613
|
+
/**
|
|
1614
|
+
* Cấu hình phân trang.
|
|
1615
|
+
* Pagination configuration.
|
|
1616
|
+
* 分页配置。
|
|
1617
|
+
*/
|
|
714
1618
|
pagination?: DataTablePagination;
|
|
1619
|
+
/**
|
|
1620
|
+
* Trạng thái sort hiện tại nếu muốn control từ ngoài.
|
|
1621
|
+
* Current sort state when controlled from the parent.
|
|
1622
|
+
* 由外部控制时的当前排序状态。
|
|
1623
|
+
*/
|
|
715
1624
|
sort?: DataTableSortState | null;
|
|
1625
|
+
/**
|
|
1626
|
+
* Callback khi trạng thái sort thay đổi.
|
|
1627
|
+
* Callback fired when sort state changes.
|
|
1628
|
+
* 排序状态变化时触发的回调。
|
|
1629
|
+
*/
|
|
716
1630
|
onSortChange?: (sort: DataTableSortState | null) => void;
|
|
1631
|
+
/**
|
|
1632
|
+
* Chế độ sort phía client hoặc server.
|
|
1633
|
+
* Sorting mode handled on the client or server.
|
|
1634
|
+
* 排序在客户端还是服务端处理。
|
|
1635
|
+
*/
|
|
717
1636
|
sortMode?: 'client' | 'server';
|
|
1637
|
+
/**
|
|
1638
|
+
* Callback khi người dùng click vào một dòng.
|
|
1639
|
+
* Callback fired when a row is clicked.
|
|
1640
|
+
* 用户点击某一行时触发的回调。
|
|
1641
|
+
*/
|
|
718
1642
|
onRowClick?: (record: T) => void;
|
|
1643
|
+
/**
|
|
1644
|
+
* Cấu hình chọn nhiều dòng.
|
|
1645
|
+
* Row-selection configuration.
|
|
1646
|
+
* 行选择配置。
|
|
1647
|
+
*/
|
|
719
1648
|
rowSelection?: DataTableRowSelection;
|
|
1649
|
+
/**
|
|
1650
|
+
* Hàm render cột action cho từng dòng.
|
|
1651
|
+
* Renderer for the per-row action column.
|
|
1652
|
+
* 每一行操作列的渲染函数。
|
|
1653
|
+
*/
|
|
720
1654
|
renderActions?: (record: T) => ReactNode;
|
|
1655
|
+
/**
|
|
1656
|
+
* Chiều rộng của cột action.
|
|
1657
|
+
* Width of the action column.
|
|
1658
|
+
* 操作列宽度。
|
|
1659
|
+
*/
|
|
721
1660
|
actionColumnWidth?: number | string;
|
|
1661
|
+
/**
|
|
1662
|
+
* Class bổ sung cho wrapper của bảng.
|
|
1663
|
+
* Extra class names for the table wrapper.
|
|
1664
|
+
* 表格容器的额外 class。
|
|
1665
|
+
*/
|
|
722
1666
|
className?: string;
|
|
1667
|
+
/**
|
|
1668
|
+
* Canh lề mặc định cho toàn bộ header.
|
|
1669
|
+
* Default alignment for all headers.
|
|
1670
|
+
* 全部表头的默认对齐方式。
|
|
1671
|
+
*/
|
|
723
1672
|
headerAlign?: DataTableAlign;
|
|
1673
|
+
/**
|
|
1674
|
+
* Canh lề mặc định cho toàn bộ cell.
|
|
1675
|
+
* Default alignment for all cells.
|
|
1676
|
+
* 全部单元格的默认对齐方式。
|
|
1677
|
+
*/
|
|
724
1678
|
cellAlign?: DataTableAlign;
|
|
1679
|
+
/**
|
|
1680
|
+
* Offset sticky cho header/cột cố định nếu layout có top bar.
|
|
1681
|
+
* Sticky offset for header or fixed columns when the layout has a top bar.
|
|
1682
|
+
* 当布局存在顶部栏时,表头/固定列的 sticky 偏移。
|
|
1683
|
+
*/
|
|
725
1684
|
stickyOffset?: number;
|
|
726
1685
|
};
|
|
727
1686
|
declare function DataTable<T>({ columns, data, rowKey, loading, emptyText, pagination, sort, onSortChange, sortMode, onRowClick, rowSelection, renderActions, actionColumnWidth, className, headerAlign, stickyOffset, }: DataTableProps<T>): react_jsx_runtime.JSX.Element;
|
|
@@ -733,6 +1692,42 @@ declare const TableCell: react.ForwardRefExoticComponent<TdHTMLAttributes<HTMLTa
|
|
|
733
1692
|
as?: "td" | "th";
|
|
734
1693
|
} & react.RefAttributes<HTMLTableCellElement>>;
|
|
735
1694
|
|
|
1695
|
+
interface SwitchProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'type' | 'size' | 'className' | 'onChange'> {
|
|
1696
|
+
/**
|
|
1697
|
+
* Class bổ sung cho wrapper ngoài cùng của switch.
|
|
1698
|
+
* Extra class names for the outer switch wrapper.
|
|
1699
|
+
* 开关最外层容器的额外 class。
|
|
1700
|
+
*/
|
|
1701
|
+
className?: string;
|
|
1702
|
+
/**
|
|
1703
|
+
* Class tùy chỉnh cho phần track.
|
|
1704
|
+
* Custom class for the switch track.
|
|
1705
|
+
* 开关轨道的自定义 class。
|
|
1706
|
+
*/
|
|
1707
|
+
trackClassName?: string;
|
|
1708
|
+
/**
|
|
1709
|
+
* Class tùy chỉnh cho phần thumb.
|
|
1710
|
+
* Custom class for the switch thumb.
|
|
1711
|
+
* 开关圆点的自定义 class。
|
|
1712
|
+
*/
|
|
1713
|
+
thumbClassName?: string;
|
|
1714
|
+
/**
|
|
1715
|
+
* Callback trả về trạng thái checked mới.
|
|
1716
|
+
* Callback that returns the next checked state.
|
|
1717
|
+
* 返回最新选中状态的回调。
|
|
1718
|
+
*/
|
|
1719
|
+
onCheckedChange?: (checked: boolean) => void;
|
|
1720
|
+
}
|
|
1721
|
+
declare const Switch: react.ForwardRefExoticComponent<SwitchProps & react.RefAttributes<HTMLInputElement>>;
|
|
1722
|
+
|
|
1723
|
+
declare function Card({ className, ...props }: react.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
1724
|
+
declare function CardHeader({ className, ...props }: react.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
1725
|
+
declare function CardTitle({ className, ...props }: react.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
1726
|
+
declare function CardDescription({ className, ...props }: react.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
1727
|
+
declare function CardAction({ className, ...props }: react.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
1728
|
+
declare function CardContent({ className, ...props }: react.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
1729
|
+
declare function CardFooter({ className, ...props }: react.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
1730
|
+
|
|
736
1731
|
type StatusAction = {
|
|
737
1732
|
label: ReactNode;
|
|
738
1733
|
color?: string;
|
|
@@ -752,59 +1747,9 @@ type StatusPresentation = {
|
|
|
752
1747
|
};
|
|
753
1748
|
declare function getStatusPresentation(status: string | number | null | undefined, options: StatusOption[]): StatusPresentation | null;
|
|
754
1749
|
|
|
755
|
-
type RemoteLoadingProps = {
|
|
756
|
-
className?: string;
|
|
757
|
-
};
|
|
758
|
-
declare function RemoteLoading({ className }: RemoteLoadingProps): react_jsx_runtime.JSX.Element;
|
|
759
|
-
|
|
760
|
-
type DateRangePickerValue = {
|
|
761
|
-
startDate?: string | null;
|
|
762
|
-
endDate?: string | null;
|
|
763
|
-
};
|
|
764
|
-
interface DateRangePickerProps {
|
|
765
|
-
value?: DateRangePickerValue;
|
|
766
|
-
onChange: (next: Required<DateRangePickerValue>) => void;
|
|
767
|
-
label?: string;
|
|
768
|
-
placeholder?: string;
|
|
769
|
-
className?: string;
|
|
770
|
-
}
|
|
771
|
-
declare function DateRangePicker({ value, onChange, label, placeholder, className, }: DateRangePickerProps): react_jsx_runtime.JSX.Element;
|
|
772
|
-
|
|
773
|
-
type QuickOption = {
|
|
774
|
-
label: string;
|
|
775
|
-
value: string;
|
|
776
|
-
};
|
|
777
|
-
interface DateTimePickerProps {
|
|
778
|
-
label?: ReactNode;
|
|
779
|
-
placeholder?: string;
|
|
780
|
-
value?: string;
|
|
781
|
-
onChange: (value: string) => void;
|
|
782
|
-
disabled?: boolean;
|
|
783
|
-
errorMessage?: string;
|
|
784
|
-
className?: string;
|
|
785
|
-
parseFormat?: string;
|
|
786
|
-
outputFormat?: string;
|
|
787
|
-
displayFormat?: string;
|
|
788
|
-
minDateTime?: Date;
|
|
789
|
-
quickOptions?: QuickOption[];
|
|
790
|
-
onQuickSelect?: (value: string) => void;
|
|
791
|
-
onClear?: () => void;
|
|
792
|
-
quickRangesLabel?: string;
|
|
793
|
-
clearLabel?: string;
|
|
794
|
-
portal?: boolean;
|
|
795
|
-
}
|
|
796
|
-
declare function DateTimePicker({ label, placeholder, value, onChange, disabled, errorMessage, className, parseFormat, outputFormat, displayFormat, minDateTime, quickOptions, onQuickSelect, onClear, quickRangesLabel, clearLabel, portal, }: DateTimePickerProps): react_jsx_runtime.JSX.Element;
|
|
797
|
-
|
|
798
|
-
type MainFePageTitleProps = {
|
|
799
|
-
title: string;
|
|
800
|
-
subtitle?: string;
|
|
801
|
-
size?: 'default' | 'compact';
|
|
802
|
-
topSlot?: React.ReactNode;
|
|
803
|
-
rightSlot?: React.ReactNode;
|
|
804
|
-
};
|
|
805
|
-
declare function PageTitle({ title, subtitle, size, topSlot, rightSlot, }: MainFePageTitleProps): react_jsx_runtime.JSX.Element;
|
|
806
|
-
|
|
807
1750
|
declare const index_ArgonSidebar: typeof ArgonSidebar;
|
|
1751
|
+
type index_ArgonSidebarHeaderRender = ArgonSidebarHeaderRender;
|
|
1752
|
+
type index_ArgonSidebarProps = ArgonSidebarProps;
|
|
808
1753
|
declare const index_Badge: typeof Badge;
|
|
809
1754
|
type index_BadgeProps = BadgeProps;
|
|
810
1755
|
declare const index_Button: typeof Button;
|
|
@@ -830,18 +1775,24 @@ type index_DataTableSortDirection = DataTableSortDirection;
|
|
|
830
1775
|
type index_DataTableSortState = DataTableSortState;
|
|
831
1776
|
declare const index_DateRangePicker: typeof DateRangePicker;
|
|
832
1777
|
type index_DateRangePickerProps = DateRangePickerProps;
|
|
1778
|
+
type index_DateRangePickerValue = DateRangePickerValue;
|
|
833
1779
|
declare const index_DateTimePicker: typeof DateTimePicker;
|
|
834
1780
|
type index_DateTimePickerProps = DateTimePickerProps;
|
|
835
1781
|
declare const index_Input: typeof Input;
|
|
836
1782
|
type index_InputProps = InputProps;
|
|
1783
|
+
type index_MainFePageTitleProps = MainFePageTitleProps;
|
|
1784
|
+
type index_MainFeSectionTitleProps = MainFeSectionTitleProps;
|
|
837
1785
|
type index_MultiTabItem = MultiTabItem;
|
|
838
1786
|
declare const index_MultiTabs: typeof MultiTabs;
|
|
839
1787
|
type index_MultiTabsProps = MultiTabsProps;
|
|
840
1788
|
declare const index_PageTitle: typeof PageTitle;
|
|
1789
|
+
type index_QuickOption = QuickOption;
|
|
841
1790
|
declare const index_RemoteLoading: typeof RemoteLoading;
|
|
842
1791
|
type index_RemoteLoadingProps = RemoteLoadingProps;
|
|
843
1792
|
declare const index_SectionTitle: typeof SectionTitle;
|
|
844
1793
|
declare const index_StatCard: typeof StatCard;
|
|
1794
|
+
type index_StatCardProps = StatCardProps;
|
|
1795
|
+
type index_StatTone = StatTone;
|
|
845
1796
|
type index_StatusAction = StatusAction;
|
|
846
1797
|
type index_StatusOption = StatusOption;
|
|
847
1798
|
type index_StatusPresentation = StatusPresentation;
|
|
@@ -854,7 +1805,7 @@ declare const index_TableHeader: typeof TableHeader;
|
|
|
854
1805
|
declare const index_TableRow: typeof TableRow;
|
|
855
1806
|
declare const index_getStatusPresentation: typeof getStatusPresentation;
|
|
856
1807
|
declare namespace index {
|
|
857
|
-
export { index_ArgonSidebar as ArgonSidebar, index_Badge as Badge, type index_BadgeProps as BadgeProps, index_Button as Button, type index_ButtonProps as ButtonProps, index_Card as Card, index_CardAction as CardAction, index_CardContent as CardContent, index_CardDescription as CardDescription, index_CardFooter as CardFooter, index_CardHeader as CardHeader, index_CardTitle as CardTitle, index_Combobox as Combobox, type index_ComboboxAsyncConfig as ComboboxAsyncConfig, type index_ComboboxOption as ComboboxOption, type index_ComboboxProps as ComboboxProps, index_DataTable as DataTable, type index_DataTableAlign as DataTableAlign, type index_DataTableColumn as DataTableColumn, type index_DataTablePagination as DataTablePagination, type index_DataTableProps as DataTableProps, type index_DataTableRowSelection as DataTableRowSelection, type index_DataTableSortDirection as DataTableSortDirection, type index_DataTableSortState as DataTableSortState, index_DateRangePicker as DateRangePicker, type index_DateRangePickerProps as DateRangePickerProps, index_DateTimePicker as DateTimePicker, type index_DateTimePickerProps as DateTimePickerProps, index_Input as Input, type index_InputProps as InputProps, type index_MultiTabItem as MultiTabItem, index_MultiTabs as MultiTabs, type index_MultiTabsProps as MultiTabsProps, index_PageTitle as PageTitle, index_RemoteLoading as RemoteLoading, type index_RemoteLoadingProps as RemoteLoadingProps, index_SectionTitle as SectionTitle, index_StatCard as StatCard, type index_StatusAction as StatusAction, type index_StatusOption as StatusOption, type index_StatusPresentation as StatusPresentation, index_Switch as Switch, type index_SwitchProps as SwitchProps, index_Table as Table, index_TableBody as TableBody, index_TableCell as TableCell, index_TableHeader as TableHeader, index_TableRow as TableRow, index_getStatusPresentation as getStatusPresentation };
|
|
1808
|
+
export { index_ArgonSidebar as ArgonSidebar, type index_ArgonSidebarHeaderRender as ArgonSidebarHeaderRender, type index_ArgonSidebarProps as ArgonSidebarProps, index_Badge as Badge, type index_BadgeProps as BadgeProps, index_Button as Button, type index_ButtonProps as ButtonProps, index_Card as Card, index_CardAction as CardAction, index_CardContent as CardContent, index_CardDescription as CardDescription, index_CardFooter as CardFooter, index_CardHeader as CardHeader, index_CardTitle as CardTitle, index_Combobox as Combobox, type index_ComboboxAsyncConfig as ComboboxAsyncConfig, type index_ComboboxOption as ComboboxOption, type index_ComboboxProps as ComboboxProps, index_DataTable as DataTable, type index_DataTableAlign as DataTableAlign, type index_DataTableColumn as DataTableColumn, type index_DataTablePagination as DataTablePagination, type index_DataTableProps as DataTableProps, type index_DataTableRowSelection as DataTableRowSelection, type index_DataTableSortDirection as DataTableSortDirection, type index_DataTableSortState as DataTableSortState, index_DateRangePicker as DateRangePicker, type index_DateRangePickerProps as DateRangePickerProps, type index_DateRangePickerValue as DateRangePickerValue, index_DateTimePicker as DateTimePicker, type index_DateTimePickerProps as DateTimePickerProps, index_Input as Input, type index_InputProps as InputProps, type index_MainFePageTitleProps as MainFePageTitleProps, type index_MainFeSectionTitleProps as MainFeSectionTitleProps, type index_MultiTabItem as MultiTabItem, index_MultiTabs as MultiTabs, type index_MultiTabsProps as MultiTabsProps, index_PageTitle as PageTitle, type index_QuickOption as QuickOption, index_RemoteLoading as RemoteLoading, type index_RemoteLoadingProps as RemoteLoadingProps, index_SectionTitle as SectionTitle, index_StatCard as StatCard, type index_StatCardProps as StatCardProps, type index_StatTone as StatTone, type index_StatusAction as StatusAction, type index_StatusOption as StatusOption, type index_StatusPresentation as StatusPresentation, index_Switch as Switch, type index_SwitchProps as SwitchProps, index_Table as Table, index_TableBody as TableBody, index_TableCell as TableCell, index_TableHeader as TableHeader, index_TableRow as TableRow, index_getStatusPresentation as getStatusPresentation };
|
|
858
1809
|
}
|
|
859
1810
|
|
|
860
|
-
export { Alert, type AlertProps, ArgonSidebar, AsyncCombobox, type AsyncComboboxProps, Badge, type BadgeProps, Breadcrumb, type BreadcrumbItem, Button$1 as Button, type ButtonProps$1 as ButtonProps, Card$1 as Card, CardAction$1 as CardAction, CardContent$1 as CardContent, CardDescription$1 as CardDescription, CardFooter$1 as CardFooter, CardHeader$1 as CardHeader, CardTitle$1 as CardTitle, Combobox$1 as Combobox, type ComboboxOption$2 as ComboboxOption, FormControl as Control, DataTable$1 as DataTable, type DataTableAlign$1 as DataTableAlign, type DataTableColumn$1 as DataTableColumn, type DataTablePagination$1 as DataTablePagination, type DataTableProps$1 as DataTableProps, type DataTableRowSelection$1 as DataTableRowSelection, type DataTableSortDirection$1 as DataTableSortDirection, type DataTableSortState$1 as DataTableSortState, FormDescription as Description, FormField as Field, Form, FormControl, FormDescription, FormField, type FormFieldProps, FormItem, FormLabel, FormMessage, Input$1 as Input, type InputProps$1 as InputProps, FormItem as Item, FormLabel as Label, LineClampTooltip, type LineClampTooltipProps, Loading, type LoadingProps, index as MainFe, FormMessage as Message, MultiSelect, type MultiSelectOption, NumericInput, type NumericInputProps, type Option, OverflowTooltip, type OverflowTooltipProps, PageTitle$1 as PageTitle, Pagination, type PaginationInfo, type PaginationProps, type PermissionChecker, SearchableSelect, type SearchableSelectOption, type SearchableSelectProps, SectionTitle$1 as SectionTitle, Select, type SelectOption, type SelectProps, Sidebar, SidebarItem, type SidebarProps, Stat, type StatProps, type TabItem, Table$1 as Table, TableBody$1 as TableBody, TableCell$1 as TableCell, TableHeader$1 as TableHeader, TableRow$1 as TableRow, Tabs, type TabsProps, Textarea, type TextareaProps, Tooltip, type Trend, TruncatedText, type TruncatedTextProps, defaultPermissionChecker, filterSidebarItems, hasActiveDescendant };
|
|
1811
|
+
export { Alert, type AlertProps, ArgonSidebar, type ArgonSidebarHeaderRender, type ArgonSidebarProps, AsyncCombobox, type AsyncComboboxProps, Badge, type BadgeProps, Breadcrumb, type BreadcrumbItem, type BreadcrumbProps, Button$1 as Button, type ButtonProps$1 as ButtonProps, Card$1 as Card, CardAction$1 as CardAction, CardContent$1 as CardContent, CardDescription$1 as CardDescription, CardFooter$1 as CardFooter, CardHeader$1 as CardHeader, CardTitle$1 as CardTitle, Combobox$1 as Combobox, type ComboboxOption$2 as ComboboxOption, type ComboboxProps$1 as ComboboxProps, FormControl as Control, DataTable$1 as DataTable, type DataTableAlign$1 as DataTableAlign, type DataTableColumn$1 as DataTableColumn, type DataTablePagination$1 as DataTablePagination, type DataTableProps$1 as DataTableProps, type DataTableRowSelection$1 as DataTableRowSelection, type DataTableSortDirection$1 as DataTableSortDirection, type DataTableSortState$1 as DataTableSortState, type DateRangePickerProps, type DateRangePickerValue, type DateTimePickerProps, FormDescription as Description, FormField as Field, Form, FormControl, FormDescription, FormField, type FormFieldProps, FormItem, FormLabel, FormMessage, Input$1 as Input, type InputProps$1 as InputProps, FormItem as Item, FormLabel as Label, LineClampTooltip, type LineClampTooltipProps, Loading, type LoadingProps, index as MainFe, type ButtonProps as MainFeButtonProps, type ComboboxAsyncConfig as MainFeComboboxAsyncConfig, type ComboboxOption as MainFeComboboxOption, type ComboboxProps as MainFeComboboxProps, type DataTableAlign as MainFeDataTableAlign, type DataTableColumn as MainFeDataTableColumn, type DataTablePagination as MainFeDataTablePagination, type DataTableProps as MainFeDataTableProps, type DataTableRowSelection as MainFeDataTableRowSelection, type DataTableSortDirection as MainFeDataTableSortDirection, type DataTableSortState as MainFeDataTableSortState, type InputProps as MainFeInputProps, type MainFePageTitleProps, type QuickOption as MainFeQuickOption, type MainFeSectionTitleProps, type SwitchProps as MainFeSwitchProps, FormMessage as Message, MultiSelect, type MultiSelectOption, type MultiSelectProps, type MultiTabItem, type MultiTabsProps, NumericInput, type NumericInputProps, type Option, OverflowTooltip, type OverflowTooltipProps, PageTitle$1 as PageTitle, type PageTitleProps, Pagination, type PaginationInfo, type PaginationProps, type PermissionChecker, type RemoteLoadingProps, SearchableSelect, type SearchableSelectOption, type SearchableSelectProps, SectionTitle$1 as SectionTitle, type SectionTitleProps, Select, type SelectOption, type SelectProps, Sidebar, SidebarItem, type SidebarProps, Stat, type StatCardProps, type StatProps, type StatTone, type TabItem, Table$1 as Table, TableBody$1 as TableBody, TableCell$1 as TableCell, TableHeader$1 as TableHeader, TableRow$1 as TableRow, Tabs, type TabsProps, Textarea, type TextareaProps, Tooltip, type TooltipProps, type Trend, TruncatedText, type TruncatedTextProps, defaultPermissionChecker, filterSidebarItems, hasActiveDescendant };
|