Эх сурвалжийг харах

fix: fixed spelling 'ElememtPlusSzie'

jinyang 3 жил өмнө
parent
commit
5dbbc60864

+ 1 - 1
src/components/ConfigGlobal/src/ConfigGlobal.vue

@@ -13,7 +13,7 @@ const { variables } = useDesign()
 const appStore = useAppStore()
 
 const props = defineProps({
-  size: propTypes.oneOf<ElememtPlusSzie[]>(['default', 'small', 'large']).def('default')
+  size: propTypes.oneOf<ElememtPlusSize[]>(['default', 'small', 'large']).def('default')
 })
 
 provide('configGlobal', props)

+ 1 - 1
src/components/SizeDropdown/src/SizeDropdown.vue

@@ -20,7 +20,7 @@ const appStore = useAppStore()
 
 const sizeMap = computed(() => appStore.sizeMap)
 
-const setCurrentSize = (size: ElememtPlusSzie) => {
+const setCurrentSize = (size: ElememtPlusSize) => {
   appStore.setCurrentSize(size)
 }
 </script>

+ 2 - 2
src/config/app.ts

@@ -39,8 +39,8 @@ export interface AppState {
   title: string
   userInfo: string
   isDark: boolean
-  currentSize: ElememtPlusSzie
-  sizeMap: ElememtPlusSzie[]
+  currentSize: ElememtPlusSize
+  sizeMap: ElememtPlusSize[]
   mobile: boolean
   footer: boolean
   theme: ThemeTypes

+ 3 - 3
src/store/modules/app.ts

@@ -69,10 +69,10 @@ export const useAppStore = defineStore({
     getIsDark(): boolean {
       return this.isDark
     },
-    getCurrentSize(): ElememtPlusSzie {
+    getCurrentSize(): ElememtPlusSize {
       return this.currentSize
     },
-    getSizeMap(): ElememtPlusSzie[] {
+    getSizeMap(): ElememtPlusSize[] {
       return this.sizeMap
     },
     getMobile(): boolean {
@@ -150,7 +150,7 @@ export const useAppStore = defineStore({
       }
       wsCache.set('isDark', this.isDark)
     },
-    setCurrentSize(currentSize: ElememtPlusSzie) {
+    setCurrentSize(currentSize: ElememtPlusSize) {
       this.currentSize = currentSize
       wsCache.set('currentSize', this.currentSize)
     },

+ 1 - 1
types/componentType/configGlobal.d.ts

@@ -1,3 +1,3 @@
 declare interface ConfigGlobalTypes {
-  size?: ElememtPlusSzie
+  size?: ElememtPlusSize
 }

+ 1 - 1
types/global.d.ts

@@ -6,7 +6,7 @@ declare type Nullable<T> = T | null
 
 declare type ElRef<T extends HTMLElement = HTMLDivElement> = Nullable<T>
 
-declare type ElememtPlusSzie = 'default' | 'small' | 'large'
+declare type ElememtPlusSize = 'default' | 'small' | 'large'
 
 declare type ElementPlusInfoType = 'success' | 'info' | 'warning' | 'danger'