mirror of
https://github.com/edward-shen/MMM-pages.git
synced 2024-12-22 00:35:09 -08:00
Add callback to hide and show
The callback is only optional, if you don't use the options. https://docs.magicmirror.builders/development/core-module-file.html#this-hide-speed-callback-options Without this change you can see an error message in the browser console: "callback is not an optional parameter!"
This commit is contained in:
parent
347c9bd78c
commit
00800b9ac4
1 changed files with 2 additions and 2 deletions
|
@ -212,13 +212,13 @@ Module.register('MMM-pages', {
|
||||||
|
|
||||||
MM.getModules()
|
MM.getModules()
|
||||||
.exceptWithClass(modulesToShow)
|
.exceptWithClass(modulesToShow)
|
||||||
.enumerate(module => module.hide(animationTime, lockStringObj));
|
.enumerate(module => module.hide(animationTime, () => {}, lockStringObj));
|
||||||
|
|
||||||
// Shows all modules meant to be on the current page, after a small delay.
|
// Shows all modules meant to be on the current page, after a small delay.
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
MM.getModules()
|
MM.getModules()
|
||||||
.withClass(modulesToShow)
|
.withClass(modulesToShow)
|
||||||
.enumerate(module => module.show(animationTime, lockStringObj));
|
.enumerate(module => module.show(animationTime, () => {}, lockStringObj));
|
||||||
}, animationTime);
|
}, animationTime);
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue