mirror of
https://github.com/edward-shen/MMM-pages.git
synced 2024-11-24 11:14:29 -08:00
Update readme.md
- Update name - Update URL to MagicMirror project - Update git URL - Fix typo
This commit is contained in:
parent
a67625905c
commit
b932a674c7
1 changed files with 25 additions and 25 deletions
48
readme.md
48
readme.md
|
@ -1,7 +1,7 @@
|
||||||
## Maintainer needed
|
## Maintainer needed
|
||||||
|
|
||||||
Hello, it's been 5 years since I've written this! While I'm happy to see it
|
Hello, it's been 5 years since I've written this! While I'm happy to see it
|
||||||
thriving, it's also about time I step away. I haven't had a magic mirror up
|
thriving, it's also about time I step away. I haven't had a MagicMirror up
|
||||||
in years, and to be frank, I'm hoping someone else will be willing to take
|
in years, and to be frank, I'm hoping someone else will be willing to take
|
||||||
up maintainership of the project.
|
up maintainership of the project.
|
||||||
|
|
||||||
|
@ -19,10 +19,10 @@ you're interested, please don't hesitate to reach out.
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
# MMM-pages
|
# MMM-Pages
|
||||||
|
|
||||||
This [MagicMirror²][mm] Module allows you to have pages in your magic mirror!
|
This [MagicMirror²][mm] Module allows you to have pages in your MagicMirror!
|
||||||
Want to have more modules in your magic mirror, but want to keep the format?
|
Want to have more modules in your MagicMirror, but want to keep the format?
|
||||||
Or, want to have grouped modules that are themed together? Look no further!
|
Or, want to have grouped modules that are themed together? Look no further!
|
||||||
|
|
||||||
![Example](example.webp)
|
![Example](example.webp)
|
||||||
|
@ -42,7 +42,7 @@ cd ~/MagicMirror/modules
|
||||||
Clone this repository:
|
Clone this repository:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
git clone https://github.com/edward-shen/MMM-pages.git
|
git clone https://github.com/sdetweil/MMM-pages
|
||||||
```
|
```
|
||||||
|
|
||||||
Configure the module in your config.js file.
|
Configure the module in your config.js file.
|
||||||
|
@ -66,7 +66,7 @@ on different pages. (like your calendar on page 1, and someone elses on page 2)
|
||||||
```js
|
```js
|
||||||
modules: [
|
modules: [
|
||||||
{
|
{
|
||||||
module: 'MMM-pages',
|
module: 'MMM-Pages',
|
||||||
config: {
|
config: {
|
||||||
modules:
|
modules:
|
||||||
[[ "newsfeed" ],
|
[[ "newsfeed" ],
|
||||||
|
@ -86,7 +86,7 @@ and alternative approach, is to define a fixed MMM-Pages config
|
||||||
```js
|
```js
|
||||||
modules: [
|
modules: [
|
||||||
{
|
{
|
||||||
module: 'MMM-pages',
|
module: 'MMM-Pages',
|
||||||
config: {
|
config: {
|
||||||
modules:
|
modules:
|
||||||
[[ "page1" ],
|
[[ "page1" ],
|
||||||
|
@ -143,7 +143,7 @@ if u want a modules content on multiple pages the classes would list those page
|
||||||
|
|
||||||
| Option | Type | Default Value | Description |
|
| Option | Type | Default Value | Description |
|
||||||
| --- | --- | --- | --- |
|
| --- | --- | --- | --- |
|
||||||
| `modules` | `[[String...]...]` | `[]` | A 2D String array of what each module should be on which page. Note that all entries must take their class name (e.g. this module's class name is `MMM-pages`, while the default modules may just have `newsfeed`, without the `MMM-` prefix. |
|
| `modules` | `[[String...]...]` | `[]` | A 2D String array of what each module should be on which page. Note that all entries must take their class name (e.g. this module's class name is `MMM-Pages`, while the default modules may just have `newsfeed`, without the `MMM-` prefix. |
|
||||||
| `fixed` | `[String...]` | `["MMM-page-indicator"]` | Which modules should show up all the time. |
|
| `fixed` | `[String...]` | `["MMM-page-indicator"]` | Which modules should show up all the time. |
|
||||||
| `excludes` | *NA* | *NA* | **Deprecated**. Use `fixed` instead. |
|
| `excludes` | *NA* | *NA* | **Deprecated**. Use `fixed` instead. |
|
||||||
| `hiddenPages` | `{String: [String...]...}` | `{}` | An Object defining special `hiddenPages` which are not available on the normal page rotation and only accassible via a notification. Modules defined in `fixed` are ignored and need to be also added if you wish to have them on any hidden page. |
|
| `hiddenPages` | `{String: [String...]...}` | `{}` | An Object defining special `hiddenPages` which are not available on the normal page rotation and only accassible via a notification. Modules defined in `fixed` are ignored and need to be also added if you wish to have them on any hidden page. |
|
||||||
|
@ -161,25 +161,25 @@ should consist of elements that should be on the second page, and so forth.
|
||||||
|
|
||||||
## Notifications
|
## Notifications
|
||||||
|
|
||||||
The following is the list of notifications that MMM-pages will handle:
|
The following is the list of notifications that MMM-Pages will handle:
|
||||||
|
|
||||||
| Notification | Payload type | Description |
|
| Notification | Payload type | Description |
|
||||||
| --- | --- | --- |
|
| --- | --- | --- |
|
||||||
| `PAGE_CHANGED` | `int` | MMM-pages will switch to the provided page index. |
|
| `PAGE_CHANGED` | `int` | MMM-Pages will switch to the provided page index. |
|
||||||
| `PAGE_INCREMENT` | `int`, Optional | MMM-pages will increment the page, or by `n` times if a number is provided. Not providing a number is equivalent to sending a payload of `1`. If there are no more pages to increment by, this will loop around to the first page. |
|
| `PAGE_INCREMENT` | `int`, Optional | MMM-Pages will increment the page, or by `n` times if a number is provided. Not providing a number is equivalent to sending a payload of `1`. If there are no more pages to increment by, this will loop around to the first page. |
|
||||||
| `PAGE_DECREMENT` | `int`, Optional | MMM-pages will decrement the page, or by `n` times if a number is provided. Not providing a number is equivalent to sending a payload of `1`. If there are no more pages to decrement by, this will loop around to the last page. |
|
| `PAGE_DECREMENT` | `int`, Optional | MMM-Pages will decrement the page, or by `n` times if a number is provided. Not providing a number is equivalent to sending a payload of `1`. If there are no more pages to decrement by, this will loop around to the last page. |
|
||||||
| `QUERY_PAGE_NUMBER` | *None* | MMM-pages will respond with `PAGE_NUMBER_IS` with the current page index. |
|
| `QUERY_PAGE_NUMBER` | *None* | MMM-Pages will respond with `PAGE_NUMBER_IS` with the current page index. |
|
||||||
| `PAUSE_ROTATION` | *None* | If MMM-pages is set to rotate, this will pause rotation until a `RESUME_ROTATION` notification is sent. This does nothing if rotation was already paused. |
|
| `PAUSE_ROTATION` | *None* | If MMM-Pages is set to rotate, this will pause rotation until a `RESUME_ROTATION` notification is sent. This does nothing if rotation was already paused. |
|
||||||
| `RESUME_ROTATION` | *None* | If MMM-pages was requested to pause rotation, this will resume automatic rotation. This does nothing MMM-pages was not requested to pause. |
|
| `RESUME_ROTATION` | *None* | If MMM-Pages was requested to pause rotation, this will resume automatic rotation. This does nothing MMM-Pages was not requested to pause. |
|
||||||
| `HOME_PAGE` | *None* | Return to the home page. If no home page is provided, return to the first page instead. |
|
| `HOME_PAGE` | *None* | Return to the home page. If no home page is provided, return to the first page instead. |
|
||||||
| `SHOW_HIDDEN_PAGE` | `String` | MMM-pages will switch to the provided hidden page name. |
|
| `SHOW_HIDDEN_PAGE` | `String` | MMM-Pages will switch to the provided hidden page name. |
|
||||||
| `LEAVE_HIDDEN_PAGE` | *None* | MMM-pages will leave the currently showing hidden page and return to the previous showing page index. |
|
| `LEAVE_HIDDEN_PAGE` | *None* | MMM-Pages will leave the currently showing hidden page and return to the previous showing page index. |
|
||||||
|
|
||||||
The following is the list of notifications that MMM-pages sends out:
|
The following is the list of notifications that MMM-Pages sends out:
|
||||||
|
|
||||||
| Notification | Payload type | Description |
|
| Notification | Payload type | Description |
|
||||||
| ------------------- | ------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------- | ------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `MAX_PAGES_CHANGED` | `int` | This is sent only once during initialization of MMM-pages. This contains the number of pages defined in `config.js`. |
|
| `MAX_PAGES_CHANGED` | `int` | This is sent only once during initialization of MMM-Pages. This contains the number of pages defined in `config.js`. |
|
||||||
| `NEW_PAGE` | `int` | This notification is sent out on every page change and contains the current page index. This is to help other modules keep track of what the current page is. This is also sent out during initialization. |
|
| `NEW_PAGE` | `int` | This notification is sent out on every page change and contains the current page index. This is to help other modules keep track of what the current page is. This is also sent out during initialization. |
|
||||||
| `PAGE_NUMBER_IS` | `int` | Sent in response to a `QUERY_PAGE_NUMBER` notification. Returns the current page index. This notification sends the same payload as `NEW_PAGE`. |
|
| `PAGE_NUMBER_IS` | `int` | Sent in response to a `QUERY_PAGE_NUMBER` notification. Returns the current page index. This notification sends the same payload as `NEW_PAGE`. |
|
||||||
|
|
||||||
|
@ -203,14 +203,14 @@ config in the config file. There is no way to dynamically change the pages you
|
||||||
have. If there arises a need, please create an issue.
|
have. If there arises a need, please create an issue.
|
||||||
|
|
||||||
This module does not enforce how other modules represents or even responds to
|
This module does not enforce how other modules represents or even responds to
|
||||||
MMM-pages notifications.
|
MMM-Pages notifications.
|
||||||
|
|
||||||
### Initialization
|
### Initialization
|
||||||
|
|
||||||
_This section provides documentation on what notifications the module sends on
|
_This section provides documentation on what notifications the module sends on
|
||||||
startup. This section isn't necessary to read for most users._
|
startup. This section isn't necessary to read for most users._
|
||||||
|
|
||||||
MMM-pages doesn't activate until we receive the `DOM_OBJECTS_CREATED`
|
MMM-Pages doesn't activate until we receive the `DOM_OBJECTS_CREATED`
|
||||||
notification, as that notification ensures all modules have been loaded. On this
|
notification, as that notification ensures all modules have been loaded. On this
|
||||||
notification, we send two notifications out, `MAX_PAGES_CHANGED` and `NEW_PAGE`,
|
notification, we send two notifications out, `MAX_PAGES_CHANGED` and `NEW_PAGE`,
|
||||||
so other modules that would like to keep synchronized of the starting page and
|
so other modules that would like to keep synchronized of the starting page and
|
||||||
|
@ -231,11 +231,11 @@ See also FAQ below.
|
||||||
|
|
||||||
- How do I interact with different pages?
|
- How do I interact with different pages?
|
||||||
|
|
||||||
MMM-pages intentionally does not provide methods to interact with the pages.
|
MMM-Pages intentionally does not provide methods to interact with the pages.
|
||||||
This is intentional by design, as there are too many ways to interact with a
|
This is intentional by design, as there are too many ways to interact with a
|
||||||
MagicMirror. [MMM-page-indicator][page indicator] does provide a way to click
|
MagicMirror. [MMM-page-indicator][page indicator] does provide a way to click
|
||||||
on the circles to change pages, but this requires the ability to click or tap
|
on the circles to change pages, but this requires the ability to click or tap
|
||||||
on the circles itself. If no other method is available, MMM-pages provides an
|
on the circles itself. If no other method is available, MMM-Pages provides an
|
||||||
automatic rotation feature.
|
automatic rotation feature.
|
||||||
|
|
||||||
- Help! My module is (above/below) another module in the same region but I want
|
- Help! My module is (above/below) another module in the same region but I want
|
||||||
|
@ -257,5 +257,5 @@ See also FAQ below.
|
||||||
Please make an issue. Thanks!
|
Please make an issue. Thanks!
|
||||||
|
|
||||||
[example_url]: https://www.youtube.com/watch?v=1NQ-sGtdUdg
|
[example_url]: https://www.youtube.com/watch?v=1NQ-sGtdUdg
|
||||||
[mm]: https://github.com/MichMich/MagicMirror
|
[mm]: https://github.com/MagicMirrorOrg/MagicMirror
|
||||||
[page indicator]: https://github.com/edward-shen/MMM-page-indicator
|
[page indicator]: https://github.com/edward-shen/MMM-page-indicator
|
||||||
|
|
Loading…
Reference in a new issue