Versie 0.3.3
This commit is contained in:
1 parent
1cf6eeed29
commit
6e741a51fe
57 files changed
+1362
-2135
No files matched your search
@@ -1,4 +1,4 @@
|
||||
// Generated, do not edit. sha256:aff33ec09f0738c89d055fc48911d73d2e952b3818493f0f70824b837ab7c4bf
|
||||
// Generated, do not edit. sha256:ae28972ed451b65f2e773094a56cc2c886f8928f30dfae76134014f65aa7c8e8
|
||||
import { listAccounts } from '../data/accounts.js';
|
||||
import { listAssets } from '../data/assets.js';
|
||||
import { accountHoldings } from '../data/positions.js';
|
||||
@@ -156,8 +156,9 @@ function mountActivity(host, events, accountIds, { onPick = null, nowText = null
|
||||
return nowText && x === todayX ? `${day} · ${nowText}` : day;
|
||||
};
|
||||
const marks = items.filter(it => it.dir === 0)
|
||||
.map(it => ({ x: it.x, variant: MARK_VARIANT[it.kind] || 'account', label: label(it.x) }));
|
||||
if (nowText) marks.push({ x: todayX, variant: 'now', label: label(todayX) });
|
||||
.map(it => ({ x: it.x, variant: MARK_VARIANT[it.kind] || 'account', label: label(it.x) }))
|
||||
.sort((a, b) => (a.variant === 'balance') - (b.variant === 'balance'));
|
||||
if (nowText) marks.unshift({ x: todayX, variant: 'now', label: label(todayX) });
|
||||
const peak = Math.max(1, ...beat.points.map(p => Math.abs(p[1])));
|
||||
mountSparkline(host, beat.points, {
|
||||
yRange: [-peak, peak],
|
||||
|
||||
Reference in new issue
Block a user