next-element-vue 0.3.2 → 0.3.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/dist/index.css +2 -1
- package/dist/index.js +850 -146
- package/dist/index.min.js +3 -3
- package/dist/index.umd.js +851 -152
- package/dist/index.umd.min.js +3 -3
- package/dist/packages/components/dialog/index.d.ts +9 -0
- package/dist/packages/components/dialog/src/index.d.ts +9 -0
- package/dist/packages/components/labelimg/index.d.ts +0 -9
- package/dist/packages/components/labelimg/src/index.d.ts +0 -9
- package/dist/packages/components/labelme/index.d.ts +57 -0
- package/dist/packages/components/labelme/src/config.d.ts +4 -0
- package/dist/packages/components/labelme/src/hooks/canvas-content.d.ts +40 -0
- package/dist/packages/components/labelme/src/index.d.ts +57 -0
- package/dist/packages/components/labelme/src/widgets/canvas-context.d.ts +34 -0
- package/dist/packages/components/labelme/src/widgets/header-tool.d.ts +35 -0
- package/dist/packages/components.d.ts +1 -0
- package/dist/packages/hooks/use-locale/index.d.ts +3 -0
- package/dist/packages/locale/lang/en.d.ts +6 -0
- package/dist/packages/locale/lang/zh-cn.d.ts +6 -0
- package/dist/packages/locale/lang/zh-tw.d.ts +3 -0
- package/dist/packages/utils/theme.d.ts +1 -0
- package/package.json +2 -2
|
@@ -24,6 +24,10 @@ export declare const NextDialog: import("../../utils/install").SFCWithInstall<im
|
|
|
24
24
|
type: BooleanConstructor;
|
|
25
25
|
default: boolean;
|
|
26
26
|
};
|
|
27
|
+
showClose: {
|
|
28
|
+
type: BooleanConstructor;
|
|
29
|
+
default: boolean;
|
|
30
|
+
};
|
|
27
31
|
appendToBody: {
|
|
28
32
|
type: BooleanConstructor;
|
|
29
33
|
default: boolean;
|
|
@@ -73,6 +77,10 @@ export declare const NextDialog: import("../../utils/install").SFCWithInstall<im
|
|
|
73
77
|
type: BooleanConstructor;
|
|
74
78
|
default: boolean;
|
|
75
79
|
};
|
|
80
|
+
showClose: {
|
|
81
|
+
type: BooleanConstructor;
|
|
82
|
+
default: boolean;
|
|
83
|
+
};
|
|
76
84
|
appendToBody: {
|
|
77
85
|
type: BooleanConstructor;
|
|
78
86
|
default: boolean;
|
|
@@ -106,6 +114,7 @@ export declare const NextDialog: import("../../utils/install").SFCWithInstall<im
|
|
|
106
114
|
fullscreenBtn: boolean;
|
|
107
115
|
width: string | number;
|
|
108
116
|
closeOnClickModal: boolean;
|
|
117
|
+
showClose: boolean;
|
|
109
118
|
appendToBody: boolean;
|
|
110
119
|
draggable: boolean;
|
|
111
120
|
zoomSize: boolean;
|
|
@@ -23,6 +23,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
23
23
|
type: BooleanConstructor;
|
|
24
24
|
default: boolean;
|
|
25
25
|
};
|
|
26
|
+
showClose: {
|
|
27
|
+
type: BooleanConstructor;
|
|
28
|
+
default: boolean;
|
|
29
|
+
};
|
|
26
30
|
appendToBody: {
|
|
27
31
|
type: BooleanConstructor;
|
|
28
32
|
default: boolean;
|
|
@@ -72,6 +76,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
72
76
|
type: BooleanConstructor;
|
|
73
77
|
default: boolean;
|
|
74
78
|
};
|
|
79
|
+
showClose: {
|
|
80
|
+
type: BooleanConstructor;
|
|
81
|
+
default: boolean;
|
|
82
|
+
};
|
|
75
83
|
appendToBody: {
|
|
76
84
|
type: BooleanConstructor;
|
|
77
85
|
default: boolean;
|
|
@@ -105,6 +113,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
105
113
|
fullscreenBtn: boolean;
|
|
106
114
|
width: string | number;
|
|
107
115
|
closeOnClickModal: boolean;
|
|
116
|
+
showClose: boolean;
|
|
108
117
|
appendToBody: boolean;
|
|
109
118
|
draggable: boolean;
|
|
110
119
|
zoomSize: boolean;
|
|
@@ -8,10 +8,6 @@ export declare const NextLabelimg: import("../../utils/install").SFCWithInstall<
|
|
|
8
8
|
type: import("vue").PropType<import("vue").CSSProperties>;
|
|
9
9
|
default: () => {};
|
|
10
10
|
};
|
|
11
|
-
rowKey: {
|
|
12
|
-
type: StringConstructor;
|
|
13
|
-
default: string;
|
|
14
|
-
};
|
|
15
11
|
options: {
|
|
16
12
|
type: ObjectConstructor;
|
|
17
13
|
default: () => {};
|
|
@@ -33,10 +29,6 @@ export declare const NextLabelimg: import("../../utils/install").SFCWithInstall<
|
|
|
33
29
|
type: import("vue").PropType<import("vue").CSSProperties>;
|
|
34
30
|
default: () => {};
|
|
35
31
|
};
|
|
36
|
-
rowKey: {
|
|
37
|
-
type: StringConstructor;
|
|
38
|
-
default: string;
|
|
39
|
-
};
|
|
40
32
|
options: {
|
|
41
33
|
type: ObjectConstructor;
|
|
42
34
|
default: () => {};
|
|
@@ -57,7 +49,6 @@ export declare const NextLabelimg: import("../../utils/install").SFCWithInstall<
|
|
|
57
49
|
}, {
|
|
58
50
|
className: string;
|
|
59
51
|
style: import("vue").CSSProperties;
|
|
60
|
-
rowKey: string;
|
|
61
52
|
options: Record<string, any>;
|
|
62
53
|
classes: unknown[];
|
|
63
54
|
data: any[];
|
|
@@ -8,10 +8,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
8
8
|
type: PropType<CSSProperties>;
|
|
9
9
|
default: () => {};
|
|
10
10
|
};
|
|
11
|
-
rowKey: {
|
|
12
|
-
type: StringConstructor;
|
|
13
|
-
default: string;
|
|
14
|
-
};
|
|
15
11
|
options: {
|
|
16
12
|
type: ObjectConstructor;
|
|
17
13
|
default: () => {};
|
|
@@ -33,10 +29,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
33
29
|
type: PropType<CSSProperties>;
|
|
34
30
|
default: () => {};
|
|
35
31
|
};
|
|
36
|
-
rowKey: {
|
|
37
|
-
type: StringConstructor;
|
|
38
|
-
default: string;
|
|
39
|
-
};
|
|
40
32
|
options: {
|
|
41
33
|
type: ObjectConstructor;
|
|
42
34
|
default: () => {};
|
|
@@ -57,7 +49,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
57
49
|
}, {
|
|
58
50
|
className: string;
|
|
59
51
|
style: CSSProperties;
|
|
60
|
-
rowKey: string;
|
|
61
52
|
options: Record<string, any>;
|
|
62
53
|
classes: unknown[];
|
|
63
54
|
data: any[];
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import './src/index.scss';
|
|
2
|
+
export declare const NextLabelme: import("../../utils/install").SFCWithInstall<import("vue").DefineComponent<{
|
|
3
|
+
className: {
|
|
4
|
+
type: StringConstructor;
|
|
5
|
+
default: string;
|
|
6
|
+
};
|
|
7
|
+
style: {
|
|
8
|
+
type: import("vue").PropType<import("vue").CSSProperties>;
|
|
9
|
+
default: () => {};
|
|
10
|
+
};
|
|
11
|
+
options: {
|
|
12
|
+
type: ObjectConstructor;
|
|
13
|
+
default: () => {};
|
|
14
|
+
};
|
|
15
|
+
classes: {
|
|
16
|
+
type: ArrayConstructor;
|
|
17
|
+
default: () => any[];
|
|
18
|
+
};
|
|
19
|
+
data: {
|
|
20
|
+
type: import("vue").PropType<any[]>;
|
|
21
|
+
default: () => any[];
|
|
22
|
+
};
|
|
23
|
+
}, () => any, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("change" | "save" | "edit-polygon" | "prev-click" | "next-click")[], "change" | "save" | "edit-polygon" | "prev-click" | "next-click", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
24
|
+
className: {
|
|
25
|
+
type: StringConstructor;
|
|
26
|
+
default: string;
|
|
27
|
+
};
|
|
28
|
+
style: {
|
|
29
|
+
type: import("vue").PropType<import("vue").CSSProperties>;
|
|
30
|
+
default: () => {};
|
|
31
|
+
};
|
|
32
|
+
options: {
|
|
33
|
+
type: ObjectConstructor;
|
|
34
|
+
default: () => {};
|
|
35
|
+
};
|
|
36
|
+
classes: {
|
|
37
|
+
type: ArrayConstructor;
|
|
38
|
+
default: () => any[];
|
|
39
|
+
};
|
|
40
|
+
data: {
|
|
41
|
+
type: import("vue").PropType<any[]>;
|
|
42
|
+
default: () => any[];
|
|
43
|
+
};
|
|
44
|
+
}>> & {
|
|
45
|
+
onChange?: (...args: any[]) => any;
|
|
46
|
+
onSave?: (...args: any[]) => any;
|
|
47
|
+
"onEdit-polygon"?: (...args: any[]) => any;
|
|
48
|
+
"onPrev-click"?: (...args: any[]) => any;
|
|
49
|
+
"onNext-click"?: (...args: any[]) => any;
|
|
50
|
+
}, {
|
|
51
|
+
className: string;
|
|
52
|
+
style: import("vue").CSSProperties;
|
|
53
|
+
options: Record<string, any>;
|
|
54
|
+
classes: unknown[];
|
|
55
|
+
data: any[];
|
|
56
|
+
}, {}>> & Record<string, any>;
|
|
57
|
+
export default NextLabelme;
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
export interface CreateRectCanvasProps {
|
|
2
|
+
canvasWidth: number;
|
|
3
|
+
canvasHeight: number;
|
|
4
|
+
}
|
|
5
|
+
export interface DrawBaseCanvasProps extends CreateRectCanvasProps {
|
|
6
|
+
canvas?: HTMLCanvasElement;
|
|
7
|
+
ctx: CanvasRenderingContext2D;
|
|
8
|
+
image: HTMLImageElement;
|
|
9
|
+
scaleFactor?: number;
|
|
10
|
+
paths?: any[];
|
|
11
|
+
}
|
|
12
|
+
export declare const printsToPath: (vertexes: [number, number][]) => Path2D;
|
|
13
|
+
export declare const isPointOnLineSegment: (px: number, py: number, vertexes: [number, number][], ctx: CanvasRenderingContext2D) => number;
|
|
14
|
+
export declare const isPointInCircle: (mouseX: number, mouseY: number, circleX: number, circleY: number, radius: number) => boolean;
|
|
15
|
+
/**
|
|
16
|
+
* 点位数据去重
|
|
17
|
+
* @param vertexes
|
|
18
|
+
* @returns
|
|
19
|
+
*/
|
|
20
|
+
export declare const vertexesUnique: (vertexes: [number, number][]) => any[];
|
|
21
|
+
export declare const colors: string[];
|
|
22
|
+
export declare class CreateDrawCanvas {
|
|
23
|
+
canvas: HTMLCanvasElement;
|
|
24
|
+
ctx: CanvasRenderingContext2D;
|
|
25
|
+
image: HTMLImageElement;
|
|
26
|
+
canvasWidth: number;
|
|
27
|
+
canvasHeight: number;
|
|
28
|
+
private paths;
|
|
29
|
+
private editDrawPolygon;
|
|
30
|
+
private createPolygonVertexes;
|
|
31
|
+
private editVertexes;
|
|
32
|
+
private editPolygonObservers;
|
|
33
|
+
constructor(options: DrawBaseCanvasProps);
|
|
34
|
+
private notifyObservers;
|
|
35
|
+
updatePolygon(callback: (vertexes: [number, number][]) => void): void;
|
|
36
|
+
drawPolygons(paths: any[]): void;
|
|
37
|
+
initCanvas: () => void;
|
|
38
|
+
render: () => void;
|
|
39
|
+
destroyed(): void;
|
|
40
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import type { CSSProperties, PropType } from 'vue';
|
|
2
|
+
declare const _default: import("vue").DefineComponent<{
|
|
3
|
+
className: {
|
|
4
|
+
type: StringConstructor;
|
|
5
|
+
default: string;
|
|
6
|
+
};
|
|
7
|
+
style: {
|
|
8
|
+
type: PropType<CSSProperties>;
|
|
9
|
+
default: () => {};
|
|
10
|
+
};
|
|
11
|
+
options: {
|
|
12
|
+
type: ObjectConstructor;
|
|
13
|
+
default: () => {};
|
|
14
|
+
};
|
|
15
|
+
classes: {
|
|
16
|
+
type: ArrayConstructor;
|
|
17
|
+
default: () => any[];
|
|
18
|
+
};
|
|
19
|
+
data: {
|
|
20
|
+
type: PropType<any[]>;
|
|
21
|
+
default: () => any[];
|
|
22
|
+
};
|
|
23
|
+
}, () => any, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("change" | "save" | "edit-polygon" | "prev-click" | "next-click")[], "change" | "save" | "edit-polygon" | "prev-click" | "next-click", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
24
|
+
className: {
|
|
25
|
+
type: StringConstructor;
|
|
26
|
+
default: string;
|
|
27
|
+
};
|
|
28
|
+
style: {
|
|
29
|
+
type: PropType<CSSProperties>;
|
|
30
|
+
default: () => {};
|
|
31
|
+
};
|
|
32
|
+
options: {
|
|
33
|
+
type: ObjectConstructor;
|
|
34
|
+
default: () => {};
|
|
35
|
+
};
|
|
36
|
+
classes: {
|
|
37
|
+
type: ArrayConstructor;
|
|
38
|
+
default: () => any[];
|
|
39
|
+
};
|
|
40
|
+
data: {
|
|
41
|
+
type: PropType<any[]>;
|
|
42
|
+
default: () => any[];
|
|
43
|
+
};
|
|
44
|
+
}>> & {
|
|
45
|
+
onChange?: (...args: any[]) => any;
|
|
46
|
+
onSave?: (...args: any[]) => any;
|
|
47
|
+
"onEdit-polygon"?: (...args: any[]) => any;
|
|
48
|
+
"onPrev-click"?: (...args: any[]) => any;
|
|
49
|
+
"onNext-click"?: (...args: any[]) => any;
|
|
50
|
+
}, {
|
|
51
|
+
className: string;
|
|
52
|
+
style: CSSProperties;
|
|
53
|
+
options: Record<string, any>;
|
|
54
|
+
classes: unknown[];
|
|
55
|
+
data: any[];
|
|
56
|
+
}, {}>;
|
|
57
|
+
export default _default;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{
|
|
2
|
+
classes: {
|
|
3
|
+
type: ArrayConstructor;
|
|
4
|
+
default: () => any[];
|
|
5
|
+
};
|
|
6
|
+
contextClientHeight: {
|
|
7
|
+
type: NumberConstructor;
|
|
8
|
+
default: any;
|
|
9
|
+
};
|
|
10
|
+
rowInfo: {
|
|
11
|
+
type: ObjectConstructor;
|
|
12
|
+
default: () => {};
|
|
13
|
+
};
|
|
14
|
+
}, () => any, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "editPolygon"[], "editPolygon", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
15
|
+
classes: {
|
|
16
|
+
type: ArrayConstructor;
|
|
17
|
+
default: () => any[];
|
|
18
|
+
};
|
|
19
|
+
contextClientHeight: {
|
|
20
|
+
type: NumberConstructor;
|
|
21
|
+
default: any;
|
|
22
|
+
};
|
|
23
|
+
rowInfo: {
|
|
24
|
+
type: ObjectConstructor;
|
|
25
|
+
default: () => {};
|
|
26
|
+
};
|
|
27
|
+
}>> & {
|
|
28
|
+
onEditPolygon?: (...args: any[]) => any;
|
|
29
|
+
}, {
|
|
30
|
+
classes: unknown[];
|
|
31
|
+
contextClientHeight: number;
|
|
32
|
+
rowInfo: Record<string, any>;
|
|
33
|
+
}, {}>;
|
|
34
|
+
export default _default;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{
|
|
2
|
+
isFullscreen: {
|
|
3
|
+
type: BooleanConstructor;
|
|
4
|
+
default: boolean;
|
|
5
|
+
};
|
|
6
|
+
imageIndex: {
|
|
7
|
+
type: NumberConstructor;
|
|
8
|
+
default: number;
|
|
9
|
+
};
|
|
10
|
+
imageLength: {
|
|
11
|
+
type: NumberConstructor;
|
|
12
|
+
default: number;
|
|
13
|
+
};
|
|
14
|
+
}, () => any, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("fullscreen" | "save")[], "fullscreen" | "save", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
15
|
+
isFullscreen: {
|
|
16
|
+
type: BooleanConstructor;
|
|
17
|
+
default: boolean;
|
|
18
|
+
};
|
|
19
|
+
imageIndex: {
|
|
20
|
+
type: NumberConstructor;
|
|
21
|
+
default: number;
|
|
22
|
+
};
|
|
23
|
+
imageLength: {
|
|
24
|
+
type: NumberConstructor;
|
|
25
|
+
default: number;
|
|
26
|
+
};
|
|
27
|
+
}>> & {
|
|
28
|
+
onFullscreen?: (...args: any[]) => any;
|
|
29
|
+
onSave?: (...args: any[]) => any;
|
|
30
|
+
}, {
|
|
31
|
+
isFullscreen: boolean;
|
|
32
|
+
imageIndex: number;
|
|
33
|
+
imageLength: number;
|
|
34
|
+
}, {}>;
|
|
35
|
+
export default _default;
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
*/
|
|
8
8
|
export declare function useChangeColor(): {
|
|
9
9
|
hexToRgb: (str: string) => any;
|
|
10
|
+
hexToRgba: (str: string, alpha?: number) => any;
|
|
10
11
|
rgbToHex: (r: any, g: any, b: any) => string;
|
|
11
12
|
getDarkColor: (color: string, level: number) => string;
|
|
12
13
|
getLightColor: (color: string, level: number) => string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "next-element-vue",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.4",
|
|
4
4
|
"author": {
|
|
5
5
|
"name": "huangteng",
|
|
6
6
|
"email": "htengweb@163.com"
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"@tensorflow/tfjs": "^4.11.0",
|
|
38
38
|
"@types/lodash-es": "^4.17.9",
|
|
39
39
|
"@vueuse/core": "^10.4.1",
|
|
40
|
-
"element-plus": "^2.
|
|
40
|
+
"element-plus": "^2.8.0",
|
|
41
41
|
"flv.js": "^1.6.2",
|
|
42
42
|
"lodash-es": "^4.17.21",
|
|
43
43
|
"mpegts.js": "^1.7.3",
|