From 50eb1647a288faac512b30c9702c7c95b09cf6d4 Mon Sep 17 00:00:00 2001 From: xingyu Date: Thu, 27 Apr 2023 17:49:24 +0800 Subject: [PATCH] chore: eslint --- .lintstagedrc.js | 9 - commitlint.config.js | 91 --------- prettier.config.js | 27 --- src/App.vue | 7 +- src/api/base/login.ts | 5 +- src/api/base/menu.ts | 1 + src/api/base/model/loginModel.ts | 8 +- src/api/base/model/menuModel.ts | 1 + src/api/base/profile.ts | 5 +- src/api/base/upload.ts | 10 +- src/api/base/user.ts | 4 +- src/api/bpm/form/index.ts | 4 +- src/api/bpm/leave/index.ts | 4 +- src/api/bpm/model/index.ts | 12 +- src/api/bpm/processInstance/index.ts | 12 +- src/api/bpm/task/types.ts | 16 +- src/api/bpm/taskAssignRule/index.ts | 4 +- src/api/bpm/userGroup/index.ts | 4 +- src/api/infra/codegen/index.ts | 3 +- src/api/infra/codegen/types.ts | 28 +-- src/api/system/dict/data.ts | 3 +- src/api/system/dict/type.ts | 3 +- src/api/system/notify/message.ts | 3 +- src/api/system/operatelog/index.ts | 2 +- src/api/system/sms/smsTemplate/index.ts | 2 +- src/components/Application/index.ts | 6 +- .../Application/src/AppDarkModeToggle.vue | 9 +- .../Application/src/AppLocalePicker.vue | 7 +- src/components/Application/src/AppLogo.vue | 7 +- .../Application/src/AppProvider.vue | 8 +- .../Application/src/AppSizePicker.vue | 7 +- .../Application/src/search/AppSearch.vue | 8 +- .../src/search/AppSearchFooter.vue | 4 +- .../src/search/AppSearchKeyItem.vue | 1 + .../Application/src/search/AppSearchModal.vue | 28 +-- .../Application/src/search/useMenuSearch.ts | 15 +- .../Application/src/useAppContext.ts | 1 + src/components/Authority/index.ts | 1 + src/components/Authority/src/Authority.vue | 1 + src/components/Basic/index.ts | 3 +- src/components/Basic/src/BasicArrow.vue | 1 + src/components/Basic/src/BasicHelp.vue | 13 +- src/components/Basic/src/BasicTitle.vue | 8 +- src/components/Button/index.ts | 4 +- src/components/Button/src/BasicButton.vue | 8 +- .../Button/src/PopConfirmButton.vue | 8 +- src/components/CardList/index.ts | 1 + src/components/CardList/src/CardList.vue | 17 +- src/components/CodeEditor/index.ts | 1 + src/components/CodeEditor/src/CodeEditor.vue | 6 +- .../CodeEditor/src/codemirror/CodeMirror.vue | 17 +- .../CodeEditor/src/codemirror/codeMirror.ts | 4 +- .../src/json-preview/JsonPreview.vue | 3 +- src/components/Container/index.ts | 3 +- .../Container/src/LazyContainer.vue | 13 +- .../Container/src/ScrollContainer.vue | 3 +- .../src/collapse/CollapseContainer.vue | 14 +- .../Container/src/collapse/CollapseHeader.vue | 5 +- src/components/ContextMenu/index.ts | 1 - .../ContextMenu/src/ContextMenu.vue | 10 +- .../ContextMenu/src/createContextMenu.ts | 8 +- src/components/CountDown/index.ts | 1 + src/components/CountDown/src/CountButton.vue | 10 +- .../CountDown/src/CountdownInput.vue | 8 +- src/components/CountDown/src/useCountdown.ts | 2 +- src/components/CountTo/index.ts | 1 + src/components/CountTo/src/CountTo.vue | 5 +- src/components/Cropper/index.ts | 1 + src/components/Cropper/src/CopperModal.vue | 26 ++- src/components/Cropper/src/Cropper.vue | 13 +- src/components/Cropper/src/CropperAvatar.vue | 20 +- src/components/Description/index.ts | 1 + .../Description/src/Description.vue | 20 +- src/components/Description/src/typing.ts | 5 +- .../Description/src/useDescription.ts | 6 +- src/components/DictTag/index.ts | 1 + src/components/DictTag/src/DictTag.vue | 5 +- src/components/Drawer/index.ts | 1 + src/components/Drawer/src/BasicDrawer.vue | 28 +-- .../Drawer/src/components/DrawerFooter.vue | 8 +- .../Drawer/src/components/DrawerHeader.vue | 7 +- src/components/Drawer/src/props.ts | 1 + src/components/Drawer/src/typing.ts | 3 +- src/components/Drawer/src/useDrawer.ts | 12 +- src/components/Dropdown/index.ts | 1 + src/components/Dropdown/src/Dropdown.vue | 16 +- src/components/Excel/index.ts | 5 +- src/components/Excel/src/Export2Excel.ts | 5 +- src/components/Excel/src/ExportExcelModal.vue | 5 +- src/components/Excel/src/ImportExcel.vue | 10 +- src/components/Excel/src/typing.ts | 2 +- src/components/Form/index.ts | 20 +- src/components/Form/src/BasicForm.vue | 40 ++-- src/components/Form/src/componentMap.ts | 36 ++-- .../Form/src/components/ApiCascader.vue | 19 +- .../Form/src/components/ApiRadioGroup.vue | 14 +- .../Form/src/components/ApiSelect.vue | 25 ++- .../Form/src/components/ApiTransfer.vue | 9 +- .../Form/src/components/ApiTree.vue | 17 +- .../Form/src/components/ApiTreeSelect.vue | 17 +- .../Form/src/components/FormAction.vue | 18 +- .../Form/src/components/FormItem.vue | 24 +-- .../Form/src/components/RadioButtonGroup.vue | 11 +- src/components/Form/src/helper.ts | 4 +- src/components/Form/src/hooks/useAdvanced.ts | 16 +- src/components/Form/src/hooks/useAutoFocus.ts | 4 +- .../Form/src/hooks/useComponentRegister.ts | 5 +- src/components/Form/src/hooks/useForm.ts | 10 +- .../Form/src/hooks/useFormContext.ts | 1 + .../Form/src/hooks/useFormEvents.ts | 14 +- .../Form/src/hooks/useFormValues.ts | 12 +- .../Form/src/hooks/useLabelWidth.ts | 4 +- src/components/Form/src/props.ts | 10 +- src/components/Form/src/types/form.ts | 9 +- src/components/FormDesign/index.ts | 4 +- .../VFormCreate/components/FormRender.vue | 7 +- .../src/components/VFormCreate/index.vue | 17 +- .../VFormDesign/components/CodeModal.vue | 7 +- .../VFormDesign/components/ComponentProps.vue | 31 +-- .../components/FormItemColumnProps.vue | 22 +-- .../VFormDesign/components/FormItemProps.vue | 32 +-- .../VFormDesign/components/FormNode.vue | 9 +- .../components/FormNodeOperate.vue | 8 +- .../VFormDesign/components/FormOptions.vue | 7 +- .../VFormDesign/components/FormProps.vue | 22 ++- .../components/ImportJsonModal.vue | 14 +- .../VFormDesign/components/JsonModal.vue | 7 +- .../VFormDesign/components/LayoutItem.vue | 16 +- .../VFormDesign/components/PreviewCode.vue | 9 +- .../VFormDesign/components/RuleProps.vue | 10 +- .../VFormDesign/config/formItemPropsConfig.ts | 2 +- .../src/components/VFormDesign/index.vue | 45 +++-- .../VFormDesign/modules/CollapseItem.vue | 10 +- .../modules/FormComponentPanel.vue | 13 +- .../VFormDesign/modules/PropsPanel.vue | 12 +- .../VFormDesign/modules/Toolbar.vue | 12 +- .../src/components/VFormItem/index.vue | 32 +-- .../src/components/VFormItem/vFormItem.vue | 7 +- .../src/components/VFormPreview/index.vue | 24 +-- .../src/components/VFormPreview/useForm.vue | 20 +- .../FormDesign/src/components/index.ts | 27 +-- .../FormDesign/src/core/formItemConfig.ts | 7 +- .../src/hooks/useFormDesignState.ts | 3 +- .../src/hooks/useFormInstanceMethods.ts | 11 +- .../FormDesign/src/hooks/useVFormMethods.ts | 7 +- .../FormDesign/src/typings/form-type.ts | 1 + .../src/typings/v-form-component.ts | 14 +- src/components/FormDesign/src/utils/index.ts | 3 +- .../FormDesign/src/utils/message.ts | 1 + src/components/IFrame/src/IFrame.vue | 5 +- src/components/Icon/index.ts | 2 +- src/components/Icon/src/Icon.vue | 10 +- src/components/Icon/src/IconPicker.vue | 45 ++--- src/components/Icon/src/SvgIcon.vue | 1 + src/components/Loading/index.ts | 2 +- src/components/Loading/src/Loading.vue | 3 +- src/components/Loading/src/createLoading.ts | 5 +- src/components/Loading/src/useLoading.ts | 3 +- src/components/Markdown/index.ts | 1 + src/components/Markdown/src/Markdown.vue | 17 +- .../Markdown/src/MarkdownViewer.vue | 7 +- src/components/Markdown/src/typing.ts | 1 + src/components/Menu/src/BasicMenu.vue | 24 +-- .../Menu/src/components/BasicMenuItem.vue | 1 + .../Menu/src/components/BasicSubMenuItem.vue | 8 +- .../Menu/src/components/MenuItemContent.vue | 5 +- src/components/Menu/src/props.ts | 11 +- src/components/Menu/src/useOpenKeys.ts | 15 +- src/components/Modal/index.ts | 6 +- src/components/Modal/src/BasicModal.vue | 29 +-- src/components/Modal/src/components/Modal.tsx | 6 +- .../Modal/src/components/ModalClose.vue | 11 +- .../Modal/src/components/ModalFooter.vue | 4 +- .../Modal/src/components/ModalWrapper.vue | 16 +- src/components/Modal/src/hooks/useModal.ts | 13 +- .../Modal/src/hooks/useModalContext.ts | 1 + .../Modal/src/hooks/useModalDrag.ts | 2 +- src/components/Modal/src/props.ts | 6 +- src/components/Modal/src/typing.ts | 2 +- src/components/Page/src/PageWrapper.vue | 21 +- src/components/Preview/index.ts | 2 +- src/components/Preview/src/Functional.vue | 7 +- src/components/Preview/src/Preview.vue | 7 +- src/components/Preview/src/functional.ts | 8 +- src/components/Qrcode/index.ts | 1 + src/components/Qrcode/src/Qrcode.vue | 6 +- src/components/Qrcode/src/drawCanvas.ts | 7 +- src/components/Qrcode/src/drawLogo.ts | 4 +- src/components/Qrcode/src/qrcodePlus.ts | 1 + src/components/Qrcode/src/toCanvas.ts | 1 + src/components/Qrcode/src/typing.ts | 6 +- src/components/Scrollbar/src/Scrollbar.vue | 8 +- src/components/Scrollbar/src/bar.ts | 7 +- src/components/Scrollbar/src/util.ts | 1 + src/components/SimpleMenu/src/SimpleMenu.vue | 20 +- .../SimpleMenu/src/SimpleMenuTag.vue | 5 +- .../SimpleMenu/src/SimpleSubMenu.vue | 15 +- .../SimpleMenu/src/components/Menu.vue | 12 +- .../src/components/MenuCollapseTransition.vue | 1 + .../SimpleMenu/src/components/MenuItem.vue | 12 +- .../SimpleMenu/src/components/SubMenuItem.vue | 31 +-- .../SimpleMenu/src/components/useMenu.ts | 2 +- .../src/components/useSimpleMenuContext.ts | 3 +- src/components/SimpleMenu/src/useOpenKeys.ts | 14 +- src/components/StrengthMeter/index.ts | 1 + .../StrengthMeter/src/StrengthMeter.vue | 9 +- src/components/Table/index.ts | 19 +- src/components/Table/src/BasicTable.vue | 50 ++--- src/components/Table/src/componentMap.ts | 6 +- .../Table/src/components/HeaderCell.vue | 6 +- .../Table/src/components/TableAction.vue | 22 ++- .../Table/src/components/TableFooter.vue | 8 +- .../Table/src/components/TableHeader.vue | 14 +- .../Table/src/components/TableImg.vue | 7 +- .../Table/src/components/TableTitle.vue | 3 +- .../src/components/editable/CellComponent.ts | 9 +- .../src/components/editable/EditableCell.vue | 27 ++- .../Table/src/components/editable/helper.ts | 3 +- .../Table/src/components/editable/index.ts | 6 +- .../src/components/settings/ColumnSetting.vue | 36 ++-- .../components/settings/FullScreenSetting.vue | 10 +- .../src/components/settings/RedoSetting.vue | 4 +- .../src/components/settings/SizeSetting.vue | 12 +- .../Table/src/components/settings/index.vue | 13 +- src/components/Table/src/hooks/useColumns.ts | 18 +- .../Table/src/hooks/useCustomRow.ts | 6 +- .../Table/src/hooks/useDataSource.ts | 14 +- src/components/Table/src/hooks/useLoading.ts | 3 +- .../Table/src/hooks/usePagination.tsx | 14 +- src/components/Table/src/hooks/useRender.ts | 7 +- .../Table/src/hooks/useRowSelection.ts | 10 +- src/components/Table/src/hooks/useScrollTo.ts | 1 + src/components/Table/src/hooks/useTable.ts | 12 +- .../Table/src/hooks/useTableContext.ts | 3 +- .../Table/src/hooks/useTableExpand.ts | 5 +- .../Table/src/hooks/useTableFooter.ts | 8 +- .../Table/src/hooks/useTableForm.ts | 8 +- .../Table/src/hooks/useTableHeader.ts | 10 +- .../Table/src/hooks/useTableScroll.ts | 15 +- .../Table/src/hooks/useTableStyle.ts | 4 +- src/components/Table/src/props.ts | 8 +- src/components/Table/src/types/table.ts | 17 +- src/components/Table/src/types/tableAction.ts | 2 + src/components/Tinymce/index.ts | 1 + src/components/Tinymce/src/Editor.vue | 26 +-- src/components/Tinymce/src/ImgUpload.vue | 6 +- src/components/Transition/index.ts | 3 +- .../Transition/src/CollapseTransition.vue | 1 + .../Transition/src/CreateTransition.tsx | 1 + src/components/Tree/index.ts | 5 +- src/components/Tree/src/BasicTree.vue | 31 +-- src/components/Tree/src/TreeIcon.ts | 6 +- .../Tree/src/components/TreeHeader.vue | 24 +-- src/components/Tree/src/hooks/useTree.ts | 7 +- src/components/Tree/src/types/tree.ts | 4 +- src/components/Upload/index.ts | 1 + src/components/Upload/src/BasicUpload.vue | 16 +- src/components/Upload/src/FileList.vue | 8 +- src/components/Upload/src/ThumbUrl.vue | 3 +- src/components/Upload/src/UploadModal.vue | 26 +-- .../Upload/src/UploadPreviewModal.vue | 16 +- src/components/Upload/src/data.tsx | 12 +- src/components/Upload/src/useUpload.ts | 4 +- src/components/Verifition/index.ts | 1 + src/components/Verifition/src/Verify.vue | 14 +- .../Verifition/src/Verify/VerifyPoints.vue | 28 +-- .../Verifition/src/Verify/VerifySlide.vue | 22 ++- src/components/Verifition/src/Verify/index.ts | 4 +- src/components/VirtualScroll/index.ts | 1 + .../VirtualScroll/src/VirtualScroll.vue | 3 +- src/components/registerGlobComp.ts | 5 +- src/directives/clickOutside.ts | 3 +- src/directives/index.ts | 3 +- src/directives/loading.ts | 3 +- src/directives/repeatClick.ts | 3 +- src/directives/ripple/index.ts | 4 +- src/hooks/component/useFormItem.ts | 17 +- src/hooks/component/usePageContext.ts | 3 +- src/hooks/core/onMountedOrActivated.ts | 2 +- src/hooks/core/useAttrs.ts | 3 +- src/hooks/core/useContext.ts | 2 +- src/hooks/core/useRefs.ts | 2 +- src/hooks/event/useBreakpoint.ts | 5 +- src/hooks/event/useEventListener.ts | 4 +- src/hooks/event/useIntersectionObserver.ts | 2 +- src/hooks/event/useScroll.ts | 8 +- src/hooks/event/useScrollTo.ts | 3 +- src/hooks/setting/index.ts | 7 +- src/hooks/setting/useHeaderSetting.ts | 8 +- src/hooks/setting/useMenuSetting.ts | 8 +- src/hooks/setting/useMultipleTabSetting.ts | 3 +- src/hooks/setting/useRootSetting.ts | 5 +- src/hooks/setting/useTransitionSetting.ts | 3 +- src/hooks/web/useAppInject.ts | 3 +- src/hooks/web/useContentHeight.ts | 5 +- src/hooks/web/useContextMenu.ts | 6 +- src/hooks/web/useCopyToClipboard.ts | 1 + src/hooks/web/useECharts.ts | 12 +- src/hooks/web/useFullContent.ts | 3 +- src/hooks/web/useI18n.ts | 4 +- src/hooks/web/useLockPage.ts | 4 +- src/hooks/web/useMessage.tsx | 14 +- src/hooks/web/usePage.ts | 5 +- src/hooks/web/usePagination.ts | 2 +- src/hooks/web/usePermission.ts | 23 +-- src/hooks/web/useSortable.ts | 4 +- src/hooks/web/useTabs.ts | 7 +- src/hooks/web/useTitle.ts | 8 +- src/hooks/web/useWatermark.ts | 3 +- src/layouts/default/content/index.vue | 7 +- .../default/content/useContentContext.ts | 3 +- .../default/content/useContentViewHeight.ts | 3 +- src/layouts/default/feature/index.vue | 12 +- src/layouts/default/footer/index.vue | 17 +- src/layouts/default/header/MultipleHeader.vue | 12 +- .../default/header/components/Breadcrumb.vue | 23 +-- .../default/header/components/ErrorAction.vue | 9 +- .../default/header/components/FullScreen.vue | 11 +- .../default/header/components/index.ts | 1 + .../header/components/lock/LockModal.vue | 9 +- .../header/components/notify/NoticeList.vue | 18 +- .../header/components/notify/index.vue | 14 +- .../header/components/user-dropdown/index.vue | 18 +- src/layouts/default/header/index.vue | 31 ++- src/layouts/default/index.vue | 19 +- src/layouts/default/menu/index.vue | 20 +- src/layouts/default/menu/useLayoutMenu.ts | 15 +- src/layouts/default/setting/SettingDrawer.tsx | 24 +-- .../setting/components/InputNumberItem.vue | 4 +- .../default/setting/components/SelectItem.vue | 7 +- .../setting/components/SettingFooter.vue | 21 +- .../default/setting/components/SwitchItem.vue | 7 +- .../setting/components/ThemeColorPicker.vue | 4 +- .../default/setting/components/TypePicker.vue | 4 +- src/layouts/default/setting/enum.ts | 3 +- src/layouts/default/setting/handler.ts | 12 +- src/layouts/default/setting/index.vue | 4 +- src/layouts/default/sider/DragBar.vue | 2 +- src/layouts/default/sider/LayoutSider.vue | 19 +- src/layouts/default/sider/MixSider.vue | 38 ++-- src/layouts/default/sider/index.vue | 7 +- src/layouts/default/sider/useLayoutSider.ts | 6 +- .../default/tabs/components/FoldButton.vue | 6 +- .../default/tabs/components/TabContent.vue | 11 +- .../default/tabs/components/TabRedo.vue | 3 +- src/layouts/default/tabs/index.vue | 28 ++- src/layouts/default/tabs/types.ts | 3 +- src/layouts/default/tabs/useMultipleTabs.ts | 7 +- src/layouts/default/tabs/useTabDropdown.ts | 17 +- src/layouts/default/trigger/HeaderTrigger.vue | 3 +- src/layouts/default/trigger/SiderTrigger.vue | 3 +- src/layouts/default/trigger/index.vue | 1 + src/layouts/iframe/index.vue | 3 +- src/layouts/iframe/useFrameKeepAlive.ts | 12 +- src/layouts/page/index.vue | 14 +- src/locales/helper.ts | 4 +- src/locales/lang/en.ts | 3 +- src/locales/lang/zh_CN.ts | 3 +- src/locales/setupI18n.ts | 5 +- src/locales/useLocale.ts | 7 +- src/logics/error-handle/index.ts | 11 +- src/logics/initAppConfig.ts | 18 +- src/logics/mitt/routeChange.ts | 3 +- src/logics/theme/dark.ts | 1 + src/logics/theme/index.ts | 6 +- src/logics/theme/updateBackground.ts | 5 +- src/main.ts | 17 +- src/router/guard/index.ts | 18 +- src/router/guard/paramMenuGuard.ts | 7 +- src/router/guard/permissionGuard.ts | 8 +- src/router/guard/stateGuard.ts | 9 +- src/router/helper/menuHelper.ts | 13 +- src/router/helper/routeHelper.ts | 9 +- src/router/index.ts | 4 +- src/router/menus/index.ts | 10 +- src/router/routes/basic.ts | 2 +- src/router/routes/index.ts | 6 +- src/router/routes/modules/about.ts | 5 +- src/router/routes/modules/dashboard.ts | 5 +- src/router/routes/modules/menu.ts | 3 +- src/router/types.ts | 5 +- src/settings/localeSetting.ts | 3 +- src/settings/projectSetting.ts | 13 +- src/settings/sizeSetting.ts | 3 +- src/store/index.ts | 2 +- src/store/modules/app.ts | 11 +- src/store/modules/dict.ts | 9 +- src/store/modules/errorLog.ts | 10 +- src/store/modules/locale.ts | 7 +- src/store/modules/lock.ts | 4 +- src/store/modules/multipleTab.ts | 19 +- src/store/modules/permission.ts | 34 ++-- src/store/modules/user.ts | 25 ++- src/types/axios.d.ts | 56 ------ src/types/config.d.ts | 183 ------------------ src/types/global.d.ts | 89 --------- src/types/index.d.ts | 37 ---- src/types/module.d.ts | 16 -- src/types/store.d.ts | 52 ----- src/types/utils.d.ts | 5 - src/types/vue-router.d.ts | 51 ----- src/utils/auth/index.ts | 5 +- src/utils/cache/index.ts | 4 +- src/utils/cache/persistent.ts | 25 +-- src/utils/cipher.ts | 11 +- src/utils/color.ts | 2 +- src/utils/domUtils.ts | 2 +- src/utils/env.ts | 8 +- src/utils/factory/createAsyncComponent.tsx | 3 +- src/utils/file/download.ts | 2 +- src/utils/helper/tsxHelper.tsx | 1 + src/utils/http/axios/Axios.ts | 21 +- src/utils/http/axios/axiosCancel.ts | 3 +- src/utils/http/axios/axiosTransform.ts | 5 +- src/utils/http/axios/checkStatus.ts | 8 +- src/utils/http/axios/index.ts | 34 ++-- src/utils/index.ts | 14 +- src/utils/is.ts | 2 +- src/utils/lib/echarts.ts | 29 ++- src/utils/propTypes.ts | 2 +- src/utils/props.ts | 14 +- src/utils/types.ts | 4 +- src/views/base/about/index.vue | 15 +- src/views/base/exception/Exception.vue | 13 +- src/views/base/iframe/index.vue | 9 +- src/views/base/lock/LockPage.vue | 32 +-- src/views/base/lock/index.vue | 4 +- src/views/base/lock/useNow.ts | 5 +- src/views/base/login/ForgetPasswordForm.vue | 20 +- src/views/base/login/Login.vue | 21 +- src/views/base/login/LoginForm.vue | 36 ++-- src/views/base/login/LoginFormTitle.vue | 2 + src/views/base/login/MobileForm.vue | 18 +- src/views/base/login/QrCodeForm.vue | 8 +- src/views/base/login/RegisterForm.vue | 26 +-- src/views/base/login/SessionTimeoutLogin.vue | 12 +- src/views/base/login/useLogin.ts | 9 +- src/views/base/profile/AccountBind.vue | 12 +- src/views/base/profile/BaseSetting.vue | 14 +- src/views/base/profile/MsgNotify.vue | 2 + src/views/base/profile/PasswordModal.vue | 10 +- src/views/base/profile/SecureSetting.vue | 8 +- src/views/base/profile/index.vue | 11 +- src/views/bpm/form/index.vue | 9 +- src/views/bpm/group/GroupModal.vue | 10 +- src/views/bpm/group/group.data.ts | 2 +- src/views/bpm/group/index.vue | 13 +- src/views/bpm/model/ModelModal.vue | 10 +- src/views/bpm/model/index.vue | 13 +- src/views/bpm/oa/leave/index.vue | 5 +- src/views/bpm/task/done/index.vue | 5 +- src/views/bpm/task/todo/index.vue | 5 +- .../analysis/components/GrowCard.vue | 4 +- .../analysis/components/SalesProductPie.vue | 5 +- .../analysis/components/SiteAnalysis.vue | 3 +- .../analysis/components/VisitAnalysis.vue | 6 +- .../analysis/components/VisitAnalysisBar.vue | 6 +- .../analysis/components/VisitRadar.vue | 3 +- .../analysis/components/VisitSource.vue | 4 +- src/views/dashboard/analysis/index.vue | 7 +- .../workbench/components/DynamicInfo.vue | 4 +- .../workbench/components/ProjectCard.vue | 2 + .../workbench/components/QuickNav.vue | 4 +- .../workbench/components/SaleRadar.vue | 3 +- .../workbench/components/WorkbenchHeader.vue | 5 +- src/views/dashboard/workbench/index.vue | 8 +- src/views/infra/apiAccessLog/index.vue | 9 +- src/views/infra/apiErrorLog/index.vue | 9 +- src/views/infra/build/index.vue | 2 +- src/views/infra/codegen/EditTable.vue | 16 +- .../codegen/components/BasicInfoForm.vue | 6 +- .../codegen/components/CloumInfoForm.vue | 6 +- .../infra/codegen/components/FinishForm.vue | 14 +- .../codegen/components/ImportTableModal.vue | 5 +- .../infra/codegen/components/PreviewModal.vue | 13 +- src/views/infra/codegen/components/data.ts | 2 +- src/views/infra/codegen/index.vue | 17 +- src/views/infra/config/ConfigModal.vue | 10 +- src/views/infra/config/index.vue | 15 +- .../DataSourceConfigModal.vue | 10 +- src/views/infra/dataSourceConfig/index.vue | 13 +- src/views/infra/dbDoc/index.vue | 7 +- src/views/infra/druid/index.vue | 1 + src/views/infra/file/index.vue | 18 +- .../infra/fileConfig/FileConfigModal.vue | 10 +- src/views/infra/fileConfig/index.vue | 13 +- src/views/infra/job/JobModal.vue | 10 +- src/views/infra/job/index.vue | 17 +- .../infra/redis/components/CommandStats.vue | 3 +- src/views/infra/redis/components/Memory.vue | 5 +- .../infra/redis/components/RedisModal.vue | 8 +- src/views/infra/redis/index.vue | 14 +- src/views/infra/server/index.vue | 1 + src/views/infra/skywalking/index.vue | 1 + src/views/infra/swagger/index.vue | 1 + src/views/infra/webSocket/index.vue | 14 +- src/views/mp/account/AccountModal.vue | 10 +- src/views/mp/account/index.vue | 13 +- .../mp/components/WxAccountSelect/index.vue | 3 +- src/views/mp/components/WxLocation/index.vue | 1 + src/views/mp/freePublish/index.vue | 15 +- src/views/mp/message/MessageModal.vue | 12 +- src/views/mp/message/index.vue | 11 +- src/views/mp/message/message.data.ts | 5 +- src/views/mp/tag/TagModal.vue | 10 +- src/views/mp/tag/index.vue | 15 +- src/views/mp/user/MpUserModal.vue | 9 +- src/views/mp/user/index.vue | 13 +- src/views/pay/app/AppModal.vue | 10 +- src/views/pay/app/app.data.ts | 5 +- src/views/pay/app/index.vue | 15 +- src/views/pay/merchant/MerchantModal.vue | 10 +- src/views/pay/merchant/index.vue | 15 +- src/views/pay/merchant/merchant.data.ts | 5 +- src/views/pay/order/OrderModal.vue | 10 +- src/views/pay/order/index.vue | 13 +- src/views/pay/refund/RefundModal.vue | 10 +- src/views/pay/refund/index.vue | 13 +- src/views/report/goview/index.vue | 1 + src/views/report/jmreport/index.vue | 1 + src/views/system/area/AreaModal.vue | 5 +- src/views/system/area/index.vue | 11 +- src/views/system/dept/DeptModal.vue | 10 +- src/views/system/dept/dept.data.ts | 2 +- src/views/system/dept/index.vue | 20 +- src/views/system/dict/DictData.vue | 16 +- src/views/system/dict/DictDataModal.vue | 10 +- src/views/system/dict/DictTypeModal.vue | 10 +- src/views/system/dict/index.vue | 16 +- src/views/system/errorCode/ErrorCodeModal.vue | 10 +- src/views/system/errorCode/index.vue | 15 +- src/views/system/loginlog/index.vue | 7 +- .../system/mail/account/AccountModal.vue | 10 +- src/views/system/mail/account/index.vue | 13 +- src/views/system/mail/log/index.vue | 3 +- src/views/system/mail/log/mailLog.data.ts | 5 +- .../system/mail/template/TemplateModal.vue | 10 +- src/views/system/mail/template/index.vue | 13 +- src/views/system/menu/MenuModal.vue | 10 +- src/views/system/menu/index.vue | 15 +- src/views/system/menu/menu.data.ts | 2 +- src/views/system/notice/NoticeModal.vue | 10 +- src/views/system/notice/index.vue | 13 +- src/views/system/notify/message/index.vue | 3 +- src/views/system/notify/my/index.vue | 7 +- .../system/notify/template/TemplateModal.vue | 10 +- src/views/system/notify/template/index.vue | 13 +- .../system/oauth2/client/ClientModal.vue | 10 +- src/views/system/oauth2/client/index.vue | 13 +- src/views/system/oauth2/token/index.vue | 9 +- src/views/system/operatelog/index.vue | 7 +- .../system/operatelog/operateLog.data.ts | 3 +- src/views/system/post/PostModal.vue | 10 +- src/views/system/post/index.vue | 15 +- src/views/system/role/RoleMenuModal.vue | 18 +- src/views/system/role/RoleModal.vue | 10 +- src/views/system/role/RoleScopeModal.vue | 16 +- src/views/system/role/index.vue | 19 +- src/views/system/role/role.data.ts | 2 +- .../sensitiveWord/SensitiveWordModal.vue | 10 +- src/views/system/sensitiveWord/index.vue | 13 +- .../system/sms/channel/SmsChannelModal.vue | 10 +- src/views/system/sms/channel/index.vue | 13 +- src/views/system/sms/log/index.vue | 7 +- src/views/system/sms/log/smsLog.data.ts | 3 +- .../system/sms/template/SmsTemplateModal.vue | 10 +- src/views/system/sms/template/index.vue | 13 +- src/views/system/tenant/TenantModal.vue | 10 +- src/views/system/tenant/index.vue | 13 +- src/views/system/tenant/tenant.data.ts | 4 +- .../tenantPackage/TenantPackageModal.vue | 18 +- src/views/system/tenantPackage/index.vue | 13 +- src/views/system/user/DeptTree.vue | 2 +- src/views/system/user/ResetPwdModal.vue | 10 +- src/views/system/user/UserModal.vue | 10 +- src/views/system/user/UserRoleModal.vue | 11 +- src/views/system/user/index.vue | 22 ++- src/views/system/user/user.data.ts | 13 +- stylelint.config.js | 78 -------- tsconfig.json | 4 +- 580 files changed, 2962 insertions(+), 3115 deletions(-) delete mode 100644 .lintstagedrc.js delete mode 100644 commitlint.config.js delete mode 100644 prettier.config.js delete mode 100644 src/types/axios.d.ts delete mode 100644 src/types/config.d.ts delete mode 100644 src/types/global.d.ts delete mode 100644 src/types/index.d.ts delete mode 100644 src/types/module.d.ts delete mode 100644 src/types/store.d.ts delete mode 100644 src/types/utils.d.ts delete mode 100644 src/types/vue-router.d.ts delete mode 100644 stylelint.config.js diff --git a/.lintstagedrc.js b/.lintstagedrc.js deleted file mode 100644 index 24cb82d7c..000000000 --- a/.lintstagedrc.js +++ /dev/null @@ -1,9 +0,0 @@ -// .lintstagedrc.js -module.exports = { - '*.{js,jsx,ts,tsx}': ['prettier --cache --ignore-unknown --write', 'eslint --cache --fix'], - '{!(package)*.json,*.code-snippets,.!(browserslist)*rc}': ['prettier --cache --write--parser json'], - 'package.json': ['prettier --cache --write'], - '*.vue': ['prettier --write', 'eslint --cache --fix', 'stylelint --fix'], - '*.{scss,less,styl,html}': ['prettier --cache --ignore-unknown --write', 'stylelint --fix'], - '*.md': ['prettier --cache --ignore-unknown --write'], -}; diff --git a/commitlint.config.js b/commitlint.config.js deleted file mode 100644 index c7271bac8..000000000 --- a/commitlint.config.js +++ /dev/null @@ -1,91 +0,0 @@ -const fs = require('fs'); -const path = require('path'); -const { execSync } = require('child_process'); - -const scopes = fs - .readdirSync(path.resolve(__dirname, 'src'), { withFileTypes: true }) - .filter((dirent) => dirent.isDirectory()) - .map((dirent) => dirent.name.replace(/s$/, '')); - -// precomputed scope -const scopeComplete = execSync('git status --porcelain || true') - .toString() - .trim() - .split('\n') - .find((r) => ~r.indexOf('M src')) - ?.replace(/(\/)/g, '%%') - ?.match(/src%%((\w|-)*)/)?.[1] - ?.replace(/s$/, ''); - -/** @type {import('cz-git').UserConfig} */ -module.exports = { - ignores: [(commit) => commit.includes('init')], - extends: ['@commitlint/config-conventional'], - rules: { - 'body-leading-blank': [2, 'always'], - 'footer-leading-blank': [1, 'always'], - 'header-max-length': [2, 'always', 108], - 'subject-empty': [2, 'never'], - 'type-empty': [2, 'never'], - 'subject-case': [0], - 'type-enum': [ - 2, - 'always', - ['feat', 'fix', 'perf', 'style', 'docs', 'test', 'refactor', 'build', 'ci', 'chore', 'revert', 'wip', 'workflow', 'types', 'release'], - ], - }, - prompt: { - /** @use `yarn commit :f` */ - alias: { - f: 'docs: fix typos', - r: 'docs: update README', - s: 'style: update code format', - b: 'build: bump dependencies', - c: 'chore: update config', - }, - customScopesAlign: !scopeComplete ? 'top' : 'bottom', - defaultScope: scopeComplete, - scopes: [...scopes, 'mock'], - allowEmptyIssuePrefixs: false, - allowCustomIssuePrefixs: false, - - // English - typesAppend: [ - { value: 'wip', name: 'wip: work in process' }, - { value: 'workflow', name: 'workflow: workflow improvements' }, - { value: 'types', name: 'types: type definition file changes' }, - ], - - // 中英文对照版 - // messages: { - // type: '选择你要提交的类型 :', - // scope: '选择一个提交范围 (可选):', - // customScope: '请输入自定义的提交范围 :', - // subject: '填写简短精炼的变更描述 :\n', - // body: '填写更加详细的变更描述 (可选)。使用 "|" 换行 :\n', - // breaking: '列举非兼容性重大的变更 (可选)。使用 "|" 换行 :\n', - // footerPrefixsSelect: '选择关联issue前缀 (可选):', - // customFooterPrefixs: '输入自定义issue前缀 :', - // footer: '列举关联issue (可选) 例如: #31, #I3244 :\n', - // confirmCommit: '是否提交或修改commit ?', - // }, - // types: [ - // { value: 'feat', name: 'feat: 新增功能' }, - // { value: 'fix', name: 'fix: 修复缺陷' }, - // { value: 'docs', name: 'docs: 文档变更' }, - // { value: 'style', name: 'style: 代码格式' }, - // { value: 'refactor', name: 'refactor: 代码重构' }, - // { value: 'perf', name: 'perf: 性能优化' }, - // { value: 'test', name: 'test: 添加疏漏测试或已有测试改动' }, - // { value: 'build', name: 'build: 构建流程、外部依赖变更 (如升级 npm 包、修改打包配置等)' }, - // { value: 'ci', name: 'ci: 修改 CI 配置、脚本' }, - // { value: 'revert', name: 'revert: 回滚 commit' }, - // { value: 'chore', name: 'chore: 对构建过程或辅助工具和库的更改 (不影响源文件、测试用例)' }, - // { value: 'wip', name: 'wip: 正在开发中' }, - // { value: 'workflow', name: 'workflow: 工作流程改进' }, - // { value: 'types', name: 'types: 类型定义文件修改' }, - // ], - // emptyScopesAlias: 'empty: 不填写', - // customScopesAlias: 'custom: 自定义', - }, -}; diff --git a/prettier.config.js b/prettier.config.js deleted file mode 100644 index 1930cd3fb..000000000 --- a/prettier.config.js +++ /dev/null @@ -1,27 +0,0 @@ -module.exports = { - printWidth: 140, - // tab宽度为2空格 - tabWidth: 2, - semi: true, - vueIndentScriptAndStyle: false, - singleQuote: true, - trailingComma: 'all', - proseWrap: 'never', - htmlWhitespaceSensitivity: 'strict', - endOfLine: 'auto', - plugins: ['prettier-plugin-packagejson'], - overrides: [ - { - files: '.*rc', - options: { - parser: 'json', - }, - }, - { - files: '*.html', - options: { - parser: 'html', - }, - }, - ], -}; diff --git a/src/App.vue b/src/App.vue index b25182c68..b2002ddb1 100644 --- a/src/App.vue +++ b/src/App.vue @@ -7,14 +7,15 @@ diff --git a/src/components/Application/src/search/AppSearchKeyItem.vue b/src/components/Application/src/search/AppSearchKeyItem.vue index 5e1896124..b3a741b2e 100644 --- a/src/components/Application/src/search/AppSearchKeyItem.vue +++ b/src/components/Application/src/search/AppSearchKeyItem.vue @@ -5,6 +5,7 @@ diff --git a/src/layouts/default/sider/DragBar.vue b/src/layouts/default/sider/DragBar.vue index 9f59140e3..9a81ce6e9 100644 --- a/src/layouts/default/sider/DragBar.vue +++ b/src/layouts/default/sider/DragBar.vue @@ -4,8 +4,8 @@ diff --git a/src/views/base/lock/useNow.ts b/src/views/base/lock/useNow.ts index dafc9abd4..88ea7db86 100644 --- a/src/views/base/lock/useNow.ts +++ b/src/views/base/lock/useNow.ts @@ -1,6 +1,7 @@ -import { dateUtil } from '@/utils/dateUtil'; -import { reactive, toRefs } from 'vue'; import { tryOnMounted, tryOnUnmounted } from '@vueuse/core'; +import { reactive, toRefs } from 'vue'; + +import { dateUtil } from '@/utils/dateUtil'; export function useNow(immediate = true) { let timer: IntervalHandle; diff --git a/src/views/base/login/ForgetPasswordForm.vue b/src/views/base/login/ForgetPasswordForm.vue index 8b9f97b19..74cb950f6 100644 --- a/src/views/base/login/ForgetPasswordForm.vue +++ b/src/views/base/login/ForgetPasswordForm.vue @@ -1,20 +1,20 @@