@web-utils/component 2.7.13 → 2.7.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (110) hide show
  1. package/dist/chunks/{ConfigSelect.vue_vue_type_template_lang.e7a9d5b7.js → ConfigSelect.vue_vue_type_template_lang.dfc91f07.js} +20 -15
  2. package/dist/chunks/{ConfigTable.vue_vue_type_template_lang.e9060616.js → ConfigTable.vue_vue_type_template_lang.b27540fd.js} +1 -1
  3. package/dist/chunks/{ConfigUpload.vue_vue_type_template_lang.48dd814b.js → ConfigUpload.vue_vue_type_template_lang.129c0ced.js} +18 -13
  4. package/dist/chunks/{WidgetConfig.vue_vue_type_template_lang.7928c468.js → WidgetConfig.vue_vue_type_template_lang.3cc74fe8.js} +16 -16
  5. package/dist/chunks/{WidgetForm.vue_vue_type_template_lang.e3e800a6.js → WidgetForm.vue_vue_type_template_lang.d4b05679.js} +10 -10
  6. package/dist/chunks/{WidgetFormGroup.vue_vue_type_template_lang.6a693e5e.js → WidgetFormGroup.vue_vue_type_template_lang.bdcb6d37.js} +13 -13
  7. package/dist/chunks/{WidgetFormTable.vue_vue_type_template_lang.291bf39a.js → WidgetFormTable.vue_vue_type_template_lang.e2b788ba.js} +3 -2
  8. package/dist/chunks/{dataformat.d3fd2d1b.js → dataformat.65b92bfe.js} +36 -35
  9. package/dist/chunks/detail.d67573b1.js +28 -0
  10. package/dist/chunks/dic.70feb9b4.js +135 -0
  11. package/dist/chunks/{event.43b42228.js → event.dd6f522d.js} +3 -3
  12. package/dist/chunks/{init.3b47bb80.js → init.7c58eb34.js} +10 -10
  13. package/dist/chunks/{monaco.1dbdc960.js → monaco.cefcb9f5.js} +92 -85
  14. package/dist/chunks/{packages.6f252850.js → packages.1fc9ccba.js} +1 -1
  15. package/dist/chunks/slot.4b391395.js +27 -0
  16. package/dist/chunks/util.23fe58fb.js +261 -0
  17. package/dist/components/afd-column/index.js +1 -1
  18. package/dist/components/affix/index.js +2 -2
  19. package/dist/components/base.css +1 -1
  20. package/dist/components/carousel/index.js +2 -2
  21. package/dist/components/chat/index.js +9 -9
  22. package/dist/components/column/index.js +25 -25
  23. package/dist/components/column-default/index.js +3 -2
  24. package/dist/components/column-dynamic/index.js +1 -1
  25. package/dist/components/column-menu/index.js +11 -11
  26. package/dist/components/column-slot/index.js +54 -53
  27. package/dist/components/config-custom/index.js +3 -3
  28. package/dist/components/config-event/index.js +5 -5
  29. package/dist/components/config-rate/index.js +1 -1
  30. package/dist/components/config-rate/style.css +1 -1
  31. package/dist/components/config-select/index.js +3 -3
  32. package/dist/components/config-switch/index.js +5 -5
  33. package/dist/components/config-switch/style.css +1 -1
  34. package/dist/components/config-table/index.js +3 -3
  35. package/dist/components/config-tree/index.js +3 -3
  36. package/dist/components/config-tree/style.css +1 -1
  37. package/dist/components/config-upload/index.js +1 -1
  38. package/dist/components/dialog-excel/index.js +37 -40
  39. package/dist/components/dialog-filter/index.js +19 -19
  40. package/dist/components/dialog-form/index.js +1 -1
  41. package/dist/components/element-dialog/index.js +2 -2
  42. package/dist/components/element-dialog/style.css +1 -1
  43. package/dist/components/flow/index.js +17 -18
  44. package/dist/components/flow-node/index.js +1 -1
  45. package/dist/components/form-temp/index.js +3 -3
  46. package/dist/components/fy-array/index.js +2 -2
  47. package/dist/components/fy-cascader/index.js +13 -13
  48. package/dist/components/fy-checkbox/index.js +4 -4
  49. package/dist/components/fy-code/index.js +1 -1
  50. package/dist/components/fy-curd/index.js +68 -69
  51. package/dist/components/fy-date/index.js +1 -1
  52. package/dist/components/fy-dialog-form/index.js +11 -11
  53. package/dist/components/fy-draggable/index.js +5 -7
  54. package/dist/components/fy-dynamic/index.js +32 -28
  55. package/dist/components/fy-empty/index.js +1 -1
  56. package/dist/components/fy-form/index.js +153 -141
  57. package/dist/components/fy-form-design/index.js +31 -31
  58. package/dist/components/fy-input/index.js +60 -46
  59. package/dist/components/fy-input-color/index.js +34 -29
  60. package/dist/components/fy-input-icon/index.js +1 -1
  61. package/dist/components/fy-input-map/index.js +14 -14
  62. package/dist/components/fy-input-number/index.js +1 -1
  63. package/dist/components/fy-input-table/index.js +2 -2
  64. package/dist/components/fy-input-tree/index.js +12 -12
  65. package/dist/components/fy-radio/index.js +1 -1
  66. package/dist/components/fy-rate/index.js +1 -1
  67. package/dist/components/fy-select/index.js +3 -3
  68. package/dist/components/fy-slider/index.js +2 -2
  69. package/dist/components/fy-switch/index.js +1 -1
  70. package/dist/components/fy-tabs/index.js +2 -2
  71. package/dist/components/fy-time/index.js +2 -2
  72. package/dist/components/fy-title/index.js +1 -1
  73. package/dist/components/fy-tree/index.js +3 -3
  74. package/dist/components/fy-u-editor/index.js +26 -24
  75. package/dist/components/fy-upload/index.js +146 -282
  76. package/dist/components/header-menu/index.js +2 -2
  77. package/dist/components/header-search/index.js +16 -15
  78. package/dist/components/image-cropper/index.js +299 -0
  79. package/dist/components/image-cropper/style.css +1 -0
  80. package/dist/components/image-preview/index.js +346 -0
  81. package/dist/components/image-preview/style.css +1 -0
  82. package/dist/components/keyboard/index.js +58 -63
  83. package/dist/components/license/index.js +7 -7
  84. package/dist/components/login/index.js +37 -32
  85. package/dist/components/name-avatar/index.js +1 -1
  86. package/dist/components/pageable-table/index.js +1 -1
  87. package/dist/components/pageable-view/index.js +26 -26
  88. package/dist/components/photo-swipe/index.js +72 -165
  89. package/dist/components/queue/index.js +6 -6
  90. package/dist/components/record-video/index.js +18 -18
  91. package/dist/components/search/index.js +3 -3
  92. package/dist/components/sign/index.js +64 -59
  93. package/dist/components/skeleton/index.js +1 -1
  94. package/dist/components/table-page/index.js +5 -5
  95. package/dist/components/text-ellipsis/index.js +11 -10
  96. package/dist/components/verify/index.js +25 -25
  97. package/dist/components/widget-config/index.js +8 -8
  98. package/dist/components/widget-form/index.js +7 -7
  99. package/dist/components/widget-form-group/index.js +8 -8
  100. package/dist/components/widget-form-item/index.js +14 -13
  101. package/dist/components/widget-form-table/index.js +14 -14
  102. package/dist/index.css +109 -40
  103. package/dist/index.es.js +4049 -3731
  104. package/package.json +5 -56
  105. package/web-types.json +33 -10
  106. package/dist/chunks/detail.ac4d421a.js +0 -28
  107. package/dist/chunks/dic.79d9f595.js +0 -133
  108. package/dist/chunks/slot.1b8d2b1b.js +0 -27
  109. package/dist/chunks/util.80e28481.js +0 -250
  110. package/dist/components/photo-swipe/style.css +0 -1
@@ -1,7 +1,7 @@
1
- import { s as S } from "../../chunks/slot.1b8d2b1b.js";
2
- import { c as h } from "../../chunks/config.46422d7f.js";
3
- import { d as w } from "../../chunks/dataformat.d3fd2d1b.js";
4
- import { o, j as g, d as m } from "../../chunks/util.80e28481.js";
1
+ import { s as S } from "../../chunks/slot.4b391395.js";
2
+ import { c as o } from "../../chunks/config.46422d7f.js";
3
+ import { d as w } from "../../chunks/dataformat.65b92bfe.js";
4
+ import { o as h, j as g, d as m } from "../../chunks/util.23fe58fb.js";
5
5
  import { n as F } from "../../chunks/vueComponentNormalizer.71e2aa87.js";
6
6
  var _ = function() {
7
7
  var e = this, a = e.$createElement, c = e._self._c || a;
@@ -103,12 +103,13 @@ const y = {
103
103
  option() {
104
104
  const e = this.crud.option, a = (t = []) => {
105
105
  t = m(t);
106
- let s = [], u = 0;
106
+ const s = [];
107
+ let u = 0;
107
108
  return t = t.sort((r, l) => (l.searchOrder || 0) - (r.searchOrder || 0)), t.forEach((r) => {
108
109
  if (r.search) {
109
- let l = u < this.searchIndex, d = {};
110
+ const l = u < this.searchIndex, d = {};
110
111
  Object.keys(r).forEach((i) => {
111
- let p = "search";
112
+ const p = "search";
112
113
  if (i != "searchProp" && i.includes(p)) {
113
114
  let n = i.replace(p, "");
114
115
  if (n.length == 0)
@@ -118,11 +119,11 @@ const y = {
118
119
  }), r = Object.assign(r, d, {
119
120
  type: w(r),
120
121
  detail: !1,
121
- dicFlag: r.cascader ? !0 : o(r.dicFlag, !1),
122
- span: r.searchSpan || e.searchSpan || h.searchSpan,
122
+ dicFlag: r.cascader ? !0 : h(r.dicFlag, !1),
123
+ span: r.searchSpan || e.searchSpan || o.searchSpan,
123
124
  control: r.searchControl,
124
- gutter: r.searchGutter || e.searchGutter || h.searchGutter,
125
- labelWidth: r.searchLabelWidth || e.searchLabelWidth || h.searchLabelWidth,
125
+ gutter: r.searchGutter || e.searchGutter || o.searchGutter,
126
+ labelWidth: r.searchLabelWidth || e.searchLabelWidth || o.searchLabelWidth,
126
127
  labelPosition: r.searchLabelPosition || e.searchLabelPosition,
127
128
  size: r.searchSize || e.searchSize,
128
129
  value: r.searchValue,
@@ -150,10 +151,10 @@ const y = {
150
151
  enter: e.searchEnter,
151
152
  size: e.searchSize,
152
153
  submitText: e.searchBtnText || "搜 索",
153
- submitBtn: o(e.searchBtn, h.searchSubBtn),
154
+ submitBtn: h(e.searchBtn, o.searchSubBtn),
154
155
  submitIcon: this.crud.getBtnIcon("searchBtn"),
155
156
  emptyText: e.emptyBtnText || "清 空",
156
- emptyBtn: o(e.emptyBtn, h.emptyBtn),
157
+ emptyBtn: h(e.emptyBtn, o.emptyBtn),
157
158
  emptyIcon: this.crud.getBtnIcon("emptyBtn"),
158
159
  menuSpan: (() => this.show || !this.isSearchIcon || e.searchMenuSpan < 6 ? e.searchMenuSpan : 6)(),
159
160
  menuPosition: e.searchMenuPosition || "center",
@@ -163,7 +164,7 @@ const y = {
163
164
  })(e);
164
165
  },
165
166
  isSearchIcon() {
166
- return o(this.crud.option.searchIcon, this.$AVUE.searchIcon) && this.searchLen > this.searchIndex;
167
+ return h(this.crud.option.searchIcon, this.$AVUE.searchIcon) && this.searchLen > this.searchIndex;
167
168
  },
168
169
  searchLen() {
169
170
  let e = 0;
@@ -226,7 +227,7 @@ const y = {
226
227
  },
227
228
  dataFormat() {
228
229
  const e = this.crud.option;
229
- this.searchShow = o(e.searchShow, h.searchShow);
230
+ this.searchShow = h(e.searchShow, o.searchShow);
230
231
  }
231
232
  }
232
233
  }, f = {};
@@ -0,0 +1,299 @@
1
+ import { w as s } from "../../chunks/util.23fe58fb.js";
2
+ import { VueCropper as a } from "vue-cropper";
3
+ import { n as p } from "../../chunks/vueComponentNormalizer.71e2aa87.js";
4
+ import f from "vue";
5
+ var l = function() {
6
+ var e = this, o = e.$createElement, t = e._self._c || o;
7
+ return t("ElementDialog", {
8
+ staticClass: "avue-cropper",
9
+ attrs: {
10
+ visible: e.visible,
11
+ "before-close": e.cancel,
12
+ title: "图片剪裁",
13
+ "close-on-press-escape": !1,
14
+ "close-on-click-modal": !1,
15
+ "modal-append-to-body": e.$AVUE.modalAppendToBody,
16
+ "append-to-body": e.$AVUE.appendToBody,
17
+ width: "1000px"
18
+ },
19
+ on: {
20
+ "update:visible": function(i) {
21
+ e.visible = i;
22
+ }
23
+ },
24
+ scopedSlots: e._u([{
25
+ key: "footer",
26
+ fn: function() {
27
+ return [t("ElButton", {
28
+ attrs: {
29
+ size: "small",
30
+ type: "primary"
31
+ },
32
+ on: {
33
+ click: e.submit
34
+ }
35
+ }, [e._v(" 确 定 ")]), t("ElButton", {
36
+ attrs: {
37
+ size: "small"
38
+ },
39
+ on: {
40
+ click: function(i) {
41
+ return e.cancel();
42
+ }
43
+ }
44
+ }, [e._v(" 取 消 ")])];
45
+ },
46
+ proxy: !0
47
+ }])
48
+ }, [t("div", {
49
+ staticClass: "cropper-content"
50
+ }, [t("div", {
51
+ staticClass: "cropper-box"
52
+ }, [t("div", {
53
+ staticClass: "cropper"
54
+ }, [t("VueCropper", {
55
+ ref: "cropper",
56
+ attrs: {
57
+ img: e.option.img,
58
+ "output-size": e.option.outputSize,
59
+ "output-type": e.option.outputType,
60
+ info: e.option.info,
61
+ "can-scale": e.option.canScale,
62
+ "auto-crop": e.option.autoCrop,
63
+ "auto-crop-width": e.option.autoCropWidth,
64
+ "auto-crop-height": e.option.autoCropHeight,
65
+ fixed: e.option.fixed,
66
+ "fixed-number": e.option.fixedNumber,
67
+ full: e.option.full,
68
+ "fixed-box": e.option.fixedBox,
69
+ "can-move": e.option.canMove,
70
+ "can-move-box": e.option.canMoveBox,
71
+ original: e.option.original,
72
+ "center-box": e.option.centerBox,
73
+ height: e.option.height,
74
+ "info-true": e.option.infoTrue,
75
+ "max-img-size": e.option.maxImgSize,
76
+ enlarge: e.option.enlarge,
77
+ mode: e.option.mode
78
+ },
79
+ on: {
80
+ realTime: e.realTime
81
+ }
82
+ })], 1), t("div", {
83
+ staticClass: "footer-btn"
84
+ }, [t("ElButton", {
85
+ attrs: {
86
+ size: "mini",
87
+ type: "danger",
88
+ icon: "el-icon-zoom-in"
89
+ },
90
+ on: {
91
+ click: function(i) {
92
+ return e.changeScale(1);
93
+ }
94
+ }
95
+ }), t("ElButton", {
96
+ attrs: {
97
+ size: "mini",
98
+ type: "danger",
99
+ icon: "el-icon-zoom-out"
100
+ },
101
+ on: {
102
+ click: function(i) {
103
+ return e.changeScale(-1);
104
+ }
105
+ }
106
+ }), t("ElButton", {
107
+ attrs: {
108
+ size: "mini",
109
+ icon: "el-icon-back",
110
+ type: "danger"
111
+ },
112
+ on: {
113
+ click: e.rotateLeft
114
+ }
115
+ }), t("ElButton", {
116
+ attrs: {
117
+ size: "mini",
118
+ type: "danger",
119
+ icon: "el-icon-right"
120
+ },
121
+ on: {
122
+ click: e.rotateRight
123
+ }
124
+ })], 1)]), t("div", {
125
+ staticClass: "show-preview"
126
+ }, [t("div", {
127
+ staticClass: "preview",
128
+ style: e.previews.div
129
+ }, [t("img", {
130
+ style: e.previews.img,
131
+ attrs: {
132
+ src: e.previews.url,
133
+ alt: ""
134
+ }
135
+ })])])])]);
136
+ }, c = [];
137
+ const h = {
138
+ name: "ImageCropper",
139
+ imageCropper: u,
140
+ components: {
141
+ VueCropper: a
142
+ },
143
+ data() {
144
+ return {
145
+ visible: !1,
146
+ previews: {},
147
+ option: {}
148
+ };
149
+ },
150
+ methods: {
151
+ show() {
152
+ this.visible = !0;
153
+ },
154
+ // 图片缩放
155
+ changeScale(e) {
156
+ e = e || 1, this.$refs.cropper.changeScale(e);
157
+ },
158
+ // 向左旋转
159
+ rotateLeft() {
160
+ this.$refs.cropper.rotateLeft();
161
+ },
162
+ // 向右旋转
163
+ rotateRight() {
164
+ this.$refs.cropper.rotateRight();
165
+ },
166
+ // 实时预览函数
167
+ realTime(e) {
168
+ this.previews = e;
169
+ },
170
+ submit() {
171
+ this.visible = !1, this.$refs.cropper.getCropData((e) => {
172
+ let o = e;
173
+ this.option.type === "file" && (o = s(e, `${new Date().getTime()}.${this.option.outputType}`)), this.option.callback && this.option.callback(o);
174
+ });
175
+ },
176
+ cancel(e) {
177
+ e && e(), this.visible = !1, this.option.cancel && this.option.cancel(), typeof this.option.beforeClose == "function" && this.option.beforeClose(), this.$destroy(), this.$el.remove();
178
+ }
179
+ }
180
+ }, n = {};
181
+ var m = /* @__PURE__ */ p(
182
+ h,
183
+ l,
184
+ c,
185
+ !1,
186
+ v,
187
+ null,
188
+ null,
189
+ null
190
+ );
191
+ function v(e) {
192
+ for (let o in n)
193
+ this[o] = n[o];
194
+ }
195
+ const d = /* @__PURE__ */ function() {
196
+ return m.exports;
197
+ }(), u = (e = {}) => {
198
+ const o = f.extend(d), t = {
199
+ outputSize: 1,
200
+ // 裁剪生成图片的质量(可选0.1 - 1)
201
+ outputType: "jpeg",
202
+ // 裁剪生成图片的格式(jpeg || png || webp)
203
+ info: !0,
204
+ // 图片大小信息
205
+ canScale: !0,
206
+ // 图片是否允许滚轮缩放
207
+ autoCrop: !0,
208
+ // 是否默认生成截图框
209
+ fixed: !1,
210
+ // 是否开启截图框宽高固定比例
211
+ full: !1,
212
+ // false按原比例裁切图片,不失真
213
+ fixedBox: !1,
214
+ // 固定截图框大小,不允许改变
215
+ canMove: !0,
216
+ // 上传图片是否可以移动
217
+ canMoveBox: !0,
218
+ // 截图框能否拖动
219
+ original: !1,
220
+ // 上传图片按照原始比例渲染
221
+ centerBox: !1,
222
+ // 截图框是否被限制在图片里面
223
+ height: !0,
224
+ // 是否按照设备的dpr 输出等比例图片
225
+ infoTrue: !1,
226
+ // true为展示真实输出图片宽高,false展示看到的截图框宽高
227
+ enlarge: 1,
228
+ // 图片根据截图框输出比例倍数
229
+ ...e
230
+ }, i = new o({
231
+ data: {
232
+ option: t
233
+ }
234
+ });
235
+ return i.$mount(), document.body.appendChild(i.$el), i.show(), i;
236
+ }, g = {
237
+ name: "ImageCropper",
238
+ imageCropper: u,
239
+ components: {
240
+ VueCropper: a
241
+ },
242
+ data() {
243
+ return {
244
+ visible: !1,
245
+ previews: {},
246
+ option: {}
247
+ };
248
+ },
249
+ methods: {
250
+ show() {
251
+ this.visible = !0;
252
+ },
253
+ // 图片缩放
254
+ changeScale(e) {
255
+ e = e || 1, this.$refs.cropper.changeScale(e);
256
+ },
257
+ // 向左旋转
258
+ rotateLeft() {
259
+ this.$refs.cropper.rotateLeft();
260
+ },
261
+ // 向右旋转
262
+ rotateRight() {
263
+ this.$refs.cropper.rotateRight();
264
+ },
265
+ // 实时预览函数
266
+ realTime(e) {
267
+ this.previews = e;
268
+ },
269
+ submit() {
270
+ this.visible = !1, this.$refs.cropper.getCropData((e) => {
271
+ let o = e;
272
+ this.option.type === "file" && (o = s(e, `${new Date().getTime()}.${this.option.outputType}`)), this.option.callback && this.option.callback(o);
273
+ });
274
+ },
275
+ cancel(e) {
276
+ e && e(), this.visible = !1, this.option.cancel && this.option.cancel(), typeof this.option.beforeClose == "function" && this.option.beforeClose(), this.$destroy(), this.$el.remove();
277
+ }
278
+ }
279
+ }, r = {};
280
+ var _ = /* @__PURE__ */ p(
281
+ g,
282
+ l,
283
+ c,
284
+ !1,
285
+ b,
286
+ null,
287
+ null,
288
+ null
289
+ );
290
+ function b(e) {
291
+ for (let o in r)
292
+ this[o] = r[o];
293
+ }
294
+ const w = /* @__PURE__ */ function() {
295
+ return _.exports;
296
+ }();
297
+ export {
298
+ w as default
299
+ };
@@ -0,0 +1 @@
1
+ .avue-cropper .cropper-content{display:flex;justify-content:flex-end}.avue-cropper .cropper-content .cropper-box{flex:1;width:100%}.avue-cropper .cropper-content .cropper-box .cropper{width:auto;height:300px}.avue-cropper .cropper-content .show-preview{flex:1;display:flex;justify-content:center}.avue-cropper .cropper-content .show-preview .preview{overflow:hidden;border:1px solid #67c23a;background:#cccccc}.avue-cropper .cropper-content .footer-btn{margin-top:30px;display:flex;justify-content:center;padding-right:10px}