@web-utils/component 2.0.13 → 2.0.14

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 (172) hide show
  1. package/dist/chunks/3a79781b.js +75 -0
  2. package/dist/chunks/{44b78389.js → 41a066be.js} +8 -8
  3. package/dist/chunks/{e1939731.js → 5a78e0db.js} +5 -6
  4. package/dist/chunks/5d4282fb.js +30 -0
  5. package/dist/chunks/{822300f3.js → 61ad06b2.js} +3 -3
  6. package/dist/chunks/76680a03.js +24 -0
  7. package/dist/chunks/8c0142e0.js +81 -0
  8. package/dist/chunks/97652d86.js +26 -0
  9. package/dist/chunks/b4acd3a6.js +126 -0
  10. package/dist/chunks/f71045fc.js +184 -0
  11. package/dist/components/address-input/index.js +43 -56
  12. package/dist/components/address-input/style.css +1 -15
  13. package/dist/components/aside-menu/index.js +30 -36
  14. package/dist/components/aside-menu/style.css +1 -9
  15. package/dist/components/awesome-button/index.js +32 -35
  16. package/dist/components/base.css +1 -66
  17. package/dist/components/capsule-tab/index.js +27 -33
  18. package/dist/components/capsule-tab/style.css +1 -32
  19. package/dist/components/chunk-file-uploader/index.js +54 -88
  20. package/dist/components/chunk-file-uploader/style.css +1 -4
  21. package/dist/components/chunk-file-uploader-button/index.js +25 -31
  22. package/dist/components/chunk-file-uploader-button/style.css +1 -17
  23. package/dist/components/chunk-file-uploader-drop/index.js +28 -42
  24. package/dist/components/chunk-file-uploader-drop/style.css +1 -12
  25. package/dist/components/chunk-file-uploader-file/index.js +134 -211
  26. package/dist/components/chunk-file-uploader-file/style.css +1 -125
  27. package/dist/components/chunk-file-uploader-files/index.js +28 -34
  28. package/dist/components/chunk-file-uploader-files/style.css +1 -9
  29. package/dist/components/chunk-file-uploader-list/index.js +29 -35
  30. package/dist/components/chunk-file-uploader-list/style.css +1 -9
  31. package/dist/components/chunk-file-uploader-un-support/index.js +30 -38
  32. package/dist/components/chunk-file-uploader-un-support/style.css +1 -6
  33. package/dist/components/code-mirror-editor/index.js +153 -181
  34. package/dist/components/code-mirror-editor/style.css +1 -17
  35. package/dist/components/color-picker/index.js +49 -68
  36. package/dist/components/confirm-button/index.js +19 -21
  37. package/dist/components/confirmable/index.js +18 -19
  38. package/dist/components/context-menu/index.js +108 -130
  39. package/dist/components/context-menu/style.css +1 -88
  40. package/dist/components/custom-scrollbar/index.js +49 -67
  41. package/dist/components/data-table-picker/index.js +62 -81
  42. package/dist/components/dynamic-table/index.js +89 -113
  43. package/dist/components/dynamic-table/style.css +1 -30
  44. package/dist/components/e-charts/index.js +120 -201
  45. package/dist/components/e-charts/style.css +1 -10
  46. package/dist/components/editable-progress/index.js +60 -93
  47. package/dist/components/editable-progress/style.css +1 -37
  48. package/dist/components/editable-tree/index.js +423 -638
  49. package/dist/components/editable-tree/style.css +1 -82
  50. package/dist/components/egd-collapse/index.js +33 -46
  51. package/dist/components/egd-collapse-item/index.js +60 -76
  52. package/dist/components/element-dialog/index.js +95 -147
  53. package/dist/components/element-dialog/style.css +1 -102
  54. package/dist/components/empty-view/index.js +28 -34
  55. package/dist/components/empty-view/style.css +1 -17
  56. package/dist/components/error-view/index.js +26 -32
  57. package/dist/components/error-view/style.css +1 -17
  58. package/dist/components/flex-column/index.js +25 -40
  59. package/dist/components/flex-item/index.js +29 -57
  60. package/dist/components/flex-row/index.js +25 -40
  61. package/dist/components/flex-scroller/index.js +26 -32
  62. package/dist/components/flex-scroller/style.css +1 -20
  63. package/dist/components/form-button/index.js +34 -38
  64. package/dist/components/form-cascader/index.js +71 -81
  65. package/dist/components/form-checkbox-group/index.js +88 -113
  66. package/dist/components/form-checkbox-group/style.css +1 -51
  67. package/dist/components/form-date-picker/index.js +70 -132
  68. package/dist/components/form-holder/index.js +32 -39
  69. package/dist/components/form-input/index.js +56 -62
  70. package/dist/components/form-input-email/index.js +48 -60
  71. package/dist/components/form-input-id-card/index.js +53 -59
  72. package/dist/components/form-input-number/index.js +61 -68
  73. package/dist/components/form-input-number/style.css +1 -12
  74. package/dist/components/form-input-phone-number/index.js +49 -55
  75. package/dist/components/form-input-time/index.js +53 -59
  76. package/dist/components/form-item/index.js +80 -123
  77. package/dist/components/form-item/style.css +1 -11
  78. package/dist/components/form-item-config-provider/index.js +25 -26
  79. package/dist/components/form-item-group/index.js +85 -111
  80. package/dist/components/form-item-group/style.css +1 -30
  81. package/dist/components/form-radio-group/index.js +85 -104
  82. package/dist/components/form-radio-group/style.css +1 -53
  83. package/dist/components/form-select/index.js +76 -91
  84. package/dist/components/form-switch/index.js +51 -57
  85. package/dist/components/form-textarea/index.js +51 -57
  86. package/dist/components/form-view/index.js +165 -232
  87. package/dist/components/form-view/style.css +1 -158
  88. package/dist/components/guide-steps/index.js +44 -58
  89. package/dist/components/guide-steps/style.css +1 -34
  90. package/dist/components/icon-card/index.js +29 -35
  91. package/dist/components/icon-card/style.css +1 -56
  92. package/dist/components/iframe-window/index.js +29 -35
  93. package/dist/components/iframe-window/style.css +1 -20
  94. package/dist/components/image-viewer/index.js +48 -66
  95. package/dist/components/image-viewer/style.css +1 -21
  96. package/dist/components/input-number/index.js +127 -193
  97. package/dist/components/input-number/style.css +1 -15
  98. package/dist/components/input-number-range/index.js +45 -57
  99. package/dist/components/input-number-range/style.css +1 -12
  100. package/dist/components/j-s-x-component/index.js +4 -4
  101. package/dist/components/keep-view-alive/index.js +73 -120
  102. package/dist/components/loading-view/index.js +26 -32
  103. package/dist/components/loading-view/style.css +1 -17
  104. package/dist/components/nav-bar/index.js +27 -37
  105. package/dist/components/nav-bar/style.css +1 -17
  106. package/dist/components/not-implement/index.js +23 -31
  107. package/dist/components/not-implement/style.css +1 -15
  108. package/dist/components/page/index.js +22 -28
  109. package/dist/components/page/style.css +1 -12
  110. package/dist/components/page-header/index.js +30 -36
  111. package/dist/components/page-header/style.css +1 -14
  112. package/dist/components/page-index/index.js +62 -83
  113. package/dist/components/page-index/style.css +1 -23
  114. package/dist/components/page-index-top/index.js +53 -68
  115. package/dist/components/page-skeleton/index.js +31 -37
  116. package/dist/components/page-skeleton/style.css +1 -23
  117. package/dist/components/page-skeleton-new/index.js +42 -48
  118. package/dist/components/page-skeleton-new/style.css +1 -42
  119. package/dist/components/pageable-table/index.js +186 -253
  120. package/dist/components/pageable-table/style.css +1 -72
  121. package/dist/components/pageable-view/index.js +129 -199
  122. package/dist/components/pageable-view/style.css +1 -69
  123. package/dist/components/photo-swipe/index.js +110 -151
  124. package/dist/components/photo-swipe/style.css +1 -20
  125. package/dist/components/resize-observer/index.js +34 -68
  126. package/dist/components/resize-observer/style.css +1 -31
  127. package/dist/components/search-popover/index.js +153 -211
  128. package/dist/components/search-popover/style.css +1 -93
  129. package/dist/components/sign-panel/index.js +92 -142
  130. package/dist/components/sign-panel/style.css +1 -97
  131. package/dist/components/split-pane/index.js +101 -162
  132. package/dist/components/split-pane/style.css +1 -100
  133. package/dist/components/stateful/index.js +31 -34
  134. package/dist/components/stateful/style.css +1 -33
  135. package/dist/components/static-pageable-table/index.js +37 -44
  136. package/dist/components/static-pageable-table/style.css +1 -9
  137. package/dist/components/swiper/index.js +85 -150
  138. package/dist/components/swiper/style.css +1 -43
  139. package/dist/components/tab/index.js +54 -72
  140. package/dist/components/tab/style.css +1 -122
  141. package/dist/components/tab-item/index.js +30 -35
  142. package/dist/components/table-column/index.js +30 -32
  143. package/dist/components/table-view/index.js +156 -227
  144. package/dist/components/table-view/style.css +1 -95
  145. package/dist/components/tag-render/index.js +44 -58
  146. package/dist/components/tag-render/style.css +1 -33
  147. package/dist/components/tinymce-editor/index.js +79 -95
  148. package/dist/components/tinymce-editor/style.css +1 -43
  149. package/dist/components/tinymce-wrapper/index.js +92 -121
  150. package/dist/components/tinymce-wrapper/style.css +1 -36
  151. package/dist/components/toolbar/index.js +63 -84
  152. package/dist/components/toolbar/style.css +1 -39
  153. package/dist/components/toolbar-button/index.js +41 -48
  154. package/dist/components/toolbar-button/style.css +1 -21
  155. package/dist/components/trigger/index.js +29 -36
  156. package/dist/components/vue-tags-input/index.js +188 -308
  157. package/dist/components/vue-tags-input/style.css +1 -682
  158. package/dist/components/watermark/index.js +25 -37
  159. package/dist/components/watermark/style.css +1 -11
  160. package/dist/components/x-dialog/index.js +67 -93
  161. package/dist/components/x-dialog/style.css +1 -15
  162. package/dist/index.css +193 -1105
  163. package/dist/index.es.js +4790 -7243
  164. package/package.json +1 -1
  165. package/web-types.json +1 -1
  166. package/dist/chunks/3d28cc08.js +0 -57
  167. package/dist/chunks/5d33812d.js +0 -147
  168. package/dist/chunks/9d848bf6.js +0 -99
  169. package/dist/chunks/a0bb327b.js +0 -96
  170. package/dist/chunks/a8891d2c.js +0 -30
  171. package/dist/chunks/c69d5628.js +0 -248
  172. package/dist/chunks/de9fe802.js +0 -24
@@ -1,108 +1,102 @@
1
- import { fastClone, validateNumber, validateIdCard, validatePhoneNum } from "@web-utils/core";
2
- import { n as normalizeComponent } from "../../chunks/3d28cc08.js";
3
- var render = function() {
4
- var _vm = this;
5
- var _h = _vm.$createElement;
6
- var _c = _vm._self._c || _h;
7
- return _c("div", {
1
+ import { fastClone as u, validateNumber as d, validateIdCard as c, validatePhoneNum as m } from "@web-utils/core";
2
+ import { n as f } from "../../chunks/5d4282fb.js";
3
+ var h = function() {
4
+ var e = this, i = e.$createElement, t = e._self._c || i;
5
+ return t("div", {
8
6
  staticClass: "dynamic-table"
9
- }, [_c("ElTable", {
10
- key: _vm.key,
7
+ }, [t("ElTable", {
8
+ key: e.key,
11
9
  staticStyle: {
12
- "width": "100%"
10
+ width: "100%"
13
11
  },
14
12
  attrs: {
15
- "data": _vm.value
13
+ data: e.value
16
14
  }
17
- }, [_vm._l(_vm.columns, function(column) {
18
- return _c("ElTableColumn", {
19
- key: column.prop,
15
+ }, [e._l(e.columns, function(a) {
16
+ return t("ElTableColumn", {
17
+ key: a.prop,
20
18
  attrs: {
21
- "prop": column.prop,
22
- "label": column.label,
19
+ prop: a.prop,
20
+ label: a.label,
23
21
  "min-width": "150"
24
22
  },
25
- scopedSlots: _vm._u([{
23
+ scopedSlots: e._u([{
26
24
  key: "default",
27
- fn: function(_ref) {
28
- var row = _ref.row, $index = _ref.$index;
29
- return [_c("ElFormItem", {
25
+ fn: function(l) {
26
+ var n = l.row, r = l.$index;
27
+ return [t("ElFormItem", {
30
28
  style: {
31
- marginBottom: _vm.inputDisabled ? "0px" : "16px"
29
+ marginBottom: e.inputDisabled ? "0px" : "16px"
32
30
  },
33
31
  attrs: {
34
- "prop": `${_vm.prop}.${$index}.${column.prop}`,
35
- "size": "mini",
36
- "rules": _vm.getRules(column)
32
+ prop: `${e.prop}.${r}.${a.prop}`,
33
+ size: "mini",
34
+ rules: e.getRules(a)
37
35
  }
38
- }, [_c("ElInput", {
36
+ }, [t("ElInput", {
39
37
  attrs: {
40
- "prefix-icon": _vm.getIcon(column),
41
- "disabled": _vm.inputDisabled,
42
- "placeholder": _vm.inputDisabled ? "" : `请输入${column.label}!`
38
+ "prefix-icon": e.getIcon(a),
39
+ disabled: e.inputDisabled,
40
+ placeholder: e.inputDisabled ? "" : `请输入${a.label}!`
43
41
  },
44
42
  model: {
45
- value: row[column.prop],
46
- callback: function($$v) {
47
- _vm.$set(row, column.prop, $$v);
43
+ value: n[a.prop],
44
+ callback: function(s) {
45
+ e.$set(n, a.prop, s);
48
46
  },
49
47
  expression: "row[column.prop]"
50
48
  }
51
49
  })], 1)];
52
50
  }
53
- }], null, true)
51
+ }], null, !0)
54
52
  });
55
- }), !_vm.inputDisabled ? _c("ElTableColumn", {
53
+ }), e.inputDisabled ? e._e() : t("ElTableColumn", {
56
54
  attrs: {
57
- "label": "操作",
58
- "width": "60",
59
- "fixed": "right"
55
+ label: "操作",
56
+ width: "60",
57
+ fixed: "right"
60
58
  },
61
- scopedSlots: _vm._u([{
59
+ scopedSlots: e._u([{
62
60
  key: "default",
63
- fn: function(_ref2) {
64
- var row = _ref2.row, column = _ref2.column, $index = _ref2.$index;
65
- return [_c("i", {
61
+ fn: function(a) {
62
+ var l = a.row, n = a.column, r = a.$index;
63
+ return [t("i", {
66
64
  staticClass: "el-icon-minus dynamic-table-action-icon",
67
65
  staticStyle: {
68
- "position": "relative",
69
- "top": "-8px",
70
- "color": "#f00"
66
+ position: "relative",
67
+ top: "-8px",
68
+ color: "#f00"
71
69
  },
72
70
  attrs: {
73
- "title": "删除"
71
+ title: "删除"
74
72
  },
75
73
  on: {
76
- "click": function($event) {
77
- $event.stopPropagation();
78
- return _vm.removeRow(row, $index, column);
74
+ click: function(s) {
75
+ return s.stopPropagation(), e.removeRow(l, r, n);
79
76
  }
80
77
  }
81
78
  })];
82
79
  }
83
- }], null, false, 410881950)
84
- }) : _vm._e()], 2), !_vm.inputDisabled ? _c("ElButton", {
80
+ }], null, !1, 410881950)
81
+ })], 2), e.inputDisabled ? e._e() : t("ElButton", {
85
82
  staticStyle: {
86
- "color": "#08c108"
83
+ color: "#08c108"
87
84
  },
88
85
  attrs: {
89
- "type": "text",
90
- "icon": "el-icon-plus"
86
+ type: "text",
87
+ icon: "el-icon-plus"
91
88
  },
92
89
  on: {
93
- "click": _vm.addRow
90
+ click: e.addRow
94
91
  }
95
- }, [_vm._v(" 添加 ")]) : _vm._e()], 1);
96
- };
97
- var staticRenderFns = [];
98
- const DynamicTable_vue_vue_type_style_index_0_lang = "";
99
- const icons = {
92
+ }, [e._v(" 添加 ")])], 1);
93
+ }, y = [];
94
+ const o = {
100
95
  number: "fa fa-superscript",
101
96
  email: "el-icon-lx-mail",
102
97
  phone: "fa fa-phone",
103
98
  idCard: "el-icon-lx-news"
104
- };
105
- const __vue2_script = {
99
+ }, v = {
106
100
  name: "DynamicTable",
107
101
  inject: {
108
102
  elForm: {
@@ -139,81 +133,63 @@ const __vue2_script = {
139
133
  },
140
134
  watch: {
141
135
  value: {
142
- deep: true,
143
- handler(newVal) {
144
- this.$emit("input", newVal);
136
+ deep: !0,
137
+ handler(e) {
138
+ this.$emit("input", e);
145
139
  }
146
140
  },
147
141
  columns: {
148
- deep: true,
142
+ deep: !0,
149
143
  handler() {
150
144
  this.key++;
151
145
  }
152
146
  }
153
147
  },
154
148
  methods: {
155
- getIcon(column) {
156
- return icons[column.type] ? icons[column.type] : "";
149
+ getIcon(e) {
150
+ return o[e.type] ? o[e.type] : "";
157
151
  },
158
152
  addRow() {
159
- const value = this.value;
160
- value.push(this.newRow());
161
- this.$emit("input", value);
153
+ const e = this.value;
154
+ e.push(this.newRow()), this.$emit("input", e);
162
155
  },
163
- removeRow(row, index) {
164
- const value = this.value;
165
- value.splice(index, 1);
166
- this.$emit("input", value);
156
+ removeRow(e, i) {
157
+ const t = this.value;
158
+ t.splice(i, 1), this.$emit("input", t);
167
159
  },
168
160
  newRow() {
169
- const row = {};
170
- this.columns.forEach((value) => {
171
- row[value.prop] = void 0;
172
- });
173
- return row;
161
+ const e = {};
162
+ return this.columns.forEach((i) => {
163
+ e[i.prop] = void 0;
164
+ }), e;
174
165
  },
175
- getRules(column) {
176
- const userRules = column.rules;
177
- if (["email", "idCard", "phone", "number"].includes(column.type)) {
178
- const rules = fastClone(userRules || []);
179
- if (column.type === "number") {
180
- rules.push({ validator: validateNumber, message: "请输入数字!" });
181
- }
182
- if (column.type === "email") {
183
- rules.push({ type: "email", message: "请输入正确的邮箱地址!" });
184
- }
185
- if (column.type === "idCard") {
186
- rules.push({ validator: validateIdCard, message: "请输入正确的身份证号码!" });
187
- }
188
- if (column.type === "phone") {
189
- rules.push({ validator: validatePhoneNum, message: "请输入正确的手机号码!" });
190
- }
191
- return rules;
192
- } else {
193
- return userRules;
194
- }
166
+ getRules(e) {
167
+ const i = e.rules;
168
+ if (["email", "idCard", "phone", "number"].includes(e.type)) {
169
+ const t = u(i || []);
170
+ return e.type === "number" && t.push({ validator: d, message: "请输入数字!" }), e.type === "email" && t.push({ type: "email", message: "请输入正确的邮箱地址!" }), e.type === "idCard" && t.push({ validator: c, message: "请输入正确的身份证号码!" }), e.type === "phone" && t.push({ validator: m, message: "请输入正确的手机号码!" }), t;
171
+ } else
172
+ return i;
195
173
  }
196
174
  }
197
- };
198
- const __cssModules = {};
199
- var __component__ = /* @__PURE__ */ normalizeComponent(
200
- __vue2_script,
201
- render,
202
- staticRenderFns,
203
- false,
204
- __vue2_injectStyles,
175
+ }, p = {};
176
+ var b = /* @__PURE__ */ f(
177
+ v,
178
+ h,
179
+ y,
180
+ !1,
181
+ _,
205
182
  null,
206
183
  null,
207
184
  null
208
185
  );
209
- function __vue2_injectStyles(context) {
210
- for (let o in __cssModules) {
211
- this[o] = __cssModules[o];
212
- }
186
+ function _(e) {
187
+ for (let i in p)
188
+ this[i] = p[i];
213
189
  }
214
- const DynamicTable = /* @__PURE__ */ function() {
215
- return __component__.exports;
190
+ const g = /* @__PURE__ */ function() {
191
+ return b.exports;
216
192
  }();
217
193
  export {
218
- DynamicTable as default
194
+ g as default
219
195
  };
@@ -1,30 +1 @@
1
- /* 全局公共颜色配置 */ /* 全局公共尺寸配置 */
2
- /* 应用头部高度 */
3
- /* 页面宽度 */
4
- /* 侧栏宽度 */
5
- /* 标签高度 */
6
- /* 页面头部工具条高度 */
7
- .dynamic-table {
8
- display: flex;
9
- flex-direction: column;
10
- align-items: center;
11
- width: 100%;
12
- }
13
- .dynamic-table .dynamic-table-action-icon {
14
- margin-left: 10px;
15
- font-weight: bold;
16
- cursor: pointer;
17
- }
18
- .dynamic-table .el-form-item {
19
- margin-bottom: 0;
20
- }
21
- .dynamic-table .el-table {
22
- flex: 1 1 auto;
23
- }
24
- .dynamic-table .el-table td {
25
- padding: 2px 0;
26
- }
27
- .dynamic-table .el-input.is-disabled .el-input__inner {
28
- background-color: transparent;
29
- border: none;
30
- }
1
+ .dynamic-table{display:flex;flex-direction:column;align-items:center;width:100%}.dynamic-table .dynamic-table-action-icon{margin-left:10px;font-weight:700;cursor:pointer}.dynamic-table .el-form-item{margin-bottom:0}.dynamic-table .el-table{flex:1 1 auto}.dynamic-table .el-table td{padding:2px 0}.dynamic-table .el-input.is-disabled .el-input__inner{background-color:transparent;border:none}