From 2dc7d0e0e157c3d2bba4b67f58cc8196b6441c57 Mon Sep 17 00:00:00 2001 From: "d.malygin" Date: Thu, 22 Aug 2024 10:50:56 +0500 Subject: [PATCH 1/7] fix autoimports --- auto-imports.d.ts | 78 ------------------ components.d.ts | 43 ---------- package.json | 1 + src/app/App.vue | 1 - src/app/auto-imports.d.ts | 142 +++++++++++++++----------------- src/app/components.d.ts | 40 +++++++++ src/modules/BaseSidebarMenu.vue | 2 - src/modules/EntityItem.vue | 10 +-- src/pages/HomePage.vue | 7 +- vite.config.ts | 8 +- yarn.lock | 18 +++- 11 files changed, 133 insertions(+), 217 deletions(-) delete mode 100644 auto-imports.d.ts delete mode 100644 components.d.ts create mode 100644 src/app/components.d.ts diff --git a/auto-imports.d.ts b/auto-imports.d.ts deleted file mode 100644 index 8b9bb34..0000000 --- a/auto-imports.d.ts +++ /dev/null @@ -1,78 +0,0 @@ -/* eslint-disable */ -/* prettier-ignore */ -// @ts-nocheck -// noinspection JSUnusedGlobalSymbols -// Generated by unplugin-auto-import -export {} -declare global { - const EffectScope: typeof import('vue')['EffectScope'] - const [alias]: typeof import('[package-name]')['[from]'] - const axios: typeof import('axios')['default'] - const computed: typeof import('vue')['computed'] - const createApp: typeof import('vue')['createApp'] - const customRef: typeof import('vue')['customRef'] - const defineAsyncComponent: typeof import('vue')['defineAsyncComponent'] - const defineComponent: typeof import('vue')['defineComponent'] - const effectScope: typeof import('vue')['effectScope'] - const getCurrentInstance: typeof import('vue')['getCurrentInstance'] - const getCurrentScope: typeof import('vue')['getCurrentScope'] - const h: typeof import('vue')['h'] - const inject: typeof import('vue')['inject'] - const isProxy: typeof import('vue')['isProxy'] - const isReactive: typeof import('vue')['isReactive'] - const isReadonly: typeof import('vue')['isReadonly'] - const isRef: typeof import('vue')['isRef'] - const markRaw: typeof import('vue')['markRaw'] - const nextTick: typeof import('vue')['nextTick'] - const onActivated: typeof import('vue')['onActivated'] - const onBeforeMount: typeof import('vue')['onBeforeMount'] - const onBeforeRouteLeave: typeof import('vue-router')['onBeforeRouteLeave'] - const onBeforeRouteUpdate: typeof import('vue-router')['onBeforeRouteUpdate'] - const onBeforeUnmount: typeof import('vue')['onBeforeUnmount'] - const onBeforeUpdate: typeof import('vue')['onBeforeUpdate'] - const onDeactivated: typeof import('vue')['onDeactivated'] - const onErrorCaptured: typeof import('vue')['onErrorCaptured'] - const onMounted: typeof import('vue')['onMounted'] - const onRenderTracked: typeof import('vue')['onRenderTracked'] - const onRenderTriggered: typeof import('vue')['onRenderTriggered'] - const onScopeDispose: typeof import('vue')['onScopeDispose'] - const onServerPrefetch: typeof import('vue')['onServerPrefetch'] - const onUnmounted: typeof import('vue')['onUnmounted'] - const onUpdated: typeof import('vue')['onUpdated'] - const provide: typeof import('vue')['provide'] - const reactive: typeof import('vue')['reactive'] - const readonly: typeof import('vue')['readonly'] - const ref: typeof import('vue')['ref'] - const resolveComponent: typeof import('vue')['resolveComponent'] - const shallowReactive: typeof import('vue')['shallowReactive'] - const shallowReadonly: typeof import('vue')['shallowReadonly'] - const shallowRef: typeof import('vue')['shallowRef'] - const toRaw: typeof import('vue')['toRaw'] - const toRef: typeof import('vue')['toRef'] - const toRefs: typeof import('vue')['toRefs'] - const toValue: typeof import('vue')['toValue'] - const triggerRef: typeof import('vue')['triggerRef'] - const unref: typeof import('vue')['unref'] - const useAttrs: typeof import('vue')['useAttrs'] - const useCssModule: typeof import('vue')['useCssModule'] - const useCssVars: typeof import('vue')['useCssVars'] - const useI18n: typeof import('vue-i18n')['useI18n'] - const useLink: typeof import('vue-router')['useLink'] - const useMyFetch: typeof import('@vueuse/core')['useFetch'] - const useRoute: typeof import('vue-router')['useRoute'] - const useRouter: typeof import('vue-router')['useRouter'] - const useSlots: typeof import('vue')['useSlots'] - const watch: typeof import('vue')['watch'] - const watchEffect: typeof import('vue')['watchEffect'] - const watchPostEffect: typeof import('vue')['watchPostEffect'] - const watchSyncEffect: typeof import('vue')['watchSyncEffect'] -} -// for type re-export -declare global { - // @ts-ignore - export type { Component, ComponentPublicInstance, ComputedRef, ExtractDefaultPropTypes, ExtractPropTypes, ExtractPublicPropTypes, InjectionKey, PropType, Ref, VNode, WritableComputedRef } from 'vue' - import('vue') - // @ts-ignore - export type { RouteLocationRaw } from 'vue-router' - import('vue-router') -} diff --git a/components.d.ts b/components.d.ts deleted file mode 100644 index 6a4a099..0000000 --- a/components.d.ts +++ /dev/null @@ -1,43 +0,0 @@ -/* eslint-disable */ -// @ts-nocheck -// Generated by unplugin-vue-components -// Read more: https://github.com/vuejs/core/pull/3399 -export {} - -/* prettier-ignore */ -declare module 'vue' { - export interface GlobalComponents { - Avatar: typeof import('primevue/avatar')['default'] - Button: typeof import('primevue/button')['default'] - CreateEntityMenu: typeof import('./src/components/CreateEntityMenu.vue')['default'] - Dialog: typeof import('primevue/dialog')['default'] - Divider: typeof import('primevue/divider')['default'] - Drawer: typeof import('primevue/drawer')['default'] - ImageItem: typeof import('@/modules/entities/ImageItem.vue')['default'] - ImageMoveMenu: typeof import('./src/components/editEntityMenu/ImageMoveMenu.vue')['default'] - ImagePositionMenu: typeof import('./src/components/editEntityMenu/ImagePositionMenu.vue')['default'] - ImageSizeMenu: typeof import('./src/components/editEntityMenu/ImageSizeMenu.vue')['default'] - ImageStateMenu: typeof import('./src/components/editEntityMenu/ImageStateMenu.vue')['default'] - LogoAndLabel: typeof import('./src/components/LogoAndLabel.vue')['default'] - MoveImageMenu: typeof import('./src/components/editEntityMenu/image/MoveImageMenu.vue')['default'] - MoveMenu: typeof import('./src/components/editEntityMenu/text/MoveMenu.vue')['default'] - MoveTextMenu: typeof import('./src/components/editEntityMenu/text/MoveTextMenu.vue')['default'] - RouterLink: typeof import('vue-router')['RouterLink'] - RouterView: typeof import('vue-router')['RouterView'] - SpeedDial: typeof import('primevue/speeddial')['default'] - Splitter: typeof import('primevue/splitter')['default'] - SplitterPanel: typeof import('primevue/splitterpanel')['default'] - StateImageMenu: typeof import('./src/components/editEntityMenu/image/StateImageMenu.vue')['default'] - StateMenu: typeof import('./src/components/editEntityMenu/text/StateMenu.vue')['default'] - StateTextMenu: typeof import('./src/components/editEntityMenu/text/StateTextMenu.vue')['default'] - TextFontMenu: typeof import('./src/components/editEntityMenu/TextFontMenu.vue')['default'] - TextItem: typeof import('@/modules/entities/TextItem.vue')['default'] - TextMoveMenu: typeof import('./src/components/editEntityMenu/TextMoveMenu.vue')['default'] - TextPositionMenu: typeof import('./src/components/editEntityMenu/TextPositionMenu.vue')['default'] - TextStateMenu: typeof import('./src/components/editEntityMenu/TextStateMenu.vue')['default'] - TextWidthMenu: typeof import('./src/components/editEntityMenu/TextWidthMenu.vue')['default'] - Toast: typeof import('primevue/toast')['default'] - Tree: typeof import('primevue/tree')['default'] - UserInfoHeaderWithSettings: typeof import('./src/components/UserInfoHeaderWithSettings.vue')['default'] - } -} diff --git a/package.json b/package.json index 131c67d..ce74ccc 100644 --- a/package.json +++ b/package.json @@ -43,6 +43,7 @@ "eslint-plugin-vue": "^9.23.0", "npm-run-all2": "^6.2.0", "prettier": "^3.2.5", + "sass": "^1.77.8", "typescript": "~5.4.0", "unplugin-auto-import": "^0.18.2", "unplugin-vue-components": "^0.27.3", diff --git a/src/app/App.vue b/src/app/App.vue index 26bfa00..4198cd4 100644 --- a/src/app/App.vue +++ b/src/app/App.vue @@ -1,6 +1,5 @@ diff --git a/src/app/auto-imports.d.ts b/src/app/auto-imports.d.ts index 07ab7b9..4683175 100644 --- a/src/app/auto-imports.d.ts +++ b/src/app/auto-imports.d.ts @@ -5,85 +5,75 @@ // Generated by unplugin-auto-import export {} declare global { - const EffectScope: (typeof import('vue'))['EffectScope']; - const [alias]: (typeof import('[package-name]'))['[from]']; - const axios: (typeof import('axios'))['default']; - const computed: (typeof import('vue'))['computed']; - const createApp: (typeof import('vue'))['createApp']; - const customRef: (typeof import('vue'))['customRef']; - const defineAsyncComponent: (typeof import('vue'))['defineAsyncComponent']; - const defineComponent: (typeof import('vue'))['defineComponent']; - const effectScope: (typeof import('vue'))['effectScope']; - const getCurrentInstance: (typeof import('vue'))['getCurrentInstance']; - const getCurrentScope: (typeof import('vue'))['getCurrentScope']; - const h: (typeof import('vue'))['h']; - const inject: (typeof import('vue'))['inject']; - const isProxy: (typeof import('vue'))['isProxy']; - const isReactive: (typeof import('vue'))['isReactive']; - const isReadonly: (typeof import('vue'))['isReadonly']; - const isRef: (typeof import('vue'))['isRef']; - const markRaw: (typeof import('vue'))['markRaw']; - const nextTick: (typeof import('vue'))['nextTick']; - const onActivated: (typeof import('vue'))['onActivated']; - const onBeforeMount: (typeof import('vue'))['onBeforeMount']; - const onBeforeRouteLeave: (typeof import('vue-router'))['onBeforeRouteLeave']; - const onBeforeRouteUpdate: (typeof import('vue-router'))['onBeforeRouteUpdate']; - const onBeforeUnmount: (typeof import('vue'))['onBeforeUnmount']; - const onBeforeUpdate: (typeof import('vue'))['onBeforeUpdate']; - const onDeactivated: (typeof import('vue'))['onDeactivated']; - const onErrorCaptured: (typeof import('vue'))['onErrorCaptured']; - const onMounted: (typeof import('vue'))['onMounted']; - const onRenderTracked: (typeof import('vue'))['onRenderTracked']; - const onRenderTriggered: (typeof import('vue'))['onRenderTriggered']; - const onScopeDispose: (typeof import('vue'))['onScopeDispose']; - const onServerPrefetch: (typeof import('vue'))['onServerPrefetch']; - const onUnmounted: (typeof import('vue'))['onUnmounted']; - const onUpdated: (typeof import('vue'))['onUpdated']; - const provide: (typeof import('vue'))['provide']; - const reactive: (typeof import('vue'))['reactive']; - const readonly: (typeof import('vue'))['readonly']; - const ref: (typeof import('vue'))['ref']; - const resolveComponent: (typeof import('vue'))['resolveComponent']; - const shallowReactive: (typeof import('vue'))['shallowReactive']; - const shallowReadonly: (typeof import('vue'))['shallowReadonly']; - const shallowRef: (typeof import('vue'))['shallowRef']; - const toRaw: (typeof import('vue'))['toRaw']; - const toRef: (typeof import('vue'))['toRef']; - const toRefs: (typeof import('vue'))['toRefs']; - const toValue: (typeof import('vue'))['toValue']; - const triggerRef: (typeof import('vue'))['triggerRef']; - const unref: (typeof import('vue'))['unref']; - const useAttrs: (typeof import('vue'))['useAttrs']; - const useCssModule: (typeof import('vue'))['useCssModule']; - const useCssVars: (typeof import('vue'))['useCssVars']; - const useLink: (typeof import('vue-router'))['useLink']; - const useMyFetch: (typeof import('@vueuse/core'))['useFetch']; - const useRoute: (typeof import('vue-router'))['useRoute']; - const useRouter: (typeof import('vue-router'))['useRouter']; - const useSlots: (typeof import('vue'))['useSlots']; - const watch: (typeof import('vue'))['watch']; - const watchEffect: (typeof import('vue'))['watchEffect']; - const watchPostEffect: (typeof import('vue'))['watchPostEffect']; - const watchSyncEffect: (typeof import('vue'))['watchSyncEffect']; + const EffectScope: typeof import('vue')['EffectScope'] + const [alias]: typeof import('[package-name]')['[from]'] + const [import-names]: typeof import('[package-name]')['[import-names]'] + const axios: typeof import('axios')['default'] + const computed: typeof import('vue')['computed'] + const createApp: typeof import('vue')['createApp'] + const customRef: typeof import('vue')['customRef'] + const defineAsyncComponent: typeof import('vue')['defineAsyncComponent'] + const defineComponent: typeof import('vue')['defineComponent'] + const effectScope: typeof import('vue')['effectScope'] + const getCurrentInstance: typeof import('vue')['getCurrentInstance'] + const getCurrentScope: typeof import('vue')['getCurrentScope'] + const h: typeof import('vue')['h'] + const inject: typeof import('vue')['inject'] + const isProxy: typeof import('vue')['isProxy'] + const isReactive: typeof import('vue')['isReactive'] + const isReadonly: typeof import('vue')['isReadonly'] + const isRef: typeof import('vue')['isRef'] + const markRaw: typeof import('vue')['markRaw'] + const nextTick: typeof import('vue')['nextTick'] + const onActivated: typeof import('vue')['onActivated'] + const onBeforeMount: typeof import('vue')['onBeforeMount'] + const onBeforeRouteLeave: typeof import('vue-router')['onBeforeRouteLeave'] + const onBeforeRouteUpdate: typeof import('vue-router')['onBeforeRouteUpdate'] + const onBeforeUnmount: typeof import('vue')['onBeforeUnmount'] + const onBeforeUpdate: typeof import('vue')['onBeforeUpdate'] + const onDeactivated: typeof import('vue')['onDeactivated'] + const onErrorCaptured: typeof import('vue')['onErrorCaptured'] + const onMounted: typeof import('vue')['onMounted'] + const onRenderTracked: typeof import('vue')['onRenderTracked'] + const onRenderTriggered: typeof import('vue')['onRenderTriggered'] + const onScopeDispose: typeof import('vue')['onScopeDispose'] + const onServerPrefetch: typeof import('vue')['onServerPrefetch'] + const onUnmounted: typeof import('vue')['onUnmounted'] + const onUpdated: typeof import('vue')['onUpdated'] + const provide: typeof import('vue')['provide'] + const reactive: typeof import('vue')['reactive'] + const readonly: typeof import('vue')['readonly'] + const ref: typeof import('vue')['ref'] + const resolveComponent: typeof import('vue')['resolveComponent'] + const shallowReactive: typeof import('vue')['shallowReactive'] + const shallowReadonly: typeof import('vue')['shallowReadonly'] + const shallowRef: typeof import('vue')['shallowRef'] + const toRaw: typeof import('vue')['toRaw'] + const toRef: typeof import('vue')['toRef'] + const toRefs: typeof import('vue')['toRefs'] + const toValue: typeof import('vue')['toValue'] + const triggerRef: typeof import('vue')['triggerRef'] + const unref: typeof import('vue')['unref'] + const useAttrs: typeof import('vue')['useAttrs'] + const useCssModule: typeof import('vue')['useCssModule'] + const useCssVars: typeof import('vue')['useCssVars'] + const useI18n: (typeof import('vue-i18n'))['useI18n'] + const useLink: typeof import('vue-router')['useLink'] + const useMyFetch: typeof import('@vueuse/core')['useFetch'] + const useRoute: typeof import('vue-router')['useRoute'] + const useRouter: typeof import('vue-router')['useRouter'] + const useSlots: typeof import('vue')['useSlots'] + const watch: typeof import('vue')['watch'] + const watchEffect: typeof import('vue')['watchEffect'] + const watchPostEffect: typeof import('vue')['watchPostEffect'] + const watchSyncEffect: typeof import('vue')['watchSyncEffect'] } // for type re-export declare global { // @ts-ignore - export type { - Component, - ComponentPublicInstance, - ComputedRef, - ExtractDefaultPropTypes, - ExtractPropTypes, - ExtractPublicPropTypes, - InjectionKey, - PropType, - Ref, - VNode, - WritableComputedRef - } from 'vue'; - import('vue'); + export type { Component, ComponentPublicInstance, ComputedRef, ExtractDefaultPropTypes, ExtractPropTypes, ExtractPublicPropTypes, InjectionKey, PropType, Ref, VNode, WritableComputedRef } from 'vue' + import('vue') // @ts-ignore - export type { RouteLocationRaw } from 'vue-router'; - import('vue-router'); + export type { RouteLocationRaw } from 'vue-router' + import('vue-router') } diff --git a/src/app/components.d.ts b/src/app/components.d.ts new file mode 100644 index 0000000..8180a9b --- /dev/null +++ b/src/app/components.d.ts @@ -0,0 +1,40 @@ +/* eslint-disable */ +// @ts-nocheck +// Generated by unplugin-vue-components +// Read more: https://github.com/vuejs/core/pull/3399 +export {} + +/* prettier-ignore */ +declare module 'vue' { + export interface GlobalComponents { + App: typeof import('./App.vue')['default'] + Avatar: typeof import('primevue/avatar')['default'] + BaseDivider: typeof import('./../shared/BaseDivider.vue')['default'] + BaseSidebarMenu: typeof import('./../modules/BaseSidebarMenu.vue')['default'] + Button: typeof import('primevue/button')['default'] + CreateEntityMenu: typeof import('./../components/CreateEntityMenu.vue')['default'] + CropImageModal: typeof import('./../modules/CropImageModal.vue')['default'] + Dialog: typeof import('primevue/dialog')['default'] + Divider: typeof import('primevue/divider')['default'] + Drawer: typeof import('primevue/drawer')['default'] + EntityItem: typeof import('./../modules/EntityItem.vue')['default'] + HomePage: typeof import('./../pages/HomePage.vue')['default'] + ImageItem: typeof import('./../modules/entities/ImageItem.vue')['default'] + ImagePositionMenu: typeof import('./../components/editEntityMenu/ImagePositionMenu.vue')['default'] + ImageSizeMenu: typeof import('./../components/editEntityMenu/ImageSizeMenu.vue')['default'] + ImageStateMenu: typeof import('./../components/editEntityMenu/ImageStateMenu.vue')['default'] + LogoAndLabel: typeof import('./../components/LogoAndLabel.vue')['default'] + RouterLink: typeof import('vue-router')['RouterLink'] + RouterView: typeof import('vue-router')['RouterView'] + SheetPage: typeof import('./../pages/[uuid]/SheetPage.vue')['default'] + SpeedDial: typeof import('primevue/speeddial')['default'] + Splitter: typeof import('primevue/splitter')['default'] + SplitterPanel: typeof import('primevue/splitterpanel')['default'] + TextFontMenu: typeof import('./../components/editEntityMenu/TextFontMenu.vue')['default'] + TextItem: typeof import('./../modules/entities/TextItem.vue')['default'] + TextPositionMenu: typeof import('./../components/editEntityMenu/TextPositionMenu.vue')['default'] + TextStateMenu: typeof import('./../components/editEntityMenu/TextStateMenu.vue')['default'] + Tree: typeof import('primevue/tree')['default'] + UserInfoHeaderWithSettings: typeof import('./../components/UserInfoHeaderWithSettings.vue')['default'] + } +} diff --git a/src/modules/BaseSidebarMenu.vue b/src/modules/BaseSidebarMenu.vue index cc67cb5..162f8a5 100644 --- a/src/modules/BaseSidebarMenu.vue +++ b/src/modules/BaseSidebarMenu.vue @@ -1,7 +1,5 @@