@vtj/ui 0.6.11 → 0.6.13

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/lib/index.js CHANGED
@@ -1,48 +1,48 @@
1
- import { defineComponent as B, openBlock as u, createElementBlock as V, renderSlot as z, createElementVNode as $, unref as o, toDisplayString as O, createVNode as b, withCtx as d, createTextVNode as N, createBlock as f, createCommentVNode as y, useAttrs as Ge, getCurrentInstance as pe, computed as v, markRaw as Pe, normalizeClass as U, resolveDynamicComponent as Z, mergeProps as X, Fragment as q, renderList as ke, isVNode as Mt, h as Y, toRef as ve, useSlots as Et, normalizeStyle as be, ref as R, normalizeProps as qe, guardReactiveProps as et, effectScope as tt, watch as ee, reactive as nt, onMounted as It, onUnmounted as Bt, watchEffect as ot, nextTick as le, Teleport as at, withDirectives as W, createSlots as $e, render as Xe, vShow as K, isRef as ye, withModifiers as At, KeepAlive as Dt, shallowRef as Ue, provide as Re, toRaw as Vt, inject as Be } from "vue";
2
- import { ElDivider as ue, ElButton as de, ElIcon as Pt, ElSubMenu as $t, ElBadge as Ae, ElMenuItem as Rt, ElMenu as Ft, ElContainer as He, ElHeader as Ot, ElAside as jt, ElMain as Nt, ElFooter as Xt, ElDropdown as Ut, ElDropdownMenu as Ht, ElDropdownItem as Lt, ElTooltip as st, ElSwitch as lt, ElInput as De, ElEmpty as Wt, ElTabs as Qt, ElTabPane as Le, ElPopover as it, ElAvatar as Zt, ElMessageBox as Me, ElSelect as Jt, ElOption as Kt, formContextKey as Yt, ElFormItem as Gt, ElForm as qt } from "element-plus";
3
- import { VideoPlay as en, Document as ae, Menu as rt, ArrowRight as tn, StarFilled as ct, Search as Ve, Close as ut, Expand as nn, Fold as on, Star as dt, Refresh as an, CopyDocument as sn, Moon as ln, Sunny as rn, MoreFilled as cn, UserFilled as un, HomeFilled as dn, WarningFilled as pn } from "@element-plus/icons-vue";
4
- import { useRouter as xe, useRoute as Fe, RouterView as pt, routeLocationKey as fn } from "vue-router";
5
- import { Minimize as mn, Popup as gn, Maximize as hn, RawClose as yn } from "@vtj/icons";
6
- import { useDraggable as vn, useMouseInElement as bn, useEventListener as _e, useElementSize as ft, useDark as _n } from "@vueuse/core";
7
- import { isEqual as mt, isObject as gt, uid as ht, arrayToMap as wn, isUrl as kn, upperFirstCamelCase as yt, merge as xn } from "@vtj/utils";
8
- function We(a) {
1
+ import { defineComponent as E, openBlock as c, createElementBlock as A, renderSlot as z, createElementVNode as O, unref as n, toDisplayString as j, createVNode as k, withCtx as p, createTextVNode as N, createBlock as m, createCommentVNode as v, useAttrs as st, getCurrentInstance as de, computed as h, markRaw as ve, normalizeClass as W, resolveDynamicComponent as L, mergeProps as X, Fragment as Q, renderList as ie, isVNode as $t, h as q, toRef as ze, useSlots as Vt, normalizeStyle as Ce, ref as P, normalizeProps as Me, guardReactiveProps as Be, effectScope as lt, watch as H, reactive as Ne, onMounted as Dt, onUnmounted as Pt, watchEffect as it, nextTick as ce, Teleport as rt, withDirectives as K, createSlots as ye, render as Ze, vShow as Y, isRef as xe, withModifiers as Rt, KeepAlive as Ft, shallowRef as Je, provide as he, toRaw as Se, inject as me } from "vue";
2
+ import { ElDivider as ge, ElButton as le, ElIcon as Ot, ElSubMenu as jt, ElBadge as Re, ElMenuItem as Nt, ElMenu as Xt, ElContainer as Ge, ElHeader as Ut, ElAside as Ht, ElMain as Wt, ElFooter as Lt, ElDropdown as Kt, ElDropdownMenu as Qt, ElDropdownItem as Zt, ElTooltip as ct, ElSwitch as Xe, ElInput as Fe, ElEmpty as Jt, ElTabs as Gt, ElTabPane as Ye, ElPopover as ut, ElAvatar as Yt, ElMessageBox as De, ElSelect as qt, ElOption as eo, ElCheckboxButton as to, ElCheckbox as oo, ElCheckboxGroup as no, ElRadioButton as ao, ElRadio as so, ElRadioGroup as lo, ElInputNumber as io, ElDatePicker as qe, ElTimePicker as ro, ElRate as co, ElSlider as uo, ElCascader as po, formContextKey as fo, ElFormItem as mo, ElForm as go } from "element-plus";
3
+ import { VideoPlay as yo, Document as se, Menu as dt, ArrowRight as ho, StarFilled as pt, Search as Oe, Close as ft, Expand as vo, Fold as bo, Star as mt, Refresh as _o, CopyDocument as ko, Moon as wo, Sunny as xo, MoreFilled as So, UserFilled as zo, HomeFilled as Co, WarningFilled as To } from "@element-plus/icons-vue";
4
+ import { useRouter as Ie, useRoute as Ue, RouterView as gt, routeLocationKey as Eo } from "vue-router";
5
+ import { Minimize as Mo, Popup as Bo, Maximize as Io, RawClose as Ao } from "@vtj/icons";
6
+ import { useDraggable as $o, useMouseInElement as Vo, useEventListener as Te, useElementSize as yt, useDark as Do } from "@vueuse/core";
7
+ import { isEqual as He, isObject as We, uid as ht, arrayToMap as Po, isUrl as Ro, upperFirstCamelCase as vt, toArray as Fo, merge as Oo } from "@vtj/utils";
8
+ function je(a) {
9
9
  return typeof a == "string" ? a : `${a}px`;
10
10
  }
11
- function me(a = 0, e) {
11
+ function _e(a = 0, t) {
12
12
  if (typeof a == "number")
13
13
  return a;
14
14
  if (/(%|vh|vw)$/i.test(a)) {
15
- const n = Number.parseInt(a);
16
- return Math.floor(e * n / 100);
15
+ const o = Number.parseInt(a);
16
+ return Math.floor(t * o / 100);
17
17
  }
18
18
  return Number.parseInt(a);
19
19
  }
20
- function Zo(a, e) {
21
- const t = {};
22
- return Object.keys(a).forEach((n) => {
23
- e.includes(n) || (t[n] = a[n]);
24
- }), t;
20
+ function fa(a, t) {
21
+ const e = {};
22
+ return Object.keys(a).forEach((o) => {
23
+ t.includes(o) || (e[o] = a[o]);
24
+ }), e;
25
25
  }
26
- function Jo(a, e) {
27
- const t = {};
28
- return Object.keys(a).forEach((n) => {
29
- e.includes(n) && (t[n] = a[n]);
30
- }), t;
26
+ function ma(a, t) {
27
+ const e = {};
28
+ return Object.keys(a).forEach((o) => {
29
+ t.includes(o) && (e[o] = a[o]);
30
+ }), e;
31
31
  }
32
- const Ko = () => {
33
- }, Qe = Symbol("INSTALLED_KEY"), zn = (a = []) => ({
34
- install: (t) => {
35
- t[Qe] || (t[Qe] = !0, a.forEach((n) => {
36
- n.name && t.component(n.name, n);
32
+ const ga = () => {
33
+ }, et = Symbol("INSTALLED_KEY"), jo = (a = []) => ({
34
+ install: (e) => {
35
+ e[et] || (e[et] = !0, a.forEach((o) => {
36
+ o.name && e.component(o.name, o);
37
37
  }));
38
38
  }
39
- }), vt = "data:image/png;base64,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", Sn = { class: "x-startup" }, Cn = { class: "brand" }, Tn = ["src"], Mn = /* @__PURE__ */ $("h3", null, [
39
+ }), bt = "data:image/png;base64,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", No = { class: "x-startup" }, Xo = { class: "brand" }, Uo = ["src"], Ho = /* @__PURE__ */ O("h3", null, [
40
40
  /* @__PURE__ */ N("基于 "),
41
- /* @__PURE__ */ $("span", null, "Vue3 + TypeScript"),
41
+ /* @__PURE__ */ O("span", null, "Vue3 + TypeScript"),
42
42
  /* @__PURE__ */ N(" 的低代码设计器引擎")
43
- ], -1), En = { class: "btn" }, In = /* @__PURE__ */ $("div", { class: "ba" }, [
44
- /* @__PURE__ */ $("a", { href: "http://beian.miit.gov.cn/" }, "粤ICP备2023104074号")
45
- ], -1), Bn = /* @__PURE__ */ B({
43
+ ], -1), Wo = { class: "btn" }, Lo = /* @__PURE__ */ O("div", { class: "ba" }, [
44
+ /* @__PURE__ */ O("a", { href: "http://beian.miit.gov.cn/" }, "粤ICP备2023104074号")
45
+ ], -1), Ko = /* @__PURE__ */ E({
46
46
  name: "XStartup",
47
47
  __name: "Startup",
48
48
  props: {
@@ -51,58 +51,58 @@ const Ko = () => {
51
51
  example: {}
52
52
  },
53
53
  setup(a) {
54
- const e = a, t = () => {
55
- location.href = e.link + "#/?startup";
56
- }, n = () => {
57
- e.example && e.example(e.link);
54
+ const t = a, e = () => {
55
+ location.href = t.link + "#/?startup";
56
+ }, o = () => {
57
+ t.example && t.example(t.link);
58
58
  };
59
- return (s, l) => (u(), V("div", Sn, [
59
+ return (s, i) => (c(), A("div", No, [
60
60
  z(s.$slots, "default", {}, () => [
61
- $("div", null, [
62
- $("div", Cn, [
63
- $("img", { src: o(vt) }, null, 8, Tn),
64
- $("h1", null, O(e.text), 1)
61
+ O("div", null, [
62
+ O("div", Xo, [
63
+ O("img", { src: n(bt) }, null, 8, Uo),
64
+ O("h1", null, j(t.text), 1)
65
65
  ]),
66
- b(o(ue)),
67
- Mn,
68
- $("div", En, [
69
- b(o(de), {
70
- onClick: t,
66
+ k(n(ge)),
67
+ Ho,
68
+ O("div", Wo, [
69
+ k(n(le), {
70
+ onClick: e,
71
71
  type: "primary",
72
72
  round: "",
73
73
  size: "large",
74
- icon: o(en)
74
+ icon: n(yo)
75
75
  }, {
76
- default: d(() => [
76
+ default: p(() => [
77
77
  N(" 立即开始体验 ")
78
78
  ]),
79
79
  _: 1
80
80
  }, 8, ["icon"]),
81
- e.example ? (u(), f(o(de), {
81
+ t.example ? (c(), m(n(le), {
82
82
  key: 0,
83
- onClick: n,
83
+ onClick: o,
84
84
  type: "default",
85
85
  round: "",
86
86
  size: "large",
87
- icon: o(ae)
87
+ icon: n(se)
88
88
  }, {
89
- default: d(() => [
89
+ default: p(() => [
90
90
  N(" 加载示例项目 ")
91
91
  ]),
92
92
  _: 1
93
- }, 8, ["icon"])) : y("", !0)
93
+ }, 8, ["icon"])) : v("", !0)
94
94
  ])
95
95
  ])
96
96
  ]),
97
- In
97
+ Lo
98
98
  ]));
99
99
  }
100
100
  });
101
- const An = {
101
+ const Qo = {
102
102
  default: 14,
103
103
  small: 12,
104
104
  large: 18
105
- }, Dn = {
105
+ }, Zo = {
106
106
  icon: {
107
107
  type: [String, Object]
108
108
  },
@@ -116,46 +116,46 @@ const An = {
116
116
  src: {
117
117
  type: String
118
118
  }
119
- }, Vn = ["src"], te = /* @__PURE__ */ B({
119
+ }, Jo = ["src"], te = /* @__PURE__ */ E({
120
120
  name: "XIcon",
121
121
  __name: "Icon",
122
- props: Dn,
122
+ props: Zo,
123
123
  setup(a) {
124
- const e = a, t = Ge(), n = pe(), s = v(() => {
125
- if (!e.icon)
124
+ const t = a, e = st(), o = de(), s = h(() => {
125
+ if (!t.icon)
126
126
  return null;
127
- const c = n?.appContext.app;
128
- return typeof e.icon == "object" ? Pe(e.icon) : c?.component(e.icon) || e.icon;
129
- }), l = v(() => {
130
- const c = {
131
- "is-pointer": !!t.onClick
127
+ const u = o?.appContext.app;
128
+ return typeof t.icon == "object" ? ve(t.icon) : u?.component(t.icon) || t.icon;
129
+ }), i = h(() => {
130
+ const u = {
131
+ "is-pointer": !!e.onClick
132
132
  };
133
- return !s.value && e.icon && (c[e.icon] = !0), c;
134
- }), i = v(() => typeof e.size == "number" ? e.size : An[e.size] ?? void 0);
135
- return (c, r) => (u(), f(o(Pt), {
136
- class: U(["x-icon", l.value]),
137
- color: e.color,
138
- size: i.value
133
+ return !s.value && t.icon && (u[t.icon] = !0), u;
134
+ }), l = h(() => typeof t.size == "number" ? t.size : Qo[t.size] ?? void 0);
135
+ return (u, r) => (c(), m(n(Ot), {
136
+ class: W(["x-icon", i.value]),
137
+ color: t.color,
138
+ size: l.value
139
139
  }, {
140
- default: d(() => [
141
- z(c.$slots, "default", {}, () => [
142
- s.value ? (u(), f(Z(s.value), { key: 0 })) : y("", !0),
143
- e.src ? (u(), V("img", {
140
+ default: p(() => [
141
+ z(u.$slots, "default", {}, () => [
142
+ s.value ? (c(), m(L(s.value), { key: 0 })) : v("", !0),
143
+ t.src ? (c(), A("img", {
144
144
  key: 1,
145
- src: e.src
146
- }, null, 8, Vn)) : y("", !0)
145
+ src: t.src
146
+ }, null, 8, Jo)) : v("", !0)
147
147
  ])
148
148
  ]),
149
149
  _: 3
150
150
  }, 8, ["class", "color", "size"]));
151
151
  }
152
- }), Pn = { class: "x-menu__wrapper" }, $n = {
152
+ }), Go = { class: "x-menu__wrapper" }, Yo = {
153
153
  key: 1,
154
154
  class: "x-menu__title"
155
- }, Rn = /* @__PURE__ */ $("i", null, null, -1), Fn = {
155
+ }, qo = /* @__PURE__ */ O("i", null, null, -1), en = {
156
156
  key: 0,
157
157
  class: "x-menu__title"
158
- }, On = /* @__PURE__ */ $("i", null, null, -1), bt = /* @__PURE__ */ B({
158
+ }, tn = /* @__PURE__ */ O("i", null, null, -1), _t = /* @__PURE__ */ E({
159
159
  inheritAttrs: !1,
160
160
  name: "XMenuItem",
161
161
  __name: "MenuItem",
@@ -165,70 +165,70 @@ const An = {
165
165
  defaultIcon: { type: [Object, Function] }
166
166
  },
167
167
  setup(a) {
168
- const e = a, t = pe(), n = (i) => {
169
- if (i)
170
- return typeof i == "string" && (t?.appContext.app?.component(i) || e.defaultIcon) || i;
171
- }, s = (i) => typeof i == "object" ? i : { value: i }, l = (i = []) => i.filter((c) => !c.hidden);
172
- return (i, c) => e.item.children ? (u(), f(o($t), X({
168
+ const t = a, e = de(), o = (l) => {
169
+ if (l)
170
+ return typeof l == "string" && (e?.appContext.app?.component(l) || t.defaultIcon) || l;
171
+ }, s = (l) => typeof l == "object" ? l : { value: l }, i = (l = []) => l.filter((u) => !u.hidden);
172
+ return (l, u) => t.item.children ? (c(), m(n(jt), X({
173
173
  key: 0,
174
- disabled: e.item.disabled
175
- }, e.subMenu, {
176
- index: String(e.item.id)
174
+ disabled: t.item.disabled
175
+ }, t.subMenu, {
176
+ index: String(t.item.id)
177
177
  }), {
178
- title: d(() => [
179
- $("div", Pn, [
180
- e.item.icon ? (u(), f(o(te), {
178
+ title: p(() => [
179
+ O("div", Go, [
180
+ t.item.icon ? (c(), m(n(te), {
181
181
  key: 0,
182
- icon: n(e.item.icon)
183
- }, null, 8, ["icon"])) : y("", !0),
184
- e.item.title ? (u(), V("span", $n, O(e.item.title), 1)) : y("", !0),
185
- e.item.badge ? (u(), f(o(Ae), X({
182
+ icon: o(t.item.icon)
183
+ }, null, 8, ["icon"])) : v("", !0),
184
+ t.item.title ? (c(), A("span", Yo, j(t.item.title), 1)) : v("", !0),
185
+ t.item.badge ? (c(), m(n(Re), X({
186
186
  key: 2,
187
187
  class: "x-menu__badge"
188
- }, s(e.item.badge)), {
189
- default: d(() => [
190
- Rn
188
+ }, s(t.item.badge)), {
189
+ default: p(() => [
190
+ qo
191
191
  ]),
192
192
  _: 1
193
- }, 16)) : y("", !0)
193
+ }, 16)) : v("", !0)
194
194
  ])
195
195
  ]),
196
- default: d(() => [
197
- (u(!0), V(q, null, ke(l(e.item.children), (r) => (u(), f(o(bt), {
196
+ default: p(() => [
197
+ (c(!0), A(Q, null, ie(i(t.item.children), (r) => (c(), m(n(_t), {
198
198
  key: r.id,
199
199
  item: r,
200
- subMenu: e.subMenu,
201
- defaultIcon: e.defaultIcon
200
+ subMenu: t.subMenu,
201
+ defaultIcon: t.defaultIcon
202
202
  }, null, 8, ["item", "subMenu", "defaultIcon"]))), 128))
203
203
  ]),
204
204
  _: 1
205
- }, 16, ["disabled", "index"])) : (u(), f(o(Rt), {
205
+ }, 16, ["disabled", "index"])) : (c(), m(n(Nt), {
206
206
  key: 1,
207
- index: String(e.item.id),
208
- disabled: e.item.disabled
207
+ index: String(t.item.id),
208
+ disabled: t.item.disabled
209
209
  }, {
210
- title: d(() => [
211
- e.item.title ? (u(), V("span", Fn, O(e.item.title), 1)) : y("", !0),
212
- e.item.badge ? (u(), f(o(Ae), X({
210
+ title: p(() => [
211
+ t.item.title ? (c(), A("span", en, j(t.item.title), 1)) : v("", !0),
212
+ t.item.badge ? (c(), m(n(Re), X({
213
213
  key: 1,
214
214
  class: "x-menu__badge"
215
- }, s(e.item.badge)), {
216
- default: d(() => [
217
- On
215
+ }, s(t.item.badge)), {
216
+ default: p(() => [
217
+ tn
218
218
  ]),
219
219
  _: 1
220
- }, 16)) : y("", !0)
220
+ }, 16)) : v("", !0)
221
221
  ]),
222
- default: d(() => [
223
- e.item.icon ? (u(), f(o(te), {
222
+ default: p(() => [
223
+ t.item.icon ? (c(), m(n(te), {
224
224
  key: 0,
225
- icon: n(e.item.icon)
226
- }, null, 8, ["icon"])) : y("", !0)
225
+ icon: o(t.item.icon)
226
+ }, null, 8, ["icon"])) : v("", !0)
227
227
  ]),
228
228
  _: 1
229
229
  }, 8, ["index", "disabled"]));
230
230
  }
231
- }), G = /* @__PURE__ */ B({
231
+ }), ee = /* @__PURE__ */ E({
232
232
  inheritAttrs: !1,
233
233
  name: "XMenu",
234
234
  __name: "Menu",
@@ -238,36 +238,36 @@ const An = {
238
238
  defaultIcon: {}
239
239
  },
240
240
  emits: ["select"],
241
- setup(a, { emit: e }) {
242
- const t = a, n = v(() => t.data.filter((i) => !i.hidden)), s = (i, c) => {
243
- const r = (p, m = []) => {
244
- for (const h of m) {
245
- if (h.id.toString() === p.toString())
246
- return h;
247
- if (h.children?.length) {
248
- const k = r(p, h.children);
249
- if (k)
250
- return k;
241
+ setup(a, { emit: t }) {
242
+ const e = a, o = h(() => e.data.filter((l) => !l.hidden)), s = (l, u) => {
243
+ const r = (d, f = []) => {
244
+ for (const g of f) {
245
+ if (g.id.toString() === d.toString())
246
+ return g;
247
+ if (g.children?.length) {
248
+ const S = r(d, g.children);
249
+ if (S)
250
+ return S;
251
251
  }
252
252
  }
253
253
  };
254
- return r(c, i);
255
- }, l = (i) => {
256
- const c = s(n.value, i);
257
- c && e("select", c);
254
+ return r(u, l);
255
+ }, i = (l) => {
256
+ const u = s(o.value, l);
257
+ u && t("select", u);
258
258
  };
259
- return (i, c) => (u(), f(o(Ft), X({ class: "x-menu" }, i.$attrs, { onSelect: l }), {
260
- default: d(() => [
261
- (u(!0), V(q, null, ke(n.value, (r) => (u(), f(o(bt), {
262
- item: { ...r, icon: r.icon || o(rt) },
263
- defaultIcon: t.defaultIcon,
264
- subMenu: t.subMenu
259
+ return (l, u) => (c(), m(n(Xt), X({ class: "x-menu" }, l.$attrs, { onSelect: i }), {
260
+ default: p(() => [
261
+ (c(!0), A(Q, null, ie(o.value, (r) => (c(), m(n(_t), {
262
+ item: { ...r, icon: r.icon || n(dt) },
263
+ defaultIcon: e.defaultIcon,
264
+ subMenu: e.subMenu
265
265
  }, null, 8, ["item", "defaultIcon", "subMenu"]))), 256))
266
266
  ]),
267
267
  _: 1
268
268
  }, 16));
269
269
  }
270
- }), jn = { class: "x-simple-mask__brand" }, Nn = { class: "x-simple-mask__aciton" }, Xn = /* @__PURE__ */ B({
270
+ }), on = { class: "x-simple-mask__brand" }, nn = { class: "x-simple-mask__aciton" }, an = /* @__PURE__ */ E({
271
271
  name: "XSimpleMask",
272
272
  __name: "SimpleMask",
273
273
  props: {
@@ -278,54 +278,54 @@ const An = {
278
278
  }) },
279
279
  menu: {}
280
280
  },
281
- setup(a, { expose: e }) {
282
- const t = a, n = xe(), s = Fe(), l = v(() => s.params.id), i = () => {
283
- const r = t.project.home;
284
- r && n.push(r);
285
- }, c = (r) => {
286
- const p = r?.id;
287
- if (p) {
288
- const h = `${t.preview ? "/preview" : t.project.page}/${p}`;
289
- n.push(h);
281
+ setup(a, { expose: t }) {
282
+ const e = a, o = Ie(), s = Ue(), i = h(() => s.params.id), l = () => {
283
+ const r = e.project.home;
284
+ r && o.push(r);
285
+ }, u = (r) => {
286
+ const d = r?.id;
287
+ if (d) {
288
+ const g = `${e.preview ? "/preview" : e.project.page}/${d}`;
289
+ o.push(g);
290
290
  }
291
291
  };
292
- return e({
293
- goHome: i
294
- }), (r, p) => (u(), f(o(He), { class: "x-simple-mask" }, {
295
- default: d(() => [
296
- b(o(Ot), { class: "x-simple-mask__header" }, {
297
- default: d(() => [
298
- $("div", jn, [
299
- $("span", {
292
+ return t({
293
+ goHome: l
294
+ }), (r, d) => (c(), m(n(Ge), { class: "x-simple-mask" }, {
295
+ default: p(() => [
296
+ k(n(Ut), { class: "x-simple-mask__header" }, {
297
+ default: p(() => [
298
+ O("div", on, [
299
+ O("span", {
300
300
  class: "x-simple-mask__logo",
301
- onClick: i
301
+ onClick: l
302
302
  }, [
303
303
  z(r.$slots, "logo", {}, () => [
304
- N(O(t.project.name), 1)
304
+ N(j(e.project.name), 1)
305
305
  ])
306
306
  ])
307
307
  ]),
308
- $("div", Nn, [
308
+ O("div", nn, [
309
309
  z(r.$slots, "action")
310
310
  ])
311
311
  ]),
312
312
  _: 3
313
313
  }),
314
- b(o(He), null, {
315
- default: d(() => [
316
- b(o(jt), { class: "x-simple-mask__aside" }, {
317
- default: d(() => [
318
- b(o(G), X(t.menu, {
319
- "default-active": l.value,
320
- onSelect: c
314
+ k(n(Ge), null, {
315
+ default: p(() => [
316
+ k(n(Ht), { class: "x-simple-mask__aside" }, {
317
+ default: p(() => [
318
+ k(n(ee), X(e.menu, {
319
+ "default-active": i.value,
320
+ onSelect: u
321
321
  }), null, 16, ["default-active"])
322
322
  ]),
323
323
  _: 1
324
324
  }),
325
- b(o(Nt), { class: "x-simple-mask__main" }, {
326
- default: d(() => [
325
+ k(n(Wt), { class: "x-simple-mask__main" }, {
326
+ default: p(() => [
327
327
  z(r.$slots, "default", {}, () => [
328
- b(o(pt))
328
+ k(n(gt))
329
329
  ])
330
330
  ]),
331
331
  _: 3
@@ -333,21 +333,21 @@ const An = {
333
333
  ]),
334
334
  _: 3
335
335
  }),
336
- r.$slots.footer ? (u(), f(o(Xt), {
336
+ r.$slots.footer ? (c(), m(n(Lt), {
337
337
  key: 0,
338
338
  class: "x-simple-mask__footer",
339
339
  height: "40px"
340
340
  }, {
341
- default: d(() => [
341
+ default: p(() => [
342
342
  z(r.$slots, "footer")
343
343
  ]),
344
344
  _: 3
345
- })) : y("", !0)
345
+ })) : v("", !0)
346
346
  ]),
347
347
  _: 3
348
348
  }));
349
349
  }
350
- }), _t = {
350
+ }), kt = {
351
351
  /**
352
352
  * 动作名称标识
353
353
  */
@@ -443,132 +443,132 @@ const An = {
443
443
  type: Boolean
444
444
  }
445
445
  };
446
- function Un(a) {
447
- return v(() => {
448
- const e = a.tooltip;
449
- if (e)
450
- return typeof e == "string" ? { content: e } : e;
446
+ function sn(a) {
447
+ return h(() => {
448
+ const t = a.tooltip;
449
+ if (t)
450
+ return typeof t == "string" ? { content: t } : t;
451
451
  });
452
452
  }
453
- function Hn(a) {
454
- return v(() => {
455
- const e = a.badge;
456
- if (e)
457
- return typeof e == "object" ? e : { value: e };
453
+ function ln(a) {
454
+ return h(() => {
455
+ const t = a.badge;
456
+ if (t)
457
+ return typeof t == "object" ? t : { value: t };
458
458
  });
459
459
  }
460
- function Ln(a) {
461
- return v(() => {
462
- const { dropdown: e, menus: t } = a;
463
- if (t && t.length > 0)
460
+ function rn(a) {
461
+ return h(() => {
462
+ const { dropdown: t, menus: e } = a;
463
+ if (e && e.length > 0)
464
464
  return Object.assign(
465
465
  { popperClass: "x-action__menus", size: a.size },
466
- e || {}
466
+ t || {}
467
467
  );
468
468
  });
469
469
  }
470
- function Wn(a) {
471
- const e = pe();
472
- return v(() => {
473
- const t = o(a);
474
- if (t)
475
- if (typeof t == "string" || t.setup || t.render || Mt(t)) {
476
- const n = e?.appContext.app;
470
+ function cn(a) {
471
+ const t = de();
472
+ return h(() => {
473
+ const e = n(a);
474
+ if (e)
475
+ if (typeof e == "string" || e.setup || e.render || $t(e)) {
476
+ const o = t?.appContext.app;
477
477
  return {
478
- icon: typeof t == "string" && n?.component(t) || t
478
+ icon: typeof e == "string" && o?.component(e) || e
479
479
  };
480
480
  } else
481
- return t;
481
+ return e;
482
482
  return null;
483
483
  });
484
484
  }
485
- function we(a) {
486
- const e = Wn(a);
487
- return e.value ? Pe(B({ render: () => Y(te, e.value) })) : null;
485
+ function Ee(a) {
486
+ const t = cn(a);
487
+ return t.value ? ve(E({ render: () => q(te, t.value) })) : null;
488
488
  }
489
- function Oe(a, e) {
490
- return v(() => {
491
- const t = o(a);
492
- return typeof t == "function" ? t(e) : !!t;
489
+ function Le(a, t) {
490
+ return h(() => {
491
+ const e = n(a);
492
+ return typeof e == "function" ? e(t) : !!e;
493
493
  });
494
494
  }
495
- const Qn = { key: 0 }, Zn = /* @__PURE__ */ B({
495
+ const un = { key: 0 }, dn = /* @__PURE__ */ E({
496
496
  __name: "Trigger",
497
- props: _t,
497
+ props: kt,
498
498
  emits: ["click"],
499
- setup(a, { emit: e }) {
500
- const t = a, n = we(ve(t, "icon")), s = Oe(ve(t, "disabled")), l = v(() => ({
501
- [`is-${t.mode}`]: !!t.mode,
502
- [`is-${t.type}`]: !!t.type,
503
- [`is-${t.size}`]: !!t.size && t.size !== "default",
504
- [`is-background-${t.background}`]: t.mode === "icon" && !!t.background,
505
- "is-disabled": !!t.disabled,
506
- "is-circle": !!t.circle
507
- })), i = () => {
508
- e("click");
499
+ setup(a, { emit: t }) {
500
+ const e = a, o = Ee(ze(e, "icon")), s = Le(ze(e, "disabled")), i = h(() => ({
501
+ [`is-${e.mode}`]: !!e.mode,
502
+ [`is-${e.type}`]: !!e.type,
503
+ [`is-${e.size}`]: !!e.size && e.size !== "default",
504
+ [`is-background-${e.background}`]: e.mode === "icon" && !!e.background,
505
+ "is-disabled": !!e.disabled,
506
+ "is-circle": !!e.circle
507
+ })), l = () => {
508
+ t("click");
509
509
  };
510
- return (c, r) => t.mode === "button" ? (u(), f(o(de), X({
510
+ return (u, r) => e.mode === "button" ? (c(), m(n(le), X({
511
511
  key: 0,
512
- icon: o(n),
513
- type: t.type,
514
- size: t.size,
515
- disabled: o(s)
516
- }, t.button, { onClick: i }), {
517
- default: d(() => [
518
- N(O(c.label), 1)
512
+ icon: n(o),
513
+ type: e.type,
514
+ size: e.size,
515
+ disabled: n(s)
516
+ }, e.button, { onClick: l }), {
517
+ default: p(() => [
518
+ N(j(u.label), 1)
519
519
  ]),
520
520
  _: 1
521
- }, 16, ["icon", "type", "size", "disabled"])) : (u(), V("div", {
521
+ }, 16, ["icon", "type", "size", "disabled"])) : (c(), A("div", {
522
522
  key: 1,
523
- class: U(["x-action__inner", l.value]),
524
- onClick: i
523
+ class: W(["x-action__inner", i.value]),
524
+ onClick: l
525
525
  }, [
526
- (u(), f(Z(o(n)))),
527
- c.label ? (u(), V("span", Qn, O(c.label), 1)) : y("", !0)
526
+ (c(), m(L(n(o)))),
527
+ u.label ? (c(), A("span", un, j(u.label), 1)) : v("", !0)
528
528
  ], 2));
529
529
  }
530
- }), Q = /* @__PURE__ */ B({
530
+ }), J = /* @__PURE__ */ E({
531
531
  name: "XAction",
532
532
  __name: "Action",
533
- props: _t,
533
+ props: kt,
534
534
  emits: ["click", "command"],
535
- setup(a, { emit: e }) {
536
- const t = a, n = Et(), s = Un(t), l = Hn(t), i = Ln(t), c = Oe(ve(t, "disabled")), r = v(() => ({
537
- [`x-action--${t.mode}`]: !!t.mode
538
- })), p = () => {
539
- e("click", t);
540
- }, m = (w) => {
541
- const E = t.menus?.find((D) => D.command === w);
542
- E && e("command", E);
543
- }, h = (w) => Y(Ae, l.value, () => [].concat(w)), k = (w) => Y(
544
- Ut,
545
- { ...i.value, disabled: c.value, onCommand: m },
535
+ setup(a, { emit: t }) {
536
+ const e = a, o = Vt(), s = sn(e), i = ln(e), l = rn(e), u = Le(ze(e, "disabled")), r = h(() => ({
537
+ [`x-action--${e.mode}`]: !!e.mode
538
+ })), d = () => {
539
+ t("click", e);
540
+ }, f = (_) => {
541
+ const T = e.menus?.find((V) => V.command === _);
542
+ T && t("command", T);
543
+ }, g = (_) => q(Re, i.value, () => [].concat(_)), S = (_) => q(
544
+ Kt,
545
+ { ...l.value, disabled: u.value, onCommand: f },
546
546
  {
547
- default: () => [w],
547
+ default: () => [_],
548
548
  dropdown: () => [
549
- Y(
550
- Ht,
551
- () => (t.menus || []).map((E) => Y(
552
- Lt,
553
- E,
554
- () => n.item ? n.item({ item: E }) : E.label
549
+ q(
550
+ Qt,
551
+ () => (e.menus || []).map((T) => q(
552
+ Zt,
553
+ T,
554
+ () => o.item ? o.item({ item: T }) : T.label
555
555
  ))
556
556
  )
557
557
  ]
558
558
  }
559
- ), A = (w) => Y(st, { ...s.value, disabled: c.value }, () => [
560
- w
561
- ]), _ = v(() => {
562
- let w = n.default ? n.default()[0] : Y(Pe(Zn), { ...t, onClick: p });
563
- return l.value && (w = h(w)), i.value && (w = k(w)), s.value && (w = A(w)), w;
559
+ ), $ = (_) => q(ct, { ...s.value, disabled: u.value }, () => [
560
+ _
561
+ ]), w = h(() => {
562
+ let _ = o.default ? o.default()[0] : q(ve(dn), { ...e, onClick: d });
563
+ return i.value && (_ = g(_)), l.value && (_ = S(_)), s.value && (_ = $(_)), _;
564
564
  });
565
- return (w, E) => (u(), V("div", {
566
- class: U(["x-action", r.value])
565
+ return (_, T) => (c(), A("div", {
566
+ class: W(["x-action", r.value])
567
567
  }, [
568
- (u(), f(Z(_.value)))
568
+ (c(), m(L(w.value)))
569
569
  ], 2));
570
570
  }
571
- }), Jn = {
571
+ }), pn = {
572
572
  /**
573
573
  * 动作项
574
574
  */
@@ -639,57 +639,57 @@ const Qn = { key: 0 }, Zn = /* @__PURE__ */ B({
639
639
  button: {
640
640
  type: Object
641
641
  }
642
- }, je = /* @__PURE__ */ B({
642
+ }, Ke = /* @__PURE__ */ E({
643
643
  name: "XActionBar",
644
644
  __name: "ActionBar",
645
- props: Jn,
645
+ props: pn,
646
646
  emits: ["click", "command"],
647
- setup(a, { emit: e }) {
648
- const t = a, n = v(() => (t.items || []).map((i) => i === "|" ? i : {
649
- ...i,
650
- badge: i.badge ? {
651
- ...t.badge,
652
- ...typeof i.badge == "object" ? i.badge || {} : { value: i.badge }
647
+ setup(a, { emit: t }) {
648
+ const e = a, o = h(() => (e.items || []).map((l) => l === "|" ? l : {
649
+ ...l,
650
+ badge: l.badge ? {
651
+ ...e.badge,
652
+ ...typeof l.badge == "object" ? l.badge || {} : { value: l.badge }
653
653
  } : void 0,
654
- tooltip: i.tooltip ? {
655
- ...t.tooltip,
656
- ...typeof i.tooltip == "object" ? i.tooltip || {} : { content: i.tooltip }
654
+ tooltip: l.tooltip ? {
655
+ ...e.tooltip,
656
+ ...typeof l.tooltip == "object" ? l.tooltip || {} : { content: l.tooltip }
657
657
  } : void 0
658
- })), s = (i) => {
659
- e("click", i);
660
- }, l = (i, c) => {
661
- e("command", i, c);
658
+ })), s = (l) => {
659
+ t("click", l);
660
+ }, i = (l, u) => {
661
+ t("command", l, u);
662
662
  };
663
- return (i, c) => (u(), f(o(M), {
663
+ return (l, u) => (c(), m(n(I), {
664
664
  class: "x-action-bar",
665
665
  align: "center"
666
666
  }, {
667
- default: d(() => [
668
- (u(!0), V(q, null, ke(n.value, (r) => (u(), V(q, null, [
669
- r === "|" ? (u(), f(o(ue), {
667
+ default: p(() => [
668
+ (c(!0), A(Q, null, ie(o.value, (r) => (c(), A(Q, null, [
669
+ r === "|" ? (c(), m(n(ge), {
670
670
  key: 0,
671
671
  direction: "vertical",
672
672
  class: "x-action-bar__divider"
673
- })) : (u(), f(o(Q), X({
673
+ })) : (c(), m(n(J), X({
674
674
  key: 1,
675
- mode: t.mode,
676
- size: t.size,
677
- type: t.type,
678
- circle: t.circle,
679
- background: t.background,
680
- button: t.button,
681
- dropdown: t.dropdown,
682
- disabled: o(Oe)(t.disabled, r).value
675
+ mode: e.mode,
676
+ size: e.size,
677
+ type: e.type,
678
+ circle: e.circle,
679
+ background: e.background,
680
+ button: e.button,
681
+ dropdown: e.dropdown,
682
+ disabled: n(Le)(e.disabled, r).value
683
683
  }, r, {
684
684
  onClick: s,
685
- onCommand: (p) => l(r, p)
685
+ onCommand: (d) => i(r, d)
686
686
  }), null, 16, ["mode", "size", "type", "circle", "background", "button", "dropdown", "disabled", "onCommand"]))
687
687
  ], 64))), 256))
688
688
  ]),
689
689
  _: 1
690
690
  }));
691
691
  }
692
- }), Kn = {
692
+ }), fn = {
693
693
  /**
694
694
  * 组件渲染html标签
695
695
  */
@@ -798,49 +798,49 @@ const Qn = { key: 0 }, Zn = /* @__PURE__ */ B({
798
798
  type: Boolean,
799
799
  default: !1
800
800
  }
801
- }, M = /* @__PURE__ */ B({
801
+ }, I = /* @__PURE__ */ E({
802
802
  name: "XContainer",
803
803
  __name: "Container",
804
- props: Kn,
804
+ props: fn,
805
805
  setup(a) {
806
- const e = a, t = pe(), n = v(() => {
807
- const i = t?.parent;
808
- if (!i)
806
+ const t = a, e = de(), o = h(() => {
807
+ const l = e?.parent;
808
+ if (!l)
809
809
  return !1;
810
- const c = i.proxy;
811
- return c.$options.name === "XContainer" || !!c.flex;
812
- }), s = v(() => ({
813
- "is-fit": e.fit,
814
- "is-flex": e.flex && !e.inline,
815
- "is-inline-flex": e.flex && e.inline,
816
- [`is-direction-${e.direction}`]: e.flex && e.direction !== "row",
817
- [`is-wrap-${e.wrap}`]: e.flex && e.wrap !== "nowrap",
818
- [`is-justify-${e.justify}`]: e.flex && e.justify !== "flex-start",
819
- [`is-align-${e.align}`]: e.flex && e.align !== "flex-start",
820
- [`is-align-content-${e.alignContent}`]: e.flex && e.alignContent !== "stretch",
821
- "is-grow": e.grow ?? n.value,
822
- "is-shrink": n.value && e.shrink,
823
- [`is-align-self-${e.alignSelf}`]: n.value && e.alignSelf !== "auto",
824
- [`is-overflow-${e.overflow}`]: !!e.overflow,
825
- "is-padding": !!e.padding
826
- })), l = v(() => {
827
- const { width: i, height: c, fit: r } = e;
810
+ const u = l.proxy;
811
+ return u.$options.name === "XContainer" || !!u.flex;
812
+ }), s = h(() => ({
813
+ "is-fit": t.fit,
814
+ "is-flex": t.flex && !t.inline,
815
+ "is-inline-flex": t.flex && t.inline,
816
+ [`is-direction-${t.direction}`]: t.flex && t.direction !== "row",
817
+ [`is-wrap-${t.wrap}`]: t.flex && t.wrap !== "nowrap",
818
+ [`is-justify-${t.justify}`]: t.flex && t.justify !== "flex-start",
819
+ [`is-align-${t.align}`]: t.flex && t.align !== "flex-start",
820
+ [`is-align-content-${t.alignContent}`]: t.flex && t.alignContent !== "stretch",
821
+ "is-grow": t.grow ?? o.value,
822
+ "is-shrink": o.value && t.shrink,
823
+ [`is-align-self-${t.alignSelf}`]: o.value && t.alignSelf !== "auto",
824
+ [`is-overflow-${t.overflow}`]: !!t.overflow,
825
+ "is-padding": !!t.padding
826
+ })), i = h(() => {
827
+ const { width: l, height: u, fit: r } = t;
828
828
  return r ? null : {
829
- width: i ? We(i) : void 0,
830
- height: c ? We(c) : void 0
829
+ width: l ? je(l) : void 0,
830
+ height: u ? je(u) : void 0
831
831
  };
832
832
  });
833
- return (i, c) => (u(), f(Z(e.tag), {
834
- class: U(["x-container", s.value]),
835
- style: be(l.value)
833
+ return (l, u) => (c(), m(L(t.tag), {
834
+ class: W(["x-container", s.value]),
835
+ style: Ce(i.value)
836
836
  }, {
837
- default: d(() => [
838
- z(i.$slots, "default")
837
+ default: p(() => [
838
+ z(l.$slots, "default")
839
839
  ]),
840
840
  _: 3
841
841
  }, 8, ["class", "style"]));
842
842
  }
843
- }), Yn = {
843
+ }), mn = {
844
844
  size: {
845
845
  type: String,
846
846
  default: "default"
@@ -861,65 +861,65 @@ const Qn = { key: 0 }, Zn = /* @__PURE__ */ B({
861
861
  more: {
862
862
  type: Boolean
863
863
  }
864
- }, Gn = {
864
+ }, gn = {
865
865
  key: 2,
866
866
  class: "x-header__subtitle"
867
- }, qn = {
867
+ }, yn = {
868
868
  key: 0,
869
869
  class: "x-header__actions"
870
- }, wt = /* @__PURE__ */ B({
870
+ }, wt = /* @__PURE__ */ E({
871
871
  name: "XHeader",
872
872
  inheritAttrs: !1,
873
873
  __name: "Header",
874
- props: Yn,
874
+ props: mn,
875
875
  setup(a) {
876
- const e = a, t = Ge(), n = we(ve(e, "icon")), s = v(() => ({
877
- [`is-size-${e.size}`]: !!e.size && e.size !== "default",
878
- "is-border": e.border,
879
- "is-pointer": !!t.onClick
876
+ const t = a, e = st(), o = Ee(ze(t, "icon")), s = h(() => ({
877
+ [`is-size-${t.size}`]: !!t.size && t.size !== "default",
878
+ "is-border": t.border,
879
+ "is-pointer": !!e.onClick
880
880
  }));
881
- return (l, i) => (u(), f(o(M), {
882
- class: U(["x-header", s.value]),
881
+ return (i, l) => (c(), m(n(I), {
882
+ class: W(["x-header", s.value]),
883
883
  justify: "space-between",
884
884
  align: "center"
885
885
  }, {
886
- default: d(() => [
887
- b(o(M), {
886
+ default: p(() => [
887
+ k(n(I), {
888
888
  align: "center",
889
- class: U(["x-header__wrapper", s.value]),
889
+ class: W(["x-header__wrapper", s.value]),
890
890
  grow: ""
891
891
  }, {
892
- default: d(() => [
893
- o(n) ? (u(), f(Z(o(n)), {
892
+ default: p(() => [
893
+ n(o) ? (c(), m(L(n(o)), {
894
894
  key: 0,
895
895
  class: "x-header__icon"
896
- })) : y("", !0),
897
- $("span", X({ class: "x-header__content" }, l.$attrs), [
898
- z(l.$slots, "default", {}, () => [
899
- N(O(e.content), 1)
896
+ })) : v("", !0),
897
+ O("span", X({ class: "x-header__content" }, i.$attrs), [
898
+ z(i.$slots, "default", {}, () => [
899
+ N(j(t.content), 1)
900
900
  ])
901
901
  ], 16),
902
- e.more ? (u(), f(o(te), {
902
+ t.more ? (c(), m(n(te), {
903
903
  key: 1,
904
904
  class: "x-header__more",
905
- icon: o(tn)
906
- }, null, 8, ["icon"])) : y("", !0),
907
- e.subtitle || l.$slots.subtitle ? (u(), V("span", Gn, [
908
- z(l.$slots, "subtitle", {}, () => [
909
- N(O(e.subtitle), 1)
905
+ icon: n(ho)
906
+ }, null, 8, ["icon"])) : v("", !0),
907
+ t.subtitle || i.$slots.subtitle ? (c(), A("span", gn, [
908
+ z(i.$slots, "subtitle", {}, () => [
909
+ N(j(t.subtitle), 1)
910
910
  ])
911
- ])) : y("", !0)
911
+ ])) : v("", !0)
912
912
  ]),
913
913
  _: 3
914
914
  }, 8, ["class"]),
915
- l.$slots.actions ? (u(), V("div", qn, [
916
- z(l.$slots, "actions")
917
- ])) : y("", !0)
915
+ i.$slots.actions ? (c(), A("div", yn, [
916
+ z(i.$slots, "actions")
917
+ ])) : v("", !0)
918
918
  ]),
919
919
  _: 3
920
920
  }, 8, ["class"]));
921
921
  }
922
- }), eo = {
922
+ }), hn = {
923
923
  /**
924
924
  * 宽高自适应
925
925
  */
@@ -991,254 +991,254 @@ const Qn = { key: 0 }, Zn = /* @__PURE__ */ B({
991
991
  footer: {
992
992
  type: Object
993
993
  }
994
- }, kt = /* @__PURE__ */ B({
994
+ }, xt = /* @__PURE__ */ E({
995
995
  name: "XPanel",
996
996
  __name: "Panel",
997
- props: eo,
998
- setup(a, { expose: e }) {
999
- const t = a, n = R(), s = v(() => ({
1000
- "x-panel--card": !!t.card,
1001
- "x-panel--default": !t.card,
1002
- [`is-${t.size}`]: !!t.size && t.size !== "default",
1003
- "is-border": !!t.border,
1004
- "is-radius": !!t.radius,
1005
- [`is-shadow-${t.shadow}`]: !!t.shadow && t.shadow !== "none"
1006
- })), l = v(() => t.header === null ? null : typeof t.header == "string" ? {
1007
- content: t.header,
1008
- size: t.size
997
+ props: hn,
998
+ setup(a, { expose: t }) {
999
+ const e = a, o = P(), s = h(() => ({
1000
+ "x-panel--card": !!e.card,
1001
+ "x-panel--default": !e.card,
1002
+ [`is-${e.size}`]: !!e.size && e.size !== "default",
1003
+ "is-border": !!e.border,
1004
+ "is-radius": !!e.radius,
1005
+ [`is-shadow-${e.shadow}`]: !!e.shadow && e.shadow !== "none"
1006
+ })), i = h(() => e.header === null ? null : typeof e.header == "string" ? {
1007
+ content: e.header,
1008
+ size: e.size
1009
1009
  } : {
1010
- ...t.header,
1011
- size: t.size
1012
- }), i = v(() => t.fit || t.height ? "auto" : void 0);
1013
- return e({
1014
- bodyRef: n
1015
- }), (c, r) => (u(), f(o(M), {
1016
- class: U(["x-panel", s.value]),
1010
+ ...e.header,
1011
+ size: e.size
1012
+ }), l = h(() => e.fit || e.height ? "auto" : void 0);
1013
+ return t({
1014
+ bodyRef: o
1015
+ }), (u, r) => (c(), m(n(I), {
1016
+ class: W(["x-panel", s.value]),
1017
1017
  direction: "column",
1018
- fit: t.fit,
1019
- width: t.width,
1020
- height: t.height
1018
+ fit: e.fit,
1019
+ width: e.width,
1020
+ height: e.height
1021
1021
  }, {
1022
- default: d(() => [
1023
- l.value ? (u(), f(o(M), {
1022
+ default: p(() => [
1023
+ i.value ? (c(), m(n(I), {
1024
1024
  key: 0,
1025
1025
  flex: !1,
1026
1026
  class: "x-panel__header"
1027
1027
  }, {
1028
- default: d(() => [
1029
- z(c.$slots, "header", {}, () => [
1030
- b(o(wt), qe(et(l.value)), {
1031
- default: d(() => [
1032
- z(c.$slots, "title")
1028
+ default: p(() => [
1029
+ z(u.$slots, "header", {}, () => [
1030
+ k(n(wt), Me(Be(i.value)), {
1031
+ default: p(() => [
1032
+ z(u.$slots, "title")
1033
1033
  ]),
1034
- actions: d(() => [
1035
- z(c.$slots, "actions")
1034
+ actions: p(() => [
1035
+ z(u.$slots, "actions")
1036
1036
  ]),
1037
1037
  _: 3
1038
1038
  }, 16)
1039
1039
  ])
1040
1040
  ]),
1041
1041
  _: 3
1042
- })) : y("", !0),
1043
- b(o(M), X({
1042
+ })) : v("", !0),
1043
+ k(n(I), X({
1044
1044
  ref_key: "bodyRef",
1045
- ref: n,
1045
+ ref: o,
1046
1046
  flex: !1,
1047
- overflow: i.value,
1047
+ overflow: l.value,
1048
1048
  grow: "",
1049
1049
  padding: "",
1050
1050
  class: "x-panel__body"
1051
- }, t.body), {
1052
- default: d(() => [
1053
- z(c.$slots, "default")
1051
+ }, e.body), {
1052
+ default: p(() => [
1053
+ z(u.$slots, "default")
1054
1054
  ]),
1055
1055
  _: 3
1056
1056
  }, 16, ["overflow"]),
1057
- c.$slots.footer ? (u(), f(o(M), X({
1057
+ u.$slots.footer ? (c(), m(n(I), X({
1058
1058
  key: 1,
1059
1059
  flex: !1,
1060
1060
  padding: "",
1061
1061
  class: "x-panel__footer"
1062
- }, t.footer), {
1063
- default: d(() => [
1064
- z(c.$slots, "footer")
1062
+ }, e.footer), {
1063
+ default: p(() => [
1064
+ z(u.$slots, "footer")
1065
1065
  ]),
1066
1066
  _: 3
1067
- }, 16)) : y("", !0)
1067
+ }, 16)) : v("", !0)
1068
1068
  ]),
1069
1069
  _: 3
1070
1070
  }, 8, ["class", "fit", "width", "height"]));
1071
1071
  }
1072
- }), Ze = "user-select-none";
1073
- class Je {
1074
- constructor(e, t = {}) {
1075
- this.el = e, this.options = t, this.scope = tt(), this.scope.run(() => {
1072
+ }), tt = "user-select-none";
1073
+ class ot {
1074
+ constructor(t, e = {}) {
1075
+ this.el = t, this.options = e, this.scope = lt(), this.scope.run(() => {
1076
1076
  this.init();
1077
1077
  });
1078
1078
  }
1079
1079
  scope;
1080
1080
  dragging = !1;
1081
1081
  getHandle() {
1082
- const { selector: e, handle: t } = this.options;
1083
- return e ? this.el.querySelector(e) : t;
1082
+ const { selector: t, handle: e } = this.options;
1083
+ return t ? this.el.querySelector(t) : e;
1084
1084
  }
1085
1085
  getTarget() {
1086
- const { target: e = "body" } = this.options;
1087
- return typeof e == "string" ? document.querySelector(e) : o(e) || document.body;
1086
+ const { target: t = "body" } = this.options;
1087
+ return typeof t == "string" ? document.querySelector(t) : n(t) || document.body;
1088
1088
  }
1089
1089
  init() {
1090
- const { el: e, options: t } = this, { disabled: n, delay: s = 150, onStart: l, onEnd: i } = t;
1091
- if (n)
1090
+ const { el: t, options: e } = this, { disabled: o, delay: s = 150, onStart: i, onEnd: l } = e;
1091
+ if (o)
1092
1092
  return;
1093
- let c = null;
1094
- const r = this.getHandle(), p = this.getTarget();
1095
- let m = e.getBoundingClientRect(), h = null;
1096
- const { x: k, y: A } = vn(e, {
1097
- initialValue: { x: m.x, y: m.y },
1098
- ...t,
1093
+ let u = null;
1094
+ const r = this.getHandle(), d = this.getTarget();
1095
+ let f = t.getBoundingClientRect(), g = null;
1096
+ const { x: S, y: $ } = $o(t, {
1097
+ initialValue: { x: f.x, y: f.y },
1098
+ ...e,
1099
1099
  handle: r,
1100
- onStart: (_, w) => {
1101
- document.body.classList.add(Ze), clearTimeout(c), c = setTimeout(() => {
1102
- this.dragging = !0, m = e.getBoundingClientRect(), h = p?.getBoundingClientRect(), l && l(_, w);
1100
+ onStart: (w, _) => {
1101
+ document.body.classList.add(tt), clearTimeout(u), u = setTimeout(() => {
1102
+ this.dragging = !0, f = t.getBoundingClientRect(), g = d?.getBoundingClientRect(), i && i(w, _);
1103
1103
  }, s);
1104
1104
  },
1105
- onEnd: (_, w) => {
1106
- if (clearTimeout(c), document.body.classList.remove(Ze), this.dragging && h) {
1105
+ onEnd: (w, _) => {
1106
+ if (clearTimeout(u), document.body.classList.remove(tt), this.dragging && g) {
1107
1107
  this.dragging = !1;
1108
- const { x: E, y: D } = _, g = this.getPosition(h, m, E, D);
1109
- i && i(g, w), h = null;
1108
+ const { x: T, y: V } = w, y = this.getPosition(g, f, T, V);
1109
+ l && l(y, _), g = null;
1110
1110
  }
1111
1111
  }
1112
1112
  });
1113
- ee([k, A], () => {
1114
- if (this.dragging && h) {
1115
- const _ = this.getPosition(h, m, k.value, A.value);
1116
- e.style.left = `${_.x}px`, e.style.top = `${_.y}px`;
1113
+ H([S, $], () => {
1114
+ if (this.dragging && g) {
1115
+ const w = this.getPosition(g, f, S.value, $.value);
1116
+ t.style.left = `${w.x}px`, t.style.top = `${w.y}px`;
1117
1117
  }
1118
1118
  });
1119
1119
  }
1120
- getPosition(e, t, n, s) {
1121
- const { edge: l = 50 } = this.options, i = -t.width + l, c = e.width - l, r = 0, p = e.height - l, m = Math.min(c, Math.max(n, i)), h = Math.min(p, Math.max(s, r));
1120
+ getPosition(t, e, o, s) {
1121
+ const { edge: i = 50 } = this.options, l = -e.width + i, u = t.width - i, r = 0, d = t.height - i, f = Math.min(u, Math.max(o, l)), g = Math.min(d, Math.max(s, r));
1122
1122
  return {
1123
- x: m,
1124
- y: h
1123
+ x: f,
1124
+ y: g
1125
1125
  };
1126
1126
  }
1127
1127
  destory() {
1128
1128
  this.scope.stop();
1129
1129
  }
1130
1130
  }
1131
- const to = {
1132
- mounted(a, e) {
1133
- const t = e.value || {}, n = new Je(a, t);
1134
- a.__draggable__ = n;
1131
+ const vn = {
1132
+ mounted(a, t) {
1133
+ const e = t.value || {}, o = new ot(a, e);
1134
+ a.__draggable__ = o;
1135
1135
  },
1136
- updated(a, e) {
1137
- const t = e.value || {};
1138
- let n = a.__draggable__;
1139
- n && !mt(n.options, t) && (n.destory(), a.__draggable__ = new Je(a, t));
1136
+ updated(a, t) {
1137
+ const e = t.value || {};
1138
+ let o = a.__draggable__;
1139
+ o && !He(o.options, e) && (o.destory(), a.__draggable__ = new ot(a, e));
1140
1140
  },
1141
1141
  unmounted(a) {
1142
- const e = a.__draggable__;
1143
- e && (e.destory(), a.__draggable__ = null);
1142
+ const t = a.__draggable__;
1143
+ t && (t.destory(), a.__draggable__ = null);
1144
1144
  }
1145
- }, Ee = "user-select-none";
1146
- class Ke {
1147
- constructor(e, t = {}) {
1148
- this.el = e, this.options = t, this.scope = tt(), this.scope.run(() => {
1145
+ }, Pe = "user-select-none";
1146
+ class nt {
1147
+ constructor(t, e = {}) {
1148
+ this.el = t, this.options = e, this.scope = lt(), this.scope.run(() => {
1149
1149
  this.init();
1150
1150
  });
1151
1151
  }
1152
1152
  scope;
1153
- resizing = R(!1);
1154
- direction = R("");
1153
+ resizing = P(!1);
1154
+ direction = P("");
1155
1155
  MIE = null;
1156
1156
  cleanMousedown;
1157
1157
  cleanMouseup;
1158
1158
  init() {
1159
- const { el: e, options: t } = this, { disabled: n, onStart: s, onEnd: l } = t;
1160
- if (n)
1159
+ const { el: t, options: e } = this, { disabled: o, onStart: s, onEnd: i } = e;
1160
+ if (o)
1161
1161
  return;
1162
- this.MIE = bn(e), this.cleanMousedown = _e(document, "mousedown", () => {
1163
- this.direction?.value && this.MIE && (this.resizing.value = !0, e.classList.add("is-resizing", `is-${this.direction.value}-resizing`), s && s(this.direction.value, this.MIE));
1164
- }), this.cleanMouseup = _e(document, "mouseup", () => {
1165
- this.resizing.value && this.direction?.value && this.MIE && (e.classList.remove(
1162
+ this.MIE = Vo(t), this.cleanMousedown = Te(document, "mousedown", () => {
1163
+ this.direction?.value && this.MIE && (this.resizing.value = !0, t.classList.add("is-resizing", `is-${this.direction.value}-resizing`), s && s(this.direction.value, this.MIE));
1164
+ }), this.cleanMouseup = Te(document, "mouseup", () => {
1165
+ this.resizing.value && this.direction?.value && this.MIE && (t.classList.remove(
1166
1166
  "is-resizing",
1167
1167
  `is-${this.direction.value}-resizing`
1168
- ), l && l(this.direction.value, this.MIE)), this.resizing.value = !1;
1169
- }), ee(this.direction, (r) => {
1170
- const p = document.body;
1171
- p.style.cursor = r ? `${r}-resize` : "", r ? p.classList.add(Ee) : p.classList.remove(Ee);
1168
+ ), i && i(this.direction.value, this.MIE)), this.resizing.value = !1;
1169
+ }), H(this.direction, (r) => {
1170
+ const d = document.body;
1171
+ d.style.cursor = r ? `${r}-resize` : "", r ? d.classList.add(Pe) : d.classList.remove(Pe);
1172
1172
  });
1173
- const { x: i, y: c } = this.MIE;
1174
- ee([i, c], () => {
1173
+ const { x: l, y: u } = this.MIE;
1174
+ H([l, u], () => {
1175
1175
  this.resizing.value ? this.resize() : this.direction.value = this.getDirection();
1176
1176
  });
1177
1177
  }
1178
1178
  resize() {
1179
- const { MIE: e, direction: t, resizing: n, options: s, el: l } = this, i = t?.value || "";
1180
- if (!e || !n.value || !i)
1179
+ const { MIE: t, direction: e, resizing: o, options: s, el: i } = this, l = e?.value || "";
1180
+ if (!t || !o.value || !l)
1181
1181
  return;
1182
- const { x: c, y: r, elementX: p, elementY: m, elementHeight: h, elementWidth: k } = e, { onResizing: A } = s, {
1183
- minWidth: _ = 0,
1184
- minHeight: w = 0,
1185
- maxWidth: E = 99999,
1186
- maxHeight: D = 99999
1182
+ const { x: u, y: r, elementX: d, elementY: f, elementHeight: g, elementWidth: S } = t, { onResizing: $ } = s, {
1183
+ minWidth: w = 0,
1184
+ minHeight: _ = 0,
1185
+ maxWidth: T = 99999,
1186
+ maxHeight: V = 99999
1187
1187
  } = s;
1188
- if (i.includes("e")) {
1189
- const g = Math.min(Math.max(p.value, _), E);
1190
- l.style.width = `${g}px`;
1188
+ if (l.includes("e")) {
1189
+ const y = Math.min(Math.max(d.value, w), T);
1190
+ i.style.width = `${y}px`;
1191
1191
  }
1192
- if (i.includes("s")) {
1193
- const g = Math.min(Math.max(m.value, w), D);
1194
- l.style.height = `${g}px`;
1192
+ if (l.includes("s")) {
1193
+ const y = Math.min(Math.max(f.value, _), V);
1194
+ i.style.height = `${y}px`;
1195
1195
  }
1196
- if (i.includes("w")) {
1197
- const g = Math.min(
1198
- Math.max(k.value - p.value, _),
1199
- E
1196
+ if (l.includes("w")) {
1197
+ const y = Math.min(
1198
+ Math.max(S.value - d.value, w),
1199
+ T
1200
1200
  );
1201
- l.style.width = `${g}px`, l.style.left = `${c.value}px`;
1201
+ i.style.width = `${y}px`, i.style.left = `${u.value}px`;
1202
1202
  }
1203
- if (i.includes("n")) {
1204
- const g = Math.min(
1205
- Math.max(h.value - m.value, w),
1206
- D
1203
+ if (l.includes("n")) {
1204
+ const y = Math.min(
1205
+ Math.max(g.value - f.value, _),
1206
+ V
1207
1207
  );
1208
- this.el.style.height = `${g}px`, this.el.style.top = `${r.value}px`;
1208
+ this.el.style.height = `${y}px`, this.el.style.top = `${r.value}px`;
1209
1209
  }
1210
- A && A(i, e);
1210
+ $ && $(l, t);
1211
1211
  }
1212
1212
  getDirection() {
1213
1213
  if (!this.MIE)
1214
1214
  return "";
1215
- const { elementX: e, elementY: t, elementHeight: n, elementWidth: s, isOutside: l } = this.MIE;
1216
- if (l.value)
1215
+ const { elementX: t, elementY: e, elementHeight: o, elementWidth: s, isOutside: i } = this.MIE;
1216
+ if (i.value)
1217
1217
  return "";
1218
- const { dirs: i = ["n", "s", "w", "e"], edge: c = 5 } = this.options;
1218
+ const { dirs: l = ["n", "s", "w", "e"], edge: u = 5 } = this.options;
1219
1219
  let r = "";
1220
- return i.includes("n") && t.value <= c ? r += "n" : i.includes("s") && t.value > n.value - c && (r += "s"), i.includes("w") && e.value <= c ? r += "w" : i.includes("e") && e.value > s.value - c && (r += "e"), r;
1220
+ return l.includes("n") && e.value <= u ? r += "n" : l.includes("s") && e.value > o.value - u && (r += "s"), l.includes("w") && t.value <= u ? r += "w" : l.includes("e") && t.value > s.value - u && (r += "e"), r;
1221
1221
  }
1222
1222
  destory() {
1223
- const e = document.body;
1224
- e.style.cursor = "", e.classList.remove(Ee), this.cleanMousedown && this.cleanMousedown(), this.cleanMouseup && this.cleanMouseup(), this.MIE?.stop(), this.scope.stop();
1223
+ const t = document.body;
1224
+ t.style.cursor = "", t.classList.remove(Pe), this.cleanMousedown && this.cleanMousedown(), this.cleanMouseup && this.cleanMouseup(), this.MIE?.stop(), this.scope.stop();
1225
1225
  }
1226
1226
  }
1227
- const xt = {
1228
- mounted(a, e) {
1229
- const t = e.value || {}, n = new Ke(a, t);
1230
- a.__resizable__ = n;
1227
+ const St = {
1228
+ mounted(a, t) {
1229
+ const e = t.value || {}, o = new nt(a, e);
1230
+ a.__resizable__ = o;
1231
1231
  },
1232
- updated(a, e) {
1233
- const t = e.value || {};
1234
- let n = a.__resizable__;
1235
- n && !mt(n.options, t) && (n.destory(), a.__resizable__ = new Ke(a, t));
1232
+ updated(a, t) {
1233
+ const e = t.value || {};
1234
+ let o = a.__resizable__;
1235
+ o && !He(o.options, e) && (o.destory(), a.__resizable__ = new nt(a, e));
1236
1236
  },
1237
1237
  unmounted(a) {
1238
- const e = a.__resizable__;
1239
- e && (e.destory(), a.__resizable__ = null);
1238
+ const t = a.__resizable__;
1239
+ t && (t.destory(), a.__resizable__ = null);
1240
1240
  }
1241
- }, no = {
1241
+ }, bn = {
1242
1242
  modelValue: {
1243
1243
  type: Boolean,
1244
1244
  default: !0
@@ -1323,9 +1323,9 @@ const xt = {
1323
1323
  type: Boolean
1324
1324
  }
1325
1325
  };
1326
- let ie = 1e3;
1327
- function oo(a, e) {
1328
- const { width: t, height: n } = ft(e), s = nt({
1326
+ let ue = 1e3;
1327
+ function _n(a, t) {
1328
+ const { width: e, height: o } = yt(t), s = Ne({
1329
1329
  mode: a.mode || "normal",
1330
1330
  wrapperWidth: 0,
1331
1331
  wrapperHeight: 0,
@@ -1333,271 +1333,274 @@ function oo(a, e) {
1333
1333
  height: 0,
1334
1334
  top: 0,
1335
1335
  left: 0,
1336
- zIndex: ++ie,
1336
+ zIndex: ++ue,
1337
1337
  dragging: !1,
1338
1338
  resizing: !1
1339
1339
  });
1340
- return ee([t, n], ([l, i]) => {
1341
- s.wrapperWidth = l, s.wrapperHeight = i, s.width = me(a.width, l), s.height = me(a.height, i), s.left = a.left ? me(a.left, l) - s.width / 2 : Math.max(Math.floor((l - s.width) / 2), 0), s.top = a.top ? me(a.top, i) : Math.max(Math.floor((i - s.height) / 2), 0);
1342
- }), ee(s, (l) => {
1343
- ie = Math.max(l.zIndex, ie);
1340
+ return H([e, o], ([i, l]) => {
1341
+ s.wrapperWidth = i, s.wrapperHeight = l, s.width = _e(a.width, i), s.height = _e(a.height, l), s.left = a.left ? _e(a.left, i) - s.width / 2 : Math.max(Math.floor((i - s.width) / 2), 0), s.top = a.top ? _e(a.top, l) : Math.max(Math.floor((l - s.height) / 2), 0);
1342
+ }), H(s, (i) => {
1343
+ ue = Math.max(i.zIndex, ue);
1344
1344
  }), {
1345
1345
  state: s,
1346
- normal: v(() => s.mode === "normal"),
1347
- maximized: v(() => s.mode === "maximized"),
1348
- minimized: v(() => s.mode === "minimized")
1346
+ normal: h(() => s.mode === "normal"),
1347
+ maximized: h(() => s.mode === "maximized"),
1348
+ minimized: h(() => s.mode === "minimized")
1349
1349
  };
1350
1350
  }
1351
- function ao(a, e) {
1352
- const t = v(() => {
1353
- const { width: i, height: c, top: r, left: p, zIndex: m } = e;
1351
+ function kn(a, t) {
1352
+ const e = h(() => {
1353
+ const { width: l, height: u, top: r, left: d, zIndex: f } = t;
1354
1354
  return {
1355
- width: `${i}px`,
1356
- height: `${c}px`,
1355
+ width: `${l}px`,
1356
+ height: `${u}px`,
1357
1357
  top: `${r}px`,
1358
- left: `${p}px`,
1359
- zIndex: m
1358
+ left: `${d}px`,
1359
+ zIndex: f
1360
1360
  };
1361
- }), n = v(() => ({
1362
- [`is-${e.mode}`]: !!e.mode,
1361
+ }), o = h(() => ({
1362
+ [`is-${t.mode}`]: !!t.mode,
1363
1363
  "is-draggable": !!a.draggable,
1364
1364
  "is-resizable": !!a.resizable,
1365
1365
  "is-primary": !!a.primary
1366
- })), s = v(() => ({
1367
- [`is-${e.mode}`]: !!e.mode,
1368
- "is-dragging": e.dragging,
1369
- "is-resizing": e.resizing
1370
- })), l = v(() => ({
1371
- zIndex: e.zIndex
1366
+ })), s = h(() => ({
1367
+ [`is-${t.mode}`]: !!t.mode,
1368
+ "is-dragging": t.dragging,
1369
+ "is-resizing": t.resizing
1370
+ })), i = h(() => ({
1371
+ zIndex: t.zIndex
1372
1372
  }));
1373
1373
  return {
1374
- styles: t,
1375
- classes: n,
1374
+ styles: e,
1375
+ classes: o,
1376
1376
  wrapperClass: s,
1377
- modalStyle: l
1377
+ modalStyle: i
1378
1378
  };
1379
1379
  }
1380
- function so(a, e, t) {
1381
- const n = (m) => {
1382
- e.mode = m, ["maximized", "minimized", "normal"].includes(m) && t(m), t("modeChange", m);
1380
+ function wn(a, t, e) {
1381
+ const o = (f) => {
1382
+ t.mode = f, ["maximized", "minimized", "normal"].includes(f) && e(f), e("modeChange", f);
1383
1383
  }, s = async () => {
1384
- (!a.beforeClose || await a.beforeClose()) && (t("update:modelValue", !1), t("close"), t("destroy"));
1384
+ (!a.beforeClose || await a.beforeClose()) && (e("update:modelValue", !1), e("close"), e("destroy"));
1385
1385
  };
1386
1386
  return {
1387
1387
  close: s,
1388
- changeMode: n,
1389
- show: () => n("normal"),
1390
- hide: () => n("minimized"),
1388
+ changeMode: o,
1389
+ show: () => o("normal"),
1390
+ hide: () => o("minimized"),
1391
1391
  active: () => {
1392
- e.zIndex = Math.max(e.zIndex, ++ie);
1392
+ t.zIndex = Math.max(t.zIndex, ++ue);
1393
1393
  },
1394
- submit: () => t("submit"),
1394
+ submit: () => e("submit"),
1395
1395
  cancel: () => {
1396
- t("cancel"), s();
1396
+ e("cancel"), s();
1397
1397
  }
1398
1398
  };
1399
1399
  }
1400
- function lo(a, e, t, n) {
1401
- return v(() => {
1400
+ function xn(a, t, e, o) {
1401
+ return h(() => {
1402
1402
  const s = typeof a.draggable == "boolean" ? !a.draggable : !!a.draggable?.disabled;
1403
1403
  return {
1404
- ...gt(a.draggable) ? a.draggable : {},
1404
+ ...We(a.draggable) ? a.draggable : {},
1405
1405
  disabled: s,
1406
- target: n,
1406
+ target: o,
1407
1407
  selector: ".x-panel__header",
1408
- onStart(l) {
1409
- e.dragging = !0, e.zIndex = Math.max(e.zIndex, ++ie), t("dragStart", l);
1408
+ onStart(i) {
1409
+ t.dragging = !0, t.zIndex = Math.max(t.zIndex, ++ue), e("dragStart", i);
1410
1410
  },
1411
- onMove(l) {
1412
- t("dragging", l);
1411
+ onMove(i) {
1412
+ e("dragging", i);
1413
1413
  },
1414
- onEnd(l) {
1415
- if (e.mode === "maximized")
1414
+ onEnd(i) {
1415
+ if (t.mode === "maximized")
1416
1416
  return;
1417
- const { x: i, y: c } = l;
1418
- e.left = i, e.top = c, e.dragging = !1, t("dragEnd", l);
1417
+ const { x: l, y: u } = i;
1418
+ t.left = l, t.top = u, t.dragging = !1, e("dragEnd", i);
1419
1419
  }
1420
1420
  };
1421
1421
  });
1422
1422
  }
1423
- function io(a, e, t) {
1424
- return v(() => {
1425
- const n = typeof a.resizable == "boolean" ? !a.resizable : !!a.resizable?.disabled;
1423
+ function Sn(a, t, e) {
1424
+ return h(() => {
1425
+ const o = typeof a.resizable == "boolean" ? !a.resizable : !!a.resizable?.disabled;
1426
1426
  return {
1427
1427
  minWidth: 200,
1428
1428
  minHeight: 150,
1429
- ...gt(a.resizable) ? a.resizable : {},
1430
- disabled: n,
1429
+ ...We(a.resizable) ? a.resizable : {},
1430
+ disabled: o,
1431
1431
  dirs: ["e", "s", "w"],
1432
- onStart(s, l) {
1433
- e.resizing = !0, e.zIndex = Math.max(e.zIndex, ++ie), t("resizeStart", s, l);
1432
+ onStart(s, i) {
1433
+ t.resizing = !0, t.zIndex = Math.max(t.zIndex, ++ue), e("resizeStart", s, i);
1434
1434
  },
1435
- onResizing(s, l) {
1436
- t("resizing", s, l);
1435
+ onResizing(s, i) {
1436
+ e("resizing", s, i);
1437
1437
  },
1438
- onEnd(s, l) {
1439
- e.left = l.elementPositionX.value, e.top = l.elementPositionY.value, e.width = l.elementWidth.value, e.height = l.elementHeight.value, e.resizing = !1, t("resizeEnd", s, l);
1438
+ onEnd(s, i) {
1439
+ t.left = i.elementPositionX.value, t.top = i.elementPositionY.value, t.width = i.elementWidth.value, t.height = i.elementHeight.value, t.resizing = !1, e("resizeEnd", s, i);
1440
1440
  }
1441
1441
  };
1442
1442
  });
1443
1443
  }
1444
- function ro(a, e) {
1445
- const t = a.componentInstance;
1446
- if (!t)
1444
+ function zn(a, t) {
1445
+ const e = a.componentInstance;
1446
+ if (!e)
1447
1447
  return;
1448
- let n = null;
1449
- return It(() => {
1450
- const s = o(e), l = o(s?.bodyRef);
1451
- n = t.$el, l && l.$el && l.$el.appendChild(n);
1452
- }), Bt(() => {
1453
- n && n.parentNode && n.parentNode.removeChild(n);
1448
+ let o = null;
1449
+ return Dt(() => {
1450
+ const s = n(t), i = n(s?.bodyRef);
1451
+ o = e.$el, i && i.$el && i.$el.appendChild(o);
1452
+ }), Pt(() => {
1453
+ o && o.parentNode && o.parentNode.removeChild(o);
1454
1454
  }), {
1455
- componentInstance: t
1455
+ componentInstance: e
1456
1456
  };
1457
1457
  }
1458
- const co = ["src"], zt = /* @__PURE__ */ B({
1458
+ const Cn = ["src"], zt = /* @__PURE__ */ E({
1459
1459
  name: "XDialog",
1460
1460
  __name: "Dialog",
1461
- props: no,
1461
+ props: bn,
1462
1462
  emits: ["update:modelValue", "open", "close", "destroy", "maximized", "minimized", "normal", "modeChange", "dragStart", "dragging", "dragEnd", "resizeStart", "resizeEnd", "resizing", "submit", "cancel"],
1463
- setup(a, { expose: e, emit: t }) {
1464
- const n = a, s = pe(), l = R(), i = R(), { state: c, maximized: r, minimized: p, normal: m } = oo(n, l), { styles: h, classes: k, wrapperClass: A, modalStyle: _ } = ao(n, c), { changeMode: w, active: E, close: D, show: g, hide: I, submit: C, cancel: F } = so(
1465
- n,
1466
- c,
1467
- t
1468
- ), H = lo(n, c, t, l), ne = io(n, c, t), oe = ro(n, i);
1469
- return ot(async () => {
1470
- n.modelValue && (await le(), s && t("open", s));
1471
- }), e({
1472
- panelRef: i,
1473
- state: c,
1463
+ setup(a, { expose: t, emit: e }) {
1464
+ const o = a, s = de(), i = P(), l = P(), { state: u, maximized: r, minimized: d, normal: f } = _n(o, i), { styles: g, classes: S, wrapperClass: $, modalStyle: w } = kn(o, u), { changeMode: _, active: T, close: V, show: y, hide: M, submit: b, cancel: D } = wn(
1465
+ o,
1466
+ u,
1467
+ e
1468
+ ), R = xn(o, u, e, i), oe = Sn(o, u, e), ne = zn(o, l);
1469
+ it(async () => {
1470
+ o.modelValue && (await ce(), s && e("open", s));
1471
+ });
1472
+ const ae = h(() => l.value?.$el);
1473
+ return t({
1474
+ $vtjEl: ae,
1475
+ panelRef: l,
1476
+ state: u,
1474
1477
  maximized: r,
1475
- minimized: p,
1476
- changeMode: w,
1477
- show: g,
1478
- hide: I,
1479
- submit: C,
1480
- cancel: F,
1481
- componentInstance: oe
1482
- }), (j, L) => n.modelValue ? (u(), f(at, {
1478
+ minimized: d,
1479
+ changeMode: _,
1480
+ show: y,
1481
+ hide: M,
1482
+ submit: b,
1483
+ cancel: D,
1484
+ componentInstance: ne
1485
+ }), (U, Z) => o.modelValue ? (c(), m(rt, {
1483
1486
  key: 0,
1484
1487
  to: "body"
1485
1488
  }, [
1486
- $("div", {
1489
+ O("div", {
1487
1490
  ref_key: "wrapper",
1488
- ref: l,
1489
- class: U(["x-dialog__wrapper", o(A)])
1491
+ ref: i,
1492
+ class: W(["x-dialog__wrapper", n($)])
1490
1493
  }, [
1491
- n.modal ? (u(), V("div", {
1494
+ o.modal ? (c(), A("div", {
1492
1495
  key: 0,
1493
1496
  class: "x-dialog__modal",
1494
- style: be(o(_))
1495
- }, null, 4)) : y("", !0),
1496
- W((u(), f(o(kt), {
1497
+ style: Ce(n(w))
1498
+ }, null, 4)) : v("", !0),
1499
+ K((c(), m(n(xt), {
1497
1500
  ref_key: "panelRef",
1498
- ref: i,
1499
- class: U(["x-dialog", o(k)]),
1501
+ ref: l,
1502
+ class: W(["x-dialog", n(S)]),
1500
1503
  card: "",
1501
1504
  shadow: "always",
1502
- header: { icon: n.icon, subtitle: n.subtitle },
1505
+ header: { icon: o.icon, subtitle: o.subtitle },
1503
1506
  width: "800px",
1504
1507
  height: "600px",
1505
1508
  footer: { justify: "space-between", flex: !0, align: "center" },
1506
- style: be(o(h)),
1507
- size: n.size,
1508
- body: { padding: n.bodyPadding },
1509
- onClick: o(E)
1510
- }, $e({
1511
- title: d(() => [
1512
- N(O(n.title), 1)
1509
+ style: Ce(n(g)),
1510
+ size: o.size,
1511
+ body: { padding: o.bodyPadding },
1512
+ onClick: n(T)
1513
+ }, ye({
1514
+ title: p(() => [
1515
+ N(j(o.title), 1)
1513
1516
  ]),
1514
- actions: d(() => [
1515
- z(j.$slots, "actions"),
1516
- n.minimizable ? (u(), f(o(Q), {
1517
+ actions: p(() => [
1518
+ z(U.$slots, "actions"),
1519
+ o.minimizable ? (c(), m(n(J), {
1517
1520
  key: 0,
1518
- icon: o(mn),
1519
- size: n.size,
1521
+ icon: n(Mo),
1522
+ size: o.size,
1520
1523
  mode: "icon",
1521
1524
  type: "primary",
1522
1525
  background: "hover",
1523
- onClick: L[0] || (L[0] = (se) => o(w)("minimized"))
1524
- }, null, 8, ["icon", "size"])) : y("", !0),
1525
- n.maximizable ? (u(), V(q, { key: 1 }, [
1526
- o(m) ? (u(), f(o(Q), {
1526
+ onClick: Z[0] || (Z[0] = (re) => n(_)("minimized"))
1527
+ }, null, 8, ["icon", "size"])) : v("", !0),
1528
+ o.maximizable ? (c(), A(Q, { key: 1 }, [
1529
+ n(f) ? (c(), m(n(J), {
1527
1530
  key: 1,
1528
- icon: o(hn),
1529
- size: n.size,
1531
+ icon: n(Io),
1532
+ size: o.size,
1530
1533
  mode: "icon",
1531
1534
  type: "primary",
1532
1535
  background: "hover",
1533
- onClick: L[2] || (L[2] = (se) => o(w)("maximized"))
1534
- }, null, 8, ["icon", "size"])) : (u(), f(o(Q), {
1536
+ onClick: Z[2] || (Z[2] = (re) => n(_)("maximized"))
1537
+ }, null, 8, ["icon", "size"])) : (c(), m(n(J), {
1535
1538
  key: 0,
1536
- icon: o(gn),
1537
- size: n.size,
1539
+ icon: n(Bo),
1540
+ size: o.size,
1538
1541
  mode: "icon",
1539
1542
  type: "primary",
1540
1543
  background: "hover",
1541
- onClick: L[1] || (L[1] = (se) => o(w)("normal"))
1544
+ onClick: Z[1] || (Z[1] = (re) => n(_)("normal"))
1542
1545
  }, null, 8, ["icon", "size"]))
1543
- ], 64)) : y("", !0),
1544
- n.closable ? (u(), f(o(Q), {
1546
+ ], 64)) : v("", !0),
1547
+ o.closable ? (c(), m(n(J), {
1545
1548
  key: 2,
1546
- icon: o(yn),
1547
- size: n.size,
1549
+ icon: n(Ao),
1550
+ size: o.size,
1548
1551
  mode: "icon",
1549
1552
  type: "danger",
1550
1553
  background: "hover",
1551
- onClick: o(D)
1552
- }, null, 8, ["icon", "size", "onClick"])) : y("", !0)
1554
+ onClick: n(V)
1555
+ }, null, 8, ["icon", "size", "onClick"])) : v("", !0)
1553
1556
  ]),
1554
- default: d(() => [
1555
- z(j.$slots, "default", {}, () => [
1556
- n.content ? (u(), f(Z(n.content), { key: 0 })) : y("", !0),
1557
- n.src ? (u(), V("iframe", {
1557
+ default: p(() => [
1558
+ z(U.$slots, "default", {}, () => [
1559
+ o.content ? (c(), m(L(o.content), { key: 0 })) : v("", !0),
1560
+ o.src ? (c(), A("iframe", {
1558
1561
  key: 1,
1559
- src: n.src,
1562
+ src: o.src,
1560
1563
  class: "x-dialog__frame"
1561
- }, null, 8, co)) : y("", !0)
1564
+ }, null, 8, Cn)) : v("", !0)
1562
1565
  ])
1563
1566
  ]),
1564
1567
  _: 2
1565
1568
  }, [
1566
- n.cancel || n.submit || j.$slots.footer || j.$slots.extra || j.$slots.handle ? {
1569
+ o.cancel || o.submit || U.$slots.footer || U.$slots.extra || U.$slots.handle ? {
1567
1570
  name: "footer",
1568
- fn: d(() => [
1569
- z(j.$slots, "footer", {}, () => [
1570
- b(o(M), null, {
1571
- default: d(() => [
1572
- z(j.$slots, "extra")
1571
+ fn: p(() => [
1572
+ z(U.$slots, "footer", {}, () => [
1573
+ k(n(I), null, {
1574
+ default: p(() => [
1575
+ z(U.$slots, "extra")
1573
1576
  ]),
1574
1577
  _: 3
1575
1578
  }),
1576
- b(o(M), null, {
1577
- default: d(() => [
1578
- z(j.$slots, "handle"),
1579
- n.cancel ? (u(), f(o(de), {
1579
+ k(n(I), null, {
1580
+ default: p(() => [
1581
+ z(U.$slots, "handle"),
1582
+ o.cancel ? (c(), m(n(le), {
1580
1583
  key: 0,
1581
1584
  type: "default",
1582
- size: n.size,
1583
- onClick: o(F)
1585
+ size: o.size,
1586
+ onClick: n(D)
1584
1587
  }, {
1585
- default: d(() => [
1586
- N(O(typeof n.cancel == "string" ? n.cancel : "取消"), 1)
1588
+ default: p(() => [
1589
+ N(j(typeof o.cancel == "string" ? o.cancel : "取消"), 1)
1587
1590
  ]),
1588
1591
  _: 1
1589
- }, 8, ["size", "onClick"])) : y("", !0),
1590
- n.submit ? (u(), f(o(de), {
1592
+ }, 8, ["size", "onClick"])) : v("", !0),
1593
+ o.submit ? (c(), m(n(le), {
1591
1594
  key: 1,
1592
1595
  type: "primary",
1593
- size: n.size,
1594
- onClick: o(C)
1596
+ size: o.size,
1597
+ onClick: n(b)
1595
1598
  }, {
1596
- default: d(() => [
1597
- N(O(typeof n.submit == "string" ? n.cancel : "确定"), 1)
1599
+ default: p(() => [
1600
+ N(j(typeof o.submit == "string" ? o.cancel : "确定"), 1)
1598
1601
  ]),
1599
1602
  _: 1
1600
- }, 8, ["size", "onClick"])) : y("", !0)
1603
+ }, 8, ["size", "onClick"])) : v("", !0)
1601
1604
  ]),
1602
1605
  _: 3
1603
1606
  })
@@ -1606,42 +1609,42 @@ const co = ["src"], zt = /* @__PURE__ */ B({
1606
1609
  key: "0"
1607
1610
  } : void 0
1608
1611
  ]), 1032, ["header", "class", "style", "size", "body", "onClick"])), [
1609
- [o(to), o(H)],
1610
- [o(xt), o(ne)]
1612
+ [n(vn), n(R)],
1613
+ [n(St), n(oe)]
1611
1614
  ])
1612
1615
  ], 2)
1613
- ])) : y("", !0);
1616
+ ])) : v("", !0);
1614
1617
  }
1615
1618
  });
1616
- function Ne(a, e) {
1617
- const t = document.createElement("div"), n = b(zt, a);
1618
- n.appContext = e ?? Ne._context, Xe(n, t);
1619
+ function Qe(a, t) {
1620
+ const e = document.createElement("div"), o = k(zt, a);
1621
+ o.appContext = t ?? Qe._context, Ze(o, e);
1619
1622
  const s = () => {
1620
- Xe(null, t), t.parentNode?.removeChild(t);
1623
+ Ze(null, e), e.parentNode?.removeChild(e);
1621
1624
  };
1622
- return n.props.onDestroy = () => {
1625
+ return o.props.onDestroy = () => {
1623
1626
  s();
1624
- }, document.body.appendChild(t), {
1625
- vnode: n,
1627
+ }, document.body.appendChild(e), {
1628
+ vnode: o,
1626
1629
  destroy: s
1627
1630
  };
1628
1631
  }
1629
- const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -1), po = /* @__PURE__ */ B({
1632
+ const Tn = /* @__PURE__ */ O("div", { class: "x-mask-sidebar__helper" }, null, -1), En = /* @__PURE__ */ E({
1630
1633
  __name: "Sidebar",
1631
1634
  props: {
1632
1635
  collapsed: { type: Boolean }
1633
1636
  },
1634
1637
  setup(a) {
1635
- const e = a;
1636
- return (t, n) => W((u(), f(o(M), {
1637
- class: U(["x-mask-sidebar", { "is-collapsed": e.collapsed }]),
1638
+ const t = a;
1639
+ return (e, o) => K((c(), m(n(I), {
1640
+ class: W(["x-mask-sidebar", { "is-collapsed": t.collapsed }]),
1638
1641
  grow: !1,
1639
1642
  flex: "",
1640
1643
  direction: "column"
1641
1644
  }, {
1642
- default: d(() => [
1643
- z(t.$slots, "brand"),
1644
- b(o(M), {
1645
+ default: p(() => [
1646
+ z(e.$slots, "brand"),
1647
+ k(n(I), {
1645
1648
  class: "x-mask-sidebar__wrapper",
1646
1649
  flex: "",
1647
1650
  grow: "",
@@ -1649,24 +1652,24 @@ const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -
1649
1652
  justify: "space-between",
1650
1653
  align: "center"
1651
1654
  }, {
1652
- default: d(() => [
1653
- z(t.$slots, "default"),
1654
- uo
1655
+ default: p(() => [
1656
+ z(e.$slots, "default"),
1657
+ Tn
1655
1658
  ]),
1656
1659
  _: 3
1657
1660
  })
1658
1661
  ]),
1659
1662
  _: 3
1660
1663
  }, 8, ["class"])), [
1661
- [o(xt), {
1664
+ [n(St), {
1662
1665
  dirs: ["e"],
1663
- disabled: e.collapsed,
1666
+ disabled: t.collapsed,
1664
1667
  maxWidth: 500,
1665
1668
  minWidth: 200
1666
1669
  }]
1667
1670
  ]);
1668
1671
  }
1669
- }), fo = /* @__PURE__ */ B({
1672
+ }), Mn = /* @__PURE__ */ E({
1670
1673
  __name: "SwitchBar",
1671
1674
  props: {
1672
1675
  collasped: { type: Boolean, default: !1 },
@@ -1678,88 +1681,88 @@ const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -
1678
1681
  "update:keyword",
1679
1682
  "update:favorite"
1680
1683
  ],
1681
- setup(a, { emit: e }) {
1682
- const t = a, n = R(!1), s = R(""), l = R(!1), i = () => {
1683
- n.value = !0;
1684
- }, c = () => {
1685
- s.value = "", n.value = !1, e("update:keyword", s.value);
1684
+ setup(a, { emit: t }) {
1685
+ const e = a, o = P(!1), s = P(""), i = P(!1), l = () => {
1686
+ o.value = !0;
1687
+ }, u = () => {
1688
+ s.value = "", o.value = !1, t("update:keyword", s.value);
1686
1689
  }, r = () => {
1687
- e("update:collasped", !t.collasped);
1688
- }, p = () => {
1689
- e("update:keyword", s.value);
1690
- }, m = () => {
1691
- e("update:favorite", l.value);
1690
+ t("update:collasped", !e.collasped);
1691
+ }, d = () => {
1692
+ t("update:keyword", s.value);
1693
+ }, f = () => {
1694
+ t("update:favorite", i.value);
1692
1695
  };
1693
- return (h, k) => (u(), f(o(M), {
1696
+ return (g, S) => (c(), m(n(I), {
1694
1697
  class: "x-mask-switch-bar",
1695
1698
  justify: "space-between",
1696
1699
  align: "center"
1697
1700
  }, {
1698
- default: d(() => [
1699
- t.collasped ? y("", !0) : (u(), f(o(M), {
1701
+ default: p(() => [
1702
+ e.collasped ? v("", !0) : (c(), m(n(I), {
1700
1703
  key: 0,
1701
1704
  class: "x-mask-switch-bar__left",
1702
1705
  grow: ""
1703
1706
  }, {
1704
- default: d(() => [
1705
- n.value ? y("", !0) : (u(), f(o(lt), {
1707
+ default: p(() => [
1708
+ o.value ? v("", !0) : (c(), m(n(Xe), {
1706
1709
  key: 0,
1707
- modelValue: l.value,
1708
- "onUpdate:modelValue": k[0] || (k[0] = (A) => l.value = A),
1710
+ modelValue: i.value,
1711
+ "onUpdate:modelValue": S[0] || (S[0] = ($) => i.value = $),
1709
1712
  class: "x-mask-switch-bar__switch",
1710
- "active-icon": o(ct),
1711
- "inactive-icon": o(rt),
1712
- onChange: m
1713
+ "active-icon": n(pt),
1714
+ "inactive-icon": n(dt),
1715
+ onChange: f
1713
1716
  }, null, 8, ["modelValue", "active-icon", "inactive-icon"])),
1714
- n.value ? (u(), f(o(De), {
1717
+ o.value ? (c(), m(n(Fe), {
1715
1718
  key: 1,
1716
1719
  modelValue: s.value,
1717
- "onUpdate:modelValue": k[1] || (k[1] = (A) => s.value = A),
1720
+ "onUpdate:modelValue": S[1] || (S[1] = ($) => s.value = $),
1718
1721
  class: "x-mask-switch-bar__input",
1719
1722
  size: "small",
1720
1723
  placeholder: "请输入查询关键字",
1721
- onInput: p,
1722
- "prefix-icon": o(Ve)
1724
+ onInput: d,
1725
+ "prefix-icon": n(Oe)
1723
1726
  }, {
1724
- suffix: d(() => [
1725
- b(o(te), {
1726
- icon: o(ut),
1727
- onClick: c
1727
+ suffix: p(() => [
1728
+ k(n(te), {
1729
+ icon: n(ft),
1730
+ onClick: u
1728
1731
  }, null, 8, ["icon"])
1729
1732
  ]),
1730
1733
  _: 1
1731
- }, 8, ["modelValue", "prefix-icon"])) : y("", !0)
1734
+ }, 8, ["modelValue", "prefix-icon"])) : v("", !0)
1732
1735
  ]),
1733
1736
  _: 1
1734
1737
  })),
1735
- b(o(M), {
1736
- class: U(["x-mask-switch-bar__right", { "is-collasped": t.collasped }]),
1738
+ k(n(I), {
1739
+ class: W(["x-mask-switch-bar__right", { "is-collasped": e.collasped }]),
1737
1740
  flex: "",
1738
1741
  align: "center",
1739
1742
  justify: "center"
1740
1743
  }, {
1741
- default: d(() => [
1742
- !n.value && !t.collasped ? (u(), f(o(Q), {
1744
+ default: p(() => [
1745
+ !o.value && !e.collasped ? (c(), m(n(J), {
1743
1746
  key: 0,
1744
- icon: o(Ve),
1747
+ icon: n(Oe),
1745
1748
  mode: "icon",
1746
1749
  background: "hover",
1747
1750
  size: "default",
1748
1751
  circle: "",
1749
- onClick: i
1750
- }, null, 8, ["icon"])) : y("", !0),
1751
- t.collasped ? (u(), f(o(Q), {
1752
+ onClick: l
1753
+ }, null, 8, ["icon"])) : v("", !0),
1754
+ e.collasped ? (c(), m(n(J), {
1752
1755
  key: 1,
1753
- icon: o(nn),
1756
+ icon: n(vo),
1754
1757
  mode: "icon",
1755
1758
  size: "default",
1756
1759
  background: "hover",
1757
1760
  onClick: r,
1758
1761
  circle: ""
1759
- }, null, 8, ["icon"])) : y("", !0),
1760
- t.collasped ? y("", !0) : (u(), f(o(Q), {
1762
+ }, null, 8, ["icon"])) : v("", !0),
1763
+ e.collasped ? v("", !0) : (c(), m(n(J), {
1761
1764
  key: 2,
1762
- icon: o(on),
1765
+ icon: n(bo),
1763
1766
  mode: "icon",
1764
1767
  size: "default",
1765
1768
  background: "hover",
@@ -1773,7 +1776,7 @@ const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -
1773
1776
  _: 1
1774
1777
  }));
1775
1778
  }
1776
- }), mo = ["src"], go = { key: 0 }, ho = /* @__PURE__ */ B({
1779
+ }), Bn = ["src"], In = { key: 0 }, An = /* @__PURE__ */ E({
1777
1780
  __name: "Brand",
1778
1781
  props: {
1779
1782
  collapsed: { type: Boolean, default: !1 },
@@ -1782,42 +1785,42 @@ const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -
1782
1785
  url: {}
1783
1786
  },
1784
1787
  setup(a) {
1785
- const e = a, t = xe(), n = () => {
1786
- e.url && t.push(e.url);
1788
+ const t = a, e = Ie(), o = () => {
1789
+ t.url && e.push(t.url);
1787
1790
  };
1788
- return (s, l) => (u(), f(o(M), {
1789
- class: U(["x-mask-brand", { "is-collapsed": e.collapsed }]),
1791
+ return (s, i) => (c(), m(n(I), {
1792
+ class: W(["x-mask-brand", { "is-collapsed": t.collapsed }]),
1790
1793
  align: "center"
1791
1794
  }, {
1792
- default: d(() => [
1793
- b(o(M), {
1795
+ default: p(() => [
1796
+ k(n(I), {
1794
1797
  class: "x-mask-brand__logo",
1795
1798
  flex: "",
1796
1799
  justify: "center",
1797
1800
  align: "center",
1798
- onClick: n
1801
+ onClick: o
1799
1802
  }, {
1800
- default: d(() => [
1803
+ default: p(() => [
1801
1804
  z(s.$slots, "logo", {}, () => [
1802
- e.logo ? (u(), V("img", {
1805
+ t.logo ? (c(), A("img", {
1803
1806
  key: 0,
1804
- src: e.logo
1805
- }, null, 8, mo)) : y("", !0)
1807
+ src: t.logo
1808
+ }, null, 8, Bn)) : v("", !0)
1806
1809
  ])
1807
1810
  ]),
1808
1811
  _: 3
1809
1812
  }),
1810
- b(o(M), {
1813
+ k(n(I), {
1811
1814
  class: "x-mask-brand__title",
1812
1815
  flex: "",
1813
1816
  align: "center"
1814
1817
  }, {
1815
- default: d(() => [
1816
- e.title ? (u(), V("span", go, [
1818
+ default: p(() => [
1819
+ t.title ? (c(), A("span", In, [
1817
1820
  z(s.$slots, "title", {}, () => [
1818
- N(O(e.title), 1)
1821
+ N(j(t.title), 1)
1819
1822
  ])
1820
- ])) : y("", !0)
1823
+ ])) : v("", !0)
1821
1824
  ]),
1822
1825
  _: 3
1823
1826
  })
@@ -1825,7 +1828,7 @@ const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -
1825
1828
  _: 3
1826
1829
  }, 8, ["class"]));
1827
1830
  }
1828
- }), ge = "__favorites__", he = "__search__", yo = /* @__PURE__ */ B({
1831
+ }), ke = "__favorites__", we = "__search__", $n = /* @__PURE__ */ E({
1829
1832
  __name: "Menu",
1830
1833
  props: {
1831
1834
  collapse: { type: Boolean, default: !1 },
@@ -1837,94 +1840,94 @@ const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -
1837
1840
  active: {}
1838
1841
  },
1839
1842
  emits: ["select"],
1840
- setup(a, { emit: e }) {
1841
- const t = a, n = v(() => t.menus || []), s = v(() => String(t.active?.id)), l = v(() => [
1843
+ setup(a, { emit: t }) {
1844
+ const e = a, o = h(() => e.menus || []), s = h(() => String(e.active?.id)), i = h(() => [
1842
1845
  {
1843
- id: ge,
1846
+ id: ke,
1844
1847
  title: "收藏",
1845
- icon: dt,
1846
- children: t.favorites?.length ? t.favorites : [
1848
+ icon: mt,
1849
+ children: e.favorites?.length ? e.favorites : [
1847
1850
  {
1848
- id: ge + "empty",
1851
+ id: ke + "empty",
1849
1852
  disabled: !0,
1850
1853
  title: "暂无收藏菜单"
1851
1854
  }
1852
1855
  ]
1853
1856
  }
1854
- ]), i = v(() => {
1855
- const r = (t.keyword || "").trim(), p = r ? (t.flatMenus || []).filter((m) => m.title?.includes(r)) : [];
1857
+ ]), l = h(() => {
1858
+ const r = (e.keyword || "").trim(), d = r ? (e.flatMenus || []).filter((f) => f.title?.includes(r)) : [];
1856
1859
  return [
1857
1860
  {
1858
- id: he,
1861
+ id: we,
1859
1862
  title: "搜索",
1860
- icon: Ve,
1861
- children: p?.length ? p : [
1863
+ icon: Oe,
1864
+ children: d?.length ? d : [
1862
1865
  {
1863
- id: he + "empty",
1866
+ id: we + "empty",
1864
1867
  disabled: !0,
1865
1868
  title: "查询匹配不到菜单项"
1866
1869
  }
1867
1870
  ]
1868
1871
  }
1869
1872
  ];
1870
- }), c = (r) => {
1871
- e("select", r);
1873
+ }), u = (r) => {
1874
+ t("select", r);
1872
1875
  };
1873
- return (r, p) => (u(), V(q, null, [
1874
- W(b(o(M), {
1876
+ return (r, d) => (c(), A(Q, null, [
1877
+ K(k(n(I), {
1875
1878
  class: "x-mask-menu",
1876
1879
  grow: "",
1877
1880
  flex: !1,
1878
1881
  overflow: "auto"
1879
1882
  }, {
1880
- default: d(() => [
1881
- W(b(o(G), {
1883
+ default: p(() => [
1884
+ K(k(n(ee), {
1882
1885
  subMenu: {
1883
1886
  popperClass: "x-mask-menu-popper",
1884
1887
  teleported: !0,
1885
1888
  showTimeout: 200,
1886
1889
  hideTimeout: 200
1887
1890
  },
1888
- data: n.value,
1889
- "default-icon": o(ae),
1891
+ data: o.value,
1892
+ "default-icon": n(se),
1890
1893
  collapse: !0,
1891
1894
  "collapse-transition": !1,
1892
1895
  "default-active": s.value,
1893
- onSelect: c
1896
+ onSelect: u
1894
1897
  }, null, 8, ["data", "default-icon", "default-active"]), [
1895
- [K, t.collapse]
1898
+ [Y, e.collapse]
1896
1899
  ]),
1897
- W(b(o(G), {
1900
+ K(k(n(ee), {
1898
1901
  subMenu: {
1899
1902
  popperClass: "x-mask-menu-popper",
1900
1903
  teleported: !0
1901
1904
  },
1902
- data: n.value,
1903
- "default-icon": o(ae),
1905
+ data: o.value,
1906
+ "default-icon": n(se),
1904
1907
  collapse: !1,
1905
1908
  "collapse-transition": !1,
1906
1909
  "default-active": s.value,
1907
- onSelect: c
1910
+ onSelect: u
1908
1911
  }, null, 8, ["data", "default-icon", "default-active"]), [
1909
- [K, !t.collapse]
1912
+ [Y, !e.collapse]
1910
1913
  ]),
1911
- n.value.length ? y("", !0) : (u(), f(o(Wt), {
1914
+ o.value.length ? v("", !0) : (c(), m(n(Jt), {
1912
1915
  key: 0,
1913
1916
  description: "暂无菜单数据"
1914
1917
  }))
1915
1918
  ]),
1916
1919
  _: 1
1917
1920
  }, 512), [
1918
- [K, !t.favorite && !t.keyword]
1921
+ [Y, !e.favorite && !e.keyword]
1919
1922
  ]),
1920
- W(b(o(M), {
1923
+ K(k(n(I), {
1921
1924
  class: "x-mask-menu",
1922
1925
  grow: "",
1923
1926
  flex: !1,
1924
1927
  overflow: "auto"
1925
1928
  }, {
1926
- default: d(() => [
1927
- W(b(o(G), {
1929
+ default: p(() => [
1930
+ K(k(n(ee), {
1928
1931
  class: "x-mask-menu__favorites",
1929
1932
  subMenu: {
1930
1933
  popperClass: "x-mask-menu-popper",
@@ -1932,17 +1935,17 @@ const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -
1932
1935
  showTimeout: 200,
1933
1936
  hideTimeout: 200
1934
1937
  },
1935
- data: l.value,
1936
- "default-icon": o(ae),
1938
+ data: i.value,
1939
+ "default-icon": n(se),
1937
1940
  collapse: !0,
1938
1941
  "collapse-transition": !1,
1939
1942
  "default-active": s.value,
1940
- "default-openeds": [ge],
1941
- onSelect: c
1943
+ "default-openeds": [ke],
1944
+ onSelect: u
1942
1945
  }, null, 8, ["data", "default-icon", "default-active", "default-openeds"]), [
1943
- [K, t.collapse]
1946
+ [Y, e.collapse]
1944
1947
  ]),
1945
- W(b(o(G), {
1948
+ K(k(n(ee), {
1946
1949
  class: "x-mask-menu__favorites",
1947
1950
  subMenu: {
1948
1951
  popperClass: "x-mask-menu-popper",
@@ -1950,30 +1953,30 @@ const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -
1950
1953
  showTimeout: 200,
1951
1954
  hideTimeout: 200
1952
1955
  },
1953
- data: l.value,
1954
- "default-icon": o(ae),
1956
+ data: i.value,
1957
+ "default-icon": n(se),
1955
1958
  collapse: !1,
1956
1959
  "collapse-transition": !1,
1957
1960
  "default-active": s.value,
1958
- "default-openeds": [ge],
1959
- onSelect: c
1961
+ "default-openeds": [ke],
1962
+ onSelect: u
1960
1963
  }, null, 8, ["data", "default-icon", "default-active", "default-openeds"]), [
1961
- [K, !t.collapse]
1964
+ [Y, !e.collapse]
1962
1965
  ])
1963
1966
  ]),
1964
1967
  _: 1
1965
1968
  }, 512), [
1966
- [K, t.favorite && !t.keyword]
1969
+ [Y, e.favorite && !e.keyword]
1967
1970
  ]),
1968
- t.keyword ? W((u(), f(o(M), {
1971
+ e.keyword ? K((c(), m(n(I), {
1969
1972
  key: 0,
1970
1973
  class: "x-mask-menu",
1971
1974
  grow: "",
1972
1975
  flex: !1,
1973
1976
  overflow: "auto"
1974
1977
  }, {
1975
- default: d(() => [
1976
- W(b(o(G), {
1978
+ default: p(() => [
1979
+ K(k(n(ee), {
1977
1980
  class: "x-mask-menu__search",
1978
1981
  subMenu: {
1979
1982
  popperClass: "x-mask-menu-popper",
@@ -1981,17 +1984,17 @@ const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -
1981
1984
  showTimeout: 200,
1982
1985
  hideTimeout: 200
1983
1986
  },
1984
- data: i.value,
1985
- "default-icon": o(ae),
1987
+ data: l.value,
1988
+ "default-icon": n(se),
1986
1989
  collapse: !0,
1987
1990
  "collapse-transition": !1,
1988
1991
  "default-active": s.value,
1989
- "default-openeds": [he],
1990
- onSelect: c
1992
+ "default-openeds": [we],
1993
+ onSelect: u
1991
1994
  }, null, 8, ["data", "default-icon", "default-active", "default-openeds"]), [
1992
- [K, t.collapse]
1995
+ [Y, e.collapse]
1993
1996
  ]),
1994
- W(b(o(G), {
1997
+ K(k(n(ee), {
1995
1998
  class: "x-mask-menu__search",
1996
1999
  subMenu: {
1997
2000
  popperClass: "x-mask-menu-popper",
@@ -1999,24 +2002,24 @@ const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -
1999
2002
  showTimeout: 200,
2000
2003
  hideTimeout: 200
2001
2004
  },
2002
- data: i.value,
2003
- "default-icon": o(ae),
2005
+ data: l.value,
2006
+ "default-icon": n(se),
2004
2007
  collapse: !1,
2005
2008
  "collapse-transition": !1,
2006
2009
  "default-active": s.value,
2007
- "default-openeds": [he],
2008
- onSelect: c
2010
+ "default-openeds": [we],
2011
+ onSelect: u
2009
2012
  }, null, 8, ["data", "default-icon", "default-active", "default-openeds"]), [
2010
- [K, !t.collapse]
2013
+ [Y, !e.collapse]
2011
2014
  ])
2012
2015
  ]),
2013
2016
  _: 1
2014
2017
  }, 512)), [
2015
- [K, !!t.keyword]
2016
- ]) : y("", !0)
2018
+ [Y, !!e.keyword]
2019
+ ]) : v("", !0)
2017
2020
  ], 64));
2018
2021
  }
2019
- }), vo = { class: "x-mask-tabs__trigger" }, bo = { key: 1 }, _o = ["onDragstart", "onDragend"], wo = { key: 1 }, ko = /* @__PURE__ */ B({
2022
+ }), Vn = { class: "x-mask-tabs__trigger" }, Dn = { key: 1 }, Pn = ["onDragstart", "onDragend"], Rn = { key: 1 }, Fn = /* @__PURE__ */ E({
2020
2023
  __name: "Tabs",
2021
2024
  props: {
2022
2025
  tabs: {},
@@ -2026,63 +2029,63 @@ const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -
2026
2029
  favorites: {}
2027
2030
  },
2028
2031
  emits: ["click", "remove", "refresh", "toggleFavorite", "dialog"],
2029
- setup(a, { emit: e }) {
2030
- const t = a, n = (p) => {
2031
- const m = !!t.favorites.find(
2032
- (h) => h === p.menu || h.id === p.menu?.id
2032
+ setup(a, { emit: t }) {
2033
+ const e = a, o = (d) => {
2034
+ const f = !!e.favorites.find(
2035
+ (g) => g === d.menu || g.id === d.menu?.id
2033
2036
  );
2034
2037
  return [
2035
2038
  {
2036
- icon: an,
2039
+ icon: _o,
2037
2040
  label: "刷新",
2038
2041
  name: "refresh",
2039
- value: p
2042
+ value: d
2040
2043
  },
2041
2044
  "|",
2042
2045
  {
2043
- icon: m ? ct : dt,
2046
+ icon: f ? pt : mt,
2044
2047
  label: "收藏",
2045
2048
  name: "favorite",
2046
- value: p.menu,
2047
- disabled: !p.menu
2049
+ value: d.menu,
2050
+ disabled: !d.menu
2048
2051
  },
2049
2052
  "|",
2050
2053
  {
2051
- icon: sn,
2054
+ icon: ko,
2052
2055
  label: "弹窗",
2053
2056
  name: "dialog",
2054
- value: p
2057
+ value: d
2055
2058
  }
2056
2059
  ];
2057
- }, s = (p) => {
2058
- const m = p.paneName;
2059
- if (m === t.home.id) {
2060
- e("click", t.home);
2060
+ }, s = (d) => {
2061
+ const f = d.paneName;
2062
+ if (f === e.home.id) {
2063
+ t("click", e.home);
2061
2064
  return;
2062
2065
  }
2063
- const h = t.tabs.find((k) => k.id === m);
2064
- h && e("click", h);
2065
- }, l = (p) => {
2066
- const m = t.tabs.find((h) => h.id === p);
2067
- m && e("remove", m);
2068
- }, i = (p) => {
2069
- switch (p.name) {
2066
+ const g = e.tabs.find((S) => S.id === f);
2067
+ g && t("click", g);
2068
+ }, i = (d) => {
2069
+ const f = e.tabs.find((g) => g.id === d);
2070
+ f && t("remove", f);
2071
+ }, l = (d) => {
2072
+ switch (d.name) {
2070
2073
  case "refresh":
2071
- e("refresh", p.value);
2074
+ t("refresh", d.value);
2072
2075
  break;
2073
2076
  case "favorite":
2074
- e("toggleFavorite", p.value);
2077
+ t("toggleFavorite", d.value);
2075
2078
  break;
2076
2079
  case "dialog":
2077
- e("dialog", p.value);
2080
+ t("dialog", d.value);
2078
2081
  break;
2079
2082
  }
2080
- }, c = (p, m) => {
2081
- m.dataTransfer && (m.dataTransfer.setData("tab", p.id), m.target && m.target.classList.add("is-dagging"));
2082
- }, r = (p, m) => {
2083
- m.target && m.target.classList.remove("is-dagging");
2083
+ }, u = (d, f) => {
2084
+ f.dataTransfer && (f.dataTransfer.setData("tab", d.id), f.target && f.target.classList.add("is-dagging"));
2085
+ }, r = (d, f) => {
2086
+ f.target && f.target.classList.remove("is-dagging");
2084
2087
  };
2085
- return (p, m) => (u(), f(o(M), {
2088
+ return (d, f) => (c(), m(n(I), {
2086
2089
  ref: "tabsRef",
2087
2090
  class: "x-mask-tabs",
2088
2091
  height: "100%",
@@ -2091,58 +2094,58 @@ const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -
2091
2094
  justify: "flex-end",
2092
2095
  direction: "column"
2093
2096
  }, {
2094
- default: d(() => [
2095
- b(o(Qt), {
2097
+ default: p(() => [
2098
+ k(n(Gt), {
2096
2099
  type: "card",
2097
- "model-value": t.value,
2098
- onTabRemove: l,
2100
+ "model-value": e.value,
2101
+ onTabRemove: i,
2099
2102
  onTabClick: s
2100
2103
  }, {
2101
- default: d(() => [
2102
- t.home ? (u(), f(o(Le), {
2104
+ default: p(() => [
2105
+ e.home ? (c(), m(n(Ye), {
2103
2106
  key: 0,
2104
- name: t.home.id
2107
+ name: e.home.id
2105
2108
  }, {
2106
- label: d(() => [
2107
- $("div", vo, [
2108
- t.home.icon ? (u(), f(Z(o(we)(t.home.icon)), { key: 0 })) : y("", !0),
2109
- t.home.title ? (u(), V("span", bo, O(t.home.title), 1)) : y("", !0)
2109
+ label: p(() => [
2110
+ O("div", Vn, [
2111
+ e.home.icon ? (c(), m(L(n(Ee)(e.home.icon)), { key: 0 })) : v("", !0),
2112
+ e.home.title ? (c(), A("span", Dn, j(e.home.title), 1)) : v("", !0)
2110
2113
  ])
2111
2114
  ]),
2112
2115
  _: 1
2113
- }, 8, ["name"])) : y("", !0),
2114
- (u(!0), V(q, null, ke(t.tabs, (h) => (u(), f(o(Le), {
2115
- key: h.id,
2116
- name: h.id,
2116
+ }, 8, ["name"])) : v("", !0),
2117
+ (c(!0), A(Q, null, ie(e.tabs, (g) => (c(), m(n(Ye), {
2118
+ key: g.id,
2119
+ name: g.id,
2117
2120
  lazy: "",
2118
2121
  closable: ""
2119
2122
  }, {
2120
- label: d(() => [
2121
- b(o(it), {
2123
+ label: p(() => [
2124
+ k(n(ut), {
2122
2125
  "open-delay": 500,
2123
2126
  placement: "bottom",
2124
2127
  trigger: "hover",
2125
2128
  width: "200px",
2126
- disabled: h.id !== t.value
2129
+ disabled: g.id !== e.value
2127
2130
  }, {
2128
- reference: d(() => [
2129
- $("div", {
2131
+ reference: p(() => [
2132
+ O("div", {
2130
2133
  class: "x-mask-tabs__trigger",
2131
2134
  draggable: "true",
2132
- onDragstart: (k) => c(h, k),
2133
- onDragend: (k) => r(h, k)
2135
+ onDragstart: (S) => u(g, S),
2136
+ onDragend: (S) => r(g, S)
2134
2137
  }, [
2135
- h.icon ? (u(), f(Z(o(we)(h.icon)), { key: 0 })) : y("", !0),
2136
- h.title ? (u(), V("span", wo, O(h.title), 1)) : y("", !0)
2137
- ], 40, _o)
2138
+ g.icon ? (c(), m(L(n(Ee)(g.icon)), { key: 0 })) : v("", !0),
2139
+ g.title ? (c(), A("span", Rn, j(g.title), 1)) : v("", !0)
2140
+ ], 40, Pn)
2138
2141
  ]),
2139
- default: d(() => [
2140
- b(o(je), {
2141
- items: n(h),
2142
+ default: p(() => [
2143
+ k(n(Ke), {
2144
+ items: o(g),
2142
2145
  mode: "text",
2143
2146
  size: "small",
2144
2147
  type: "info",
2145
- onClick: i
2148
+ onClick: l
2146
2149
  }, null, 8, ["items"])
2147
2150
  ]),
2148
2151
  _: 2
@@ -2157,20 +2160,20 @@ const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -
2157
2160
  _: 1
2158
2161
  }, 512));
2159
2162
  }
2160
- }), xo = /* @__PURE__ */ B({
2163
+ }), On = /* @__PURE__ */ E({
2161
2164
  __name: "ThemeSwitch",
2162
2165
  setup(a) {
2163
- const e = _n();
2164
- return (t, n) => (u(), f(o(lt), {
2166
+ const t = Do();
2167
+ return (e, o) => (c(), m(n(Xe), {
2165
2168
  class: "x-mask-theme-switch",
2166
- modelValue: o(e),
2167
- "onUpdate:modelValue": n[0] || (n[0] = (s) => ye(e) ? e.value = s : null),
2169
+ modelValue: n(t),
2170
+ "onUpdate:modelValue": o[0] || (o[0] = (s) => xe(t) ? t.value = s : null),
2168
2171
  size: "default",
2169
- "active-action-icon": o(ln),
2170
- "inactive-action-icon": o(rn)
2172
+ "active-action-icon": n(wo),
2173
+ "inactive-action-icon": n(xo)
2171
2174
  }, null, 8, ["modelValue", "active-action-icon", "inactive-action-icon"]));
2172
2175
  }
2173
- }), zo = { class: "x-mask-toolbar__menu-item" }, So = /* @__PURE__ */ B({
2176
+ }), jn = { class: "x-mask-toolbar__menu-item" }, Nn = /* @__PURE__ */ E({
2174
2177
  __name: "Toolbar",
2175
2178
  props: {
2176
2179
  tabs: { default: () => [] },
@@ -2185,12 +2188,12 @@ const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -
2185
2188
  "actionClick",
2186
2189
  "actionCommand"
2187
2190
  ],
2188
- setup(a, { emit: e }) {
2189
- const t = a, n = v(() => {
2190
- const r = t.tabs.map((p, m) => ({
2191
- divided: m === 0,
2192
- label: p.title,
2193
- command: p
2191
+ setup(a, { emit: t }) {
2192
+ const e = a, o = h(() => {
2193
+ const r = e.tabs.map((d, f) => ({
2194
+ divided: f === 0,
2195
+ label: d.title,
2196
+ command: d
2194
2197
  }));
2195
2198
  return [
2196
2199
  {
@@ -2204,126 +2207,126 @@ const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -
2204
2207
  ...r
2205
2208
  ];
2206
2209
  }), s = (r) => {
2207
- e("closeTab", r.command);
2208
- }, l = (r) => {
2210
+ t("closeTab", r.command);
2211
+ }, i = (r) => {
2209
2212
  switch (r.command) {
2210
2213
  case "all":
2211
- e("closeAllTabs");
2214
+ t("closeAllTabs");
2212
2215
  break;
2213
2216
  case "other":
2214
- e("closeOtherTabs");
2217
+ t("closeOtherTabs");
2215
2218
  break;
2216
2219
  default:
2217
- e("clickTab", r.command);
2220
+ t("clickTab", r.command);
2218
2221
  break;
2219
2222
  }
2220
- }, i = (r) => {
2221
- e("actionClick", r);
2222
- }, c = (r, p) => {
2223
- e("actionCommand", r, p);
2223
+ }, l = (r) => {
2224
+ t("actionClick", r);
2225
+ }, u = (r, d) => {
2226
+ t("actionCommand", r, d);
2224
2227
  };
2225
- return (r, p) => (u(), f(o(M), {
2228
+ return (r, d) => (c(), m(n(I), {
2226
2229
  class: "x-mask-toolbar",
2227
2230
  align: "center"
2228
2231
  }, {
2229
- default: d(() => [
2230
- b(o(Q), {
2231
- icon: o(cn),
2232
- menus: n.value,
2232
+ default: p(() => [
2233
+ k(n(J), {
2234
+ icon: n(So),
2235
+ menus: o.value,
2233
2236
  dropdown: { size: "small" },
2234
2237
  mode: "icon",
2235
2238
  circle: "",
2236
2239
  background: "hover",
2237
- onCommand: l
2240
+ onCommand: i
2238
2241
  }, {
2239
- item: d(({ item: m }) => [
2240
- $("span", zo, [
2241
- N(O(m.label) + " ", 1),
2242
- ["other", "all"].includes(m.command) ? y("", !0) : (u(), f(o(te), {
2242
+ item: p(({ item: f }) => [
2243
+ O("span", jn, [
2244
+ N(j(f.label) + " ", 1),
2245
+ ["other", "all"].includes(f.command) ? v("", !0) : (c(), m(n(te), {
2243
2246
  key: 0,
2244
- onClick: At((h) => s(m), ["stop"]),
2245
- icon: o(ut)
2247
+ onClick: Rt((g) => s(f), ["stop"]),
2248
+ icon: n(ft)
2246
2249
  }, null, 8, ["onClick", "icon"]))
2247
2250
  ])
2248
2251
  ]),
2249
2252
  _: 1
2250
2253
  }, 8, ["icon", "menus"]),
2251
- b(o(ue), { direction: "vertical" }),
2252
- t.actions ? (u(), f(o(je), {
2254
+ k(n(ge), { direction: "vertical" }),
2255
+ e.actions ? (c(), m(n(Ke), {
2253
2256
  key: 0,
2254
2257
  circle: "",
2255
2258
  mode: "icon",
2256
2259
  size: "default",
2257
2260
  background: "hover",
2258
2261
  items: r.actions,
2259
- onClick: i,
2260
- onCommand: c
2261
- }, null, 8, ["items"])) : y("", !0),
2262
- t.actions ? (u(), f(o(ue), {
2262
+ onClick: l,
2263
+ onCommand: u
2264
+ }, null, 8, ["items"])) : v("", !0),
2265
+ e.actions ? (c(), m(n(ge), {
2263
2266
  key: 1,
2264
2267
  direction: "vertical"
2265
- })) : y("", !0),
2266
- t.theme ? (u(), f(xo, { key: 2 })) : y("", !0),
2267
- t.theme ? (u(), f(o(ue), {
2268
+ })) : v("", !0),
2269
+ e.theme ? (c(), m(On, { key: 2 })) : v("", !0),
2270
+ e.theme ? (c(), m(n(ge), {
2268
2271
  key: 3,
2269
2272
  direction: "vertical"
2270
- })) : y("", !0),
2273
+ })) : v("", !0),
2271
2274
  z(r.$slots, "default")
2272
2275
  ]),
2273
2276
  _: 3
2274
2277
  }));
2275
2278
  }
2276
- }), Co = /* @__PURE__ */ B({
2279
+ }), Xn = /* @__PURE__ */ E({
2277
2280
  __name: "Avatar",
2278
2281
  props: {
2279
2282
  avatar: {}
2280
2283
  },
2281
2284
  setup(a) {
2282
- const e = a;
2283
- return (t, n) => (u(), f(o(it), {
2285
+ const t = a;
2286
+ return (e, o) => (c(), m(n(ut), {
2284
2287
  width: 200,
2285
2288
  "popper-class": "x-mask-avatar__popper",
2286
- disabled: !t.$slots.default
2289
+ disabled: !e.$slots.default
2287
2290
  }, {
2288
- reference: d(() => [
2289
- b(o(Zt), {
2291
+ reference: p(() => [
2292
+ k(n(Yt), {
2290
2293
  class: "x-mask-avatar",
2291
2294
  shape: "circle",
2292
- icon: o(un),
2293
- src: e.avatar,
2295
+ icon: n(zo),
2296
+ src: t.avatar,
2294
2297
  size: 26
2295
2298
  }, null, 8, ["icon", "src"])
2296
2299
  ]),
2297
- default: d(() => [
2298
- t.$slots.default ? z(t.$slots, "default", { key: 0 }) : y("", !0)
2300
+ default: p(() => [
2301
+ e.$slots.default ? z(e.$slots, "default", { key: 0 }) : v("", !0)
2299
2302
  ]),
2300
2303
  _: 3
2301
2304
  }, 8, ["disabled"]));
2302
2305
  }
2303
- }), Ye = /* @__PURE__ */ B({
2306
+ }), at = /* @__PURE__ */ E({
2304
2307
  __name: "Content",
2305
2308
  props: {
2306
2309
  createView: { type: Function },
2307
2310
  exclude: {}
2308
2311
  },
2309
2312
  setup(a) {
2310
- const e = a;
2311
- return (t, n) => (u(), f(o(M), {
2313
+ const t = a;
2314
+ return (e, o) => (c(), m(n(I), {
2312
2315
  class: "x-mask__content",
2313
2316
  flex: !1,
2314
2317
  grow: "",
2315
2318
  padding: !1
2316
2319
  }, {
2317
- default: d(() => [
2318
- z(t.$slots, "default"),
2319
- b(o(pt), null, {
2320
- default: d(({ Component: s, route: l }) => [
2321
- (u(), f(Dt, {
2322
- exclude: e.exclude
2320
+ default: p(() => [
2321
+ z(e.$slots, "default"),
2322
+ k(n(gt), null, {
2323
+ default: p(({ Component: s, route: i }) => [
2324
+ (c(), m(Ft, {
2325
+ exclude: t.exclude
2323
2326
  }, [
2324
- s ? (u(), f(Z(e.createView(s, l)), {
2325
- key: l.fullPath
2326
- })) : y("", !0)
2327
+ s ? (c(), m(L(t.createView(s, i)), {
2328
+ key: i.fullPath
2329
+ })) : v("", !0)
2327
2330
  ], 1032, ["exclude"]))
2328
2331
  ]),
2329
2332
  _: 1
@@ -2332,13 +2335,13 @@ const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -
2332
2335
  _: 3
2333
2336
  }));
2334
2337
  }
2335
- }), To = 140, Mo = {
2338
+ }), Un = 140, Hn = {
2336
2339
  /**
2337
2340
  * 系统logo
2338
2341
  */
2339
2342
  logo: {
2340
2343
  type: String,
2341
- default: vt
2344
+ default: bt
2342
2345
  },
2343
2346
  /**
2344
2347
  * 系统标题
@@ -2415,382 +2418,382 @@ const uo = /* @__PURE__ */ $("div", { class: "x-mask-sidebar__helper" }, null, -
2415
2418
  removeFavorite: {
2416
2419
  type: Function
2417
2420
  }
2418
- }, St = Symbol(), Ct = Symbol();
2419
- function Eo(a) {
2420
- const e = R(!1), t = R(""), n = R(!1);
2421
+ }, Ct = Symbol(), Tt = Symbol();
2422
+ function Wn(a) {
2423
+ const t = P(!1), e = P(""), o = P(!1);
2421
2424
  return {
2422
- collapsed: e,
2423
- keyword: t,
2424
- favorite: n
2425
+ collapsed: t,
2426
+ keyword: e,
2427
+ favorite: o
2425
2428
  };
2426
2429
  }
2427
- function Io(a) {
2428
- const e = ht();
2429
- return v(() => {
2430
- const t = a.home;
2430
+ function Ln(a) {
2431
+ const t = ht();
2432
+ return h(() => {
2433
+ const e = a.home;
2431
2434
  return Object.assign(
2432
- { id: e, url: "/", name: "MaskHome", icon: dn, closable: !1 },
2433
- typeof t == "string" ? { url: t } : t || {}
2435
+ { id: t, url: "/", name: "MaskHome", icon: Co, closable: !1 },
2436
+ typeof e == "string" ? { url: e } : e || {}
2434
2437
  );
2435
2438
  });
2436
2439
  }
2437
- function Tt(a, e) {
2438
- let t = [];
2439
- return a.forEach((n) => {
2440
- n = e ? e(n) : n, n.children ? t = t.concat(Tt(n.children, e)) : t.push(n);
2441
- }), t;
2440
+ function Et(a, t) {
2441
+ let e = [];
2442
+ return a.forEach((o) => {
2443
+ o = t ? t(o) : o, o.children ? e = e.concat(Et(o.children, t)) : e.push(o);
2444
+ }), e;
2442
2445
  }
2443
- function Bo(a, e) {
2444
- const t = xe(), n = Ue([]), s = Ue([]), l = v(() => Tt(n.value, a.menuAdapter)), i = v(() => wn(l.value, "id")), c = R(null), r = (_) => {
2445
- const w = typeof _ == "object" ? _.id : _, E = i.value.get(w);
2446
- if (!E) {
2447
- console.warn("找不到菜单", _);
2446
+ function Kn(a, t) {
2447
+ const e = Ie(), o = Je([]), s = Je([]), i = h(() => Et(o.value, a.menuAdapter)), l = h(() => Po(i.value, "id")), u = P(null), r = (w) => {
2448
+ const _ = typeof w == "object" ? w.id : w, T = l.value.get(_);
2449
+ if (!T) {
2450
+ console.warn("找不到菜单", w);
2448
2451
  return;
2449
2452
  }
2450
- const { type: D = "route", url: g, title: I, icon: C } = E;
2451
- if (!g) {
2452
- c.value = E, e("select", E);
2453
+ const { type: V = "route", url: y, title: M, icon: b } = T;
2454
+ if (!y) {
2455
+ u.value = T, t("select", T);
2453
2456
  return;
2454
2457
  }
2455
- if (D === "route") {
2456
- kn(g) || g.startsWith("//") ? window.open(g) : (c.value = E, t.push(g).catch((F) => F));
2458
+ if (V === "route") {
2459
+ Ro(y) || y.startsWith("//") ? window.open(y) : (u.value = T, e.push(y).catch((D) => D));
2457
2460
  return;
2458
2461
  }
2459
- if (D === "window") {
2460
- window.open(g);
2462
+ if (V === "window") {
2463
+ window.open(y);
2461
2464
  return;
2462
2465
  }
2463
- D === "dialog" && Ne({
2466
+ V === "dialog" && Qe({
2464
2467
  resizable: !0,
2465
2468
  bodyPadding: !1,
2466
2469
  width: "80%",
2467
2470
  height: "80%",
2468
- title: I,
2469
- icon: C,
2470
- src: g
2471
+ title: M,
2472
+ icon: b,
2473
+ src: y
2471
2474
  });
2472
- }, p = async () => {
2473
- n.value = typeof a.menus == "function" ? await a.menus() || [] : a.menus ?? [], s.value = typeof a.favorites == "function" ? await a.favorites() || [] : a.favorites ?? [];
2474
- }, m = (_) => {
2475
- s.value = [_, ...s.value], a.addFavorite && a.addFavorite(_);
2476
- }, h = (_) => {
2477
- s.value = s.value.filter((w) => w.id !== _.id), a.removeFavorite && a.removeFavorite(_);
2478
- }, k = (_) => !!s.value.find((w) => w === _ || w.id === _.id), A = (_) => {
2479
- k(_) ? h(_) : m(_);
2475
+ }, d = async () => {
2476
+ o.value = typeof a.menus == "function" ? await a.menus() || [] : a.menus ?? [], s.value = typeof a.favorites == "function" ? await a.favorites() || [] : a.favorites ?? [];
2477
+ }, f = (w) => {
2478
+ s.value = [w, ...s.value], a.addFavorite && a.addFavorite(w);
2479
+ }, g = (w) => {
2480
+ s.value = s.value.filter((_) => _.id !== w.id), a.removeFavorite && a.removeFavorite(w);
2481
+ }, S = (w) => !!s.value.find((_) => _ === w || _.id === w.id), $ = (w) => {
2482
+ S(w) ? g(w) : f(w);
2480
2483
  };
2481
- return ot(p), {
2482
- menus: n,
2484
+ return it(d), {
2485
+ menus: o,
2483
2486
  favorites: s,
2484
- flatMenus: l,
2485
- active: c,
2487
+ flatMenus: i,
2488
+ active: u,
2486
2489
  select: r,
2487
- toggleFavorite: A
2490
+ toggleFavorite: $
2488
2491
  };
2489
2492
  }
2490
- function Ao(a, e, t, n, s) {
2491
- const l = Fe(), i = xe(), c = {}, r = R([]), p = R(), { width: m } = ft(p), h = v(() => Math.floor(m.value / To)), k = v(
2492
- () => r.value.slice(0, h.value).filter((x) => !x.dialog)
2493
- ), A = v(() => r.value.slice(h.value)), _ = (x) => t.value.find((S) => S.url === x), w = (x) => l.fullPath === x.url, E = (x) => s.value.id === x ? s.value : r.value.find((S) => S.id === x), D = R(""), g = v(() => E(D.value)), I = (x) => {
2494
- i.push(x.url).catch((S) => S);
2495
- }, C = (x) => {
2496
- D.value = x.id, l.fullPath !== x.url && I(x);
2497
- }, F = () => {
2498
- I(s.value);
2499
- }, H = (x) => {
2500
- const S = r.value.find((T) => T.url === x.url || T.id === x.id);
2501
- S ? C(S) : (r.value.unshift(x), C(x));
2502
- }, ne = async (x) => {
2503
- const { url: S = l.fullPath, icon: T, title: Se = "新建标签页" } = x || {}, fe = c[S], Ce = ht(), Te = yt(S);
2493
+ function Qn(a, t, e, o, s) {
2494
+ const i = Ue(), l = Ie(), u = {}, r = P([]), d = P(), { width: f } = yt(d), g = h(() => Math.floor(f.value / Un)), S = h(
2495
+ () => r.value.slice(0, g.value).filter((x) => !x.dialog)
2496
+ ), $ = h(() => r.value.slice(g.value)), w = (x) => e.value.find((C) => C.url === x), _ = (x) => i.fullPath === x.url, T = (x) => s.value.id === x ? s.value : r.value.find((C) => C.id === x), V = P(""), y = h(() => T(V.value)), M = (x) => {
2497
+ l.push(x.url).catch((C) => C);
2498
+ }, b = (x) => {
2499
+ V.value = x.id, i.fullPath !== x.url && M(x);
2500
+ }, D = () => {
2501
+ M(s.value);
2502
+ }, R = (x) => {
2503
+ const C = r.value.find((B) => B.url === x.url || B.id === x.id);
2504
+ C ? b(C) : (r.value.unshift(x), b(x));
2505
+ }, oe = async (x) => {
2506
+ const { url: C = i.fullPath, icon: B, title: Ae = "新建标签页" } = x || {}, be = u[C], $e = ht(), Ve = vt(C);
2504
2507
  return {
2505
- id: Ce,
2506
- name: Te,
2507
- url: S,
2508
- icon: T,
2509
- title: Se,
2508
+ id: $e,
2509
+ name: Ve,
2510
+ url: C,
2511
+ icon: B,
2512
+ title: Ae,
2510
2513
  closable: !0,
2511
2514
  menu: x,
2512
- ...fe ? await fe() : {}
2515
+ ...be ? await be() : {}
2513
2516
  };
2514
- }, oe = async (x) => {
2515
- if (await Me.confirm("是否关闭页签", "提示", {
2517
+ }, ne = async (x) => {
2518
+ if (await De.confirm("是否关闭页签", "提示", {
2516
2519
  type: "warning"
2517
- }).catch((T) => !1)) {
2518
- if (r.value = r.value.filter((T) => T.id !== x.id), D.value === x.id) {
2519
- const T = r.value[0];
2520
- I(T || s.value);
2520
+ }).catch((B) => !1)) {
2521
+ if (r.value = r.value.filter((B) => B.id !== x.id), V.value === x.id) {
2522
+ const B = r.value[0];
2523
+ M(B || s.value);
2521
2524
  }
2522
2525
  return x;
2523
2526
  }
2524
- }, j = (x) => {
2525
- const S = r.value.findIndex((T) => T.id === x.id);
2526
- if (S >= 0) {
2527
- const T = r.value[S];
2528
- r.value.splice(S, 1, Object.assign(T, x));
2527
+ }, ae = (x) => {
2528
+ const C = r.value.findIndex((B) => B.id === x.id);
2529
+ if (C >= 0) {
2530
+ const B = r.value[C];
2531
+ r.value.splice(C, 1, Object.assign(B, x));
2529
2532
  }
2530
- }, L = async () => {
2531
- if (!await Me.confirm("是否关闭全部页签", "提示", {
2533
+ }, U = async () => {
2534
+ if (!await De.confirm("是否关闭全部页签", "提示", {
2532
2535
  type: "warning"
2533
- }).catch((T) => !1))
2536
+ }).catch((B) => !1))
2534
2537
  return;
2535
- const S = r.value;
2536
- return r.value = [], C(s.value), S;
2537
- }, se = async () => {
2538
- if (!await Me.confirm("是否关闭其他页签", "提示", {
2538
+ const C = r.value;
2539
+ return r.value = [], b(s.value), C;
2540
+ }, Z = async () => {
2541
+ if (!await De.confirm("是否关闭其他页签", "提示", {
2539
2542
  type: "warning"
2540
- }).catch((T) => !1))
2543
+ }).catch((B) => !1))
2541
2544
  return;
2542
- const S = r.value.filter((T) => T.id !== D.value);
2543
- return r.value = r.value.filter((T) => T.id === D.value), S;
2544
- }, ze = (x) => {
2545
- const S = r.value.filter((T) => T.id !== x.id);
2546
- r.value = [x, ...S], C(x);
2547
- }, re = async () => {
2548
- await le();
2549
- const x = s.value.url === l.fullPath, S = _(l.fullPath);
2545
+ const C = r.value.filter((B) => B.id !== V.value);
2546
+ return r.value = r.value.filter((B) => B.id === V.value), C;
2547
+ }, re = (x) => {
2548
+ const C = r.value.filter((B) => B.id !== x.id);
2549
+ r.value = [x, ...C], b(x);
2550
+ }, pe = async () => {
2551
+ await ce();
2552
+ const x = s.value.url === i.fullPath, C = w(i.fullPath);
2550
2553
  if (x)
2551
- D.value = s.value.id;
2554
+ V.value = s.value.id;
2552
2555
  else {
2553
- const T = await ne(S);
2554
- H(T);
2556
+ const B = await oe(C);
2557
+ R(B);
2555
2558
  }
2556
- await le(), n.value = S || null;
2559
+ await ce(), o.value = C || null;
2557
2560
  };
2558
- return ee(t, re), ee(l, re, { immediate: !0 }), Re(St, c), {
2559
- tabRef: p,
2561
+ return H(e, pe), H(i, pe, { immediate: !0 }), he(Ct, u), {
2562
+ tabRef: d,
2560
2563
  tabs: r,
2561
- showTabs: k,
2562
- currentTab: g,
2563
- changeTab: I,
2564
- removeTab: oe,
2565
- updateTab: j,
2566
- addTab: H,
2564
+ showTabs: S,
2565
+ currentTab: y,
2566
+ changeTab: M,
2567
+ removeTab: ne,
2568
+ updateTab: ae,
2569
+ addTab: R,
2567
2570
  home: s,
2568
- tabValue: D,
2569
- isCurrentTab: w,
2570
- activeHome: F,
2571
- activeTab: C,
2572
- dropdownTabs: A,
2573
- removeAllTabs: L,
2574
- removeOtherTabs: se,
2575
- moveToShow: ze
2571
+ tabValue: V,
2572
+ isCurrentTab: _,
2573
+ activeHome: D,
2574
+ activeTab: b,
2575
+ dropdownTabs: $,
2576
+ removeAllTabs: U,
2577
+ removeOtherTabs: Z,
2578
+ moveToShow: re
2576
2579
  };
2577
2580
  }
2578
- function Do(a) {
2579
- const e = /* @__PURE__ */ new Map(), t = R([]), n = nt({}), s = {}, { updateTab: l, isCurrentTab: i, activeHome: c, tabs: r } = a, p = (g, I) => {
2580
- const C = I.fullPath;
2581
- if (e.has(C))
2582
- return e.get(C);
2581
+ function Zn(a) {
2582
+ const t = /* @__PURE__ */ new Map(), e = P([]), o = Ne({}), s = {}, { updateTab: i, isCurrentTab: l, activeHome: u, tabs: r } = a, d = (y, M) => {
2583
+ const b = M.fullPath;
2584
+ if (t.has(b))
2585
+ return t.get(b);
2583
2586
  {
2584
- const F = yt(C), H = {
2585
- name: F,
2587
+ const D = vt(b), R = {
2588
+ name: D,
2586
2589
  setup() {
2587
- const ne = v(() => n[C] || document.body), oe = v(() => !n[C]), j = v(() => !t.value.includes(F));
2588
- return Re(
2589
- fn,
2590
- Vt({ ...I })
2591
- ), () => j.value ? Y(
2592
- at,
2590
+ const oe = h(() => o[b] || document.body), ne = h(() => !o[b]), ae = h(() => !e.value.includes(D));
2591
+ return he(
2592
+ Eo,
2593
+ Se({ ...M })
2594
+ ), () => ae.value ? q(
2595
+ rt,
2593
2596
  {
2594
- to: ne.value,
2595
- disabled: oe.value
2597
+ to: oe.value,
2598
+ disabled: ne.value
2596
2599
  },
2597
- [Y(g)]
2600
+ [q(y)]
2598
2601
  ) : null;
2599
2602
  }
2600
2603
  };
2601
- return e.set(C, H), H;
2604
+ return t.set(b, R), R;
2602
2605
  }
2603
- }, m = (g) => {
2604
- g.dialog = void 0, delete n[g.url];
2605
- const I = s[g.id];
2606
- I && (I.destroy(), delete s[g.id], l(g));
2607
- }, h = (g = []) => {
2608
- g.forEach((I) => {
2609
- m(I);
2606
+ }, f = (y) => {
2607
+ y.dialog = void 0, delete o[y.url];
2608
+ const M = s[y.id];
2609
+ M && (M.destroy(), delete s[y.id], i(y));
2610
+ }, g = (y = []) => {
2611
+ y.forEach((M) => {
2612
+ f(M);
2610
2613
  });
2611
- }, k = async (g) => {
2612
- g.dialog = {
2613
- ...g.dialog,
2614
+ }, S = async (y) => {
2615
+ y.dialog = {
2616
+ ...y.dialog,
2614
2617
  onMinimized: () => {
2615
- m(g);
2618
+ f(y);
2616
2619
  },
2617
2620
  onClose: async () => {
2618
- m(g), r.value = r.value.filter((C) => C.id !== g.id);
2621
+ f(y), r.value = r.value.filter((b) => b.id !== y.id);
2619
2622
  }
2620
- }, l(g);
2621
- const I = Ne({
2622
- title: g.title,
2623
- icon: g.icon,
2623
+ }, i(y);
2624
+ const M = Qe({
2625
+ title: y.title,
2626
+ icon: y.icon,
2624
2627
  modal: !1,
2625
2628
  resizable: !0,
2626
2629
  draggable: !0,
2627
- ...g.dialog,
2628
- onOpen(C) {
2629
- n[g.url] = C.refs.panelRef?.bodyRef?.$el;
2630
+ ...y.dialog,
2631
+ onOpen(b) {
2632
+ o[y.url] = b.refs.panelRef?.bodyRef?.$el;
2630
2633
  }
2631
2634
  });
2632
- return await le(), i(g) && c(), s[g.id] = I, I;
2633
- }, A = async (g) => {
2634
- t.value = [g.name], await le(), t.value = [];
2635
- }, _ = async (g) => {
2636
- t.value = g.map((I) => I.name), await le(), t.value = [];
2637
- }, w = (g) => (g.preventDefault(), !1), E = (g) => {
2638
- if (g.dataTransfer) {
2639
- const I = g.dataTransfer.getData("tab"), C = r.value.find((F) => F.id === I);
2640
- if (C) {
2641
- const { clientX: F, clientY: H } = g;
2642
- C.dialog = {
2643
- left: F,
2644
- top: H
2645
- }, k(C);
2635
+ return await ce(), l(y) && u(), s[y.id] = M, M;
2636
+ }, $ = async (y) => {
2637
+ e.value = [y.name], await ce(), e.value = [];
2638
+ }, w = async (y) => {
2639
+ e.value = y.map((M) => M.name), await ce(), e.value = [];
2640
+ }, _ = (y) => (y.preventDefault(), !1), T = (y) => {
2641
+ if (y.dataTransfer) {
2642
+ const M = y.dataTransfer.getData("tab"), b = r.value.find((D) => D.id === M);
2643
+ if (b) {
2644
+ const { clientX: D, clientY: R } = y;
2645
+ b.dialog = {
2646
+ left: D,
2647
+ top: R
2648
+ }, S(b);
2646
2649
  }
2647
2650
  }
2648
- }, D = (g) => !!n[g];
2649
- return _e(document, "dragover", w), _e(document, "drop", E), {
2650
- createView: p,
2651
- openDialog: k,
2652
- refresh: A,
2653
- exclude: t,
2654
- cleanCache: _,
2655
- hasDialog: D,
2656
- closeDialog: m,
2657
- closeDialogs: h
2651
+ }, V = (y) => !!o[y];
2652
+ return Te(document, "dragover", _), Te(document, "drop", T), {
2653
+ createView: d,
2654
+ openDialog: S,
2655
+ refresh: $,
2656
+ exclude: e,
2657
+ cleanCache: w,
2658
+ hasDialog: V,
2659
+ closeDialog: f,
2660
+ closeDialogs: g
2658
2661
  };
2659
2662
  }
2660
- const Vo = /* @__PURE__ */ B({
2663
+ const Jn = /* @__PURE__ */ E({
2661
2664
  name: "XMask",
2662
2665
  __name: "Mask",
2663
- props: Mo,
2666
+ props: Hn,
2664
2667
  emits: ["select", "actionClick", "actionCommand"],
2665
- setup(a, { emit: e }) {
2666
- const t = a, n = Io(t), { collapsed: s, keyword: l, favorite: i } = Eo(), { menus: c, favorites: r, flatMenus: p, active: m, select: h, toggleFavorite: k } = Bo(t, e), {
2667
- tabRef: A,
2668
- showTabs: _,
2669
- currentTab: w,
2670
- changeTab: E,
2671
- removeTab: D,
2672
- tabs: g,
2673
- updateTab: I,
2674
- isCurrentTab: C,
2675
- activeHome: F,
2676
- removeAllTabs: H,
2677
- removeOtherTabs: ne,
2678
- dropdownTabs: oe,
2679
- moveToShow: j
2680
- } = Ao(t, e, p, m, n), { createView: L, openDialog: se, refresh: ze, exclude: re, cleanCache: x, closeDialogs: S } = Do({
2681
- tabs: g,
2682
- updateTab: I,
2683
- isCurrentTab: C,
2684
- activeHome: F
2685
- }), T = async (P) => {
2686
- await D(P) && await x([P]);
2687
- }, Se = async () => {
2688
- const P = await H();
2689
- P && (S(P), await x(P));
2690
- }, fe = async () => {
2691
- const P = await ne();
2692
- P && (S(P), await x(P));
2693
- }, Ce = (P) => {
2694
- e("actionClick", P);
2695
- }, Te = (P, J) => {
2696
- e("actionCommand", P, J);
2668
+ setup(a, { emit: t }) {
2669
+ const e = a, o = Ln(e), { collapsed: s, keyword: i, favorite: l } = Wn(), { menus: u, favorites: r, flatMenus: d, active: f, select: g, toggleFavorite: S } = Kn(e, t), {
2670
+ tabRef: $,
2671
+ showTabs: w,
2672
+ currentTab: _,
2673
+ changeTab: T,
2674
+ removeTab: V,
2675
+ tabs: y,
2676
+ updateTab: M,
2677
+ isCurrentTab: b,
2678
+ activeHome: D,
2679
+ removeAllTabs: R,
2680
+ removeOtherTabs: oe,
2681
+ dropdownTabs: ne,
2682
+ moveToShow: ae
2683
+ } = Qn(e, t, d, f, o), { createView: U, openDialog: Z, refresh: re, exclude: pe, cleanCache: x, closeDialogs: C } = Zn({
2684
+ tabs: y,
2685
+ updateTab: M,
2686
+ isCurrentTab: b,
2687
+ activeHome: D
2688
+ }), B = async (F) => {
2689
+ await V(F) && await x([F]);
2690
+ }, Ae = async () => {
2691
+ const F = await R();
2692
+ F && (C(F), await x(F));
2693
+ }, be = async () => {
2694
+ const F = await oe();
2695
+ F && (C(F), await x(F));
2696
+ }, $e = (F) => {
2697
+ t("actionClick", F);
2698
+ }, Ve = (F, G) => {
2699
+ t("actionCommand", F, G);
2697
2700
  };
2698
- return Re(Ct, {
2699
- tabs: g,
2700
- flatMenus: p,
2701
+ return he(Tt, {
2702
+ tabs: y,
2703
+ flatMenus: d,
2701
2704
  favorites: r,
2702
- updateTab: I,
2703
- active: m,
2704
- currentTab: w
2705
- }), (P, J) => (u(), f(o(M), { class: "x-mask" }, {
2706
- default: d(() => [
2707
- t.disabled ? (u(), f(Ye, {
2705
+ updateTab: M,
2706
+ active: f,
2707
+ currentTab: _
2708
+ }), (F, G) => (c(), m(n(I), { class: "x-mask" }, {
2709
+ default: p(() => [
2710
+ e.disabled ? (c(), m(at, {
2708
2711
  key: 1,
2709
- createView: o(L),
2710
- exclude: o(re)
2712
+ createView: n(U),
2713
+ exclude: n(pe)
2711
2714
  }, {
2712
- default: d(() => [
2713
- P.$slots.default ? z(P.$slots, "default", { key: 0 }) : y("", !0)
2715
+ default: p(() => [
2716
+ F.$slots.default ? z(F.$slots, "default", { key: 0 }) : v("", !0)
2714
2717
  ]),
2715
2718
  _: 3
2716
- }, 8, ["createView", "exclude"])) : (u(), V(q, { key: 0 }, [
2717
- b(po, { collapsed: o(s) }, {
2718
- brand: d(() => [
2719
- b(ho, {
2720
- logo: t.logo,
2721
- title: t.title,
2722
- url: o(n).url,
2723
- collapsed: o(s)
2719
+ }, 8, ["createView", "exclude"])) : (c(), A(Q, { key: 0 }, [
2720
+ k(En, { collapsed: n(s) }, {
2721
+ brand: p(() => [
2722
+ k(An, {
2723
+ logo: e.logo,
2724
+ title: e.title,
2725
+ url: n(o).url,
2726
+ collapsed: n(s)
2724
2727
  }, null, 8, ["logo", "title", "url", "collapsed"])
2725
2728
  ]),
2726
- default: d(() => [
2727
- b(fo, {
2728
- collasped: o(s),
2729
- "onUpdate:collasped": J[0] || (J[0] = (ce) => ye(s) ? s.value = ce : null),
2730
- favorite: o(i),
2731
- "onUpdate:favorite": J[1] || (J[1] = (ce) => ye(i) ? i.value = ce : null),
2732
- keyword: o(l),
2733
- "onUpdate:keyword": J[2] || (J[2] = (ce) => ye(l) ? l.value = ce : null)
2729
+ default: p(() => [
2730
+ k(Mn, {
2731
+ collasped: n(s),
2732
+ "onUpdate:collasped": G[0] || (G[0] = (fe) => xe(s) ? s.value = fe : null),
2733
+ favorite: n(l),
2734
+ "onUpdate:favorite": G[1] || (G[1] = (fe) => xe(l) ? l.value = fe : null),
2735
+ keyword: n(i),
2736
+ "onUpdate:keyword": G[2] || (G[2] = (fe) => xe(i) ? i.value = fe : null)
2734
2737
  }, null, 8, ["collasped", "favorite", "keyword"]),
2735
- b(yo, {
2736
- collapse: o(s),
2737
- keyword: o(l),
2738
- favorite: o(i),
2739
- favorites: o(r),
2740
- flatMenus: o(p),
2741
- menus: o(c),
2742
- active: o(m),
2743
- onSelect: o(h)
2738
+ k($n, {
2739
+ collapse: n(s),
2740
+ keyword: n(i),
2741
+ favorite: n(l),
2742
+ favorites: n(r),
2743
+ flatMenus: n(d),
2744
+ menus: n(u),
2745
+ active: n(f),
2746
+ onSelect: n(g)
2744
2747
  }, null, 8, ["collapse", "keyword", "favorite", "favorites", "flatMenus", "menus", "active", "onSelect"])
2745
2748
  ]),
2746
2749
  _: 1
2747
2750
  }, 8, ["collapsed"]),
2748
- b(o(M), {
2751
+ k(n(I), {
2749
2752
  class: "x-mask__main",
2750
2753
  grow: "",
2751
2754
  shrink: "",
2752
2755
  flex: "",
2753
2756
  direction: "column"
2754
2757
  }, {
2755
- default: d(() => [
2756
- b(o(M), {
2758
+ default: p(() => [
2759
+ k(n(I), {
2757
2760
  class: "x-mask-topbar",
2758
2761
  justify: "space-between",
2759
2762
  align: "center"
2760
2763
  }, {
2761
- default: d(() => [
2762
- b(ko, {
2764
+ default: p(() => [
2765
+ k(Fn, {
2763
2766
  ref_key: "tabRef",
2764
- ref: A,
2765
- favorites: o(r),
2766
- tabs: o(_),
2767
- home: o(n),
2768
- value: o(w)?.id,
2769
- onClick: o(E),
2770
- onToggleFavorite: o(k),
2771
- onRemove: T,
2772
- onDialog: o(se),
2773
- onRefresh: o(ze)
2767
+ ref: $,
2768
+ favorites: n(r),
2769
+ tabs: n(w),
2770
+ home: n(o),
2771
+ value: n(_)?.id,
2772
+ onClick: n(T),
2773
+ onToggleFavorite: n(S),
2774
+ onRemove: B,
2775
+ onDialog: n(Z),
2776
+ onRefresh: n(re)
2774
2777
  }, null, 8, ["favorites", "tabs", "home", "value", "onClick", "onToggleFavorite", "onDialog", "onRefresh"]),
2775
- b(So, {
2776
- tabs: o(oe),
2777
- actions: t.actions,
2778
- theme: t.theme,
2779
- onCloseOtherTabs: fe,
2780
- onCloseAllTabs: Se,
2781
- onCloseTab: T,
2782
- onClickTab: o(j),
2783
- onActionClick: Ce,
2784
- onActionCommand: Te
2778
+ k(Nn, {
2779
+ tabs: n(ne),
2780
+ actions: e.actions,
2781
+ theme: e.theme,
2782
+ onCloseOtherTabs: be,
2783
+ onCloseAllTabs: Ae,
2784
+ onCloseTab: B,
2785
+ onClickTab: n(ae),
2786
+ onActionClick: $e,
2787
+ onActionCommand: Ve
2785
2788
  }, {
2786
- default: d(() => [
2787
- b(Co, {
2788
- avatar: t.avatar
2789
- }, $e({ _: 2 }, [
2790
- P.$slots.user ? {
2789
+ default: p(() => [
2790
+ k(Xn, {
2791
+ avatar: e.avatar
2792
+ }, ye({ _: 2 }, [
2793
+ F.$slots.user ? {
2791
2794
  name: "default",
2792
- fn: d(() => [
2793
- z(P.$slots, "user")
2795
+ fn: p(() => [
2796
+ z(F.$slots, "user")
2794
2797
  ]),
2795
2798
  key: "0"
2796
2799
  } : void 0
@@ -2801,12 +2804,12 @@ const Vo = /* @__PURE__ */ B({
2801
2804
  ]),
2802
2805
  _: 3
2803
2806
  }),
2804
- b(Ye, {
2805
- createView: o(L),
2806
- exclude: o(re)
2807
+ k(at, {
2808
+ createView: n(U),
2809
+ exclude: n(pe)
2807
2810
  }, {
2808
- default: d(() => [
2809
- P.$slots.default ? z(P.$slots, "default", { key: 0 }) : y("", !0)
2811
+ default: p(() => [
2812
+ F.$slots.default ? z(F.$slots, "default", { key: 0 }) : v("", !0)
2810
2813
  ]),
2811
2814
  _: 3
2812
2815
  }, 8, ["createView", "exclude"])
@@ -2819,240 +2822,607 @@ const Vo = /* @__PURE__ */ B({
2819
2822
  }));
2820
2823
  }
2821
2824
  });
2822
- function Yo(a = {}) {
2823
- const e = Fe(), t = Be(St, null), n = Be(Ct, null);
2824
- if (t) {
2825
- const l = typeof a == "function" ? a : async () => a;
2826
- t[e.fullPath] = l;
2825
+ function ya(a = {}) {
2826
+ const t = Ue(), e = me(Ct, null), o = me(Tt, null);
2827
+ if (e) {
2828
+ const i = typeof a == "function" ? a : async () => a;
2829
+ e[t.fullPath] = i;
2827
2830
  }
2828
2831
  return {
2829
- tab: v(() => n ? n.tabs.value.find((l) => l.url === e.fullPath) : null),
2830
- mask: n
2832
+ tab: h(() => o ? o.tabs.value.find((i) => i.url === t.fullPath) : null),
2833
+ mask: o
2831
2834
  };
2832
2835
  }
2833
- const Po = /* @__PURE__ */ B({
2836
+ const Gn = /* @__PURE__ */ E({
2834
2837
  __name: "SelectEditor",
2838
+ props: {
2839
+ options: { default: () => [] }
2840
+ },
2835
2841
  setup(a) {
2836
- return (e, t) => (u(), f(o(Jt), null, {
2837
- default: d(() => [
2838
- b(o(Kt), {
2839
- label: "Label",
2840
- value: "label"
2841
- })
2842
+ const t = a;
2843
+ return (e, o) => (c(), m(n(qt), Me(Be(e.$attrs)), {
2844
+ default: p(() => [
2845
+ (c(!0), A(Q, null, ie(t.options, (s, i) => (c(), m(n(eo), X({
2846
+ key: `item_${i}_${s.value}`
2847
+ }, s), ye({ _: 2 }, [
2848
+ e.$slots.option ? {
2849
+ name: "default",
2850
+ fn: p(() => [
2851
+ z(e.$slots, "option", { option: s })
2852
+ ]),
2853
+ key: "0"
2854
+ } : void 0
2855
+ ]), 1040))), 128))
2856
+ ]),
2857
+ _: 3
2858
+ }, 16));
2859
+ }
2860
+ }), Yn = /* @__PURE__ */ E({
2861
+ __name: "CheckboxEditor",
2862
+ props: {
2863
+ options: { default: () => [] },
2864
+ button: { type: Boolean, default: !1 }
2865
+ },
2866
+ setup(a) {
2867
+ const t = a, e = h(
2868
+ () => ve(t.button ? to : oo)
2869
+ );
2870
+ return (o, s) => (c(), m(n(no), Me(Be(o.$attrs)), {
2871
+ default: p(() => [
2872
+ (c(!0), A(Q, null, ie(t.options, (i, l) => (c(), m(L(e.value), {
2873
+ key: `item_${l}_${i.value}`,
2874
+ label: i.value
2875
+ }, {
2876
+ default: p(() => [
2877
+ N(j(i.label), 1)
2878
+ ]),
2879
+ _: 2
2880
+ }, 1032, ["label"]))), 128))
2842
2881
  ]),
2843
2882
  _: 1
2844
- }));
2883
+ }, 16));
2845
2884
  }
2846
- }), Ie = {
2885
+ }), qn = /* @__PURE__ */ E({
2886
+ __name: "RadioEditor",
2887
+ props: {
2888
+ options: { default: () => [] },
2889
+ button: { type: Boolean, default: !1 }
2890
+ },
2891
+ setup(a) {
2892
+ const t = a, e = h(
2893
+ () => ve(t.button ? ao : so)
2894
+ );
2895
+ return (o, s) => (c(), m(n(lo), Me(Be(o.$attrs)), {
2896
+ default: p(() => [
2897
+ (c(!0), A(Q, null, ie(t.options, (i, l) => (c(), m(L(e.value), {
2898
+ key: `item_${l}_${i.value}`,
2899
+ label: i.value
2900
+ }, {
2901
+ default: p(() => [
2902
+ N(j(i.label), 1)
2903
+ ]),
2904
+ _: 2
2905
+ }, 1032, ["label"]))), 128))
2906
+ ]),
2907
+ _: 1
2908
+ }, 16));
2909
+ }
2910
+ }), Mt = {
2911
+ none: {
2912
+ component: "div",
2913
+ props: {
2914
+ class: "x-field-none"
2915
+ }
2916
+ },
2847
2917
  text: {
2848
- name: De,
2918
+ component: Fe,
2849
2919
  props: {
2850
2920
  clearable: !0
2851
- }
2921
+ },
2922
+ defaultValue: ""
2852
2923
  },
2853
2924
  textarea: {
2854
- name: De,
2925
+ component: Fe,
2855
2926
  props: {
2856
2927
  type: "textarea",
2857
- rows: 2,
2858
- autosize: {
2859
- minRows: 2,
2860
- maxRows: 5
2861
- }
2862
- }
2928
+ rows: 2
2929
+ },
2930
+ defaultValue: ""
2863
2931
  },
2864
2932
  select: {
2865
- name: Po,
2933
+ component: Gn,
2866
2934
  props: {
2867
2935
  clearable: !0
2868
2936
  }
2937
+ },
2938
+ checkbox: {
2939
+ component: Yn,
2940
+ props: {},
2941
+ defaultValue: []
2942
+ },
2943
+ radio: {
2944
+ component: qn,
2945
+ props: {}
2946
+ },
2947
+ number: {
2948
+ component: io,
2949
+ props: {}
2950
+ },
2951
+ date: {
2952
+ component: qe,
2953
+ props: {}
2954
+ },
2955
+ time: {
2956
+ component: ro,
2957
+ props: {}
2958
+ },
2959
+ datetime: {
2960
+ component: qe,
2961
+ props: {
2962
+ type: "datetime"
2963
+ }
2964
+ },
2965
+ switch: {
2966
+ component: Xe,
2967
+ props: {}
2968
+ },
2969
+ rate: {
2970
+ component: co,
2971
+ props: {}
2972
+ },
2973
+ slider: {
2974
+ component: uo,
2975
+ props: {}
2976
+ },
2977
+ cascader: {
2978
+ component: po,
2979
+ props: {}
2869
2980
  }
2870
- }, $o = {
2981
+ }, ea = {
2982
+ /**
2983
+ * 字段名称
2984
+ */
2985
+ name: {
2986
+ type: String
2987
+ },
2988
+ /**
2989
+ * 字段标题文本
2990
+ */
2871
2991
  label: {
2872
2992
  type: String
2873
2993
  },
2994
+ /**
2995
+ * 编辑器组件
2996
+ */
2874
2997
  editor: {
2875
2998
  type: [String, Object],
2876
2999
  default: "text"
2877
3000
  },
3001
+ /**
3002
+ * 编辑器组件参数
3003
+ */
3004
+ props: {
3005
+ type: Object
3006
+ },
3007
+ /**
3008
+ * 字段值
3009
+ */
2878
3010
  modelValue: {
2879
3011
  type: [String, Number, Boolean, Object, Array],
2880
- default: ""
3012
+ default(a) {
3013
+ return Mt[a.editor]?.defaultValue;
3014
+ }
2881
3015
  },
3016
+ /**
3017
+ * 输入框尺寸
3018
+ */
2882
3019
  size: {
2883
3020
  type: String
2884
3021
  },
2885
- // 是否在tooltip显示校验信息
3022
+ width: {
3023
+ type: [String, Number]
3024
+ },
3025
+ /**
3026
+ * 是否在tooltip显示校验信息
3027
+ */
2886
3028
  tooltipMessage: {
2887
3029
  type: [Boolean, Object],
2888
3030
  default: !0
2889
3031
  },
2890
- // tooltip信息显示相对输入框的位置
3032
+ /**
3033
+ * tooltip信息显示相对输入框的位置
3034
+ */
2891
3035
  tooltipPosition: {
2892
3036
  type: [String, Number],
2893
3037
  default: "outer"
2894
3038
  },
2895
- // null 不显示 placeholder
3039
+ /**
3040
+ * null 不显示 placeholder
3041
+ */
2896
3042
  placeholder: {
2897
3043
  type: String
2898
3044
  },
3045
+ /**
3046
+ * 禁用
3047
+ */
2899
3048
  disabled: {
2900
3049
  type: Boolean
2901
3050
  },
3051
+ /**
3052
+ * 只读
3053
+ */
3054
+ readonly: {
3055
+ type: Boolean
3056
+ },
3057
+ /**
3058
+ * 选项数据
3059
+ */
2902
3060
  options: {
2903
3061
  type: [Array, Function]
3062
+ },
3063
+ /**
3064
+ * 是否显示控制
3065
+ */
3066
+ visible: {
3067
+ type: [Boolean, Object, Function],
3068
+ default: !0
3069
+ },
3070
+ /**
3071
+ * 级联字段,根据字段值变化刷新options
3072
+ */
3073
+ cascader: {
3074
+ type: [String, Array]
2904
3075
  }
2905
3076
  };
2906
- function Ro(a) {
2907
- return v(() => {
2908
- const { editor: e = "text", placeholder: t, label: n, disabled: s } = a, l = {
2909
- placeholder: t || (t === null ? void 0 : `请输入${n}`),
2910
- disabled: s
2911
- };
2912
- return xn(
2913
- typeof e == "string" ? Ie[e] || Ie.text : Ie[e.name] || {},
2914
- { props: l },
2915
- e
2916
- );
2917
- });
3077
+ async function ta(a, t) {
3078
+ const e = a.options;
3079
+ return e ? typeof e == "function" ? await e(t) || [] : e : [];
2918
3080
  }
2919
- const Fo = /* @__PURE__ */ B({
3081
+ function oa(a, t, e, o, s) {
3082
+ const i = P([]), l = h(() => !o || !s ? {} : Fo(a.cascader).reduce((d, f) => (d[f] = s[f], d), {}));
3083
+ return H(
3084
+ l,
3085
+ async (r) => {
3086
+ if (e.value) {
3087
+ i.value = await ta(a, r);
3088
+ const d = o?.exposed?.reset;
3089
+ d && a.name && d(a.name);
3090
+ }
3091
+ },
3092
+ {
3093
+ immediate: !0
3094
+ }
3095
+ ), {
3096
+ editor: h(() => {
3097
+ const {
3098
+ editor: r = "text",
3099
+ placeholder: d,
3100
+ label: f = "...",
3101
+ disabled: g,
3102
+ readonly: S
3103
+ } = a, $ = {
3104
+ ...a.props,
3105
+ placeholder: d || (d === null ? void 0 : `请输入${f}`),
3106
+ disabled: g,
3107
+ readonly: S,
3108
+ options: i.value,
3109
+ onFocus: () => t("focus"),
3110
+ onBlur: () => t("blur"),
3111
+ onChange: (_) => t("change", _)
3112
+ }, w = typeof r == "string" ? Mt[r] : {
3113
+ component: r,
3114
+ props: {}
3115
+ };
3116
+ return Oo({}, w, {
3117
+ props: $
3118
+ });
3119
+ })
3120
+ };
3121
+ }
3122
+ const Bt = /* @__PURE__ */ E({
2920
3123
  name: "XField",
2921
3124
  __name: "Field",
2922
- props: $o,
2923
- emits: ["update:modelValue", "change"],
2924
- setup(a, { expose: e, emit: t }) {
2925
- const n = a, s = Be(Yt, null), l = Ro(n), i = R(n.modelValue), c = R(), r = R(), p = v(
2926
- () => n.size || s?.size || "default"
2927
- ), m = v(() => ({
2928
- [`is-tooltip-${n.tooltipPosition}`]: !!n.tooltipPosition
2929
- })), h = v(() => ({
2930
- right: typeof n.tooltipPosition == "number" ? `${n.tooltipPosition}px` : void 0
3125
+ props: ea,
3126
+ emits: ["update:modelValue", "change", "focus", "blur"],
3127
+ setup(a, { expose: t, emit: e }) {
3128
+ const o = a, s = me(It, null), i = me(fo, null), l = me(At, null), u = h(() => !s?.proxy || !l ? o.visible : typeof o.visible == "function" ? o.visible(l) : We(o.visible) ? Object.entries(o.visible).every(([D, R]) => l[D] === R) : o.visible), r = () => s?.proxy && l && o.name ? l[o.name] ?? o.modelValue : o.modelValue, d = P(r()), { editor: f } = oa(
3129
+ o,
3130
+ e,
3131
+ u,
3132
+ s,
3133
+ l
3134
+ ), g = P(), S = P(), $ = h(
3135
+ () => o.size || i?.size || "default"
3136
+ ), w = h(() => ({
3137
+ [`is-tooltip-${o.tooltipPosition}`]: !!o.tooltipPosition
3138
+ })), _ = h(() => {
3139
+ const b = s?.proxy;
3140
+ return {
3141
+ width: o.width ? je(o.width) : b && b.inline && b.inlineColumns ? `${100 / b.inlineColumns}%` : null
3142
+ };
3143
+ }), T = h(() => ({
3144
+ right: typeof o.tooltipPosition == "number" ? `${o.tooltipPosition}px` : void 0
3145
+ })), V = h(() => ({
3146
+ ...f.value.props,
3147
+ modelValue: d.value,
3148
+ "onUpdate:modelValue": (b) => {
3149
+ d.value = b;
3150
+ }
2931
3151
  }));
2932
- return ee(i, (k) => {
2933
- t("update:modelValue", k), t("change", k);
2934
- }), e({
2935
- fieldValue: i,
2936
- itemRef: c,
2937
- editorRef: r
2938
- }), (k, A) => (u(), f(o(Gt), X({
2939
- class: ["x-field", m.value],
3152
+ return H(d, (b, D) => {
3153
+ u.value && !He(b, D) && (e("update:modelValue", b), s?.proxy && l && o.name && (l[o.name] = b));
3154
+ }), H(
3155
+ () => !s?.proxy || !o.name || !l ? o.modelValue : l[o.name] ?? o.modelValue,
3156
+ (b) => {
3157
+ u.value && (d.value = b);
3158
+ },
3159
+ {
3160
+ immediate: !0
3161
+ }
3162
+ ), H(
3163
+ u,
3164
+ (b) => {
3165
+ s?.proxy && l && o.name && (b ? (d.value = r(), l[o.name] = d.value) : (d.value = void 0, delete l[o.name]));
3166
+ },
3167
+ {
3168
+ immediate: !0
3169
+ }
3170
+ ), t({
3171
+ fieldValue: d,
3172
+ itemRef: g,
3173
+ editorRef: S,
3174
+ focus: () => {
3175
+ S.value?.focus && S.value.focus();
3176
+ },
3177
+ blur: () => {
3178
+ S.value?.foucs && S.value.blur();
3179
+ }
3180
+ }), (b, D) => u.value ? (c(), m(n(mo), X({
3181
+ key: 0,
3182
+ class: ["x-field", w.value],
2940
3183
  ref_key: "itemRef",
2941
- ref: c,
2942
- label: k.label,
2943
- size: p.value
2944
- }, k.$attrs), $e({
2945
- error: d(({ error: _ }) => [
2946
- z(k.$slots, "error", { error: _ }, () => [
2947
- n.tooltipMessage ? (u(), V("div", {
3184
+ ref: g,
3185
+ prop: o.name,
3186
+ label: b.label,
3187
+ size: $.value,
3188
+ style: _.value
3189
+ }, b.$attrs), ye({
3190
+ error: p(({ error: R }) => [
3191
+ z(b.$slots, "error", { error: R }, () => [
3192
+ o.tooltipMessage ? (c(), A("div", {
2948
3193
  key: 0,
2949
3194
  class: "x-field__info",
2950
- style: be(h.value)
3195
+ style: Ce(T.value)
2951
3196
  }, [
2952
- b(o(st), X({ content: _ }, n.tooltipMessage), {
2953
- default: d(() => [
2954
- b(o(te), {
3197
+ k(n(ct), X({ content: R }, o.tooltipMessage), {
3198
+ default: p(() => [
3199
+ k(n(te), {
2955
3200
  class: "x-field__trigger",
2956
- icon: o(pn),
2957
- size: p.value
3201
+ icon: n(To),
3202
+ size: $.value
2958
3203
  }, null, 8, ["icon", "size"])
2959
3204
  ]),
2960
3205
  _: 2
2961
3206
  }, 1040, ["content"])
2962
- ], 4)) : y("", !0)
3207
+ ], 4)) : v("", !0)
2963
3208
  ])
2964
3209
  ]),
2965
- default: d(() => [
2966
- z(k.$slots, "default"),
2967
- o(l).name ? (u(), f(Z(o(l).name), X({
2968
- key: 0,
2969
- ref_key: "editorRef",
2970
- ref: r,
2971
- modelValue: i.value,
2972
- "onUpdate:modelValue": A[0] || (A[0] = (_) => i.value = _)
2973
- }, o(l).props), null, 16, ["modelValue"])) : y("", !0)
3210
+ default: p(() => [
3211
+ z(b.$slots, "editor", { editor: V.value }, () => [
3212
+ n(f).component ? (c(), m(L(n(f).component), X({
3213
+ key: 0,
3214
+ class: "x-field__editor",
3215
+ ref_key: "editorRef",
3216
+ ref: S,
3217
+ modelValue: d.value,
3218
+ "onUpdate:modelValue": D[0] || (D[0] = (R) => d.value = R)
3219
+ }, n(f).props), ye({ _: 2 }, [
3220
+ b.$slots.option ? {
3221
+ name: "option",
3222
+ fn: p(({ option: R }) => [
3223
+ z(b.$slots, "option", { option: R })
3224
+ ]),
3225
+ key: "0"
3226
+ } : void 0
3227
+ ]), 1040, ["modelValue"])) : v("", !0)
3228
+ ])
2974
3229
  ]),
2975
3230
  _: 2
2976
3231
  }, [
2977
- k.$slots.label ? {
3232
+ b.$slots.label ? {
2978
3233
  name: "label",
2979
- fn: d(() => [
2980
- z(k.$slots, "label")
3234
+ fn: p(() => [
3235
+ z(b.$slots, "label")
2981
3236
  ]),
2982
3237
  key: "0"
2983
3238
  } : void 0
2984
- ]), 1040, ["label", "size", "class"]));
3239
+ ]), 1040, ["prop", "label", "size", "class", "style"])) : v("", !0);
3240
+ }
3241
+ }), na = {
3242
+ /**
3243
+ * 表单模型
3244
+ */
3245
+ model: {
3246
+ type: Object,
3247
+ default() {
3248
+ return /* @__PURE__ */ Object.create(null);
3249
+ }
3250
+ },
3251
+ /**
3252
+ * inline模式
3253
+ */
3254
+ inline: {
3255
+ type: Boolean
3256
+ },
3257
+ /**
3258
+ * inline模式显示列数
3259
+ */
3260
+ inlineColumns: {
3261
+ type: Number
3262
+ },
3263
+ /**
3264
+ * 显示底部操作按钮
3265
+ */
3266
+ footer: {
3267
+ type: Boolean,
3268
+ default: !0
3269
+ },
3270
+ /**
3271
+ * 提交按钮文本
3272
+ */
3273
+ submitText: {
3274
+ type: String,
3275
+ default: "提交"
3276
+ },
3277
+ /**
3278
+ * 重置按钮文本
3279
+ */
3280
+ resetText: {
3281
+ type: String,
3282
+ default: "重置"
3283
+ },
3284
+ /**
3285
+ * 表单提交处理方法
3286
+ */
3287
+ submitMethod: {
3288
+ type: Function
2985
3289
  }
2986
- }), Go = /* @__PURE__ */ B({
3290
+ }, It = Symbol("formInstanceKey"), At = Symbol("formModelKey"), ha = /* @__PURE__ */ E({
3291
+ name: "XForm",
2987
3292
  __name: "Form",
2988
- setup(a) {
2989
- return (e, t) => (u(), f(o(qt), qe(et(e.$attrs)), {
2990
- default: d(() => [
2991
- z(e.$slots, "default")
3293
+ props: na,
3294
+ emits: ["change", "submit", "reset"],
3295
+ setup(a, { expose: t, emit: e }) {
3296
+ const o = a, s = de(), i = P(), l = Ne(o.model || {}), u = P(!1);
3297
+ he(It, s), he(At, l), H(l, () => {
3298
+ e("change", Se(l));
3299
+ }), H(
3300
+ () => o.model,
3301
+ (f) => {
3302
+ Object.assign(l, f);
3303
+ },
3304
+ { deep: !0 }
3305
+ );
3306
+ const r = async () => {
3307
+ await i.value.validate().catch((g) => g) && o.model && (e("submit", Se(l)), o.submitMethod && (u.value = !0, await o.submitMethod(Se(l)), u.value = !1));
3308
+ }, d = (f) => {
3309
+ i.value.resetFields(f), e("reset");
3310
+ };
3311
+ return t({
3312
+ formRef: i,
3313
+ model: l,
3314
+ submit: r,
3315
+ reset: d
3316
+ }), (f, g) => (c(), m(n(go), X({
3317
+ ref_key: "formRef",
3318
+ ref: i,
3319
+ class: "x-form",
3320
+ inline: o.inline,
3321
+ model: l
3322
+ }, f.$attrs), {
3323
+ default: p(() => [
3324
+ z(f.$slots, "default"),
3325
+ o.footer ? (c(), m(n(Bt), {
3326
+ key: 0,
3327
+ editor: "none",
3328
+ class: "x-form__footer",
3329
+ label: " "
3330
+ }, {
3331
+ editor: p(() => [
3332
+ o.submitText ? (c(), m(n(le), {
3333
+ key: 0,
3334
+ loading: u.value,
3335
+ type: "primary",
3336
+ onClick: r
3337
+ }, {
3338
+ default: p(() => [
3339
+ N(j(o.submitText), 1)
3340
+ ]),
3341
+ _: 1
3342
+ }, 8, ["loading"])) : v("", !0),
3343
+ o.resetText ? (c(), m(n(le), {
3344
+ key: 1,
3345
+ type: "default",
3346
+ onClick: g[0] || (g[0] = () => d())
3347
+ }, {
3348
+ default: p(() => [
3349
+ N(j(o.resetText), 1)
3350
+ ]),
3351
+ _: 1
3352
+ })) : v("", !0)
3353
+ ]),
3354
+ default: p(() => [
3355
+ z(f.$slots, "footer")
3356
+ ]),
3357
+ _: 3
3358
+ })) : v("", !0)
2992
3359
  ]),
2993
3360
  _: 3
2994
- }, 16));
3361
+ }, 16, ["inline", "model"]));
2995
3362
  }
2996
- }), Oo = [
2997
- Bn,
3363
+ }), aa = [
3364
+ Ko,
2998
3365
  te,
2999
- G,
3000
- Xn,
3001
- Q,
3002
- je,
3003
- M,
3366
+ ee,
3367
+ an,
3368
+ J,
3369
+ Ke,
3370
+ I,
3004
3371
  wt,
3005
- kt,
3372
+ xt,
3006
3373
  zt,
3007
- Vo,
3008
- Fo
3009
- ], qo = "0.6.11", jo = zn(Oo), ea = jo.install;
3374
+ Jn,
3375
+ Bt
3376
+ ], va = "0.6.13", sa = jo(aa), ba = sa.install;
3010
3377
  export {
3011
- Ie as BuiltinEditors,
3012
- Je as Draggable,
3013
- Qe as INSTALLED_KEY,
3014
- Ct as MASK_KEY,
3015
- Ko as NOOP,
3016
- Ke as Resizable,
3017
- St as TAB_CREATORS_KEY,
3018
- To as TAB_ITEM_WIDTH,
3019
- Q as XAction,
3020
- je as XActionBar,
3021
- M as XContainer,
3378
+ ot as Draggable,
3379
+ et as INSTALLED_KEY,
3380
+ Tt as MASK_KEY,
3381
+ ga as NOOP,
3382
+ nt as Resizable,
3383
+ Ct as TAB_CREATORS_KEY,
3384
+ Un as TAB_ITEM_WIDTH,
3385
+ J as XAction,
3386
+ Ke as XActionBar,
3387
+ I as XContainer,
3022
3388
  zt as XDialog,
3023
- Fo as XField,
3024
- Go as XForm,
3389
+ Bt as XField,
3390
+ ha as XForm,
3025
3391
  wt as XHeader,
3026
3392
  te as XIcon,
3027
- Vo as XMask,
3028
- G as XMenu,
3029
- kt as XPanel,
3030
- Xn as XSimpleMask,
3031
- Bn as XStartup,
3032
- Jn as actionBarProps,
3033
- _t as actionProps,
3034
- Oo as components,
3035
- Kn as containerProps,
3036
- Ne as createDialog,
3037
- ea as default,
3038
- Yo as defineTab,
3039
- no as dialogProps,
3040
- $o as fieldProps,
3041
- We as getSizeValue,
3042
- Yn as headerProps,
3043
- Dn as iconProps,
3044
- An as iconSizeMap,
3045
- ea as install,
3046
- zn as makeInstaller,
3047
- Mo as maskProps,
3048
- Zo as omit,
3049
- eo as panelProps,
3050
- me as parseSize,
3051
- Jo as pick,
3052
- Oe as useDisabled,
3053
- we as useIcon,
3054
- Wn as useIconProps,
3055
- to as vDraggable,
3056
- xt as vResizable,
3057
- qo as version
3393
+ Jn as XMask,
3394
+ ee as XMenu,
3395
+ xt as XPanel,
3396
+ an as XSimpleMask,
3397
+ Ko as XStartup,
3398
+ pn as actionBarProps,
3399
+ kt as actionProps,
3400
+ Mt as builtinFieldEditors,
3401
+ aa as components,
3402
+ fn as containerProps,
3403
+ Qe as createDialog,
3404
+ ba as default,
3405
+ ya as defineTab,
3406
+ bn as dialogProps,
3407
+ ea as fieldProps,
3408
+ It as formInstanceKey,
3409
+ At as formModelKey,
3410
+ na as formProps,
3411
+ je as getSizeValue,
3412
+ mn as headerProps,
3413
+ Zo as iconProps,
3414
+ Qo as iconSizeMap,
3415
+ ba as install,
3416
+ jo as makeInstaller,
3417
+ Hn as maskProps,
3418
+ fa as omit,
3419
+ hn as panelProps,
3420
+ _e as parseSize,
3421
+ ma as pick,
3422
+ Le as useDisabled,
3423
+ Ee as useIcon,
3424
+ cn as useIconProps,
3425
+ vn as vDraggable,
3426
+ St as vResizable,
3427
+ va as version
3058
3428
  };