@web-utils/component 2.0.13 → 2.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunks/config.46422d7f.js +73 -0
- package/dist/chunks/confirmable-mixin.3a79781b.js +75 -0
- package/dist/chunks/dataformat.fb35ee10.js +61 -0
- package/dist/chunks/detail.a3249549.js +28 -0
- package/dist/chunks/dic.5f7e3523.js +132 -0
- package/dist/chunks/event.50c365eb.js +235 -0
- package/dist/chunks/form-input-mixin.ff5b58f7.js +24 -0
- package/dist/chunks/form-item-mixin.79f6eaff.js +128 -0
- package/dist/chunks/{822300f3.js → form-pick-mixin.61ad06b2.js} +3 -3
- package/dist/chunks/init.352281f5.js +121 -0
- package/dist/chunks/{44b78389.js → input-number-mixin.41a066be.js} +8 -8
- package/dist/chunks/{e1939731.js → mixins.5a78e0db.js} +5 -6
- package/dist/chunks/packages.5d7a86c4.js +114 -0
- package/dist/chunks/permission.ce5d2121.js +16 -0
- package/dist/chunks/slot.1b8d2b1b.js +27 -0
- package/dist/chunks/tab-mixin.8c0142e0.js +81 -0
- package/dist/chunks/util.5053d54e.js +264 -0
- package/dist/chunks/utils.97652d86.js +26 -0
- package/dist/chunks/utils.fa73de78.js +185 -0
- package/dist/chunks/vueComponentNormalizer.71e2aa87.js +32 -0
- package/dist/components/address-input/index.js +43 -56
- package/dist/components/address-input/style.css +1 -15
- package/dist/components/affix/index.js +102 -0
- package/dist/components/affix/style.css +1 -0
- package/dist/components/array/index.js +156 -0
- package/dist/components/array/style.css +1 -0
- package/dist/components/article/index.js +93 -0
- package/dist/components/article/style.css +1 -0
- package/dist/components/aside-menu/index.js +30 -36
- package/dist/components/aside-menu/style.css +1 -9
- package/dist/components/avatar/index.js +106 -0
- package/dist/components/avatar/style.css +1 -0
- package/dist/components/awesome-button/index.js +32 -35
- package/dist/components/base.css +1 -66
- package/dist/components/capsule-tab/index.js +27 -33
- package/dist/components/capsule-tab/style.css +1 -32
- package/dist/components/card/index.js +130 -0
- package/dist/components/card/style.css +1 -0
- package/dist/components/carousel/index.js +70 -0
- package/dist/components/carousel/style.css +1 -0
- package/dist/components/chat/index.js +567 -0
- package/dist/components/chat/style.css +1 -0
- package/dist/components/chunk-file-uploader/index.js +54 -88
- package/dist/components/chunk-file-uploader/style.css +1 -4
- package/dist/components/chunk-file-uploader-button/index.js +25 -31
- package/dist/components/chunk-file-uploader-button/style.css +1 -17
- package/dist/components/chunk-file-uploader-drop/index.js +28 -42
- package/dist/components/chunk-file-uploader-drop/style.css +1 -12
- package/dist/components/chunk-file-uploader-file/index.js +134 -211
- package/dist/components/chunk-file-uploader-file/style.css +1 -125
- package/dist/components/chunk-file-uploader-files/index.js +28 -34
- package/dist/components/chunk-file-uploader-files/style.css +1 -9
- package/dist/components/chunk-file-uploader-list/index.js +29 -35
- package/dist/components/chunk-file-uploader-list/style.css +1 -9
- package/dist/components/chunk-file-uploader-un-support/index.js +30 -38
- package/dist/components/chunk-file-uploader-un-support/style.css +1 -6
- package/dist/components/code/index.js +66 -0
- package/dist/components/code-mirror-editor/index.js +156 -181
- package/dist/components/code-mirror-editor/style.css +1 -17
- package/dist/components/color-picker/index.js +49 -68
- package/dist/components/column/index.js +114 -0
- package/dist/components/column-default/index.js +105 -0
- package/dist/components/column-dynamic/index.js +93 -0
- package/dist/components/column-menu/index.js +286 -0
- package/dist/components/column-slot/index.js +265 -0
- package/dist/components/comment/index.js +94 -0
- package/dist/components/comment/style.css +1 -0
- package/dist/components/confirm-button/index.js +19 -21
- package/dist/components/confirmable/index.js +18 -19
- package/dist/components/context-menu/index.js +118 -130
- package/dist/components/context-menu/style.css +1 -88
- package/dist/components/count-up/index.js +120 -0
- package/dist/components/custom-scrollbar/index.js +50 -68
- package/dist/components/data-box/index.js +97 -0
- package/dist/components/data-box/style.css +1 -0
- package/dist/components/data-card/index.js +98 -0
- package/dist/components/data-card/style.css +1 -0
- package/dist/components/data-cardtext/index.js +82 -0
- package/dist/components/data-cardtext/style.css +1 -0
- package/dist/components/data-display/index.js +93 -0
- package/dist/components/data-display/style.css +1 -0
- package/dist/components/data-icons/index.js +104 -0
- package/dist/components/data-icons/style.css +1 -0
- package/dist/components/data-imgtext/index.js +106 -0
- package/dist/components/data-imgtext/style.css +1 -0
- package/dist/components/data-operatext/index.js +99 -0
- package/dist/components/data-operatext/style.css +1 -0
- package/dist/components/data-panel/index.js +93 -0
- package/dist/components/data-panel/style.css +1 -0
- package/dist/components/data-pay/index.js +149 -0
- package/dist/components/data-pay/style.css +1 -0
- package/dist/components/data-price/index.js +84 -0
- package/dist/components/data-price/style.css +1 -0
- package/dist/components/data-progress/index.js +97 -0
- package/dist/components/data-progress/style.css +1 -0
- package/dist/components/data-rotate/index.js +96 -0
- package/dist/components/data-rotate/style.css +1 -0
- package/dist/components/data-table-picker/index.js +62 -81
- package/dist/components/data-tabs/index.js +94 -0
- package/dist/components/data-tabs/style.css +1 -0
- package/dist/components/dialog-column/index.js +138 -0
- package/dist/components/dialog-excel/index.js +214 -0
- package/dist/components/dialog-filter/index.js +245 -0
- package/dist/components/dialog-form/index.js +275 -0
- package/dist/components/draggable/index.js +384 -0
- package/dist/components/draggable/style.css +1 -0
- package/dist/components/dynamic-table/index.js +89 -113
- package/dist/components/dynamic-table/style.css +1 -30
- package/dist/components/e-charts/index.js +126 -201
- package/dist/components/e-charts/style.css +1 -10
- package/dist/components/editable-progress/index.js +60 -93
- package/dist/components/editable-progress/style.css +1 -37
- package/dist/components/editable-tree/index.js +423 -638
- package/dist/components/editable-tree/style.css +1 -82
- package/dist/components/egd-collapse/index.js +33 -46
- package/dist/components/egd-collapse-item/index.js +60 -76
- package/dist/components/element-dialog/index.js +95 -147
- package/dist/components/element-dialog/style.css +1 -102
- package/dist/components/empty/index.js +59 -0
- package/dist/components/empty/style.css +1 -0
- package/dist/components/empty-view/index.js +28 -34
- package/dist/components/empty-view/style.css +1 -17
- package/dist/components/error-view/index.js +26 -32
- package/dist/components/error-view/style.css +1 -17
- package/dist/components/flex-column/index.js +25 -40
- package/dist/components/flex-item/index.js +29 -57
- package/dist/components/flex-row/index.js +25 -40
- package/dist/components/flex-scroller/index.js +26 -32
- package/dist/components/flex-scroller/style.css +1 -20
- package/dist/components/flow/index.js +278 -0
- package/dist/components/flow/style.css +1 -0
- package/dist/components/flow-node/index.js +102 -0
- package/dist/components/form-button/index.js +34 -38
- package/dist/components/form-cascader/index.js +71 -81
- package/dist/components/form-checkbox-group/index.js +88 -113
- package/dist/components/form-checkbox-group/style.css +1 -51
- package/dist/components/form-date-picker/index.js +70 -132
- package/dist/components/form-group/index.js +122 -0
- package/dist/components/form-group/style.css +1 -0
- package/dist/components/form-holder/index.js +53 -39
- package/dist/components/form-input/index.js +56 -62
- package/dist/components/form-input-email/index.js +48 -60
- package/dist/components/form-input-id-card/index.js +53 -59
- package/dist/components/form-input-number/index.js +61 -68
- package/dist/components/form-input-number/style.css +1 -12
- package/dist/components/form-input-phone-number/index.js +49 -55
- package/dist/components/form-input-time/index.js +53 -59
- package/dist/components/form-item/index.js +80 -123
- package/dist/components/form-item/style.css +1 -11
- package/dist/components/form-item-config-provider/index.js +25 -26
- package/dist/components/form-item-group/index.js +85 -111
- package/dist/components/form-item-group/style.css +1 -30
- package/dist/components/form-radio-group/index.js +85 -104
- package/dist/components/form-radio-group/style.css +1 -53
- package/dist/components/form-select/index.js +76 -91
- package/dist/components/form-switch/index.js +51 -57
- package/dist/components/form-temp/index.js +149 -0
- package/dist/components/form-textarea/index.js +51 -57
- package/dist/components/form-view/index.js +165 -232
- package/dist/components/form-view/style.css +1 -158
- package/dist/components/fy-cascader/index.js +132 -0
- package/dist/components/fy-checkbox/index.js +116 -0
- package/dist/components/fy-checkbox/style.css +1 -0
- package/dist/components/fy-curd/index.js +846 -0
- package/dist/components/fy-curd/style.css +1 -0
- package/dist/components/fy-date/index.js +84 -0
- package/dist/components/fy-date/style.css +1 -0
- package/dist/components/fy-dialog-form/index.js +278 -0
- package/dist/components/fy-dialog-form/style.css +1 -0
- package/dist/components/fy-dynamic/index.js +335 -0
- package/dist/components/fy-dynamic/style.css +1 -0
- package/dist/components/fy-form/index.js +754 -0
- package/dist/components/fy-form/style.css +1 -0
- package/dist/components/fy-form-menu/index.js +95 -0
- package/dist/components/fy-input/index.js +162 -0
- package/dist/components/fy-input-color/index.js +96 -0
- package/dist/components/fy-input-icon/index.js +161 -0
- package/dist/components/fy-input-icon/style.css +1 -0
- package/dist/components/fy-input-map/index.js +275 -0
- package/dist/components/fy-input-map/style.css +1 -0
- package/dist/components/fy-input-number/index.js +87 -0
- package/dist/components/fy-input-table/index.js +172 -0
- package/dist/components/fy-input-table/style.css +1 -0
- package/dist/components/fy-input-tree/index.js +265 -0
- package/dist/components/fy-input-tree/style.css +1 -0
- package/dist/components/fy-radio/index.js +68 -0
- package/dist/components/fy-radio/style.css +1 -0
- package/dist/components/fy-rate/index.js +105 -0
- package/dist/components/fy-rate/style.css +1 -0
- package/dist/components/fy-select/index.js +223 -0
- package/dist/components/fy-select/style.css +1 -0
- package/dist/components/fy-slider/index.js +79 -0
- package/dist/components/fy-switch/index.js +73 -0
- package/dist/components/fy-time/index.js +95 -0
- package/dist/components/fy-title/index.js +40 -0
- package/dist/components/fy-title/style.css +1 -0
- package/dist/components/fy-upload/index.js +704 -0
- package/dist/components/fy-upload/style.css +1 -0
- package/dist/components/guide-steps/index.js +44 -58
- package/dist/components/guide-steps/style.css +1 -34
- package/dist/components/header-menu/index.js +238 -0
- package/dist/components/header-search/index.js +246 -0
- package/dist/components/icon-card/index.js +29 -35
- package/dist/components/icon-card/style.css +1 -56
- package/dist/components/icon-temp/index.js +50 -0
- package/dist/components/icon-temp/style.css +1 -0
- package/dist/components/iframe-window/index.js +29 -35
- package/dist/components/iframe-window/style.css +1 -20
- package/dist/components/image-viewer/index.js +48 -66
- package/dist/components/image-viewer/style.css +1 -21
- package/dist/components/input-number/index.js +127 -193
- package/dist/components/input-number/style.css +1 -15
- package/dist/components/input-number-range/index.js +45 -57
- package/dist/components/input-number-range/style.css +1 -12
- package/dist/components/j-s-x-component/index.js +4 -4
- package/dist/components/keep-view-alive/index.js +77 -120
- package/dist/components/keyboard/index.js +389 -0
- package/dist/components/keyboard/style.css +1 -0
- package/dist/components/license/index.js +134 -0
- package/dist/components/loading-view/index.js +26 -32
- package/dist/components/loading-view/style.css +1 -17
- package/dist/components/login/index.js +244 -0
- package/dist/components/login/style.css +1 -0
- package/dist/components/name-avatar/index.js +66 -0
- package/dist/components/name-avatar/style.css +1 -0
- package/dist/components/nav-bar/index.js +27 -37
- package/dist/components/nav-bar/style.css +1 -17
- package/dist/components/not-implement/index.js +23 -31
- package/dist/components/not-implement/style.css +1 -15
- package/dist/components/notice/index.js +143 -0
- package/dist/components/notice/style.css +1 -0
- package/dist/components/page/index.js +22 -28
- package/dist/components/page/style.css +1 -12
- package/dist/components/page-header/index.js +30 -36
- package/dist/components/page-header/style.css +1 -14
- package/dist/components/page-index/index.js +62 -83
- package/dist/components/page-index/style.css +1 -23
- package/dist/components/page-index-top/index.js +53 -68
- package/dist/components/page-skeleton/index.js +31 -37
- package/dist/components/page-skeleton/style.css +1 -23
- package/dist/components/page-skeleton-new/index.js +42 -48
- package/dist/components/page-skeleton-new/style.css +1 -42
- package/dist/components/pageable-table/index.js +190 -253
- package/dist/components/pageable-table/style.css +1 -72
- package/dist/components/pageable-view/index.js +134 -199
- package/dist/components/pageable-view/style.css +1 -69
- package/dist/components/photo-swipe/index.js +116 -151
- package/dist/components/photo-swipe/style.css +1 -20
- package/dist/components/progress/index.js +60 -0
- package/dist/components/queue/index.js +76 -0
- package/dist/components/record-video/index.js +173 -0
- package/dist/components/record-video/style.css +1 -0
- package/dist/components/resize-observer/index.js +34 -68
- package/dist/components/resize-observer/style.css +1 -31
- package/dist/components/search/index.js +142 -0
- package/dist/components/search/style.css +1 -0
- package/dist/components/search-popover/index.js +153 -211
- package/dist/components/search-popover/style.css +1 -93
- package/dist/components/sign/index.js +128 -0
- package/dist/components/sign/style.css +1 -0
- package/dist/components/sign-panel/index.js +105 -142
- package/dist/components/sign-panel/style.css +1 -97
- package/dist/components/skeleton/index.js +82 -0
- package/dist/components/skeleton/style.css +1 -0
- package/dist/components/split-pane/index.js +107 -162
- package/dist/components/split-pane/style.css +1 -100
- package/dist/components/stateful/index.js +31 -34
- package/dist/components/stateful/style.css +1 -33
- package/dist/components/static-pageable-table/index.js +37 -44
- package/dist/components/static-pageable-table/style.css +1 -9
- package/dist/components/swiper/index.js +85 -150
- package/dist/components/swiper/style.css +1 -43
- package/dist/components/tab/index.js +56 -72
- package/dist/components/tab/style.css +1 -122
- package/dist/components/tab-item/index.js +30 -35
- package/dist/components/table-column/index.js +30 -32
- package/dist/components/table-page/index.js +129 -0
- package/dist/components/table-view/index.js +156 -227
- package/dist/components/table-view/style.css +1 -95
- package/dist/components/tabs/index.js +90 -0
- package/dist/components/tabs/style.css +0 -0
- package/dist/components/tag-render/index.js +44 -58
- package/dist/components/tag-render/style.css +1 -33
- package/dist/components/text-ellipsis/index.js +107 -0
- package/dist/components/text-ellipsis/style.css +1 -0
- package/dist/components/tinymce-editor/index.js +79 -95
- package/dist/components/tinymce-editor/style.css +1 -43
- package/dist/components/tinymce-wrapper/index.js +92 -121
- package/dist/components/tinymce-wrapper/style.css +1 -36
- package/dist/components/toolbar/index.js +63 -84
- package/dist/components/toolbar/style.css +1 -39
- package/dist/components/toolbar-button/index.js +41 -48
- package/dist/components/toolbar-button/style.css +1 -21
- package/dist/components/tree/index.js +427 -0
- package/dist/components/tree/style.css +1 -0
- package/dist/components/trigger/index.js +29 -36
- package/dist/components/verify/index.js +80 -0
- package/dist/components/verify/style.css +1 -0
- package/dist/components/vue-tags-input/index.js +305 -311
- package/dist/components/vue-tags-input/style.css +1 -682
- package/dist/components/watermark/index.js +43 -37
- package/dist/components/watermark/style.css +1 -11
- package/dist/index.css +4157 -1686
- package/dist/index.es.js +23131 -11014
- package/package.json +20 -4
- package/web-types.json +12777 -2788
- package/dist/chunks/3d28cc08.js +0 -57
- package/dist/chunks/5d33812d.js +0 -147
- package/dist/chunks/9d848bf6.js +0 -99
- package/dist/chunks/a0bb327b.js +0 -96
- package/dist/chunks/a8891d2c.js +0 -30
- package/dist/chunks/c69d5628.js +0 -248
- package/dist/chunks/de9fe802.js +0 -24
- package/dist/components/x-dialog/index.js +0 -199
- package/dist/components/x-dialog/style.css +0 -15
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
import { i as r } from "./utils.fa73de78.js";
|
|
2
|
+
import { Col as i, FormItem as a } from "element-ui";
|
|
3
|
+
const u = ["span"], s = [...Object.keys(i.props)], n = s.filter((e) => !u.includes(e)), p = ["label", "prop", "rules", "labelWidth", "required"], l = [...Object.keys(a.props)], m = l.filter((e) => !p.includes(e)), f = [
|
|
4
|
+
"wrapCol",
|
|
5
|
+
"wrapFormItem",
|
|
6
|
+
"unwrap",
|
|
7
|
+
"prefixConfig",
|
|
8
|
+
"block",
|
|
9
|
+
"placeholder",
|
|
10
|
+
"prefixPick",
|
|
11
|
+
"half",
|
|
12
|
+
...s,
|
|
13
|
+
...l
|
|
14
|
+
], h = {
|
|
15
|
+
inject: {
|
|
16
|
+
elForm: {
|
|
17
|
+
default: {}
|
|
18
|
+
},
|
|
19
|
+
formItemGroup: {
|
|
20
|
+
default: {}
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
props: {
|
|
24
|
+
disabled: Boolean,
|
|
25
|
+
wrapCol: {
|
|
26
|
+
type: Boolean,
|
|
27
|
+
default: !0
|
|
28
|
+
},
|
|
29
|
+
wrapFormItem: {
|
|
30
|
+
type: Boolean,
|
|
31
|
+
default: !0
|
|
32
|
+
},
|
|
33
|
+
unwrap: Boolean,
|
|
34
|
+
half: Boolean,
|
|
35
|
+
prefixConfig: Boolean,
|
|
36
|
+
block: Boolean,
|
|
37
|
+
placeholder: {
|
|
38
|
+
type: [Boolean, String],
|
|
39
|
+
default: !0
|
|
40
|
+
},
|
|
41
|
+
formItemClass: String,
|
|
42
|
+
prefixPick: Boolean,
|
|
43
|
+
// el-form-item
|
|
44
|
+
label: String,
|
|
45
|
+
labelWidth: String,
|
|
46
|
+
prop: String,
|
|
47
|
+
required: Boolean,
|
|
48
|
+
rules: [Object, Array],
|
|
49
|
+
error: String,
|
|
50
|
+
validateStatus: String,
|
|
51
|
+
for: String,
|
|
52
|
+
inlineMessage: {
|
|
53
|
+
type: [String, Boolean],
|
|
54
|
+
default: ""
|
|
55
|
+
},
|
|
56
|
+
showMessage: {
|
|
57
|
+
type: Boolean,
|
|
58
|
+
default: !0
|
|
59
|
+
},
|
|
60
|
+
size: String,
|
|
61
|
+
// el-col
|
|
62
|
+
span: {
|
|
63
|
+
type: Number,
|
|
64
|
+
default: 12
|
|
65
|
+
},
|
|
66
|
+
tag: {
|
|
67
|
+
type: String,
|
|
68
|
+
default: "div"
|
|
69
|
+
},
|
|
70
|
+
offset: Number,
|
|
71
|
+
pull: Number,
|
|
72
|
+
push: Number,
|
|
73
|
+
xs: [Number, Object],
|
|
74
|
+
sm: [Number, Object],
|
|
75
|
+
md: [Number, Object],
|
|
76
|
+
lg: [Number, Object],
|
|
77
|
+
xl: [Number, Object]
|
|
78
|
+
},
|
|
79
|
+
computed: {
|
|
80
|
+
prefix() {
|
|
81
|
+
return this.prefixConfig ? "请配置" : this.prefixPick ? "请选择" : "请输入";
|
|
82
|
+
},
|
|
83
|
+
message() {
|
|
84
|
+
var e;
|
|
85
|
+
return `${this.prefix}${((e = this.label) == null ? void 0 : e.replace(":", "")) || ""}`;
|
|
86
|
+
},
|
|
87
|
+
computeRules() {
|
|
88
|
+
const e = [...this.rules || []];
|
|
89
|
+
if (this.required) {
|
|
90
|
+
const t = e.find((o) => o.required);
|
|
91
|
+
t ? t.ref ? t.label = t.label || this.label : t.message = e.message || this.message : e.unshift(this.getRequireRule());
|
|
92
|
+
}
|
|
93
|
+
return e.concat(this.getRules());
|
|
94
|
+
},
|
|
95
|
+
computeSpan() {
|
|
96
|
+
return this.block ? 24 : this.span;
|
|
97
|
+
},
|
|
98
|
+
formItemProps() {
|
|
99
|
+
return r({ ...this.$props, ...this.$attrs }, f);
|
|
100
|
+
},
|
|
101
|
+
elFormItemProps() {
|
|
102
|
+
return r({ ...this.$props, ...this.$attrs }, m);
|
|
103
|
+
},
|
|
104
|
+
elColProps() {
|
|
105
|
+
return r({ ...this.$props, ...this.$attrs }, n);
|
|
106
|
+
}
|
|
107
|
+
},
|
|
108
|
+
watch: {
|
|
109
|
+
computeRules() {
|
|
110
|
+
var e, t;
|
|
111
|
+
(t = (e = this.elForm) == null ? void 0 : e.clearValidate) == null || t.call(e, this.prop);
|
|
112
|
+
}
|
|
113
|
+
},
|
|
114
|
+
methods: {
|
|
115
|
+
getRules() {
|
|
116
|
+
return [];
|
|
117
|
+
},
|
|
118
|
+
getRequireRule() {
|
|
119
|
+
return {
|
|
120
|
+
required: !0,
|
|
121
|
+
message: this.message
|
|
122
|
+
};
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
};
|
|
126
|
+
export {
|
|
127
|
+
h as f
|
|
128
|
+
};
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
import { s as o, l as n, a as h, b as r } from "./dic.5f7e3523.js";
|
|
2
|
+
import { k as d, a as l, c as s } from "./util.5053d54e.js";
|
|
3
|
+
import { s as c } from "./slot.1b8d2b1b.js";
|
|
4
|
+
const O = {
|
|
5
|
+
mixins: [c],
|
|
6
|
+
props: {
|
|
7
|
+
defaults: {
|
|
8
|
+
type: Object,
|
|
9
|
+
default() {
|
|
10
|
+
return {};
|
|
11
|
+
}
|
|
12
|
+
},
|
|
13
|
+
option: {
|
|
14
|
+
type: Object,
|
|
15
|
+
required: !0,
|
|
16
|
+
default: () => ({})
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
watch: {
|
|
20
|
+
defaults: {
|
|
21
|
+
handler(t) {
|
|
22
|
+
this.objectOption = t;
|
|
23
|
+
},
|
|
24
|
+
deep: !0
|
|
25
|
+
},
|
|
26
|
+
objectOption: {
|
|
27
|
+
handler(t) {
|
|
28
|
+
this.$emit("update:defaults", t);
|
|
29
|
+
},
|
|
30
|
+
deep: !0
|
|
31
|
+
},
|
|
32
|
+
propOption: {
|
|
33
|
+
handler(t) {
|
|
34
|
+
let i = {};
|
|
35
|
+
t.forEach((e) => {
|
|
36
|
+
i[e.prop] = e;
|
|
37
|
+
}), this.$set(this, "objectOption", i);
|
|
38
|
+
},
|
|
39
|
+
deep: !0
|
|
40
|
+
},
|
|
41
|
+
option: {
|
|
42
|
+
handler() {
|
|
43
|
+
this.init(!1);
|
|
44
|
+
},
|
|
45
|
+
deep: !0
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
data() {
|
|
49
|
+
return {
|
|
50
|
+
DIC: {},
|
|
51
|
+
cascaderDIC: {},
|
|
52
|
+
tableOption: {},
|
|
53
|
+
isMobile: "",
|
|
54
|
+
objectOption: {}
|
|
55
|
+
};
|
|
56
|
+
},
|
|
57
|
+
created() {
|
|
58
|
+
this.init();
|
|
59
|
+
},
|
|
60
|
+
computed: {
|
|
61
|
+
resultOption() {
|
|
62
|
+
return Object.assign(d(this.tableOption), {
|
|
63
|
+
column: this.propOption
|
|
64
|
+
});
|
|
65
|
+
},
|
|
66
|
+
rowKey() {
|
|
67
|
+
return this.tableOption.rowKey || l.rowKey;
|
|
68
|
+
},
|
|
69
|
+
formRules() {
|
|
70
|
+
let t = {};
|
|
71
|
+
return this.propOption.forEach((i) => {
|
|
72
|
+
i.rules && i.display !== !1 && (t[i.prop] = i.rules);
|
|
73
|
+
}), t;
|
|
74
|
+
},
|
|
75
|
+
isMediumSize() {
|
|
76
|
+
return this.controlSize;
|
|
77
|
+
},
|
|
78
|
+
controlSize() {
|
|
79
|
+
return this.tableOption.size || this.$AVUE.size;
|
|
80
|
+
}
|
|
81
|
+
},
|
|
82
|
+
methods: {
|
|
83
|
+
init(t) {
|
|
84
|
+
this.tableOption = this.option, this.getIsMobile(), this.handleLocalDic(), t !== !1 && this.handleLoadDic();
|
|
85
|
+
},
|
|
86
|
+
dicInit(t) {
|
|
87
|
+
t === "cascader" ? this.handleLoadCascaderDic() : this.handleLoadDic();
|
|
88
|
+
},
|
|
89
|
+
getIsMobile() {
|
|
90
|
+
this.isMobile = document.body.clientWidth <= 768;
|
|
91
|
+
},
|
|
92
|
+
updateDic(t, i) {
|
|
93
|
+
let e = this.findObject(this.propOption, t);
|
|
94
|
+
s(i) && s(t) ? this.handleLoadDic() : s(i) && !s(e.dicUrl) ? o({
|
|
95
|
+
column: e
|
|
96
|
+
}).then((a) => {
|
|
97
|
+
this.$set(this.DIC, t, a);
|
|
98
|
+
}) : this.$set(this.DIC, t, i);
|
|
99
|
+
},
|
|
100
|
+
handleSetDic(t, i = {}) {
|
|
101
|
+
Object.keys(i).forEach((e) => {
|
|
102
|
+
this.$set(t, e, i[e]);
|
|
103
|
+
});
|
|
104
|
+
},
|
|
105
|
+
//本地字典
|
|
106
|
+
handleLocalDic() {
|
|
107
|
+
this.handleSetDic(this.DIC, n(this.resultOption));
|
|
108
|
+
},
|
|
109
|
+
// 网络字典加载
|
|
110
|
+
handleLoadDic() {
|
|
111
|
+
h(this.resultOption).then((t) => this.handleSetDic(this.DIC, t));
|
|
112
|
+
},
|
|
113
|
+
//级联字典加载
|
|
114
|
+
handleLoadCascaderDic() {
|
|
115
|
+
r(this.propOption, this.data).then((t) => this.handleSetDic(this.cascaderDIC, t));
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
};
|
|
119
|
+
export {
|
|
120
|
+
O as i
|
|
121
|
+
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const
|
|
1
|
+
const t = {
|
|
2
2
|
props: {
|
|
3
3
|
suffixIcon: {
|
|
4
4
|
type: String
|
|
@@ -12,15 +12,15 @@ const inputNumberMixin = {
|
|
|
12
12
|
},
|
|
13
13
|
stepStrictly: {
|
|
14
14
|
type: Boolean,
|
|
15
|
-
default:
|
|
15
|
+
default: !1
|
|
16
16
|
},
|
|
17
17
|
max: {
|
|
18
18
|
type: Number,
|
|
19
|
-
default:
|
|
19
|
+
default: 1 / 0
|
|
20
20
|
},
|
|
21
21
|
min: {
|
|
22
22
|
type: Number,
|
|
23
|
-
default: -
|
|
23
|
+
default: -1 / 0
|
|
24
24
|
},
|
|
25
25
|
value: {
|
|
26
26
|
type: [Number, String]
|
|
@@ -31,7 +31,7 @@ const inputNumberMixin = {
|
|
|
31
31
|
},
|
|
32
32
|
controls: {
|
|
33
33
|
type: Boolean,
|
|
34
|
-
default:
|
|
34
|
+
default: !0
|
|
35
35
|
},
|
|
36
36
|
controlsPosition: {
|
|
37
37
|
type: String,
|
|
@@ -49,12 +49,12 @@ const inputNumberMixin = {
|
|
|
49
49
|
precision: {
|
|
50
50
|
type: Number,
|
|
51
51
|
default: void 0,
|
|
52
|
-
validator(
|
|
53
|
-
return
|
|
52
|
+
validator(e) {
|
|
53
|
+
return e >= 0 && e === parseInt(e, 10);
|
|
54
54
|
}
|
|
55
55
|
}
|
|
56
56
|
}
|
|
57
57
|
};
|
|
58
58
|
export {
|
|
59
|
-
|
|
59
|
+
t as i
|
|
60
60
|
};
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
const
|
|
1
|
+
const t = {
|
|
2
2
|
inject: ["uploader"]
|
|
3
|
-
}
|
|
4
|
-
const supportMixin = {
|
|
3
|
+
}, p = {
|
|
5
4
|
data() {
|
|
6
5
|
return {
|
|
7
|
-
support:
|
|
6
|
+
support: !0
|
|
8
7
|
};
|
|
9
8
|
},
|
|
10
9
|
mounted() {
|
|
@@ -12,6 +11,6 @@ const supportMixin = {
|
|
|
12
11
|
}
|
|
13
12
|
};
|
|
14
13
|
export {
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
p as s,
|
|
15
|
+
t as u
|
|
17
16
|
};
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
const s = {};
|
|
2
|
+
function l(t = "default") {
|
|
3
|
+
let i = "";
|
|
4
|
+
switch (t) {
|
|
5
|
+
case "default":
|
|
6
|
+
i = "#35495E";
|
|
7
|
+
break;
|
|
8
|
+
case "primary":
|
|
9
|
+
i = "#3488ff";
|
|
10
|
+
break;
|
|
11
|
+
case "success":
|
|
12
|
+
i = "#43B883";
|
|
13
|
+
break;
|
|
14
|
+
case "warning":
|
|
15
|
+
i = "#e6a23c";
|
|
16
|
+
break;
|
|
17
|
+
case "danger":
|
|
18
|
+
i = "#f56c6c";
|
|
19
|
+
break;
|
|
20
|
+
}
|
|
21
|
+
return i;
|
|
22
|
+
}
|
|
23
|
+
s.capsule = function(t, i, a = "primary") {
|
|
24
|
+
console.log(
|
|
25
|
+
`%c ${t} %c ${i} %c`,
|
|
26
|
+
"background:#35495E; padding: 1px; border-radius: 3px 0 0 3px; color: #fff;",
|
|
27
|
+
`background:${l(
|
|
28
|
+
a
|
|
29
|
+
)}; padding: 1px; border-radius: 0 3px 3px 0; color: #fff;`,
|
|
30
|
+
"background:transparent"
|
|
31
|
+
);
|
|
32
|
+
};
|
|
33
|
+
s.colorful = function(t) {
|
|
34
|
+
console.log(
|
|
35
|
+
`%c${t.map((i) => i.text || "").join("%c")}`,
|
|
36
|
+
...t.map((i) => `color: ${l(i.type)};`)
|
|
37
|
+
);
|
|
38
|
+
};
|
|
39
|
+
s.default = function(t) {
|
|
40
|
+
s.colorful([{ text: t }]);
|
|
41
|
+
};
|
|
42
|
+
s.primary = function(t) {
|
|
43
|
+
s.colorful([{ text: t, type: "primary" }]);
|
|
44
|
+
};
|
|
45
|
+
s.success = function(t) {
|
|
46
|
+
s.colorful([{ text: t, type: "success" }]);
|
|
47
|
+
};
|
|
48
|
+
s.warning = function(t) {
|
|
49
|
+
s.colorful([{ text: t, type: "warning" }]);
|
|
50
|
+
};
|
|
51
|
+
s.danger = function(t) {
|
|
52
|
+
s.colorful([{ text: t, type: "danger" }]);
|
|
53
|
+
};
|
|
54
|
+
const c = {
|
|
55
|
+
AliOSS: {
|
|
56
|
+
url: "https://cdn.staticfile.org/ali-oss/6.17.1/aliyun-oss-sdk.min.js",
|
|
57
|
+
title: "阿里云云图片上传,需引入OSS的sdk",
|
|
58
|
+
github: "https://github.com/ali-sdk/ali-oss/"
|
|
59
|
+
},
|
|
60
|
+
Map: {
|
|
61
|
+
url: "https://webapi.amap.com/maps?v=1.4.11&key=xxxxx&plugin=AMap.PlaceSearch,https://webapi.amap.com/ui/1.0/main.js?v=1.0.11",
|
|
62
|
+
title: "地图组件,需引入高德SDK"
|
|
63
|
+
},
|
|
64
|
+
MapUi: {
|
|
65
|
+
url: "https://webapi.amap.com/ui/1.0/main.js?v=1.0.11",
|
|
66
|
+
title: "地图组件,需引入高德UISDK"
|
|
67
|
+
},
|
|
68
|
+
Sortable: {
|
|
69
|
+
url: "https://cdn.staticfile.org/Sortable/1.10.0-rc2/Sortable.min.js",
|
|
70
|
+
title: "拖拽,需引入sortableJs",
|
|
71
|
+
github: "https://github.com/SortableJS/Sortable"
|
|
72
|
+
},
|
|
73
|
+
Screenshot: {
|
|
74
|
+
url: "https://cdn.staticfile.org/html2canvas/0.5.0-beta4/html2canvas.min.js",
|
|
75
|
+
title: "需引入html2canvas依赖包",
|
|
76
|
+
github: "https://github.com/niklasvh/html2canvas/"
|
|
77
|
+
},
|
|
78
|
+
CryptoJS: {
|
|
79
|
+
url: "https://avuejs.com/cdn/CryptoJS.js",
|
|
80
|
+
title: "七牛云图片上传,需引入CryptoJS"
|
|
81
|
+
},
|
|
82
|
+
hljs: {
|
|
83
|
+
url: "https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.15.6/highlight.min.js",
|
|
84
|
+
title: "需引入hljs框架包",
|
|
85
|
+
github: "https://github.com/highlightjs/highlight.js"
|
|
86
|
+
},
|
|
87
|
+
"file-saver": {
|
|
88
|
+
url: "https://cdn.staticfile.org/FileSaver.js/2014-11-29/FileSaver.min.js",
|
|
89
|
+
title: "需引入文件操作包",
|
|
90
|
+
github: "https://github.com/eligrey/FileSaver.js"
|
|
91
|
+
},
|
|
92
|
+
xlsx: {
|
|
93
|
+
url: "https://cdn.staticfile.org/xlsx/0.18.2/xlsx.full.min.js",
|
|
94
|
+
title: "需引入excel操作包",
|
|
95
|
+
github: "https://github.com/protobi/js-xlsx"
|
|
96
|
+
},
|
|
97
|
+
mock: {
|
|
98
|
+
url: "https://cdn.staticfile.org/Mock.js/1.0.1-beta3/mock-min.js",
|
|
99
|
+
title: "需要引入mock模拟数据包",
|
|
100
|
+
github: "https://github.com/Colingo/mock"
|
|
101
|
+
}
|
|
102
|
+
}, o = (() => ({
|
|
103
|
+
logs: function(t) {
|
|
104
|
+
const i = c[t];
|
|
105
|
+
s.capsule(
|
|
106
|
+
t,
|
|
107
|
+
i.title,
|
|
108
|
+
"warning"
|
|
109
|
+
), s.warning("CDN:" + (i.url || "-")), s.warning("GITHUB:" + (i.github || "-"));
|
|
110
|
+
}
|
|
111
|
+
}))();
|
|
112
|
+
export {
|
|
113
|
+
o as p
|
|
114
|
+
};
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
const u = {
|
|
2
|
+
methods: {
|
|
3
|
+
getSlotName(l = {}, a = "D", e) {
|
|
4
|
+
let r = {
|
|
5
|
+
F: "Form",
|
|
6
|
+
H: "Header",
|
|
7
|
+
E: "Error",
|
|
8
|
+
L: "Label",
|
|
9
|
+
S: "Search",
|
|
10
|
+
T: "Type",
|
|
11
|
+
D: ""
|
|
12
|
+
}, t = l.prop + r[a];
|
|
13
|
+
return e ? e[t] : t;
|
|
14
|
+
},
|
|
15
|
+
getSlotList(l = [], a, e) {
|
|
16
|
+
return e = e.map((r) => r.prop), Object.keys(a).filter((r) => {
|
|
17
|
+
let t = !1;
|
|
18
|
+
return e.includes(r) || l.forEach((s) => {
|
|
19
|
+
r.includes(s) && (t = !0);
|
|
20
|
+
}), t;
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
};
|
|
25
|
+
export {
|
|
26
|
+
u as s
|
|
27
|
+
};
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
const n = {
|
|
2
|
+
mounted() {
|
|
3
|
+
this.value >= 0 && (this.currentIndex = this.value), this.updateIndex();
|
|
4
|
+
},
|
|
5
|
+
methods: {
|
|
6
|
+
updateIndex() {
|
|
7
|
+
if (!this.$children || !this.$children.length)
|
|
8
|
+
return;
|
|
9
|
+
this.number = this.$children.length;
|
|
10
|
+
const e = this.$children;
|
|
11
|
+
for (let t = 0; t < e.length; t++)
|
|
12
|
+
e[t].currentIndex = t, e[t].currentSelected && (this.index = t);
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
props: {
|
|
16
|
+
value: Number
|
|
17
|
+
},
|
|
18
|
+
watch: {
|
|
19
|
+
currentIndex(e, t) {
|
|
20
|
+
t > -1 && this.$children[t] && (this.$children[t].currentSelected = !1), e > -1 && this.$children[e] && (this.$children[e].currentSelected = !0), this.$emit("input", e), this.$emit("on-index-change", e, t);
|
|
21
|
+
},
|
|
22
|
+
index(e) {
|
|
23
|
+
this.currentIndex = e;
|
|
24
|
+
},
|
|
25
|
+
value(e) {
|
|
26
|
+
this.index = e;
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
data() {
|
|
30
|
+
return {
|
|
31
|
+
index: -1,
|
|
32
|
+
currentIndex: this.index,
|
|
33
|
+
number: this.$children.length
|
|
34
|
+
};
|
|
35
|
+
}
|
|
36
|
+
}, i = {
|
|
37
|
+
props: {
|
|
38
|
+
selected: {
|
|
39
|
+
type: Boolean,
|
|
40
|
+
default: !1
|
|
41
|
+
}
|
|
42
|
+
},
|
|
43
|
+
mounted() {
|
|
44
|
+
this.$parent.updateIndex();
|
|
45
|
+
},
|
|
46
|
+
beforeDestroy() {
|
|
47
|
+
const e = this.$parent;
|
|
48
|
+
this.$nextTick(() => {
|
|
49
|
+
e.updateIndex();
|
|
50
|
+
});
|
|
51
|
+
},
|
|
52
|
+
methods: {
|
|
53
|
+
onItemClick(e) {
|
|
54
|
+
if (this.$parent.preventDefault) {
|
|
55
|
+
this.$parent.$emit("on-before-index-change", this.currentIndex);
|
|
56
|
+
return;
|
|
57
|
+
}
|
|
58
|
+
(typeof this.disabled > "u" || this.disabled === !1) && (this.currentSelected = !0, this.$parent.currentIndex = this.currentIndex, this.$nextTick(() => {
|
|
59
|
+
this.$emit("on-item-click", this.currentIndex);
|
|
60
|
+
}));
|
|
61
|
+
}
|
|
62
|
+
},
|
|
63
|
+
watch: {
|
|
64
|
+
currentSelected(e) {
|
|
65
|
+
e && (this.$parent.index = this.currentIndex);
|
|
66
|
+
},
|
|
67
|
+
selected(e) {
|
|
68
|
+
this.currentSelected = e;
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
data() {
|
|
72
|
+
return {
|
|
73
|
+
currentIndex: -1,
|
|
74
|
+
currentSelected: this.selected
|
|
75
|
+
};
|
|
76
|
+
}
|
|
77
|
+
};
|
|
78
|
+
export {
|
|
79
|
+
i as c,
|
|
80
|
+
n as p
|
|
81
|
+
};
|