Skip to content

Commit df2b778

Browse files
authored
Lists page - Improve hints and help text (#3798)
2 parents 3c88c80 + 3e40fb9 commit df2b778

3 files changed

Lines changed: 43 additions & 9 deletions

File tree

groups-lists.lp

Lines changed: 35 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,6 @@ mg.include('scripts/lua/header_authenticated.lp','r')
4747
<ol>
4848
<li>Please run <code>pihole -g</code> or update your gravity list <a href="<?=webhome?>gravity">online</a> after modifying your lists.</li>
4949
<li>Multiple lists can be added by separating each <em>unique</em> URL with a space or comma</li>
50-
<li>Click on the icon in the first column to get additional information about your lists. The icons correspond to the health of the list.</li>
5150
</ol>
5251
<div class="btn-toolbar pull-right" role="toolbar" aria-label="Toolbar with buttons">
5352
<div class="btn-group" role="group">
@@ -68,8 +67,8 @@ mg.include('scripts/lua/header_authenticated.lp','r')
6867
<h3 class="box-title">
6968
Subscribed lists
7069
</h3>
71-
</div>
72-
<!-- /.box-header -->
70+
</div><!-- /.box-header -->
71+
7372
<div class="box-body">
7473
<table id="listsTable" class="table table-striped table-bordered" width="100%">
7574
<thead>
@@ -87,10 +86,39 @@ mg.include('scripts/lua/header_authenticated.lp','r')
8786
</thead>
8887
</table>
8988
<button type="button" id="resetButton" class="btn btn-default btn-sm text-red hidden">Reset sorting</button>
90-
</div>
91-
<!-- /.box-body -->
92-
</div>
93-
<!-- /.box -->
89+
</div><!-- /.box-body -->
90+
91+
<div class="box-footer clearfix">
92+
<div class="row">
93+
<div class="col-xs-12">
94+
<p><strong>Hint:</strong> Click on the icons (first and second columns) to get additional information about your lists. The icons correspond to the health of the list.</p>
95+
</div>
96+
</div>
97+
<div class="row">
98+
<div class="col-sm-12 list-icon-legend-block">
99+
<div class="list-icon-legend">
100+
<p><strong>List Status:</strong></p>
101+
<div>
102+
<span class="fa fa-fw fa-check-circle list-status-1"></span> - List download was successful<br>
103+
<span class="fa fa-fw fa-history list-status-2"></span> - List unchanged upstream, Pi-hole used a local copy<br>
104+
<span class="fa fa-fw fa-exclamation-circle list-status-3"></span> - List unavailable, Pi-hole used a local copy<br>
105+
<span class="fa fa-fw fa-times-circle list-status-4"></span> - List unavailable and no local copy of this list is available<br>
106+
<span class="fa fa-fw fa-question-circle list-status-0"></span> - Unknown<br>
107+
<em>(The status icon turns gray when the list is disabled.)</em>
108+
</div>
109+
</div>
110+
<div class="list-icon-legend">
111+
<p><strong>List Type:</strong></p>
112+
<div>
113+
<span class="fa fa-fw fa-check text-green"></span> - Allow list<br>
114+
<span class="fa fa-fw fa-ban text-red"></span> - Block list
115+
</div>
116+
</div>
117+
</div>
118+
</div>
119+
</div><!-- /.box-footer -->
120+
121+
</div><!-- /.box -->
94122
</div>
95123
</div>
96124

scripts/js/groups-lists.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ function setStatusIcon(data) {
109109
break;
110110
}
111111

112-
return "<i class='fa fa-fw " + statusIcon + "' title='" + statusTitle + "'></i>";
112+
return "<span class='fa fa-fw " + statusIcon + "' title='" + statusTitle + "'></span>";
113113
}
114114

115115
// Define human-friendly status string
@@ -167,7 +167,7 @@ function setTypeIcon(type) {
167167
title = "This is an allowlist";
168168
}
169169

170-
return `<i class='fa fa-fw ${iconClass}' title='${title}\nClick for details about this list'></i> `;
170+
return `<span class='fa fa-fw ${iconClass}' title='${title}\nClick for details about this list'></span> `;
171171
}
172172

173173
function initTable() {

style/pi-hole.css

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -544,6 +544,12 @@ tfoot.add-new-item > tr > th {
544544
color: #cc0000;
545545
}
546546

547+
.list-icon-legend-block {
548+
display: flex;
549+
flex-wrap: wrap;
550+
gap: 15px 60px;
551+
}
552+
547553
td.details-control {
548554
cursor: pointer;
549555
text-align: center;

0 commit comments

Comments
 (0)