mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-05-05 16:38:59 -04:00
Refactor to reuse search box HTML
This commit is contained in:
10
app/templates/views/templates/_search-box.html
Normal file
10
app/templates/views/templates/_search-box.html
Normal file
@@ -0,0 +1,10 @@
|
||||
{% if show_search_box %}
|
||||
<div data-module="autofocus">
|
||||
<div class="live-search" data-module="live-search" data-targets="#template-list .column-whole">
|
||||
{{ textbox(
|
||||
search_form.search,
|
||||
width='1-1'
|
||||
) }}
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
@@ -28,16 +28,7 @@
|
||||
|
||||
{% else %}
|
||||
|
||||
{% if show_search_box %}
|
||||
<div data-module="autofocus">
|
||||
<div class="live-search" data-module="live-search" data-targets="#template-list .column-whole">
|
||||
{{ textbox(
|
||||
search_form.search,
|
||||
width='1-1'
|
||||
) }}
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
{% include "views/templates/_search-box.html" %}
|
||||
|
||||
<nav class="grid-row" id=template-list>
|
||||
{% for template in templates %}
|
||||
|
||||
@@ -54,16 +54,7 @@
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
{% if show_search_box %}
|
||||
<div data-module="autofocus">
|
||||
<div class="live-search" data-module="live-search" data-targets="#template-list .column-whole">
|
||||
{{ textbox(
|
||||
search_form.search,
|
||||
width='1-1'
|
||||
) }}
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
{% include "views/templates/_search-box.html" %}
|
||||
|
||||
<nav class="grid-row" id=template-list>
|
||||
{% for template in templates %}
|
||||
|
||||
Reference in New Issue
Block a user