luci-app-statistics: rework markup and CSS classes for easier styling

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
This commit is contained in:
Jo-Philipp Wich 2020-03-23 22:19:26 +01:00
parent 3a32eb26ef
commit 6d17667524

View file

@ -200,24 +200,30 @@ return L.view.extend({
var view = E([], [
E('h2', {}, [ _('Statistics') ]),
E('div', {}, [
E('div', {}, [
hostSel,
E('button', {
'class': 'cbi-button cbi-button-apply',
'click': ui.createHandlerFn(this, 'updateGraphs', hostSel, spanSel, timeSel, graphDiv, )
}, [ _('Display Host »') ]),
E('p', { 'class': 'controls' }, [
E('span', { 'class': 'nowrap' }, [
hostSel,
E('button', {
'class': 'cbi-button cbi-button-apply',
'click': ui.createHandlerFn(this, 'updateGraphs', hostSel, spanSel, timeSel, graphDiv, )
}, [ _('Display Host »') ]),
]),
' ',
spanSel,
E('button', {
'class': 'cbi-button cbi-button-apply',
'click': ui.createHandlerFn(this, 'updateGraphs', hostSel, spanSel, timeSel, graphDiv)
}, [ _('Display timespan »') ]),
E('span', { 'class': 'nowrap' }, [
spanSel,
E('button', {
'class': 'cbi-button cbi-button-apply',
'click': ui.createHandlerFn(this, 'updateGraphs', hostSel, spanSel, timeSel, graphDiv)
}, [ _('Display timespan »') ]),
]),
' ',
timeSel,
E('button', {
'class': 'cbi-button cbi-button-apply',
'click': ui.createHandlerFn(this, 'togglePolling', hostSel, spanSel, timeSel, graphDiv)
}, [ _('Apply interval »') ])
E('span', { 'class': 'nowrap' }, [
timeSel,
E('button', {
'class': 'cbi-button cbi-button-apply',
'click': ui.createHandlerFn(this, 'togglePolling', hostSel, spanSel, timeSel, graphDiv)
}, [ _('Apply interval »') ])
])
]),
E('hr'),
graphDiv