repo: janusweb action: commit revision: path_from: revision_from: c21625983c3249008a0cc83d1c0b9f7dad99e6ff: path_to: revision_to:
commit c21625983c3249008a0cc83d1c0b9f7dad99e6ff Author: James BaicoianuDate: Thu Oct 17 17:31:29 2024 -0700 Allow hiding of popup without removing from DOM diff --git a/scripts/client.js b/scripts/client.js
--- a/scripts/client.js
+++ b/scripts/client.js
@@ -504,15 +504,17 @@ elation.require(['elements.elements', 'elements', 'engine.engine', 'engine.asset
}
elation.events.fire({type: 'overlay_show', element: this});
}
- hide() {
+ hide(remove=true) {
super.hide();
elation.events.fire({type: 'overlay_hide', element: this});
- setTimeout(() => {
- if (this.parentNode) {
- this.oldparent = this.parentNode;
- this.parentNode.removeChild(this);
- }
- }, 1000);
+ if (remove) {
+ setTimeout(() => {
+ if (this.parentNode) {
+ this.oldparent = this.parentNode;
+ this.parentNode.removeChild(this);
+ }
+ }, 1000);
+ }
}
});
}
-----END OF PAGE-----