summaryrefslogtreecommitdiffhomepage
path: root/applications/luci-app-adblock/htdocs/luci-static/resources/view
diff options
context:
space:
mode:
authorDirk Brenken <dev@brenken.org>2020-11-27 21:33:04 +0100
committerDirk Brenken <dev@brenken.org>2020-11-27 22:22:13 +0100
commit1ae99ff8d6dcb7c340e7fe921f8ccb355fff83df (patch)
tree92c7a08a9e11b8c1d658d6ebe700d952b0935f49 /applications/luci-app-adblock/htdocs/luci-static/resources/view
parentc850608dcf58e1872692ca48af7985e528651e80 (diff)
luci-app-adblock: update dns report page
* add search anchor to all listed domains on dns report page * small wording changes & cosmetics * update translations Signed-off-by: Dirk Brenken <dev@brenken.org>
Diffstat (limited to 'applications/luci-app-adblock/htdocs/luci-static/resources/view')
-rw-r--r--applications/luci-app-adblock/htdocs/luci-static/resources/view/adblock/dnsreport.js19
1 files changed, 10 insertions, 9 deletions
diff --git a/applications/luci-app-adblock/htdocs/luci-static/resources/view/adblock/dnsreport.js b/applications/luci-app-adblock/htdocs/luci-static/resources/view/adblock/dnsreport.js
index 3f3d233e20..0feee2ae70 100644
--- a/applications/luci-app-adblock/htdocs/luci-static/resources/view/adblock/dnsreport.js
+++ b/applications/luci-app-adblock/htdocs/luci-static/resources/view/adblock/dnsreport.js
@@ -12,7 +12,7 @@ function handleAction(ev) {
E('p', _('Add this (sub-)domain to your local blacklist.')),
E('div', { 'class': 'left', 'style': 'display:flex; flex-direction:column' }, [
E('label', { 'class': 'cbi-input-text', 'style': 'padding-top:.5em' }, [
- E('input', { 'class': 'cbi-input-text', 'style': 'width:300px', 'id': 'blacklist', 'value': ev.target.getAttribute('value') }, [])
+ E('input', { 'class': 'cbi-input-text', 'style': 'width:300px', 'spellcheck': 'false', 'id': 'blacklist', 'value': ev.target.getAttribute('value') }, [])
])
]),
E('div', { 'class': 'right' }, [
@@ -47,7 +47,7 @@ function handleAction(ev) {
E('p', _('Add this (sub-)domain to your local whitelist.')),
E('div', { 'class': 'left', 'style': 'display:flex; flex-direction:column' }, [
E('label', { 'class': 'cbi-input-text', 'style': 'padding-top:.5em' }, [
- E('input', { 'class': 'cbi-input-text', 'style': 'width:300px', 'id': 'whitelist', 'value': ev.target.getAttribute('value') }, [])
+ E('input', { 'class': 'cbi-input-text', 'style': 'width:300px', 'spellcheck': 'false', 'id': 'whitelist', 'value': ev.target.getAttribute('value') }, [])
])
]),
E('div', { 'class': 'right' }, [
@@ -86,6 +86,7 @@ function handleAction(ev) {
'class': 'cbi-input-text',
'placeholder': 'google.com',
'style': 'width:300px',
+ 'spellcheck': 'false',
'id': 'search'
})
])
@@ -227,13 +228,13 @@ return view.extend({
b_cnt = content.data.top_domains[i].count;
}
if (content.data.top_domains[i]) {
- b_addr = content.data.top_domains[i].address;
+ b_addr = '<a href="https://duckduckgo.com/?q=' + encodeURIComponent(content.data.top_domains[i].address) + '&k1=-1&km=l&kh=1" target="_blank" title="Search this domain">' + content.data.top_domains[i].address + '</a>';
}
if (content.data.top_blocked[i]) {
c_cnt = content.data.top_blocked[i].count;
}
if (content.data.top_blocked[i]) {
- c_addr = content.data.top_blocked[i].address;
+ c_addr = '<a href="https://duckduckgo.com/?q=' + encodeURIComponent(content.data.top_blocked[i].address) + '&k1=-1&km=l&kh=1" target="_blank" title="Search this domain">' + content.data.top_blocked[i].address + '</a>';
}
rows_top.push([
a_cnt,
@@ -284,7 +285,7 @@ return view.extend({
content.data.requests[i].date,
content.data.requests[i].time,
content.data.requests[i].client,
- content.data.requests[i].domain,
+ '<a href="https://duckduckgo.com/?q=' + encodeURIComponent(content.data.requests[i].domain) + '&k1=-1&km=l&kh=1" target="_blank" title="Search this domain">' + content.data.requests[i].domain + '</a>',
content.data.requests[i].rc,
button
]);
@@ -297,16 +298,16 @@ return view.extend({
E('p', _('This shows the last generated DNS Report, press the refresh button to get a current one.')),
E('p', '\xa0'),
E('div', { 'class': 'cbi-value', 'style': 'margin-bottom:5px' }, [
- E('label', { 'class': 'cbi-value-title', 'style': 'padding-top:0rem' }, _('Start Date')),
+ E('label', { 'class': 'cbi-value-title', 'style': 'padding-top:0rem' }, _('Start Timestamp')),
E('div', { 'class': 'cbi-value-field', 'id': 'start', 'style': 'margin-bottom:5px;margin-left:200px;color:#37c' }, (content.data.start_date || '-') + ', ' + (content.data.start_time || '-'))]),
E('div', { 'class': 'cbi-value', 'style': 'margin-bottom:5px' }, [
- E('label', { 'class': 'cbi-value-title', 'style': 'padding-top:0rem' }, _('End Date')),
+ E('label', { 'class': 'cbi-value-title', 'style': 'padding-top:0rem' }, _('End Timestamp')),
E('div', { 'class': 'cbi-value-field', 'id': 'end', 'style': 'margin-bottom:5px;margin-left:200px;color:#37c' }, (content.data.end_date || '-') + ', ' + (content.data.end_time || '-'))]),
E('div', { 'class': 'cbi-value', 'style': 'margin-bottom:5px' }, [
- E('label', { 'class': 'cbi-value-title', 'style': 'padding-top:0rem' }, _('DNS Requests (total)')),
+ E('label', { 'class': 'cbi-value-title', 'style': 'padding-top:0rem' }, _('Total DNS Requests')),
E('div', { 'class': 'cbi-value-field', 'id': 'total', 'style': 'margin-bottom:5px;margin-left:200px;color:#37c' }, content.data.total || '-')]),
E('div', { 'class': 'cbi-value', 'style': 'margin-bottom:5px' }, [
- E('label', { 'class': 'cbi-value-title', 'style': 'padding-top:0rem' }, _('DNS Requests (blocked)')),
+ E('label', { 'class': 'cbi-value-title', 'style': 'padding-top:0rem' }, _('Blocked DNS Requests')),
E('div', { 'class': 'cbi-value-field', 'id': 'blocked', 'style': 'margin-bottom:5px;margin-left:200px;color:#37c' }, (content.data.blocked || '-') + ' (' + (content.data.percent || '-') + ')')]),
E('div', { 'class': 'right' }, [
E('button', {