Read the statement by Michael Teeuw here.
MMM-Page-Selector: A page switcher that can set positions of modules
-
@veldrovive said in MMM-Page-Selector: A page switcher that can set positions of modules:
MMM-Page-Selector
This is exactly what I was looking for. I am building a Leap Motion Module ( for native Leap app on Windows, MacOS, etc … not Raspberry Pi ) that detects swipe gestures.
I will release that in the next few days and make a comment on here about it. But essentially you swipe left to go to a previous page, swipe right to go to the next, etc.
My Smart Mirror is going in a bathroom, and I wanted a way to navigate the pages without having to touch anything, including the mirror. This actually works pretty well.
I found your repo on GitHub a few days ago and have already been messing with it, and was trying to work out some bugs with the old
pages
prop you used to have on your module, but this new method of moving thepages
to the modules we want to embed is much cleaner.Bravo.
-
Just pushed up the Leap Motion Controller Module. Added a code snippet on how to get it to work with your module:
-
@mrmidi said in MMM-Page-Selector: A page switcher that can set positions of modules:
I’m glad that you’re finding this module useful. I usually only get to work on these types of projects in bursts so it’s good that I happened to get an update out to shift the pages configuration to something a little more… not horrible.
I think I have a leap controller around somewhere so I’m going to have to dig it out and try your module.
My next update is going to be a system to specify custom notification names so PAGE_SELECT isn’t mandatory and incrementing and decrementing pages is easier. Using the new system, it should be easy to interface with your module just through the config.
-
Hi,
Anyone have real exemple to use this ?
-
a example of the config from Veldrovive want be nice
-
Good news for al beginers :-)
Veldrovive has published an config example on his github page.
Look there under issues. -
I can’t get this to work on my mirrror.
I don’t know what can be missing.
I have installed both MMM-Page-Selector and MMM-page-indicator. The Indicator shows up nice and easy, but I have create 3 pages and it only shows 2 and when I click one of the circles from MMM-Page-indicator it does not switch page.I have tried to use MMM-Pages and there it works just fine.
My config is for MMM-Page_selector is:
{ module: "MMM-Page-Selector", position: "top_bar", config: { defaultPage: "domoticz", displayTitle: true, selectPageNotif: ["SELECT_PAGE"], incrementPageNotif: ["PAGE_UP"], decrementPageNotif: ["PAGE_DOWN"] } },
and my config for MMM-page-indicator is:
{ module: "MMM-page-indicator", position: "bottom_bar", pages: "all", config: { pages: 3, } }
I have tried with and without pages:3 in the MMM-page-indicator config
Greatful for some guidens
/Peter
-
Sorry for taking a bit to get back to you.
You shouldn’t need to put thepages: 3
in the Page Indicator config as that should be handled automatically.
In order to get at the root of the problem, I would need to have the configs for you other modules since all pages are implicitly declared to exist inside thepages
object of your modules.
For example:{ module: "MMM-a-module", position: "bottom_center", pages: {"pageOne": "top_center", "pageTwo": "bottom_left"}, config: {} },
is defining two pages with the names
pageOne
andpageTwo
and then saying that this module will appear at thetop_center
andbottom_left
positions on those two pages respectively.
I am assuming that something went wrong with thepages
objects which is causing some problems.
If you post those I will probably be able to figure out the problem. -
Hello Veldrovive,
I also have a hard time with the config. But am still on the build.
The implementation is very complicated with many modules the overview is lost. All lines must also be marked with “” signs.But that’s just the way with the codes :-)
What would be great if you had a main config and for each additional page its own config which is then read out.
Would make the whole course very clear.
Even more if you did not need to provide the entire modules and each line with extra signs.That’s just wishful thinking, of course. ;-)
Nevertheless! A great module
Thank you -
Hey Robiv8,
First, I will address a couple of things.All lines must also be marked with “” signs:
To be clear, it is not necessary to put quotes around page names or props. For example:
"pages": {"main": "top_right", "fun": "top_left"}
is exactly the same as
pages: {main: "top_right", fun: "top_left"}
I just believe that it is more clear for everything to be specified as strings.Even more if you did not need to provide the entire modules and each line with extra signs:
Could you elaborate a little bit about what this means? What do you mean when you say each line with extra signs?What would be great if you had a main config and for each additional page its own config which is then read out:
I’m still very much open to developing this further and possibly adding more ways to create pages.
I think I get the idea that when you have many modules it can be hard to keep track of what modules have been put on what pages and where, but I am unclear on what exactly you are suggesting.One idea that I had during development was to have a pages section in the config.js like this:
address: "localhost", port: 8081, ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1"], modules: [ ... ], pages: { "main": { "calendar": "top_left", "MMM-Bob-Ross": "bottom_left", "clock": "top_right", "weatherforecast": "bottom_right", "newsfeed": "bottom_center" }, "fun": { "clock": "top_left", "MMM-Lunartic": "bottom_right", "MMM-Astronauts": "bottom_left", "MMM-Reddit": "top_right" } }
In order to condense the page config down when there are just too many modules to handle. Something like this would be very easy to implement.
Is this along the lines of what you were suggesting?