Improve mod-card. Bugfix.
This commit is contained in:
parent
501a52d562
commit
050f8627f8
File diff suppressed because one or more lines are too long
2
package-lock.json
generated
2
package-lock.json
generated
@ -627,7 +627,7 @@
|
|||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"card-tools": {
|
"card-tools": {
|
||||||
"version": "github:thomasloven/lovelace-card-tools#4bcbb48158dc6ee1cfa767c25125fe84c0ea32df",
|
"version": "github:thomasloven/lovelace-card-tools#605caa906c46340599614aaf9d4e934aabc19b15",
|
||||||
"from": "github:thomasloven/lovelace-card-tools"
|
"from": "github:thomasloven/lovelace-card-tools"
|
||||||
},
|
},
|
||||||
"chalk": {
|
"chalk": {
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "webpack",
|
"build": "webpack",
|
||||||
"watch": "webpack --watch --mode=development",
|
"watch": "webpack --watch --mode=development",
|
||||||
"test": "echo \"Error: no test specified\" && exit 1"
|
"update-card-tools": "npm uninstall card-tools && npm install thomasloven/lovelace-card-tools"
|
||||||
},
|
},
|
||||||
"keywords": [],
|
"keywords": [],
|
||||||
"author": "Thomas Lovén",
|
"author": "Thomas Lovén",
|
||||||
|
@ -8,10 +8,14 @@ ha-card {
|
|||||||
}`;
|
}`;
|
||||||
|
|
||||||
class ModCard extends LitElement {
|
class ModCard extends LitElement {
|
||||||
|
static get properties() {
|
||||||
|
return {
|
||||||
|
hass: {},
|
||||||
|
};
|
||||||
|
}
|
||||||
setConfig(config) {
|
setConfig(config) {
|
||||||
this._config = config;
|
this._config = config;
|
||||||
if(!config.style === undefined)
|
if(config.style === undefined)
|
||||||
{
|
{
|
||||||
this._config.style = NO_STYLE;
|
this._config.style = NO_STYLE;
|
||||||
} else if (typeof(config.style) === "string") {
|
} else if (typeof(config.style) === "string") {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user