2
0

feat: 统一修改系统名

This commit is contained in:
caiyuchao
2025-06-18 17:58:15 +08:00
parent e8c98e77d3
commit c96e307060
6 changed files with 21 additions and 6 deletions

2
.env
View File

@@ -1,6 +1,6 @@
VITE_BASE_URL=/
VITE_APP_TITLE="WANFi Platform"
VITE_APP_TITLE="Platform"
# the prefix of the icon name
VITE_ICON_PREFIX=icon

View File

@@ -4,6 +4,8 @@
<meta charset="UTF-8" />
<link rel="icon" href="/favicon.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<script src="/langs/zh-cn.js"></script>
<script src="/langs/en-us.js"></script>
<title>%VITE_APP_TITLE%</title>
</head>
<body>

5
public/langs/en-us.js Normal file
View File

@@ -0,0 +1,5 @@
const enUS = {
system: {
title: 'MacroHub'
}
};

5
public/langs/zh-cn.js Normal file
View File

@@ -0,0 +1,5 @@
const zhCN = {
system: {
title: 'MacroHub'
}
};

View File

@@ -1,9 +1,12 @@
import zhCN from './langs/zh-cn';
import enUS from './langs/en-us';
import localeZhCN from './langs/zh-cn';
import localeEnUS from './langs/en-us';
const fullZhCN = { ...localeZhCN, ...zhCN };
const fullEnUS = { ...localeEnUS, ...enUS };
const locales: Record<App.I18n.LangType, App.I18n.Schema> = {
'zh-CN': zhCN,
'en-US': enUS
'zh-CN': fullZhCN,
'en-US': fullEnUS
};
export default locales;

View File

@@ -62,7 +62,7 @@ const bgColor = computed(() => {
</header>
<main>
<div class="flex justify-between items-center">
<h3 class="text-28px text-primary font-500 lt-sm:text-22px">{{ "WANFi" }}</h3>
<h3 class="text-28px text-primary font-500 lt-sm:text-22px">{{ $t('system.title') }}</h3>
<LangSwitch :lang="appStore.locale" :lang-options="appStore.localeOptions" @change-lang="appStore.changeLocale" />
</div>
<div class="animation-slide-in-left">