diff --git a/web/app/components/workflow/nodes/_base/components/option-card.tsx b/web/app/components/workflow/nodes/_base/components/option-card.tsx index 71c2c2958d..7be5c12633 100644 --- a/web/app/components/workflow/nodes/_base/components/option-card.tsx +++ b/web/app/components/workflow/nodes/_base/components/option-card.tsx @@ -3,7 +3,9 @@ import type { FC } from 'react' import React, { useCallback } from 'react' import type { VariantProps } from 'class-variance-authority' import { cva } from 'class-variance-authority' +import { RiQuestionLine } from '@remixicon/react' import cn from '@/utils/classnames' +import TooltipPlus from '@/app/components/base/tooltip-plus' const variants = cva([], { variants: { @@ -26,6 +28,7 @@ type Props = { selected: boolean disabled?: boolean align?: 'left' | 'center' | 'right' + tooltip?: string } & VariantProps const OptionCard: FC = ({ @@ -35,6 +38,7 @@ const OptionCard: FC = ({ selected, disabled, align = 'center', + tooltip, }) => { const handleSelect = useCallback(() => { if (selected || disabled) @@ -54,7 +58,14 @@ const OptionCard: FC = ({ )} onClick={handleSelect} > - {title} + {title} + {tooltip && + {tooltip} + } + > + + } ) } diff --git a/web/app/components/workflow/nodes/_base/components/variable/utils.ts b/web/app/components/workflow/nodes/_base/components/variable/utils.ts index e42088fd1b..3deec09dc2 100644 --- a/web/app/components/workflow/nodes/_base/components/variable/utils.ts +++ b/web/app/components/workflow/nodes/_base/components/variable/utils.ts @@ -99,6 +99,10 @@ const formatItem = ( variable: 'sys.query', type: VarType.string, }) + res.vars.push({ + variable: 'sys.dialogue_count', + type: VarType.number, + }) res.vars.push({ variable: 'sys.conversation_id', type: VarType.string, diff --git a/web/app/components/workflow/nodes/assigner/panel.tsx b/web/app/components/workflow/nodes/assigner/panel.tsx index 6bba0d2a31..ff5a6420f3 100644 --- a/web/app/components/workflow/nodes/assigner/panel.tsx +++ b/web/app/components/workflow/nodes/assigner/panel.tsx @@ -49,7 +49,6 @@ const Panel: FC> = ({
{writeModeTypes.map(type => ( @@ -59,6 +58,7 @@ const Panel: FC> = ({ onSelect={handleWriteModeChange(type)} selected={inputs.write_mode === type} disabled={!isSupportAppend && type === WriteMode.Append} + tooltip={type === WriteMode.Append ? t(`${i18nPrefix}.writeModeTip`)! : undefined} /> ))}
diff --git a/web/app/components/workflow/nodes/start/panel.tsx b/web/app/components/workflow/nodes/start/panel.tsx index 48b5d6b7c2..ce86a34265 100644 --- a/web/app/components/workflow/nodes/start/panel.tsx +++ b/web/app/components/workflow/nodes/start/panel.tsx @@ -84,17 +84,30 @@ const Panel: FC> = ({ /> { isChatMode && ( - - String - - } - /> + <> + + Number + + } + /> + + String + + } + /> + ) }