fix(i18n): 补齐九语翻译并修复国际化检查
补齐历史缺译并统一整句插值。九语覆盖 100%,静态检查及 713 项单测通过。
This commit is contained in:
@@ -17,6 +17,7 @@ along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
For commercial licensing, please contact support@quantumnous.com
|
||||
*/
|
||||
|
||||
import { I18N_TECHNICAL_TEXT } from '../../../i18n/technicalText.js';
|
||||
import { useEffectEvent } from '../../../hooks/common/useEffectEvent';
|
||||
import React, { useState, useEffect, useRef } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
@@ -248,7 +249,9 @@ const VideoTutorial = () => {
|
||||
<div className='video-tips'>
|
||||
<Card className='video-tips-card'>
|
||||
<div className='video-tips-content'>
|
||||
<span className='video-tips-icon'>💡</span>
|
||||
<span className='video-tips-icon'>
|
||||
{I18N_TECHNICAL_TEXT.TIP_ICON}
|
||||
</span>
|
||||
<div>
|
||||
<Text strong>{t('观看提示')}</Text>
|
||||
<Paragraph
|
||||
|
||||
@@ -17,6 +17,8 @@ along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
For commercial licensing, please contact support@quantumnous.com
|
||||
*/
|
||||
|
||||
import { Trans } from 'react-i18next';
|
||||
import { I18N_TECHNICAL_TEXT } from '../../i18n/technicalText.js';
|
||||
import { writeClipboardText } from '../../helpers/clipboard';
|
||||
import React, { useState, useContext, useRef } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
@@ -200,7 +202,9 @@ const Tutorial = () => {
|
||||
|
||||
<Card className='tutorial-card tutorial-warning-card'>
|
||||
<div className='tutorial-warning-content'>
|
||||
<div className='tutorial-warning-icon'>⚠️</div>
|
||||
<div className='tutorial-warning-icon'>
|
||||
{I18N_TECHNICAL_TEXT.WARNING_ICON}
|
||||
</div>
|
||||
<div>
|
||||
<Text strong>{t('重要提示')}</Text>
|
||||
<Paragraph
|
||||
@@ -258,11 +262,18 @@ const Tutorial = () => {
|
||||
<div className='tutorial-step-item'>
|
||||
<span className='tutorial-step-number'>1</span>
|
||||
<span>
|
||||
{t('在')}
|
||||
<Link to='/user-center/key-management' className='tutorial-link'>
|
||||
「{t('密钥管理')}」
|
||||
</Link>
|
||||
{t('页面找到刚创建的密钥')}
|
||||
<Trans
|
||||
t={t}
|
||||
i18nKey='在<part0>「密钥管理」</part0>页面找到刚创建的密钥'
|
||||
components={{
|
||||
part0: (
|
||||
<Link
|
||||
to='/user-center/key-management'
|
||||
className='tutorial-link'
|
||||
/>
|
||||
),
|
||||
}}
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
<div className='tutorial-step-item'>
|
||||
@@ -278,7 +289,9 @@ const Tutorial = () => {
|
||||
|
||||
<Card className='tutorial-card tutorial-tip-card'>
|
||||
<div className='tutorial-tip-content'>
|
||||
<div className='tutorial-tip-icon'>💡</div>
|
||||
<div className='tutorial-tip-icon'>
|
||||
{I18N_TECHNICAL_TEXT.TIP_ICON}
|
||||
</div>
|
||||
<div>
|
||||
<Text strong>{t('小提示')}</Text>
|
||||
<Paragraph
|
||||
@@ -330,14 +343,18 @@ const Tutorial = () => {
|
||||
<div className='tutorial-step-item'>
|
||||
<span className='tutorial-step-number'>1</span>
|
||||
<span>
|
||||
{t('点击页面右上角的')}
|
||||
<Link
|
||||
to='/recharge'
|
||||
className='tutorial-link tutorial-link-orange'
|
||||
>
|
||||
「{t('充值')}」
|
||||
</Link>
|
||||
{t('按钮')}
|
||||
<Trans
|
||||
t={t}
|
||||
i18nKey='点击页面右上角的<part0>「充值」</part0>按钮'
|
||||
components={{
|
||||
part0: (
|
||||
<Link
|
||||
to='/recharge'
|
||||
className='tutorial-link tutorial-link-orange'
|
||||
/>
|
||||
),
|
||||
}}
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
<div className='tutorial-step-item'>
|
||||
@@ -353,7 +370,9 @@ const Tutorial = () => {
|
||||
|
||||
<Card className='tutorial-card tutorial-info-card'>
|
||||
<div className='tutorial-info-content'>
|
||||
<div className='tutorial-info-icon'>💰</div>
|
||||
<div className='tutorial-info-icon'>
|
||||
{I18N_TECHNICAL_TEXT.MONEY_ICON}
|
||||
</div>
|
||||
<div>
|
||||
<Text strong>{t('计费说明')}</Text>
|
||||
<Paragraph
|
||||
@@ -432,7 +451,11 @@ const Tutorial = () => {
|
||||
className='tutorial-os-tabs'
|
||||
>
|
||||
<TabPane
|
||||
tab={<span className='tutorial-tab-label'>🪟 Windows</span>}
|
||||
tab={
|
||||
<span className='tutorial-tab-label'>
|
||||
{I18N_TECHNICAL_TEXT.WINDOWS_PLATFORM}
|
||||
</span>
|
||||
}
|
||||
itemKey='windows'
|
||||
>
|
||||
<div className='tutorial-tab-content'>
|
||||
@@ -454,7 +477,11 @@ const Tutorial = () => {
|
||||
</TabPane>
|
||||
|
||||
<TabPane
|
||||
tab={<span className='tutorial-tab-label'>🍎 macOS</span>}
|
||||
tab={
|
||||
<span className='tutorial-tab-label'>
|
||||
{I18N_TECHNICAL_TEXT.MACOS_PLATFORM}
|
||||
</span>
|
||||
}
|
||||
itemKey='macos'
|
||||
>
|
||||
<div className='tutorial-tab-content'>
|
||||
@@ -476,7 +503,11 @@ source ~/.zshrc`,
|
||||
</TabPane>
|
||||
|
||||
<TabPane
|
||||
tab={<span className='tutorial-tab-label'>🐧 Linux</span>}
|
||||
tab={
|
||||
<span className='tutorial-tab-label'>
|
||||
{I18N_TECHNICAL_TEXT.LINUX_PLATFORM}
|
||||
</span>
|
||||
}
|
||||
itemKey='linux'
|
||||
>
|
||||
<div className='tutorial-tab-content'>
|
||||
@@ -548,7 +579,9 @@ source ~/.bashrc`,
|
||||
</div>
|
||||
|
||||
<div className='tutorial-completion-card'>
|
||||
<div className='tutorial-completion-icon'>🎉</div>
|
||||
<div className='tutorial-completion-icon'>
|
||||
{I18N_TECHNICAL_TEXT.CELEBRATION_ICON}
|
||||
</div>
|
||||
<Title heading={4}>{t('准备就绪!')}</Title>
|
||||
<Paragraph>
|
||||
{t('您已经完成了所有配置,现在可以开始使用 AI 服务了')}
|
||||
@@ -582,7 +615,9 @@ source ~/.bashrc`,
|
||||
to='/market'
|
||||
className='tutorial-explore-card tutorial-explore-card-purple'
|
||||
>
|
||||
<div className='tutorial-explore-icon'>💎</div>
|
||||
<div className='tutorial-explore-icon'>
|
||||
{I18N_TECHNICAL_TEXT.DIAMOND_ICON}
|
||||
</div>
|
||||
<div className='tutorial-explore-content'>
|
||||
<Text strong>{t('模型超市')}</Text>
|
||||
<Paragraph type='secondary' style={{ marginBottom: 0 }}>
|
||||
@@ -598,7 +633,9 @@ source ~/.bashrc`,
|
||||
rel='noopener noreferrer'
|
||||
className='tutorial-explore-card tutorial-explore-card-blue'
|
||||
>
|
||||
<div className='tutorial-explore-icon'>📚</div>
|
||||
<div className='tutorial-explore-icon'>
|
||||
{I18N_TECHNICAL_TEXT.BOOKS_ICON}
|
||||
</div>
|
||||
<div className='tutorial-explore-content'>
|
||||
<Text strong>{t('使用文档')}</Text>
|
||||
<Paragraph type='secondary' style={{ marginBottom: 0 }}>
|
||||
@@ -612,7 +649,9 @@ source ~/.bashrc`,
|
||||
to='/experience-center'
|
||||
className='tutorial-explore-card tutorial-explore-card-green'
|
||||
>
|
||||
<div className='tutorial-explore-icon'>🎮</div>
|
||||
<div className='tutorial-explore-icon'>
|
||||
{I18N_TECHNICAL_TEXT.GAME_ICON}
|
||||
</div>
|
||||
<div className='tutorial-explore-content'>
|
||||
<Text strong>{t('体验中心')}</Text>
|
||||
<Paragraph type='secondary' style={{ marginBottom: 0 }}>
|
||||
@@ -626,7 +665,9 @@ source ~/.bashrc`,
|
||||
to='/user-center'
|
||||
className='tutorial-explore-card tutorial-explore-card-orange'
|
||||
>
|
||||
<div className='tutorial-explore-icon'>📊</div>
|
||||
<div className='tutorial-explore-icon'>
|
||||
{I18N_TECHNICAL_TEXT.CHART_ICON}
|
||||
</div>
|
||||
<div className='tutorial-explore-content'>
|
||||
<Text strong>{t('用户中心')}</Text>
|
||||
<Paragraph type='secondary' style={{ marginBottom: 0 }}>
|
||||
@@ -741,7 +782,9 @@ source ~/.bashrc`,
|
||||
|
||||
{/* 底部完成提示 */}
|
||||
<div className='tutorial-scroll-end'>
|
||||
<div className='tutorial-scroll-end-icon'>🎉</div>
|
||||
<div className='tutorial-scroll-end-icon'>
|
||||
{I18N_TECHNICAL_TEXT.CELEBRATION_ICON}
|
||||
</div>
|
||||
<Paragraph type='secondary'>
|
||||
{t('恭喜!您已浏览完所有教程内容')}
|
||||
</Paragraph>
|
||||
|
||||
Reference in New Issue
Block a user