@das-fed/ui 7.0.7-hot.20 → 7.0.7-hot.22

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.
Files changed (100) hide show
  1. package/package.json +5 -5
  2. package/packages/business-components/ai-panel/{index-8yffh0Id.js → index-DMJXZM7n.js} +1067 -1056
  3. package/packages/business-components/ai-panel/index-DMJXZM7n.js.gz +0 -0
  4. package/packages/business-components/ai-panel/{index-IzGl26KU.js → index-MqhMkLo9.js} +9 -9
  5. package/packages/business-components/ai-panel/index-MqhMkLo9.js.gz +0 -0
  6. package/packages/business-components/ai-panel/{index-OwRrV6K8.js → index-_q72oKSF.js} +63 -62
  7. package/packages/business-components/ai-panel/index-_q72oKSF.js.gz +0 -0
  8. package/packages/business-components/ai-panel/index.js +1 -1
  9. package/packages/business-components/device-panel/index.js +14908 -14808
  10. package/packages/business-components/device-panel/index.js.gz +0 -0
  11. package/packages/business-components/echarts/index.js +2056 -2049
  12. package/packages/business-components/echarts/index.js.gz +0 -0
  13. package/packages/business-components/process-configuration/index.js +46 -46
  14. package/packages/business-components/process-configuration/index.js.gz +0 -0
  15. package/packages/business-components/process-form/index.js +675 -655
  16. package/packages/business-components/process-form/index.js.gz +0 -0
  17. package/packages/business-components/process-form/src/utils/common-methods.d.ts +6 -0
  18. package/packages/business-components/process-search-form/index.js +77 -77
  19. package/packages/business-components/process-search-form/index.js.gz +0 -0
  20. package/packages/business-components/process-table/index.js +215 -213
  21. package/packages/business-components/process-table/index.js.gz +0 -0
  22. package/packages/business-components/urgent-panel/index.js +1104 -1096
  23. package/packages/business-components/urgent-panel/index.js.gz +0 -0
  24. package/packages/business-components/user-org-dialog/index.js +243 -240
  25. package/packages/business-components/user-org-dialog/index.js.gz +0 -0
  26. package/packages/business-components/video-dialog/index.js +65 -64
  27. package/packages/business-components/video-dialog/index.js.gz +0 -0
  28. package/packages/components/autocomplete/index.js +12 -6
  29. package/packages/components/autocomplete/index.js.gz +0 -0
  30. package/packages/components/calendar/index.js +99 -99
  31. package/packages/components/calendar/index.js.gz +0 -0
  32. package/packages/components/cascader/index.js +2 -2
  33. package/packages/components/cascader/index.js.gz +0 -0
  34. package/packages/components/checkbox/index.js +30 -30
  35. package/packages/components/checkbox/index.js.gz +0 -0
  36. package/packages/components/date-picker/index.js +212 -212
  37. package/packages/components/date-picker/index.js.gz +0 -0
  38. package/packages/components/dimple-layout/index.js +77 -75
  39. package/packages/components/dimple-layout/index.js.gz +0 -0
  40. package/packages/components/dropdown/index.js +25 -24
  41. package/packages/components/dropdown/index.js.gz +0 -0
  42. package/packages/components/edit-table/index.js +398 -397
  43. package/packages/components/edit-table/index.js.gz +0 -0
  44. package/packages/components/error-overlay-model/index.js +47 -45
  45. package/packages/components/error-overlay-model/index.js.gz +0 -0
  46. package/packages/components/form-item/index.js +67 -67
  47. package/packages/components/form-item/index.js.gz +0 -0
  48. package/packages/components/hls-player/index.js +14 -7
  49. package/packages/components/hls-player/index.js.gz +0 -0
  50. package/packages/components/image-upload/index.js +147 -143
  51. package/packages/components/image-upload/index.js.gz +0 -0
  52. package/packages/components/image-viewer/index.js +297 -293
  53. package/packages/components/image-viewer/index.js.gz +0 -0
  54. package/packages/components/input/index.js +52 -52
  55. package/packages/components/input/index.js.gz +0 -0
  56. package/packages/components/input-number/index.js +26 -26
  57. package/packages/components/input-number/index.js.gz +0 -0
  58. package/packages/components/live-player/index.js +251 -248
  59. package/packages/components/live-player/index.js.gz +0 -0
  60. package/packages/components/map/index.js +421 -415
  61. package/packages/components/map/index.js.gz +0 -0
  62. package/packages/components/menu-aside/index.js +1 -1
  63. package/packages/components/menu-aside/index.js.gz +0 -0
  64. package/packages/components/message/index.js +6 -6
  65. package/packages/components/message/index.js.gz +0 -0
  66. package/packages/components/popover/index.js +12 -12
  67. package/packages/components/popover/index.js.gz +0 -0
  68. package/packages/components/radio-tabs/index.js +34 -34
  69. package/packages/components/radio-tabs/index.js.gz +0 -0
  70. package/packages/components/rich-editor/index.js +4613 -4583
  71. package/packages/components/rich-editor/index.js.gz +0 -0
  72. package/packages/components/scrollbar/index.js +135 -135
  73. package/packages/components/scrollbar/index.js.gz +0 -0
  74. package/packages/components/search/index.js +24 -24
  75. package/packages/components/search/index.js.gz +0 -0
  76. package/packages/components/select/index.js +60 -60
  77. package/packages/components/select/index.js.gz +0 -0
  78. package/packages/components/select-list/index.js +9 -5
  79. package/packages/components/select-list/index.js.gz +0 -0
  80. package/packages/components/special-range-picker-month/index.js +16 -14
  81. package/packages/components/special-range-picker-month/index.js.gz +0 -0
  82. package/packages/components/special-range-picker-year/index.js +53 -51
  83. package/packages/components/special-range-picker-year/index.js.gz +0 -0
  84. package/packages/components/spin/index.js +33 -33
  85. package/packages/components/spin/index.js.gz +0 -0
  86. package/packages/components/split-panel/index.js +129 -128
  87. package/packages/components/split-panel/index.js.gz +0 -0
  88. package/packages/components/table/index.js +179 -178
  89. package/packages/components/table/index.js.gz +0 -0
  90. package/packages/components/time-line/index.js +1 -1
  91. package/packages/components/time-line/index.js.gz +0 -0
  92. package/packages/components/tree-select/index.js +1 -1
  93. package/packages/components/tree-select/index.js.gz +0 -0
  94. package/packages/components/tree-table/index.js +2 -2
  95. package/packages/components/tree-table/index.js.gz +0 -0
  96. package/packages/components/tree-v2/index.js +1117 -1093
  97. package/packages/components/tree-v2/index.js.gz +0 -0
  98. package/packages/business-components/ai-panel/index-8yffh0Id.js.gz +0 -0
  99. package/packages/business-components/ai-panel/index-IzGl26KU.js.gz +0 -0
  100. package/packages/business-components/ai-panel/index-OwRrV6K8.js.gz +0 -0
@@ -1,9 +1,9 @@
1
1
  import '@das-fed/ui/packages/components/image-viewer/style.css';
2
2
  import { withInstall as rt } from "@das-fed/utils/with-install/index";
3
3
  import { setThemeRule as ot } from "@das-fed/web/packages/theme/index";
4
- import { ref as Ee, computed as x, watch as st, createApp as lt, defineComponent as ut, createElementBlock as U, openBlock as y, Fragment as de, createCommentVNode as p, createElementVNode as X, withDirectives as J, normalizeStyle as fe, createVNode as ie, unref as n, normalizeClass as ge, withCtx as ne, createBlock as O, vShow as j, isRef as Qe, createTextVNode as Pe, toDisplayString as Te, renderList as Me } from "vue";
5
- import { ElImageViewer as ct, ElImage as Le } from "element-plus";
6
- import { Upload as Fe } from "ant-design-vue";
4
+ import { ref as Ee, computed as x, watch as st, createApp as lt, defineComponent as ut, createElementBlock as U, openBlock as y, Fragment as de, createCommentVNode as p, createElementVNode as X, withDirectives as j, normalizeStyle as fe, createVNode as ae, unref as n, normalizeClass as ge, withCtx as ne, createBlock as O, vShow as z, isRef as Qe, createTextVNode as Pe, toDisplayString as Me, renderList as Te } from "vue";
5
+ import { ElImageViewer as ct, ElImage as Fe } from "element-plus";
6
+ import { Upload as Le } from "ant-design-vue";
7
7
  import { vDasTooltip as Ne } from "@das-fed/ui/packages/components/text-tooltip/index";
8
8
  import { DasImageUpload as Ve } from "@das-fed/ui/packages/components/image-upload/index";
9
9
  import { DasSpin as Je } from "@das-fed/ui/packages/components/spin/index";
@@ -25,38 +25,38 @@ import "element-plus/es/components/image/style/css";
25
25
  import "element-plus/es/components/image-viewer/style/css";
26
26
  import "@das-fed/ui/packages/global/theme";
27
27
  const Ie = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAYAAACtWK6eAAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAAAyKADAAQAAAABAAAAyAAAAACbWz2VAAAPbUlEQVR4Ae1dDXfiKhDV1o92T3f//9/ctVWjUR+XLe9hnvKRkMCQO+fYJIYg3OGWmYHA8nq93tRnQSECROAegZeXl8Xqdrst8KEQASJwjwB48XL/Fa+IABGwESBBbDR4TgQ6CJAgHUB4SQRsBEgQGw2eE4EOAiRIBxBeEgEbARLERoPnRKCDAAnSAYSXRMBGgASx0eA5EeggQIJ0AOElEbARIEFsNHhOBDoIkCAdQHhJBGwESBAbDZ4TgQ4CJEgHEF4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FauV27yCY87FGHqCW9BjJEhPZei5V45n2+/drRxJeEsAAiRIDyW9Yncqn3mlFsCmyEeABOmhw7XPvFJrZnG1kh7AFvgICdJDKT7zis55D1ALfYQEiVRMiHlF/yMS1IKTkyCRysHUdpdgjw+aVy6EZN0jQSL15Z252/7dmz0yWyYvFAESJEIx2NzTN/eqJUEiEC0/KQkSoaPXlfu9D6wYBxOLUg8CJEiELlce/4O9RwSYQpKSIBGKWnl6EEavIsAUkpQECVTUcqmg8izrc7nQQQ+EU0wyEiRQVXr8w5EWS4ryvXMHQEJvkSCBivP5H5y5GwiksGQkSKDCXlbuda8uLaNXgVCKSkaCBKrLN/7BHiQQSGHJSJAAhfmml+jxD/WCFKU+BEiQAJ1i9RKXtJfWdZv3BCNAggQo79VDkCsJEoCizCQkSIDefP4Hp5cEgCg0CQkSoDifiXXh/KsAFGUmIUE8etMj6J40fP/DA5Dg2ySIR3l+/4PRKw+Eom+TIB71+cwrLkztAVD4bRLEo8CXFzdE9D88AAq/7da+8MqlKP7SQxBMUqTUiwAJ4tHtC6a5O4QzeB3gVHDLrf0KKji0Cr4ehHOwhiJc9vMkiEs/apEGp6h30Cl1I0CCOPTrDfHeGOJ1wFfFLRLEocalZ4Xq25VdiAO+Km4tm6a5MVT5WJcYA3Et1ADcLlwH6zF4FXy7Vtt7/wME4YHuqneMGQAAAABJRU5ErkJggg==", gt = (t, e) => {
28
- const i = new Image();
29
- i.setAttribute("crossOrigin", "Anonymous"), i.onload = function() {
30
- let a = document.createElement("canvas");
31
- const r = a.getContext("2d");
32
- a.width = i.width, a.height = i.height, r.drawImage(i, 0, 0, i.width, i.height), a.toBlob((o) => {
28
+ const a = new Image();
29
+ a.setAttribute("crossOrigin", "Anonymous"), a.onload = function() {
30
+ let i = document.createElement("canvas");
31
+ const r = i.getContext("2d");
32
+ i.width = a.width, i.height = a.height, r.drawImage(a, 0, 0, a.width, a.height), i.toBlob((o) => {
33
33
  let g = URL.createObjectURL(o), s = document.createElement("a"), f = new MouseEvent("click");
34
34
  const c = t.substring(t.lastIndexOf(".")).toLowerCase();
35
35
  s.download = e || `default${c}`, s.href = g, s.dispatchEvent(f), URL.revokeObjectURL(g);
36
36
  });
37
- }, i.src = t + "?v=" + Date.now();
37
+ }, a.src = t + "?v=" + Date.now();
38
38
  }, vt = (t, e) => {
39
- t && fetch(t).then((i) => i.blob()).then((i) => {
40
- const a = document.createElement("a");
41
- document.body.appendChild(a), a.style.display = "none";
42
- const r = window.URL.createObjectURL(i);
43
- a.href = r, a.download = e, a.click(), document.body.removeChild(a), window.URL.revokeObjectURL(r);
39
+ t && fetch(t).then((a) => a.blob()).then((a) => {
40
+ const i = document.createElement("a");
41
+ document.body.appendChild(i), i.style.display = "none";
42
+ const r = window.URL.createObjectURL(a);
43
+ i.href = r, i.download = e, i.click(), document.body.removeChild(i), window.URL.revokeObjectURL(r);
44
44
  });
45
45
  }, pt = (t) => {
46
46
  const e = (t == null ? void 0 : t.minioTokenApi) ?? "token";
47
- return et.get(e, (i) => (i.headers || (i.headers = {}), t != null && t.baseUrl && (i.baseURL = t.baseUrl), i));
47
+ return et.get(e, (a) => (a.headers || (a.headers = {}), t != null && t.baseUrl && (a.baseURL = t.baseUrl), a));
48
48
  }, ht = (t) => et.post("put-object", (e) => (e.headers || (e.headers = {}), t && (e.baseURL = t), e.headers["Content-Type"] = "multipart/form-data", e)), wt = () => {
49
49
  const t = ft();
50
50
  return t ? t.tenantId : "";
51
51
  }, At = (t) => {
52
- const { baseUrl: e, serviceName: i, pathPrefix: a, bucketName: r, minioTokenApi: o, autoContentType: g } = t, s = async () => {
52
+ const { baseUrl: e, serviceName: a, pathPrefix: i, bucketName: r, minioTokenApi: o, autoContentType: g } = t, s = async () => {
53
53
  const [v, d] = await pt({ baseUrl: e, minioTokenApi: o })().run();
54
54
  return v ? { stauts: !1 } : { status: !0, data: d };
55
55
  }, { generateUniqueName: f } = dt();
56
56
  return { upload: async (v, d = {}) => {
57
57
  const C = await s();
58
58
  if (!C.status) return;
59
- const h = v.name, m = C.data, E = a || wt(), k = h.substring(h.lastIndexOf(".")).toLowerCase(), S = t.randomName ? `${f("")}${k}` : h, K = i ? `${E}/${i}/${S}` : `${E}/${S}`, T = {
59
+ const h = v.name, m = C.data, E = i || wt(), k = h.substring(h.lastIndexOf(".")).toLowerCase(), S = t.randomName ? `${f("")}${k}` : h, K = a ? `${E}/${a}/${S}` : `${E}/${S}`, M = {
60
60
  accessKeyId: m.accessKeyId,
61
61
  secretAccessKey: m.secretAccessKey,
62
62
  sessionToken: m.sessionToken,
@@ -66,32 +66,32 @@ const Ie = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAYAAACtWK6eAA
66
66
  isThumbnail: !0,
67
67
  autoContentType: g === !0 ? !0 : void 0,
68
68
  ...d
69
- }, [M, L] = await ht(e)(T).run();
70
- return M ? "error" : L.value;
69
+ }, [T, F] = await ht(e)(M).run();
70
+ return T ? "error" : F.value;
71
71
  } };
72
72
  }, yt = () => ({ size2B: (e) => {
73
73
  isNaN(Number(e)) ? e = e.toString() : e = e + "M";
74
- const i = Number(e.slice(0, -1)), a = e[e.length - 1].toUpperCase(), r = 1024, o = {
74
+ const a = Number(e.slice(0, -1)), i = e[e.length - 1].toUpperCase(), r = 1024, o = {
75
75
  M: r * r,
76
76
  K: r,
77
77
  B: 1
78
78
  };
79
- return { finalSize: i * o[a], sizeText: e };
80
- } }), Ct = (t) => ({ handlerImageSrc: (i, a) => {
81
- if (a.startsWith("http")) return a;
82
- const r = t.useOriginUrl ? a : Re(a);
83
- return i + r;
79
+ return { finalSize: a * o[i], sizeText: e };
80
+ } }), Ct = (t) => ({ handlerImageSrc: (a, i) => {
81
+ if (i.startsWith("http")) return i;
82
+ const r = t.useOriginUrl ? i : Re(i);
83
+ return a + r;
84
84
  } }), Et = async (t) => {
85
- const i = De().baseURL + Re(t);
86
- return await _e(i);
85
+ const a = De().baseURL + Re(t);
86
+ return await _e(a);
87
87
  }, bt = async (t) => {
88
88
  const e = De();
89
- let i = [];
90
- for (const a of t) {
91
- const r = e.baseURL + Re(a), o = await _e(r);
92
- i.push(o);
89
+ let a = [];
90
+ for (const i of t) {
91
+ const r = e.baseURL + Re(i), o = await _e(r);
92
+ a.push(o);
93
93
  }
94
- return i;
94
+ return a;
95
95
  };
96
96
  /*!
97
97
  * Compressor.js v1.2.1
@@ -103,22 +103,22 @@ const Ie = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAYAAACtWK6eAA
103
103
  * Date: 2023-02-28T14:09:41.732Z
104
104
  */
105
105
  function We(t, e) {
106
- var i = Object.keys(t);
106
+ var a = Object.keys(t);
107
107
  if (Object.getOwnPropertySymbols) {
108
- var a = Object.getOwnPropertySymbols(t);
109
- e && (a = a.filter(function(r) {
108
+ var i = Object.getOwnPropertySymbols(t);
109
+ e && (i = i.filter(function(r) {
110
110
  return Object.getOwnPropertyDescriptor(t, r).enumerable;
111
- })), i.push.apply(i, a);
111
+ })), a.push.apply(a, i);
112
112
  }
113
- return i;
113
+ return a;
114
114
  }
115
115
  function he(t) {
116
116
  for (var e = 1; e < arguments.length; e++) {
117
- var i = arguments[e] != null ? arguments[e] : {};
118
- e % 2 ? We(Object(i), !0).forEach(function(a) {
119
- kt(t, a, i[a]);
120
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(t, Object.getOwnPropertyDescriptors(i)) : We(Object(i)).forEach(function(a) {
121
- Object.defineProperty(t, a, Object.getOwnPropertyDescriptor(i, a));
117
+ var a = arguments[e] != null ? arguments[e] : {};
118
+ e % 2 ? We(Object(a), !0).forEach(function(i) {
119
+ kt(t, i, a[i]);
120
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(t, Object.getOwnPropertyDescriptors(a)) : We(Object(a)).forEach(function(i) {
121
+ Object.defineProperty(t, i, Object.getOwnPropertyDescriptor(a, i));
122
122
  });
123
123
  }
124
124
  return t;
@@ -128,40 +128,40 @@ function Bt(t, e) {
128
128
  throw new TypeError("Cannot call a class as a function");
129
129
  }
130
130
  function Ye(t, e) {
131
- for (var i = 0; i < e.length; i++) {
132
- var a = e[i];
133
- a.enumerable = a.enumerable || !1, a.configurable = !0, "value" in a && (a.writable = !0), Object.defineProperty(t, tt(a.key), a);
131
+ for (var a = 0; a < e.length; a++) {
132
+ var i = e[a];
133
+ i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(t, tt(i.key), i);
134
134
  }
135
135
  }
136
- function It(t, e, i) {
137
- return e && Ye(t.prototype, e), i && Ye(t, i), Object.defineProperty(t, "prototype", {
136
+ function It(t, e, a) {
137
+ return e && Ye(t.prototype, e), a && Ye(t, a), Object.defineProperty(t, "prototype", {
138
138
  writable: !1
139
139
  }), t;
140
140
  }
141
- function kt(t, e, i) {
141
+ function kt(t, e, a) {
142
142
  return e = tt(e), e in t ? Object.defineProperty(t, e, {
143
- value: i,
143
+ value: a,
144
144
  enumerable: !0,
145
145
  configurable: !0,
146
146
  writable: !0
147
- }) : t[e] = i, t;
147
+ }) : t[e] = a, t;
148
148
  }
149
149
  function Ae() {
150
150
  return Ae = Object.assign ? Object.assign.bind() : function(t) {
151
151
  for (var e = 1; e < arguments.length; e++) {
152
- var i = arguments[e];
153
- for (var a in i)
154
- Object.prototype.hasOwnProperty.call(i, a) && (t[a] = i[a]);
152
+ var a = arguments[e];
153
+ for (var i in a)
154
+ Object.prototype.hasOwnProperty.call(a, i) && (t[i] = a[i]);
155
155
  }
156
156
  return t;
157
157
  }, Ae.apply(this, arguments);
158
158
  }
159
159
  function Dt(t, e) {
160
160
  if (typeof t != "object" || t === null) return t;
161
- var i = t[Symbol.toPrimitive];
162
- if (i !== void 0) {
163
- var a = i.call(t, e);
164
- if (typeof a != "object") return a;
161
+ var a = t[Symbol.toPrimitive];
162
+ if (a !== void 0) {
163
+ var i = a.call(t, e);
164
+ if (typeof i != "object") return i;
165
165
  throw new TypeError("@@toPrimitive must return a primitive value.");
166
166
  }
167
167
  return String(t);
@@ -170,50 +170,50 @@ function tt(t) {
170
170
  var e = Dt(t, "string");
171
171
  return typeof e == "symbol" ? e : String(e);
172
172
  }
173
- var at = { exports: {} };
173
+ var it = { exports: {} };
174
174
  (function(t) {
175
175
  typeof window > "u" || function(e) {
176
- var i = e.HTMLCanvasElement && e.HTMLCanvasElement.prototype, a = e.Blob && function() {
176
+ var a = e.HTMLCanvasElement && e.HTMLCanvasElement.prototype, i = e.Blob && function() {
177
177
  try {
178
178
  return !!new Blob();
179
179
  } catch {
180
180
  return !1;
181
181
  }
182
- }(), r = a && e.Uint8Array && function() {
182
+ }(), r = i && e.Uint8Array && function() {
183
183
  try {
184
184
  return new Blob([new Uint8Array(100)]).size === 100;
185
185
  } catch {
186
186
  return !1;
187
187
  }
188
- }(), o = e.BlobBuilder || e.WebKitBlobBuilder || e.MozBlobBuilder || e.MSBlobBuilder, g = /^data:((.*?)(;charset=.*?)?)(;base64)?,/, s = (a || o) && e.atob && e.ArrayBuffer && e.Uint8Array && function(f) {
188
+ }(), o = e.BlobBuilder || e.WebKitBlobBuilder || e.MozBlobBuilder || e.MSBlobBuilder, g = /^data:((.*?)(;charset=.*?)?)(;base64)?,/, s = (i || o) && e.atob && e.ArrayBuffer && e.Uint8Array && function(f) {
189
189
  var c, v, d, C, h, m, E, k, S;
190
190
  if (c = f.match(g), !c)
191
191
  throw new Error("invalid data URI");
192
192
  for (v = c[2] ? c[1] : "text/plain" + (c[3] || ";charset=US-ASCII"), d = !!c[4], C = f.slice(c[0].length), d ? h = atob(C) : h = decodeURIComponent(C), m = new ArrayBuffer(h.length), E = new Uint8Array(m), k = 0; k < h.length; k += 1)
193
193
  E[k] = h.charCodeAt(k);
194
- return a ? new Blob([r ? E : m], {
194
+ return i ? new Blob([r ? E : m], {
195
195
  type: v
196
196
  }) : (S = new o(), S.append(m), S.getBlob(v));
197
197
  };
198
- e.HTMLCanvasElement && !i.toBlob && (i.mozGetAsFile ? i.toBlob = function(f, c, v) {
198
+ e.HTMLCanvasElement && !a.toBlob && (a.mozGetAsFile ? a.toBlob = function(f, c, v) {
199
199
  var d = this;
200
200
  setTimeout(function() {
201
- v && i.toDataURL && s ? f(s(d.toDataURL(c, v))) : f(d.mozGetAsFile("blob", c));
201
+ v && a.toDataURL && s ? f(s(d.toDataURL(c, v))) : f(d.mozGetAsFile("blob", c));
202
202
  });
203
- } : i.toDataURL && s && (i.msToBlob ? i.toBlob = function(f, c, v) {
203
+ } : a.toDataURL && s && (a.msToBlob ? a.toBlob = function(f, c, v) {
204
204
  var d = this;
205
205
  setTimeout(function() {
206
- (c && c !== "image/png" || v) && i.toDataURL && s ? f(s(d.toDataURL(c, v))) : f(d.msToBlob(c));
206
+ (c && c !== "image/png" || v) && a.toDataURL && s ? f(s(d.toDataURL(c, v))) : f(d.msToBlob(c));
207
207
  });
208
- } : i.toBlob = function(f, c, v) {
208
+ } : a.toBlob = function(f, c, v) {
209
209
  var d = this;
210
210
  setTimeout(function() {
211
211
  f(s(d.toDataURL(c, v)));
212
212
  });
213
213
  })), t.exports ? t.exports = s : e.dataURLtoBlob = s;
214
214
  }(window);
215
- })(at);
216
- var Ge = at.exports, Rt = function(e) {
215
+ })(it);
216
+ var Ge = it.exports, Rt = function(e) {
217
217
  return typeof Blob > "u" ? !1 : e instanceof Blob || Object.prototype.toString.call(e) === "[object Blob]";
218
218
  }, Xe = {
219
219
  /**
@@ -353,23 +353,23 @@ function Qt(t) {
353
353
  var e = ke(t) ? t.substr(6) : "";
354
354
  return e === "jpeg" && (e = "jpg"), ".".concat(e);
355
355
  }
356
- var it = String.fromCharCode;
357
- function Pt(t, e, i) {
358
- var a = "", r;
359
- for (i += e, r = e; r < i; r += 1)
360
- a += it(t.getUint8(r));
361
- return a;
356
+ var at = String.fromCharCode;
357
+ function Pt(t, e, a) {
358
+ var i = "", r;
359
+ for (a += e, r = e; r < a; r += 1)
360
+ i += at(t.getUint8(r));
361
+ return i;
362
362
  }
363
- var Tt = q.btoa;
363
+ var Mt = q.btoa;
364
364
  function qe(t, e) {
365
- for (var i = [], a = 8192, r = new Uint8Array(t); r.length > 0; )
366
- i.push(it.apply(null, Se(r.subarray(0, a)))), r = r.subarray(a);
367
- return "data:".concat(e, ";base64,").concat(Tt(i.join("")));
365
+ for (var a = [], i = 8192, r = new Uint8Array(t); r.length > 0; )
366
+ a.push(at.apply(null, Se(r.subarray(0, i)))), r = r.subarray(i);
367
+ return "data:".concat(e, ";base64,").concat(Mt(a.join("")));
368
368
  }
369
- function Mt(t) {
370
- var e = new DataView(t), i;
369
+ function Tt(t) {
370
+ var e = new DataView(t), a;
371
371
  try {
372
- var a, r, o;
372
+ var i, r, o;
373
373
  if (e.getUint8(0) === 255 && e.getUint8(1) === 216)
374
374
  for (var g = e.byteLength, s = 2; s + 1 < g; ) {
375
375
  if (e.getUint8(s) === 255 && e.getUint8(s + 1) === 225) {
@@ -382,45 +382,45 @@ function Mt(t) {
382
382
  var f = r + 4, c = r + 10;
383
383
  if (Pt(e, f, 4) === "Exif") {
384
384
  var v = e.getUint16(c);
385
- if (a = v === 18761, (a || v === 19789) && e.getUint16(c + 2, a) === 42) {
386
- var d = e.getUint32(c + 4, a);
385
+ if (i = v === 18761, (i || v === 19789) && e.getUint16(c + 2, i) === 42) {
386
+ var d = e.getUint32(c + 4, i);
387
387
  d >= 8 && (o = c + d);
388
388
  }
389
389
  }
390
390
  }
391
391
  if (o) {
392
- var C = e.getUint16(o, a), h, m;
392
+ var C = e.getUint16(o, i), h, m;
393
393
  for (m = 0; m < C; m += 1)
394
- if (h = o + m * 12 + 2, e.getUint16(h, a) === 274) {
395
- h += 8, i = e.getUint16(h, a), e.setUint16(h, 1, a);
394
+ if (h = o + m * 12 + 2, e.getUint16(h, i) === 274) {
395
+ h += 8, a = e.getUint16(h, i), e.setUint16(h, 1, i);
396
396
  break;
397
397
  }
398
398
  }
399
399
  } catch {
400
- i = 1;
400
+ a = 1;
401
401
  }
402
- return i;
402
+ return a;
403
403
  }
404
- function Lt(t) {
405
- var e = 0, i = 1, a = 1;
404
+ function Ft(t) {
405
+ var e = 0, a = 1, i = 1;
406
406
  switch (t) {
407
407
  case 2:
408
- i = -1;
408
+ a = -1;
409
409
  break;
410
410
  case 3:
411
411
  e = -180;
412
412
  break;
413
413
  case 4:
414
- a = -1;
414
+ i = -1;
415
415
  break;
416
416
  case 5:
417
- e = 90, a = -1;
417
+ e = 90, i = -1;
418
418
  break;
419
419
  case 6:
420
420
  e = 90;
421
421
  break;
422
422
  case 7:
423
- e = 90, i = -1;
423
+ e = 90, a = -1;
424
424
  break;
425
425
  case 8:
426
426
  e = -90;
@@ -428,28 +428,28 @@ function Lt(t) {
428
428
  }
429
429
  return {
430
430
  rotate: e,
431
- scaleX: i,
432
- scaleY: a
431
+ scaleX: a,
432
+ scaleY: i
433
433
  };
434
434
  }
435
- var Ft = /\.\d*(?:0|9){12}\d*$/;
435
+ var Lt = /\.\d*(?:0|9){12}\d*$/;
436
436
  function Ze(t) {
437
437
  var e = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 1e11;
438
- return Ft.test(t) ? Math.round(t * e) / e : t;
438
+ return Lt.test(t) ? Math.round(t * e) / e : t;
439
439
  }
440
440
  function se(t) {
441
- var e = t.aspectRatio, i = t.height, a = t.width, r = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "none", o = ye(a), g = ye(i);
441
+ var e = t.aspectRatio, a = t.height, i = t.width, r = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "none", o = ye(i), g = ye(a);
442
442
  if (o && g) {
443
- var s = i * e;
444
- (r === "contain" || r === "none") && s > a || r === "cover" && s < a ? i = a / e : a = i * e;
445
- } else o ? i = a / e : g && (a = i * e);
443
+ var s = a * e;
444
+ (r === "contain" || r === "none") && s > i || r === "cover" && s < i ? a = i / e : i = a * e;
445
+ } else o ? a = i / e : g && (i = a * e);
446
446
  return {
447
- width: a,
448
- height: i
447
+ width: i,
448
+ height: a
449
449
  };
450
450
  }
451
451
  function Nt(t) {
452
- for (var e = Se(new Uint8Array(t)), i = e.length, a = [], r = 0; r + 3 < i; ) {
452
+ for (var e = Se(new Uint8Array(t)), a = e.length, i = [], r = 0; r + 3 < a; ) {
453
453
  var o = e[r], g = e[r + 1];
454
454
  if (o === 255 && g === 218)
455
455
  break;
@@ -457,33 +457,33 @@ function Nt(t) {
457
457
  r += 2;
458
458
  else {
459
459
  var s = e[r + 2] * 256 + e[r + 3], f = r + s + 2, c = e.slice(r, f);
460
- a.push(c), r = f;
460
+ i.push(c), r = f;
461
461
  }
462
462
  }
463
- return a.reduce(function(v, d) {
463
+ return i.reduce(function(v, d) {
464
464
  return d[0] === 255 && d[1] === 225 ? v.concat(d) : v;
465
465
  }, []);
466
466
  }
467
467
  function Vt(t, e) {
468
- var i = Se(new Uint8Array(t));
469
- if (i[2] !== 255 || i[3] !== 224)
468
+ var a = Se(new Uint8Array(t));
469
+ if (a[2] !== 255 || a[3] !== 224)
470
470
  return t;
471
- var a = i[4] * 256 + i[5], r = [255, 216].concat(e, i.slice(4 + a));
471
+ var i = a[4] * 256 + a[5], r = [255, 216].concat(e, a.slice(4 + i));
472
472
  return new Uint8Array(r);
473
473
  }
474
474
  var Jt = q.ArrayBuffer, Be = q.FileReader, te = q.URL || q.webkitURL, jt = /\.\w+$/, zt = q.Compressor, xt = /* @__PURE__ */ function() {
475
- function t(e, i) {
476
- Bt(this, t), this.file = e, this.exif = [], this.image = new Image(), this.options = he(he({}, Xe), i), this.aborted = !1, this.result = null, this.init();
475
+ function t(e, a) {
476
+ Bt(this, t), this.file = e, this.exif = [], this.image = new Image(), this.options = he(he({}, Xe), a), this.aborted = !1, this.result = null, this.init();
477
477
  }
478
478
  return It(t, [{
479
479
  key: "init",
480
480
  value: function() {
481
- var i = this, a = this.file, r = this.options;
482
- if (!Rt(a)) {
481
+ var a = this, i = this.file, r = this.options;
482
+ if (!Rt(i)) {
483
483
  this.fail(new Error("The first argument must be a File or Blob object."));
484
484
  return;
485
485
  }
486
- var o = a.type;
486
+ var o = i.type;
487
487
  if (!ke(o)) {
488
488
  this.fail(new Error("The first argument must be an image File or Blob object."));
489
489
  return;
@@ -496,71 +496,71 @@ var Jt = q.ArrayBuffer, Be = q.FileReader, te = q.URL || q.webkitURL, jt = /\.\w
496
496
  var g = o === "image/jpeg", s = g && r.checkOrientation, f = g && r.retainExif;
497
497
  if (te && !s && !f)
498
498
  this.load({
499
- url: te.createObjectURL(a)
499
+ url: te.createObjectURL(i)
500
500
  });
501
501
  else {
502
502
  var c = new Be();
503
503
  this.reader = c, c.onload = function(v) {
504
504
  var d = v.target, C = d.result, h = {}, m = 1;
505
- s && (m = Mt(C), m > 1 && Ae(h, Lt(m))), f && (i.exif = Nt(C)), s || f ? !te || m > 1 ? h.url = qe(C, o) : h.url = te.createObjectURL(a) : h.url = C, i.load(h);
505
+ s && (m = Tt(C), m > 1 && Ae(h, Ft(m))), f && (a.exif = Nt(C)), s || f ? !te || m > 1 ? h.url = qe(C, o) : h.url = te.createObjectURL(i) : h.url = C, a.load(h);
506
506
  }, c.onabort = function() {
507
- i.fail(new Error("Aborted to read the image with FileReader."));
507
+ a.fail(new Error("Aborted to read the image with FileReader."));
508
508
  }, c.onerror = function() {
509
- i.fail(new Error("Failed to read the image with FileReader."));
509
+ a.fail(new Error("Failed to read the image with FileReader."));
510
510
  }, c.onloadend = function() {
511
- i.reader = null;
512
- }, s || f ? c.readAsArrayBuffer(a) : c.readAsDataURL(a);
511
+ a.reader = null;
512
+ }, s || f ? c.readAsArrayBuffer(i) : c.readAsDataURL(i);
513
513
  }
514
514
  }
515
515
  }, {
516
516
  key: "load",
517
- value: function(i) {
518
- var a = this, r = this.file, o = this.image;
517
+ value: function(a) {
518
+ var i = this, r = this.file, o = this.image;
519
519
  o.onload = function() {
520
- a.draw(he(he({}, i), {}, {
520
+ i.draw(he(he({}, a), {}, {
521
521
  naturalWidth: o.naturalWidth,
522
522
  naturalHeight: o.naturalHeight
523
523
  }));
524
524
  }, o.onabort = function() {
525
- a.fail(new Error("Aborted to load the image."));
525
+ i.fail(new Error("Aborted to load the image."));
526
526
  }, o.onerror = function() {
527
- a.fail(new Error("Failed to load the image."));
528
- }, q.navigator && /(?:iPad|iPhone|iPod).*?AppleWebKit/i.test(q.navigator.userAgent) && (o.crossOrigin = "anonymous"), o.alt = r.name, o.src = i.url;
527
+ i.fail(new Error("Failed to load the image."));
528
+ }, q.navigator && /(?:iPad|iPhone|iPod).*?AppleWebKit/i.test(q.navigator.userAgent) && (o.crossOrigin = "anonymous"), o.alt = r.name, o.src = a.url;
529
529
  }
530
530
  }, {
531
531
  key: "draw",
532
- value: function(i) {
533
- var a = this, r = i.naturalWidth, o = i.naturalHeight, g = i.rotate, s = g === void 0 ? 0 : g, f = i.scaleX, c = f === void 0 ? 1 : f, v = i.scaleY, d = v === void 0 ? 1 : v, C = this.file, h = this.image, m = this.options, E = document.createElement("canvas"), k = E.getContext("2d"), S = Math.abs(s) % 180 === 90, K = (m.resize === "contain" || m.resize === "cover") && ye(m.width) && ye(m.height), T = Math.max(m.maxWidth, 0) || 1 / 0, M = Math.max(m.maxHeight, 0) || 1 / 0, L = Math.max(m.minWidth, 0) || 0, H = Math.max(m.minHeight, 0) || 0, z = r / o, b = m.width, B = m.height;
532
+ value: function(a) {
533
+ var i = this, r = a.naturalWidth, o = a.naturalHeight, g = a.rotate, s = g === void 0 ? 0 : g, f = a.scaleX, c = f === void 0 ? 1 : f, v = a.scaleY, d = v === void 0 ? 1 : v, C = this.file, h = this.image, m = this.options, E = document.createElement("canvas"), k = E.getContext("2d"), S = Math.abs(s) % 180 === 90, K = (m.resize === "contain" || m.resize === "cover") && ye(m.width) && ye(m.height), M = Math.max(m.maxWidth, 0) || 1 / 0, T = Math.max(m.maxHeight, 0) || 1 / 0, F = Math.max(m.minWidth, 0) || 0, H = Math.max(m.minHeight, 0) || 0, L = r / o, b = m.width, B = m.height;
534
534
  if (S) {
535
- var Z = [M, T];
536
- T = Z[0], M = Z[1];
537
- var $ = [H, L];
538
- L = $[0], H = $[1];
535
+ var Z = [T, M];
536
+ M = Z[0], T = Z[1];
537
+ var $ = [H, F];
538
+ F = $[0], H = $[1];
539
539
  var u = [B, b];
540
540
  b = u[0], B = u[1];
541
541
  }
542
- K && (z = b / B);
542
+ K && (L = b / B);
543
543
  var w = se({
544
- aspectRatio: z,
545
- width: T,
546
- height: M
544
+ aspectRatio: L,
545
+ width: M,
546
+ height: T
547
547
  }, "contain");
548
- T = w.width, M = w.height;
548
+ M = w.width, T = w.height;
549
549
  var I = se({
550
- aspectRatio: z,
551
- width: L,
550
+ aspectRatio: L,
551
+ width: F,
552
552
  height: H
553
553
  }, "cover");
554
- if (L = I.width, H = I.height, K) {
554
+ if (F = I.width, H = I.height, K) {
555
555
  var A = se({
556
- aspectRatio: z,
556
+ aspectRatio: L,
557
557
  width: b,
558
558
  height: B
559
559
  }, m.resize);
560
560
  b = A.width, B = A.height;
561
561
  } else {
562
562
  var _ = se({
563
- aspectRatio: z,
563
+ aspectRatio: L,
564
564
  width: b,
565
565
  height: B
566
566
  }), W = _.width;
@@ -568,11 +568,11 @@ var Jt = q.ArrayBuffer, Be = q.FileReader, te = q.URL || q.webkitURL, jt = /\.\w
568
568
  var l = _.height;
569
569
  B = l === void 0 ? o : l;
570
570
  }
571
- b = Math.floor(Ze(Math.min(Math.max(b, L), T))), B = Math.floor(Ze(Math.min(Math.max(B, H), M)));
572
- var D = -b / 2, F = -B / 2, ee = b, N = B, R = [];
571
+ b = Math.floor(Ze(Math.min(Math.max(b, F), M))), B = Math.floor(Ze(Math.min(Math.max(B, H), T)));
572
+ var D = -b / 2, N = -B / 2, ee = b, V = B, R = [];
573
573
  if (K) {
574
574
  var Q = 0, P = 0, G = r, Y = o, le = se({
575
- aspectRatio: z,
575
+ aspectRatio: L,
576
576
  width: r,
577
577
  height: o
578
578
  }, {
@@ -581,44 +581,44 @@ var Jt = q.ArrayBuffer, Be = q.FileReader, te = q.URL || q.webkitURL, jt = /\.\w
581
581
  }[m.resize]);
582
582
  G = le.width, Y = le.height, Q = (r - G) / 2, P = (o - Y) / 2, R.push(Q, P, G, Y);
583
583
  }
584
- if (R.push(D, F, ee, N), S) {
584
+ if (R.push(D, N, ee, V), S) {
585
585
  var ue = [B, b];
586
586
  b = ue[0], B = ue[1];
587
587
  }
588
588
  E.width = b, E.height = B, ke(m.mimeType) || (m.mimeType = C.type);
589
- var V = "transparent";
589
+ var J = "transparent";
590
590
  C.size > m.convertSize && m.convertTypes.indexOf(m.mimeType) >= 0 && (m.mimeType = "image/jpeg");
591
591
  var ce = m.mimeType === "image/jpeg";
592
- if (ce && (V = "#fff"), k.fillStyle = V, k.fillRect(0, 0, b, B), m.beforeDraw && m.beforeDraw.call(this, k, E), !this.aborted && (k.save(), k.translate(b / 2, B / 2), k.rotate(s * Math.PI / 180), k.scale(c, d), k.drawImage.apply(k, [h].concat(R)), k.restore(), m.drew && m.drew.call(this, k, E), !this.aborted)) {
592
+ if (ce && (J = "#fff"), k.fillStyle = J, k.fillRect(0, 0, b, B), m.beforeDraw && m.beforeDraw.call(this, k, E), !this.aborted && (k.save(), k.translate(b / 2, B / 2), k.rotate(s * Math.PI / 180), k.scale(c, d), k.drawImage.apply(k, [h].concat(R)), k.restore(), m.drew && m.drew.call(this, k, E), !this.aborted)) {
593
593
  var me = function(re) {
594
- if (!a.aborted) {
594
+ if (!i.aborted) {
595
595
  var Ue = function(oe) {
596
- return a.done({
596
+ return i.done({
597
597
  naturalWidth: r,
598
598
  naturalHeight: o,
599
599
  result: oe
600
600
  });
601
601
  };
602
- if (re && ce && m.retainExif && a.exif && a.exif.length > 0) {
602
+ if (re && ce && m.retainExif && i.exif && i.exif.length > 0) {
603
603
  var Oe = function(oe) {
604
- return Ue(Ge(qe(Vt(oe, a.exif), m.mimeType)));
604
+ return Ue(Ge(qe(Vt(oe, i.exif), m.mimeType)));
605
605
  };
606
606
  if (re.arrayBuffer)
607
607
  re.arrayBuffer().then(Oe).catch(function() {
608
- a.fail(new Error("Failed to read the compressed image with Blob.arrayBuffer()."));
608
+ i.fail(new Error("Failed to read the compressed image with Blob.arrayBuffer()."));
609
609
  });
610
610
  else {
611
- var ae = new Be();
612
- a.reader = ae, ae.onload = function(Ce) {
611
+ var ie = new Be();
612
+ i.reader = ie, ie.onload = function(Ce) {
613
613
  var oe = Ce.target;
614
614
  Oe(oe.result);
615
- }, ae.onabort = function() {
616
- a.fail(new Error("Aborted to read the compressed image with FileReader."));
617
- }, ae.onerror = function() {
618
- a.fail(new Error("Failed to read the compressed image with FileReader."));
619
- }, ae.onloadend = function() {
620
- a.reader = null;
621
- }, ae.readAsArrayBuffer(re);
615
+ }, ie.onabort = function() {
616
+ i.fail(new Error("Aborted to read the compressed image with FileReader."));
617
+ }, ie.onerror = function() {
618
+ i.fail(new Error("Failed to read the compressed image with FileReader."));
619
+ }, ie.onloadend = function() {
620
+ i.reader = null;
621
+ }, ie.readAsArrayBuffer(re);
622
622
  }
623
623
  } else
624
624
  Ue(re);
@@ -629,10 +629,10 @@ var Jt = q.ArrayBuffer, Be = q.FileReader, te = q.URL || q.webkitURL, jt = /\.\w
629
629
  }
630
630
  }, {
631
631
  key: "done",
632
- value: function(i) {
633
- var a = i.naturalWidth, r = i.naturalHeight, o = i.result, g = this.file, s = this.image, f = this.options;
632
+ value: function(a) {
633
+ var i = a.naturalWidth, r = a.naturalHeight, o = a.result, g = this.file, s = this.image, f = this.options;
634
634
  if (te && s.src.indexOf("blob:") === 0 && te.revokeObjectURL(s.src), o)
635
- if (f.strict && !f.retainExif && o.size > g.size && f.mimeType === g.type && !(f.width > a || f.height > r || f.minWidth > a || f.minHeight > r || f.maxWidth < a || f.maxHeight < r))
635
+ if (f.strict && !f.retainExif && o.size > g.size && f.mimeType === g.type && !(f.width > i || f.height > r || f.minWidth > i || f.minHeight > r || f.maxWidth < i || f.maxHeight < r))
636
636
  o = g;
637
637
  else {
638
638
  var c = /* @__PURE__ */ new Date();
@@ -644,12 +644,12 @@ var Jt = q.ArrayBuffer, Be = q.FileReader, te = q.URL || q.webkitURL, jt = /\.\w
644
644
  }
645
645
  }, {
646
646
  key: "fail",
647
- value: function(i) {
648
- var a = this.options;
649
- if (a.error)
650
- a.error.call(this, i);
647
+ value: function(a) {
648
+ var i = this.options;
649
+ if (i.error)
650
+ i.error.call(this, a);
651
651
  else
652
- throw i;
652
+ throw a;
653
653
  }
654
654
  }, {
655
655
  key: "abort",
@@ -671,34 +671,34 @@ var Jt = q.ArrayBuffer, Be = q.FileReader, te = q.URL || q.webkitURL, jt = /\.\w
671
671
  */
672
672
  }, {
673
673
  key: "setDefaults",
674
- value: function(i) {
675
- Ae(Xe, i);
674
+ value: function(a) {
675
+ Ae(Xe, a);
676
676
  }
677
677
  }]), t;
678
678
  }();
679
- const Kt = (t, e) => new Promise((i, a) => {
679
+ const Kt = (t, e) => new Promise((a, i) => {
680
680
  if (t.size <= e)
681
681
  return t;
682
682
  const r = e / t.size, o = Math.max(0.5, Math.min(0.9, 0.8 * r)), g = Math.max(800, Math.min(1920, 1920 * Math.sqrt(r)));
683
683
  $e(t, o, g, g, (s) => {
684
- s.size <= e ? i(s) : $e(
684
+ s.size <= e ? a(s) : (console.log("第一次压缩后仍大于5MB,进行二次压缩"), $e(
685
685
  s,
686
686
  Math.max(0.4, o - 0.2),
687
687
  // 降低质量
688
688
  Math.max(640, g * 0.8),
689
689
  // 缩小尺寸
690
690
  Math.max(640, g * 0.8),
691
- i,
692
691
  a,
692
+ i,
693
693
  t
694
694
  // 传递原始文件用于错误处理
695
- );
696
- }, a, t);
697
- }), $e = (t, e, i, a, r, o, g) => {
695
+ ));
696
+ }, i, t);
697
+ }), $e = (t, e, a, i, r, o, g) => {
698
698
  new xt(t, {
699
699
  quality: e,
700
- maxWidth: i,
701
- maxHeight: a,
700
+ maxWidth: a,
701
+ maxHeight: i,
702
702
  convertSize: 1 / 0,
703
703
  success(s) {
704
704
  try {
@@ -724,7 +724,7 @@ const Kt = (t, e) => new Promise((i, a) => {
724
724
  }
725
725
  });
726
726
  }, Ht = (t, e) => {
727
- const i = De(), a = be(t, "modelValue"), r = be(t, "status"), { upload: o } = At(t), { size2B: g } = yt(), { handlerImageSrc: s } = Ct(t), f = be(t, "isOverMaxLimitCompressImg"), c = Ee(""), v = Ee([]), d = [".mp4", ".avi", ".mkv", ".mov", ".wmv", ".flv", ".mpeg", ".webm"], C = [".mp3", ".wav", ".aac", ".flac", ".ogg", ".alff", ".wma", ".m4a"], h = x(() => t.baseUrl ? t.baseUrl : process.env.NODE_ENV === "production" ? "" : i.baseURL || ""), m = (l) => {
727
+ const a = De(), i = be(t, "modelValue"), r = be(t, "status"), { upload: o } = At(t), { size2B: g } = yt(), { handlerImageSrc: s } = Ct(t), f = be(t, "isOverMaxLimitCompressImg"), c = Ee(""), v = Ee([]), d = [".mp4", ".avi", ".mkv", ".mov", ".wmv", ".flv", ".mpeg", ".webm"], C = [".mp3", ".wav", ".aac", ".flac", ".ogg", ".alff", ".wma", ".m4a"], h = x(() => t.baseUrl ? t.baseUrl : process.env.NODE_ENV === "production" ? "" : a.baseURL || ""), m = (l) => {
728
728
  if (l) {
729
729
  const D = l.substring(l.lastIndexOf(".")).toLowerCase();
730
730
  if (d.includes(D)) return "isVideo";
@@ -735,27 +735,27 @@ const Kt = (t, e) => new Promise((i, a) => {
735
735
  var D;
736
736
  let l = t.accept ? (D = t.accept) == null ? void 0 : D.split(",") : [];
737
737
  return l.includes("image/jpg") && !l.includes("image/jpeg") && l.push("image/jpeg"), l.includes(".jpg") && !l.includes(".jpeg") && l.push(".jpeg"), t.acceptVideo && (l = [...l, ...d]), t.acceptAudio && (l = [...l, ...C]), l.join(",");
738
- }), k = x(() => r.value === "uploading"), S = Ee(0), K = (l) => k.value ? S.value === l : !1, T = x(() => a.value ? [s(h.value, a.value)] : []), M = x(() => a.value ? a.value.map((l) => [s(h.value, l)]) : []), L = x(() => t.status !== "info" && (t.needDeleteBtn || t.needChangeBtn) || t.needDownloadBtn), H = x(() => t.status !== "info" && t.needDeleteBtn || t.needDownloadBtn), z = x(() => {
738
+ }), k = x(() => r.value === "uploading"), S = Ee(0), K = (l) => k.value ? S.value === l : !1, M = x(() => i.value ? [s(h.value, i.value)] : []), T = x(() => i.value ? i.value.map((l) => [s(h.value, l)]) : []), F = x(() => t.status !== "info" && (t.needDeleteBtn || t.needChangeBtn) || t.needDownloadBtn), H = x(() => t.status !== "info" && t.needDeleteBtn || t.needDownloadBtn), L = x(() => {
739
739
  const l = [], D = t.previewBtnConfig;
740
740
  if (typeof D == "boolean")
741
741
  return D ? ["zoom_in", "zoom_out", "turn_left", "turn_right", "full_screen"] : [];
742
- for (const F in D)
743
- D[F] && l.push(F);
742
+ for (const N in D)
743
+ D[N] && l.push(N);
744
744
  return l;
745
745
  }), b = () => {
746
746
  setTimeout(() => {
747
747
  const l = document.querySelector(".el-image-viewer__wrapper");
748
- l == null || l.classList.add("das-image-viewer-preview-btn-groups"), l == null || l.classList.add(...z.value);
748
+ console.log(L.value), l == null || l.classList.add("das-image-viewer-preview-btn-groups"), l == null || l.classList.add(...L.value);
749
749
  }, 0);
750
750
  }, B = (l) => {
751
751
  e("clickChangeIcon", l);
752
752
  }, Z = (l, D) => {
753
- t.limitNum === 1 ? (a.value = "", e("update:modelValue", ""), e("deleteImage", l)) : (a.value.splice(D, 1), e("update:modelValue", a.value), e("deleteImage", l));
753
+ t.limitNum === 1 ? (i.value = "", e("update:modelValue", ""), e("deleteImage", l)) : (i.value.splice(D, 1), e("update:modelValue", i.value), e("deleteImage", l));
754
754
  }, $ = (l, D = 0) => {
755
755
  var ee;
756
756
  e("downloadImage", l);
757
- let F = "";
758
- t.limitNum === 1 ? F = t.imageName || c.value : F = ((ee = t.imageName) == null ? void 0 : ee[D]) || v.value[D], m(l) === "isImg" ? gt(s(h.value, l), F) : vt(s(h.value, l), F);
757
+ let N = "";
758
+ t.limitNum === 1 ? N = t.imageName || c.value : N = ((ee = t.imageName) == null ? void 0 : ee[D]) || v.value[D], m(l) === "isImg" ? gt(s(h.value, l), N) : vt(s(h.value, l), N);
759
759
  }, u = [
760
760
  "image/jpeg",
761
761
  "image/png",
@@ -767,8 +767,8 @@ const Kt = (t, e) => new Promise((i, a) => {
767
767
  ], w = async (l, D) => {
768
768
  var ee;
769
769
  if (t.maxSize) {
770
- const { finalSize: N, sizeText: R } = g(t.maxSize);
771
- if (l.size > N && !f.value) {
770
+ const { finalSize: V, sizeText: R } = g(t.maxSize);
771
+ if (l.size > V && !f.value) {
772
772
  const Q = Ke.value === "zh-CN" ? "、" : ", ", P = He(
773
773
  "das-ui-import-upload-key3",
774
774
  R,
@@ -777,45 +777,49 @@ const Kt = (t, e) => new Promise((i, a) => {
777
777
  return xe.warning(G), !1;
778
778
  }
779
779
  }
780
- const F = async (N) => {
780
+ const N = async (V) => {
781
781
  let R = l;
782
782
  if (t.maxSize) {
783
783
  const { finalSize: P, sizeText: G } = g(t.maxSize);
784
784
  if (l.size > P && f.value && u.includes(l.type))
785
785
  try {
786
- R = await Kt(l, P);
786
+ R = await Kt(l, P), console.log(
787
+ "压缩成功:",
788
+ `原始大小: ${(l.size / 1024 / 1024).toFixed(2)}MB →`,
789
+ `压缩后: ${(R.size / 1024 / 1024).toFixed(2)}MB`
790
+ );
787
791
  } catch (Y) {
788
- R = (Y == null ? void 0 : Y.original) || l;
792
+ console.log("压缩失败,使用原始文件"), R = (Y == null ? void 0 : Y.original) || l;
789
793
  }
790
794
  }
791
- S.value = N, e("update:status", "uploading"), e("image-upload", R);
795
+ S.value = V, e("update:status", "uploading"), e("image-upload", R);
792
796
  const Q = await o(R);
793
- return Q === "error" ? (e("update:status", "error"), !1) : (e("upload-success", R, Q), t.limitNum === 1 ? a.value = Q : a.value[N] = Q, e("update:modelValue", a.value), e("update:status", "normal"), !1);
797
+ return Q === "error" ? (e("update:status", "error"), !1) : (e("upload-success", R, Q), t.limitNum === 1 ? i.value = Q : i.value[V] = Q, e("update:modelValue", i.value), e("update:status", "normal"), !1);
794
798
  };
795
799
  if (t.customCheck) {
796
- const N = t.customCheck(l);
797
- if (N instanceof Promise)
800
+ const V = t.customCheck(l);
801
+ if (V instanceof Promise)
798
802
  return new Promise(async (R, Q) => {
799
803
  let P;
800
804
  try {
801
- P = await N.then();
805
+ P = await V.then();
802
806
  } catch {
803
807
  P = !1;
804
808
  }
805
- P ? F(D) : Q(!1);
809
+ P ? N(D) : Q(!1);
806
810
  });
807
- if (!N) return !1;
811
+ if (!V) return !1;
808
812
  } else if (E.value) {
809
- const N = E.value.split(",").filter((V) => V.trim().startsWith(".")).map((V) => V.trim()), R = E.value.split(",").filter((V) => !V.trim().startsWith(".")).map((V) => V.trim()), Q = mt(l.name), P = N.includes(Q);
813
+ const V = E.value.split(",").filter((J) => J.trim().startsWith(".")).map((J) => J.trim()), R = E.value.split(",").filter((J) => !J.trim().startsWith(".")).map((J) => J.trim()), Q = mt(l.name), P = V.includes(Q);
810
814
  let G = R.includes("image/*") && l.type.split("/")[0].trim() === "image", Y = R.includes("video/*") && l.type.split("/")[0].trim() === "video", le = R.includes("audio/*") && l.type.split("/")[0].trim() === "audio", ue = R.includes(l.type) || G || Y || le;
811
815
  if (!P && !ue) {
812
- const V = t.acceptAudio || t.acceptVideo ? "das-ui-import-upload-key2" : "das-ui-import-upload-key1", ce = Ke.value === "zh-CN" ? "、" : ", ", me = t.errorMessage || He(V, E.value.toUpperCase().replaceAll(".", "").replaceAll(",", ce)).value;
816
+ const J = t.acceptAudio || t.acceptVideo ? "das-ui-import-upload-key2" : "das-ui-import-upload-key1", ce = Ke.value === "zh-CN" ? "、" : ", ", me = t.errorMessage || He(J, E.value.toUpperCase().replaceAll(".", "").replaceAll(",", ce)).value;
813
817
  return xe.warning(me), !1;
814
818
  }
815
819
  }
816
- return F(D);
820
+ return N(D);
817
821
  }, I = async (l) => {
818
- t.limitNum !== 1 && (S.value = a.length), e("update:status", "uploading"), e("image-upload", l);
822
+ t.limitNum !== 1 && (S.value = i.length), e("update:status", "uploading"), e("image-upload", l);
819
823
  const D = await o(l);
820
824
  e("upload-success", l, D), t.limitNum === 1 ? A(D) : _(D);
821
825
  }, A = (l) => {
@@ -823,29 +827,29 @@ const Kt = (t, e) => new Promise((i, a) => {
823
827
  e("update:status", "error");
824
828
  return;
825
829
  }
826
- a.value = l, e("update:modelValue", a.value), e("update:status", "normal");
830
+ i.value = l, e("update:modelValue", i.value), e("update:status", "normal");
827
831
  }, _ = (l) => {
828
832
  if (l === "error") {
829
833
  e("update:status", "error");
830
834
  return;
831
835
  }
832
- a.value.push(l), e("update:modelValue", a.value), e("update:status", "normal");
836
+ console.log(i, "========url"), i.value.push(l), e("update:modelValue", i.value), e("update:status", "normal");
833
837
  };
834
- return st(a, async () => {
838
+ return st(i, async () => {
835
839
  const l = t.limitNum ?? 1;
836
- l === 1 && a.value ? c.value = await Et(a.value) : l > 1 && a.value.length > 0 && (v.value = await bt(a.value));
840
+ l === 1 && i.value ? c.value = await Et(i.value) : l > 1 && i.value.length > 0 && (v.value = await bt(i.value));
837
841
  }, {
838
842
  deep: !0,
839
843
  immediate: !0
840
844
  }), {
841
- url: a,
842
- singlePreviewList: T,
843
- multiPreviewList: M,
845
+ url: i,
846
+ singlePreviewList: M,
847
+ multiPreviewList: T,
844
848
  isAccept: E,
845
849
  loading: k,
846
850
  uploadStatus: r,
847
- previewBtns: z,
848
- operateShow: L,
851
+ previewBtns: L,
852
+ operateShow: F,
849
853
  operateShow_Multi: H,
850
854
  singlePreviewName: c,
851
855
  multiPreviewName: v,
@@ -860,9 +864,9 @@ const Kt = (t, e) => new Promise((i, a) => {
860
864
  };
861
865
  }, Wt = (t, e) => {
862
866
  var o;
863
- const { __IN_DAS_MICRO_APP: i, __DAS_MAIN_APP_HREF: a } = window;
864
- if (!i || !a) return;
865
- const { origin: r } = new URL(a);
867
+ const { __IN_DAS_MICRO_APP: a, __DAS_MAIN_APP_HREF: i } = window;
868
+ if (!a || !i) return;
869
+ const { origin: r } = new URL(i);
866
870
  (o = window.top) == null || o.postMessage({ type: t, data: e }, r);
867
871
  }, nt = "proxy-image-viewer", we = {
868
872
  sendMessageToMainApp: Wt,
@@ -870,17 +874,17 @@ const Kt = (t, e) => new Promise((i, a) => {
870
874
  isMicroApp: () => window.__IN_DAS_MICRO_APP && window.top !== window.self,
871
875
  addEventFromMicroApp: () => {
872
876
  window.addEventListener("message", (t) => {
873
- const { type: e, data: i } = t.data;
877
+ const { type: e, data: a } = t.data;
874
878
  if (e !== nt) return;
875
- const a = document.createElement("div");
876
- a.classList.add("das-image-viewer-preview-btn-groups");
877
- const { previewList: r, previewBtns: o } = i, g = lt(ct, {
879
+ const i = document.createElement("div");
880
+ i.classList.add("das-image-viewer-preview-btn-groups");
881
+ const { previewList: r, previewBtns: o } = a, g = lt(ct, {
878
882
  urlList: r,
879
883
  onClose: () => {
880
- g.unmount(), document.body.removeChild(a);
884
+ g.unmount(), document.body.removeChild(i);
881
885
  }
882
886
  });
883
- document.body.appendChild(a), g.mount(a), setTimeout(() => {
887
+ document.body.appendChild(i), g.mount(i), setTimeout(() => {
884
888
  const s = document.querySelector(".el-image-viewer__wrapper");
885
889
  s == null || s.classList.add("das-image-viewer-preview-btn-groups"), s == null || s.classList.add(...o);
886
890
  }, 0);
@@ -889,7 +893,7 @@ const Kt = (t, e) => new Promise((i, a) => {
889
893
  };
890
894
  we.addEventFromMicroApp();
891
895
  const Yt = (t) => {
892
- const { handleImageClickProxy: e, previewBtns: i } = t;
896
+ const { handleImageClickProxy: e, previewBtns: a } = t;
893
897
  return { needPreviewImage: x(() => !t.needPreview || we.isMicroApp() ? !1 : t.needPreview), handleImageClick: (o) => {
894
898
  if (!t.needPreview) return;
895
899
  if (!we.isMicroApp()) {
@@ -899,7 +903,7 @@ const Yt = (t) => {
899
903
  let g = [];
900
904
  Array.isArray(o) && g.push(...o), typeof o == "string" && g.push(o), we.sendMessageToMainApp(nt, {
901
905
  previewList: g,
902
- previewBtns: i.value
906
+ previewBtns: a.value
903
907
  });
904
908
  } };
905
909
  }, Gt = {
@@ -909,13 +913,13 @@ const Yt = (t) => {
909
913
  class: "no-data-img",
910
914
  src: Ie,
911
915
  alt: ""
912
- }, qt = { class: "image-name" }, Zt = { class: "das-ui-image-viewer-groups" }, $t = { class: "image-name" }, _t = { class: "das-ui-image-viewer-container" }, ea = {
916
+ }, qt = { class: "image-name" }, Zt = { class: "das-ui-image-viewer-groups" }, $t = { class: "image-name" }, _t = { class: "das-ui-image-viewer-container" }, ei = {
913
917
  key: 1,
914
918
  class: "das-ui-image-viewer-container"
915
- }, ta = { class: "das-ui-image-viewer" }, aa = {
919
+ }, ti = { class: "das-ui-image-viewer" }, ii = {
916
920
  key: 2,
917
921
  class: "das-ui-image-viewer"
918
- }, ia = /* @__PURE__ */ ut({
922
+ }, ai = /* @__PURE__ */ ut({
919
923
  __name: "Index",
920
924
  props: {
921
925
  style: { default: "" },
@@ -953,17 +957,17 @@ const Yt = (t) => {
953
957
  },
954
958
  emits: ["update:modelValue", "update:status", "downloadImage", "image-upload", "upload-success", "clickChangeIcon", "deleteImage"],
955
959
  setup(t, { emit: e }) {
956
- const i = t, a = e, r = x(() => {
960
+ const a = t, i = e, r = x(() => {
957
961
  const w = [
958
- i.needDownloadBtn,
959
- i.limitNum === 1 && d.value !== "info" && i.needChangeBtn,
960
- d.value !== "info" && i.needDeleteBtn
962
+ a.needDownloadBtn,
963
+ a.limitNum === 1 && d.value !== "info" && a.needChangeBtn,
964
+ d.value !== "info" && a.needDeleteBtn
961
965
  ].filter((A) => A).length;
962
966
  let I = "center";
963
967
  return w === 2 && (I = "space-around"), w === 3 && (I = "space-between"), {
964
968
  "justify-content": I
965
969
  };
966
- }), o = x(() => i.mode === "view" ? !1 : s.value ? d.value === "error" : d.value !== "info"), g = (u) => {
970
+ }), o = x(() => a.mode === "view" ? !1 : s.value ? d.value === "error" : d.value !== "info"), g = (u) => {
967
971
  u.stopPropagation();
968
972
  }, {
969
973
  url: s,
@@ -978,16 +982,16 @@ const Yt = (t) => {
978
982
  singlePreviewName: k,
979
983
  multiPreviewName: S,
980
984
  changeImg: K,
981
- delImg: T,
982
- beforeupload: M,
983
- uploadImg: L,
985
+ delImg: M,
986
+ beforeupload: T,
987
+ uploadImg: F,
984
988
  onDownload: H,
985
- handleImageClick: z,
989
+ handleImageClick: L,
986
990
  getFileType: b,
987
991
  isLoadingMulti: B
988
- } = Ht(i, a), { needPreviewImage: Z, handleImageClick: $ } = Yt({
989
- needPreview: i.needPreview,
990
- handleImageClickProxy: z,
992
+ } = Ht(a, i), { needPreviewImage: Z, handleImageClick: $ } = Yt({
993
+ needPreview: a.needPreview,
994
+ handleImageClickProxy: L,
991
995
  previewBtns: h
992
996
  });
993
997
  return (u, w) => (y(), U(
@@ -1004,14 +1008,14 @@ const Yt = (t) => {
1004
1008
  },
1005
1009
  [
1006
1010
  p(" 状态不为 error 时显示 "),
1007
- J(ie(n(Je), {
1011
+ j(ae(n(Je), {
1008
1012
  class: ge([{ "loading-border": n(C) }]),
1009
1013
  type: "component",
1010
1014
  spinning: n(C)
1011
1015
  }, {
1012
1016
  default: ne(() => [
1013
1017
  p(" 图片 "),
1014
- n(b)(n(c)[0]) === "isImg" ? J((y(), O(n(Le), {
1018
+ n(b)(n(c)[0]) === "isImg" ? j((y(), O(n(Fe), {
1015
1019
  key: 0,
1016
1020
  class: ge(["image-context", [n(h)]]),
1017
1021
  "preview-teleported": !0,
@@ -1021,10 +1025,10 @@ const Yt = (t) => {
1021
1025
  fit: u.imageFit,
1022
1026
  onClick: w[0] || (w[0] = (I) => n($)(n(c)))
1023
1027
  }, null, 8, ["class", "src", "preview-src-list", "fit"])), [
1024
- [j, !n(C)]
1028
+ [z, !n(C)]
1025
1029
  ]) : p("v-if", !0),
1026
1030
  p(" 视频 "),
1027
- n(b)(n(c)[0]) === "isVideo" ? J((y(), O(n(ve), {
1031
+ n(b)(n(c)[0]) === "isVideo" ? j((y(), O(n(ve), {
1028
1032
  key: 1,
1029
1033
  mode: n(d) === "info" || u.mode === "view" ? "view" : "normal",
1030
1034
  src: n(c)[0],
@@ -1034,10 +1038,10 @@ const Yt = (t) => {
1034
1038
  "player-props": { videoWidth: u.videoWidth, videoHeight: u.videoHeight },
1035
1039
  fullPath: ""
1036
1040
  }, null, 8, ["mode", "src", "needPreview", "player-props"])), [
1037
- [j, !n(C)]
1041
+ [z, !n(C)]
1038
1042
  ]) : p("v-if", !0),
1039
1043
  p(" 音频 "),
1040
- n(b)(n(c)[0]) === "isAudio" ? J((y(), O(n(ve), {
1044
+ n(b)(n(c)[0]) === "isAudio" ? j((y(), O(n(ve), {
1041
1045
  key: 2,
1042
1046
  mode: n(d) === "info" || u.mode === "view" ? "view" : "normal",
1043
1047
  src: n(c)[0],
@@ -1047,7 +1051,7 @@ const Yt = (t) => {
1047
1051
  type: "audio",
1048
1052
  fullPath: ""
1049
1053
  }, null, 8, ["mode", "src", "needPreview"])), [
1050
- [j, !n(C)]
1054
+ [z, !n(C)]
1051
1055
  ]) : p("v-if", !0),
1052
1056
  !n(C) && n(m) ? (y(), U(
1053
1057
  "div",
@@ -1070,15 +1074,15 @@ const Yt = (t) => {
1070
1074
  class: "change-icon-box",
1071
1075
  onClick: w[2] || (w[2] = (I) => n(K)(n(s)))
1072
1076
  }, [
1073
- u.openFileDialogOnClick ? (y(), O(n(Fe), {
1077
+ u.openFileDialogOnClick ? (y(), O(n(Le), {
1074
1078
  key: 0,
1075
- "before-upload": (I) => n(M)(I, 0),
1079
+ "before-upload": (I) => n(T)(I, 0),
1076
1080
  accept: n(f),
1077
1081
  openFileDialogOnClick: u.openFileDialogOnClick
1078
1082
  }, {
1079
1083
  itemRender: ne(({ file: I, actions: A }) => w[7] || (w[7] = [])),
1080
1084
  default: ne(() => [
1081
- ie(n(pe), {
1085
+ ae(n(pe), {
1082
1086
  class: "operate-btn m-t-6",
1083
1087
  "icon-color": "#fff",
1084
1088
  size: "medium"
@@ -1099,7 +1103,7 @@ const Yt = (t) => {
1099
1103
  class: "operate-btn",
1100
1104
  "icon-color": "#fff",
1101
1105
  size: "medium",
1102
- onClick: w[3] || (w[3] = (I) => n(T)(n(s)))
1106
+ onClick: w[3] || (w[3] = (I) => n(M)(n(s)))
1103
1107
  })) : p("v-if", !0)
1104
1108
  ],
1105
1109
  4
@@ -1109,10 +1113,10 @@ const Yt = (t) => {
1109
1113
  _: 1
1110
1114
  /* STABLE */
1111
1115
  }, 8, ["class", "spinning"]), [
1112
- [j, n(s) && u.status !== "error"]
1116
+ [z, n(s) && u.status !== "error"]
1113
1117
  ]),
1114
1118
  p(" 上传模式,当 url 为空或者 uploading 和 error 时显示 "),
1115
- J(ie(n(Ve), {
1119
+ j(ae(n(Ve), {
1116
1120
  status: n(d),
1117
1121
  "onUpdate:status": w[4] || (w[4] = (I) => Qe(d) ? d.value = I : null),
1118
1122
  "max-size": u.maxSize,
@@ -1124,33 +1128,33 @@ const Yt = (t) => {
1124
1128
  "custom-check": u.customCheck,
1125
1129
  "error-message": u.errorMessage,
1126
1130
  openFileDialogOnClick: u.openFileDialogOnClick,
1127
- onImageUpload: n(L),
1131
+ onImageUpload: n(F),
1128
1132
  isOverMaxLimitCompressImg: u.isOverMaxLimitCompressImg
1129
1133
  }, null, 8, ["status", "max-size", "accept", "acceptVideo", "message", "acceptAudio", "autoContentType", "custom-check", "error-message", "openFileDialogOnClick", "onImageUpload", "isOverMaxLimitCompressImg"]), [
1130
- [j, o.value]
1134
+ [z, o.value]
1131
1135
  ]),
1132
1136
  p(" 查看模式 "),
1133
- J(X(
1137
+ j(X(
1134
1138
  "img",
1135
1139
  Xt,
1136
1140
  null,
1137
1141
  512
1138
1142
  /* NEED_PATCH */
1139
1143
  ), [
1140
- [j, !n(s) && (n(d) === "info" || u.mode === "view")]
1144
+ [z, !n(s) && (n(d) === "info" || u.mode === "view")]
1141
1145
  ])
1142
1146
  ],
1143
1147
  4
1144
1148
  /* STYLE */
1145
1149
  ),
1146
- J((y(), U("div", qt, [
1150
+ j((y(), U("div", qt, [
1147
1151
  Pe(
1148
- Te(i.imageName || n(k)),
1152
+ Me(a.imageName || n(k)),
1149
1153
  1
1150
1154
  /* TEXT */
1151
1155
  )
1152
1156
  ])), [
1153
- [j, n(s) && u.showImageName && (n(d) === "normal" || n(d) === "info")],
1157
+ [z, n(s) && u.showImageName && (n(d) === "normal" || n(d) === "info")],
1154
1158
  [n(Ne)]
1155
1159
  ])
1156
1160
  ])) : (y(), U(
@@ -1163,7 +1167,7 @@ const Yt = (t) => {
1163
1167
  (y(!0), U(
1164
1168
  de,
1165
1169
  null,
1166
- Me(n(s), (I, A) => {
1170
+ Te(n(s), (I, A) => {
1167
1171
  var _;
1168
1172
  return y(), U("div", {
1169
1173
  key: A,
@@ -1176,13 +1180,13 @@ const Yt = (t) => {
1176
1180
  style: fe(u.style)
1177
1181
  },
1178
1182
  [
1179
- J(ie(n(Je), {
1183
+ j(ae(n(Je), {
1180
1184
  class: ge([{ "loading-border": n(B)(A) }]),
1181
1185
  type: "component",
1182
1186
  spinning: n(B)(A)
1183
1187
  }, {
1184
1188
  default: ne(() => [
1185
- n(b)(n(v)[A][0]) === "isImg" ? J((y(), O(n(Le), {
1189
+ n(b)(n(v)[A][0]) === "isImg" ? j((y(), O(n(Fe), {
1186
1190
  key: 0,
1187
1191
  class: ge(["image-context", [n(h)]]),
1188
1192
  src: n(v)[A][0],
@@ -1192,10 +1196,10 @@ const Yt = (t) => {
1192
1196
  onClick: (W) => n($)(n(v)[A]),
1193
1197
  fit: "cover"
1194
1198
  }, null, 8, ["class", "src", "preview-src-list", "initial-index", "onClick"])), [
1195
- [j, !n(B)(A)]
1199
+ [z, !n(B)(A)]
1196
1200
  ]) : p("v-if", !0),
1197
1201
  p(" 视频 "),
1198
- n(b)(n(v)[A][0]) === "isVideo" ? J((y(), O(n(ve), {
1202
+ n(b)(n(v)[A][0]) === "isVideo" ? j((y(), O(n(ve), {
1199
1203
  key: 1,
1200
1204
  mode: n(d) === "info" || u.mode === "view" ? "view" : "normal",
1201
1205
  src: n(v)[A][0],
@@ -1205,10 +1209,10 @@ const Yt = (t) => {
1205
1209
  fullPath: "",
1206
1210
  "player-props": { videoWidth: u.videoWidth, videoHeight: u.videoHeight }
1207
1211
  }, null, 8, ["mode", "src", "needPreview", "player-props"])), [
1208
- [j, !n(B)(A)]
1212
+ [z, !n(B)(A)]
1209
1213
  ]) : p("v-if", !0),
1210
1214
  p(" 音频 "),
1211
- n(b)(n(v)[A][0]) === "isAudio" ? J((y(), O(n(ve), {
1215
+ n(b)(n(v)[A][0]) === "isAudio" ? j((y(), O(n(ve), {
1212
1216
  key: 2,
1213
1217
  mode: n(d) === "info" || u.mode === "view" ? "view" : "normal",
1214
1218
  src: n(v)[A][0],
@@ -1218,7 +1222,7 @@ const Yt = (t) => {
1218
1222
  type: "audio",
1219
1223
  fullPath: ""
1220
1224
  }, null, 8, ["mode", "src", "needPreview"])), [
1221
- [j, !n(B)(A)]
1225
+ [z, !n(B)(A)]
1222
1226
  ]) : p("v-if", !0),
1223
1227
  !n(C) && n(E) ? (y(), U(
1224
1228
  "div",
@@ -1240,15 +1244,15 @@ const Yt = (t) => {
1240
1244
  class: "change-icon-box",
1241
1245
  onClick: w[5] || (w[5] = (W) => n(K)(n(s)))
1242
1246
  }, [
1243
- u.openFileDialogOnClick ? (y(), O(n(Fe), {
1247
+ u.openFileDialogOnClick ? (y(), O(n(Le), {
1244
1248
  key: 0,
1245
- "before-upload": (W) => n(M)(W, A),
1249
+ "before-upload": (W) => n(T)(W, A),
1246
1250
  accept: n(f),
1247
1251
  openFileDialogOnClick: u.openFileDialogOnClick
1248
1252
  }, {
1249
1253
  itemRender: ne(({ file: W, actions: l }) => w[8] || (w[8] = [])),
1250
1254
  default: ne(() => [
1251
- ie(n(pe), {
1255
+ ae(n(pe), {
1252
1256
  class: "operate-btn m-t-6",
1253
1257
  "icon-color": "#fff",
1254
1258
  size: "medium"
@@ -1269,7 +1273,7 @@ const Yt = (t) => {
1269
1273
  class: "operate-btn",
1270
1274
  "icon-color": "#fff",
1271
1275
  size: "medium",
1272
- onClick: (W) => n(T)(I, A)
1276
+ onClick: (W) => n(M)(I, A)
1273
1277
  }, null, 8, ["onClick"])) : p("v-if", !0)
1274
1278
  ],
1275
1279
  4
@@ -1279,20 +1283,20 @@ const Yt = (t) => {
1279
1283
  _: 2
1280
1284
  /* DYNAMIC */
1281
1285
  }, 1032, ["class", "spinning"]), [
1282
- [j, I]
1286
+ [z, I]
1283
1287
  ])
1284
1288
  ],
1285
1289
  4
1286
1290
  /* STYLE */
1287
1291
  ),
1288
- J((y(), U("div", $t, [
1292
+ j((y(), U("div", $t, [
1289
1293
  Pe(
1290
- Te(((_ = i.imageName) == null ? void 0 : _[A]) || n(S)[A]),
1294
+ Me(((_ = a.imageName) == null ? void 0 : _[A]) || n(S)[A]),
1291
1295
  1
1292
1296
  /* TEXT */
1293
1297
  )
1294
1298
  ])), [
1295
- [j, I && u.showImageName && !n(B)(A)],
1299
+ [z, I && u.showImageName && !n(B)(A)],
1296
1300
  [n(Ne)]
1297
1301
  ])
1298
1302
  ]);
@@ -1304,7 +1308,7 @@ const Yt = (t) => {
1304
1308
  u.mode === "view" ? (y(!0), U(
1305
1309
  de,
1306
1310
  { key: 0 },
1307
- Me(u.limitNum - n(s).length, (I) => (y(), U("div", _t, w[9] || (w[9] = [
1311
+ Te(u.limitNum - n(s).length, (I) => (y(), U("div", _t, w[9] || (w[9] = [
1308
1312
  X(
1309
1313
  "div",
1310
1314
  { class: "das-ui-image-viewer" },
@@ -1323,9 +1327,9 @@ const Yt = (t) => {
1323
1327
  /* UNKEYED_FRAGMENT */
1324
1328
  )) : p("v-if", !0),
1325
1329
  p(" 图片数量未到达最大数量限制时,显示上传组件 "),
1326
- u.mode === "upload" && n(d) !== "info" && n(s).length < u.limitNum ? (y(), U("div", ea, [
1327
- X("div", ta, [
1328
- ie(n(Ve), {
1330
+ u.mode === "upload" && n(d) !== "info" && n(s).length < u.limitNum ? (y(), U("div", ei, [
1331
+ X("div", ti, [
1332
+ ae(n(Ve), {
1329
1333
  status: n(d),
1330
1334
  "onUpdate:status": w[6] || (w[6] = (I) => Qe(d) ? d.value = I : null),
1331
1335
  "max-size": u.maxSize,
@@ -1336,13 +1340,13 @@ const Yt = (t) => {
1336
1340
  "custom-check": u.customCheck,
1337
1341
  "error-message": u.errorMessage,
1338
1342
  openFileDialogOnClick: u.openFileDialogOnClick,
1339
- onImageUpload: n(L),
1343
+ onImageUpload: n(F),
1340
1344
  isOverMaxLimitCompressImg: u.isOverMaxLimitCompressImg
1341
1345
  }, null, 8, ["status", "max-size", "accept", "acceptVideo", "acceptAudio", "message", "custom-check", "error-message", "openFileDialogOnClick", "onImageUpload", "isOverMaxLimitCompressImg"])
1342
1346
  ])
1343
1347
  ])) : p("v-if", !0),
1344
1348
  p(" 当图片状态为查看态且无数据时,显示无数据图片 "),
1345
- n(d) === "info" && n(s).length === 0 ? (y(), U("div", aa, w[10] || (w[10] = [
1349
+ n(d) === "info" && n(s).length === 0 ? (y(), U("div", ii, w[10] || (w[10] = [
1346
1350
  X(
1347
1351
  "img",
1348
1352
  {
@@ -1365,20 +1369,20 @@ const Yt = (t) => {
1365
1369
  /* STABLE_FRAGMENT, DEV_ROOT_FRAGMENT */
1366
1370
  ));
1367
1371
  }
1368
- }), na = (t, e) => {
1369
- const i = t.__vccOpts || t;
1370
- for (const [a, r] of e)
1371
- i[a] = r;
1372
- return i;
1373
- }, ra = /* @__PURE__ */ na(ia, [["__scopeId", "data-v-0cbe0660"]]), oa = {
1372
+ }), ni = (t, e) => {
1373
+ const a = t.__vccOpts || t;
1374
+ for (const [i, r] of e)
1375
+ a[i] = r;
1376
+ return a;
1377
+ }, ri = /* @__PURE__ */ ni(ai, [["__scopeId", "data-v-0cbe0660"]]), oi = {
1374
1378
  "--das-ui-image-viewer-bg-color": { light: "rgba(0, 0, 0, 0.5)" },
1375
1379
  "--das-ui-image-viewer-btn-hover": { light: "#87A9FF" },
1376
1380
  "--das-ui-image-viewer-btn-active": { light: "#276FF5" }
1377
- }, Pa = rt(ra);
1378
- ot(oa);
1381
+ }, Pi = rt(ri);
1382
+ ot(oi);
1379
1383
  export {
1380
- Pa as DasImageViewer,
1381
- Pa as default,
1384
+ Pi as DasImageViewer,
1385
+ Pi as default,
1382
1386
  At as minioUpload,
1383
1387
  yt as useCalculateSize
1384
1388
  };