@design.estate/dees-catalog 1.0.182 → 1.0.185

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -13,6 +13,15 @@ export class DeesWindowLayer extends DeesElement {
13
13
  // STATIC
14
14
  public static demo = () => html`<dees-windowlayer></dees-windowlayer>`;
15
15
 
16
+ public static async createAndShow() {
17
+ const domtoolsInstance = domtools.DomTools.getGlobalDomToolsSync();
18
+ const windowLayer = new DeesWindowLayer();
19
+ document.body.append(windowLayer);
20
+ await domtoolsInstance.convenience.smartdelay.delayFor(0);
21
+ windowLayer.show();
22
+ return windowLayer;
23
+ }
24
+
16
25
  // INSTANCE
17
26
  @property({
18
27
  type: Boolean
@@ -29,7 +38,7 @@ export class DeesWindowLayer extends DeesElement {
29
38
  ${domtools.elementBasic.styles}
30
39
  <style>
31
40
  .windowOverlay {
32
- transition: all 0.3s;
41
+ transition: all 0.2s;
33
42
  will-change: transform;
34
43
  position: fixed;
35
44
  top: 0px;
@@ -82,4 +91,11 @@ export class DeesWindowLayer extends DeesElement {
82
91
  await domtools.convenience.smartdelay.delayFor(0);
83
92
  this.visible = false;
84
93
  }
94
+
95
+ public async destroy() {
96
+ const domtools = await this.domtoolsPromise;
97
+ await this.hide();
98
+ await domtools.convenience.smartdelay.delayFor(300);
99
+ this.remove();
100
+ }
85
101
  }