refactor: resize function

removed: vault name in title bar
This commit is contained in:
quenousimporte 2023-01-26 15:55:21 +01:00
parent f1893552d3
commit 2edf906402
1 changed files with 6 additions and 12 deletions

18
main.js
View File

@ -1322,16 +1322,10 @@ function before(nb)
function resize()
{
if (md.clientHeight >= md.scrollHeight) return;
//console.log("resize");
md.style.height = md.scrollHeight + 'px';
/*md.rows = (md.value.match(/\n/g) || []).length + 1;
while (md.scrollHeight > md.clientHeight)
if (md.clientHeight < md.scrollHeight)
{
md.rows *= 1.5;
}*/
md.style.height = md.scrollHeight + 'px';
}
}
function putontop()
@ -1646,12 +1640,12 @@ function mainkeydownhandler()
function setwindowtitle()
{
document.title = currentvault + " -";
document.title = "";
if (currenttag)
{
document.title += " tag:" + currenttag + " -";
document.title += "[" + currenttag + "] -\xa0";
}
document.title += " " + currentnote.title;
document.title += currentnote.title;
}
function ontitlechange()