@web-utils/component 2.7.3 → 2.7.5
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/chunks/AfdColumn.vue_vue_type_template_lang.768f2ed2.js +302 -0
- package/dist/chunks/ConfigArray.vue_vue_type_template_lang.66483daa.js +51 -0
- package/dist/chunks/ConfigColor.vue_vue_type_template_lang.cd880091.js +24 -0
- package/dist/chunks/ConfigCustom.vue_vue_type_template_lang.6e03d7fd.js +52 -0
- package/dist/chunks/ConfigDate.vue_vue_type_template_lang.420fa897.js +104 -0
- package/dist/chunks/ConfigDynamic.vue_vue_type_template_lang.82d24ab0.js +133 -0
- package/dist/chunks/ConfigEvent.vue_vue_type_template_lang.5e8ed6cc.js +96 -0
- package/dist/chunks/ConfigGroup.vue_vue_type_template_lang.44117322.js +48 -0
- package/dist/chunks/ConfigInput.vue_vue_type_template_lang.cc1eb052.js +96 -0
- package/dist/chunks/ConfigMap.vue_vue_type_template_lang.daee4d38.js +31 -0
- package/dist/chunks/ConfigNumber.vue_vue_type_template_lang.d60231d7.js +130 -0
- package/dist/chunks/ConfigRate.vue_vue_type_style_index_0_scoped_true_lang.cf5d437d.js +125 -0
- package/dist/chunks/ConfigSelect.vue_vue_type_template_lang.7db7e57f.js +483 -0
- package/dist/chunks/ConfigSlider.vue_vue_type_template_lang.27b8cc7b.js +99 -0
- package/dist/chunks/ConfigSwitch.vue_vue_type_style_index_0_scoped_true_lang.4caf1bd0.js +54 -0
- package/dist/chunks/ConfigTable.vue_vue_type_template_lang.3e8136d9.js +341 -0
- package/dist/chunks/ConfigTextarea.vue_vue_type_template_lang.5cddf41c.js +88 -0
- package/dist/chunks/ConfigTitle.vue_vue_type_template_lang.57d9deb5.js +87 -0
- package/dist/chunks/ConfigTree.vue_vue_type_style_index_0_scoped_true_lang.3770c37e.js +464 -0
- package/dist/chunks/ConfigUEditor.vue_vue_type_template_lang.9726b4f5.js +240 -0
- package/dist/chunks/ConfigUpload.vue_vue_type_template_lang.531a9b2a.js +471 -0
- package/dist/chunks/FormConfig.vue_vue_type_template_lang.85b4ee87.js +232 -0
- package/dist/chunks/WidgetConfig.vue_vue_type_template_lang.fbbbff76.js +1765 -0
- package/dist/chunks/WidgetForm.vue_vue_type_template_lang.82248338.js +242 -0
- package/dist/chunks/WidgetFormGroup.vue_vue_type_template_lang.c636aabd.js +266 -0
- package/dist/chunks/WidgetFormItem.vue_vue_type_template_lang.48d55a5c.js +24 -0
- package/dist/chunks/WidgetFormTable.vue_vue_type_template_lang.30625146.js +228 -0
- package/dist/chunks/{dataformat.3cfcf62c.js → dataformat.d3fd2d1b.js} +25 -24
- package/dist/chunks/{detail.a3249549.js → detail.ac4d421a.js} +7 -7
- package/dist/chunks/{dic.5f7e3523.js → dic.79d9f595.js} +28 -27
- package/dist/chunks/{event.b76c568a.js → event.43b42228.js} +7 -6
- package/dist/chunks/{init.352281f5.js → init.3b47bb80.js} +8 -7
- package/dist/chunks/monaco.1dbdc960.js +283 -0
- package/dist/chunks/{packages.5d7a86c4.js → packages.6f252850.js} +5 -61
- package/dist/chunks/{util.5053d54e.js → util.80e28481.js} +37 -51
- package/dist/components/afd-column/index.js +54 -0
- package/dist/components/chat/index.js +1 -1
- package/dist/components/code/index.js +1 -1
- package/dist/components/column/index.js +8 -7
- package/dist/components/column-default/index.js +1 -1
- package/dist/components/column-dynamic/index.js +1 -1
- package/dist/components/column-menu/index.js +1 -1
- package/dist/components/column-slot/index.js +27 -26
- package/dist/components/config-array/index.js +26 -0
- package/dist/components/config-color/index.js +26 -0
- package/dist/components/config-custom/index.js +60 -0
- package/dist/components/config-date/index.js +26 -0
- package/dist/components/config-dynamic/index.js +26 -0
- package/dist/components/config-event/index.js +72 -0
- package/dist/components/config-group/index.js +34 -0
- package/dist/components/config-input/index.js +26 -0
- package/dist/components/config-map/index.js +26 -0
- package/dist/components/config-number/index.js +26 -0
- package/dist/components/config-rate/index.js +69 -0
- package/dist/components/config-rate/style.css +1 -0
- package/dist/components/config-select/index.js +88 -0
- package/dist/components/config-slider/index.js +26 -0
- package/dist/components/config-switch/index.js +31 -0
- package/dist/components/config-switch/style.css +1 -0
- package/dist/components/config-table/index.js +120 -0
- package/dist/components/config-textarea/index.js +26 -0
- package/dist/components/config-title/index.js +31 -0
- package/dist/components/config-tree/index.js +120 -0
- package/dist/components/config-tree/style.css +1 -0
- package/dist/components/config-u-editor/index.js +32 -0
- package/dist/components/config-upload/index.js +56 -0
- package/dist/components/custom-scrollbar/index.js +6 -1
- package/dist/components/dialog-excel/index.js +2 -2
- package/dist/components/dialog-filter/index.js +1 -1
- package/dist/components/dialog-form/index.js +8 -7
- package/dist/components/flex-item/index.js +4 -1
- package/dist/components/flow/index.js +1 -1
- package/dist/components/flow-node/index.js +1 -1
- package/dist/components/form-config/index.js +26 -0
- package/dist/components/form-group/index.js +1 -1
- package/dist/components/form-temp/index.js +2 -2
- package/dist/components/{array → fy-array}/index.js +5 -5
- package/dist/components/{array → fy-array}/style.css +0 -0
- package/dist/components/fy-cascader/index.js +1 -1
- package/dist/components/fy-checkbox/index.js +1 -1
- package/dist/components/fy-curd/index.js +7 -6
- package/dist/components/fy-date/index.js +1 -1
- package/dist/components/fy-dialog-form/index.js +9 -8
- package/dist/components/{draggable → fy-draggable}/index.js +2 -2
- package/dist/components/{draggable → fy-draggable}/style.css +0 -0
- package/dist/components/fy-dynamic/index.js +2 -2
- package/dist/components/{empty → fy-empty}/index.js +6 -6
- package/dist/components/{empty → fy-empty}/style.css +0 -0
- package/dist/components/fy-form/index.js +9 -8
- package/dist/components/fy-form-design/index.js +1255 -0
- package/dist/components/fy-form-design/style.css +1 -0
- package/dist/components/fy-input/index.js +1 -1
- package/dist/components/fy-input-color/index.js +1 -1
- package/dist/components/fy-input-icon/index.js +1 -1
- package/dist/components/fy-input-map/index.js +4 -4
- package/dist/components/fy-input-number/index.js +1 -1
- package/dist/components/fy-input-table/index.js +4 -4
- package/dist/components/fy-input-tree/index.js +2 -2
- package/dist/components/fy-radio/index.js +1 -1
- package/dist/components/fy-rate/index.js +1 -1
- package/dist/components/fy-select/index.js +18 -17
- package/dist/components/fy-slider/index.js +2 -2
- package/dist/components/fy-switch/index.js +1 -1
- package/dist/components/fy-time/index.js +2 -2
- package/dist/components/fy-title/index.js +1 -1
- package/dist/components/fy-tree/index.js +7 -6
- package/dist/components/fy-upload/index.js +11 -10
- package/dist/components/header-menu/index.js +1 -1
- package/dist/components/header-search/index.js +2 -2
- package/dist/components/license/index.js +5 -5
- package/dist/components/login/index.js +9 -8
- package/dist/components/record-video/index.js +1 -1
- package/dist/components/search/index.js +10 -9
- package/dist/components/sign/index.js +1 -1
- package/dist/components/table-column/index.js +4 -1
- package/dist/components/table-page/index.js +1 -1
- package/dist/components/text-ellipsis/index.js +1 -1
- package/dist/components/verify/index.js +1 -1
- package/dist/components/watermark/index.js +5 -1
- package/dist/components/widget-config/index.js +107 -0
- package/dist/components/widget-form/index.js +68 -0
- package/dist/components/widget-form-group/index.js +91 -0
- package/dist/components/widget-form-item/index.js +70 -0
- package/dist/components/widget-form-table/index.js +90 -0
- package/dist/index.css +761 -201
- package/dist/index.es.js +24100 -16510
- package/package.json +5 -3
- package/web-types.json +1880 -1781
|
@@ -0,0 +1,283 @@
|
|
|
1
|
+
import * as h from "monaco-editor/esm/vs/editor/editor.api";
|
|
2
|
+
import "monaco-editor/esm/vs/basic-languages/javascript/javascript.contribution";
|
|
3
|
+
let y = /[\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g, j = /^[a-zA-Z_$][0-9a-zA-Z_$]*$/, u, g, O = {
|
|
4
|
+
// table of character substitutions
|
|
5
|
+
"\b": "\\b",
|
|
6
|
+
" ": "\\t",
|
|
7
|
+
"\n": "\\n",
|
|
8
|
+
"\f": "\\f",
|
|
9
|
+
"\r": "\\r",
|
|
10
|
+
'"': '\\"',
|
|
11
|
+
"'": "\\'",
|
|
12
|
+
"\\": "\\\\"
|
|
13
|
+
}, c;
|
|
14
|
+
function b(t, e = {}) {
|
|
15
|
+
var i = e.space || 2, n = e.dropQuotesOnKeys != !1, r = e.dropQuotesOnNumbers || !1, s = e.inlineShortArrays || !1, a = e.inlineShortArraysDepth || 1, f = e.quoteType || "single", d = e.minify || !1;
|
|
16
|
+
r && x(t);
|
|
17
|
+
var l = $(t, null, d ? void 0 : i, n, f);
|
|
18
|
+
if (s && !d) {
|
|
19
|
+
var o = S(l);
|
|
20
|
+
if (a > 1)
|
|
21
|
+
for (var v = 1; v < a && (l = o, o = S(l), o != l); v++)
|
|
22
|
+
;
|
|
23
|
+
l = o;
|
|
24
|
+
}
|
|
25
|
+
return l;
|
|
26
|
+
}
|
|
27
|
+
function x(t) {
|
|
28
|
+
if (M(t)) {
|
|
29
|
+
var e = Object.keys(t);
|
|
30
|
+
e && e.forEach(function(i) {
|
|
31
|
+
var n = t[i];
|
|
32
|
+
if (typeof n == "string") {
|
|
33
|
+
var r = n - 0;
|
|
34
|
+
t[i] = isNaN(r) ? n : r;
|
|
35
|
+
} else
|
|
36
|
+
(M(n) || Array.isArray(n)) && x(n);
|
|
37
|
+
});
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
function M(t) {
|
|
41
|
+
return t && typeof t == "object";
|
|
42
|
+
}
|
|
43
|
+
function S(t, e) {
|
|
44
|
+
if (e || (e = 80), typeof e != "number" || e < 20)
|
|
45
|
+
throw "Invalid width '" + e + "'. Expecting number equal or larger than 20.";
|
|
46
|
+
for (var i = t.split(`
|
|
47
|
+
`), n = 0, r = null, s = []; n < i.length; ) {
|
|
48
|
+
var a = !!i[n].match(/\[/), f = !!i[n].match(/\],?/);
|
|
49
|
+
if (a && !f)
|
|
50
|
+
s = [i[n]], r = n;
|
|
51
|
+
else if (f && !a && r) {
|
|
52
|
+
s.push((i[n] || "").trim());
|
|
53
|
+
var d = s.join(" ");
|
|
54
|
+
d.length < e && (i.splice(r, n - r + 1, d), n = r), r = null, s = [];
|
|
55
|
+
} else
|
|
56
|
+
r && s.push((i[n] || "").trim());
|
|
57
|
+
n += 1;
|
|
58
|
+
}
|
|
59
|
+
return i.join(`
|
|
60
|
+
`);
|
|
61
|
+
}
|
|
62
|
+
function $(t, e, i, n, r) {
|
|
63
|
+
var s;
|
|
64
|
+
if (u = "", g = "", typeof i == "number")
|
|
65
|
+
for (s = 0; s < i; s += 1)
|
|
66
|
+
g += " ";
|
|
67
|
+
else
|
|
68
|
+
typeof i == "string" && (g = i);
|
|
69
|
+
if (c = e, e && typeof e != "function" && (typeof e != "object" || typeof e.length != "number"))
|
|
70
|
+
throw new Error("JSON.stringify");
|
|
71
|
+
return m("", { "": t }, n, r);
|
|
72
|
+
}
|
|
73
|
+
function m(t, e, i, n) {
|
|
74
|
+
var r, s, a, f, d = u, l, o = e[t];
|
|
75
|
+
switch (o && typeof o == "object" && typeof o.toJSON == "function" && (o = o.toJSON(t)), typeof c == "function" && (o = c.call(e, t, o)), typeof o) {
|
|
76
|
+
case "function":
|
|
77
|
+
return o;
|
|
78
|
+
case "string":
|
|
79
|
+
return p(o, n);
|
|
80
|
+
case "number":
|
|
81
|
+
return isFinite(o) ? String(o) : "null";
|
|
82
|
+
case "boolean":
|
|
83
|
+
case "null":
|
|
84
|
+
return String(o);
|
|
85
|
+
case "object":
|
|
86
|
+
if (!o)
|
|
87
|
+
return "null";
|
|
88
|
+
if (u += g, l = [], Object.prototype.toString.apply(o) === "[object Array]") {
|
|
89
|
+
for (f = o.length, r = 0; r < f; r += 1)
|
|
90
|
+
l[r] = m(r, o, i, n) || "null";
|
|
91
|
+
return a = l.length === 0 ? "[]" : u ? `[
|
|
92
|
+
` + u + l.join(`,
|
|
93
|
+
` + u) + `
|
|
94
|
+
` + d + "]" : "[" + l.join(",") + "]", u = d, a;
|
|
95
|
+
}
|
|
96
|
+
if (c && typeof c == "object")
|
|
97
|
+
for (f = c.length, r = 0; r < f; r += 1)
|
|
98
|
+
typeof c[r] == "string" && (s = c[r], a = m(s, o, i, n), a && l.push((i ? _(s, n) : p(s, n)) + (u ? ": " : ":") + a));
|
|
99
|
+
else
|
|
100
|
+
for (s in o)
|
|
101
|
+
Object.prototype.hasOwnProperty.call(o, s) && (a = m(s, o, i, n), a && l.push((i ? _(s, n) : p(s, n)) + (u ? ": " : ":") + a));
|
|
102
|
+
return a = l.length === 0 ? "{}" : u ? `{
|
|
103
|
+
` + u + l.join(`,
|
|
104
|
+
` + u) + `
|
|
105
|
+
` + d + "}" : "{" + l.join(",") + "}", u = d, a;
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
function p(t, e) {
|
|
109
|
+
y.lastIndex = 0;
|
|
110
|
+
var i = '"';
|
|
111
|
+
return e === "single" && (i = "'"), y.test(t) ? i + t.replace(y, function(n) {
|
|
112
|
+
var r = O[n];
|
|
113
|
+
return typeof r == "string" ? r : "\\u" + ("0000" + n.charCodeAt(0).toString(16)).slice(-4);
|
|
114
|
+
}) + i : i + t + i;
|
|
115
|
+
}
|
|
116
|
+
function _(t, e) {
|
|
117
|
+
return j.test(t) ? t : p(t, e);
|
|
118
|
+
}
|
|
119
|
+
function E() {
|
|
120
|
+
}
|
|
121
|
+
const w = {
|
|
122
|
+
name: "MonacoEditor",
|
|
123
|
+
props: {
|
|
124
|
+
diffEditor: { type: Boolean, default: !1 },
|
|
125
|
+
//是否使用diff模式
|
|
126
|
+
width: { type: [String, Number], default: "100%" },
|
|
127
|
+
height: { type: [String, Number], default: "100%" },
|
|
128
|
+
original: String,
|
|
129
|
+
//只有在diff模式下有效
|
|
130
|
+
value: [String, Object],
|
|
131
|
+
language: { type: String, default: "javascript" },
|
|
132
|
+
theme: { type: String, default: "vs" },
|
|
133
|
+
readOnly: { type: Boolean, default: !1 },
|
|
134
|
+
options: {
|
|
135
|
+
type: Object,
|
|
136
|
+
default() {
|
|
137
|
+
return {};
|
|
138
|
+
}
|
|
139
|
+
},
|
|
140
|
+
editorMounted: { type: Function, default: E },
|
|
141
|
+
editorBeforeMount: { type: Function, default: E },
|
|
142
|
+
keyIndex: { type: String }
|
|
143
|
+
},
|
|
144
|
+
watch: {
|
|
145
|
+
options: {
|
|
146
|
+
deep: !0,
|
|
147
|
+
handler(t) {
|
|
148
|
+
this.editor && this.editor.updateOptions(t);
|
|
149
|
+
}
|
|
150
|
+
},
|
|
151
|
+
keyIndex() {
|
|
152
|
+
let t = this.value;
|
|
153
|
+
typeof t == "object" && (t = b(t)), this.editor && t !== this._getValue() && this._setValue(t);
|
|
154
|
+
},
|
|
155
|
+
language() {
|
|
156
|
+
if (this.editor)
|
|
157
|
+
if (this.diffEditor) {
|
|
158
|
+
const { original: t, modified: e } = this.editor.getModel();
|
|
159
|
+
h.editor.setModelLanguage(t, this.language), h.editor.setModelLanguage(e, this.language);
|
|
160
|
+
} else
|
|
161
|
+
h.editor.setModelLanguage(this.editor.getModel(), this.language);
|
|
162
|
+
},
|
|
163
|
+
theme() {
|
|
164
|
+
this.editor && h.editor.setTheme(this.theme);
|
|
165
|
+
},
|
|
166
|
+
style() {
|
|
167
|
+
this.editor && this.$nextTick(() => {
|
|
168
|
+
this.editor.layout();
|
|
169
|
+
});
|
|
170
|
+
},
|
|
171
|
+
value(t) {
|
|
172
|
+
this.editor && t !== this._getValue() && this._setValue(t);
|
|
173
|
+
}
|
|
174
|
+
},
|
|
175
|
+
computed: {
|
|
176
|
+
style() {
|
|
177
|
+
return {
|
|
178
|
+
width: /^\d+$/.test(this.width) ? `${this.width}px` : this.width,
|
|
179
|
+
height: /^\d+$/.test(this.height) ? `${this.height}px` : this.height,
|
|
180
|
+
position: "relative"
|
|
181
|
+
};
|
|
182
|
+
}
|
|
183
|
+
},
|
|
184
|
+
mounted() {
|
|
185
|
+
this.initMonaco();
|
|
186
|
+
},
|
|
187
|
+
beforeDestroy() {
|
|
188
|
+
this.editor && this.editor.dispose();
|
|
189
|
+
},
|
|
190
|
+
render(t) {
|
|
191
|
+
const e = this.options.fullScreen;
|
|
192
|
+
return t("div", { class: "monaco_editor_container", style: this.style }, [
|
|
193
|
+
e ? t("i", {
|
|
194
|
+
class: "el-icon-full-screen",
|
|
195
|
+
style: {
|
|
196
|
+
width: "1.2em",
|
|
197
|
+
height: "1.2em",
|
|
198
|
+
position: "absolute",
|
|
199
|
+
left: "0px",
|
|
200
|
+
top: "0px",
|
|
201
|
+
zIndex: "1",
|
|
202
|
+
cursor: "pointer"
|
|
203
|
+
},
|
|
204
|
+
on: { click: this._handleFullScreen }
|
|
205
|
+
}) : ""
|
|
206
|
+
]);
|
|
207
|
+
},
|
|
208
|
+
methods: {
|
|
209
|
+
initMonaco() {
|
|
210
|
+
const { value: t, language: e, theme: i, readOnly: n, options: r } = this;
|
|
211
|
+
Object.assign(r, this._editorBeforeMount()), this.editor = h.editor[this.diffEditor ? "createDiffEditor" : "create"](this.$el, {
|
|
212
|
+
value: typeof t == "string" ? t : b(t),
|
|
213
|
+
language: e,
|
|
214
|
+
theme: i,
|
|
215
|
+
readOnly: n,
|
|
216
|
+
...r
|
|
217
|
+
}), this.diffEditor && this._setModel(this.value, this.original), this._editorMounted(this.editor);
|
|
218
|
+
},
|
|
219
|
+
_handleFullScreen() {
|
|
220
|
+
this.isMaximum ? this.minEditor() : this.maxEditor();
|
|
221
|
+
},
|
|
222
|
+
// 放大
|
|
223
|
+
maxEditor() {
|
|
224
|
+
this.isMaximum = !0;
|
|
225
|
+
let t = this.$el;
|
|
226
|
+
this.originSize = {
|
|
227
|
+
width: t.clientWidth,
|
|
228
|
+
height: t.clientHeight
|
|
229
|
+
}, t.classList.add("editor-fullscreen"), this.editor.layout({
|
|
230
|
+
height: document.body.clientHeight,
|
|
231
|
+
width: document.body.clientWidth
|
|
232
|
+
}), document.addEventListener("keyup", (e) => {
|
|
233
|
+
e.keyCode == 27 && this.minEditor();
|
|
234
|
+
});
|
|
235
|
+
},
|
|
236
|
+
// 缩小
|
|
237
|
+
minEditor() {
|
|
238
|
+
this.isMaximum = !1, this.$el.classList.remove("editor-fullscreen"), this.editor.layout({
|
|
239
|
+
height: this.originSize.height,
|
|
240
|
+
width: this.originSize.width
|
|
241
|
+
}), document.removeEventListener("keyup", () => {
|
|
242
|
+
});
|
|
243
|
+
},
|
|
244
|
+
_getEditor() {
|
|
245
|
+
return this.editor ? this.diffEditor ? this.editor.modifiedEditor : this.editor : null;
|
|
246
|
+
},
|
|
247
|
+
_setModel(t, e) {
|
|
248
|
+
const { language: i } = this, n = h.editor.createModel(e, i), r = h.editor.createModel(t, i);
|
|
249
|
+
this.editor.setModel({
|
|
250
|
+
original: n,
|
|
251
|
+
modified: r
|
|
252
|
+
});
|
|
253
|
+
},
|
|
254
|
+
_setValue(t) {
|
|
255
|
+
let e = this._getEditor();
|
|
256
|
+
if (e)
|
|
257
|
+
return e.setValue(t);
|
|
258
|
+
},
|
|
259
|
+
_getValue() {
|
|
260
|
+
let t = this._getEditor();
|
|
261
|
+
return t ? t.getValue() : "";
|
|
262
|
+
},
|
|
263
|
+
_editorBeforeMount() {
|
|
264
|
+
return this.editorBeforeMount(h) || {};
|
|
265
|
+
},
|
|
266
|
+
_editorMounted(t) {
|
|
267
|
+
this.editorMounted(t, h), this.diffEditor ? t.onDidUpdateDiff((e) => {
|
|
268
|
+
const i = this._getValue();
|
|
269
|
+
this._emitChange(i, e);
|
|
270
|
+
}) : t.onDidChangeModelContent((e) => {
|
|
271
|
+
const i = this._getValue();
|
|
272
|
+
this._emitChange(i, e);
|
|
273
|
+
});
|
|
274
|
+
},
|
|
275
|
+
_emitChange(t, e) {
|
|
276
|
+
this.$emit("change", t, e), this.$emit("input", t);
|
|
277
|
+
}
|
|
278
|
+
}
|
|
279
|
+
};
|
|
280
|
+
export {
|
|
281
|
+
w as M,
|
|
282
|
+
b as c
|
|
283
|
+
};
|
|
@@ -1,57 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
let i = "";
|
|
4
|
-
switch (t) {
|
|
5
|
-
case "default":
|
|
6
|
-
i = "#35495E";
|
|
7
|
-
break;
|
|
8
|
-
case "primary":
|
|
9
|
-
i = "#3488ff";
|
|
10
|
-
break;
|
|
11
|
-
case "success":
|
|
12
|
-
i = "#43B883";
|
|
13
|
-
break;
|
|
14
|
-
case "warning":
|
|
15
|
-
i = "#e6a23c";
|
|
16
|
-
break;
|
|
17
|
-
case "danger":
|
|
18
|
-
i = "#f56c6c";
|
|
19
|
-
break;
|
|
20
|
-
}
|
|
21
|
-
return i;
|
|
22
|
-
}
|
|
23
|
-
s.capsule = function(t, i, a = "primary") {
|
|
24
|
-
console.log(
|
|
25
|
-
`%c ${t} %c ${i} %c`,
|
|
26
|
-
"background:#35495E; padding: 1px; border-radius: 3px 0 0 3px; color: #fff;",
|
|
27
|
-
`background:${l(
|
|
28
|
-
a
|
|
29
|
-
)}; padding: 1px; border-radius: 0 3px 3px 0; color: #fff;`,
|
|
30
|
-
"background:transparent"
|
|
31
|
-
);
|
|
32
|
-
};
|
|
33
|
-
s.colorful = function(t) {
|
|
34
|
-
console.log(
|
|
35
|
-
`%c${t.map((i) => i.text || "").join("%c")}`,
|
|
36
|
-
...t.map((i) => `color: ${l(i.type)};`)
|
|
37
|
-
);
|
|
38
|
-
};
|
|
39
|
-
s.default = function(t) {
|
|
40
|
-
s.colorful([{ text: t }]);
|
|
41
|
-
};
|
|
42
|
-
s.primary = function(t) {
|
|
43
|
-
s.colorful([{ text: t, type: "primary" }]);
|
|
44
|
-
};
|
|
45
|
-
s.success = function(t) {
|
|
46
|
-
s.colorful([{ text: t, type: "success" }]);
|
|
47
|
-
};
|
|
48
|
-
s.warning = function(t) {
|
|
49
|
-
s.colorful([{ text: t, type: "warning" }]);
|
|
50
|
-
};
|
|
51
|
-
s.danger = function(t) {
|
|
52
|
-
s.colorful([{ text: t, type: "danger" }]);
|
|
53
|
-
};
|
|
54
|
-
const c = {
|
|
1
|
+
import { createLogger as l } from "@web-utils/core";
|
|
2
|
+
const a = {
|
|
55
3
|
AliOSS: {
|
|
56
4
|
url: "https://cdn.staticfile.org/ali-oss/6.17.1/aliyun-oss-sdk.min.js",
|
|
57
5
|
title: "阿里云云图片上传,需引入OSS的sdk",
|
|
@@ -100,13 +48,9 @@ const c = {
|
|
|
100
48
|
github: "https://github.com/Colingo/mock"
|
|
101
49
|
}
|
|
102
50
|
}, o = (() => ({
|
|
103
|
-
logs: function(
|
|
104
|
-
const
|
|
105
|
-
|
|
106
|
-
t,
|
|
107
|
-
i.title,
|
|
108
|
-
"warning"
|
|
109
|
-
), s.warning("CDN:" + (i.url || "-")), s.warning("GITHUB:" + (i.github || "-"));
|
|
51
|
+
logs: function(s) {
|
|
52
|
+
const t = a[s], i = l(s);
|
|
53
|
+
i.warning(t.title), i.warning("CDN:" + (t.url || "-")), i.warning("GITHUB:" + (t.github || "-"));
|
|
110
54
|
}
|
|
111
55
|
}))();
|
|
112
56
|
export {
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { isBlank, getObjType } from "@web-utils/core";
|
|
1
2
|
const KEY_COMPONENT_NAME = "fy-", DIC_PROPS = {
|
|
2
3
|
rowKey: "id",
|
|
3
4
|
rowParentKey: "parentId",
|
|
@@ -33,7 +34,7 @@ const KEY_COMPONENT_NAME = "fy-", DIC_PROPS = {
|
|
|
33
34
|
img: /\.(gif|jpg|jpeg|png|webp|svg|GIF|JPG|JPEG|PNG|WEBP|SVG)/,
|
|
34
35
|
video: /\.(swf|avi|flv|mpg|rm|mov|wav|asf|3gp|mkv|rmvb|ogg|mp4)/,
|
|
35
36
|
audio: /\.(mp3|wav|MP3|WAV)/
|
|
36
|
-
},
|
|
37
|
+
}, isMediaType = (e, r) => {
|
|
37
38
|
if (!isBlank(e))
|
|
38
39
|
return typeList.audio.test(e) || r === "audio" ? "audio" : typeList.video.test(e) || r === "video" ? "video" : typeList.img.test(e) || r === "img" ? "img" : !1;
|
|
39
40
|
};
|
|
@@ -79,23 +80,23 @@ function strCorNum(e) {
|
|
|
79
80
|
}), e;
|
|
80
81
|
}
|
|
81
82
|
function extend() {
|
|
82
|
-
var e = arguments[0] || {}, r = !1, n = Array.prototype.slice.call(arguments), t = 1, a, i, l,
|
|
83
|
+
var e = arguments[0] || {}, r = !1, n = Array.prototype.slice.call(arguments), t = 1, a, i, l, s, o = !1;
|
|
83
84
|
for (typeof e == "boolean" && (r = e, t++, e = arguments[1]); t < n.length; t++)
|
|
84
85
|
if ((a = n[t]) != null)
|
|
85
86
|
for (l in a)
|
|
86
|
-
|
|
87
|
+
s = a[l], i = e[l], r && (toString.call(s) === "[object Object]" || (o = toString.call(s) === "[object Array]")) ? (o ? i = toString.call(i) === "[object Array]" ? i : [] : i = toString.call(i) === "[object Object]" ? i : {}, e[l] = extend(r, i, s)) : s !== void 0 && s !== i && (e[l] = s);
|
|
87
88
|
return e;
|
|
88
89
|
}
|
|
89
90
|
function createObj(e, r) {
|
|
90
91
|
let n = r.split("."), t = n.splice(0, 1)[0], a = {};
|
|
91
92
|
if (a[t] = {}, n.length >= 2) {
|
|
92
|
-
let i = "{", l = "}",
|
|
93
|
-
n.forEach((
|
|
94
|
-
|
|
95
|
-
}),
|
|
96
|
-
for (let
|
|
97
|
-
|
|
98
|
-
|
|
93
|
+
let i = "{", l = "}", s = "";
|
|
94
|
+
n.forEach((o) => {
|
|
95
|
+
s = `${s}${i}"${o}":`;
|
|
96
|
+
}), s = `${s}""`;
|
|
97
|
+
for (let o = 0; o < n.length; o++)
|
|
98
|
+
s = `${s}${l}`;
|
|
99
|
+
s = JSON.parse(s), a[t] = s;
|
|
99
100
|
}
|
|
100
101
|
return e = extend(!0, e, a), e;
|
|
101
102
|
}
|
|
@@ -125,21 +126,7 @@ function randomId() {
|
|
|
125
126
|
n += e.charAt(Math.floor(Math.random() * r));
|
|
126
127
|
return n;
|
|
127
128
|
}
|
|
128
|
-
const
|
|
129
|
-
var r = Object.prototype.toString, n = {
|
|
130
|
-
"[object Boolean]": "boolean",
|
|
131
|
-
"[object Number]": "number",
|
|
132
|
-
"[object String]": "string",
|
|
133
|
-
"[object Function]": "function",
|
|
134
|
-
"[object Array]": "array",
|
|
135
|
-
"[object Date]": "date",
|
|
136
|
-
"[object RegExp]": "regExp",
|
|
137
|
-
"[object Undefined]": "undefined",
|
|
138
|
-
"[object Null]": "null",
|
|
139
|
-
"[object Object]": "object"
|
|
140
|
-
};
|
|
141
|
-
return e instanceof Element ? "element" : n[r.call(e)];
|
|
142
|
-
}, deepClone = (e) => {
|
|
129
|
+
const deepClone = (e) => {
|
|
143
130
|
var r = getObjType(e), n;
|
|
144
131
|
if (r === "array")
|
|
145
132
|
n = [];
|
|
@@ -181,10 +168,10 @@ const getObjType = (e) => {
|
|
|
181
168
|
let a;
|
|
182
169
|
t || (e = detailDicGroup(e, n));
|
|
183
170
|
let i = (l) => {
|
|
184
|
-
const
|
|
171
|
+
const s = n.label || DIC_PROPS.label, o = n.value || DIC_PROPS.value, f = n.children || DIC_PROPS.children;
|
|
185
172
|
for (let u = 0; u < l.length; u++) {
|
|
186
173
|
const c = l[u], d = c[f] || [];
|
|
187
|
-
c[
|
|
174
|
+
c[o] === r ? a = t ? c : c[s] : i(d);
|
|
188
175
|
}
|
|
189
176
|
};
|
|
190
177
|
return i(e), a;
|
|
@@ -227,38 +214,37 @@ function uploadFun(e = {}, r) {
|
|
|
227
214
|
}
|
|
228
215
|
export {
|
|
229
216
|
ARRAY_VALUE_LIST as A,
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
DIC_HTTP_PROPS as D,
|
|
217
|
+
dataURLtoFile as B,
|
|
218
|
+
DIC_SPLIT as D,
|
|
233
219
|
INPUT_LIST as I,
|
|
234
220
|
KEY_COMPONENT_NAME as K,
|
|
235
221
|
MULTIPLE_LIST as M,
|
|
236
222
|
RANGE_LIST as R,
|
|
237
223
|
SELECT_LIST as S,
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
224
|
+
detailDataType as a,
|
|
225
|
+
ARRAY_LIST as b,
|
|
226
|
+
createObj as c,
|
|
227
|
+
deepClone as d,
|
|
228
|
+
DATE_LIST as e,
|
|
243
229
|
findObject as f,
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
230
|
+
getFixed as g,
|
|
231
|
+
setAsVal as h,
|
|
232
|
+
getAsVal as i,
|
|
233
|
+
filterParams as j,
|
|
234
|
+
DIC_PROPS as k,
|
|
235
|
+
clearVal as l,
|
|
236
|
+
strCorNum as m,
|
|
237
|
+
DIC_SHOW_SPLIT as n,
|
|
252
238
|
optVal as o,
|
|
253
|
-
|
|
254
|
-
|
|
239
|
+
getPasswordChar as p,
|
|
240
|
+
findByValue as q,
|
|
255
241
|
randomId as r,
|
|
256
242
|
setPx as s,
|
|
257
|
-
|
|
243
|
+
detailDic as t,
|
|
258
244
|
uploadFun as u,
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
245
|
+
getObjValue as v,
|
|
246
|
+
downFile as w,
|
|
247
|
+
isMediaType as x,
|
|
248
|
+
DIC_HTTP_PROPS as y,
|
|
249
|
+
arraySort as z
|
|
264
250
|
};
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { s as n, r as o, f as i } from "../../chunks/AfdColumn.vue_vue_type_template_lang.768f2ed2.js";
|
|
2
|
+
import { d as l } from "../../chunks/util.80e28481.js";
|
|
3
|
+
import { n as r } from "../../chunks/vueComponentNormalizer.71e2aa87.js";
|
|
4
|
+
const m = {
|
|
5
|
+
name: "AfdColumn",
|
|
6
|
+
props: {
|
|
7
|
+
column: []
|
|
8
|
+
},
|
|
9
|
+
emits: ["submit"],
|
|
10
|
+
data() {
|
|
11
|
+
return {
|
|
12
|
+
fields: i,
|
|
13
|
+
visible: !1,
|
|
14
|
+
list: []
|
|
15
|
+
};
|
|
16
|
+
},
|
|
17
|
+
watch: {
|
|
18
|
+
column: {
|
|
19
|
+
handler(e) {
|
|
20
|
+
this.list = e;
|
|
21
|
+
},
|
|
22
|
+
deep: !0,
|
|
23
|
+
immediate: !0
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
methods: {
|
|
27
|
+
handleSubmit() {
|
|
28
|
+
this.$emit("submit", l(this.list)), this.visible = !1;
|
|
29
|
+
},
|
|
30
|
+
handleDic(e) {
|
|
31
|
+
console.log(e), this.$message.error("暂未实现");
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}, s = {};
|
|
35
|
+
var a = /* @__PURE__ */ r(
|
|
36
|
+
m,
|
|
37
|
+
o,
|
|
38
|
+
n,
|
|
39
|
+
!1,
|
|
40
|
+
u,
|
|
41
|
+
null,
|
|
42
|
+
null,
|
|
43
|
+
null
|
|
44
|
+
);
|
|
45
|
+
function u(e) {
|
|
46
|
+
for (let t in s)
|
|
47
|
+
this[t] = s[t];
|
|
48
|
+
}
|
|
49
|
+
const p = /* @__PURE__ */ function() {
|
|
50
|
+
return a.exports;
|
|
51
|
+
}();
|
|
52
|
+
export {
|
|
53
|
+
p as default
|
|
54
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { formatDate as d } from "@web-utils/core";
|
|
2
|
-
import { s as l } from "../../chunks/util.
|
|
2
|
+
import { s as l } from "../../chunks/util.80e28481.js";
|
|
3
3
|
import { n as u } from "../../chunks/vueComponentNormalizer.71e2aa87.js";
|
|
4
4
|
var m = function() {
|
|
5
5
|
var t = this, o = t.$createElement, e = t._self._c || o;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import s from "element-ui/lib/scrollbar";
|
|
2
|
-
import { s as o } from "../../chunks/util.
|
|
2
|
+
import { s as o } from "../../chunks/util.80e28481.js";
|
|
3
3
|
import { n as l } from "../../chunks/vueComponentNormalizer.71e2aa87.js";
|
|
4
4
|
var i = function() {
|
|
5
5
|
var t = this, e = t.$createElement, n = t._self._c || e;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { z as s, k as l } from "../../chunks/util.80e28481.js";
|
|
2
|
+
import { isBlank as p } from "@web-utils/core";
|
|
2
3
|
import { n as c } from "../../chunks/vueComponentNormalizer.71e2aa87.js";
|
|
3
4
|
var d = function() {
|
|
4
5
|
var t = this, n = t.$createElement, e = t._self._c || n;
|
|
@@ -32,8 +33,8 @@ var d = function() {
|
|
|
32
33
|
})], null, !0)
|
|
33
34
|
})];
|
|
34
35
|
}), t._t("footer")], 2);
|
|
35
|
-
},
|
|
36
|
-
const
|
|
36
|
+
}, f = [];
|
|
37
|
+
const a = {
|
|
37
38
|
name: "Column",
|
|
38
39
|
inject: ["crud"],
|
|
39
40
|
provide() {
|
|
@@ -93,9 +94,9 @@ const f = {
|
|
|
93
94
|
}
|
|
94
95
|
}, u = {};
|
|
95
96
|
var h = /* @__PURE__ */ c(
|
|
96
|
-
f,
|
|
97
|
-
d,
|
|
98
97
|
a,
|
|
98
|
+
d,
|
|
99
|
+
f,
|
|
99
100
|
!1,
|
|
100
101
|
_,
|
|
101
102
|
null,
|
|
@@ -106,9 +107,9 @@ function _(t) {
|
|
|
106
107
|
for (let n in u)
|
|
107
108
|
this[n] = u[n];
|
|
108
109
|
}
|
|
109
|
-
const
|
|
110
|
+
const C = /* @__PURE__ */ function() {
|
|
110
111
|
return h.exports;
|
|
111
112
|
}();
|
|
112
113
|
export {
|
|
113
|
-
|
|
114
|
+
C as default
|
|
114
115
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { c as r } from "../../chunks/config.46422d7f.js";
|
|
2
|
-
import { o as d } from "../../chunks/util.
|
|
2
|
+
import { o as d } from "../../chunks/util.80e28481.js";
|
|
3
3
|
import { n as c } from "../../chunks/vueComponentNormalizer.71e2aa87.js";
|
|
4
4
|
var a = function() {
|
|
5
5
|
var e = this, n = e.$createElement, t = e._self._c || n;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { c as u } from "../../chunks/config.46422d7f.js";
|
|
2
2
|
import { p as d } from "../../chunks/permission.ce5d2121.js";
|
|
3
|
-
import { o as a } from "../../chunks/util.
|
|
3
|
+
import { o as a } from "../../chunks/util.80e28481.js";
|
|
4
4
|
import { n as l } from "../../chunks/vueComponentNormalizer.71e2aa87.js";
|
|
5
5
|
var m = function() {
|
|
6
6
|
var e = this, o = e.$createElement, r = e._self._c || o;
|