From 73ecdd5494c05bfe6b03b171219effb3d7cb55b8 Mon Sep 17 00:00:00 2001 From: kurokobo Date: Wed, 29 Apr 2026 15:28:21 +0900 Subject: [PATCH 1/5] fix: ensure generated password satisfies the password policy (#35672) --- api/commands/account.py | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/api/commands/account.py b/api/commands/account.py index 761323a73d..0d99ce7a0f 100644 --- a/api/commands/account.py +++ b/api/commands/account.py @@ -113,8 +113,18 @@ def create_tenant(email: str, language: str | None = None, name: str | None = No # Validates name encoding for non-Latin characters. name = name.strip().encode("utf-8").decode("utf-8") if name else None - # generate random password - new_password = secrets.token_urlsafe(16) + # Generate a random password that satisfies the password policy. + # The iteration limit guards against infinite loops caused by unexpected bugs in valid_password. + for _ in range(100): + new_password = secrets.token_urlsafe(16) + try: + valid_password(new_password) + break + except Exception: + continue + else: + click.echo(click.style("Failed to generate a valid password. Please try again.", fg="red")) + return # register account account = RegisterService.register( From 25973c7d7704c8e5578488ecfda70d11071c9976 Mon Sep 17 00:00:00 2001 From: yyh <92089059+lyzno1@users.noreply.github.com> Date: Wed, 29 Apr 2026 14:35:02 +0800 Subject: [PATCH 2/5] chore: update eslint suppressions codeowner (#35679) --- .github/CODEOWNERS | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 94e857f93a..98b7e9f119 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -6,6 +6,9 @@ * @crazywoola @laipz8200 @Yeuoly +# ESLint suppression file is maintained by autofix.ci pruning. +/eslint-suppressions.json + # CODEOWNERS file /.github/CODEOWNERS @laipz8200 @crazywoola From 0e55dcb297e1fb69465de62cf48e0d634ba32755 Mon Sep 17 00:00:00 2001 From: yyh <92089059+lyzno1@users.noreply.github.com> Date: Wed, 29 Apr 2026 14:44:39 +0800 Subject: [PATCH 3/5] refactor(web): migrate rich tooltip overlays (#35675) Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com> --- eslint-suppressions.json | 40 ---- .../config/agent/agent-tools/index.tsx | 120 +++++++--- .../app/overview/__tests__/app-card.spec.tsx | 1 + web/app/components/app/overview/app-card.tsx | 104 ++++---- .../external-api/external-api-modal/index.tsx | 226 ++++++++++-------- .../datasets/extra-info/statistics.tsx | 38 +-- .../__tests__/endpoint-list.spec.tsx | 19 +- .../plugin-detail-panel/endpoint-list.tsx | 39 ++- .../components/tools/mcp/detail/tool-item.tsx | 36 +-- .../components/tools/mcp/mcp-service-card.tsx | 88 ++++--- .../nodes/_base/components/prompt/editor.tsx | 87 ++++--- web/app/signin/one-more-step.tsx | 36 ++- 12 files changed, 493 insertions(+), 341 deletions(-) diff --git a/eslint-suppressions.json b/eslint-suppressions.json index c724609e88..b23e612a0a 100644 --- a/eslint-suppressions.json +++ b/eslint-suppressions.json @@ -385,9 +385,6 @@ } }, "web/app/components/app/configuration/config/agent/agent-tools/index.tsx": { - "no-restricted-imports": { - "count": 1 - }, "ts/no-explicit-any": { "count": 9 } @@ -641,11 +638,6 @@ "count": 2 } }, - "web/app/components/app/overview/app-card.tsx": { - "no-restricted-imports": { - "count": 1 - } - }, "web/app/components/app/overview/customize/index.tsx": { "no-restricted-imports": { "count": 1 @@ -2607,14 +2599,6 @@ "count": 1 } }, - "web/app/components/datasets/external-api/external-api-modal/index.tsx": { - "no-restricted-imports": { - "count": 2 - }, - "react/set-state-in-effect": { - "count": 1 - } - }, "web/app/components/datasets/external-knowledge-base/create/ExternalApiSelect.tsx": { "react/set-state-in-effect": { "count": 1 @@ -2625,11 +2609,6 @@ "count": 1 } }, - "web/app/components/datasets/extra-info/statistics.tsx": { - "no-restricted-imports": { - "count": 1 - } - }, "web/app/components/datasets/formatted-text/flavours/type.ts": { "ts/no-empty-object-type": { "count": 1 @@ -3299,9 +3278,6 @@ } }, "web/app/components/plugins/plugin-detail-panel/endpoint-list.tsx": { - "no-restricted-imports": { - "count": 1 - }, "ts/no-explicit-any": { "count": 2 } @@ -3764,11 +3740,6 @@ "count": 1 } }, - "web/app/components/tools/mcp/detail/tool-item.tsx": { - "no-restricted-imports": { - "count": 1 - } - }, "web/app/components/tools/mcp/mcp-server-modal.tsx": { "no-restricted-imports": { "count": 1 @@ -3782,11 +3753,6 @@ "count": 1 } }, - "web/app/components/tools/mcp/mcp-service-card.tsx": { - "no-restricted-imports": { - "count": 1 - } - }, "web/app/components/tools/mcp/modal.tsx": { "no-restricted-imports": { "count": 1 @@ -4241,9 +4207,6 @@ } }, "web/app/components/workflow/nodes/_base/components/prompt/editor.tsx": { - "no-restricted-imports": { - "count": 1 - }, "ts/no-explicit-any": { "count": 4 } @@ -5711,9 +5674,6 @@ } }, "web/app/signin/one-more-step.tsx": { - "no-restricted-imports": { - "count": 1 - }, "ts/no-explicit-any": { "count": 1 } diff --git a/web/app/components/app/configuration/config/agent/agent-tools/index.tsx b/web/app/components/app/configuration/config/agent/agent-tools/index.tsx index 6100e415cc..3242bcdcf8 100644 --- a/web/app/components/app/configuration/config/agent/agent-tools/index.tsx +++ b/web/app/components/app/configuration/config/agent/agent-tools/index.tsx @@ -6,7 +6,9 @@ import type { ToolWithProvider } from '@/app/components/workflow/types' import type { AgentTool } from '@/types/app' import { Button } from '@langgenius/dify-ui/button' import { cn } from '@langgenius/dify-ui/cn' +import { Popover, PopoverContent, PopoverTrigger } from '@langgenius/dify-ui/popover' import { Switch } from '@langgenius/dify-ui/switch' +import { Tooltip, TooltipContent, TooltipTrigger } from '@langgenius/dify-ui/tooltip' import { RiDeleteBinLine, RiEqualizer2Line, @@ -23,7 +25,6 @@ import OperationBtn from '@/app/components/app/configuration/base/operation-btn' import AppIcon from '@/app/components/base/app-icon' import { DefaultToolIcon } from '@/app/components/base/icons/src/public/other' import { AlertTriangle } from '@/app/components/base/icons/src/vender/solid/alertsAndFeedback' -import Tooltip from '@/app/components/base/tooltip' import Indicator from '@/app/components/header/indicator' import { CollectionType } from '@/app/components/tools/types' import { addDefaultValue, toolParametersToFormSchemas } from '@/app/components/tools/utils/to-form-schema' @@ -154,13 +155,23 @@ const AgentTools: FC = () => { title={(
{t('agent.tools.name', { ns: 'appDebug' })}
- - {t('agent.tools.description', { ns: 'appDebug' })} -
- )} - /> + + + + + )} + /> + + {t('agent.tools.description', { ns: 'appDebug' })} + + )} headerRight={( @@ -216,34 +227,59 @@ const AgentTools: FC = () => { {getProviderShowName(item)} {item.tool_label} {!item.isDeleted && !readonly && ( - + + + + + )} + /> + +
{item.tool_name}
{t('toolNameUsageTip', { ns: 'tools' })}
-
copy(item.tool_name)}>{t('copyToolName', { ns: 'tools' })}
+
- )} - > -
-
- -
-
-
+ + )}
{item.isDeleted && (
- -
- -
-
+ + + + + )} + /> + + {t('toolRemoved', { ns: 'tools' })} + +
{ @@ -263,19 +299,25 @@ const AgentTools: FC = () => { {!item.isDeleted && !readonly && (
{!item.notAuthor && ( - -
{ - setCurrentTool(item) - setIsShowSettingTool(true) - }} - > - -
+ + { + setCurrentTool(item) + setIsShowSettingTool(true) + }} + > + + + )} + /> + + {t('setBuiltInTools.infoAndSetting', { ns: 'tools' })} + )}
{ />, ) + fireEvent.click(screen.getByRole('button', { name: 'overview.appInfo.enableTooltip.description' })) fireEvent.click(screen.getByText('overview.appInfo.enableTooltip.learnMore')) expect(mockWindowOpen).toHaveBeenCalledWith('https://docs.example.com/use-dify/nodes/user-input', '_blank') diff --git a/web/app/components/app/overview/app-card.tsx b/web/app/components/app/overview/app-card.tsx index f0502ae918..b7ec4a2d81 100644 --- a/web/app/components/app/overview/app-card.tsx +++ b/web/app/components/app/overview/app-card.tsx @@ -2,6 +2,7 @@ import type { ConfigParams } from './settings' import type { AppDetailResponse } from '@/models/app' import type { AppSSO } from '@/types/app' +import { Popover, PopoverContent, PopoverTrigger } from '@langgenius/dify-ui/popover' import { Switch } from '@langgenius/dify-ui/switch' import { useSuspenseQuery } from '@tanstack/react-query' import * as React from 'react' @@ -9,7 +10,6 @@ import { useCallback, useMemo, useState } from 'react' import { useTranslation } from 'react-i18next' import AppBasic from '@/app/components/app-sidebar/basic' import { useStore as useAppStore } from '@/app/components/app/store' -import Tooltip from '@/app/components/base/tooltip' import SecretKeyButton from '@/app/components/develop/secret-key/secret-key-button' import Indicator from '@/app/components/header/indicator' import { useAppContext } from '@/context/app-context' @@ -179,6 +179,31 @@ function AppCard({ triggerModeDisabled, ]) + const missingStartNodeContent = cardState.appUnpublished || cardState.missingStartNode + ? ( + <> +
+ {t('overview.appInfo.enableTooltip.description', { ns: 'appOverview' })} +
+ + + ) + : '' + + const statusPopoverContent = cardState.toggleDisabled + ? ( + triggerModeDisabled && triggerModeMessage + ? triggerModeMessage + : missingStartNodeContent + ) + : '' + return (
- - -
- {t('overview.appInfo.enableTooltip.description', { ns: 'appOverview' })} -
-
window.open(docLink('/use-dify/nodes/user-input'), '_blank')} - > - {t('overview.appInfo.enableTooltip.learnMore', { ns: 'appOverview' })} -
- - ) - : '' - ) - : '' - } - position="right" - popupClassName="w-58 max-w-60 rounded-xl bg-components-panel-bg px-3.5 py-3 shadow-lg" - offset={24} - > -
- -
-
+ {cardState.toggleDisabled && statusPopoverContent + ? ( + + + +
+ )} + /> + + {statusPopoverContent} + + + ) + : ( + + )}
{!cardState.isMinimalState && ( = ({ data, onSave, onCancel, datasetBindings, isEditMode, onEdit }) => { const { t } = useTranslation() const [loading, setLoading] = useState(false) const [showConfirm, setShowConfirm] = useState(false) - const [formData, setFormData] = useState({ name: '', settings: { endpoint: '', api_key: '' } }) - useEffect(() => { - if (isEditMode && data) - setFormData(data) - }, [isEditMode, data]) + const [formData, setFormData] = useState(() => isEditMode && data ? data : emptyExternalAPIFormData) const hasEmptyInputs = Object.values(formData).some(value => typeof value === 'string' ? value.trim() === '' : Object.values(value).some(v => v.trim() === '')) const handleDataChange = (val: CreateExternalAPIReq) => { setFormData(val) @@ -108,106 +113,121 @@ const AddExternalAPIModal: FC = ({ data, onSave, onCan } } return ( - - -
-
-
-
- {isEditMode ? t('editExternalAPIFormTitle', { ns: 'dataset' }) : t('createExternalAPI', { ns: 'dataset' })} -
- {isEditMode && (datasetBindings?.length ?? 0) > 0 && ( -
- {t('editExternalAPIFormWarning.front', { ns: 'dataset' })} - -   - {datasetBindings?.length} - {' '} - {t('editExternalAPIFormWarning.end', { ns: 'dataset' })} + { + if (!open) + onCancel() + }} + > + +
+
+ + {isEditMode ? t('editExternalAPIFormTitle', { ns: 'dataset' }) : t('createExternalAPI', { ns: 'dataset' })} + + {isEditMode && (datasetBindings?.length ?? 0) > 0 && ( +
+ {t('editExternalAPIFormWarning.front', { ns: 'dataset' })} + +   + {datasetBindings?.length} + {' '} + {t('editExternalAPIFormWarning.end', { ns: 'dataset' })}   - -
-
{`${datasetBindings?.length} ${t('editExternalAPITooltipTitle', { ns: 'dataset' })}`}
-
- {datasetBindings?.map(binding => ( -
- -
{binding.name}
-
- ))} -
+ + + + )} - asChild={false} - position="bottom" + /> + - - - -
- )} -
- - - -
-
- - -
-
- - {t('externalAPIForm.encrypted.front', { ns: 'dataset' })} - - PKCS1_OAEP - - {t('externalAPIForm.encrypted.end', { ns: 'dataset' })} -
-
- 0} - onOpenChange={open => !open && setShowConfirm(false)} - > - -
- - Warning - - - {`${t('editExternalAPIConfirmWarningContent.front', { ns: 'dataset' })} ${datasetBindings?.length} ${t('editExternalAPIConfirmWarningContent.end', { ns: 'dataset' })}`} - +
+
+
{`${datasetBindings?.length} ${t('editExternalAPITooltipTitle', { ns: 'dataset' })}`}
+
+ {datasetBindings?.map(binding => ( +
+ +
{binding.name}
+
+ ))} +
+ + +
- - {t('operation.cancel', { ns: 'common' })} - - {t('operation.confirm', { ns: 'common' })} - - -
-
+ )} +
+ + + + +
+ + +
+
+ + {t('externalAPIForm.encrypted.front', { ns: 'dataset' })} + + PKCS1_OAEP + + {t('externalAPIForm.encrypted.end', { ns: 'dataset' })} +
- - + 0} + onOpenChange={open => !open && setShowConfirm(false)} + > + +
+ + Warning + + + {`${t('editExternalAPIConfirmWarningContent.front', { ns: 'dataset' })} ${datasetBindings?.length} ${t('editExternalAPIConfirmWarningContent.end', { ns: 'dataset' })}`} + +
+ + {t('operation.cancel', { ns: 'common' })} + + {t('operation.confirm', { ns: 'common' })} + + +
+
+ + ) } export default memo(AddExternalAPIModal) diff --git a/web/app/components/datasets/extra-info/statistics.tsx b/web/app/components/datasets/extra-info/statistics.tsx index f02db4c5dc..4adf71cc57 100644 --- a/web/app/components/datasets/extra-info/statistics.tsx +++ b/web/app/components/datasets/extra-info/statistics.tsx @@ -1,10 +1,10 @@ import type { RelatedAppResponse } from '@/models/datasets' +import { Popover, PopoverContent, PopoverTrigger } from '@langgenius/dify-ui/popover' import { RiInformation2Line } from '@remixicon/react' import * as React from 'react' import { useTranslation } from 'react-i18next' import Divider from '@/app/components/base/divider' import LinkedAppsPanel from '@/app/components/base/linked-apps-panel' -import Tooltip from '@/app/components/base/tooltip' import NoLinkedAppsPanel from '../no-linked-apps-panel' type StatisticsProps = { @@ -40,26 +40,34 @@ const Statistics = ({
{relatedAppsTotal ?? '--'}
- + + {t('datasetMenus.relatedApp', { ns: 'common' })} + + + )} + /> + + {hasRelatedApps ? ( ) - : - } - > -
- {t('datasetMenus.relatedApp', { ns: 'common' })} - -
-
+ : } + +
) diff --git a/web/app/components/plugins/plugin-detail-panel/__tests__/endpoint-list.spec.tsx b/web/app/components/plugins/plugin-detail-panel/__tests__/endpoint-list.spec.tsx index e31afc7cb2..ec9a8eeccf 100644 --- a/web/app/components/plugins/plugin-detail-panel/__tests__/endpoint-list.spec.tsx +++ b/web/app/components/plugins/plugin-detail-panel/__tests__/endpoint-list.spec.tsx @@ -76,6 +76,8 @@ const createPluginDetail = (): PluginDetail => ({ }) describe('EndpointList', () => { + const getAddButton = () => screen.getByRole('button', { name: 'plugin.detailPanel.endpointModalTitle' }) + beforeEach(() => { vi.clearAllMocks() mockEndpointListData = { endpoints: mockEndpoints } @@ -112,7 +114,7 @@ describe('EndpointList', () => { it('should render add button', () => { render() - expect(screen.getAllByRole('button').length).toBeGreaterThan(0) + expect(getAddButton()).toBeInTheDocument() }) }) @@ -120,8 +122,7 @@ describe('EndpointList', () => { it('should show modal when add button clicked', () => { render() - const addButton = screen.getAllByRole('button')[0] - fireEvent.click(addButton!) + fireEvent.click(getAddButton()) expect(screen.getByTestId('endpoint-modal'))!.toBeInTheDocument() }) @@ -129,8 +130,7 @@ describe('EndpointList', () => { it('should hide modal when cancel clicked', () => { render() - const addButton = screen.getAllByRole('button')[0] - fireEvent.click(addButton!) + fireEvent.click(getAddButton()) expect(screen.getByTestId('endpoint-modal'))!.toBeInTheDocument() fireEvent.click(screen.getByTestId('modal-cancel')) @@ -140,8 +140,7 @@ describe('EndpointList', () => { it('should call createEndpoint when save clicked', () => { render() - const addButton = screen.getAllByRole('button')[0] - fireEvent.click(addButton!) + fireEvent.click(getAddButton()) fireEvent.click(screen.getByTestId('modal-save')) expect(mockCreateEndpoint).toHaveBeenCalled() @@ -176,8 +175,7 @@ describe('EndpointList', () => { it('should invalidate endpoint list after successful create', () => { render() - const addButton = screen.getAllByRole('button')[0] - fireEvent.click(addButton!) + fireEvent.click(getAddButton()) fireEvent.click(screen.getByTestId('modal-save')) expect(mockInvalidateEndpointList).toHaveBeenCalledWith('test-plugin') @@ -186,8 +184,7 @@ describe('EndpointList', () => { it('should pass correct params to createEndpoint', () => { render() - const addButton = screen.getAllByRole('button')[0] - fireEvent.click(addButton!) + fireEvent.click(getAddButton()) fireEvent.click(screen.getByTestId('modal-save')) expect(mockCreateEndpoint).toHaveBeenCalledWith({ diff --git a/web/app/components/plugins/plugin-detail-panel/endpoint-list.tsx b/web/app/components/plugins/plugin-detail-panel/endpoint-list.tsx index 2d11305f6e..d50ab4c4ea 100644 --- a/web/app/components/plugins/plugin-detail-panel/endpoint-list.tsx +++ b/web/app/components/plugins/plugin-detail-panel/endpoint-list.tsx @@ -1,5 +1,6 @@ import type { PluginDetail } from '@/app/components/plugins/types' import { cn } from '@langgenius/dify-ui/cn' +import { Popover, PopoverContent, PopoverTrigger } from '@langgenius/dify-ui/popover' import { toast } from '@langgenius/dify-ui/toast' import { RiAddLine, @@ -11,7 +12,6 @@ import * as React from 'react' import { useMemo } from 'react' import { useTranslation } from 'react-i18next' import ActionButton from '@/app/components/base/action-button' -import Tooltip from '@/app/components/base/tooltip' import { toolCredentialToFormSchemas } from '@/app/components/tools/utils/to-form-schema' import { useDocLink } from '@/context/i18n' import { @@ -67,10 +67,23 @@ const EndpointList = ({ detail }: Props) => {
{t('detailPanel.endpoints', { ns: 'plugin' })} - + + + + )} + /> +
@@ -80,17 +93,19 @@ const EndpointList = ({ detail }: Props) => { href={docLink('/develop-plugin/getting-started/getting-started-dify-plugin')} target="_blank" rel="noopener noreferrer" + className="inline-flex cursor-pointer items-center gap-1 system-xs-regular text-text-accent" > -
- - {t('detailPanel.endpointsDocLink', { ns: 'plugin' })} -
+ + {t('detailPanel.endpointsDocLink', { ns: 'plugin' })}
- )} - /> + +
- +
diff --git a/web/app/components/tools/mcp/detail/tool-item.tsx b/web/app/components/tools/mcp/detail/tool-item.tsx index 4101fa2078..f05890aee2 100644 --- a/web/app/components/tools/mcp/detail/tool-item.tsx +++ b/web/app/components/tools/mcp/detail/tool-item.tsx @@ -1,9 +1,9 @@ 'use client' import type { Tool } from '@/app/components/tools/types' import { cn } from '@langgenius/dify-ui/cn' +import { Popover, PopoverContent, PopoverTrigger } from '@langgenius/dify-ui/popover' import * as React from 'react' import { useTranslation } from 'react-i18next' -import Tooltip from '@/app/components/base/tooltip' import { useLocale } from '@/context/i18n' import { getLanguage } from '@/i18n-config/language' @@ -51,25 +51,31 @@ const MCPToolItem = ({ } return ( - + +
{tool.label[language]}
+
{tool.description[language]}
+ + )} + /> +
{tool.label[language]}
{tool.description[language]}
{renderParameters()}
- )} - > -
-
{tool.label[language]}
-
{tool.description[language]}
-
-
+ + ) } export default MCPToolItem diff --git a/web/app/components/tools/mcp/mcp-service-card.tsx b/web/app/components/tools/mcp/mcp-service-card.tsx index 67beb9b3ee..3810e5b4c2 100644 --- a/web/app/components/tools/mcp/mcp-service-card.tsx +++ b/web/app/components/tools/mcp/mcp-service-card.tsx @@ -15,14 +15,15 @@ import { } from '@langgenius/dify-ui/alert-dialog' import { Button } from '@langgenius/dify-ui/button' import { cn } from '@langgenius/dify-ui/cn' +import { Popover, PopoverContent, PopoverTrigger } from '@langgenius/dify-ui/popover' import { Switch } from '@langgenius/dify-ui/switch' +import { Tooltip, TooltipContent, TooltipTrigger } from '@langgenius/dify-ui/tooltip' import { RiEditLine, RiLoopLeftLine } from '@remixicon/react' import { useEffect, useRef, useState } from 'react' import { useTranslation } from 'react-i18next' import CopyFeedback from '@/app/components/base/copy-feedback' import Divider from '@/app/components/base/divider' import { Mcp } from '@/app/components/base/icons/src/vender/other' -import Tooltip from '@/app/components/base/tooltip' import Indicator from '@/app/components/header/indicator' import MCPServerModal from '@/app/components/tools/mcp/mcp-server-modal' import { collaborationManager } from '@/app/components/workflow/collaboration/core/collaboration-manager' @@ -81,13 +82,22 @@ const ServerURLSection: FC = ({ {isCurrentWorkspaceManager && ( - -
- -
+ + + + + )} + /> + + {t('overview.appInfo.regenerate', { ns: 'appOverview' })} + )} @@ -104,13 +114,19 @@ type TriggerModeOverlayProps = { const TriggerModeOverlay: FC = ({ triggerModeMessage }) => { if (triggerModeMessage) { return ( - - - + + } + /> + + {triggerModeMessage} + + ) } return @@ -146,12 +162,13 @@ function getTooltipContent({
{t('overview.appInfo.enableTooltip.description', { ns: 'appOverview' })}
-
window.open(docLink('/use-dify/nodes/user-input'), '_blank')} > {t('overview.appInfo.enableTooltip.learnMore', { ns: 'appOverview' })} -
+ ) } @@ -316,16 +333,31 @@ const MCPServiceCard: FC = ({
- -
- -
-
+ {toggleDisabled && tooltipContent + ? ( + + + +
+ )} + /> + + {tooltipContent} + + + ) + : ( + + )}
{!isMinimalState && ( = ({ {' '} {required && *} - {!!titleTooltip && } + {!!titleTooltip && ( + + + + + )} + /> + + {titleTooltip} + + + )}
{value?.length || 0}
@@ -184,34 +203,48 @@ const Editor: FC = ({ {/* Operations */}
{isSupportJinja && ( - -
{t('common.enableJinja', { ns: 'workflow' })}
- {t('common.learnMore', { ns: 'workflow' })} -
- )} - > -
- - { - onEditionTypeChange?.(checked ? EditionType.jinja2 : EditionType.basic) - }} +
+ + + + + )} /> -
- - + +
+
{t('common.enableJinja', { ns: 'workflow' })}
+ {t('common.learnMore', { ns: 'workflow' })} +
+
+ + { + onEditionTypeChange?.(checked ? EditionType.jinja2 : EditionType.basic) + }} + /> +
)} {!readOnly && ( - - - - + + + + + )} + /> + + {t('common.insertVarTip', { ns: 'workflow' })} + )} {showRemove && ( diff --git a/web/app/signin/one-more-step.tsx b/web/app/signin/one-more-step.tsx index f6cd0fb126..47982e87a5 100644 --- a/web/app/signin/one-more-step.tsx +++ b/web/app/signin/one-more-step.tsx @@ -2,11 +2,11 @@ import type { Reducer } from 'react' import type { LanguagesSupported } from '@/i18n-config/language' import { Button } from '@langgenius/dify-ui/button' +import { Popover, PopoverContent, PopoverTrigger } from '@langgenius/dify-ui/popover' import { Select, SelectContent, SelectItem, SelectItemIndicator, SelectItemText, SelectTrigger } from '@langgenius/dify-ui/select' import { toast } from '@langgenius/dify-ui/toast' import { useReducer } from 'react' import { useTranslation } from 'react-i18next' -import Tooltip from '@/app/components/base/tooltip' import { LICENSE_LINK } from '@/constants/link' import { languages } from '@/i18n-config/language' import Link from '@/next/link' @@ -94,21 +94,35 @@ const OneMoreStep = () => {
-