mirror of
https://gitee.com/dromara/go-view.git
synced 2026-04-23 00:00:12 +08:00
fix: 修改文件建构
This commit is contained in:
@@ -0,0 +1,3 @@
|
||||
import GoLangSelect from './index.vue';
|
||||
|
||||
export { GoLangSelect };
|
||||
@@ -0,0 +1,29 @@
|
||||
<template>
|
||||
<n-dropdown
|
||||
trigger="hover"
|
||||
@select="handleSelect"
|
||||
:show-arrow="true"
|
||||
:options="options"
|
||||
>
|
||||
<n-button quaternary>
|
||||
<n-icon size="20" :depth="1">
|
||||
<language-icon></language-icon>
|
||||
</n-icon>
|
||||
</n-button>
|
||||
</n-dropdown>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { useLangStore } from '@/store/modules/langStore/langStore'
|
||||
import { langList } from '@/i18n/index'
|
||||
import { LangEnum } from '@/enums/styleEnum'
|
||||
import { icon } from '@/plugins'
|
||||
|
||||
const { LanguageIcon } = icon.ionicons5
|
||||
const langStore = useLangStore()
|
||||
const options = langList
|
||||
|
||||
const handleSelect = (key: LangEnum) => {
|
||||
langStore.changeLang(key)
|
||||
}
|
||||
</script>
|
||||
Reference in New Issue
Block a user