x-essential-lib 0.5.13 → 0.5.14
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/microApp.d.ts +1 -2
- package/dist/index.d.ts +1 -3
- package/dist/index.js +331 -423
- package/dist/store/index.d.ts +0 -1
- package/package.json +1 -1
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
export declare function useMicroApp(prod: boolean, instance?: AxiosInstance): void;
|
|
1
|
+
export declare function useMicroApp(): void;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,9 +1,7 @@
|
|
|
1
|
-
import './styles/global.css';
|
|
2
1
|
declare const _default: {
|
|
3
2
|
install: (app: import("vue").App<any>) => void;
|
|
4
3
|
};
|
|
5
4
|
export default _default;
|
|
6
5
|
export * from './composables';
|
|
7
|
-
export * from './store
|
|
8
|
-
export * from './store/viewMgr';
|
|
6
|
+
export * from './store';
|
|
9
7
|
export * from './utils';
|
package/dist/index.js
CHANGED
|
@@ -1,11 +1,48 @@
|
|
|
1
|
-
(function(){"use strict";try{if(typeof document<"u"){var
|
|
2
|
-
import { ref as
|
|
3
|
-
import {
|
|
4
|
-
import { defineStore as
|
|
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 f, computed as i, onMounted as C, onBeforeUnmount as S, defineComponent as j, watch as H, resolveComponent as v, openBlock as b, createBlock as T, unref as L, isRef as X, withKeys as F, withModifiers as B, withCtx as m, createVNode as y, createTextVNode as I, toDisplayString as R, createElementBlock as K, normalizeStyle as ie, pushScopeId as ge, popScopeId as ve, createElementVNode as g, reactive as me, Fragment as he, renderList as we, createCommentVNode as ye } from "vue";
|
|
3
|
+
import { useLocale as J, useTheme as G, useDisplay as xe } from "vuetify";
|
|
4
|
+
import { defineStore as ke } from "pinia";
|
|
5
5
|
import be from "axios";
|
|
6
|
-
import { useRouter as
|
|
6
|
+
import { useRouter as le, useRoute as Ce } from "vue-router";
|
|
7
|
+
const re = ke("viewMgr", () => {
|
|
8
|
+
const e = f([]);
|
|
9
|
+
function a() {
|
|
10
|
+
return e.value.length <= 0;
|
|
11
|
+
}
|
|
12
|
+
function t() {
|
|
13
|
+
const u = e.value.length;
|
|
14
|
+
if (u > 0)
|
|
15
|
+
return e.value[u - 1];
|
|
16
|
+
}
|
|
17
|
+
function l(u) {
|
|
18
|
+
return e.value.find((s) => s === u) !== void 0;
|
|
19
|
+
}
|
|
20
|
+
function o(u) {
|
|
21
|
+
e.value.push(u);
|
|
22
|
+
}
|
|
23
|
+
function n(u) {
|
|
24
|
+
const s = e.value.findIndex((h) => h === u);
|
|
25
|
+
s !== -1 && e.value.splice(s, e.value.length - s);
|
|
26
|
+
}
|
|
27
|
+
function r() {
|
|
28
|
+
console.assert(e.value.length > 0), e.value.pop();
|
|
29
|
+
}
|
|
30
|
+
function c() {
|
|
31
|
+
e.value = [];
|
|
32
|
+
}
|
|
33
|
+
return {
|
|
34
|
+
views: e,
|
|
35
|
+
isEmpty: a,
|
|
36
|
+
lastView: t,
|
|
37
|
+
hasView: l,
|
|
38
|
+
addView: o,
|
|
39
|
+
delView: n,
|
|
40
|
+
popView: r,
|
|
41
|
+
clearViews: c
|
|
42
|
+
};
|
|
43
|
+
});
|
|
7
44
|
/*! js-cookie v3.0.5 | MIT */
|
|
8
|
-
function
|
|
45
|
+
function z(e) {
|
|
9
46
|
for (var a = 1; a < arguments.length; a++) {
|
|
10
47
|
var t = arguments[a];
|
|
11
48
|
for (var l in t)
|
|
@@ -24,10 +61,10 @@ var De = {
|
|
|
24
61
|
);
|
|
25
62
|
}
|
|
26
63
|
};
|
|
27
|
-
function
|
|
64
|
+
function N(e, a) {
|
|
28
65
|
function t(o, n, r) {
|
|
29
66
|
if (!(typeof document > "u")) {
|
|
30
|
-
r =
|
|
67
|
+
r = z({}, a, r), typeof r.expires == "number" && (r.expires = new Date(Date.now() + r.expires * 864e5)), r.expires && (r.expires = r.expires.toUTCString()), o = encodeURIComponent(o).replace(/%(2[346B]|5E|60|7C)/g, decodeURIComponent).replace(/[()]/g, escape);
|
|
31
68
|
var c = "";
|
|
32
69
|
for (var u in r)
|
|
33
70
|
r[u] && (c += "; " + u, r[u] !== !0 && (c += "=" + r[u].split(";")[0]));
|
|
@@ -37,10 +74,10 @@ function X(e, a) {
|
|
|
37
74
|
function l(o) {
|
|
38
75
|
if (!(typeof document > "u" || arguments.length && !o)) {
|
|
39
76
|
for (var n = document.cookie ? document.cookie.split("; ") : [], r = {}, c = 0; c < n.length; c++) {
|
|
40
|
-
var u = n[c].split("="),
|
|
77
|
+
var u = n[c].split("="), s = u.slice(1).join("=");
|
|
41
78
|
try {
|
|
42
|
-
var
|
|
43
|
-
if (r[
|
|
79
|
+
var h = decodeURIComponent(u[0]);
|
|
80
|
+
if (r[h] = e.read(s, h), o === h)
|
|
44
81
|
break;
|
|
45
82
|
} catch {
|
|
46
83
|
}
|
|
@@ -56,16 +93,16 @@ function X(e, a) {
|
|
|
56
93
|
t(
|
|
57
94
|
o,
|
|
58
95
|
"",
|
|
59
|
-
|
|
96
|
+
z({}, n, {
|
|
60
97
|
expires: -1
|
|
61
98
|
})
|
|
62
99
|
);
|
|
63
100
|
},
|
|
64
101
|
withAttributes: function(o) {
|
|
65
|
-
return
|
|
102
|
+
return N(this.converter, z({}, this.attributes, o));
|
|
66
103
|
},
|
|
67
104
|
withConverter: function(o) {
|
|
68
|
-
return
|
|
105
|
+
return N(z({}, this.converter, o), this.attributes);
|
|
69
106
|
}
|
|
70
107
|
},
|
|
71
108
|
{
|
|
@@ -74,29 +111,29 @@ function X(e, a) {
|
|
|
74
111
|
}
|
|
75
112
|
);
|
|
76
113
|
}
|
|
77
|
-
var
|
|
78
|
-
function
|
|
114
|
+
var O = N(De, { path: "/" });
|
|
115
|
+
function ot(e) {
|
|
79
116
|
const a = be.create({
|
|
80
117
|
timeout: 6e3
|
|
81
118
|
});
|
|
82
119
|
return a.defaults.baseURL = e.baseUrl, a.interceptors.request.use(
|
|
83
|
-
(t) =>
|
|
120
|
+
(t) => Ve(t),
|
|
84
121
|
(t) => {
|
|
85
|
-
|
|
122
|
+
Re(t, e.onError);
|
|
86
123
|
}
|
|
87
124
|
), a.interceptors.response.use(
|
|
88
|
-
(t) =>
|
|
125
|
+
(t) => Se(t),
|
|
89
126
|
(t) => qe(t, e.onError)
|
|
90
127
|
), a;
|
|
91
128
|
}
|
|
92
|
-
function
|
|
93
|
-
const a =
|
|
129
|
+
function Ve(e) {
|
|
130
|
+
const a = O.get("accessToken") ?? "";
|
|
94
131
|
return e.headers.Authorization = "Basic " + a, e.headers["Content-Type"] = "application/json", e.data = JSON.stringify(e.data), e;
|
|
95
132
|
}
|
|
96
|
-
function
|
|
133
|
+
function Re(e, a) {
|
|
97
134
|
console.error(e), a("request timeout");
|
|
98
135
|
}
|
|
99
|
-
function
|
|
136
|
+
function Se(e) {
|
|
100
137
|
return e.data;
|
|
101
138
|
}
|
|
102
139
|
function qe(e, a) {
|
|
@@ -104,17 +141,17 @@ function qe(e, a) {
|
|
|
104
141
|
const t = e.response;
|
|
105
142
|
if (!t)
|
|
106
143
|
return Promise.reject(e);
|
|
107
|
-
t.status === 401 &&
|
|
144
|
+
t.status === 401 && Ie();
|
|
108
145
|
let l = (o = t.data) == null ? void 0 : o.message;
|
|
109
146
|
return l || (l = {
|
|
110
147
|
code: t.status,
|
|
111
148
|
message: t.statusText
|
|
112
149
|
}), a(l), Promise.reject(e);
|
|
113
150
|
}
|
|
114
|
-
function
|
|
115
|
-
|
|
151
|
+
function Ie() {
|
|
152
|
+
O.remove("accessToken"), O.remove("refreshToken"), O.remove("activeOrg"), le().replace({ path: "/passport/login" });
|
|
116
153
|
}
|
|
117
|
-
function
|
|
154
|
+
function Oe(e) {
|
|
118
155
|
return { all: e = e || /* @__PURE__ */ new Map(), on: function(a, t) {
|
|
119
156
|
var l = e.get(a);
|
|
120
157
|
l ? l.push(t) : e.set(a, [t]);
|
|
@@ -130,13 +167,13 @@ function Te(e) {
|
|
|
130
167
|
});
|
|
131
168
|
} };
|
|
132
169
|
}
|
|
133
|
-
const
|
|
134
|
-
async function
|
|
170
|
+
const p = Oe();
|
|
171
|
+
async function lt(e) {
|
|
135
172
|
return new Promise((a) => {
|
|
136
173
|
setTimeout(a, e);
|
|
137
174
|
});
|
|
138
175
|
}
|
|
139
|
-
async function
|
|
176
|
+
async function Q(e, a, t) {
|
|
140
177
|
const l = Date.now();
|
|
141
178
|
return new Promise((o) => {
|
|
142
179
|
const n = async () => {
|
|
@@ -150,35 +187,35 @@ function ne() {
|
|
|
150
187
|
const e = Date.now();
|
|
151
188
|
return e - ee > 500 ? (ee = e, !0) : !1;
|
|
152
189
|
}
|
|
153
|
-
let
|
|
190
|
+
let Te = 0;
|
|
154
191
|
function ce() {
|
|
155
|
-
return ++
|
|
192
|
+
return ++Te;
|
|
156
193
|
}
|
|
157
|
-
async function
|
|
194
|
+
async function rt(e) {
|
|
158
195
|
if (!ne())
|
|
159
196
|
return;
|
|
160
197
|
let a = !1, t;
|
|
161
198
|
const l = (n) => {
|
|
162
199
|
t = n, a = !0;
|
|
163
200
|
}, o = ce();
|
|
164
|
-
return
|
|
201
|
+
return p.on("confirmDlgResult" + o, l), p.emit("confirmDlg", { ...e, seq: o }), await Q(() => a), p.off("confirmDlgResult" + o, l), t;
|
|
165
202
|
}
|
|
166
|
-
async function
|
|
203
|
+
async function nt(e) {
|
|
167
204
|
if (!ne())
|
|
168
205
|
return;
|
|
169
206
|
let a = !1, t;
|
|
170
207
|
const l = (n) => {
|
|
171
208
|
t = n, a = !0;
|
|
172
209
|
}, o = ce();
|
|
173
|
-
return
|
|
210
|
+
return p.on("promptDlgResult" + o, l), p.emit("promptDlg", { ...e, seq: o }), await Q(() => a), p.off("promptDlgResult" + o, l), t;
|
|
174
211
|
}
|
|
175
|
-
function
|
|
176
|
-
|
|
212
|
+
function ct() {
|
|
213
|
+
p.emit("openWaitDlg");
|
|
177
214
|
}
|
|
178
|
-
function
|
|
179
|
-
|
|
215
|
+
function ut() {
|
|
216
|
+
p.emit("closeWaitDlg");
|
|
180
217
|
}
|
|
181
|
-
var
|
|
218
|
+
var je = /* @__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))(je || {});
|
|
182
219
|
function te(e, a) {
|
|
183
220
|
if (!e)
|
|
184
221
|
return !1;
|
|
@@ -192,24 +229,24 @@ function te(e, a) {
|
|
|
192
229
|
return !1;
|
|
193
230
|
}), Object.keys(t).length <= 0);
|
|
194
231
|
}
|
|
195
|
-
const
|
|
196
|
-
function
|
|
197
|
-
const t =
|
|
232
|
+
const pt = f(1), _t = f(), st = f("en"), Ee = f({}), dt = f("");
|
|
233
|
+
function ft(e, a) {
|
|
234
|
+
const t = Ee.value[e];
|
|
198
235
|
return t ? a ? !(!te(t.includes, a) || te(t.excludes, a)) : !0 : !1;
|
|
199
236
|
}
|
|
200
|
-
function
|
|
201
|
-
|
|
237
|
+
function it(e, a) {
|
|
238
|
+
p.emit("message", { type: "error", text: e, timeout: a });
|
|
202
239
|
}
|
|
203
|
-
function
|
|
204
|
-
|
|
240
|
+
function gt(e, a) {
|
|
241
|
+
p.emit("message", { type: "info", text: e, timeout: a });
|
|
205
242
|
}
|
|
206
|
-
function
|
|
207
|
-
|
|
243
|
+
function vt(e, a) {
|
|
244
|
+
p.emit("message", { type: "success", text: e, timeout: a });
|
|
208
245
|
}
|
|
209
|
-
function
|
|
210
|
-
|
|
246
|
+
function mt(e, a) {
|
|
247
|
+
p.emit("message", { type: "warning", text: e, timeout: a });
|
|
211
248
|
}
|
|
212
|
-
function
|
|
249
|
+
function ht(e) {
|
|
213
250
|
var l, o;
|
|
214
251
|
if (!window.appAppear) {
|
|
215
252
|
window.appAppear = !0;
|
|
@@ -220,7 +257,7 @@ function yt(e) {
|
|
|
220
257
|
t.add("app-reset");
|
|
221
258
|
}, 0));
|
|
222
259
|
}
|
|
223
|
-
const
|
|
260
|
+
const Ae = [
|
|
224
261
|
{ path: "/passport/login", level: 0 },
|
|
225
262
|
{ path: "/passport/loginAccount", level: 1 },
|
|
226
263
|
{ path: "/passport/register", level: 1 },
|
|
@@ -239,10 +276,10 @@ const Ee = [
|
|
|
239
276
|
{ path: "/calc", level: 1, requiredState: "org" },
|
|
240
277
|
{ path: "/data", level: 1, requiredState: "org" }
|
|
241
278
|
];
|
|
242
|
-
function
|
|
279
|
+
function Y(e) {
|
|
243
280
|
let a, t = 0;
|
|
244
281
|
const l = e.split("/").filter((o) => o.trim() !== "");
|
|
245
|
-
return
|
|
282
|
+
return Ae.forEach((o) => {
|
|
246
283
|
const n = o.path.split("/").filter((c) => c.trim() !== "");
|
|
247
284
|
let r = 0;
|
|
248
285
|
for (let c = 0; c < l.length && !(c >= n.length || l[c] !== n[c]); c++)
|
|
@@ -253,27 +290,27 @@ function F(e) {
|
|
|
253
290
|
function ae(e) {
|
|
254
291
|
if (e === "/")
|
|
255
292
|
return { app: "", path: "/", level: -1 };
|
|
256
|
-
const a =
|
|
293
|
+
const a = Y(e);
|
|
257
294
|
if (!a)
|
|
258
295
|
return { app: "invalidApp", path: "/invalidApp/invalidRoute", level: -1 };
|
|
259
296
|
const t = e.split("/");
|
|
260
297
|
return console.assert(t.length >= 2), { app: t[1], path: a.path, level: a.level };
|
|
261
298
|
}
|
|
262
|
-
const oe =
|
|
263
|
-
function
|
|
299
|
+
const oe = f("");
|
|
300
|
+
function k(e, a) {
|
|
264
301
|
const t = ae(e), l = ae(a), o = t.app === l.app, n = t.path === l.path, r = t.level >= l.level;
|
|
265
302
|
console.info(
|
|
266
303
|
`~~~~before route change~~~~ ${l.path} -> ${t.path} inner=${o} forward=${r}`
|
|
267
304
|
), o ? n ? oe.value = "" : oe.value = r ? "inner-left" : "inner-right" : window.routeExtras = { forward: r };
|
|
268
305
|
}
|
|
269
|
-
function
|
|
270
|
-
return !!
|
|
306
|
+
function Ue() {
|
|
307
|
+
return !!O.get("accessToken");
|
|
271
308
|
}
|
|
272
|
-
function
|
|
273
|
-
return !!
|
|
309
|
+
function Be() {
|
|
310
|
+
return !!O.get("activeOrg");
|
|
274
311
|
}
|
|
275
|
-
function
|
|
276
|
-
const l =
|
|
312
|
+
function wt(e, a, t) {
|
|
313
|
+
const l = Ue(), o = Be(), n = Y(e.path);
|
|
277
314
|
if (!n) {
|
|
278
315
|
t();
|
|
279
316
|
return;
|
|
@@ -282,110 +319,38 @@ function xt(e, a, t) {
|
|
|
282
319
|
if (l)
|
|
283
320
|
if (o) {
|
|
284
321
|
const r = "/main";
|
|
285
|
-
|
|
322
|
+
k(r, a.path), t({ path: r });
|
|
286
323
|
} else
|
|
287
|
-
|
|
324
|
+
k(e.path, a.path), t();
|
|
288
325
|
else {
|
|
289
326
|
const r = "/passport/login";
|
|
290
|
-
|
|
327
|
+
k(r, a.path), t({ path: r });
|
|
291
328
|
}
|
|
292
329
|
else if (n.requiredState === "org")
|
|
293
330
|
if (l)
|
|
294
331
|
if (o)
|
|
295
|
-
|
|
332
|
+
k(e.path, a.path), t();
|
|
296
333
|
else {
|
|
297
334
|
const r = "/org/joinOrCreate";
|
|
298
|
-
|
|
335
|
+
k(r, a.path), t({ path: r });
|
|
299
336
|
}
|
|
300
337
|
else {
|
|
301
338
|
const r = "/passport/login";
|
|
302
|
-
|
|
339
|
+
k(r, a.path), t({ path: r });
|
|
303
340
|
}
|
|
304
341
|
else if (l)
|
|
305
342
|
if (o) {
|
|
306
343
|
const r = "/main";
|
|
307
|
-
|
|
344
|
+
k(r, a.path), t({ path: r });
|
|
308
345
|
} else {
|
|
309
346
|
const r = "/org/joinOrCreate";
|
|
310
|
-
|
|
347
|
+
k(r, a.path), t({ path: r });
|
|
311
348
|
}
|
|
312
349
|
else
|
|
313
|
-
|
|
314
|
-
}
|
|
315
|
-
const Ue = le(
|
|
316
|
-
"global",
|
|
317
|
-
() => {
|
|
318
|
-
const e = H(), a = d(!0), t = d(1), l = d(), o = d("en"), n = d({}), r = d("");
|
|
319
|
-
return N(
|
|
320
|
-
l,
|
|
321
|
-
() => {
|
|
322
|
-
s.emit("darkchange", l.value), e.global.name.value = l.value ? "dark" : "light";
|
|
323
|
-
},
|
|
324
|
-
{
|
|
325
|
-
immediate: !0
|
|
326
|
-
}
|
|
327
|
-
), {
|
|
328
|
-
running: a,
|
|
329
|
-
mainActive: t,
|
|
330
|
-
dark: l,
|
|
331
|
-
locale: o,
|
|
332
|
-
permissionObjects: n,
|
|
333
|
-
permissionChecksum: r
|
|
334
|
-
};
|
|
335
|
-
},
|
|
336
|
-
{
|
|
337
|
-
persist: [
|
|
338
|
-
{
|
|
339
|
-
storage: localStorage,
|
|
340
|
-
paths: [
|
|
341
|
-
"mainActive",
|
|
342
|
-
"dark",
|
|
343
|
-
"locale",
|
|
344
|
-
"permissionObjects",
|
|
345
|
-
"permissionChecksum"
|
|
346
|
-
]
|
|
347
|
-
}
|
|
348
|
-
]
|
|
349
|
-
}
|
|
350
|
-
), ue = le("viewMgr", () => {
|
|
351
|
-
const e = d([]);
|
|
352
|
-
function a() {
|
|
353
|
-
return e.value.length <= 0;
|
|
354
|
-
}
|
|
355
|
-
function t() {
|
|
356
|
-
const u = e.value.length;
|
|
357
|
-
if (u > 0)
|
|
358
|
-
return e.value[u - 1];
|
|
359
|
-
}
|
|
360
|
-
function l(u) {
|
|
361
|
-
return e.value.find((_) => _ === u) !== void 0;
|
|
362
|
-
}
|
|
363
|
-
function o(u) {
|
|
364
|
-
e.value.push(u);
|
|
365
|
-
}
|
|
366
|
-
function n(u) {
|
|
367
|
-
const _ = e.value.findIndex((v) => v === u);
|
|
368
|
-
_ !== -1 && e.value.splice(_, e.value.length - _);
|
|
369
|
-
}
|
|
370
|
-
function r() {
|
|
371
|
-
console.assert(e.value.length > 0), e.value.pop();
|
|
372
|
-
}
|
|
373
|
-
function c() {
|
|
374
|
-
e.value = [];
|
|
375
|
-
}
|
|
376
|
-
return {
|
|
377
|
-
views: e,
|
|
378
|
-
isEmpty: a,
|
|
379
|
-
lastView: t,
|
|
380
|
-
hasView: l,
|
|
381
|
-
addView: o,
|
|
382
|
-
delView: n,
|
|
383
|
-
popView: r,
|
|
384
|
-
clearViews: c
|
|
385
|
-
};
|
|
386
|
-
});
|
|
350
|
+
k(e.path, a.path), t();
|
|
351
|
+
}
|
|
387
352
|
function Z(e, a) {
|
|
388
|
-
const t =
|
|
353
|
+
const t = re(), l = i({
|
|
389
354
|
get() {
|
|
390
355
|
return t.hasView(e);
|
|
391
356
|
},
|
|
@@ -395,82 +360,82 @@ function Z(e, a) {
|
|
|
395
360
|
}), o = (n) => {
|
|
396
361
|
a == null || a(n), l.value = !0;
|
|
397
362
|
};
|
|
398
|
-
return
|
|
399
|
-
|
|
400
|
-
}),
|
|
401
|
-
|
|
363
|
+
return C(() => {
|
|
364
|
+
p.on(e, o);
|
|
365
|
+
}), S(() => {
|
|
366
|
+
p.off(e, o);
|
|
402
367
|
}), { open: l };
|
|
403
368
|
}
|
|
404
|
-
const
|
|
369
|
+
const Me = /* @__PURE__ */ j({
|
|
405
370
|
__name: "index",
|
|
406
371
|
setup(e) {
|
|
407
|
-
const a =
|
|
408
|
-
var
|
|
409
|
-
return ((
|
|
410
|
-
}), u =
|
|
411
|
-
var
|
|
412
|
-
return ((
|
|
413
|
-
}),
|
|
414
|
-
var
|
|
415
|
-
return ((
|
|
416
|
-
}),
|
|
417
|
-
var
|
|
418
|
-
return ((
|
|
372
|
+
const a = J(), { open: t } = Z("confirmDlg"), l = f(""), o = f(""), n = f(), r = f(), c = i(() => {
|
|
373
|
+
var d;
|
|
374
|
+
return ((d = n.value) == null ? void 0 : d.color) ?? "primary";
|
|
375
|
+
}), u = i(() => {
|
|
376
|
+
var d;
|
|
377
|
+
return ((d = n.value) == null ? void 0 : d.text) ?? a.t("cancel");
|
|
378
|
+
}), s = i(() => {
|
|
379
|
+
var d;
|
|
380
|
+
return ((d = r.value) == null ? void 0 : d.color) ?? "primary";
|
|
381
|
+
}), h = i(() => {
|
|
382
|
+
var d;
|
|
383
|
+
return ((d = r.value) == null ? void 0 : d.text) ?? a.t("confirm");
|
|
419
384
|
});
|
|
420
|
-
let
|
|
421
|
-
const
|
|
422
|
-
l.value =
|
|
385
|
+
let q = 0, D = !1;
|
|
386
|
+
const M = (d) => {
|
|
387
|
+
l.value = d.title, o.value = d.text, n.value = d.cancel, r.value = d.confirm, q = d.seq, D = !1, t.value = !0;
|
|
423
388
|
};
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
}),
|
|
427
|
-
|
|
389
|
+
C(() => {
|
|
390
|
+
p.on("confirmDlg", M);
|
|
391
|
+
}), S(() => {
|
|
392
|
+
p.off("confirmDlg", M);
|
|
428
393
|
});
|
|
429
|
-
const
|
|
430
|
-
t.value = !1,
|
|
394
|
+
const $ = () => {
|
|
395
|
+
t.value = !1, D || (p.emit("confirmDlgResult" + q, !0), D = !0);
|
|
431
396
|
};
|
|
432
|
-
return
|
|
433
|
-
!
|
|
434
|
-
}), (
|
|
435
|
-
const
|
|
436
|
-
return
|
|
437
|
-
modelValue:
|
|
438
|
-
"onUpdate:modelValue":
|
|
397
|
+
return H(t, (d) => {
|
|
398
|
+
!d && !D && (p.emit("confirmDlgResult" + q, !1), D = !0);
|
|
399
|
+
}), (d, x) => {
|
|
400
|
+
const V = v("v-card-text"), E = v("v-btn"), W = v("v-card-actions"), _ = v("v-card"), w = v("v-dialog");
|
|
401
|
+
return b(), T(w, {
|
|
402
|
+
modelValue: L(t),
|
|
403
|
+
"onUpdate:modelValue": x[1] || (x[1] = (A) => X(t) ? t.value = A : null),
|
|
439
404
|
onKeydown: [
|
|
440
|
-
|
|
441
|
-
|
|
405
|
+
x[2] || (x[2] = F(B((A) => t.value = !1, ["stop", "prevent"]), ["esc"])),
|
|
406
|
+
F(B($, ["stop", "prevent"]), ["enter"])
|
|
442
407
|
],
|
|
443
408
|
transition: "dialog-top-transition",
|
|
444
409
|
"max-width": "600px"
|
|
445
410
|
}, {
|
|
446
|
-
default:
|
|
447
|
-
|
|
448
|
-
default:
|
|
449
|
-
|
|
450
|
-
default:
|
|
451
|
-
|
|
411
|
+
default: m(() => [
|
|
412
|
+
y(_, { title: l.value }, {
|
|
413
|
+
default: m(() => [
|
|
414
|
+
y(V, null, {
|
|
415
|
+
default: m(() => [
|
|
416
|
+
I(R(o.value), 1)
|
|
452
417
|
]),
|
|
453
418
|
_: 1
|
|
454
419
|
}),
|
|
455
|
-
|
|
456
|
-
default:
|
|
457
|
-
|
|
458
|
-
onClick:
|
|
420
|
+
y(W, { class: "d-flex justify-end" }, {
|
|
421
|
+
default: m(() => [
|
|
422
|
+
y(E, {
|
|
423
|
+
onClick: x[0] || (x[0] = (A) => t.value = !1),
|
|
459
424
|
color: c.value,
|
|
460
425
|
variant: "text"
|
|
461
426
|
}, {
|
|
462
|
-
default:
|
|
463
|
-
|
|
427
|
+
default: m(() => [
|
|
428
|
+
I(R(u.value), 1)
|
|
464
429
|
]),
|
|
465
430
|
_: 1
|
|
466
431
|
}, 8, ["color"]),
|
|
467
|
-
|
|
468
|
-
onClick:
|
|
469
|
-
color:
|
|
432
|
+
y(E, {
|
|
433
|
+
onClick: $,
|
|
434
|
+
color: s.value,
|
|
470
435
|
variant: "text"
|
|
471
436
|
}, {
|
|
472
|
-
default:
|
|
473
|
-
|
|
437
|
+
default: m(() => [
|
|
438
|
+
I(R(h.value), 1)
|
|
474
439
|
]),
|
|
475
440
|
_: 1
|
|
476
441
|
}, 8, ["color"])
|
|
@@ -485,22 +450,22 @@ const $e = /* @__PURE__ */ M({
|
|
|
485
450
|
}, 8, ["modelValue", "onKeydown"]);
|
|
486
451
|
};
|
|
487
452
|
}
|
|
488
|
-
}),
|
|
489
|
-
/* @__PURE__ */
|
|
490
|
-
/* @__PURE__ */
|
|
491
|
-
/* @__PURE__ */
|
|
492
|
-
/* @__PURE__ */
|
|
493
|
-
/* @__PURE__ */
|
|
494
|
-
/* @__PURE__ */
|
|
495
|
-
/* @__PURE__ */
|
|
496
|
-
/* @__PURE__ */
|
|
497
|
-
/* @__PURE__ */
|
|
498
|
-
/* @__PURE__ */
|
|
499
|
-
/* @__PURE__ */
|
|
500
|
-
/* @__PURE__ */
|
|
453
|
+
}), $e = (e) => (ge("data-v-f4ad116e"), e = e(), ve(), e), We = /* @__PURE__ */ $e(() => /* @__PURE__ */ g("div", { class: "lds-spinner" }, [
|
|
454
|
+
/* @__PURE__ */ g("div"),
|
|
455
|
+
/* @__PURE__ */ g("div"),
|
|
456
|
+
/* @__PURE__ */ g("div"),
|
|
457
|
+
/* @__PURE__ */ g("div"),
|
|
458
|
+
/* @__PURE__ */ g("div"),
|
|
459
|
+
/* @__PURE__ */ g("div"),
|
|
460
|
+
/* @__PURE__ */ g("div"),
|
|
461
|
+
/* @__PURE__ */ g("div"),
|
|
462
|
+
/* @__PURE__ */ g("div"),
|
|
463
|
+
/* @__PURE__ */ g("div"),
|
|
464
|
+
/* @__PURE__ */ g("div"),
|
|
465
|
+
/* @__PURE__ */ g("div")
|
|
501
466
|
], -1)), ze = [
|
|
502
467
|
We
|
|
503
|
-
], Le = /* @__PURE__ */
|
|
468
|
+
], Le = /* @__PURE__ */ j({
|
|
504
469
|
__name: "index",
|
|
505
470
|
props: {
|
|
506
471
|
zIndex: {
|
|
@@ -509,21 +474,21 @@ const $e = /* @__PURE__ */ M({
|
|
|
509
474
|
}
|
|
510
475
|
},
|
|
511
476
|
setup(e) {
|
|
512
|
-
const a =
|
|
477
|
+
const a = G(), t = e, l = i(() => ({
|
|
513
478
|
background: a.current.value.dark ? "#1e1e1e" : "#ffffff",
|
|
514
479
|
zIndex: t.zIndex
|
|
515
480
|
}));
|
|
516
|
-
return (o, n) => (
|
|
481
|
+
return (o, n) => (b(), K("div", {
|
|
517
482
|
class: "x-cont",
|
|
518
|
-
style:
|
|
483
|
+
style: ie(l.value)
|
|
519
484
|
}, ze, 4));
|
|
520
485
|
}
|
|
521
|
-
}),
|
|
486
|
+
}), ue = (e, a) => {
|
|
522
487
|
const t = e.__vccOpts || e;
|
|
523
488
|
for (const [l, o] of a)
|
|
524
489
|
t[l] = o;
|
|
525
490
|
return t;
|
|
526
|
-
}, Fe = /* @__PURE__ */
|
|
491
|
+
}, Fe = /* @__PURE__ */ ue(Le, [["__scopeId", "data-v-f4ad116e"]]), Ke = /* @__PURE__ */ j({
|
|
527
492
|
__name: "item",
|
|
528
493
|
props: {
|
|
529
494
|
id: {},
|
|
@@ -533,16 +498,16 @@ const $e = /* @__PURE__ */ M({
|
|
|
533
498
|
},
|
|
534
499
|
emits: ["timeout"],
|
|
535
500
|
setup(e, { emit: a }) {
|
|
536
|
-
const t = e, l =
|
|
537
|
-
return
|
|
501
|
+
const t = e, l = f(!0), o = a;
|
|
502
|
+
return C(() => {
|
|
538
503
|
setTimeout(() => {
|
|
539
504
|
o("timeout", t.id);
|
|
540
505
|
}, t.timeout);
|
|
541
|
-
}),
|
|
506
|
+
}), H(l, (n) => {
|
|
542
507
|
n || o("timeout", t.id);
|
|
543
508
|
}), (n, r) => {
|
|
544
|
-
const c =
|
|
545
|
-
return
|
|
509
|
+
const c = v("v-alert");
|
|
510
|
+
return b(), T(c, {
|
|
546
511
|
modelValue: l.value,
|
|
547
512
|
"onUpdate:modelValue": r[0] || (r[0] = (u) => l.value = u),
|
|
548
513
|
class: "mt-2",
|
|
@@ -556,14 +521,14 @@ const $e = /* @__PURE__ */ M({
|
|
|
556
521
|
}, null, 8, ["modelValue", "type", "text"]);
|
|
557
522
|
};
|
|
558
523
|
}
|
|
559
|
-
}),
|
|
524
|
+
}), Ne = /* @__PURE__ */ j({
|
|
560
525
|
__name: "index",
|
|
561
526
|
setup(e) {
|
|
562
|
-
const a =
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
}),
|
|
566
|
-
|
|
527
|
+
const a = me({ items: [] });
|
|
528
|
+
C(() => {
|
|
529
|
+
p.on("message", t);
|
|
530
|
+
}), S(() => {
|
|
531
|
+
p.off("message", t);
|
|
567
532
|
});
|
|
568
533
|
const t = (c) => {
|
|
569
534
|
n(c.type, c.text, c.timeout);
|
|
@@ -571,113 +536,113 @@ const $e = /* @__PURE__ */ M({
|
|
|
571
536
|
r(c);
|
|
572
537
|
};
|
|
573
538
|
let o = 0;
|
|
574
|
-
const n = (c, u,
|
|
575
|
-
const
|
|
576
|
-
a.items.push({ id:
|
|
539
|
+
const n = (c, u, s) => {
|
|
540
|
+
const h = o++;
|
|
541
|
+
a.items.push({ id: h, type: c, text: u, timeout: s });
|
|
577
542
|
}, r = (c) => {
|
|
578
|
-
const u = a.items.findIndex((
|
|
543
|
+
const u = a.items.findIndex((s) => s.id === c);
|
|
579
544
|
u >= 0 && a.items.splice(u, 1);
|
|
580
545
|
};
|
|
581
|
-
return (c, u) => (
|
|
582
|
-
onClick: u[0] || (u[0] =
|
|
546
|
+
return (c, u) => (b(), K("div", {
|
|
547
|
+
onClick: u[0] || (u[0] = B(() => {
|
|
583
548
|
}, ["stop"])),
|
|
584
549
|
class: "x-cont d-flex flex-column-reverse align-center"
|
|
585
550
|
}, [
|
|
586
|
-
(
|
|
551
|
+
(b(!0), K(he, null, we(a.items, (s) => (b(), T(Ke, {
|
|
587
552
|
onTimeout: l,
|
|
588
|
-
id:
|
|
589
|
-
type:
|
|
590
|
-
text:
|
|
591
|
-
timeout:
|
|
592
|
-
key:
|
|
553
|
+
id: s.id,
|
|
554
|
+
type: s.type,
|
|
555
|
+
text: s.text,
|
|
556
|
+
timeout: s.timeout,
|
|
557
|
+
key: s.id
|
|
593
558
|
}, null, 8, ["id", "type", "text", "timeout"]))), 128))
|
|
594
559
|
]));
|
|
595
560
|
}
|
|
596
|
-
}),
|
|
561
|
+
}), He = /* @__PURE__ */ ue(Ne, [["__scopeId", "data-v-0ce1c82d"]]), Xe = /* @__PURE__ */ j({
|
|
597
562
|
__name: "index",
|
|
598
563
|
setup(e) {
|
|
599
|
-
const a =
|
|
600
|
-
var
|
|
601
|
-
return ((
|
|
602
|
-
}),
|
|
603
|
-
var
|
|
604
|
-
return ((
|
|
605
|
-
}),
|
|
606
|
-
var
|
|
607
|
-
return ((
|
|
608
|
-
}),
|
|
609
|
-
var
|
|
610
|
-
return ((
|
|
611
|
-
}),
|
|
612
|
-
let
|
|
613
|
-
const
|
|
614
|
-
var
|
|
615
|
-
l.value =
|
|
564
|
+
const a = J(), { open: t } = Z("promptDlg"), l = f(""), o = f(""), n = f(), r = f(), c = f(), u = f(""), s = f(), h = f(), q = i(() => {
|
|
565
|
+
var _;
|
|
566
|
+
return ((_ = s.value) == null ? void 0 : _.color) ?? "primary";
|
|
567
|
+
}), D = i(() => {
|
|
568
|
+
var _;
|
|
569
|
+
return ((_ = s.value) == null ? void 0 : _.text) ?? a.t("cancel");
|
|
570
|
+
}), M = i(() => {
|
|
571
|
+
var _;
|
|
572
|
+
return ((_ = h.value) == null ? void 0 : _.color) ?? "primary";
|
|
573
|
+
}), $ = i(() => {
|
|
574
|
+
var _;
|
|
575
|
+
return ((_ = h.value) == null ? void 0 : _.text) ?? a.t("confirm");
|
|
576
|
+
}), d = f();
|
|
577
|
+
let x = 0, V = !1;
|
|
578
|
+
const E = async (_) => {
|
|
579
|
+
var w;
|
|
580
|
+
l.value = _.title, o.value = _.text, n.value = _.label, r.value = _.placeholder, c.value = _.rules, u.value = _.value, s.value = _.cancel, h.value = _.confirm, x = _.seq, V = !1, t.value = !0, await Q(() => d.value !== void 0, 1e3), (w = d.value) == null || w.focus();
|
|
616
581
|
};
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
}),
|
|
620
|
-
|
|
582
|
+
C(() => {
|
|
583
|
+
p.on("promptDlg", E);
|
|
584
|
+
}), S(() => {
|
|
585
|
+
p.off("promptDlg", E);
|
|
621
586
|
});
|
|
622
|
-
const
|
|
623
|
-
t.value = !1,
|
|
587
|
+
const W = () => {
|
|
588
|
+
t.value = !1, V || (p.emit("promptDlgResult" + x, u.value ?? ""), V = !0);
|
|
624
589
|
};
|
|
625
|
-
return
|
|
626
|
-
!
|
|
627
|
-
}), (
|
|
628
|
-
const
|
|
629
|
-
return
|
|
630
|
-
modelValue:
|
|
631
|
-
"onUpdate:modelValue":
|
|
590
|
+
return H(t, (_) => {
|
|
591
|
+
!_ && !V && (p.emit("promptDlgResult" + x, void 0), V = !0);
|
|
592
|
+
}), (_, w) => {
|
|
593
|
+
const A = v("v-card-text"), pe = v("v-text-field"), _e = v("v-form"), P = v("v-btn"), se = v("v-card-actions"), de = v("v-card"), fe = v("v-dialog");
|
|
594
|
+
return b(), T(fe, {
|
|
595
|
+
modelValue: L(t),
|
|
596
|
+
"onUpdate:modelValue": w[2] || (w[2] = (U) => X(t) ? t.value = U : null),
|
|
632
597
|
onKeydown: [
|
|
633
|
-
|
|
634
|
-
|
|
598
|
+
w[3] || (w[3] = F(B((U) => t.value = !1, ["stop", "prevent"]), ["esc"])),
|
|
599
|
+
F(B(W, ["stop", "prevent"]), ["enter"])
|
|
635
600
|
],
|
|
636
601
|
transition: "dialog-top-transition",
|
|
637
602
|
"max-width": "600px"
|
|
638
603
|
}, {
|
|
639
|
-
default:
|
|
640
|
-
|
|
641
|
-
default:
|
|
642
|
-
o.value ? (
|
|
643
|
-
default:
|
|
644
|
-
|
|
604
|
+
default: m(() => [
|
|
605
|
+
y(de, { title: l.value }, {
|
|
606
|
+
default: m(() => [
|
|
607
|
+
o.value ? (b(), T(A, { key: 0 }, {
|
|
608
|
+
default: m(() => [
|
|
609
|
+
I(R(o.value), 1)
|
|
645
610
|
]),
|
|
646
611
|
_: 1
|
|
647
|
-
})) :
|
|
648
|
-
|
|
649
|
-
default:
|
|
650
|
-
|
|
612
|
+
})) : ye("", !0),
|
|
613
|
+
y(_e, { class: "mx-3" }, {
|
|
614
|
+
default: m(() => [
|
|
615
|
+
y(pe, {
|
|
651
616
|
modelValue: u.value,
|
|
652
|
-
"onUpdate:modelValue":
|
|
617
|
+
"onUpdate:modelValue": w[0] || (w[0] = (U) => u.value = U),
|
|
653
618
|
label: n.value,
|
|
654
619
|
placeholder: r.value,
|
|
655
620
|
rules: c.value,
|
|
656
621
|
ref_key: "target",
|
|
657
|
-
ref:
|
|
622
|
+
ref: d
|
|
658
623
|
}, null, 8, ["modelValue", "label", "placeholder", "rules"])
|
|
659
624
|
]),
|
|
660
625
|
_: 1
|
|
661
626
|
}),
|
|
662
|
-
|
|
663
|
-
default:
|
|
664
|
-
|
|
665
|
-
onClick:
|
|
666
|
-
color:
|
|
627
|
+
y(se, { class: "d-flex justify-end" }, {
|
|
628
|
+
default: m(() => [
|
|
629
|
+
y(P, {
|
|
630
|
+
onClick: w[1] || (w[1] = (U) => t.value = !1),
|
|
631
|
+
color: q.value,
|
|
667
632
|
variant: "text"
|
|
668
633
|
}, {
|
|
669
|
-
default:
|
|
670
|
-
|
|
634
|
+
default: m(() => [
|
|
635
|
+
I(R(D.value), 1)
|
|
671
636
|
]),
|
|
672
637
|
_: 1
|
|
673
638
|
}, 8, ["color"]),
|
|
674
|
-
|
|
675
|
-
onClick:
|
|
676
|
-
color:
|
|
639
|
+
y(P, {
|
|
640
|
+
onClick: W,
|
|
641
|
+
color: M.value,
|
|
677
642
|
variant: "text"
|
|
678
643
|
}, {
|
|
679
|
-
default:
|
|
680
|
-
|
|
644
|
+
default: m(() => [
|
|
645
|
+
I(R($.value), 1)
|
|
681
646
|
]),
|
|
682
647
|
_: 1
|
|
683
648
|
}, 8, ["color"])
|
|
@@ -692,37 +657,37 @@ const $e = /* @__PURE__ */ M({
|
|
|
692
657
|
}, 8, ["modelValue", "onKeydown"]);
|
|
693
658
|
};
|
|
694
659
|
}
|
|
695
|
-
}),
|
|
660
|
+
}), Je = { class: "mx-auto my-auto" }, Ge = { class: "d-flex align-center justify-center w-100 h-100" }, Qe = /* @__PURE__ */ j({
|
|
696
661
|
__name: "index",
|
|
697
662
|
setup(e) {
|
|
698
|
-
const a =
|
|
663
|
+
const a = J(), { open: t } = Z("waitDlg"), l = () => {
|
|
699
664
|
t.value = !0;
|
|
700
665
|
}, o = () => {
|
|
701
666
|
t.value = !1;
|
|
702
667
|
};
|
|
703
|
-
return
|
|
704
|
-
|
|
705
|
-
}),
|
|
706
|
-
|
|
668
|
+
return C(() => {
|
|
669
|
+
p.on("openWaitDlg", l), p.on("closeWaitDlg", o);
|
|
670
|
+
}), S(() => {
|
|
671
|
+
p.off("openWaitDlg", l), p.off("closeWaitDlg", o);
|
|
707
672
|
}), (n, r) => {
|
|
708
|
-
const c =
|
|
709
|
-
return
|
|
710
|
-
modelValue:
|
|
711
|
-
"onUpdate:modelValue": r[0] || (r[0] = (
|
|
673
|
+
const c = v("v-card"), u = v("v-dialog");
|
|
674
|
+
return b(), T(u, {
|
|
675
|
+
modelValue: L(t),
|
|
676
|
+
"onUpdate:modelValue": r[0] || (r[0] = (s) => X(t) ? t.value = s : null),
|
|
712
677
|
persistent: "",
|
|
713
678
|
"no-click-animation": "",
|
|
714
679
|
fullscreen: ""
|
|
715
680
|
}, {
|
|
716
|
-
default:
|
|
717
|
-
|
|
718
|
-
|
|
681
|
+
default: m(() => [
|
|
682
|
+
g("div", Je, [
|
|
683
|
+
y(c, {
|
|
719
684
|
width: "300px",
|
|
720
685
|
height: "80px",
|
|
721
686
|
loading: ""
|
|
722
687
|
}, {
|
|
723
|
-
default:
|
|
724
|
-
|
|
725
|
-
|
|
688
|
+
default: m(() => [
|
|
689
|
+
g("div", Ge, [
|
|
690
|
+
g("span", null, R(L(a).t("waitingResponse")), 1)
|
|
726
691
|
])
|
|
727
692
|
]),
|
|
728
693
|
_: 1
|
|
@@ -733,11 +698,11 @@ const $e = /* @__PURE__ */ M({
|
|
|
733
698
|
}, 8, ["modelValue"]);
|
|
734
699
|
};
|
|
735
700
|
}
|
|
736
|
-
}),
|
|
737
|
-
e.component("x-confirm-dlg",
|
|
701
|
+
}), Ye = (e) => {
|
|
702
|
+
e.component("x-confirm-dlg", Me), e.component("x-loading", Fe), e.component("x-message", He), e.component("x-prompt-dlg", Xe), e.component("x-wait-dlg", Qe);
|
|
738
703
|
};
|
|
739
|
-
function
|
|
740
|
-
const e =
|
|
704
|
+
function yt() {
|
|
705
|
+
const e = G(), a = i(() => e.global.current.value.colors.primary), t = i(() => e.global.current.value.colors.secondary), l = i(() => e.current.value.dark ? "#2e2e2e" : "#bdbdbd"), o = i(() => e.current.value.dark ? "#272727" : "#eeeeee"), n = i(() => e.current.value.dark ? "#1e1e1e" : "#ffffff"), r = i(() => e.current.value.dark ? "#303030" : "#f6f6f6"), c = i(() => e.current.value.dark ? "#ffffff1f" : "#0000001f");
|
|
741
706
|
return {
|
|
742
707
|
primaryColor: a,
|
|
743
708
|
secondaryColor: t,
|
|
@@ -748,123 +713,66 @@ function kt() {
|
|
|
748
713
|
borderColor: c
|
|
749
714
|
};
|
|
750
715
|
}
|
|
751
|
-
function
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
const t = Ce(), l = re(), o = Ue(), n = ue(), r = () => {
|
|
756
|
-
o.running = !1;
|
|
757
|
-
}, c = () => {
|
|
758
|
-
o.running = !0;
|
|
759
|
-
}, u = () => {
|
|
760
|
-
var p;
|
|
761
|
-
if (!n.isEmpty()) {
|
|
762
|
-
n.hasView("waitDlg") || n.popView();
|
|
716
|
+
function xt() {
|
|
717
|
+
const e = Ce(), a = le(), t = re(), l = () => {
|
|
718
|
+
if (!t.isEmpty()) {
|
|
719
|
+
t.hasView("waitDlg") || t.popView();
|
|
763
720
|
return;
|
|
764
721
|
}
|
|
765
|
-
const
|
|
766
|
-
(
|
|
767
|
-
() => {
|
|
768
|
-
},
|
|
769
|
-
() => {
|
|
770
|
-
}
|
|
771
|
-
) : l.back();
|
|
722
|
+
const n = Y(e.path);
|
|
723
|
+
(n == null ? void 0 : n.level) === 0 || a.back();
|
|
772
724
|
};
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
}),
|
|
776
|
-
|
|
725
|
+
C(() => {
|
|
726
|
+
p.on("backbutton", l);
|
|
727
|
+
}), S(() => {
|
|
728
|
+
p.off("backbutton", l);
|
|
777
729
|
});
|
|
778
|
-
const
|
|
779
|
-
if (
|
|
780
|
-
|
|
781
|
-
return;
|
|
782
|
-
}
|
|
783
|
-
if (!e && f.ctrlKey && f.altKey && f.code === "KeyD") {
|
|
784
|
-
o.dark = !o.dark;
|
|
785
|
-
return;
|
|
786
|
-
}
|
|
787
|
-
if (!e && f.ctrlKey && f.altKey && f.code === "KeyL") {
|
|
788
|
-
o.locale === "en" ? o.locale = "zhHans" : o.locale = "en";
|
|
730
|
+
const o = (n) => {
|
|
731
|
+
if (n.key === "Escape") {
|
|
732
|
+
l();
|
|
789
733
|
return;
|
|
790
734
|
}
|
|
791
735
|
};
|
|
792
|
-
|
|
793
|
-
window.addEventListener("keydown",
|
|
794
|
-
}),
|
|
795
|
-
window.removeEventListener("keydown",
|
|
796
|
-
});
|
|
797
|
-
let v;
|
|
798
|
-
const D = async () => {
|
|
799
|
-
if (!o.running)
|
|
800
|
-
return;
|
|
801
|
-
const f = F(t.path);
|
|
802
|
-
if (!(!f || f.requiredState !== "org"))
|
|
803
|
-
try {
|
|
804
|
-
const { update: p, permissions: y } = await Pe(a, {
|
|
805
|
-
checksum: o.permissionChecksum
|
|
806
|
-
});
|
|
807
|
-
if (!p)
|
|
808
|
-
return;
|
|
809
|
-
const C = {};
|
|
810
|
-
for (const S in y) {
|
|
811
|
-
if (S === "checksum")
|
|
812
|
-
continue;
|
|
813
|
-
const I = y[S];
|
|
814
|
-
C[S] = JSON.parse(I);
|
|
815
|
-
}
|
|
816
|
-
o.permissionObjects = C, o.permissionChecksum = y.checksum ?? "";
|
|
817
|
-
} catch (p) {
|
|
818
|
-
console.error(p);
|
|
819
|
-
}
|
|
820
|
-
}, b = async (f) => {
|
|
821
|
-
f && await D(), clearTimeout(v), v = setTimeout(async () => {
|
|
822
|
-
await D(), v && b();
|
|
823
|
-
}, 3e3);
|
|
824
|
-
}, j = () => {
|
|
825
|
-
clearTimeout(v), v = void 0;
|
|
826
|
-
};
|
|
827
|
-
R(() => {
|
|
828
|
-
a && b(!0);
|
|
829
|
-
}), O(() => {
|
|
830
|
-
j();
|
|
736
|
+
C(() => {
|
|
737
|
+
window.addEventListener("keydown", o);
|
|
738
|
+
}), S(() => {
|
|
739
|
+
window.removeEventListener("keydown", o);
|
|
831
740
|
});
|
|
832
741
|
}
|
|
833
|
-
function
|
|
834
|
-
const e =
|
|
742
|
+
function kt() {
|
|
743
|
+
const e = G(), a = xe(), t = i(() => e.current.value.dark), l = i(() => !!window.cordova), o = i(() => a.width.value <= 1280 ? a.width.value + "px" : a.width.value <= 1920 ? 1920 / 2.5 + "px" : 2560 / 2.5 + "px");
|
|
835
744
|
return { dark: t, sysBarAvail: l, compactWidth: o };
|
|
836
745
|
}
|
|
837
|
-
const
|
|
746
|
+
const bt = { install: Ye };
|
|
838
747
|
export {
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
748
|
+
je as Permission,
|
|
749
|
+
ht as appAppear,
|
|
750
|
+
ut as closeWaitDlg,
|
|
751
|
+
ot as createAxios,
|
|
752
|
+
_t as dark,
|
|
753
|
+
bt as default,
|
|
754
|
+
p as eventBus,
|
|
846
755
|
te as isExist,
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
756
|
+
st as locale,
|
|
757
|
+
pt as mainActive,
|
|
758
|
+
Y as matchRouteMeta,
|
|
759
|
+
it as messageError,
|
|
760
|
+
gt as messageInfo,
|
|
761
|
+
vt as messageSuccess,
|
|
762
|
+
mt as messageWarning,
|
|
763
|
+
wt as onBeforeEach,
|
|
764
|
+
rt as openConfirmDlg,
|
|
765
|
+
nt as openPromptDlg,
|
|
766
|
+
ct as openWaitDlg,
|
|
767
|
+
dt as permissionChecksum,
|
|
768
|
+
Ee as permissionObjects,
|
|
860
769
|
oe as routeTransName,
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
ue as useViewMgrStore,
|
|
770
|
+
yt as useColor,
|
|
771
|
+
xt as useMicroApp,
|
|
772
|
+
kt as useSystem,
|
|
773
|
+
re as useViewMgrStore,
|
|
866
774
|
Z as useViewStack,
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
775
|
+
ft as verifyPermission,
|
|
776
|
+
lt as waitMs,
|
|
777
|
+
Q as waitUtil
|
|
870
778
|
};
|
package/dist/store/index.d.ts
CHANGED