This commit is contained in:
Nicolas A. Tonne
2015-04-15 02:05:17 +02:00
parent 7419c18427
commit dcaab7d0e7
6 changed files with 178 additions and 38 deletions

View File

@@ -80,6 +80,14 @@ main {
height: 120px;
}
.white-bg{
background-color:white;
}
.white-bg:hover{
background-color:white;
}
.card .card-content {
padding: 10px 20px;
}
@@ -161,8 +169,9 @@ hide mdi-action-visibility mdi-action-visibility-off
float: left;
}
.list-song{background-color: rgba(255, 255, 255, 0.1);}
.card .card-content{padding:0;}
.list-song .card-content{padding:0;}
.list-title{
display:block;
color:white;font-size:1em;
@@ -185,4 +194,31 @@ hide mdi-action-visibility mdi-action-visibility-off
}
.result_info{margin-top:-36px;}
/** settings **/
#settings-button{color:white !important;}
.setting-text {
font-size: 13px !important;
padding: 0 !important;
}
.switch{
display: inline;
float: right;
}
.switch label .lever {
background-color: #00B2FF;
}
.switch label input[type=checkbox]:checked + .lever {
background-color: #5ADB74;
}
.switch label input[type=checkbox]:checked + .lever:after {
background-color: white;
}
.switch label {
color:#848484;
}

View File

@@ -11,29 +11,11 @@ socket.on("toast", function(msg)
remove_bar();*/
});
function admin()
{
adminTogg = !adminTogg;
if(adminTogg)
{
if(find)
{
eH = -10;
}else
eH = 30;
$("#playlist").height($("#player").height()-290+eH); //opening
}else if(!adminTogg)
{
if(find)
{
eH = -10;
}else
eH = 30;
$("#playlist").height($("#player").height()+eH); //closing
}
$("#adminPanel").toggleClass("hiddenAdmin");
}
//function used in html onlick
function save(){
submitAdmin($("#adminForm"));
}
function submitAdmin(form)
{
@@ -48,10 +30,14 @@ function submitAdmin(form)
shuffling = form.shuffle.value;
configs = [voting, addsongs, longsongs, frontpage, allvideos, removeplay, adminpass, skipping, shuffling];
alert(configs)
socket.emit("conf", configs);
}
function hide_settings(){
$('#settings').sideNav('hide');
}
function remove_bar()
{
setTimeout(function(){

View File

@@ -45,7 +45,6 @@ function populate_list(msg)
names=["vote","addsongs","longsongs","frontpage", "allvideos", "removeplay", "skip", "shuffle"];
for (var i = 0; i < names.length; i++) {
document.getElementsByName(names[i])[0].checked = (listeID[names[i]] === 'true');
document.getElementsByName(names[i])[1].checked = (listeID[names[i]] === 'false');
}
if(hasadmin)
@@ -63,6 +62,7 @@ function populate_list(msg)
$("#wrapper").append(list_html);
var song = $("#list-song");
song.find(".list-title").text(video_title);
song.find(".list-title").attr("title", video_title);
song.find(".list-votes").text(video_votes);
song.find(".votebg").attr("onclick", "vote('"+video_id+"','pos')");
song.find(".list-image").attr("style",video_thumb);

View File

@@ -77,7 +77,13 @@ socket.on(chan.toLowerCase()+",viewers", function(view)
$(document).ready(function()
{
$("#settings").sideNav();
$("#settings").sideNav({
menuWidth: 300, // Default is 240
edge: 'right', // Choose the horizontal origin
closeOnClick: false // Closes side-nav on <a> clicks, useful for Angular/Meteor
});
$('#settings-close').sideNav('hide');
colorThief = new ColorThief();
window.mobilecheck = function() {
var check = false;