Skip to content

Commit 86be3a3

Browse files
committed
Refine the Dependency tab rendering #286
Signed-off-by: tdruez <tdruez@nexb.com>
1 parent 273bbb6 commit 86be3a3

2 files changed

Lines changed: 15 additions & 11 deletions

File tree

dejacode/static/css/dejacode_bootstrap.css

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -426,19 +426,22 @@ table.vulnerabilities-table .column-summary {
426426

427427
/* -- Dependency tab -- */
428428
#tab_dependencies .column-for_package {
429-
width: 250px;
429+
min-width: 300px;
430430
}
431431
#tab_dependencies .column-resolved_to_package {
432-
width: 250px;
432+
min-width: 300px;
433433
}
434434
#tab_dependencies .column-is_runtime {
435-
width: 100px;
435+
width: 85px;
436+
font-size: 0.75rem;
436437
}
437-
#tab_dependencies .column-column-is_optional {
438-
width: 100px;
438+
#tab_dependencies .column-is_optional {
439+
width: 85px;
440+
font-size: 0.75rem;
439441
}
440-
#tab_dependencies .column-column-is_pinned {
441-
width: 88px;
442+
#tab_dependencies .column-is_pinned {
443+
width: 80px;
444+
font-size: 0.75rem;
442445
}
443446

444447
/* -- Package Details -- */
@@ -661,7 +664,6 @@ td.sub-header {
661664
.table thead tr th a.sort:hover {
662665
color: #ccc;
663666
text-decoration: none;
664-
margin-left: 0;
665667
}
666668
.table thead tr th a.sort.active {
667669
color: var(--bs-body-color);

dje/templates/includes/object_list_table_header.html

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
{% load i18n %}
2+
{% spaceless %}
23
<thead class="text-break-initial">
34
<tr>
45
{% if is_grouping_active %}
@@ -27,10 +28,10 @@
2728
{% with query_no_sort=filter.get_query_no_sort %}
2829
{% if filter.form.sort.data and header.field_name in filter.form.sort.data.0 %}
2930
{# The sort for this field is currently active #}
30-
<a href="?{% if query_no_sort %}{{ query_no_sort }}&{% endif %}{% if tab_id %}{{ tab_id }}-{% endif %}sort={% if '-' not in filter.form.sort.data.0 %}-{% endif %}{{ header.field_name }}{% if tab_id %}#{{ tab_id }}{% endif %}" class="sort active" aria-label="Sort"><i class="fas fa-sort-{% if '-' not in filter.form.sort.data.0 %}up{% else %}down{% endif %}"></i></a>
31+
<a href="?{% if query_no_sort %}{{ query_no_sort }}&{% endif %}{% if tab_id %}{{ tab_id }}-{% endif %}sort={% if '-' not in filter.form.sort.data.0 %}-{% endif %}{{ header.field_name }}{% if tab_id %}#{{ tab_id }}{% endif %}" class="sort active ms-1" aria-label="Sort"><i class="fas fa-sort-{% if '-' not in filter.form.sort.data.0 %}up{% else %}down{% endif %}"></i></a>
3132
{% else %}
3233
{# The sort for this field is NOT active #}
33-
<a href="?{% if query_no_sort %}{{ query_no_sort }}&{% endif %}{% if tab_id %}{{ tab_id }}-{% endif %}sort={{ header.field_name }}{% if tab_id %}#{{ tab_id }}{% endif %}" class="sort" aria-label="Sort"><i class="fas fa-sort"></i></a>
34+
<a href="?{% if query_no_sort %}{{ query_no_sort }}&{% endif %}{% if tab_id %}{{ tab_id }}-{% endif %}sort={{ header.field_name }}{% if tab_id %}#{{ tab_id }}{% endif %}" class="sort ms-1" aria-label="Sort"><i class="fas fa-sort"></i></a>
3435
{% endif %}
3536
{% endwith %}
3637
{% endif %}
@@ -40,4 +41,5 @@
4041
<th class="column-action" scope="col"></th>
4142
{% endif %}
4243
</tr>
43-
</thead>
44+
</thead>
45+
{% endspaceless %}

0 commit comments

Comments
 (0)