feat: redesign sleep timer custom input as clickable row with inline edit
This commit is contained in:
1 parent
b4c12a2940
commit
e2c28926b2
3 files changed
+14
-6
No files matched your search
+4
-3
@@ -696,9 +696,10 @@
|
||||
<button onclick="absSleepIn(30)">30 Min</button>
|
||||
<button onclick="absSleepIn(45)">45 Min</button>
|
||||
<button onclick="absSleepIn(60)">60 Min</button>
|
||||
<div class="abs-sleep-custom">
|
||||
<input id="abs-sleep-custom-input" type="number" min="1" max="999" placeholder="Min" onkeydown="if(event.key==='Enter'){const v=parseInt(this.value);if(v>0)absSleepIn(v);}">
|
||||
<button onclick="const v=parseInt(document.getElementById('abs-sleep-custom-input').value);if(v>0)absSleepIn(v);">OK</button>
|
||||
<div id="abs-sleep-custom-row" class="abs-sleep-custom-row" onclick="if(!this.classList.contains('active')){this.classList.add('active');var inp=document.getElementById('abs-sleep-custom-input');inp.value='';inp.focus();}">
|
||||
<span class="abs-sleep-custom-label">Eigene Zeit…</span>
|
||||
<input id="abs-sleep-custom-input" type="number" min="1" max="999" placeholder="Min" onclick="event.stopPropagation()" onkeydown="if(event.key==='Enter'){var v=parseInt(this.value);if(v>0)absSleepIn(v);}">
|
||||
<button onclick="event.stopPropagation();var v=parseInt(document.getElementById('abs-sleep-custom-input').value);if(v>0)absSleepIn(v);">OK</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in new issue
Block a user