hs-admin-ui 1.0.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/.env +11 -0
- package/.env.development +5 -0
- package/.env.production +5 -0
- package/.eslintignore +18 -0
- package/.eslintrc.js +104 -0
- package/.prettierrc.js +39 -0
- package/.vite/deps_temp_3669a513/chunk-FVXAE7ZR.js +11400 -0
- package/.vite/deps_temp_3669a513/chunk-ZS7NZCD4.js +36 -0
- package/.vite/deps_temp_3669a513/default-passive-events.js +25 -0
- package/.vite/deps_temp_3669a513/element-plus.js +65013 -0
- package/.vite/deps_temp_3669a513/lodash.js +5497 -0
- package/.vite/deps_temp_3669a513/package.json +3 -0
- package/.vite/deps_temp_3669a513/vue.js +324 -0
- package/.vite/deps_temp_3669a513/vxe-table.js +32336 -0
- package/CHANGELOG.md +1 -0
- package/LICENSE +21 -0
- package/README.md +0 -0
- package/directoryList.md +180 -0
- package/package.json +78 -0
- package/postcss.config.js +7 -0
- package/src/App.vue +88 -0
- package/src/api/fieldConfigController/index.ts +76 -0
- package/src/api/fieldConfigController/type.ts +44 -0
- package/src/api/login/index.ts +78 -0
- package/src/api/loginController/index.ts +74 -0
- package/src/api/menu/index.ts +34 -0
- package/src/api/menu/index2.ts +291 -0
- package/src/api/menuController/index.ts +189 -0
- package/src/api/systemController/index.ts +26 -0
- package/src/api/systemController/type.ts +16 -0
- package/src/api/test/index.ts +22 -0
- package/src/api/user/index.ts +30 -0
- package/src/assets/404.png +0 -0
- package/src/assets/logo-main.svg +12 -0
- package/src/assets/logo-mini.svg +12 -0
- package/src/components/base/hsAffix/src/hsAffix.vue +22 -0
- package/src/components/base/hsAlert/src/hsAlert.vue +15 -0
- package/src/components/base/hsAutocomplete/src/hsAutocomplete.vue +36 -0
- package/src/components/base/hsButton/src/hsButton.vue +26 -0
- package/src/components/base/hsButton/src/hsButtonGroup.vue +8 -0
- package/src/components/base/hsButton/useButtonEvents.ts +19 -0
- package/src/components/base/hsCalendar/src/hsCalendar.vue +36 -0
- package/src/components/base/hsCarousel/src/hsCarousel.vue +15 -0
- package/src/components/base/hsCarousel/src/hsCarouselItem.vue +15 -0
- package/src/components/base/hsCascader/src/hsCascader.vue +36 -0
- package/src/components/base/hsCascader/src/hsCascaderPanel.vue +29 -0
- package/src/components/base/hsCheckbox/src/hsCheckbox.vue +32 -0
- package/src/components/base/hsCheckbox/src/hsCheckboxButton.vue +18 -0
- package/src/components/base/hsCheckbox/src/hsCheckboxGroup.vue +32 -0
- package/src/components/base/hsCol/src/hsCol.vue +20 -0
- package/src/components/base/hsCollapse/src/hsCollapse.vue +36 -0
- package/src/components/base/hsCollapse/src/hsCollapseItem.vue +22 -0
- package/src/components/base/hsColorPicker/src/hsColorPicker.vue +32 -0
- package/src/components/base/hsDatePicker/src/hsDatePicker.vue +40 -0
- package/src/components/base/hsDialog/src/hsDialog.vue +36 -0
- package/src/components/base/hsDrawer/src/hsDrawer.vue +29 -0
- package/src/components/base/hsDropdown/src/hsDropdown.vue +15 -0
- package/src/components/base/hsDropdown/src/hsDropdownItem.vue +15 -0
- package/src/components/base/hsDropdown/src/hsDropdownMenu.vue +15 -0
- package/src/components/base/hsForm/src/hsForm.vue +23 -0
- package/src/components/base/hsForm/src/hsFormItem.vue +22 -0
- package/src/components/base/hsGetApi/src/hsGetApis.vue +231 -0
- package/src/components/base/hsGetApi/useGetApis.ts +158 -0
- package/src/components/base/hsInput/src/hsInput.vue +40 -0
- package/src/components/base/hsInput/useInputEvents.ts +52 -0
- package/src/components/base/hsInputNumber/src/hsInputNumber.vue +31 -0
- package/src/components/base/hsPopconfirm/src/hsPopconfirm.vue +15 -0
- package/src/components/base/hsPopover/src/hsPopover.vue +22 -0
- package/src/components/base/hsProgress/src/hsProgress.vue +15 -0
- package/src/components/base/hsRadio/src/hsRadio.vue +32 -0
- package/src/components/base/hsRadio/src/hsRadioButton.vue +18 -0
- package/src/components/base/hsRadio/src/hsRadioGroup.vue +32 -0
- package/src/components/base/hsRate/src/hsRate.vue +33 -0
- package/src/components/base/hsResult/src/hsResult.vue +15 -0
- package/src/components/base/hsRow/src/hsRow.vue +20 -0
- package/src/components/base/hsScrollbar/src/hsScrollbar.vue +22 -0
- package/src/components/base/hsSelect/src/hsOption.vue +8 -0
- package/src/components/base/hsSelect/src/hsOptionGroup.vue +8 -0
- package/src/components/base/hsSelect/src/hsSelect.vue +42 -0
- package/src/components/base/hsSelect/useSelectEvents.ts +60 -0
- package/src/components/base/hsSlider/src/hsSlider.vue +25 -0
- package/src/components/base/hsSteps/src/hsStep.vue +15 -0
- package/src/components/base/hsSteps/src/hsSteps.vue +15 -0
- package/src/components/base/hsSwitch/src/hsSwitch.vue +35 -0
- package/src/components/base/hsTable/hsBCTable.vue +116 -0
- package/src/components/base/hsTable/hsTable copy.vue +226 -0
- package/src/components/base/hsTable/hsTable.vue +213 -0
- package/src/components/base/hsTable/useHsTableConfig.ts +95 -0
- package/src/components/base/hsTable/useTableEvents.ts +118 -0
- package/src/components/base/hsTabs/src/hsTabPane.vue +15 -0
- package/src/components/base/hsTabs/src/hsTabs.vue +29 -0
- package/src/components/base/hsTag/src/hsCheckTag.vue +16 -0
- package/src/components/base/hsTag/src/hsTag.vue +15 -0
- package/src/components/base/hsTest/HsTest.vue +320 -0
- package/src/components/base/hsTooltip/src/hsTooltip.vue +22 -0
- package/src/components/base/hsTour/src/hsTour.vue +31 -0
- package/src/components/base/hsTour/src/hsTourStep.vue +15 -0
- package/src/components/base/hsTransfer/src/hsTransfer.vue +36 -0
- package/src/components/base/hsTree/src/hsTree.vue +24 -0
- package/src/components/base/hsTreeSelect/src/hsTreeSelect.vue +39 -0
- package/src/components/base/hsUpload/src/hsUpload.vue +32 -0
- package/src/components/base/hsWatermark/src/hsWatermark.vue +15 -0
- package/src/components/business/bcAutoComplete/bcAutoComplete.vue +38 -0
- package/src/components/business/bcAutoComplete/defaultData.ts +25 -0
- package/src/components/business/bcAutoComplete/useAutoComplete.ts +65 -0
- package/src/components/business/bcBtn/bcBtn.vue +40 -0
- package/src/components/business/bcForm/bcForm.vue +113 -0
- package/src/components/business/bcForm/bcFormDrag.vue +104 -0
- package/src/components/business/bcForm/bcFormSearch.vue +154 -0
- package/src/components/business/bcForm/components/sortForm/index.ts +18 -0
- package/src/components/business/bcForm/components/sortForm/sortForm.vue +92 -0
- package/src/components/business/bcFormConfig/bcFormConfig.vue +196 -0
- package/src/components/business/bcFormTable/bcFormTable.vue +91 -0
- package/src/components/business/bcFormTable/components/bcTabs/bcTabs.vue +53 -0
- package/src/components/business/bcFormTable/components/contextBody/contextBody.vue +67 -0
- package/src/components/business/bcFormTable/components/contextBody/useContextMenu.ts +53 -0
- package/src/components/business/bcFormTable/components/formSearchBtn/formSearchBtn.vue +21 -0
- package/src/components/business/bcFormTable/methods/cellDetailMethod.ts +5 -0
- package/src/components/business/bcFormTable/methods/filterAgeMethod.ts +5 -0
- package/src/components/business/bcFormTable/methods/footerMethod.ts +25 -0
- package/src/components/business/bcFormTable/methods/index.ts +10 -0
- package/src/components/business/bcFormTable/utils/onFormKey.ts +121 -0
- package/src/components/business/bcFormTable/utils/onTableKey.ts +119 -0
- package/src/components/business/bcFormTable/utils/parseTable.ts +201 -0
- package/src/components/business/bcFormTable/utils/useButon.ts +20 -0
- package/src/components/business/bcFormTable/utils/useTableHeight.ts +44 -0
- package/src/components/business/bcPageConfig/bcPageConfig.vue +79 -0
- package/src/components/business/bcPageConfig/components/hsBtn/src/hsAttrBtn.vue +39 -0
- package/src/components/business/bcPageConfig/components/hsBtn/src/hsBtnConfigList.vue +45 -0
- package/src/components/business/bcPageConfig/components/hsBtn/src/hsBtnItemConfig.vue +32 -0
- package/src/components/business/bcPageConfig/components/hsBtn/src/hsBtnPanel.vue +45 -0
- package/src/components/business/bcPageConfig/components/hsBtn/useAttrBtn.ts +58 -0
- package/src/components/business/bcPageConfig/components/hsBtn/useBtnConfigList.ts +71 -0
- package/src/components/business/bcPageConfig/components/hsBtn/useBtnItemConfig.ts +35 -0
- package/src/components/business/bcPageConfig/components/hsExpand/src/hsExpand.vue +33 -0
- package/src/components/business/bcPageConfig/components/hsExpand/useExpand.ts +9 -0
- package/src/components/business/bcPageConfig/components/hsForm/src/hsAttrForm.vue +54 -0
- package/src/components/business/bcPageConfig/components/hsForm/src/hsFormConfig.vue +180 -0
- package/src/components/business/bcPageConfig/components/hsForm/src/hsFormConfigList.vue +45 -0
- package/src/components/business/bcPageConfig/components/hsForm/src/hsFormPanel.vue +64 -0
- package/src/components/business/bcPageConfig/components/hsForm/src/hsFormParse.vue +24 -0
- package/src/components/business/bcPageConfig/components/hsForm/useAttrForm.ts +108 -0
- package/src/components/business/bcPageConfig/components/hsForm/useFormListConfig.ts +69 -0
- package/src/components/business/bcPageConfig/components/hsForm/useFormParse.ts +120 -0
- package/src/components/business/bcPageConfig/components/hsSaveForm/saveFormConfig.ts +66 -0
- package/src/components/business/bcPageConfig/components/hsSaveForm/src/saveForm.vue +48 -0
- package/src/components/business/bcPageConfig/components/hsSaveForm/useSaveForm.ts +148 -0
- package/src/components/business/bcPageConfig/components/hsTables/src/hsAttrTable.vue +122 -0
- package/src/components/business/bcPageConfig/components/hsTables/src/hsRecursionConfig.vue +36 -0
- package/src/components/business/bcPageConfig/components/hsTables/src/hsTableConfig.vue +51 -0
- package/src/components/business/bcPageConfig/components/hsTables/src/hsTableConfigList.vue +46 -0
- package/src/components/business/bcPageConfig/components/hsTables/src/hsTablePanel.vue +68 -0
- package/src/components/business/bcPageConfig/components/hsTables/src/hsTableParse.vue +24 -0
- package/src/components/business/bcPageConfig/components/hsTables/useAttrTable.ts +218 -0
- package/src/components/business/bcPageConfig/components/hsTables/useTableConfigList.ts +77 -0
- package/src/components/business/bcPageConfig/components/hsTables/useTableParse.ts +78 -0
- package/src/components/business/bcPageConfig/default/apis.json +24712 -0
- package/src/components/business/bcPageConfig/default/baseBtnConfig.ts +256 -0
- package/src/components/business/bcPageConfig/default/baseFormConfig.ts +380 -0
- package/src/components/business/bcPageConfig/default/baseTableConfig.ts +2399 -0
- package/src/components/business/bcPageConfig/usePageConfig.ts +469 -0
- package/src/components/business/bcSelect/bcSelect.vue +50 -0
- package/src/components/business/bcSwitchSystems/bcSwitchSystems.vue +36 -0
- package/src/components/business/bcSwitchSystems/useSwitchSystems.ts +74 -0
- package/src/components/business/bcTable/bcTable.vue +63 -0
- package/src/components/business/bcTable/components/sortColumn/index.ts +19 -0
- package/src/components/business/bcTable/components/sortColumn/sortColumn.vue +107 -0
- package/src/components/business/bcTable/useTable.ts +51 -0
- package/src/components/business/bcTable/useTableHeight.ts +24 -0
- package/src/components/business/bcTreeSelect/bcTreeSelect.vue +12 -0
- package/src/components/business/cardID/cardID.vue +24 -0
- package/src/components/business/cardID/type.ts +0 -0
- package/src/components/business/cardID/useCardID.ts +0 -0
- package/src/components/component.ts +188 -0
- package/src/components/config/autocompleteAttrConfig/autocompleteAttrConfig.vue +26 -0
- package/src/components/config/autocompleteAttrConfig/config.ts +170 -0
- package/src/components/config/baseForm.vue +175 -0
- package/src/components/config/buttonAttrConfig/buttonAttrConfig.vue +26 -0
- package/src/components/config/buttonAttrConfig/config.ts +261 -0
- package/src/components/config/cascaderAttrConfig/cascaderAttrConfig.vue +26 -0
- package/src/components/config/cascaderAttrConfig/config.ts +287 -0
- package/src/components/config/cascaderPanelAttrConfig/cascaderPanelAttrConfig.vue +26 -0
- package/src/components/config/cascaderPanelAttrConfig/config.ts +278 -0
- package/src/components/config/checkboxAttrConfig/checkboxAttrConfig.vue +26 -0
- package/src/components/config/checkboxAttrConfig/config.ts +301 -0
- package/src/components/config/datePickerAttrConfig/config.ts +256 -0
- package/src/components/config/datePickerAttrConfig/datePickerAttrConfig.vue +26 -0
- package/src/components/config/inputAttrConfig/config.ts +322 -0
- package/src/components/config/inputAttrConfig/inputAttrConfig.vue +33 -0
- package/src/components/config/inputAttrConfig/inputEventConfig.vue +35 -0
- package/src/components/config/inputNumberAttrConfig/config.ts +177 -0
- package/src/components/config/inputNumberAttrConfig/inputNumberAttrConfig.vue +26 -0
- package/src/components/config/radioAttrConfig/config.ts +212 -0
- package/src/components/config/radioAttrConfig/radioAttrConfig.vue +26 -0
- package/src/components/config/selectAttrConfig/config.ts +478 -0
- package/src/components/config/selectAttrConfig/selectAttrConfig.vue +26 -0
- package/src/components/config/switchAttrConfig/config.ts +195 -0
- package/src/components/config/switchAttrConfig/switchAttrConfig.vue +26 -0
- package/src/components/config/treeSelectAttrConfig/config.ts +625 -0
- package/src/components/config/treeSelectAttrConfig/treeSelectAttrConfig.vue +26 -0
- package/src/components/config/type/formType.ts +25 -0
- package/src/components/config/uploadAttrConfig/config.ts +250 -0
- package/src/components/config/uploadAttrConfig/uploadAttrConfig.vue +26 -0
- package/src/components/iconSelector/index.vue +247 -0
- package/src/components/iconSelector/list.vue +84 -0
- package/src/components/svgIcon/index.vue +61 -0
- package/src/directive/authDirective.ts +40 -0
- package/src/directive/customDirective.ts +178 -0
- package/src/directive/index.ts +18 -0
- package/src/hooks/useCrypto.ts +36 -0
- package/src/hooks/useExpose.ts +60 -0
- package/src/layout/component/aside.vue +160 -0
- package/src/layout/component/columnsAside.vue +299 -0
- package/src/layout/component/header.vue +18 -0
- package/src/layout/component/main.vue +65 -0
- package/src/layout/footer/index.vue +25 -0
- package/src/layout/index.vue +53 -0
- package/src/layout/lockScreen/index.vue +352 -0
- package/src/layout/logo/index.vue +75 -0
- package/src/layout/main/classic.vue +73 -0
- package/src/layout/main/columns.vue +73 -0
- package/src/layout/main/defaults.vue +73 -0
- package/src/layout/main/transverse.vue +60 -0
- package/src/layout/navBars/index.vue +35 -0
- package/src/layout/navBars/tagsView/contextmenu.vue +133 -0
- package/src/layout/navBars/tagsView/tagsView.vue +737 -0
- package/src/layout/navBars/topBar/breadcrumb.vue +146 -0
- package/src/layout/navBars/topBar/closeFull.vue +53 -0
- package/src/layout/navBars/topBar/index.vue +107 -0
- package/src/layout/navBars/topBar/search.vue +123 -0
- package/src/layout/navBars/topBar/setings.vue +789 -0
- package/src/layout/navBars/topBar/user.vue +222 -0
- package/src/layout/navBars/topBar/userNews.vue +107 -0
- package/src/layout/navMenu/horizontal.vue +138 -0
- package/src/layout/navMenu/subItem.vue +49 -0
- package/src/layout/navMenu/vertical.vue +100 -0
- package/src/layout/routerView/iframes.vue +101 -0
- package/src/layout/routerView/link.vue +93 -0
- package/src/layout/routerView/parent.vue +104 -0
- package/src/layout/upgrade/index.vue +147 -0
- package/src/main.ts +70 -0
- package/src/router/backEnd.ts +173 -0
- package/src/router/frontEnd.ts +155 -0
- package/src/router/index.ts +138 -0
- package/src/router/route.ts +94 -0
- package/src/stores/index.ts +8 -0
- package/src/stores/keepAliveNames.ts +38 -0
- package/src/stores/requestOldRoutes.ts +16 -0
- package/src/stores/routesList.ts +26 -0
- package/src/stores/tagsViewRoutes.ts +23 -0
- package/src/stores/themeConfig.ts +142 -0
- package/src/stores/userInfo.ts +65 -0
- package/src/style/index.scss +0 -0
- package/src/style/tailwind.css +29 -0
- package/src/theme/app.scss +333 -0
- package/src/theme/common/transition.scss +147 -0
- package/src/theme/dark.scss +255 -0
- package/src/theme/element.scss +321 -0
- package/src/theme/iconSelector.scss +31 -0
- package/src/theme/index.scss +8 -0
- package/src/theme/loading.scss +51 -0
- package/src/theme/media/chart.scss +94 -0
- package/src/theme/media/cityLinkage.scss +10 -0
- package/src/theme/media/date.scss +25 -0
- package/src/theme/media/dialog.scss +12 -0
- package/src/theme/media/error.scss +45 -0
- package/src/theme/media/form.scss +31 -0
- package/src/theme/media/home.scss +23 -0
- package/src/theme/media/index.scss +15 -0
- package/src/theme/media/layout.scss +63 -0
- package/src/theme/media/login.scss +74 -0
- package/src/theme/media/media.scss +13 -0
- package/src/theme/media/pagination.scss +15 -0
- package/src/theme/media/personal.scss +16 -0
- package/src/theme/media/scrollbar.scss +56 -0
- package/src/theme/media/tagsView.scss +11 -0
- package/src/theme/mixins/index.scss +56 -0
- package/src/theme/other.scss +36 -0
- package/src/theme/tableTool.scss +27 -0
- package/src/theme/waves.scss +101 -0
- package/src/types/auth.d.ts +44 -0
- package/src/types/axios.d.ts +13 -0
- package/src/types/components.d.ts +30 -0
- package/src/types/customData.d.ts +163 -0
- package/src/types/form.ts +68 -0
- package/src/types/formItem/autocomplete.ts +43 -0
- package/src/types/formItem/button.ts +39 -0
- package/src/types/formItem/input.ts +66 -0
- package/src/types/formItem/inputNumber.ts +42 -0
- package/src/types/formItem/selelct.ts +54 -0
- package/src/types/formItem/treeSelect.ts +37 -0
- package/src/types/formTable.d.ts +210 -0
- package/src/types/global.d.ts +118 -0
- package/src/types/layout.d.ts +59 -0
- package/src/types/mitt.d.ts +38 -0
- package/src/types/pinia.d.ts +92 -0
- package/src/types/views.d.ts +331 -0
- package/src/utils/arrayOperation.ts +65 -0
- package/src/utils/authFunction.ts +38 -0
- package/src/utils/build.ts +124 -0
- package/src/utils/commonFunction.ts +64 -0
- package/src/utils/formatTime.ts +137 -0
- package/src/utils/getDataType.ts +136 -0
- package/src/utils/getStyleSheets.ts +101 -0
- package/src/utils/loading.ts +44 -0
- package/src/utils/mitt.ts +8 -0
- package/src/utils/other.ts +214 -0
- package/src/utils/request.ts +82 -0
- package/src/utils/setIconfont.ts +48 -0
- package/src/utils/showMessage.ts +57 -0
- package/src/utils/showMessageBox.ts +39 -0
- package/src/utils/showNotification.ts +50 -0
- package/src/utils/showPopup.ts +81 -0
- package/src/utils/storage.ts +137 -0
- package/src/utils/theme.ts +65 -0
- package/src/utils/toolsValidate.ts +370 -0
- package/src/utils/watermark.ts +47 -0
- package/src/views/error/401.vue +88 -0
- package/src/views/error/404.vue +89 -0
- package/src/views/home/index.vue +62 -0
- package/src/views/login/component/account.vue +172 -0
- package/src/views/login/component/mobile.vue +72 -0
- package/src/views/login/component/scan.vue +63 -0
- package/src/views/login/index.vue +254 -0
- package/src/views/system/auth/index.vue +48 -0
- package/src/views/system/auth/list.ts +50 -0
- package/src/views/system/auth/useAuth.ts +34 -0
- package/src/views/system/dept/dialog.vue +167 -0
- package/src/views/system/dept/index.vue +135 -0
- package/src/views/system/dic/dialog.vue +150 -0
- package/src/views/system/dic/index.vue +132 -0
- package/src/views/system/form/data.json +360 -0
- package/src/views/system/form/index.vue +24 -0
- package/src/views/system/formSetting/components/hsBtn/src/hsAttrBtn.vue +58 -0
- package/src/views/system/formSetting/components/hsBtn/src/hsBtnConfigList.vue +45 -0
- package/src/views/system/formSetting/components/hsBtn/src/hsBtnPanel.vue +51 -0
- package/src/views/system/formSetting/components/hsBtn/useAttrBtn.ts +129 -0
- package/src/views/system/formSetting/components/hsBtn/useBtnConfigList.ts +73 -0
- package/src/views/system/formSetting/components/hsExpand/src/hsExpand.vue +27 -0
- package/src/views/system/formSetting/components/hsExpand/useExpand.ts +9 -0
- package/src/views/system/formSetting/components/hsForm/src/hsAttrForm.vue +124 -0
- package/src/views/system/formSetting/components/hsForm/src/hsFormConfig.vue +180 -0
- package/src/views/system/formSetting/components/hsForm/src/hsFormConfigList.vue +45 -0
- package/src/views/system/formSetting/components/hsForm/src/hsFormPanel.vue +152 -0
- package/src/views/system/formSetting/components/hsForm/src/hsFormParse.vue +33 -0
- package/src/views/system/formSetting/components/hsForm/useAttrForm.ts +109 -0
- package/src/views/system/formSetting/components/hsForm/useFormListConfig.ts +70 -0
- package/src/views/system/formSetting/components/hsPageTree/configData.ts +3700 -0
- package/src/views/system/formSetting/components/hsPageTree/src/hsPageTree.vue +30 -0
- package/src/views/system/formSetting/components/hsPageTree/usePageTree.ts +50 -0
- package/src/views/system/formSetting/components/hsSaveForm/saveFormConfig.ts +66 -0
- package/src/views/system/formSetting/components/hsSaveForm/src/saveForm.vue +47 -0
- package/src/views/system/formSetting/components/hsSaveForm/useSaveForm.ts +122 -0
- package/src/views/system/formSetting/components/hsTables/src/hsAttrTable.vue +91 -0
- package/src/views/system/formSetting/components/hsTables/src/hsRecursionConfig.vue +36 -0
- package/src/views/system/formSetting/components/hsTables/src/hsTableConfig.vue +39 -0
- package/src/views/system/formSetting/components/hsTables/src/hsTableConfigList.vue +45 -0
- package/src/views/system/formSetting/components/hsTables/src/hsTablePanel.vue +56 -0
- package/src/views/system/formSetting/components/hsTables/src/hsTableParse.vue +29 -0
- package/src/views/system/formSetting/components/hsTables/useAttrTable.ts +125 -0
- package/src/views/system/formSetting/components/hsTables/useTableConfigList.ts +77 -0
- package/src/views/system/formSetting/components/selectConfig/config.ts +476 -0
- package/src/views/system/formSetting/components/selectConfig/selectConfig.vue +30 -0
- package/src/views/system/formSetting/data.json +360 -0
- package/src/views/system/formSetting/default/baseBtnConfig.ts +216 -0
- package/src/views/system/formSetting/default/baseFormConfig.ts +567 -0
- package/src/views/system/formSetting/default/baseTableConfig.ts +2353 -0
- package/src/views/system/formSetting/formConfig.vue +108 -0
- package/src/views/system/formSetting/index.vue +35 -0
- package/src/views/system/formSetting/menuType.d.ts +12 -0
- package/src/views/system/formSetting/panelConfig.json +164 -0
- package/src/views/system/formSetting/useForm.ts +89 -0
- package/src/views/system/formSetting/useFormConfig.ts +192 -0
- package/src/views/system/menu/dialog.vue +285 -0
- package/src/views/system/menu/index.vue +180 -0
- package/src/views/system/page/components/hsPageTree/configData.ts +3700 -0
- package/src/views/system/page/components/hsPageTree/src/hsPageTree.vue +30 -0
- package/src/views/system/page/components/hsPageTree/usePageTree.ts +49 -0
- package/src/views/system/page/index.vue +32 -0
- package/src/views/system/page/menuType.d.ts +12 -0
- package/src/views/system/page/usePage.ts +125 -0
- package/src/views/system/role/dialog.vue +236 -0
- package/src/views/system/role/index.vue +146 -0
- package/src/views/system/table/data.json +747 -0
- package/src/views/system/table/formate.js +49 -0
- package/src/views/system/table/index.vue +53 -0
- package/src/views/system/user/dialog.vue +187 -0
- package/src/views/system/user/index.vue +161 -0
- package/src/views/test/test/components/hsBtn/src/hsAttrBtn.vue +58 -0
- package/src/views/test/test/components/hsBtn/src/hsBtnConfigList.vue +45 -0
- package/src/views/test/test/components/hsBtn/src/hsBtnPanel.vue +51 -0
- package/src/views/test/test/components/hsBtn/useAttrBtn.ts +129 -0
- package/src/views/test/test/components/hsBtn/useBtnConfigList.ts +73 -0
- package/src/views/test/test/components/hsExpand/src/hsExpand.vue +27 -0
- package/src/views/test/test/components/hsExpand/useExpand.ts +9 -0
- package/src/views/test/test/components/hsForm/src/hsAttrForm.vue +124 -0
- package/src/views/test/test/components/hsForm/src/hsFormConfig.vue +180 -0
- package/src/views/test/test/components/hsForm/src/hsFormConfigList.vue +45 -0
- package/src/views/test/test/components/hsForm/src/hsFormPanel.vue +152 -0
- package/src/views/test/test/components/hsForm/src/hsFormParse.vue +33 -0
- package/src/views/test/test/components/hsForm/useAttrForm.ts +109 -0
- package/src/views/test/test/components/hsForm/useFormListConfig.ts +70 -0
- package/src/views/test/test/components/hsSaveForm/saveFormConfig.ts +66 -0
- package/src/views/test/test/components/hsSaveForm/src/saveForm.vue +47 -0
- package/src/views/test/test/components/hsSaveForm/useSaveForm.ts +122 -0
- package/src/views/test/test/components/hsTables/src/hsAttrTable.vue +91 -0
- package/src/views/test/test/components/hsTables/src/hsRecursionConfig.vue +36 -0
- package/src/views/test/test/components/hsTables/src/hsTableConfig.vue +39 -0
- package/src/views/test/test/components/hsTables/src/hsTableConfigList.vue +45 -0
- package/src/views/test/test/components/hsTables/src/hsTablePanel.vue +56 -0
- package/src/views/test/test/components/hsTables/src/hsTableParse.vue +29 -0
- package/src/views/test/test/components/hsTables/useAttrTable.ts +125 -0
- package/src/views/test/test/components/hsTables/useTableConfigList.ts +77 -0
- package/src/views/test/test/components/selectConfig/config.ts +476 -0
- package/src/views/test/test/components/selectConfig/selectConfig.vue +30 -0
- package/src/views/test/test/data.json +360 -0
- package/src/views/test/test/default/baseBtnConfig.ts +216 -0
- package/src/views/test/test/default/baseFormConfig.ts +567 -0
- package/src/views/test/test/default/baseTableConfig.ts +2353 -0
- package/src/views/test/test/formConfig.vue +102 -0
- package/src/views/test/test/test.vue +28 -0
- package/src/views/test/test/test3.vue +24 -0
- package/src/views/test/test/test4.vue +107 -0
- package/src/views/test/test/test/345/211/257/346/234/254.vue +2424 -0
- package/src/views/test/test/useFormConfig.ts +192 -0
- package/src/views/test/test2/test2.vue +17 -0
- package/src/views/test/test3/test.vue +20 -0
- package/tailwind.config.js +12 -0
- package/tsconfig.json +75 -0
- package/vite.config.ts +123 -0
|
@@ -0,0 +1,212 @@
|
|
|
1
|
+
export const radioAttrConfig = [
|
|
2
|
+
{
|
|
3
|
+
prop: 'attrs',
|
|
4
|
+
label: 'radioAttrs',
|
|
5
|
+
tooltip: 'radioAttrs',
|
|
6
|
+
type: 'object',
|
|
7
|
+
el: 'title',
|
|
8
|
+
children: [
|
|
9
|
+
{
|
|
10
|
+
prop: 'defaultValue',
|
|
11
|
+
label: '默认值',
|
|
12
|
+
tooltip: '默认值',
|
|
13
|
+
type: 'string / number / boolean',
|
|
14
|
+
el: 'hs-input',
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
prop: 'label',
|
|
18
|
+
label: '单选框的值',
|
|
19
|
+
tooltip: '单选框的值',
|
|
20
|
+
type: 'string / number / boolean',
|
|
21
|
+
el: 'hs-input',
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
prop: 'disabled',
|
|
25
|
+
label: '是否禁用单选框',
|
|
26
|
+
tooltip: '是否禁用单选框',
|
|
27
|
+
type: 'boolean',
|
|
28
|
+
el: 'hs-switch',
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
prop: 'border',
|
|
32
|
+
label: '是否显示边框',
|
|
33
|
+
tooltip: '是否显示边框',
|
|
34
|
+
type: 'boolean',
|
|
35
|
+
el: 'hs-switch',
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
prop: 'size',
|
|
39
|
+
label: '单选框的尺寸',
|
|
40
|
+
tooltip: '单选框的尺寸',
|
|
41
|
+
type: 'enum',
|
|
42
|
+
el: 'hs-select',
|
|
43
|
+
op: [
|
|
44
|
+
{ label: 'large', value: 'large' },
|
|
45
|
+
{ label: 'default', value: 'default' },
|
|
46
|
+
{ label: 'small', value: 'small' },
|
|
47
|
+
],
|
|
48
|
+
cel: 'hs-option',
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
prop: 'name',
|
|
52
|
+
label: '原始 name 属性',
|
|
53
|
+
tooltip: '原始 name 属性',
|
|
54
|
+
type: 'string',
|
|
55
|
+
el: 'hs-input',
|
|
56
|
+
},
|
|
57
|
+
],
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
prop: 'groupAttrs',
|
|
61
|
+
label: 'radioGroupAttrs',
|
|
62
|
+
tooltip: 'radioGroupAttrs',
|
|
63
|
+
type: 'object',
|
|
64
|
+
el: 'title',
|
|
65
|
+
children: [
|
|
66
|
+
{
|
|
67
|
+
prop: 'isGroupEnabled',
|
|
68
|
+
label: '是否启用分组',
|
|
69
|
+
tooltip: '是否启用分组',
|
|
70
|
+
type: 'boolean',
|
|
71
|
+
el: 'hs-switch',
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
prop: 'size',
|
|
75
|
+
label: '单选框按钮大小',
|
|
76
|
+
tooltip: '单选框按钮或边框按钮的大小',
|
|
77
|
+
type: 'enum',
|
|
78
|
+
el: 'hs-select',
|
|
79
|
+
op: [
|
|
80
|
+
{ label: 'large', value: 'large' },
|
|
81
|
+
{ label: 'default', value: 'default' },
|
|
82
|
+
{ label: 'small', value: 'small' },
|
|
83
|
+
],
|
|
84
|
+
cel: 'hs-option',
|
|
85
|
+
},
|
|
86
|
+
{
|
|
87
|
+
prop: 'disabled',
|
|
88
|
+
label: '是否禁用',
|
|
89
|
+
tooltip: '是否禁用',
|
|
90
|
+
type: 'boolean',
|
|
91
|
+
el: 'hs-switch',
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
prop: 'text-color',
|
|
95
|
+
label: '字体颜色',
|
|
96
|
+
tooltip: '当按钮为活跃状态时的字体颜色',
|
|
97
|
+
type: 'string',
|
|
98
|
+
el: 'hs-input',
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
prop: 'fill',
|
|
102
|
+
label: '边框和背景颜色',
|
|
103
|
+
tooltip: '当按钮为活跃状态时的边框和背景颜色',
|
|
104
|
+
type: 'string',
|
|
105
|
+
el: 'hs-input',
|
|
106
|
+
},
|
|
107
|
+
{
|
|
108
|
+
prop: 'validate-event',
|
|
109
|
+
label: '是否触发表单验证',
|
|
110
|
+
tooltip: '是否触发表单验证',
|
|
111
|
+
type: 'string',
|
|
112
|
+
el: 'hs-switch',
|
|
113
|
+
},
|
|
114
|
+
{
|
|
115
|
+
prop: 'label',
|
|
116
|
+
label: '单选框的值',
|
|
117
|
+
tooltip: '单选框的值',
|
|
118
|
+
type: 'string',
|
|
119
|
+
el: 'hs-input',
|
|
120
|
+
},
|
|
121
|
+
{
|
|
122
|
+
prop: 'name',
|
|
123
|
+
label: '原生 name 属性',
|
|
124
|
+
tooltip: '原生 name 属性',
|
|
125
|
+
type: 'string',
|
|
126
|
+
el: 'hs-input',
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
prop: 'id ',
|
|
130
|
+
label: '原生 id 属性',
|
|
131
|
+
tooltip: '原生 id 属性',
|
|
132
|
+
type: 'string',
|
|
133
|
+
el: 'hs-input',
|
|
134
|
+
},
|
|
135
|
+
],
|
|
136
|
+
},
|
|
137
|
+
{
|
|
138
|
+
prop: 'buttonAttrs',
|
|
139
|
+
label: 'radioButtonAttrs',
|
|
140
|
+
tooltip: 'radioButtonAttrs',
|
|
141
|
+
type: 'object',
|
|
142
|
+
el: 'title',
|
|
143
|
+
children: [
|
|
144
|
+
{
|
|
145
|
+
prop: 'label',
|
|
146
|
+
label: '单选框的值',
|
|
147
|
+
tooltip: '单选框的值',
|
|
148
|
+
type: 'string',
|
|
149
|
+
el: 'hs-input',
|
|
150
|
+
},
|
|
151
|
+
{
|
|
152
|
+
prop: 'disabled',
|
|
153
|
+
label: '是否禁用单选框',
|
|
154
|
+
tooltip: '是否禁用单选框',
|
|
155
|
+
type: 'string',
|
|
156
|
+
el: 'hs-switch',
|
|
157
|
+
},
|
|
158
|
+
{
|
|
159
|
+
prop: 'name',
|
|
160
|
+
label: '原生 name 属性',
|
|
161
|
+
tooltip: '原生 name 属性',
|
|
162
|
+
type: 'string',
|
|
163
|
+
el: 'hs-input',
|
|
164
|
+
},
|
|
165
|
+
],
|
|
166
|
+
},
|
|
167
|
+
{
|
|
168
|
+
prop: 'rules',
|
|
169
|
+
label: 'rules',
|
|
170
|
+
tooltip: 'rules',
|
|
171
|
+
type: 'object',
|
|
172
|
+
el: 'title',
|
|
173
|
+
children: [
|
|
174
|
+
{
|
|
175
|
+
prop: 'required',
|
|
176
|
+
label: '是否必填',
|
|
177
|
+
tooltip: '是否必填',
|
|
178
|
+
type: 'boolean',
|
|
179
|
+
el: 'hs-switch',
|
|
180
|
+
},
|
|
181
|
+
// 必填项规则
|
|
182
|
+
{
|
|
183
|
+
prop: 'rules',
|
|
184
|
+
label: '必填项规则',
|
|
185
|
+
tooltip: '必填项规则',
|
|
186
|
+
type: 'array',
|
|
187
|
+
el: 'hs-input',
|
|
188
|
+
attrs: {
|
|
189
|
+
type: 'textarea',
|
|
190
|
+
},
|
|
191
|
+
},
|
|
192
|
+
],
|
|
193
|
+
},
|
|
194
|
+
];
|
|
195
|
+
export const radioAttrConfigMap = {
|
|
196
|
+
// 默认配置项
|
|
197
|
+
attrs: {
|
|
198
|
+
disabled: false, // 是否禁用单选框
|
|
199
|
+
border: false, // 是否显示边框
|
|
200
|
+
},
|
|
201
|
+
groupAttrs: {
|
|
202
|
+
size: 'small', // 单选框按钮大小
|
|
203
|
+
disabled: false, // 是否禁用
|
|
204
|
+
'text-color': '#ffffff', // 字体颜色
|
|
205
|
+
fill: '#409EFF', // 边框和背景颜色
|
|
206
|
+
'validate-event': true, // 是否触发表单验证
|
|
207
|
+
},
|
|
208
|
+
buttonAttrs: {
|
|
209
|
+
disabled: false, // 是否禁用单选框
|
|
210
|
+
},
|
|
211
|
+
rules: {},
|
|
212
|
+
};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="p-[10px] h-full">
|
|
3
|
+
<base-form v-model:data="data" :config="radioAttrConfig" :isVModel="isVModel"></base-form>
|
|
4
|
+
</div>
|
|
5
|
+
</template>
|
|
6
|
+
|
|
7
|
+
<script setup lang="ts" name="radioAttrConfig">
|
|
8
|
+
import baseForm from '../baseForm.vue';
|
|
9
|
+
import { ref } from 'vue';
|
|
10
|
+
import { radioAttrConfig, radioAttrConfigMap } from './config';
|
|
11
|
+
import _ from 'lodash';
|
|
12
|
+
const props = defineProps({
|
|
13
|
+
data: {
|
|
14
|
+
type: Object,
|
|
15
|
+
default: () => {},
|
|
16
|
+
},
|
|
17
|
+
isVModel: {
|
|
18
|
+
type: Boolean,
|
|
19
|
+
default: false,
|
|
20
|
+
},
|
|
21
|
+
});
|
|
22
|
+
// lodash判断对象是否为空
|
|
23
|
+
const data = ref(_.isEmpty(props.data) ? Object.assign(props.data, _.cloneDeep(radioAttrConfigMap)) : props.data);
|
|
24
|
+
</script>
|
|
25
|
+
|
|
26
|
+
<style scoped lang="scss"></style>
|
|
@@ -0,0 +1,478 @@
|
|
|
1
|
+
export const selectAttrConfig = [
|
|
2
|
+
{
|
|
3
|
+
prop: 'attrs',
|
|
4
|
+
label: 'selectAttrs',
|
|
5
|
+
tooltip: 'selectAttrs',
|
|
6
|
+
type: 'object',
|
|
7
|
+
el: 'title',
|
|
8
|
+
children: [
|
|
9
|
+
{
|
|
10
|
+
prop: 'defaultValue',
|
|
11
|
+
label: '默认值',
|
|
12
|
+
tooltip: '默认值',
|
|
13
|
+
type: 'string / number / boolean / object / array',
|
|
14
|
+
el: 'hs-input',
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
prop: 'options',
|
|
18
|
+
label: 'option配置数据',
|
|
19
|
+
tooltip: 'option配置数据',
|
|
20
|
+
type: 'string',
|
|
21
|
+
el: 'hs-input',
|
|
22
|
+
attrs: {
|
|
23
|
+
type: 'textarea',
|
|
24
|
+
},
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
prop: 'url',
|
|
28
|
+
label: 'url获取options',
|
|
29
|
+
tooltip: '通过url请求获取options配置项数据',
|
|
30
|
+
type: 'string',
|
|
31
|
+
el: 'hs-input',
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
prop: 'paramKey',
|
|
35
|
+
label: '请求参数key',
|
|
36
|
+
tooltip: '请求参数key',
|
|
37
|
+
type: 'string',
|
|
38
|
+
el: 'hs-input',
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
prop: 'paramValue',
|
|
42
|
+
label: '请求参数Value',
|
|
43
|
+
tooltip: '请求参数Value',
|
|
44
|
+
type: 'string',
|
|
45
|
+
el: 'hs-input',
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
prop: 'multiple',
|
|
49
|
+
label: '是否多选',
|
|
50
|
+
tooltip: '是否多选',
|
|
51
|
+
type: 'boolean',
|
|
52
|
+
el: 'hs-switch',
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
prop: 'disabled',
|
|
56
|
+
label: '是否禁用',
|
|
57
|
+
tooltip: '是否禁用',
|
|
58
|
+
type: 'boolean',
|
|
59
|
+
el: 'hs-switch',
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
prop: 'value-key',
|
|
63
|
+
label: 'value 唯一标识',
|
|
64
|
+
tooltip: '作为 value 唯一标识的键名,绑定值为对象类型时必填',
|
|
65
|
+
type: 'string',
|
|
66
|
+
el: 'hs-input',
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
prop: 'placeholder',
|
|
70
|
+
label: '占位符',
|
|
71
|
+
tooltip: '占位符,默认为“Select”',
|
|
72
|
+
type: 'string',
|
|
73
|
+
el: 'hs-input',
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
prop: 'size',
|
|
77
|
+
label: '输入框尺寸',
|
|
78
|
+
tooltip: '输入框尺寸',
|
|
79
|
+
type: 'enum',
|
|
80
|
+
el: 'hs-select',
|
|
81
|
+
op: [
|
|
82
|
+
{ label: 'large', value: 'large' },
|
|
83
|
+
{ label: 'default', value: 'default' },
|
|
84
|
+
{ label: 'small', value: 'small' },
|
|
85
|
+
],
|
|
86
|
+
cel: 'hs-option',
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
prop: 'clearable',
|
|
90
|
+
label: '是否可以清空',
|
|
91
|
+
tooltip: '是否可以清空选项',
|
|
92
|
+
type: 'boolean',
|
|
93
|
+
el: 'hs-switch',
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
prop: 'collapse-tags',
|
|
97
|
+
label: '值按文字展示',
|
|
98
|
+
tooltip: '多选时是否将选中值按文字的形式展示',
|
|
99
|
+
type: 'boolean',
|
|
100
|
+
el: 'hs-switch',
|
|
101
|
+
},
|
|
102
|
+
{
|
|
103
|
+
prop: 'collapse-tags-tooltip',
|
|
104
|
+
label: '是否显示所选',
|
|
105
|
+
tooltip: '当鼠标悬停于折叠标签的文本时,是否显示所有选中的标签。 要使用此属性,collapse-tags属性必须设定为 true',
|
|
106
|
+
type: 'boolean',
|
|
107
|
+
el: 'hs-switch',
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
prop: 'multiple-limit',
|
|
111
|
+
label: '最多可选数',
|
|
112
|
+
tooltip: 'multiple 属性设置为 true 时,代表多选场景下用户最多可以选择的项目数, 为 0 则不限制',
|
|
113
|
+
type: 'number',
|
|
114
|
+
el: 'hs-input-number',
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
prop: 'name',
|
|
118
|
+
label: '原生name属性',
|
|
119
|
+
tooltip: 'Select 输入框的原生 name 属性',
|
|
120
|
+
type: 'string',
|
|
121
|
+
el: 'hs-input',
|
|
122
|
+
},
|
|
123
|
+
{
|
|
124
|
+
prop: 'effect',
|
|
125
|
+
label: 'tooltip 主题',
|
|
126
|
+
tooltip: 'tooltip 主题,内置了 dark / light 两种',
|
|
127
|
+
type: 'enum / string',
|
|
128
|
+
el: 'hs-select',
|
|
129
|
+
op: [
|
|
130
|
+
{ label: 'dark', value: 'dark' },
|
|
131
|
+
{ label: 'light', value: 'light' },
|
|
132
|
+
],
|
|
133
|
+
cel: 'hs-option',
|
|
134
|
+
},
|
|
135
|
+
{
|
|
136
|
+
prop: 'autocomplete',
|
|
137
|
+
label: 'autocomplete',
|
|
138
|
+
tooltip: 'Select 输入框的原生 autocomplete 属性',
|
|
139
|
+
type: 'string',
|
|
140
|
+
el: 'hs-input',
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
prop: 'filterable',
|
|
144
|
+
label: '是否可筛选',
|
|
145
|
+
tooltip: 'Select 组件是否可筛选',
|
|
146
|
+
type: 'boolean',
|
|
147
|
+
el: 'hs-switch',
|
|
148
|
+
},
|
|
149
|
+
{
|
|
150
|
+
prop: 'allow-create',
|
|
151
|
+
label: '允许创建条目',
|
|
152
|
+
tooltip: '是否允许用户创建新条目, 只有当 filterable 设置为 true 时才会生效。',
|
|
153
|
+
type: 'boolean',
|
|
154
|
+
el: 'hs-switch',
|
|
155
|
+
},
|
|
156
|
+
{
|
|
157
|
+
prop: 'filter-method',
|
|
158
|
+
label: '筛选方法',
|
|
159
|
+
tooltip: '自定义筛选方法',
|
|
160
|
+
type: 'Function',
|
|
161
|
+
el: 'hs-input',
|
|
162
|
+
},
|
|
163
|
+
{
|
|
164
|
+
prop: 'remote',
|
|
165
|
+
label: '是否远程加载',
|
|
166
|
+
tooltip: '其中的选项是否从服务器远程加载',
|
|
167
|
+
type: 'boolean',
|
|
168
|
+
el: 'hs-switch',
|
|
169
|
+
},
|
|
170
|
+
{
|
|
171
|
+
prop: 'remote-method',
|
|
172
|
+
label: '远程搜索方法',
|
|
173
|
+
tooltip: '自定义远程搜索方法',
|
|
174
|
+
type: 'Function',
|
|
175
|
+
el: 'hs-input',
|
|
176
|
+
},
|
|
177
|
+
{
|
|
178
|
+
prop: 'remote-show-suffix',
|
|
179
|
+
label: '远程搜索图标',
|
|
180
|
+
tooltip: '远程搜索方法显示后缀图标',
|
|
181
|
+
type: 'boolean',
|
|
182
|
+
el: 'hs-switch',
|
|
183
|
+
},
|
|
184
|
+
{
|
|
185
|
+
prop: 'loading',
|
|
186
|
+
label: '是否正在获取',
|
|
187
|
+
tooltip: '是否正在从远程获取数据',
|
|
188
|
+
type: 'boolean',
|
|
189
|
+
el: 'hs-switch',
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
prop: 'loading-text',
|
|
193
|
+
label: '加载时文本',
|
|
194
|
+
tooltip: '从服务器加载数据时显示的文本,默认为“Loading”',
|
|
195
|
+
type: 'string',
|
|
196
|
+
el: 'hs-input',
|
|
197
|
+
},
|
|
198
|
+
{
|
|
199
|
+
prop: 'no-match-text',
|
|
200
|
+
label: '无匹配时显示',
|
|
201
|
+
tooltip: "搜索条件无匹配时显示的文字,也可以使用 empty 插槽设置,默认是 “No matching data'”",
|
|
202
|
+
type: 'string',
|
|
203
|
+
el: 'hs-input',
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
prop: 'no-data-text',
|
|
207
|
+
label: '无选项时显示',
|
|
208
|
+
tooltip: '无选项时显示的文字,也可以使用 empty 插槽设置自定义内容,默认是 “No data”',
|
|
209
|
+
type: 'string',
|
|
210
|
+
el: 'hs-input',
|
|
211
|
+
},
|
|
212
|
+
{
|
|
213
|
+
prop: 'popper-class',
|
|
214
|
+
label: '下拉菜单类名',
|
|
215
|
+
tooltip: '选择器下拉菜单的自定义类名',
|
|
216
|
+
type: 'string',
|
|
217
|
+
el: 'hs-input',
|
|
218
|
+
},
|
|
219
|
+
{
|
|
220
|
+
prop: 'reserve-keyword',
|
|
221
|
+
label: '保留关键词',
|
|
222
|
+
tooltip: '当 multiple 和 filterable被设置为 true 时,是否在选中一个选项后保留当前的搜索关键词',
|
|
223
|
+
type: 'boolean',
|
|
224
|
+
el: 'hs-switch',
|
|
225
|
+
},
|
|
226
|
+
{
|
|
227
|
+
prop: 'default-first-option',
|
|
228
|
+
label: '回车选择',
|
|
229
|
+
tooltip: '是否在输入框按下回车时,选择第一个匹配项。 需配合 filterable 或 remote 使用',
|
|
230
|
+
type: 'boolean',
|
|
231
|
+
el: 'hs-switch',
|
|
232
|
+
},
|
|
233
|
+
{
|
|
234
|
+
prop: 'teleported',
|
|
235
|
+
label: '是否插入至body',
|
|
236
|
+
tooltip: '是否将下拉列表插入至 body 元素',
|
|
237
|
+
type: 'boolean',
|
|
238
|
+
el: 'hs-switch',
|
|
239
|
+
},
|
|
240
|
+
{
|
|
241
|
+
prop: 'persistent',
|
|
242
|
+
label: '选择器未被激活',
|
|
243
|
+
tooltip: '当下拉选择器未被激活并且persistent设置为false,选择器会被删除。',
|
|
244
|
+
type: 'boolean',
|
|
245
|
+
el: 'hs-switch',
|
|
246
|
+
},
|
|
247
|
+
{
|
|
248
|
+
prop: 'automatic-dropdown',
|
|
249
|
+
label: '自动弹出选项',
|
|
250
|
+
tooltip: '对于不可搜索的 Select,是否在输入框获得焦点后自动弹出选项菜单',
|
|
251
|
+
type: 'boolean',
|
|
252
|
+
el: 'hs-switch',
|
|
253
|
+
},
|
|
254
|
+
{
|
|
255
|
+
prop: 'clear-icon',
|
|
256
|
+
label: '清除图标',
|
|
257
|
+
tooltip: '自定义清除图标',
|
|
258
|
+
type: 'string / object',
|
|
259
|
+
el: 'hs-input',
|
|
260
|
+
},
|
|
261
|
+
{
|
|
262
|
+
prop: 'fit-input-width',
|
|
263
|
+
label: '下拉框宽度',
|
|
264
|
+
tooltip: '下拉框的宽度是否与输入框相同',
|
|
265
|
+
type: 'boolean',
|
|
266
|
+
el: 'hs-switch',
|
|
267
|
+
},
|
|
268
|
+
{
|
|
269
|
+
prop: 'suffix-icon',
|
|
270
|
+
label: '后缀图标',
|
|
271
|
+
tooltip: '自定义后缀图标组件',
|
|
272
|
+
type: 'string / object',
|
|
273
|
+
el: 'hs-input',
|
|
274
|
+
},
|
|
275
|
+
{
|
|
276
|
+
prop: 'suffix-transition deprecated',
|
|
277
|
+
label: '下拉图标动画',
|
|
278
|
+
tooltip: '下拉菜单显示/消失时后缀图标的动画',
|
|
279
|
+
type: 'boolean',
|
|
280
|
+
el: 'hs-switch',
|
|
281
|
+
},
|
|
282
|
+
{
|
|
283
|
+
prop: 'tag-type',
|
|
284
|
+
label: '标签类型',
|
|
285
|
+
tooltip: '标签类型',
|
|
286
|
+
type: 'enum',
|
|
287
|
+
el: 'hs-select',
|
|
288
|
+
op: [
|
|
289
|
+
{ label: 'success', value: 'success' },
|
|
290
|
+
{ label: 'info', value: 'info' },
|
|
291
|
+
{ label: 'warning', value: 'warning' },
|
|
292
|
+
{ label: 'danger', value: 'danger' },
|
|
293
|
+
],
|
|
294
|
+
cel: 'hs-option',
|
|
295
|
+
},
|
|
296
|
+
{
|
|
297
|
+
prop: 'validate-event',
|
|
298
|
+
label: '表单验证',
|
|
299
|
+
tooltip: '是否触发表单验证',
|
|
300
|
+
type: 'boolean',
|
|
301
|
+
el: 'hs-switch',
|
|
302
|
+
},
|
|
303
|
+
{
|
|
304
|
+
prop: 'placement',
|
|
305
|
+
label: '下拉框出现位置',
|
|
306
|
+
tooltip: '下拉框出现的位置',
|
|
307
|
+
type: 'enum',
|
|
308
|
+
el: 'hs-select',
|
|
309
|
+
op: [
|
|
310
|
+
{ label: 'top', value: 'top' },
|
|
311
|
+
{ label: 'top-start', value: 'top-start' },
|
|
312
|
+
{ label: 'top-end', value: 'top-end' },
|
|
313
|
+
{ label: 'bottom', value: 'bottom' },
|
|
314
|
+
{ label: 'bottom-start', value: 'bottom-start' },
|
|
315
|
+
{ label: 'bottom-end', value: 'bottom-end' },
|
|
316
|
+
{ label: 'left', value: 'left' },
|
|
317
|
+
{ label: 'left-start', value: 'left-start' },
|
|
318
|
+
{ label: 'left-end', value: 'left-end' },
|
|
319
|
+
{ label: 'right', value: 'right' },
|
|
320
|
+
{ label: 'right-start', value: 'right-start' },
|
|
321
|
+
{ label: 'right-end', value: 'right-end' },
|
|
322
|
+
],
|
|
323
|
+
cel: 'hs-option',
|
|
324
|
+
},
|
|
325
|
+
{
|
|
326
|
+
prop: 'max-collapse-tags',
|
|
327
|
+
label: 'Tag最大数量',
|
|
328
|
+
tooltip: '需要显示的 Tag 的最大数量 只有当 collapse-tags 设置为 true 时才会生效。',
|
|
329
|
+
type: 'number',
|
|
330
|
+
el: 'hs-input-number',
|
|
331
|
+
},
|
|
332
|
+
{
|
|
333
|
+
prop: 'popper-options',
|
|
334
|
+
label: 'popper参数',
|
|
335
|
+
tooltip: 'popper.js 参数',
|
|
336
|
+
type: 'objectrefer to popper.js doc',
|
|
337
|
+
el: 'hs-input',
|
|
338
|
+
},
|
|
339
|
+
{
|
|
340
|
+
prop: 'aria-label',
|
|
341
|
+
label: 'aria-label',
|
|
342
|
+
tooltip: '等价于原生 input aria-label 属性',
|
|
343
|
+
type: 'string',
|
|
344
|
+
el: 'hs-input',
|
|
345
|
+
},
|
|
346
|
+
],
|
|
347
|
+
},
|
|
348
|
+
{
|
|
349
|
+
prop: 'groupAttrs',
|
|
350
|
+
label: 'optionGroupAttrs',
|
|
351
|
+
tooltip: 'optionGroupAttrs',
|
|
352
|
+
type: 'object',
|
|
353
|
+
el: 'title',
|
|
354
|
+
children: [
|
|
355
|
+
{
|
|
356
|
+
prop: 'isGroupEnabled',
|
|
357
|
+
label: '是否启用分组',
|
|
358
|
+
tooltip: '是否启用分组',
|
|
359
|
+
type: 'boolean',
|
|
360
|
+
el: 'hs-switch',
|
|
361
|
+
},
|
|
362
|
+
{
|
|
363
|
+
prop: 'label',
|
|
364
|
+
label: '分组的名称',
|
|
365
|
+
tooltip: '分组的名称',
|
|
366
|
+
type: 'string',
|
|
367
|
+
el: 'hs-input',
|
|
368
|
+
},
|
|
369
|
+
{
|
|
370
|
+
prop: 'disabled',
|
|
371
|
+
label: '是否禁用分组',
|
|
372
|
+
tooltip: '是否将该分组下所有选项置为禁用',
|
|
373
|
+
type: 'string',
|
|
374
|
+
el: 'hs-switch',
|
|
375
|
+
},
|
|
376
|
+
],
|
|
377
|
+
},
|
|
378
|
+
{
|
|
379
|
+
prop: 'optionAttrs',
|
|
380
|
+
label: 'optionAttrs',
|
|
381
|
+
tooltip: 'optionAttrs',
|
|
382
|
+
type: 'object',
|
|
383
|
+
el: 'title',
|
|
384
|
+
children: [
|
|
385
|
+
{
|
|
386
|
+
prop: 'value',
|
|
387
|
+
label: '选项的值',
|
|
388
|
+
tooltip: '选项的值',
|
|
389
|
+
type: 'string',
|
|
390
|
+
el: 'hs-input',
|
|
391
|
+
},
|
|
392
|
+
{
|
|
393
|
+
prop: 'label',
|
|
394
|
+
label: '选项的标签',
|
|
395
|
+
tooltip: '选项的标签,若不设置则默认与value相同',
|
|
396
|
+
type: 'string',
|
|
397
|
+
el: 'hs-input',
|
|
398
|
+
},
|
|
399
|
+
{
|
|
400
|
+
prop: 'disabled',
|
|
401
|
+
label: '是否禁用选项',
|
|
402
|
+
tooltip: '是否禁用该选项',
|
|
403
|
+
type: 'string',
|
|
404
|
+
el: 'hs-switch',
|
|
405
|
+
},
|
|
406
|
+
],
|
|
407
|
+
},
|
|
408
|
+
{
|
|
409
|
+
prop: 'rules',
|
|
410
|
+
label: 'rules',
|
|
411
|
+
tooltip: 'rules',
|
|
412
|
+
type: 'object',
|
|
413
|
+
el: 'title',
|
|
414
|
+
children: [
|
|
415
|
+
{
|
|
416
|
+
prop: 'required',
|
|
417
|
+
label: '是否必填',
|
|
418
|
+
tooltip: '是否必填',
|
|
419
|
+
type: 'boolean',
|
|
420
|
+
el: 'hs-switch',
|
|
421
|
+
},
|
|
422
|
+
// 必填项规则
|
|
423
|
+
{
|
|
424
|
+
prop: 'rules',
|
|
425
|
+
label: '必填项规则',
|
|
426
|
+
tooltip: '必填项规则',
|
|
427
|
+
type: 'array',
|
|
428
|
+
el: 'hs-input',
|
|
429
|
+
attrs: {
|
|
430
|
+
type: 'textarea',
|
|
431
|
+
},
|
|
432
|
+
},
|
|
433
|
+
],
|
|
434
|
+
},
|
|
435
|
+
];
|
|
436
|
+
export const selectAttrConfigMap = {
|
|
437
|
+
// 默认配置项
|
|
438
|
+
attrs: {
|
|
439
|
+
size: 'small',
|
|
440
|
+
multiple: false, // 是否多选
|
|
441
|
+
disabled: false, // 是否禁用
|
|
442
|
+
'value-key': 'value', // value 唯一标识
|
|
443
|
+
clearable: true, // 是否可以清空
|
|
444
|
+
'collapse-tags': false, // 值按文字展示
|
|
445
|
+
'collapse-tags-tooltip': false, // 是否显示所选
|
|
446
|
+
'multiple-limit': 0, // 最多可选数
|
|
447
|
+
effect: 'light', // tooltip 主题
|
|
448
|
+
autocomplete: 'off', // autocomplete
|
|
449
|
+
filterable: true, // 是否可筛选
|
|
450
|
+
'allow-create': false, // 允许创建条目
|
|
451
|
+
remote: false, // 是否远程加载
|
|
452
|
+
'remote-show-suffix': false, // 远程搜索图标
|
|
453
|
+
loading: false, // 是否正在获取
|
|
454
|
+
'reserve-keyword': true, // 保留关键词
|
|
455
|
+
'default-first-option': false, // 是否在输入框按下回车时,选择第一个匹配项
|
|
456
|
+
teleported: true, // 是否插入至body
|
|
457
|
+
persistent: true, // 选择器未被激活
|
|
458
|
+
'automatic-dropdown': true, // 自动弹出选项
|
|
459
|
+
'clear-icon': '', // 清除图标
|
|
460
|
+
'fit-input-width': false, // 下拉框宽度
|
|
461
|
+
'suffix-icon': '', // 后缀图标
|
|
462
|
+
'tag-type': 'info', // 标签类型
|
|
463
|
+
'validate-event': true, // 表单验证
|
|
464
|
+
placement: 'bottom-start', // 下拉框出现的位置
|
|
465
|
+
'max-collapse-tags': 1, // 需要显示的 Tag 的最大数量
|
|
466
|
+
options: 'string=', //
|
|
467
|
+
},
|
|
468
|
+
groupAttrs: {
|
|
469
|
+
disabled: false, // 是否禁用分组
|
|
470
|
+
isGroupEnabled: false, // 是否启用分组
|
|
471
|
+
},
|
|
472
|
+
optionAttrs: {
|
|
473
|
+
value: 'value',
|
|
474
|
+
label: 'label',
|
|
475
|
+
disabled: false, // 是否禁用该选项
|
|
476
|
+
},
|
|
477
|
+
rules: {},
|
|
478
|
+
};
|