x-essential-lib 0.5.16 → 0.5.18
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/composables/permission.d.ts +1 -1
- package/dist/index.js +275 -293
- package/dist/store/global.d.ts +2 -8
- package/dist/store/index.d.ts +1 -0
- package/dist/utils/core.d.ts +0 -7
- package/dist/utils/permission.d.ts +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,11 +1,19 @@
|
|
|
1
1
|
(function(){"use strict";try{if(typeof document<"u"){var a=document.createElement("style");a.id="x-essential-lib",a.appendChild(document.createTextNode('.x-cont[data-v-f4ad116e]{position:absolute;top:0;left:0;bottom:0;right:0;display:flex;align-items:center;justify-content:center}.lds-spinner[data-v-f4ad116e]{color:official;display:inline-block;position:relative;width:40px;height:40px}.lds-spinner div[data-v-f4ad116e]{transform-origin:20px 20px;animation:lds-spinner-f4ad116e 1.2s linear infinite}.lds-spinner div[data-v-f4ad116e]:after{content:" ";display:block;position:absolute;top:3px;left:18px;width:2px;height:6px;border-radius:5%;background:#9e9e9e}.lds-spinner div[data-v-f4ad116e]:nth-child(1){transform:rotate(0);animation-delay:-1.1s}.lds-spinner div[data-v-f4ad116e]:nth-child(2){transform:rotate(30deg);animation-delay:-1s}.lds-spinner div[data-v-f4ad116e]:nth-child(3){transform:rotate(60deg);animation-delay:-.9s}.lds-spinner div[data-v-f4ad116e]:nth-child(4){transform:rotate(90deg);animation-delay:-.8s}.lds-spinner div[data-v-f4ad116e]:nth-child(5){transform:rotate(120deg);animation-delay:-.7s}.lds-spinner div[data-v-f4ad116e]:nth-child(6){transform:rotate(150deg);animation-delay:-.6s}.lds-spinner div[data-v-f4ad116e]:nth-child(7){transform:rotate(180deg);animation-delay:-.5s}.lds-spinner div[data-v-f4ad116e]:nth-child(8){transform:rotate(210deg);animation-delay:-.4s}.lds-spinner div[data-v-f4ad116e]:nth-child(9){transform:rotate(240deg);animation-delay:-.3s}.lds-spinner div[data-v-f4ad116e]:nth-child(10){transform:rotate(270deg);animation-delay:-.2s}.lds-spinner div[data-v-f4ad116e]:nth-child(11){transform:rotate(300deg);animation-delay:-.1s}.lds-spinner div[data-v-f4ad116e]:nth-child(12){transform:rotate(330deg);animation-delay:0s}@keyframes lds-spinner-f4ad116e{0%{opacity:1}to{opacity:0}}.x-cont[data-v-0ce1c82d]{position:absolute;left:50%;bottom:20px;transform:translate(-50%);z-index:9999}')),document.head.appendChild(a)}}catch(t){console.error("vite-plugin-css-injected-by-js",t)}})();
|
|
2
|
-
import { ref as
|
|
3
|
-
import { useLocale as
|
|
4
|
-
import { defineStore as
|
|
5
|
-
import
|
|
6
|
-
import { useRouter as
|
|
7
|
-
const
|
|
8
|
-
const e =
|
|
2
|
+
import { ref as i, computed as g, onMounted as S, onBeforeUnmount as j, defineComponent as T, watch as X, resolveComponent as m, openBlock as b, createBlock as O, unref as z, isRef as G, withKeys as F, withModifiers as U, withCtx as h, createVNode as y, createTextVNode as q, toDisplayString as V, createElementBlock as N, normalizeStyle as ie, pushScopeId as ge, popScopeId as ve, createElementVNode as v, reactive as me, Fragment as he, renderList as we, createCommentVNode as ye } from "vue";
|
|
3
|
+
import { useLocale as J, useTheme as K, useDisplay as xe } from "vuetify";
|
|
4
|
+
import { defineStore as oe } from "pinia";
|
|
5
|
+
import ke from "axios";
|
|
6
|
+
import { useRouter as le, useRoute as be } from "vue-router";
|
|
7
|
+
const Ce = oe("global", () => {
|
|
8
|
+
const e = i(), a = i("en"), t = i({}), l = i("");
|
|
9
|
+
return {
|
|
10
|
+
dark: e,
|
|
11
|
+
locale: a,
|
|
12
|
+
permissionObjects: t,
|
|
13
|
+
permissionChecksum: l
|
|
14
|
+
};
|
|
15
|
+
}), ne = oe("viewMgr", () => {
|
|
16
|
+
const e = i([]);
|
|
9
17
|
function a() {
|
|
10
18
|
return e.value.length <= 0;
|
|
11
19
|
}
|
|
@@ -15,14 +23,14 @@ const re = be("viewMgr", () => {
|
|
|
15
23
|
return e.value[u - 1];
|
|
16
24
|
}
|
|
17
25
|
function l(u) {
|
|
18
|
-
return e.value.find((
|
|
26
|
+
return e.value.find((_) => _ === u) !== void 0;
|
|
19
27
|
}
|
|
20
28
|
function o(u) {
|
|
21
29
|
e.value.push(u);
|
|
22
30
|
}
|
|
23
31
|
function r(u) {
|
|
24
|
-
const
|
|
25
|
-
|
|
32
|
+
const _ = e.value.findIndex((s) => s === u);
|
|
33
|
+
_ !== -1 && e.value.splice(_, e.value.length - _);
|
|
26
34
|
}
|
|
27
35
|
function n() {
|
|
28
36
|
console.assert(e.value.length > 0), e.value.pop();
|
|
@@ -42,7 +50,7 @@ const re = be("viewMgr", () => {
|
|
|
42
50
|
};
|
|
43
51
|
});
|
|
44
52
|
/*! js-cookie v3.0.5 | MIT */
|
|
45
|
-
function
|
|
53
|
+
function L(e) {
|
|
46
54
|
for (var a = 1; a < arguments.length; a++) {
|
|
47
55
|
var t = arguments[a];
|
|
48
56
|
for (var l in t)
|
|
@@ -50,7 +58,7 @@ function z(e) {
|
|
|
50
58
|
}
|
|
51
59
|
return e;
|
|
52
60
|
}
|
|
53
|
-
var
|
|
61
|
+
var De = {
|
|
54
62
|
read: function(e) {
|
|
55
63
|
return e[0] === '"' && (e = e.slice(1, -1)), e.replace(/(%[\dA-F]{2})+/gi, decodeURIComponent);
|
|
56
64
|
},
|
|
@@ -61,10 +69,10 @@ var Ve = {
|
|
|
61
69
|
);
|
|
62
70
|
}
|
|
63
71
|
};
|
|
64
|
-
function
|
|
72
|
+
function H(e, a) {
|
|
65
73
|
function t(o, r, n) {
|
|
66
74
|
if (!(typeof document > "u")) {
|
|
67
|
-
n =
|
|
75
|
+
n = L({}, a, n), typeof n.expires == "number" && (n.expires = new Date(Date.now() + n.expires * 864e5)), n.expires && (n.expires = n.expires.toUTCString()), o = encodeURIComponent(o).replace(/%(2[346B]|5E|60|7C)/g, decodeURIComponent).replace(/[()]/g, escape);
|
|
68
76
|
var c = "";
|
|
69
77
|
for (var u in n)
|
|
70
78
|
n[u] && (c += "; " + u, n[u] !== !0 && (c += "=" + n[u].split(";")[0]));
|
|
@@ -74,10 +82,10 @@ function X(e, a) {
|
|
|
74
82
|
function l(o) {
|
|
75
83
|
if (!(typeof document > "u" || arguments.length && !o)) {
|
|
76
84
|
for (var r = document.cookie ? document.cookie.split("; ") : [], n = {}, c = 0; c < r.length; c++) {
|
|
77
|
-
var u = r[c].split("="),
|
|
85
|
+
var u = r[c].split("="), _ = u.slice(1).join("=");
|
|
78
86
|
try {
|
|
79
|
-
var
|
|
80
|
-
if (n[
|
|
87
|
+
var s = decodeURIComponent(u[0]);
|
|
88
|
+
if (n[s] = e.read(_, s), o === s)
|
|
81
89
|
break;
|
|
82
90
|
} catch {
|
|
83
91
|
}
|
|
@@ -93,16 +101,16 @@ function X(e, a) {
|
|
|
93
101
|
t(
|
|
94
102
|
o,
|
|
95
103
|
"",
|
|
96
|
-
|
|
104
|
+
L({}, r, {
|
|
97
105
|
expires: -1
|
|
98
106
|
})
|
|
99
107
|
);
|
|
100
108
|
},
|
|
101
109
|
withAttributes: function(o) {
|
|
102
|
-
return
|
|
110
|
+
return H(this.converter, L({}, this.attributes, o));
|
|
103
111
|
},
|
|
104
112
|
withConverter: function(o) {
|
|
105
|
-
return
|
|
113
|
+
return H(L({}, this.converter, o), this.attributes);
|
|
106
114
|
}
|
|
107
115
|
},
|
|
108
116
|
{
|
|
@@ -111,47 +119,47 @@ function X(e, a) {
|
|
|
111
119
|
}
|
|
112
120
|
);
|
|
113
121
|
}
|
|
114
|
-
var
|
|
115
|
-
function
|
|
116
|
-
const a =
|
|
122
|
+
var I = H(De, { path: "/" });
|
|
123
|
+
function at(e) {
|
|
124
|
+
const a = ke.create({
|
|
117
125
|
timeout: 6e3
|
|
118
126
|
});
|
|
119
127
|
return a.defaults.baseURL = e.baseUrl, a.interceptors.request.use(
|
|
120
|
-
(t) =>
|
|
128
|
+
(t) => Ve(t),
|
|
121
129
|
(t) => {
|
|
122
130
|
Se(t, e.onError);
|
|
123
131
|
}
|
|
124
132
|
), a.interceptors.response.use(
|
|
125
|
-
(t) =>
|
|
126
|
-
(t) =>
|
|
133
|
+
(t) => Re(t),
|
|
134
|
+
(t) => qe(t, e.onError)
|
|
127
135
|
), a;
|
|
128
136
|
}
|
|
129
|
-
function
|
|
130
|
-
const a =
|
|
137
|
+
function Ve(e) {
|
|
138
|
+
const a = I.get("accessToken") ?? "";
|
|
131
139
|
return e.headers.Authorization = "Basic " + a, e.headers["Content-Type"] = "application/json", e.data = JSON.stringify(e.data), e;
|
|
132
140
|
}
|
|
133
141
|
function Se(e, a) {
|
|
134
142
|
console.error(e), a("request timeout");
|
|
135
143
|
}
|
|
136
|
-
function
|
|
144
|
+
function Re(e) {
|
|
137
145
|
return e.data;
|
|
138
146
|
}
|
|
139
|
-
function
|
|
147
|
+
function qe(e, a) {
|
|
140
148
|
var o;
|
|
141
149
|
const t = e.response;
|
|
142
150
|
if (!t)
|
|
143
151
|
return Promise.reject(e);
|
|
144
|
-
t.status === 401 &&
|
|
152
|
+
t.status === 401 && Ie();
|
|
145
153
|
let l = (o = t.data) == null ? void 0 : o.message;
|
|
146
154
|
return l || (l = {
|
|
147
155
|
code: t.status,
|
|
148
156
|
message: t.statusText
|
|
149
157
|
}), a(l), Promise.reject(e);
|
|
150
158
|
}
|
|
151
|
-
function
|
|
152
|
-
|
|
159
|
+
function Ie() {
|
|
160
|
+
I.remove("accessToken"), I.remove("refreshToken"), I.remove("activeOrg"), le().replace({ path: "/passport/login" });
|
|
153
161
|
}
|
|
154
|
-
function
|
|
162
|
+
function Oe(e) {
|
|
155
163
|
return { all: e = e || /* @__PURE__ */ new Map(), on: function(a, t) {
|
|
156
164
|
var l = e.get(a);
|
|
157
165
|
l ? l.push(t) : e.set(a, [t]);
|
|
@@ -168,19 +176,9 @@ function je(e) {
|
|
|
168
176
|
} };
|
|
169
177
|
}
|
|
170
178
|
const p = function() {
|
|
171
|
-
return window.eventBus || (window.eventBus =
|
|
172
|
-
}(), ee = function() {
|
|
173
|
-
return window.dark || (window.dark = f()), window.dark;
|
|
174
|
-
}(), nt = function() {
|
|
175
|
-
return window.locale || (window.locale = f("en")), window.locale;
|
|
176
|
-
}(), Te = function() {
|
|
177
|
-
return window.permissionObjects || (window.permissionObjects = f()), window.permissionObjects;
|
|
178
|
-
}(), rt = function() {
|
|
179
|
-
return window.permissionChecksum || (window.permissionChecksum = f("")), window.permissionChecksum;
|
|
180
|
-
}(), ct = function() {
|
|
181
|
-
return window.mainActive || (window.mainActive = f(1)), window.mainAcitve;
|
|
179
|
+
return window.eventBus || (window.eventBus = Oe()), window.eventBus;
|
|
182
180
|
}();
|
|
183
|
-
async function
|
|
181
|
+
async function ot(e) {
|
|
184
182
|
return new Promise((a) => {
|
|
185
183
|
setTimeout(a, e);
|
|
186
184
|
});
|
|
@@ -194,7 +192,7 @@ async function Q(e, a, t) {
|
|
|
194
192
|
r();
|
|
195
193
|
});
|
|
196
194
|
}
|
|
197
|
-
function
|
|
195
|
+
function lt(e) {
|
|
198
196
|
var l, o;
|
|
199
197
|
if (!window.appAppear) {
|
|
200
198
|
window.appAppear = !0;
|
|
@@ -205,53 +203,53 @@ function pt(e) {
|
|
|
205
203
|
t.add("app-reset");
|
|
206
204
|
}, 0));
|
|
207
205
|
}
|
|
208
|
-
let
|
|
209
|
-
function
|
|
206
|
+
let ee = Date.now();
|
|
207
|
+
function re() {
|
|
210
208
|
const e = Date.now();
|
|
211
|
-
return e -
|
|
209
|
+
return e - ee > 500 ? (ee = e, !0) : !1;
|
|
212
210
|
}
|
|
213
|
-
let
|
|
214
|
-
function
|
|
215
|
-
return ++
|
|
211
|
+
let je = 0;
|
|
212
|
+
function ce() {
|
|
213
|
+
return ++je;
|
|
216
214
|
}
|
|
217
|
-
async function
|
|
218
|
-
if (!
|
|
215
|
+
async function nt(e) {
|
|
216
|
+
if (!re())
|
|
219
217
|
return;
|
|
220
218
|
let a = !1, t;
|
|
221
219
|
const l = (r) => {
|
|
222
220
|
t = r, a = !0;
|
|
223
|
-
}, o =
|
|
221
|
+
}, o = ce();
|
|
224
222
|
return p.on("confirmDlgResult" + o, l), p.emit("confirmDlg", { ...e, seq: o }), await Q(() => a), p.off("confirmDlgResult" + o, l), t;
|
|
225
223
|
}
|
|
226
|
-
async function
|
|
227
|
-
if (!
|
|
224
|
+
async function rt(e) {
|
|
225
|
+
if (!re())
|
|
228
226
|
return;
|
|
229
227
|
let a = !1, t;
|
|
230
228
|
const l = (r) => {
|
|
231
229
|
t = r, a = !0;
|
|
232
|
-
}, o =
|
|
230
|
+
}, o = ce();
|
|
233
231
|
return p.on("promptDlgResult" + o, l), p.emit("promptDlg", { ...e, seq: o }), await Q(() => a), p.off("promptDlgResult" + o, l), t;
|
|
234
232
|
}
|
|
235
|
-
function
|
|
233
|
+
function ct() {
|
|
236
234
|
p.emit("openWaitDlg");
|
|
237
235
|
}
|
|
238
|
-
function
|
|
236
|
+
function ut() {
|
|
239
237
|
p.emit("closeWaitDlg");
|
|
240
238
|
}
|
|
241
|
-
function
|
|
239
|
+
function pt(e, a) {
|
|
242
240
|
p.emit("message", { type: "error", text: e, timeout: a });
|
|
243
241
|
}
|
|
244
|
-
function
|
|
242
|
+
function _t(e, a) {
|
|
245
243
|
p.emit("message", { type: "info", text: e, timeout: a });
|
|
246
244
|
}
|
|
247
|
-
function
|
|
245
|
+
function st(e, a) {
|
|
248
246
|
p.emit("message", { type: "success", text: e, timeout: a });
|
|
249
247
|
}
|
|
250
|
-
function
|
|
248
|
+
function dt(e, a) {
|
|
251
249
|
p.emit("message", { type: "warning", text: e, timeout: a });
|
|
252
250
|
}
|
|
253
|
-
var
|
|
254
|
-
function
|
|
251
|
+
var Te = /* @__PURE__ */ ((e) => (e.list_app_group = "list_app_group", e.create_app_group = "create_app_group", e.delete_app_group = "delete_app_group", e.update_app_group = "update_app_group", e.arrange_app_group = "arrange_app_group", e.list_app = "list_app", e.get_app = "get_app", e.create_app = "create_app", e.delete_app = "delete_app", e.update_app = "update_app", e.list_app_release = "list_app_release", e.get_app_release = "get_app_release", e.create_app_release = "create_app_release", e.delete_app_release = "delete_app_release", e.deploy_app_release = "deploy_app_release", e.open_app_layer = "open_app_layer", e.open_app = "open_app", e.list_calc_space = "list_calc_space", e.get_calc_space = "get_calc_space", e.create_calc_space = "create_calc_space", e.delete_calc_space = "delete_calc_space", e.update_calc_space = "update_calc_space", e.arrange_calc_space = "arrange_calc_space", e.list_func_group = "list_func_group", e.create_func_group = "create_func_group", e.delete_func_group = "delete_func_group", e.update_func_group = "update_func_group", e.arrange_func_group = "arrange_func_group", e.list_func = "list_func", e.get_func = "get_func", e.create_func = "create_func", e.delete_func = "delete_func", e.update_func = "update_func", e.debug_func = "debug_func", e.call_func = "call_func", e.list_func_release = "list_func_release", e.get_func_release = "get_func_release", e.create_func_release = "create_func_release", e.delete_func_release = "delete_func_release", e.deploy_func_release = "deploy_func_release", e.list_flow_group = "list_flow_group", e.create_flow_group = "create_flow_group", e.delete_flow_group = "delete_flow_group", e.update_flow_group = "update_flow_group", e.arrange_flow_group = "arrange_flow_group", e.list_flow = "list_flow", e.get_flow = "get_flow", e.create_flow = "create_flow", e.delete_flow = "delete_flow", e.update_flow = "update_flow", e.call_flow = "call_flow", e.list_flow_release = "list_flow_release", e.get_flow_release = "get_flow_release", e.create_flow_release = "create_flow_release", e.delete_flow_release = "delete_flow_release", e.deploy_flow_release = "deploy_flow_release", e.list_task = "list_task", e.get_task = "get_task", e.create_task = "create_task", e.delete_task = "delete_task", e.update_task = "update_task", e.call_task = "call_task", e.open_calc_layer = "open_calc_layer", e.list_db_space = "list_db_space", e.get_db_space = "get_db_space", e.create_db_space = "create_db_space", e.delete_db_space = "delete_db_space", e.update_db_space = "update_db_space", e.arrange_db_space = "arrange_db_space", e.list_model_group = "list_model_group", e.create_model_group = "create_model_group", e.delete_model_group = "delete_model_group", e.update_model_group = "update_model_group", e.arrange_model_group = "arrange_model_group", e.list_model = "list_model", e.get_model = "get_model", e.create_model = "create_model", e.delete_model = "delete_model", e.update_model = "update_model", e.get_model_data = "get_model_data", e.create_model_data = "create_model_data", e.delete_model_data = "delete_model_data", e.update_model_data = "update_model_data", e.get_graph = "get_graph", e.update_graph = "update_graph", e.list_change = "list_change", e.apply_change = "apply_change", e.open_data_layer = "open_data_layer", e.list_asset_space = "list_asset_space", e.get_asset_space = "get_asset_space", e.create_asset_space = "create_asset_space", e.delete_asset_space = "delete_asset_space", e.update_asset_space = "update_asset_space", e.arrange_asset_space = "arrange_asset_space", e.list_dir = "list_dir", e.create_dir = "create_dir", e.delete_dir = "delete_dir", e.update_dir = "update_dir", e.move_dir = "move_dir", e.list_asset = "list_asset", e.get_asset = "get_asset", e.create_asset = "create_asset", e.delete_asset = "delete_asset", e.update_asset = "update_asset", e.move_asset = "move_asset", e.open_asset_layer = "open_asset_layer", e.list_org_member = "list_org_member", e.add_org_member = "add_org_member", e.remove_org_member = "remove_org_member", e.update_org_member = "update_org_member", e.list_org_role = "list_org_role", e.get_org_role = "get_org_role", e.create_org_role = "create_org_role", e.delete_org_role = "delete_org_role", e.update_org_role = "update_org_role", e.arrange_org_role = "arrange_org_role", e.get_org_structure = "get_org_structure", e.update_org_structure = "update_org_structure", e.filter_model = "filter_model", e))(Te || {});
|
|
252
|
+
function ft(e, a) {
|
|
255
253
|
if (!e)
|
|
256
254
|
return !1;
|
|
257
255
|
let t = e;
|
|
@@ -264,11 +262,7 @@ function ae(e, a) {
|
|
|
264
262
|
return !1;
|
|
265
263
|
}), Object.keys(t).length <= 0);
|
|
266
264
|
}
|
|
267
|
-
|
|
268
|
-
const t = Te.value[e];
|
|
269
|
-
return t ? a ? !(!ae(t.includes, a) || ae(t.excludes, a)) : !0 : !1;
|
|
270
|
-
}
|
|
271
|
-
const Ee = [
|
|
265
|
+
const Be = [
|
|
272
266
|
{ path: "/passport/login", level: 0 },
|
|
273
267
|
{ path: "/passport/loginAccount", level: 1 },
|
|
274
268
|
{ path: "/passport/register", level: 1 },
|
|
@@ -290,7 +284,7 @@ const Ee = [
|
|
|
290
284
|
function Y(e) {
|
|
291
285
|
let a, t = 0;
|
|
292
286
|
const l = e.split("/").filter((o) => o.trim() !== "");
|
|
293
|
-
return
|
|
287
|
+
return Be.forEach((o) => {
|
|
294
288
|
const r = o.path.split("/").filter((c) => c.trim() !== "");
|
|
295
289
|
let n = 0;
|
|
296
290
|
for (let c = 0; c < l.length && !(c >= r.length || l[c] !== r[c]); c++)
|
|
@@ -298,7 +292,7 @@ function Y(e) {
|
|
|
298
292
|
n > 0 && n >= t && (a = o, t = n);
|
|
299
293
|
}), a;
|
|
300
294
|
}
|
|
301
|
-
function
|
|
295
|
+
function te(e) {
|
|
302
296
|
if (e === "/")
|
|
303
297
|
return { app: "", path: "/", level: -1 };
|
|
304
298
|
const a = Y(e);
|
|
@@ -307,21 +301,21 @@ function oe(e) {
|
|
|
307
301
|
const t = e.split("/");
|
|
308
302
|
return console.assert(t.length >= 2), { app: t[1], path: a.path, level: a.level };
|
|
309
303
|
}
|
|
310
|
-
const
|
|
304
|
+
const ae = i("");
|
|
311
305
|
function k(e, a) {
|
|
312
|
-
const t =
|
|
306
|
+
const t = te(e), l = te(a), o = t.app === l.app, r = t.path === l.path, n = t.level >= l.level;
|
|
313
307
|
console.info(
|
|
314
308
|
`~~~~before route change~~~~ ${l.path} -> ${t.path} inner=${o} forward=${n}`
|
|
315
|
-
), o ? r ?
|
|
309
|
+
), o ? r ? ae.value = "" : ae.value = n ? "inner-left" : "inner-right" : window.routeExtras = { forward: n };
|
|
316
310
|
}
|
|
317
|
-
function
|
|
318
|
-
return !!
|
|
311
|
+
function Ee() {
|
|
312
|
+
return !!I.get("accessToken");
|
|
319
313
|
}
|
|
320
|
-
function
|
|
321
|
-
return !!
|
|
314
|
+
function Ae() {
|
|
315
|
+
return !!I.get("activeOrg");
|
|
322
316
|
}
|
|
323
|
-
function
|
|
324
|
-
const l =
|
|
317
|
+
function it(e, a, t) {
|
|
318
|
+
const l = Ee(), o = Ae(), r = Y(e.path);
|
|
325
319
|
if (!r) {
|
|
326
320
|
t();
|
|
327
321
|
return;
|
|
@@ -361,7 +355,7 @@ function ht(e, a, t) {
|
|
|
361
355
|
k(e.path, a.path), t();
|
|
362
356
|
}
|
|
363
357
|
function Z(e, a) {
|
|
364
|
-
const t =
|
|
358
|
+
const t = ne(), l = g({
|
|
365
359
|
get() {
|
|
366
360
|
return t.hasView(e);
|
|
367
361
|
},
|
|
@@ -371,82 +365,82 @@ function Z(e, a) {
|
|
|
371
365
|
}), o = (r) => {
|
|
372
366
|
a == null || a(r), l.value = !0;
|
|
373
367
|
};
|
|
374
|
-
return
|
|
368
|
+
return S(() => {
|
|
375
369
|
p.on(e, o);
|
|
376
|
-
}),
|
|
370
|
+
}), j(() => {
|
|
377
371
|
p.off(e, o);
|
|
378
372
|
}), { open: l };
|
|
379
373
|
}
|
|
380
|
-
const
|
|
374
|
+
const Ue = /* @__PURE__ */ T({
|
|
381
375
|
__name: "index",
|
|
382
376
|
setup(e) {
|
|
383
|
-
const a =
|
|
384
|
-
var
|
|
385
|
-
return ((
|
|
386
|
-
}), u =
|
|
387
|
-
var
|
|
388
|
-
return ((
|
|
389
|
-
}),
|
|
390
|
-
var
|
|
391
|
-
return ((
|
|
392
|
-
}),
|
|
393
|
-
var
|
|
394
|
-
return ((
|
|
377
|
+
const a = J(), { open: t } = Z("confirmDlg"), l = i(""), o = i(""), r = i(), n = i(), c = g(() => {
|
|
378
|
+
var f;
|
|
379
|
+
return ((f = r.value) == null ? void 0 : f.color) ?? "primary";
|
|
380
|
+
}), u = g(() => {
|
|
381
|
+
var f;
|
|
382
|
+
return ((f = r.value) == null ? void 0 : f.text) ?? a.t("cancel");
|
|
383
|
+
}), _ = g(() => {
|
|
384
|
+
var f;
|
|
385
|
+
return ((f = n.value) == null ? void 0 : f.color) ?? "primary";
|
|
386
|
+
}), s = g(() => {
|
|
387
|
+
var f;
|
|
388
|
+
return ((f = n.value) == null ? void 0 : f.text) ?? a.t("confirm");
|
|
395
389
|
});
|
|
396
|
-
let
|
|
397
|
-
const M = (
|
|
398
|
-
l.value =
|
|
390
|
+
let R = 0, C = !1;
|
|
391
|
+
const M = (f) => {
|
|
392
|
+
l.value = f.title, o.value = f.text, r.value = f.cancel, n.value = f.confirm, R = f.seq, C = !1, t.value = !0;
|
|
399
393
|
};
|
|
400
|
-
|
|
394
|
+
S(() => {
|
|
401
395
|
p.on("confirmDlg", M);
|
|
402
|
-
}),
|
|
396
|
+
}), j(() => {
|
|
403
397
|
p.off("confirmDlg", M);
|
|
404
398
|
});
|
|
405
399
|
const $ = () => {
|
|
406
|
-
t.value = !1,
|
|
400
|
+
t.value = !1, C || (p.emit("confirmDlgResult" + R, !0), C = !0);
|
|
407
401
|
};
|
|
408
|
-
return
|
|
409
|
-
!
|
|
410
|
-
}), (
|
|
411
|
-
const
|
|
412
|
-
return b(),
|
|
413
|
-
modelValue:
|
|
414
|
-
"onUpdate:modelValue": x[1] || (x[1] = (
|
|
402
|
+
return X(t, (f) => {
|
|
403
|
+
!f && !C && (p.emit("confirmDlgResult" + R, !1), C = !0);
|
|
404
|
+
}), (f, x) => {
|
|
405
|
+
const D = m("v-card-text"), B = m("v-btn"), W = m("v-card-actions"), d = m("v-card"), w = m("v-dialog");
|
|
406
|
+
return b(), O(w, {
|
|
407
|
+
modelValue: z(t),
|
|
408
|
+
"onUpdate:modelValue": x[1] || (x[1] = (E) => G(t) ? t.value = E : null),
|
|
415
409
|
onKeydown: [
|
|
416
|
-
x[2] || (x[2] = F(U((
|
|
410
|
+
x[2] || (x[2] = F(U((E) => t.value = !1, ["stop", "prevent"]), ["esc"])),
|
|
417
411
|
F(U($, ["stop", "prevent"]), ["enter"])
|
|
418
412
|
],
|
|
419
413
|
transition: "dialog-top-transition",
|
|
420
414
|
"max-width": "600px"
|
|
421
415
|
}, {
|
|
422
|
-
default:
|
|
423
|
-
y(
|
|
424
|
-
default:
|
|
425
|
-
y(
|
|
426
|
-
default:
|
|
427
|
-
|
|
416
|
+
default: h(() => [
|
|
417
|
+
y(d, { title: l.value }, {
|
|
418
|
+
default: h(() => [
|
|
419
|
+
y(D, null, {
|
|
420
|
+
default: h(() => [
|
|
421
|
+
q(V(o.value), 1)
|
|
428
422
|
]),
|
|
429
423
|
_: 1
|
|
430
424
|
}),
|
|
431
425
|
y(W, { class: "d-flex justify-end" }, {
|
|
432
|
-
default:
|
|
433
|
-
y(
|
|
434
|
-
onClick: x[0] || (x[0] = (
|
|
426
|
+
default: h(() => [
|
|
427
|
+
y(B, {
|
|
428
|
+
onClick: x[0] || (x[0] = (E) => t.value = !1),
|
|
435
429
|
color: c.value,
|
|
436
430
|
variant: "text"
|
|
437
431
|
}, {
|
|
438
|
-
default:
|
|
439
|
-
|
|
432
|
+
default: h(() => [
|
|
433
|
+
q(V(u.value), 1)
|
|
440
434
|
]),
|
|
441
435
|
_: 1
|
|
442
436
|
}, 8, ["color"]),
|
|
443
|
-
y(
|
|
437
|
+
y(B, {
|
|
444
438
|
onClick: $,
|
|
445
|
-
color:
|
|
439
|
+
color: _.value,
|
|
446
440
|
variant: "text"
|
|
447
441
|
}, {
|
|
448
|
-
default:
|
|
449
|
-
|
|
442
|
+
default: h(() => [
|
|
443
|
+
q(V(s.value), 1)
|
|
450
444
|
]),
|
|
451
445
|
_: 1
|
|
452
446
|
}, 8, ["color"])
|
|
@@ -461,22 +455,22 @@ const $e = /* @__PURE__ */ T({
|
|
|
461
455
|
}, 8, ["modelValue", "onKeydown"]);
|
|
462
456
|
};
|
|
463
457
|
}
|
|
464
|
-
}),
|
|
465
|
-
/* @__PURE__ */
|
|
466
|
-
/* @__PURE__ */
|
|
467
|
-
/* @__PURE__ */
|
|
468
|
-
/* @__PURE__ */
|
|
469
|
-
/* @__PURE__ */
|
|
470
|
-
/* @__PURE__ */
|
|
471
|
-
/* @__PURE__ */
|
|
472
|
-
/* @__PURE__ */
|
|
473
|
-
/* @__PURE__ */
|
|
474
|
-
/* @__PURE__ */
|
|
475
|
-
/* @__PURE__ */
|
|
476
|
-
/* @__PURE__ */
|
|
477
|
-
], -1)),
|
|
478
|
-
|
|
479
|
-
],
|
|
458
|
+
}), Me = (e) => (ge("data-v-f4ad116e"), e = e(), ve(), e), $e = /* @__PURE__ */ Me(() => /* @__PURE__ */ v("div", { class: "lds-spinner" }, [
|
|
459
|
+
/* @__PURE__ */ v("div"),
|
|
460
|
+
/* @__PURE__ */ v("div"),
|
|
461
|
+
/* @__PURE__ */ v("div"),
|
|
462
|
+
/* @__PURE__ */ v("div"),
|
|
463
|
+
/* @__PURE__ */ v("div"),
|
|
464
|
+
/* @__PURE__ */ v("div"),
|
|
465
|
+
/* @__PURE__ */ v("div"),
|
|
466
|
+
/* @__PURE__ */ v("div"),
|
|
467
|
+
/* @__PURE__ */ v("div"),
|
|
468
|
+
/* @__PURE__ */ v("div"),
|
|
469
|
+
/* @__PURE__ */ v("div"),
|
|
470
|
+
/* @__PURE__ */ v("div")
|
|
471
|
+
], -1)), We = [
|
|
472
|
+
$e
|
|
473
|
+
], Le = /* @__PURE__ */ T({
|
|
480
474
|
__name: "index",
|
|
481
475
|
props: {
|
|
482
476
|
zIndex: {
|
|
@@ -485,21 +479,21 @@ const $e = /* @__PURE__ */ T({
|
|
|
485
479
|
}
|
|
486
480
|
},
|
|
487
481
|
setup(e) {
|
|
488
|
-
const a =
|
|
482
|
+
const a = K(), t = e, l = g(() => ({
|
|
489
483
|
background: a.current.value.dark ? "#1e1e1e" : "#ffffff",
|
|
490
484
|
zIndex: t.zIndex
|
|
491
485
|
}));
|
|
492
|
-
return (o, r) => (b(),
|
|
486
|
+
return (o, r) => (b(), N("div", {
|
|
493
487
|
class: "x-cont",
|
|
494
|
-
style:
|
|
495
|
-
},
|
|
488
|
+
style: ie(l.value)
|
|
489
|
+
}, We, 4));
|
|
496
490
|
}
|
|
497
|
-
}),
|
|
491
|
+
}), ue = (e, a) => {
|
|
498
492
|
const t = e.__vccOpts || e;
|
|
499
493
|
for (const [l, o] of a)
|
|
500
494
|
t[l] = o;
|
|
501
495
|
return t;
|
|
502
|
-
},
|
|
496
|
+
}, ze = /* @__PURE__ */ ue(Le, [["__scopeId", "data-v-f4ad116e"]]), Fe = /* @__PURE__ */ T({
|
|
503
497
|
__name: "item",
|
|
504
498
|
props: {
|
|
505
499
|
id: {},
|
|
@@ -509,16 +503,16 @@ const $e = /* @__PURE__ */ T({
|
|
|
509
503
|
},
|
|
510
504
|
emits: ["timeout"],
|
|
511
505
|
setup(e, { emit: a }) {
|
|
512
|
-
const t = e, l =
|
|
513
|
-
return
|
|
506
|
+
const t = e, l = i(!0), o = a;
|
|
507
|
+
return S(() => {
|
|
514
508
|
setTimeout(() => {
|
|
515
509
|
o("timeout", t.id);
|
|
516
510
|
}, t.timeout);
|
|
517
|
-
}),
|
|
511
|
+
}), X(l, (r) => {
|
|
518
512
|
r || o("timeout", t.id);
|
|
519
513
|
}), (r, n) => {
|
|
520
|
-
const c =
|
|
521
|
-
return b(),
|
|
514
|
+
const c = m("v-alert");
|
|
515
|
+
return b(), O(c, {
|
|
522
516
|
modelValue: l.value,
|
|
523
517
|
"onUpdate:modelValue": n[0] || (n[0] = (u) => l.value = u),
|
|
524
518
|
class: "mt-2",
|
|
@@ -532,13 +526,13 @@ const $e = /* @__PURE__ */ T({
|
|
|
532
526
|
}, null, 8, ["modelValue", "type", "text"]);
|
|
533
527
|
};
|
|
534
528
|
}
|
|
535
|
-
}),
|
|
529
|
+
}), Ke = /* @__PURE__ */ T({
|
|
536
530
|
__name: "index",
|
|
537
531
|
setup(e) {
|
|
538
|
-
const a =
|
|
539
|
-
|
|
532
|
+
const a = me({ items: [] });
|
|
533
|
+
S(() => {
|
|
540
534
|
p.on("message", t);
|
|
541
|
-
}),
|
|
535
|
+
}), j(() => {
|
|
542
536
|
p.off("message", t);
|
|
543
537
|
});
|
|
544
538
|
const t = (c) => {
|
|
@@ -547,103 +541,103 @@ const $e = /* @__PURE__ */ T({
|
|
|
547
541
|
n(c);
|
|
548
542
|
};
|
|
549
543
|
let o = 0;
|
|
550
|
-
const r = (c, u,
|
|
551
|
-
const
|
|
552
|
-
a.items.push({ id:
|
|
544
|
+
const r = (c, u, _) => {
|
|
545
|
+
const s = o++;
|
|
546
|
+
a.items.push({ id: s, type: c, text: u, timeout: _ });
|
|
553
547
|
}, n = (c) => {
|
|
554
|
-
const u = a.items.findIndex((
|
|
548
|
+
const u = a.items.findIndex((_) => _.id === c);
|
|
555
549
|
u >= 0 && a.items.splice(u, 1);
|
|
556
550
|
};
|
|
557
|
-
return (c, u) => (b(),
|
|
551
|
+
return (c, u) => (b(), N("div", {
|
|
558
552
|
onClick: u[0] || (u[0] = U(() => {
|
|
559
553
|
}, ["stop"])),
|
|
560
554
|
class: "x-cont d-flex flex-column-reverse align-center"
|
|
561
555
|
}, [
|
|
562
|
-
(b(!0),
|
|
556
|
+
(b(!0), N(he, null, we(a.items, (_) => (b(), O(Fe, {
|
|
563
557
|
onTimeout: l,
|
|
564
|
-
id:
|
|
565
|
-
type:
|
|
566
|
-
text:
|
|
567
|
-
timeout:
|
|
568
|
-
key:
|
|
558
|
+
id: _.id,
|
|
559
|
+
type: _.type,
|
|
560
|
+
text: _.text,
|
|
561
|
+
timeout: _.timeout,
|
|
562
|
+
key: _.id
|
|
569
563
|
}, null, 8, ["id", "type", "text", "timeout"]))), 128))
|
|
570
564
|
]));
|
|
571
565
|
}
|
|
572
|
-
}),
|
|
566
|
+
}), Ne = /* @__PURE__ */ ue(Ke, [["__scopeId", "data-v-0ce1c82d"]]), He = /* @__PURE__ */ T({
|
|
573
567
|
__name: "index",
|
|
574
568
|
setup(e) {
|
|
575
|
-
const a =
|
|
576
|
-
var
|
|
577
|
-
return ((
|
|
578
|
-
}),
|
|
579
|
-
var
|
|
580
|
-
return ((
|
|
581
|
-
}), M =
|
|
582
|
-
var
|
|
583
|
-
return ((
|
|
584
|
-
}), $ =
|
|
585
|
-
var
|
|
586
|
-
return ((
|
|
587
|
-
}),
|
|
588
|
-
let x = 0,
|
|
589
|
-
const
|
|
590
|
-
var
|
|
591
|
-
l.value =
|
|
569
|
+
const a = J(), { open: t } = Z("promptDlg"), l = i(""), o = i(""), r = i(), n = i(), c = i(), u = i(""), _ = i(), s = i(), R = g(() => {
|
|
570
|
+
var d;
|
|
571
|
+
return ((d = _.value) == null ? void 0 : d.color) ?? "primary";
|
|
572
|
+
}), C = g(() => {
|
|
573
|
+
var d;
|
|
574
|
+
return ((d = _.value) == null ? void 0 : d.text) ?? a.t("cancel");
|
|
575
|
+
}), M = g(() => {
|
|
576
|
+
var d;
|
|
577
|
+
return ((d = s.value) == null ? void 0 : d.color) ?? "primary";
|
|
578
|
+
}), $ = g(() => {
|
|
579
|
+
var d;
|
|
580
|
+
return ((d = s.value) == null ? void 0 : d.text) ?? a.t("confirm");
|
|
581
|
+
}), f = i();
|
|
582
|
+
let x = 0, D = !1;
|
|
583
|
+
const B = async (d) => {
|
|
584
|
+
var w;
|
|
585
|
+
l.value = d.title, o.value = d.text, r.value = d.label, n.value = d.placeholder, c.value = d.rules, u.value = d.value, _.value = d.cancel, s.value = d.confirm, x = d.seq, D = !1, t.value = !0, await Q(() => f.value !== void 0, 1e3), (w = f.value) == null || w.focus();
|
|
592
586
|
};
|
|
593
|
-
|
|
594
|
-
p.on("promptDlg",
|
|
595
|
-
}),
|
|
596
|
-
p.off("promptDlg",
|
|
587
|
+
S(() => {
|
|
588
|
+
p.on("promptDlg", B);
|
|
589
|
+
}), j(() => {
|
|
590
|
+
p.off("promptDlg", B);
|
|
597
591
|
});
|
|
598
592
|
const W = () => {
|
|
599
|
-
t.value = !1,
|
|
593
|
+
t.value = !1, D || (p.emit("promptDlgResult" + x, u.value ?? ""), D = !0);
|
|
600
594
|
};
|
|
601
|
-
return
|
|
602
|
-
!
|
|
603
|
-
}), (
|
|
604
|
-
const
|
|
605
|
-
return b(),
|
|
606
|
-
modelValue:
|
|
607
|
-
"onUpdate:modelValue":
|
|
595
|
+
return X(t, (d) => {
|
|
596
|
+
!d && !D && (p.emit("promptDlgResult" + x, void 0), D = !0);
|
|
597
|
+
}), (d, w) => {
|
|
598
|
+
const E = m("v-card-text"), pe = m("v-text-field"), _e = m("v-form"), P = m("v-btn"), se = m("v-card-actions"), de = m("v-card"), fe = m("v-dialog");
|
|
599
|
+
return b(), O(fe, {
|
|
600
|
+
modelValue: z(t),
|
|
601
|
+
"onUpdate:modelValue": w[2] || (w[2] = (A) => G(t) ? t.value = A : null),
|
|
608
602
|
onKeydown: [
|
|
609
|
-
|
|
603
|
+
w[3] || (w[3] = F(U((A) => t.value = !1, ["stop", "prevent"]), ["esc"])),
|
|
610
604
|
F(U(W, ["stop", "prevent"]), ["enter"])
|
|
611
605
|
],
|
|
612
606
|
transition: "dialog-top-transition",
|
|
613
607
|
"max-width": "600px"
|
|
614
608
|
}, {
|
|
615
|
-
default:
|
|
616
|
-
y(
|
|
617
|
-
default:
|
|
618
|
-
o.value ? (b(),
|
|
619
|
-
default:
|
|
620
|
-
|
|
609
|
+
default: h(() => [
|
|
610
|
+
y(de, { title: l.value }, {
|
|
611
|
+
default: h(() => [
|
|
612
|
+
o.value ? (b(), O(E, { key: 0 }, {
|
|
613
|
+
default: h(() => [
|
|
614
|
+
q(V(o.value), 1)
|
|
621
615
|
]),
|
|
622
616
|
_: 1
|
|
623
|
-
})) :
|
|
624
|
-
y(
|
|
625
|
-
default:
|
|
626
|
-
y(
|
|
617
|
+
})) : ye("", !0),
|
|
618
|
+
y(_e, { class: "mx-3" }, {
|
|
619
|
+
default: h(() => [
|
|
620
|
+
y(pe, {
|
|
627
621
|
modelValue: u.value,
|
|
628
|
-
"onUpdate:modelValue":
|
|
622
|
+
"onUpdate:modelValue": w[0] || (w[0] = (A) => u.value = A),
|
|
629
623
|
label: r.value,
|
|
630
624
|
placeholder: n.value,
|
|
631
625
|
rules: c.value,
|
|
632
626
|
ref_key: "target",
|
|
633
|
-
ref:
|
|
627
|
+
ref: f
|
|
634
628
|
}, null, 8, ["modelValue", "label", "placeholder", "rules"])
|
|
635
629
|
]),
|
|
636
630
|
_: 1
|
|
637
631
|
}),
|
|
638
|
-
y(
|
|
639
|
-
default:
|
|
632
|
+
y(se, { class: "d-flex justify-end" }, {
|
|
633
|
+
default: h(() => [
|
|
640
634
|
y(P, {
|
|
641
|
-
onClick:
|
|
642
|
-
color:
|
|
635
|
+
onClick: w[1] || (w[1] = (A) => t.value = !1),
|
|
636
|
+
color: R.value,
|
|
643
637
|
variant: "text"
|
|
644
638
|
}, {
|
|
645
|
-
default:
|
|
646
|
-
|
|
639
|
+
default: h(() => [
|
|
640
|
+
q(V(C.value), 1)
|
|
647
641
|
]),
|
|
648
642
|
_: 1
|
|
649
643
|
}, 8, ["color"]),
|
|
@@ -652,8 +646,8 @@ const $e = /* @__PURE__ */ T({
|
|
|
652
646
|
color: M.value,
|
|
653
647
|
variant: "text"
|
|
654
648
|
}, {
|
|
655
|
-
default:
|
|
656
|
-
|
|
649
|
+
default: h(() => [
|
|
650
|
+
q(V($.value), 1)
|
|
657
651
|
]),
|
|
658
652
|
_: 1
|
|
659
653
|
}, 8, ["color"])
|
|
@@ -668,37 +662,37 @@ const $e = /* @__PURE__ */ T({
|
|
|
668
662
|
}, 8, ["modelValue", "onKeydown"]);
|
|
669
663
|
};
|
|
670
664
|
}
|
|
671
|
-
}),
|
|
665
|
+
}), Xe = { class: "mx-auto my-auto" }, Ge = { class: "d-flex align-center justify-center w-100 h-100" }, Je = /* @__PURE__ */ T({
|
|
672
666
|
__name: "index",
|
|
673
667
|
setup(e) {
|
|
674
|
-
const a =
|
|
668
|
+
const a = J(), { open: t } = Z("waitDlg"), l = () => {
|
|
675
669
|
t.value = !0;
|
|
676
670
|
}, o = () => {
|
|
677
671
|
t.value = !1;
|
|
678
672
|
};
|
|
679
|
-
return
|
|
673
|
+
return S(() => {
|
|
680
674
|
p.on("openWaitDlg", l), p.on("closeWaitDlg", o);
|
|
681
|
-
}),
|
|
675
|
+
}), j(() => {
|
|
682
676
|
p.off("openWaitDlg", l), p.off("closeWaitDlg", o);
|
|
683
677
|
}), (r, n) => {
|
|
684
|
-
const c =
|
|
685
|
-
return b(),
|
|
686
|
-
modelValue:
|
|
687
|
-
"onUpdate:modelValue": n[0] || (n[0] = (
|
|
678
|
+
const c = m("v-card"), u = m("v-dialog");
|
|
679
|
+
return b(), O(u, {
|
|
680
|
+
modelValue: z(t),
|
|
681
|
+
"onUpdate:modelValue": n[0] || (n[0] = (_) => G(t) ? t.value = _ : null),
|
|
688
682
|
persistent: "",
|
|
689
683
|
"no-click-animation": "",
|
|
690
684
|
fullscreen: ""
|
|
691
685
|
}, {
|
|
692
|
-
default:
|
|
693
|
-
|
|
686
|
+
default: h(() => [
|
|
687
|
+
v("div", Xe, [
|
|
694
688
|
y(c, {
|
|
695
689
|
width: "300px",
|
|
696
690
|
height: "80px",
|
|
697
691
|
loading: ""
|
|
698
692
|
}, {
|
|
699
|
-
default:
|
|
700
|
-
|
|
701
|
-
|
|
693
|
+
default: h(() => [
|
|
694
|
+
v("div", Ge, [
|
|
695
|
+
v("span", null, V(z(a).t("waitingResponse")), 1)
|
|
702
696
|
])
|
|
703
697
|
]),
|
|
704
698
|
_: 1
|
|
@@ -709,11 +703,11 @@ const $e = /* @__PURE__ */ T({
|
|
|
709
703
|
}, 8, ["modelValue"]);
|
|
710
704
|
};
|
|
711
705
|
}
|
|
712
|
-
}),
|
|
713
|
-
e.component("x-confirm-dlg",
|
|
706
|
+
}), Qe = (e) => {
|
|
707
|
+
e.component("x-confirm-dlg", Ue), e.component("x-loading", ze), e.component("x-message", Ne), e.component("x-prompt-dlg", He), e.component("x-wait-dlg", Je);
|
|
714
708
|
};
|
|
715
|
-
function
|
|
716
|
-
const e =
|
|
709
|
+
function gt() {
|
|
710
|
+
const e = K(), a = g(() => e.global.current.value.colors.primary), t = g(() => e.global.current.value.colors.secondary), l = g(() => e.current.value.dark ? "#2e2e2e" : "#bdbdbd"), o = g(() => e.current.value.dark ? "#272727" : "#eeeeee"), r = g(() => e.current.value.dark ? "#1e1e1e" : "#ffffff"), n = g(() => e.current.value.dark ? "#303030" : "#f6f6f6"), c = g(() => e.current.value.dark ? "#ffffff1f" : "#0000001f");
|
|
717
711
|
return {
|
|
718
712
|
primaryColor: a,
|
|
719
713
|
secondaryColor: t,
|
|
@@ -724,73 +718,61 @@ function yt() {
|
|
|
724
718
|
borderColor: c
|
|
725
719
|
};
|
|
726
720
|
}
|
|
727
|
-
function
|
|
728
|
-
const e =
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
if (!l.isEmpty()) {
|
|
738
|
-
l.hasView("waitDlg") || l.popView();
|
|
721
|
+
function vt() {
|
|
722
|
+
const e = be(), a = le(), t = K(), l = Ce(), o = ne(), r = (s) => {
|
|
723
|
+
l.dark = s, t.global.name.value = l.dark ? "dark" : "light";
|
|
724
|
+
}, n = (s) => {
|
|
725
|
+
l.locale = s;
|
|
726
|
+
}, c = (s) => {
|
|
727
|
+
l.permissionObjects = s.permissionObjects, l.permissionChecksum = s.permissionChecksum;
|
|
728
|
+
}, u = () => {
|
|
729
|
+
if (!o.isEmpty()) {
|
|
730
|
+
o.hasView("waitDlg") || o.popView();
|
|
739
731
|
return;
|
|
740
732
|
}
|
|
741
|
-
const
|
|
742
|
-
(
|
|
743
|
-
}
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
}), S(() => {
|
|
747
|
-
p.off("backbutton", o);
|
|
748
|
-
});
|
|
749
|
-
const r = (n) => {
|
|
750
|
-
if (n.key === "Escape") {
|
|
751
|
-
o();
|
|
733
|
+
const s = Y(e.path);
|
|
734
|
+
(s == null ? void 0 : s.level) === 0 || a.back();
|
|
735
|
+
}, _ = (s) => {
|
|
736
|
+
if (s.key === "Escape") {
|
|
737
|
+
u();
|
|
752
738
|
return;
|
|
753
739
|
}
|
|
754
740
|
};
|
|
755
|
-
|
|
756
|
-
window.addEventListener("keydown",
|
|
757
|
-
}),
|
|
758
|
-
window.removeEventListener("keydown",
|
|
741
|
+
S(() => {
|
|
742
|
+
p.on("darkchange", r), p.on("localechange", n), p.on("permissionchange", c), p.on("backbutton", u), window.addEventListener("keydown", _);
|
|
743
|
+
}), j(() => {
|
|
744
|
+
p.off("darkchange", r), p.off("localechange", n), p.off("permissionchange", c), p.off("backbutton", u), window.removeEventListener("keydown", _);
|
|
759
745
|
});
|
|
760
746
|
}
|
|
761
|
-
function
|
|
762
|
-
const e =
|
|
747
|
+
function mt() {
|
|
748
|
+
const e = K(), a = xe(), t = g(() => e.current.value.dark), l = g(() => !!window.cordova), o = g(() => a.width.value <= 1280 ? a.width.value + "px" : a.width.value <= 1920 ? 1920 / 2.5 + "px" : 2560 / 2.5 + "px");
|
|
763
749
|
return { dark: t, sysBarAvail: l, compactWidth: o };
|
|
764
750
|
}
|
|
765
|
-
const
|
|
751
|
+
const ht = { install: Qe };
|
|
766
752
|
export {
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
bt as default,
|
|
753
|
+
Te as Permission,
|
|
754
|
+
lt as appAppear,
|
|
755
|
+
ut as closeWaitDlg,
|
|
756
|
+
at as createAxios,
|
|
757
|
+
ht as default,
|
|
773
758
|
p as eventBus,
|
|
774
|
-
|
|
775
|
-
ct as mainAcitve,
|
|
759
|
+
ft as isExist,
|
|
776
760
|
Y as matchRouteMeta,
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
re as useViewMgrStore,
|
|
761
|
+
pt as messageError,
|
|
762
|
+
_t as messageInfo,
|
|
763
|
+
st as messageSuccess,
|
|
764
|
+
dt as messageWarning,
|
|
765
|
+
it as onBeforeEach,
|
|
766
|
+
nt as openConfirmDlg,
|
|
767
|
+
rt as openPromptDlg,
|
|
768
|
+
ct as openWaitDlg,
|
|
769
|
+
ae as routeTransName,
|
|
770
|
+
gt as useColor,
|
|
771
|
+
Ce as useGlobalStore,
|
|
772
|
+
vt as useMicroApp,
|
|
773
|
+
mt as useSystem,
|
|
774
|
+
ne as useViewMgrStore,
|
|
792
775
|
Z as useViewStack,
|
|
793
|
-
|
|
794
|
-
ut as waitMs,
|
|
776
|
+
ot as waitMs,
|
|
795
777
|
Q as waitUtil
|
|
796
778
|
};
|
package/dist/store/global.d.ts
CHANGED
|
@@ -1,21 +1,15 @@
|
|
|
1
|
-
import { PermissionObjects } from '../utils
|
|
1
|
+
import { PermissionObjects } from '../utils';
|
|
2
2
|
export declare const useGlobalStore: import("pinia").StoreDefinition<"global", import("pinia")._UnwrapAll<Pick<{
|
|
3
|
-
running: import("vue").Ref<boolean>;
|
|
4
|
-
mainActive: import("vue").Ref<0 | 1 | 2 | 3 | 4>;
|
|
5
3
|
dark: import("vue").Ref<boolean | undefined>;
|
|
6
4
|
locale: import("vue").Ref<string>;
|
|
7
5
|
permissionObjects: import("vue").Ref<PermissionObjects>;
|
|
8
6
|
permissionChecksum: import("vue").Ref<string>;
|
|
9
|
-
}, "
|
|
10
|
-
running: import("vue").Ref<boolean>;
|
|
11
|
-
mainActive: import("vue").Ref<0 | 1 | 2 | 3 | 4>;
|
|
7
|
+
}, "dark" | "locale" | "permissionObjects" | "permissionChecksum">>, Pick<{
|
|
12
8
|
dark: import("vue").Ref<boolean | undefined>;
|
|
13
9
|
locale: import("vue").Ref<string>;
|
|
14
10
|
permissionObjects: import("vue").Ref<PermissionObjects>;
|
|
15
11
|
permissionChecksum: import("vue").Ref<string>;
|
|
16
12
|
}, never>, Pick<{
|
|
17
|
-
running: import("vue").Ref<boolean>;
|
|
18
|
-
mainActive: import("vue").Ref<0 | 1 | 2 | 3 | 4>;
|
|
19
13
|
dark: import("vue").Ref<boolean | undefined>;
|
|
20
14
|
locale: import("vue").Ref<string>;
|
|
21
15
|
permissionObjects: import("vue").Ref<PermissionObjects>;
|
package/dist/store/index.d.ts
CHANGED
package/dist/utils/core.d.ts
CHANGED
|
@@ -1,9 +1,2 @@
|
|
|
1
1
|
import { Emitter, EventType } from 'mitt';
|
|
2
|
-
import { Ref } from 'vue';
|
|
3
|
-
import { PermissionObjects } from './permission';
|
|
4
2
|
export declare const eventBus: Emitter<Record<EventType, unknown>>;
|
|
5
|
-
export declare const dark: Ref<boolean | undefined>;
|
|
6
|
-
export declare const locale: Ref<string>;
|
|
7
|
-
export declare const permissionObjects: Ref<PermissionObjects>;
|
|
8
|
-
export declare const permissionChecksum: Ref<string>;
|
|
9
|
-
export declare const mainAcitve: Ref<0 | 1 | 2 | 3 | 4>;
|
|
@@ -129,5 +129,5 @@ type PermissionObject = {
|
|
|
129
129
|
export type PermissionObjects = {
|
|
130
130
|
[key: string]: PermissionObject;
|
|
131
131
|
};
|
|
132
|
-
export declare function
|
|
132
|
+
export declare function isExist(instanceTree: InstanceTree | undefined, instance: string): boolean;
|
|
133
133
|
export {};
|