1
0
mirror of https://github.com/BookStackApp/BookStack.git synced 2025-07-28 17:02:04 +03:00

Added new confirm-dialog component, both view and logic

This commit is contained in:
Dan Brown
2022-04-20 14:58:37 +01:00
parent 214992650d
commit eff539f89b
5 changed files with 83 additions and 4 deletions

View File

@ -34,7 +34,7 @@ class Popup {
}
hide(onComplete = null) {
fadeOut(this.container, 240, onComplete);
fadeOut(this.container, 120, onComplete);
if (this.onkeyup) {
window.removeEventListener('keyup', this.onkeyup);
this.onkeyup = null;
@ -45,7 +45,7 @@ class Popup {
}
show(onComplete = null, onHide = null) {
fadeIn(this.container, 240, onComplete);
fadeIn(this.container, 120, onComplete);
this.onkeyup = (event) => {
if (event.key === 'Escape') {