mirror of
https://github.com/searxng/searxng
synced 2024-01-01 19:24:07 +01:00
[simple] checkboxes can get the focusable
Do note that checkboxes in the engine tab are displayed reversed.
See: 3408d061aa/searx/templates/simple/preferences.html (L313)
A checkbox for an engine is checked when the engine is disabled.
This commit is contained in:
parent
0ddcc12474
commit
3d9e48b84e
6 changed files with 220 additions and 168 deletions
|
|
@ -72,19 +72,13 @@
|
|||
{%- endmacro -%}
|
||||
|
||||
{%- macro checkbox_onoff(name, checked) -%}
|
||||
<div class="checkbox-onoff">{{- '' -}}
|
||||
<input type="checkbox" value="None" id="{{ name }}" name="{{ name }}" {% if checked %}checked{% endif %}/>{{- '' -}}
|
||||
<label for="{{ name }}"></label>{{- '' -}}
|
||||
</div>
|
||||
<input type="checkbox" name="{{ name }}" id="{{ name }}" value="None" class="checkbox-onoff" {% if checked %}checked{% endif %} />
|
||||
{%- endmacro -%}
|
||||
|
||||
{%- macro checkbox(name, checked, readonly, disabled) -%}
|
||||
<div class="checkbox">{{- '' -}}
|
||||
{%- if checked == '?' -%}
|
||||
{{ icon_small('warning') }}
|
||||
{%- else -%}
|
||||
<input type="checkbox" value="None" id="{{ name }}" name="{{ name }}" {% if checked %}checked{% endif %}{% if readonly %} readonly="readonly" {% endif %}{% if disabled %} disabled="disabled" {% endif %}/>{{- '' -}}
|
||||
<label for="{{ name }}"></label>{{- '' -}}
|
||||
{%- endif -%}
|
||||
</div>
|
||||
{%- macro checkbox(name, checked, disabled) -%}
|
||||
{%- if checked == '?' -%}
|
||||
{{- icon_small('warning') -}}
|
||||
{%- else -%}
|
||||
<input type="checkbox"{% if name %} name="{{ name }}"{% endif %} value="None"{% if checked %} checked{% endif %}{% if disabled %} disabled{% endif %} />
|
||||
{%- endif -%}
|
||||
{%- endmacro -%}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue