diff --git a/web/app/components/app/configuration/config-prompt/conversation-histroy/history-panel.tsx b/web/app/components/app/configuration/config-prompt/conversation-histroy/history-panel.tsx index c5c54db73..ec6d20a59 100644 --- a/web/app/components/app/configuration/config-prompt/conversation-histroy/history-panel.tsx +++ b/web/app/components/app/configuration/config-prompt/conversation-histroy/history-panel.tsx @@ -1,10 +1,12 @@ 'use client' import type { FC } from 'react' import React from 'react' +import { useContext } from 'use-context-selector' import { useTranslation } from 'react-i18next' import OperationBtn from '@/app/components/app/configuration/base/operation-btn' import Panel from '@/app/components/app/configuration/base/feature-panel' import { MessageClockCircle } from '@/app/components/base/icons/src/vender/solid/general' +import I18n from '@/context/i18n' type Props = { showWarning: boolean @@ -16,6 +18,7 @@ const HistoryPanel: FC = ({ onShowEditModal, }) => { const { t } = useTranslation() + const { locale } = useContext(I18n) return ( = ({ > {showWarning && (
- {/*
{t('appDebug.feature.conversationHistory.tip')} {t('appDebug.feature.conversationHistory.learnMore')}
*/} -
{t('appDebug.feature.conversationHistory.tip')}
+
{t('appDebug.feature.conversationHistory.tip')} {t('appDebug.feature.conversationHistory.learnMore')}
)}
diff --git a/web/app/components/app/configuration/prompt-mode/advanced-mode-waring.tsx b/web/app/components/app/configuration/prompt-mode/advanced-mode-waring.tsx index 8684dbab3..0a794dcd8 100644 --- a/web/app/components/app/configuration/prompt-mode/advanced-mode-waring.tsx +++ b/web/app/components/app/configuration/prompt-mode/advanced-mode-waring.tsx @@ -2,9 +2,12 @@ import type { FC } from 'react' import React from 'react' import { useTranslation } from 'react-i18next' +import { useContext } from 'use-context-selector' +import I18n from '@/context/i18n' const AdvancedModeWarning: FC = () => { const { t } = useTranslation() + const { locale } = useContext(I18n) const [show, setShow] = React.useState(true) if (!show) return null @@ -14,14 +17,13 @@ const AdvancedModeWarning: FC = () => {
{t('appDebug.promptMode.advancedWarning.description')} - {/* TODO: Doc link */} - {/* {t('appDebug.promptMode.advancedWarning.learnMore')} - */} +