Simplify the approach to leave change behaviour as it is and leave persistence to the close behaviour
This commit is contained in:
parent
b9c685b83b
commit
3c2cb3dda1
|
@ -1078,15 +1078,10 @@
|
||||||
>
|
>
|
||||||
<CodeEditor
|
<CodeEditor
|
||||||
value={inputData[key]}
|
value={inputData[key]}
|
||||||
on:blur={e => {
|
on:change={e => {
|
||||||
// need to pass without the value inside
|
// need to pass without the value inside
|
||||||
inputData[key] = e.detail
|
inputData[key] = e.detail
|
||||||
}}
|
}}
|
||||||
on:insert={e => {
|
|
||||||
// Blur events only happen once after inserting a binding
|
|
||||||
// State will now update on insert
|
|
||||||
inputData[key] = e.detail
|
|
||||||
}}
|
|
||||||
completions={stepCompletions}
|
completions={stepCompletions}
|
||||||
mode={codeMode}
|
mode={codeMode}
|
||||||
autocompleteEnabled={codeMode !== EditorModes.JS}
|
autocompleteEnabled={codeMode !== EditorModes.JS}
|
||||||
|
|
|
@ -140,7 +140,6 @@
|
||||||
}
|
}
|
||||||
: undefined,
|
: undefined,
|
||||||
})
|
})
|
||||||
dispatch("insert", editor.state.doc.toString())
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Match decoration for HBS bindings
|
// Match decoration for HBS bindings
|
||||||
|
|
Loading…
Reference in New Issue