diff --git a/packages/editor-ui/src/components/ParameterInput.vue b/packages/editor-ui/src/components/ParameterInput.vue index c1f2de10dcff90..b5ca14dd887fde 100644 --- a/packages/editor-ui/src/components/ParameterInput.vue +++ b/packages/editor-ui/src/components/ParameterInput.vue @@ -941,6 +941,14 @@ watch(remoteParameterOptionsLoading, () => { tempValue.value = displayValue.value as string; }); +// Focus input field when changing from fixed value to expression +watch(isModelValueExpression, async (isExpression, wasExpression) => { + if (isExpression && !wasExpression) { + await nextTick(); + inputField.value?.focus(); + } +}); + onUpdated(async () => { await nextTick();