diff --git a/HISTORY.md b/HISTORY.md index 953b461..708c530 100644 --- a/HISTORY.md +++ b/HISTORY.md @@ -3,6 +3,11 @@ https://github.com/josdejong/jsoneditor +## 2016-02-15, version 5.1.5 + +- Fixed #272: Checkbox for boolean values visible in view mode. + + ## 2016-02-13, version 5.1.4 - Fixed broken example 04_load_and_save.html. See #265. diff --git a/src/js/Node.js b/src/js/Node.js index faf006e..707ab11 100644 --- a/src/js/Node.js +++ b/src/js/Node.js @@ -1248,7 +1248,7 @@ Node.prototype._updateDomValue = function () { } // show checkbox when the value is a boolean - if (type === 'boolean') { + if (type === 'boolean' && this.editable.value) { if (!this.dom.checkbox) { this.dom.checkbox = document.createElement('input'); this.dom.checkbox.type = 'checkbox';