mirror of
https://git.ianrenton.com/ian/spothole.git
synced 2026-09-29 02:32:05 +00:00
Replace pages' use of the options call with directly building the HTML components using templates, as the syntax is much nicer. Use a common set of data provided to all modules via pagetemplate.py instead of passing things like web_ui_options around. Closes #153
This commit is contained in:
@@ -1,6 +1,26 @@
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
<h5 class="card-title">Modes</h5>
|
||||
<div id="mode-options" class="card-text spothole-card-text"></div>
|
||||
<div class="card-text spothole-card-text">
|
||||
<div class="row row-cols-3 row-cols-md-2 row-cols-lg-3 g-1 mb-1">
|
||||
{% for m in options["modes"] %}
|
||||
<div class="col">
|
||||
<div class="form-check">
|
||||
<input type="checkbox" class="form-check-input filter-button-mode storeable-checkbox"
|
||||
id="filter-button-mode-{{ dom_safe_name(m) }}" value="{{ m }}"
|
||||
data-mode-type="{{ infer_mode_type_from_mode(m).value }}"
|
||||
autocomplete="off" onClick="filtersUpdated()" checked>
|
||||
<label class="form-check-label" for="filter-button-mode-{{ dom_safe_name(m) }}">{{ m }}</label>
|
||||
</div>
|
||||
</div>
|
||||
{% end %}
|
||||
</div>
|
||||
<div class="mt-1">
|
||||
<a href="#" onclick="toggleFilterButtons('mode', true); return false;">All</a>
|
||||
<a href="#" onclick="toggleFilterButtons('mode', false); return false;">None</a>
|
||||
<a href="#" onclick="setVoiceModeToggles(); return false;">Voice only</a>
|
||||
<a href="#" onclick="setDigiModeToggles(); return false;">Digimodes only</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user