remove ws, fmt
This commit is contained in:
parent
5316f40967
commit
cd45c2d9cf
17 changed files with 96 additions and 97 deletions
|
|
@ -14,11 +14,13 @@ Text {
|
|||
const m = {};
|
||||
text().split("\n").forEach(l => {
|
||||
const [k, v] = l.split(":");
|
||||
if (v) m[k.trim()] = parseInt(v.trim());
|
||||
if (v)
|
||||
m[k.trim()] = parseInt(v.trim());
|
||||
});
|
||||
const total = m.MemTotal;
|
||||
const avail = m.MemAvailable;
|
||||
if (total > 0) root.percent = Math.round(((total - avail) / total) * 100);
|
||||
if (total > 0)
|
||||
root.percent = Math.round(((total - avail) / total) * 100);
|
||||
}
|
||||
}
|
||||
Timer {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue