x-essential-lib 0.6.2 → 0.6.4

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.
@@ -1,14 +1,28 @@
1
- declare const _default: import("vue").DefineComponent<{
2
- zIndex: {
3
- type: NumberConstructor;
4
- default: number;
5
- };
6
- }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
7
- zIndex: {
8
- type: NumberConstructor;
9
- default: number;
10
- };
11
- }>>, {
1
+ interface Props {
2
+ zIndex?: number;
3
+ }
4
+ declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToOption<Props>, {
5
+ zIndex: number;
6
+ }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToOption<Props>, {
7
+ zIndex: number;
8
+ }>>>, {
12
9
  zIndex: number;
13
10
  }, {}>;
14
11
  export default _default;
12
+ type __VLS_WithDefaults<P, D> = {
13
+ [K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
14
+ default: D[K];
15
+ }> : P[K];
16
+ };
17
+ type __VLS_Prettify<T> = {
18
+ [K in keyof T]: T[K];
19
+ } & {};
20
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
21
+ type __VLS_TypePropsToOption<T> = {
22
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
23
+ type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
24
+ } : {
25
+ type: import('vue').PropType<T[K]>;
26
+ required: true;
27
+ };
28
+ };
package/dist/index.js CHANGED
@@ -1,25 +1,25 @@
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-ea85eb65]{position:absolute;top:0;left:0;bottom:0;right:0;display:flex;align-items:center;justify-content:center}.lds-spinner[data-v-ea85eb65]{color:official;display:inline-block;position:relative;width:40px;height:40px}.lds-spinner div[data-v-ea85eb65]{transform-origin:20px 20px;animation:lds-spinner-ea85eb65 1.2s linear infinite}.lds-spinner div[data-v-ea85eb65]:after{content:" ";display:block;position:absolute;top:3px;left:18px;width:2px;height:6px;border-radius:5%;background:#9e9e9e}.lds-spinner div[data-v-ea85eb65]:nth-child(1){transform:rotate(0);animation-delay:-1.1s}.lds-spinner div[data-v-ea85eb65]:nth-child(2){transform:rotate(30deg);animation-delay:-1s}.lds-spinner div[data-v-ea85eb65]:nth-child(3){transform:rotate(60deg);animation-delay:-.9s}.lds-spinner div[data-v-ea85eb65]:nth-child(4){transform:rotate(90deg);animation-delay:-.8s}.lds-spinner div[data-v-ea85eb65]:nth-child(5){transform:rotate(120deg);animation-delay:-.7s}.lds-spinner div[data-v-ea85eb65]:nth-child(6){transform:rotate(150deg);animation-delay:-.6s}.lds-spinner div[data-v-ea85eb65]:nth-child(7){transform:rotate(180deg);animation-delay:-.5s}.lds-spinner div[data-v-ea85eb65]:nth-child(8){transform:rotate(210deg);animation-delay:-.4s}.lds-spinner div[data-v-ea85eb65]:nth-child(9){transform:rotate(240deg);animation-delay:-.3s}.lds-spinner div[data-v-ea85eb65]:nth-child(10){transform:rotate(270deg);animation-delay:-.2s}.lds-spinner div[data-v-ea85eb65]:nth-child(11){transform:rotate(300deg);animation-delay:-.1s}.lds-spinner div[data-v-ea85eb65]:nth-child(12){transform:rotate(330deg);animation-delay:0s}@keyframes lds-spinner-ea85eb65{0%{opacity:1}to{opacity:0}}.x-item[data-v-448d0248]{width:600px}@media (max-width: 600px){.x-item[data-v-448d0248]{width:calc(100vw - 16px)}}.x-cont[data-v-fc1bc7ac]{position:absolute;left:50%;bottom:20px;transform:translate(-50%);z-index:9999}')),document.head.appendChild(a)}}catch(e){console.error("vite-plugin-css-injected-by-js",e)}})();
2
- import { ref as d, defineComponent as T, computed as g, onMounted as V, onBeforeUnmount as I, watch as Z, resolveComponent as h, openBlock as D, createBlock as O, withKeys as K, withModifiers as W, withCtx as w, createVNode as b, createTextVNode as j, toDisplayString as q, createElementBlock as Q, normalizeStyle as ne, pushScopeId as fe, popScopeId as ge, createElementVNode as v, createCommentVNode as le, unref as re, Fragment as ve, renderList as me, getCurrentScope as he, onScopeDispose as we, watchEffect as xe, getCurrentInstance as ye } from "vue";
3
- import { useI18n as Y } from "vue-i18n";
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-7ab74c70]{position:absolute;top:0;left:0;bottom:0;right:0;display:flex;align-items:center;justify-content:center}.lds-spinner[data-v-7ab74c70]{color:official;display:inline-block;position:relative;width:40px;height:40px}.lds-spinner div[data-v-7ab74c70]{transform-origin:20px 20px;animation:lds-spinner-7ab74c70 1.2s linear infinite}.lds-spinner div[data-v-7ab74c70]:after{content:" ";display:block;position:absolute;top:3px;left:18px;width:2px;height:6px;border-radius:5%;background:#9e9e9e}.lds-spinner div[data-v-7ab74c70]:nth-child(1){transform:rotate(0);animation-delay:-1.1s}.lds-spinner div[data-v-7ab74c70]:nth-child(2){transform:rotate(30deg);animation-delay:-1s}.lds-spinner div[data-v-7ab74c70]:nth-child(3){transform:rotate(60deg);animation-delay:-.9s}.lds-spinner div[data-v-7ab74c70]:nth-child(4){transform:rotate(90deg);animation-delay:-.8s}.lds-spinner div[data-v-7ab74c70]:nth-child(5){transform:rotate(120deg);animation-delay:-.7s}.lds-spinner div[data-v-7ab74c70]:nth-child(6){transform:rotate(150deg);animation-delay:-.6s}.lds-spinner div[data-v-7ab74c70]:nth-child(7){transform:rotate(180deg);animation-delay:-.5s}.lds-spinner div[data-v-7ab74c70]:nth-child(8){transform:rotate(210deg);animation-delay:-.4s}.lds-spinner div[data-v-7ab74c70]:nth-child(9){transform:rotate(240deg);animation-delay:-.3s}.lds-spinner div[data-v-7ab74c70]:nth-child(10){transform:rotate(270deg);animation-delay:-.2s}.lds-spinner div[data-v-7ab74c70]:nth-child(11){transform:rotate(300deg);animation-delay:-.1s}.lds-spinner div[data-v-7ab74c70]:nth-child(12){transform:rotate(330deg);animation-delay:0s}@keyframes lds-spinner-7ab74c70{0%{opacity:1}to{opacity:0}}.x-item[data-v-d5cfe252]{width:600px}@media (max-width: 600px){.x-item[data-v-d5cfe252]{width:calc(100vw - 16px)}}.x-cont[data-v-d525e6f5]{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 d, defineComponent as T, computed as g, onMounted as V, onBeforeUnmount as I, watch as N, resolveComponent as h, openBlock as D, createBlock as O, withKeys as F, withModifiers as W, withCtx as w, createVNode as b, createTextVNode as E, toDisplayString as q, createElementBlock as J, normalizeStyle as ne, pushScopeId as fe, popScopeId as ge, createElementVNode as v, createCommentVNode as le, unref as re, Fragment as ve, renderList as me, getCurrentScope as he, onScopeDispose as we, watchEffect as ye, getCurrentInstance as xe } from "vue";
3
+ import { useI18n as P } from "vue-i18n";
4
4
  import { defineStore as ce } from "pinia";
5
5
  import ke from "axios";
6
6
  import { useRouter as ue, useRoute as be } from "vue-router";
7
- import { useTheme as P, useDisplay as Ce } from "vuetify";
8
- const G = ce("global", () => {
9
- const e = d(), t = d("en"), a = d({}), n = d(""), o = d("");
7
+ import { useTheme as ee, useDisplay as Ce } from "vuetify";
8
+ const Z = ce("global", () => {
9
+ const e = d(), a = d("en"), t = d({}), n = d(""), o = d("");
10
10
  return {
11
11
  dark: e,
12
- locale: t,
13
- permissionObjects: a,
12
+ locale: a,
13
+ permissionObjects: t,
14
14
  permissionChecksum: n,
15
15
  lastAppPath: o
16
16
  };
17
17
  }), $ = ce("viewMgr", () => {
18
18
  const e = d([]);
19
- function t() {
19
+ function a() {
20
20
  return e.value.length <= 0;
21
21
  }
22
- function a() {
22
+ function t() {
23
23
  const u = e.value.length;
24
24
  if (u > 0)
25
25
  return e.value[u - 1];
@@ -43,8 +43,8 @@ const G = ce("global", () => {
43
43
  }
44
44
  return {
45
45
  views: e,
46
- isEmpty: t,
47
- lastView: a,
46
+ isEmpty: a,
47
+ lastView: t,
48
48
  hasView: n,
49
49
  addView: o,
50
50
  delView: r,
@@ -53,11 +53,11 @@ const G = ce("global", () => {
53
53
  };
54
54
  });
55
55
  /*! js-cookie v3.0.5 | MIT */
56
- function F(e) {
57
- for (var t = 1; t < arguments.length; t++) {
58
- var a = arguments[t];
59
- for (var n in a)
60
- e[n] = a[n];
56
+ function X(e) {
57
+ for (var a = 1; a < arguments.length; a++) {
58
+ var t = arguments[a];
59
+ for (var n in t)
60
+ e[n] = t[n];
61
61
  }
62
62
  return e;
63
63
  }
@@ -72,10 +72,10 @@ var De = {
72
72
  );
73
73
  }
74
74
  };
75
- function J(e, t) {
76
- function a(o, r, l) {
75
+ function Y(e, a) {
76
+ function t(o, r, l) {
77
77
  if (!(typeof document > "u")) {
78
- l = F({}, t, l), typeof l.expires == "number" && (l.expires = new Date(Date.now() + l.expires * 864e5)), l.expires && (l.expires = l.expires.toUTCString()), o = encodeURIComponent(o).replace(/%(2[346B]|5E|60|7C)/g, decodeURIComponent).replace(/[()]/g, escape);
78
+ l = X({}, a, l), typeof l.expires == "number" && (l.expires = new Date(Date.now() + l.expires * 864e5)), l.expires && (l.expires = l.expires.toUTCString()), o = encodeURIComponent(o).replace(/%(2[346B]|5E|60|7C)/g, decodeURIComponent).replace(/[()]/g, escape);
79
79
  var c = "";
80
80
  for (var u in l)
81
81
  l[u] && (c += "; " + u, l[u] !== !0 && (c += "=" + l[u].split(";")[0]));
@@ -98,83 +98,83 @@ function J(e, t) {
98
98
  }
99
99
  return Object.create(
100
100
  {
101
- set: a,
101
+ set: t,
102
102
  get: n,
103
103
  remove: function(o, r) {
104
- a(
104
+ t(
105
105
  o,
106
106
  "",
107
- F({}, r, {
107
+ X({}, r, {
108
108
  expires: -1
109
109
  })
110
110
  );
111
111
  },
112
112
  withAttributes: function(o) {
113
- return J(this.converter, F({}, this.attributes, o));
113
+ return Y(this.converter, X({}, this.attributes, o));
114
114
  },
115
115
  withConverter: function(o) {
116
- return J(F({}, this.converter, o), this.attributes);
116
+ return Y(X({}, this.converter, o), this.attributes);
117
117
  }
118
118
  },
119
119
  {
120
- attributes: { value: Object.freeze(t) },
120
+ attributes: { value: Object.freeze(a) },
121
121
  converter: { value: Object.freeze(e) }
122
122
  }
123
123
  );
124
124
  }
125
- var E = J(De, { path: "/" });
126
- function yt(e) {
127
- const t = ke.create({
125
+ var j = Y(De, { path: "/" });
126
+ function xt(e) {
127
+ const a = ke.create({
128
128
  timeout: 6e3
129
129
  });
130
- return t.defaults.baseURL = e.baseUrl, t.interceptors.request.use(
131
- (a) => Le(a),
132
- (a) => {
133
- Ve(a, e.onError);
130
+ return a.defaults.baseURL = e.baseUrl, a.interceptors.request.use(
131
+ (t) => Le(t),
132
+ (t) => {
133
+ Ve(t, e.onError);
134
134
  }
135
- ), t.interceptors.response.use(
136
- (a) => Me(a),
137
- (a) => Se(a, e.onError)
138
- ), t;
135
+ ), a.interceptors.response.use(
136
+ (t) => Me(t),
137
+ (t) => Se(t, e.onError)
138
+ ), a;
139
139
  }
140
140
  function Le(e) {
141
- const t = E.get("accessToken") ?? "";
142
- return e.headers.Authorization = "Basic " + t, e.headers["Content-Type"] = "application/json", e.data = JSON.stringify(e.data), e;
141
+ const a = j.get("accessToken") ?? "";
142
+ return e.headers.Authorization = "Basic " + a, e.headers["Content-Type"] = "application/json", e.data = JSON.stringify(e.data), e;
143
143
  }
144
- function Ve(e, t) {
145
- console.error(e), t("request timeout");
144
+ function Ve(e, a) {
145
+ console.error(e), a("request timeout");
146
146
  }
147
147
  function Me(e) {
148
148
  return e.data;
149
149
  }
150
- function Se(e, t) {
150
+ function Se(e, a) {
151
151
  var o;
152
- const a = e.response;
153
- if (!a)
152
+ const t = e.response;
153
+ if (!t)
154
154
  return Promise.reject(e);
155
- a.status === 401 && Ae();
156
- let n = (o = a.data) == null ? void 0 : o.message;
155
+ t.status === 401 && Ae();
156
+ let n = (o = t.data) == null ? void 0 : o.message;
157
157
  return n || (n = {
158
- code: a.status,
159
- message: a.statusText
160
- }), t(n), Promise.reject(e);
158
+ code: t.status,
159
+ message: t.statusText
160
+ }), a(n), Promise.reject(e);
161
161
  }
162
162
  function Ae() {
163
- E.remove("accessToken"), E.remove("refreshToken"), E.remove("activeOrg"), ue().replace({ path: "/passport/login" });
163
+ j.remove("accessToken"), j.remove("refreshToken"), j.remove("activeOrg"), ue().replace({ path: "/passport/login" });
164
164
  }
165
165
  function qe(e) {
166
- return { all: e = e || /* @__PURE__ */ new Map(), on: function(t, a) {
167
- var n = e.get(t);
168
- n ? n.push(a) : e.set(t, [a]);
169
- }, off: function(t, a) {
170
- var n = e.get(t);
171
- n && (a ? n.splice(n.indexOf(a) >>> 0, 1) : e.set(t, []));
172
- }, emit: function(t, a) {
173
- var n = e.get(t);
166
+ return { all: e = e || /* @__PURE__ */ new Map(), on: function(a, t) {
167
+ var n = e.get(a);
168
+ n ? n.push(t) : e.set(a, [t]);
169
+ }, off: function(a, t) {
170
+ var n = e.get(a);
171
+ n && (t ? n.splice(n.indexOf(t) >>> 0, 1) : e.set(a, []));
172
+ }, emit: function(a, t) {
173
+ var n = e.get(a);
174
174
  n && n.slice().map(function(o) {
175
- o(a);
175
+ o(t);
176
176
  }), (n = e.get("*")) && n.slice().map(function(o) {
177
- o(t, a);
177
+ o(a, t);
178
178
  });
179
179
  } };
180
180
  }
@@ -182,25 +182,22 @@ const s = function() {
182
182
  return window.eventBus || (window.eventBus = qe()), window.eventBus;
183
183
  }();
184
184
  async function kt(e) {
185
- return new Promise((t) => {
186
- setTimeout(t, e);
185
+ return new Promise((a) => {
186
+ setTimeout(a, e);
187
187
  });
188
188
  }
189
- async function ee(e, t, a) {
189
+ async function G(e, a, t) {
190
190
  const n = Date.now();
191
191
  return new Promise((o) => {
192
192
  const r = async () => {
193
- e() ? o(!0) : t && Date.now() - n > t ? o(!1) : setTimeout(r, a ?? 30);
193
+ e() ? o(!0) : a && Date.now() - n > a ? o(!1) : setTimeout(r, t ?? 30);
194
194
  };
195
195
  r();
196
196
  });
197
197
  }
198
- function Re(e, t) {
199
- var o;
200
- const a = "single-spa-application:" + e, n = (o = document.getElementById(a)) == null ? void 0 : o.classList;
201
- n && (n.remove("app-left", "app-right", "app-reset"), t ? n.add("app-left") : n.add("app-right"), setTimeout(() => {
202
- n.add("app-reset");
203
- }, 50));
198
+ async function Re(e, a) {
199
+ const t = document.getElementById("single-spa-application:" + e);
200
+ t && (t.classList.remove("app-left", "app-right", "app-reset"), a ? t.classList.add("app-left") : t.classList.add("app-right"), await G(() => t.hasChildNodes(), 5e3), t.classList.add("app-reset"));
204
201
  }
205
202
  let ae = Date.now();
206
203
  function se() {
@@ -214,20 +211,20 @@ function pe() {
214
211
  async function bt(e) {
215
212
  if (!se())
216
213
  return;
217
- let t = !1, a;
214
+ let a = !1, t;
218
215
  const n = (r) => {
219
- a = r, t = !0;
216
+ t = r, a = !0;
220
217
  }, o = pe();
221
- return s.on("confirmDlgResult" + o, n), s.emit("confirmDlg", { ...e, seq: o }), await ee(() => t), s.off("confirmDlgResult" + o, n), a;
218
+ return s.on("confirmDlgResult" + o, n), s.emit("confirmDlg", { ...e, seq: o }), await G(() => a), s.off("confirmDlgResult" + o, n), t;
222
219
  }
223
220
  async function Ct(e) {
224
221
  if (!se())
225
222
  return;
226
- let t = !1, a;
223
+ let a = !1, t;
227
224
  const n = (r) => {
228
- a = r, t = !0;
225
+ t = r, a = !0;
229
226
  }, o = pe();
230
- return s.on("promptDlgResult" + o, n), s.emit("promptDlg", { ...e, seq: o }), await ee(() => t), s.off("promptDlgResult" + o, n), a;
227
+ return s.on("promptDlgResult" + o, n), s.emit("promptDlg", { ...e, seq: o }), await G(() => a), s.off("promptDlgResult" + o, n), t;
231
228
  }
232
229
  function Dt(e) {
233
230
  s.emit("openWaitDlg", { text: e });
@@ -235,33 +232,33 @@ function Dt(e) {
235
232
  function Lt() {
236
233
  s.emit("closeWaitDlg");
237
234
  }
238
- function Vt(e, t) {
239
- s.emit("message", { type: "error", text: e, timeout: t });
235
+ function Vt(e, a) {
236
+ s.emit("message", { type: "error", text: e, timeout: a });
240
237
  }
241
- function Mt(e, t) {
242
- s.emit("message", { type: "info", text: e, timeout: t });
238
+ function Mt(e, a) {
239
+ s.emit("message", { type: "info", text: e, timeout: a });
243
240
  }
244
- function St(e, t) {
245
- s.emit("message", { type: "success", text: e, timeout: t });
241
+ function St(e, a) {
242
+ s.emit("message", { type: "success", text: e, timeout: a });
246
243
  }
247
- function At(e, t) {
248
- s.emit("message", { type: "warning", text: e, timeout: t });
244
+ function At(e, a) {
245
+ s.emit("message", { type: "warning", text: e, timeout: a });
249
246
  }
250
247
  var Oe = /* @__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))(Oe || {});
251
- function oe(e, t) {
248
+ function oe(e, a) {
252
249
  if (!e)
253
250
  return !1;
254
- let a = e;
255
- return Object.keys(a).length <= 0 || (t.split("/").forEach((o) => {
256
- if (Object.keys(a).length <= 0)
251
+ let t = e;
252
+ return Object.keys(t).length <= 0 || (a.split("/").forEach((o) => {
253
+ if (Object.keys(t).length <= 0)
257
254
  return !0;
258
- if (a[o])
259
- a = a[o];
255
+ if (t[o])
256
+ t = t[o];
260
257
  else
261
258
  return !1;
262
- }), Object.keys(a).length <= 0);
259
+ }), Object.keys(t).length <= 0);
263
260
  }
264
- const je = [
261
+ const Ee = [
265
262
  {
266
263
  app: "x-passport-mf",
267
264
  path: "/passport/login",
@@ -369,92 +366,92 @@ const je = [
369
366
  mainActive: 2
370
367
  }
371
368
  ];
372
- function N(e) {
373
- let t, a = 0;
369
+ function K(e) {
370
+ let a, t = 0;
374
371
  const n = e.split("/").filter((o) => o.trim() !== "");
375
- return je.forEach((o) => {
372
+ return Ee.forEach((o) => {
376
373
  const r = o.path.split("/").filter((c) => c.trim() !== "");
377
374
  let l = 0;
378
375
  for (let c = 0; c < n.length && !(c >= r.length || n[c] !== r[c]); c++)
379
376
  l++;
380
- l > 0 && l > a && (t = o, a = l);
381
- }), t;
382
- }
383
- const X = d("");
384
- function L(e, t) {
385
- const a = G();
386
- t === "/" && (t = a.lastAppPath);
387
- const n = N(e), o = N(t);
377
+ l > 0 && l > t && (a = o, t = l);
378
+ }), a;
379
+ }
380
+ const Q = d("");
381
+ function L(e, a) {
382
+ const t = Z();
383
+ a === "/" && (a = t.lastAppPath);
384
+ const n = K(e), o = K(a);
388
385
  if (!n) {
389
386
  console.assert(!1);
390
387
  return;
391
388
  }
392
- if (console.info(`~~~~routeChange~~~~ ${t} -> ${e}`), !o)
389
+ if (console.info(`~~~~routeChange~~~~ ${a} -> ${e}`), !o)
393
390
  return;
394
391
  const r = n.app === o.app, l = n.path === o.path, c = n.level >= o.level;
395
- r ? l ? X.value = "" : X.value = c ? "inner-left" : "inner-right" : (X.value = "", Re(n.app, c));
392
+ r ? l ? Q.value = "" : Q.value = c ? "inner-left" : "inner-right" : (Q.value = "", Re(n.app, c));
396
393
  }
397
- function Ee() {
398
- return !!E.get("accessToken");
394
+ function je() {
395
+ return !!j.get("accessToken");
399
396
  }
400
397
  function Te() {
401
- return !!E.get("activeOrg");
398
+ return !!j.get("activeOrg");
402
399
  }
403
- function qt(e, t, a) {
404
- const n = Ee(), o = Te(), r = N(e.path);
400
+ function qt(e, a, t) {
401
+ const n = je(), o = Te(), r = K(e.path);
405
402
  if (!r) {
406
- console.assert(!1), a();
403
+ console.assert(!1), t();
407
404
  return;
408
405
  }
409
406
  if (r.requiredState === "auth")
410
407
  if (n)
411
408
  if (o) {
412
409
  const l = "/main";
413
- L(l, t.path), a({ path: l });
410
+ L(l, a.path), t({ path: l });
414
411
  } else
415
- L(e.path, t.path), a();
412
+ L(e.path, a.path), t();
416
413
  else {
417
414
  const l = "/passport/login";
418
- L(l, t.path), a({ path: l });
415
+ L(l, a.path), t({ path: l });
419
416
  }
420
417
  else if (r.requiredState === "org")
421
418
  if (n)
422
419
  if (o)
423
- L(e.path, t.path), a();
420
+ L(e.path, a.path), t();
424
421
  else {
425
422
  const l = "/org/joinOrCreate";
426
- L(l, t.path), a({ path: l });
423
+ L(l, a.path), t({ path: l });
427
424
  }
428
425
  else {
429
426
  const l = "/passport/login";
430
- L(l, t.path), a({ path: l });
427
+ L(l, a.path), t({ path: l });
431
428
  }
432
429
  else if (n)
433
430
  if (o) {
434
431
  const l = "/main";
435
- L(l, t.path), a({ path: l });
432
+ L(l, a.path), t({ path: l });
436
433
  } else {
437
434
  const l = "/org/joinOrCreate";
438
- L(l, t.path), a({ path: l });
435
+ L(l, a.path), t({ path: l });
439
436
  }
440
437
  else
441
- L(e.path, t.path), a();
438
+ L(e.path, a.path), t();
442
439
  }
443
440
  const Be = /* @__PURE__ */ T({
444
441
  __name: "index",
445
442
  setup(e) {
446
- const { t } = Y(), a = $(), n = g({
443
+ const { t: a } = P(), t = $(), n = g({
447
444
  get() {
448
- return a.hasView("confirmDlg");
445
+ return t.hasView("confirmDlg");
449
446
  },
450
447
  set(m) {
451
- m ? a.addView("confirmDlg") : a.delView("confirmDlg");
448
+ m ? t.addView("confirmDlg") : t.delView("confirmDlg");
452
449
  }
453
450
  }), o = d(""), r = d(""), l = d(""), c = d(""), u = d(""), p = d("");
454
- let _ = 0, x = !1;
451
+ let _ = 0, y = !1;
455
452
  const i = (m) => {
456
- var y, C, S, R;
457
- o.value = m.title, r.value = m.text, l.value = ((y = m.cancel) == null ? void 0 : y.color) ?? "primary", c.value = ((C = m.cancel) == null ? void 0 : C.text) ?? t("dlg.common.cancel"), u.value = ((S = m.confirm) == null ? void 0 : S.color) ?? "primary", p.value = ((R = m.confirm) == null ? void 0 : R.text) ?? t("dlg.common.confirm"), _ = m.seq, x = !1, n.value = !0;
453
+ var x, C, S, R;
454
+ o.value = m.title, r.value = m.text, l.value = ((x = m.cancel) == null ? void 0 : x.color) ?? "primary", c.value = ((C = m.cancel) == null ? void 0 : C.text) ?? a("dlg.common.cancel"), u.value = ((S = m.confirm) == null ? void 0 : S.color) ?? "primary", p.value = ((R = m.confirm) == null ? void 0 : R.text) ?? a("dlg.common.confirm"), _ = m.seq, y = !1, n.value = !0;
458
455
  };
459
456
  V(() => {
460
457
  s.on("confirmDlg", i);
@@ -462,50 +459,50 @@ const Be = /* @__PURE__ */ T({
462
459
  s.off("confirmDlg", i);
463
460
  });
464
461
  const M = () => {
465
- n.value = !1, x || (s.emit("confirmDlgResult" + _, !0), x = !0);
462
+ n.value = !1, y || (s.emit("confirmDlgResult" + _, !0), y = !0);
466
463
  };
467
- return Z(n, (m) => {
468
- !m && !x && (s.emit("confirmDlgResult" + _, !1), x = !0);
469
- }), (m, y) => {
464
+ return N(n, (m) => {
465
+ !m && !y && (s.emit("confirmDlgResult" + _, !1), y = !0);
466
+ }), (m, x) => {
470
467
  const C = h("v-card-text"), S = h("v-btn"), R = h("v-card-actions"), f = h("v-card"), k = h("v-dialog");
471
468
  return D(), O(k, {
472
469
  modelValue: n.value,
473
- "onUpdate:modelValue": y[1] || (y[1] = (A) => n.value = A),
474
- onKeydown: [
475
- y[2] || (y[2] = K(W((A) => n.value = !1, ["stop", "prevent"]), ["esc"])),
476
- K(W(M, ["stop", "prevent"]), ["enter"])
477
- ],
470
+ "onUpdate:modelValue": x[1] || (x[1] = (A) => n.value = A),
478
471
  transition: "dialog-top-transition",
479
- "max-width": "600px"
472
+ "max-width": "600px",
473
+ onKeydown: [
474
+ x[2] || (x[2] = F(W((A) => n.value = !1, ["stop", "prevent"]), ["esc"])),
475
+ F(W(M, ["stop", "prevent"]), ["enter"])
476
+ ]
480
477
  }, {
481
478
  default: w(() => [
482
479
  b(f, { title: o.value }, {
483
480
  default: w(() => [
484
481
  b(C, null, {
485
482
  default: w(() => [
486
- j(q(r.value), 1)
483
+ E(q(r.value), 1)
487
484
  ]),
488
485
  _: 1
489
486
  }),
490
487
  b(R, { class: "d-flex justify-end" }, {
491
488
  default: w(() => [
492
489
  b(S, {
493
- onClick: y[0] || (y[0] = (A) => n.value = !1),
494
490
  color: l.value,
495
- variant: "text"
491
+ variant: "text",
492
+ onClick: x[0] || (x[0] = (A) => n.value = !1)
496
493
  }, {
497
494
  default: w(() => [
498
- j(q(c.value), 1)
495
+ E(q(c.value), 1)
499
496
  ]),
500
497
  _: 1
501
498
  }, 8, ["color"]),
502
499
  b(S, {
503
- onClick: M,
504
500
  color: u.value,
505
- variant: "text"
501
+ variant: "text",
502
+ onClick: M
506
503
  }, {
507
504
  default: w(() => [
508
- j(q(p.value), 1)
505
+ E(q(p.value), 1)
509
506
  ]),
510
507
  _: 1
511
508
  }, 8, ["color"])
@@ -520,7 +517,7 @@ const Be = /* @__PURE__ */ T({
520
517
  }, 8, ["modelValue", "onKeydown"]);
521
518
  };
522
519
  }
523
- }), Ue = (e) => (fe("data-v-ea85eb65"), e = e(), ge(), e), We = /* @__PURE__ */ Ue(() => /* @__PURE__ */ v("div", { class: "lds-spinner" }, [
520
+ }), Ue = (e) => (fe("data-v-7ab74c70"), e = e(), ge(), e), We = /* @__PURE__ */ Ue(() => /* @__PURE__ */ v("div", { class: "lds-spinner" }, [
524
521
  /* @__PURE__ */ v("div"),
525
522
  /* @__PURE__ */ v("div"),
526
523
  /* @__PURE__ */ v("div"),
@@ -538,29 +535,26 @@ const Be = /* @__PURE__ */ T({
538
535
  ], He = /* @__PURE__ */ T({
539
536
  __name: "index",
540
537
  props: {
541
- zIndex: {
542
- type: Number,
543
- default: 1
544
- }
538
+ zIndex: { default: 1 }
545
539
  },
546
540
  setup(e) {
547
- const t = P(), a = e, n = g(() => ({
548
- background: t.current.value.dark ? "#1e1e1e" : "#ffffff",
549
- zIndex: a.zIndex
541
+ const a = ee(), t = e, n = g(() => ({
542
+ background: a.current.value.dark ? "#1e1e1e" : "#ffffff",
543
+ zIndex: t.zIndex
550
544
  }));
551
- return (o, r) => (D(), Q("div", {
545
+ return (o, r) => (D(), J("div", {
552
546
  class: "x-cont",
553
547
  style: ne(n.value)
554
548
  }, $e, 4));
555
549
  }
556
- }), te = (e, t) => {
557
- const a = e.__vccOpts || e;
558
- for (const [n, o] of t)
559
- a[n] = o;
560
- return a;
561
- }, ze = /* @__PURE__ */ te(He, [["__scopeId", "data-v-ea85eb65"]]);
562
- var Fe = "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", Ke = "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", Ne = "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", Ze = "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", Ge = "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";
563
- const Xe = /* @__PURE__ */ T({
550
+ }), te = (e, a) => {
551
+ const t = e.__vccOpts || e;
552
+ for (const [n, o] of a)
553
+ t[n] = o;
554
+ return t;
555
+ }, ze = /* @__PURE__ */ te(He, [["__scopeId", "data-v-7ab74c70"]]);
556
+ var Xe = "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", Fe = "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", Ke = "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", Ne = "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", Ze = "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";
557
+ const Ge = /* @__PURE__ */ T({
564
558
  __name: "item",
565
559
  props: {
566
560
  id: {},
@@ -569,35 +563,35 @@ const Xe = /* @__PURE__ */ T({
569
563
  timeout: { default: 5e3 }
570
564
  },
571
565
  emits: ["timeout"],
572
- setup(e, { emit: t }) {
573
- const a = e, n = g(() => ({
566
+ setup(e, { emit: a }) {
567
+ const t = e, n = g(() => ({
574
568
  width: "calc(100% - 64px)",
575
569
  overflowWrap: "break-word"
576
570
  })), o = g(() => {
577
- switch (a.type) {
571
+ switch (t.type) {
578
572
  case "success":
579
- return Ke;
573
+ return Fe;
580
574
  case "info":
581
- return Ge;
582
- case "error":
583
575
  return Ze;
576
+ case "error":
577
+ return Ne;
584
578
  case "warning":
585
- return Fe;
579
+ return Xe;
586
580
  default:
587
581
  return "";
588
582
  }
589
- }), r = d(!0), l = t;
583
+ }), r = d(!0), l = a;
590
584
  return V(() => {
591
585
  setTimeout(() => {
592
- l("timeout", a.id);
593
- }, a.timeout);
594
- }), Z(r, (c) => {
595
- c || l("timeout", a.id);
586
+ l("timeout", t.id);
587
+ }, t.timeout);
588
+ }), N(r, (c) => {
589
+ c || l("timeout", t.id);
596
590
  }), (c, u) => {
597
591
  const p = h("v-icon"), _ = h("v-sheet");
598
592
  return D(), O(_, {
599
- class: "x-item d-flex align-center mb-2",
600
- color: a.type,
593
+ class: "x-item d-flex align-center py-2 mb-2",
594
+ color: t.type,
601
595
  elevation: 1
602
596
  }, {
603
597
  default: w(() => [
@@ -608,27 +602,27 @@ const Xe = /* @__PURE__ */ T({
608
602
  }, null, 8, ["icon"])) : le("", !0),
609
603
  v("div", {
610
604
  style: ne(n.value)
611
- }, q(a.text), 5),
605
+ }, q(t.text), 5),
612
606
  b(p, {
613
- onClick: u[0] || (u[0] = (x) => l("timeout", a.id)),
614
607
  class: "mx-1",
615
- icon: re(Ne)
608
+ icon: re(Ke),
609
+ onClick: u[0] || (u[0] = (y) => l("timeout", t.id))
616
610
  }, null, 8, ["icon"])
617
611
  ]),
618
612
  _: 1
619
613
  }, 8, ["color"]);
620
614
  };
621
615
  }
622
- }), Qe = /* @__PURE__ */ te(Xe, [["__scopeId", "data-v-448d0248"]]), Je = /* @__PURE__ */ T({
616
+ }), Qe = /* @__PURE__ */ te(Ge, [["__scopeId", "data-v-d5cfe252"]]), Je = /* @__PURE__ */ T({
623
617
  __name: "index",
624
618
  setup(e) {
625
- const t = d([]);
619
+ const a = d([]);
626
620
  V(() => {
627
- s.on("message", a);
621
+ s.on("message", t);
628
622
  }), I(() => {
629
- s.off("message", a);
623
+ s.off("message", t);
630
624
  });
631
- const a = (c) => {
625
+ const t = (c) => {
632
626
  r(c.type, c.text, c.timeout);
633
627
  }, n = (c) => {
634
628
  l(c);
@@ -636,41 +630,41 @@ const Xe = /* @__PURE__ */ T({
636
630
  let o = 0;
637
631
  const r = (c, u, p) => {
638
632
  const _ = o++;
639
- t.value.push({ id: _, type: c, text: u, timeout: p });
633
+ a.value.push({ id: _, type: c, text: u, timeout: p });
640
634
  }, l = (c) => {
641
- const u = t.value.findIndex((p) => p.id === c);
642
- u >= 0 && t.value.splice(u, 1);
635
+ const u = a.value.findIndex((p) => p.id === c);
636
+ u >= 0 && a.value.splice(u, 1);
643
637
  };
644
- return (c, u) => (D(), Q("div", {
638
+ return (c, u) => (D(), J("div", {
639
+ class: "x-cont d-flex flex-column-reverse align-center",
645
640
  onClick: u[0] || (u[0] = W(() => {
646
- }, ["stop"])),
647
- class: "x-cont d-flex flex-column-reverse align-center"
641
+ }, ["stop"]))
648
642
  }, [
649
- (D(!0), Q(ve, null, me(t.value, (p) => (D(), O(Qe, {
650
- key: p.id,
651
- onTimeout: n,
643
+ (D(!0), J(ve, null, me(a.value, (p) => (D(), O(Qe, {
652
644
  id: p.id,
645
+ key: p.id,
653
646
  type: p.type,
654
647
  text: p.text,
655
- timeout: p.timeout
648
+ timeout: p.timeout,
649
+ onTimeout: n
656
650
  }, null, 8, ["id", "type", "text", "timeout"]))), 128))
657
651
  ]));
658
652
  }
659
- }), Ye = /* @__PURE__ */ te(Je, [["__scopeId", "data-v-fc1bc7ac"]]), Pe = /* @__PURE__ */ T({
653
+ }), Ye = /* @__PURE__ */ te(Je, [["__scopeId", "data-v-d525e6f5"]]), Pe = /* @__PURE__ */ T({
660
654
  __name: "index",
661
655
  setup(e) {
662
- const { t } = Y(), a = $(), n = g({
656
+ const { t: a } = P(), t = $(), n = g({
663
657
  get() {
664
- return a.hasView("promptDlg");
658
+ return t.hasView("promptDlg");
665
659
  },
666
660
  set(f) {
667
- f ? a.addView("promptDlg") : a.delView("promptDlg");
661
+ f ? t.addView("promptDlg") : t.delView("promptDlg");
668
662
  }
669
- }), o = d(""), r = d(""), l = d(""), c = d(""), u = d(), p = d(""), _ = d(""), x = d(""), i = d(""), M = d(""), m = d();
670
- let y = 0, C = !1;
663
+ }), o = d(""), r = d(""), l = d(""), c = d(""), u = d(), p = d(""), _ = d(""), y = d(""), i = d(""), M = d(""), m = d();
664
+ let x = 0, C = !1;
671
665
  const S = async (f) => {
672
666
  var k, A, H, z, B;
673
- o.value = f.title, r.value = f.text, l.value = f.label, c.value = f.placeholder, u.value = f.rules, p.value = f.value, _.value = ((k = f.cancel) == null ? void 0 : k.color) ?? "primary", x.value = ((A = f.cancel) == null ? void 0 : A.text) ?? t("dlg.common.cancel"), i.value = ((H = f.confirm) == null ? void 0 : H.color) ?? "primary", M.value = ((z = f.confirm) == null ? void 0 : z.text) ?? t("dlg.common.confirm"), y = f.seq, C = !1, n.value = !0, await ee(() => !!m.value, 1e3), (B = m.value) == null || B.focus();
667
+ o.value = f.title, r.value = f.text, l.value = f.label, c.value = f.placeholder, u.value = f.rules, p.value = f.value, _.value = ((k = f.cancel) == null ? void 0 : k.color) ?? "primary", y.value = ((A = f.cancel) == null ? void 0 : A.text) ?? a("dlg.common.cancel"), i.value = ((H = f.confirm) == null ? void 0 : H.color) ?? "primary", M.value = ((z = f.confirm) == null ? void 0 : z.text) ?? a("dlg.common.confirm"), x = f.seq, C = !1, n.value = !0, await G(() => !!m.value, 1e3), (B = m.value) == null || B.focus();
674
668
  };
675
669
  V(() => {
676
670
  s.on("promptDlg", S);
@@ -678,41 +672,41 @@ const Xe = /* @__PURE__ */ T({
678
672
  s.off("promptDlg", S);
679
673
  });
680
674
  const R = () => {
681
- n.value = !1, C || (s.emit("promptDlgResult" + y, p.value ?? ""), C = !0);
675
+ n.value = !1, C || (s.emit("promptDlgResult" + x, p.value ?? ""), C = !0);
682
676
  };
683
- return Z(n, (f) => {
684
- !f && !C && (s.emit("promptDlgResult" + y, void 0), C = !0);
677
+ return N(n, (f) => {
678
+ !f && !C && (s.emit("promptDlgResult" + x, void 0), C = !0);
685
679
  }), (f, k) => {
686
680
  const A = h("v-card-text"), H = h("v-text-field"), z = h("v-form"), B = h("v-btn"), de = h("v-card-actions"), _e = h("v-card"), ie = h("v-dialog");
687
681
  return D(), O(ie, {
688
682
  modelValue: n.value,
689
683
  "onUpdate:modelValue": k[2] || (k[2] = (U) => n.value = U),
690
- onKeydown: [
691
- k[3] || (k[3] = K(W((U) => n.value = !1, ["stop", "prevent"]), ["esc"])),
692
- K(W(R, ["stop", "prevent"]), ["enter"])
693
- ],
694
684
  transition: "dialog-top-transition",
695
- "max-width": "600px"
685
+ "max-width": "600px",
686
+ onKeydown: [
687
+ k[3] || (k[3] = F(W((U) => n.value = !1, ["stop", "prevent"]), ["esc"])),
688
+ F(W(R, ["stop", "prevent"]), ["enter"])
689
+ ]
696
690
  }, {
697
691
  default: w(() => [
698
692
  b(_e, { title: o.value }, {
699
693
  default: w(() => [
700
694
  r.value ? (D(), O(A, { key: 0 }, {
701
695
  default: w(() => [
702
- j(q(r.value), 1)
696
+ E(q(r.value), 1)
703
697
  ]),
704
698
  _: 1
705
699
  })) : le("", !0),
706
700
  b(z, { class: "mx-3" }, {
707
701
  default: w(() => [
708
702
  b(H, {
703
+ ref_key: "target",
704
+ ref: m,
709
705
  modelValue: p.value,
710
706
  "onUpdate:modelValue": k[0] || (k[0] = (U) => p.value = U),
711
707
  label: l.value,
712
708
  placeholder: c.value,
713
- rules: u.value,
714
- ref_key: "target",
715
- ref: m
709
+ rules: u.value
716
710
  }, null, 8, ["modelValue", "label", "placeholder", "rules"])
717
711
  ]),
718
712
  _: 1
@@ -720,22 +714,22 @@ const Xe = /* @__PURE__ */ T({
720
714
  b(de, { class: "d-flex justify-end" }, {
721
715
  default: w(() => [
722
716
  b(B, {
723
- onClick: k[1] || (k[1] = (U) => n.value = !1),
724
717
  color: _.value,
725
- variant: "text"
718
+ variant: "text",
719
+ onClick: k[1] || (k[1] = (U) => n.value = !1)
726
720
  }, {
727
721
  default: w(() => [
728
- j(q(x.value), 1)
722
+ E(q(y.value), 1)
729
723
  ]),
730
724
  _: 1
731
725
  }, 8, ["color"]),
732
726
  b(B, {
733
- onClick: R,
734
727
  color: i.value,
735
- variant: "text"
728
+ variant: "text",
729
+ onClick: R
736
730
  }, {
737
731
  default: w(() => [
738
- j(q(M.value), 1)
732
+ E(q(M.value), 1)
739
733
  ]),
740
734
  _: 1
741
735
  }, 8, ["color"])
@@ -753,15 +747,15 @@ const Xe = /* @__PURE__ */ T({
753
747
  }), et = { class: "mx-auto my-auto" }, tt = { class: "w-100 h-100 d-flex align-center justify-center" }, at = { class: "text-body-1" }, ot = /* @__PURE__ */ T({
754
748
  __name: "index",
755
749
  setup(e) {
756
- const { t } = Y(), a = $(), n = g({
750
+ const { t: a } = P(), t = $(), n = g({
757
751
  get() {
758
- return a.hasView("waitDlg");
752
+ return t.hasView("waitDlg");
759
753
  },
760
754
  set(c) {
761
- c ? a.addView("waitDlg") : a.delView("waitDlg");
755
+ c ? t.addView("waitDlg") : t.delView("waitDlg");
762
756
  }
763
757
  }), o = d(""), r = (c) => {
764
- o.value = c.text ?? t("dlg.common.waiting"), n.value = !0;
758
+ o.value = c.text ?? a("dlg.common.waiting"), n.value = !0;
765
759
  }, l = () => {
766
760
  n.value = !1;
767
761
  };
@@ -773,7 +767,7 @@ const Xe = /* @__PURE__ */ T({
773
767
  const p = h("v-card"), _ = h("v-dialog");
774
768
  return D(), O(_, {
775
769
  modelValue: n.value,
776
- "onUpdate:modelValue": u[0] || (u[0] = (x) => n.value = x),
770
+ "onUpdate:modelValue": u[0] || (u[0] = (y) => n.value = y),
777
771
  persistent: "",
778
772
  "no-click-animation": "",
779
773
  fullscreen: ""
@@ -799,13 +793,13 @@ const Xe = /* @__PURE__ */ T({
799
793
  };
800
794
  }
801
795
  }), nt = (e) => {
802
- e.component("x-confirm-dlg", Be), e.component("x-loading", ze), e.component("x-message", Ye), e.component("x-prompt-dlg", Pe), e.component("x-wait-dlg", ot);
796
+ e.component("XConfirmDlg", Be), e.component("XLoading", ze), e.component("XMessage", Ye), e.component("XPromptDlg", Pe), e.component("XWaitDlg", ot);
803
797
  };
804
798
  function Rt() {
805
- const e = P(), t = g(() => e.global.current.value.colors.primary), a = g(() => e.global.current.value.colors.secondary), n = g(() => e.current.value.dark ? "#2e2e2e" : "#bdbdbd"), o = g(() => e.current.value.dark ? "#272727" : "#eeeeee"), r = g(() => e.current.value.dark ? "#1e1e1e" : "#ffffff"), l = g(() => e.current.value.dark ? "#303030" : "#f6f6f6"), c = g(() => e.current.value.dark ? "#ffffff1f" : "#0000001f");
799
+ const e = ee(), a = g(() => e.global.current.value.colors.primary), t = g(() => e.global.current.value.colors.secondary), n = g(() => e.current.value.dark ? "#2e2e2e" : "#bdbdbd"), o = g(() => e.current.value.dark ? "#272727" : "#eeeeee"), r = g(() => e.current.value.dark ? "#1e1e1e" : "#ffffff"), l = g(() => e.current.value.dark ? "#303030" : "#f6f6f6"), c = g(() => e.current.value.dark ? "#ffffff1f" : "#0000001f");
806
800
  return {
807
- primaryColor: t,
808
- secondaryColor: a,
801
+ primaryColor: a,
802
+ secondaryColor: t,
809
803
  backgroundColor0: n,
810
804
  backgroundColor1: o,
811
805
  backgroundColor2: r,
@@ -823,24 +817,24 @@ const ct = typeof window < "u" && typeof document < "u";
823
817
  typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope;
824
818
  const ut = ct ? window : void 0;
825
819
  function st() {
826
- const e = d(!1), t = ye();
827
- return t && V(() => {
820
+ const e = d(!1), a = xe();
821
+ return a && V(() => {
828
822
  e.value = !0;
829
- }, t), e;
823
+ }, a), e;
830
824
  }
831
825
  function pt(e) {
832
- const t = st();
833
- return g(() => (t.value, !!e()));
826
+ const a = st();
827
+ return g(() => (a.value, !!e()));
834
828
  }
835
- function dt(e, t = {}) {
836
- const { window: a = ut } = t, n = pt(() => a && "matchMedia" in a && typeof a.matchMedia == "function");
829
+ function dt(e, a = {}) {
830
+ const { window: t = ut } = a, n = pt(() => t && "matchMedia" in t && typeof t.matchMedia == "function");
837
831
  let o;
838
832
  const r = d(!1), l = (p) => {
839
833
  r.value = p.matches;
840
834
  }, c = () => {
841
835
  o && ("removeEventListener" in o ? o.removeEventListener("change", l) : o.removeListener(l));
842
- }, u = xe(() => {
843
- n.value && (c(), o = a.matchMedia(rt(e)), "addEventListener" in o ? o.addEventListener("change", l) : o.addListener(l), r.value = o.matches);
836
+ }, u = ye(() => {
837
+ n.value && (c(), o = t.matchMedia(rt(e)), "addEventListener" in o ? o.addEventListener("change", l) : o.addListener(l), r.value = o.matches);
844
838
  });
845
839
  return lt(() => {
846
840
  u(), c(), o = void 0;
@@ -850,15 +844,15 @@ function _t(e) {
850
844
  return dt("(prefers-color-scheme: dark)", e);
851
845
  }
852
846
  function it() {
853
- const e = Ce(), t = G(), a = _t(), n = g(() => typeof t.dark == "boolean" ? t.dark : a.value), o = g(() => !!window.cordova), r = g(() => e.width.value <= 1280 ? e.width.value + "px" : e.width.value <= 1920 ? 1920 / 2.5 + "px" : 2560 / 2.5 + "px");
847
+ const e = Ce(), a = Z(), t = _t(), n = g(() => typeof a.dark == "boolean" ? a.dark : t.value), o = g(() => !!window.cordova), r = g(() => e.width.value <= 1280 ? e.width.value + "px" : e.width.value <= 1920 ? 1920 / 2.5 + "px" : 2560 / 2.5 + "px");
854
848
  return { dark: n, sysBarAvail: o, compactWidth: r };
855
849
  }
856
850
  function It() {
857
- const e = be(), t = ue(), a = P(), { dark: n } = it(), o = G(), r = $();
858
- Z(
851
+ const e = be(), a = ue(), t = ee(), { dark: n } = it(), o = Z(), r = $();
852
+ N(
859
853
  n,
860
854
  (i) => {
861
- a.global.name.value = i ? "dark" : "light";
855
+ t.global.name.value = i ? "dark" : "light";
862
856
  },
863
857
  { immediate: !0 }
864
858
  );
@@ -873,13 +867,13 @@ function It() {
873
867
  r.hasView("waitDlg") || r.popView();
874
868
  return;
875
869
  }
876
- const i = N(e.path);
870
+ const i = K(e.path);
877
871
  (i == null ? void 0 : i.level) === 0 ? (M = navigator == null ? void 0 : navigator.Backbutton) == null || M.goHome(
878
872
  () => {
879
873
  },
880
874
  () => {
881
875
  }
882
- ) : t.back();
876
+ ) : a.back();
883
877
  };
884
878
  V(() => {
885
879
  window.addEventListener("keydown", l), s.on("backbutton", c);
@@ -892,33 +886,33 @@ function It() {
892
886
  o.locale = i;
893
887
  }, _ = (i) => {
894
888
  o.permissionObjects = i[0], o.permissionChecksum = i[1];
895
- }, x = (i) => {
889
+ }, y = (i) => {
896
890
  o.lastAppPath = i;
897
891
  };
898
892
  V(() => {
899
- s.on("updateDark", u), s.on("updateLocale", p), s.on("updatePermission", _), s.on("updateLastAppPath", x), s.emit("syncGlobalState");
893
+ s.on("updateDark", u), s.on("updateLocale", p), s.on("updatePermission", _), s.on("updateLastAppPath", y), s.emit("syncGlobalState");
900
894
  }), I(() => {
901
- s.off("updateDark", u), s.off("updateLocale", p), s.off("updatePermission", _), s.off("updateLastAppPath", x);
895
+ s.off("updateDark", u), s.off("updateLocale", p), s.off("updatePermission", _), s.off("updateLastAppPath", y);
902
896
  });
903
897
  }
904
898
  function Ot() {
905
- const e = G();
906
- function t(a, n) {
907
- const o = e.permissionObjects[a];
899
+ const e = Z();
900
+ function a(t, n) {
901
+ const o = e.permissionObjects[t];
908
902
  return o ? n ? !(!oe(o.includes, n) || oe(o.excludes, n)) : !0 : !1;
909
903
  }
910
- return { verifyPermission: t };
904
+ return { verifyPermission: a };
911
905
  }
912
- function jt(e, t) {
913
- const a = $(), n = g({
906
+ function Et(e, a) {
907
+ const t = $(), n = g({
914
908
  get() {
915
- return a.hasView(e);
909
+ return t.hasView(e);
916
910
  },
917
911
  set(r) {
918
- r ? a.addView(e) : a.delView(e);
912
+ r ? t.addView(e) : t.delView(e);
919
913
  }
920
914
  }), o = (r) => {
921
- t == null || t(r), n.value = !0;
915
+ a == null || a(r), n.value = !0;
922
916
  };
923
917
  return V(() => {
924
918
  s.on(e, o);
@@ -926,20 +920,20 @@ function jt(e, t) {
926
920
  s.off(e, o);
927
921
  }), { open: n };
928
922
  }
929
- const ft = (e, t, a) => {
930
- const n = e[t];
923
+ const ft = (e, a, t) => {
924
+ const n = e[a];
931
925
  return n ? typeof n == "function" ? n() : Promise.resolve(n) : new Promise((o, r) => {
932
926
  (typeof queueMicrotask == "function" ? queueMicrotask : setTimeout)(
933
927
  r.bind(
934
928
  null,
935
929
  new Error(
936
- "Unknown variable dynamic import: " + t + (t.split("/").length !== a ? ". Note that variables only represent file names one level deep." : "")
930
+ "Unknown variable dynamic import: " + a + (a.split("/").length !== t ? ". Note that variables only represent file names one level deep." : "")
937
931
  )
938
932
  )
939
933
  );
940
934
  });
941
935
  };
942
- async function Et(e) {
936
+ async function jt(e) {
943
937
  return (await ft(/* @__PURE__ */ Object.assign({ "./locales/en/index.ts": () => import("./en-iuzmkt0n.js"), "./locales/zhHans/index.ts": () => import("./zhHans-m6y1by9n.js") }), `./locales/${e}/index.ts`, 4)).default;
944
938
  }
945
939
  const Tt = { install: nt };
@@ -947,12 +941,12 @@ export {
947
941
  Oe as Permission,
948
942
  Re as appAppear,
949
943
  Lt as closeWaitDlg,
950
- yt as createAxios,
944
+ xt as createAxios,
951
945
  Tt as default,
952
946
  s as eventBus,
953
947
  oe as isExist,
954
- Et as loadLocaleMessageEssential,
955
- N as matchRouteMeta,
948
+ jt as loadLocaleMessageEssential,
949
+ K as matchRouteMeta,
956
950
  Vt as messageError,
957
951
  Mt as messageInfo,
958
952
  St as messageSuccess,
@@ -961,14 +955,14 @@ export {
961
955
  bt as openConfirmDlg,
962
956
  Ct as openPromptDlg,
963
957
  Dt as openWaitDlg,
964
- X as routeTransName,
958
+ Q as routeTransName,
965
959
  Rt as useColor,
966
- G as useGlobalStore,
960
+ Z as useGlobalStore,
967
961
  It as useMicroApp,
968
962
  Ot as usePermission,
969
963
  it as useSystem,
970
964
  $ as useViewMgrStore,
971
- jt as useViewStack,
965
+ Et as useViewStack,
972
966
  kt as waitMs,
973
- ee as waitUtil
967
+ G as waitUtil
974
968
  };
@@ -2,4 +2,4 @@ import { Emitter, EventType } from 'mitt';
2
2
  export declare const eventBus: Emitter<Record<EventType, unknown>>;
3
3
  export declare function waitMs(ms: number): Promise<void>;
4
4
  export declare function waitUtil(conditionFunc: () => boolean, timeout?: number, interval?: number): Promise<boolean>;
5
- export declare function appAppear(name: string, forward: boolean): void;
5
+ export declare function appAppear(name: string, forward: boolean): Promise<void>;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "x-essential-lib",
3
3
  "private": false,
4
- "version": "0.6.2",
4
+ "version": "0.6.4",
5
5
  "type": "module",
6
6
  "module": "dist/index.js",
7
7
  "types": "dist/index.d.ts",
@@ -30,10 +30,10 @@
30
30
  "axios": "^1.7.2",
31
31
  "pinia": "^2.1.7",
32
32
  "pinia-plugin-persistedstate": "^3.2.1",
33
- "vue": "^3.4.31",
33
+ "vue": "^3.4.32",
34
34
  "vue-i18n": "^9.13.1",
35
35
  "vue-router": "^4.4.0",
36
- "vuetify": "^3.6.12"
36
+ "vuetify": "^3.6.13"
37
37
  },
38
38
  "devDependencies": {
39
39
  "@mdi/js": "^7.4.47",
@@ -47,7 +47,7 @@
47
47
  "eslint-plugin-vue": "^9.27.0",
48
48
  "husky": "^9.0.11",
49
49
  "lint-staged": "^15.2.7",
50
- "prettier": "3.3.2",
50
+ "prettier": "3.3.3",
51
51
  "sass": "^1.77.7",
52
52
  "typescript": "^5.5.3",
53
53
  "vite": "^5.3.3",