fix(core): update
This commit is contained in:
parent
d2cd5ce6f3
commit
68bcc10ee6
@ -13,6 +13,9 @@ export class DeesElement extends plugins.lit.LitElement {
|
|||||||
|
|
||||||
private themeSubscription: plugins.smartrx.rxjs.Subscription;
|
private themeSubscription: plugins.smartrx.rxjs.Subscription;
|
||||||
|
|
||||||
|
private elementDomReadyDeferred = plugins.domtools.plugins.smartpromise.defer();
|
||||||
|
public elementDomReady = this.elementDomReadyDeferred.promise;
|
||||||
|
|
||||||
constructor() {
|
constructor() {
|
||||||
super();
|
super();
|
||||||
this.domtoolsPromise.then((domtoolsArg) => {
|
this.domtoolsPromise.then((domtoolsArg) => {
|
||||||
@ -29,6 +32,11 @@ export class DeesElement extends plugins.lit.LitElement {
|
|||||||
this.dispatchEvent(new CustomEvent('deesElementConnected'));
|
this.dispatchEvent(new CustomEvent('deesElementConnected'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public firstUpdated(_changedProperties: Map<string | number | symbol, unknown>): void {
|
||||||
|
super.firstUpdated(_changedProperties);
|
||||||
|
this.elementDomReadyDeferred.resolve();
|
||||||
|
}
|
||||||
|
|
||||||
public async disconnectedCallback() {
|
public async disconnectedCallback() {
|
||||||
await this.domtoolsPromise;
|
await this.domtoolsPromise;
|
||||||
super.disconnectedCallback();
|
super.disconnectedCallback();
|
||||||
|
Loading…
Reference in New Issue
Block a user