+ parseHtml: function(txt) {
+ return !txt.match(/<[/a-zA-Z]+>/)
+ ? txt.replace(/\n/g, "<br/>") //no HTML tag
+ : txt;
+ },
+ adjustHeight: function(e) {
+ // https://stackoverflow.com/a/48460773
+ let t = e.target;
+ t.style.height = "";
+ t.style.height = t.scrollHeight + "px";
+ },