-
-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat: layout i18n * refactor: add alternate urls
- Loading branch information
Showing
10 changed files
with
111 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
export const en = Object.freeze({ | ||
general: { | ||
share: 'Share', | ||
}, | ||
site: { | ||
description: 'Auth Wiki is a comprehensive collection of articles, tutorials, and resources about authentication and authorization. Learn about OAuth 2.0, OpenID Connect, SAML, and more.', | ||
}, | ||
home: { | ||
description: 'Explore and find clear definitions of key glossaries related to authentication, authorization, and identity management. Work with open-standards like <a href="/openid-connect">OpenID Connect</a>, <a href="/oauth-2.0">OAuth 2.0</a>, and <a href="/saml">SAML</a>.' | ||
}, | ||
content: { | ||
edit_on_github: 'Edit on GitHub', | ||
table_of_contents: 'Table of Contents', | ||
see_also: 'See also', | ||
resources_and_references: 'Resources and references', | ||
} | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
export * from './en'; | ||
export * from './zh'; | ||
|
||
import { en } from './en'; | ||
import { zh } from './zh'; | ||
|
||
export const getPhrases = (locale: string) => { | ||
switch (locale) { | ||
case 'zh': | ||
return zh; | ||
case 'en': | ||
return en; | ||
default: | ||
throw new Error(`Unsupported locale: ${locale}`); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
export const zh = Object.freeze({ | ||
general: { | ||
share: '分享', | ||
}, | ||
site: { | ||
description: 'Auth Wiki 是一个关于身份验证和授权的全面文章、教程和资源集合。了解 OAuth 2.0、OpenID Connect、SAML 等内容。' | ||
}, | ||
home: { | ||
description: '探索并找到与身份验证、授权和身份管理相关的关键术语的清晰定义。使用诸如 <a href="/openid-connect">OpenID Connect</a>、<a href="/oauth-2.0">OAuth 2.0</a> 和 <a href="/saml">SAML</a> 等开放标准。' | ||
}, | ||
content: { | ||
edit_on_github: '在 GitHub 上编辑', | ||
table_of_contents: '目录', | ||
see_also: '另请参阅', | ||
resources_and_references: '资源和参考', | ||
} | ||
}); |