@vyr/element-plus-browser 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/package.json +26 -0
- package/src/common/event.ts +9 -0
- package/src/common/index.ts +2 -0
- package/src/common/provider.ts +14 -0
- package/src/index.ts +3 -0
- package/src/locale/Language.ts +10 -0
- package/src/locale/LanguageProvider.ts +427 -0
- package/src/locale/index.ts +2 -0
- package/src/option/Button.ts +38 -0
- package/src/option/Column.ts +19 -0
- package/src/option/Dialog.ts +10 -0
- package/src/option/Form.ts +16 -0
- package/src/option/Input.ts +18 -0
- package/src/option/Menu.ts +31 -0
- package/src/option/Row.ts +19 -0
- package/src/option/index.ts +7 -0
- package/src/preset/ElTable.ts +425 -0
- package/src/preset/index.ts +14 -0
- package/src/service/global/index.ts +1 -0
- package/src/service/global/scripts/index.ts +60 -0
- package/src/service/index.ts +53 -0
- package/src/service/inspector/ElButton.vue +98 -0
- package/src/service/inspector/ElCascader.vue +98 -0
- package/src/service/inspector/ElCheckbox.vue +91 -0
- package/src/service/inspector/ElCol.vue +32 -0
- package/src/service/inspector/ElDatePicker.vue +92 -0
- package/src/service/inspector/ElDialog.vue +33 -0
- package/src/service/inspector/ElForm.vue +44 -0
- package/src/service/inspector/ElInput.vue +134 -0
- package/src/service/inspector/ElInputNumber.vue +78 -0
- package/src/service/inspector/ElMenu.vue +60 -0
- package/src/service/inspector/ElMenuItem.vue +46 -0
- package/src/service/inspector/ElPagination.vue +103 -0
- package/src/service/inspector/ElRadio.vue +91 -0
- package/src/service/inspector/ElRow.vue +36 -0
- package/src/service/inspector/ElSelect.vue +98 -0
- package/src/service/inspector/ElSubMenu.vue +32 -0
- package/src/service/inspector/ElSwitch.vue +58 -0
- package/src/service/inspector/ElTable.vue +47 -0
- package/src/service/inspector/ElTableColumn.vue +107 -0
- package/src/service/inspector/VueViewer.vue +65 -0
- package/src/service/inspector/index.ts +23 -0
- package/src/shims-vue.d.ts +10 -0
package/package.json
ADDED
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@vyr/element-plus-browser",
|
|
3
|
+
"version": "0.0.1",
|
|
4
|
+
"description": "",
|
|
5
|
+
"main": "./src/index.ts",
|
|
6
|
+
"author": "",
|
|
7
|
+
"license": "MIT",
|
|
8
|
+
"dependencies": {
|
|
9
|
+
"@vyr/locale": "0.0.1",
|
|
10
|
+
"@vyr/runtime": "0.0.1",
|
|
11
|
+
"@vyr/engine": "0.0.1",
|
|
12
|
+
"@vyr/design": "0.0.1",
|
|
13
|
+
"@vyr/builtin": "0.0.1",
|
|
14
|
+
"@vyr/vue": "0.0.1",
|
|
15
|
+
"@vyr/element-plus": "0.0.1",
|
|
16
|
+
"vue": "3.5.22"
|
|
17
|
+
},
|
|
18
|
+
"files": [
|
|
19
|
+
"package.json",
|
|
20
|
+
"src/"
|
|
21
|
+
],
|
|
22
|
+
"vyr": {
|
|
23
|
+
"type": "browser",
|
|
24
|
+
"order": 1001
|
|
25
|
+
}
|
|
26
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Descriptor } from "@vyr/engine";
|
|
2
|
+
import { ElInputDescriptor, ElPaginationDescriptor } from "@vyr/element-plus";
|
|
3
|
+
|
|
4
|
+
const events = [
|
|
5
|
+
{ ids: ['input', 'clear'], ignore: (descriptor: Descriptor) => descriptor.type !== ElInputDescriptor.type },
|
|
6
|
+
{ ids: ['change'], ignore: (descriptor: Descriptor) => descriptor.type !== ElPaginationDescriptor.type },
|
|
7
|
+
]
|
|
8
|
+
|
|
9
|
+
export { events }
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { provide, inject, Ref } from "vue";
|
|
2
|
+
import { Descriptor } from "@vyr/engine";
|
|
3
|
+
|
|
4
|
+
const providerKey = Symbol()
|
|
5
|
+
|
|
6
|
+
const providerDescriptor = (descriptor: Ref<Descriptor | null>) => {
|
|
7
|
+
provide(providerKey, descriptor)
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
const useDescriptor = <T extends Descriptor = Descriptor>() => {
|
|
11
|
+
return inject(providerKey) as Ref<T>
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
export { providerDescriptor, useDescriptor }
|
package/src/index.ts
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Locale } from "@vyr/locale";
|
|
2
|
+
import { zhCnLanguageProvider, ZhCNLanguageProvider } from "./LanguageProvider";
|
|
3
|
+
|
|
4
|
+
Locale.register(zhCnLanguageProvider)
|
|
5
|
+
|
|
6
|
+
const language = Locale.getLanguage<ZhCNLanguageProvider>(zhCnLanguageProvider.name)
|
|
7
|
+
|
|
8
|
+
export {
|
|
9
|
+
language
|
|
10
|
+
}
|
|
@@ -0,0 +1,427 @@
|
|
|
1
|
+
import { LanguageProvider } from '@vyr/locale'
|
|
2
|
+
|
|
3
|
+
interface ZhCNLanguageProvider extends LanguageProvider {
|
|
4
|
+
'descriptor.type.ElButton': string
|
|
5
|
+
'descriptor.type.ElRow': string
|
|
6
|
+
'descriptor.type.ElCol': string
|
|
7
|
+
'descriptor.type.ElInput': string
|
|
8
|
+
'descriptor.type.ElInputNumber': string
|
|
9
|
+
'descriptor.type.ElSelect': string
|
|
10
|
+
'descriptor.type.ElCascader': string
|
|
11
|
+
'descriptor.type.ElDatePicker': string
|
|
12
|
+
'descriptor.type.ElSwitch': string
|
|
13
|
+
'descriptor.type.ElCheckbox': string
|
|
14
|
+
'descriptor.type.ElRadio': string
|
|
15
|
+
'descriptor.type.ElForm': string
|
|
16
|
+
'descriptor.type.ElTable': string
|
|
17
|
+
'descriptor.type.ElTableColumn': string
|
|
18
|
+
'descriptor.type.ElPagination': string
|
|
19
|
+
'descriptor.type.ElDialog': string
|
|
20
|
+
'descriptor.type.ElMenu': string
|
|
21
|
+
'descriptor.type.ElSubMenu': string
|
|
22
|
+
'descriptor.type.ElMenuItem': string
|
|
23
|
+
|
|
24
|
+
'option.ElButton.type.default': string
|
|
25
|
+
'option.ElButton.type.primary': string
|
|
26
|
+
'option.ElButton.type.success': string
|
|
27
|
+
'option.ElButton.type.info': string
|
|
28
|
+
'option.ElButton.type.warning': string
|
|
29
|
+
'option.ElButton.type.danger': string
|
|
30
|
+
'option.ElButton.size.default': string
|
|
31
|
+
'option.ElButton.size.small': string
|
|
32
|
+
'option.ElButton.size.large': string
|
|
33
|
+
'option.ElButton.shape.rect': string
|
|
34
|
+
'option.ElButton.shape.circle': string
|
|
35
|
+
'option.ElButton.shape.roundedRectangle': string
|
|
36
|
+
'option.ElButton.state.enable': string
|
|
37
|
+
'option.ElButton.state.loading': string
|
|
38
|
+
'option.ElButton.state.disable': string
|
|
39
|
+
'option.ElButton.plain.default': string
|
|
40
|
+
'option.ElButton.plain.simple': string
|
|
41
|
+
|
|
42
|
+
'option.ElRow.justify.start': string
|
|
43
|
+
'option.ElRow.justify.end': string
|
|
44
|
+
'option.ElRow.justify.center': string
|
|
45
|
+
'option.ElRow.justify.space-between': string
|
|
46
|
+
'option.ElRow.justify.space-around': string
|
|
47
|
+
|
|
48
|
+
'option.ElRow.align.top': string
|
|
49
|
+
'option.ElRow.align.middle': string
|
|
50
|
+
'option.ElRow.align.bottom': string
|
|
51
|
+
|
|
52
|
+
'option.ElColumn.type.default': string
|
|
53
|
+
'option.ElColumn.type.index': string
|
|
54
|
+
'option.ElColumn.type.expand': string
|
|
55
|
+
'option.ElColumn.type.selection': string
|
|
56
|
+
|
|
57
|
+
'option.ElColumn.fixed.close': string
|
|
58
|
+
'option.ElColumn.fixed.left': string
|
|
59
|
+
'option.ElColumn.fixed.right': string
|
|
60
|
+
|
|
61
|
+
'option.ElForm.inline.disable': string
|
|
62
|
+
'option.ElForm.inline.enable': string
|
|
63
|
+
|
|
64
|
+
'option.ElForm.position.left': string
|
|
65
|
+
'option.ElForm.position.right': string
|
|
66
|
+
'option.ElForm.position.top': string
|
|
67
|
+
|
|
68
|
+
'option.ElInput.switch.open': string
|
|
69
|
+
'option.ElInput.switch.close': string
|
|
70
|
+
|
|
71
|
+
'option.ElInput.type.text': string
|
|
72
|
+
'option.ElInput.type.number': string
|
|
73
|
+
'option.ElInput.type.textarea': string
|
|
74
|
+
'option.ElInput.type.password': string
|
|
75
|
+
|
|
76
|
+
'option.ElDialog.closeOnClickModal.true': string
|
|
77
|
+
'option.ElDialog.closeOnClickModal.false': string
|
|
78
|
+
|
|
79
|
+
'option.ElMenu.mode.horizontal': string
|
|
80
|
+
'option.ElMenu.mode.vertical': string
|
|
81
|
+
|
|
82
|
+
'preset.Interaction.id.input': string
|
|
83
|
+
'preset.Interaction.id.clear': string
|
|
84
|
+
'preset.Interaction.id.change': string
|
|
85
|
+
|
|
86
|
+
'preset.ElTable.list': string
|
|
87
|
+
'preset.ElTable.list.url': string
|
|
88
|
+
'preset.ElTable.list.form': string
|
|
89
|
+
'preset.ElTable.list.pagination': string
|
|
90
|
+
'preset.ElTable.list.dataset': string
|
|
91
|
+
|
|
92
|
+
'preset.ElTable.reset': string
|
|
93
|
+
|
|
94
|
+
'preset.ElTable.edit': string
|
|
95
|
+
'preset.ElTable.edit.url': string
|
|
96
|
+
'preset.ElTable.edit.dataset': string
|
|
97
|
+
'preset.ElTable.edit.dialog': string
|
|
98
|
+
'preset.ElTable.edit.dialog.title': string
|
|
99
|
+
|
|
100
|
+
'preset.ElTable.create': string
|
|
101
|
+
'preset.ElTable.create.dataset': string
|
|
102
|
+
'preset.ElTable.create.dialog': string
|
|
103
|
+
'preset.ElTable.create.dialog.title': string
|
|
104
|
+
|
|
105
|
+
'preset.ElTable.delete': string
|
|
106
|
+
'preset.ElTable.delete.url': string
|
|
107
|
+
|
|
108
|
+
'preset.ElTable.submit': string
|
|
109
|
+
'preset.ElTable.submit.url': string
|
|
110
|
+
'preset.ElTable.submit.form': string
|
|
111
|
+
'preset.ElTable.submit.dialog': string
|
|
112
|
+
|
|
113
|
+
'preset.ElTable.close': string
|
|
114
|
+
'preset.ElTable.close.dialog': string
|
|
115
|
+
|
|
116
|
+
'inspector.ElButton.type': string
|
|
117
|
+
'inspector.ElButton.text': string
|
|
118
|
+
'inspector.ElButton.size': string
|
|
119
|
+
'inspector.ElButton.shape': string
|
|
120
|
+
'inspector.ElButton.state': string
|
|
121
|
+
'inspector.ElButton.plain': string
|
|
122
|
+
|
|
123
|
+
'inspector.ElRow.gutter': string
|
|
124
|
+
'inspector.ElRow.justify': string
|
|
125
|
+
'inspector.ElRow.align': string
|
|
126
|
+
|
|
127
|
+
'inspector.ElCol.span': string
|
|
128
|
+
'inspector.ElCol.offset': string
|
|
129
|
+
|
|
130
|
+
'inspector.ElForm.inline': string
|
|
131
|
+
'inspector.ElForm.disabled': string
|
|
132
|
+
'inspector.ElForm.label.position': string
|
|
133
|
+
'inspector.ElForm.label.width': string
|
|
134
|
+
|
|
135
|
+
'inspector.ElFormItem.modelValue': string
|
|
136
|
+
'inspector.ElFormItem.placeholder': string
|
|
137
|
+
'inspector.ElFormItem.columnName': string
|
|
138
|
+
'inspector.ElFormItem.columnComment': string
|
|
139
|
+
'inspector.ElFormItem.columnType': string
|
|
140
|
+
'inspector.ElFormItem.required': string
|
|
141
|
+
|
|
142
|
+
'inspector.ElFormItem.options': string
|
|
143
|
+
'inspector.ElFormItem.label': string
|
|
144
|
+
'inspector.ElFormItem.value': string
|
|
145
|
+
'inspector.ElFormItem.border': string
|
|
146
|
+
'inspector.ElFormItem.readonly': string
|
|
147
|
+
'inspector.ElFormItem.disabled': string
|
|
148
|
+
'inspector.ElFormItem.clearable': string
|
|
149
|
+
'inspector.ElFormItem.rows': string
|
|
150
|
+
'inspector.ElFormItem.step': string
|
|
151
|
+
'inspector.ElFormItem.maxlength': string
|
|
152
|
+
'inspector.ElFormItem.minlength': string
|
|
153
|
+
'inspector.ElFormItem.autofocus': string
|
|
154
|
+
'inspector.ElFormItem.showWordLimit': string
|
|
155
|
+
'inspector.ElFormItem.showPassword': string
|
|
156
|
+
'inspector.ElFormItem.min': string
|
|
157
|
+
'inspector.ElFormItem.max': string
|
|
158
|
+
'inspector.ElFormItem.loading': string
|
|
159
|
+
|
|
160
|
+
'inspector.ElInput.type': string
|
|
161
|
+
'inspector.ElDatePicker.type': string
|
|
162
|
+
'inspector.ElDatePicker.format': string
|
|
163
|
+
|
|
164
|
+
'inspector.ElTable.border': string
|
|
165
|
+
'inspector.ElTable.stripe': string
|
|
166
|
+
'inspector.ElTable.showHeader': string
|
|
167
|
+
'inspector.ElTable.fit': string
|
|
168
|
+
|
|
169
|
+
'inspector.ElTableColumn.columnName': string
|
|
170
|
+
'inspector.ElTableColumn.columnComment': string
|
|
171
|
+
'inspector.ElTableColumn.columnWidth': string
|
|
172
|
+
'inspector.ElTableColumn.columnType': string
|
|
173
|
+
'inspector.ElTableColumn.columnFixed': string
|
|
174
|
+
'inspector.ElTableColumn.columnAlign': string
|
|
175
|
+
'inspector.ElTableColumn.columnTooltip': string
|
|
176
|
+
'inspector.ElTableColumn.formattingScript': string
|
|
177
|
+
'inspector.ElTableColumn.formattingDataset': string
|
|
178
|
+
'inspector.ElTableColumn.formattingLabel': string
|
|
179
|
+
'inspector.ElTableColumn.formattingValue': string
|
|
180
|
+
'inspector.ElTableColumn.formattingSeparator': string
|
|
181
|
+
|
|
182
|
+
'inspector.ElPagination.total': string
|
|
183
|
+
'inspector.ElPagination.currentPage': string
|
|
184
|
+
'inspector.ElPagination.pageSize': string
|
|
185
|
+
'inspector.ElPagination.pageSizes': string
|
|
186
|
+
'inspector.ElPagination.background': string
|
|
187
|
+
'inspector.ElPagination.layoutSizes': string
|
|
188
|
+
'inspector.ElPagination.layoutPrev': string
|
|
189
|
+
'inspector.ElPagination.layoutPager': string
|
|
190
|
+
'inspector.ElPagination.layoutNext': string
|
|
191
|
+
'inspector.ElPagination.layoutJumper': string
|
|
192
|
+
'inspector.ElPagination.layoutArrow': string
|
|
193
|
+
'inspector.ElPagination.layoutTotal': string
|
|
194
|
+
|
|
195
|
+
'inspector.ElDialog.title': string
|
|
196
|
+
'inspector.ElDialog.closeOnClickModal': string
|
|
197
|
+
|
|
198
|
+
'inspector.ElMenu.mode': string
|
|
199
|
+
'inspector.ElMenu.defaultActive': string
|
|
200
|
+
'inspector.ElMenu.backgroundColor': string
|
|
201
|
+
'inspector.ElMenu.textColor': string
|
|
202
|
+
'inspector.ElMenu.activeTextColor': string
|
|
203
|
+
|
|
204
|
+
'inspector.ElSubMenu.label': string
|
|
205
|
+
'inspector.ElSubMenu.icon': string
|
|
206
|
+
|
|
207
|
+
'inspector.ElMenuItem.label': string
|
|
208
|
+
'inspector.ElMenuItem.icon': string
|
|
209
|
+
'inspector.ElMenuItem.content': string
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
const zhCnLanguageProvider: ZhCNLanguageProvider = {
|
|
213
|
+
id: 'zh_CN',
|
|
214
|
+
name: '@vyr/element-plus-browser',
|
|
215
|
+
|
|
216
|
+
'descriptor.type.ElButton': '按钮',
|
|
217
|
+
'descriptor.type.ElRow': '行布局',
|
|
218
|
+
'descriptor.type.ElCol': '列布局',
|
|
219
|
+
'descriptor.type.ElInput': '输入框',
|
|
220
|
+
'descriptor.type.ElInputNumber': '数字输入框',
|
|
221
|
+
'descriptor.type.ElSelect': '选择器',
|
|
222
|
+
'descriptor.type.ElCascader': '级联选择器',
|
|
223
|
+
'descriptor.type.ElDatePicker': '日期选择器',
|
|
224
|
+
'descriptor.type.ElSwitch': '开关',
|
|
225
|
+
'descriptor.type.ElCheckbox': '复选框',
|
|
226
|
+
'descriptor.type.ElRadio': '单选框',
|
|
227
|
+
'descriptor.type.ElForm': '表单',
|
|
228
|
+
'descriptor.type.ElTable': '表格',
|
|
229
|
+
'descriptor.type.ElTableColumn': '表格列',
|
|
230
|
+
'descriptor.type.ElPagination': '分页',
|
|
231
|
+
'descriptor.type.ElDialog': '弹窗',
|
|
232
|
+
'descriptor.type.ElMenu': '菜单',
|
|
233
|
+
'descriptor.type.ElSubMenu': '子菜单',
|
|
234
|
+
'descriptor.type.ElMenuItem': '菜单项',
|
|
235
|
+
|
|
236
|
+
'option.ElButton.type.default': '默认',
|
|
237
|
+
'option.ElButton.type.primary': '主要',
|
|
238
|
+
'option.ElButton.type.success': '成功',
|
|
239
|
+
'option.ElButton.type.info': '信息',
|
|
240
|
+
'option.ElButton.type.warning': '警告',
|
|
241
|
+
'option.ElButton.type.danger': '危险',
|
|
242
|
+
'option.ElButton.size.default': '默认',
|
|
243
|
+
'option.ElButton.size.small': '缩小',
|
|
244
|
+
'option.ElButton.size.large': '放大',
|
|
245
|
+
'option.ElButton.shape.rect': '矩形',
|
|
246
|
+
'option.ElButton.shape.circle': '圆形',
|
|
247
|
+
'option.ElButton.shape.roundedRectangle': '圆角矩形',
|
|
248
|
+
'option.ElButton.state.enable': '启用',
|
|
249
|
+
'option.ElButton.state.loading': '加载',
|
|
250
|
+
'option.ElButton.state.disable': '禁用',
|
|
251
|
+
'option.ElButton.plain.default': '默认',
|
|
252
|
+
'option.ElButton.plain.simple': '朴素',
|
|
253
|
+
|
|
254
|
+
'option.ElRow.justify.start': '左对齐',
|
|
255
|
+
'option.ElRow.justify.end': '右对齐',
|
|
256
|
+
'option.ElRow.justify.center': '中间对齐',
|
|
257
|
+
'option.ElRow.justify.space-between': '两端对齐',
|
|
258
|
+
'option.ElRow.justify.space-around': '等距对齐',
|
|
259
|
+
|
|
260
|
+
'option.ElRow.align.top': '顶部对齐',
|
|
261
|
+
'option.ElRow.align.middle': '底部对齐',
|
|
262
|
+
'option.ElRow.align.bottom': '中间对齐',
|
|
263
|
+
|
|
264
|
+
'option.ElColumn.type.default': '默认',
|
|
265
|
+
'option.ElColumn.type.index': '序号',
|
|
266
|
+
'option.ElColumn.type.expand': '展开',
|
|
267
|
+
'option.ElColumn.type.selection': '多选',
|
|
268
|
+
|
|
269
|
+
'option.ElColumn.fixed.close': '关闭',
|
|
270
|
+
'option.ElColumn.fixed.left': '左侧',
|
|
271
|
+
'option.ElColumn.fixed.right': '右侧',
|
|
272
|
+
|
|
273
|
+
'option.ElForm.inline.disable': '基础表单',
|
|
274
|
+
'option.ElForm.inline.enable': '行内表单',
|
|
275
|
+
|
|
276
|
+
'option.ElForm.position.left': '左侧',
|
|
277
|
+
'option.ElForm.position.right': '右侧',
|
|
278
|
+
'option.ElForm.position.top': '顶部',
|
|
279
|
+
|
|
280
|
+
'option.ElInput.switch.open': '开启',
|
|
281
|
+
'option.ElInput.switch.close': '关闭',
|
|
282
|
+
|
|
283
|
+
'option.ElInput.type.text': '文本框',
|
|
284
|
+
'option.ElInput.type.number': '数值框',
|
|
285
|
+
'option.ElInput.type.textarea': '文本域',
|
|
286
|
+
'option.ElInput.type.password': '密码框',
|
|
287
|
+
|
|
288
|
+
'option.ElDialog.closeOnClickModal.true': '关闭弹窗',
|
|
289
|
+
'option.ElDialog.closeOnClickModal.false': '无交互',
|
|
290
|
+
|
|
291
|
+
'option.ElMenu.mode.horizontal': '水平模式',
|
|
292
|
+
'option.ElMenu.mode.vertical': '垂直模式',
|
|
293
|
+
|
|
294
|
+
'preset.Interaction.id.input': '输入时触发',
|
|
295
|
+
'preset.Interaction.id.clear': '清空时触发',
|
|
296
|
+
'preset.Interaction.id.change': '变化时触发',
|
|
297
|
+
|
|
298
|
+
'preset.ElTable.list': '请求表格数据',
|
|
299
|
+
'preset.ElTable.list.form': '表格请求条件',
|
|
300
|
+
'preset.ElTable.list.pagination': '表格分页条件',
|
|
301
|
+
'preset.ElTable.list.url': '发送数据请求',
|
|
302
|
+
'preset.ElTable.list.dataset': '更新表格数据集',
|
|
303
|
+
|
|
304
|
+
'preset.ElTable.reset': '重置表格数据',
|
|
305
|
+
|
|
306
|
+
'preset.ElTable.edit': '编辑表格项',
|
|
307
|
+
'preset.ElTable.edit.url': '发送数据请求',
|
|
308
|
+
'preset.ElTable.edit.dataset': '更新表单数据集',
|
|
309
|
+
'preset.ElTable.edit.dialog': '打开编辑弹窗',
|
|
310
|
+
'preset.ElTable.edit.dialog.title': '弹窗标题',
|
|
311
|
+
|
|
312
|
+
'preset.ElTable.create': '新增表格项',
|
|
313
|
+
'preset.ElTable.create.dataset': '更新表单数据集',
|
|
314
|
+
'preset.ElTable.create.dialog': '打开编辑弹窗',
|
|
315
|
+
'preset.ElTable.create.dialog.title': '弹窗标题',
|
|
316
|
+
|
|
317
|
+
'preset.ElTable.delete': '删除表格项',
|
|
318
|
+
'preset.ElTable.delete.url': '发送删除请求',
|
|
319
|
+
|
|
320
|
+
'preset.ElTable.submit': '提交表单数据',
|
|
321
|
+
'preset.ElTable.submit.url': '表单提交地址',
|
|
322
|
+
'preset.ElTable.submit.form': '需要提交数据的表单',
|
|
323
|
+
'preset.ElTable.submit.dialog': '需要关闭的弹窗',
|
|
324
|
+
|
|
325
|
+
'preset.ElTable.close': '关闭表格弹窗',
|
|
326
|
+
'preset.ElTable.close.dialog': '需要关闭的弹窗',
|
|
327
|
+
|
|
328
|
+
'inspector.ElButton.type': '类型',
|
|
329
|
+
'inspector.ElButton.text': '文本',
|
|
330
|
+
'inspector.ElButton.size': '尺寸',
|
|
331
|
+
'inspector.ElButton.shape': '形状',
|
|
332
|
+
'inspector.ElButton.state': '状态',
|
|
333
|
+
'inspector.ElButton.plain': '风格',
|
|
334
|
+
|
|
335
|
+
'inspector.ElRow.gutter': '栅格间隔',
|
|
336
|
+
'inspector.ElRow.justify': '水平排列',
|
|
337
|
+
'inspector.ElRow.align': '垂直排列',
|
|
338
|
+
|
|
339
|
+
'inspector.ElCol.span': '栅格占比',
|
|
340
|
+
'inspector.ElCol.offset': '栅格偏移',
|
|
341
|
+
|
|
342
|
+
'inspector.ElForm.inline': '表单模式',
|
|
343
|
+
'inspector.ElForm.disabled': '禁用表单',
|
|
344
|
+
'inspector.ElForm.label.position': '标签位置',
|
|
345
|
+
'inspector.ElForm.label.width': '标签宽度',
|
|
346
|
+
|
|
347
|
+
'inspector.ElFormItem.modelValue': '默认值',
|
|
348
|
+
'inspector.ElFormItem.placeholder': '提示词',
|
|
349
|
+
'inspector.ElFormItem.columnName': '字段名',
|
|
350
|
+
'inspector.ElFormItem.columnComment': '字段备注',
|
|
351
|
+
'inspector.ElFormItem.columnType': '字段类型',
|
|
352
|
+
'inspector.ElFormItem.required': '非空验证',
|
|
353
|
+
|
|
354
|
+
'inspector.ElFormItem.options': '选项',
|
|
355
|
+
'inspector.ElFormItem.label': '标签',
|
|
356
|
+
'inspector.ElFormItem.value': '标识',
|
|
357
|
+
'inspector.ElFormItem.border': '边框',
|
|
358
|
+
'inspector.ElFormItem.readonly': '只读',
|
|
359
|
+
'inspector.ElFormItem.disabled': '禁用',
|
|
360
|
+
'inspector.ElFormItem.clearable': '可清空',
|
|
361
|
+
'inspector.ElFormItem.rows': '文本行数',
|
|
362
|
+
'inspector.ElFormItem.step': '步长',
|
|
363
|
+
'inspector.ElFormItem.maxlength': '最大长度',
|
|
364
|
+
'inspector.ElFormItem.minlength': '最小长度',
|
|
365
|
+
'inspector.ElFormItem.autofocus': '自动聚焦',
|
|
366
|
+
'inspector.ElFormItem.showWordLimit': '文本统计',
|
|
367
|
+
'inspector.ElFormItem.showPassword': '密码切换',
|
|
368
|
+
'inspector.ElFormItem.min': '最小值',
|
|
369
|
+
'inspector.ElFormItem.max': '最大值',
|
|
370
|
+
'inspector.ElFormItem.loading': '加载中',
|
|
371
|
+
|
|
372
|
+
'inspector.ElInput.type': '输入框类型',
|
|
373
|
+
'inspector.ElDatePicker.type': '时间类型',
|
|
374
|
+
'inspector.ElDatePicker.format': '时间格式',
|
|
375
|
+
|
|
376
|
+
'inspector.ElTable.border': '边框',
|
|
377
|
+
'inspector.ElTable.stripe': '条纹',
|
|
378
|
+
'inspector.ElTable.showHeader': '渲染表头',
|
|
379
|
+
'inspector.ElTable.fit': '自动列宽',
|
|
380
|
+
|
|
381
|
+
'inspector.ElTableColumn.columnName': '字段名',
|
|
382
|
+
'inspector.ElTableColumn.columnComment': '字段备注',
|
|
383
|
+
'inspector.ElTableColumn.columnWidth': '列宽',
|
|
384
|
+
'inspector.ElTableColumn.columnType': '列类型',
|
|
385
|
+
'inspector.ElTableColumn.columnFixed': '固定列',
|
|
386
|
+
'inspector.ElTableColumn.columnAlign': '对其方式',
|
|
387
|
+
'inspector.ElTableColumn.columnTooltip': '自动隐藏',
|
|
388
|
+
'inspector.ElTableColumn.formattingScript': '格式化脚本',
|
|
389
|
+
'inspector.ElTableColumn.formattingDataset': '格式化数据',
|
|
390
|
+
'inspector.ElTableColumn.formattingLabel': '格式化标签',
|
|
391
|
+
'inspector.ElTableColumn.formattingValue': '格式化数值',
|
|
392
|
+
'inspector.ElTableColumn.formattingSeparator': '格式化分隔',
|
|
393
|
+
|
|
394
|
+
'inspector.ElPagination.total': '总条数',
|
|
395
|
+
'inspector.ElPagination.currentPage': '当前页',
|
|
396
|
+
'inspector.ElPagination.pageSize': '每页条数',
|
|
397
|
+
'inspector.ElPagination.pageSizes': '条数选项',
|
|
398
|
+
'inspector.ElPagination.background': '背景色',
|
|
399
|
+
'inspector.ElPagination.layoutSizes': '条数选择器',
|
|
400
|
+
'inspector.ElPagination.layoutPrev': '上一页按钮',
|
|
401
|
+
'inspector.ElPagination.layoutPager': '页码列表',
|
|
402
|
+
'inspector.ElPagination.layoutNext': '下一页按钮',
|
|
403
|
+
'inspector.ElPagination.layoutJumper': '页码跳转',
|
|
404
|
+
'inspector.ElPagination.layoutArrow': '翻页箭头',
|
|
405
|
+
'inspector.ElPagination.layoutTotal': '总条数显示',
|
|
406
|
+
|
|
407
|
+
'inspector.ElDialog.title': '弹窗标题',
|
|
408
|
+
'inspector.ElDialog.closeOnClickModal': '点击遮罩',
|
|
409
|
+
|
|
410
|
+
'inspector.ElMenu.mode': '模式',
|
|
411
|
+
'inspector.ElMenu.defaultActive': '默认激活',
|
|
412
|
+
'inspector.ElMenu.backgroundColor': '背景色',
|
|
413
|
+
'inspector.ElMenu.textColor': '文字颜色',
|
|
414
|
+
'inspector.ElMenu.activeTextColor': '激活文字颜色',
|
|
415
|
+
|
|
416
|
+
'inspector.ElSubMenu.label': '子菜单名',
|
|
417
|
+
'inspector.ElSubMenu.icon': '子菜单图标',
|
|
418
|
+
|
|
419
|
+
'inspector.ElMenuItem.label': '菜单项名称',
|
|
420
|
+
'inspector.ElMenuItem.icon': '菜单项图标',
|
|
421
|
+
'inspector.ElMenuItem.content': '展示内容',
|
|
422
|
+
}
|
|
423
|
+
|
|
424
|
+
export {
|
|
425
|
+
ZhCNLanguageProvider,
|
|
426
|
+
zhCnLanguageProvider,
|
|
427
|
+
}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { language } from '../locale'
|
|
2
|
+
|
|
3
|
+
const typeOptions = [
|
|
4
|
+
{ label: language.get('option.ElButton.type.default'), value: 'default' },
|
|
5
|
+
{ label: language.get('option.ElButton.type.primary'), value: 'primary' },
|
|
6
|
+
{ label: language.get('option.ElButton.type.success'), value: 'success' },
|
|
7
|
+
{ label: language.get('option.ElButton.type.info'), value: 'info' },
|
|
8
|
+
{ label: language.get('option.ElButton.type.warning'), value: 'warning' },
|
|
9
|
+
{ label: language.get('option.ElButton.type.danger'), value: 'danger' },
|
|
10
|
+
]
|
|
11
|
+
|
|
12
|
+
const sizeOptions = [
|
|
13
|
+
{ label: language.get('option.ElButton.size.default'), value: 'default' },
|
|
14
|
+
{ label: language.get('option.ElButton.size.small'), value: 'small' },
|
|
15
|
+
{ label: language.get('option.ElButton.size.large'), value: 'large' },
|
|
16
|
+
]
|
|
17
|
+
const shapeOptions = [
|
|
18
|
+
{ label: language.get('option.ElButton.shape.rect'), value: 1 },
|
|
19
|
+
{ label: language.get('option.ElButton.shape.circle'), value: 2 },
|
|
20
|
+
{ label: language.get('option.ElButton.shape.roundedRectangle'), value: 3 },
|
|
21
|
+
]
|
|
22
|
+
const stateOptions = [
|
|
23
|
+
{ label: language.get('option.ElButton.state.enable'), value: 1 },
|
|
24
|
+
{ label: language.get('option.ElButton.state.loading'), value: 2 },
|
|
25
|
+
{ label: language.get('option.ElButton.state.disable'), value: 3 },
|
|
26
|
+
]
|
|
27
|
+
const plainOptions = [
|
|
28
|
+
{ label: language.get('option.ElButton.plain.default'), value: false },
|
|
29
|
+
{ label: language.get('option.ElButton.plain.simple'), value: true },
|
|
30
|
+
]
|
|
31
|
+
|
|
32
|
+
export {
|
|
33
|
+
typeOptions,
|
|
34
|
+
sizeOptions,
|
|
35
|
+
shapeOptions,
|
|
36
|
+
stateOptions,
|
|
37
|
+
plainOptions,
|
|
38
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { language } from '../locale'
|
|
2
|
+
|
|
3
|
+
const typeOptions = [
|
|
4
|
+
{ label: language.get('option.ElColumn.type.default'), value: 'default' },
|
|
5
|
+
{ label: language.get('option.ElColumn.type.index'), value: 'index' },
|
|
6
|
+
{ label: language.get('option.ElColumn.type.expand'), value: 'expand' },
|
|
7
|
+
{ label: language.get('option.ElColumn.type.selection'), value: 'selection' },
|
|
8
|
+
]
|
|
9
|
+
|
|
10
|
+
const fixedOptions = [
|
|
11
|
+
{ label: language.get('option.ElColumn.fixed.close'), value: false },
|
|
12
|
+
{ label: language.get('option.ElColumn.fixed.left'), value: 'left' },
|
|
13
|
+
{ label: language.get('option.ElColumn.fixed.right'), value: 'right' },
|
|
14
|
+
]
|
|
15
|
+
|
|
16
|
+
export {
|
|
17
|
+
typeOptions,
|
|
18
|
+
fixedOptions
|
|
19
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { language } from '../locale'
|
|
2
|
+
|
|
3
|
+
const closeOnClickModalOptions = [
|
|
4
|
+
{ label: language.get('option.ElDialog.closeOnClickModal.true'), value: true },
|
|
5
|
+
{ label: language.get('option.ElDialog.closeOnClickModal.false'), value: false },
|
|
6
|
+
]
|
|
7
|
+
|
|
8
|
+
export {
|
|
9
|
+
closeOnClickModalOptions,
|
|
10
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { language } from '../locale'
|
|
2
|
+
|
|
3
|
+
const inlineOptions = [
|
|
4
|
+
{ label: language.get('option.ElForm.inline.disable'), value: false },
|
|
5
|
+
{ label: language.get('option.ElForm.inline.enable'), value: true },
|
|
6
|
+
]
|
|
7
|
+
const positionOptions = [
|
|
8
|
+
{ label: language.get('option.ElForm.position.left'), value: 'left' },
|
|
9
|
+
{ label: language.get('option.ElForm.position.right'), value: 'right' },
|
|
10
|
+
{ label: language.get('option.ElForm.position.top'), value: 'top' },
|
|
11
|
+
]
|
|
12
|
+
|
|
13
|
+
export {
|
|
14
|
+
inlineOptions,
|
|
15
|
+
positionOptions,
|
|
16
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { language } from '../locale'
|
|
2
|
+
|
|
3
|
+
const switchOptions = [
|
|
4
|
+
{ label: language.get('option.ElInput.switch.open'), value: true },
|
|
5
|
+
{ label: language.get('option.ElInput.switch.close'), value: false },
|
|
6
|
+
]
|
|
7
|
+
|
|
8
|
+
const typeOptions = [
|
|
9
|
+
{ label: language.get('option.ElInput.type.text'), value: 'text' },
|
|
10
|
+
{ label: language.get('option.ElInput.type.number'), value: 'number' },
|
|
11
|
+
{ label: language.get('option.ElInput.type.textarea'), value: 'textarea' },
|
|
12
|
+
{ label: language.get('option.ElInput.type.password'), value: 'password' },
|
|
13
|
+
]
|
|
14
|
+
|
|
15
|
+
export {
|
|
16
|
+
switchOptions,
|
|
17
|
+
typeOptions,
|
|
18
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { Descriptor } from '@vyr/engine'
|
|
2
|
+
import { ElMenuItemDescriptor } from '@vyr/element-plus'
|
|
3
|
+
import { Option } from '@vyr/design'
|
|
4
|
+
import { language } from '../locale'
|
|
5
|
+
|
|
6
|
+
const modeOptions = [
|
|
7
|
+
{ label: language.get('option.ElMenu.mode.horizontal'), value: 'horizontal' },
|
|
8
|
+
{ label: language.get('option.ElMenu.mode.vertical'), value: 'vertical' },
|
|
9
|
+
]
|
|
10
|
+
|
|
11
|
+
const getDefaultActiveOptions = (uuid: string) => {
|
|
12
|
+
const options: Option[] = []
|
|
13
|
+
const descriptor = Descriptor.get<Descriptor>(uuid)
|
|
14
|
+
if (descriptor === null) return options
|
|
15
|
+
|
|
16
|
+
descriptor.traverse(child => {
|
|
17
|
+
if ([ElMenuItemDescriptor.type].includes(child.type)) {
|
|
18
|
+
options.push({
|
|
19
|
+
label: child.name,
|
|
20
|
+
value: child.uuid,
|
|
21
|
+
})
|
|
22
|
+
}
|
|
23
|
+
})
|
|
24
|
+
|
|
25
|
+
return options
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export {
|
|
29
|
+
modeOptions,
|
|
30
|
+
getDefaultActiveOptions,
|
|
31
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { language } from '../locale'
|
|
2
|
+
|
|
3
|
+
const justifyOptions = [
|
|
4
|
+
{ label: language.get('option.ElRow.justify.start'), value: 'start' },
|
|
5
|
+
{ label: language.get('option.ElRow.justify.end'), value: 'end' },
|
|
6
|
+
{ label: language.get('option.ElRow.justify.center'), value: 'center' },
|
|
7
|
+
{ label: language.get('option.ElRow.justify.space-between'), value: 'space-between' },
|
|
8
|
+
{ label: language.get('option.ElRow.justify.space-around'), value: 'space-around' },
|
|
9
|
+
]
|
|
10
|
+
const alignOptions = [
|
|
11
|
+
{ label: language.get('option.ElRow.align.top'), value: 'top' },
|
|
12
|
+
{ label: language.get('option.ElRow.align.middle'), value: 'middle' },
|
|
13
|
+
{ label: language.get('option.ElRow.align.bottom'), value: 'bottom' },
|
|
14
|
+
]
|
|
15
|
+
|
|
16
|
+
export {
|
|
17
|
+
justifyOptions,
|
|
18
|
+
alignOptions,
|
|
19
|
+
}
|