zhytech-ui 1.2.19 → 1.3.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/README.md +12 -0
- package/dist/src/components/dynamicForm/components/layout/gridLayout/index.d.ts +88 -0
- package/dist/src/components/dynamicForm/components/layout/gridLayout/propsEditor.vue.d.ts +2 -0
- package/dist/src/components/dynamicForm/components/layout/gridLayout/renderer.vue.d.ts +80 -0
- package/dist/src/components/dynamicForm/components/layout/index.d.ts +2 -1
- package/dist/src/components/dynamicForm/formDesigner.vue.d.ts +35 -0
- package/dist/src/components/dynamicForm/formRenderer.vue.d.ts +24 -0
- package/dist/src/components/dynamicForm/types/componentAttribute/index.d.ts +2 -1
- package/dist/src/components/dynamicForm/types/componentAttribute/layout/gridLayoutAttribute.d.ts +50 -0
- package/dist/src/components/dynamicForm/types/httpSettingView.d.ts +4 -0
- package/dist/src/hooks/useUtils.d.ts +2 -1
- package/dist/style.css +1 -1
- package/dist/zhytech-ui.es.js +9092 -8146
- package/dist/zhytech-ui.umd.js +15 -15
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -90,6 +90,18 @@ npm install --legacy-peer-deps
|
|
|
90
90
|
|
|
91
91
|
> #### 版本更新清单:
|
|
92
92
|
|
|
93
|
+
**V 1.3.0**
|
|
94
|
+
```html
|
|
95
|
+
1.添加支持预览模式,在预览模式下,组件显示为只读状态,可输入组件只显示值,不显示输入框
|
|
96
|
+
2.新增网格布局组件(gridLayout),支持拖动调整网格高度和宽度,支持添加行/列,支持网格合并和拆分,支持预览模式高度自适应内容,支持设置背景色
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
**V 1.2.20**
|
|
100
|
+
```html
|
|
101
|
+
1.删除动态接口请求超时时间配置,永不超时
|
|
102
|
+
2.调整动态接口设置画面,新增baseUrlFromProps参数,用于从props中获取baseUrl
|
|
103
|
+
```
|
|
104
|
+
|
|
93
105
|
**V 1.2.19**
|
|
94
106
|
```html
|
|
95
107
|
1.调整动态接口请求超时时间,60秒
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
import { default as baseComponent } from '../../../types/baseComponent';
|
|
2
|
+
declare class component extends baseComponent {
|
|
3
|
+
constructor();
|
|
4
|
+
}
|
|
5
|
+
declare const _default: {
|
|
6
|
+
component: typeof component;
|
|
7
|
+
renderer: import('vue').DefineComponent<globalThis.ExtractPropTypes<{
|
|
8
|
+
isDesigner: {
|
|
9
|
+
type: BooleanConstructor;
|
|
10
|
+
default: boolean;
|
|
11
|
+
};
|
|
12
|
+
componentID: {
|
|
13
|
+
type: (StringConstructor | NumberConstructor)[];
|
|
14
|
+
required: true;
|
|
15
|
+
};
|
|
16
|
+
component: {
|
|
17
|
+
type: PropType<Record<string, any>>;
|
|
18
|
+
required: true;
|
|
19
|
+
};
|
|
20
|
+
showDescription: {
|
|
21
|
+
type: BooleanConstructor;
|
|
22
|
+
default: boolean;
|
|
23
|
+
};
|
|
24
|
+
currentShowIDArray: {
|
|
25
|
+
type: {
|
|
26
|
+
(arrayLength: number): String[][];
|
|
27
|
+
(...items: String[][]): String[][];
|
|
28
|
+
new (arrayLength: number): String[][];
|
|
29
|
+
new (...items: String[][]): String[][];
|
|
30
|
+
isArray(arg: any): arg is any[];
|
|
31
|
+
readonly prototype: any[];
|
|
32
|
+
from<T>(arrayLike: ArrayLike<T>): T[];
|
|
33
|
+
from<T, U>(arrayLike: ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
|
|
34
|
+
from<T>(iterable: Iterable<T> | ArrayLike<T>): T[];
|
|
35
|
+
from<T, U>(iterable: Iterable<T> | ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
|
|
36
|
+
of<T>(...items: T[]): T[];
|
|
37
|
+
readonly [Symbol.species]: ArrayConstructor;
|
|
38
|
+
};
|
|
39
|
+
default: never[];
|
|
40
|
+
};
|
|
41
|
+
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
42
|
+
change: (...args: any[]) => void;
|
|
43
|
+
deleteComponent: (...args: any[]) => void;
|
|
44
|
+
}, string, import('vue').PublicProps, Readonly<globalThis.ExtractPropTypes<{
|
|
45
|
+
isDesigner: {
|
|
46
|
+
type: BooleanConstructor;
|
|
47
|
+
default: boolean;
|
|
48
|
+
};
|
|
49
|
+
componentID: {
|
|
50
|
+
type: (StringConstructor | NumberConstructor)[];
|
|
51
|
+
required: true;
|
|
52
|
+
};
|
|
53
|
+
component: {
|
|
54
|
+
type: PropType<Record<string, any>>;
|
|
55
|
+
required: true;
|
|
56
|
+
};
|
|
57
|
+
showDescription: {
|
|
58
|
+
type: BooleanConstructor;
|
|
59
|
+
default: boolean;
|
|
60
|
+
};
|
|
61
|
+
currentShowIDArray: {
|
|
62
|
+
type: {
|
|
63
|
+
(arrayLength: number): String[][];
|
|
64
|
+
(...items: String[][]): String[][];
|
|
65
|
+
new (arrayLength: number): String[][];
|
|
66
|
+
new (...items: String[][]): String[][];
|
|
67
|
+
isArray(arg: any): arg is any[];
|
|
68
|
+
readonly prototype: any[];
|
|
69
|
+
from<T>(arrayLike: ArrayLike<T>): T[];
|
|
70
|
+
from<T, U>(arrayLike: ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
|
|
71
|
+
from<T>(iterable: Iterable<T> | ArrayLike<T>): T[];
|
|
72
|
+
from<T, U>(iterable: Iterable<T> | ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
|
|
73
|
+
of<T>(...items: T[]): T[];
|
|
74
|
+
readonly [Symbol.species]: ArrayConstructor;
|
|
75
|
+
};
|
|
76
|
+
default: never[];
|
|
77
|
+
};
|
|
78
|
+
}>> & Readonly<{
|
|
79
|
+
onChange?: ((...args: any[]) => any) | undefined;
|
|
80
|
+
onDeleteComponent?: ((...args: any[]) => any) | undefined;
|
|
81
|
+
}>, {
|
|
82
|
+
showDescription: boolean;
|
|
83
|
+
currentShowIDArray: String[][];
|
|
84
|
+
isDesigner: boolean;
|
|
85
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, HTMLDivElement>;
|
|
86
|
+
propEditor: import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
87
|
+
};
|
|
88
|
+
export default _default;
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
declare const _default: import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
2
|
+
export default _default;
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
declare const _default: import('vue').DefineComponent<globalThis.ExtractPropTypes<{
|
|
2
|
+
isDesigner: {
|
|
3
|
+
type: BooleanConstructor;
|
|
4
|
+
default: boolean;
|
|
5
|
+
};
|
|
6
|
+
componentID: {
|
|
7
|
+
type: (StringConstructor | NumberConstructor)[];
|
|
8
|
+
required: true;
|
|
9
|
+
};
|
|
10
|
+
component: {
|
|
11
|
+
type: PropType<Record<string, any>>;
|
|
12
|
+
required: true;
|
|
13
|
+
};
|
|
14
|
+
showDescription: {
|
|
15
|
+
type: BooleanConstructor;
|
|
16
|
+
default: boolean;
|
|
17
|
+
};
|
|
18
|
+
currentShowIDArray: {
|
|
19
|
+
type: {
|
|
20
|
+
(arrayLength: number): String[][];
|
|
21
|
+
(...items: String[][]): String[][];
|
|
22
|
+
new (arrayLength: number): String[][];
|
|
23
|
+
new (...items: String[][]): String[][];
|
|
24
|
+
isArray(arg: any): arg is any[];
|
|
25
|
+
readonly prototype: any[];
|
|
26
|
+
from<T>(arrayLike: ArrayLike<T>): T[];
|
|
27
|
+
from<T, U>(arrayLike: ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
|
|
28
|
+
from<T>(iterable: Iterable<T> | ArrayLike<T>): T[];
|
|
29
|
+
from<T, U>(iterable: Iterable<T> | ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
|
|
30
|
+
of<T>(...items: T[]): T[];
|
|
31
|
+
readonly [Symbol.species]: ArrayConstructor;
|
|
32
|
+
};
|
|
33
|
+
default: never[];
|
|
34
|
+
};
|
|
35
|
+
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
36
|
+
change: (...args: any[]) => void;
|
|
37
|
+
deleteComponent: (...args: any[]) => void;
|
|
38
|
+
}, string, import('vue').PublicProps, Readonly<globalThis.ExtractPropTypes<{
|
|
39
|
+
isDesigner: {
|
|
40
|
+
type: BooleanConstructor;
|
|
41
|
+
default: boolean;
|
|
42
|
+
};
|
|
43
|
+
componentID: {
|
|
44
|
+
type: (StringConstructor | NumberConstructor)[];
|
|
45
|
+
required: true;
|
|
46
|
+
};
|
|
47
|
+
component: {
|
|
48
|
+
type: PropType<Record<string, any>>;
|
|
49
|
+
required: true;
|
|
50
|
+
};
|
|
51
|
+
showDescription: {
|
|
52
|
+
type: BooleanConstructor;
|
|
53
|
+
default: boolean;
|
|
54
|
+
};
|
|
55
|
+
currentShowIDArray: {
|
|
56
|
+
type: {
|
|
57
|
+
(arrayLength: number): String[][];
|
|
58
|
+
(...items: String[][]): String[][];
|
|
59
|
+
new (arrayLength: number): String[][];
|
|
60
|
+
new (...items: String[][]): String[][];
|
|
61
|
+
isArray(arg: any): arg is any[];
|
|
62
|
+
readonly prototype: any[];
|
|
63
|
+
from<T>(arrayLike: ArrayLike<T>): T[];
|
|
64
|
+
from<T, U>(arrayLike: ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
|
|
65
|
+
from<T>(iterable: Iterable<T> | ArrayLike<T>): T[];
|
|
66
|
+
from<T, U>(iterable: Iterable<T> | ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
|
|
67
|
+
of<T>(...items: T[]): T[];
|
|
68
|
+
readonly [Symbol.species]: ArrayConstructor;
|
|
69
|
+
};
|
|
70
|
+
default: never[];
|
|
71
|
+
};
|
|
72
|
+
}>> & Readonly<{
|
|
73
|
+
onChange?: ((...args: any[]) => any) | undefined;
|
|
74
|
+
onDeleteComponent?: ((...args: any[]) => any) | undefined;
|
|
75
|
+
}>, {
|
|
76
|
+
showDescription: boolean;
|
|
77
|
+
currentShowIDArray: String[][];
|
|
78
|
+
isDesigner: boolean;
|
|
79
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, HTMLDivElement>;
|
|
80
|
+
export default _default;
|
|
@@ -99,6 +99,13 @@ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<gl
|
|
|
99
99
|
type: BooleanConstructor;
|
|
100
100
|
default: boolean;
|
|
101
101
|
};
|
|
102
|
+
/**
|
|
103
|
+
* 接口基础路径
|
|
104
|
+
*/
|
|
105
|
+
httpBaseUrl: {
|
|
106
|
+
type: StringConstructor;
|
|
107
|
+
default: string;
|
|
108
|
+
};
|
|
102
109
|
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
103
110
|
change: (...args: any[]) => void;
|
|
104
111
|
test: (...args: any[]) => void;
|
|
@@ -200,6 +207,13 @@ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<gl
|
|
|
200
207
|
type: BooleanConstructor;
|
|
201
208
|
default: boolean;
|
|
202
209
|
};
|
|
210
|
+
/**
|
|
211
|
+
* 接口基础路径
|
|
212
|
+
*/
|
|
213
|
+
httpBaseUrl: {
|
|
214
|
+
type: StringConstructor;
|
|
215
|
+
default: string;
|
|
216
|
+
};
|
|
203
217
|
}>> & Readonly<{
|
|
204
218
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
205
219
|
onTest?: ((...args: any[]) => any) | undefined;
|
|
@@ -207,6 +221,7 @@ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<gl
|
|
|
207
221
|
defaultSourceType: string;
|
|
208
222
|
dictionary: dictionaryData;
|
|
209
223
|
uploadOptions: uploadOption;
|
|
224
|
+
httpBaseUrl: string;
|
|
210
225
|
realTimeDisplayAnswerMode: boolean;
|
|
211
226
|
everyItemDisplayAnalysisSwitch: boolean;
|
|
212
227
|
showCorrectOrNot: boolean;
|
|
@@ -326,6 +341,14 @@ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<gl
|
|
|
326
341
|
type: BooleanConstructor;
|
|
327
342
|
default: boolean;
|
|
328
343
|
};
|
|
344
|
+
httpBaseUrl: {
|
|
345
|
+
type: StringConstructor;
|
|
346
|
+
default: string;
|
|
347
|
+
};
|
|
348
|
+
isPreview: {
|
|
349
|
+
type: BooleanConstructor;
|
|
350
|
+
default: boolean;
|
|
351
|
+
};
|
|
329
352
|
}>> & Readonly<{
|
|
330
353
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
331
354
|
onSelect?: ((...args: any[]) => any) | undefined;
|
|
@@ -347,7 +370,9 @@ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<gl
|
|
|
347
370
|
selectComponents: Record<string, any>[];
|
|
348
371
|
selectMode: boolean;
|
|
349
372
|
disabled: boolean;
|
|
373
|
+
isPreview: boolean;
|
|
350
374
|
uploadOptions: uploadOption;
|
|
375
|
+
httpBaseUrl: string;
|
|
351
376
|
realTimeDisplayAnswerMode: boolean;
|
|
352
377
|
everyItemDisplayAnalysisSwitch: boolean;
|
|
353
378
|
showCorrectOrNot: boolean;
|
|
@@ -424,6 +449,14 @@ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<gl
|
|
|
424
449
|
type: BooleanConstructor;
|
|
425
450
|
default: boolean;
|
|
426
451
|
};
|
|
452
|
+
httpBaseUrl: {
|
|
453
|
+
type: StringConstructor;
|
|
454
|
+
default: string;
|
|
455
|
+
};
|
|
456
|
+
isPreview: {
|
|
457
|
+
type: BooleanConstructor;
|
|
458
|
+
default: boolean;
|
|
459
|
+
};
|
|
427
460
|
}>> & Readonly<{
|
|
428
461
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
429
462
|
onSelect?: ((...args: any[]) => any) | undefined;
|
|
@@ -442,7 +475,9 @@ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<gl
|
|
|
442
475
|
selectComponents: Record<string, any>[];
|
|
443
476
|
selectMode: boolean;
|
|
444
477
|
disabled: boolean;
|
|
478
|
+
isPreview: boolean;
|
|
445
479
|
uploadOptions: uploadOption;
|
|
480
|
+
httpBaseUrl: string;
|
|
446
481
|
realTimeDisplayAnswerMode: boolean;
|
|
447
482
|
everyItemDisplayAnalysisSwitch: boolean;
|
|
448
483
|
showCorrectOrNot: boolean;
|
|
@@ -96,6 +96,17 @@ declare const _default: import('vue').DefineComponent<globalThis.ExtractPropType
|
|
|
96
96
|
type: BooleanConstructor;
|
|
97
97
|
default: boolean;
|
|
98
98
|
};
|
|
99
|
+
/**
|
|
100
|
+
* 接口基础路径
|
|
101
|
+
*/
|
|
102
|
+
httpBaseUrl: {
|
|
103
|
+
type: StringConstructor;
|
|
104
|
+
default: string;
|
|
105
|
+
};
|
|
106
|
+
isPreview: {
|
|
107
|
+
type: BooleanConstructor;
|
|
108
|
+
default: boolean;
|
|
109
|
+
};
|
|
99
110
|
}>, {
|
|
100
111
|
/**
|
|
101
112
|
* @description: 获取表单数据
|
|
@@ -231,6 +242,17 @@ declare const _default: import('vue').DefineComponent<globalThis.ExtractPropType
|
|
|
231
242
|
type: BooleanConstructor;
|
|
232
243
|
default: boolean;
|
|
233
244
|
};
|
|
245
|
+
/**
|
|
246
|
+
* 接口基础路径
|
|
247
|
+
*/
|
|
248
|
+
httpBaseUrl: {
|
|
249
|
+
type: StringConstructor;
|
|
250
|
+
default: string;
|
|
251
|
+
};
|
|
252
|
+
isPreview: {
|
|
253
|
+
type: BooleanConstructor;
|
|
254
|
+
default: boolean;
|
|
255
|
+
};
|
|
234
256
|
}>> & Readonly<{
|
|
235
257
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
236
258
|
onSelect?: ((...args: any[]) => any) | undefined;
|
|
@@ -239,7 +261,9 @@ declare const _default: import('vue').DefineComponent<globalThis.ExtractPropType
|
|
|
239
261
|
selectComponents: Record<string, any>[];
|
|
240
262
|
selectMode: boolean;
|
|
241
263
|
disabled: boolean;
|
|
264
|
+
isPreview: boolean;
|
|
242
265
|
uploadOptions: uploadOption;
|
|
266
|
+
httpBaseUrl: string;
|
|
243
267
|
realTimeDisplayAnswerMode: boolean;
|
|
244
268
|
everyItemDisplayAnalysisSwitch: boolean;
|
|
245
269
|
showCorrectOrNot: boolean;
|
|
@@ -12,4 +12,5 @@ import { gradeAttribute } from './application/gradeAttribute';
|
|
|
12
12
|
import { departmentAttribute } from './application/departmentAttribute';
|
|
13
13
|
import { groupLayoutAttribute } from './layout/groupLayoutAttribute';
|
|
14
14
|
import { tabsLayoutAttribute } from './layout/tabsLayoutAttribute';
|
|
15
|
-
|
|
15
|
+
import { gridLayoutAttribute } from './layout/gridLayoutAttribute';
|
|
16
|
+
export type { baseAttribute, editAttribute, checkboxAttribute, inputAttribute, radioAttribute, datetimeAttribute, inputNumberAttribute, uploadAttribute, employeeAttribute, postAttribute, gradeAttribute, departmentAttribute, groupLayoutAttribute, tabsLayoutAttribute, gridLayoutAttribute };
|
package/dist/src/components/dynamicForm/types/componentAttribute/layout/gridLayoutAttribute.d.ts
ADDED
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @description: 网格布局(gridLayout)组件属性
|
|
3
|
+
*/
|
|
4
|
+
export interface gridLayoutAttribute {
|
|
5
|
+
/**
|
|
6
|
+
* 行数
|
|
7
|
+
*/
|
|
8
|
+
rows: number;
|
|
9
|
+
/**
|
|
10
|
+
* 列数
|
|
11
|
+
*/
|
|
12
|
+
columns: number;
|
|
13
|
+
/**
|
|
14
|
+
* 是否显示网格线
|
|
15
|
+
*/
|
|
16
|
+
showGridLines: boolean;
|
|
17
|
+
/**
|
|
18
|
+
* 网格线颜色
|
|
19
|
+
*/
|
|
20
|
+
gridLineColor: string;
|
|
21
|
+
/**
|
|
22
|
+
* 单元格内边距
|
|
23
|
+
*/
|
|
24
|
+
cellPadding: number;
|
|
25
|
+
/**
|
|
26
|
+
* 行高配置
|
|
27
|
+
*/
|
|
28
|
+
rowHeights: number[];
|
|
29
|
+
/**
|
|
30
|
+
* 列宽配置
|
|
31
|
+
*/
|
|
32
|
+
columnWidths: number[];
|
|
33
|
+
/**
|
|
34
|
+
* 背景色
|
|
35
|
+
*/
|
|
36
|
+
backgroundColor: string;
|
|
37
|
+
/**
|
|
38
|
+
* 单元格布局方式
|
|
39
|
+
*/
|
|
40
|
+
layoutMode: "horizontal" | "vertical";
|
|
41
|
+
/**
|
|
42
|
+
* 合并单元格配置
|
|
43
|
+
*/
|
|
44
|
+
mergedCells: {
|
|
45
|
+
startRow: number;
|
|
46
|
+
startCol: number;
|
|
47
|
+
rowSpan: number;
|
|
48
|
+
colSpan: number;
|
|
49
|
+
}[];
|
|
50
|
+
}
|
|
@@ -84,8 +84,9 @@ export declare function useUtils(): {
|
|
|
84
84
|
* @description: 调用api
|
|
85
85
|
* @param httpSetting 接口配置
|
|
86
86
|
* @param datas 接口参数替换数据
|
|
87
|
+
* @param baseUrl 接口基础url
|
|
87
88
|
* @param autoDealResult 是否自动处理结果
|
|
88
89
|
* @return
|
|
89
90
|
*/
|
|
90
|
-
callApi(httpSetting: httpSettingView, datas: Record<string, any>, autoDealResult?: boolean): Promise<any>;
|
|
91
|
+
callApi(httpSetting: httpSettingView, datas: Record<string, any>, baseUrl?: string, autoDealResult?: boolean): Promise<any>;
|
|
91
92
|
};
|