zc-lowcode 0.0.1
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 +5 -0
- package/dist/lowcode-editor.es.js +79541 -0
- package/dist/lowcode-editor.umd.js +79542 -0
- package/dist/style.css +154 -0
- package/dist/type.d.ts +28 -0
- package/package.json +60 -0
package/dist/style.css
ADDED
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
.tabs[data-v-0b793052] .ant-tabs-nav {
|
|
2
|
+
margin-bottom: 0 !important;
|
|
3
|
+
}
|
|
4
|
+
.tabs .widget-collapse ul[data-v-0b793052] {
|
|
5
|
+
padding: 0;
|
|
6
|
+
margin: 0;
|
|
7
|
+
display: flex;
|
|
8
|
+
flex-wrap: wrap;
|
|
9
|
+
border-left: 1px solid var(--colorBorderSecondary);
|
|
10
|
+
border-top: 1px solid var(--colorBorderSecondary);
|
|
11
|
+
}
|
|
12
|
+
.tabs .widget-collapse ul li[data-v-0b793052] {
|
|
13
|
+
height: 80px;
|
|
14
|
+
width: 33.33%;
|
|
15
|
+
cursor: move;
|
|
16
|
+
overflow: hidden;
|
|
17
|
+
display: flex;
|
|
18
|
+
flex-direction: column;
|
|
19
|
+
align-items: center;
|
|
20
|
+
justify-content: center;
|
|
21
|
+
border-right: 1px solid var(--colorBorderSecondary);
|
|
22
|
+
border-bottom: 1px solid var(--colorBorderSecondary);
|
|
23
|
+
background: var(--colorBgContainer);
|
|
24
|
+
transition: box-shadow 0.2s ease, -webkit-box-shadow 0.2s ease;
|
|
25
|
+
}
|
|
26
|
+
.tabs .widget-collapse ul li .widget-item-icon[data-v-0b793052] {
|
|
27
|
+
font-size: 20px;
|
|
28
|
+
color: var(--colorTextSecondary);
|
|
29
|
+
}
|
|
30
|
+
.tabs .widget-collapse ul li .widget-item-name[data-v-0b793052] {
|
|
31
|
+
margin-top: 8px;
|
|
32
|
+
white-space: nowrap;
|
|
33
|
+
text-overflow: ellipsis;
|
|
34
|
+
}
|
|
35
|
+
.tabs .widget-collapse ul li[data-v-0b793052]:hover {
|
|
36
|
+
box-shadow: 0 0 30px var(--colorBorder);
|
|
37
|
+
color: var(--colorPrimary);
|
|
38
|
+
}
|
|
39
|
+
.tabs .widget-collapse ul li:hover .widget-item-icon[data-v-0b793052] {
|
|
40
|
+
color: var(--colorPrimary);
|
|
41
|
+
}
|
|
42
|
+
.tabs .template-list[data-v-0b793052] {
|
|
43
|
+
padding: 0;
|
|
44
|
+
margin: 0;
|
|
45
|
+
list-style: none;
|
|
46
|
+
}
|
|
47
|
+
.tabs .template-list li[data-v-0b793052] {
|
|
48
|
+
border: 1px solid var(--colorBorderSecondary);
|
|
49
|
+
transition: box-shadow 0.2s ease, -webkit-box-shadow 0.2s ease;
|
|
50
|
+
margin: 10px;
|
|
51
|
+
}
|
|
52
|
+
.tabs .template-list li[data-v-0b793052]:hover {
|
|
53
|
+
box-shadow: 0 0 30px var(--colorBorder);
|
|
54
|
+
color: var(--colorPrimary);
|
|
55
|
+
}
|
|
56
|
+
.tabs .template-list li:hover .widget-item-icon[data-v-0b793052] {
|
|
57
|
+
color: var(--colorPrimary);
|
|
58
|
+
}
|
|
59
|
+
.tabs .template-list li .template-item-footer[data-v-0b793052] {
|
|
60
|
+
display: flex;
|
|
61
|
+
align-items: center;
|
|
62
|
+
justify-content: space-between;
|
|
63
|
+
padding: 8px;
|
|
64
|
+
}
|
|
65
|
+
.tabs .template-list li .template-item-footer .template-item-name[data-v-0b793052] {
|
|
66
|
+
overflow: hidden;
|
|
67
|
+
white-space: nowrap;
|
|
68
|
+
text-overflow: ellipsis;
|
|
69
|
+
}
|
|
70
|
+
.wrapper[data-v-8504a6dd] {
|
|
71
|
+
position: relative;
|
|
72
|
+
border: 0.5px dashed var(--colorBorderSecondary);
|
|
73
|
+
}
|
|
74
|
+
.wrapper .widget-toolbar[data-v-8504a6dd] {
|
|
75
|
+
display: none;
|
|
76
|
+
position: absolute;
|
|
77
|
+
bottom: -20px;
|
|
78
|
+
right: 0;
|
|
79
|
+
z-index: 1;
|
|
80
|
+
font-size: 12px;
|
|
81
|
+
color: #eee;
|
|
82
|
+
}
|
|
83
|
+
.wrapper .widget-toolbar .widget-name[data-v-8504a6dd] {
|
|
84
|
+
margin-right: 10px;
|
|
85
|
+
padding: 2px 10px;
|
|
86
|
+
border-radius: 4px;
|
|
87
|
+
background-color: var(--colorPrimary);
|
|
88
|
+
white-space: nowrap;
|
|
89
|
+
}
|
|
90
|
+
.wrapper .widget-toolbar .widget-actions[data-v-8504a6dd] {
|
|
91
|
+
padding: 2px 10px;
|
|
92
|
+
border-radius: 4px;
|
|
93
|
+
background-color: var(--colorPrimary);
|
|
94
|
+
}
|
|
95
|
+
.wrapper.actived[data-v-8504a6dd] {
|
|
96
|
+
border: 0.5px dashed var(--colorPrimary);
|
|
97
|
+
}
|
|
98
|
+
.wrapper.actived > .widget-toolbar[data-v-8504a6dd] {
|
|
99
|
+
display: flex;
|
|
100
|
+
flex-wrap: nowrap;
|
|
101
|
+
align-items: stretch;
|
|
102
|
+
}
|
|
103
|
+
.draggable[data-v-3fb66b3f] {
|
|
104
|
+
width: 100%;
|
|
105
|
+
height: 100%;
|
|
106
|
+
}
|
|
107
|
+
.empty[data-v-3fb66b3f] {
|
|
108
|
+
width: 100%;
|
|
109
|
+
height: 100%;
|
|
110
|
+
display: flex;
|
|
111
|
+
justify-content: center;
|
|
112
|
+
align-items: center;
|
|
113
|
+
color: var(--colorTextQuaternary);
|
|
114
|
+
}
|
|
115
|
+
.ace-editor[data-v-894885b6] {
|
|
116
|
+
min-height: 300px;
|
|
117
|
+
}
|
|
118
|
+
.designer-container[data-v-c3575626] {
|
|
119
|
+
overflow: auto;
|
|
120
|
+
padding: 10px;
|
|
121
|
+
flex: 1;
|
|
122
|
+
display: flex;
|
|
123
|
+
flex-direction: column;
|
|
124
|
+
}
|
|
125
|
+
.designer-container .device[data-v-c3575626] {
|
|
126
|
+
flex: 1;
|
|
127
|
+
margin: 0 auto;
|
|
128
|
+
}
|
|
129
|
+
.designer-container .device.Pc[data-v-c3575626] {
|
|
130
|
+
width: 100%;
|
|
131
|
+
height: 100%;
|
|
132
|
+
}
|
|
133
|
+
.designer-container .device.Pad[data-v-c3575626] {
|
|
134
|
+
width: 768px;
|
|
135
|
+
border-radius: 15px;
|
|
136
|
+
box-shadow: 0 0 1px 10px #495060;
|
|
137
|
+
margin: 2vh auto;
|
|
138
|
+
}
|
|
139
|
+
.designer-container .device.H5[data-v-c3575626] {
|
|
140
|
+
width: 375px;
|
|
141
|
+
border-radius: 15px;
|
|
142
|
+
box-shadow: 0 0 1px 10px #495060;
|
|
143
|
+
margin: 2vh auto;
|
|
144
|
+
}
|
|
145
|
+
.preview[data-v-c3575626] {
|
|
146
|
+
max-height: 90vh;
|
|
147
|
+
min-height: 10vh;
|
|
148
|
+
}
|
|
149
|
+
.content[data-v-c0b1e935] {
|
|
150
|
+
height: 100vh;
|
|
151
|
+
min-width: 795px;
|
|
152
|
+
display: flex;
|
|
153
|
+
flex-direction: column;
|
|
154
|
+
}
|
package/dist/type.d.ts
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
export type WidgetSchema = {
|
|
2
|
+
id: number;
|
|
3
|
+
type: string;
|
|
4
|
+
name: string;
|
|
5
|
+
icon?: any;
|
|
6
|
+
internal?: boolean;
|
|
7
|
+
hidden?: boolean;
|
|
8
|
+
component?: any;
|
|
9
|
+
setterComponent?: any;
|
|
10
|
+
options: any;
|
|
11
|
+
};
|
|
12
|
+
export type WidgetContainerSchema = WidgetSchema & {
|
|
13
|
+
children: Array<WidgetSchema | WidgetContainerSchema>;
|
|
14
|
+
};
|
|
15
|
+
export type WidgetPackage = {
|
|
16
|
+
type: string;
|
|
17
|
+
name: string;
|
|
18
|
+
widgetList: Array<WidgetSchema | WidgetContainerSchema>;
|
|
19
|
+
};
|
|
20
|
+
export type LowCodePage = {
|
|
21
|
+
id: number;
|
|
22
|
+
name: string;
|
|
23
|
+
previewImg?: string;
|
|
24
|
+
widgetList: Array<WidgetSchema | WidgetContainerSchema>;
|
|
25
|
+
options: {
|
|
26
|
+
backgroundColor: string;
|
|
27
|
+
};
|
|
28
|
+
};
|
package/package.json
ADDED
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "zc-lowcode",
|
|
3
|
+
"private": false,
|
|
4
|
+
"author": {
|
|
5
|
+
"name": "hezechang",
|
|
6
|
+
"email": "hezechang@gmail.com"
|
|
7
|
+
},
|
|
8
|
+
"keywords": [
|
|
9
|
+
"lowcode",
|
|
10
|
+
"lowcode-editor"
|
|
11
|
+
],
|
|
12
|
+
"version": "0.0.1",
|
|
13
|
+
"type": "module",
|
|
14
|
+
"main": "dist/lowcode-editor.umd.js",
|
|
15
|
+
"module": "dist/lowcode-editor.es.js",
|
|
16
|
+
"unpkg": "dist/lowcode-editor.umd.js",
|
|
17
|
+
"typings": "./dist/index.d.ts",
|
|
18
|
+
"exports": {
|
|
19
|
+
".": {
|
|
20
|
+
"types": "./dist/index.d.ts",
|
|
21
|
+
"import": "./dist/lowcode-editor.es.js",
|
|
22
|
+
"require": "./dist/lowcode-editor.umd.js"
|
|
23
|
+
},
|
|
24
|
+
"./*": [
|
|
25
|
+
"./",
|
|
26
|
+
"./*.d.ts"
|
|
27
|
+
]
|
|
28
|
+
},
|
|
29
|
+
"files": [
|
|
30
|
+
"dist/*"
|
|
31
|
+
],
|
|
32
|
+
"scripts": {
|
|
33
|
+
"dev": "vite",
|
|
34
|
+
"build": "vue-tsc -b && vite build",
|
|
35
|
+
"lib": "vite build --config vite-lib.config.ts",
|
|
36
|
+
"release": "tsc && npm publish --registry https://registry.npmjs.org"
|
|
37
|
+
},
|
|
38
|
+
"dependencies": {
|
|
39
|
+
"ace-builds": "^1.36.3",
|
|
40
|
+
"ant-design-vue": "4.x",
|
|
41
|
+
"vue": "^3.4.31",
|
|
42
|
+
"vue-i18n": "^10.0.1",
|
|
43
|
+
"vue-router": "4",
|
|
44
|
+
"vuedraggable": "^4.1.0"
|
|
45
|
+
},
|
|
46
|
+
"devDependencies": {
|
|
47
|
+
"@types/node": "^22.0.2",
|
|
48
|
+
"@vitejs/plugin-vue": "^5.0.5",
|
|
49
|
+
"@vitejs/plugin-vue-jsx": "^4.0.1",
|
|
50
|
+
"fast-glob": "^3.3.2",
|
|
51
|
+
"less": "^4.2.0",
|
|
52
|
+
"less-loader": "^12.2.0",
|
|
53
|
+
"typescript": "^5.2.2",
|
|
54
|
+
"unplugin-vue-components": "^0.27.4",
|
|
55
|
+
"vite": "^5.3.4",
|
|
56
|
+
"vite-plugin-dts": "^4.0.0-beta.2",
|
|
57
|
+
"vite-svg-loader": "^5.1.0",
|
|
58
|
+
"vue-tsc": "^2.0.24"
|
|
59
|
+
}
|
|
60
|
+
}
|