Show the edit pane before it finishes loading so that it's more clear it's working.

git-svn-id: https://www.unprompted.com/svn/projects/tildefriends/trunk@4310 ed5197a5-7fde-0310-b194-c3ffbd925b24
This commit is contained in:
Cory McWilliams 2023-05-23 22:03:17 +00:00
parent 813d3cd492
commit 8e6f1284e1

View File

@ -390,6 +390,7 @@ function edit() {
gSplit = undefined;
}
gSplit = Split(['#editPane', '#viewPane'], {minSize: 0});
document.getElementById("editPane").style.display = 'flex';
ensureLoaded([
{tagName: "script", attributes: {src: "/codemirror/codemirror.min.js"}},
@ -457,7 +458,6 @@ function loadFile(name, id) {
}).then(function(text) {
gFiles[name].doc = new CodeMirror.Doc(text, guessMode(name));
if (!Object.values(gFiles).some(x => !x.doc)) {
document.getElementById("editPane").style.display = 'flex';
openFile(Object.keys(gFiles).sort()[0]);
}
});