Fix
Checkbox fixes added
This commit is contained in:
parent
a485451328
commit
14fc64f2f1
@ -90,71 +90,62 @@
|
||||
<div id="picker" class="noslide"></div>
|
||||
<div id="hwrap" class="slider">
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderH" class="noslide" oninput="fromH()" onchange="setColor(0)" max="359" min="0" type="range" value="0" step="any">
|
||||
<input id="sliderH" tooltip="Hue" class="noslide" oninput="fromH()" onchange="setColor(0)" max="359" min="0" type="range" value="0" step="any">
|
||||
<div class="sliderdisplay" style="background: linear-gradient(90deg, #f00 2%, #ff0 19%, #0f0 35%, #0ff 52%, #00f 68%, #f0f 85%, #f00)"></div>
|
||||
</div>
|
||||
<span class="tooltiptext">Hue</span>
|
||||
</div>
|
||||
<div id="swrap" class="slider">
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderS" class="noslide" oninput="fromS()" onchange="setColor(0)" max="100" min="0" type="range" value="100" step="any">
|
||||
<input id="sliderS" tooltip="Saturation" class="noslide" oninput="fromS()" onchange="setColor(0)" max="100" min="0" type="range" value="100" step="any">
|
||||
<div class="sliderdisplay" style="background: linear-gradient(90deg, #aaa 0%, #f00)"></div>
|
||||
</div>
|
||||
<span class="tooltiptext">Saturation</span>
|
||||
</div>
|
||||
<div id="vwrap" class="slider">
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderV" class="noslide" oninput="fromV()" onchange="setColor(0)" max="100" min="0" type="range" value="100" step="any" />
|
||||
<input id="sliderV" tooltip="Value / Brightness" class="noslide" oninput="fromV()" onchange="setColor(0)" max="100" min="0" type="range" value="100" step="any" />
|
||||
<div class="sliderdisplay"></div>
|
||||
</div>
|
||||
<span class="tooltiptext">Value/Brightness</span>
|
||||
</div>
|
||||
<div id="kwrap" class="slider">
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderK" class="noslide" oninput="fromK()" onchange="setColor(0)" max="10091" min="1900" type="range" value="6550" />
|
||||
<input id="sliderK" tooltip="Kelvin / Temperature" class="noslide" oninput="fromK()" onchange="setColor(0)" max="10091" min="1900" type="range" value="6550" />
|
||||
<div class="sliderdisplay"></div>
|
||||
</div>
|
||||
<span class="tooltiptext">Kelvin/Temperature</span>
|
||||
</div>
|
||||
<div id="rgbwrap">
|
||||
<!--p class="labels hd">RGB color</p-->
|
||||
<div id="rwrap" class="slider">
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderR" class="noslide" oninput="fromRgb()" onchange="setColor(0)" max="255" min="0" type="range" value="128" />
|
||||
<input id="sliderR" tooltip="Red channel" class="noslide" oninput="fromRgb()" onchange="setColor(0)" max="255" min="0" type="range" value="128" />
|
||||
<div class="sliderdisplay"></div>
|
||||
</div>
|
||||
<span class="tooltiptext">Red channel</span>
|
||||
</div>
|
||||
<div id="gwrap" class="slider">
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderG" class="noslide" oninput="fromRgb()" onchange="setColor(0)" max="255" min="0" type="range" value="128" />
|
||||
<input id="sliderG" tooltip="Green channel" class="noslide" oninput="fromRgb()" onchange="setColor(0)" max="255" min="0" type="range" value="128" />
|
||||
<div class="sliderdisplay"></div>
|
||||
</div>
|
||||
<span class="tooltiptext">Green channel</span>
|
||||
</div>
|
||||
<div id="bwrap" class="slider">
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderB" class="noslide" oninput="fromRgb()" onchange="setColor(0)" max="255" min="0" type="range" value="128" />
|
||||
<input id="sliderB" tooltip="Blue channel" class="noslide" oninput="fromRgb()" onchange="setColor(0)" max="255" min="0" type="range" value="128" />
|
||||
<div class="sliderdisplay"></div>
|
||||
</div>
|
||||
<span class="tooltiptext">Blue channel</span>
|
||||
</div>
|
||||
</div>
|
||||
<div id="wwrap" class="slider">
|
||||
<!--p class="labels hd">White channel</p-->
|
||||
<div id="whibri" class="sliderwrap il">
|
||||
<input id="sliderW" class="noslide" oninput="fromW()" onchange="setColor(0)" max="255" min="0" type="range" value="128" />
|
||||
<input id="sliderW" tooltip="White channel" class="noslide" oninput="fromW()" onchange="setColor(0)" max="255" min="0" type="range" value="128" />
|
||||
<div class="sliderdisplay"></div>
|
||||
</div>
|
||||
<span class="tooltiptext">White channel</span>
|
||||
</div>
|
||||
<div id="wbal" class="slider">
|
||||
<!--p class="labels hd">White balance</p-->
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderA" class="noslide" onchange="setBalance(this.value)" max="255" min="0" type="range" value="128" />
|
||||
<input id="sliderA" tooltip="White balance" class="noslide" onchange="setBalance(this.value)" max="255" min="0" type="range" value="128" />
|
||||
<div class="sliderdisplay"></div>
|
||||
</div>
|
||||
<span class="tooltiptext">White balance</span>
|
||||
</div>
|
||||
<div id="qcs-w">
|
||||
<div class="qcs" onclick="pC('#ff0000');" title="Red" style="background-color:#ff0000;"></div>
|
||||
@ -294,17 +285,17 @@
|
||||
<output class="sliderbubble"></output>
|
||||
</div>
|
||||
<div id="fxopt" class="option fade">
|
||||
<label id="opt0" class="check ochkl hide"><i class="icons"></i><span class="tooltiptext" id="optLabel0">Check 1</span>
|
||||
<label id="opt0" class="check ochkl hide"><i class="icons"></i>
|
||||
<input id="checkO1" type="checkbox" onchange="setOption(1, this.checked)">
|
||||
<span class="checkmark"></span>
|
||||
<span class="checkmark" tooltip="Check 1"></span>
|
||||
</label>
|
||||
<label id="opt1" class="check ochkl hide"><i class="icons"></i><span class="tooltiptext" id="optLabel1">Check 2</span>
|
||||
<label id="opt1" class="check ochkl hide"><i class="icons"></i>
|
||||
<input id="checkO2" type="checkbox" onchange="setOption(2, this.checked)">
|
||||
<span class="checkmark"></span>
|
||||
<span class="checkmark" tooltip="Check 2"></span>
|
||||
</label>
|
||||
<label id="opt2" class="check ochkl hide"><i class="icons"></i><span class="tooltiptext" id="optLabel2">Check 3</span>
|
||||
<label id="opt2" class="check ochkl hide"><i class="icons"></i>
|
||||
<input id="checkO3" type="checkbox" onchange="setOption(3, this.checked)">
|
||||
<span class="checkmark"></span>
|
||||
<span class="checkmark" tooltip="Check 3"></span>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1511,22 +1511,29 @@ function setEffectParameters(idx)
|
||||
if ((!controlDefined && i < ((idx < 128) ? 2 : nSliders)) || (slOnOff.length > i && slOnOff[i] != "")) {
|
||||
const newText = slOnOff.length > i && slOnOff[i] != "!" ? slOnOff[i] : text;
|
||||
tooltip.setAttribute("tooltip", newText);
|
||||
|
||||
slider.classList.remove('hide');
|
||||
} else {
|
||||
slider.classList.add('hide');
|
||||
}
|
||||
});
|
||||
|
||||
if (slOnOff.length>5) { // up to 3 checkboxes
|
||||
if (slOnOff.length > 5) { // up to 3 checkboxes
|
||||
gId('fxopt').classList.remove('fade');
|
||||
for (let i = 0; i<3; i++) {
|
||||
if (5+i<slOnOff.length && slOnOff[5+i]!=='') {
|
||||
gId('opt'+i).classList.remove('hide');
|
||||
gId('optLabel'+i).innerHTML = slOnOff[5+i]=="!" ? 'Option' : slOnOff[5+i].substr(0,16);
|
||||
} else
|
||||
gId('opt'+i).classList.add('hide');
|
||||
}
|
||||
|
||||
let checks = d.querySelectorAll("#fxopt .check");
|
||||
|
||||
checks.forEach(function(check, i){
|
||||
const tooltip = check.querySelector('[tooltip]');
|
||||
const text = tooltip.getAttribute("tooltip");
|
||||
|
||||
if (5 + i < slOnOff.length && slOnOff[5 + i] !== '') {
|
||||
const newText = slOnOff[5 + i] == "!" ? text : slOnOff[5 + i].substr(0, 16);
|
||||
tooltip.setAttribute("tooltip", newText);
|
||||
check.classList.remove('hide');
|
||||
} else {
|
||||
check.classList.add('hide');
|
||||
}
|
||||
});
|
||||
} else {
|
||||
gId('fxopt').classList.add('fade');
|
||||
}
|
||||
|
2861
wled00/html_ui.h
2861
wled00/html_ui.h
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user