cleanup
parent
802b1d820b
commit
c4fec994cf
|
|
@ -1,9 +1,7 @@
|
|||
const settings = require("Storage").readJSON("coin_info.settings.json", 1) || {};
|
||||
const db = require("Storage").readJSON("coin_info.cmc_key.json", 1) || {};
|
||||
const csTokens = db.csTokens.split(',');
|
||||
//
|
||||
var ticker = 0;
|
||||
var csTknNameLen = (csTokens[ticker]).length;
|
||||
|
||||
var Layout = require("Layout");
|
||||
var layout = new Layout({
|
||||
|
|
@ -62,23 +60,12 @@ function setDummy(x) {
|
|||
currentLabel = x;
|
||||
}
|
||||
|
||||
function getFmtTknName(currTKn) {
|
||||
if (currTKn.length > csTknNameLen)
|
||||
csTknNameLen = currTKn.length;
|
||||
|
||||
return currTKn.toUpperCase().padEnd(csTknNameLen);
|
||||
}
|
||||
|
||||
// timeout used to update every minute
|
||||
var drawTimeout;
|
||||
// update the screen
|
||||
function draw() {
|
||||
//
|
||||
// layout.clear(layout.tknName);
|
||||
// layout.clear(layout.tknGraph);
|
||||
|
||||
//
|
||||
layout.tknName.label = getFmtTknName(csTokens[ticker]);
|
||||
layout.tknName.label = (csTokens[ticker]).toUpperCase();
|
||||
layout.tknGraph.label = currentLabel;
|
||||
layout.render();
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{ "id": "coin_info",
|
||||
"name": "Crypto-Coins Info",
|
||||
"shortName":"Coins Info",
|
||||
"version": "0.06.22",
|
||||
"version": "0.06.23",
|
||||
"description": "Crypto-Coins Infos with the help of the Binance API",
|
||||
"icon": "app.png",
|
||||
"tags": "clkinfo",
|
||||
|
|
|
|||
Loading…
Reference in New Issue