Compare commits
10 Commits
79a5397342
...
51a9aa5cc9
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
51a9aa5cc9 | ||
|
|
50bfcae3e5 | ||
|
|
d5fb5308aa | ||
|
|
6e1d78e4bc | ||
|
|
d09d24436b | ||
|
|
c1d4c6f95f | ||
|
|
db03d5a5d3 | ||
|
|
e87b360145 | ||
|
|
6658734774 | ||
|
|
f2e2869bb7 |
2
.github/workflows/release-drafter.yml
vendored
2
.github/workflows/release-drafter.yml
vendored
@@ -20,7 +20,7 @@ jobs:
|
|||||||
# echo "GHE_HOST=${GITHUB_SERVER_URL##https:\/\/}" >> $GITHUB_ENV
|
# echo "GHE_HOST=${GITHUB_SERVER_URL##https:\/\/}" >> $GITHUB_ENV
|
||||||
|
|
||||||
# Drafts your next Release notes as Pull Requests are merged into "master"
|
# Drafts your next Release notes as Pull Requests are merged into "master"
|
||||||
- uses: release-drafter/release-drafter@v5
|
- uses: release-drafter/release-drafter@v6
|
||||||
# (Optional) specify config name to use, relative to .github/. Default: release-drafter.yml
|
# (Optional) specify config name to use, relative to .github/. Default: release-drafter.yml
|
||||||
# with:
|
# with:
|
||||||
# config-name: my-config.yml
|
# config-name: my-config.yml
|
||||||
|
|||||||
1
.gitignore
vendored
1
.gitignore
vendored
@@ -4,3 +4,4 @@ npm-debug.log
|
|||||||
package-lock.json
|
package-lock.json
|
||||||
pm2.json
|
pm2.json
|
||||||
workspace.code-workspace
|
workspace.code-workspace
|
||||||
|
.DS_Store
|
||||||
|
|||||||
@@ -147,7 +147,13 @@ Module.register("MMM-HomeAssistantDisplay", {
|
|||||||
if (payload.identifier === this.identifier) {
|
if (payload.identifier === this.identifier) {
|
||||||
switch (notification) {
|
switch (notification) {
|
||||||
case "MODULE_DISPLAY_RENDERED":
|
case "MODULE_DISPLAY_RENDERED":
|
||||||
this.displayModule = payload.render.toLowerCase() === "true" || payload.render.toLowerCase() === "on";
|
|
||||||
|
if (payload.render.toLowerCase() === "true" || payload.render.toLowerCase() === "on"){
|
||||||
|
this.displayModule = true;
|
||||||
|
}else {
|
||||||
|
this.displayModule = false;
|
||||||
|
}
|
||||||
|
|
||||||
this.updateDom();
|
this.updateDom();
|
||||||
break;
|
break;
|
||||||
case "CHANGED_STATE":
|
case "CHANGED_STATE":
|
||||||
|
|||||||
17
README.md
17
README.md
@@ -15,7 +15,7 @@ Templates allow you to output virtually any HTML you want to in the contents of
|
|||||||
* [Simple Hiding](#simple-hiding)
|
* [Simple Hiding](#simple-hiding)
|
||||||
* [Media Info when Playing](#media-info-when-playing)
|
* [Media Info when Playing](#media-info-when-playing)
|
||||||
* [Always Displayed with Complex Template](#always-displayed-with-complex-template)
|
* [Always Displayed with Complex Template](#always-displayed-with-complex-template)
|
||||||
* [Programatic Sections](#programatic-sections)
|
* [Programmatic Sections](#programmatic-sections)
|
||||||
* [License](#license)
|
* [License](#license)
|
||||||
|
|
||||||
### Features:
|
### Features:
|
||||||
@@ -28,8 +28,15 @@ Templates allow you to output virtually any HTML you want to in the contents of
|
|||||||
* Material Design icons embedded in module to use with output.
|
* Material Design icons embedded in module to use with output.
|
||||||
|
|
||||||
### How to use
|
### How to use
|
||||||
1. Clone this repo into your Magic Mirrors modules directory with the following command: git clone https://github.com/wonderslug/MMM-HomeAssistantDisplay.git.
|
1. Clone this repo into your Magic Mirrors modules directory with the following command:
|
||||||
2. Install all the npm modules with *npm install*.
|
```bash
|
||||||
|
git clone https://github.com/wonderslug/MMM-HomeAssistantDisplay.git
|
||||||
|
```
|
||||||
|
.
|
||||||
|
2. Install all the npm modules with:
|
||||||
|
```bash
|
||||||
|
npm install
|
||||||
|
```
|
||||||
3. Update your Magic Mirror Configto setup a Module Instance. See the configuration options and examples below.
|
3. Update your Magic Mirror Configto setup a Module Instance. See the configuration options and examples below.
|
||||||
|
|
||||||
### Configuration Options
|
### Configuration Options
|
||||||
@@ -212,9 +219,9 @@ This example will show a complex template logic that is always displayed because
|
|||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
#### Programatic Sections
|
#### Programmatic Sections
|
||||||
|
|
||||||
Programatic setting of sections from long list for always displayed module:
|
Programmatic setting of sections from long list for always displayed module:
|
||||||
|
|
||||||
This shows how you can use code to set the configuration for the module. It takes a long list of entities to watch and sets each of them as a section of the module to display only when opened.
|
This shows how you can use code to set the configuration for the module. It takes a long list of entities to watch and sets each of them as a section of the module to display only when opened.
|
||||||
|
|
||||||
|
|||||||
@@ -33,8 +33,8 @@
|
|||||||
"grunt-markdownlint": "latest",
|
"grunt-markdownlint": "latest",
|
||||||
"grunt-stylelint": "latest",
|
"grunt-stylelint": "latest",
|
||||||
"grunt-yamllint": "latest",
|
"grunt-yamllint": "latest",
|
||||||
"stylelint": "^14.16.1",
|
"stylelint": "latest",
|
||||||
"stylelint-config-standard": "^34.0.0",
|
"stylelint-config-standard": "latest",
|
||||||
"time-grunt": "latest"
|
"time-grunt": "latest"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user