From 873d54056dd559c1b17da0c471166cba90eef639 Mon Sep 17 00:00:00 2001 From: TheSmileCat <2098833867@qq.com> Date: Thu, 2 Feb 2023 16:07:38 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=9B=E5=BB=BA=E4=BB=93=E5=BA=93?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .editorconfig | 0 .env.build | 6 + .env.build-test | 8 + .env.serve-dev | 10 + .env.serve-test | 10 + .eslintignore | 6 + .eslintrc.json | 4 + .gitignore | 51 +++ .husky/commit-msg | 5 + .husky/pre-commit | 8 + .npmrc | 7 + .prettierrc | 10 + .vscode/extensions.json | 3 + .vscode/settings.json | 4 + README.md | 85 ++++ eslintrc/.eslintrc-auto-import.json | 116 ++++++ eslintrc/eslint-config.js | 200 ++++++++++ index.html | 13 + mock-prod-server.ts | 12 + mock/example.ts | 12 + mock/excel.ts | 56 +++ mock/table.ts | 31 ++ optimize-include.ts | 133 +++++++ package.json | 129 ++++++ public/favicon.ico | Bin 0 -> 209410 bytes src/App.vue | 45 +++ src/api/remote-search.ts | 17 + src/api/user.ts | 31 ++ src/assets/401_images/401.gif | Bin 0 -> 164227 bytes src/assets/404_images/404.png | Bin 0 -> 98071 bytes src/assets/404_images/404_cloud.png | Bin 0 -> 4766 bytes src/assets/layout/animation-image.gif | Bin 0 -> 6334 bytes src/assets/layout/login-bg.svg | 1 + src/assets/layout/login-front.svg | 6 + src/assets/layout/login-top.svg | 21 + src/assets/layout/login.svg | 1 + src/assets/layout/logo.png | Bin 0 -> 10543 bytes src/components/ElSvgIcon.vue | 36 ++ src/components/TestUnit.vue | 15 + src/components/__tests__/el-svgIcon.test.jsx | 236 +++++++++++ src/directives/button-codes.ts | 21 + src/directives/codes-permission.ts | 20 + src/directives/example/clickoutside.js | 21 + src/directives/example/copy.js | 31 ++ src/directives/example/debounce.js | 26 ++ src/directives/example/longpress.js | 45 +++ src/directives/example/watermark.js | 28 ++ src/directives/example/waves.css | 26 ++ src/directives/example/waves.js | 72 ++++ src/directives/index.ts | 26 ++ src/directives/lang.ts | 44 +++ src/directives/roles-permission.ts | 20 + src/hooks/use-common.ts | 47 +++ src/hooks/use-element.ts | 214 ++++++++++ src/hooks/use-error-log.ts | 32 ++ src/hooks/use-layout.ts | 44 +++ src/hooks/use-permission.ts | 184 +++++++++ src/hooks/use-self-router.ts | 43 ++ src/hooks/use-table.ts | 122 ++++++ src/icons/SvgIcon.vue | 45 +++ src/icons/common/404.svg | 0 src/icons/common/bug.svg | 1 + src/icons/common/chart.svg | 1 + src/icons/common/clipboard.svg | 1 + src/icons/common/component.svg | 1 + src/icons/common/dashboard.svg | 1 + src/icons/common/demo.svg | 1 + src/icons/common/documentation.svg | 1 + src/icons/common/drag.svg | 1 + src/icons/common/edit.svg | 1 + src/icons/common/education.svg | 1 + src/icons/common/email.svg | 1 + src/icons/common/example.svg | 1 + src/icons/common/excel.svg | 1 + src/icons/common/exit-fullscreen.svg | 1 + src/icons/common/eye-open.svg | 1 + src/icons/common/eye.svg | 1 + src/icons/common/form.svg | 1 + src/icons/common/fullscreen.svg | 1 + src/icons/common/guide.svg | 1 + src/icons/common/hamburger.svg | 2 + src/icons/common/icon.svg | 1 + src/icons/common/international.svg | 1 + src/icons/common/language.svg | 1 + src/icons/common/link.svg | 1 + src/icons/common/list.svg | 1 + src/icons/common/lock.svg | 1 + src/icons/common/message.svg | 1 + src/icons/common/money.svg | 1 + src/icons/common/nested.svg | 1 + src/icons/common/password.svg | 1 + src/icons/common/pdf.svg | 1 + src/icons/common/people.svg | 1 + src/icons/common/peoples.svg | 1 + src/icons/common/qq.svg | 1 + src/icons/common/search.svg | 1 + src/icons/common/shopping.svg | 1 + src/icons/common/sidebar-logo.svg | 2 + src/icons/common/size.svg | 1 + src/icons/common/skill.svg | 1 + src/icons/common/star.svg | 1 + src/icons/common/tab.svg | 1 + src/icons/common/table.svg | 1 + src/icons/common/theme.svg | 1 + src/icons/common/tree-table.svg | 1 + src/icons/common/tree.svg | 1 + src/icons/common/user.svg | 1 + src/icons/common/wechat.svg | 1 + src/icons/common/zip.svg | 0 src/icons/nav-bar/dashboard.svg | 1 + src/icons/nav-bar/example.svg | 1 + src/icons/nav-bar/eye-open.svg | 1 + src/icons/nav-bar/eye.svg | 1 + src/icons/nav-bar/form.svg | 1 + src/icons/nav-bar/language.svg | 1 + src/icons/nav-bar/link.svg | 1 + src/icons/nav-bar/nested.svg | 1 + src/icons/nav-bar/password.svg | 1 + src/icons/nav-bar/table.svg | 1 + src/icons/nav-bar/theme-icon.svg | 2 + src/icons/nav-bar/tree.svg | 1 + src/icons/nav-bar/user.svg | 1 + src/lang/en.ts | 123 ++++++ src/lang/index.ts | 19 + src/lang/zh.ts | 177 +++++++++ src/layout/app-main/Breadcrumb.vue | 86 ++++ src/layout/app-main/Hamburger.vue | 33 ++ src/layout/app-main/Navbar.vue | 129 ++++++ src/layout/app-main/TagsView.vue | 305 +++++++++++++++ src/layout/app-main/component/LangSelect.vue | 41 ++ src/layout/app-main/component/ScreenFull.vue | 57 +++ src/layout/app-main/component/ScreenLock.vue | 225 +++++++++++ src/layout/app-main/component/SizeSelect.vue | 39 ++ src/layout/app-main/component/ThemeSelect.vue | 52 +++ src/layout/app-main/index.vue | 120 ++++++ src/layout/index.vue | 68 ++++ src/layout/sidebar/Link.vue | 31 ++ src/layout/sidebar/Logo.vue | 78 ++++ src/layout/sidebar/MenuIcon.vue | 25 ++ src/layout/sidebar/SidebarItem.vue | 82 ++++ src/layout/sidebar/index.vue | 42 ++ src/lib/element-plus.ts | 8 + src/main.ts | 52 +++ src/permission.ts | 50 +++ src/plugins/vite-plugin-setup-extend/index.ts | 38 ++ src/router/index.ts | 222 +++++++++++ src/router/modules/basic-demo.ts | 100 +++++ src/router/modules/charts.ts | 42 ++ src/router/modules/directive.ts | 48 +++ src/router/modules/excel.ts | 23 ++ src/router/modules/guid.ts | 14 + src/router/modules/other.ts | 35 ++ src/router/modules/rich-text.ts | 17 + src/router/modules/table.ts | 23 ++ src/settings.ts | 115 ++++++ src/store/basic.ts | 112 ++++++ src/store/config.ts | 33 ++ src/store/tags-view.ts | 65 ++++ src/styles/index.scss | 69 ++++ src/styles/reset-elemenet-plus-style.scss | 4 + src/styles/scss-suger.scss | 274 +++++++++++++ src/styles/transition.scss | 44 +++ src/theme/base/custom/ct-css-vars.scss | 67 ++++ src/theme/base/element-plus/button.scss | 122 ++++++ src/theme/base/element-plus/checkbox.scss | 27 ++ src/theme/base/element-plus/css-vars.scss | 17 + src/theme/base/element-plus/form.scss | 20 + src/theme/base/element-plus/pagination.scss | 30 ++ src/theme/base/element-plus/redio.scss | 18 + src/theme/base/element-plus/table.scss | 17 + src/theme/base/element-plus/var.scss | 63 +++ src/theme/base/index.scss | 13 + src/theme/china-red/custom/ct-css-vars.scss | 90 +++++ src/theme/china-red/element-plus/button.scss | 123 ++++++ .../china-red/element-plus/checkbox.scss | 27 ++ .../china-red/element-plus/css-vars.scss | 17 + src/theme/china-red/element-plus/form.scss | 20 + .../china-red/element-plus/pagination.scss | 30 ++ src/theme/china-red/element-plus/redio.scss | 18 + src/theme/china-red/element-plus/table.scss | 17 + src/theme/china-red/element-plus/var.scss | 63 +++ src/theme/china-red/index.scss | 13 + src/theme/dark/custom/ct-css-vars.scss | 68 ++++ src/theme/dark/element-plus/button.scss | 123 ++++++ src/theme/dark/element-plus/checkbox.scss | 27 ++ src/theme/dark/element-plus/css-vars.css | 0 src/theme/dark/element-plus/css-vars.css.map | 1 + src/theme/dark/element-plus/css-vars.scss | 17 + src/theme/dark/element-plus/form.scss | 20 + src/theme/dark/element-plus/pagination.scss | 30 ++ src/theme/dark/element-plus/redio.scss | 18 + src/theme/dark/element-plus/table.scss | 17 + src/theme/dark/element-plus/var.scss | 63 +++ src/theme/dark/index.scss | 13 + src/theme/index.css | 0 src/theme/index.css.map | 1 + src/theme/index.scss | 11 + src/theme/lighting/custom/ct-css-vars.scss | 67 ++++ src/theme/lighting/element-plus/button.scss | 123 ++++++ src/theme/lighting/element-plus/checkbox.scss | 27 ++ src/theme/lighting/element-plus/css-vars.css | 0 .../lighting/element-plus/css-vars.css.map | 1 + src/theme/lighting/element-plus/css-vars.scss | 17 + src/theme/lighting/element-plus/form.scss | 20 + .../lighting/element-plus/pagination.scss | 30 ++ src/theme/lighting/element-plus/redio.scss | 18 + src/theme/lighting/element-plus/table.scss | 17 + src/theme/lighting/element-plus/var.scss | 63 +++ src/theme/lighting/index.scss | 13 + src/theme/mixins/_var.scss | 55 +++ src/theme/mixins/config.scss | 5 + src/theme/mixins/function.scss | 60 +++ src/theme/mixins/mixins.scss | 61 +++ src/theme/utils/change-theme.ts | 3 + src/theme/utils/index.ts | 1 + src/utils/axios-req.ts | 67 ++++ src/utils/bus.ts | 3 + src/utils/common-util.ts | 126 ++++++ src/utils/mock-axios-req.ts | 59 +++ src/views/basic-demo/hook/index.vue | 14 + src/views/basic-demo/keep-alive/index.vue | 58 +++ .../basic-demo/keep-alive/second-child.vue | 33 ++ .../basic-demo/keep-alive/tab-keep-alive.vue | 19 + .../basic-demo/keep-alive/third-child.vue | 30 ++ .../third-children/SecondChildren.vue | 10 + .../third-children/ThirdChildren.vue | 10 + .../keep-alive/third-keep-alive.vue | 19 + src/views/basic-demo/mock/index.vue | 17 + .../basic-demo/parent-children/Children.vue | 76 ++++ .../parent-children/SubChildren.vue | 34 ++ .../basic-demo/parent-children/index.vue | 54 +++ src/views/basic-demo/pinia/index.vue | 14 + src/views/basic-demo/svg-icon/index.vue | 18 + .../basic-demo/vue3-template/Vue3Template.vue | 39 ++ src/views/basic-demo/worker/index.vue | 45 +++ src/views/charts/components/Keyboard.vue | 158 ++++++++ src/views/charts/components/LineMarker.vue | 278 +++++++++++++ src/views/charts/components/MixChart.vue | 232 +++++++++++ src/views/charts/components/mixins/resize.js | 56 +++ src/views/charts/echarts-demo.vue | 356 +++++++++++++++++ src/views/charts/keyboard.vue | 17 + src/views/charts/line.vue | 17 + src/views/charts/mix-chart.vue | 17 + src/views/dashboard/index.vue | 51 +++ src/views/directive/clickoutside.vue | 35 ++ src/views/directive/copy.vue | 19 + src/views/directive/debounce.vue | 24 ++ src/views/directive/longpress.vue | 15 + src/views/directive/watermark.vue | 12 + src/views/directive/waves.vue | 17 + src/views/error-log/error-generator.vue | 79 ++++ src/views/error-log/index.vue | 148 +++++++ src/views/error-page/401.vue | 93 +++++ src/views/error-page/404.vue | 225 +++++++++++ src/views/excel/excel.js | 57 +++ src/views/excel/exportExcel.vue | 99 +++++ src/views/excel/importExcel.vue | 54 +++ src/views/guide/index.vue | 33 ++ src/views/guide/steps.ts | 45 +++ src/views/login/index.vue | 22 ++ src/views/login/login-alt.vue | 270 +++++++++++++ src/views/login/login-basic.vue | 253 ++++++++++++ src/views/login/login-lighting.vue | 252 ++++++++++++ src/views/nested/menu1/index.vue | 9 + src/views/nested/menu1/menu1-1/index.vue | 11 + src/views/nested/menu1/menu1-2/index.vue | 9 + .../nested/menu1/menu1-2/menu1-2-1/index.vue | 5 + .../nested/menu1/menu1-2/menu1-2-2/index.vue | 5 + src/views/nested/menu1/menu1-3/index.vue | 5 + src/views/nested/menu2/index.vue | 6 + src/views/other/count-to.vue | 24 ++ src/views/other/d3/component/NodeDetail.vue | 61 +++ src/views/other/d3/data.json | 269 +++++++++++++ src/views/other/d3/index.vue | 170 ++++++++ src/views/other/d3/useD3.js | 183 +++++++++ src/views/other/d3/useDatas.js | 109 ++++++ src/views/other/drag-pane.vue | 41 ++ src/views/other/signboard/component/index.vue | 89 +++++ src/views/other/signboard/index.vue | 58 +++ src/views/rbac-test/TestAddEdit.vue | 5 + src/views/rbac-test/TestButton.vue | 14 + src/views/rbac-test/TestDetail.vue | 5 + src/views/rbac-test/TestMenu.vue | 22 ++ src/views/redirect/index.tsx | 13 + src/views/rich-text/TinymceExample-bak.vue | 33 ++ src/views/rich-text/TinymceExample.vue | 7 + src/views/rich-text/tinymce/index.vue | 119 ++++++ src/views/roles-codes/button-permission.vue | 7 + src/views/roles-codes/code-index.vue | 4 + src/views/roles-codes/index.vue | 29 ++ src/views/roles-codes/role-index.vue | 3 + src/views/setting-switch/SettingSwitch.vue | 50 +++ src/views/setting-switch/index.vue | 50 +++ src/views/table/dynamic-table.vue | 90 +++++ src/views/table/vxe-table.vue | 368 ++++++++++++++++++ ts-out-dir/package.json | 124 ++++++ ts-out-dir/src/api/user.d.ts | 3 + ts-out-dir/src/api/user.js | 26 ++ ts-out-dir/src/directives/button-codes.d.ts | 5 + ts-out-dir/src/directives/button-codes.js | 22 ++ .../src/directives/codes-permission.d.ts | 5 + ts-out-dir/src/directives/codes-permission.js | 22 ++ ts-out-dir/src/directives/index.d.ts | 1 + ts-out-dir/src/directives/index.js | 8 + .../src/directives/roles-permission.d.ts | 5 + ts-out-dir/src/directives/roles-permission.js | 22 ++ ts-out-dir/src/hooks/use-common.d.ts | 10 + ts-out-dir/src/hooks/use-common.js | 31 ++ ts-out-dir/src/hooks/use-element.d.ts | 67 ++++ ts-out-dir/src/hooks/use-element.js | 158 ++++++++ ts-out-dir/src/hooks/use-error-log.d.ts | 1 + ts-out-dir/src/hooks/use-error-log.js | 28 ++ ts-out-dir/src/hooks/use-layout.d.ts | 2 + ts-out-dir/src/hooks/use-layout.js | 38 ++ ts-out-dir/src/hooks/use-permission.d.ts | 15 + ts-out-dir/src/hooks/use-permission.js | 146 +++++++ ts-out-dir/src/hooks/use-self-router.d.ts | 4 + ts-out-dir/src/hooks/use-self-router.js | 40 ++ ts-out-dir/src/hooks/use-table.d.ts | 15 + ts-out-dir/src/hooks/use-table.js | 106 +++++ ts-out-dir/src/lib/element-plus.d.ts | 1 + ts-out-dir/src/lib/element-plus.js | 7 + ts-out-dir/src/main.d.ts | 6 + ts-out-dir/src/main.js | 22 ++ ts-out-dir/src/permission.d.ts | 1 + ts-out-dir/src/permission.js | 44 +++ ts-out-dir/src/router/index.d.ts | 6 + ts-out-dir/src/router/index.js | 203 ++++++++++ ts-out-dir/src/settings.d.ts | 3 + ts-out-dir/src/settings.js | 21 + ts-out-dir/src/store/basic.d.ts | 41 ++ ts-out-dir/src/store/basic.js | 124 ++++++ ts-out-dir/src/store/tagsView.d.ts | 8 + ts-out-dir/src/store/tagsView.js | 59 +++ ts-out-dir/src/utils/axios-req.d.ts | 1 + ts-out-dir/src/utils/axios-req.js | 52 +++ ts-out-dir/src/utils/bus.d.ts | 2 + ts-out-dir/src/utils/bus.js | 2 + ts-out-dir/src/utils/common-util.d.ts | 16 + ts-out-dir/src/utils/common-util.js | 66 ++++ ts-out-dir/src/views/redirect/index.d.ts | 2 + ts-out-dir/src/views/redirect/index.jsx | 13 + tsconfig.base.json | 50 +++ tsconfig.json | 11 + typings/auto-imports.d.ts | 116 ++++++ typings/basic.d.ts | 66 ++++ typings/components.d.ts | 16 + typings/env.d.ts | 12 + typings/global.d.ts | 10 + typings/shims-vue.d.ts | 6 + vite.config.ts | 123 ++++++ vitest.config.ts | 19 + vitest.setup.ts | 5 + 353 files changed, 15014 insertions(+) create mode 100644 .editorconfig create mode 100644 .env.build create mode 100644 .env.build-test create mode 100644 .env.serve-dev create mode 100644 .env.serve-test create mode 100644 .eslintignore create mode 100644 .eslintrc.json create mode 100644 .gitignore create mode 100644 .husky/commit-msg create mode 100644 .husky/pre-commit create mode 100644 .npmrc create mode 100644 .prettierrc create mode 100644 .vscode/extensions.json create mode 100644 .vscode/settings.json create mode 100644 README.md create mode 100644 eslintrc/.eslintrc-auto-import.json create mode 100644 eslintrc/eslint-config.js create mode 100644 index.html create mode 100644 mock-prod-server.ts create mode 100644 mock/example.ts create mode 100644 mock/excel.ts create mode 100644 mock/table.ts create mode 100644 optimize-include.ts create mode 100644 package.json create mode 100644 public/favicon.ico create mode 100644 src/App.vue create mode 100644 src/api/remote-search.ts create mode 100644 src/api/user.ts create mode 100644 src/assets/401_images/401.gif create mode 100644 src/assets/404_images/404.png create mode 100644 src/assets/404_images/404_cloud.png create mode 100644 src/assets/layout/animation-image.gif create mode 100644 src/assets/layout/login-bg.svg create mode 100644 src/assets/layout/login-front.svg create mode 100644 src/assets/layout/login-top.svg create mode 100644 src/assets/layout/login.svg create mode 100644 src/assets/layout/logo.png create mode 100644 src/components/ElSvgIcon.vue create mode 100644 src/components/TestUnit.vue create mode 100644 src/components/__tests__/el-svgIcon.test.jsx create mode 100644 src/directives/button-codes.ts create mode 100644 src/directives/codes-permission.ts create mode 100644 src/directives/example/clickoutside.js create mode 100644 src/directives/example/copy.js create mode 100644 src/directives/example/debounce.js create mode 100644 src/directives/example/longpress.js create mode 100644 src/directives/example/watermark.js create mode 100644 src/directives/example/waves.css create mode 100644 src/directives/example/waves.js create mode 100644 src/directives/index.ts create mode 100644 src/directives/lang.ts create mode 100644 src/directives/roles-permission.ts create mode 100644 src/hooks/use-common.ts create mode 100644 src/hooks/use-element.ts create mode 100644 src/hooks/use-error-log.ts create mode 100644 src/hooks/use-layout.ts create mode 100644 src/hooks/use-permission.ts create mode 100644 src/hooks/use-self-router.ts create mode 100644 src/hooks/use-table.ts create mode 100644 src/icons/SvgIcon.vue create mode 100644 src/icons/common/404.svg create mode 100644 src/icons/common/bug.svg create mode 100644 src/icons/common/chart.svg create mode 100644 src/icons/common/clipboard.svg create mode 100644 src/icons/common/component.svg create mode 100644 src/icons/common/dashboard.svg create mode 100644 src/icons/common/demo.svg create mode 100644 src/icons/common/documentation.svg create mode 100644 src/icons/common/drag.svg create mode 100644 src/icons/common/edit.svg create mode 100644 src/icons/common/education.svg create mode 100644 src/icons/common/email.svg create mode 100644 src/icons/common/example.svg create mode 100644 src/icons/common/excel.svg create mode 100644 src/icons/common/exit-fullscreen.svg create mode 100644 src/icons/common/eye-open.svg create mode 100644 src/icons/common/eye.svg create mode 100644 src/icons/common/form.svg create mode 100644 src/icons/common/fullscreen.svg create mode 100644 src/icons/common/guide.svg create mode 100644 src/icons/common/hamburger.svg create mode 100644 src/icons/common/icon.svg create mode 100644 src/icons/common/international.svg create mode 100644 src/icons/common/language.svg create mode 100644 src/icons/common/link.svg create mode 100644 src/icons/common/list.svg create mode 100644 src/icons/common/lock.svg create mode 100644 src/icons/common/message.svg create mode 100644 src/icons/common/money.svg create mode 100644 src/icons/common/nested.svg create mode 100644 src/icons/common/password.svg create mode 100644 src/icons/common/pdf.svg create mode 100644 src/icons/common/people.svg create mode 100644 src/icons/common/peoples.svg create mode 100644 src/icons/common/qq.svg create mode 100644 src/icons/common/search.svg create mode 100644 src/icons/common/shopping.svg create mode 100644 src/icons/common/sidebar-logo.svg create mode 100644 src/icons/common/size.svg create mode 100644 src/icons/common/skill.svg create mode 100644 src/icons/common/star.svg create mode 100644 src/icons/common/tab.svg create mode 100644 src/icons/common/table.svg create mode 100644 src/icons/common/theme.svg create mode 100644 src/icons/common/tree-table.svg create mode 100644 src/icons/common/tree.svg create mode 100644 src/icons/common/user.svg create mode 100644 src/icons/common/wechat.svg create mode 100644 src/icons/common/zip.svg create mode 100644 src/icons/nav-bar/dashboard.svg create mode 100644 src/icons/nav-bar/example.svg create mode 100644 src/icons/nav-bar/eye-open.svg create mode 100644 src/icons/nav-bar/eye.svg create mode 100644 src/icons/nav-bar/form.svg create mode 100644 src/icons/nav-bar/language.svg create mode 100644 src/icons/nav-bar/link.svg create mode 100644 src/icons/nav-bar/nested.svg create mode 100644 src/icons/nav-bar/password.svg create mode 100644 src/icons/nav-bar/table.svg create mode 100644 src/icons/nav-bar/theme-icon.svg create mode 100644 src/icons/nav-bar/tree.svg create mode 100644 src/icons/nav-bar/user.svg create mode 100644 src/lang/en.ts create mode 100644 src/lang/index.ts create mode 100644 src/lang/zh.ts create mode 100644 src/layout/app-main/Breadcrumb.vue create mode 100644 src/layout/app-main/Hamburger.vue create mode 100644 src/layout/app-main/Navbar.vue create mode 100644 src/layout/app-main/TagsView.vue create mode 100644 src/layout/app-main/component/LangSelect.vue create mode 100644 src/layout/app-main/component/ScreenFull.vue create mode 100644 src/layout/app-main/component/ScreenLock.vue create mode 100644 src/layout/app-main/component/SizeSelect.vue create mode 100644 src/layout/app-main/component/ThemeSelect.vue create mode 100644 src/layout/app-main/index.vue create mode 100644 src/layout/index.vue create mode 100644 src/layout/sidebar/Link.vue create mode 100644 src/layout/sidebar/Logo.vue create mode 100644 src/layout/sidebar/MenuIcon.vue create mode 100644 src/layout/sidebar/SidebarItem.vue create mode 100644 src/layout/sidebar/index.vue create mode 100644 src/lib/element-plus.ts create mode 100644 src/main.ts create mode 100644 src/permission.ts create mode 100644 src/plugins/vite-plugin-setup-extend/index.ts create mode 100644 src/router/index.ts create mode 100644 src/router/modules/basic-demo.ts create mode 100644 src/router/modules/charts.ts create mode 100644 src/router/modules/directive.ts create mode 100644 src/router/modules/excel.ts create mode 100644 src/router/modules/guid.ts create mode 100644 src/router/modules/other.ts create mode 100644 src/router/modules/rich-text.ts create mode 100644 src/router/modules/table.ts create mode 100644 src/settings.ts create mode 100644 src/store/basic.ts create mode 100644 src/store/config.ts create mode 100644 src/store/tags-view.ts create mode 100644 src/styles/index.scss create mode 100644 src/styles/reset-elemenet-plus-style.scss create mode 100644 src/styles/scss-suger.scss create mode 100644 src/styles/transition.scss create mode 100644 src/theme/base/custom/ct-css-vars.scss create mode 100644 src/theme/base/element-plus/button.scss create mode 100644 src/theme/base/element-plus/checkbox.scss create mode 100644 src/theme/base/element-plus/css-vars.scss create mode 100644 src/theme/base/element-plus/form.scss create mode 100644 src/theme/base/element-plus/pagination.scss create mode 100644 src/theme/base/element-plus/redio.scss create mode 100644 src/theme/base/element-plus/table.scss create mode 100644 src/theme/base/element-plus/var.scss create mode 100644 src/theme/base/index.scss create mode 100644 src/theme/china-red/custom/ct-css-vars.scss create mode 100644 src/theme/china-red/element-plus/button.scss create mode 100644 src/theme/china-red/element-plus/checkbox.scss create mode 100644 src/theme/china-red/element-plus/css-vars.scss create mode 100644 src/theme/china-red/element-plus/form.scss create mode 100644 src/theme/china-red/element-plus/pagination.scss create mode 100644 src/theme/china-red/element-plus/redio.scss create mode 100644 src/theme/china-red/element-plus/table.scss create mode 100644 src/theme/china-red/element-plus/var.scss create mode 100644 src/theme/china-red/index.scss create mode 100644 src/theme/dark/custom/ct-css-vars.scss create mode 100644 src/theme/dark/element-plus/button.scss create mode 100644 src/theme/dark/element-plus/checkbox.scss create mode 100644 src/theme/dark/element-plus/css-vars.css create mode 100644 src/theme/dark/element-plus/css-vars.css.map create mode 100644 src/theme/dark/element-plus/css-vars.scss create mode 100644 src/theme/dark/element-plus/form.scss create mode 100644 src/theme/dark/element-plus/pagination.scss create mode 100644 src/theme/dark/element-plus/redio.scss create mode 100644 src/theme/dark/element-plus/table.scss create mode 100644 src/theme/dark/element-plus/var.scss create mode 100644 src/theme/dark/index.scss create mode 100644 src/theme/index.css create mode 100644 src/theme/index.css.map create mode 100644 src/theme/index.scss create mode 100644 src/theme/lighting/custom/ct-css-vars.scss create mode 100644 src/theme/lighting/element-plus/button.scss create mode 100644 src/theme/lighting/element-plus/checkbox.scss create mode 100644 src/theme/lighting/element-plus/css-vars.css create mode 100644 src/theme/lighting/element-plus/css-vars.css.map create mode 100644 src/theme/lighting/element-plus/css-vars.scss create mode 100644 src/theme/lighting/element-plus/form.scss create mode 100644 src/theme/lighting/element-plus/pagination.scss create mode 100644 src/theme/lighting/element-plus/redio.scss create mode 100644 src/theme/lighting/element-plus/table.scss create mode 100644 src/theme/lighting/element-plus/var.scss create mode 100644 src/theme/lighting/index.scss create mode 100644 src/theme/mixins/_var.scss create mode 100644 src/theme/mixins/config.scss create mode 100644 src/theme/mixins/function.scss create mode 100644 src/theme/mixins/mixins.scss create mode 100644 src/theme/utils/change-theme.ts create mode 100644 src/theme/utils/index.ts create mode 100644 src/utils/axios-req.ts create mode 100644 src/utils/bus.ts create mode 100644 src/utils/common-util.ts create mode 100644 src/utils/mock-axios-req.ts create mode 100644 src/views/basic-demo/hook/index.vue create mode 100644 src/views/basic-demo/keep-alive/index.vue create mode 100644 src/views/basic-demo/keep-alive/second-child.vue create mode 100644 src/views/basic-demo/keep-alive/tab-keep-alive.vue create mode 100644 src/views/basic-demo/keep-alive/third-child.vue create mode 100644 src/views/basic-demo/keep-alive/third-children/SecondChildren.vue create mode 100644 src/views/basic-demo/keep-alive/third-children/ThirdChildren.vue create mode 100644 src/views/basic-demo/keep-alive/third-keep-alive.vue create mode 100644 src/views/basic-demo/mock/index.vue create mode 100644 src/views/basic-demo/parent-children/Children.vue create mode 100644 src/views/basic-demo/parent-children/SubChildren.vue create mode 100644 src/views/basic-demo/parent-children/index.vue create mode 100644 src/views/basic-demo/pinia/index.vue create mode 100644 src/views/basic-demo/svg-icon/index.vue create mode 100644 src/views/basic-demo/vue3-template/Vue3Template.vue create mode 100644 src/views/basic-demo/worker/index.vue create mode 100644 src/views/charts/components/Keyboard.vue create mode 100644 src/views/charts/components/LineMarker.vue create mode 100644 src/views/charts/components/MixChart.vue create mode 100644 src/views/charts/components/mixins/resize.js create mode 100644 src/views/charts/echarts-demo.vue create mode 100644 src/views/charts/keyboard.vue create mode 100644 src/views/charts/line.vue create mode 100644 src/views/charts/mix-chart.vue create mode 100644 src/views/dashboard/index.vue create mode 100644 src/views/directive/clickoutside.vue create mode 100644 src/views/directive/copy.vue create mode 100644 src/views/directive/debounce.vue create mode 100644 src/views/directive/longpress.vue create mode 100644 src/views/directive/watermark.vue create mode 100644 src/views/directive/waves.vue create mode 100644 src/views/error-log/error-generator.vue create mode 100644 src/views/error-log/index.vue create mode 100644 src/views/error-page/401.vue create mode 100644 src/views/error-page/404.vue create mode 100644 src/views/excel/excel.js create mode 100644 src/views/excel/exportExcel.vue create mode 100644 src/views/excel/importExcel.vue create mode 100644 src/views/guide/index.vue create mode 100644 src/views/guide/steps.ts create mode 100644 src/views/login/index.vue create mode 100644 src/views/login/login-alt.vue create mode 100644 src/views/login/login-basic.vue create mode 100644 src/views/login/login-lighting.vue create mode 100644 src/views/nested/menu1/index.vue create mode 100644 src/views/nested/menu1/menu1-1/index.vue create mode 100644 src/views/nested/menu1/menu1-2/index.vue create mode 100644 src/views/nested/menu1/menu1-2/menu1-2-1/index.vue create mode 100644 src/views/nested/menu1/menu1-2/menu1-2-2/index.vue create mode 100644 src/views/nested/menu1/menu1-3/index.vue create mode 100644 src/views/nested/menu2/index.vue create mode 100644 src/views/other/count-to.vue create mode 100644 src/views/other/d3/component/NodeDetail.vue create mode 100644 src/views/other/d3/data.json create mode 100644 src/views/other/d3/index.vue create mode 100644 src/views/other/d3/useD3.js create mode 100644 src/views/other/d3/useDatas.js create mode 100644 src/views/other/drag-pane.vue create mode 100644 src/views/other/signboard/component/index.vue create mode 100644 src/views/other/signboard/index.vue create mode 100644 src/views/rbac-test/TestAddEdit.vue create mode 100644 src/views/rbac-test/TestButton.vue create mode 100644 src/views/rbac-test/TestDetail.vue create mode 100644 src/views/rbac-test/TestMenu.vue create mode 100644 src/views/redirect/index.tsx create mode 100644 src/views/rich-text/TinymceExample-bak.vue create mode 100644 src/views/rich-text/TinymceExample.vue create mode 100644 src/views/rich-text/tinymce/index.vue create mode 100644 src/views/roles-codes/button-permission.vue create mode 100644 src/views/roles-codes/code-index.vue create mode 100644 src/views/roles-codes/index.vue create mode 100644 src/views/roles-codes/role-index.vue create mode 100644 src/views/setting-switch/SettingSwitch.vue create mode 100644 src/views/setting-switch/index.vue create mode 100644 src/views/table/dynamic-table.vue create mode 100644 src/views/table/vxe-table.vue create mode 100644 ts-out-dir/package.json create mode 100644 ts-out-dir/src/api/user.d.ts create mode 100644 ts-out-dir/src/api/user.js create mode 100644 ts-out-dir/src/directives/button-codes.d.ts create mode 100644 ts-out-dir/src/directives/button-codes.js create mode 100644 ts-out-dir/src/directives/codes-permission.d.ts create mode 100644 ts-out-dir/src/directives/codes-permission.js create mode 100644 ts-out-dir/src/directives/index.d.ts create mode 100644 ts-out-dir/src/directives/index.js create mode 100644 ts-out-dir/src/directives/roles-permission.d.ts create mode 100644 ts-out-dir/src/directives/roles-permission.js create mode 100644 ts-out-dir/src/hooks/use-common.d.ts create mode 100644 ts-out-dir/src/hooks/use-common.js create mode 100644 ts-out-dir/src/hooks/use-element.d.ts create mode 100644 ts-out-dir/src/hooks/use-element.js create mode 100644 ts-out-dir/src/hooks/use-error-log.d.ts create mode 100644 ts-out-dir/src/hooks/use-error-log.js create mode 100644 ts-out-dir/src/hooks/use-layout.d.ts create mode 100644 ts-out-dir/src/hooks/use-layout.js create mode 100644 ts-out-dir/src/hooks/use-permission.d.ts create mode 100644 ts-out-dir/src/hooks/use-permission.js create mode 100644 ts-out-dir/src/hooks/use-self-router.d.ts create mode 100644 ts-out-dir/src/hooks/use-self-router.js create mode 100644 ts-out-dir/src/hooks/use-table.d.ts create mode 100644 ts-out-dir/src/hooks/use-table.js create mode 100644 ts-out-dir/src/lib/element-plus.d.ts create mode 100644 ts-out-dir/src/lib/element-plus.js create mode 100644 ts-out-dir/src/main.d.ts create mode 100644 ts-out-dir/src/main.js create mode 100644 ts-out-dir/src/permission.d.ts create mode 100644 ts-out-dir/src/permission.js create mode 100644 ts-out-dir/src/router/index.d.ts create mode 100644 ts-out-dir/src/router/index.js create mode 100644 ts-out-dir/src/settings.d.ts create mode 100644 ts-out-dir/src/settings.js create mode 100644 ts-out-dir/src/store/basic.d.ts create mode 100644 ts-out-dir/src/store/basic.js create mode 100644 ts-out-dir/src/store/tagsView.d.ts create mode 100644 ts-out-dir/src/store/tagsView.js create mode 100644 ts-out-dir/src/utils/axios-req.d.ts create mode 100644 ts-out-dir/src/utils/axios-req.js create mode 100644 ts-out-dir/src/utils/bus.d.ts create mode 100644 ts-out-dir/src/utils/bus.js create mode 100644 ts-out-dir/src/utils/common-util.d.ts create mode 100644 ts-out-dir/src/utils/common-util.js create mode 100644 ts-out-dir/src/views/redirect/index.d.ts create mode 100644 ts-out-dir/src/views/redirect/index.jsx create mode 100644 tsconfig.base.json create mode 100644 tsconfig.json create mode 100644 typings/auto-imports.d.ts create mode 100644 typings/basic.d.ts create mode 100644 typings/components.d.ts create mode 100644 typings/env.d.ts create mode 100644 typings/global.d.ts create mode 100644 typings/shims-vue.d.ts create mode 100644 vite.config.ts create mode 100644 vitest.config.ts create mode 100644 vitest.setup.ts diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000..e69de29 diff --git a/.env.build b/.env.build new file mode 100644 index 0000000..43a43c7 --- /dev/null +++ b/.env.build @@ -0,0 +1,6 @@ +VITE_APP_ENV = 'prod' +#自动获取地址推荐 +VITE_APP_BASE_URL = 'https://github.jzfai.top/micro-service-api' + +#image or oss address +VITE_APP_IMAGE_URL = 'https://github.jzfai.top/gofast-image' diff --git a/.env.build-test b/.env.build-test new file mode 100644 index 0000000..d454976 --- /dev/null +++ b/.env.build-test @@ -0,0 +1,8 @@ +VITE_APP_ENV = 'test' +#自动获取地址推荐 +#VITE_APP_BASE_URL = '/micro-service-api' +VITE_APP_BASE_URL = 'https://github.jzfai.top/micro-service-api' +VITE_APP_BASE_WS_URL = '' + +#image or oss address +VITE_APP_IMAGE_URL = 'https://github.jzfai.top/gofast-image' diff --git a/.env.serve-dev b/.env.serve-dev new file mode 100644 index 0000000..a38d289 --- /dev/null +++ b/.env.serve-dev @@ -0,0 +1,10 @@ +#The defined variable must start with VITE_APP_ +VITE_APP_ENV = 'dev' +VITE_APP_BASE_URL = 'https://github.jzfai.top/micro-service-api' + +#image or oss address +VITE_APP_IMAGE_URL = 'https://github.jzfai.top/gofast-image' + +#proxy, use this to test proxy +#VITE_APP_BASE_URL = '/api' +#VITE_APP_PROXY_URL = 'https://github.jzfai.top/micro-service-api' diff --git a/.env.serve-test b/.env.serve-test new file mode 100644 index 0000000..ed14544 --- /dev/null +++ b/.env.serve-test @@ -0,0 +1,10 @@ +#The defined variable must start with VITE_APP_ +VITE_APP_ENV = 'test' +VITE_APP_BASE_URL = 'https://github.jzfai.top/micro-service-api' + + #image or oss address +VITE_APP_IMAGE_URL = 'https://github.jzfai.top/gofast-image' + +#proxy, use this to test proxy +#VITE_APP_BASE_URL = '/api' +#VITE_APP_PROXY_URL = 'https://github.jzfai.top/micro-service-api' diff --git a/.eslintignore b/.eslintignore new file mode 100644 index 0000000..14f5b39 --- /dev/null +++ b/.eslintignore @@ -0,0 +1,6 @@ +public +node_modules +.history +.husky +dist +*.d.ts diff --git a/.eslintrc.json b/.eslintrc.json new file mode 100644 index 0000000..c7e7ebd --- /dev/null +++ b/.eslintrc.json @@ -0,0 +1,4 @@ +{ + "root": true, + "extends": ["./eslintrc/eslint-config.js", "./eslintrc/.eslintrc-auto-import.json"] +} diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..b5e33a8 --- /dev/null +++ b/.gitignore @@ -0,0 +1,51 @@ +# compiled output +/dist +/dist-ssr +/node_modules + +#lock +pnpm-lock.yaml + +# Logs +logs +*.log +npm-debug.log* +pnpm-debug.log* +yarn-debug.log* +yarn-error.log* +lerna-debug.log* + +# OS +.DS_Store + +# Tests +/coverage +/.nyc_output + +# IDEs and editors +/.idea +.project +.classpath +.c9/ +*.launch +.settings/ +*.sublime-workspace + +# IDE - VSCode +.vscode/* +!.vscode/settings.json +!.vscode/tasks.json +!.vscode/launch.json +!.vscode/extensions.json + +# Other +.history +*.local +yarn* +pnpm* + + +#.eslintrc-auto-import.json +#auto-imports.d.ts +#components.d.ts +stats.html diff --git a/.husky/commit-msg b/.husky/commit-msg new file mode 100644 index 0000000..3b92648 --- /dev/null +++ b/.husky/commit-msg @@ -0,0 +1,5 @@ +#!/bin/sh +#. "$(dirname "$0")/_/husky.sh" +#在项目中我们会使用commit-msg这个git hook来校验我们commit时添加的备注信息是否符合规范。在以前的我们通常是这样配置: +#--no-install 参数表示强制npx使用项目中node_modules目录中的commitlint包(如果需要开启,注意:需要安装npx) +#npx --no-install commitlint --edit $1 diff --git a/.husky/pre-commit b/.husky/pre-commit new file mode 100644 index 0000000..db96295 --- /dev/null +++ b/.husky/pre-commit @@ -0,0 +1,8 @@ +#!/bin/sh +. "$(dirname "$0")/_/husky.sh" + +#推送之前运行eslint检查 +npm run lint +#推送之前运行单元测试检查 +#npm run test:unit + diff --git a/.npmrc b/.npmrc new file mode 100644 index 0000000..daf66a1 --- /dev/null +++ b/.npmrc @@ -0,0 +1,7 @@ +shamefully-hoist=true +strict-peer-dependencies=false + +###aliyun address +registry = https://registry.npmmirror.com + + diff --git a/.prettierrc b/.prettierrc new file mode 100644 index 0000000..454eec7 --- /dev/null +++ b/.prettierrc @@ -0,0 +1,10 @@ +{ + "useTabs": false, + "tabWidth": 2, + "printWidth": 120, + "singleQuote": true, + "trailingComma": "none", + "bracketSpacing": true, + "semi": false, + "htmlWhitespaceSensitivity": "ignore" +} diff --git a/.vscode/extensions.json b/.vscode/extensions.json new file mode 100644 index 0000000..0c87b22 --- /dev/null +++ b/.vscode/extensions.json @@ -0,0 +1,3 @@ +{ + "recommendations": ["johnsoncodehk.volar", "esbenp.prettier-vscode","dbaeumer.vscode-eslint"] +} diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..4029450 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,4 @@ +{ + "editor.defaultFormatter": "esbenp.prettier-vscode", + "npm.packageManager": "yarn" +} diff --git a/README.md b/README.md new file mode 100644 index 0000000..ffef565 --- /dev/null +++ b/README.md @@ -0,0 +1,85 @@ +# vue3-admin-plus + +The plus version of vue3-admin-ts , provide enterprise-class using demo + +suggestion the Node.js >= 16.0.0。 + + + +## Documents + +- [Official Documentation](https://github.jzfai.top/vue3-admin-doc/) + +- [中文官网](https://github.jzfai.top/vue3-admin-cn-doc/) + + + +## Online experience + +[Access address](https://github.jzfai.top/vue3-admin-plus) + +[国内体验地址](https://github.jzfai.top/vue3-admin-plus) + + + +## Related items + +The framework is available in js,ts, plus and electron versions +- js version:[vue3-admin-template](https://github.com/jzfai/vue3-admin-template.git) -- basic version +- ts version:[vue3-element-ts](https://github.com/jzfai/vue3-admin-ts.git) +- ts version for plus:[vue3-element-plus](https://github.com/jzfai/vue3-admin-plus.git) +- ts version for electron:[vue3-element-electron](https://github.com/jzfai/vue3-admin-electron.git) +- java Micro-service background data:[micro-service-plus](https://github.com/jzfai/micro-service-plus) + + +## Build Setup + +```bash +# clone the project +git clone https://github.com/jzfai/vue3-admin-plus.git + +# enter the project directory +cd vue3-admin-plus + +# pnpm address https://pnpm.io/zh/motivation +# install dependency(Recommend use pnpm) +# you can use "npm -g i pnpm@7.9.0" to install pnpm +pnpm i + +# develop +pnpm run dev +``` + + +## Build + +```bash +# build for test environment +pnpm run build-test + +# build for production environment +pnpm run build +``` + +## Others + +```bash +# preview the release environment effect +pnpm run preview + +# code format check +pnpm run lint + +``` + + +## Browsers support + +Note: Vue3 is not supported the Internet Explorer + + +## Discussion and Communication +[WeChat group](https://github.jzfai.top/file/images/wx-groud.png) + + + diff --git a/eslintrc/.eslintrc-auto-import.json b/eslintrc/.eslintrc-auto-import.json new file mode 100644 index 0000000..429c7b0 --- /dev/null +++ b/eslintrc/.eslintrc-auto-import.json @@ -0,0 +1,116 @@ +{ + "globals": { + "EffectScope": true, + "axiosReq": true, + "bus": true, + "buttonCodes": true, + "casHandleChange": true, + "clickoutside": true, + "cloneDeep": true, + "closeElLoading": true, + "codesPermission": true, + "commonUtil": true, + "computed": true, + "copy": true, + "copyValueToClipboard": true, + "createApp": true, + "customRef": true, + "debounce": true, + "defineAsyncComponent": true, + "defineComponent": true, + "directives": true, + "effectScope": true, + "elConfirm": true, + "elConfirmNoCancelBtn": true, + "elLoading": true, + "elMessage": true, + "elNotify": true, + "filterAsyncRouter": true, + "filterAsyncRouterByCodes": true, + "filterAsyncRoutesByMenuList": true, + "filterAsyncRoutesByRoles": true, + "freshRouter": true, + "getCurrentInstance": true, + "getCurrentScope": true, + "getLangInstance": true, + "getQueryParam": true, + "h": true, + "inject": true, + "isExternal": true, + "isProxy": true, + "isReactive": true, + "isReadonly": true, + "isRef": true, + "lang": true, + "langTitle": true, + "loginOutReq": true, + "loginReq": true, + "longpress": true, + "markRaw": true, + "mockAxiosReq": true, + "nextTick": true, + "onActivated": true, + "onBeforeMount": true, + "onBeforeRouteLeave": true, + "onBeforeRouteUpdate": true, + "onBeforeUnmount": true, + "onBeforeUpdate": true, + "onDeactivated": true, + "onErrorCaptured": true, + "onMounted": true, + "onRenderTracked": true, + "onRenderTriggered": true, + "onScopeDispose": true, + "onServerPrefetch": true, + "onUnmounted": true, + "onUpdated": true, + "progressClose": true, + "progressStart": true, + "provide": true, + "reactive": true, + "readonly": true, + "ref": true, + "resetRouter": true, + "resetState": true, + "resizeHandler": true, + "resolveComponent": true, + "resolveDirective": true, + "rolesPermission": true, + "routeInfo": true, + "routerBack": true, + "routerPush": true, + "routerReplace": true, + "searchUser": true, + "shallowReactive": true, + "shallowReadonly": true, + "shallowRef": true, + "sleepTimeout": true, + "storeToRefs": true, + "toRaw": true, + "toRef": true, + "toRefs": true, + "transactionList": true, + "triggerRef": true, + "unref": true, + "useAttrs": true, + "useBasicStore": true, + "useConfigStore": true, + "useCssModule": true, + "useCssVars": true, + "useElement": true, + "useErrorLog": true, + "useLink": true, + "useRoute": true, + "useRouter": true, + "useSlots": true, + "useTable": true, + "useTagsViewStore": true, + "userInfoReq": true, + "watch": true, + "watchEffect": true, + "watchPostEffect": true, + "watchSyncEffect": true, + "watermark": true, + "waves": true + } +} \ No newline at end of file diff --git a/eslintrc/eslint-config.js b/eslintrc/eslint-config.js new file mode 100644 index 0000000..34b37f7 --- /dev/null +++ b/eslintrc/eslint-config.js @@ -0,0 +1,200 @@ +// eslint-disable-next-line @typescript-eslint/no-var-requires +const { defineConfig } = require('eslint-define-config') +module.exports = defineConfig({ + env: { + es6: true, + browser: true, + node: true + }, + globals: { + defineOptions: true, + $ref: true + }, + plugins: ['@typescript-eslint', 'prettier', 'unicorn'], + extends: [ + 'eslint:recommended', + 'plugin:import/recommended', + 'plugin:eslint-comments/recommended', + 'plugin:jsonc/recommended-with-jsonc', + 'plugin:markdown/recommended', + 'plugin:vue/vue3-recommended', + 'plugin:@typescript-eslint/recommended', + 'prettier' + ], + settings: { + 'import/resolver': { + node: { extensions: ['.js', '.mjs', '.ts', '.d.ts', '.tsx'] } + } + }, + overrides: [ + { + files: ['*.ts', '*.vue'], + rules: { + 'no-undef': 'off', + '@typescript-eslint/ban-types': 'off' + } + }, + { + files: ['*.js'], + rules: { + '@typescript-eslint/no-var-requires': 'off' + } + }, + { + files: ['*.vue'], + parser: 'vue-eslint-parser', + parserOptions: { + parser: '@typescript-eslint/parser', + extraFileExtensions: ['.vue'], + ecmaVersion: 'latest', + ecmaFeatures: { + jsx: true + } + }, + rules: { + 'no-undef': 'off', + '@typescript-eslint/no-unused-vars': 'off', + '@typescript-eslint/no-empty-function': 'off' + } + } + ], + rules: { + // js/ts + camelcase: ['error', { properties: 'never' }], + 'no-console': ['warn', { allow: ['error'] }], + 'no-debugger': 'warn', + 'no-constant-condition': ['error', { checkLoops: false }], + 'no-restricted-syntax': ['error', 'LabeledStatement', 'WithStatement'], + 'no-return-await': 'error', + 'no-var': 'error', + 'no-empty': ['error', { allowEmptyCatch: true }], + 'prefer-const': ['warn', { destructuring: 'all', ignoreReadBeforeAssign: true }], + 'prefer-arrow-callback': ['error', { allowNamedFunctions: false, allowUnboundThis: true }], + 'object-shorthand': ['error', 'always', { ignoreConstructors: false, avoidQuotes: true }], + 'prefer-rest-params': 'error', + 'prefer-spread': 'error', + 'prefer-template': 'error', + + 'no-redeclare': 'off', + '@typescript-eslint/no-redeclare': 'error', + // best-practice + 'array-callback-return': 'error', + 'block-scoped-var': 'error', + 'no-alert': 'warn', + 'no-case-declarations': 'error', + 'no-multi-str': 'error', + 'no-with': 'error', + 'no-void': 'error', + + 'sort-imports': [ + 'warn', + { + ignoreCase: false, + ignoreDeclarationSort: true, + ignoreMemberSort: false, + memberSyntaxSortOrder: ['none', 'all', 'multiple', 'single'], + allowSeparatedGroups: false + } + ], + // stylistic-issues + 'prefer-exponentiation-operator': 'error', + + // ts + '@typescript-eslint/explicit-module-boundary-types': 'off', + '@typescript-eslint/no-explicit-any': 'off', + '@typescript-eslint/no-non-null-assertion': 'off', + '@typescript-eslint/no-non-null-asserted-optional-chain': 'off', + '@typescript-eslint/consistent-type-imports': ['error', { disallowTypeAnnotations: false }], + '@typescript-eslint/ban-ts-comment': ['off', { 'ts-ignore': false }], + '@typescript-eslint/no-empty-function': 'off', + // vue + 'vue/no-v-html': 'off', + 'vue/require-default-prop': 'off', + 'vue/require-explicit-emits': 'off', + 'vue/multi-word-component-names': 'off', + 'vue/prefer-import-from-vue': 'off', + 'vue/no-v-text-v-html-on-component': 'off', + 'vue/html-self-closing': [ + 'error', + { + html: { + void: 'always', + normal: 'always', + component: 'always' + }, + svg: 'always', + math: 'always' + } + ], + + // prettier + //fix lf error + 'prettier/prettier': 'off', + // import + // 'import/first': 'error', + // 'import/no-duplicates': 'error', + // 'import/order': [ + // 'error', + // { + // groups: ['builtin', 'external', 'internal', 'parent', 'sibling', 'index', 'object', 'type'], + // + // pathGroups: [ + // { + // pattern: 'vue', + // group: 'external', + // position: 'before' + // } + // ], + // pathGroupsExcludedImportTypes: ['type'] + // } + // ], + 'import/no-unresolved': 'off', + 'import/namespace': 'off', + 'import/default': 'off', + 'import/no-named-as-default': 'off', + 'import/no-named-as-default-member': 'off', + 'import/named': 'off', + + // eslint-plugin-eslint-comments + 'eslint-comments/disable-enable-pair': ['error', { allowWholeFile: true }], + + // unicorn + 'unicorn/custom-error-definition': 'error', + 'unicorn/error-message': 'error', + 'unicorn/escape-case': 'error', + 'unicorn/import-index': 'error', + 'unicorn/new-for-builtins': 'error', + 'unicorn/no-array-method-this-argument': 'error', + 'unicorn/no-array-push-push': 'error', + 'unicorn/no-console-spaces': 'error', + 'unicorn/no-for-loop': 'error', + 'unicorn/no-hex-escape': 'error', + 'unicorn/no-instanceof-array': 'error', + 'unicorn/no-invalid-remove-event-listener': 'error', + 'unicorn/no-new-array': 'error', + 'unicorn/no-new-buffer': 'error', + 'unicorn/no-unsafe-regex': 'off', + 'unicorn/number-literal-case': 'error', + 'unicorn/prefer-array-find': 'error', + 'unicorn/prefer-array-flat-map': 'error', + 'unicorn/prefer-array-index-of': 'error', + 'unicorn/prefer-array-some': 'error', + 'unicorn/prefer-date-now': 'error', + 'unicorn/prefer-dom-node-dataset': 'error', + 'unicorn/prefer-includes': 'error', + 'unicorn/prefer-keyboard-event-key': 'error', + 'unicorn/prefer-math-trunc': 'error', + 'unicorn/prefer-modern-dom-apis': 'error', + 'unicorn/prefer-negative-index': 'error', + 'unicorn/prefer-number-properties': 'error', + 'unicorn/prefer-optional-catch-binding': 'error', + 'unicorn/prefer-prototype-methods': 'error', + 'unicorn/prefer-query-selector': 'error', + 'unicorn/prefer-reflect-apply': 'error', + 'unicorn/prefer-string-slice': 'error', + 'unicorn/prefer-string-starts-ends-with': 'error', + 'unicorn/prefer-string-trim-start-end': 'error', + 'unicorn/prefer-type-error': 'error', + 'unicorn/throw-new-error': 'error' + } +}) diff --git a/index.html b/index.html new file mode 100644 index 0000000..b8226ee --- /dev/null +++ b/index.html @@ -0,0 +1,13 @@ + + +
+ + + +8A;#V^6uYJ({0gyN?XcFY^9ls=`BTESH;Vm4
z$~ZzDWmzXHqV>>HP4nNEHK*+;T07b(T)t2!_DxM$pPPc6*Z)}SUXK0WyV&$R!MfdW
zY*|Yw{{5*Wd@1y~1ACg<*cDE}HtGZHz<$Ng_czX0U^g^_@|$b#DsQ{9Qz`RQzttX(
ztk0IEo)2ILzEgHimTjKav1QwZeZ+BW+*V=#)ld60c-waeTfWv%@j+JHnXB8+ZTP!v
zzLmdhhb;Rc+1e9d<8OQhr(rJ DnV9{NSJiTz4vxm Jc?NH
z2Fc3OT7&WWYx%^K+lZ43n~g$70fF&BR$GzsRZ?y+zu|s{x4b!0e~*4(yhdE=fc1c0
zzQ#AdnvF~)Hx1;YEO&-%;9Bw*+#65%TcSux49zvnK9&>T$=8o5TdX^d-2C30?o_7M
zXS8+}f5Z|-2P&Q8eznn)y(=5j_nYDhcJ%Fu90}{LQZCN_20{aKl0C?UdYnJWQPbK$
z(ZZ7=b4MEtwsJ}*w
q#-5t{Gu-&uP4ivAJ194&Jgl
zpSS_h$6Q>)1Mvr6i(HRSZJ7Nh@Fsj)A3P@`YJ65nUz?-PW7SQhAv`DvGY!{l9%})d
zm2O@Z97j2J+pffrNu4ETE*7O{{pQuya9JsxlwH%^1AoiLX8#SrsuxMo-Vyi|iqYx0
zGL`t-QJ;+CnuNFm!}4ZL-QAsxEM3<%5w?Yl+;7KBzsF~J3QNN_S#nx8Fe!fg8lEh@
zJVTO96B#;%$?7rRhBCp@`bu%@VyOUuKCD}k<-VdKzzNgaS1I#zSM*M%58-NEP>;44
z4T~2v2?RCxZ`?zXra?Af0pi0p8l$ncMh4v<^hgR(h=#~*SUI4vA;H*CH#mxuV<(f!
z+B)CTA0n8q-al*mH6|3FIjhA2rugUP%J09%r(bwW9$KdVUEHX)P4xpZu5H#f4^fv_
zE;XpH0nH@8NY;psCE(xs^mWFJl37~=$JPvkmaNSd#Z|sQbo$l&KPz=!9oJFYuwUPq
zVpX|<L7R9+6|7|xuUu{0o)*f&1Z<5|l
zE=8R<&6xcQoufd9AFS(e;FmkGcunp1Q+dv20r!@Ml{^iDVBO7MVQ(uD4fR!8Wyibh
zS}-!(S`(`w2oG3cZ)P8$sP-{u1Jn}YPf;Owe_-4SFWKu6qUKyJ{^FokcX=2bIzK;D
zY>&`arcnuY!|NpkDCCG}aX