@web-utils/component 1.2.5 → 1.2.7

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 (111) hide show
  1. package/README.md +27 -27
  2. package/dist/chunks/163eed3b.js +16 -1
  3. package/dist/chunks/2bd4e340.js +184 -0
  4. package/dist/chunks/6499de3a.js +30 -1
  5. package/dist/chunks/7af3ceb1.js +75 -0
  6. package/dist/chunks/86bcadec.js +24 -0
  7. package/dist/chunks/8bbde9bf.js +81 -1
  8. package/dist/chunks/90bd3d52.js +26 -1
  9. package/dist/chunks/92404ceb.js +126 -0
  10. package/dist/chunks/a73fe8ee.js +11 -0
  11. package/dist/chunks/df803484.js +60 -0
  12. package/dist/components/address-input/index.js +113 -1
  13. package/dist/components/aside-menu/index.js +58 -1
  14. package/dist/components/awesome-button/index.js +82 -1
  15. package/dist/components/capsule-tab/index.js +52 -1
  16. package/dist/components/chunk-file-uploader/index.js +119 -1
  17. package/dist/components/chunk-file-uploader-button/index.js +60 -1
  18. package/dist/components/chunk-file-uploader-drop/index.js +65 -1
  19. package/dist/components/chunk-file-uploader-file/index.js +311 -1
  20. package/dist/components/chunk-file-uploader-files/index.js +49 -1
  21. package/dist/components/chunk-file-uploader-list/index.js +50 -1
  22. package/dist/components/chunk-file-uploader-un-support/index.js +51 -1
  23. package/dist/components/code-mirror-editor/index.js +310 -6
  24. package/dist/components/color-picker/index.js +110 -1
  25. package/dist/components/confirm-button/index.js +57 -1
  26. package/dist/components/confirmable/index.js +28 -1
  27. package/dist/components/context-menu/index.js +236 -1
  28. package/dist/components/custom-scrollbar/index.js +150 -1
  29. package/dist/components/data-table-picker/index.js +137 -1
  30. package/dist/components/dynamic-table/index.js +195 -1
  31. package/dist/components/e-charts/index.js +229 -1
  32. package/dist/components/editable-progress/index.js +141 -1
  33. package/dist/components/editable-tree/index.js +789 -1
  34. package/dist/components/egd-collapse/index.js +79 -1
  35. package/dist/components/egd-collapse-item/index.js +132 -1
  36. package/dist/components/element-dialog/index.js +242 -1
  37. package/dist/components/empty-view/index.js +69 -1
  38. package/dist/components/error-view/index.js +61 -1
  39. package/dist/components/flex-column/index.js +50 -1
  40. package/dist/components/flex-item/index.js +66 -1
  41. package/dist/components/flex-row/index.js +50 -1
  42. package/dist/components/flex-scroller/index.js +47 -1
  43. package/dist/components/form-button/index.js +80 -1
  44. package/dist/components/form-cascader/index.js +151 -1
  45. package/dist/components/form-checkbox-group/index.js +192 -1
  46. package/dist/components/form-date-picker/index.js +182 -1
  47. package/dist/components/form-holder/index.js +90 -1
  48. package/dist/components/form-input/index.js +106 -1
  49. package/dist/components/form-input-email/index.js +97 -1
  50. package/dist/components/form-input-id-card/index.js +104 -1
  51. package/dist/components/form-input-number/index.js +123 -1
  52. package/dist/components/form-input-phone-number/index.js +98 -1
  53. package/dist/components/form-input-time/index.js +124 -1
  54. package/dist/components/form-item/index.js +120 -1
  55. package/dist/components/form-item-config-provider/index.js +63 -1
  56. package/dist/components/form-item-group/index.js +169 -1
  57. package/dist/components/form-radio-group/index.js +170 -1
  58. package/dist/components/form-select/index.js +154 -1
  59. package/dist/components/form-switch/index.js +97 -1
  60. package/dist/components/form-textarea/index.js +102 -1
  61. package/dist/components/form-view/index.js +343 -1
  62. package/dist/components/guide-steps/index.js +94 -1
  63. package/dist/components/icon-card/index.js +62 -1
  64. package/dist/components/iframe-window/index.js +99 -1
  65. package/dist/components/input-number/index.js +274 -1
  66. package/dist/components/input-number-range/index.js +110 -1
  67. package/dist/components/j-s-x-component/index.js +16 -1
  68. package/dist/components/keep-view-alive/index.js +119 -1
  69. package/dist/components/loading-view/index.js +61 -1
  70. package/dist/components/nav-bar/index.js +52 -1
  71. package/dist/components/not-implement/index.js +35 -1
  72. package/dist/components/page/index.js +40 -1
  73. package/dist/components/page-header/index.js +56 -1
  74. package/dist/components/page-index/index.js +151 -1
  75. package/dist/components/page-index-top/index.js +119 -1
  76. package/dist/components/page-skeleton/index.js +56 -1
  77. package/dist/components/page-skeleton-new/index.js +98 -1
  78. package/dist/components/pageable-table/index.js +429 -1
  79. package/dist/components/pageable-view/index.js +328 -2
  80. package/dist/components/photo-swipe/index.js +187 -1
  81. package/dist/components/resize-observer/index.js +62 -1
  82. package/dist/components/search-popover/index.js +391 -2
  83. package/dist/components/sign-panel/index.js +242 -1
  84. package/dist/components/split-pane/index.js +209 -1
  85. package/dist/components/stateful/index.js +84 -1
  86. package/dist/components/static-pageable-table/index.js +92 -1
  87. package/dist/components/swiper/index.js +158 -1
  88. package/dist/components/tab/index.js +145 -1
  89. package/dist/components/tab-item/index.js +73 -1
  90. package/dist/components/table-column/index.js +89 -1
  91. package/dist/components/table-view/index.js +363 -1
  92. package/dist/components/tag-render/index.js +97 -1
  93. package/dist/components/tinymce-editor/index.js +173 -1
  94. package/dist/components/tinymce-wrapper/index.js +618 -1
  95. package/dist/components/toolbar/index.js +217 -1
  96. package/dist/components/toolbar-button/index.js +90 -1
  97. package/dist/components/trigger/index.js +71 -1
  98. package/dist/components/vue-tags-input/index.js +439 -1
  99. package/dist/components/watermark/index.js +63 -1
  100. package/dist/components/x-dialog/index.js +173 -1
  101. package/dist/index.css +2102 -1
  102. package/dist/index.es.js +3097 -2347
  103. package/package.json +29 -29
  104. package/web-types.json +22 -55
  105. package/dist/chunks/23bd3525.js +0 -1
  106. package/dist/chunks/65f4f4f2.js +0 -1
  107. package/dist/chunks/8473fc69.js +0 -1
  108. package/dist/chunks/a125d16c.js +0 -1
  109. package/dist/chunks/addb6ed5.js +0 -1
  110. package/dist/chunks/f15477c7.js +0 -1
  111. package/dist/components/el-color-picker-dropdown/index.js +0 -1
@@ -1 +1,169 @@
1
- import{isFunction as m}from"@web-utils/core";import{n as f}from"../../chunks/6499de3a.js";const s=["disabled","size","statusIcon","inlineMessage","autoLabelWidth","hideRequiredAsterisk","$emit","validate","clearValidate"],p=["$emit","validate","clearValidate"];var u={name:"FormItemGroup",inject:{elForm:{default:{}}},provide(){return{elForm:this.formConfig,formItemGroup:this}},props:{blockTitle:{type:String},active:Boolean,enabled:Boolean,disabled:Boolean,wrapRow:{type:Boolean,default:!0},gutter:{type:Number,default:20},collapse:Boolean},data(){const e={};return s.forEach(t=>{e[t]=null}),{expand:!0,formConfig:e}},computed:{formCfg(){const e={enabled:this.enabled,forbidden:this.disabled};return s.forEach(t=>{e[t]=this.elForm[t]}),e}},watch:{collapse:{immediate:!0,handler(e){this.expand=!e}},formCfg:{immediate:!0,handler(){this.formConfig.disabled=this.isDisabled(),s.forEach(e=>{var t;e!=="disabled"&&(p.includes(e)?this.formConfig[e]=(t=this.elForm[e])==null?void 0:t.bind(this.elForm):this.formConfig[e]=this.elForm[e])})}}},mounted(){this.dispatch("FormView","FormView.addGroup",[this])},beforeDestroy(){this.dispatch("FormView","FormView.removeGroup",[this])},methods:{isDisabled(){return this.disabled?this.disabled:this.enabled?!this.enabled:this.elForm.disabled},dispatch(e,t,r){let i=this.$parent||this.$root,o=i.$options.name;for(;i&&(!o||o!==e);)i=i.$parent,i&&(o=i.$options.name);i&&i.$emit.apply(i,[t].concat(r))},renderDefault(){const e=this.$createElement,{wrapRow:t,gutter:r,formConfig:i,$scopedSlots:o}=this;return m(o.default)?t?e("ElRow",{attrs:{gutter:r},class:"form-item-group-row"},[o.default({disabled:i.disabled})]):o.default({disabled:i.disabled}):e("EmptyView",{attrs:{"font-size":"14px","empty-tips":"\u6682\u65E0\u4FE1\u606F"}})},toggle(){this.expand=!this.expand},open(){this.expand=!0}},render(){const e=arguments[0],{renderDefault:t,blockTitle:r,active:i,expand:o,toggle:n,$scopedSlots:a,isDisabled:d}=this;return e("div",{class:["form-item-group",{"default-active":i,"is-disabled":d()}]},[e("div",{class:"form-item-group-title",on:{click:n}},[e("span",{class:"flex-item"},[r,a["title-right"]?a["title-right"]():null])," ",e("i",{class:o?"el-icon-arrow-down":"el-icon-arrow-right"})]),e("ElCollapseTransition",[e("div",{directives:[{name:"show",value:o}]},[t()])])])}};let c,h;const l={};var g=f(u,c,h,!1,b,null,null,null);function b(e){for(let t in l)this[t]=l[t]}var _=function(){return g.exports}();export{_ as default};
1
+ import { isFunction as m } from "@web-utils/core";
2
+ import { n as u } from "../../chunks/6499de3a.js";
3
+ const r = ["disabled", "size", "statusIcon", "inlineMessage", "autoLabelWidth", "hideRequiredAsterisk", "$emit", "validate", "clearValidate"], c = ["$emit", "validate", "clearValidate"], p = {
4
+ name: "FormItemGroup",
5
+ inject: {
6
+ elForm: {
7
+ default: {}
8
+ }
9
+ },
10
+ provide() {
11
+ return {
12
+ elForm: this.formConfig,
13
+ formItemGroup: this
14
+ };
15
+ },
16
+ props: {
17
+ blockTitle: {
18
+ type: String
19
+ },
20
+ active: Boolean,
21
+ enabled: Boolean,
22
+ disabled: Boolean,
23
+ wrapRow: {
24
+ type: Boolean,
25
+ default: !0
26
+ },
27
+ gutter: {
28
+ type: Number,
29
+ default: 20
30
+ },
31
+ collapse: Boolean
32
+ },
33
+ data() {
34
+ const e = {};
35
+ return r.forEach((t) => {
36
+ e[t] = null;
37
+ }), {
38
+ expand: !0,
39
+ formConfig: e
40
+ };
41
+ },
42
+ computed: {
43
+ formCfg() {
44
+ const e = {
45
+ enabled: this.enabled,
46
+ forbidden: this.disabled
47
+ };
48
+ return r.forEach((t) => {
49
+ e[t] = this.elForm[t];
50
+ }), e;
51
+ }
52
+ },
53
+ watch: {
54
+ collapse: {
55
+ immediate: !0,
56
+ handler(e) {
57
+ this.expand = !e;
58
+ }
59
+ },
60
+ formCfg: {
61
+ immediate: !0,
62
+ handler() {
63
+ this.formConfig.disabled = this.isDisabled(), r.forEach((e) => {
64
+ var t;
65
+ e !== "disabled" && (c.includes(e) ? this.formConfig[e] = (t = this.elForm[e]) == null ? void 0 : t.bind(this.elForm) : this.formConfig[e] = this.elForm[e]);
66
+ });
67
+ }
68
+ }
69
+ },
70
+ mounted() {
71
+ this.dispatch("FormView", "FormView.addGroup", [this]);
72
+ },
73
+ beforeDestroy() {
74
+ this.dispatch("FormView", "FormView.removeGroup", [this]);
75
+ },
76
+ methods: {
77
+ isDisabled() {
78
+ return this.disabled ? this.disabled : this.enabled ? !this.enabled : this.elForm.disabled;
79
+ },
80
+ dispatch(e, t, s) {
81
+ let i = this.$parent || this.$root, o = i.$options.name;
82
+ for (; i && (!o || o !== e); )
83
+ i = i.$parent, i && (o = i.$options.name);
84
+ i && i.$emit.apply(i, [t].concat(s));
85
+ },
86
+ renderDefault() {
87
+ const e = this.$createElement, {
88
+ wrapRow: t,
89
+ gutter: s,
90
+ formConfig: i,
91
+ $scopedSlots: o
92
+ } = this;
93
+ return m(o.default) ? t ? e("ElRow", {
94
+ attrs: {
95
+ gutter: s
96
+ },
97
+ class: "form-item-group-row"
98
+ }, [o.default({
99
+ disabled: i.disabled
100
+ })]) : o.default({
101
+ disabled: i.disabled
102
+ }) : e("EmptyView", {
103
+ attrs: {
104
+ "font-size": "14px",
105
+ "empty-tips": "\u6682\u65E0\u4FE1\u606F"
106
+ }
107
+ });
108
+ },
109
+ toggle() {
110
+ this.expand = !this.expand;
111
+ },
112
+ open() {
113
+ this.expand = !0;
114
+ }
115
+ },
116
+ render() {
117
+ const e = arguments[0], {
118
+ renderDefault: t,
119
+ blockTitle: s,
120
+ active: i,
121
+ expand: o,
122
+ toggle: n,
123
+ $scopedSlots: a,
124
+ isDisabled: d
125
+ } = this;
126
+ return e("div", {
127
+ class: ["form-item-group", {
128
+ "default-active": i,
129
+ "is-disabled": d()
130
+ }]
131
+ }, [e("div", {
132
+ class: "form-item-group-title",
133
+ on: {
134
+ click: n
135
+ }
136
+ }, [e("span", {
137
+ class: "flex-item"
138
+ }, [s, a["title-right"] ? a["title-right"]() : null]), " ", e("i", {
139
+ class: o ? "el-icon-arrow-down" : "el-icon-arrow-right"
140
+ })]), e("ElCollapseTransition", [e("div", {
141
+ directives: [{
142
+ name: "show",
143
+ value: o
144
+ }]
145
+ }, [t()])])]);
146
+ }
147
+ };
148
+ let f, h;
149
+ const l = {};
150
+ var b = /* @__PURE__ */ u(
151
+ p,
152
+ f,
153
+ h,
154
+ !1,
155
+ g,
156
+ null,
157
+ null,
158
+ null
159
+ );
160
+ function g(e) {
161
+ for (let t in l)
162
+ this[t] = l[t];
163
+ }
164
+ const w = /* @__PURE__ */ function() {
165
+ return b.exports;
166
+ }();
167
+ export {
168
+ w as default
169
+ };
@@ -1 +1,170 @@
1
- var p=Object.defineProperty;var a=Object.getOwnPropertySymbols;var u=Object.prototype.hasOwnProperty,d=Object.prototype.propertyIsEnumerable;var n=(r,e,o)=>e in r?p(r,e,{enumerable:!0,configurable:!0,writable:!0,value:o}):r[e]=o,t=(r,e)=>{for(var o in e||(e={}))u.call(e,o)&&n(r,o,e[o]);if(a)for(var o of a(e))d.call(e,o)&&n(r,o,e[o]);return r};import{f}from"../../chunks/a125d16c.js";import{f as m}from"../../chunks/23bd3525.js";import{RadioGroup as c}from"element-ui";import{i as h,n as g}from"../../chunks/8473fc69.js";import{n as _}from"../../chunks/6499de3a.js";var y=function(){var r=this,e=r.$createElement,o=r._self._c||e;return o("FormItem",r._b({class:["form-radio-group",{"form-radio-group-row":r.fillRow,inline:r.inline},r.ellipsis?"form-radio-group-row-ellipsis":"form-radio-group-row-break-word"],attrs:{rules:r.computeRules,disabled:r.inputDisabled},scopedSlots:r._u([{key:"default",fn:function(){return[o("ElRadioGroup",r._g(r._b({class:{"over-flow":r.overFlow},attrs:{value:r.value,disabled:r.inputDisabled,placeholder:r.computePlaceholder},on:{input:function(i){return r.$emit("input",i)}}},"ElRadioGroup",r.inputProps,!1),r.listeners),[r.allowCancel?r._l(r.innerOptions,function(i){return o("ElRadio",{key:i[r.valueKey],attrs:{label:i[r.valueKey]},nativeOn:{click:function(l){return l.preventDefault(),l.stopPropagation(),r.toggle(i)}}},[r._v(" "+r._s(i[r.labelKey])+" ")])}):r._l(r.innerOptions,function(i){return o("ElRadio",{key:i[r.valueKey],attrs:{label:i[r.valueKey]}},[r._v(" "+r._s(i[r.labelKey])+" ")])})],2),r._t("append")]},proxy:!0},{key:"error",fn:function(i){var l=i.error;return[r._t("error",null,{error:l})]}},{key:"label",fn:function(){return[r._t("label")]},proxy:!0},{key:"below",fn:function(){return[r._t("below")]},proxy:!0}],null,!0)},"FormItem",r.formItemProps,!1))},v=[];const b=Object.keys(c.props).filter(r=>!["value","placeholder","disabled"].includes(r)),w={name:"FormRadioGroup",mixins:[f,m],props:{options:{type:Array,default:()=>[]},gender:Boolean,overFlow:Boolean,confirm:Boolean,labelProp:{type:String,default:"name"},valueProp:{type:String,default:"code"},english:Boolean,chinese:Boolean,typing:Boolean,classic:Boolean,fillRow:Boolean,ellipsis:Boolean,inline:Boolean,allowCancel:Boolean},computed:{prefix(){return"\u8BF7\u9009\u62E9"},inputProps(){return h(t(t({},g(this.$attrs)),this.$props),b)},labelKey(){return this.classic?"label":this.labelProp},valueKey(){return this.classic?"value":this.valueProp},innerOptions(){return this.gender?[{[this.labelKey]:"\u7537",[this.valueKey]:this.chinese?"\u7537":this.typing?1:"1"},{[this.labelKey]:"\u5973",[this.valueKey]:this.chinese?"\u5973":this.typing?2:"2"}]:this.confirm?[{[this.labelKey]:"\u662F",[this.valueKey]:this.chinese?"\u662F":this.english?"Y":this.typing?1:"1"},{[this.labelKey]:"\u5426",[this.valueKey]:this.chinese?"\u5426":this.english?"N":this.typing?0:"0"}]:this.options}},methods:{emitInput(r){this.$emit("input",r)},toggle(r){this.value===r[this.valueKey]?this.emitInput(null):this.emitInput(r[this.valueKey])}}},s={};var x=_(w,y,v,!1,K,null,null,null);function K(r){for(let e in s)this[e]=s[e]}var k=function(){return x.exports}();export{k as default};
1
+ import { f as n } from "../../chunks/86bcadec.js";
2
+ import { f as s } from "../../chunks/a73fe8ee.js";
3
+ import { RadioGroup as a } from "element-ui";
4
+ import { i as u, n as p } from "../../chunks/2bd4e340.js";
5
+ import { n as c } from "../../chunks/6499de3a.js";
6
+ var f = function() {
7
+ var e = this, o = e.$createElement, r = e._self._c || o;
8
+ return r("FormItem", e._b({
9
+ class: ["form-radio-group", {
10
+ "form-radio-group-row": e.fillRow,
11
+ inline: e.inline
12
+ }, e.ellipsis ? "form-radio-group-row-ellipsis" : "form-radio-group-row-break-word"],
13
+ attrs: {
14
+ rules: e.computeRules,
15
+ disabled: e.inputDisabled
16
+ },
17
+ scopedSlots: e._u([{
18
+ key: "default",
19
+ fn: function() {
20
+ return [r("ElRadioGroup", e._g(e._b({
21
+ class: {
22
+ "over-flow": e.overFlow
23
+ },
24
+ attrs: {
25
+ value: e.value,
26
+ disabled: e.inputDisabled,
27
+ placeholder: e.computePlaceholder
28
+ },
29
+ on: {
30
+ input: function(t) {
31
+ return e.$emit("input", t);
32
+ }
33
+ }
34
+ }, "ElRadioGroup", e.inputProps, !1), e.listeners), [e.allowCancel ? e._l(e.innerOptions, function(t) {
35
+ return r("ElRadio", {
36
+ key: t[e.valueKey],
37
+ attrs: {
38
+ label: t[e.valueKey]
39
+ },
40
+ nativeOn: {
41
+ click: function(l) {
42
+ return l.preventDefault(), l.stopPropagation(), e.toggle(t);
43
+ }
44
+ }
45
+ }, [e._v(" " + e._s(t[e.labelKey]) + " ")]);
46
+ }) : e._l(e.innerOptions, function(t) {
47
+ return r("ElRadio", {
48
+ key: t[e.valueKey],
49
+ attrs: {
50
+ label: t[e.valueKey]
51
+ }
52
+ }, [e._v(" " + e._s(t[e.labelKey]) + " ")]);
53
+ })], 2), e._t("append")];
54
+ },
55
+ proxy: !0
56
+ }, {
57
+ key: "error",
58
+ fn: function(t) {
59
+ var l = t.error;
60
+ return [e._t("error", null, {
61
+ error: l
62
+ })];
63
+ }
64
+ }, {
65
+ key: "label",
66
+ fn: function() {
67
+ return [e._t("label")];
68
+ },
69
+ proxy: !0
70
+ }, {
71
+ key: "below",
72
+ fn: function() {
73
+ return [e._t("below")];
74
+ },
75
+ proxy: !0
76
+ }], null, !0)
77
+ }, "FormItem", e.formItemProps, !1));
78
+ }, h = [];
79
+ const d = Object.keys(a.props).filter((e) => !["value", "placeholder", "disabled"].includes(e)), y = {
80
+ name: "FormRadioGroup",
81
+ mixins: [n, s],
82
+ props: {
83
+ options: {
84
+ type: Array,
85
+ default: () => []
86
+ },
87
+ gender: Boolean,
88
+ overFlow: Boolean,
89
+ confirm: Boolean,
90
+ labelProp: {
91
+ type: String,
92
+ default: "name"
93
+ },
94
+ valueProp: {
95
+ type: String,
96
+ default: "code"
97
+ },
98
+ english: Boolean,
99
+ chinese: Boolean,
100
+ typing: Boolean,
101
+ classic: Boolean,
102
+ fillRow: Boolean,
103
+ ellipsis: Boolean,
104
+ inline: Boolean,
105
+ allowCancel: Boolean
106
+ },
107
+ computed: {
108
+ prefix() {
109
+ return "\u8BF7\u9009\u62E9";
110
+ },
111
+ inputProps() {
112
+ return u({ ...p(this.$attrs), ...this.$props }, d);
113
+ },
114
+ labelKey() {
115
+ return this.classic ? "label" : this.labelProp;
116
+ },
117
+ valueKey() {
118
+ return this.classic ? "value" : this.valueProp;
119
+ },
120
+ innerOptions() {
121
+ return this.gender ? [
122
+ {
123
+ [this.labelKey]: "\u7537",
124
+ [this.valueKey]: this.chinese ? "\u7537" : this.typing ? 1 : "1"
125
+ },
126
+ {
127
+ [this.labelKey]: "\u5973",
128
+ [this.valueKey]: this.chinese ? "\u5973" : this.typing ? 2 : "2"
129
+ }
130
+ ] : this.confirm ? [
131
+ {
132
+ [this.labelKey]: "\u662F",
133
+ [this.valueKey]: this.chinese ? "\u662F" : this.english ? "Y" : this.typing ? 1 : "1"
134
+ },
135
+ {
136
+ [this.labelKey]: "\u5426",
137
+ [this.valueKey]: this.chinese ? "\u5426" : this.english ? "N" : this.typing ? 0 : "0"
138
+ }
139
+ ] : this.options;
140
+ }
141
+ },
142
+ methods: {
143
+ emitInput(e) {
144
+ this.$emit("input", e);
145
+ },
146
+ toggle(e) {
147
+ this.value === e[this.valueKey] ? this.emitInput(null) : this.emitInput(e[this.valueKey]);
148
+ }
149
+ }
150
+ }, i = {};
151
+ var m = /* @__PURE__ */ c(
152
+ y,
153
+ f,
154
+ h,
155
+ !1,
156
+ _,
157
+ null,
158
+ null,
159
+ null
160
+ );
161
+ function _(e) {
162
+ for (let o in i)
163
+ this[o] = i[o];
164
+ }
165
+ const B = /* @__PURE__ */ function() {
166
+ return m.exports;
167
+ }();
168
+ export {
169
+ B as default
170
+ };
@@ -1 +1,154 @@
1
- var u=Object.defineProperty;var s=Object.getOwnPropertySymbols;var p=Object.prototype.hasOwnProperty,c=Object.prototype.propertyIsEnumerable;var o=(e,r,t)=>r in e?u(e,r,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[r]=t,n=(e,r)=>{for(var t in r||(r={}))p.call(r,t)&&o(e,t,r[t]);if(s)for(var t of s(r))c.call(r,t)&&o(e,t,r[t]);return e};import{f as h}from"../../chunks/a125d16c.js";import{f}from"../../chunks/23bd3525.js";import{Select as m}from"element-ui";import{i as y,n as _}from"../../chunks/8473fc69.js";import{n as d}from"../../chunks/6499de3a.js";var v=function(){var e=this,r=e.$createElement,t=e._self._c||r;return t("FormItem",e._b({attrs:{rules:e.computeRules,disabled:e.inputDisabled},scopedSlots:e._u([{key:"default",fn:function(){return[t("ElSelect",e._g(e._b({attrs:{value:e.value,filterable:e.filterable,placeholder:e.inputDisabled?"--":e.computePlaceholder,disabled:e.inputDisabled},on:{input:e.emitInput}},"ElSelect",e.inputProps,!1),e.listeners),e._l(e.innerOptions,function(l){return t("ElOption",{key:l[e.valueKey],attrs:{value:l[e.valueKey],label:l[e.labelKey]}})}),1),e.$slots.warn?t("div",{staticClass:"el-form-item__warn"},[e._t("warn")],2):e._e()]},proxy:!0},{key:"error",fn:function(l){var i=l.error;return[e.$scopedSlots.error&&e.$scopedSlots.error(i)?t("div",{staticClass:"el-form-item__error"},[e._t("error",function(){return[e._v(" "+e._s(i)+" ")]},{error:i})],2):e._e()]}},{key:"label",fn:function(){return[e._t("label")]},proxy:!0},{key:"below",fn:function(){return[e._t("below")]},proxy:!0}],null,!0)},"FormItem",e.formItemProps,!1))},b=[];const K=Object.keys(m.props).filter(e=>!["value","placeholder","disabled"].includes(e)),g={name:"FormSelect",mixins:[h,f],props:{options:{type:Array,default:()=>[]},gender:Boolean,all:Boolean,filterable:Boolean,confirm:Boolean,value:{type:[String,Number]},labelProp:{type:String,default:"name"},valueProp:{type:String,default:"code"},english:Boolean,chinese:Boolean,typing:Boolean,classic:Boolean},computed:{prefix(){return"\u8BF7\u9009\u62E9"},labelKey(){return this.classic?"label":this.labelProp},valueKey(){return this.classic?"value":this.valueProp},inputProps(){return y(n(n({},_(this.$attrs)),this.$props),K)},innerOptions(){return this.gender?[{[this.labelKey]:"\u7537",[this.valueKey]:this.chinese?"\u7537":this.typing?1:"1"},{[this.labelKey]:"\u5973",[this.valueKey]:this.chinese?"\u5973":this.typing?2:"2"}]:this.confirm?[{[this.labelKey]:"\u662F",[this.valueKey]:this.chinese?"\u662F":this.english?"Y":this.typing?1:"1"},{[this.labelKey]:"\u5426",[this.valueKey]:this.chinese?"\u5426":this.english?"N":this.typing?0:"0"}]:this.all?[{[this.valueKey]:"",[this.labelKey]:"\u5168\u90E8"},...this.options]:this.options}},methods:{emitInput(e){this.$emit("input",e)}}},a={};var S=d(g,v,b,!1,P,null,null,null);function P(e){for(let r in a)this[r]=a[r]}var x=function(){return S.exports}();export{x as default};
1
+ import { f as s } from "../../chunks/86bcadec.js";
2
+ import { f as o } from "../../chunks/a73fe8ee.js";
3
+ import { Select as a } from "element-ui";
4
+ import { i as u, n as p } from "../../chunks/2bd4e340.js";
5
+ import { n as c } from "../../chunks/6499de3a.js";
6
+ var h = function() {
7
+ var e = this, l = e.$createElement, t = e._self._c || l;
8
+ return t("FormItem", e._b({
9
+ attrs: {
10
+ rules: e.computeRules,
11
+ disabled: e.inputDisabled
12
+ },
13
+ scopedSlots: e._u([{
14
+ key: "default",
15
+ fn: function() {
16
+ return [t("ElSelect", e._g(e._b({
17
+ attrs: {
18
+ value: e.value,
19
+ filterable: e.filterable,
20
+ placeholder: e.inputDisabled ? "--" : e.computePlaceholder,
21
+ disabled: e.inputDisabled
22
+ },
23
+ on: {
24
+ input: e.emitInput
25
+ }
26
+ }, "ElSelect", e.inputProps, !1), e.listeners), e._l(e.innerOptions, function(r) {
27
+ return t("ElOption", {
28
+ key: r[e.valueKey],
29
+ attrs: {
30
+ value: r[e.valueKey],
31
+ label: r[e.labelKey]
32
+ }
33
+ });
34
+ }), 1), e.$slots.warn ? t("div", {
35
+ staticClass: "el-form-item__warn"
36
+ }, [e._t("warn")], 2) : e._e()];
37
+ },
38
+ proxy: !0
39
+ }, {
40
+ key: "error",
41
+ fn: function(r) {
42
+ var i = r.error;
43
+ return [e.$scopedSlots.error && e.$scopedSlots.error(i) ? t("div", {
44
+ staticClass: "el-form-item__error"
45
+ }, [e._t("error", function() {
46
+ return [e._v(" " + e._s(i) + " ")];
47
+ }, {
48
+ error: i
49
+ })], 2) : e._e()];
50
+ }
51
+ }, {
52
+ key: "label",
53
+ fn: function() {
54
+ return [e._t("label")];
55
+ },
56
+ proxy: !0
57
+ }, {
58
+ key: "below",
59
+ fn: function() {
60
+ return [e._t("below")];
61
+ },
62
+ proxy: !0
63
+ }], null, !0)
64
+ }, "FormItem", e.formItemProps, !1));
65
+ }, f = [];
66
+ const m = Object.keys(a.props).filter((e) => !["value", "placeholder", "disabled"].includes(e)), y = {
67
+ name: "FormSelect",
68
+ mixins: [s, o],
69
+ props: {
70
+ options: {
71
+ type: Array,
72
+ default: () => []
73
+ },
74
+ gender: Boolean,
75
+ all: Boolean,
76
+ filterable: Boolean,
77
+ confirm: Boolean,
78
+ value: {
79
+ type: [String, Number]
80
+ },
81
+ labelProp: {
82
+ type: String,
83
+ default: "name"
84
+ },
85
+ valueProp: {
86
+ type: String,
87
+ default: "code"
88
+ },
89
+ english: Boolean,
90
+ chinese: Boolean,
91
+ typing: Boolean,
92
+ classic: Boolean
93
+ },
94
+ computed: {
95
+ prefix() {
96
+ return "\u8BF7\u9009\u62E9";
97
+ },
98
+ labelKey() {
99
+ return this.classic ? "label" : this.labelProp;
100
+ },
101
+ valueKey() {
102
+ return this.classic ? "value" : this.valueProp;
103
+ },
104
+ inputProps() {
105
+ return u({ ...p(this.$attrs), ...this.$props }, m);
106
+ },
107
+ innerOptions() {
108
+ return this.gender ? [
109
+ {
110
+ [this.labelKey]: "\u7537",
111
+ [this.valueKey]: this.chinese ? "\u7537" : this.typing ? 1 : "1"
112
+ },
113
+ {
114
+ [this.labelKey]: "\u5973",
115
+ [this.valueKey]: this.chinese ? "\u5973" : this.typing ? 2 : "2"
116
+ }
117
+ ] : this.confirm ? [
118
+ {
119
+ [this.labelKey]: "\u662F",
120
+ [this.valueKey]: this.chinese ? "\u662F" : this.english ? "Y" : this.typing ? 1 : "1"
121
+ },
122
+ {
123
+ [this.labelKey]: "\u5426",
124
+ [this.valueKey]: this.chinese ? "\u5426" : this.english ? "N" : this.typing ? 0 : "0"
125
+ }
126
+ ] : this.all ? [{ [this.valueKey]: "", [this.labelKey]: "\u5168\u90E8" }, ...this.options] : this.options;
127
+ }
128
+ },
129
+ methods: {
130
+ emitInput(e) {
131
+ this.$emit("input", e);
132
+ }
133
+ }
134
+ }, n = {};
135
+ var _ = /* @__PURE__ */ c(
136
+ y,
137
+ h,
138
+ f,
139
+ !1,
140
+ d,
141
+ null,
142
+ null,
143
+ null
144
+ );
145
+ function d(e) {
146
+ for (let l in n)
147
+ this[l] = n[l];
148
+ }
149
+ const P = /* @__PURE__ */ function() {
150
+ return _.exports;
151
+ }();
152
+ export {
153
+ P as default
154
+ };
@@ -1 +1,97 @@
1
- var a=Object.defineProperty;var o=Object.getOwnPropertySymbols;var p=Object.prototype.hasOwnProperty,c=Object.prototype.propertyIsEnumerable;var l=(e,r,t)=>r in e?a(e,r,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[r]=t,n=(e,r)=>{for(var t in r||(r={}))p.call(r,t)&&l(e,t,r[t]);if(o)for(var t of o(r))c.call(r,t)&&l(e,t,r[t]);return e};import{f as m}from"../../chunks/a125d16c.js";import{Switch as d}from"element-ui";import{i as f,n as _}from"../../chunks/8473fc69.js";import{n as v}from"../../chunks/6499de3a.js";var h=function(){var e=this,r=e.$createElement,t=e._self._c||r;return t("FormItem",e._b({attrs:{rules:e.computeRules,disabled:e.inputDisabled},scopedSlots:e._u([{key:"default",fn:function(){return[e._t("default",function(){return[t("ElSwitch",e._g(e._b({class:{"is-readonly":e.readonly},attrs:{"active-value":"Y","inactive-value":"N",value:e.value,readonly:e.readonly,disabled:e.inputDisabled,placeholder:e.computePlaceholder},on:{input:e.emitInput},scopedSlots:e._u([{key:"append",fn:function(){return[e._t("append")]},proxy:!0}],null,!0)},"ElSwitch",e.inputProps,!1),e.listeners))]})]},proxy:!0},{key:"error",fn:function(u){var s=u.error;return[e._t("error",null,{error:s})]}},{key:"label",fn:function(){return[e._t("label")]},proxy:!0}],null,!0)},"FormItem",e.formItemProps,!1))},y=[];const b=Object.keys(d.props).filter(e=>!["value","placeholder","disabled"].includes(e)),S={name:"FormSwitch",mixins:[m],props:{value:{type:[String,Number,Boolean]}},computed:{inputProps(){return f(n(n({},_(this.$attrs)),this.$props),b)}},methods:{emitInput(e){this.$emit("input",e)}}},i={};var x=v(S,h,y,!1,I,null,null,null);function I(e){for(let r in i)this[r]=i[r]}var P=function(){return x.exports}();export{P as default};
1
+ import { f as i } from "../../chunks/86bcadec.js";
2
+ import { Switch as s } from "element-ui";
3
+ import { i as u, n as a } from "../../chunks/2bd4e340.js";
4
+ import { n as p } from "../../chunks/6499de3a.js";
5
+ var c = function() {
6
+ var e = this, t = e.$createElement, r = e._self._c || t;
7
+ return r("FormItem", e._b({
8
+ attrs: {
9
+ rules: e.computeRules,
10
+ disabled: e.inputDisabled
11
+ },
12
+ scopedSlots: e._u([{
13
+ key: "default",
14
+ fn: function() {
15
+ return [e._t("default", function() {
16
+ return [r("ElSwitch", e._g(e._b({
17
+ class: {
18
+ "is-readonly": e.readonly
19
+ },
20
+ attrs: {
21
+ "active-value": "Y",
22
+ "inactive-value": "N",
23
+ value: e.value,
24
+ readonly: e.readonly,
25
+ disabled: e.inputDisabled,
26
+ placeholder: e.computePlaceholder
27
+ },
28
+ on: {
29
+ input: e.emitInput
30
+ },
31
+ scopedSlots: e._u([{
32
+ key: "append",
33
+ fn: function() {
34
+ return [e._t("append")];
35
+ },
36
+ proxy: !0
37
+ }], null, !0)
38
+ }, "ElSwitch", e.inputProps, !1), e.listeners))];
39
+ })];
40
+ },
41
+ proxy: !0
42
+ }, {
43
+ key: "error",
44
+ fn: function(o) {
45
+ var l = o.error;
46
+ return [e._t("error", null, {
47
+ error: l
48
+ })];
49
+ }
50
+ }, {
51
+ key: "label",
52
+ fn: function() {
53
+ return [e._t("label")];
54
+ },
55
+ proxy: !0
56
+ }], null, !0)
57
+ }, "FormItem", e.formItemProps, !1));
58
+ }, m = [];
59
+ const d = Object.keys(s.props).filter((e) => !["value", "placeholder", "disabled"].includes(e)), f = {
60
+ name: "FormSwitch",
61
+ mixins: [i],
62
+ props: {
63
+ value: {
64
+ type: [String, Number, Boolean]
65
+ }
66
+ },
67
+ computed: {
68
+ inputProps() {
69
+ return u({ ...a(this.$attrs), ...this.$props }, d);
70
+ }
71
+ },
72
+ methods: {
73
+ emitInput(e) {
74
+ this.$emit("input", e);
75
+ }
76
+ }
77
+ }, n = {};
78
+ var _ = /* @__PURE__ */ p(
79
+ f,
80
+ c,
81
+ m,
82
+ !1,
83
+ v,
84
+ null,
85
+ null,
86
+ null
87
+ );
88
+ function v(e) {
89
+ for (let t in n)
90
+ this[t] = n[t];
91
+ }
92
+ const x = /* @__PURE__ */ function() {
93
+ return _.exports;
94
+ }();
95
+ export {
96
+ x as default
97
+ };