diff --git a/code/index.css b/code/index.css index 41ceff5..4772854 100644 --- a/code/index.css +++ b/code/index.css @@ -99,5 +99,9 @@ background-image: url("ress/green.png"); background-repeat: no-repeat; background-position: center; - background-size: cover; + } + + .pickr { + width: 30px; + height: 30px; } \ No newline at end of file diff --git a/code/index.php b/code/index.php index 708cbe7..971842f 100644 --- a/code/index.php +++ b/code/index.php @@ -78,16 +78,17 @@ -
Choisir les couleurs des points (ne fonctionne pas en mode "gemmes" ou "les deux")
+
- - - - - - - - +
Choisir les couleurs des points
+ + + + + + + +

diff --git a/code/options.js b/code/options.js index 3bfdf6f..a815aba 100644 --- a/code/options.js +++ b/code/options.js @@ -10,6 +10,7 @@ var span = document.getElementsByClassName("close")[0]; // When the user clicks the button, open the modal btn.onclick = function() { modal.style.display = "block"; + document.getElementById("color_pickers").style.display= (document.getElementById("displays").value!="points" ? "none" : "inline"); } // When the user clicks on (x), close the modal @@ -32,6 +33,10 @@ slider.oninput = function() { output.innerHTML = this.value; } +document.getElementById("displays").addEventListener("click", function(){ + document.getElementById("color_pickers").style.display= (document.getElementById("displays").value!="points" ? "none" : "inline"); +}) + function saveOptions() { setCookie("dotsAmount",document.getElementById("range_dots").value,30); setCookie("displayMode",document.getElementById("displays").value,30); @@ -44,8 +49,9 @@ function saveOptions() { document.getElementById("gem").width=size/6; document.getElementById("dot").style.height=size/6; document.getElementById("dot").style.width=size/6; -document.getElementById("both").style.height=size/6 -document.getElementById("both").style.width=size/6 +document.getElementById("both").style.height=size/6; +document.getElementById("both").style.width=size/6; +document.getElementById("both").style.backgroundSize=size/8+"px"; if(getCookie("pause")!=1) document.getElementById("no_pause").checked=true;