gp-designer 1.0.23 → 1.0.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/gp-designer.es.js +2037 -2025
- package/dist/gp-designer.umd.js +7 -7
- package/dist/style.css +2 -2
- package/dist/topic/004.css +809 -0
- package/dist/types/components/ElementRenderer.vue.d.ts +43 -1
- package/dist/types/components/GpCropperModal/index.vue.d.ts +2 -2
- package/dist/types/components/GpImageUpload.vue.d.ts +24 -1
- package/dist/types/components/GpMessage.vue.d.ts +1 -1
- package/dist/types/components/GpModal.vue.d.ts +3 -3
- package/package.json +1 -1
- package/dist/types/components/UploadImage.vue.d.ts +0 -43
@@ -1,12 +1,33 @@
|
|
1
1
|
import { PropType } from 'vue';
|
2
2
|
import { IElement } from './Model';
|
3
3
|
declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
|
4
|
+
/**
|
5
|
+
* 节点
|
6
|
+
*/
|
4
7
|
element: {
|
5
8
|
type: () => IElement;
|
6
9
|
required: true;
|
7
10
|
};
|
11
|
+
/**
|
12
|
+
* 选中的节点
|
13
|
+
*/
|
8
14
|
selectedElement: () => IElement | undefined;
|
15
|
+
/**
|
16
|
+
* 悬停的节点
|
17
|
+
*/
|
9
18
|
hoveredElement: () => IElement | undefined;
|
19
|
+
/**
|
20
|
+
* 上传图片
|
21
|
+
*/
|
22
|
+
uploadByFile: {
|
23
|
+
type: PropType<(file: File) => Promise<{
|
24
|
+
success: boolean | number;
|
25
|
+
file: {
|
26
|
+
url: string;
|
27
|
+
};
|
28
|
+
}>>;
|
29
|
+
required: false;
|
30
|
+
};
|
10
31
|
icons: {
|
11
32
|
type: PropType<string[]>;
|
12
33
|
default: () => any[];
|
@@ -48,12 +69,33 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
48
69
|
addIcon: (...args: any[]) => void;
|
49
70
|
upload: (...args: any[]) => void;
|
50
71
|
}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
|
72
|
+
/**
|
73
|
+
* 节点
|
74
|
+
*/
|
51
75
|
element: {
|
52
76
|
type: () => IElement;
|
53
77
|
required: true;
|
54
78
|
};
|
79
|
+
/**
|
80
|
+
* 选中的节点
|
81
|
+
*/
|
55
82
|
selectedElement: () => IElement | undefined;
|
83
|
+
/**
|
84
|
+
* 悬停的节点
|
85
|
+
*/
|
56
86
|
hoveredElement: () => IElement | undefined;
|
87
|
+
/**
|
88
|
+
* 上传图片
|
89
|
+
*/
|
90
|
+
uploadByFile: {
|
91
|
+
type: PropType<(file: File) => Promise<{
|
92
|
+
success: boolean | number;
|
93
|
+
file: {
|
94
|
+
url: string;
|
95
|
+
};
|
96
|
+
}>>;
|
97
|
+
required: false;
|
98
|
+
};
|
57
99
|
icons: {
|
58
100
|
type: PropType<string[]>;
|
59
101
|
default: () => any[];
|
@@ -95,7 +137,7 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
95
137
|
onAddIcon?: (...args: any[]) => any;
|
96
138
|
onUpload?: (...args: any[]) => any;
|
97
139
|
}>, {
|
98
|
-
icons: string[];
|
99
140
|
mode: "preview" | "edit" | "design";
|
141
|
+
icons: string[];
|
100
142
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
101
143
|
export default _default;
|
@@ -13,10 +13,10 @@ declare const _default: import('vue').DefineComponent<{}, {
|
|
13
13
|
handleCloseCropper: typeof handleCloseCropper;
|
14
14
|
handleOpenCropper: typeof handleOpenCropper;
|
15
15
|
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
|
16
|
-
ok: (value: any) => any;
|
17
16
|
cancel: () => any;
|
17
|
+
ok: (value: any) => any;
|
18
18
|
}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{
|
19
|
-
onOk?: (value: any) => any;
|
20
19
|
onCancel?: () => any;
|
20
|
+
onOk?: (value: any) => any;
|
21
21
|
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
22
22
|
export default _default;
|
@@ -4,6 +4,7 @@ export interface UploadFile {
|
|
4
4
|
status: "uploading" | "done" | "error" | "removed";
|
5
5
|
url?: string;
|
6
6
|
thumbUrl?: string;
|
7
|
+
file: File;
|
7
8
|
}
|
8
9
|
export interface UploadProps {
|
9
10
|
accept?: string;
|
@@ -26,12 +27,34 @@ declare const _default: import('vue').DefineComponent<{
|
|
26
27
|
status: "uploading" | "done" | "error" | "removed";
|
27
28
|
url?: string;
|
28
29
|
thumbUrl?: string;
|
30
|
+
file: {
|
31
|
+
readonly lastModified: number;
|
32
|
+
readonly name: string;
|
33
|
+
readonly webkitRelativePath: string;
|
34
|
+
readonly size: number;
|
35
|
+
readonly type: string;
|
36
|
+
arrayBuffer: () => Promise<ArrayBuffer>;
|
37
|
+
slice: (start?: number, end?: number, contentType?: string) => Blob;
|
38
|
+
stream: () => ReadableStream<Uint8Array>;
|
39
|
+
text: () => Promise<string>;
|
40
|
+
};
|
29
41
|
}[], UploadFile[] | {
|
30
42
|
uid: string;
|
31
43
|
name: string;
|
32
44
|
status: "uploading" | "done" | "error" | "removed";
|
33
45
|
url?: string;
|
34
46
|
thumbUrl?: string;
|
47
|
+
file: {
|
48
|
+
readonly lastModified: number;
|
49
|
+
readonly name: string;
|
50
|
+
readonly webkitRelativePath: string;
|
51
|
+
readonly size: number;
|
52
|
+
readonly type: string;
|
53
|
+
arrayBuffer: () => Promise<ArrayBuffer>;
|
54
|
+
slice: (start?: number, end?: number, contentType?: string) => Blob;
|
55
|
+
stream: () => ReadableStream<Uint8Array>;
|
56
|
+
text: () => Promise<string>;
|
57
|
+
};
|
35
58
|
}[]>;
|
36
59
|
triggerInput: () => void;
|
37
60
|
handleChange: (event: Event) => Promise<void>;
|
@@ -43,8 +66,8 @@ declare const _default: import('vue').DefineComponent<{
|
|
43
66
|
beforeUpload?: (file: File) => boolean | Promise<File>;
|
44
67
|
onChange?: (fileList: UploadFile[]) => void;
|
45
68
|
}> & Readonly<{}>, {
|
46
|
-
multiple: boolean;
|
47
69
|
accept: string;
|
70
|
+
multiple: boolean;
|
48
71
|
maxCount: number;
|
49
72
|
showList: boolean;
|
50
73
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
@@ -55,8 +55,8 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
55
55
|
};
|
56
56
|
}>> & Readonly<{}>, {
|
57
57
|
type: "error" | "success" | "info" | "warning";
|
58
|
-
icon: boolean;
|
59
58
|
position: "top-left" | "top-right" | "bottom-left" | "bottom-right" | "top-center" | "bottom-center";
|
60
59
|
duration: number;
|
60
|
+
icon: boolean;
|
61
61
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
62
62
|
export default _default;
|
@@ -35,7 +35,7 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
35
35
|
onClose: () => void;
|
36
36
|
onOk: () => void;
|
37
37
|
onCancel: () => void;
|
38
|
-
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, ("
|
38
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, ("cancel" | "ok" | "update:visible")[], "cancel" | "ok" | "update:visible", import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
|
39
39
|
visible: {
|
40
40
|
type: BooleanConstructor;
|
41
41
|
required: true;
|
@@ -65,9 +65,9 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
65
65
|
default: boolean;
|
66
66
|
};
|
67
67
|
}>> & Readonly<{
|
68
|
-
"onUpdate:visible"?: (...args: any[]) => any;
|
69
|
-
onOk?: (...args: any[]) => any;
|
70
68
|
onCancel?: (...args: any[]) => any;
|
69
|
+
onOk?: (...args: any[]) => any;
|
70
|
+
"onUpdate:visible"?: (...args: any[]) => any;
|
71
71
|
}>, {
|
72
72
|
title: string;
|
73
73
|
okText: string;
|
package/package.json
CHANGED
@@ -1,43 +0,0 @@
|
|
1
|
-
export type MaybeUndefined<T> = T | undefined;
|
2
|
-
/**
|
3
|
-
* 字符串类型对象
|
4
|
-
*/
|
5
|
-
export type Recordable<T = any> = Record<string, T>;
|
6
|
-
export interface Fn<T = any> {
|
7
|
-
(...args: any[]): T;
|
8
|
-
}
|
9
|
-
declare const _default: import('vue').DefineComponent<{
|
10
|
-
alt?: string;
|
11
|
-
beforeUpload?: (file: File) => boolean | Promise<boolean>;
|
12
|
-
customUpload?: (files: File) => any;
|
13
|
-
getExtraData?: (file: File) => Promise<Recordable<any>> | Recordable<any>;
|
14
|
-
height?: number | string;
|
15
|
-
/** Only available when custom upload.
|
16
|
-
* @default false
|
17
|
-
*/
|
18
|
-
multiple?: boolean;
|
19
|
-
src?: string;
|
20
|
-
tip?: string;
|
21
|
-
width?: number | string;
|
22
|
-
uploadByImage?: (file: File) => any;
|
23
|
-
}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{
|
24
|
-
alt?: string;
|
25
|
-
beforeUpload?: (file: File) => boolean | Promise<boolean>;
|
26
|
-
customUpload?: (files: File) => any;
|
27
|
-
getExtraData?: (file: File) => Promise<Recordable<any>> | Recordable<any>;
|
28
|
-
height?: number | string;
|
29
|
-
/** Only available when custom upload.
|
30
|
-
* @default false
|
31
|
-
*/
|
32
|
-
multiple?: boolean;
|
33
|
-
src?: string;
|
34
|
-
tip?: string;
|
35
|
-
width?: number | string;
|
36
|
-
uploadByImage?: (file: File) => any;
|
37
|
-
}> & Readonly<{}>, {
|
38
|
-
height: number | string;
|
39
|
-
multiple: boolean;
|
40
|
-
tip: string;
|
41
|
-
width: number | string;
|
42
|
-
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
43
|
-
export default _default;
|