fix(editor): Do not focus expression input if it was not in focus before switching (#18744)

This commit is contained in:
Elias Meire
2025-08-27 17:03:02 +02:00
committed by GitHub
parent 215d5a1eca
commit a6406b904f
2 changed files with 49 additions and 2 deletions

View File

@@ -1150,7 +1150,7 @@ watch(remoteParameterOptionsLoading, () => {
// Focus input field when changing between fixed and expression
watch(isModelValueExpression, async (isExpression, wasExpression) => {
if (!props.isReadOnly && isExpression !== wasExpression) {
if (!props.isReadOnly && isFocused.value && isExpression !== wasExpression) {
await nextTick();
await setFocus();
}