Skip to content

Commit

Permalink
fix chevron up down icons
Browse files Browse the repository at this point in the history
  • Loading branch information
catborise committed Jan 17, 2024
1 parent f0cd0bc commit 9a05c18
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
6 changes: 3 additions & 3 deletions instances/templates/allinstances_index_grouped.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
{% if compute.status is True and compute.instance_set.count > 0 %}
<tr class="table-secondary fw-bold border-bottom border-dark">
<td>
<span id="collapse_host_instances_{{ compute.id }}" onclick="hide_host_instances('{{ compute.id }}');">{% bs_icon 'chevron-up'%} </span>
<span id="collapse_host_instances_{{ compute.id }}" onclick="hide_host_instances('{{ compute.id }}');" class="bi bi-chevron-up" ></span>
</td>
<td>
<a class="link-dark" href="{% url 'overview' compute.id %}">{{ compute.name }}</a>
Expand Down Expand Up @@ -91,14 +91,14 @@
var rows = $('table tr');
all_host_rows = rows.filter('[host]');
all_host_rows.toggle();
$('span[id^=collapse_host_instances_]').toggleClass("fa-chevron-down").toggleClass("fa-chevron-up");
$('span[id^=collapse_host_instances_]').toggleClass("bi bi-chevron-down ").toggleClass("bi bi-chevron-up");
$('span[id^=inst_count_badge_]').toggleClass("d-none");
}
function hide_host_instances(host) {
var rows = $('table tr');
host_rows = rows.filter("[host='"+host+"']");
host_rows.toggle();
$("span[id='collapse_host_instances_"+host+"']").toggleClass("fa-chevron-down").toggleClass("fa-chevron-up");
$("span[id='collapse_host_instances_"+host+"']").toggleClass("bi-chevron-down ").toggleClass("bi-chevron-up");
$("span[id='inst_count_badge_"+host+"']").toggleClass("d-none");
}
</script>
Expand Down
8 changes: 8 additions & 0 deletions static/icon_cache/chevron-down_None_None_None.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 9a05c18

Please sign in to comment.