Compare commits
6 Commits
Author | SHA1 | Date | |
---|---|---|---|
8390ba67b3 | |||
d5872511b8 | |||
a322c9a929 | |||
6301d827e1 | |||
a0e7ef2beb | |||
3d144ff81d |
39
package-lock.json
generated
39
package-lock.json
generated
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@designestate/dees-element",
|
"name": "@designestate/dees-element",
|
||||||
"version": "1.0.7",
|
"version": "1.0.10",
|
||||||
"lockfileVersion": 1,
|
"lockfileVersion": 1,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
@ -1119,17 +1119,18 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"@designestate/dees-domtools": {
|
"@designestate/dees-domtools": {
|
||||||
"version": "1.0.70",
|
"version": "1.0.80",
|
||||||
"resolved": "https://verdaccio.lossless.one/@designestate%2fdees-domtools/-/dees-domtools-1.0.70.tgz",
|
"resolved": "https://verdaccio.lossless.one/@designestate%2fdees-domtools/-/dees-domtools-1.0.80.tgz",
|
||||||
"integrity": "sha512-kpppQycHqEA6UG5/Pf2WrbSNC5Pz9r88JfxbxyWSW2hHddreYmzHBJ3GM/n/7emPK8iDaW8AIhMapVMOVPQKfw==",
|
"integrity": "sha512-Lm6BLL/F8YKLviO5XHNJbuxPdqh2FsJlHL0nMLVH95A5SzXnT071OW+Nj9CXLMpoFa+0RZGQz4fJK+P/AxPGNQ==",
|
||||||
"requires": {
|
"requires": {
|
||||||
"@apiglobal/typedrequest": "^1.0.54",
|
"@apiglobal/typedrequest": "^1.0.54",
|
||||||
"@designestate/dees-comms": "^1.0.7",
|
"@designestate/dees-comms": "^1.0.7",
|
||||||
"@pushrocks/lik": "^4.0.20",
|
"@pushrocks/lik": "^4.0.20",
|
||||||
"@pushrocks/smartdelay": "^2.0.10",
|
"@pushrocks/smartdelay": "^2.0.10",
|
||||||
"@pushrocks/smartpromise": "^3.1.3",
|
"@pushrocks/smartpromise": "^3.1.3",
|
||||||
"@pushrocks/smartrouter": "^1.0.4",
|
"@pushrocks/smartrouter": "^1.0.6",
|
||||||
"@pushrocks/smartstate": "^1.0.17",
|
"@pushrocks/smartrx": "^2.0.19",
|
||||||
|
"@pushrocks/smartstate": "^1.0.21",
|
||||||
"@pushrocks/webrequest": "^2.0.13",
|
"@pushrocks/webrequest": "^2.0.13",
|
||||||
"@pushrocks/websetup": "^3.0.11",
|
"@pushrocks/websetup": "^3.0.11",
|
||||||
"@pushrocks/webstore": "^1.0.16",
|
"@pushrocks/webstore": "^1.0.16",
|
||||||
@ -1953,9 +1954,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"@pushrocks/smartrouter": {
|
"@pushrocks/smartrouter": {
|
||||||
"version": "1.0.4",
|
"version": "1.0.7",
|
||||||
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmartrouter/-/smartrouter-1.0.4.tgz",
|
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmartrouter/-/smartrouter-1.0.7.tgz",
|
||||||
"integrity": "sha512-6ahtHvZvwH/IQh7EtachXJkHxfQZe3i/TqCxmzFdhppDTWek+v8E/fpHit0av/568tLmC6Jc2B+WHPge6whVhg==",
|
"integrity": "sha512-ns4ye4uyzjpFUDr/vciOZog4y5QDsFBxwnYmXkSMxCA7hwiL0Fn64lvCexjez05t6Gz54ge5yflWSvyv63X0kA==",
|
||||||
"requires": {
|
"requires": {
|
||||||
"path-to-regexp": "^6.1.0"
|
"path-to-regexp": "^6.1.0"
|
||||||
},
|
},
|
||||||
@ -2005,14 +2006,14 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"@pushrocks/smartstate": {
|
"@pushrocks/smartstate": {
|
||||||
"version": "1.0.17",
|
"version": "1.0.21",
|
||||||
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmartstate/-/smartstate-1.0.17.tgz",
|
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmartstate/-/smartstate-1.0.21.tgz",
|
||||||
"integrity": "sha512-lzcN6zeGXdDxG67cJPSgC2Of0Up7iQf7hKI0KMAxricYCQp514DJYdfrv82SAEoTqB4eG4bOVqq5M9IYkvEfZw==",
|
"integrity": "sha512-uyrnTrBoIP6Ka3pYAMZFZVZ4AOgFSTPgM5sURWMNogC5Fncx1A7PuDL5nE1oRJIZOl5U/kH3vq+/81gmPn4QbA==",
|
||||||
"requires": {
|
"requires": {
|
||||||
"@pushrocks/lik": "^4.0.12",
|
"@pushrocks/lik": "^4.0.20",
|
||||||
"@pushrocks/smartpromise": "^3.0.6",
|
"@pushrocks/smartpromise": "^3.1.3",
|
||||||
"@pushrocks/smartrx": "^2.0.15",
|
"@pushrocks/smartrx": "^2.0.19",
|
||||||
"rxjs": "^6.5.5"
|
"rxjs": "^6.6.3"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"@pushrocks/smartstring": {
|
"@pushrocks/smartstring": {
|
||||||
@ -6586,9 +6587,9 @@
|
|||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"idb": {
|
"idb": {
|
||||||
"version": "5.0.7",
|
"version": "5.0.8",
|
||||||
"resolved": "https://verdaccio.lossless.one/idb/-/idb-5.0.7.tgz",
|
"resolved": "https://verdaccio.lossless.one/idb/-/idb-5.0.8.tgz",
|
||||||
"integrity": "sha512-tXkkEtzOEolCKNLpxEvE5ctPqUhgTEi+wPWVWIWavl/Z0/NjSJx0o/79z4/etJWpEpVjhbQNZ7fvmp/UFv/Yog=="
|
"integrity": "sha512-K9xInRkVbT3ZsYimD2KVj6B4E93IBvOjEQTryu99WuuN7G+7x3SzA79+yubbX0QRN9V64Gi+L+ulG5QYTVydOg=="
|
||||||
},
|
},
|
||||||
"ieee754": {
|
"ieee754": {
|
||||||
"version": "1.2.1",
|
"version": "1.2.1",
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@designestate/dees-element",
|
"name": "@designestate/dees-element",
|
||||||
"version": "1.0.7",
|
"version": "1.0.10",
|
||||||
"private": false,
|
"private": false,
|
||||||
"description": "a custom element class extending lit element class",
|
"description": "a custom element class extending lit element class",
|
||||||
"main": "dist_ts/index.js",
|
"main": "dist_ts/index.js",
|
||||||
@ -21,7 +21,8 @@
|
|||||||
"tslint-config-prettier": "^1.15.0"
|
"tslint-config-prettier": "^1.15.0"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@designestate/dees-domtools": "^1.0.70",
|
"@designestate/dees-domtools": "^1.0.80",
|
||||||
|
"@pushrocks/smartrx": "^2.0.19",
|
||||||
"lit-element": "^2.4.0"
|
"lit-element": "^2.4.0"
|
||||||
},
|
},
|
||||||
"browserslist": [
|
"browserslist": [
|
||||||
|
@ -1,3 +1,11 @@
|
|||||||
|
// pushrocks scope
|
||||||
|
import * as smartrx from '@pushrocks/smartrx';
|
||||||
|
|
||||||
|
export {
|
||||||
|
smartrx
|
||||||
|
};
|
||||||
|
|
||||||
|
// third party scope
|
||||||
import { LitElement, property } from 'lit-element';
|
import { LitElement, property } from 'lit-element';
|
||||||
const litElement = {
|
const litElement = {
|
||||||
LitElement,
|
LitElement,
|
||||||
|
31
ts/index.ts
31
ts/index.ts
@ -6,21 +6,42 @@ export {
|
|||||||
customElement,
|
customElement,
|
||||||
TemplateResult,
|
TemplateResult,
|
||||||
internalProperty,
|
internalProperty,
|
||||||
css
|
css,
|
||||||
|
unsafeCSS,
|
||||||
} from 'lit-element';
|
} from 'lit-element';
|
||||||
|
|
||||||
export class DeesElement extends plugins.litElement.LitElement {
|
export class DeesElement extends plugins.litElement.LitElement {
|
||||||
@plugins.litElement.property({type: Boolean})
|
@plugins.litElement.property({ type: Boolean })
|
||||||
public goBright: boolean = false;
|
public goBright: boolean = false;
|
||||||
|
|
||||||
|
// domtools
|
||||||
public domtoolsPromise = plugins.domtools.elementBasic.setup(this);
|
public domtoolsPromise = plugins.domtools.elementBasic.setup(this);
|
||||||
|
|
||||||
|
@plugins.litElement.property()
|
||||||
|
domtools?: plugins.domtools.DomTools;
|
||||||
|
|
||||||
|
private themeSubscription: plugins.smartrx.rxjs.Subscription;
|
||||||
|
|
||||||
|
constructor() {
|
||||||
|
super();
|
||||||
|
this.domtoolsPromise.then((domtoolsArg) => {
|
||||||
|
this.domtools = domtoolsArg;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
public connectedCallback() {
|
public connectedCallback() {
|
||||||
super.connectedCallback();
|
super.connectedCallback();
|
||||||
this.dispatchEvent(new CustomEvent('domtools-connected'));
|
this.domtoolsPromise.then(async (domtools) => {
|
||||||
|
this.themeSubscription = domtools.themeManager.themeObservable.subscribe((goBrightArg) => {
|
||||||
|
this.goBright = goBrightArg;
|
||||||
|
});
|
||||||
|
});
|
||||||
|
this.dispatchEvent(new CustomEvent('deesElementConnected'));
|
||||||
}
|
}
|
||||||
|
|
||||||
public disconnectedCallback() {
|
public disconnectedCallback() {
|
||||||
super.disconnectedCallback();
|
super.disconnectedCallback();
|
||||||
this.dispatchEvent(new CustomEvent('domtools-disconnected'));
|
this.themeSubscription.unsubscribe();
|
||||||
|
this.dispatchEvent(new CustomEvent('deesElementDisconnected'));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user