mirror of
https://github.com/IrosTheBeggar/mStream.git
synced 2025-10-27 07:31:02 +00:00
Remove outadted docs
This commit is contained in:
parent
e5bb53113d
commit
8e9c88ada8
103
docs/SKININNG.md
103
docs/SKININNG.md
@ -1,103 +0,0 @@
|
||||
## Skinning
|
||||
|
||||
#### Step 1: Download and Setup the Stack
|
||||
- mstream.player.js and mstream.api.js
|
||||
- VueJS
|
||||
- Sortable JS & Vue Draggable
|
||||
- Aurora and Flac JS
|
||||
- Howler JS
|
||||
|
||||
|
||||
There's a lot in that stack:
|
||||
- mstream.player.js creates a global MSTREAM module that contains a fully functional media player and playlist
|
||||
- Howler, Aurora, and Flac JS are all dependencies of mstream.player.js
|
||||
- You can read the API for this module here: ['TODO: PUT URL HERE']
|
||||
- mstream.api.js creates a global MSTREAMAPI module that is used to manage and query mStream servers
|
||||
- VueJS is what we will use to bind the MSTREAM module the HTML
|
||||
- SortableJS and Vue Draggable add drag and drop functionality to the playlist
|
||||
|
||||
|
||||
Now make an html file with the following
|
||||
```
|
||||
<head>
|
||||
<!-- mStream CSS -->
|
||||
<link rel="stylesheet" href="/public-shared/css/mstream.css">
|
||||
<!-- Pure CSS -->
|
||||
<link rel="stylesheet" href="https://unpkg.com/purecss@0.6.1/build/pure-min.css" integrity="sha384-CCTZv2q9I9m3UOxRLaJneXrrqKwUNOzZ6NGEUMwHtShDJ+nCoiXJCAgi05KfkLGY" crossorigin="anonymous">
|
||||
|
||||
<!--
|
||||
This is the mStream Player stack
|
||||
DO NOT Change to order these are loaded in
|
||||
You do not need to worry about how these work
|
||||
-->
|
||||
<script src="/js/aurora.js"></script>
|
||||
<script src="/js/flac.js"></script>
|
||||
<script src="/js/howler.core.min.js"></script>
|
||||
<script src="/js/mstream.js"></script>
|
||||
<script src="/js/mstream.api.js"></script>
|
||||
|
||||
<!-- Vue JS -->
|
||||
<script src="https://unpkg.com/vue/dist/vue.js"></script>
|
||||
<!-- Sortable JS -->
|
||||
<script src="https://unpkg.com/sortablejs@latest"></script>
|
||||
<!-- https://github.com/SortableJS/Vue.Draggable - v2.6 -->
|
||||
<script src="/public-shared/js/vue-sortable.js"></script>
|
||||
|
||||
</head>
|
||||
```
|
||||
|
||||
|
||||
#### Step 2: Make a Playlist
|
||||
Add the playlist HTML
|
||||
```
|
||||
<!-- Playlist -->
|
||||
<div class="playlist-container">
|
||||
<draggable :list="playlist" @end="checkMove" id="playlist">
|
||||
<div v-for="(song, index) in playlist" is="playlist-item" :key="index" :index="index" :text="song.filepath" :active="(index == current) ? 'theclass' : 'noclass'">
|
||||
</div>
|
||||
</draggable>
|
||||
</div>
|
||||
```
|
||||
|
||||
There's a lot going on here. The draggable element is used by Sortable JS to make a the list inside it have drag and drop capability. The rest of the bizare syntax is used by VueJS
|
||||
|
||||
```
|
||||
// Highlight currently playing song
|
||||
Vue.component('playlist-item', {
|
||||
template: '\
|
||||
<div class="playlist-item" v-bind:class="{ playing: (index2 == active2.val) }" >\
|
||||
<span v-on:click="goToSong($event)" class="song-area">{{ text }}</span> <span v-on:click="removeSong($event)" class="removeSong">X</div>\
|
||||
</div>\
|
||||
',
|
||||
props: ['text', 'active', 'index', 'current', 'drag'],
|
||||
data: function(){
|
||||
return {
|
||||
active2: MSTREAM.positionCache,
|
||||
index2: this.index,
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
goToSong: function(event){
|
||||
MSTREAM.goToSongAtPosition(this.index);
|
||||
},
|
||||
removeSong: function(event){
|
||||
MSTREAM.removeSongAtPosition(this.index, false);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
// Code to update playlist
|
||||
var playlistElement = new Vue({
|
||||
el: '#playlist',
|
||||
data: {
|
||||
playlist: MSTREAM.playlist,
|
||||
current: MSTREAM.positionCache,
|
||||
},
|
||||
methods: {
|
||||
checkMove: function (event) {
|
||||
MSTREAM.resetPositionCache();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
```
|
||||
@ -1,28 +0,0 @@
|
||||
{
|
||||
"port":3031,
|
||||
"users":{
|
||||
"paul":{
|
||||
"password":"glassjar98",
|
||||
"email":"paul@wall.com",
|
||||
"musicDir":"/path/to/music",
|
||||
},
|
||||
"paul2":{
|
||||
"password":"glassjar98",
|
||||
"email":"paul@wall2.com",
|
||||
"musicDir":"/path/to/music2",
|
||||
},
|
||||
"paul2-guest":{
|
||||
"password":"glassjar98",
|
||||
"guestTo":"paul2",
|
||||
}
|
||||
},
|
||||
"userinterface":"public",
|
||||
"database_plugin":{
|
||||
"type":"sqlite",
|
||||
"dbPath":"/path/to/db",
|
||||
},
|
||||
"tunnel":{
|
||||
"refreshInterval":10000,
|
||||
"protocol":"upnp"
|
||||
}
|
||||
}
|
||||
@ -1,56 +0,0 @@
|
||||
{
|
||||
"port":3031,
|
||||
"users":{
|
||||
"paul":{
|
||||
"password":"glassjar98",
|
||||
"email":"paul@wall.com",
|
||||
"musicDir":"/path/to/music",
|
||||
"privateDBOptions":{
|
||||
"privateDB":"BEETS",
|
||||
"importDB":"path/to/sqlite3.db",
|
||||
"beetsCommand":"Run This Command Update Call",
|
||||
"quickSync": true,
|
||||
},
|
||||
"bannedGuestFunctions":"todo. make this optional",
|
||||
"vPath":"UUID-GOES-HERE"
|
||||
},
|
||||
"paul2":{
|
||||
"password":"glassjar98",
|
||||
"email":"paul@wall2.com",
|
||||
"musicDir":"/path/to/music2",
|
||||
},
|
||||
"paul2-guest":{
|
||||
"password":"glassjar98",
|
||||
"guestTo":"paul2",
|
||||
}
|
||||
},
|
||||
"userinterface":"public",
|
||||
"database_plugin":{
|
||||
"type":"sqlite",
|
||||
"dbPath":"/path/to/db",
|
||||
},
|
||||
"database_plugin-BEETS":{
|
||||
"type":"beets",
|
||||
"dbPath":"/path/to/db",
|
||||
"beetsCommand":""
|
||||
},
|
||||
"database_plugin-MYSQL":{
|
||||
"type":"mysql",
|
||||
"username":"lol",
|
||||
"password":"lol",
|
||||
"db-name":"lolDB"
|
||||
},
|
||||
"database_plugin-LOKI":{
|
||||
"comming":"soon",
|
||||
},
|
||||
"secret":"Secret for JSON web token",
|
||||
"tunnel":{
|
||||
"gateway":"1.1.1.1",
|
||||
"refreshInterval":10000,
|
||||
"protocol":"upnp"
|
||||
},
|
||||
"salt":"Salt for passwords. optional. Necessarry forthe noHash function which allows hashed passwords to be stored in users array",
|
||||
"noHash":true,
|
||||
"ssl":"SSL OPTIONS"
|
||||
|
||||
}
|
||||
@ -1 +0,0 @@
|
||||
"{'code':55414, "command":{"action":"next"}}"
|
||||
@ -1,4 +0,0 @@
|
||||
{
|
||||
"port":5060,
|
||||
"userinterface":"public",
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user