Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/justjim1220/MMM-RandomYouTubePlayer
This module loads a YouTube player and a specified playlist and will randomize the videos.
https://github.com/justjim1220/MMM-RandomYouTubePlayer
3rd-party-modules magic-mirror-modules magicmirror2 youtube-api-v3 youtube-player youtube-playlist
Last synced: 3 months ago
JSON representation
This module loads a YouTube player and a specified playlist and will randomize the videos.
- Host: GitHub
- URL: https://github.com/justjim1220/MMM-RandomYouTubePlayer
- Owner: justjim1220
- License: unlicense
- Created: 2018-05-18T02:22:05.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2019-03-05T18:09:01.000Z (over 5 years ago)
- Last Synced: 2024-06-29T08:36:41.548Z (5 months ago)
- Topics: 3rd-party-modules, magic-mirror-modules, magicmirror2, youtube-api-v3, youtube-player, youtube-playlist
- Language: JavaScript
- Homepage:
- Size: 97.7 KB
- Stars: 15
- Watchers: 5
- Forks: 7
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-mmm - **MMM-RandomYouTubePlayer**
README
# Module: MMM-RandomYouTubePlayer...
The MMM-RandomYouTubePlayer module is a 3rd party module of the MagicMirror
This module loads a YouTube player and a specified playlist and will randomize the videos.## Using the module...
To use this module, add it to the modules array in the 'config/config.js' file:
```
modules: [
{
module: "MMM-RandomYouTubePlayer",
position: "top_center", // This can be any of the regions...
config: {
playlistId: "PLl_KM23gznEAZW-INW8ty4QNaHH8JCnNW", // See Configuration Options below...
height: 480,
width: 720,
}
},
]
```## Install...
```
cd ~/MagicMirror/modules
git clone https://github.com/justjim1220/MMM-RandomYouTubePlayer.git
```## Optional parameters: (defaults for the player as is. change per your needs...)
```
autoplay: true,
disablekb: true,
enablejsapi: true,
color: "red",
fs: false,
volume: "100%",
cc_load_policy: true,
controls: false,
showinfo: false,
rel: false,
modestbranding: true,
loop: true,
```## Configuration Options...
The following properties NEED to be configured:| Config | Description
| --------------------- | ---------------------------------------------------------------------
| playlistId: " " | Youtube playlist id to display. You can get it from youtube url
**Example:** https://www.youtube.com/playlist?list=PLl_KM23gznEAZW-INW8ty4QNaHH8JCnNW
**playlistId:** PLl_KM23gznEAZW-INW8ty4QNaHH8JCnNW (playlist always starts with PL)
| width: 480 | YT player width
**size in pixels per your need**
| height: 700 | YT player height
**size in pixels per your need**## Optional Configuration Options...
The following properties CAN be configured:| Option | Description
| ----------------- | ---------------------------------------------------------------------
| autoplay: true | Autoplays video when it loaded
**true OR false**
| volume: 75%: | Sets the volume at a certain level when starting
**1 to 100 %**
| color: "red" | Player's video progress bar - color can only be "red" or "white
**red or white**
| controls: true | Show youtube video controls bar
**true OR false**
| enablejsapi: true | Enables the player to be controlled via IFrame API calls.
**true OR false**
| disablekb: | Disables keyboard control
**true OR false**
| fs: false | Displays the fullscreen button in player
**true OR false**
| loop: true | Auto-replays video again
**true OR false**
| cc_load_policy: true | Displays captions if available for the video playing
**true OR false**
| modestbranding: false | Prevents the Youtube logo from displaying in the controlbar.
**true OR false**
| rel: true | Shows related videos at the end of video
**true OR false**
| showinfo: true | Shows video title and uploader
**true OR false**## Screenshots...
On my TODO list...
## Known issues...
ONE... Player will only show a max of 200 videos loaded, but it will shuffle through the full playlist.
My current playlist has approx. 1600 videos, and it shuffles through them all.TWO... Player will shuffle the videos, but you will get repeats. (still working on this)
## Acknowledgements...
I used code snippets from the MMM-EmbedYouTube module by @nitpum
And from the MMM-YouTube-API by @C4TFLY
Thanks to them for giving me the snippets I needed to get started on this module!!!
And, I added my own snippets to complete the project!
I also want to thank @cowboysdude and @Mykle for their help as well! You guys are Awesome!!!