@robot-admin/naive-ui-components 0.17.6 → 0.19.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +18 -0
- package/dist/C_AntV.css +10 -10
- package/dist/C_AntV.d.cts +2 -2
- package/dist/C_AntV.d.ts +2 -2
- package/dist/C_AntV2.cjs +1 -1
- package/dist/C_AntV2.js +1 -1
- package/dist/C_Date.cjs +1 -1
- package/dist/C_Date.css +5 -5
- package/dist/C_Date.d.cts +18 -2
- package/dist/C_Date.d.ts +18 -2
- package/dist/C_Date.js +1 -1
- package/dist/C_Date2.cjs +1 -1
- package/dist/C_Date2.js +1 -1
- package/dist/C_Draggable.css +53 -53
- package/dist/C_Draggable.d.cts +2 -2
- package/dist/C_Draggable.d.ts +2 -2
- package/dist/C_Draggable2.cjs +1 -1
- package/dist/C_Draggable2.js +1 -1
- package/dist/C_Editor.d.cts +1 -1
- package/dist/C_Editor.d.ts +1 -1
- package/dist/C_Form.cjs +1 -1
- package/dist/C_FormModal.d.cts +1 -1
- package/dist/C_FormModal.d.ts +1 -1
- package/dist/C_FormSearch.cjs +1 -1
- package/dist/C_FormSearch.css +52 -52
- package/dist/C_FormSearch.d.cts +18 -2
- package/dist/C_FormSearch.d.ts +18 -2
- package/dist/C_FormSearch.js +1 -1
- package/dist/C_FormSearch2.cjs +1 -1
- package/dist/C_FormSearch2.js +1 -1
- package/dist/C_Guide.d.cts +1 -1
- package/dist/C_Guide.d.ts +1 -1
- package/dist/C_Icon.d.cts +1 -1
- package/dist/C_Icon.d.ts +1 -1
- package/dist/C_Language.d.cts +1 -1
- package/dist/C_Language.d.ts +1 -1
- package/dist/C_Loading.d.cts +1 -1
- package/dist/C_Loading.d.ts +1 -1
- package/dist/C_Login.d.cts +1 -1
- package/dist/C_Login.d.ts +1 -1
- package/dist/C_Markdown.d.cts +1 -1
- package/dist/C_Markdown.d.ts +1 -1
- package/dist/C_Menu.d.ts +1 -1
- package/dist/C_OrgChart.d.cts +1 -1
- package/dist/C_OrgChart.d.ts +1 -1
- package/dist/C_Progress.d.cts +1 -1
- package/dist/C_Progress.d.ts +1 -1
- package/dist/C_Skeleton.d.cts +1 -1
- package/dist/C_Skeleton.d.ts +1 -1
- package/dist/C_Steps.d.cts +1 -1
- package/dist/C_Steps.d.ts +1 -1
- package/dist/C_Table.base.css +144 -155
- package/dist/C_Table.css +144 -155
- package/dist/C_Table.d.cts +2 -2
- package/dist/C_Table.d.ts +6 -6
- package/dist/C_TagsView.d.cts +1 -1
- package/dist/C_TagsView.d.ts +1 -1
- package/dist/C_Theme.d.cts +1 -1
- package/dist/C_Theme.d.ts +1 -1
- package/dist/C_Time.cjs +1 -1
- package/dist/C_Time.css +4 -4
- package/dist/C_Time.d.cts +18 -2
- package/dist/C_Time.d.ts +18 -2
- package/dist/C_Time.js +1 -1
- package/dist/C_Time2.cjs +1 -1
- package/dist/C_Time2.js +1 -1
- package/dist/C_Timeline.d.cts +1 -1
- package/dist/C_Timeline.d.ts +1 -1
- package/dist/C_Transfer.css +26 -26
- package/dist/C_Transfer.d.cts +2 -2
- package/dist/C_Transfer.d.ts +2 -2
- package/dist/C_Transfer2.cjs +1 -1
- package/dist/C_Transfer2.js +1 -1
- package/dist/C_Tree.css +23 -23
- package/dist/C_Tree.d.ts +4 -4
- package/dist/C_Tree2.cjs +1 -1
- package/dist/C_Tree2.js +1 -1
- package/dist/C_VtableGantt.cjs +1 -1
- package/dist/C_VtableGantt.css +31 -31
- package/dist/C_VtableGantt.d.cts +18 -2
- package/dist/C_VtableGantt.d.ts +18 -2
- package/dist/C_VtableGantt.js +1 -1
- package/dist/C_WorkFlow.css +150 -150
- package/dist/C_WorkFlow.d.cts +2 -2
- package/dist/C_WorkFlow.d.ts +2 -2
- package/dist/C_WorkFlow2.cjs +1 -1
- package/dist/C_WorkFlow2.js +1 -1
- package/dist/constants3.d.cts +6 -6
- package/dist/constants3.d.ts +6 -6
- package/dist/constants4.d.cts +7 -7
- package/dist/constants4.d.ts +7 -7
- package/dist/constants5.d.cts +2 -2
- package/dist/constants5.d.ts +2 -2
- package/dist/data.d.cts +7 -7
- package/dist/data.d.ts +7 -7
- package/dist/dateRange.d.cts +197 -0
- package/dist/dateRange.d.ts +197 -0
- package/dist/formValidation.cjs +1 -1
- package/dist/formValidation.js +1 -1
- package/dist/graphics.cjs +1 -0
- package/dist/graphics.d.cts +837 -0
- package/dist/graphics.d.ts +837 -0
- package/dist/graphics.js +1 -0
- package/dist/helpers.cjs +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +47 -43
- package/dist/index.d.ts +47 -44
- package/dist/index.js +1 -1
- package/dist/index.vue.d.cts +4 -4
- package/dist/index.vue.d.ts +4 -4
- package/dist/index10.vue.d.cts +3 -3
- package/dist/index10.vue.d.ts +53 -68
- package/dist/index11.vue.d.cts +53 -68
- package/dist/index11.vue.d.ts +52 -58
- package/dist/index12.vue.d.cts +52 -58
- package/dist/index12.vue.d.ts +124 -50
- package/dist/index13.vue.d.cts +124 -50
- package/dist/index13.vue.d.ts +51 -123
- package/dist/index14.vue.d.cts +51 -123
- package/dist/index14.vue.d.ts +26 -52
- package/dist/index15.vue.d.cts +26 -52
- package/dist/index15.vue.d.ts +12 -26
- package/dist/index16.vue.d.cts +12 -26
- package/dist/index16.vue.d.ts +129 -13
- package/dist/index17.vue.d.cts +129 -13
- package/dist/index17.vue.d.ts +76 -129
- package/dist/index18.vue.d.cts +76 -129
- package/dist/index18.vue.d.ts +65 -75
- package/dist/index19.vue.d.cts +97 -75
- package/dist/index19.vue.d.ts +94 -62
- package/dist/index2.vue.d.cts +2 -2
- package/dist/index2.vue.d.ts +2 -2
- package/dist/index20.vue.d.cts +40 -91
- package/dist/index20.vue.d.ts +40 -91
- package/dist/index21.vue.d.cts +89 -40
- package/dist/index21.vue.d.ts +89 -40
- package/dist/index22.vue.d.cts +37 -95
- package/dist/index22.vue.d.ts +37 -95
- package/dist/index23.vue.d.cts +8 -34
- package/dist/index23.vue.d.ts +8 -34
- package/dist/index24.vue.d.cts +86 -9
- package/dist/index24.vue.d.ts +86 -9
- package/dist/index25.vue.d.cts +99 -654
- package/dist/index25.vue.d.ts +99 -654
- package/dist/index26.vue.d.cts +66 -87
- package/dist/index26.vue.d.ts +66 -87
- package/dist/index3.vue.d.cts +2 -2
- package/dist/index3.vue.d.ts +2 -2
- package/dist/index4.vue.d.cts +3 -3
- package/dist/index6.vue.d.ts +3 -3
- package/dist/index7.vue.d.cts +3 -3
- package/dist/index8.vue.d.ts +4 -4
- package/dist/index9.vue.d.cts +4 -4
- package/dist/index9.vue.d.ts +3 -3
- package/dist/mapUtils.d.cts +3 -3
- package/dist/mapUtils.d.ts +3 -3
- package/dist/presets.d.cts +5 -3
- package/dist/presets.d.ts +5 -3
- package/dist/style.css +499 -510
- package/dist/types.d.ts +51 -0
- package/dist/types2.d.cts +51 -0
- package/dist/useCalendarEvents.d.cts +2 -2
- package/dist/useCalendarEvents.d.ts +2 -2
- package/dist/useCollapsePanel.d.cts +4 -4
- package/dist/useCollapsePanel.d.ts +4 -4
- package/dist/useCropperCore.d.cts +9 -9
- package/dist/useCropperCore.d.ts +9 -9
- package/dist/useDraggableLayout.d.cts +94 -125
- package/dist/useDraggableLayout.d.ts +94 -125
- package/dist/useDynamicFormState.d.cts +23 -15
- package/dist/useDynamicFormState.d.ts +23 -15
- package/dist/useEdgeInteraction.d.cts +10 -5
- package/dist/useEdgeInteraction.d.ts +10 -5
- package/dist/useFullscreen.d.cts +3 -3
- package/dist/useFullscreen.d.ts +3 -3
- package/dist/useInfiniteScroll.d.cts +2 -2
- package/dist/useInfiniteScroll.d.ts +2 -2
- package/dist/useQRCode.d.cts +4 -4
- package/dist/useQRCode.d.ts +4 -4
- package/dist/useSignatureHistory.d.cts +3 -3
- package/dist/useSignatureHistory.d.ts +3 -3
- package/dist/useSplitResize.d.cts +6 -6
- package/dist/useSplitResize.d.ts +6 -6
- package/dist/useTableQuery.cjs +2 -2
- package/dist/useTableQuery.d.cts +490 -519
- package/dist/useTableQuery.d.ts +490 -519
- package/dist/useTableQuery.js +2 -2
- package/dist/useTimeSelection.d.cts +19 -52
- package/dist/useTimeSelection.d.ts +19 -52
- package/dist/useWorkflowValidation.d.cts +495 -116
- package/dist/useWorkflowValidation.d.ts +495 -116
- package/dist/verification.d.cts +4 -4
- package/dist/verification.d.ts +4 -4
- package/docs/guides/usage.en.md +18 -1
- package/docs/guides/usage.md +18 -1
- package/package.json +2 -2
- package/dist/C_VtableGantt2.cjs +0 -1
- package/dist/C_VtableGantt2.js +0 -1
- package/dist/index27.vue.d.cts +0 -111
- package/dist/index27.vue.d.ts +0 -111
- package/dist/index28.vue.d.cts +0 -84
- package/dist/index28.vue.d.ts +0 -84
- package/dist/useSearchState.d.cts +0 -163
- package/dist/useSearchState.d.ts +0 -163
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import * as vue from "vue";
|
|
2
|
+
import { DeepReadonly, VNodeChild } from "vue";
|
|
2
3
|
import { DraggableEvent } from "vue-draggable-plus";
|
|
3
4
|
|
|
4
5
|
//#region src/components/C_Draggable/types.d.ts
|
|
@@ -8,12 +9,12 @@ interface DraggableItem {
|
|
|
8
9
|
name?: string;
|
|
9
10
|
label?: string;
|
|
10
11
|
description?: string;
|
|
11
|
-
[key: string]:
|
|
12
|
+
[key: string]: unknown;
|
|
12
13
|
}
|
|
13
|
-
interface DragEvent {
|
|
14
|
+
interface DragEvent<T extends object = DraggableItem> {
|
|
14
15
|
oldIndex: number;
|
|
15
16
|
newIndex: number;
|
|
16
|
-
item:
|
|
17
|
+
item: T;
|
|
17
18
|
}
|
|
18
19
|
interface GroupOptions {
|
|
19
20
|
name: string;
|
|
@@ -21,11 +22,11 @@ interface GroupOptions {
|
|
|
21
22
|
put?: boolean | string | string[];
|
|
22
23
|
revertClone?: boolean;
|
|
23
24
|
}
|
|
24
|
-
type LayoutMode =
|
|
25
|
-
type JustifyContent =
|
|
26
|
-
type AlignItems =
|
|
27
|
-
interface DraggableProps {
|
|
28
|
-
modelValue?:
|
|
25
|
+
type LayoutMode = 'vertical' | 'horizontal' | 'grid' | 'flex-wrap';
|
|
26
|
+
type JustifyContent = 'flex-start' | 'flex-end' | 'center' | 'space-between' | 'space-around' | 'space-evenly';
|
|
27
|
+
type AlignItems = 'flex-start' | 'flex-end' | 'center' | 'stretch' | 'baseline';
|
|
28
|
+
interface DraggableProps<T extends object = DraggableItem> {
|
|
29
|
+
modelValue?: T[];
|
|
29
30
|
disabled?: boolean;
|
|
30
31
|
group?: string | GroupOptions;
|
|
31
32
|
sort?: boolean;
|
|
@@ -41,12 +42,12 @@ interface DraggableProps {
|
|
|
41
42
|
itemClass?: string;
|
|
42
43
|
showEmptyState?: boolean;
|
|
43
44
|
emptyText?: string;
|
|
44
|
-
itemKey?: (item:
|
|
45
|
-
itemTitle?: (item:
|
|
46
|
-
itemDescription?: (item:
|
|
45
|
+
itemKey?: (item: T, index: number) => string | number;
|
|
46
|
+
itemTitle?: (item: T) => string;
|
|
47
|
+
itemDescription?: (item: T) => string;
|
|
47
48
|
swapThreshold?: number;
|
|
48
49
|
invertSwap?: boolean;
|
|
49
|
-
direction?:
|
|
50
|
+
direction?: 'vertical' | 'horizontal';
|
|
50
51
|
layout?: LayoutMode;
|
|
51
52
|
gridColumns?: number;
|
|
52
53
|
gridRows?: number;
|
|
@@ -56,143 +57,111 @@ interface DraggableProps {
|
|
|
56
57
|
alignItems?: AlignItems;
|
|
57
58
|
customStyles?: Record<string, string | number>;
|
|
58
59
|
}
|
|
59
|
-
interface DraggableEmits {
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
60
|
+
interface DraggableEmits<T extends object = DraggableItem> {
|
|
61
|
+
'update:modelValue': [value: T[]];
|
|
62
|
+
'drag-start': [event: DragEvent<T>];
|
|
63
|
+
'drag-end': [event: DragEvent<T>];
|
|
64
|
+
'item-add': [item: T, index: number];
|
|
65
|
+
'item-remove': [item: T, index: number];
|
|
66
|
+
'list-change': [list: T[]];
|
|
66
67
|
}
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
item:
|
|
68
|
+
/** 插槽直接保留 v-model 的业务项类型。 */
|
|
69
|
+
interface DraggableSlots<T extends object = DraggableItem> {
|
|
70
|
+
default?: (context: {
|
|
71
|
+
item: T;
|
|
71
72
|
index: number;
|
|
72
73
|
isDragging: boolean;
|
|
73
74
|
isDisabled: boolean;
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
readonly id: string | number;
|
|
85
|
-
readonly title?: string | undefined;
|
|
86
|
-
readonly name?: string | undefined;
|
|
87
|
-
readonly label?: string | undefined;
|
|
88
|
-
readonly description?: string | undefined;
|
|
89
|
-
}[], readonly {
|
|
90
|
-
readonly [x: string]: any;
|
|
91
|
-
readonly id: string | number;
|
|
92
|
-
readonly title?: string | undefined;
|
|
93
|
-
readonly name?: string | undefined;
|
|
94
|
-
readonly label?: string | undefined;
|
|
95
|
-
readonly description?: string | undefined;
|
|
96
|
-
}[]>>;
|
|
97
|
-
isEmpty: Readonly<vue.Ref<boolean, boolean>>;
|
|
98
|
-
addItem: (item: DraggableItem, index?: number) => void;
|
|
99
|
-
removeItem: (index: number) => DraggableItem | null;
|
|
75
|
+
}) => VNodeChild;
|
|
76
|
+
empty?: () => VNodeChild;
|
|
77
|
+
}
|
|
78
|
+
/** Vue 公开实例中的状态已经解包;列表只读,修改统一通过方法。 */
|
|
79
|
+
interface DraggableExpose<T extends object = DraggableItem> {
|
|
80
|
+
isDragging: boolean;
|
|
81
|
+
list: readonly DeepReadonly<T>[];
|
|
82
|
+
isEmpty: boolean;
|
|
83
|
+
addItem: (item: T, index?: number) => void;
|
|
84
|
+
removeItem: (index: number) => T | null;
|
|
100
85
|
moveItem: (fromIndex: number, toIndex: number) => boolean;
|
|
101
|
-
updateList: (
|
|
86
|
+
updateList: (list: T[]) => void;
|
|
102
87
|
clear: () => void;
|
|
103
|
-
getItem: (index: number) =>
|
|
104
|
-
findIndex: (predicate: (item:
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
listClass: string;
|
|
137
|
-
itemClass: string;
|
|
138
|
-
showEmptyState: boolean;
|
|
139
|
-
swapThreshold: number;
|
|
140
|
-
invertSwap: boolean;
|
|
141
|
-
gridColumns: number;
|
|
142
|
-
gridRows: number;
|
|
143
|
-
gap: string | number;
|
|
144
|
-
flexWrap: boolean;
|
|
145
|
-
alignItems: AlignItems;
|
|
146
|
-
customStyles: Record<string, string | number>;
|
|
147
|
-
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
148
|
-
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
149
|
-
declare const _default: typeof __VLS_export;
|
|
150
|
-
type __VLS_WithSlots<T, S> = T & {
|
|
151
|
-
new (): {
|
|
152
|
-
$slots: S;
|
|
153
|
-
};
|
|
88
|
+
getItem: (index: number) => T | undefined;
|
|
89
|
+
findIndex: (predicate: (item: T) => boolean) => number;
|
|
90
|
+
}
|
|
91
|
+
//#endregion
|
|
92
|
+
//#region src/components/C_Draggable/index.vue.d.ts
|
|
93
|
+
declare const __VLS_export: <T extends object = DraggableItem>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
94
|
+
props: vue.PublicProps & __VLS_PrettifyLocal<DraggableProps<T> & {
|
|
95
|
+
"onUpdate:modelValue"?: ((value: T[]) => any) | undefined;
|
|
96
|
+
"onDrag-start"?: ((event: DragEvent<T>) => any) | undefined;
|
|
97
|
+
"onDrag-end"?: ((event: DragEvent<T>) => any) | undefined;
|
|
98
|
+
"onItem-add"?: ((item: T, index: number) => any) | undefined;
|
|
99
|
+
"onItem-remove"?: ((item: T, index: number) => any) | undefined;
|
|
100
|
+
"onList-change"?: ((list: T[]) => any) | undefined;
|
|
101
|
+
}> & (typeof globalThis extends {
|
|
102
|
+
__VLS_PROPS_FALLBACK: infer P;
|
|
103
|
+
} ? P : {});
|
|
104
|
+
expose: (exposed: vue.ShallowUnwrapRef<{
|
|
105
|
+
isDragging: Readonly<vue.Ref<boolean, boolean>>;
|
|
106
|
+
list: Readonly<vue.Ref<readonly vue.DeepReadonly<T>[], readonly vue.DeepReadonly<T>[]>>;
|
|
107
|
+
isEmpty: Readonly<vue.Ref<boolean, boolean>>;
|
|
108
|
+
addItem: (item: T, index?: number) => void;
|
|
109
|
+
removeItem: (index: number) => T | null;
|
|
110
|
+
moveItem: (fromIndex: number, toIndex: number) => boolean;
|
|
111
|
+
updateList: (newList: T[]) => void;
|
|
112
|
+
clear: () => void;
|
|
113
|
+
getItem: (index: number) => T | undefined;
|
|
114
|
+
findIndex: (predicate: (item: T) => boolean) => number;
|
|
115
|
+
}>) => void;
|
|
116
|
+
attrs: any;
|
|
117
|
+
slots: DraggableSlots<T>;
|
|
118
|
+
emit: ((evt: "update:modelValue", value: T[]) => void) & ((evt: "drag-start", event: DragEvent<T>) => void) & ((evt: "drag-end", event: DragEvent<T>) => void) & ((evt: "item-add", item: T, index: number) => void) & ((evt: "item-remove", item: T, index: number) => void) & ((evt: "list-change", list: T[]) => void);
|
|
119
|
+
}>) => vue.VNode & {
|
|
120
|
+
__ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
|
|
154
121
|
};
|
|
122
|
+
declare const _default: typeof __VLS_export;
|
|
123
|
+
type __VLS_PrettifyLocal<T> = (T extends any ? { [K in keyof T]: T[K] } : { [K in keyof T as K]: T[K] }) & {};
|
|
155
124
|
//#endregion
|
|
156
125
|
//#region src/components/C_Draggable/composables/useDraggableLayout.d.ts
|
|
157
|
-
type LayoutDragEvent = Partial<Pick<DraggableEvent<
|
|
158
|
-
type EmitFn = {
|
|
159
|
-
(event: 'update:modelValue', value:
|
|
160
|
-
(event: 'drag-start', dragEvent: DragEvent): void;
|
|
161
|
-
(event: 'drag-end', dragEvent: DragEvent): void;
|
|
162
|
-
(event: 'item-add', item:
|
|
163
|
-
(event: 'item-remove', item:
|
|
164
|
-
(event: 'list-change', list:
|
|
126
|
+
type LayoutDragEvent<T extends object> = Partial<Pick<DraggableEvent<T>, 'data' | 'clonedData' | 'oldIndex' | 'newIndex' | 'oldDraggableIndex' | 'newDraggableIndex' | 'from' | 'to' | 'pullMode'>>;
|
|
127
|
+
type EmitFn$1<T extends object> = {
|
|
128
|
+
(event: 'update:modelValue', value: T[]): void;
|
|
129
|
+
(event: 'drag-start', dragEvent: DragEvent<T>): void;
|
|
130
|
+
(event: 'drag-end', dragEvent: DragEvent<T>): void;
|
|
131
|
+
(event: 'item-add', item: T, index: number): void;
|
|
132
|
+
(event: 'item-remove', item: T, index: number): void;
|
|
133
|
+
(event: 'list-change', list: T[]): void;
|
|
165
134
|
};
|
|
166
135
|
/**
|
|
167
136
|
*
|
|
168
137
|
*/
|
|
169
|
-
declare function useDraggableLayout(props: DraggableProps
|
|
138
|
+
declare function useDraggableLayout<T extends object = DraggableItem>(props: DraggableProps<T>, emit: EmitFn$1<T>): {
|
|
170
139
|
isDragging: vue.Ref<boolean, boolean>;
|
|
171
|
-
internalList: vue.WritableComputedRef<
|
|
140
|
+
internalList: vue.WritableComputedRef<T[], T[]>;
|
|
172
141
|
isEmpty: vue.ComputedRef<boolean>;
|
|
173
142
|
listClasses: vue.ComputedRef<(string | {
|
|
174
143
|
'flex-wrap': boolean | undefined;
|
|
175
144
|
} | undefined)[]>;
|
|
176
145
|
listStyles: vue.ComputedRef<Record<string, string | number>>;
|
|
177
|
-
draggableOptions: vue.ComputedRef<Record<string,
|
|
178
|
-
getItemKey: (item:
|
|
179
|
-
getItemTitle: (item:
|
|
180
|
-
getItemDescription: (item:
|
|
146
|
+
draggableOptions: vue.ComputedRef<Record<string, unknown>>;
|
|
147
|
+
getItemKey: (item: T, index: number) => string | number;
|
|
148
|
+
getItemTitle: (item: T) => string;
|
|
149
|
+
getItemDescription: (item: T) => string;
|
|
181
150
|
getItemClass: () => (string | {
|
|
182
151
|
'is-disabled': boolean | undefined;
|
|
183
152
|
} | undefined)[];
|
|
184
|
-
handleStart: (event: LayoutDragEvent) => void;
|
|
185
|
-
handleEnd: (event: LayoutDragEvent) => void;
|
|
186
|
-
handleAdd: (event: LayoutDragEvent) => void;
|
|
187
|
-
handleRemove: (event: LayoutDragEvent) => void;
|
|
153
|
+
handleStart: (event: LayoutDragEvent<T>) => void;
|
|
154
|
+
handleEnd: (event: LayoutDragEvent<T>) => void;
|
|
155
|
+
handleAdd: (event: LayoutDragEvent<T>) => void;
|
|
156
|
+
handleRemove: (event: LayoutDragEvent<T>) => void;
|
|
188
157
|
handleUpdate: () => void;
|
|
189
|
-
addItem: (item:
|
|
190
|
-
removeItem: (index: number) =>
|
|
158
|
+
addItem: (item: T, index?: number) => void;
|
|
159
|
+
removeItem: (index: number) => T | null;
|
|
191
160
|
moveItem: (fromIndex: number, toIndex: number) => boolean;
|
|
192
|
-
updateList: (newList:
|
|
161
|
+
updateList: (newList: T[]) => void;
|
|
193
162
|
clear: () => void;
|
|
194
|
-
getItem: (index: number) =>
|
|
195
|
-
findIndex: (predicate: (item:
|
|
163
|
+
getItem: (index: number) => T | undefined;
|
|
164
|
+
findIndex: (predicate: (item: T) => boolean) => number;
|
|
196
165
|
};
|
|
197
166
|
//#endregion
|
|
198
|
-
export { DraggableEmits as a,
|
|
167
|
+
export { DraggableEmits as a, DraggableProps as c, JustifyContent as d, LayoutMode as f, DragEvent as i, DraggableSlots as l, _default as n, DraggableExpose as o, AlignItems as r, DraggableItem as s, useDraggableLayout as t, GroupOptions as u };
|
|
@@ -8,18 +8,24 @@ import { NAIVE_COMBOS, NaiveRule, PRESET_RULES, RuleSpec, RuleSpec as RuleSpec$1
|
|
|
8
8
|
//#region src/components/C_Form/utils/formValidation.d.ts
|
|
9
9
|
/** 原生规则、验证库规则和框架无关规则均可直接作为字段配置。 */
|
|
10
10
|
type FormValidationRule = FormItemRule | NaiveRule | RuleSpec;
|
|
11
|
-
type NativePresetRule = FormItemRule & Pick<NaiveRule, 'trigger' | 'validator' | 'required' | 'message'>;
|
|
12
|
-
type NativeRuleFactories<T> = { readonly [Key in keyof T]: T[Key] extends ((...args: infer Args) => infer Result) ? (...args: Args) => Result extends readonly NaiveRule[] ? NativePresetRule[] : Result extends NaiveRule ? NativePresetRule : Result : T[Key] };
|
|
13
|
-
/** 运行时保持验证库的工厂对象,只有公开类型在组件包内统一适配。 */
|
|
14
|
-
declare const PRESET_RULES$1: NativeRuleFactories<typeof PRESET_RULES>;
|
|
15
|
-
declare const NAIVE_COMBOS$1: NativeRuleFactories<typeof NAIVE_COMBOS>;
|
|
16
11
|
//#endregion
|
|
17
12
|
//#region src/components/C_Form/types.d.ts
|
|
18
13
|
type MaybePromise<T> = T | Promise<T>;
|
|
19
14
|
type FormRecord = Record<string, unknown>;
|
|
20
15
|
type AtomicFormValue = string | number | boolean | bigint | symbol | null | undefined | Date | RegExp | File | Blob;
|
|
21
|
-
|
|
22
|
-
|
|
16
|
+
/**
|
|
17
|
+
* 最多展开五次子模型,保留六层字段路径及递归业务模型支持。
|
|
18
|
+
* 每层引用独立别名,避免 TypeScript 5.8 方差检查递归路径自身时栈溢出。
|
|
19
|
+
*/
|
|
20
|
+
type FieldPathChild<T> = NonNullable<T> extends AtomicFormValue ? never : NonNullable<T> extends readonly (infer Item)[] ? NonNullable<Item> extends AtomicFormValue ? never : NonNullable<Item> extends object ? NonNullable<Item> : never : NonNullable<T> extends object ? NonNullable<T> : never;
|
|
21
|
+
type FieldPathStep<T extends object, Children extends { [K in keyof T]: string }> = { [K in Extract<keyof T, string>]: NonNullable<T[K]> extends AtomicFormValue ? K : NonNullable<T[K]> extends readonly (infer Item)[] ? NonNullable<Item> extends AtomicFormValue ? K | `${K}.${number}` : NonNullable<Item> extends object ? K | `${K}.${number}` | `${K}.${number}.${Children[K]}` : K : NonNullable<T[K]> extends object ? K | `${K}.${Children[K]}` : K }[Extract<keyof T, string>];
|
|
22
|
+
type NestedFieldPath0<T extends object> = Extract<keyof T, string>;
|
|
23
|
+
type NestedFieldPath1<T extends object> = FieldPathStep<T, { [K in keyof T]: NestedFieldPath0<FieldPathChild<T[K]>> }>;
|
|
24
|
+
type NestedFieldPath2<T extends object> = FieldPathStep<T, { [K in keyof T]: NestedFieldPath1<FieldPathChild<T[K]>> }>;
|
|
25
|
+
type NestedFieldPath3<T extends object> = FieldPathStep<T, { [K in keyof T]: NestedFieldPath2<FieldPathChild<T[K]>> }>;
|
|
26
|
+
type NestedFieldPath4<T extends object> = FieldPathStep<T, { [K in keyof T]: NestedFieldPath3<FieldPathChild<T[K]>> }>;
|
|
27
|
+
type NestedFieldPath5<T extends object> = FieldPathStep<T, { [K in keyof T]: NestedFieldPath4<FieldPathChild<T[K]>> }>;
|
|
28
|
+
type FieldPath<T extends object = FormRecord> = keyof T extends never ? string : string extends keyof T ? string : NestedFieldPath5<T>;
|
|
23
29
|
type NestedFieldPathValue<T, P extends string> = T extends readonly (infer Item)[] ? P extends `${number}.${infer Rest}` ? NestedFieldPathValue<NonNullable<Item>, Rest> : P extends `${number}` ? Item : unknown : P extends keyof T ? T[P] : P extends `${infer K}.${infer Rest}` ? K extends keyof T ? NestedFieldPathValue<NonNullable<T[K]>, Rest> : unknown : unknown;
|
|
24
30
|
type FieldPathValue<T extends object, P extends string> = NestedFieldPathValue<T, P>;
|
|
25
31
|
/**
|
|
@@ -273,12 +279,10 @@ interface LayoutConfig {
|
|
|
273
279
|
* 表单配置项接口
|
|
274
280
|
* @description 单个表单项的完整配置
|
|
275
281
|
*/
|
|
276
|
-
interface
|
|
282
|
+
interface FormOptionBase<T extends object> {
|
|
277
283
|
id?: string;
|
|
278
284
|
type: ComponentType | string;
|
|
279
|
-
prop: FieldPath<T>;
|
|
280
285
|
label?: string;
|
|
281
|
-
value?: unknown;
|
|
282
286
|
placeholder?: string;
|
|
283
287
|
rules?: readonly FormValidationRule[];
|
|
284
288
|
attrs?: Record<string, unknown>;
|
|
@@ -293,8 +297,6 @@ interface FormOption<T extends object = FormRecord> {
|
|
|
293
297
|
disabled?: boolean | ((formModel: FormModel<T>) => boolean);
|
|
294
298
|
/** 字段级只读(优先级高于全局 config.readonly) */
|
|
295
299
|
readonly?: boolean | ((formModel: FormModel<T>) => boolean);
|
|
296
|
-
/** 联动赋值:其他字段变化时自动计算本字段的值 */
|
|
297
|
-
valueWhen?: (formModel: FormModel<T>) => unknown;
|
|
298
300
|
/** 异步数据源:select / cascader / checkbox / radio 的远程选项加载 */
|
|
299
301
|
asyncOptions?: (formModel: FormModel<T>, context?: AsyncOptionsContext) => Promise<readonly OptionItem[]>;
|
|
300
302
|
/** 联动校验规则:根据表单数据动态返回校验规则 */
|
|
@@ -302,6 +304,12 @@ interface FormOption<T extends object = FormRecord> {
|
|
|
302
304
|
/** 跨字段校验:需要引用多个字段值的验证函数,返回错误消息或 null */
|
|
303
305
|
crossFieldValidator?: (formModel: FormModel<T>) => MaybePromise<string | null>;
|
|
304
306
|
}
|
|
307
|
+
/** 字段名与初值、联动返回值关联;未声明业务模型时保持动态表单的宽松契约。 */
|
|
308
|
+
type FormOption<T extends object = FormRecord> = FormOptionBase<T> & { [P in FieldPath<T>]: {
|
|
309
|
+
prop: P;
|
|
310
|
+
value?: FieldPathValue<T, P>; /** 联动赋值:其他字段变化时自动计算本字段的值。 */
|
|
311
|
+
valueWhen?: (formModel: FormModel<T>) => FieldPathValue<T, P>;
|
|
312
|
+
} }[FieldPath<T>];
|
|
305
313
|
/**
|
|
306
314
|
* 表单提交事件参数
|
|
307
315
|
*/
|
|
@@ -467,7 +475,7 @@ interface LayoutCallbacks<T extends object = FormRecord> {
|
|
|
467
475
|
onGroupToggle?: (groupKey: string, collapsed: boolean) => void;
|
|
468
476
|
onGroupReset?: (groupKey: string) => void;
|
|
469
477
|
onFieldsChange?: (fields: FormOption<T>[]) => void;
|
|
470
|
-
onSubmit?: (payload: SubmitEventPayload<T>, context?: FormSubmitContext) =>
|
|
478
|
+
onSubmit?: (payload: SubmitEventPayload<T>, context?: FormSubmitContext) => unknown;
|
|
471
479
|
onError?: (error: unknown, context: FormErrorContext) => void;
|
|
472
480
|
}
|
|
473
481
|
/**
|
|
@@ -722,7 +730,7 @@ type FormEmit = {
|
|
|
722
730
|
declare function useFormState(options: ComputedRef<FormOption[]>, config: ComputedRef<ResolvedFormConfig>, formRef: Ref<FormInst | null>, emit: FormEmit, externalModel?: ComputedRef<FormModel | undefined>, validationReady?: ComputedRef<boolean>): {
|
|
723
731
|
formModel: FormRecord;
|
|
724
732
|
formRules: FormRules;
|
|
725
|
-
visibleOptions: ComputedRef<FormOption
|
|
733
|
+
visibleOptions: ComputedRef<FormOption[]>;
|
|
726
734
|
initialize: () => void;
|
|
727
735
|
handleFieldChange: (field: string) => void;
|
|
728
736
|
setFormItemRef: (field: string, instance: FormItemInst | null) => void;
|
|
@@ -809,4 +817,4 @@ type DynamicFormStateType = DynamicFormController;
|
|
|
809
817
|
*/
|
|
810
818
|
declare const DYNAMIC_FORM_STATE_KEY: unique symbol;
|
|
811
819
|
//#endregion
|
|
812
|
-
export { FormStepActionsSlotProps as $, ResolvedFormConfig as A, DynamicFormConfig as B, unregisterRenderer as C, FormConfig as D, FORM_GLOBAL_CONFIG_KEY as E, AsyncOptionsContext as F, FormActionSlotProps as G, DynamicFormState as H, CardLayoutConfig as I, FormMode as J, FormErrorContext as K, ComponentType as L, resolveFormConfig as M, shouldShowActions as N, LAYOUTS_WITH_OWN_CONTROLS as O, useFormGlobalConfig as P, FormSlots as Q, CustomLayoutConfig as R, registerRenderer as S, FORM_DEFAULTS as T, FieldPath as U, DynamicFormController as V, FieldPathValue as W, FormOption as X, FormModel as Y, FormRecord as Z, FormRendererContext as _, UseFormDirtyReturn as a, LayoutConfig as at, UseFormRendererOptions as b, UseCFormOptions as c, OptionItem as ct, defineFormOptions as d, TabsLayoutConfig as dt, FormSubmitContext as et, useCForm as f, FormValidationRule as ft, FormRenderer as g, SPEC_RULES as gt, FORM_RENDERER_REGISTRY_KEY as h, RuleSpec$1 as ht, useDynamicFormState as i, LabelPlacement as it, mergeFormConfig as j, LayoutCallbacks as k, UseCFormReturn as l, StepsLayoutConfig as lt, ComponentMap as m, PRESET_RULES
|
|
820
|
+
export { FormStepActionsSlotProps as $, ResolvedFormConfig as A, DynamicFormConfig as B, unregisterRenderer as C, FormConfig as D, FORM_GLOBAL_CONFIG_KEY as E, AsyncOptionsContext as F, FormActionSlotProps as G, DynamicFormState as H, CardLayoutConfig as I, FormMode as J, FormErrorContext as K, ComponentType as L, resolveFormConfig as M, shouldShowActions as N, LAYOUTS_WITH_OWN_CONTROLS as O, useFormGlobalConfig as P, FormSlots as Q, CustomLayoutConfig as R, registerRenderer as S, FORM_DEFAULTS as T, FieldPath as U, DynamicFormController as V, FieldPathValue as W, FormOption as X, FormModel as Y, FormRecord as Z, FormRendererContext as _, UseFormDirtyReturn as a, LayoutConfig as at, UseFormRendererOptions as b, UseCFormOptions as c, OptionItem as ct, defineFormOptions as d, TabsLayoutConfig as dt, FormSubmitContext as et, useCForm as f, FormValidationRule as ft, FormRenderer as g, SPEC_RULES as gt, FORM_RENDERER_REGISTRY_KEY as h, RuleSpec$1 as ht, useDynamicFormState as i, LabelPlacement as it, mergeFormConfig as j, LayoutCallbacks as k, UseCFormReturn as l, StepsLayoutConfig as lt, ComponentMap as m, PRESET_RULES as mt, DynamicFormStateType as n, GridLayoutConfig as nt, useFormDirty as o, LayoutType as ot, _default as p, NAIVE_COMBOS as pt, FormInstance as q, FIELD_TYPE_OPTIONS as r, InlineLayoutConfig as rt, useFormState as s, MaybePromise as st, DYNAMIC_FORM_STATE_KEY as t, FormTabActionsSlotProps as tt, defineFormConfig as u, SubmitEventPayload as ut, FormRendererRegistry as v, useFormRenderer as w, createFormRendererRegistry as x, RendererProps as y, DynamicFieldConfig as z };
|
|
@@ -8,18 +8,24 @@ import { NAIVE_COMBOS, NaiveRule, PRESET_RULES, RuleSpec, RuleSpec as RuleSpec$1
|
|
|
8
8
|
//#region src/components/C_Form/utils/formValidation.d.ts
|
|
9
9
|
/** 原生规则、验证库规则和框架无关规则均可直接作为字段配置。 */
|
|
10
10
|
type FormValidationRule = FormItemRule | NaiveRule | RuleSpec;
|
|
11
|
-
type NativePresetRule = FormItemRule & Pick<NaiveRule, 'trigger' | 'validator' | 'required' | 'message'>;
|
|
12
|
-
type NativeRuleFactories<T> = { readonly [Key in keyof T]: T[Key] extends ((...args: infer Args) => infer Result) ? (...args: Args) => Result extends readonly NaiveRule[] ? NativePresetRule[] : Result extends NaiveRule ? NativePresetRule : Result : T[Key] };
|
|
13
|
-
/** 运行时保持验证库的工厂对象,只有公开类型在组件包内统一适配。 */
|
|
14
|
-
declare const PRESET_RULES$1: NativeRuleFactories<typeof PRESET_RULES>;
|
|
15
|
-
declare const NAIVE_COMBOS$1: NativeRuleFactories<typeof NAIVE_COMBOS>;
|
|
16
11
|
//#endregion
|
|
17
12
|
//#region src/components/C_Form/types.d.ts
|
|
18
13
|
type MaybePromise<T> = T | Promise<T>;
|
|
19
14
|
type FormRecord = Record<string, unknown>;
|
|
20
15
|
type AtomicFormValue = string | number | boolean | bigint | symbol | null | undefined | Date | RegExp | File | Blob;
|
|
21
|
-
|
|
22
|
-
|
|
16
|
+
/**
|
|
17
|
+
* 最多展开五次子模型,保留六层字段路径及递归业务模型支持。
|
|
18
|
+
* 每层引用独立别名,避免 TypeScript 5.8 方差检查递归路径自身时栈溢出。
|
|
19
|
+
*/
|
|
20
|
+
type FieldPathChild<T> = NonNullable<T> extends AtomicFormValue ? never : NonNullable<T> extends readonly (infer Item)[] ? NonNullable<Item> extends AtomicFormValue ? never : NonNullable<Item> extends object ? NonNullable<Item> : never : NonNullable<T> extends object ? NonNullable<T> : never;
|
|
21
|
+
type FieldPathStep<T extends object, Children extends { [K in keyof T]: string }> = { [K in Extract<keyof T, string>]: NonNullable<T[K]> extends AtomicFormValue ? K : NonNullable<T[K]> extends readonly (infer Item)[] ? NonNullable<Item> extends AtomicFormValue ? K | `${K}.${number}` : NonNullable<Item> extends object ? K | `${K}.${number}` | `${K}.${number}.${Children[K]}` : K : NonNullable<T[K]> extends object ? K | `${K}.${Children[K]}` : K }[Extract<keyof T, string>];
|
|
22
|
+
type NestedFieldPath0<T extends object> = Extract<keyof T, string>;
|
|
23
|
+
type NestedFieldPath1<T extends object> = FieldPathStep<T, { [K in keyof T]: NestedFieldPath0<FieldPathChild<T[K]>> }>;
|
|
24
|
+
type NestedFieldPath2<T extends object> = FieldPathStep<T, { [K in keyof T]: NestedFieldPath1<FieldPathChild<T[K]>> }>;
|
|
25
|
+
type NestedFieldPath3<T extends object> = FieldPathStep<T, { [K in keyof T]: NestedFieldPath2<FieldPathChild<T[K]>> }>;
|
|
26
|
+
type NestedFieldPath4<T extends object> = FieldPathStep<T, { [K in keyof T]: NestedFieldPath3<FieldPathChild<T[K]>> }>;
|
|
27
|
+
type NestedFieldPath5<T extends object> = FieldPathStep<T, { [K in keyof T]: NestedFieldPath4<FieldPathChild<T[K]>> }>;
|
|
28
|
+
type FieldPath<T extends object = FormRecord> = keyof T extends never ? string : string extends keyof T ? string : NestedFieldPath5<T>;
|
|
23
29
|
type NestedFieldPathValue<T, P extends string> = T extends readonly (infer Item)[] ? P extends `${number}.${infer Rest}` ? NestedFieldPathValue<NonNullable<Item>, Rest> : P extends `${number}` ? Item : unknown : P extends keyof T ? T[P] : P extends `${infer K}.${infer Rest}` ? K extends keyof T ? NestedFieldPathValue<NonNullable<T[K]>, Rest> : unknown : unknown;
|
|
24
30
|
type FieldPathValue<T extends object, P extends string> = NestedFieldPathValue<T, P>;
|
|
25
31
|
/**
|
|
@@ -273,12 +279,10 @@ interface LayoutConfig {
|
|
|
273
279
|
* 表单配置项接口
|
|
274
280
|
* @description 单个表单项的完整配置
|
|
275
281
|
*/
|
|
276
|
-
interface
|
|
282
|
+
interface FormOptionBase<T extends object> {
|
|
277
283
|
id?: string;
|
|
278
284
|
type: ComponentType | string;
|
|
279
|
-
prop: FieldPath<T>;
|
|
280
285
|
label?: string;
|
|
281
|
-
value?: unknown;
|
|
282
286
|
placeholder?: string;
|
|
283
287
|
rules?: readonly FormValidationRule[];
|
|
284
288
|
attrs?: Record<string, unknown>;
|
|
@@ -293,8 +297,6 @@ interface FormOption<T extends object = FormRecord> {
|
|
|
293
297
|
disabled?: boolean | ((formModel: FormModel<T>) => boolean);
|
|
294
298
|
/** 字段级只读(优先级高于全局 config.readonly) */
|
|
295
299
|
readonly?: boolean | ((formModel: FormModel<T>) => boolean);
|
|
296
|
-
/** 联动赋值:其他字段变化时自动计算本字段的值 */
|
|
297
|
-
valueWhen?: (formModel: FormModel<T>) => unknown;
|
|
298
300
|
/** 异步数据源:select / cascader / checkbox / radio 的远程选项加载 */
|
|
299
301
|
asyncOptions?: (formModel: FormModel<T>, context?: AsyncOptionsContext) => Promise<readonly OptionItem[]>;
|
|
300
302
|
/** 联动校验规则:根据表单数据动态返回校验规则 */
|
|
@@ -302,6 +304,12 @@ interface FormOption<T extends object = FormRecord> {
|
|
|
302
304
|
/** 跨字段校验:需要引用多个字段值的验证函数,返回错误消息或 null */
|
|
303
305
|
crossFieldValidator?: (formModel: FormModel<T>) => MaybePromise<string | null>;
|
|
304
306
|
}
|
|
307
|
+
/** 字段名与初值、联动返回值关联;未声明业务模型时保持动态表单的宽松契约。 */
|
|
308
|
+
type FormOption<T extends object = FormRecord> = FormOptionBase<T> & { [P in FieldPath<T>]: {
|
|
309
|
+
prop: P;
|
|
310
|
+
value?: FieldPathValue<T, P>; /** 联动赋值:其他字段变化时自动计算本字段的值。 */
|
|
311
|
+
valueWhen?: (formModel: FormModel<T>) => FieldPathValue<T, P>;
|
|
312
|
+
} }[FieldPath<T>];
|
|
305
313
|
/**
|
|
306
314
|
* 表单提交事件参数
|
|
307
315
|
*/
|
|
@@ -467,7 +475,7 @@ interface LayoutCallbacks<T extends object = FormRecord> {
|
|
|
467
475
|
onGroupToggle?: (groupKey: string, collapsed: boolean) => void;
|
|
468
476
|
onGroupReset?: (groupKey: string) => void;
|
|
469
477
|
onFieldsChange?: (fields: FormOption<T>[]) => void;
|
|
470
|
-
onSubmit?: (payload: SubmitEventPayload<T>, context?: FormSubmitContext) =>
|
|
478
|
+
onSubmit?: (payload: SubmitEventPayload<T>, context?: FormSubmitContext) => unknown;
|
|
471
479
|
onError?: (error: unknown, context: FormErrorContext) => void;
|
|
472
480
|
}
|
|
473
481
|
/**
|
|
@@ -722,7 +730,7 @@ type FormEmit = {
|
|
|
722
730
|
declare function useFormState(options: ComputedRef<FormOption[]>, config: ComputedRef<ResolvedFormConfig>, formRef: Ref<FormInst | null>, emit: FormEmit, externalModel?: ComputedRef<FormModel | undefined>, validationReady?: ComputedRef<boolean>): {
|
|
723
731
|
formModel: FormRecord;
|
|
724
732
|
formRules: FormRules;
|
|
725
|
-
visibleOptions: ComputedRef<FormOption
|
|
733
|
+
visibleOptions: ComputedRef<FormOption[]>;
|
|
726
734
|
initialize: () => void;
|
|
727
735
|
handleFieldChange: (field: string) => void;
|
|
728
736
|
setFormItemRef: (field: string, instance: FormItemInst | null) => void;
|
|
@@ -809,4 +817,4 @@ type DynamicFormStateType = DynamicFormController;
|
|
|
809
817
|
*/
|
|
810
818
|
declare const DYNAMIC_FORM_STATE_KEY: unique symbol;
|
|
811
819
|
//#endregion
|
|
812
|
-
export { FormStepActionsSlotProps as $, ResolvedFormConfig as A, DynamicFormConfig as B, unregisterRenderer as C, FormConfig as D, FORM_GLOBAL_CONFIG_KEY as E, AsyncOptionsContext as F, FormActionSlotProps as G, DynamicFormState as H, CardLayoutConfig as I, FormMode as J, FormErrorContext as K, ComponentType as L, resolveFormConfig as M, shouldShowActions as N, LAYOUTS_WITH_OWN_CONTROLS as O, useFormGlobalConfig as P, FormSlots as Q, CustomLayoutConfig as R, registerRenderer as S, FORM_DEFAULTS as T, FieldPath as U, DynamicFormController as V, FieldPathValue as W, FormOption as X, FormModel as Y, FormRecord as Z, FormRendererContext as _, UseFormDirtyReturn as a, LayoutConfig as at, UseFormRendererOptions as b, UseCFormOptions as c, OptionItem as ct, defineFormOptions as d, TabsLayoutConfig as dt, FormSubmitContext as et, useCForm as f, FormValidationRule as ft, FormRenderer as g, SPEC_RULES as gt, FORM_RENDERER_REGISTRY_KEY as h, RuleSpec$1 as ht, useDynamicFormState as i, LabelPlacement as it, mergeFormConfig as j, LayoutCallbacks as k, UseCFormReturn as l, StepsLayoutConfig as lt, ComponentMap as m, PRESET_RULES
|
|
820
|
+
export { FormStepActionsSlotProps as $, ResolvedFormConfig as A, DynamicFormConfig as B, unregisterRenderer as C, FormConfig as D, FORM_GLOBAL_CONFIG_KEY as E, AsyncOptionsContext as F, FormActionSlotProps as G, DynamicFormState as H, CardLayoutConfig as I, FormMode as J, FormErrorContext as K, ComponentType as L, resolveFormConfig as M, shouldShowActions as N, LAYOUTS_WITH_OWN_CONTROLS as O, useFormGlobalConfig as P, FormSlots as Q, CustomLayoutConfig as R, registerRenderer as S, FORM_DEFAULTS as T, FieldPath as U, DynamicFormController as V, FieldPathValue as W, FormOption as X, FormModel as Y, FormRecord as Z, FormRendererContext as _, UseFormDirtyReturn as a, LayoutConfig as at, UseFormRendererOptions as b, UseCFormOptions as c, OptionItem as ct, defineFormOptions as d, TabsLayoutConfig as dt, FormSubmitContext as et, useCForm as f, FormValidationRule as ft, FormRenderer as g, SPEC_RULES as gt, FORM_RENDERER_REGISTRY_KEY as h, RuleSpec$1 as ht, useDynamicFormState as i, LabelPlacement as it, mergeFormConfig as j, LayoutCallbacks as k, UseCFormReturn as l, StepsLayoutConfig as lt, ComponentMap as m, PRESET_RULES as mt, DynamicFormStateType as n, GridLayoutConfig as nt, useFormDirty as o, LayoutType as ot, _default as p, NAIVE_COMBOS as pt, FormInstance as q, FIELD_TYPE_OPTIONS as r, InlineLayoutConfig as rt, useFormState as s, MaybePromise as st, DYNAMIC_FORM_STATE_KEY as t, FormTabActionsSlotProps as tt, defineFormConfig as u, SubmitEventPayload as ut, FormRendererRegistry as v, useFormRenderer as w, createFormRendererRegistry as x, RendererProps as y, DynamicFieldConfig as z };
|
|
@@ -238,6 +238,11 @@ interface GraphConfig {
|
|
|
238
238
|
history?: HistoryConfig;
|
|
239
239
|
clipboard?: ClipboardConfig;
|
|
240
240
|
}
|
|
241
|
+
/** 公开图实例;初始化和布局切换期间尚无实例时返回 undefined。 */
|
|
242
|
+
interface DiagramExpose {
|
|
243
|
+
getGraph: () => Graph | undefined;
|
|
244
|
+
getData: () => DiagramData | undefined;
|
|
245
|
+
}
|
|
241
246
|
//#endregion
|
|
242
247
|
//#region src/components/C_AntV/index.vue.d.ts
|
|
243
248
|
interface Props extends DiagramConfig {
|
|
@@ -250,8 +255,8 @@ interface Props extends DiagramConfig {
|
|
|
250
255
|
theme?: 'light' | 'dark';
|
|
251
256
|
}
|
|
252
257
|
declare const __VLS_export: vue.DefineComponent<Props, {
|
|
253
|
-
getGraph: () =>
|
|
254
|
-
getData: () =>
|
|
258
|
+
getGraph: () => Graph | undefined;
|
|
259
|
+
getData: () => DiagramData | undefined;
|
|
255
260
|
}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {} & {
|
|
256
261
|
ready: (graph: Graph) => any;
|
|
257
262
|
"data-change": (data: DiagramData) => any;
|
|
@@ -259,10 +264,10 @@ declare const __VLS_export: vue.DefineComponent<Props, {
|
|
|
259
264
|
onReady?: ((graph: Graph) => any) | undefined;
|
|
260
265
|
"onData-change"?: ((data: DiagramData) => any) | undefined;
|
|
261
266
|
}>, {
|
|
267
|
+
width: string | number;
|
|
262
268
|
height: string | number;
|
|
263
|
-
showToolbar: boolean;
|
|
264
269
|
theme: "light" | "dark";
|
|
265
|
-
|
|
270
|
+
showToolbar: boolean;
|
|
266
271
|
readonly: boolean;
|
|
267
272
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
268
273
|
declare const _default: typeof __VLS_export;
|
|
@@ -324,4 +329,4 @@ declare function useEdgeInteraction(graph: Ref<Graph | null>, options?: EdgeInte
|
|
|
324
329
|
bindInteractions: () => void;
|
|
325
330
|
};
|
|
326
331
|
//#endregion
|
|
327
|
-
export {
|
|
332
|
+
export { ScrollerConfig as A, ValidationResult as B, HistoryConfig as C, MinimapConfig as D, MenuItem as E, UMLAttribute as F, UMLClass as I, UMLDiagramData as L, SnapshotConfig as M, ThemeConfig as N, MouseWheelConfig as O, ToolbarAction as P, UMLMethod as R, GridConfig as S, LayoutOptions as T, ERTable as _, BPMNDiagramData as a, GraphEvents as b, ClipboardConfig as c, DiagramData as d, DiagramExpose as f, ERRelation as g, ERField as h, _default as i, SelectionConfig as j, Position as k, ConnectionConfig as l, ERDiagramData as m, useGraphExport as n, BPMNFlow as o, DiagramType as p, useGraphBase as r, BPMNNode as s, useEdgeInteraction as t, DiagramConfig as u, ExportFormat as v, KeyboardConfig as w, GraphExportOptions as x, GraphConfig as y, UMLRelation as z };
|
|
@@ -238,6 +238,11 @@ interface GraphConfig {
|
|
|
238
238
|
history?: HistoryConfig;
|
|
239
239
|
clipboard?: ClipboardConfig;
|
|
240
240
|
}
|
|
241
|
+
/** 公开图实例;初始化和布局切换期间尚无实例时返回 undefined。 */
|
|
242
|
+
interface DiagramExpose {
|
|
243
|
+
getGraph: () => Graph | undefined;
|
|
244
|
+
getData: () => DiagramData | undefined;
|
|
245
|
+
}
|
|
241
246
|
//#endregion
|
|
242
247
|
//#region src/components/C_AntV/index.vue.d.ts
|
|
243
248
|
interface Props extends DiagramConfig {
|
|
@@ -250,8 +255,8 @@ interface Props extends DiagramConfig {
|
|
|
250
255
|
theme?: 'light' | 'dark';
|
|
251
256
|
}
|
|
252
257
|
declare const __VLS_export: vue.DefineComponent<Props, {
|
|
253
|
-
getGraph: () =>
|
|
254
|
-
getData: () =>
|
|
258
|
+
getGraph: () => Graph | undefined;
|
|
259
|
+
getData: () => DiagramData | undefined;
|
|
255
260
|
}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {} & {
|
|
256
261
|
ready: (graph: Graph) => any;
|
|
257
262
|
"data-change": (data: DiagramData) => any;
|
|
@@ -259,10 +264,10 @@ declare const __VLS_export: vue.DefineComponent<Props, {
|
|
|
259
264
|
onReady?: ((graph: Graph) => any) | undefined;
|
|
260
265
|
"onData-change"?: ((data: DiagramData) => any) | undefined;
|
|
261
266
|
}>, {
|
|
267
|
+
width: string | number;
|
|
262
268
|
height: string | number;
|
|
263
|
-
showToolbar: boolean;
|
|
264
269
|
theme: "light" | "dark";
|
|
265
|
-
|
|
270
|
+
showToolbar: boolean;
|
|
266
271
|
readonly: boolean;
|
|
267
272
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
268
273
|
declare const _default: typeof __VLS_export;
|
|
@@ -324,4 +329,4 @@ declare function useEdgeInteraction(graph: Ref<Graph | null>, options?: EdgeInte
|
|
|
324
329
|
bindInteractions: () => void;
|
|
325
330
|
};
|
|
326
331
|
//#endregion
|
|
327
|
-
export {
|
|
332
|
+
export { ScrollerConfig as A, ValidationResult as B, HistoryConfig as C, MinimapConfig as D, MenuItem as E, UMLAttribute as F, UMLClass as I, UMLDiagramData as L, SnapshotConfig as M, ThemeConfig as N, MouseWheelConfig as O, ToolbarAction as P, UMLMethod as R, GridConfig as S, LayoutOptions as T, ERTable as _, BPMNDiagramData as a, GraphEvents as b, ClipboardConfig as c, DiagramData as d, DiagramExpose as f, ERRelation as g, ERField as h, _default as i, SelectionConfig as j, Position as k, ConnectionConfig as l, ERDiagramData as m, useGraphExport as n, BPMNFlow as o, DiagramType as p, useGraphBase as r, BPMNNode as s, useEdgeInteraction as t, DiagramConfig as u, ExportFormat as v, KeyboardConfig as w, GraphExportOptions as x, GraphConfig as y, UMLRelation as z };
|
package/dist/useFullscreen.d.cts
CHANGED
|
@@ -10,15 +10,15 @@ type __VLS_Props = {
|
|
|
10
10
|
inline?: boolean;
|
|
11
11
|
};
|
|
12
12
|
declare const __VLS_export: vue.DefineComponent<__VLS_Props, {}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
13
|
-
preview: (file: string | File) => any;
|
|
14
13
|
download: (file: string | File) => any;
|
|
14
|
+
preview: (file: string | File) => any;
|
|
15
15
|
}, string, vue.PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
16
|
-
onPreview?: ((file: string | File) => any) | undefined;
|
|
17
16
|
onDownload?: ((file: string | File) => any) | undefined;
|
|
17
|
+
onPreview?: ((file: string | File) => any) | undefined;
|
|
18
18
|
}>, {
|
|
19
|
-
inline: boolean;
|
|
20
19
|
fileName: string;
|
|
21
20
|
autoPreview: boolean;
|
|
21
|
+
inline: boolean;
|
|
22
22
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
23
23
|
declare const _default: typeof __VLS_export;
|
|
24
24
|
//#endregion
|
package/dist/useFullscreen.d.ts
CHANGED
|
@@ -10,15 +10,15 @@ type __VLS_Props = {
|
|
|
10
10
|
inline?: boolean;
|
|
11
11
|
};
|
|
12
12
|
declare const __VLS_export: vue.DefineComponent<__VLS_Props, {}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
13
|
-
preview: (file: string | File) => any;
|
|
14
13
|
download: (file: string | File) => any;
|
|
14
|
+
preview: (file: string | File) => any;
|
|
15
15
|
}, string, vue.PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
16
|
-
onPreview?: ((file: string | File) => any) | undefined;
|
|
17
16
|
onDownload?: ((file: string | File) => any) | undefined;
|
|
17
|
+
onPreview?: ((file: string | File) => any) | undefined;
|
|
18
18
|
}>, {
|
|
19
|
-
inline: boolean;
|
|
20
19
|
fileName: string;
|
|
21
20
|
autoPreview: boolean;
|
|
21
|
+
inline: boolean;
|
|
22
22
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
23
23
|
declare const _default: typeof __VLS_export;
|
|
24
24
|
//#endregion
|
|
@@ -79,13 +79,13 @@ type __VLS_Slots = {} & {
|
|
|
79
79
|
footer?: (props: typeof __VLS_5) => any;
|
|
80
80
|
};
|
|
81
81
|
declare const __VLS_base: vue.DefineComponent<WaterFallProps, WaterFallExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
82
|
-
"item-click": (item: WaterFallItem, index: number) => any;
|
|
83
82
|
"load-more": () => any;
|
|
83
|
+
"item-click": (item: WaterFallItem, index: number) => any;
|
|
84
84
|
"image-loaded": (item: WaterFallItem) => any;
|
|
85
85
|
"image-error": (item: WaterFallItem) => any;
|
|
86
86
|
}, string, vue.PublicProps, Readonly<WaterFallProps> & Readonly<{
|
|
87
|
-
"onItem-click"?: ((item: WaterFallItem, index: number) => any) | undefined;
|
|
88
87
|
"onLoad-more"?: (() => any) | undefined;
|
|
88
|
+
"onItem-click"?: ((item: WaterFallItem, index: number) => any) | undefined;
|
|
89
89
|
"onImage-loaded"?: ((item: WaterFallItem) => any) | undefined;
|
|
90
90
|
"onImage-error"?: ((item: WaterFallItem) => any) | undefined;
|
|
91
91
|
}>, {
|