mgacn-commonsdk 1.2.1 → 1.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,25 +1,25 @@
1
1
  import { Plus as ot, Delete as it, CircleCloseFilled as ut, Document as ct, Close as dt, CircleClose as Ve, CircleCheck as pt, ArrowUp as ft, ArrowDown as ht } from "@element-plus/icons-vue";
2
- import { ElMessage as E, ElMessageBox as Oe } from "element-plus";
2
+ import { ElMessage as K, ElMessageBox as Oe } from "element-plus";
3
3
  import mt from "cropperjs";
4
4
  import * as $e from "ali-oss";
5
- import { g as gt, _ as G, h as Ie, t as yt, i as vt, j as Ae, k as bt, l as _t, m as wt, n as Ct, o as kt } from "./_plugin-vue_export-helper-C5bbN0Gq.js";
6
- import { c as ol, p as il, q as ul, b as cl, r as dl, u as pl, a as fl, s as hl, v as ml } from "./_plugin-vue_export-helper-C5bbN0Gq.js";
7
- import { resolveComponent as F, openBlock as u, createElementBlock as b, createElementVNode as w, toDisplayString as T, createCommentVNode as D, createTextVNode as K, Fragment as W, renderList as q, normalizeStyle as re, normalizeClass as z, createVNode as U, withCtx as S, withModifiers as de, withDirectives as ee, vShow as te, createBlock as P, computed as ye, ref as A, watch as se, onMounted as ve, reactive as Ne, nextTick as Z, onBeforeUnmount as ze, withKeys as Le, unref as ne, renderSlot as ae, mergeProps as Me, createSlots as Ut } from "vue";
8
- const xt = $e.default ?? $e, He = "__MGACN_COMMONSDK_OSS_URL__";
9
- function St(e = "") {
10
- globalThis[He] = String(e || "").replace(/\/$/, "");
5
+ import { g as gt, _ as G, o as yt, k as Ie, t as vt, l as bt, m as Ae, F as _t, n as wt, p as Ct, q as kt, r as Ut, u as xt } from "./FilePreview-DVaCq1Fr.js";
6
+ import { i as ul, j as cl, c as dl, v as pl, w as fl, b as hl, x as ml, y as gl, a as yl, s as vl, z as bl } from "./FilePreview-DVaCq1Fr.js";
7
+ import { resolveComponent as F, openBlock as p, createElementBlock as v, createElementVNode as _, toDisplayString as T, createCommentVNode as D, createTextVNode as j, Fragment as W, renderList as q, normalizeStyle as re, normalizeClass as H, createVNode as U, withCtx as S, withModifiers as de, withDirectives as ee, vShow as te, createBlock as P, computed as ye, ref as A, watch as se, onMounted as ve, reactive as Le, nextTick as Z, onBeforeUnmount as He, withKeys as Ne, unref as ne, renderSlot as ae, mergeProps as Me, createSlots as St } from "vue";
8
+ const Ft = $e.default ?? $e, ze = "__MGACN_COMMONSDK_OSS_URL__";
9
+ function $t(e = "") {
10
+ globalThis[ze] = String(e || "").replace(/\/$/, "");
11
11
  }
12
- function je() {
13
- return globalThis[He] || "";
12
+ function Ee() {
13
+ return globalThis[ze] || "";
14
14
  }
15
15
  function Pe(e) {
16
16
  return String(e).padStart(2, "0");
17
17
  }
18
- function Ft() {
18
+ function Lt() {
19
19
  const e = /* @__PURE__ */ new Date();
20
20
  return `${e.getFullYear()}${Pe(e.getMonth() + 1)}${Pe(e.getDate())}`;
21
21
  }
22
- function Ke(e = 10) {
22
+ function je(e = 10) {
23
23
  const t = "0123456789abcdefghijklmnopqrstuvwxyz";
24
24
  let n = "";
25
25
  for (let r = 0; r < e; r++)
@@ -27,16 +27,16 @@ function Ke(e = 10) {
27
27
  return n;
28
28
  }
29
29
  function be(e = "portal_cms") {
30
- return `${e}/${Ft()}/`;
30
+ return `${e}/${Lt()}/`;
31
31
  }
32
- function Ee(e) {
32
+ function Ke(e) {
33
33
  return gt().getOssSts(e);
34
34
  }
35
- function $t(e = {}) {
35
+ function Nt(e = {}) {
36
36
  const t = e.accessKeyId || e.AccessKeyId || e.accessKeyID || "", n = e.accessKeySecret || e.AccessKeySecret || "", r = e.securityToken || e.SecurityToken || e.stsToken || e.token || "", s = e.bucketName || e.bucket || e.BucketName || "";
37
37
  let o = String(e.endPoint || e.endpoint || e.EndPoint || "").replace(/^https?:\/\//i, "").replace(/\/$/, "");
38
38
  s && o.startsWith(`${s}.`) && (o = o.slice(s.length + 1));
39
- const m = e.region || (o.startsWith("oss-") ? o.replace(/\.aliyuncs\.com.*$/i, "") : ""), h = String(e.ossUrl || e.domain || e.cdnDomain || "").replace(/\/$/, ""), $ = s && o ? `https://${s}.${o}` : je();
39
+ const m = e.region || (o.startsWith("oss-") ? o.replace(/\.aliyuncs\.com.*$/i, "") : ""), h = String(e.ossUrl || e.domain || e.cdnDomain || "").replace(/\/$/, ""), $ = s && o ? `https://${s}.${o}` : Ee();
40
40
  return {
41
41
  accessKeyId: t,
42
42
  accessKeySecret: n,
@@ -48,7 +48,7 @@ function $t(e = {}) {
48
48
  };
49
49
  }
50
50
  async function _e(e = {}) {
51
- const { dir: t, foldName: n, getOss: r, ossinfo: s } = e, o = t || be(n || "portal_cms"), m = s || (typeof r == "function" ? await r(o) : await Ee(o)), h = $t(m || {});
51
+ const { dir: t, foldName: n, getOss: r, ossinfo: s } = e, o = t || be(n || "portal_cms"), m = s || (typeof r == "function" ? await r(o) : await Ke(o)), h = Nt(m || {});
52
52
  if (!h.accessKeyId || !h.accessKeySecret || !h.bucketName)
53
53
  throw new Error("[mgacn-commonsdk] 获取 OSS STS 失败:凭证字段不完整");
54
54
  if (!h.securityToken)
@@ -62,62 +62,62 @@ async function _e(e = {}) {
62
62
  success_action_status: "200"
63
63
  };
64
64
  h.region && ($.region = h.region), h.endPoint && ($.endpoint = h.endPoint);
65
- const _ = new xt($);
66
- return _.options.ossUrl = h.ossUrl || je(), _.options.uploadDir = o, _;
65
+ const b = new Ft($);
66
+ return b.options.ossUrl = h.ossUrl || Ee(), b.options.uploadDir = o, b;
67
67
  }
68
68
  async function We(e = {}) {
69
- var B, X;
69
+ var R, X;
70
70
  const { client: t, file: n, dir: r, foldName: s, fileName: o, onProgress: m } = e;
71
71
  if (!n)
72
72
  throw new Error("[mgacn-commonsdk] uploadToOss 缺少 file");
73
73
  const h = t || await _e({ dir: r, foldName: s }), $ = r || h.options.uploadDir || be(s);
74
- let _ = o;
75
- if (!_) {
76
- const V = n.name || "file", H = V.lastIndexOf("."), J = H > -1 ? V.slice(H) : "";
77
- _ = `${$}${Ke(10)}${J}`;
74
+ let b = o;
75
+ if (!b) {
76
+ const V = n.name || "file", z = V.lastIndexOf("."), J = z > -1 ? V.slice(z) : "";
77
+ b = `${$}${je(10)}${J}`;
78
78
  }
79
- const N = (V) => {
79
+ const x = (V) => {
80
80
  typeof m == "function" && m(Math.min(100, Math.max(0, Math.floor(Number(V) * 100))));
81
- }, g = n.size > 1 * 1024 * 1024, p = {
81
+ }, M = n.size > 1 * 1024 * 1024, u = {
82
82
  progress: async (V) => {
83
- N(V);
83
+ x(V);
84
84
  }
85
85
  };
86
- let d;
87
- const c = async (V) => {
88
- const H = V ? { "x-oss-object-acl": "public-read" } : void 0;
89
- return g ? h.multipartUpload(_, n, {
90
- ...p,
91
- ...H ? { headers: H } : {}
92
- }) : h.put(_, n, {
93
- ...p,
94
- ...H ? { headers: H } : {}
86
+ let c;
87
+ const d = async (V) => {
88
+ const z = V ? { "x-oss-object-acl": "public-read" } : void 0;
89
+ return M ? h.multipartUpload(b, n, {
90
+ ...u,
91
+ ...z ? { headers: z } : {}
92
+ }) : h.put(b, n, {
93
+ ...u,
94
+ ...z ? { headers: z } : {}
95
95
  });
96
96
  };
97
97
  try {
98
- N(0.01), d = await c(!0);
98
+ x(0.01), c = await d(!0);
99
99
  } catch {
100
- N(0.01), d = await c(!1);
100
+ x(0.01), c = await d(!1);
101
101
  }
102
- const x = ((B = d == null ? void 0 : d.res) == null ? void 0 : B.statusCode) ?? ((X = d == null ? void 0 : d.res) == null ? void 0 : X.status);
103
- if (x && x !== 200)
102
+ const k = ((R = c == null ? void 0 : c.res) == null ? void 0 : R.statusCode) ?? ((X = c == null ? void 0 : c.res) == null ? void 0 : X.status);
103
+ if (k && k !== 200)
104
104
  throw new Error("[mgacn-commonsdk] 上传失败");
105
- N(1);
106
- const L = (h.options.ossUrl || "").replace(/\/$/, ""), y = L ? `${L}/${_}` : _;
107
- let R = y;
105
+ x(1);
106
+ const L = (h.options.ossUrl || "").replace(/\/$/, ""), g = L ? `${L}/${b}` : b;
107
+ let B = g;
108
108
  try {
109
- R = h.signatureUrl(_, { expires: 3600 * 24 });
109
+ B = h.signatureUrl(b, { expires: 3600 * 24 });
110
110
  } catch {
111
111
  }
112
112
  return {
113
- name: _,
114
- url: y,
115
- previewUrl: R,
116
- raw: d,
113
+ name: b,
114
+ url: g,
115
+ previewUrl: B,
116
+ raw: c,
117
117
  client: h
118
118
  };
119
119
  }
120
- function Nt(e = "", t = "") {
120
+ function Mt(e = "", t = "") {
121
121
  const n = String(e || "").trim();
122
122
  if (!n) return "";
123
123
  if (!/^https?:\/\//i.test(n)) return n.replace(/^\//, "");
@@ -133,8 +133,8 @@ function Nt(e = "", t = "") {
133
133
  return "";
134
134
  }
135
135
  }
136
- async function Lt(e, t = {}) {
137
- const n = t.client || await _e(t), r = Nt(e, n.options.ossUrl);
136
+ async function Pt(e, t = {}) {
137
+ const n = t.client || await _e(t), r = Mt(e, n.options.ossUrl);
138
138
  if (!r) return e;
139
139
  try {
140
140
  return n.signatureUrl(r, { expires: t.expires || 3600 * 24 });
@@ -147,9 +147,9 @@ const Ye = {
147
147
  getDir() {
148
148
  return be(this.foldName || "portal_cms");
149
149
  },
150
- randomString: Ke,
150
+ randomString: je,
151
151
  getOss() {
152
- return Ee(this.getDir());
152
+ return Ke(this.getDir());
153
153
  },
154
154
  async createOssClient() {
155
155
  return _e({
@@ -163,10 +163,10 @@ let Te = 0;
163
163
  function qe() {
164
164
  return Te += 1, `mg-img-${Date.now()}-${Te}`;
165
165
  }
166
- function Mt(e) {
166
+ function Tt(e) {
167
167
  return Array.isArray(e) ? e.filter(Boolean) : e ? [e] : [];
168
168
  }
169
- function Be(e) {
169
+ function Re(e) {
170
170
  return e.map((t) => ({
171
171
  uid: qe(),
172
172
  url: t,
@@ -178,14 +178,14 @@ function Be(e) {
178
178
  function ce(e = "") {
179
179
  return String(e).startsWith("blob:");
180
180
  }
181
- function Pt(e = "") {
181
+ function Rt(e = "") {
182
182
  return /[?&](Expires|Signature|OSSAccessKeyId)=/i.test(String(e));
183
183
  }
184
- function Tt(e = "") {
184
+ function Bt(e = "") {
185
185
  const t = e.lastIndexOf(".");
186
186
  return t > -1 ? e.slice(t + 1).toLowerCase() : "";
187
187
  }
188
- const Bt = {
188
+ const Dt = {
189
189
  name: "MgImageUpload",
190
190
  mixins: [Ye],
191
191
  components: { CircleCloseFilled: ut, Delete: it, Plus: ot },
@@ -253,7 +253,7 @@ const Bt = {
253
253
  deep: !0,
254
254
  immediate: !0,
255
255
  handler(e) {
256
- e != null && e.length && (this.replaceList(Be(e)), this.ensureSignedPreviews());
256
+ e != null && e.length && (this.replaceList(Re(e)), this.ensureSignedPreviews());
257
257
  }
258
258
  },
259
259
  modelValue: {
@@ -261,12 +261,12 @@ const Bt = {
261
261
  handler(e) {
262
262
  var o;
263
263
  if ((o = this.initFileList) != null && o.length) return;
264
- const t = Mt(e), n = this.successUrls;
264
+ const t = Tt(e), n = this.successUrls;
265
265
  if (t.length === n.length && t.every((m, h) => m === n[h]))
266
266
  return;
267
267
  const r = new Map(
268
268
  this.fileList.map((m) => [m.url, m.previewUrl]).filter(([m]) => m)
269
- ), s = Be(t).map((m) => ({
269
+ ), s = Re(t).map((m) => ({
270
270
  ...m,
271
271
  previewUrl: r.get(m.url) || ""
272
272
  }));
@@ -302,14 +302,14 @@ const Bt = {
302
302
  /** 私有桶回显:给已有 url 补签名预览 */
303
303
  async ensureSignedPreviews() {
304
304
  const e = this.fileList.filter(
305
- (t) => t.status === "success" && t.url && !ce(t.previewUrl) && !Pt(t.previewUrl || t.url)
305
+ (t) => t.status === "success" && t.url && !ce(t.previewUrl) && !Rt(t.previewUrl || t.url)
306
306
  );
307
307
  if (e.length)
308
308
  try {
309
309
  const t = await this.createOssClient();
310
310
  await Promise.all(
311
311
  e.map(async (n) => {
312
- const r = await Lt(n.url, { client: t });
312
+ const r = await Pt(n.url, { client: t });
313
313
  r && (n.previewUrl = r);
314
314
  })
315
315
  );
@@ -346,7 +346,7 @@ const Bt = {
346
346
  handleUpload() {
347
347
  if (!this.disabled) {
348
348
  if (this.fileList.length >= this.fileNum) {
349
- E.error(`文件数量不超过${this.fileNum}`);
349
+ K.error(`文件数量不超过${this.fileNum}`);
350
350
  return;
351
351
  }
352
352
  this.openFilePicker();
@@ -357,12 +357,12 @@ const Bt = {
357
357
  if (!t.length) return;
358
358
  const n = this.dialogVisible || this.isCropper, r = this.fileNum - this.fileList.length;
359
359
  if (!n && t.length > r) {
360
- E.error(`文件数量不超过${this.fileNum}个`);
360
+ K.error(`文件数量不超过${this.fileNum}个`);
361
361
  return;
362
362
  }
363
363
  const s = [], o = [];
364
364
  if (t.forEach((m) => {
365
- this.acceptList.includes(Tt(m.name)) ? s.push(m) : o.push(m);
365
+ this.acceptList.includes(Bt(m.name)) ? s.push(m) : o.push(m);
366
366
  }), o.length) {
367
367
  const m = o.map((h) => h.name).join(",");
368
368
  Oe.confirm(
@@ -406,7 +406,7 @@ const Bt = {
406
406
  const t = this.maxFileSize * 1024 * 1024, n = [];
407
407
  return e.forEach((r) => {
408
408
  if (r.size > t) {
409
- E.error(`「${r.name}」超出 ${this.maxFileSize}MB 限制`);
409
+ K.error(`「${r.name}」超出 ${this.maxFileSize}MB 限制`);
410
410
  return;
411
411
  }
412
412
  const s = URL.createObjectURL(r), o = {
@@ -435,7 +435,7 @@ const Bt = {
435
435
  });
436
436
  e.url = r.url, e.previewUrl = t || r.previewUrl || r.url, e.status = "success", n(100), e.raw = null, this.activeUploadCount = Math.max(0, this.activeUploadCount - 1), this.$emit("update:uploading", this.activeUploadCount > 0), this.emitFile(), this.$emit("success", r, e);
437
437
  } catch (r) {
438
- e.status = "fail", n(0), this.activeUploadCount = Math.max(0, this.activeUploadCount - 1), this.$emit("update:uploading", this.activeUploadCount > 0), E.error((r == null ? void 0 : r.message) || "上传失败"), this.$emit("error", r, e);
438
+ e.status = "fail", n(0), this.activeUploadCount = Math.max(0, this.activeUploadCount - 1), this.$emit("update:uploading", this.activeUploadCount > 0), K.error((r == null ? void 0 : r.message) || "上传失败"), this.$emit("error", r, e);
439
439
  }
440
440
  },
441
441
  initCropper() {
@@ -464,7 +464,7 @@ const Bt = {
464
464
  },
465
465
  confirmCrop() {
466
466
  if (this.uploadingCount) {
467
- E.error("上传中,请稍后!");
467
+ K.error("上传中,请稍后!");
468
468
  return;
469
469
  }
470
470
  if (!this.cropper) return;
@@ -484,62 +484,62 @@ const Bt = {
484
484
  !t || t.status === "uploading" || (this.revokePreview(t), this.fileList.splice(e, 1), this.emitFile());
485
485
  }
486
486
  }
487
- }, Rt = { class: "upload-image-cropper" }, Dt = ["multiple", "accept"], Vt = {
487
+ }, Vt = { class: "upload-image-cropper" }, Ot = ["multiple", "accept"], It = {
488
488
  key: 0,
489
489
  class: "grey-tips"
490
- }, Ot = { key: 0 }, It = { class: "list-box" }, At = {
490
+ }, At = { key: 0 }, Ht = { class: "list-box" }, zt = {
491
491
  key: 0,
492
492
  class: "status-mask is-uploading"
493
- }, zt = { class: "progress-wrap" }, Ht = { class: "percent-text" }, jt = {
493
+ }, Et = { class: "progress-wrap" }, jt = { class: "percent-text" }, Kt = {
494
494
  key: 1,
495
495
  class: "status-mask is-fail"
496
- }, Kt = ["onClick"], Et = { class: "cropper-box" }, Wt = ["src"], Yt = {
496
+ }, Wt = ["onClick"], Yt = { class: "cropper-box" }, qt = ["src"], Gt = {
497
497
  key: 0,
498
498
  class: "cropper-placeholder"
499
- }, qt = {
499
+ }, Xt = {
500
500
  key: 0,
501
501
  class: "btn-box btn-box--rotate"
502
- }, Gt = { class: "btn-box" };
503
- function Xt(e, t, n, r, s, o) {
504
- const m = F("el-image"), h = F("el-progress"), $ = F("CircleCloseFilled"), _ = F("el-icon"), N = F("Delete"), g = F("Plus"), p = F("el-button"), d = F("el-dialog");
505
- return u(), b("div", Rt, [
506
- w("input", {
502
+ }, Jt = { class: "btn-box" };
503
+ function Qt(e, t, n, r, s, o) {
504
+ const m = F("el-image"), h = F("el-progress"), $ = F("CircleCloseFilled"), b = F("el-icon"), x = F("Delete"), M = F("Plus"), u = F("el-button"), c = F("el-dialog");
505
+ return p(), v("div", Vt, [
506
+ _("input", {
507
507
  ref: "fileInput",
508
508
  type: "file",
509
509
  class: "file-input",
510
510
  multiple: o.multiple,
511
511
  accept: n.accept,
512
- onChange: t[0] || (t[0] = (...c) => o.onFileChange && o.onFileChange(...c))
513
- }, null, 40, Dt),
514
- n.greyTips ? (u(), b("div", Vt, [
515
- n.otherTips ? (u(), b("div", Ot, T(n.otherTips), 1)) : D("", !0),
516
- K(" " + T(n.greyTips), 1)
512
+ onChange: t[0] || (t[0] = (...d) => o.onFileChange && o.onFileChange(...d))
513
+ }, null, 40, Ot),
514
+ n.greyTips ? (p(), v("div", It, [
515
+ n.otherTips ? (p(), v("div", At, T(n.otherTips), 1)) : D("", !0),
516
+ j(" " + T(n.greyTips), 1)
517
517
  ])) : D("", !0),
518
- w("div", It, [
519
- (u(!0), b(W, null, q(s.fileList, (c, x) => (u(), b("div", {
520
- key: c.uid,
521
- class: z(["image-box", [`is-${c.status}`]]),
518
+ _("div", Ht, [
519
+ (p(!0), v(W, null, q(s.fileList, (d, k) => (p(), v("div", {
520
+ key: d.uid,
521
+ class: H(["image-box", [`is-${d.status}`]]),
522
522
  style: re(n.imageStyle)
523
523
  }, [
524
524
  U(m, {
525
- src: c.previewUrl || c.url,
525
+ src: d.previewUrl || d.url,
526
526
  fit: "cover",
527
527
  class: "img"
528
528
  }, null, 8, ["src"]),
529
- c.status === "uploading" ? (u(), b("div", At, [
530
- w("div", zt, [
529
+ d.status === "uploading" ? (p(), v("div", zt, [
530
+ _("div", Et, [
531
531
  U(h, {
532
532
  type: "circle",
533
- percentage: c.percent,
533
+ percentage: d.percent,
534
534
  width: 30,
535
535
  "stroke-width": 3,
536
536
  "show-text": !1,
537
537
  color: "var(--mg-primary, #ff5722)"
538
538
  }, null, 8, ["percentage"]),
539
- w("span", Ht, T(c.percent) + "%", 1)
539
+ _("span", jt, T(d.percent) + "%", 1)
540
540
  ])
541
- ])) : c.status === "fail" ? (u(), b("div", jt, [
542
- U(_, {
541
+ ])) : d.status === "fail" ? (p(), v("div", Kt, [
542
+ U(b, {
543
543
  class: "fail-icon",
544
544
  size: 16
545
545
  }, {
@@ -548,56 +548,56 @@ function Xt(e, t, n, r, s, o) {
548
548
  ]),
549
549
  _: 1
550
550
  }),
551
- t[5] || (t[5] = w("span", { class: "fail-text" }, "失败", -1)),
552
- U(_, {
551
+ t[5] || (t[5] = _("span", { class: "fail-text" }, "失败", -1)),
552
+ U(b, {
553
553
  class: "remove-icon",
554
554
  size: 14,
555
555
  title: "删除",
556
- onClick: de((L) => o.removeImg(x), ["stop"])
556
+ onClick: de((L) => o.removeImg(k), ["stop"])
557
557
  }, {
558
558
  default: S(() => [
559
- U(N)
559
+ U(x)
560
560
  ]),
561
561
  _: 1
562
562
  }, 8, ["onClick"])
563
- ])) : (u(), b("div", {
563
+ ])) : (p(), v("div", {
564
564
  key: 2,
565
565
  class: "status-mask is-success",
566
- onClick: (L) => o.removeImg(x)
566
+ onClick: (L) => o.removeImg(k)
567
567
  }, [
568
- U(_, {
568
+ U(b, {
569
569
  class: "remove-icon",
570
570
  size: 16
571
571
  }, {
572
572
  default: S(() => [
573
- U(N)
573
+ U(x)
574
574
  ]),
575
575
  _: 1
576
576
  })
577
- ], 8, Kt))
577
+ ], 8, Wt))
578
578
  ], 6))), 128)),
579
- ee(w("div", {
579
+ ee(_("div", {
580
580
  class: "image-box upload-btn",
581
581
  style: re(n.imageStyle),
582
- onClick: t[1] || (t[1] = (...c) => o.handleUpload && o.handleUpload(...c))
582
+ onClick: t[1] || (t[1] = (...d) => o.handleUpload && o.handleUpload(...d))
583
583
  }, [
584
- U(_, {
584
+ U(b, {
585
585
  class: "icon",
586
586
  size: 14
587
587
  }, {
588
588
  default: S(() => [
589
- U(g)
589
+ U(M)
590
590
  ]),
591
591
  _: 1
592
592
  }),
593
- t[6] || (t[6] = w("div", null, "上传图片", -1))
593
+ t[6] || (t[6] = _("div", null, "上传图片", -1))
594
594
  ], 4), [
595
595
  [te, o.showUploadBtn]
596
596
  ])
597
597
  ]),
598
- U(d, {
598
+ U(c, {
599
599
  modelValue: s.dialogVisible,
600
- "onUpdate:modelValue": t[4] || (t[4] = (c) => s.dialogVisible = c),
600
+ "onUpdate:modelValue": t[4] || (t[4] = (d) => s.dialogVisible = d),
601
601
  title: "裁剪图片",
602
602
  width: "650px",
603
603
  top: "5vh",
@@ -607,70 +607,70 @@ function Xt(e, t, n, r, s, o) {
607
607
  onClose: o.handleBack
608
608
  }, {
609
609
  footer: S(() => [
610
- n.isDegree ? (u(), b("div", qt, [
611
- U(p, {
612
- onClick: t[2] || (t[2] = (c) => o.rotate(-n.degree))
610
+ n.isDegree ? (p(), v("div", Xt, [
611
+ U(u, {
612
+ onClick: t[2] || (t[2] = (d) => o.rotate(-n.degree))
613
613
  }, {
614
614
  default: S(() => [...t[7] || (t[7] = [
615
- K("向左旋转", -1)
615
+ j("向左旋转", -1)
616
616
  ])]),
617
617
  _: 1
618
618
  }),
619
- U(p, {
620
- onClick: t[3] || (t[3] = (c) => o.rotate(n.degree))
619
+ U(u, {
620
+ onClick: t[3] || (t[3] = (d) => o.rotate(n.degree))
621
621
  }, {
622
622
  default: S(() => [...t[8] || (t[8] = [
623
- K("向右旋转", -1)
623
+ j("向右旋转", -1)
624
624
  ])]),
625
625
  _: 1
626
626
  })
627
627
  ])) : D("", !0),
628
- w("div", Gt, [
629
- U(p, {
628
+ _("div", Jt, [
629
+ U(u, {
630
630
  type: "primary",
631
631
  onClick: o.openFilePicker
632
632
  }, {
633
633
  default: S(() => [
634
- K(T(s.cropImageUrl ? "重新上传" : "点击上传"), 1)
634
+ j(T(s.cropImageUrl ? "重新上传" : "点击上传"), 1)
635
635
  ]),
636
636
  _: 1
637
637
  }, 8, ["onClick"]),
638
- U(p, {
638
+ U(u, {
639
639
  type: "primary",
640
640
  onClick: o.confirmCrop
641
641
  }, {
642
642
  default: S(() => [...t[9] || (t[9] = [
643
- K("确定", -1)
643
+ j("确定", -1)
644
644
  ])]),
645
645
  _: 1
646
646
  }, 8, ["onClick"])
647
647
  ])
648
648
  ]),
649
649
  default: S(() => [
650
- w("div", Et, [
651
- ee(w("img", {
650
+ _("div", Yt, [
651
+ ee(_("img", {
652
652
  ref: "cropImage",
653
653
  src: s.cropImageUrl,
654
654
  class: "cropper-img"
655
- }, null, 8, Wt), [
655
+ }, null, 8, qt), [
656
656
  [te, s.cropImageUrl]
657
657
  ]),
658
- s.cropImageUrl ? D("", !0) : (u(), b("div", Yt, "请选择图片后进行裁剪"))
658
+ s.cropImageUrl ? D("", !0) : (p(), v("div", Gt, "请选择图片后进行裁剪"))
659
659
  ])
660
660
  ]),
661
661
  _: 1
662
662
  }, 8, ["modelValue", "onClose"])
663
663
  ]);
664
664
  }
665
- const Jt = /* @__PURE__ */ G(Bt, [["render", Xt], ["__scopeId", "data-v-68531340"]]), Qt = ".mp4,.mov,.jpg,.jpeg,.m3u8,.png,.m4v,.doc,.docx,.xls,.xlsx,.pdf";
666
- let Re = 0;
665
+ const Zt = /* @__PURE__ */ G(Dt, [["render", Qt], ["__scopeId", "data-v-68531340"]]), en = ".mp4,.mov,.jpg,.jpeg,.m3u8,.png,.m4v,.doc,.docx,.xls,.xlsx,.pdf";
666
+ let Be = 0;
667
667
  function we() {
668
- return Re += 1, `mg-file-${Date.now()}-${Re}`;
668
+ return Be += 1, `mg-file-${Date.now()}-${Be}`;
669
669
  }
670
- function Zt(e) {
670
+ function tn(e) {
671
671
  return Array.isArray(e) ? e.filter(Boolean) : e ? [e] : [];
672
672
  }
673
- function en(e) {
673
+ function nn(e) {
674
674
  return Array.isArray(e) ? e.map((t) => {
675
675
  if (!t) return null;
676
676
  if (typeof t == "string")
@@ -682,7 +682,7 @@ function en(e) {
682
682
  } : null;
683
683
  }).filter(Boolean) : [];
684
684
  }
685
- function tn(e = [], t = []) {
685
+ function ln(e = [], t = []) {
686
686
  return e.length !== t.length ? !1 : e.every((n, r) => {
687
687
  const s = t[r];
688
688
  return n.fileUrl === s.fileUrl && n.fileName === s.fileName;
@@ -705,7 +705,7 @@ function De(e) {
705
705
  raw: null
706
706
  }));
707
707
  }
708
- function nn(e = []) {
708
+ function sn(e = []) {
709
709
  return e.map((t) => ({
710
710
  uid: we(),
711
711
  name: t.fileName || oe(t.fileUrl),
@@ -715,11 +715,11 @@ function nn(e = []) {
715
715
  raw: null
716
716
  }));
717
717
  }
718
- function ln(e = "") {
718
+ function an(e = "") {
719
719
  const t = e.lastIndexOf(".");
720
720
  return t > -1 ? e.slice(t + 1).toLowerCase() : "";
721
721
  }
722
- const sn = {
722
+ const rn = {
723
723
  name: "MgFileUpload",
724
724
  mixins: [Ye],
725
725
  components: { CircleCheck: pt, CircleClose: Ve, Close: dt, Document: ct },
@@ -741,7 +741,7 @@ const sn = {
741
741
  initFileList: { type: Array, default: () => [] },
742
742
  /** 选满后是否清空再传 */
743
743
  resetFilelist: Boolean,
744
- accept: { type: String, default: Qt },
744
+ accept: { type: String, default: en },
745
745
  foldName: { type: String, default: "portal_cms" },
746
746
  disabled: Boolean,
747
747
  buttonText: { type: String, default: "点击上传" },
@@ -807,12 +807,12 @@ const sn = {
807
807
  var r;
808
808
  if ((r = this.initFileList) != null && r.length) return;
809
809
  if (this.valueFormat === "file") {
810
- const s = en(e);
811
- if (tn(s, this.modelOutputValue)) return;
812
- this.fileList = nn(s);
810
+ const s = nn(e);
811
+ if (ln(s, this.modelOutputValue)) return;
812
+ this.fileList = sn(s);
813
813
  return;
814
814
  }
815
- const t = Zt(e), n = this.successUrls;
815
+ const t = tn(e), n = this.successUrls;
816
816
  t.length === n.length && t.every((s, o) => s === n[o]) || (this.fileList = De(t));
817
817
  }
818
818
  }
@@ -832,7 +832,7 @@ const sn = {
832
832
  handleUpload() {
833
833
  if (!this.disabled) {
834
834
  if (this.fileList.length >= this.fileNum) {
835
- E.error(`文件数量不超过${this.fileNum}`);
835
+ K.error(`文件数量不超过${this.fileNum}`);
836
836
  return;
837
837
  }
838
838
  this.openFilePicker();
@@ -847,12 +847,12 @@ const sn = {
847
847
  if (!t.length || this.disabled) return;
848
848
  const n = this.fileNum - this.fileList.length;
849
849
  if (t.length > n && !(this.resetFilelist || this.fileNum === 1)) {
850
- E.error(`文件数量不超过${this.fileNum}个`);
850
+ K.error(`文件数量不超过${this.fileNum}个`);
851
851
  return;
852
852
  }
853
853
  const r = [], s = [];
854
854
  if (t.forEach((o) => {
855
- this.acceptList.includes(ln(o.name)) ? r.push(o) : s.push(o);
855
+ this.acceptList.includes(an(o.name)) ? r.push(o) : s.push(o);
856
856
  }), s.length) {
857
857
  const o = s.map((m) => m.name).join(",");
858
858
  Oe.confirm(
@@ -874,7 +874,7 @@ const sn = {
874
874
  const t = this.maxFileSize * 1024 * 1024, n = [];
875
875
  return e.forEach((r) => {
876
876
  if (r.size > t) {
877
- E.error(`「${r.name}」超出 ${this.maxFileSize}MB 限制`);
877
+ K.error(`「${r.name}」超出 ${this.maxFileSize}MB 限制`);
878
878
  return;
879
879
  }
880
880
  const s = {
@@ -903,61 +903,64 @@ const sn = {
903
903
  });
904
904
  e.url = n.url, e.name = e.name || oe(n.url), e.status = "success", t(100), e.raw = null, this.activeUploadCount = Math.max(0, this.activeUploadCount - 1), this.$emit("update:uploading", this.activeUploadCount > 0), this.emitFile(), this.$emit("success", n, e);
905
905
  } catch (n) {
906
- e.status = "fail", t(0), this.activeUploadCount = Math.max(0, this.activeUploadCount - 1), this.$emit("update:uploading", this.activeUploadCount > 0), E.error((n == null ? void 0 : n.message) || "上传失败"), this.$emit("error", n, e);
906
+ e.status = "fail", t(0), this.activeUploadCount = Math.max(0, this.activeUploadCount - 1), this.$emit("update:uploading", this.activeUploadCount > 0), K.error((n == null ? void 0 : n.message) || "上传失败"), this.$emit("error", n, e);
907
907
  }
908
908
  },
909
909
  onFileClick(e) {
910
- (e == null ? void 0 : e.status) === "success" && e.url && window.open(e.url, "_blank", "noopener,noreferrer");
910
+ (e == null ? void 0 : e.status) !== "success" || !e.url || yt({
911
+ src: e.url,
912
+ name: e.name || ""
913
+ });
911
914
  },
912
915
  removeFile(e) {
913
916
  const t = this.fileList[e];
914
917
  !t || t.status === "uploading" || (this.fileList.splice(e, 1), this.emitFile());
915
918
  }
916
919
  }
917
- }, an = { class: "mg-file-upload" }, rn = ["multiple", "accept", "disabled"], on = {
920
+ }, on = { class: "mg-file-upload" }, un = ["multiple", "accept", "disabled"], cn = {
918
921
  key: 1,
919
922
  class: "el-upload__tip"
920
- }, un = {
923
+ }, dn = {
921
924
  key: 2,
922
925
  class: "el-upload-list el-upload-list--text"
923
- }, cn = { class: "el-upload-list__item-info" }, dn = ["href", "target", "onClick"], pn = { class: "el-upload-list__item-file-name" }, fn = { class: "el-upload-list__item-status-label" };
924
- function hn(e, t, n, r, s, o) {
925
- const m = F("el-button"), h = F("Document"), $ = F("el-icon"), _ = F("CircleCheck"), N = F("CircleClose"), g = F("Close"), p = F("el-progress");
926
- return u(), b("div", an, [
927
- w("input", {
926
+ }, pn = { class: "el-upload-list__item-info" }, fn = ["href", "target", "onClick"], hn = { class: "el-upload-list__item-file-name" }, mn = { class: "el-upload-list__item-status-label" };
927
+ function gn(e, t, n, r, s, o) {
928
+ const m = F("el-button"), h = F("Document"), $ = F("el-icon"), b = F("CircleCheck"), x = F("CircleClose"), M = F("Close"), u = F("el-progress");
929
+ return p(), v("div", on, [
930
+ _("input", {
928
931
  ref: "fileInput",
929
932
  type: "file",
930
933
  class: "file-input",
931
934
  multiple: o.multiple,
932
935
  accept: n.accept,
933
936
  disabled: n.disabled,
934
- onChange: t[0] || (t[0] = (...d) => o.onFileChange && o.onFileChange(...d))
935
- }, null, 40, rn),
936
- n.showButton ? (u(), P(m, {
937
+ onChange: t[0] || (t[0] = (...c) => o.onFileChange && o.onFileChange(...c))
938
+ }, null, 40, un),
939
+ n.showButton ? (p(), P(m, {
937
940
  key: 0,
938
941
  type: "primary",
939
942
  disabled: n.disabled || !o.showUploadBtn,
940
943
  onClick: o.handleUpload
941
944
  }, {
942
945
  default: S(() => [
943
- K(T(n.buttonText), 1)
946
+ j(T(n.buttonText), 1)
944
947
  ]),
945
948
  _: 1
946
949
  }, 8, ["disabled", "onClick"])) : D("", !0),
947
- o.tipText ? (u(), b("div", on, T(o.tipText), 1)) : D("", !0),
948
- n.showFileList ? (u(), b("ul", un, [
949
- (u(!0), b(W, null, q(s.fileList, (d, c) => (u(), b("li", {
950
- key: d.uid,
951
- class: z(["el-upload-list__item", [`is-${d.status}`]]),
950
+ o.tipText ? (p(), v("div", cn, T(o.tipText), 1)) : D("", !0),
951
+ n.showFileList ? (p(), v("ul", dn, [
952
+ (p(!0), v(W, null, q(s.fileList, (c, d) => (p(), v("li", {
953
+ key: c.uid,
954
+ class: H(["el-upload-list__item", [`is-${c.status}`]]),
952
955
  tabindex: "0"
953
956
  }, [
954
- w("div", cn, [
955
- w("a", {
957
+ _("div", pn, [
958
+ _("a", {
956
959
  class: "el-upload-list__item-name",
957
- href: d.url || void 0,
958
- target: d.url ? "_blank" : void 0,
960
+ href: c.url || void 0,
961
+ target: c.url ? "_blank" : void 0,
959
962
  rel: "noopener noreferrer",
960
- onClick: de((x) => o.onFileClick(d), ["prevent"])
963
+ onClick: de((k) => o.onFileClick(c), ["prevent"])
961
964
  }, [
962
965
  U($, { class: "el-icon--document" }, {
963
966
  default: S(() => [
@@ -965,51 +968,51 @@ function hn(e, t, n, r, s, o) {
965
968
  ]),
966
969
  _: 1
967
970
  }),
968
- w("span", pn, T(d.name), 1)
969
- ], 8, dn)
971
+ _("span", hn, T(c.name), 1)
972
+ ], 8, fn)
970
973
  ]),
971
- w("label", fn, [
972
- d.status === "success" ? (u(), P($, {
974
+ _("label", mn, [
975
+ c.status === "success" ? (p(), P($, {
973
976
  key: 0,
974
977
  class: "el-icon--upload-success el-icon--circle-check"
975
978
  }, {
976
979
  default: S(() => [
977
- U(_)
980
+ U(b)
978
981
  ]),
979
982
  _: 1
980
- })) : d.status === "fail" ? (u(), P($, {
983
+ })) : c.status === "fail" ? (p(), P($, {
981
984
  key: 1,
982
985
  class: "el-icon--upload-fail"
983
986
  }, {
984
987
  default: S(() => [
985
- U(N)
988
+ U(x)
986
989
  ]),
987
990
  _: 1
988
991
  })) : D("", !0)
989
992
  ]),
990
- d.status !== "uploading" ? (u(), P($, {
993
+ c.status !== "uploading" ? (p(), P($, {
991
994
  key: 0,
992
995
  class: "el-icon--close",
993
996
  title: "删除",
994
- onClick: de((x) => o.removeFile(c), ["stop"])
997
+ onClick: de((k) => o.removeFile(d), ["stop"])
995
998
  }, {
996
999
  default: S(() => [
997
- U(g)
1000
+ U(M)
998
1001
  ]),
999
1002
  _: 1
1000
1003
  }, 8, ["onClick"])) : D("", !0),
1001
- d.status === "uploading" ? (u(), P(p, {
1004
+ c.status === "uploading" ? (p(), P(u, {
1002
1005
  key: 1,
1003
1006
  class: "el-upload-list__item-progress",
1004
1007
  type: "line",
1005
- percentage: d.percent,
1008
+ percentage: c.percent,
1006
1009
  "stroke-width": 2
1007
1010
  }, null, 8, ["percentage"])) : D("", !0)
1008
1011
  ], 2))), 128))
1009
1012
  ])) : D("", !0)
1010
1013
  ]);
1011
1014
  }
1012
- const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98"]]), gn = {
1015
+ const yn = /* @__PURE__ */ G(rn, [["render", gn], ["__scopeId", "data-v-0cf84609"]]), vn = {
1013
1016
  __name: "DateRangePicker",
1014
1017
  props: {
1015
1018
  start: {
@@ -1041,58 +1044,66 @@ const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98
1041
1044
  emits: ["update:start", "update:end", "change"],
1042
1045
  setup(e, { emit: t }) {
1043
1046
  const n = t, r = e;
1044
- function s(g) {
1045
- const p = new Date(g);
1046
- return p.setHours(0, 0, 0, 0), p;
1047
+ function s(u) {
1048
+ const c = new Date(u);
1049
+ return c.setHours(0, 0, 0, 0), c;
1047
1050
  }
1048
- function o(g) {
1049
- const p = new Date(g);
1050
- return p.setHours(23, 59, 59, 0), p;
1051
+ function o(u) {
1052
+ const c = new Date(u);
1053
+ return c.setHours(23, 59, 59, 0), c;
1051
1054
  }
1052
- function m(g) {
1053
- const p = o(/* @__PURE__ */ new Date()), d = s(/* @__PURE__ */ new Date());
1054
- return g(d), [d, p];
1055
+ function m(u) {
1056
+ const c = o(/* @__PURE__ */ new Date()), d = s(/* @__PURE__ */ new Date());
1057
+ return u(d), [d, c];
1055
1058
  }
1056
1059
  const h = [
1057
1060
  {
1058
1061
  text: "七天内",
1059
- value: () => m((g) => {
1060
- g.setDate(g.getDate() - 6);
1062
+ value: () => m((u) => {
1063
+ u.setDate(u.getDate() - 6);
1061
1064
  })
1062
1065
  },
1063
1066
  {
1064
1067
  text: "一个月内",
1065
- value: () => m((g) => {
1066
- g.setMonth(g.getMonth() - 1);
1068
+ value: () => m((u) => {
1069
+ u.setMonth(u.getMonth() - 1);
1067
1070
  })
1068
1071
  },
1069
1072
  {
1070
1073
  text: "一年内",
1071
- value: () => m((g) => {
1072
- g.setFullYear(g.getFullYear() - 1);
1074
+ value: () => m((u) => {
1075
+ u.setFullYear(u.getFullYear() - 1);
1073
1076
  })
1074
1077
  }
1075
1078
  ], $ = ye(() => {
1076
- var g;
1079
+ var u;
1077
1080
  if (r.showShortcuts)
1078
- return (g = r.shortcuts) != null && g.length ? r.shortcuts : h;
1079
- }), _ = A([]);
1081
+ return (u = r.shortcuts) != null && u.length ? r.shortcuts : h;
1082
+ }), b = A([]);
1083
+ function x(u, c) {
1084
+ if (u && c) {
1085
+ b.value = [u, c];
1086
+ return;
1087
+ }
1088
+ b.value = [];
1089
+ }
1080
1090
  se(
1081
1091
  () => [r.start, r.end],
1082
- ([g, p]) => {
1083
- _.value = g || p ? [g, p] : [];
1092
+ ([u, c]) => {
1093
+ x(u, c);
1084
1094
  }
1085
1095
  ), ve(() => {
1086
- _.value = r.start || r.end ? [r.start, r.end] : [];
1096
+ x(r.start, r.end);
1087
1097
  });
1088
- function N(g) {
1089
- n("update:start", g ? g[0] : ""), n("update:end", g ? g[1] : ""), n("change");
1098
+ function M(u) {
1099
+ const c = Array.isArray(u) ? u[0] : "", d = Array.isArray(u) ? u[1] : "";
1100
+ c && d ? (n("update:start", c), n("update:end", d)) : (n("update:start", ""), n("update:end", "")), n("change");
1090
1101
  }
1091
- return (g, p) => {
1102
+ return (u, c) => {
1092
1103
  const d = F("el-date-picker");
1093
- return u(), P(d, {
1094
- modelValue: _.value,
1095
- "onUpdate:modelValue": p[0] || (p[0] = (c) => _.value = c),
1104
+ return p(), P(d, {
1105
+ modelValue: b.value,
1106
+ "onUpdate:modelValue": c[0] || (c[0] = (k) => b.value = k),
1096
1107
  type: e.type,
1097
1108
  "range-separator": "至",
1098
1109
  "start-placeholder": e.title ? `${e.title} 开始` : "开始",
@@ -1101,18 +1112,18 @@ const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98
1101
1112
  "default-time": e.defaultTime,
1102
1113
  shortcuts: $.value,
1103
1114
  class: "date-range-picker",
1104
- onChange: N,
1115
+ onChange: M,
1105
1116
  clearable: e.canClearable
1106
1117
  }, null, 8, ["modelValue", "type", "start-placeholder", "value-format", "default-time", "shortcuts", "clearable"]);
1107
1118
  };
1108
1119
  }
1109
- }, Ge = /* @__PURE__ */ G(gn, [["__scopeId", "data-v-88a05aae"]]), yn = { class: "common-search__body" }, vn = { class: "common-search__control-wrap" }, bn = ["onKeyup"], _n = { class: "common-search__range-sep" }, wn = {
1120
+ }, Ge = /* @__PURE__ */ G(vn, [["__scopeId", "data-v-0dfa12ab"]]), bn = { class: "common-search__body" }, _n = { class: "common-search__control-wrap" }, wn = ["onKeyup"], Cn = { class: "common-search__range-sep" }, kn = {
1110
1121
  key: 5,
1111
1122
  class: "common-search__range"
1112
- }, Cn = {
1123
+ }, Un = {
1113
1124
  key: 0,
1114
1125
  class: "common-search__actions is-inline"
1115
- }, kn = { class: "common-search__actions-main" }, Un = /* @__PURE__ */ Object.assign({ name: "MgSearchForm" }, {
1126
+ }, xn = { class: "common-search__actions-main" }, Sn = /* @__PURE__ */ Object.assign({ name: "MgSearchForm" }, {
1116
1127
  __name: "SearchForm",
1117
1128
  props: {
1118
1129
  modelValue: { type: Object, default: () => ({}) },
@@ -1120,17 +1131,17 @@ const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98
1120
1131
  },
1121
1132
  emits: ["change", "search", "reset", "update:modelValue"],
1122
1133
  setup(e, { emit: t }) {
1123
- const n = e, r = t, s = A({}), o = Ne({}), m = Ne({});
1134
+ const n = e, r = t, s = A({}), o = Le({}), m = Le({});
1124
1135
  let h = !1;
1125
1136
  function $(l, i) {
1126
1137
  return JSON.stringify(l ?? {}) === JSON.stringify(i ?? {});
1127
1138
  }
1128
- const _ = A(null), N = A(!1), g = A(!1), p = A(0), d = A(0), c = A(0), x = A(null);
1129
- let L = null, y = !1, R = !1;
1130
- const B = ye(() => {
1131
- if (!(!g.value || x.value == null))
1139
+ const b = A(null), x = A(!1), M = A(!1), u = A(0), c = A(0), d = A(0), k = A(null);
1140
+ let L = null, g = !1, B = !1;
1141
+ const R = ye(() => {
1142
+ if (!(!M.value || k.value == null))
1132
1143
  return {
1133
- maxHeight: `${x.value}px`,
1144
+ maxHeight: `${k.value}px`,
1134
1145
  overflow: "hidden"
1135
1146
  };
1136
1147
  });
@@ -1140,21 +1151,21 @@ const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98
1140
1151
  function V(l = {}) {
1141
1152
  return String(l.tip || X(l) || "").trim();
1142
1153
  }
1143
- function H(l = "") {
1154
+ function z(l = "") {
1144
1155
  const i = String(l).trim();
1145
1156
  return !i || (/* @__PURE__ */ new Set(["全部", "或选择", "请输入或选择"])).has(i) ? "" : i.replace(/^请(输入|选择)/, "").trim() || i;
1146
1157
  }
1147
1158
  function J(l = {}, i = "") {
1148
1159
  if (l.placeholder != null && l.placeholder !== "") {
1149
- const k = H(l.placeholder);
1150
- if (k) return k;
1160
+ const C = z(l.placeholder);
1161
+ if (C) return C;
1151
1162
  }
1152
1163
  const f = X(l);
1153
- return f || H(i) || i;
1164
+ return f || z(i) || i;
1154
1165
  }
1155
1166
  function Ce(l = {}, i = "min") {
1156
- const f = i === "min" ? l.minPlaceholder : l.maxPlaceholder, C = X(l), k = i === "min" ? "最小值" : "最大值", M = /* @__PURE__ */ new Set(["最小", "最大", "最小值", "最大值"]);
1157
- return f != null && f !== "" ? C && M.has(String(f).trim()) ? `${C}${f}` : f : C ? `${C}${k}` : k;
1167
+ const f = i === "min" ? l.minPlaceholder : l.maxPlaceholder, w = X(l), C = i === "min" ? "最小值" : "最大值", N = /* @__PURE__ */ new Set(["最小", "最大", "最小值", "最大值"]);
1168
+ return f != null && f !== "" ? w && N.has(String(f).trim()) ? `${w}${f}` : f : w ? `${w}${C}` : C;
1158
1169
  }
1159
1170
  se(
1160
1171
  () => n.modelValue,
@@ -1173,56 +1184,56 @@ const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98
1173
1184
  ), se(
1174
1185
  () => n.itemList,
1175
1186
  () => {
1176
- N.value = !1, p.value = 0, Z(() => Q());
1187
+ x.value = !1, u.value = 0, Z(() => Q());
1177
1188
  },
1178
1189
  { deep: !0 }
1179
1190
  ), ve(() => {
1180
1191
  Z(() => Q()), typeof ResizeObserver < "u" && (L = new ResizeObserver(() => {
1181
- !y && !R && Q();
1182
- }), _.value && L.observe(_.value)), window.addEventListener("resize", ke);
1183
- }), ze(() => {
1192
+ !g && !B && Q();
1193
+ }), b.value && L.observe(b.value)), window.addEventListener("resize", ke);
1194
+ }), He(() => {
1184
1195
  L == null || L.disconnect(), window.removeEventListener("resize", ke);
1185
1196
  });
1186
1197
  function ke() {
1187
- !y && !R && Q();
1198
+ !g && !B && Q();
1188
1199
  }
1189
1200
  function Je(l) {
1190
1201
  const i = n.itemList.length;
1191
1202
  if (!i) return !1;
1192
- const f = p.value > 0 ? p.value : i;
1203
+ const f = u.value > 0 ? u.value : i;
1193
1204
  return l === Math.min(f, i) - 1;
1194
1205
  }
1195
- function Qe(l, i, f, C) {
1196
- let k = 1, M = l[i].offsetWidth;
1206
+ function Qe(l, i, f, w) {
1207
+ let C = 1, N = l[i].offsetWidth;
1197
1208
  for (let O = i + 1; O < l.length; O += 1) {
1198
1209
  const I = l[O].offsetWidth;
1199
- M + C + I > f ? (k += 1, M = I) : M += C + I;
1210
+ N + w + I > f ? (C += 1, N = I) : N += w + I;
1200
1211
  }
1201
- return k;
1212
+ return C;
1202
1213
  }
1203
- function Ze(l, i, f, C) {
1204
- let k = 0, M = 0;
1214
+ function Ze(l, i, f, w) {
1215
+ let C = 0, N = 0;
1205
1216
  for (let O = 0; O < l.length; O += 1) {
1206
- const I = l[O].offsetWidth, Y = k === 0 ? I : k + C + I;
1207
- if (Y + C + f <= i)
1208
- k = Y, M = O + 1;
1217
+ const I = l[O].offsetWidth, Y = C === 0 ? I : C + w + I;
1218
+ if (Y + w + f <= i)
1219
+ C = Y, N = O + 1;
1209
1220
  else
1210
1221
  break;
1211
1222
  }
1212
- return M || 1;
1223
+ return N || 1;
1213
1224
  }
1214
1225
  function et(l) {
1215
1226
  const i = l.type === "number-range" || l.type === "numberRange", f = 360;
1216
1227
  if (!l.width) {
1217
1228
  if (i) {
1218
- const M = `${f}px`;
1219
- return { width: M, minWidth: M };
1229
+ const N = `${f}px`;
1230
+ return { width: N, minWidth: N };
1220
1231
  }
1221
1232
  return;
1222
1233
  }
1223
- let C = typeof l.width == "number" ? l.width : parseInt(String(l.width), 10);
1224
- const k = typeof l.width == "number" || Number.isFinite(C) ? `${C}px` : l.width;
1225
- return { width: k, minWidth: k };
1234
+ let w = typeof l.width == "number" ? l.width : parseInt(String(l.width), 10);
1235
+ const C = typeof l.width == "number" || Number.isFinite(w) ? `${w}px` : l.width;
1236
+ return { width: C, minWidth: C };
1226
1237
  }
1227
1238
  function Ue(l, i) {
1228
1239
  if (l == null) return "";
@@ -1243,25 +1254,25 @@ const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98
1243
1254
  if (l == null || l === "") return;
1244
1255
  const f = Ie(l, i);
1245
1256
  if (f == null || f === "") return;
1246
- const C = Number(String(f).replace(/,/g, ""));
1247
- return Number.isFinite(C) ? C : void 0;
1257
+ const w = Number(String(f).replace(/,/g, ""));
1258
+ return Number.isFinite(w) ? w : void 0;
1248
1259
  }
1249
1260
  function fe(l) {
1250
- const { startKey: i, endKey: f } = pe(l), C = l.precision ?? 2;
1251
- let k = xe(s.value[i], C), M = xe(s.value[f], C);
1252
- k != null && M != null && k > M && ([k, M] = [M, k]), s.value[i] = k, s.value[f] = M;
1261
+ const { startKey: i, endKey: f } = pe(l), w = l.precision ?? 2;
1262
+ let C = xe(s.value[i], w), N = xe(s.value[f], w);
1263
+ C != null && N != null && C > N && ([C, N] = [N, C]), s.value[i] = C, s.value[f] = N;
1253
1264
  }
1254
1265
  function tt(l) {
1255
- fe(l), j();
1266
+ fe(l), E();
1256
1267
  }
1257
1268
  function nt(l) {
1258
- const { startKey: i, endKey: f } = pe(l), C = s.value[i], k = s.value[f];
1259
- return C != null && C !== "" || k != null && k !== "";
1269
+ const { startKey: i, endKey: f } = pe(l), w = s.value[i], C = s.value[f];
1270
+ return w != null && w !== "" || C != null && C !== "";
1260
1271
  }
1261
1272
  function lt(l) {
1262
1273
  if (l.disabled) return;
1263
1274
  const { startKey: i, endKey: f } = pe(l);
1264
- s.value[i] = void 0, s.value[f] = void 0, j();
1275
+ s.value[i] = void 0, s.value[f] = void 0, E();
1265
1276
  }
1266
1277
  async function st(l, i) {
1267
1278
  if (typeof l.remoteMethod == "function") {
@@ -1275,51 +1286,51 @@ const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98
1275
1286
  }
1276
1287
  }
1277
1288
  function he(l) {
1278
- const i = l.style.maxHeight, f = l.style.overflow, C = l.style.transition;
1289
+ const i = l.style.maxHeight, f = l.style.overflow, w = l.style.transition;
1279
1290
  l.style.transition = "none", l.style.maxHeight = "none", l.style.overflow = "visible";
1280
- const k = l.scrollHeight;
1281
- return l.style.maxHeight = i, l.style.overflow = f, l.offsetHeight, l.style.transition = C, k;
1291
+ const C = l.scrollHeight;
1292
+ return l.style.maxHeight = i, l.style.overflow = f, l.offsetHeight, l.style.transition = w, C;
1282
1293
  }
1283
1294
  function Q() {
1284
- const l = _.value;
1285
- if (!l || y || R) return;
1286
- y = !0;
1287
- const i = l.closest(".common-search"), f = Array.from(l.querySelectorAll(".common-search__field")), C = l.querySelector(".common-search__actions");
1295
+ const l = b.value;
1296
+ if (!l || g || B) return;
1297
+ g = !0;
1298
+ const i = l.closest(".common-search"), f = Array.from(l.querySelectorAll(".common-search__field")), w = l.querySelector(".common-search__actions");
1288
1299
  if (!f.length || !i) {
1289
- g.value = !1, d.value = 0, c.value = 0, x.value = null, p.value = 0, y = !1;
1300
+ M.value = !1, c.value = 0, d.value = 0, k.value = null, u.value = 0, g = !1;
1290
1301
  return;
1291
1302
  }
1292
- d.value = f[0].offsetHeight, c.value = he(l);
1293
- const k = 16, M = i.clientWidth, O = (C == null ? void 0 : C.offsetWidth) || 220, I = Ze(f, M, O, k);
1303
+ c.value = f[0].offsetHeight, d.value = he(l);
1304
+ const C = 16, N = i.clientWidth, O = (w == null ? void 0 : w.offsetWidth) || 220, I = Ze(f, N, O, C);
1294
1305
  let Y = 1;
1295
- f.length > I && (Y += Qe(f, I, M, k));
1296
- const le = p.value;
1297
- p.value = I;
1298
- const a = Y > 1, ue = g.value;
1299
- g.value = a, a ? N.value ? x.value = null : x.value = d.value : (N.value = !1, x.value = null), y = !1, (ue !== a || le !== I) && Z(() => Q());
1306
+ f.length > I && (Y += Qe(f, I, N, C));
1307
+ const le = u.value;
1308
+ u.value = I;
1309
+ const a = Y > 1, ue = M.value;
1310
+ M.value = a, a ? x.value ? k.value = null : k.value = c.value : (x.value = !1, k.value = null), g = !1, (ue !== a || le !== I) && Z(() => Q());
1300
1311
  }
1301
1312
  function at() {
1302
- const l = _.value;
1303
- if (!l || R) return;
1304
- R = !0;
1305
- const i = l.getBoundingClientRect().height || d.value;
1306
- if (N.value)
1307
- x.value = i || he(l), N.value = !1, requestAnimationFrame(() => {
1313
+ const l = b.value;
1314
+ if (!l || B) return;
1315
+ B = !0;
1316
+ const i = l.getBoundingClientRect().height || c.value;
1317
+ if (x.value)
1318
+ k.value = i || he(l), x.value = !1, requestAnimationFrame(() => {
1308
1319
  requestAnimationFrame(() => {
1309
- x.value = d.value;
1320
+ k.value = c.value;
1310
1321
  });
1311
1322
  });
1312
1323
  else {
1313
- x.value = i;
1324
+ k.value = i;
1314
1325
  const f = he(l);
1315
- c.value = f, N.value = !0, requestAnimationFrame(() => {
1326
+ d.value = f, x.value = !0, requestAnimationFrame(() => {
1316
1327
  requestAnimationFrame(() => {
1317
- x.value = Math.max(f, d.value || 0);
1328
+ k.value = Math.max(f, c.value || 0);
1318
1329
  });
1319
1330
  });
1320
1331
  }
1321
1332
  window.setTimeout(() => {
1322
- R = !1, N.value && (x.value = null), Q();
1333
+ B = !1, x.value && (k.value = null), Q();
1323
1334
  }, 380);
1324
1335
  }
1325
1336
  function rt() {
@@ -1331,34 +1342,34 @@ const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98
1331
1342
  function Se() {
1332
1343
  r("update:modelValue", { ...s.value });
1333
1344
  }
1334
- function j() {
1345
+ function E() {
1335
1346
  Se(), r("change", { ...s.value }), r("search", { ...s.value });
1336
1347
  }
1337
1348
  function Fe() {
1338
1349
  s.value = rt(), Se(), r("reset", { ...s.value }), r("change", { ...s.value });
1339
1350
  }
1340
1351
  return (l, i) => {
1341
- const f = F("el-input"), C = F("el-option"), k = F("el-select"), M = F("el-input-number"), O = F("el-icon"), I = F("el-date-picker"), Y = F("el-tooltip"), le = F("el-button");
1342
- return ee((u(), b("div", {
1343
- class: z(["common-search", {
1344
- "is-single-row": !g.value,
1345
- "is-multi-row": g.value,
1346
- "is-expanded": g.value && N.value,
1347
- "is-collapsed": g.value && !N.value
1352
+ const f = F("el-input"), w = F("el-option"), C = F("el-select"), N = F("el-input-number"), O = F("el-icon"), I = F("el-date-picker"), Y = F("el-tooltip"), le = F("el-button");
1353
+ return ee((p(), v("div", {
1354
+ class: H(["common-search", {
1355
+ "is-single-row": !M.value,
1356
+ "is-multi-row": M.value,
1357
+ "is-expanded": M.value && x.value,
1358
+ "is-collapsed": M.value && !x.value
1348
1359
  }])
1349
1360
  }, [
1350
- w("div", yn, [
1351
- w("div", {
1361
+ _("div", bn, [
1362
+ _("div", {
1352
1363
  ref_key: "fieldsRef",
1353
- ref: _,
1364
+ ref: b,
1354
1365
  class: "common-search__fields",
1355
- style: re(B.value)
1366
+ style: re(R.value)
1356
1367
  }, [
1357
- (u(!0), b(W, null, q(e.itemList, (a, ue) => (u(), b(W, {
1368
+ (p(!0), v(W, null, q(e.itemList, (a, ue) => (p(), v(W, {
1358
1369
  key: a.prop || a.start || ue
1359
1370
  }, [
1360
- w("div", {
1361
- class: z(["common-search__field", [`is-${a.type}`, a.className]]),
1371
+ _("div", {
1372
+ class: H(["common-search__field", [`is-${a.type}`, a.className]]),
1362
1373
  style: re(et(a))
1363
1374
  }, [
1364
1375
  U(Y, {
@@ -1368,23 +1379,23 @@ const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98
1368
1379
  "show-after": 280
1369
1380
  }, {
1370
1381
  default: S(() => [
1371
- w("div", vn, [
1372
- a.type === "input" || a.type === "text" ? (u(), P(f, {
1382
+ _("div", _n, [
1383
+ a.type === "input" || a.type === "text" ? (p(), P(f, {
1373
1384
  key: 0,
1374
1385
  modelValue: s.value[a.prop],
1375
- "onUpdate:modelValue": (v) => s.value[a.prop] = v,
1386
+ "onUpdate:modelValue": (y) => s.value[a.prop] = y,
1376
1387
  modelModifiers: { trim: !0 },
1377
1388
  clearable: "",
1378
1389
  placeholder: J(a, "请输入"),
1379
1390
  maxlength: a.maxlength || 200,
1380
1391
  disabled: a.disabled,
1381
1392
  class: "common-search__control",
1382
- onKeyup: Le(j, ["enter"]),
1383
- onClear: j
1384
- }, null, 8, ["modelValue", "onUpdate:modelValue", "placeholder", "maxlength", "disabled"])) : a.type === "select" ? (u(), P(k, {
1393
+ onKeyup: Ne(E, ["enter"]),
1394
+ onClear: E
1395
+ }, null, 8, ["modelValue", "onUpdate:modelValue", "placeholder", "maxlength", "disabled"])) : a.type === "select" ? (p(), P(C, {
1385
1396
  key: 1,
1386
1397
  modelValue: s.value[a.prop],
1387
- "onUpdate:modelValue": (v) => s.value[a.prop] = v,
1398
+ "onUpdate:modelValue": (y) => s.value[a.prop] = y,
1388
1399
  placeholder: J(a, "请选择"),
1389
1400
  clearable: "",
1390
1401
  filterable: a.filterable !== !1,
@@ -1393,21 +1404,21 @@ const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98
1393
1404
  "collapse-tags-tooltip": a.multiple,
1394
1405
  disabled: a.disabled,
1395
1406
  class: "common-search__control",
1396
- onChange: j
1407
+ onChange: E
1397
1408
  }, {
1398
1409
  default: S(() => [
1399
- (u(!0), b(W, null, q(a.options || [], (v, me) => (u(), P(C, {
1400
- key: `${ie(v, a)}-${me}`,
1401
- label: Ue(v, a),
1402
- value: ie(v, a),
1403
- disabled: typeof v == "object" && (v == null ? void 0 : v.disabled)
1410
+ (p(!0), v(W, null, q(a.options || [], (y, me) => (p(), P(w, {
1411
+ key: `${ie(y, a)}-${me}`,
1412
+ label: Ue(y, a),
1413
+ value: ie(y, a),
1414
+ disabled: typeof y == "object" && (y == null ? void 0 : y.disabled)
1404
1415
  }, null, 8, ["label", "value", "disabled"]))), 128))
1405
1416
  ]),
1406
1417
  _: 2
1407
- }, 1032, ["modelValue", "onUpdate:modelValue", "placeholder", "filterable", "multiple", "collapse-tags", "collapse-tags-tooltip", "disabled"])) : a.type === "remote-select" || a.type === "remoteSelect" ? (u(), P(k, {
1418
+ }, 1032, ["modelValue", "onUpdate:modelValue", "placeholder", "filterable", "multiple", "collapse-tags", "collapse-tags-tooltip", "disabled"])) : a.type === "remote-select" || a.type === "remoteSelect" ? (p(), P(C, {
1408
1419
  key: 2,
1409
1420
  modelValue: s.value[a.prop],
1410
- "onUpdate:modelValue": (v) => s.value[a.prop] = v,
1421
+ "onUpdate:modelValue": (y) => s.value[a.prop] = y,
1411
1422
  placeholder: J(a, "请输入关键词搜索"),
1412
1423
  clearable: "",
1413
1424
  filterable: "",
@@ -1416,66 +1427,66 @@ const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98
1416
1427
  "collapse-tags": a.multiple,
1417
1428
  "collapse-tags-tooltip": a.multiple,
1418
1429
  "reserve-keyword": !1,
1419
- "remote-method": (v) => st(a, v),
1430
+ "remote-method": (y) => st(a, y),
1420
1431
  loading: !!m[a.prop],
1421
1432
  disabled: a.disabled,
1422
1433
  class: "common-search__control",
1423
- onClear: (v) => o[a.prop] = [],
1424
- onChange: j
1434
+ onClear: (y) => o[a.prop] = [],
1435
+ onChange: E
1425
1436
  }, {
1426
1437
  default: S(() => [
1427
- (u(!0), b(W, null, q(o[a.prop] || a.options || [], (v, me) => (u(), P(C, {
1428
- key: `${ie(v, a)}-${me}`,
1429
- label: Ue(v, a),
1430
- value: ie(v, a),
1431
- disabled: typeof v == "object" && (v == null ? void 0 : v.disabled)
1438
+ (p(!0), v(W, null, q(o[a.prop] || a.options || [], (y, me) => (p(), P(w, {
1439
+ key: `${ie(y, a)}-${me}`,
1440
+ label: Ue(y, a),
1441
+ value: ie(y, a),
1442
+ disabled: typeof y == "object" && (y == null ? void 0 : y.disabled)
1432
1443
  }, null, 8, ["label", "value", "disabled"]))), 128))
1433
1444
  ]),
1434
1445
  _: 2
1435
- }, 1032, ["modelValue", "onUpdate:modelValue", "placeholder", "multiple", "collapse-tags", "collapse-tags-tooltip", "remote-method", "loading", "disabled", "onClear"])) : a.type === "number-range" || a.type === "numberRange" ? (u(), b("div", {
1446
+ }, 1032, ["modelValue", "onUpdate:modelValue", "placeholder", "multiple", "collapse-tags", "collapse-tags-tooltip", "remote-method", "loading", "disabled", "onClear"])) : a.type === "number-range" || a.type === "numberRange" ? (p(), v("div", {
1436
1447
  key: 3,
1437
1448
  class: "common-search__range common-search__range--number",
1438
- onKeyup: Le((v) => tt(a), ["enter"])
1449
+ onKeyup: Ne((y) => tt(a), ["enter"])
1439
1450
  }, [
1440
- U(M, {
1451
+ U(N, {
1441
1452
  modelValue: s.value[a.start || `${a.prop}Min`],
1442
- "onUpdate:modelValue": (v) => s.value[a.start || `${a.prop}Min`] = v,
1453
+ "onUpdate:modelValue": (y) => s.value[a.start || `${a.prop}Min`] = y,
1443
1454
  controls: !1,
1444
1455
  min: a.min,
1445
1456
  max: a.max,
1446
1457
  placeholder: Ce(a, "min"),
1447
1458
  disabled: a.disabled,
1448
1459
  class: "common-search__range-input",
1449
- onBlur: (v) => fe(a)
1460
+ onBlur: (y) => fe(a)
1450
1461
  }, null, 8, ["modelValue", "onUpdate:modelValue", "min", "max", "placeholder", "disabled", "onBlur"]),
1451
- w("span", _n, T(a.separator || "至"), 1),
1452
- U(M, {
1462
+ _("span", Cn, T(a.separator || "至"), 1),
1463
+ U(N, {
1453
1464
  modelValue: s.value[a.end || `${a.prop}Max`],
1454
- "onUpdate:modelValue": (v) => s.value[a.end || `${a.prop}Max`] = v,
1465
+ "onUpdate:modelValue": (y) => s.value[a.end || `${a.prop}Max`] = y,
1455
1466
  controls: !1,
1456
1467
  min: a.min,
1457
1468
  max: a.max,
1458
1469
  placeholder: Ce(a, "max"),
1459
1470
  disabled: a.disabled,
1460
1471
  class: "common-search__range-input",
1461
- onBlur: (v) => fe(a)
1472
+ onBlur: (y) => fe(a)
1462
1473
  }, null, 8, ["modelValue", "onUpdate:modelValue", "min", "max", "placeholder", "disabled", "onBlur"]),
1463
- a.clearable !== !1 && nt(a) ? (u(), P(O, {
1474
+ a.clearable !== !1 && nt(a) ? (p(), P(O, {
1464
1475
  key: 0,
1465
1476
  class: "common-search__range-clear",
1466
1477
  onMousedown: i[0] || (i[0] = de(() => {
1467
1478
  }, ["prevent"])),
1468
- onClick: (v) => lt(a)
1479
+ onClick: (y) => lt(a)
1469
1480
  }, {
1470
1481
  default: S(() => [
1471
1482
  U(ne(Ve))
1472
1483
  ]),
1473
1484
  _: 1
1474
1485
  }, 8, ["onClick"])) : D("", !0)
1475
- ], 40, bn)) : a.type === "date" ? (u(), P(I, {
1486
+ ], 40, wn)) : a.type === "date" ? (p(), P(I, {
1476
1487
  key: 4,
1477
1488
  modelValue: s.value[a.prop],
1478
- "onUpdate:modelValue": (v) => s.value[a.prop] = v,
1489
+ "onUpdate:modelValue": (y) => s.value[a.prop] = y,
1479
1490
  type: a.dateType || "date",
1480
1491
  placeholder: J(a, "年/月/日"),
1481
1492
  "value-format": a.valueFormat || "YYYY-MM-DD",
@@ -1483,13 +1494,13 @@ const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98
1483
1494
  clearable: a.clearable !== !1,
1484
1495
  disabled: a.disabled,
1485
1496
  class: "common-search__control",
1486
- onChange: j
1487
- }, null, 8, ["modelValue", "onUpdate:modelValue", "type", "placeholder", "value-format", "format", "clearable", "disabled"])) : a.type === "daterange" || a.type === "dateRange" ? (u(), b("div", wn, [
1497
+ onChange: E
1498
+ }, null, 8, ["modelValue", "onUpdate:modelValue", "type", "placeholder", "value-format", "format", "clearable", "disabled"])) : a.type === "daterange" || a.type === "dateRange" ? (p(), v("div", kn, [
1488
1499
  U(Ge, {
1489
1500
  start: s.value[a.start || a.startProp],
1490
- "onUpdate:start": (v) => s.value[a.start || a.startProp] = v,
1501
+ "onUpdate:start": (y) => s.value[a.start || a.startProp] = y,
1491
1502
  end: s.value[a.end || a.endProp],
1492
- "onUpdate:end": (v) => s.value[a.end || a.endProp] = v,
1503
+ "onUpdate:end": (y) => s.value[a.end || a.endProp] = y,
1493
1504
  title: a.label || a.title || "",
1494
1505
  type: a.dateType || a.pickerType || "daterange",
1495
1506
  "value-format": a.valueFormat || "YYYY-MM-DD HH:mm:ss",
@@ -1497,7 +1508,7 @@ const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98
1497
1508
  "show-shortcuts": a.showShortcuts !== !1,
1498
1509
  shortcuts: a.shortcuts,
1499
1510
  "can-clearable": a.clearable !== !1,
1500
- onChange: j
1511
+ onChange: E
1501
1512
  }, null, 8, ["start", "onUpdate:start", "end", "onUpdate:end", "title", "type", "value-format", "format", "show-shortcuts", "shortcuts", "can-clearable"])
1502
1513
  ])) : ae(l.$slots, a.slotName || a.prop, {
1503
1514
  item: a,
@@ -1508,10 +1519,10 @@ const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98
1508
1519
  _: 2
1509
1520
  }, 1032, ["content", "disabled"])
1510
1521
  ], 6),
1511
- Je(ue) ? (u(), b("div", Cn, [
1512
- w("div", kn, [
1522
+ Je(ue) ? (p(), v("div", Un, [
1523
+ _("div", xn, [
1513
1524
  ae(l.$slots, "actions", {
1514
- search: j,
1525
+ search: E,
1515
1526
  reset: Fe,
1516
1527
  form: s.value
1517
1528
  }, () => [
@@ -1520,32 +1531,32 @@ const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98
1520
1531
  onClick: Fe
1521
1532
  }, {
1522
1533
  default: S(() => [...i[1] || (i[1] = [
1523
- K("重置", -1)
1534
+ j("重置", -1)
1524
1535
  ])]),
1525
1536
  _: 1
1526
1537
  }),
1527
1538
  U(le, {
1528
1539
  type: "primary",
1529
1540
  class: "common-search__submit",
1530
- onClick: j
1541
+ onClick: E
1531
1542
  }, {
1532
1543
  default: S(() => [...i[2] || (i[2] = [
1533
- K(" 搜索 ", -1)
1544
+ j(" 搜索 ", -1)
1534
1545
  ])]),
1535
1546
  _: 1
1536
1547
  })
1537
1548
  ], !0),
1538
- g.value ? (u(), P(le, {
1549
+ M.value ? (p(), P(le, {
1539
1550
  key: 0,
1540
1551
  link: "",
1541
1552
  type: "primary",
1542
1553
  onClick: at
1543
1554
  }, {
1544
1555
  default: S(() => [
1545
- K(T(N.value ? "收起" : "展开") + " ", 1),
1556
+ j(T(x.value ? "收起" : "展开") + " ", 1),
1546
1557
  U(O, { class: "el-icon--right" }, {
1547
1558
  default: S(() => [
1548
- N.value ? (u(), P(ne(ft), { key: 0 })) : (u(), P(ne(ht), { key: 1 }))
1559
+ x.value ? (p(), P(ne(ft), { key: 0 })) : (p(), P(ne(ht), { key: 1 }))
1549
1560
  ]),
1550
1561
  _: 1
1551
1562
  })
@@ -1562,7 +1573,7 @@ const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98
1562
1573
  ]);
1563
1574
  };
1564
1575
  }
1565
- }), xn = /* @__PURE__ */ G(Un, [["__scopeId", "data-v-006c1ace"]]), Sn = {
1576
+ }), Fn = /* @__PURE__ */ G(Sn, [["__scopeId", "data-v-006c1ace"]]), $n = {
1566
1577
  name: "MgOverflowHid",
1567
1578
  props: {
1568
1579
  label: String,
@@ -1585,65 +1596,65 @@ const mn = /* @__PURE__ */ G(sn, [["render", hn], ["__scopeId", "data-v-a13d2c98
1585
1596
  return n && n.length > t && (n = n.slice(0, t) + "..."), n;
1586
1597
  }
1587
1598
  }
1588
- }, Fn = { class: "tableOverflowHid" }, $n = ["innerHTML"], Nn = { class: "name-wrapper" }, Ln = ["innerHTML"], Mn = { key: 1 }, Pn = ["innerHTML"];
1589
- function Tn(e, t, n, r, s, o) {
1599
+ }, Ln = { class: "tableOverflowHid" }, Nn = ["innerHTML"], Mn = { class: "name-wrapper" }, Pn = ["innerHTML"], Tn = { key: 1 }, Rn = ["innerHTML"];
1600
+ function Bn(e, t, n, r, s, o) {
1590
1601
  const m = F("el-popover");
1591
- return u(), b("div", Fn, [
1592
- n.value && n.value.length > n.maxLength ? (u(), P(m, {
1602
+ return p(), v("div", Ln, [
1603
+ n.value && n.value.length > n.maxLength ? (p(), P(m, {
1593
1604
  key: 0,
1594
1605
  trigger: "hover",
1595
1606
  placement: "bottom",
1596
1607
  width: "400"
1597
1608
  }, {
1598
1609
  reference: S(() => [
1599
- w("div", Nn, [
1600
- ee(w("span", {
1601
- class: z(n.labelClassName)
1610
+ _("div", Mn, [
1611
+ ee(_("span", {
1612
+ class: H(n.labelClassName)
1602
1613
  }, T(n.label) + ":", 3), [
1603
1614
  [te, n.label]
1604
1615
  ]),
1605
- w("span", {
1606
- class: z(n.valueClassName),
1616
+ _("span", {
1617
+ class: H(n.valueClassName),
1607
1618
  innerHTML: o.cutString(n.value, n.maxLength)
1608
- }, null, 10, Ln)
1619
+ }, null, 10, Pn)
1609
1620
  ])
1610
1621
  ]),
1611
1622
  default: S(() => [
1612
- ee(w("span", {
1613
- class: z(n.labelClassName)
1623
+ ee(_("span", {
1624
+ class: H(n.labelClassName)
1614
1625
  }, T(n.label) + ":", 3), [
1615
1626
  [te, n.label]
1616
1627
  ]),
1617
- w("span", { innerHTML: n.value }, null, 8, $n)
1628
+ _("span", { innerHTML: n.value }, null, 8, Nn)
1618
1629
  ]),
1619
1630
  _: 1
1620
- })) : (u(), b("div", Mn, [
1621
- ee(w("span", {
1622
- class: z(n.labelClassName)
1631
+ })) : (p(), v("div", Tn, [
1632
+ ee(_("span", {
1633
+ class: H(n.labelClassName)
1623
1634
  }, T(n.label) + ":", 3), [
1624
1635
  [te, n.label]
1625
1636
  ]),
1626
- w("span", {
1627
- class: z([n.valueClassName, "value"])
1637
+ _("span", {
1638
+ class: H([n.valueClassName, "value"])
1628
1639
  }, [
1629
- w("span", { innerHTML: n.value }, null, 8, Pn)
1640
+ _("span", { innerHTML: n.value }, null, 8, Rn)
1630
1641
  ], 2)
1631
1642
  ]))
1632
1643
  ]);
1633
1644
  }
1634
- const Xe = /* @__PURE__ */ G(Sn, [["render", Tn], ["__scopeId", "data-v-ef86ea54"]]), Bn = { class: "common-table__main" }, Rn = { key: 0 }, Dn = { key: 1 }, Vn = {
1645
+ const Xe = /* @__PURE__ */ G($n, [["render", Bn], ["__scopeId", "data-v-ef86ea54"]]), Dn = { class: "common-table__main" }, Vn = { key: 0 }, On = { key: 1 }, In = {
1635
1646
  key: 2,
1636
1647
  class: "price-text"
1637
- }, On = {
1648
+ }, An = {
1638
1649
  key: 3,
1639
1650
  class: "rate-text"
1640
- }, In = {
1651
+ }, Hn = {
1641
1652
  key: 4,
1642
1653
  class: "bold-text"
1643
- }, An = {
1654
+ }, zn = {
1644
1655
  key: 0,
1645
1656
  class: "common-table__pagination"
1646
- }, zn = /* @__PURE__ */ Object.assign({ name: "MgDataTable" }, {
1657
+ }, En = /* @__PURE__ */ Object.assign({ name: "MgDataTable" }, {
1647
1658
  __name: "DataTable",
1648
1659
  props: {
1649
1660
  /** 列配置:el-table-column 属性 + slotName */
@@ -1725,45 +1736,45 @@ const Xe = /* @__PURE__ */ G(Sn, [["render", Tn], ["__scopeId", "data-v-ef86ea54
1725
1736
  headerCellStyle: s,
1726
1737
  ...n.tableBind
1727
1738
  }));
1728
- function m(p) {
1729
- const { slotName: d, headerSlotName: c, maxLength: x, ...L } = p || {};
1739
+ function m(u) {
1740
+ const { slotName: c, headerSlotName: d, maxLength: k, ...L } = u || {};
1730
1741
  return {
1731
1742
  ...L
1732
1743
  };
1733
1744
  }
1734
- function h(p) {
1735
- return n.pagination ? (n.pagination.page - 1) * n.pagination.limit + p + 1 : p + 1;
1745
+ function h(u) {
1746
+ return n.pagination ? (n.pagination.page - 1) * n.pagination.limit + u + 1 : u + 1;
1736
1747
  }
1737
- function $(p) {
1738
- var d;
1739
- r("pageChange", { page: (d = n.pagination) == null ? void 0 : d.page, limit: p });
1748
+ function $(u) {
1749
+ var c;
1750
+ r("pageChange", { page: (c = n.pagination) == null ? void 0 : c.page, limit: u });
1740
1751
  }
1741
- function _(p) {
1742
- var d;
1743
- r("pageChange", { page: p, limit: (d = n.pagination) == null ? void 0 : d.limit });
1752
+ function b(u) {
1753
+ var c;
1754
+ r("pageChange", { page: u, limit: (c = n.pagination) == null ? void 0 : c.limit });
1744
1755
  }
1745
- function N(p, d, c, x) {
1746
- r("cellClick", p, d, c, x), n.canCellClick && (d == null ? void 0 : d.label) !== "操作" && window.getSelection().toString();
1756
+ function x(u, c, d, k) {
1757
+ r("cellClick", u, c, d, k), n.canCellClick && (c == null ? void 0 : c.label) !== "操作" && window.getSelection().toString();
1747
1758
  }
1748
- function g(p) {
1749
- r("selectionChange", p);
1759
+ function M(u) {
1760
+ r("selectionChange", u);
1750
1761
  }
1751
- return (p, d) => {
1752
- const c = F("el-table-column"), x = F("el-table"), L = F("el-pagination");
1753
- return u(), b("div", {
1754
- class: z(["common-table", { "is-fill-height": e.fillHeight }])
1762
+ return (u, c) => {
1763
+ const d = F("el-table-column"), k = F("el-table"), L = F("el-pagination");
1764
+ return p(), v("div", {
1765
+ class: H(["common-table", { "is-fill-height": e.fillHeight }])
1755
1766
  }, [
1756
- w("div", Bn, [
1757
- U(x, Me({
1767
+ _("div", Dn, [
1768
+ U(k, Me({
1758
1769
  data: e.dataList,
1759
1770
  height: e.fillHeight ? "100%" : void 0,
1760
1771
  class: { "common-pointer-table": e.canCellClick }
1761
1772
  }, o.value, {
1762
- onCellClick: N,
1763
- onSelectionChange: g
1773
+ onCellClick: x,
1774
+ onSelectionChange: M
1764
1775
  }), {
1765
1776
  default: S(() => [
1766
- e.showSelection ? (u(), P(c, {
1777
+ e.showSelection ? (p(), P(d, {
1767
1778
  key: 0,
1768
1779
  type: "selection",
1769
1780
  width: e.selectionWidth,
@@ -1771,7 +1782,7 @@ const Xe = /* @__PURE__ */ G(Sn, [["render", Tn], ["__scopeId", "data-v-ef86ea54
1771
1782
  selectable: e.selectable,
1772
1783
  fixed: "left"
1773
1784
  }, null, 8, ["width", "selectable"])) : D("", !0),
1774
- e.showIndex ? (u(), P(c, {
1785
+ e.showIndex ? (p(), P(d, {
1775
1786
  key: 1,
1776
1787
  type: "index",
1777
1788
  label: e.indexLabel,
@@ -1779,48 +1790,48 @@ const Xe = /* @__PURE__ */ G(Sn, [["render", Tn], ["__scopeId", "data-v-ef86ea54
1779
1790
  index: h,
1780
1791
  align: "center"
1781
1792
  }, null, 8, ["label", "width"])) : D("", !0),
1782
- (u(!0), b(W, null, q(e.propList, (y, R) => (u(), P(c, Me({
1783
- key: y.prop || y.slotName || R
1784
- }, { ref_for: !0 }, m(y)), Ut({ _: 2 }, [
1785
- y.headerSlotName ? {
1793
+ (p(!0), v(W, null, q(e.propList, (g, B) => (p(), P(d, Me({
1794
+ key: g.prop || g.slotName || B
1795
+ }, { ref_for: !0 }, m(g)), St({ _: 2 }, [
1796
+ g.headerSlotName ? {
1786
1797
  name: "header",
1787
1798
  fn: S(() => [
1788
- ae(p.$slots, y.headerSlotName, { column: y }, void 0, !0)
1799
+ ae(u.$slots, g.headerSlotName, { column: g }, void 0, !0)
1789
1800
  ]),
1790
1801
  key: "0"
1791
1802
  } : void 0,
1792
- y.slotName ? {
1803
+ g.slotName ? {
1793
1804
  name: "default",
1794
- fn: S((B) => [
1795
- y.slotName === "overtext" ? (u(), b("div", Rn, [
1805
+ fn: S((R) => [
1806
+ g.slotName === "overtext" ? (p(), v("div", Vn, [
1796
1807
  U(Xe, {
1797
- value: String(B.row[y.prop] ?? ""),
1798
- "max-length": y.maxLength || 18
1808
+ value: String(R.row[g.prop] ?? ""),
1809
+ "max-length": g.maxLength || 18
1799
1810
  }, null, 8, ["value", "max-length"])
1800
- ])) : y.slotName === "whether" ? (u(), b("div", Dn, [
1801
- w("span", {
1802
- class: z({
1803
- "whether-yes": B.row[y.prop] == 1,
1804
- "whether-no": B.row[y.prop] == 0
1811
+ ])) : g.slotName === "whether" ? (p(), v("div", On, [
1812
+ _("span", {
1813
+ class: H({
1814
+ "whether-yes": R.row[g.prop] == 1,
1815
+ "whether-no": R.row[g.prop] == 0
1805
1816
  })
1806
- }, T(B.row[y.prop] == 0 ? "否" : B.row[y.prop] == 1 ? "是" : ""), 3)
1807
- ])) : y.slotName === "price" ? (u(), b("div", Vn, T(ne(Ie)(B.row[y.prop], 2)), 1)) : y.slotName === "rate" ? (u(), b("div", On, T(ne(yt)(B.row[y.prop], 2, "toPercentText")), 1)) : y.slotName === "boldtext" ? (u(), b("div", In, T(B.row[y.prop]), 1)) : ae(p.$slots, y.slotName, {
1808
- row: B.row,
1809
- index: B.$index,
1810
- column: y
1817
+ }, T(R.row[g.prop] == 0 ? "否" : R.row[g.prop] == 1 ? "是" : ""), 3)
1818
+ ])) : g.slotName === "price" ? (p(), v("div", In, T(ne(Ie)(R.row[g.prop], 2)), 1)) : g.slotName === "rate" ? (p(), v("div", An, T(ne(vt)(R.row[g.prop], 2, "toPercentText")), 1)) : g.slotName === "boldtext" ? (p(), v("div", Hn, T(R.row[g.prop]), 1)) : ae(u.$slots, g.slotName, {
1819
+ row: R.row,
1820
+ index: R.$index,
1821
+ column: g
1811
1822
  }, () => [
1812
- K(T(ne(vt)(B.row[y.prop])), 1)
1823
+ j(T(ne(bt)(R.row[g.prop])), 1)
1813
1824
  ], !0, 5)
1814
1825
  ]),
1815
1826
  key: "1"
1816
1827
  } : void 0
1817
1828
  ]), 1040))), 128)),
1818
- ae(p.$slots, "default", {}, void 0, !0)
1829
+ ae(u.$slots, "default", {}, void 0, !0)
1819
1830
  ]),
1820
1831
  _: 3
1821
1832
  }, 16, ["data", "height", "class"])
1822
1833
  ]),
1823
- e.pagination ? (u(), b("div", An, [
1834
+ e.pagination ? (p(), v("div", zn, [
1824
1835
  U(L, {
1825
1836
  background: "",
1826
1837
  "current-page": e.pagination.page,
@@ -1829,16 +1840,16 @@ const Xe = /* @__PURE__ */ G(Sn, [["render", Tn], ["__scopeId", "data-v-ef86ea54
1829
1840
  total: e.pagination.total,
1830
1841
  layout: e.paginationLayout,
1831
1842
  onSizeChange: $,
1832
- onCurrentChange: _
1843
+ onCurrentChange: b
1833
1844
  }, null, 8, ["current-page", "page-size", "page-sizes", "total", "layout"])
1834
1845
  ])) : D("", !0)
1835
1846
  ], 2);
1836
1847
  };
1837
1848
  }
1838
- }), Hn = /* @__PURE__ */ G(zn, [["__scopeId", "data-v-bea5678b"]]), jn = ["aria-checked", "disabled", "onClick"], Kn = { class: "segmented__label" }, En = {
1849
+ }), jn = /* @__PURE__ */ G(En, [["__scopeId", "data-v-bea5678b"]]), Kn = ["aria-checked", "disabled", "onClick"], Wn = { class: "segmented__label" }, Yn = {
1839
1850
  key: 0,
1840
1851
  class: "segmented__badge"
1841
- }, Wn = {
1852
+ }, qn = {
1842
1853
  __name: "SegmentedControl",
1843
1854
  props: {
1844
1855
  modelValue: { type: [String, Number, Boolean], default: void 0 },
@@ -1852,73 +1863,73 @@ const Xe = /* @__PURE__ */ G(Sn, [["render", Tn], ["__scopeId", "data-v-ef86ea54
1852
1863
  transform: "translateX(0px)"
1853
1864
  });
1854
1865
  let $ = null;
1855
- function _(c) {
1856
- return (c == null ? void 0 : c.count) != null || (c == null ? void 0 : c.badge) != null;
1866
+ function b(d) {
1867
+ return (d == null ? void 0 : d.count) != null || (d == null ? void 0 : d.badge) != null;
1857
1868
  }
1858
- function N(c) {
1859
- return c.count != null ? c.count : c.badge;
1869
+ function x(d) {
1870
+ return d.count != null ? d.count : d.badge;
1860
1871
  }
1861
- function g(c, x) {
1862
- c && (o.value[x] = c);
1872
+ function M(d, k) {
1873
+ d && (o.value[k] = d);
1863
1874
  }
1864
- function p() {
1865
- const c = s.value;
1866
- if (!c) return;
1867
- const x = n.options.findIndex((B) => B.value === n.modelValue), L = o.value[x];
1875
+ function u() {
1876
+ const d = s.value;
1877
+ if (!d) return;
1878
+ const k = n.options.findIndex((R) => R.value === n.modelValue), L = o.value[k];
1868
1879
  if (!L) {
1869
1880
  h.value = { width: "0px", transform: "translateX(0px)" };
1870
1881
  return;
1871
1882
  }
1872
- const y = c.getBoundingClientRect(), R = L.getBoundingClientRect();
1883
+ const g = d.getBoundingClientRect(), B = L.getBoundingClientRect();
1873
1884
  h.value = {
1874
- width: `${R.width}px`,
1875
- transform: `translateX(${R.left - y.left}px)`
1885
+ width: `${B.width}px`,
1886
+ transform: `translateX(${B.left - g.left}px)`
1876
1887
  }, m.value = !0;
1877
1888
  }
1878
- function d(c) {
1879
- c.disabled || (r("update:modelValue", c.value), r("change", c.value));
1889
+ function c(d) {
1890
+ d.disabled || (r("update:modelValue", d.value), r("change", d.value));
1880
1891
  }
1881
1892
  return se(
1882
1893
  () => [n.modelValue, n.options],
1883
1894
  async () => {
1884
- await Z(), p();
1895
+ await Z(), u();
1885
1896
  },
1886
1897
  { deep: !0 }
1887
1898
  ), ve(async () => {
1888
- await Z(), p(), typeof ResizeObserver < "u" && s.value && ($ = new ResizeObserver(() => p()), $.observe(s.value));
1889
- }), ze(() => {
1899
+ await Z(), u(), typeof ResizeObserver < "u" && s.value && ($ = new ResizeObserver(() => u()), $.observe(s.value));
1900
+ }), He(() => {
1890
1901
  $ == null || $.disconnect(), $ = null;
1891
- }), (c, x) => (u(), b("div", {
1902
+ }), (d, k) => (p(), v("div", {
1892
1903
  ref_key: "rootRef",
1893
1904
  ref: s,
1894
1905
  class: "segmented",
1895
1906
  role: "radiogroup"
1896
1907
  }, [
1897
- w("div", {
1898
- class: z(["segmented__thumb", { "is-ready": m.value }]),
1908
+ _("div", {
1909
+ class: H(["segmented__thumb", { "is-ready": m.value }]),
1899
1910
  style: re(h.value)
1900
1911
  }, null, 6),
1901
- (u(!0), b(W, null, q(e.options, (L, y) => (u(), b("button", {
1912
+ (p(!0), v(W, null, q(e.options, (L, g) => (p(), v("button", {
1902
1913
  key: String(L.value),
1903
1914
  ref_for: !0,
1904
- ref: (R) => g(R, y),
1915
+ ref: (B) => M(B, g),
1905
1916
  type: "button",
1906
- class: z(["segmented__item", { "is-active": e.modelValue === L.value }]),
1917
+ class: H(["segmented__item", { "is-active": e.modelValue === L.value }]),
1907
1918
  role: "radio",
1908
1919
  "aria-checked": e.modelValue === L.value,
1909
1920
  disabled: L.disabled,
1910
- onClick: (R) => d(L)
1921
+ onClick: (B) => c(L)
1911
1922
  }, [
1912
- w("span", Kn, T(L.label), 1),
1913
- _(L) ? (u(), b("span", En, T(N(L)), 1)) : D("", !0)
1914
- ], 10, jn))), 128))
1923
+ _("span", Wn, T(L.label), 1),
1924
+ b(L) ? (p(), v("span", Yn, T(x(L)), 1)) : D("", !0)
1925
+ ], 10, Kn))), 128))
1915
1926
  ], 512));
1916
1927
  }
1917
- }, Yn = /* @__PURE__ */ G(Wn, [["__scopeId", "data-v-b7b0abe9"]]);
1918
- function qn(e) {
1928
+ }, Gn = /* @__PURE__ */ G(qn, [["__scopeId", "data-v-b7b0abe9"]]);
1929
+ function Xn(e) {
1919
1930
  return e == null || e === "" ? [] : Array.isArray(e) ? e.map((t) => String(t).trim()).filter(Boolean) : String(e).split(",").map((t) => t.trim()).filter(Boolean);
1920
1931
  }
1921
- function Gn(e) {
1932
+ function Jn(e) {
1922
1933
  if (!e.parentNode) {
1923
1934
  e.style.display = "none";
1924
1935
  return;
@@ -1930,12 +1941,12 @@ function Gn(e) {
1930
1941
  e.parentNode.removeChild(e);
1931
1942
  }
1932
1943
  function ge(e, t, n, r = !1) {
1933
- const s = qn(t.value);
1944
+ const s = Xn(t.value);
1934
1945
  if (!s.length) return;
1935
1946
  let o = Ae(s, n);
1936
- r && (o = !o), o || Gn(e);
1947
+ r && (o = !o), o || Jn(e);
1937
1948
  }
1938
- function Xn(e) {
1949
+ function Qn(e) {
1939
1950
  e.directive("hasPermission", {
1940
1951
  mounted(t, n) {
1941
1952
  ge(t, n, "and");
@@ -1950,54 +1961,59 @@ function Xn(e) {
1950
1961
  }
1951
1962
  });
1952
1963
  }
1953
- const Jn = {
1954
- MgImageUpload: Jt,
1955
- MgFileUpload: mn,
1956
- MgSearchForm: xn,
1957
- MgDataTable: Hn,
1964
+ const Zn = {
1965
+ MgImageUpload: Zt,
1966
+ MgFileUpload: yn,
1967
+ MgFilePreview: _t,
1968
+ MgSearchForm: Fn,
1969
+ MgDataTable: jn,
1958
1970
  MgDateRangePicker: Ge,
1959
- MgSegmentedControl: Yn,
1971
+ MgSegmentedControl: Gn,
1960
1972
  MgOverflowHid: Xe
1961
- }, Qn = (e, t = {}) => {
1962
- Object.entries(Jn).forEach(([s, o]) => {
1973
+ }, el = (e, t = {}) => {
1974
+ Object.entries(Zn).forEach(([s, o]) => {
1963
1975
  e.component(o.name || s, o);
1964
- }), t.ossUrl && St(t.ossUrl), typeof t.getPermissions == "function" && bt(t.getPermissions), Xn(e);
1965
- const n = _t(t), r = wt(n);
1966
- Ct(n), kt(r), e.config.globalProperties.$request = n, e.config.globalProperties.$api = r, e.config.globalProperties.$hasPermission = Ae;
1967
- }, sl = {
1968
- install: Qn,
1969
- version: "1.0.5"
1976
+ }), t.ossUrl && $t(t.ossUrl), typeof t.getPermissions == "function" && wt(t.getPermissions), Qn(e);
1977
+ const n = Ct(t), r = kt(n);
1978
+ Ut(n), xt(r), e.config.globalProperties.$request = n, e.config.globalProperties.$api = r, e.config.globalProperties.$hasPermission = Ae;
1979
+ }, rl = {
1980
+ install: el,
1981
+ version: "1.2.2"
1970
1982
  };
1971
1983
  export {
1972
- Hn as DataTable,
1984
+ jn as DataTable,
1973
1985
  Ge as DateRangePicker,
1974
- mn as FileUpload,
1975
- Jt as ImageUpload,
1976
- xn as SearchForm,
1977
- Yn as SegmentedControl,
1986
+ ul as FILE_PREVIEW_ROUTE_PATH,
1987
+ _t as FilePreview,
1988
+ yn as FileUpload,
1989
+ Zt as ImageUpload,
1990
+ Fn as SearchForm,
1991
+ Gn as SegmentedControl,
1978
1992
  Xe as TableOverflowHid,
1979
1993
  Ye as aliOssMixin,
1980
- ol as checkPermission,
1981
- wt as createApi,
1994
+ cl as buildFilePreviewHref,
1995
+ dl as checkPermission,
1996
+ kt as createApi,
1982
1997
  _e as createOssClient,
1983
- _t as createRequest,
1984
- il as createService,
1985
- sl as default,
1998
+ Ct as createRequest,
1999
+ pl as createService,
2000
+ rl as default,
1986
2001
  gt as getApi,
1987
- Ee as getOssSts,
1988
- ul as getPermissionGetter,
1989
- cl as getRequest,
1990
- dl as getSystemId,
1991
- pl as getUserId,
2002
+ Ke as getOssSts,
2003
+ fl as getPermissionGetter,
2004
+ hl as getRequest,
2005
+ ml as getSystemId,
2006
+ gl as getUserId,
1992
2007
  Ae as hasPermission,
1993
- Qn as install,
1994
- Xn as installPermissionDirectives,
1995
- kt as setApi,
1996
- St as setDefaultOssUrl,
1997
- bt as setPermissionGetter,
1998
- Ct as setRequest,
1999
- fl as setSystemId,
2000
- hl as setUserId,
2008
+ el as install,
2009
+ Qn as installPermissionDirectives,
2010
+ yt as openFilePreview,
2011
+ xt as setApi,
2012
+ $t as setDefaultOssUrl,
2013
+ wt as setPermissionGetter,
2014
+ Ut as setRequest,
2015
+ yl as setSystemId,
2016
+ vl as setUserId,
2001
2017
  We as uploadToOss,
2002
- ml as utils
2018
+ bl as utils
2003
2019
  };