Skip to content

Commit 62a405f

Browse files
save file
1 parent eb7faae commit 62a405f

File tree

1 file changed

+23
-8
lines changed

1 file changed

+23
-8
lines changed

utils/editors/html-editor/v2.0/html-editor-v2.0.html

Lines changed: 23 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -649,15 +649,16 @@ <h1 slot=seo-hdr class=visually-hidden>html editor</h1>
649649

650650

651651
function run(){
652-
653-
var html = editor.getValue();
654-
output.srcdoc(html);
655-
652+
debug('run');
656653
if(autosave.checked){
657-
console.log('save');
654+
debug('autosave');
658655
filemod.save();
659656
}
660657

658+
var html = editor.getValue();
659+
output.srcdoc(html);
660+
661+
661662
}//run
662663

663664

@@ -681,6 +682,20 @@ <h1 slot=seo-hdr class=visually-hidden>html editor</h1>
681682
//:
682683

683684

685+
function debug(...args){
686+
687+
if(!df && !obj.df)return;
688+
args.unshift(`[ ${did} ]`);
689+
var fmt = Array.from({length:args.length}).fill('%O').join(' ');
690+
var args2 = [fmt].concat(args);
691+
console.groupCollapsed.apply(console,args2);
692+
console.trace();
693+
console.groupEnd();
694+
695+
}//debug
696+
697+
698+
/*
684699
function debug(){
685700
686701
if(!df)return;
@@ -716,9 +731,9 @@ <h1 slot=seo-hdr class=visually-hidden>html editor</h1>
716731
debug.log.apply(null,arguments);
717732
718733
}//trace
719-
720-
721-
734+
*/
735+
736+
722737
</script>
723738

724739

0 commit comments

Comments
 (0)