diff --git a/CHANGELOG.md b/CHANGELOG.md index 4e8f6671..d4d0d55f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,7 @@ - widgets - frames: allow loading local html files without requiring a web server to serve them + - text: escape html tags characters (`<` & `>`) ## 0.47.4 diff --git a/src/client/app/widgets/plots/text.js b/src/client/app/widgets/plots/text.js index e3c30463..b7761623 100644 --- a/src/client/app/widgets/plots/text.js +++ b/src/client/app/widgets/plots/text.js @@ -57,7 +57,7 @@ module.exports = class Text extends Widget { setValue(v, options={}) { this.value = v==null ? this.defaultValue : v - this.widget.innerHTML = iconify(String(this.value).replace(/\n/g,'
')) + this.widget.innerHTML = iconify(String(this.value).replace(//g, '>').replace(/\n/g,'
')) if (options.sync) this.changed(options)