delete
Announcement
Collapse
No announcement yet.
Announce: Material Skin
Collapse
X
-
Code:{ "title":"Artist Radio", "script":"lmsCommand('$ID', ['dynamicplaylist', 'playlist', 'play', 'dpldefault_zz_CONTEXTMENU_for_selected_artist_a01_songs_random', 'dynamicplaylist_parameter_1:$ARTISTID']); setTimeout(() => lmsCommand('$ID', ['dynamicplaylist', 'playlist', 'stop']), 10000)", "icon":"queue_music" },
Code:{ "title":"Artist Radio", "script":"let artistRadioId=$ID; lmsCommand(artistRadioId, ['dynamicplaylist', 'playlist', 'play', 'dpldefault_zz_CONTEXTMENU_for_selected_artist_a01_songs_random', 'dynamicplaylist_parameter_1:$ARTISTID']); setTimeout(() => lmsCommand(artistRadioId, ['dynamicplaylist', 'playlist', 'stop']), 10000)", "icon":"queue_music" }
Code:lmsCommand('', [...]).then(({data}) => { // Next command here... });
Material debug: 1. Launch via http: //SERVER:9000/material/?debug=json (Use http: //SERVER:9000/material/?debug=json,cometd to also see update messages, e.g. play queue) 2. Open browser's developer tools 3. Open console tab in developer tools 4. REQ/RESP messages sent to/from LMS will be logged here.Comment
-
Android 12 update appeared on my Pixel phone today. Material seems to have come through it fine. There is a small change in behavior of "Material as screensaver", though. When woken up, rather than waking direct to Material there is a very slight delay as Material sweeps in from the right. I think I prefer the old behavior, but I'll get used to the new way.Comment
-
I think the replacement of "$ID" only works for the fist occurance - will fix for next release. For now, however, you could just use a variable. e.g. (untested):
[code]
{
"title":"Artist Radio",
"script":"let artistRadioId=$ID; lmsCommand(artistRadioId, ['dynamicplaylist', 'playlist', 'play', 'dpldefault_zz_CONTEXTMENU_for_selected_artist_a01 _songs_random', 'dynamicplaylist_parameter_1:$ARTISTID']); setTimeout(() => lmsCommand(artistRadioId, ['dynamicplaylist', 'playlist', 'stop']), 10000)",
"icon":"queue_music"
}
Also using the "lmscommand": method is working on 2.7.1Comment
-
I tried using a variable as you suggested above but it did not work. It gave many json errors in the dev terminal but I didn't have time to go through them. I will try to get you an example of the errors later. Either way for the moment luckily using $ID and then $NAME is working for what I wanted to do.
Also using the "lmscommand": method is working on 2.7.1Material debug: 1. Launch via http: //SERVER:9000/material/?debug=json (Use http: //SERVER:9000/material/?debug=json,cometd to also see update messages, e.g. play queue) 2. Open browser's developer tools 3. Open console tab in developer tools 4. REQ/RESP messages sent to/from LMS will be logged here.Comment
-
2.7.2 Release
Bug-fix release, changes:
- Translation updates.
- When replacing strings in custom actions replace all occurances.
- Handle 'nextWindow' when browsing if no items are returned.
- Update Roboto fonts.
- Allow multiple characters when jumping in list via keypress.
Material debug: 1. Launch via http: //SERVER:9000/material/?debug=json (Use http: //SERVER:9000/material/?debug=json,cometd to also see update messages, e.g. play queue) 2. Open browser's developer tools 3. Open console tab in developer tools 4. REQ/RESP messages sent to/from LMS will be logged here.Comment
-
Craig, Thanks for your input on my other thread to use material skin actions.json to execute a shell script.
I have now created file named "actions.json" within a "material-skin" sub-folder in my LMS's preferences folder - a simple iframe/weblink to see if the link is displayed under the top level of the main menu (accessed via the three-dotted icon top right). However I still dont see the links getting displayed. Wondering if I am doing something wrong here as Material is not picking up the .json. I have tried restarting the server a few times.
I have LMS(V 8.1.1) and Squeezelite running on a raspberry pi(3b) with nanosound DAC2 .
Code:{ "system":[ { "title":"A page to embed in Material", "iframe":"http://www.nhk.jp", "locked":true, "icon":"link", "toolbar":{ "title":"Title \u2022 $NAME" } { "title":"NHK - A page to launch in a new window/tab", "weblink":"http://www.nhk.jp" }, ], }
Comment
-
Craig, Thanks for your input on my other thread to use material skin actions.json to execute a shell script.
I have now created file named "actions.json" within a "material-skin" sub-folder in my LMS's preferences folder - a simple iframe/weblink to see if the link is displayed under the top level of the main menu (accessed via the three-dotted icon top right). However I still dont see the links getting displayed. Wondering if I am doing something wrong here as Material is not picking up the .json. I have tried restarting the server a few times.
I have LMS(V 8.1.1) and Squeezelite running on a raspberry pi(3b) with nanosound DAC2 .
Try this...
Code:{ "system":[ { "title":"A page to embed in Material", "iframe":"http://www.nhk.jp", "locked":true, "icon":"link", "toolbar":{ "title":"Title \u2022 $NAME" }, { "title":"NHK - A page to launch in a new window/tab", "weblink":"http://www.nhk.jp" } ] }
Also there should not be a comma after the last ] unless you are going to ad another section such as ArtistLast edited by shinedou; 2021-10-24, 03:58.Comment
-
In my special case of playing an Audiobook, can the skip back/forward buttons be modified to jump 15 or 30 secs rather than next/previous track?
I thought there was a setting to adjust this but I can't find it.------------------------------------------------------------------------------------Comment
-
You need to long-press (press and hold) the buttons for this.Material debug: 1. Launch via http: //SERVER:9000/material/?debug=json (Use http: //SERVER:9000/material/?debug=json,cometd to also see update messages, e.g. play queue) 2. Open browser's developer tools 3. Open console tab in developer tools 4. REQ/RESP messages sent to/from LMS will be logged here.Comment
-
Code:curl 'http://localhost:9000/jsonrpc.js' --data-raw '{"id":0,"method":"slim.request","params":["",["material-skin", "send-notif", "type:alert", "msg:Hello world"]]}'
Material debug: 1. Launch via http: //SERVER:9000/material/?debug=json (Use http: //SERVER:9000/material/?debug=json,cometd to also see update messages, e.g. play queue) 2. Open browser's developer tools 3. Open console tab in developer tools 4. REQ/RESP messages sent to/from LMS will be logged here.Comment
-
Any chance of adding this to Material Skin
I use Material Skin on my phone almost exclusively to control my SB's and love it. Is there any chance of adding a button or menu option to cycle through the available 'Now Playing' views in piCorePlayer? Same as the 'Now Playing' button on the SB remotes.
Thanks for any consideration.
HowardComment
-
Material debug: 1. Launch via http: //SERVER:9000/material/?debug=json (Use http: //SERVER:9000/material/?debug=json,cometd to also see update messages, e.g. play queue) 2. Open browser's developer tools 3. Open console tab in developer tools 4. REQ/RESP messages sent to/from LMS will be logged here.Comment
-
Ya know, I'm not sure where the 'Now Playing' screen saver resides. The VU meters are in Jivelite, but I'm not sure that's where the screen savers are controlled from. I know that the SB remote as for the SB3, etc. have a button that changes the screen screen view on most of the Squeeze boxes inclusive of the Transporter. It's the same function if you are using a touch screen and you touch the middle of the screen.
Anyway, I'll take a peak at the link you supplied, although I am a complete luddite, maybe I can figure something out.
Thanks,
Howard
You mean add a button to control Jivelite? I have no such device, so would have no idea how this could be done. Still, having one UI to control another seems a bit odd. You can however, probably use Material's custom actions to achieve this. For more details refer to see https://github.com/CDrummond/lms-mat...-CustomisationComment
Comment