Replaced the default number input arrow buttons with own ones to better support touch input (references #44)

This commit is contained in:
Bernd Bestel
2018-09-08 12:04:31 +02:00
parent 8a71d55f0f
commit e777be4d3b
12 changed files with 148 additions and 57 deletions

View File

@@ -37,11 +37,15 @@
<input type="text" class="form-control" id="used_in" name="used_in" value="@if($mode == 'edit'){{ $battery->used_in }}@endif">
</div>
<div class="form-group">
<label for="charge_interval_days">{{ $L('Charge cycle interval (days)') }}<br><span class="small text-muted">{{ $L('0 means suggestions for the next charge cycle are disabled') }}</span></label>
<input required min="0" step="1" type="number" class="form-control" id="charge_interval_days" name="charge_interval_days" value="@if($mode == 'edit'){{ $battery->charge_interval_days }}@else{{0}}@endif">
<div class="invalid-feedback">{{ $L('This cannot be negative') }}</div>
</div>
@php if($mode == 'edit') { $value = $battery->charge_interval_days; } else { $value = 0; } @endphp
@include('components.numberpicker', array(
'id' => 'charge_interval_days',
'label' => 'Charge cycle interval (days)',
'value' => $value,
'min' => '0',
'hint' => $L('0 means suggestions for the next charge cycle are disabled'),
'invalidFeedback' => $L('This cannot be negative')
))
<button id="save-battery-button" type="submit" class="btn btn-success">{{ $L('Save') }}</button>