Cancel edit in number and string editors. (#1764)

This commit is contained in:
Alexander Platov 2022-05-16 16:53:53 +03:00 committed by GitHub
parent 2defbc434b
commit a1c298ebca
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 4 deletions

View File

@ -43,8 +43,10 @@
{ value, format: 'number' }, { value, format: 'number' },
eventToHTMLElement(ev), eventToHTMLElement(ev),
(res) => { (res) => {
if (res !== undefined) value = res if (res !== undefined) {
onChange(value) value = res
onChange(value)
}
shown = false shown = false
}, },
(res) => { (res) => {

View File

@ -43,8 +43,10 @@
{ value }, { value },
eventToHTMLElement(ev), eventToHTMLElement(ev),
(res) => { (res) => {
if (res !== undefined) value = res if (res !== undefined) {
onChange(value) value = res
onChange(value)
}
shown = false shown = false
}, },
(res) => { (res) => {