mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-19 14:09:20 -04:00
Add search bar to team member list
Another thing we did for templates, when they started to get unmanageable, was add a find-as-you type search. We’ve observed real users interacting with this to great effect, so I think it makes sense for users too. Like for templates, it only shows up when there are more than 7, so that it’s not clutter for teams who don’t have a lot of members.
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
{% from "components/table.html" import list_table, row, field, hidden_field_heading %}
|
||||
{% from "components/page-footer.html" import page_footer %}
|
||||
{% from "components/tick-cross.html" import tick_cross %}
|
||||
{% from "components/textbox.html" import textbox %}
|
||||
|
||||
{% set table_options = {
|
||||
'field_headings': [
|
||||
@@ -30,6 +31,17 @@
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
{% if show_search_box %}
|
||||
<div data-module="autofocus">
|
||||
<div class="live-search" data-module="live-search" data-targets=".user-list-item">
|
||||
{{ textbox(
|
||||
form.search,
|
||||
width='1-1'
|
||||
) }}
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<div class="user-list">
|
||||
{% for user in users %}
|
||||
<div class="user-list-item">
|
||||
|
||||
Reference in New Issue
Block a user