feat(Help): switch to the Chinese page when using Chinese (#3567)
This commit is contained in:
parent
3d1f73fcaf
commit
4373e6da88
@ -16,6 +16,9 @@ const SettingsMenu: React.FC<{
|
||||
const data = useCurrentAppInfo();
|
||||
const { token } = useToken();
|
||||
|
||||
// 是否是简体中文
|
||||
const isSimplifiedChinese = data?.data?.lang === 'zh-CN';
|
||||
|
||||
const items = [
|
||||
{
|
||||
key: 'nocobase',
|
||||
@ -34,7 +37,7 @@ const SettingsMenu: React.FC<{
|
||||
{
|
||||
key: 'homePage',
|
||||
label: (
|
||||
<a href="https://www.nocobase.com" target="__blank">
|
||||
<a href={isSimplifiedChinese ? 'https://cn.nocobase.com/' : 'https://www.nocobase.com'} target="__blank">
|
||||
{t('Home page')}
|
||||
</a>
|
||||
),
|
||||
@ -42,7 +45,14 @@ const SettingsMenu: React.FC<{
|
||||
{
|
||||
key: 'userManual',
|
||||
label: (
|
||||
<a href="https://docs.nocobase.com/manual/quick-start/the-first-app" target="__blank">
|
||||
<a
|
||||
href={
|
||||
isSimplifiedChinese
|
||||
? 'https://docs-cn.nocobase.com/manual/quick-start/the-first-app'
|
||||
: 'https://docs.nocobase.com/manual/quick-start/the-first-app'
|
||||
}
|
||||
target="__blank"
|
||||
>
|
||||
{t('User manual')}
|
||||
</a>
|
||||
),
|
||||
|
Loading…
Reference in New Issue
Block a user