diff --git a/awx/ui_next/src/components/CodeEditor/VariablesField.jsx b/awx/ui_next/src/components/CodeEditor/VariablesField.jsx index 3b1b1e528f..58e9960b82 100644 --- a/awx/ui_next/src/components/CodeEditor/VariablesField.jsx +++ b/awx/ui_next/src/components/CodeEditor/VariablesField.jsx @@ -81,7 +81,7 @@ function VariablesField({ const handleModeChange = newMode => { if (newMode === YAML_MODE && !isJsonEdited && lastYamlValue !== null) { - helpers.setValue(lastYamlValue); + helpers.setValue(lastYamlValue, false); setMode(newMode); return; } @@ -91,7 +91,7 @@ function VariablesField({ newMode === YAML_MODE ? jsonToYaml(field.value) : yamlToJson(field.value); - helpers.setValue(newVal); + helpers.setValue(newVal, false); setMode(newMode); } catch (err) { helpers.setError(err.message); @@ -109,7 +109,7 @@ function VariablesField({ }; return ( - <> +
) : null} - +
); } VariablesField.propTypes = {