add shadow docs, add ztop limit to pocket and trace
This commit is contained in:
parent
a6675efbb4
commit
a48b0f1d80
7 changed files with 138 additions and 41 deletions
|
|
@ -160,6 +160,12 @@ function inRange(value, min, max) {
|
|||
}
|
||||
|
||||
function round(v, zeros) {
|
||||
if (typeof v === 'object') {
|
||||
for (let [key,val] of Object.entries(v)) {
|
||||
v[key] = round(val);
|
||||
}
|
||||
return v;
|
||||
}
|
||||
const prec = zeros !== undefined ? zeros : round_decimal_precision;
|
||||
if (prec === 0) return v | 0;
|
||||
let pow = Math.pow(10, prec);
|
||||
|
|
|
|||
Loading…
Reference in a new issue