From 8aca4f412935a2fb330aac76472a24d82d4f71b3 Mon Sep 17 00:00:00 2001 From: Joel Date: Thu, 25 Jun 2026 10:42:33 +0800 Subject: [PATCH] chore: some tooltips --- .../advanced/content-moderation.tsx | 2 -- .../components/orchestrate/advanced/env.tsx | 3 ++- .../orchestrate/common/tip-content.tsx | 16 +++++++++++++- .../configure/components/preview/header.tsx | 22 ++++++++++++++++++- web/i18n/ar-TN/agent-v-2.json | 7 +++++- web/i18n/de-DE/agent-v-2.json | 7 +++++- web/i18n/en-US/agent-v-2.json | 7 +++++- web/i18n/es-ES/agent-v-2.json | 7 +++++- web/i18n/fa-IR/agent-v-2.json | 7 +++++- web/i18n/fr-FR/agent-v-2.json | 7 +++++- web/i18n/hi-IN/agent-v-2.json | 7 +++++- web/i18n/id-ID/agent-v-2.json | 7 +++++- web/i18n/it-IT/agent-v-2.json | 7 +++++- web/i18n/ja-JP/agent-v-2.json | 7 +++++- web/i18n/ko-KR/agent-v-2.json | 7 +++++- web/i18n/nl-NL/agent-v-2.json | 7 +++++- web/i18n/pl-PL/agent-v-2.json | 7 +++++- web/i18n/pt-BR/agent-v-2.json | 7 +++++- web/i18n/ro-RO/agent-v-2.json | 7 +++++- web/i18n/ru-RU/agent-v-2.json | 7 +++++- web/i18n/sl-SI/agent-v-2.json | 7 +++++- web/i18n/th-TH/agent-v-2.json | 7 +++++- web/i18n/tr-TR/agent-v-2.json | 7 +++++- web/i18n/uk-UA/agent-v-2.json | 7 +++++- web/i18n/vi-VN/agent-v-2.json | 7 +++++- web/i18n/zh-Hans/agent-v-2.json | 7 +++++- web/i18n/zh-Hant/agent-v-2.json | 7 +++++- 27 files changed, 176 insertions(+), 28 deletions(-) diff --git a/web/features/agent-v2/agent-detail/configure/components/orchestrate/advanced/content-moderation.tsx b/web/features/agent-v2/agent-detail/configure/components/orchestrate/advanced/content-moderation.tsx index 7a5578fbff1..57c1ec9d543 100644 --- a/web/features/agent-v2/agent-detail/configure/components/orchestrate/advanced/content-moderation.tsx +++ b/web/features/agent-v2/agent-detail/configure/components/orchestrate/advanced/content-moderation.tsx @@ -109,8 +109,6 @@ function AgentContentModerationSettingsContent() { labelId="agent-configure-content-moderation-label" headingLevel="h4" panelId={panelId} - tip={t('feature.moderation.description', { ns: 'appDebug' })} - tipAriaLabel={t('feature.moderation.description', { ns: 'appDebug' })} rootClassName="gap-1 border-t border-divider-subtle py-3" headerClassName="mb-0 gap-1 px-3" panelContentClassName="px-3 pt-1" diff --git a/web/features/agent-v2/agent-detail/configure/components/orchestrate/advanced/env.tsx b/web/features/agent-v2/agent-detail/configure/components/orchestrate/advanced/env.tsx index cd8044c3030..e989cd9e365 100644 --- a/web/features/agent-v2/agent-detail/configure/components/orchestrate/advanced/env.tsx +++ b/web/features/agent-v2/agent-detail/configure/components/orchestrate/advanced/env.tsx @@ -13,6 +13,7 @@ import { useTranslation } from 'react-i18next' import { agentComposerEnvVariablesAtom } from '@/features/agent-v2/agent-composer/store-modules/env' import { checkKeys } from '@/utils/var' import { ConfigureSection } from '../common/section' +import { AgentConfigureTipContent } from '../common/tip-content' import { useAgentOrchestrateReadOnly } from '../read-only-context' import { getEnvImportPlatform, parseEnvVariables } from './env-utils' @@ -480,7 +481,7 @@ export function AgentEnvEditor() { labelId="agent-configure-env-editor-label" headingLevel="h4" panelId={envEditorTableId} - tip={envEditorTip} + tip={} tipAriaLabel={envEditorTip} rootClassName="gap-1 pt-3" headerClassName="mb-0 gap-1 px-3" diff --git a/web/features/agent-v2/agent-detail/configure/components/orchestrate/common/tip-content.tsx b/web/features/agent-v2/agent-detail/configure/components/orchestrate/common/tip-content.tsx index 944da5f65e2..7edbcbe6a27 100644 --- a/web/features/agent-v2/agent-detail/configure/components/orchestrate/common/tip-content.tsx +++ b/web/features/agent-v2/agent-detail/configure/components/orchestrate/common/tip-content.tsx @@ -5,7 +5,7 @@ import { Trans, useTranslation } from 'react-i18next' import { useDocLink } from '@/context/i18n' type AgentConfigureTipContentProps = { - type: 'prompt' | 'skills' | 'files' | 'tools' + type: 'prompt' | 'skills' | 'files' | 'tools' | 'env' } function DocsLink({ @@ -31,6 +31,20 @@ export function AgentConfigureTipContent({ type }: AgentConfigureTipContentProps const { t } = useTranslation('agentV2') const docLink = useDocLink() + if (type === 'env') { + return ( + + , + }} + /> + + ) + } + if (type === 'skills') { return ( @@ -50,7 +54,23 @@ export function AgentPreviewHeader({ {t('agentDetail.configure.rightPanel.preview')} - + + + + + )} + /> + +
{modeTipTitle}
+
{modeTipBody}
+
+