summaryrefslogtreecommitdiffhomepage
path: root/modules/luci-mod-network/htdocs/luci-static
diff options
context:
space:
mode:
authorJo-Philipp Wich <jo@mein.io>2020-03-24 22:13:01 +0100
committerJo-Philipp Wich <jo@mein.io>2020-03-24 22:14:18 +0100
commit04c73f1613734b3f2a7204c24d7c9267d1b45955 (patch)
treeabcd1d2a8a1857719447706393959cda5a07af29 /modules/luci-mod-network/htdocs/luci-static
parent82fb5a67d39d965595d2ad833dbf930e559c0202 (diff)
luci-mod-network, luci-mod-status: allow assoclist wrapping
Signed-off-by: Jo-Philipp Wich <jo@mein.io> (cherry picked from commit a600ebb5fe14b13cb53669eb73b86f66cc699e94)
Diffstat (limited to 'modules/luci-mod-network/htdocs/luci-static')
-rw-r--r--modules/luci-mod-network/htdocs/luci-static/resources/view/network/wireless.js25
1 files changed, 14 insertions, 11 deletions
diff --git a/modules/luci-mod-network/htdocs/luci-static/resources/view/network/wireless.js b/modules/luci-mod-network/htdocs/luci-static/resources/view/network/wireless.js
index 767bab254d..2682871345 100644
--- a/modules/luci-mod-network/htdocs/luci-static/resources/view/network/wireless.js
+++ b/modules/luci-mod-network/htdocs/luci-static/resources/view/network/wireless.js
@@ -46,7 +46,7 @@ function render_signal_badge(signalPercent, signalValue, noiseValue, wrap) {
icon = L.resource('icons/signal-75-100.png');
if (signalValue != null && signalValue != 0 && noiseValue != null && noiseValue != 0) {
- value = '%d / %d %s'.format(signalValue, noiseValue, _('dBm'));
+ value = '%d/%d\xa0%s'.format(signalValue, noiseValue, _('dBm'));
title = '%s: %d %s / %s: %d %s / %s %d'.format(
_('Signal'), signalValue, _('dBm'),
_('Noise'), noiseValue, _('dBm'),
@@ -165,13 +165,16 @@ function render_modal_status(node, radioNet) {
}
function format_wifirate(rate) {
- var s = '%.1f Mbit/s, %dMHz'.format(rate.rate / 1000, rate.mhz);
-
- if (rate.ht || rate.vht) {
- if (rate.vht) s += ', VHT-MCS %d'.format(rate.mcs);
- if (rate.nss) s += ', VHT-NSS %d'.format(rate.nss);
- if (rate.ht) s += ', MCS %s'.format(rate.mcs);
- if (rate.short_gi) s += ', Short GI';
+ var s = '%.1f\xa0%s, %d\xa0%s'.format(rate.rate / 1000, _('Mbit/s'), rate.mhz, _('MHz')),
+ ht = rate.ht, vht = rate.vht,
+ mhz = rate.mhz, nss = rate.nss,
+ mcs = rate.mcs, sgi = rate.short_gi;
+
+ if (ht || vht) {
+ if (vht) s += ', VHT-MCS\xa0%d'.format(mcs);
+ if (nss) s += ', VHT-NSS\xa0%d'.format(nss);
+ if (ht) s += ', MCS\xa0%s'.format(mcs);
+ if (sgi) s += ', ' + _('Short GI').replace(/ /g, '\xa0');
}
return s;
@@ -586,7 +589,7 @@ return L.view.extend({
if (bss.network.isClientDisconnectSupported()) {
if (table.firstElementChild.childNodes.length < 6)
- table.firstElementChild.appendChild(E('div', { 'class': 'th nowrap right'}, [ _('Disconnect') ]));
+ table.firstElementChild.appendChild(E('div', { 'class': 'th cbi-section-actions'}));
row.push(E('button', {
'class': 'cbi-button cbi-button-remove',
@@ -2164,8 +2167,8 @@ return L.view.extend({
E('div', { 'class': 'th nowrap' }, _('Network')),
E('div', { 'class': 'th hide-xs' }, _('MAC-Address')),
E('div', { 'class': 'th' }, _('Host')),
- E('div', { 'class': 'th nowrap' }, _('Signal / Noise')),
- E('div', { 'class': 'th nowrap' }, _('RX Rate / TX Rate'))
+ E('div', { 'class': 'th' }, _('Signal / Noise')),
+ E('div', { 'class': 'th' }, _('RX Rate / TX Rate'))
])
]);