vxe-pc-ui 0.0.2 → 0.1.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/es/anchor/src/anchor.js +1 -1
- package/es/anchor-link/index.js +1 -1
- package/es/{button-group → button}/src/button-group.js +2 -2
- package/es/button/src/button.js +3 -3
- package/es/button/style.css +17 -17
- package/es/button/style.min.css +1 -1
- package/es/button-group/index.js +1 -1
- package/es/checkbox/index.js +10 -0
- package/es/checkbox/src/checkbox.js +116 -0
- package/es/checkbox/src/group.js +108 -0
- package/es/checkbox/style.css +107 -0
- package/es/checkbox/style.min.css +1 -0
- package/es/checkbox-group/index.js +10 -0
- package/es/col/index.js +1 -1
- package/es/components.js +98 -35
- package/es/dynamics/index.js +27 -0
- package/es/form/index.js +8 -0
- package/es/form/src/form-config-item.js +178 -0
- package/es/form/src/form-gather.js +47 -0
- package/es/form/src/form-item.js +228 -0
- package/es/form/src/form.js +665 -0
- package/es/form/src/itemInfo.js +39 -0
- package/es/form/src/render.js +68 -0
- package/es/form/src/util.js +65 -0
- package/es/form/style.css +321 -0
- package/es/form/style.min.css +1 -0
- package/es/form-design/index.js +8 -0
- package/es/form-design/src/form-design.js +79 -0
- package/es/form-design/src/setting.js +12 -0
- package/es/form-design/src/util.js +8 -0
- package/es/form-design/src/view.js +113 -0
- package/es/form-design/src/widget.js +104 -0
- package/es/form-design/style.css +97 -0
- package/es/form-design/style.min.css +1 -0
- package/es/form-gather/index.js +8 -0
- package/es/form-item/index.js +8 -0
- package/es/icon/style.css +540 -1
- package/es/icon/style.min.css +1 -1
- package/es/input/index.js +10 -0
- package/es/input/src/date.js +41 -0
- package/es/input/src/input.js +2333 -0
- package/es/input/src/number.js +10 -0
- package/es/input/style.css +1000 -0
- package/es/input/style.min.css +1 -0
- package/es/layout-aside/style.css +1 -0
- package/es/layout-aside/style.min.css +1 -1
- package/es/layout-body/style.css +1 -0
- package/es/layout-body/style.min.css +1 -1
- package/es/layout-footer/style.css +1 -0
- package/es/layout-footer/style.min.css +1 -1
- package/es/layout-header/style.css +1 -0
- package/es/layout-header/style.min.css +1 -1
- package/es/list-design/index.js +8 -0
- package/es/{design/src/design.js → list-design/src/list-design.js} +7 -7
- package/es/loading/index.js +8 -0
- package/es/loading/src/loading.js +53 -0
- package/es/loading/style.css +75 -0
- package/es/loading/style.min.css +1 -0
- package/es/modal/index.js +96 -0
- package/es/modal/src/modal.js +876 -0
- package/es/modal/style.css +323 -0
- package/es/modal/style.min.css +1 -0
- package/es/optgroup/index.js +10 -0
- package/es/optgroup/style.css +0 -0
- package/es/optgroup/style.min.css +0 -0
- package/es/option/index.js +10 -0
- package/es/option/style.css +0 -0
- package/es/option/style.min.css +0 -0
- package/es/pager/index.js +10 -0
- package/es/pager/src/pager.js +539 -0
- package/es/pager/style.css +319 -0
- package/es/pager/style.min.css +1 -0
- package/es/pulldown/index.js +10 -0
- package/es/pulldown/src/pulldown.js +328 -0
- package/es/pulldown/style.css +57 -0
- package/es/pulldown/style.min.css +1 -0
- package/es/radio/index.js +10 -0
- package/es/radio/src/button.js +113 -0
- package/es/radio/src/group.js +93 -0
- package/es/radio/src/radio.js +118 -0
- package/es/radio/style.css +143 -0
- package/es/radio/style.min.css +1 -0
- package/es/radio-button/index.js +10 -0
- package/es/radio-button/style.css +0 -0
- package/es/radio-button/style.min.css +0 -0
- package/es/radio-group/index.js +10 -0
- package/es/radio-group/style.css +0 -0
- package/es/radio-group/style.min.css +0 -0
- package/es/select/index.js +10 -0
- package/es/select/src/optgroup.js +31 -0
- package/es/select/src/option.js +31 -0
- package/es/select/src/optionInfo.js +16 -0
- package/es/select/src/select.js +992 -0
- package/es/select/src/util.js +36 -0
- package/es/select/style.css +201 -0
- package/es/select/style.min.css +1 -0
- package/es/style.css +1 -1
- package/es/style.min.css +1 -1
- package/es/switch/index.js +10 -0
- package/es/switch/src/switch.js +151 -0
- package/es/switch/style.css +97 -0
- package/es/switch/style.min.css +1 -0
- package/es/textarea/index.js +10 -0
- package/es/textarea/src/textarea.js +245 -0
- package/es/textarea/style.css +102 -0
- package/es/textarea/style.min.css +1 -0
- package/es/tooltip/index.js +8 -0
- package/es/tooltip/src/tooltip.js +336 -0
- package/es/tooltip/style.css +103 -0
- package/es/tooltip/style.min.css +1 -0
- package/es/ui/src/core.js +12 -2
- package/es/ui/src/dom.js +20 -0
- package/es/ui/src/globalStore.js +119 -4
- package/es/ui/src/i18n.js +7 -0
- package/es/ui/src/log.js +2 -2
- package/es/ui/src/renderer.js +67 -0
- package/es/ui/src/store.js +41 -0
- package/es/ui/src/utils.js +10 -0
- package/es/ui/src/validators.js +5 -0
- package/es/ui/src/vn.js +10 -0
- package/es/vxe-button/style.css +17 -17
- package/es/vxe-button/style.min.css +1 -1
- package/es/vxe-checkbox/index.js +3 -0
- package/es/vxe-checkbox/style.css +107 -0
- package/es/vxe-checkbox/style.min.css +1 -0
- package/es/vxe-checkbox-group/index.js +3 -0
- package/es/vxe-checkbox-group/style.css +0 -0
- package/es/vxe-checkbox-group/style.min.css +0 -0
- package/es/vxe-form/index.js +3 -0
- package/es/vxe-form/style.css +321 -0
- package/es/vxe-form/style.min.css +1 -0
- package/es/vxe-form-design/index.js +3 -0
- package/es/vxe-form-design/style.css +97 -0
- package/es/vxe-form-design/style.min.css +1 -0
- package/es/vxe-form-gather/index.js +3 -0
- package/es/vxe-form-gather/style.css +0 -0
- package/es/vxe-form-gather/style.min.css +0 -0
- package/es/vxe-form-item/index.js +3 -0
- package/es/vxe-form-item/style.css +0 -0
- package/es/vxe-form-item/style.min.css +0 -0
- package/es/vxe-icon/style.css +540 -1
- package/es/vxe-icon/style.min.css +1 -1
- package/es/vxe-input/index.js +3 -0
- package/es/vxe-input/style.css +1000 -0
- package/es/vxe-input/style.min.css +1 -0
- package/es/vxe-layout-aside/style.css +1 -0
- package/es/vxe-layout-aside/style.min.css +1 -1
- package/es/vxe-layout-body/style.css +1 -0
- package/es/vxe-layout-body/style.min.css +1 -1
- package/es/vxe-layout-footer/style.css +1 -0
- package/es/vxe-layout-footer/style.min.css +1 -1
- package/es/vxe-layout-header/style.css +1 -0
- package/es/vxe-layout-header/style.min.css +1 -1
- package/es/vxe-list-design/index.js +3 -0
- package/es/vxe-list-design/style.css +0 -0
- package/es/vxe-list-design/style.min.css +0 -0
- package/es/vxe-loading/index.js +3 -0
- package/es/vxe-loading/style.css +75 -0
- package/es/vxe-loading/style.min.css +1 -0
- package/es/vxe-modal/index.js +3 -0
- package/es/vxe-modal/style.css +323 -0
- package/es/vxe-modal/style.min.css +1 -0
- package/es/vxe-optgroup/index.js +3 -0
- package/es/vxe-optgroup/style.css +0 -0
- package/es/vxe-optgroup/style.min.css +0 -0
- package/es/vxe-option/index.js +3 -0
- package/es/vxe-option/style.css +0 -0
- package/es/vxe-option/style.min.css +0 -0
- package/es/vxe-pager/index.js +3 -0
- package/es/vxe-pager/style.css +319 -0
- package/es/vxe-pager/style.min.css +1 -0
- package/es/vxe-pulldown/index.js +3 -0
- package/es/vxe-pulldown/style.css +57 -0
- package/es/vxe-pulldown/style.min.css +1 -0
- package/es/vxe-radio/index.js +3 -0
- package/es/vxe-radio/style.css +143 -0
- package/es/vxe-radio/style.min.css +1 -0
- package/es/vxe-radio-button/index.js +3 -0
- package/es/vxe-radio-button/style.css +0 -0
- package/es/vxe-radio-button/style.min.css +0 -0
- package/es/vxe-radio-group/index.js +3 -0
- package/es/vxe-radio-group/style.css +0 -0
- package/es/vxe-radio-group/style.min.css +0 -0
- package/es/vxe-select/index.js +3 -0
- package/es/vxe-select/style.css +201 -0
- package/es/vxe-select/style.min.css +1 -0
- package/es/vxe-switch/index.js +3 -0
- package/es/vxe-switch/style.css +97 -0
- package/es/vxe-switch/style.min.css +1 -0
- package/es/vxe-textarea/index.js +3 -0
- package/es/vxe-textarea/style.css +102 -0
- package/es/vxe-textarea/style.min.css +1 -0
- package/es/vxe-tooltip/index.js +3 -0
- package/es/vxe-tooltip/style.css +103 -0
- package/es/vxe-tooltip/style.min.css +1 -0
- package/lib/anchor/src/anchor.js +1 -1
- package/lib/anchor/src/anchor.min.js +1 -1
- package/lib/anchor-link/index.js +1 -1
- package/lib/anchor-link/index.min.js +1 -1
- package/lib/{button-group → button}/src/button-group.js +2 -2
- package/lib/button/src/button-group.min.js +1 -0
- package/lib/button/src/button.js +3 -3
- package/lib/button/src/button.min.js +1 -1
- package/lib/button/style/style.css +17 -17
- package/lib/button/style/style.min.css +1 -1
- package/lib/button-group/index.js +1 -1
- package/lib/button-group/index.min.js +1 -1
- package/lib/checkbox/index.js +17 -0
- package/lib/checkbox/index.min.js +1 -0
- package/lib/checkbox/src/checkbox.js +144 -0
- package/lib/checkbox/src/checkbox.min.js +1 -0
- package/lib/checkbox/src/group.js +129 -0
- package/lib/checkbox/src/group.min.js +1 -0
- package/lib/checkbox/style/style.css +107 -0
- package/lib/checkbox/style/style.min.css +1 -0
- package/lib/checkbox-group/index.js +17 -0
- package/lib/checkbox-group/index.min.js +1 -0
- package/lib/checkbox-group/style/style.css +0 -0
- package/lib/checkbox-group/style/style.min.css +0 -0
- package/lib/col/index.js +1 -1
- package/lib/col/index.min.js +1 -1
- package/lib/components.js +290 -63
- package/lib/components.min.js +1 -1
- package/lib/dynamics/index.js +36 -0
- package/lib/dynamics/index.min.js +1 -0
- package/lib/form/index.js +15 -0
- package/lib/form/index.min.js +1 -0
- package/lib/form/src/form-config-item.js +192 -0
- package/lib/form/src/form-config-item.min.js +1 -0
- package/lib/form/src/form-gather.js +57 -0
- package/lib/form/src/form-gather.min.js +1 -0
- package/lib/form/src/form-item.js +247 -0
- package/lib/form/src/form-item.min.js +1 -0
- package/lib/form/src/form.js +768 -0
- package/lib/form/src/form.min.js +1 -0
- package/lib/form/src/itemInfo.js +47 -0
- package/lib/form/src/itemInfo.min.js +1 -0
- package/lib/form/src/render.js +84 -0
- package/lib/form/src/render.min.js +1 -0
- package/lib/form/src/util.js +108 -0
- package/lib/form/src/util.min.js +1 -0
- package/lib/form/style/index.js +1 -0
- package/lib/form/style/style.css +321 -0
- package/lib/form/style/style.min.css +1 -0
- package/lib/form-design/index.js +15 -0
- package/lib/form-design/index.min.js +1 -0
- package/lib/form-design/src/form-design.js +87 -0
- package/lib/form-design/src/form-design.min.js +1 -0
- package/lib/form-design/src/setting.js +18 -0
- package/lib/form-design/src/setting.min.js +1 -0
- package/lib/form-design/src/util.js +17 -0
- package/lib/form-design/src/util.min.js +1 -0
- package/lib/form-design/src/view.js +147 -0
- package/lib/form-design/src/view.min.js +1 -0
- package/lib/form-design/src/widget.js +114 -0
- package/lib/form-design/src/widget.min.js +1 -0
- package/lib/form-design/style/index.js +1 -0
- package/lib/form-design/style/style.css +97 -0
- package/lib/form-design/style/style.min.css +1 -0
- package/lib/form-gather/index.js +15 -0
- package/lib/form-gather/index.min.js +1 -0
- package/lib/form-gather/style/index.js +1 -0
- package/lib/form-gather/style/style.css +0 -0
- package/lib/form-gather/style/style.min.css +0 -0
- package/lib/form-item/index.js +15 -0
- package/lib/form-item/index.min.js +1 -0
- package/lib/form-item/style/index.js +1 -0
- package/lib/form-item/style/style.css +0 -0
- package/lib/form-item/style/style.min.css +0 -0
- package/lib/icon/style/style.css +540 -1
- package/lib/icon/style/style.min.css +1 -1
- package/lib/index.umd.js +10741 -782
- package/lib/index.umd.min.js +1 -1
- package/lib/input/index.js +17 -0
- package/lib/input/index.min.js +1 -0
- package/lib/input/src/date.js +46 -0
- package/lib/input/src/date.min.js +1 -0
- package/lib/input/src/input.js +2546 -0
- package/lib/input/src/input.min.js +1 -0
- package/lib/input/src/number.js +18 -0
- package/lib/input/src/number.min.js +1 -0
- package/lib/input/style/index.js +1 -0
- package/lib/input/style/style.css +1000 -0
- package/lib/input/style/style.min.css +1 -0
- package/lib/layout-aside/style/style.css +1 -0
- package/lib/layout-aside/style/style.min.css +1 -1
- package/lib/layout-body/style/style.css +1 -0
- package/lib/layout-body/style/style.min.css +1 -1
- package/lib/layout-footer/style/style.css +1 -0
- package/lib/layout-footer/style/style.min.css +1 -1
- package/lib/layout-header/style/style.css +1 -0
- package/lib/layout-header/style/style.min.css +1 -1
- package/lib/list-design/index.js +15 -0
- package/lib/list-design/index.min.js +1 -0
- package/lib/{design/src/design.js → list-design/src/list-design.js} +7 -7
- package/lib/list-design/src/list-design.min.js +1 -0
- package/lib/list-design/style/index.js +1 -0
- package/lib/list-design/style/style.css +0 -0
- package/lib/list-design/style/style.min.css +0 -0
- package/lib/loading/index.js +15 -0
- package/lib/loading/index.min.js +1 -0
- package/lib/loading/src/loading.js +49 -0
- package/lib/loading/src/loading.min.js +1 -0
- package/lib/loading/style/index.js +1 -0
- package/lib/loading/style/style.css +75 -0
- package/lib/loading/style/style.min.css +1 -0
- package/lib/modal/index.js +110 -0
- package/lib/modal/index.min.js +1 -0
- package/lib/modal/src/modal.js +1064 -0
- package/lib/modal/src/modal.min.js +1 -0
- package/lib/modal/style/index.js +1 -0
- package/lib/modal/style/style.css +323 -0
- package/lib/modal/style/style.min.css +1 -0
- package/lib/optgroup/index.js +17 -0
- package/lib/optgroup/index.min.js +1 -0
- package/lib/optgroup/style/index.js +1 -0
- package/lib/optgroup/style/style.css +0 -0
- package/lib/optgroup/style/style.min.css +0 -0
- package/lib/option/index.js +17 -0
- package/lib/option/index.min.js +1 -0
- package/lib/option/style/index.js +1 -0
- package/lib/option/style/style.css +0 -0
- package/lib/option/style/style.min.css +0 -0
- package/lib/pager/index.js +17 -0
- package/lib/pager/index.min.js +1 -0
- package/lib/pager/src/pager.js +593 -0
- package/lib/pager/src/pager.min.js +1 -0
- package/lib/pager/style/index.js +1 -0
- package/lib/pager/style/style.css +319 -0
- package/lib/pager/style/style.min.css +1 -0
- package/lib/pulldown/index.js +17 -0
- package/lib/pulldown/index.min.js +1 -0
- package/lib/pulldown/src/pulldown.js +359 -0
- package/lib/pulldown/src/pulldown.min.js +1 -0
- package/lib/pulldown/style/index.js +1 -0
- package/lib/pulldown/style/style.css +57 -0
- package/lib/pulldown/style/style.min.css +1 -0
- package/lib/radio/index.js +17 -0
- package/lib/radio/index.min.js +1 -0
- package/lib/radio/src/button.js +135 -0
- package/lib/radio/src/button.min.js +1 -0
- package/lib/radio/src/group.js +108 -0
- package/lib/radio/src/group.min.js +1 -0
- package/lib/radio/src/radio.js +139 -0
- package/lib/radio/src/radio.min.js +1 -0
- package/lib/radio/style/index.js +1 -0
- package/lib/radio/style/style.css +143 -0
- package/lib/radio/style/style.min.css +1 -0
- package/lib/radio-button/index.js +17 -0
- package/lib/radio-button/index.min.js +1 -0
- package/lib/radio-button/style/index.js +1 -0
- package/lib/radio-button/style/style.css +0 -0
- package/lib/radio-button/style/style.min.css +0 -0
- package/lib/radio-group/index.js +17 -0
- package/lib/radio-group/index.min.js +1 -0
- package/lib/radio-group/style/index.js +1 -0
- package/lib/radio-group/style/style.css +0 -0
- package/lib/radio-group/style/style.min.css +0 -0
- package/lib/select/index.js +17 -0
- package/lib/select/index.min.js +1 -0
- package/lib/select/src/optgroup.js +47 -0
- package/lib/select/src/optgroup.min.js +1 -0
- package/lib/select/src/option.js +45 -0
- package/lib/select/src/option.min.js +1 -0
- package/lib/select/src/optionInfo.js +24 -0
- package/lib/select/src/optionInfo.min.js +1 -0
- package/lib/select/src/select.js +1104 -0
- package/lib/select/src/select.min.js +1 -0
- package/lib/select/src/util.js +57 -0
- package/lib/select/src/util.min.js +1 -0
- package/lib/select/style/index.js +1 -0
- package/lib/select/style/style.css +201 -0
- package/lib/select/style/style.min.css +1 -0
- package/lib/style.css +1 -1
- package/lib/style.min.css +1 -1
- package/lib/switch/index.js +17 -0
- package/lib/switch/index.min.js +1 -0
- package/lib/switch/src/switch.js +161 -0
- package/lib/switch/src/switch.min.js +1 -0
- package/lib/switch/style/index.js +1 -0
- package/lib/switch/style/style.css +97 -0
- package/lib/switch/style/style.min.css +1 -0
- package/lib/textarea/index.js +17 -0
- package/lib/textarea/index.min.js +1 -0
- package/lib/textarea/src/textarea.js +298 -0
- package/lib/textarea/src/textarea.min.js +1 -0
- package/lib/textarea/style/index.js +1 -0
- package/lib/textarea/style/style.css +102 -0
- package/lib/textarea/style/style.min.css +1 -0
- package/lib/tooltip/index.js +15 -0
- package/lib/tooltip/index.min.js +1 -0
- package/lib/tooltip/src/tooltip.js +418 -0
- package/lib/tooltip/src/tooltip.min.js +1 -0
- package/lib/tooltip/style/index.js +1 -0
- package/lib/tooltip/style/style.css +103 -0
- package/lib/tooltip/style/style.min.css +1 -0
- package/lib/ui/src/core.js +49 -2
- package/lib/ui/src/core.min.js +1 -1
- package/lib/ui/src/dom.js +22 -0
- package/lib/ui/src/dom.min.js +1 -1
- package/lib/ui/src/globalStore.js +119 -4
- package/lib/ui/src/globalStore.min.js +1 -1
- package/lib/ui/src/i18n.js +14 -0
- package/lib/ui/src/i18n.min.js +1 -0
- package/lib/ui/src/log.js +2 -3
- package/lib/ui/src/log.min.js +1 -1
- package/lib/ui/src/renderer.js +77 -0
- package/lib/ui/src/renderer.min.js +1 -0
- package/lib/ui/src/store.js +49 -0
- package/lib/ui/src/store.min.js +1 -0
- package/lib/ui/src/utils.js +12 -0
- package/lib/ui/src/utils.min.js +1 -1
- package/lib/ui/src/validators.js +14 -0
- package/lib/ui/src/validators.min.js +1 -0
- package/lib/ui/src/vn.js +18 -0
- package/lib/ui/src/vn.min.js +1 -0
- package/lib/vxe-button/style/style.css +17 -17
- package/lib/vxe-button/style/style.min.css +1 -1
- package/lib/vxe-checkbox/index.js +22 -0
- package/lib/vxe-checkbox/index.min.js +1 -0
- package/lib/vxe-checkbox/style/index.js +1 -0
- package/lib/vxe-checkbox/style/style.css +107 -0
- package/lib/vxe-checkbox/style/style.min.css +1 -0
- package/lib/vxe-checkbox-group/index.js +22 -0
- package/lib/vxe-checkbox-group/index.min.js +1 -0
- package/lib/vxe-checkbox-group/style/index.js +1 -0
- package/lib/vxe-checkbox-group/style/style.css +0 -0
- package/lib/vxe-checkbox-group/style/style.min.css +0 -0
- package/lib/{vxe-design → vxe-form}/index.js +5 -5
- package/lib/vxe-form/index.min.js +1 -0
- package/lib/vxe-form/style/index.js +1 -0
- package/lib/vxe-form/style/style.css +321 -0
- package/lib/vxe-form/style/style.min.css +1 -0
- package/lib/vxe-form-design/index.js +22 -0
- package/lib/vxe-form-design/index.min.js +1 -0
- package/lib/vxe-form-design/style/index.js +1 -0
- package/lib/vxe-form-design/style/style.css +97 -0
- package/lib/vxe-form-design/style/style.min.css +1 -0
- package/lib/vxe-form-gather/index.js +22 -0
- package/lib/vxe-form-gather/index.min.js +1 -0
- package/lib/vxe-form-gather/style/index.js +1 -0
- package/lib/vxe-form-gather/style/style.css +0 -0
- package/lib/vxe-form-gather/style/style.min.css +0 -0
- package/lib/vxe-form-item/index.js +22 -0
- package/lib/vxe-form-item/index.min.js +1 -0
- package/lib/vxe-form-item/style/index.js +1 -0
- package/lib/vxe-form-item/style/style.css +0 -0
- package/lib/vxe-form-item/style/style.min.css +0 -0
- package/lib/vxe-icon/style/style.css +540 -1
- package/lib/vxe-icon/style/style.min.css +1 -1
- package/lib/vxe-input/index.js +22 -0
- package/lib/vxe-input/index.min.js +1 -0
- package/lib/vxe-input/style/index.js +1 -0
- package/lib/vxe-input/style/style.css +1000 -0
- package/lib/vxe-input/style/style.min.css +1 -0
- package/lib/vxe-layout-aside/style/style.css +1 -0
- package/lib/vxe-layout-aside/style/style.min.css +1 -1
- package/lib/vxe-layout-body/style/style.css +1 -0
- package/lib/vxe-layout-body/style/style.min.css +1 -1
- package/lib/vxe-layout-footer/style/style.css +1 -0
- package/lib/vxe-layout-footer/style/style.min.css +1 -1
- package/lib/vxe-layout-header/style/style.css +1 -0
- package/lib/vxe-layout-header/style/style.min.css +1 -1
- package/lib/vxe-list-design/index.js +22 -0
- package/lib/vxe-list-design/index.min.js +1 -0
- package/lib/vxe-list-design/style/index.js +1 -0
- package/lib/vxe-list-design/style/style.css +0 -0
- package/lib/vxe-list-design/style/style.min.css +0 -0
- package/lib/vxe-loading/index.js +22 -0
- package/lib/vxe-loading/index.min.js +1 -0
- package/lib/vxe-loading/style/index.js +1 -0
- package/lib/vxe-loading/style/style.css +75 -0
- package/lib/vxe-loading/style/style.min.css +1 -0
- package/lib/vxe-modal/index.js +22 -0
- package/lib/vxe-modal/index.min.js +1 -0
- package/lib/vxe-modal/style/index.js +1 -0
- package/lib/vxe-modal/style/style.css +323 -0
- package/lib/vxe-modal/style/style.min.css +1 -0
- package/lib/vxe-optgroup/index.js +22 -0
- package/lib/vxe-optgroup/index.min.js +1 -0
- package/lib/vxe-optgroup/style/index.js +1 -0
- package/lib/vxe-optgroup/style/style.css +0 -0
- package/lib/vxe-optgroup/style/style.min.css +0 -0
- package/lib/vxe-option/index.js +22 -0
- package/lib/vxe-option/index.min.js +1 -0
- package/lib/vxe-option/style/index.js +1 -0
- package/lib/vxe-option/style/style.css +0 -0
- package/lib/vxe-option/style/style.min.css +0 -0
- package/lib/vxe-pager/index.js +22 -0
- package/lib/vxe-pager/index.min.js +1 -0
- package/lib/vxe-pager/style/index.js +1 -0
- package/lib/vxe-pager/style/style.css +319 -0
- package/lib/vxe-pager/style/style.min.css +1 -0
- package/lib/vxe-pulldown/index.js +22 -0
- package/lib/vxe-pulldown/index.min.js +1 -0
- package/lib/vxe-pulldown/style/index.js +1 -0
- package/lib/vxe-pulldown/style/style.css +57 -0
- package/lib/vxe-pulldown/style/style.min.css +1 -0
- package/lib/vxe-radio/index.js +22 -0
- package/lib/vxe-radio/index.min.js +1 -0
- package/lib/vxe-radio/style/index.js +1 -0
- package/lib/vxe-radio/style/style.css +143 -0
- package/lib/vxe-radio/style/style.min.css +1 -0
- package/lib/vxe-radio-button/index.js +22 -0
- package/lib/vxe-radio-button/index.min.js +1 -0
- package/lib/vxe-radio-button/style/index.js +1 -0
- package/lib/vxe-radio-button/style/style.css +0 -0
- package/lib/vxe-radio-button/style/style.min.css +0 -0
- package/lib/vxe-radio-group/index.js +22 -0
- package/lib/vxe-radio-group/index.min.js +1 -0
- package/lib/vxe-radio-group/style/index.js +1 -0
- package/lib/vxe-radio-group/style/style.css +0 -0
- package/lib/vxe-radio-group/style/style.min.css +0 -0
- package/lib/vxe-select/index.js +22 -0
- package/lib/vxe-select/index.min.js +1 -0
- package/lib/vxe-select/style/index.js +1 -0
- package/lib/vxe-select/style/style.css +201 -0
- package/lib/vxe-select/style/style.min.css +1 -0
- package/lib/vxe-switch/index.js +22 -0
- package/lib/vxe-switch/index.min.js +1 -0
- package/lib/vxe-switch/style/index.js +1 -0
- package/lib/vxe-switch/style/style.css +97 -0
- package/lib/vxe-switch/style/style.min.css +1 -0
- package/lib/vxe-textarea/index.js +22 -0
- package/lib/vxe-textarea/index.min.js +1 -0
- package/lib/vxe-textarea/style/index.js +1 -0
- package/lib/vxe-textarea/style/style.css +102 -0
- package/lib/vxe-textarea/style/style.min.css +1 -0
- package/lib/vxe-tooltip/index.js +22 -0
- package/lib/vxe-tooltip/index.min.js +1 -0
- package/lib/vxe-tooltip/style/index.js +1 -0
- package/lib/vxe-tooltip/style/style.css +103 -0
- package/lib/vxe-tooltip/style/style.min.css +1 -0
- package/package.json +1 -1
- package/packages/anchor/src/anchor.ts +1 -1
- package/packages/anchor-link/index.ts +1 -1
- package/packages/{button-group → button}/src/button-group.ts +2 -2
- package/packages/button/src/button.ts +3 -3
- package/packages/button-group/index.ts +1 -1
- package/packages/checkbox/index.ts +15 -0
- package/packages/checkbox/src/checkbox.ts +131 -0
- package/packages/checkbox/src/group.ts +127 -0
- package/packages/checkbox-group/index.ts +15 -0
- package/packages/col/index.ts +1 -1
- package/packages/components.ts +100 -35
- package/packages/dynamics/index.ts +34 -0
- package/packages/form/index.ts +11 -0
- package/packages/form/src/form-config-item.ts +193 -0
- package/packages/form/src/form-gather.ts +60 -0
- package/packages/form/src/form-item.ts +253 -0
- package/packages/form/src/form.ts +716 -0
- package/packages/form/src/itemInfo.ts +43 -0
- package/packages/form/src/render.ts +83 -0
- package/packages/form/src/util.ts +79 -0
- package/packages/form-design/index.ts +11 -0
- package/packages/form-design/src/form-design.ts +99 -0
- package/packages/form-design/src/setting.ts +13 -0
- package/packages/form-design/src/util.ts +10 -0
- package/packages/form-design/src/view.ts +125 -0
- package/packages/form-design/src/widget.ts +117 -0
- package/packages/form-gather/index.ts +11 -0
- package/packages/form-item/index.ts +11 -0
- package/packages/icon/src/icon.ts +1 -1
- package/packages/input/index.ts +15 -0
- package/packages/input/src/date.ts +42 -0
- package/packages/input/src/input.ts +2480 -0
- package/packages/input/src/number.ts +12 -0
- package/packages/list-design/index.ts +11 -0
- package/packages/list-design/src/list-design.ts +55 -0
- package/packages/loading/index.ts +11 -0
- package/packages/loading/src/loading.ts +56 -0
- package/packages/modal/index.ts +110 -0
- package/packages/modal/src/modal.ts +950 -0
- package/packages/optgroup/index.ts +15 -0
- package/packages/option/index.ts +15 -0
- package/packages/pager/index.ts +15 -0
- package/packages/pager/src/pager.ts +595 -0
- package/packages/pulldown/index.ts +15 -0
- package/packages/pulldown/src/pulldown.ts +349 -0
- package/packages/radio/index.ts +15 -0
- package/packages/radio/src/button.ts +132 -0
- package/packages/radio/src/group.ts +110 -0
- package/packages/radio/src/radio.ts +137 -0
- package/packages/radio-button/index.ts +15 -0
- package/packages/radio-group/index.ts +15 -0
- package/packages/select/index.ts +15 -0
- package/packages/select/src/optgroup.ts +39 -0
- package/packages/select/src/option.ts +38 -0
- package/packages/select/src/optionInfo.ts +20 -0
- package/packages/select/src/select.ts +1034 -0
- package/packages/select/src/util.ts +47 -0
- package/packages/switch/index.ts +15 -0
- package/packages/switch/src/switch.ts +171 -0
- package/packages/textarea/index.ts +15 -0
- package/packages/textarea/src/textarea.ts +273 -0
- package/packages/tooltip/index.ts +11 -0
- package/packages/tooltip/src/tooltip.ts +360 -0
- package/packages/ui/src/core.ts +13 -1
- package/packages/ui/src/dom.ts +23 -0
- package/packages/ui/src/globalStore.ts +122 -5
- package/packages/ui/src/i18n.ts +8 -0
- package/packages/ui/src/log.ts +2 -2
- package/packages/ui/src/renderer.ts +71 -0
- package/packages/ui/src/store.ts +49 -0
- package/packages/ui/src/utils.ts +12 -0
- package/packages/ui/src/validators.ts +9 -0
- package/packages/ui/src/vn.ts +14 -0
- package/styles/all.scss +30 -10
- package/styles/base/common.scss +13 -0
- package/styles/components/button.scss +8 -8
- package/styles/components/checkbox-group.scss +0 -0
- package/styles/components/checkbox.scss +91 -0
- package/styles/components/form-design.scss +93 -0
- package/styles/components/form-gather.scss +0 -0
- package/styles/components/form-item.scss +0 -0
- package/styles/components/form.scss +339 -0
- package/styles/components/icon.scss +3 -1
- package/styles/components/input.scss +911 -0
- package/styles/components/layout-aside.scss +1 -0
- package/styles/components/layout-body.scss +1 -0
- package/styles/components/layout-footer.scss +1 -0
- package/styles/components/layout-header.scss +1 -0
- package/styles/components/list-design.scss +0 -0
- package/styles/components/list.scss +26 -0
- package/styles/components/loading.scss +84 -0
- package/styles/components/modal.scss +383 -0
- package/styles/components/old-icon.scss +712 -0
- package/styles/components/optgroup.scss +0 -0
- package/styles/components/option.scss +0 -0
- package/styles/components/pager.scss +287 -0
- package/styles/components/pulldown.scss +55 -0
- package/styles/components/radio-button.scss +0 -0
- package/styles/components/radio-group.scss +0 -0
- package/styles/components/radio.scss +149 -0
- package/styles/components/select.scss +226 -0
- package/styles/components/switch.scss +113 -0
- package/styles/components/textarea.scss +102 -0
- package/styles/components/tooltip.scss +124 -0
- package/styles/helpers/mixin.scss +12 -12
- package/styles/theme/base.scss +143 -6
- package/types/all.d.ts +66 -33
- package/types/{component → components}/anchor-link.d.ts +17 -2
- package/types/{component → components}/anchor.d.ts +10 -2
- package/types/{component → components}/breadcrumb-item.d.ts +12 -1
- package/types/{component → components}/breadcrumb.d.ts +10 -2
- package/types/{component → components}/button-group.d.ts +11 -3
- package/types/{component → components}/button.d.ts +14 -3
- package/types/components/checkbox-group.d.ts +112 -0
- package/types/components/checkbox.d.ts +119 -0
- package/types/{component → components}/col.d.ts +9 -1
- package/types/components/form-design.d.ts +88 -0
- package/types/components/form-gather.d.ts +75 -0
- package/types/components/form-item.d.ts +231 -0
- package/types/components/form.d.ts +349 -0
- package/types/{component → components}/icon.d.ts +7 -2
- package/types/components/input.d.ts +375 -0
- package/types/{component → components}/layout-aside.d.ts +10 -2
- package/types/{component → components}/layout-body.d.ts +10 -2
- package/types/{component → components}/layout-container.d.ts +10 -2
- package/types/{component → components}/layout-footer.d.ts +10 -2
- package/types/{component → components}/layout-header.d.ts +7 -1
- package/types/components/list-design.d.ts +67 -0
- package/types/components/loading.d.ts +66 -0
- package/types/components/modal.d.ts +381 -0
- package/types/components/optgroup.d.ts +80 -0
- package/types/components/option.d.ts +99 -0
- package/types/components/pager.d.ts +208 -0
- package/types/components/pulldown.d.ts +134 -0
- package/types/components/radio-button.d.ts +99 -0
- package/types/components/radio-group.d.ts +107 -0
- package/types/components/radio.d.ts +119 -0
- package/types/{component → components}/row.d.ts +10 -2
- package/types/components/select.d.ts +274 -0
- package/types/components/switch.d.ts +118 -0
- package/types/components/textarea.d.ts +212 -0
- package/types/components/tooltip.d.ts +122 -0
- package/types/ui/global-config.d.ts +43 -6
- package/types/ui/global-icon.d.ts +80 -10
- package/types/ui/index.d.ts +25 -2
- package/types/ui/renderer.d.ts +239 -0
- package/types/ui/validators.d.ts +26 -0
- package/es/design/index.js +0 -8
- package/es/vxe-design/index.js +0 -3
- package/lib/button-group/src/button-group.min.js +0 -1
- package/lib/design/index.js +0 -15
- package/lib/design/index.min.js +0 -1
- package/lib/design/src/design.min.js +0 -1
- package/lib/vxe-design/index.min.js +0 -1
- package/packages/design/index.ts +0 -11
- package/packages/design/src/design.ts +0 -55
- package/styles/components/design.scss +0 -1
- package/types/component/design.d.ts +0 -63
- /package/es/{anchor-link → anchor}/src/anchor-link.js +0 -0
- /package/es/{anchor-link → anchor}/src/util.js +0 -0
- /package/es/{design → checkbox-group}/style.css +0 -0
- /package/es/{design → checkbox-group}/style.min.css +0 -0
- /package/es/{vxe-design → form-gather}/style.css +0 -0
- /package/es/{vxe-design → form-gather}/style.min.css +0 -0
- /package/{lib/design/style → es/form-item}/style.css +0 -0
- /package/{lib/design/style → es/form-item}/style.min.css +0 -0
- /package/{lib/vxe-design/style → es/list-design}/style.css +0 -0
- /package/{lib/vxe-design/style → es/list-design}/style.min.css +0 -0
- /package/es/{col → row}/src/col.js +0 -0
- /package/lib/{anchor-link → anchor}/src/anchor-link.js +0 -0
- /package/lib/{anchor-link → anchor}/src/anchor-link.min.js +0 -0
- /package/lib/{anchor-link → anchor}/src/util.js +0 -0
- /package/lib/{anchor-link → anchor}/src/util.min.js +0 -0
- /package/lib/{vxe-design → checkbox}/style/index.js +0 -0
- /package/lib/{design → checkbox-group}/style/index.js +0 -0
- /package/lib/{col → row}/src/col.js +0 -0
- /package/lib/{col → row}/src/col.min.js +0 -0
- /package/packages/{anchor-link → anchor}/src/anchor-link.ts +0 -0
- /package/packages/{anchor-link → anchor}/src/util.ts +0 -0
- /package/packages/{col → row}/src/col.ts +0 -0
package/es/components.js
CHANGED
|
@@ -1,57 +1,120 @@
|
|
|
1
1
|
import XEUtils from 'xe-utils';
|
|
2
2
|
import { setConfig } from './ui';
|
|
3
|
+
import VxeAnchor from './anchor';
|
|
4
|
+
import VxeAnchorLink from './anchor-link';
|
|
5
|
+
import VxeBreadcrumb from './breadcrumb';
|
|
6
|
+
import VxeBreadcrumbItem from './breadcrumb-item';
|
|
7
|
+
import VxeButton from './button';
|
|
8
|
+
import VxeButtonGroup from './button-group';
|
|
9
|
+
import VxeCheckbox from './checkbox';
|
|
10
|
+
import VxeCheckboxGroup from './checkbox-group';
|
|
11
|
+
import VxeCol from './col';
|
|
12
|
+
import VxeForm from './form';
|
|
13
|
+
import VxeFormDesign from './form-design';
|
|
14
|
+
import VxeFormGather from './form-gather';
|
|
15
|
+
import VxeFormItem from './form-item';
|
|
3
16
|
import VxeIcon from './icon';
|
|
4
|
-
import
|
|
5
|
-
import VxeLayoutHeader from './layout-header';
|
|
17
|
+
import VxeInput from './input';
|
|
6
18
|
import VxeLayoutAside from './layout-aside';
|
|
7
19
|
import VxeLayoutBody from './layout-body';
|
|
20
|
+
import VxeLayoutContainer from './layout-container';
|
|
8
21
|
import VxeLayoutFooter from './layout-footer';
|
|
22
|
+
import VxeLayoutHeader from './layout-header';
|
|
23
|
+
import VxeListDesign from './list-design';
|
|
24
|
+
import VxeLoading from './loading';
|
|
25
|
+
import VxeModal from './modal';
|
|
26
|
+
import VxeOptgroup from './optgroup';
|
|
27
|
+
import VxeOption from './option';
|
|
28
|
+
import VxePager from './pager';
|
|
29
|
+
import VxePulldown from './pulldown';
|
|
30
|
+
import VxeRadio from './radio';
|
|
31
|
+
import VxeRadioButton from './radio-button';
|
|
32
|
+
import VxeRadioGroup from './radio-group';
|
|
9
33
|
import VxeRow from './row';
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import
|
|
14
|
-
import VxeButtonGroup from './button-group';
|
|
15
|
-
import VxeAnchor from './anchor';
|
|
16
|
-
import VxeAnchorLink from './anchor-link';
|
|
17
|
-
import VxeDesign from './design';
|
|
34
|
+
import VxeSelect from './select';
|
|
35
|
+
import VxeSwitch from './switch';
|
|
36
|
+
import VxeTextarea from './textarea';
|
|
37
|
+
import VxeTooltip from './tooltip';
|
|
18
38
|
import zhCN from './locale/lang/zh-CN';
|
|
19
39
|
// 默认中文
|
|
20
40
|
setConfig({
|
|
21
41
|
i18n: (key, args) => XEUtils.toFormatString(XEUtils.get(zhCN, key), args)
|
|
22
42
|
});
|
|
43
|
+
const components = [
|
|
44
|
+
VxeAnchor,
|
|
45
|
+
VxeAnchorLink,
|
|
46
|
+
VxeBreadcrumb,
|
|
47
|
+
VxeBreadcrumbItem,
|
|
48
|
+
VxeButton,
|
|
49
|
+
VxeButtonGroup,
|
|
50
|
+
VxeCheckbox,
|
|
51
|
+
VxeCheckboxGroup,
|
|
52
|
+
VxeCol,
|
|
53
|
+
VxeForm,
|
|
54
|
+
VxeFormDesign,
|
|
55
|
+
VxeFormGather,
|
|
56
|
+
VxeFormItem,
|
|
57
|
+
VxeIcon,
|
|
58
|
+
VxeInput,
|
|
59
|
+
VxeLayoutAside,
|
|
60
|
+
VxeLayoutBody,
|
|
61
|
+
VxeLayoutContainer,
|
|
62
|
+
VxeLayoutFooter,
|
|
63
|
+
VxeLayoutHeader,
|
|
64
|
+
VxeListDesign,
|
|
65
|
+
VxeLoading,
|
|
66
|
+
VxeModal,
|
|
67
|
+
VxeOptgroup,
|
|
68
|
+
VxeOption,
|
|
69
|
+
VxePager,
|
|
70
|
+
VxePulldown,
|
|
71
|
+
VxeRadio,
|
|
72
|
+
VxeRadioButton,
|
|
73
|
+
VxeRadioGroup,
|
|
74
|
+
VxeRow,
|
|
75
|
+
VxeSelect,
|
|
76
|
+
VxeSwitch,
|
|
77
|
+
VxeTextarea,
|
|
78
|
+
VxeTooltip
|
|
79
|
+
];
|
|
23
80
|
export function install(app, options) {
|
|
24
81
|
setConfig(options);
|
|
25
|
-
app.use(
|
|
26
|
-
app.use(VxeLayoutContainer);
|
|
27
|
-
app.use(VxeLayoutHeader);
|
|
28
|
-
app.use(VxeLayoutAside);
|
|
29
|
-
app.use(VxeLayoutBody);
|
|
30
|
-
app.use(VxeLayoutFooter);
|
|
31
|
-
app.use(VxeRow);
|
|
32
|
-
app.use(VxeCol);
|
|
33
|
-
app.use(VxeBreadcrumb);
|
|
34
|
-
app.use(VxeBreadcrumbItem);
|
|
35
|
-
app.use(VxeButton);
|
|
36
|
-
app.use(VxeButtonGroup);
|
|
37
|
-
app.use(VxeAnchor);
|
|
38
|
-
app.use(VxeAnchorLink);
|
|
39
|
-
app.use(VxeDesign);
|
|
82
|
+
components.forEach(component => app.use(component));
|
|
40
83
|
}
|
|
41
84
|
export * from './ui';
|
|
42
85
|
// Components
|
|
86
|
+
export * from './anchor';
|
|
87
|
+
export * from './anchor-link';
|
|
88
|
+
export * from './breadcrumb';
|
|
89
|
+
export * from './breadcrumb-item';
|
|
90
|
+
export * from './button';
|
|
91
|
+
export * from './button-group';
|
|
92
|
+
export * from './checkbox';
|
|
93
|
+
export * from './checkbox-group';
|
|
94
|
+
export * from './col';
|
|
95
|
+
export * from './form';
|
|
96
|
+
export * from './form-design';
|
|
97
|
+
export * from './form-gather';
|
|
98
|
+
export * from './form-item';
|
|
43
99
|
export * from './icon';
|
|
44
|
-
export * from './
|
|
45
|
-
export * from './layout-header';
|
|
100
|
+
export * from './input';
|
|
46
101
|
export * from './layout-aside';
|
|
47
102
|
export * from './layout-body';
|
|
103
|
+
export * from './layout-container';
|
|
48
104
|
export * from './layout-footer';
|
|
105
|
+
export * from './layout-header';
|
|
106
|
+
export * from './list-design';
|
|
107
|
+
export * from './loading';
|
|
108
|
+
export * from './modal';
|
|
109
|
+
export * from './optgroup';
|
|
110
|
+
export * from './option';
|
|
111
|
+
export * from './pager';
|
|
112
|
+
export * from './pulldown';
|
|
113
|
+
export * from './radio';
|
|
114
|
+
export * from './radio-button';
|
|
115
|
+
export * from './radio-group';
|
|
49
116
|
export * from './row';
|
|
50
|
-
export * from './
|
|
51
|
-
export * from './
|
|
52
|
-
export * from './
|
|
53
|
-
export * from './
|
|
54
|
-
export * from './button-group';
|
|
55
|
-
export * from './anchor';
|
|
56
|
-
export * from './anchor-link';
|
|
57
|
-
export * from './design';
|
|
117
|
+
export * from './select';
|
|
118
|
+
export * from './switch';
|
|
119
|
+
export * from './textarea';
|
|
120
|
+
export * from './tooltip';
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { defineComponent, h, createApp, resolveComponent, reactive } from 'vue';
|
|
2
|
+
let dynamicContainerElem;
|
|
3
|
+
export const dynamicStore = reactive({
|
|
4
|
+
modals: []
|
|
5
|
+
});
|
|
6
|
+
/**
|
|
7
|
+
* 动态组件
|
|
8
|
+
*/
|
|
9
|
+
const VxeDynamics = defineComponent({
|
|
10
|
+
setup() {
|
|
11
|
+
return () => {
|
|
12
|
+
const { modals } = dynamicStore;
|
|
13
|
+
return h('div', {
|
|
14
|
+
class: 'vxe-dynamics--modal'
|
|
15
|
+
}, modals.map((item) => h(resolveComponent('vxe-modal'), item)));
|
|
16
|
+
};
|
|
17
|
+
}
|
|
18
|
+
});
|
|
19
|
+
export const dynamicApp = createApp(VxeDynamics);
|
|
20
|
+
export function checkDynamic() {
|
|
21
|
+
if (!dynamicContainerElem) {
|
|
22
|
+
dynamicContainerElem = document.createElement('div');
|
|
23
|
+
dynamicContainerElem.className = 'vxe-dynamics';
|
|
24
|
+
document.body.appendChild(dynamicContainerElem);
|
|
25
|
+
dynamicApp.mount(dynamicContainerElem);
|
|
26
|
+
}
|
|
27
|
+
}
|
package/es/form/index.js
ADDED
|
@@ -0,0 +1,178 @@
|
|
|
1
|
+
import { defineComponent, h, inject, provide, createCommentVNode } from 'vue';
|
|
2
|
+
import XEUtils from 'xe-utils';
|
|
3
|
+
import iconConfigStore from '../../ui/src/iconStore';
|
|
4
|
+
import { renderer } from '../../ui/src/renderer';
|
|
5
|
+
import { getFuncText, isEnableConf } from '../../ui/src/utils';
|
|
6
|
+
import { getSlotVNs } from '../../ui/src/vn';
|
|
7
|
+
import { getI18n } from '../../ui/src/i18n';
|
|
8
|
+
import { renderTitle } from './render';
|
|
9
|
+
import { isActivetem } from './util';
|
|
10
|
+
const VxeFormConfigItem = defineComponent({
|
|
11
|
+
name: 'VxeFormConfigItem',
|
|
12
|
+
props: {
|
|
13
|
+
itemConfig: Object
|
|
14
|
+
},
|
|
15
|
+
setup(props) {
|
|
16
|
+
const $xeform = inject('$xeForm', {});
|
|
17
|
+
const xeformiteminfo = { itemConfig: props.itemConfig };
|
|
18
|
+
provide('$xeFormItemInfo', xeformiteminfo);
|
|
19
|
+
const renderVN = () => {
|
|
20
|
+
const { reactData } = $xeform;
|
|
21
|
+
const { data, rules, span: allSpan, align: allAlign, titleAlign: allTitleAlign, titleWidth: allTitleWidth, titleColon: allTitleColon, titleAsterisk: allTitleAsterisk, titleOverflow: allTitleOverflow, vertical: allVertical } = $xeform.props;
|
|
22
|
+
const { computeValidOpts } = $xeform.getComputeMaps();
|
|
23
|
+
const item = props.itemConfig;
|
|
24
|
+
const { collapseAll } = reactData;
|
|
25
|
+
const validOpts = computeValidOpts.value;
|
|
26
|
+
const { slots, title, visible, folding, field, collapseNode, itemRender, showError, errRule, className, titleOverflow, vertical, children, showTitle, contentClassName, contentStyle, titleClassName, titleStyle } = item;
|
|
27
|
+
const compConf = isEnableConf(itemRender) ? renderer.get(itemRender.name) : null;
|
|
28
|
+
const itemClassName = compConf ? compConf.itemClassName : '';
|
|
29
|
+
const itemStyle = compConf ? compConf.itemStyle : null;
|
|
30
|
+
const itemContentClassName = compConf ? compConf.itemContentClassName : '';
|
|
31
|
+
const itemContentStyle = compConf ? compConf.itemContentStyle : null;
|
|
32
|
+
const itemTitleClassName = compConf ? compConf.itemTitleClassName : '';
|
|
33
|
+
const itemTitleStyle = compConf ? compConf.itemTitleStyle : null;
|
|
34
|
+
const defaultSlot = slots ? slots.default : null;
|
|
35
|
+
const titleSlot = slots ? slots.title : null;
|
|
36
|
+
const span = item.span || allSpan;
|
|
37
|
+
const align = item.align || allAlign;
|
|
38
|
+
const titleAlign = XEUtils.eqNull(item.titleAlign) ? allTitleAlign : item.titleAlign;
|
|
39
|
+
const titleWidth = XEUtils.eqNull(item.titleWidth) ? allTitleWidth : item.titleWidth;
|
|
40
|
+
const titleColon = XEUtils.eqNull(item.titleColon) ? allTitleColon : item.titleColon;
|
|
41
|
+
const titleAsterisk = XEUtils.eqNull(item.titleAsterisk) ? allTitleAsterisk : item.titleAsterisk;
|
|
42
|
+
const itemOverflow = (XEUtils.isUndefined(titleOverflow) || XEUtils.isNull(titleOverflow)) ? allTitleOverflow : titleOverflow;
|
|
43
|
+
const itemVertical = (XEUtils.isUndefined(vertical) || XEUtils.isNull(vertical)) ? allVertical : vertical;
|
|
44
|
+
const ovEllipsis = itemOverflow === 'ellipsis';
|
|
45
|
+
const ovTitle = itemOverflow === 'title';
|
|
46
|
+
const ovTooltip = itemOverflow === true || itemOverflow === 'tooltip';
|
|
47
|
+
const hasEllipsis = ovTitle || ovTooltip || ovEllipsis;
|
|
48
|
+
const params = { data, field, property: field, item, $form: $xeform, $grid: $xeform.xegrid };
|
|
49
|
+
if (visible === false) {
|
|
50
|
+
return createCommentVNode();
|
|
51
|
+
}
|
|
52
|
+
let isRequired = false;
|
|
53
|
+
if (rules) {
|
|
54
|
+
const itemRules = rules[field];
|
|
55
|
+
if (itemRules) {
|
|
56
|
+
isRequired = itemRules.some((rule) => rule.required);
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
// 如果为项集合
|
|
60
|
+
const isGather = children && children.length > 0;
|
|
61
|
+
if (isGather) {
|
|
62
|
+
const childVNs = children.map((childItem, index) => {
|
|
63
|
+
return h(VxeFormConfigItem, {
|
|
64
|
+
key: index,
|
|
65
|
+
itemConfig: childItem
|
|
66
|
+
});
|
|
67
|
+
});
|
|
68
|
+
return childVNs.length
|
|
69
|
+
? h('div', {
|
|
70
|
+
class: ['vxe-form--gather vxe-row', item.id, span ? `vxe-col--${span} is--span` : '', className ? (XEUtils.isFunction(className) ? className(params) : className) : '']
|
|
71
|
+
}, childVNs)
|
|
72
|
+
: createCommentVNode();
|
|
73
|
+
}
|
|
74
|
+
let contentVNs = [];
|
|
75
|
+
if (defaultSlot) {
|
|
76
|
+
contentVNs = $xeform.callSlot(defaultSlot, params);
|
|
77
|
+
}
|
|
78
|
+
else if (compConf && compConf.renderItemContent) {
|
|
79
|
+
contentVNs = getSlotVNs(compConf.renderItemContent(itemRender, params));
|
|
80
|
+
}
|
|
81
|
+
else if (field) {
|
|
82
|
+
contentVNs = [XEUtils.toValueString(XEUtils.get(data, field))];
|
|
83
|
+
}
|
|
84
|
+
if (collapseNode) {
|
|
85
|
+
contentVNs.push(h('div', {
|
|
86
|
+
class: 'vxe-form--item-trigger-node',
|
|
87
|
+
onClick: $xeform.toggleCollapseEvent
|
|
88
|
+
}, [
|
|
89
|
+
h('span', {
|
|
90
|
+
class: 'vxe-form--item-trigger-text'
|
|
91
|
+
}, collapseAll ? getI18n('vxe.form.unfolding') : getI18n('vxe.form.folding')),
|
|
92
|
+
h('i', {
|
|
93
|
+
class: ['vxe-form--item-trigger-icon', collapseAll ? iconConfigStore.FORM_FOLDING : iconConfigStore.FORM_UNFOLDING]
|
|
94
|
+
})
|
|
95
|
+
]));
|
|
96
|
+
}
|
|
97
|
+
if (errRule && validOpts.showMessage) {
|
|
98
|
+
contentVNs.push(h('div', {
|
|
99
|
+
class: 'vxe-form--item-valid',
|
|
100
|
+
style: errRule.maxWidth
|
|
101
|
+
? {
|
|
102
|
+
width: `${errRule.maxWidth}px`
|
|
103
|
+
}
|
|
104
|
+
: null
|
|
105
|
+
}, errRule.content));
|
|
106
|
+
}
|
|
107
|
+
const ons = ovTooltip
|
|
108
|
+
? {
|
|
109
|
+
onMouseenter(evnt) {
|
|
110
|
+
$xeform.triggerTitleTipEvent(evnt, params);
|
|
111
|
+
},
|
|
112
|
+
onMouseleave: $xeform.handleTitleTipLeaveEvent
|
|
113
|
+
}
|
|
114
|
+
: {};
|
|
115
|
+
return h('div', {
|
|
116
|
+
class: [
|
|
117
|
+
'vxe-form--item',
|
|
118
|
+
item.id,
|
|
119
|
+
span ? `vxe-col--${span} is--span` : '',
|
|
120
|
+
className ? (XEUtils.isFunction(className) ? className(params) : className) : '',
|
|
121
|
+
itemClassName ? (XEUtils.isFunction(itemClassName) ? itemClassName(params) : itemClassName) : '',
|
|
122
|
+
{
|
|
123
|
+
'is--title': title,
|
|
124
|
+
'is--colon': titleColon,
|
|
125
|
+
'is--vertical': itemVertical,
|
|
126
|
+
'is--asterisk': titleAsterisk,
|
|
127
|
+
'is--required': isRequired,
|
|
128
|
+
'is--hidden': folding && collapseAll,
|
|
129
|
+
'is--active': isActivetem($xeform, item),
|
|
130
|
+
'is--error': showError
|
|
131
|
+
}
|
|
132
|
+
],
|
|
133
|
+
style: XEUtils.isFunction(itemStyle) ? itemStyle(params) : itemStyle
|
|
134
|
+
}, [
|
|
135
|
+
h('div', {
|
|
136
|
+
class: 'vxe-form--item-inner'
|
|
137
|
+
}, [
|
|
138
|
+
(showTitle !== false) && (title || titleSlot)
|
|
139
|
+
? h('div', {
|
|
140
|
+
class: [
|
|
141
|
+
'vxe-form--item-title',
|
|
142
|
+
titleAlign ? `align--${titleAlign}` : '',
|
|
143
|
+
hasEllipsis ? 'is--ellipsis' : '',
|
|
144
|
+
itemTitleClassName ? (XEUtils.isFunction(itemTitleClassName) ? itemTitleClassName(params) : itemTitleClassName) : '',
|
|
145
|
+
titleClassName ? (XEUtils.isFunction(titleClassName) ? titleClassName(params) : titleClassName) : ''
|
|
146
|
+
],
|
|
147
|
+
style: Object.assign({}, XEUtils.isFunction(itemTitleStyle) ? itemTitleStyle(params) : itemTitleStyle, XEUtils.isFunction(titleStyle) ? titleStyle(params) : titleStyle, titleWidth
|
|
148
|
+
? {
|
|
149
|
+
width: isNaN(titleWidth) ? titleWidth : `${titleWidth}px`
|
|
150
|
+
}
|
|
151
|
+
: null),
|
|
152
|
+
title: ovTitle ? getFuncText(title) : null,
|
|
153
|
+
...ons
|
|
154
|
+
}, renderTitle($xeform, item))
|
|
155
|
+
: null,
|
|
156
|
+
h('div', {
|
|
157
|
+
class: [
|
|
158
|
+
'vxe-form--item-content',
|
|
159
|
+
align ? `align--${align}` : '',
|
|
160
|
+
itemContentClassName ? (XEUtils.isFunction(itemContentClassName) ? itemContentClassName(params) : itemContentClassName) : '',
|
|
161
|
+
contentClassName ? (XEUtils.isFunction(contentClassName) ? contentClassName(params) : contentClassName) : ''
|
|
162
|
+
],
|
|
163
|
+
style: Object.assign({}, XEUtils.isFunction(itemContentStyle) ? itemContentStyle(params) : itemContentStyle, XEUtils.isFunction(contentStyle) ? contentStyle(params) : contentStyle)
|
|
164
|
+
}, contentVNs)
|
|
165
|
+
])
|
|
166
|
+
]);
|
|
167
|
+
};
|
|
168
|
+
const $xeformconfigitem = {
|
|
169
|
+
renderVN
|
|
170
|
+
};
|
|
171
|
+
provide('$xeFormGather', null);
|
|
172
|
+
return $xeformconfigitem;
|
|
173
|
+
},
|
|
174
|
+
render() {
|
|
175
|
+
return this.renderVN();
|
|
176
|
+
}
|
|
177
|
+
});
|
|
178
|
+
export default VxeFormConfigItem;
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { defineComponent, h, onUnmounted, inject, ref, reactive, onMounted, provide, nextTick } from 'vue';
|
|
2
|
+
import { errLog } from '../../ui/src/log';
|
|
3
|
+
import { createItem, watchItem, destroyItem, assemItem } from './util';
|
|
4
|
+
import { formItemProps } from './form-item';
|
|
5
|
+
export default defineComponent({
|
|
6
|
+
name: 'VxeFormGather',
|
|
7
|
+
props: formItemProps,
|
|
8
|
+
setup(props, { slots }) {
|
|
9
|
+
const refElem = ref();
|
|
10
|
+
const $xeForm = inject('$xeForm', {});
|
|
11
|
+
const parentFormGather = inject('$xeFormGather', null);
|
|
12
|
+
const defaultSlot = slots.default;
|
|
13
|
+
const formItem = reactive(createItem($xeForm, props));
|
|
14
|
+
formItem.children = [];
|
|
15
|
+
const formItemInfo = { itemConfig: formItem };
|
|
16
|
+
provide('$xeFormItemInfo', formItemInfo);
|
|
17
|
+
watchItem(props, formItem);
|
|
18
|
+
onMounted(() => {
|
|
19
|
+
assemItem($xeForm, refElem.value, formItem, parentFormGather);
|
|
20
|
+
});
|
|
21
|
+
onUnmounted(() => {
|
|
22
|
+
destroyItem($xeForm, formItem);
|
|
23
|
+
});
|
|
24
|
+
if (process.env.NODE_ENV === 'development') {
|
|
25
|
+
nextTick(() => {
|
|
26
|
+
if ($xeForm && $xeForm.props.customLayout) {
|
|
27
|
+
errLog('vxe.error.errConflicts', ['custom-layout', '<form-gather ...>']);
|
|
28
|
+
}
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
const renderVN = () => {
|
|
32
|
+
return h('div', {
|
|
33
|
+
ref: refElem
|
|
34
|
+
}, defaultSlot ? defaultSlot() : []);
|
|
35
|
+
};
|
|
36
|
+
const $xeFormGather = {
|
|
37
|
+
formItem,
|
|
38
|
+
renderVN
|
|
39
|
+
};
|
|
40
|
+
provide('$xeFormGather', $xeFormGather);
|
|
41
|
+
provide('$xeFormItem', null);
|
|
42
|
+
return $xeFormGather;
|
|
43
|
+
},
|
|
44
|
+
render() {
|
|
45
|
+
return this.renderVN();
|
|
46
|
+
}
|
|
47
|
+
});
|
|
@@ -0,0 +1,228 @@
|
|
|
1
|
+
import { defineComponent, h, onUnmounted, inject, ref, provide, onMounted, createCommentVNode, reactive } from 'vue';
|
|
2
|
+
import XEUtils from 'xe-utils';
|
|
3
|
+
import iconConfigStore from '../../ui/src/iconStore';
|
|
4
|
+
import { renderer } from '../../ui/src/renderer';
|
|
5
|
+
import { getFuncText, isEnableConf } from '../../ui/src/utils';
|
|
6
|
+
import { getSlotVNs } from '../../ui/src/vn';
|
|
7
|
+
import { getI18n } from '../../ui/src/i18n';
|
|
8
|
+
import { createItem, watchItem, destroyItem, assemItem, isActivetem } from './util';
|
|
9
|
+
import { renderTitle } from './render';
|
|
10
|
+
export const formItemProps = {
|
|
11
|
+
title: String,
|
|
12
|
+
field: String,
|
|
13
|
+
span: [String, Number],
|
|
14
|
+
align: String,
|
|
15
|
+
titleAlign: {
|
|
16
|
+
type: String,
|
|
17
|
+
default: null
|
|
18
|
+
},
|
|
19
|
+
titleWidth: {
|
|
20
|
+
type: [String, Number],
|
|
21
|
+
default: null
|
|
22
|
+
},
|
|
23
|
+
titleColon: {
|
|
24
|
+
type: Boolean,
|
|
25
|
+
default: null
|
|
26
|
+
},
|
|
27
|
+
titleAsterisk: {
|
|
28
|
+
type: Boolean,
|
|
29
|
+
default: null
|
|
30
|
+
},
|
|
31
|
+
showTitle: {
|
|
32
|
+
type: Boolean,
|
|
33
|
+
default: true
|
|
34
|
+
},
|
|
35
|
+
vertical: {
|
|
36
|
+
type: Boolean,
|
|
37
|
+
default: null
|
|
38
|
+
},
|
|
39
|
+
className: [String, Function],
|
|
40
|
+
contentClassName: [String, Function],
|
|
41
|
+
contentStyle: [Object, Function],
|
|
42
|
+
titleClassName: [String, Function],
|
|
43
|
+
titleStyle: [Object, Function],
|
|
44
|
+
titleOverflow: {
|
|
45
|
+
type: [Boolean, String],
|
|
46
|
+
default: null
|
|
47
|
+
},
|
|
48
|
+
titlePrefix: Object,
|
|
49
|
+
titleSuffix: Object,
|
|
50
|
+
resetValue: { default: null },
|
|
51
|
+
visibleMethod: Function,
|
|
52
|
+
visible: { type: Boolean, default: null },
|
|
53
|
+
folding: Boolean,
|
|
54
|
+
collapseNode: Boolean,
|
|
55
|
+
itemRender: Object
|
|
56
|
+
};
|
|
57
|
+
export default defineComponent({
|
|
58
|
+
name: 'VxeFormItem',
|
|
59
|
+
props: formItemProps,
|
|
60
|
+
setup(props, { slots }) {
|
|
61
|
+
const refElem = ref();
|
|
62
|
+
const $xeform = inject('$xeForm', {});
|
|
63
|
+
const formGather = inject('$xeformgather', null);
|
|
64
|
+
const formItem = reactive(createItem($xeform, props));
|
|
65
|
+
formItem.slots = slots;
|
|
66
|
+
const formItemInfo = { itemConfig: formItem };
|
|
67
|
+
provide('$xeFormItemInfo', formItemInfo);
|
|
68
|
+
watchItem(props, formItem);
|
|
69
|
+
onMounted(() => {
|
|
70
|
+
assemItem($xeform, refElem.value, formItem, formGather);
|
|
71
|
+
});
|
|
72
|
+
onUnmounted(() => {
|
|
73
|
+
destroyItem($xeform, formItem);
|
|
74
|
+
});
|
|
75
|
+
const renderItem = ($xeform, item) => {
|
|
76
|
+
const { props, reactData } = $xeform;
|
|
77
|
+
const { data, rules, titleAlign: allTitleAlign, titleWidth: allTitleWidth, titleColon: allTitleColon, titleAsterisk: allTitleAsterisk, titleOverflow: allTitleOverflow, vertical: allVertical } = props;
|
|
78
|
+
const { collapseAll } = reactData;
|
|
79
|
+
const { computeValidOpts } = $xeform.getComputeMaps();
|
|
80
|
+
const validOpts = computeValidOpts.value;
|
|
81
|
+
const { slots, title, visible, folding, field, collapseNode, itemRender, showError, errRule, className, titleOverflow, vertical, showTitle, contentClassName, contentStyle, titleClassName, titleStyle } = item;
|
|
82
|
+
const compConf = isEnableConf(itemRender) ? renderer.get(itemRender.name) : null;
|
|
83
|
+
const itemClassName = compConf ? compConf.itemClassName : '';
|
|
84
|
+
const itemStyle = compConf ? compConf.itemStyle : null;
|
|
85
|
+
const itemContentClassName = compConf ? compConf.itemContentClassName : '';
|
|
86
|
+
const itemContentStyle = compConf ? compConf.itemContentStyle : null;
|
|
87
|
+
const itemTitleClassName = compConf ? compConf.itemTitleClassName : '';
|
|
88
|
+
const itemTitleStyle = compConf ? compConf.itemTitleStyle : null;
|
|
89
|
+
const defaultSlot = slots ? slots.default : null;
|
|
90
|
+
const titleSlot = slots ? slots.title : null;
|
|
91
|
+
const span = item.span || props.span;
|
|
92
|
+
const align = item.align || props.align;
|
|
93
|
+
const titleAlign = XEUtils.eqNull(item.titleAlign) ? allTitleAlign : item.titleAlign;
|
|
94
|
+
const titleWidth = XEUtils.eqNull(item.titleWidth) ? allTitleWidth : item.titleWidth;
|
|
95
|
+
const titleColon = XEUtils.eqNull(item.titleColon) ? allTitleColon : item.titleColon;
|
|
96
|
+
const titleAsterisk = XEUtils.eqNull(item.titleAsterisk) ? allTitleAsterisk : item.titleAsterisk;
|
|
97
|
+
const itemOverflow = (XEUtils.isUndefined(titleOverflow) || XEUtils.isNull(titleOverflow)) ? allTitleOverflow : titleOverflow;
|
|
98
|
+
const itemVertical = (XEUtils.isUndefined(vertical) || XEUtils.isNull(vertical)) ? allVertical : vertical;
|
|
99
|
+
const ovEllipsis = itemOverflow === 'ellipsis';
|
|
100
|
+
const ovTitle = itemOverflow === 'title';
|
|
101
|
+
const ovTooltip = itemOverflow === true || itemOverflow === 'tooltip';
|
|
102
|
+
const hasEllipsis = ovTitle || ovTooltip || ovEllipsis;
|
|
103
|
+
const params = { data, field, property: field, item, $form: $xeform, $grid: $xeform.xegrid };
|
|
104
|
+
let isRequired = false;
|
|
105
|
+
if (visible === false) {
|
|
106
|
+
return createCommentVNode();
|
|
107
|
+
}
|
|
108
|
+
if (rules) {
|
|
109
|
+
const itemRules = rules[field];
|
|
110
|
+
if (itemRules) {
|
|
111
|
+
isRequired = itemRules.some((rule) => rule.required);
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
let contentVNs = [];
|
|
115
|
+
if (defaultSlot) {
|
|
116
|
+
contentVNs = $xeform.callSlot(defaultSlot, params);
|
|
117
|
+
}
|
|
118
|
+
else if (compConf && compConf.renderItemContent) {
|
|
119
|
+
contentVNs = getSlotVNs(compConf.renderItemContent(itemRender, params));
|
|
120
|
+
}
|
|
121
|
+
else if (field) {
|
|
122
|
+
contentVNs = [`${XEUtils.get(data, field)}`];
|
|
123
|
+
}
|
|
124
|
+
if (collapseNode) {
|
|
125
|
+
contentVNs.push(h('div', {
|
|
126
|
+
class: 'vxe-form--item-trigger-node',
|
|
127
|
+
onClick: $xeform.toggleCollapseEvent
|
|
128
|
+
}, [
|
|
129
|
+
h('span', {
|
|
130
|
+
class: 'vxe-form--item-trigger-text'
|
|
131
|
+
}, collapseAll ? getI18n('vxe.form.unfolding') : getI18n('vxe.form.folding')),
|
|
132
|
+
h('i', {
|
|
133
|
+
class: ['vxe-form--item-trigger-icon', collapseAll ? iconConfigStore.FORM_FOLDING : iconConfigStore.FORM_UNFOLDING]
|
|
134
|
+
})
|
|
135
|
+
]));
|
|
136
|
+
}
|
|
137
|
+
if (errRule && validOpts.showMessage) {
|
|
138
|
+
contentVNs.push(h('div', {
|
|
139
|
+
class: 'vxe-form--item-valid',
|
|
140
|
+
style: errRule.maxWidth
|
|
141
|
+
? {
|
|
142
|
+
width: `${errRule.maxWidth}px`
|
|
143
|
+
}
|
|
144
|
+
: null
|
|
145
|
+
}, errRule.message));
|
|
146
|
+
}
|
|
147
|
+
const ons = ovTooltip
|
|
148
|
+
? {
|
|
149
|
+
onMouseenter(evnt) {
|
|
150
|
+
$xeform.triggerTitleTipEvent(evnt, params);
|
|
151
|
+
},
|
|
152
|
+
onMouseleave: $xeform.handleTitleTipLeaveEvent
|
|
153
|
+
}
|
|
154
|
+
: {};
|
|
155
|
+
return h('div', {
|
|
156
|
+
ref: refElem,
|
|
157
|
+
class: [
|
|
158
|
+
'vxe-form--item',
|
|
159
|
+
item.id,
|
|
160
|
+
span ? `vxe-col--${span} is--span` : '',
|
|
161
|
+
className ? (XEUtils.isFunction(className) ? className(params) : className) : '',
|
|
162
|
+
itemClassName ? (XEUtils.isFunction(itemClassName) ? itemClassName(params) : itemClassName) : '',
|
|
163
|
+
{
|
|
164
|
+
'is--title': title,
|
|
165
|
+
'is--colon': titleColon,
|
|
166
|
+
'is--vertical': itemVertical,
|
|
167
|
+
'is--asterisk': titleAsterisk,
|
|
168
|
+
'is--required': isRequired,
|
|
169
|
+
'is--hidden': folding && collapseAll,
|
|
170
|
+
'is--active': isActivetem($xeform, item),
|
|
171
|
+
'is--error': showError
|
|
172
|
+
}
|
|
173
|
+
],
|
|
174
|
+
style: XEUtils.isFunction(itemStyle) ? itemStyle(params) : itemStyle
|
|
175
|
+
}, [
|
|
176
|
+
h('div', {
|
|
177
|
+
class: 'vxe-form--item-inner'
|
|
178
|
+
}, [
|
|
179
|
+
(showTitle !== false) && (title || titleSlot)
|
|
180
|
+
? h('div', {
|
|
181
|
+
class: [
|
|
182
|
+
'vxe-form--item-title',
|
|
183
|
+
titleAlign ? `align--${titleAlign}` : '',
|
|
184
|
+
hasEllipsis ? 'is--ellipsis' : '',
|
|
185
|
+
itemTitleClassName ? (XEUtils.isFunction(itemTitleClassName) ? itemTitleClassName(params) : itemTitleClassName) : '',
|
|
186
|
+
titleClassName ? (XEUtils.isFunction(titleClassName) ? titleClassName(params) : titleClassName) : ''
|
|
187
|
+
],
|
|
188
|
+
style: Object.assign({}, XEUtils.isFunction(itemTitleStyle) ? itemTitleStyle(params) : itemTitleStyle, XEUtils.isFunction(titleStyle) ? titleStyle(params) : titleStyle, titleWidth
|
|
189
|
+
? {
|
|
190
|
+
width: isNaN(titleWidth) ? titleWidth : `${titleWidth}px`
|
|
191
|
+
}
|
|
192
|
+
: null),
|
|
193
|
+
title: ovTitle ? getFuncText(title) : null,
|
|
194
|
+
...ons
|
|
195
|
+
}, renderTitle($xeform, item))
|
|
196
|
+
: null,
|
|
197
|
+
h('div', {
|
|
198
|
+
class: [
|
|
199
|
+
'vxe-form--item-content',
|
|
200
|
+
align ? `align--${align}` : '',
|
|
201
|
+
itemContentClassName ? (XEUtils.isFunction(itemContentClassName) ? itemContentClassName(params) : itemContentClassName) : '',
|
|
202
|
+
contentClassName ? (XEUtils.isFunction(contentClassName) ? contentClassName(params) : contentClassName) : ''
|
|
203
|
+
],
|
|
204
|
+
style: Object.assign({}, XEUtils.isFunction(itemContentStyle) ? itemContentStyle(params) : itemContentStyle, XEUtils.isFunction(contentStyle) ? contentStyle(params) : contentStyle)
|
|
205
|
+
}, contentVNs)
|
|
206
|
+
])
|
|
207
|
+
]);
|
|
208
|
+
};
|
|
209
|
+
const renderVN = () => {
|
|
210
|
+
const formProps = $xeform ? $xeform.props : null;
|
|
211
|
+
return formProps && formProps.customLayout
|
|
212
|
+
? renderItem($xeform, formItem)
|
|
213
|
+
: h('div', {
|
|
214
|
+
ref: refElem
|
|
215
|
+
});
|
|
216
|
+
};
|
|
217
|
+
const $xeformitem = {
|
|
218
|
+
formItem,
|
|
219
|
+
renderVN
|
|
220
|
+
};
|
|
221
|
+
provide('$xeformitem', $xeformitem);
|
|
222
|
+
provide('$xeformgather', null);
|
|
223
|
+
return $xeformitem;
|
|
224
|
+
},
|
|
225
|
+
render() {
|
|
226
|
+
return this.renderVN();
|
|
227
|
+
}
|
|
228
|
+
});
|