Fix #1090: autocomplete firing on dragging or clicking a node

This commit is contained in:
Jos de Jong 2020-09-09 09:29:45 +02:00
parent 2cbac6fd5c
commit 60b84bb6bd
2 changed files with 6 additions and 0 deletions

View File

@ -5,6 +5,7 @@ https://github.com/josdejong/jsoneditor
## not yet published, version 9.0.5 ## not yet published, version 9.0.5
- Fix #1090: autocomplete firing on dragging or clicking a node.
- Fix #1096: editor crashing when passing an empty string as `name`. - Fix #1096: editor crashing when passing an empty string as `name`.
- Updated dependencies to `ajv@6.12.4`. - Updated dependencies to `ajv@6.12.4`.

View File

@ -1490,6 +1490,11 @@ treemode._showAutoComplete = function (element) {
if (element.className.indexOf('jsoneditor-value') >= 0) jsonElementType = 'value' if (element.className.indexOf('jsoneditor-value') >= 0) jsonElementType = 'value'
if (element.className.indexOf('jsoneditor-field') >= 0) jsonElementType = 'field' if (element.className.indexOf('jsoneditor-field') >= 0) jsonElementType = 'field'
if (jsonElementType === '') {
// Unknown element field. Could be a button or something else
return
}
const self = this const self = this
setTimeout(() => { setTimeout(() => {