mirror of
https://github.com/dscalzi/HeliosLauncher.git
synced 2024-12-22 11:42:14 -08:00
Fixed range slider rendering when value is out of range.
If the value of a ranged slider is out of range, the slider will snap to either 0% or 100%. Reduced memory label margin to preserve sufficient spacing.
This commit is contained in:
parent
9769458499
commit
4196856d31
@ -1422,7 +1422,7 @@ input:checked + .toggleSwitchSlider:before {
|
||||
/* Label which displays a memory slider's value. */
|
||||
.settingsMemoryLabel {
|
||||
font-size: 14px;
|
||||
margin-right: 3%;
|
||||
margin-right: 2%;
|
||||
}
|
||||
|
||||
/* Range sliders for min and max memory settings. */
|
||||
|
@ -588,6 +588,12 @@ function updateRangedSlider(element, value, notch){
|
||||
|
||||
element.setAttribute('value', value)
|
||||
|
||||
if(notch < 0){
|
||||
notch = 0
|
||||
} else if(notch > 100) {
|
||||
notch = 100
|
||||
}
|
||||
|
||||
const event = new MouseEvent('change', {
|
||||
target: element,
|
||||
type: 'change',
|
||||
|
Loading…
Reference in New Issue
Block a user