x-essential-lib 0.8.6 → 0.8.8
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/index.js +344 -343
- package/dist/utils/provideInject.d.ts +2 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
(function(){"use strict";try{if(typeof document<"u"){var t=document.createElement("style");t.id="x-essential-lib",t.appendChild(document.createTextNode('.fade-leave-active[data-v-0c686889]{transition:opacity .5s ease}.fade-leave-to[data-v-0c686889]{opacity:0}.x-cont[data-v-0c686889]{position:absolute;top:0;left:0;bottom:0;right:0;display:flex;align-items:center;justify-content:center}.lds-spinner[data-v-0c686889]{color:official;display:inline-block;position:relative;width:40px;height:40px}.lds-spinner div[data-v-0c686889]{transform-origin:20px 20px;animation:lds-spinner-0c686889 1.2s linear infinite}.lds-spinner div[data-v-0c686889]:after{content:" ";display:block;position:absolute;top:3px;left:18px;width:2px;height:6px;border-radius:5%;background:#9e9e9e}.lds-spinner div[data-v-0c686889]:nth-child(1){transform:rotate(0);animation-delay:-1.1s}.lds-spinner div[data-v-0c686889]:nth-child(2){transform:rotate(30deg);animation-delay:-1s}.lds-spinner div[data-v-0c686889]:nth-child(3){transform:rotate(60deg);animation-delay:-.9s}.lds-spinner div[data-v-0c686889]:nth-child(4){transform:rotate(90deg);animation-delay:-.8s}.lds-spinner div[data-v-0c686889]:nth-child(5){transform:rotate(120deg);animation-delay:-.7s}.lds-spinner div[data-v-0c686889]:nth-child(6){transform:rotate(150deg);animation-delay:-.6s}.lds-spinner div[data-v-0c686889]:nth-child(7){transform:rotate(180deg);animation-delay:-.5s}.lds-spinner div[data-v-0c686889]:nth-child(8){transform:rotate(210deg);animation-delay:-.4s}.lds-spinner div[data-v-0c686889]:nth-child(9){transform:rotate(240deg);animation-delay:-.3s}.lds-spinner div[data-v-0c686889]:nth-child(10){transform:rotate(270deg);animation-delay:-.2s}.lds-spinner div[data-v-0c686889]:nth-child(11){transform:rotate(300deg);animation-delay:-.1s}.lds-spinner div[data-v-0c686889]:nth-child(12){transform:rotate(330deg);animation-delay:0s}@keyframes lds-spinner-0c686889{0%{opacity:1}to{opacity:0}}.x-item[data-v-74835a85]{width:600px}@media (max-width: 600px){.x-item[data-v-74835a85]{width:calc(100vw - 16px)}}.x-cont[data-v-c6a59757]{position:fixed;left:50%;bottom:20px;transform:translate(-50%);z-index:9999}')),document.head.appendChild(t)}}catch(a){console.error("vite-plugin-css-injected-by-js",a)}})();
|
|
2
|
-
import { computed as x, provide as
|
|
3
|
-
import { useI18n as
|
|
4
|
-
import { useTheme as
|
|
5
|
-
import { useRouter as
|
|
2
|
+
import { computed as x, provide as B, inject as q, ref as g, getCurrentInstance as de, hasInjectionContext as fe, watch as Q, getCurrentScope as Re, onScopeDispose as Ae, shallowRef as Z, watchEffect as te, toValue as O, onMounted as E, unref as z, onBeforeUnmount as $, onBeforeMount as qe, defineComponent as U, resolveComponent as b, createBlock as R, openBlock as S, withKeys as ae, withModifiers as H, isRef as J, withCtx as w, createVNode as C, createTextVNode as I, toDisplayString as V, Transition as Oe, createElementBlock as oe, createCommentVNode as re, normalizeStyle as ge, createElementVNode as y, Fragment as Ie, renderList as Te, useTemplateRef as Be } from "vue";
|
|
3
|
+
import { useI18n as le } from "vue-i18n";
|
|
4
|
+
import { useTheme as ve, useDisplay as Ee } from "vuetify";
|
|
5
|
+
import { useRouter as me, useRoute as Ue } from "vue-router";
|
|
6
6
|
import We from "axios";
|
|
7
|
-
function
|
|
8
|
-
const e =
|
|
7
|
+
function $e() {
|
|
8
|
+
const e = ve(), t = x(() => e.global.current.value.colors.primary), a = x(() => e.global.current.value.colors.secondary), o = x(() => e.current.value.dark ? "#2e2e2e" : "#bdbdbd"), n = x(() => e.current.value.dark ? "#272727" : "#eeeeee"), l = x(() => e.current.value.dark ? "#1e1e1e" : "#ffffff"), c = x(() => e.current.value.dark ? "#303030" : "#f6f6f6"), r = x(() => e.current.value.dark ? "#ffffff1f" : "#0000001f");
|
|
9
9
|
return {
|
|
10
10
|
primaryColor: t,
|
|
11
11
|
secondaryColor: a,
|
|
@@ -25,7 +25,7 @@ function N(e) {
|
|
|
25
25
|
}
|
|
26
26
|
return e;
|
|
27
27
|
}
|
|
28
|
-
var
|
|
28
|
+
var He = {
|
|
29
29
|
read: function(e) {
|
|
30
30
|
return e[0] === '"' && (e = e.slice(1, -1)), e.replace(/(%[\dA-F]{2})+/gi, decodeURIComponent);
|
|
31
31
|
},
|
|
@@ -36,7 +36,7 @@ var $e = {
|
|
|
36
36
|
);
|
|
37
37
|
}
|
|
38
38
|
};
|
|
39
|
-
function
|
|
39
|
+
function ne(e, t) {
|
|
40
40
|
function a(n, l, c) {
|
|
41
41
|
if (!(typeof document > "u")) {
|
|
42
42
|
c = N({}, t, c), typeof c.expires == "number" && (c.expires = new Date(Date.now() + c.expires * 864e5)), c.expires && (c.expires = c.expires.toUTCString()), n = encodeURIComponent(n).replace(/%(2[346B]|5E|60|7C)/g, decodeURIComponent).replace(/[()]/g, escape);
|
|
@@ -74,10 +74,10 @@ function ae(e, t) {
|
|
|
74
74
|
);
|
|
75
75
|
},
|
|
76
76
|
withAttributes: function(n) {
|
|
77
|
-
return
|
|
77
|
+
return ne(this.converter, N({}, this.attributes, n));
|
|
78
78
|
},
|
|
79
79
|
withConverter: function(n) {
|
|
80
|
-
return
|
|
80
|
+
return ne(N({}, this.converter, n), this.attributes);
|
|
81
81
|
}
|
|
82
82
|
},
|
|
83
83
|
{
|
|
@@ -86,43 +86,43 @@ function ae(e, t) {
|
|
|
86
86
|
}
|
|
87
87
|
);
|
|
88
88
|
}
|
|
89
|
-
var
|
|
90
|
-
function
|
|
89
|
+
var T = ne(He, { path: "/" });
|
|
90
|
+
function Yt(e) {
|
|
91
91
|
const t = We.create({
|
|
92
92
|
timeout: 6e3
|
|
93
93
|
});
|
|
94
94
|
return t.defaults.baseURL = e.baseUrl, t.interceptors.request.use(
|
|
95
|
-
(a) =>
|
|
95
|
+
(a) => ze(a),
|
|
96
96
|
(a) => {
|
|
97
97
|
Ke(a, e.onError);
|
|
98
98
|
}
|
|
99
99
|
), t.interceptors.response.use(
|
|
100
|
-
(a) =>
|
|
101
|
-
(a) =>
|
|
100
|
+
(a) => Fe(a),
|
|
101
|
+
(a) => Xe(a, e.onError)
|
|
102
102
|
), t;
|
|
103
103
|
}
|
|
104
|
-
function
|
|
105
|
-
const t =
|
|
104
|
+
function ze(e) {
|
|
105
|
+
const t = T.get("accessToken") ?? "";
|
|
106
106
|
return e.headers.Authorization = "Basic " + t, e.headers["Content-Type"] = "application/json", e.data = JSON.stringify(e.data), e;
|
|
107
107
|
}
|
|
108
108
|
function Ke(e, t) {
|
|
109
109
|
console.error(e), t("request timeout");
|
|
110
110
|
}
|
|
111
|
-
function
|
|
111
|
+
function Fe(e) {
|
|
112
112
|
return e.data;
|
|
113
113
|
}
|
|
114
|
-
function
|
|
114
|
+
function Xe(e, t) {
|
|
115
115
|
var n, l;
|
|
116
116
|
const o = e.response;
|
|
117
|
-
return o && (o.status === 401 &&
|
|
117
|
+
return o && (o.status === 401 && Ne(), (n = o.data) != null && n.message ? t((l = o.data) == null ? void 0 : l.message) : t({
|
|
118
118
|
code: o.status,
|
|
119
119
|
message: o.statusText
|
|
120
120
|
})), Promise.reject(e);
|
|
121
121
|
}
|
|
122
|
-
function
|
|
123
|
-
|
|
122
|
+
function Ne() {
|
|
123
|
+
T.remove("accessToken"), T.remove("refreshToken"), T.remove("activeOrg"), me().replace({ path: "/passport/login" });
|
|
124
124
|
}
|
|
125
|
-
function
|
|
125
|
+
function Ze(e) {
|
|
126
126
|
return { all: e = e || /* @__PURE__ */ new Map(), on: function(t, a) {
|
|
127
127
|
var o = e.get(t);
|
|
128
128
|
o ? o.push(a) : e.set(t, [a]);
|
|
@@ -139,14 +139,14 @@ function Ne(e) {
|
|
|
139
139
|
} };
|
|
140
140
|
}
|
|
141
141
|
const p = function() {
|
|
142
|
-
return window.eventBus || (window.eventBus =
|
|
142
|
+
return window.eventBus || (window.eventBus = Ze()), window.eventBus;
|
|
143
143
|
}();
|
|
144
|
-
async function
|
|
144
|
+
async function Pt(e) {
|
|
145
145
|
return new Promise((t) => {
|
|
146
146
|
setTimeout(t, e);
|
|
147
147
|
});
|
|
148
148
|
}
|
|
149
|
-
async function
|
|
149
|
+
async function ce(e, t, a) {
|
|
150
150
|
const o = Date.now();
|
|
151
151
|
return new Promise((n) => {
|
|
152
152
|
const l = async () => {
|
|
@@ -155,59 +155,59 @@ async function re(e, t, a) {
|
|
|
155
155
|
l();
|
|
156
156
|
});
|
|
157
157
|
}
|
|
158
|
-
function
|
|
158
|
+
function Ge(e, t) {
|
|
159
159
|
const a = document.getElementById("single-spa-application:" + e);
|
|
160
160
|
a && (a.classList.remove("app-left", "app-right", "app-reset"), t ? a.classList.add("app-left") : a.classList.add("app-right"), setTimeout(() => {
|
|
161
161
|
a.classList.add("app-reset");
|
|
162
162
|
}, 50));
|
|
163
163
|
}
|
|
164
|
-
let
|
|
165
|
-
function
|
|
164
|
+
let pe = Date.now();
|
|
165
|
+
function he() {
|
|
166
166
|
const e = Date.now();
|
|
167
|
-
return e -
|
|
167
|
+
return e - pe > 500 ? (pe = e, !0) : !1;
|
|
168
168
|
}
|
|
169
|
-
let
|
|
170
|
-
function
|
|
171
|
-
return ++
|
|
169
|
+
let Qe = 0;
|
|
170
|
+
function ye() {
|
|
171
|
+
return ++Qe;
|
|
172
172
|
}
|
|
173
|
-
async function
|
|
174
|
-
if (!
|
|
173
|
+
async function ea(e) {
|
|
174
|
+
if (!he())
|
|
175
175
|
return;
|
|
176
176
|
let t = !1, a;
|
|
177
177
|
const o = (l) => {
|
|
178
178
|
a = l, t = !0;
|
|
179
|
-
}, n =
|
|
180
|
-
return p.on("confirmDlgResult" + n, o), p.emit("confirmDlg", { ...e, seq: n }), await
|
|
179
|
+
}, n = ye();
|
|
180
|
+
return p.on("confirmDlgResult" + n, o), p.emit("confirmDlg", { ...e, seq: n }), await ce(() => t), p.off("confirmDlgResult" + n, o), a;
|
|
181
181
|
}
|
|
182
|
-
async function
|
|
183
|
-
if (!
|
|
182
|
+
async function ta(e) {
|
|
183
|
+
if (!he())
|
|
184
184
|
return;
|
|
185
185
|
let t = !1, a;
|
|
186
186
|
const o = (l) => {
|
|
187
187
|
a = l, t = !0;
|
|
188
|
-
}, n =
|
|
189
|
-
return p.on("promptDlgResult" + n, o), p.emit("promptDlg", { ...e, seq: n }), await
|
|
188
|
+
}, n = ye();
|
|
189
|
+
return p.on("promptDlgResult" + n, o), p.emit("promptDlg", { ...e, seq: n }), await ce(() => t), p.off("promptDlgResult" + n, o), a;
|
|
190
190
|
}
|
|
191
|
-
function
|
|
191
|
+
function aa(e) {
|
|
192
192
|
p.emit("openWaitDlg", { text: e });
|
|
193
193
|
}
|
|
194
|
-
function
|
|
194
|
+
function oa() {
|
|
195
195
|
p.emit("closeWaitDlg");
|
|
196
196
|
}
|
|
197
|
-
function
|
|
197
|
+
function na(e, t) {
|
|
198
198
|
p.emit("message", { type: "error", text: e, timeout: t });
|
|
199
199
|
}
|
|
200
|
-
function
|
|
200
|
+
function ra(e, t) {
|
|
201
201
|
p.emit("message", { type: "info", text: e, timeout: t });
|
|
202
202
|
}
|
|
203
|
-
function
|
|
203
|
+
function la(e, t) {
|
|
204
204
|
p.emit("message", { type: "success", text: e, timeout: t });
|
|
205
205
|
}
|
|
206
|
-
function
|
|
206
|
+
function ca(e, t) {
|
|
207
207
|
p.emit("message", { type: "warning", text: e, timeout: t });
|
|
208
208
|
}
|
|
209
|
-
var
|
|
210
|
-
function
|
|
209
|
+
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_compute_space = "list_compute_space", e.get_compute_space = "get_compute_space", e.create_compute_space = "create_compute_space", e.delete_compute_space = "delete_compute_space", e.update_compute_space = "update_compute_space", e.arrange_compute_space = "arrange_compute_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.debug_flow = "debug_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_compute_layer = "open_compute_layer", e.list_data_space = "list_data_space", e.get_data_space = "get_data_space", e.create_data_space = "create_data_space", e.delete_data_space = "delete_data_space", e.update_data_space = "update_data_space", e.arrange_data_space = "arrange_data_space", e.list_table_group = "list_table_group", e.create_table_group = "create_table_group", e.delete_table_group = "delete_table_group", e.update_table_group = "update_table_group", e.arrange_table_group = "arrange_table_group", e.list_table = "list_table", e.get_table = "get_table", e.create_table = "create_table", e.delete_table = "delete_table", e.update_table = "update_table", e.get_data = "get_data", e.create_data = "create_data", e.delete_data = "delete_data", e.update_data = "update_data", e.get_relation_graph = "get_relation_graph", e.update_relation_graph = "update_relation_graph", e.list_change = "list_change", e.apply_change = "apply_change", e.open_data_layer = "open_data_layer", e.list_resource_space = "list_resource_space", e.get_resource_space = "get_resource_space", e.create_resource_space = "create_resource_space", e.delete_resource_space = "delete_resource_space", e.update_resource_space = "update_resource_space", e.arrange_resource_space = "arrange_resource_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_resource = "list_resource", e.get_resource = "get_resource", e.create_resource = "create_resource", e.delete_resource = "delete_resource", e.update_resource = "update_resource", e.move_resource = "move_resource", e.open_resource_layer = "open_resource_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_group = "list_org_role_group", e.create_org_role_group = "create_org_role_group", e.delete_org_role_group = "delete_org_role_group", e.update_org_role_group = "update_org_role_group", e.arrange_org_role_group = "arrange_org_role_group", 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.get_org_structure = "get_org_structure", e.update_org_structure = "update_org_structure", e.filter_table = "filter_table", e))(Je || {});
|
|
210
|
+
function _e(e, t) {
|
|
211
211
|
if (!e)
|
|
212
212
|
return !1;
|
|
213
213
|
let a = e;
|
|
@@ -220,48 +220,48 @@ function se(e, t) {
|
|
|
220
220
|
return !1;
|
|
221
221
|
}), Object.keys(a).length <= 0);
|
|
222
222
|
}
|
|
223
|
-
function
|
|
223
|
+
function Ye(e, t, a) {
|
|
224
224
|
const o = e[t];
|
|
225
|
-
return o ? a ? !(!
|
|
226
|
-
}
|
|
227
|
-
const he = "essentialDark", ye = "essentialLocale", we = "essentialPermissionObjects", xe = "essentialPermissionChecksum", be = "essentialLastAppPath", ke = "essentialViews";
|
|
228
|
-
function Ye(e) {
|
|
229
|
-
T(he, e);
|
|
230
|
-
}
|
|
231
|
-
function ca() {
|
|
232
|
-
return A(he);
|
|
225
|
+
return o ? a ? !(!_e(o.includes, a) || _e(o.excludes, a)) : !0 : !1;
|
|
233
226
|
}
|
|
227
|
+
const we = "essentialDark", xe = "essentialLocale", be = "essentialPermissionObjects", ke = "essentialPermissionChecksum", Ce = "essentialLastAppPath", Le = "essentialViews";
|
|
234
228
|
function Pe(e) {
|
|
235
|
-
|
|
229
|
+
B(we, e);
|
|
236
230
|
}
|
|
237
231
|
function ua() {
|
|
238
|
-
return
|
|
232
|
+
return q(we);
|
|
239
233
|
}
|
|
240
234
|
function et(e) {
|
|
241
|
-
|
|
235
|
+
B(xe, e);
|
|
242
236
|
}
|
|
243
|
-
function
|
|
244
|
-
return
|
|
237
|
+
function sa() {
|
|
238
|
+
return q(xe);
|
|
245
239
|
}
|
|
246
|
-
function
|
|
247
|
-
|
|
240
|
+
function tt(e) {
|
|
241
|
+
B(be, e);
|
|
248
242
|
}
|
|
249
|
-
function
|
|
250
|
-
return
|
|
243
|
+
function at() {
|
|
244
|
+
return q(be);
|
|
251
245
|
}
|
|
252
246
|
function ot(e) {
|
|
253
|
-
|
|
247
|
+
B(ke, e);
|
|
254
248
|
}
|
|
255
249
|
function pa() {
|
|
256
|
-
return
|
|
250
|
+
return q(ke);
|
|
257
251
|
}
|
|
258
252
|
function nt(e) {
|
|
259
|
-
|
|
253
|
+
B(Ce, e);
|
|
254
|
+
}
|
|
255
|
+
function _a() {
|
|
256
|
+
return q(Ce);
|
|
260
257
|
}
|
|
261
|
-
function rt() {
|
|
262
|
-
|
|
258
|
+
function rt(e) {
|
|
259
|
+
B(Le, e);
|
|
263
260
|
}
|
|
264
|
-
|
|
261
|
+
function lt() {
|
|
262
|
+
return q(Le);
|
|
263
|
+
}
|
|
264
|
+
const ct = [
|
|
265
265
|
{
|
|
266
266
|
app: "x-passport-mf",
|
|
267
267
|
path: "/passport/login",
|
|
@@ -369,10 +369,10 @@ const lt = [
|
|
|
369
369
|
mainActive: 2
|
|
370
370
|
}
|
|
371
371
|
];
|
|
372
|
-
function
|
|
372
|
+
function G(e) {
|
|
373
373
|
let t, a = 0;
|
|
374
374
|
const o = e.split("/").filter((n) => n.trim() !== "");
|
|
375
|
-
return
|
|
375
|
+
return ct.forEach((n) => {
|
|
376
376
|
const l = n.path.split("/").filter((r) => r.trim() !== "");
|
|
377
377
|
let c = 0;
|
|
378
378
|
for (let r = 0; r < o.length && !(r >= l.length || o[r] !== l[r]); r++)
|
|
@@ -381,9 +381,9 @@ function Q(e) {
|
|
|
381
381
|
}), t;
|
|
382
382
|
}
|
|
383
383
|
const Y = g("");
|
|
384
|
-
function
|
|
384
|
+
function j(e, t, a) {
|
|
385
385
|
t === "/" && (t = a);
|
|
386
|
-
const o =
|
|
386
|
+
const o = G(e), n = G(t);
|
|
387
387
|
if (!o) {
|
|
388
388
|
console.assert(!1);
|
|
389
389
|
return;
|
|
@@ -391,16 +391,16 @@ function S(e, t, a) {
|
|
|
391
391
|
if (console.info(`~~~~routeChange~~~~ ${t} -> ${e}`), !n)
|
|
392
392
|
return;
|
|
393
393
|
const l = o.app === n.app, c = o.path === n.path, r = o.level >= n.level;
|
|
394
|
-
l ? c ? Y.value = "" : Y.value = r ? "inner-left" : "inner-right" : (Y.value = "",
|
|
395
|
-
}
|
|
396
|
-
function ct() {
|
|
397
|
-
return !!I.get("accessToken");
|
|
394
|
+
l ? c ? Y.value = "" : Y.value = r ? "inner-left" : "inner-right" : (Y.value = "", Ge(o.app, r));
|
|
398
395
|
}
|
|
399
396
|
function ut() {
|
|
400
|
-
return !!
|
|
397
|
+
return !!T.get("accessToken");
|
|
398
|
+
}
|
|
399
|
+
function st() {
|
|
400
|
+
return !!T.get("activeOrg");
|
|
401
401
|
}
|
|
402
|
-
function
|
|
403
|
-
const n =
|
|
402
|
+
function ia(e, t, a, o) {
|
|
403
|
+
const n = ut(), l = st(), c = G(e.path);
|
|
404
404
|
if (!c) {
|
|
405
405
|
console.assert(!1), a();
|
|
406
406
|
return;
|
|
@@ -409,79 +409,79 @@ function _a(e, t, a, o) {
|
|
|
409
409
|
if (n)
|
|
410
410
|
if (l) {
|
|
411
411
|
const r = "/main";
|
|
412
|
-
|
|
412
|
+
j(r, t.path, o), a({ path: r });
|
|
413
413
|
} else
|
|
414
|
-
|
|
414
|
+
j(e.path, t.path, o), a();
|
|
415
415
|
else {
|
|
416
416
|
const r = "/passport/login";
|
|
417
|
-
|
|
417
|
+
j(r, t.path, o), a({ path: r });
|
|
418
418
|
}
|
|
419
419
|
else if (c.requiredState === "org")
|
|
420
420
|
if (n)
|
|
421
421
|
if (l)
|
|
422
|
-
|
|
422
|
+
j(e.path, t.path, o), a();
|
|
423
423
|
else {
|
|
424
424
|
const r = "/org/joinOrCreate";
|
|
425
|
-
|
|
425
|
+
j(r, t.path, o), a({ path: r });
|
|
426
426
|
}
|
|
427
427
|
else {
|
|
428
428
|
const r = "/passport/login";
|
|
429
|
-
|
|
429
|
+
j(r, t.path, o), a({ path: r });
|
|
430
430
|
}
|
|
431
431
|
else if (n)
|
|
432
432
|
if (l) {
|
|
433
433
|
const r = "/main";
|
|
434
|
-
|
|
434
|
+
j(r, t.path, o), a({ path: r });
|
|
435
435
|
} else {
|
|
436
436
|
const r = "/org/joinOrCreate";
|
|
437
|
-
|
|
437
|
+
j(r, t.path, o), a({ path: r });
|
|
438
438
|
}
|
|
439
439
|
else
|
|
440
|
-
|
|
440
|
+
j(e.path, t.path, o), a();
|
|
441
441
|
}
|
|
442
|
-
function
|
|
442
|
+
function pt(e) {
|
|
443
443
|
return e.value.length <= 0;
|
|
444
444
|
}
|
|
445
|
-
function
|
|
445
|
+
function da(e) {
|
|
446
446
|
return e.value.at(-1);
|
|
447
447
|
}
|
|
448
|
-
function
|
|
448
|
+
function De(e, t) {
|
|
449
449
|
return !!e.value.find((a) => a === t);
|
|
450
450
|
}
|
|
451
|
-
function
|
|
451
|
+
function _t(e, t) {
|
|
452
452
|
const a = e.value.findIndex((o) => o === t);
|
|
453
453
|
a >= 0 && e.value.splice(a, 1), e.value.push(t);
|
|
454
454
|
}
|
|
455
|
-
function
|
|
455
|
+
function it(e, t) {
|
|
456
456
|
const a = e.value.findIndex((o) => o === t);
|
|
457
457
|
a >= 0 && e.value.splice(a, 1);
|
|
458
458
|
}
|
|
459
|
-
function
|
|
459
|
+
function dt(e) {
|
|
460
460
|
console.assert(e.value.length > 0), e.value.pop();
|
|
461
461
|
}
|
|
462
|
-
function
|
|
462
|
+
function fa(e) {
|
|
463
463
|
e.value = [];
|
|
464
464
|
}
|
|
465
|
-
function
|
|
466
|
-
return
|
|
465
|
+
function ft(e) {
|
|
466
|
+
return Re() ? (Ae(e), !0) : !1;
|
|
467
467
|
}
|
|
468
|
-
const P = /* @__PURE__ */ new WeakMap(),
|
|
468
|
+
const P = /* @__PURE__ */ new WeakMap(), gt = (...e) => {
|
|
469
469
|
var t;
|
|
470
|
-
const a = e[0], o = (t =
|
|
471
|
-
if (o == null && !
|
|
470
|
+
const a = e[0], o = (t = de()) == null ? void 0 : t.proxy;
|
|
471
|
+
if (o == null && !fe())
|
|
472
472
|
throw new Error("injectLocal must be called in setup");
|
|
473
|
-
return o && P.has(o) && a in P.get(o) ? P.get(o)[a] :
|
|
474
|
-
},
|
|
473
|
+
return o && P.has(o) && a in P.get(o) ? P.get(o)[a] : q(...e);
|
|
474
|
+
}, vt = typeof window < "u" && typeof document < "u";
|
|
475
475
|
typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope;
|
|
476
|
-
const
|
|
477
|
-
function
|
|
476
|
+
const mt = Object.prototype.toString, ht = (e) => mt.call(e) === "[object Object]";
|
|
477
|
+
function ie(e) {
|
|
478
478
|
return e.endsWith("rem") ? Number.parseFloat(e) * 16 : Number.parseFloat(e);
|
|
479
479
|
}
|
|
480
480
|
function ee(e) {
|
|
481
481
|
return Array.isArray(e) ? e : [e];
|
|
482
482
|
}
|
|
483
|
-
function
|
|
484
|
-
return
|
|
483
|
+
function yt(e, t, a) {
|
|
484
|
+
return Q(
|
|
485
485
|
e,
|
|
486
486
|
t,
|
|
487
487
|
{
|
|
@@ -490,33 +490,33 @@ function ht(e, t, a) {
|
|
|
490
490
|
}
|
|
491
491
|
);
|
|
492
492
|
}
|
|
493
|
-
const
|
|
494
|
-
function
|
|
493
|
+
const Se = vt ? window : void 0;
|
|
494
|
+
function wt(e) {
|
|
495
495
|
var t;
|
|
496
|
-
const a =
|
|
496
|
+
const a = O(e);
|
|
497
497
|
return (t = a == null ? void 0 : a.$el) != null ? t : a;
|
|
498
498
|
}
|
|
499
|
-
function
|
|
499
|
+
function xt(...e) {
|
|
500
500
|
const t = [], a = () => {
|
|
501
501
|
t.forEach((r) => r()), t.length = 0;
|
|
502
502
|
}, o = (r, u, s, i) => (r.addEventListener(u, s, i), () => r.removeEventListener(u, s, i)), n = x(() => {
|
|
503
|
-
const r = ee(
|
|
503
|
+
const r = ee(O(e[0])).filter((u) => u != null);
|
|
504
504
|
return r.every((u) => typeof u != "string") ? r : void 0;
|
|
505
|
-
}), l =
|
|
505
|
+
}), l = yt(
|
|
506
506
|
() => {
|
|
507
507
|
var r, u;
|
|
508
508
|
return [
|
|
509
|
-
(u = (r = n.value) == null ? void 0 : r.map((s) =>
|
|
510
|
-
ee(
|
|
509
|
+
(u = (r = n.value) == null ? void 0 : r.map((s) => wt(s))) != null ? u : [Se].filter((s) => s != null),
|
|
510
|
+
ee(O(n.value ? e[1] : e[0])),
|
|
511
511
|
ee(z(n.value ? e[2] : e[1])),
|
|
512
512
|
// @ts-expect-error - TypeScript gets the correct types, but somehow still complains
|
|
513
|
-
|
|
513
|
+
O(n.value ? e[3] : e[2])
|
|
514
514
|
];
|
|
515
515
|
},
|
|
516
516
|
([r, u, s, i]) => {
|
|
517
517
|
if (a(), !(r != null && r.length) || !(u != null && u.length) || !(s != null && s.length))
|
|
518
518
|
return;
|
|
519
|
-
const v =
|
|
519
|
+
const v = ht(i) ? { ...i } : i;
|
|
520
520
|
t.push(
|
|
521
521
|
...r.flatMap(
|
|
522
522
|
(k) => u.flatMap(
|
|
@@ -529,106 +529,104 @@ function wt(...e) {
|
|
|
529
529
|
), c = () => {
|
|
530
530
|
l(), a();
|
|
531
531
|
};
|
|
532
|
-
return
|
|
532
|
+
return ft(a), c;
|
|
533
533
|
}
|
|
534
|
-
function
|
|
535
|
-
const e = Z(!1), t =
|
|
536
|
-
return t &&
|
|
534
|
+
function bt() {
|
|
535
|
+
const e = Z(!1), t = de();
|
|
536
|
+
return t && E(() => {
|
|
537
537
|
e.value = !0;
|
|
538
538
|
}, t), e;
|
|
539
539
|
}
|
|
540
|
-
function
|
|
541
|
-
const t =
|
|
540
|
+
function kt(e) {
|
|
541
|
+
const t = bt();
|
|
542
542
|
return x(() => (t.value, !!e()));
|
|
543
543
|
}
|
|
544
|
-
const
|
|
545
|
-
function
|
|
546
|
-
const e =
|
|
544
|
+
const Ct = Symbol("vueuse-ssr-width");
|
|
545
|
+
function Lt() {
|
|
546
|
+
const e = fe() ? gt(Ct, null) : null;
|
|
547
547
|
return typeof e == "number" ? e : void 0;
|
|
548
548
|
}
|
|
549
|
-
function
|
|
550
|
-
const { window: a =
|
|
549
|
+
function Dt(e, t = {}) {
|
|
550
|
+
const { window: a = Se, ssrWidth: o = Lt() } = t, n = kt(() => a && "matchMedia" in a && typeof a.matchMedia == "function"), l = Z(typeof o == "number"), c = Z(), r = Z(!1), u = (s) => {
|
|
551
551
|
r.value = s.matches;
|
|
552
552
|
};
|
|
553
|
-
return
|
|
553
|
+
return te(() => {
|
|
554
554
|
if (l.value) {
|
|
555
555
|
l.value = !n.value;
|
|
556
|
-
const s =
|
|
556
|
+
const s = O(e).split(",");
|
|
557
557
|
r.value = s.some((i) => {
|
|
558
558
|
const v = i.includes("not all"), k = i.match(/\(\s*min-width:\s*(-?\d+(?:\.\d*)?[a-z]+\s*)\)/), m = i.match(/\(\s*max-width:\s*(-?\d+(?:\.\d*)?[a-z]+\s*)\)/);
|
|
559
559
|
let _ = !!(k || m);
|
|
560
|
-
return k && _ && (_ = o >=
|
|
560
|
+
return k && _ && (_ = o >= ie(k[1])), m && _ && (_ = o <= ie(m[1])), v ? !_ : _;
|
|
561
561
|
});
|
|
562
562
|
return;
|
|
563
563
|
}
|
|
564
|
-
n.value && (c.value = a.matchMedia(
|
|
565
|
-
}),
|
|
566
|
-
}
|
|
567
|
-
function
|
|
568
|
-
return
|
|
569
|
-
}
|
|
570
|
-
function
|
|
571
|
-
const c =
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
if (!st(l)) {
|
|
585
|
-
Ce(l, "waitDlg") || it(l);
|
|
564
|
+
n.value && (c.value = a.matchMedia(O(e)), r.value = c.value.matches);
|
|
565
|
+
}), xt(c, "change", u, { passive: !0 }), x(() => r.value);
|
|
566
|
+
}
|
|
567
|
+
function St(e) {
|
|
568
|
+
return Dt("(prefers-color-scheme: dark)", e);
|
|
569
|
+
}
|
|
570
|
+
function ga(e, t, a, o, n, l) {
|
|
571
|
+
const c = Ue(), r = me(), u = St(), s = g(!1);
|
|
572
|
+
te(() => {
|
|
573
|
+
let f = !1;
|
|
574
|
+
typeof e.value == "boolean" ? f = e.value : f = u.value, s.value = f;
|
|
575
|
+
}), Pe(s), et(t), tt(a), ot(o), nt(n), rt(l);
|
|
576
|
+
const i = ve();
|
|
577
|
+
te(() => {
|
|
578
|
+
i.global.name.value = s.value ? "dark" : "light";
|
|
579
|
+
});
|
|
580
|
+
const v = () => {
|
|
581
|
+
var L;
|
|
582
|
+
if (!pt(l)) {
|
|
583
|
+
De(l, "waitDlg") || dt(l);
|
|
586
584
|
return;
|
|
587
585
|
}
|
|
588
|
-
const
|
|
589
|
-
if (!
|
|
586
|
+
const f = G(c.path);
|
|
587
|
+
if (!f) {
|
|
590
588
|
console.assert(!1);
|
|
591
589
|
return;
|
|
592
590
|
}
|
|
593
|
-
|
|
591
|
+
f.level === 0 ? (L = navigator == null ? void 0 : navigator.Backbutton) == null || L.goHome(
|
|
594
592
|
() => {
|
|
595
593
|
},
|
|
596
594
|
() => {
|
|
597
595
|
}
|
|
598
596
|
) : r.back();
|
|
599
|
-
},
|
|
600
|
-
if (
|
|
601
|
-
|
|
597
|
+
}, k = (f) => {
|
|
598
|
+
if (f.key === "Escape") {
|
|
599
|
+
v();
|
|
602
600
|
return;
|
|
603
601
|
}
|
|
604
|
-
},
|
|
605
|
-
|
|
602
|
+
}, m = () => {
|
|
603
|
+
v();
|
|
606
604
|
};
|
|
607
|
-
|
|
608
|
-
window.addEventListener("keydown",
|
|
605
|
+
E(() => {
|
|
606
|
+
window.addEventListener("keydown", k), p.on("backbutton", m);
|
|
609
607
|
}), $(() => {
|
|
610
|
-
window.removeEventListener("keydown",
|
|
608
|
+
window.removeEventListener("keydown", k), p.off("backbutton", m);
|
|
611
609
|
});
|
|
612
|
-
const
|
|
613
|
-
e.value =
|
|
614
|
-
},
|
|
615
|
-
t.value =
|
|
616
|
-
},
|
|
617
|
-
const
|
|
618
|
-
a.value =
|
|
619
|
-
},
|
|
620
|
-
n.value =
|
|
610
|
+
const _ = (f) => {
|
|
611
|
+
e.value = f;
|
|
612
|
+
}, M = (f) => {
|
|
613
|
+
t.value = f;
|
|
614
|
+
}, h = (f) => {
|
|
615
|
+
const L = f;
|
|
616
|
+
a.value = L[0], o.value = L[1];
|
|
617
|
+
}, D = (f) => {
|
|
618
|
+
n.value = f;
|
|
621
619
|
};
|
|
622
|
-
|
|
623
|
-
p.on("updateDark",
|
|
620
|
+
qe(() => {
|
|
621
|
+
p.on("updateDark", _), p.on("updateLocale", M), p.on("updatePermission", h), p.on("updateLastAppPath", D), p.emit("syncGlobalState");
|
|
624
622
|
}), $(() => {
|
|
625
|
-
p.off("updateDark",
|
|
623
|
+
p.off("updateDark", _), p.off("updateLocale", M), p.off("updatePermission", h), p.off("updateLastAppPath", D);
|
|
626
624
|
});
|
|
627
625
|
}
|
|
628
|
-
function
|
|
629
|
-
const e =
|
|
626
|
+
function va() {
|
|
627
|
+
const e = at();
|
|
630
628
|
function t(a, o) {
|
|
631
|
-
return
|
|
629
|
+
return Ye(
|
|
632
630
|
e.value,
|
|
633
631
|
a,
|
|
634
632
|
o ?? ""
|
|
@@ -636,82 +634,82 @@ function ga() {
|
|
|
636
634
|
}
|
|
637
635
|
return { verifyPermission: t };
|
|
638
636
|
}
|
|
639
|
-
function
|
|
640
|
-
const e = x(() => !!window.cordova), t =
|
|
637
|
+
function ma() {
|
|
638
|
+
const e = x(() => !!window.cordova), t = Ee(), a = x(() => t.width.value <= 1280 ? t.width.value + "px" : t.width.value <= 1920 ? 1920 / 2.5 + "px" : 2560 / 2.5 + "px");
|
|
641
639
|
return { sysBarAvail: e, compactWidth: a };
|
|
642
640
|
}
|
|
643
|
-
function
|
|
644
|
-
const a =
|
|
641
|
+
function ue(e, t) {
|
|
642
|
+
const a = lt(), o = x({
|
|
645
643
|
get() {
|
|
646
|
-
return
|
|
644
|
+
return De(a, e);
|
|
647
645
|
},
|
|
648
646
|
set(l) {
|
|
649
|
-
l ?
|
|
647
|
+
l ? _t(a, e) : it(a, e);
|
|
650
648
|
}
|
|
651
649
|
}), n = (l) => {
|
|
652
650
|
t == null || t(l), o.value = !0;
|
|
653
651
|
};
|
|
654
|
-
return
|
|
652
|
+
return E(() => {
|
|
655
653
|
p.on(e, n);
|
|
656
654
|
}), $(() => {
|
|
657
655
|
p.off(e, n);
|
|
658
656
|
}), { open: o };
|
|
659
657
|
}
|
|
660
|
-
const Mt = /* @__PURE__ */
|
|
658
|
+
const Mt = /* @__PURE__ */ U({
|
|
661
659
|
__name: "index",
|
|
662
660
|
setup(e) {
|
|
663
|
-
const { t } =
|
|
661
|
+
const { t } = le(), a = g(""), o = g(""), n = g(""), l = g(""), c = g(""), r = g("");
|
|
664
662
|
let u = 0, s = !1;
|
|
665
663
|
const i = (m) => {
|
|
666
|
-
var M, h,
|
|
664
|
+
var M, h, D, f;
|
|
667
665
|
const _ = m;
|
|
668
|
-
a.value = _.title, o.value = _.text, n.value = ((M = _.cancel) == null ? void 0 : M.color) ?? "primary", l.value = ((h = _.cancel) == null ? void 0 : h.text) ?? t("dlg.common.cancel"), c.value = ((
|
|
669
|
-
}, { open: v } =
|
|
666
|
+
a.value = _.title, o.value = _.text, n.value = ((M = _.cancel) == null ? void 0 : M.color) ?? "primary", l.value = ((h = _.cancel) == null ? void 0 : h.text) ?? t("dlg.common.cancel"), c.value = ((D = _.confirm) == null ? void 0 : D.color) ?? "primary", r.value = ((f = _.confirm) == null ? void 0 : f.text) ?? t("dlg.common.confirm"), u = _.seq, s = !1, v.value = !0;
|
|
667
|
+
}, { open: v } = ue("confirmDlg", i), k = () => {
|
|
670
668
|
v.value = !1, s || (p.emit("confirmDlgResult" + u, !0), s = !0);
|
|
671
669
|
};
|
|
672
|
-
return
|
|
670
|
+
return Q(v, (m) => {
|
|
673
671
|
!m && !s && (p.emit("confirmDlgResult" + u, !1), s = !0);
|
|
674
672
|
}), (m, _) => {
|
|
675
|
-
const M = b("v-card-text"), h = b("v-btn"),
|
|
676
|
-
return
|
|
673
|
+
const M = b("v-card-text"), h = b("v-btn"), D = b("v-card-actions"), f = b("v-card"), L = b("v-dialog");
|
|
674
|
+
return S(), R(L, {
|
|
677
675
|
modelValue: z(v),
|
|
678
|
-
"onUpdate:modelValue": _[1] || (_[1] = (
|
|
676
|
+
"onUpdate:modelValue": _[1] || (_[1] = (d) => J(v) ? v.value = d : null),
|
|
679
677
|
transition: "dialog-top-transition",
|
|
680
678
|
"max-width": "600px",
|
|
681
679
|
attach: "",
|
|
682
680
|
onKeydown: [
|
|
683
|
-
_[2] || (_[2] =
|
|
684
|
-
|
|
681
|
+
_[2] || (_[2] = ae(H((d) => v.value = !1, ["stop", "prevent"]), ["esc"])),
|
|
682
|
+
ae(H(k, ["stop", "prevent"]), ["enter"])
|
|
685
683
|
]
|
|
686
684
|
}, {
|
|
687
685
|
default: w(() => [
|
|
688
|
-
|
|
686
|
+
C(f, { title: a.value }, {
|
|
689
687
|
default: w(() => [
|
|
690
|
-
|
|
688
|
+
C(M, null, {
|
|
691
689
|
default: w(() => [
|
|
692
|
-
|
|
690
|
+
I(V(o.value), 1)
|
|
693
691
|
]),
|
|
694
692
|
_: 1
|
|
695
693
|
}),
|
|
696
|
-
|
|
694
|
+
C(D, { class: "d-flex justify-end" }, {
|
|
697
695
|
default: w(() => [
|
|
698
|
-
|
|
696
|
+
C(h, {
|
|
699
697
|
color: n.value,
|
|
700
698
|
variant: "text",
|
|
701
|
-
onClick: _[0] || (_[0] = (
|
|
699
|
+
onClick: _[0] || (_[0] = (d) => v.value = !1)
|
|
702
700
|
}, {
|
|
703
701
|
default: w(() => [
|
|
704
|
-
|
|
702
|
+
I(V(l.value), 1)
|
|
705
703
|
]),
|
|
706
704
|
_: 1
|
|
707
705
|
}, 8, ["color"]),
|
|
708
|
-
|
|
706
|
+
C(h, {
|
|
709
707
|
color: c.value,
|
|
710
708
|
variant: "text",
|
|
711
709
|
onClick: k
|
|
712
710
|
}, {
|
|
713
711
|
default: w(() => [
|
|
714
|
-
|
|
712
|
+
I(V(r.value), 1)
|
|
715
713
|
]),
|
|
716
714
|
_: 1
|
|
717
715
|
}, 8, ["color"])
|
|
@@ -726,24 +724,24 @@ const Mt = /* @__PURE__ */ E({
|
|
|
726
724
|
}, 8, ["modelValue", "onKeydown"]);
|
|
727
725
|
};
|
|
728
726
|
}
|
|
729
|
-
}),
|
|
727
|
+
}), jt = /* @__PURE__ */ U({
|
|
730
728
|
__name: "index",
|
|
731
729
|
props: {
|
|
732
730
|
open: { type: Boolean, default: !0 },
|
|
733
731
|
zIndex: { default: 1 }
|
|
734
732
|
},
|
|
735
733
|
setup(e) {
|
|
736
|
-
const { backgroundColor2: t } =
|
|
734
|
+
const { backgroundColor2: t } = $e(), a = x(() => ({
|
|
737
735
|
background: t.value,
|
|
738
736
|
zIndex: e.zIndex
|
|
739
737
|
}));
|
|
740
738
|
let o = 0;
|
|
741
|
-
return (n, l) => (
|
|
739
|
+
return (n, l) => (S(), R(Oe, { name: "fade" }, {
|
|
742
740
|
default: w(() => [
|
|
743
|
-
n.open ? (
|
|
741
|
+
n.open ? (S(), oe("div", {
|
|
744
742
|
key: J(o) ? ++o.value : ++o,
|
|
745
743
|
class: "x-cont",
|
|
746
|
-
style:
|
|
744
|
+
style: ge(a.value)
|
|
747
745
|
}, l[0] || (l[0] = [
|
|
748
746
|
y("div", { class: "lds-spinner" }, [
|
|
749
747
|
y("div"),
|
|
@@ -759,19 +757,19 @@ const Mt = /* @__PURE__ */ E({
|
|
|
759
757
|
y("div"),
|
|
760
758
|
y("div")
|
|
761
759
|
], -1)
|
|
762
|
-
]), 4)) :
|
|
760
|
+
]), 4)) : re("", !0)
|
|
763
761
|
]),
|
|
764
762
|
_: 1
|
|
765
763
|
}));
|
|
766
764
|
}
|
|
767
|
-
}),
|
|
765
|
+
}), se = (e, t) => {
|
|
768
766
|
const a = e.__vccOpts || e;
|
|
769
767
|
for (const [o, n] of t)
|
|
770
768
|
a[o] = n;
|
|
771
769
|
return a;
|
|
772
|
-
},
|
|
773
|
-
var Rt = "M13,13H11V7H13M13,17H11V15H13M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2Z",
|
|
774
|
-
const
|
|
770
|
+
}, Vt = /* @__PURE__ */ se(jt, [["__scopeId", "data-v-0c686889"]]);
|
|
771
|
+
var Rt = "M13,13H11V7H13M13,17H11V15H13M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2Z", At = "M12 2C6.5 2 2 6.5 2 12S6.5 22 12 22 22 17.5 22 12 17.5 2 12 2M10 17L5 12L6.41 10.59L10 14.17L17.59 6.58L19 8L10 17Z", qt = "M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z", Ot = "M12,2C17.53,2 22,6.47 22,12C22,17.53 17.53,22 12,22C6.47,22 2,17.53 2,12C2,6.47 6.47,2 12,2M15.59,7L12,10.59L8.41,7L7,8.41L10.59,12L7,15.59L8.41,17L12,13.41L15.59,17L17,15.59L13.41,12L17,8.41L15.59,7Z", It = "M13,9H11V7H13M13,17H11V11H13M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2Z";
|
|
772
|
+
const Tt = /* @__PURE__ */ U({
|
|
775
773
|
__name: "item",
|
|
776
774
|
props: {
|
|
777
775
|
id: {},
|
|
@@ -787,42 +785,42 @@ const It = /* @__PURE__ */ E({
|
|
|
787
785
|
})), o = x(() => {
|
|
788
786
|
switch (e.type) {
|
|
789
787
|
case "success":
|
|
790
|
-
return
|
|
788
|
+
return At;
|
|
791
789
|
case "info":
|
|
792
|
-
return
|
|
790
|
+
return It;
|
|
793
791
|
case "error":
|
|
794
|
-
return
|
|
792
|
+
return Ot;
|
|
795
793
|
case "warning":
|
|
796
794
|
return Rt;
|
|
797
795
|
default:
|
|
798
796
|
return "";
|
|
799
797
|
}
|
|
800
798
|
}), n = g(!0), l = t;
|
|
801
|
-
return
|
|
799
|
+
return E(() => {
|
|
802
800
|
setTimeout(() => {
|
|
803
801
|
l("timeout", e.id);
|
|
804
802
|
}, e.timeout);
|
|
805
|
-
}),
|
|
803
|
+
}), Q(n, (c) => {
|
|
806
804
|
c || l("timeout", e.id);
|
|
807
805
|
}), (c, r) => {
|
|
808
806
|
const u = b("v-icon"), s = b("v-sheet");
|
|
809
|
-
return
|
|
807
|
+
return S(), R(s, {
|
|
810
808
|
class: "x-item d-flex align-center py-2 mb-2",
|
|
811
809
|
color: c.type,
|
|
812
810
|
elevation: 1
|
|
813
811
|
}, {
|
|
814
812
|
default: w(() => [
|
|
815
|
-
o.value ? (
|
|
813
|
+
o.value ? (S(), R(u, {
|
|
816
814
|
key: 0,
|
|
817
815
|
class: "mx-1",
|
|
818
816
|
icon: o.value
|
|
819
|
-
}, null, 8, ["icon"])) :
|
|
817
|
+
}, null, 8, ["icon"])) : re("", !0),
|
|
820
818
|
y("div", {
|
|
821
|
-
style:
|
|
822
|
-
},
|
|
823
|
-
|
|
819
|
+
style: ge(a.value)
|
|
820
|
+
}, V(c.text), 5),
|
|
821
|
+
C(u, {
|
|
824
822
|
class: "mx-1",
|
|
825
|
-
icon: z(
|
|
823
|
+
icon: z(qt),
|
|
826
824
|
onClick: r[0] || (r[0] = (i) => l("timeout", c.id))
|
|
827
825
|
}, null, 8, ["icon"])
|
|
828
826
|
]),
|
|
@@ -830,11 +828,11 @@ const It = /* @__PURE__ */ E({
|
|
|
830
828
|
}, 8, ["color"]);
|
|
831
829
|
};
|
|
832
830
|
}
|
|
833
|
-
}),
|
|
831
|
+
}), Bt = /* @__PURE__ */ se(Tt, [["__scopeId", "data-v-74835a85"]]), Et = /* @__PURE__ */ U({
|
|
834
832
|
__name: "index",
|
|
835
833
|
setup(e) {
|
|
836
834
|
const t = g([]);
|
|
837
|
-
|
|
835
|
+
E(() => {
|
|
838
836
|
p.on("message", a);
|
|
839
837
|
}), $(() => {
|
|
840
838
|
p.off("message", a);
|
|
@@ -853,12 +851,12 @@ const It = /* @__PURE__ */ E({
|
|
|
853
851
|
const u = t.value.findIndex((s) => s.id === r);
|
|
854
852
|
u >= 0 && t.value.splice(u, 1);
|
|
855
853
|
};
|
|
856
|
-
return (r, u) => (
|
|
854
|
+
return (r, u) => (S(), oe("div", {
|
|
857
855
|
class: "x-cont d-flex flex-column-reverse align-center",
|
|
858
856
|
onClick: u[0] || (u[0] = H(() => {
|
|
859
857
|
}, ["stop"]))
|
|
860
858
|
}, [
|
|
861
|
-
(
|
|
859
|
+
(S(!0), oe(Ie, null, Te(t.value, (s) => (S(), R(Bt, {
|
|
862
860
|
id: s.id,
|
|
863
861
|
key: s.id,
|
|
864
862
|
type: s.type,
|
|
@@ -868,105 +866,108 @@ const It = /* @__PURE__ */ E({
|
|
|
868
866
|
}, null, 8, ["id", "type", "text", "timeout"]))), 128))
|
|
869
867
|
]));
|
|
870
868
|
}
|
|
871
|
-
}),
|
|
869
|
+
}), Ut = /* @__PURE__ */ se(Et, [["__scopeId", "data-v-c6a59757"]]), Wt = /* @__PURE__ */ U({
|
|
872
870
|
__name: "index",
|
|
873
871
|
setup(e) {
|
|
874
|
-
const { t } =
|
|
872
|
+
const { t } = le(), a = g(""), o = g(""), n = g(""), l = g(""), c = g(), r = g(""), u = g(""), s = g(""), i = g(""), v = g(""), k = Be("target");
|
|
875
873
|
let m = 0, _ = !1;
|
|
876
|
-
const M = async (
|
|
877
|
-
var
|
|
878
|
-
const
|
|
879
|
-
a.value =
|
|
880
|
-
}, { open: h } =
|
|
874
|
+
const M = async (L) => {
|
|
875
|
+
var K, F, W, X;
|
|
876
|
+
const d = L;
|
|
877
|
+
a.value = d.title, o.value = d.text, n.value = d.label, l.value = d.placeholder, c.value = d.rules, r.value = d.value, u.value = ((K = d.cancel) == null ? void 0 : K.color) ?? "primary", s.value = ((F = d.cancel) == null ? void 0 : F.text) ?? t("dlg.common.cancel"), i.value = ((W = d.confirm) == null ? void 0 : W.color) ?? "primary", v.value = ((X = d.confirm) == null ? void 0 : X.text) ?? t("dlg.common.confirm"), m = d.seq, _ = !1, h.value = !0, await ce(() => !!k.value), k.value.focus();
|
|
878
|
+
}, { open: h } = ue("promptDlg", M), D = g(!1), f = () => {
|
|
881
879
|
h.value = !1, _ || (p.emit("promptDlgResult" + m, r.value ?? ""), _ = !0);
|
|
882
880
|
};
|
|
883
|
-
return
|
|
884
|
-
!
|
|
885
|
-
}), (
|
|
886
|
-
const
|
|
887
|
-
return
|
|
881
|
+
return Q(h, (L) => {
|
|
882
|
+
!L && !_ && (p.emit("promptDlgResult" + m, void 0), _ = !0);
|
|
883
|
+
}), (L, d) => {
|
|
884
|
+
const K = b("v-card-text"), F = b("v-text-field"), W = b("v-btn"), X = b("v-card-actions"), Me = b("v-form"), je = b("v-card"), Ve = b("v-dialog");
|
|
885
|
+
return S(), R(Ve, {
|
|
888
886
|
modelValue: z(h),
|
|
889
|
-
"onUpdate:modelValue":
|
|
887
|
+
"onUpdate:modelValue": d[3] || (d[3] = (A) => J(h) ? h.value = A : null),
|
|
890
888
|
transition: "dialog-top-transition",
|
|
891
889
|
"max-width": "600px",
|
|
892
890
|
attach: "",
|
|
893
|
-
onKeydown: [
|
|
894
|
-
f[3] || (f[3] = G(H((U) => h.value = !1, ["stop", "prevent"]), ["esc"])),
|
|
895
|
-
G(H(d, ["stop", "prevent"]), ["enter"])
|
|
896
|
-
]
|
|
891
|
+
onKeydown: d[4] || (d[4] = ae(H((A) => h.value = !1, ["stop", "prevent"]), ["esc"]))
|
|
897
892
|
}, {
|
|
898
893
|
default: w(() => [
|
|
899
|
-
|
|
894
|
+
C(je, { title: a.value }, {
|
|
900
895
|
default: w(() => [
|
|
901
|
-
o.value ? (
|
|
896
|
+
o.value ? (S(), R(K, { key: 0 }, {
|
|
902
897
|
default: w(() => [
|
|
903
|
-
|
|
898
|
+
I(V(o.value), 1)
|
|
904
899
|
]),
|
|
905
900
|
_: 1
|
|
906
|
-
})) :
|
|
907
|
-
|
|
901
|
+
})) : re("", !0),
|
|
902
|
+
C(Me, {
|
|
903
|
+
modelValue: D.value,
|
|
904
|
+
"onUpdate:modelValue": d[2] || (d[2] = (A) => D.value = A),
|
|
905
|
+
class: "mx-3",
|
|
906
|
+
onSubmit: H(f, ["prevent"])
|
|
907
|
+
}, {
|
|
908
908
|
default: w(() => [
|
|
909
|
-
|
|
909
|
+
C(F, {
|
|
910
910
|
ref_key: "target",
|
|
911
911
|
ref: k,
|
|
912
912
|
modelValue: r.value,
|
|
913
|
-
"onUpdate:modelValue":
|
|
913
|
+
"onUpdate:modelValue": d[0] || (d[0] = (A) => r.value = A),
|
|
914
914
|
label: n.value,
|
|
915
915
|
placeholder: l.value,
|
|
916
916
|
rules: c.value
|
|
917
|
-
}, null, 8, ["modelValue", "label", "placeholder", "rules"])
|
|
918
|
-
|
|
919
|
-
_: 1
|
|
920
|
-
}),
|
|
921
|
-
L(De, { class: "d-flex justify-end" }, {
|
|
922
|
-
default: w(() => [
|
|
923
|
-
L(W, {
|
|
924
|
-
color: u.value,
|
|
925
|
-
variant: "text",
|
|
926
|
-
onClick: f[1] || (f[1] = (U) => h.value = !1)
|
|
927
|
-
}, {
|
|
928
|
-
default: w(() => [
|
|
929
|
-
O(R(s.value), 1)
|
|
930
|
-
]),
|
|
931
|
-
_: 1
|
|
932
|
-
}, 8, ["color"]),
|
|
933
|
-
L(W, {
|
|
934
|
-
color: i.value,
|
|
935
|
-
variant: "text",
|
|
936
|
-
onClick: d
|
|
937
|
-
}, {
|
|
917
|
+
}, null, 8, ["modelValue", "label", "placeholder", "rules"]),
|
|
918
|
+
C(X, { class: "d-flex justify-end" }, {
|
|
938
919
|
default: w(() => [
|
|
939
|
-
|
|
920
|
+
C(W, {
|
|
921
|
+
variant: "text",
|
|
922
|
+
color: u.value,
|
|
923
|
+
onClick: d[1] || (d[1] = (A) => h.value = !1)
|
|
924
|
+
}, {
|
|
925
|
+
default: w(() => [
|
|
926
|
+
I(V(s.value), 1)
|
|
927
|
+
]),
|
|
928
|
+
_: 1
|
|
929
|
+
}, 8, ["color"]),
|
|
930
|
+
C(W, {
|
|
931
|
+
disabled: !D.value,
|
|
932
|
+
variant: "text",
|
|
933
|
+
color: i.value,
|
|
934
|
+
type: "submit"
|
|
935
|
+
}, {
|
|
936
|
+
default: w(() => [
|
|
937
|
+
I(V(v.value), 1)
|
|
938
|
+
]),
|
|
939
|
+
_: 1
|
|
940
|
+
}, 8, ["disabled", "color"])
|
|
940
941
|
]),
|
|
941
942
|
_: 1
|
|
942
|
-
}
|
|
943
|
+
})
|
|
943
944
|
]),
|
|
944
945
|
_: 1
|
|
945
|
-
})
|
|
946
|
+
}, 8, ["modelValue"])
|
|
946
947
|
]),
|
|
947
948
|
_: 1
|
|
948
949
|
}, 8, ["title"])
|
|
949
950
|
]),
|
|
950
951
|
_: 1
|
|
951
|
-
}, 8, ["modelValue"
|
|
952
|
+
}, 8, ["modelValue"]);
|
|
952
953
|
};
|
|
953
954
|
}
|
|
954
|
-
}),
|
|
955
|
+
}), $t = { class: "mx-auto my-auto" }, Ht = { class: "w-100 h-100 d-flex align-center justify-center" }, zt = { class: "text-body-1" }, Kt = /* @__PURE__ */ U({
|
|
955
956
|
__name: "index",
|
|
956
957
|
setup(e) {
|
|
957
|
-
const { t } =
|
|
958
|
+
const { t } = le(), a = g(""), o = (c) => {
|
|
958
959
|
const r = c;
|
|
959
960
|
a.value = r.text ?? t("dlg.common.waiting"), l.value = !0;
|
|
960
961
|
}, n = () => {
|
|
961
962
|
l.value = !1;
|
|
962
|
-
}, { open: l } =
|
|
963
|
-
return
|
|
963
|
+
}, { open: l } = ue("waitDlg", o);
|
|
964
|
+
return E(() => {
|
|
964
965
|
p.on("closeWaitDlg", n);
|
|
965
966
|
}), $(() => {
|
|
966
967
|
p.off("closeWaitDlg", n);
|
|
967
968
|
}), (c, r) => {
|
|
968
969
|
const u = b("v-card"), s = b("v-dialog");
|
|
969
|
-
return
|
|
970
|
+
return S(), R(s, {
|
|
970
971
|
modelValue: z(l),
|
|
971
972
|
"onUpdate:modelValue": r[0] || (r[0] = (i) => J(l) ? l.value = i : null),
|
|
972
973
|
persistent: "",
|
|
@@ -975,15 +976,15 @@ const It = /* @__PURE__ */ E({
|
|
|
975
976
|
attach: ""
|
|
976
977
|
}, {
|
|
977
978
|
default: w(() => [
|
|
978
|
-
y("div",
|
|
979
|
-
|
|
979
|
+
y("div", $t, [
|
|
980
|
+
C(u, {
|
|
980
981
|
width: "300px",
|
|
981
982
|
height: "80px",
|
|
982
983
|
loading: ""
|
|
983
984
|
}, {
|
|
984
985
|
default: w(() => [
|
|
985
|
-
y("div",
|
|
986
|
-
y("span",
|
|
986
|
+
y("div", Ht, [
|
|
987
|
+
y("span", zt, V(a.value), 1)
|
|
987
988
|
])
|
|
988
989
|
]),
|
|
989
990
|
_: 1
|
|
@@ -994,9 +995,9 @@ const It = /* @__PURE__ */ E({
|
|
|
994
995
|
}, 8, ["modelValue"]);
|
|
995
996
|
};
|
|
996
997
|
}
|
|
997
|
-
}),
|
|
998
|
-
e.component("XConfirmDlg", Mt), e.component("XLoading",
|
|
999
|
-
},
|
|
998
|
+
}), Ft = (e) => {
|
|
999
|
+
e.component("XConfirmDlg", Mt), e.component("XLoading", Vt), e.component("XMessage", Ut), e.component("XPromptDlg", Wt), e.component("XWaitDlg", Kt);
|
|
1000
|
+
}, Xt = (e, t, a) => {
|
|
1000
1001
|
const o = e[t];
|
|
1001
1002
|
return o ? typeof o == "function" ? o() : Promise.resolve(o) : new Promise((n, l) => {
|
|
1002
1003
|
(typeof queueMicrotask == "function" ? queueMicrotask : setTimeout)(
|
|
@@ -1009,54 +1010,54 @@ const It = /* @__PURE__ */ E({
|
|
|
1009
1010
|
);
|
|
1010
1011
|
});
|
|
1011
1012
|
};
|
|
1012
|
-
async function
|
|
1013
|
-
return (await
|
|
1013
|
+
async function ha(e) {
|
|
1014
|
+
return (await Xt(/* @__PURE__ */ Object.assign({ "./locales/en/index.ts": () => import("./i18n-en-iuzmkt0n.js"), "./locales/zhHans/index.ts": () => import("./i18n-zhHans-m6y1by9n.js") }), `./locales/${e}/index.ts`, 4)).default;
|
|
1014
1015
|
}
|
|
1015
|
-
const
|
|
1016
|
+
const ya = { install: Ft };
|
|
1016
1017
|
export {
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1018
|
+
Je as Permission,
|
|
1019
|
+
_t as addView,
|
|
1020
|
+
Ge as appAppear,
|
|
1021
|
+
fa as clearViews,
|
|
1022
|
+
oa as closeWaitDlg,
|
|
1023
|
+
Yt as createAxios,
|
|
1024
|
+
ya as default,
|
|
1025
|
+
it as delView,
|
|
1025
1026
|
p as eventBus,
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1027
|
+
De as hasView,
|
|
1028
|
+
ua as injectDark,
|
|
1029
|
+
_a as injectLastAppPath,
|
|
1030
|
+
sa as injectLocale,
|
|
1031
|
+
pa as injectPermissionChecksum,
|
|
1032
|
+
at as injectPermissionObjects,
|
|
1033
|
+
lt as injectViews,
|
|
1034
|
+
pt as isEmpty,
|
|
1035
|
+
_e as isExist,
|
|
1036
|
+
da as lastView,
|
|
1037
|
+
ha as loadLocaleMessageEssential,
|
|
1038
|
+
G as matchRouteMeta,
|
|
1039
|
+
na as messageError,
|
|
1040
|
+
ra as messageInfo,
|
|
1041
|
+
la as messageSuccess,
|
|
1042
|
+
ca as messageWarning,
|
|
1043
|
+
ia as onBeforeEach,
|
|
1044
|
+
ea as openConfirmDlg,
|
|
1045
|
+
ta as openPromptDlg,
|
|
1046
|
+
aa as openWaitDlg,
|
|
1047
|
+
dt as popView,
|
|
1048
|
+
Pe as provideDark,
|
|
1049
|
+
nt as provideLastAppPath,
|
|
1050
|
+
et as provideLocale,
|
|
1051
|
+
ot as providePermissionChecksum,
|
|
1052
|
+
tt as providePermissionObjects,
|
|
1053
|
+
rt as provideViews,
|
|
1053
1054
|
Y as routeTransName,
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1055
|
+
$e as useColor,
|
|
1056
|
+
ga as useMicroApp,
|
|
1057
|
+
va as usePermission,
|
|
1058
|
+
ma as useSystem,
|
|
1059
|
+
ue as useViewStack,
|
|
1060
|
+
Ye as verifyPermission,
|
|
1061
|
+
Pt as waitMs,
|
|
1062
|
+
ce as waitUtil
|
|
1062
1063
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Ref } from 'vue';
|
|
2
2
|
import { PermissionObjects } from './permission';
|
|
3
|
-
export declare function provideDark(dark: Ref<boolean
|
|
4
|
-
export declare function injectDark(): Ref<boolean
|
|
3
|
+
export declare function provideDark(dark: Ref<boolean>): void;
|
|
4
|
+
export declare function injectDark(): Ref<boolean>;
|
|
5
5
|
export declare function provideLocale(locale: Ref<string>): void;
|
|
6
6
|
export declare function injectLocale(): Ref<string>;
|
|
7
7
|
export declare function providePermissionObjects(permissionObjects: Ref<PermissionObjects>): void;
|