mirror of
https://github.com/langgenius/dify.git
synced 2026-05-06 10:28:10 +08:00
fix: Fix variable insertion to only remove @ trigger on current line
This commit is contained in:
@ -500,7 +500,8 @@ const MixedVariableTextInput = ({
|
||||
if (!onChange)
|
||||
return
|
||||
|
||||
const valueWithoutTrigger = value.replace(/@$/, '')
|
||||
// compute words after the latest '@' and delete them
|
||||
const valueWithoutTrigger = value.replace(/@[^@\n]*$/, '')
|
||||
const newValue = `{{@${agent.id}.context@}}${valueWithoutTrigger}`
|
||||
|
||||
if (toolNodeId && paramKey) {
|
||||
|
||||
Reference in New Issue
Block a user