[view] tag entry should grow as-needed, but not shrink - fixes #1005

This commit is contained in:
Shish 2024-01-09 17:38:55 +00:00
parent e95c47c547
commit d986d0d378

View file

@ -6,9 +6,15 @@ function joinUrlSegments(base, query) {
return base + separatorChar + query;
}
/**
* @param {HTMLElement} el
*/
function autosize(el) {
setTimeout(function() {
el.style.cssText = 'height:' + el.scrollHeight + 'px';
if(el.offsetHeight < el.scrollHeight) {
el.style.height = el.scrollHeight + 'px';
el.style.width = el.offsetWidth + 'px';
}
}, 0);
}