mirror of
https://github.com/2009scape/2009scape.github.io.git
synced 2024-10-05 15:07:16 +02:00
After a long time, the slider now has a better style :)
This commit is contained in:
parent
669f672c6b
commit
0b57aece5c
@ -85,7 +85,7 @@ hiscores.initalizeRightsideButtons = () => {
|
||||
|
||||
document.getElementById("filter_submit").addEventListener("click", function (e) {
|
||||
e.preventDefault();
|
||||
let pageRemovedFiltersLocation = window.location.search.split(/\?iron=[A-z]+|\?ultiron=[A-z]+|\?hciron=[A-z]+|\?maxXP=\d+/).join('');
|
||||
let pageRemovedFiltersLocation = window.location.search.split(/\?iron=[A-z]+|\?ultiron=[A-z]+|\?hciron=[A-z]+|\?maxXP=[\d\.]+/).join('');
|
||||
const ironparam = `?iron=${document.getElementById('check_iron').checked}`;
|
||||
const ultironparam = `?ultiron=${document.getElementById('check_ultiron').checked}`;
|
||||
const hcironparam = `?hciron=${document.getElementById('check_hciron').checked}`;
|
||||
|
@ -598,28 +598,28 @@ English
|
||||
onclick="document.getElementById('check_iron').checked = !document.getElementById('check_iron').checked">
|
||||
<img src="../../site/img/osrsimg/ironman.png" style="height: 11px;">
|
||||
<input type="checkbox" name="check_iron" id="check_iron" value="1" class="checkbox"
|
||||
style="pointer-events: none;" checked>
|
||||
style="pointer-events: none;">
|
||||
</td>
|
||||
<td onmouseover="this.style.background='rgba(20, 20, 20, 0.3)';"
|
||||
onmouseout="this.style.background='rgba(0, 0, 0, 0)';"
|
||||
onclick="document.getElementById('check_ultiron').checked = !document.getElementById('check_ultiron').checked">
|
||||
<img src="../../site/img/osrsimg/ultimateironman.png" style="height: 11px;">
|
||||
<input type="checkbox" name="check_ultiron" id="check_ultiron" value="1" class="checkbox"
|
||||
style="pointer-events: none;" checked>
|
||||
style="pointer-events: none;">
|
||||
</td>
|
||||
<td onmouseover="this.style.background='rgba(20, 20, 20, 0.3)';"
|
||||
onmouseout="this.style.background='rgba(0, 0, 0, 0)';"
|
||||
onclick="document.getElementById('check_hciron').checked = !document.getElementById('check_hciron').checked">
|
||||
<img src="../../site/img/osrsimg/hcim.png" style="height: 11px;">
|
||||
<input type="checkbox" name="check_hciron" id="check_hciron" value="1" class="checkbox"
|
||||
style="pointer-events: none;" checked>
|
||||
style="pointer-events: none;">
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<table class="center" style="margin: 0 auto; padding-top: 4px;">
|
||||
<tr>
|
||||
<td>
|
||||
<input id="maxXP" type="range" min="1" max="10" value="10" step="0.5"
|
||||
<input class="nonBlueInputSlider" id="maxXP" type="range" min="1" max="10" value="10" step="0.5"
|
||||
oninput="this.nextElementSibling.nextElementSibling.value = this.value % 1 != 0 ? this.value : this.value + '.0'">
|
||||
<br>
|
||||
Max XP Rate: <output id="maxXPoutput">10</output>
|
||||
|
@ -786,3 +786,100 @@
|
||||
.alR {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
input[type=range] {
|
||||
width: 100%;
|
||||
margin: 5.3px 0;
|
||||
background-color: transparent;
|
||||
-webkit-appearance: none;
|
||||
}
|
||||
input[type=range]:focus {
|
||||
outline: none;
|
||||
}
|
||||
input[type=range]::-webkit-slider-runnable-track {
|
||||
background: rgba(232, 222, 196, 0.78);
|
||||
border: 1px solid #010101;
|
||||
border-radius: 8.1px;
|
||||
width: 100%;
|
||||
height: 11.4px;
|
||||
cursor: pointer;
|
||||
}
|
||||
input[type=range]::-webkit-slider-thumb {
|
||||
margin-top: -6.3px;
|
||||
width: 22px;
|
||||
height: 22px;
|
||||
background: #d9d9d9;
|
||||
border: 1.8px solid #00001e;
|
||||
border-radius: 49px;
|
||||
cursor: pointer;
|
||||
-webkit-appearance: none;
|
||||
}
|
||||
input[type=range]:focus::-webkit-slider-runnable-track {
|
||||
background: #e8dec4;
|
||||
}
|
||||
input[type=range]::-moz-range-track {
|
||||
background: rgba(232, 222, 196, 0.78);
|
||||
border: 1px solid #010101;
|
||||
border-radius: 8.1px;
|
||||
width: 100%;
|
||||
height: 11.4px;
|
||||
cursor: pointer;
|
||||
}
|
||||
input[type=range]::-moz-range-thumb {
|
||||
width: 22px;
|
||||
height: 22px;
|
||||
background: #d9d9d9;
|
||||
border: 1.8px solid #00001e;
|
||||
border-radius: 49px;
|
||||
cursor: pointer;
|
||||
}
|
||||
input[type=range]::-ms-track {
|
||||
background: transparent;
|
||||
border-color: transparent;
|
||||
border-width: 6.2px 0;
|
||||
color: transparent;
|
||||
width: 100%;
|
||||
height: 11.4px;
|
||||
cursor: pointer;
|
||||
}
|
||||
input[type=range]::-ms-fill-lower {
|
||||
background: #e8dec4;
|
||||
border: 1px solid #010101;
|
||||
border-radius: 16.2px;
|
||||
}
|
||||
input[type=range]::-ms-fill-upper {
|
||||
background: rgba(232, 222, 196, 0.78);
|
||||
border: 1px solid #010101;
|
||||
border-radius: 16.2px;
|
||||
}
|
||||
input[type=range]::-ms-thumb {
|
||||
width: 22px;
|
||||
height: 22px;
|
||||
background: #d9d9d9;
|
||||
border: 1.8px solid #00001e;
|
||||
border-radius: 49px;
|
||||
cursor: pointer;
|
||||
margin-top: 0px;
|
||||
/*Needed to keep the Edge thumb centred*/
|
||||
}
|
||||
input[type=range]:focus::-ms-fill-lower {
|
||||
background: rgba(232, 222, 196, 0.78);
|
||||
}
|
||||
input[type=range]:focus::-ms-fill-upper {
|
||||
background: #e8dec4;
|
||||
}
|
||||
/*TODO: Use one of the selectors from https://stackoverflow.com/a/20541859/7077589 and figure out
|
||||
how to remove the virtical space around the range input in IE*/
|
||||
@supports (-ms-ime-align:auto) {
|
||||
/* Pre-Chromium Edge only styles, selector taken from hhttps://stackoverflow.com/a/32202953/7077589 */
|
||||
input[type=range] {
|
||||
margin: 0;
|
||||
/*Edge starts the margin from the thumb, not the track as other browsers do*/
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user