add share button

This commit is contained in:
2023-08-27 17:42:55 +02:00
parent 74e7d1d083
commit 39377c7e96
2 changed files with 11 additions and 7 deletions

View File

@ -171,7 +171,7 @@ export class Editor {
// Share button
share_button: HTMLElement = document.getElementById(
"share_button"
"share-button"
) as HTMLElement;
// Error line
@ -513,11 +513,6 @@ export class Editor {
});
this.share_button.addEventListener("click", () => {
this.share_button.classList.add("animate-spin");
setInterval(
() => this.share_button.classList.remove("animate-spin"),
1000
);
// trigger a manual save
this.currentFile().candidate = app.view.state.doc.toString();
this.currentFile().committed = app.view.state.doc.toString();