x-essential-lib 0.5.13 → 0.5.15

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