llmtop 0.1.2 → 0.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -1
- package/bin/llmtop.mjs +44 -4
- package/dashboard/dist/assets/index-NQzaBVIY.css +1 -0
- package/dashboard/dist/assets/montserrat-cyrillic-ext-wght-normal-CO5hGrJv.woff2 +0 -0
- package/dashboard/dist/assets/montserrat-cyrillic-wght-normal-EAA9jha_.woff2 +0 -0
- package/dashboard/dist/assets/montserrat-latin-ext-wght-normal-BsZE-iaG.woff2 +0 -0
- package/dashboard/dist/assets/montserrat-latin-wght-normal-l_AIctKy.woff2 +0 -0
- package/dashboard/dist/assets/montserrat-vietnamese-wght-normal-k7S-YeeD.woff2 +0 -0
- package/dashboard/dist/assets/roboto-mono-cyrillic-ext-wght-normal-BUDPrIko.woff2 +0 -0
- package/dashboard/dist/assets/roboto-mono-cyrillic-wght-normal-HUlVHixE.woff2 +0 -0
- package/dashboard/dist/assets/roboto-mono-greek-wght-normal-BJJTbwTT.woff2 +0 -0
- package/dashboard/dist/assets/roboto-mono-latin-ext-wght-normal-QAYlOegK.woff2 +0 -0
- package/dashboard/dist/assets/roboto-mono-latin-wght-normal-CZtBPCCa.woff2 +0 -0
- package/dashboard/dist/assets/roboto-mono-vietnamese-wght-normal-DlC-zuDL.woff2 +0 -0
- package/dashboard/dist/index.html +2 -2
- package/dashboard/src/main.tsx +2 -0
- package/dashboard/src/styles.css +2 -2
- package/package.json +3 -1
- package/src/install.mjs +58 -0
- package/src/process.mjs +237 -0
- package/src/uninstall.mjs +179 -0
- package/src/update.mjs +140 -0
- package/dashboard/dist/assets/index-Cp7Swcz5.css +0 -1
- /package/dashboard/dist/assets/{index-BVbAwMVB.js → index-Ba0kF2tG.js} +0 -0
package/README.md
CHANGED
|
@@ -29,7 +29,7 @@ llmtop serve
|
|
|
29
29
|
|
|
30
30
|
Or run without installing: `npx llmtop serve`. Open <http://localhost:4310>.
|
|
31
31
|
|
|
32
|
-
- **Local-only:** Binds `127.0.0.1` only; zero telemetry, zero
|
|
32
|
+
- **Local-only:** Binds `127.0.0.1` only; zero telemetry, zero background network requests (only `llmtop update` contacts npmjs when invoked), zero runtime npm dependencies.
|
|
33
33
|
- **Zero setup:** Automatically reads `~/.claude/projects`, `~/.codex/sessions`, and `~/.gemini/antigravity-cli`, skipping absent tools.
|
|
34
34
|
- **Persistent archive:** Copies transcripts into append-only `.jsonl.zst` frames and indexes them into SQLite (`node:sqlite`) under `~/.config/llmtop/data/`. Requires **Node.js 22.15+**.
|
|
35
35
|
|
|
@@ -91,11 +91,15 @@ CLI and dashboard totals stay identical for the same window and filters (`--json
|
|
|
91
91
|
|
|
92
92
|
```bash
|
|
93
93
|
llmtop serve [--port n] # Dashboard at http://localhost:4310
|
|
94
|
+
llmtop stop # Stop the running dashboard server
|
|
94
95
|
llmtop scan # Archive new transcript lines into usage.db
|
|
95
96
|
llmtop usage [--days n | --since d --until d] [--by day|model|provider|effort|project|session|hour|tool|skill|subagent]
|
|
96
97
|
[--provider name] [--project name] [--model family] [--effort level] [--json]
|
|
97
98
|
llmtop prices [--json] # Verify prices.md against host cost records
|
|
98
99
|
llmtop show <session>:<line> # Print one archived record
|
|
100
|
+
llmtop update [--check] [--json] # Check npmjs or upgrade to the latest release
|
|
101
|
+
llmtop uninstall [--purge] [--dry-run] [--yes]
|
|
102
|
+
# Stop llmtop and remove the global installation
|
|
99
103
|
llmtop --help | --version
|
|
100
104
|
```
|
|
101
105
|
|
package/bin/llmtop.mjs
CHANGED
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { readFileSync } from "node:fs";
|
|
3
3
|
import { join } from "node:path";
|
|
4
|
-
import { loadConfig, ROOT } from "../src/config.mjs";
|
|
4
|
+
import { defaultConfigDir, defaultConfigPath, loadConfig, ROOT } from "../src/config.mjs";
|
|
5
5
|
import { localTime } from "../src/format.mjs";
|
|
6
6
|
import { pricesCommand } from "../src/prices-command.mjs";
|
|
7
|
+
import { stopCommand, writeServerState } from "../src/process.mjs";
|
|
7
8
|
import { scan, scanReport } from "../src/scan.mjs";
|
|
8
9
|
import { serve } from "../src/serve.mjs";
|
|
9
10
|
import { show } from "../src/show.mjs";
|
|
11
|
+
import { uninstallCommand } from "../src/uninstall.mjs";
|
|
12
|
+
import { updateCommand } from "../src/update.mjs";
|
|
10
13
|
import { usageCommand } from "../src/usage-command.mjs";
|
|
11
14
|
|
|
12
15
|
const { version: VERSION } = JSON.parse(readFileSync(join(ROOT, "package.json"), "utf8"));
|
|
@@ -19,14 +22,30 @@ const USAGE = `usage: llmtop <command> [options]
|
|
|
19
22
|
[--provider name] [--project name] [--model family] [--effort level]
|
|
20
23
|
prices the price table checked against the host's cost records
|
|
21
24
|
serve [--port n] the built dashboard on http://localhost:<port>
|
|
25
|
+
stop stop the running llmtop serve process
|
|
26
|
+
update [--check] [--force] check npmjs or upgrade llmtop to the latest version
|
|
27
|
+
uninstall [--purge] [--dry-run] [--yes]
|
|
28
|
+
stop llmtop and remove the global installation
|
|
22
29
|
|
|
23
30
|
Options:
|
|
24
31
|
-h, --help show this help message
|
|
25
32
|
-v, --version show version (${VERSION})
|
|
26
33
|
|
|
27
|
-
Listing commands accept --json. Config and data default to ~/.config/llmtop
|
|
34
|
+
Listing commands and update --check accept --json. Config and data default to ~/.config/llmtop
|
|
28
35
|
(override with LLMTOP_CONFIG and LLMTOP_DATA).`;
|
|
29
36
|
|
|
37
|
+
function loadConfigOrDefault() {
|
|
38
|
+
try {
|
|
39
|
+
return loadConfig();
|
|
40
|
+
} catch {
|
|
41
|
+
return {
|
|
42
|
+
configPath: defaultConfigPath(),
|
|
43
|
+
data: process.env.LLMTOP_DATA || join(defaultConfigDir(), "data"),
|
|
44
|
+
providers: {},
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
|
|
30
49
|
const COMMANDS = {
|
|
31
50
|
async scan({ config, out }) {
|
|
32
51
|
const t = await scan(config);
|
|
@@ -42,18 +61,38 @@ const COMMANDS = {
|
|
|
42
61
|
if (!Number.isInteger(port) || port < 0 || port > 65535) throw new UsageError(`--port needs a port number, got ${options.port}`);
|
|
43
62
|
const at = localTime(config.timeZone);
|
|
44
63
|
const server = await serve(config, { port, onScan: (t) => reportScan(t, out, `${at(new Date().toISOString())} `) });
|
|
64
|
+
const cleanup = writeServerState(config, { pid: process.pid, port: server.address().port, version: VERSION });
|
|
65
|
+
server.once("close", cleanup);
|
|
66
|
+
let closing = false;
|
|
67
|
+
const shutdown = () => {
|
|
68
|
+
if (closing) return;
|
|
69
|
+
closing = true;
|
|
70
|
+
cleanup();
|
|
71
|
+
server.closeAllConnections?.();
|
|
72
|
+
server.close(() => process.exit(0));
|
|
73
|
+
};
|
|
74
|
+
process.once("SIGINT", shutdown);
|
|
75
|
+
process.once("SIGTERM", shutdown);
|
|
45
76
|
out.write(`dashboard at http://localhost:${server.address().port}: its Refresh button scans again, Ctrl+C to stop\n`);
|
|
46
77
|
},
|
|
47
78
|
prices: pricesCommand,
|
|
79
|
+
stop: stopCommand,
|
|
80
|
+
update: updateCommand,
|
|
81
|
+
uninstall: uninstallCommand,
|
|
48
82
|
};
|
|
49
83
|
|
|
50
84
|
// Options are --name value or --flag; FLAGS lists the ones without a value.
|
|
51
|
-
const FLAGS = new Set(["json"]);
|
|
85
|
+
const FLAGS = new Set(["json", "check", "force", "purge", "dry-run", "yes"]);
|
|
86
|
+
const LENIENT_CONFIG_COMMANDS = new Set(["stop", "update", "uninstall"]);
|
|
52
87
|
function parseArgs(argv) {
|
|
53
88
|
const positional = [];
|
|
54
89
|
const options = {};
|
|
55
90
|
for (let i = 0; i < argv.length; i++) {
|
|
56
91
|
const arg = argv[i];
|
|
92
|
+
if (arg === "-y") {
|
|
93
|
+
options.yes = true;
|
|
94
|
+
continue;
|
|
95
|
+
}
|
|
57
96
|
if (!arg.startsWith("--")) {
|
|
58
97
|
positional.push(arg);
|
|
59
98
|
continue;
|
|
@@ -90,7 +129,8 @@ async function main(argv) {
|
|
|
90
129
|
return 2;
|
|
91
130
|
}
|
|
92
131
|
const { positional, options } = parseArgs(rest);
|
|
93
|
-
|
|
132
|
+
const config = LENIENT_CONFIG_COMMANDS.has(command) ? loadConfigOrDefault() : loadConfig();
|
|
133
|
+
return (await run({ config, positional, options, out: process.stdout })) ?? 0;
|
|
94
134
|
}
|
|
95
135
|
|
|
96
136
|
try {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@font-face{font-family:Montserrat Variable;font-style:normal;font-display:swap;font-weight:100 900;src:url(/assets/montserrat-cyrillic-ext-wght-normal-CO5hGrJv.woff2)format("woff2-variations");unicode-range:U+460-52F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:Montserrat Variable;font-style:normal;font-display:swap;font-weight:100 900;src:url(/assets/montserrat-cyrillic-wght-normal-EAA9jha_.woff2)format("woff2-variations");unicode-range:U+301,U+400-45F,U+490-491,U+4B0-4B1,U+2116}@font-face{font-family:Montserrat Variable;font-style:normal;font-display:swap;font-weight:100 900;src:url(/assets/montserrat-vietnamese-wght-normal-k7S-YeeD.woff2)format("woff2-variations");unicode-range:U+102-103,U+110-111,U+128-129,U+168-169,U+1A0-1A1,U+1AF-1B0,U+300-301,U+303-304,U+308-309,U+323,U+329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Montserrat Variable;font-style:normal;font-display:swap;font-weight:100 900;src:url(/assets/montserrat-latin-ext-wght-normal-BsZE-iaG.woff2)format("woff2-variations");unicode-range:U+100-2BA,U+2BD-2C5,U+2C7-2CC,U+2CE-2D7,U+2DD-2FF,U+304,U+308,U+329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Montserrat Variable;font-style:normal;font-display:swap;font-weight:100 900;src:url(/assets/montserrat-latin-wght-normal-l_AIctKy.woff2)format("woff2-variations");unicode-range:U+??,U+131,U+152-153,U+2BB-2BC,U+2C6,U+2DA,U+2DC,U+304,U+308,U+329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@font-face{font-family:Roboto Mono Variable;font-style:normal;font-display:swap;font-weight:100 700;src:url(/assets/roboto-mono-cyrillic-ext-wght-normal-BUDPrIko.woff2)format("woff2-variations");unicode-range:U+460-52F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:Roboto Mono Variable;font-style:normal;font-display:swap;font-weight:100 700;src:url(/assets/roboto-mono-cyrillic-wght-normal-HUlVHixE.woff2)format("woff2-variations");unicode-range:U+301,U+400-45F,U+490-491,U+4B0-4B1,U+2116}@font-face{font-family:Roboto Mono Variable;font-style:normal;font-display:swap;font-weight:100 700;src:url(/assets/roboto-mono-greek-wght-normal-BJJTbwTT.woff2)format("woff2-variations");unicode-range:U+370-377,U+37A-37F,U+384-38A,U+38C,U+38E-3A1,U+3A3-3FF}@font-face{font-family:Roboto Mono Variable;font-style:normal;font-display:swap;font-weight:100 700;src:url(/assets/roboto-mono-vietnamese-wght-normal-DlC-zuDL.woff2)format("woff2-variations");unicode-range:U+102-103,U+110-111,U+128-129,U+168-169,U+1A0-1A1,U+1AF-1B0,U+300-301,U+303-304,U+308-309,U+323,U+329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Roboto Mono Variable;font-style:normal;font-display:swap;font-weight:100 700;src:url(/assets/roboto-mono-latin-ext-wght-normal-QAYlOegK.woff2)format("woff2-variations");unicode-range:U+100-2BA,U+2BD-2C5,U+2C7-2CC,U+2CE-2D7,U+2DD-2FF,U+304,U+308,U+329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Roboto Mono Variable;font-style:normal;font-display:swap;font-weight:100 700;src:url(/assets/roboto-mono-latin-wght-normal-CZtBPCCa.woff2)format("woff2-variations");unicode-range:U+??,U+131,U+152-153,U+2BB-2BC,U+2C6,U+2DA,U+2DC,U+304,U+308,U+329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}:root{--brand-ink:#1a1a1a;--brand-paper:#f2f2f2;--brand-white:#fff;--brand-black:#000;--brand-tile-dark:#1a1a1a;--brand-tile-light:#f2f2f2;--brand-donut-1:#1a1a1a;--brand-donut-2:#3f3f3f;--brand-donut-3:#7f7f7f;--brand-donut-4:#d8d8d8;--page:var(--brand-paper);--surface:var(--brand-white);--raised:var(--brand-white);--ink:var(--brand-ink);--ink2:#3f3f3f;--muted:#7f7f7f;--hair:#e0e0e0;--base:#c8c8c8;--wash:#1a1a1a0d;--accent:#2a78d6;--accent-ink:#1c5cab;--s1:#2a78d6;--s2:#eb6834;--s3:#1baf7a;--s4:#eda100;--s5:#e87ba4;--s6:#0e9aa7;--s7:#8b5cf6;--s8:#6b8e23;--s9:#d946ef;--s10:#0284c7;--s11:#dc2626;--s12:#65a30d;--s13:#ea580c;--s14:#0d9488;--s15:#4f46e5;--s16:#ca8a04;--s0:#b9b8b0;--sub:#6d4fe8;--seq:#2a78d6;--v0:#c9c4fb;--v1:#9d93f5;--v2:#6f5ce6;--v3:#4630c0;--v4:#26177a;--k0:#d8d8d8;--k1:#888;--k2:#3f3f3f;--kw:repeating-linear-gradient(135deg, #d8d8d8 0 4px, #bebebe 4px 8px);--ck0:#3b6fd9;--ck1:#7c5bd1;--ck2:#a8864f;--good:#0ca30c;--up:#1c5cab;--neg:#d03b3b;--shadow:0 8px 28px #0000001a;--sb:#0b0b0b2e;--sb-hover:#0b0b0b57}:root[data-theme=dark]{--brand-donut-1:#fff;--brand-donut-2:#d8d8d8;--brand-donut-3:#888;--brand-donut-4:#3f3f3f;--page:#111;--surface:var(--brand-ink);--raised:#242424;--ink:var(--brand-white);--ink2:#d8d8d8;--muted:#888;--hair:#2c2c2c;--base:#3f3f3f;--wash:#ffffff12;--accent:#3987e5;--accent-ink:#86b6ef;--s1:#3987e5;--s2:#d95926;--s3:#199e70;--s4:#c98500;--s5:#d55181;--s6:#18b4c2;--s7:#a27bf8;--s8:#8ab03a;--s9:#e879f9;--s10:#38bdf8;--s11:#f87171;--s12:#a3e635;--s13:#fb923c;--s14:#2dd4bf;--s15:#818cf8;--s16:#facc15;--s0:#5a5a55;--sub:#7b66f0;--seq:#3987e5;--v0:#30286a;--v1:#4e42ae;--v2:#7c6ff0;--v3:#b2abff;--v4:#e4e1ff;--k0:#3f3f3f;--k1:#888;--k2:#d8d8d8;--kw:repeating-linear-gradient(135deg, #3f3f3f 0 4px, #555 4px 8px);--ck0:#5b8def;--ck1:#a07eea;--ck2:#c8a878;--good:#0ca30c;--up:#86b6ef;--neg:#e66767;--shadow:0 8px 28px #00000080;--sb:#ffffff29;--sb-hover:#ffffff52}*{box-sizing:border-box}html{-webkit-text-size-adjust:100%;--lightningcss-light:initial;--lightningcss-dark: ;color-scheme:light}html[data-theme=dark]{--lightningcss-light: ;--lightningcss-dark:initial;color-scheme:dark}body{background:var(--page);color:var(--ink);margin:0;font:14px/1.45 Montserrat Variable,Montserrat,system-ui,-apple-system,Segoe UI,sans-serif}button,select,input{font:inherit;color:inherit}code{font:12.5px/1 Roboto Mono Variable,Roboto Mono,ui-monospace,SF Mono,Menlo,monospace}.app{grid-template-columns:228px minmax(0,1fr);min-height:100vh;display:grid}.side{border-right:1px solid var(--hair);background:var(--surface);flex-direction:column;height:100vh;padding:22px 14px 16px;display:flex;position:sticky;top:0}.brand{align-items:center;padding:8px 10px 20px;display:flex}.brand .brand-lockup{flex:none;width:132px;height:auto;display:block}.navlabel{color:var(--muted);letter-spacing:.04em;text-transform:uppercase;margin:14px 10px 6px;font-size:11.5px;font-weight:600}.nav{flex-direction:column;gap:2px;display:flex}.nav button{text-align:left;cursor:pointer;width:100%;color:var(--ink2);background:0 0;border:0;border-radius:9px;align-items:center;gap:10px;padding:8px 10px;font-weight:500;display:flex}.nav button:hover{background:var(--wash);color:var(--ink)}.nav button[aria-current=page]{background:var(--wash);color:var(--ink);font-weight:600}.nav svg{stroke:currentColor;fill:none;stroke-width:1.7px;stroke-linecap:round;stroke-linejoin:round;flex:none;width:16px;height:16px}.nav.quiet button{padding:6px 10px;font-size:13px}.side .foot{border-top:1px solid var(--hair);color:var(--ink2);grid-template-columns:minmax(0,1fr);gap:12px;margin-top:auto;padding:12px 0 0;font-size:12.5px;display:grid}.foot .scan{justify-content:space-between;align-items:center;gap:8px;padding-left:10px;display:flex}.foot .si{min-width:0;color:var(--ink2);white-space:nowrap;text-overflow:ellipsis;font-size:12.5px;line-height:1.4;overflow:hidden}.foot .si span{text-overflow:ellipsis;display:block;overflow:hidden}.foot .scan .icon{background:0 0}.foot .scan .icon:hover:not(:disabled){background:var(--wash)}.foot .prefs{justify-content:space-between;align-items:center;gap:8px;display:flex}.foot .icon{width:30px;height:30px;color:var(--ink2);border-radius:8px}.foot .icon:hover:not(:disabled){color:var(--ink)}.sr{clip-path:inset(50%);white-space:nowrap;width:1px;height:1px;position:absolute;overflow:hidden}.mock{border:1px solid var(--base);border-radius:999px;margin-top:8px;padding:2px 8px;font-size:11.5px;font-weight:500;display:inline-block}main{min-width:0;padding:20px 36px 56px}.wrap{max-width:1320px;margin:0 auto}.seg{background:var(--wash);border-radius:10px;padding:3px;display:inline-flex}.seg button{cursor:pointer;color:var(--ink2);white-space:nowrap;background:0 0;border:0;border-radius:7px;padding:5px 11px;font-size:13px;font-weight:500}.seg button:hover{color:var(--ink)}.seg button[aria-pressed=true]{background:color-mix(in srgb, var(--accent) 16%, var(--raised));color:var(--accent-ink);box-shadow:inset 0 0 0 1px color-mix(in srgb, var(--accent) 40%, transparent)}.icon{background:var(--wash);cursor:pointer;border:0;border-radius:10px;place-items:center;width:34px;height:34px;display:grid}.icon svg{stroke:currentColor;fill:none;stroke-width:1.7px;stroke-linecap:round;stroke-linejoin:round;width:16px;height:16px}.filters{flex-wrap:wrap;align-items:center;gap:10px;margin:0 0 22px;display:flex}.field{border:1px solid var(--hair);background:var(--surface);height:34px;color:var(--ink2);border-radius:10px;align-items:center;gap:6px;padding:0 10px;font-size:13px;display:inline-flex}.field input{min-width:0;color:var(--ink);background:0 0;border:0;outline:none;font-size:13px}.clearall{color:var(--ink);cursor:pointer;gap:6px}.clearall svg{fill:none;stroke:currentColor;stroke-width:1.8px;stroke-linecap:round;width:14px;height:14px}.clearall:hover{border-color:var(--base);background:var(--wash)}.rowlink{color:inherit;font:inherit;cursor:pointer;background:0 0;border:0;padding:0}.rowlink:focus-visible,.clearall:focus-visible{outline:2px solid var(--accent);outline-offset:2px}.grid{gap:20px;display:grid}.kpis{grid-template-columns:repeat(3,minmax(0,1fr))}.two{grid-template-columns:minmax(0,2fr) minmax(0,1fr)}.half{grid-template-columns:repeat(2,minmax(0,1fr))}.stack{gap:20px;display:grid}.card{border:1px solid var(--hair);background:var(--surface);border-radius:14px;min-width:0;padding:16px 20px 20px}.card>header{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:8px 12px;min-height:28px;margin-bottom:14px;display:flex}.card>header .segs{flex-wrap:wrap;gap:8px;display:flex}.card>header .seg{padding:2px}.card>header .seg button{padding:3px 10px;line-height:18px}.card>header .field{height:28px}h2{letter-spacing:-.01em;margin:0;font-size:16px;font-weight:650}.hint{color:var(--ink2);font-size:12.5px}.link{color:var(--accent-ink);cursor:pointer;white-space:nowrap;background:0 0;border:0;padding:0;font-size:13px}.kpi{padding:16px 18px 14px}.kpi .l{color:var(--ink2);white-space:nowrap;text-overflow:ellipsis;font-size:13px;overflow:hidden}.kpi .vr{justify-content:space-between;align-items:flex-end;gap:8px;margin-top:6px;display:flex}.kpi .v{letter-spacing:-.02em;min-width:0;font-size:28px;font-weight:620;line-height:1.1}.kpi .v small{letter-spacing:0;color:var(--ink2);white-space:nowrap;font-size:14px;font-weight:500}.kpi .d{color:var(--ink2);white-space:nowrap;text-overflow:ellipsis;margin-top:10px;font-size:12.5px;overflow:hidden}.kpi .d b{color:var(--ink);font-weight:600}.kpi .d b.better{color:var(--good)}.kpi .d b.worse{color:var(--neg)}.kpi .d b.vol{color:var(--up)}.spark{flex:none;width:72px;height:24px;margin-bottom:4px;overflow:visible}.spark polyline{fill:none;stroke:var(--base);stroke-width:1.5px;vector-effect:non-scaling-stroke;stroke-linejoin:round;stroke-linecap:round}td .spark{margin:0}.spark circle{fill:var(--accent);stroke:var(--surface);stroke-width:2px}.legend{color:var(--ink2);flex-wrap:wrap;gap:4px 16px;margin:0 0 12px;padding:0;font-size:12.5px;list-style:none;display:flex}.legend i{vertical-align:-1px;border-radius:3px;width:10px;height:10px;margin-right:6px;display:inline-block}.legend b{color:var(--ink);margin-left:5px;font-weight:600}.v0{background:var(--v0)}.v1{background:var(--v1)}.v2{background:var(--v2)}.v3{background:var(--v3)}.v4{background:var(--v4)}.v5,.v6,.v7,.v8,.v9{background:var(--s0)}.split i.v0,.split i.v1{color:#0b0b0b}:root[data-theme=dark] .split i.v0,:root[data-theme=dark] .split i.v1{color:#fff}:root[data-theme=dark] .split i.v3,:root[data-theme=dark] .split i.v4{color:#0b0b0b}.lead{margin:0 0 16px;font-size:15.5px;line-height:1.5}.lead b{font-weight:650}.lead.accent{border-left:3px solid;padding:2px 0 2px 12px}.shares{grid-template-columns:max-content minmax(0,1fr);align-items:center;gap:10px 14px;display:grid}.shares>span{color:var(--ink2);font-size:12.5px}.shares .split{margin:0}.lv{align-items:center;gap:7px;display:inline-flex}.lv i{border-radius:3px;width:9px;height:9px}.price td{padding-top:12px;padding-bottom:12px}.price td[data-tip]:hover{background:var(--wash)}.price .sub.up{color:var(--ink);font-weight:600}.x1{color:var(--ink2)}.c1{background:var(--s1)}.c2{background:var(--s2)}.c3{background:var(--s3)}.c4{background:var(--s4)}.c5{background:var(--s5)}.c6{background:var(--s6)}.c7{background:var(--s7)}.c8{background:var(--s8)}.c9{background:var(--s9)}.c10{background:var(--s10)}.c11{background:var(--s11)}.c12{background:var(--s12)}.c13{background:var(--s13)}.c14{background:var(--s14)}.c15{background:var(--s15)}.c16{background:var(--s16)}.c0{background:var(--s0)}.csub{background:var(--sub)}.chart{grid-template-columns:44px minmax(0,1fr);padding-top:10px;display:grid}.axis{height:230px;position:relative}.axis span{color:var(--muted);font-variant-numeric:tabular-nums;white-space:nowrap;font-size:11.5px;position:absolute;right:8px;transform:translateY(50%)}.plot{border-bottom:1px solid var(--base);align-items:flex-end;height:230px;display:flex;position:relative}.plot .gl{background:var(--hair);height:1px;position:absolute;left:0;right:0}.col{outline:none;flex:1;justify-content:center;align-items:flex-end;min-width:0;height:100%;display:flex;position:relative}.col:hover,.col:focus-visible{background:var(--wash)}.bars{flex-direction:column;justify-content:flex-end;gap:2px;width:min(22px,64%);height:100%;display:flex}.bars i{min-height:1px;display:block}.bars i:first-child{border-radius:4px 4px 0 0}.col .x{color:var(--muted);white-space:nowrap;margin-top:8px;font-size:11.5px;position:absolute;top:100%}.col .x em{color:var(--ink2);margin-top:1px;font-style:normal;position:absolute;top:100%;left:0}.xpad{height:44px}.rank{grid-template-columns:minmax(84px,auto) minmax(0,1fr) auto;align-items:center;gap:9px 12px;display:grid}.rank .n{white-space:nowrap;text-overflow:ellipsis;max-width:170px;font-weight:550;overflow:hidden}.rank .n i{border-radius:3px;width:9px;height:9px;margin-right:7px;display:inline-block}.rank .b{background:var(--s1);border-radius:0 4px 4px 0;min-width:2px;height:8px;display:block}.rank .t{background:var(--wash);border-radius:4px;height:8px}.rank .val{text-align:right;font-variant-numeric:tabular-nums;white-space:nowrap}.rank .val small{color:var(--ink2);margin-left:6px;font-size:12px}.rank button.n{text-align:left;cursor:pointer;background:0 0;border:0;padding:0}.rank button.n:hover{color:var(--accent-ink)}.scroll{margin-inline:-10px;overflow-x:auto}table{border-collapse:collapse;font-variant-numeric:tabular-nums;width:100%}th,td{text-align:left;vertical-align:top;border-bottom:1px solid var(--hair);white-space:nowrap;padding:10px 14px 10px 0;font-weight:400}tr:last-child td,tr:last-child th{border-bottom:0}th:first-child,td:first-child{padding-left:10px}th:last-child,td:last-child{padding-right:10px}thead th{color:var(--ink2);vertical-align:bottom;padding-top:0;padding-bottom:8px;font-size:12.5px;font-weight:500;border-bottom:1px solid var(--base)!important}thead th button{color:inherit;font:inherit;cursor:pointer;background:0 0;border:0;padding:0}thead th[aria-sort] button{color:var(--ink);font-weight:600}.compare thead th,.wraphead thead th{white-space:normal;text-wrap:balance;min-width:76px}.flag{color:var(--ink2);vertical-align:super;cursor:default;outline-offset:2px;margin-left:2px;font-size:.55em}.num{text-align:right}.name{font-weight:550}.ph{display:none!important}.sub{color:var(--ink2);margin-top:2px;font-size:12.5px;font-weight:400;display:block}.title{white-space:normal;-webkit-line-clamp:2;-webkit-box-orient:vertical;min-width:140px;max-width:260px;display:-webkit-box;overflow:hidden}.sesstable .title,.sesstable td .sub{white-space:normal;max-width:460px}.sesstable .nw{white-space:nowrap}tbody tr.go{cursor:pointer}tbody tr.go:hover td,tbody tr.go:hover th{background:var(--wash)}.mix{gap:2px;width:84px;height:8px;margin-top:5px;display:flex}.mix i{min-width:2px;height:100%;display:block}.mix i:first-child{border-radius:4px 0 0 4px}.mix i:last-child{border-radius:0 4px 4px 0}.mix i:only-child{border-radius:4px}.heat{grid-template-columns:30px repeat(24,minmax(0,1fr));align-items:center;gap:2px;display:grid}.heat .rl{color:var(--ink2);font-size:12px}.heat .cl{color:var(--muted);text-align:left;padding-top:4px;font-size:11px}.heat .cell{aspect-ratio:1;background:color-mix(in srgb, var(--seq) var(--m), var(--wash));border-radius:3px;width:100%;max-height:26px}.heat .cell:hover{outline:2px solid var(--ink);outline-offset:-1px}.hstats{grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin:18px 0 0;display:grid}.hstats div{align-content:start;gap:2px;min-width:0;display:grid}.hstats dt{color:var(--ink2);font-size:12px}.hstats dd{white-space:nowrap;align-items:center;gap:7px;margin:0;font-size:20px;font-weight:650;display:flex}.hstats .sub{color:var(--muted);font-size:12px}.hstats .sub .line{white-space:nowrap;display:block}.hstats dd.err{color:var(--neg)}.hstats+.rank,.hstats+.legend,.hstats+.rows{margin-top:18px}.lead+.hstats,header+.hstats{margin-top:2px}.hstats .gap{height:16px;display:block}.hstats .meter{background:var(--wash);border-radius:3px;height:6px;margin:6px 0 4px;display:block;overflow:hidden}.hstats .meter i{border-radius:3px;height:100%;display:block}.hstats .dots{flex-wrap:wrap;align-items:center;gap:3px;height:7px;margin:5px 0 4px;display:flex}.hstats .dots i{background:var(--wash);width:7px;height:7px;box-shadow:inset 0 0 0 1px var(--base);border-radius:50%}.hstats .dots i.on{background:var(--seq);box-shadow:none}.hstats .hsw{background:color-mix(in srgb, var(--seq) var(--m), var(--wash));border-radius:3px;width:12px;height:12px}.cseq{background:var(--seq)}.cneg{background:var(--neg)}.split{gap:2px;height:28px;margin:4px 0 12px;display:flex}.split i{color:#fff;white-space:nowrap;border-radius:4px;align-items:center;padding:0 9px;font-size:12.5px;font-style:normal;font-weight:600;display:flex;overflow:hidden}.split i:empty{padding:0}.split i.c4,.split i.c12,.split i.c14,.split i.c16{color:#0b0b0b}.split i.c0{color:var(--ink)}.money td.wide,.money th.wide{width:55%}.rank .b.k0{background:var(--k0)}.rank .b.k1{background:var(--k1)}.rank .b.k2{background:var(--k2)}.rank .b.kw{background:var(--kw)}.rank .b.kx{box-shadow:inset 0 0 0 1px var(--base);background:0 0}.split.kinds{cursor:default;min-width:240px;height:24px;margin:0}.k0{background:var(--k0)}.k1{background:var(--k1)}.k2{background:var(--k2)}.kw{background:var(--kw)}.kx{box-shadow:inset 0 0 0 1px var(--base);background:0 0}.split i.k0,.split i.k1,.split i.kw{color:#0b0b0b}.split i.k2{color:#fff}.split i.kx{color:var(--ink2)}:root[data-theme=dark] .split i.k0,:root[data-theme=dark] .split i.k1,:root[data-theme=dark] .split i.kw{color:#fff}:root[data-theme=dark] .split i.k2{color:#0b0b0b}.ck0{background:var(--ck0)}.ck1{background:var(--ck1)}.ck2{background:var(--ck2)}.empty{text-align:center;color:var(--ink2);padding:40px 0}#tip{z-index:9;border:1px solid var(--base);background:var(--raised);min-width:150px;max-width:400px;box-shadow:var(--shadow);pointer-events:none;border-radius:10px;padding:10px 12px;font-size:12.5px;display:none;position:fixed}#tip .h{color:var(--ink2);margin-bottom:6px}#tip .h:last-child{color:var(--ink);margin-bottom:0}#tip .r{align-items:center;gap:8px;display:flex}#tip .r span{flex:1;min-width:0}#tip .r b{white-space:nowrap}#tip .r i{border-radius:2px;flex:none;width:12px;height:3px}#tip .r span{color:var(--ink2)}#tip .r b{font-variant-numeric:tabular-nums;margin-left:auto;padding-left:16px;font-weight:600}::-webkit-scrollbar{width:12px;height:12px}::-webkit-scrollbar-track{background:0 0}::-webkit-scrollbar-corner{background:0 0}::-webkit-scrollbar-thumb{background:var(--sb) padding-box;border:3px solid #0000;border-radius:999px;min-height:36px}::-webkit-scrollbar-thumb:hover{background-color:var(--sb-hover)}@supports not selector(::-webkit-scrollbar){*{scrollbar-width:thin;scrollbar-color:var(--sb) transparent}}.rank.tools .b{justify-content:flex-end;display:flex;overflow:hidden}.rank.tools .b i{background:var(--neg);height:100%}.rank .val small.err{color:var(--neg)}.rank .grp{color:var(--ink2);letter-spacing:.04em;text-transform:uppercase;grid-column:1/-1;margin-top:6px;font-size:11.5px;font-weight:600}.rank .grp:first-child{margin-top:0}.rank .b.parts{background:0 0;justify-content:flex-start;position:relative}.rank .b.parts b{flex:none;height:100%}.rank .b.parts i{position:absolute;top:0;right:0}.card>.disc.more{margin-top:10px}#tip .r i.neg{background:var(--neg)}.money td{vertical-align:middle}.sharebar{grid-template-columns:minmax(80px,1fr) 44px 64px;align-items:center;gap:10px;min-width:220px;padding-right:12px;display:grid}.sharebar .t{background:var(--wash);border-radius:4px;height:8px;overflow:hidden}.sharebar .t i{border-radius:4px;height:100%;display:block}.sharebar b{text-align:right;font-weight:600}.sharebar small{color:var(--ink2);text-align:right;font-size:12.5px}.rows{grid-template-columns:minmax(64px,auto) minmax(0,1fr);align-items:center;gap:10px 14px;display:grid}.rows.total{grid-template-columns:minmax(64px,auto) minmax(0,1fr) auto}.rows .num{color:var(--ink2);text-align:right;font-size:12.5px}.rows .n{white-space:nowrap;font-weight:550}.tree{position:relative}.tile{box-sizing:border-box;border:2px solid var(--surface);color:#fff;font:inherit;text-align:left;cursor:pointer;border-radius:10px;flex-direction:column;justify-content:flex-end;gap:2px;padding:8px 10px;transition:opacity .15s;display:flex;position:absolute;overflow:hidden}.tile b{white-space:nowrap;text-overflow:ellipsis;font-size:13px;font-weight:600;overflow:hidden}.tile span{opacity:.85;white-space:nowrap;text-overflow:ellipsis;font-size:12px;overflow:hidden}.tile.c4{color:#0b0b0b}.tile.c0{color:var(--ink)}.tile:hover{filter:brightness(1.08)}.tile:focus-visible{outline:2px solid var(--accent);outline-offset:-2px}.compare tfoot th,.compare tfoot td{color:var(--ink2);border-bottom:0;font-weight:600}.compare .quiet{color:var(--muted)}.ctl{flex:none;position:relative}.ctl svg,.search svg,.disc svg{fill:none;stroke:currentColor;stroke-width:1.6px;stroke-linecap:round;stroke-linejoin:round;flex:none;width:14px;height:14px}button.field{cursor:pointer}button.field:hover,button.field[aria-expanded=true],.field.search:focus-within{border-color:var(--base)}button.field:focus-visible,.disc:focus-visible,.clear:focus-visible,.cal-step:focus-visible{outline:2px solid var(--accent);outline-offset:1px}.field.pick{color:var(--ink);gap:8px}.pick .pv{text-overflow:ellipsis;white-space:nowrap;max-width:200px;overflow:hidden}.pick .chev{color:var(--muted);transition:transform .15s}.field.pick.on{border-color:color-mix(in srgb, var(--accent) 45%, transparent);background:color-mix(in srgb, var(--accent) 9%, var(--surface));color:var(--accent-ink)}.field.pick.on .chev{color:var(--accent-ink)}.pick[aria-expanded=true] .chev{transform:rotate(180deg)}.pick .cal{color:var(--ink2)}.pop{z-index:8;border:1px solid var(--base);background:var(--raised);min-width:100%;box-shadow:var(--shadow);border-radius:12px;outline:none;padding:6px;position:absolute;top:calc(100% + 6px);left:0}.ttl{align-items:center;gap:6px;display:flex}.ib{width:22px;height:22px;color:var(--muted);cursor:pointer;background:0 0;border:0;border-radius:6px;place-items:center;padding:0;display:grid}.ib:hover,.ib[aria-expanded=true]{background:var(--wash);color:var(--ink)}.ib svg{fill:none;stroke:currentColor;stroke-width:1.4px;stroke-linecap:round;width:15px;height:15px}.pop.note{width:min(340px,100vw - 16px);color:var(--ink2);white-space:normal;padding:12px 14px;font-size:13px;line-height:1.5}.pop.note p{margin:0 0 8px}.pop.note ul{margin:0;padding-left:16px}.pop.note li+li{margin-top:4px}.note b{color:var(--ink);font-weight:600}.list{min-width:190px;max-height:340px;overflow-y:auto}.opt{color:var(--ink2);white-space:nowrap;cursor:pointer;border-radius:8px;justify-content:space-between;align-items:center;gap:16px;padding:7px 10px;font-size:13px;display:flex}.opt.active{background:color-mix(in srgb, var(--accent) 14%, transparent);color:var(--ink)}.opt[aria-selected=true]{color:var(--accent-ink);font-weight:600}.opt .tick{color:var(--accent-ink)}.cal-pop{padding:12px 14px 10px}.cal-nav{pointer-events:none;justify-content:space-between;display:flex;position:absolute;top:12px;left:12px;right:12px}.cal-step{width:28px;height:28px;color:var(--ink2);cursor:pointer;pointer-events:auto;background:0 0;border:0;border-radius:8px;place-items:center;display:grid}.cal-step:hover:not(:disabled){background:var(--wash);color:var(--ink)}.cal-step:disabled{opacity:.3;cursor:default}.cal-months{gap:28px;display:flex}.cal-title{text-align:center;height:28px;margin-bottom:4px;font-size:13.5px;font-weight:600;line-height:28px}.cal-title:first-letter{text-transform:uppercase}.cal-row{grid-template-columns:repeat(7,36px);display:grid}.cal-wd{text-align:center;height:26px;color:var(--muted);font-size:11.5px;line-height:26px}.cal-cell{place-items:center;height:34px;margin:1px 0;display:grid}.cal-cell.in{background:color-mix(in srgb, var(--accent) 13%, transparent)}.cal-cell.lo,.cal-cell.in:first-child,.blank+.cal-cell.in{border-top-left-radius:9px;border-bottom-left-radius:9px}.cal-cell.hi,.cal-cell.in:last-child{border-top-right-radius:9px;border-bottom-right-radius:9px}.cal-cell.in:has(+.blank){border-top-right-radius:9px;border-bottom-right-radius:9px}.cal-day{width:34px;height:34px;color:var(--ink);font-variant-numeric:tabular-nums;cursor:pointer;background:0 0;border:0;border-radius:9px;font-size:13px}.cal-day:hover:not(:disabled){background:var(--wash)}.cal-day.today{box-shadow:inset 0 0 0 1px var(--base)}.cal-day.end,.cal-day.end:hover{background:var(--accent);color:#fff;box-shadow:none;font-weight:600}.cal-day:disabled{color:var(--muted);opacity:.45;cursor:default}.cal-day:focus-visible{outline:2px solid var(--accent);outline-offset:1px}.field.search{gap:7px}.search .mag{color:var(--muted)}.search input{width:200px}.clear{width:22px;height:22px;color:var(--muted);cursor:pointer;background:0 0;border:0;border-radius:6px;place-items:center;margin-right:-5px;display:grid}.clear:hover{background:var(--wash);color:var(--ink)}.disc{color:var(--ink2);cursor:pointer;background:0 0;border:0;border-radius:7px;align-items:center;gap:6px;margin-left:-6px;padding:4px 8px 4px 6px;font-size:12.5px;display:inline-flex}.disc:hover{background:var(--wash);color:var(--ink)}.disc svg{transition:transform .15s}.disc[aria-expanded=true] svg{transform:rotate(90deg)}.disclosure .scroll{margin-top:10px}@media (prefers-reduced-motion:reduce){.pick .chev,.disc svg{transition:none}}@media (width<=1400px){.o3{display:none}.filters{gap:8px}.pick .pv{max-width:112px}.range .pv{max-width:none}.filters .seg button{padding:5px 7px}}@media (width<=1500px){.wraphead .o3{display:none}}@media (width<=1060px){.two,.half{grid-template-columns:minmax(0,1fr)}.o2{display:none}}@media (width<=880px){.app{display:block}.side{border-right:0;border-bottom:1px solid var(--hair);scrollbar-width:none;flex-direction:row;align-items:center;gap:4px 6px;height:auto;padding:10px 16px;position:static;overflow-x:auto}.side::-webkit-scrollbar{display:none}.nav{flex:none}.brand{flex:none;padding:6px 10px 6px 2px}.brand .brand-lockup{width:120px}.navlabel,.foot .si{display:none}.foot .scan{padding:0}.foot .scan .icon{background:var(--wash)}.side .foot{background:var(--surface);border-top:0;align-self:stretch;align-items:center;gap:6px;margin:0 -16px 0 auto;padding:0 16px 0 10px;display:flex;position:sticky;right:-16px}.nav{flex-direction:row}.nav button{white-space:nowrap}.nav svg{display:none}.nav.quiet button{padding:8px 10px;font-size:14px}main{padding:20px 20px 48px}.title{max-width:200px}.filters{gap:8px}.filters .seg button{padding:5px 6px;font-size:12.5px}.field{padding:0 8px}}@media (width<=600px){main{padding:16px 16px 40px}.kpis{grid-template-columns:repeat(2,minmax(0,1fr))}.grid,.stack{gap:14px}.kpi .spark{display:none}.kpi .d{white-space:normal}.kpi .v{font-size:24px}.card{padding:16px}.o1{display:none}.title{max-width:160px}.search input{width:150px}.ph{white-space:normal;max-width:170px;display:block!important}thead th{white-space:normal}.mix.wide{width:84px!important}th,td{padding-right:10px}.axis,.plot{height:190px}.chart{grid-template-columns:38px minmax(0,1fr)}.heat{grid-template-columns:32px repeat(24,minmax(0,1fr));gap:1px}.hstats{grid-template-columns:repeat(2,minmax(0,1fr))}.rank .n{max-width:120px}.price th,.price td{padding-right:8px;font-size:13px}.price .lv{gap:5px}}.refresh:disabled{cursor:progress}.refresh.busy svg{animation:1s linear infinite spin}@keyframes spin{to{transform:rotate(360deg)}}@media (prefers-reduced-motion:reduce){.refresh.busy svg{animation-duration:3s}}.alert{color:var(--neg);margin:-6px 0 0;font-size:12.5px}.loading{text-align:center;color:var(--ink2);padding:80px 0}.boot{place-items:center;min-height:100vh;padding:24px 16px;display:grid}.boot-in{gap:14px;width:min(400px,100%);margin-top:-8vh;display:grid}.boot .brand{padding:8px 0 12px}.boot .brand .brand-lockup{width:160px}.boot-msg{margin:0;font-size:15px;font-weight:550}.boot-err{color:var(--neg);overflow-wrap:anywhere;margin:0;font-size:13px}.boot .clearall{justify-self:start}.boot-bar{background:var(--wash);border-radius:3px;height:6px;overflow:hidden}.boot-bar span{background:var(--accent);border-radius:3px;width:0;height:100%;transition:width .3s;display:block}.boot-bar.wait span{width:30%;animation:1.2s ease-in-out infinite boot-wait}@keyframes boot-wait{0%{transform:translate(-100%)}to{transform:translate(340%)}}.boot-count{color:var(--ink2);font-variant-numeric:tabular-nums;margin:0;font-size:12.5px}@media (prefers-reduced-motion:reduce){.boot-bar span{transition:none}.boot-bar.wait span{opacity:.35;width:100%;animation:none}}.plot .bands,.plot .bands i,.plot .bands svg{pointer-events:none;position:absolute;inset:0}.plot .bands svg{width:100%;height:100%;overflow:visible}.plot .bands i{opacity:.42;-webkit-mask-image:linear-gradient(#000 20%,#00000026);mask-image:linear-gradient(#000 20%,#00000026)}:root[data-theme=dark] .plot .bands i{opacity:.62}.plot .bands polyline{fill:none;stroke:var(--base);stroke-width:2px;vector-effect:non-scaling-stroke;stroke-linejoin:round;stroke-linecap:round}.plot .bands polyline.c0{stroke:var(--s0)}.plot .bands polyline.c1{stroke:var(--s1)}.plot .bands polyline.c2{stroke:var(--s2)}.plot .bands polyline.c3{stroke:var(--s3)}.plot .bands polyline.c4{stroke:var(--s4)}.plot .bands polyline.c5{stroke:var(--s5)}.plot .bands polyline.c6{stroke:var(--s6)}.plot .bands polyline.c7{stroke:var(--s7)}.plot .bands polyline.c8{stroke:var(--s8)}.plot .bands polyline.c9{stroke:var(--s9)}.plot .bands polyline.c10{stroke:var(--s10)}.plot .bands polyline.c11{stroke:var(--s11)}.plot .bands polyline.c12{stroke:var(--s12)}.plot .bands polyline.c13{stroke:var(--s13)}.plot .bands polyline.c14{stroke:var(--s14)}.plot .bands polyline.c15{stroke:var(--s15)}.plot .bands polyline.c16{stroke:var(--s16)}.plot .bands polyline.csub{stroke:var(--sub)}.plot .bands polyline.v0{stroke:var(--v0)}.plot .bands polyline.v1{stroke:var(--v1)}.plot .bands polyline.v2{stroke:var(--v2)}.plot .bands polyline.v3{stroke:var(--v3)}.plot .bands polyline.v4{stroke:var(--v4)}.plot .bands polyline.k0{stroke:var(--k0)}.plot .bands polyline.k1{stroke:var(--k1)}.plot .bands polyline.k2{stroke:var(--k2)}.plot .bands polyline.kw,.plot .bands polyline.kx{stroke:var(--base)}.plot.area .col:hover,.plot.area .col:focus-visible{background:0 0}.plot.area .col:hover:before,.plot.area .col:focus-visible:before{content:"";background:var(--ink);opacity:.55;width:1px;position:absolute;top:0;bottom:0;left:50%}.plot.area .col .dot{z-index:1;width:8px;height:8px;box-shadow:0 0 0 2px var(--surface);pointer-events:none;border-radius:50%;margin:0 0 -4px -4px;display:none;position:absolute;left:50%}.plot.area .col:hover .dot,.plot.area .col:focus-visible .dot{display:block}.spark polygon{stroke:none}.spark .g0{stop-color:var(--ink2);stop-opacity:.2}.spark .g1{stop-color:var(--ink2);stop-opacity:0}.magbar{min-width:56px;padding-bottom:6px;display:inline-block;position:relative}.magbar:after{content:"";height:3px;width:calc(var(--w) * 56px);background:var(--ink2);opacity:.55;border-radius:2px;position:absolute;bottom:0;right:0}.panels{grid-template-columns:repeat(3,minmax(0,1fr));gap:22px 32px;display:grid}.panel h3{color:var(--ink2);margin:0 0 10px;font-size:13px;font-weight:600}@media (width<=1060px){.panels{grid-template-columns:repeat(2,minmax(0,1fr))}}@media (width<=640px){.panels{grid-template-columns:minmax(0,1fr)}}.chartseg button{align-items:center;display:inline-flex}.chartseg svg{fill:none;stroke:currentColor;stroke-width:1.8px;stroke-linecap:round;stroke-linejoin:round;width:16px;height:16px}.card>header .segs{align-items:center}.gauge{margin:2px 0 6px}.gauge .track{gap:2px;height:14px;display:flex}.gauge .track i{height:100%;display:block}.gauge .track i:first-child{border-radius:4px 0 0 4px}.gauge .track i:last-child{border-radius:0 4px 4px 0}.gauge .ticks{height:18px;color:var(--muted);font-variant-numeric:tabular-nums;margin-top:6px;font-size:11.5px;position:relative}.gauge .ticks span{white-space:nowrap;position:absolute;top:0;transform:translate(-50%)}.gauge .ticks span:first-child{transform:none}.gauge .ticks span:last-child{color:var(--ink2);transform:translate(-100%)}.ctx .hstats{grid-template-columns:repeat(3,minmax(0,1fr));margin:16px 0 18px}.ctx .hstats .tipped{cursor:default;-webkit-text-decoration:underline dotted var(--base);text-decoration:underline dotted var(--base);text-underline-offset:5px;outline-offset:3px}.ctx td,.ctx th{vertical-align:middle}.ctx td.lbl{font-weight:550}.ctx td.lbl .sub{margin:0 0 0 6px;display:inline}.ctx tfoot td{border-top:1px solid var(--base);color:var(--ink2);border-bottom:0;font-weight:600}.ctx .better{color:var(--good);font-weight:600}.ctx .worse{color:var(--neg);font-weight:600}.cell-bar{width:42%}td.cell-bar .split.kinds{min-width:0;height:20px;margin:0}.bar1{background:var(--s1);border-radius:0 4px 4px 0;min-width:2px;height:8px;display:block}.est{border:1px dashed var(--base);height:22px;color:var(--ink2);font:inherit;cursor:default;background:0 0;border-radius:999px;align-items:center;padding:0 9px;font-size:12px;font-weight:500;display:inline-flex}.est:hover,.est:focus-visible{color:var(--ink);border-color:var(--ink2)}.chip{background:color-mix(in srgb, var(--accent) 16%, var(--raised));color:var(--accent-ink);vertical-align:1px;border-radius:999px;margin-left:8px;padding:1px 7px;font-size:11.5px;font-weight:600;display:inline-block}.ctx tbody tr.now td{--line:color-mix(in srgb, var(--accent) 45%, transparent);background:color-mix(in srgb, var(--accent) 7%, transparent);box-shadow:inset 0 1px 0 var(--line), inset 0 -1px 0 var(--line)}.ctx tbody tr.now td:first-child{box-shadow:inset 1px 1px 0 var(--line), inset 0 -1px 0 var(--line);border-radius:8px 0 0 8px}.ctx tbody tr.now td:last-child{box-shadow:inset -1px 1px 0 var(--line), inset 0 -1px 0 var(--line);border-radius:0 8px 8px 0}@media (width<=600px){.ctx .hstats{grid-template-columns:repeat(3,minmax(0,1fr))}.ctx .hstats dd{font-size:17px}}.kpi{container-type:inline-size}@container (width<=260px){.kpis:has(.v small) .spark{display:none}}
|
|
@@ -9,8 +9,8 @@
|
|
|
9
9
|
<link rel="apple-touch-icon" href="/apple-touch-icon.png">
|
|
10
10
|
<link rel="manifest" href="/site.webmanifest">
|
|
11
11
|
<meta name="theme-color" content="#1A1A1A">
|
|
12
|
-
<script type="module" crossorigin src="/assets/index-
|
|
13
|
-
<link rel="stylesheet" crossorigin href="/assets/index-
|
|
12
|
+
<script type="module" crossorigin src="/assets/index-Ba0kF2tG.js"></script>
|
|
13
|
+
<link rel="stylesheet" crossorigin href="/assets/index-NQzaBVIY.css">
|
|
14
14
|
</head>
|
|
15
15
|
<body>
|
|
16
16
|
<div id="root"></div>
|
package/dashboard/src/main.tsx
CHANGED
package/dashboard/src/styles.css
CHANGED
|
@@ -25,9 +25,9 @@
|
|
|
25
25
|
* { box-sizing: border-box; }
|
|
26
26
|
html { -webkit-text-size-adjust: 100%; color-scheme: light; }
|
|
27
27
|
html[data-theme="dark"] { color-scheme: dark; }
|
|
28
|
-
body { margin: 0; background: var(--page); color: var(--ink); font: 14px/1.45 "Montserrat", system-ui, -apple-system, "Segoe UI", sans-serif; }
|
|
28
|
+
body { margin: 0; background: var(--page); color: var(--ink); font: 14px/1.45 "Montserrat Variable", "Montserrat", system-ui, -apple-system, "Segoe UI", sans-serif; }
|
|
29
29
|
button, select, input { font: inherit; color: inherit; }
|
|
30
|
-
code { font: 12.5px/1 "Roboto Mono", ui-monospace, "SF Mono", Menlo, monospace; }
|
|
30
|
+
code { font: 12.5px/1 "Roboto Mono Variable", "Roboto Mono", ui-monospace, "SF Mono", Menlo, monospace; }
|
|
31
31
|
.app { display: grid; grid-template-columns: 228px minmax(0, 1fr); min-height: 100vh; }
|
|
32
32
|
|
|
33
33
|
/* sidebar */
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "llmtop",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.3",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Local usage and cost analytics dashboard and CLI for Claude Code, Codex and Antigravity",
|
|
6
6
|
"author": "Trung Nguyen",
|
|
@@ -63,6 +63,8 @@
|
|
|
63
63
|
"test": "node --test \"test/*.test.mjs\" \"dashboard/src/*.test.ts\""
|
|
64
64
|
},
|
|
65
65
|
"devDependencies": {
|
|
66
|
+
"@fontsource-variable/montserrat": "^5.3.0",
|
|
67
|
+
"@fontsource-variable/roboto-mono": "^5.3.0",
|
|
66
68
|
"@types/node": "^26.6.6",
|
|
67
69
|
"@types/react": "^19.3.0",
|
|
68
70
|
"@types/react-dom": "^19.3.0",
|
package/src/install.mjs
ADDED
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { spawnSync } from "node:child_process";
|
|
2
|
+
import { existsSync } from "node:fs";
|
|
3
|
+
import { join } from "node:path";
|
|
4
|
+
import { ROOT } from "./config.mjs";
|
|
5
|
+
|
|
6
|
+
export function detectInstallMode({ root = ROOT, exists = existsSync } = {}) {
|
|
7
|
+
const normalized = root.replace(/\\/g, "/");
|
|
8
|
+
if (normalized.includes("/_npx/")) return { mode: "npx", packageManager: "npm", root };
|
|
9
|
+
if (!normalized.includes("/node_modules/") && exists(join(root, ".git"))) return { mode: "local", packageManager: null, root };
|
|
10
|
+
if (normalized.includes("/pnpm/") || normalized.includes("/pnpm-global/")) return { mode: "global", packageManager: "pnpm", root };
|
|
11
|
+
if (normalized.includes("/yarn/") || normalized.includes("/.yarn/")) return { mode: "global", packageManager: "yarn", root };
|
|
12
|
+
if (normalized.includes("/.bun/")) return { mode: "global", packageManager: "bun", root };
|
|
13
|
+
if (normalized.includes("/node_modules/")) return { mode: "global", packageManager: "npm", root };
|
|
14
|
+
return { mode: "unknown", packageManager: "npm", root };
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export function packageManagerCommand(pm, action, spec) {
|
|
18
|
+
const table = {
|
|
19
|
+
npm: { install: ["npm", ["install", "-g", spec]], uninstall: ["npm", ["uninstall", "-g", spec]] },
|
|
20
|
+
pnpm: { install: ["pnpm", ["add", "-g", spec]], uninstall: ["pnpm", ["remove", "-g", spec]] },
|
|
21
|
+
yarn: { install: ["yarn", ["global", "add", spec]], uninstall: ["yarn", ["global", "remove", spec]] },
|
|
22
|
+
bun: { install: ["bun", ["add", "-g", spec]], uninstall: ["bun", ["remove", "-g", spec]] },
|
|
23
|
+
};
|
|
24
|
+
const manager = table[pm] ?? table.npm;
|
|
25
|
+
return manager[action];
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export function formatCommand(cmd, args) {
|
|
29
|
+
return [cmd, ...args].join(" ");
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export function runPackageManager(pm, action, spec, { spawn = spawnSync, platform = process.platform } = {}) {
|
|
33
|
+
const [cmd, args] = packageManagerCommand(pm, action, spec);
|
|
34
|
+
const command = formatCommand(cmd, args);
|
|
35
|
+
const res = spawn(cmd, args, { encoding: "utf8", stdio: "pipe", shell: platform === "win32" });
|
|
36
|
+
const stdout = res.stdout ?? "";
|
|
37
|
+
const stderr = res.stderr ?? "";
|
|
38
|
+
const error = res.error ? res.error.message : "";
|
|
39
|
+
const ok = !res.error && res.status === 0;
|
|
40
|
+
const permissionDenied = /EACCES|EPERM|permission denied/i.test(`${stderr}\n${error}`);
|
|
41
|
+
return { ok, code: res.status ?? 1, stdout, stderr, error, command, permissionDenied };
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export function hasGlobalPackage(pm = "npm", pkgName = "llmtop", { spawn = spawnSync, platform = process.platform } = {}) {
|
|
45
|
+
if (pm !== "npm") return false;
|
|
46
|
+
try {
|
|
47
|
+
const res = spawn("npm", ["list", "-g", pkgName, "--depth=0", "--json"], {
|
|
48
|
+
encoding: "utf8",
|
|
49
|
+
stdio: "pipe",
|
|
50
|
+
shell: platform === "win32",
|
|
51
|
+
});
|
|
52
|
+
if (res.status !== 0 || !res.stdout?.trim()) return false;
|
|
53
|
+
const parsed = JSON.parse(res.stdout);
|
|
54
|
+
return Boolean(parsed?.dependencies?.[pkgName]);
|
|
55
|
+
} catch {
|
|
56
|
+
return false;
|
|
57
|
+
}
|
|
58
|
+
}
|
package/src/process.mjs
ADDED
|
@@ -0,0 +1,237 @@
|
|
|
1
|
+
import { spawnSync } from "node:child_process";
|
|
2
|
+
import { existsSync, mkdirSync, readFileSync, renameSync, unlinkSync, writeFileSync } from "node:fs";
|
|
3
|
+
import { join } from "node:path";
|
|
4
|
+
import { ROOT } from "./config.mjs";
|
|
5
|
+
|
|
6
|
+
export function serverStatePath(config) {
|
|
7
|
+
return join(config.data, "serve.json");
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
// Writes serve.json atomically and returns a cleanup callback that removes it only if the PID still matches.
|
|
11
|
+
export function writeServerState(config, { pid = process.pid, port, version }) {
|
|
12
|
+
const path = serverStatePath(config);
|
|
13
|
+
mkdirSync(config.data, { recursive: true });
|
|
14
|
+
const tmp = join(config.data, `.serve.${pid}.${process.hrtime.bigint()}.tmp`);
|
|
15
|
+
const payload = JSON.stringify({ pid, port, startedAt: new Date().toISOString(), version }, null, 2);
|
|
16
|
+
writeFileSync(tmp, `${payload}\n`);
|
|
17
|
+
renameSync(tmp, path);
|
|
18
|
+
return () => {
|
|
19
|
+
try {
|
|
20
|
+
const current = JSON.parse(readFileSync(path, "utf8"));
|
|
21
|
+
if (current?.pid === pid) unlinkSync(path);
|
|
22
|
+
} catch {
|
|
23
|
+
// Missing or already replaced state file needs no cleanup.
|
|
24
|
+
}
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export function readServerState(config, { exists = existsSync, readFile = readFileSync } = {}) {
|
|
29
|
+
const path = serverStatePath(config);
|
|
30
|
+
if (!exists(path)) return null;
|
|
31
|
+
try {
|
|
32
|
+
const parsed = JSON.parse(readFile(path, "utf8"));
|
|
33
|
+
return parsed && typeof parsed === "object" ? parsed : null;
|
|
34
|
+
} catch {
|
|
35
|
+
return null;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
export function isPidAlive(pid) {
|
|
40
|
+
if (!Number.isInteger(pid) || pid <= 0) return false;
|
|
41
|
+
try {
|
|
42
|
+
process.kill(pid, 0);
|
|
43
|
+
return true;
|
|
44
|
+
} catch (err) {
|
|
45
|
+
return err?.code === "EPERM";
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export function isLlmtopServeCommand(command) {
|
|
50
|
+
if (typeof command !== "string") return false;
|
|
51
|
+
const trimmed = command.trim();
|
|
52
|
+
if (!trimmed) return false;
|
|
53
|
+
if (/^(?:\/[\w/.-]*\/)?(?:sh|bash|zsh|fish|grep|rg|awk|sed)\b/.test(trimmed)) return false;
|
|
54
|
+
return /(?:^|[\s"'/\\])llmtop(?:\.mjs|\.cmd|\.ps1)?["']?\s+serve(?:\s|$)/.test(trimmed);
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
export function listOsProcesses({ spawn = spawnSync, platform = process.platform } = {}) {
|
|
58
|
+
try {
|
|
59
|
+
if (platform === "win32") {
|
|
60
|
+
const res = spawn(
|
|
61
|
+
"powershell.exe",
|
|
62
|
+
["-NoProfile", "-Command", "Get-CimInstance Win32_Process | Select-Object ProcessId,CommandLine | ConvertTo-Json -Compress"],
|
|
63
|
+
{ encoding: "utf8", stdio: "pipe" },
|
|
64
|
+
);
|
|
65
|
+
if (res.status !== 0 || !res.stdout?.trim()) return [];
|
|
66
|
+
const parsed = JSON.parse(res.stdout);
|
|
67
|
+
const list = Array.isArray(parsed) ? parsed : [parsed];
|
|
68
|
+
return list
|
|
69
|
+
.filter((item) => item && Number.isInteger(Number(item.ProcessId)) && Number(item.ProcessId) > 0)
|
|
70
|
+
.map((item) => ({ pid: Number(item.ProcessId), command: String(item.CommandLine || "") }));
|
|
71
|
+
}
|
|
72
|
+
const res = spawn("ps", ["-eo", "pid=,args="], { encoding: "utf8", stdio: "pipe" });
|
|
73
|
+
if (res.status !== 0 || !res.stdout) return [];
|
|
74
|
+
const processes = [];
|
|
75
|
+
for (const line of res.stdout.split(/\r?\n/)) {
|
|
76
|
+
const match = line.match(/^\s*(\d+)\s+(.+)$/);
|
|
77
|
+
if (!match) continue;
|
|
78
|
+
processes.push({ pid: Number(match[1]), command: match[2].trim() });
|
|
79
|
+
}
|
|
80
|
+
return processes;
|
|
81
|
+
} catch {
|
|
82
|
+
return [];
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
function parsePortFromCommand(command) {
|
|
87
|
+
const match = command.match(/(?:^|\s)--port(?:=|\s+)(\d+)\b/);
|
|
88
|
+
return match ? Number(match[1]) : null;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
export function findRunningServers(config, deps = {}) {
|
|
92
|
+
const {
|
|
93
|
+
listProcesses = listOsProcesses,
|
|
94
|
+
isAlive = isPidAlive,
|
|
95
|
+
selfPid = process.pid,
|
|
96
|
+
root = ROOT,
|
|
97
|
+
exists = existsSync,
|
|
98
|
+
readFile = readFileSync,
|
|
99
|
+
} = deps;
|
|
100
|
+
const osList = listProcesses();
|
|
101
|
+
const osByPid = new Map(osList.map((p) => [p.pid, p]));
|
|
102
|
+
const byPid = new Map();
|
|
103
|
+
let staleState = false;
|
|
104
|
+
|
|
105
|
+
const statePath = serverStatePath(config);
|
|
106
|
+
if (exists(statePath)) {
|
|
107
|
+
const state = readServerState(config, { exists, readFile });
|
|
108
|
+
if (state && Number.isInteger(state.pid) && state.pid > 0) {
|
|
109
|
+
if (state.pid !== selfPid) {
|
|
110
|
+
const osEntry = osByPid.get(state.pid);
|
|
111
|
+
const matchesOs = osList.length === 0 || (osEntry && isLlmtopServeCommand(osEntry.command));
|
|
112
|
+
if (isAlive(state.pid) && matchesOs) {
|
|
113
|
+
byPid.set(state.pid, { pid: state.pid, port: state.port ?? null, source: "state" });
|
|
114
|
+
} else {
|
|
115
|
+
staleState = true;
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
} else {
|
|
119
|
+
staleState = true;
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
const pidFile = join(root, "data", "serve.pid");
|
|
124
|
+
if (exists(pidFile)) {
|
|
125
|
+
try {
|
|
126
|
+
const pid = Number(readFile(pidFile, "utf8").trim());
|
|
127
|
+
if (Number.isInteger(pid) && pid > 0 && pid !== selfPid && isAlive(pid)) {
|
|
128
|
+
const osEntry = osByPid.get(pid);
|
|
129
|
+
if (osEntry && isLlmtopServeCommand(osEntry.command)) {
|
|
130
|
+
const existing = byPid.get(pid);
|
|
131
|
+
if (existing) existing.pidFile = pidFile;
|
|
132
|
+
else byPid.set(pid, { pid, port: parsePortFromCommand(osEntry.command), source: "pidfile", pidFile });
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
} catch {
|
|
136
|
+
// Ignore unreadable legacy pidfile.
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
for (const proc of osList) {
|
|
141
|
+
if (proc.pid === selfPid || byPid.has(proc.pid) || !isLlmtopServeCommand(proc.command)) continue;
|
|
142
|
+
byPid.set(proc.pid, { pid: proc.pid, port: parsePortFromCommand(proc.command), source: "process" });
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
return { servers: [...byPid.values()].sort((a, b) => a.pid - b.pid), staleState };
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
async function waitForExit(pid, isAlive, sleep, timeoutMs) {
|
|
149
|
+
const deadline = Date.now() + timeoutMs;
|
|
150
|
+
while (isAlive(pid)) {
|
|
151
|
+
if (Date.now() >= deadline) return false;
|
|
152
|
+
await sleep(50);
|
|
153
|
+
}
|
|
154
|
+
return true;
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
export async function stopRunningServers(config, deps = {}) {
|
|
158
|
+
const {
|
|
159
|
+
kill = process.kill,
|
|
160
|
+
sleep = (ms) => new Promise((resolve) => setTimeout(resolve, ms)),
|
|
161
|
+
timeoutMs = 3000,
|
|
162
|
+
unlink = unlinkSync,
|
|
163
|
+
isAlive = isPidAlive,
|
|
164
|
+
exists = existsSync,
|
|
165
|
+
readFile = readFileSync,
|
|
166
|
+
} = deps;
|
|
167
|
+
const { servers, staleState } = findRunningServers(config, { ...deps, isAlive, exists, readFile });
|
|
168
|
+
const stopped = [];
|
|
169
|
+
const failed = [];
|
|
170
|
+
|
|
171
|
+
for (const server of servers) {
|
|
172
|
+
try {
|
|
173
|
+
kill(server.pid, "SIGTERM");
|
|
174
|
+
} catch (err) {
|
|
175
|
+
if (err?.code !== "ESRCH") {
|
|
176
|
+
failed.push({ ...server, error: err?.message ?? String(err) });
|
|
177
|
+
continue;
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
let exited = await waitForExit(server.pid, isAlive, sleep, timeoutMs);
|
|
181
|
+
if (!exited) {
|
|
182
|
+
try {
|
|
183
|
+
kill(server.pid, "SIGKILL");
|
|
184
|
+
} catch (err) {
|
|
185
|
+
if (err?.code !== "ESRCH") {
|
|
186
|
+
failed.push({ ...server, error: err?.message ?? String(err) });
|
|
187
|
+
continue;
|
|
188
|
+
}
|
|
189
|
+
}
|
|
190
|
+
exited = await waitForExit(server.pid, isAlive, sleep, 500);
|
|
191
|
+
}
|
|
192
|
+
if (!exited && isAlive(server.pid)) {
|
|
193
|
+
failed.push({ ...server, error: "process did not exit" });
|
|
194
|
+
continue;
|
|
195
|
+
}
|
|
196
|
+
stopped.push(server);
|
|
197
|
+
if (server.pidFile) {
|
|
198
|
+
try {
|
|
199
|
+
unlink(server.pidFile);
|
|
200
|
+
} catch {
|
|
201
|
+
// Ignore missing legacy pidfile.
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
let cleanedState = false;
|
|
207
|
+
const statePath = serverStatePath(config);
|
|
208
|
+
if (exists(statePath)) {
|
|
209
|
+
const state = readServerState(config, { exists, readFile });
|
|
210
|
+
if (!state || !Number.isInteger(state.pid) || !isAlive(state.pid) || staleState) {
|
|
211
|
+
try {
|
|
212
|
+
unlink(statePath);
|
|
213
|
+
cleanedState = true;
|
|
214
|
+
} catch {
|
|
215
|
+
// Ignore already-deleted state file.
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
return { stopped, failed, cleanedState };
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
export async function stopCommand({ config, out, err = process.stderr, deps = {} }) {
|
|
224
|
+
const { stopped, failed } = await stopRunningServers(config, deps);
|
|
225
|
+
if (failed.length) {
|
|
226
|
+
for (const f of failed) err.write(`error: could not stop llmtop serve (pid ${f.pid}): ${f.error}\n`);
|
|
227
|
+
return 1;
|
|
228
|
+
}
|
|
229
|
+
if (!stopped.length) {
|
|
230
|
+
out.write("llmtop serve is not running\n");
|
|
231
|
+
return 0;
|
|
232
|
+
}
|
|
233
|
+
for (const s of stopped) {
|
|
234
|
+
out.write(`stopped llmtop serve (pid ${s.pid}${s.port ? `, port ${s.port}` : ""})\n`);
|
|
235
|
+
}
|
|
236
|
+
return 0;
|
|
237
|
+
}
|
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
import { existsSync, readdirSync, rmSync, rmdirSync } from "node:fs";
|
|
2
|
+
import { homedir } from "node:os";
|
|
3
|
+
import { dirname, resolve, sep } from "node:path";
|
|
4
|
+
import { createInterface } from "node:readline/promises";
|
|
5
|
+
import { defaultConfigDir } from "./config.mjs";
|
|
6
|
+
import { detectInstallMode, hasGlobalPackage, packageManagerCommand, formatCommand, runPackageManager } from "./install.mjs";
|
|
7
|
+
import { findRunningServers, stopRunningServers } from "./process.mjs";
|
|
8
|
+
|
|
9
|
+
function isSameOrInside(target, parent) {
|
|
10
|
+
return target === parent || target.startsWith(parent + sep);
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export function collectDataTargets(config, { env = process.env, home = homedir(), exists = existsSync } = {}) {
|
|
14
|
+
const defaultDir = resolve(defaultConfigDir(env, home));
|
|
15
|
+
const cfgPath = resolve(config.configPath);
|
|
16
|
+
const dataDir = resolve(config.data);
|
|
17
|
+
const homeDir = resolve(home);
|
|
18
|
+
const transcriptPaths = Object.values(config.providers ?? {})
|
|
19
|
+
.map((p) => p?.transcripts)
|
|
20
|
+
.filter(Boolean)
|
|
21
|
+
.map((p) => resolve(p));
|
|
22
|
+
|
|
23
|
+
const isSafeTarget = (target) => {
|
|
24
|
+
if (!target || target === sep || target === "/" || target === homeDir) return false;
|
|
25
|
+
return !transcriptPaths.some((t) => isSameOrInside(t, target));
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
if (isSameOrInside(cfgPath, defaultDir) && isSameOrInside(dataDir, defaultDir)) {
|
|
29
|
+
return exists(defaultDir) && isSafeTarget(defaultDir) ? [defaultDir] : [];
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
const candidates = [dataDir, cfgPath];
|
|
33
|
+
if (exists(defaultDir)) candidates.push(defaultDir);
|
|
34
|
+
|
|
35
|
+
const targets = [];
|
|
36
|
+
for (const candidate of candidates) {
|
|
37
|
+
if (!exists(candidate) || !isSafeTarget(candidate)) continue;
|
|
38
|
+
if (targets.some((existing) => existing === candidate || isSameOrInside(candidate, existing))) continue;
|
|
39
|
+
targets.push(candidate);
|
|
40
|
+
}
|
|
41
|
+
return targets;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
async function promptConfirm(question, input, out) {
|
|
45
|
+
const rl = createInterface({ input, output: out });
|
|
46
|
+
try {
|
|
47
|
+
const answer = await rl.question(question);
|
|
48
|
+
return /^y(?:es)?$/i.test(answer.trim());
|
|
49
|
+
} finally {
|
|
50
|
+
rl.close();
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
export async function uninstallCommand({ config, options = {}, out, err = process.stderr, input = process.stdin, deps = {} }) {
|
|
55
|
+
const dryRun = Boolean(options["dry-run"]);
|
|
56
|
+
const yes = Boolean(options.yes);
|
|
57
|
+
let purge = Boolean(options.purge);
|
|
58
|
+
const env = deps.env ?? process.env;
|
|
59
|
+
const home = deps.home ?? homedir();
|
|
60
|
+
const isTTY = deps.isTTY ?? Boolean(input.isTTY && out.isTTY);
|
|
61
|
+
const exists = deps.exists ?? existsSync;
|
|
62
|
+
const remove = deps.rm ?? rmSync;
|
|
63
|
+
|
|
64
|
+
const install = (deps.detectInstallMode ?? detectInstallMode)();
|
|
65
|
+
const { servers, staleState } = (deps.findRunningServers ?? findRunningServers)(config);
|
|
66
|
+
const dataTargets = collectDataTargets(config, { env, home, exists });
|
|
67
|
+
|
|
68
|
+
let packageManager = null;
|
|
69
|
+
if (install.mode === "global") {
|
|
70
|
+
packageManager = install.packageManager || "npm";
|
|
71
|
+
} else if ((deps.hasGlobalPackage ?? hasGlobalPackage)("npm", "llmtop")) {
|
|
72
|
+
packageManager = "npm";
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
out.write("llmtop uninstall plan:\n");
|
|
76
|
+
if (servers.length > 0) {
|
|
77
|
+
const summary = servers.map((s) => `pid ${s.pid}${s.port ? ` (port ${s.port})` : ""}`).join(", ");
|
|
78
|
+
out.write(` - stop running server(s): ${summary}\n`);
|
|
79
|
+
} else {
|
|
80
|
+
out.write(" - stop running server(s): none\n");
|
|
81
|
+
}
|
|
82
|
+
if (packageManager) {
|
|
83
|
+
const [cmd, args] = packageManagerCommand(packageManager, "uninstall", "llmtop");
|
|
84
|
+
out.write(` - remove global package: ${formatCommand(cmd, args)}\n`);
|
|
85
|
+
} else if (install.mode === "local") {
|
|
86
|
+
out.write(` - remove global package: none (local checkout at ${install.root} will not be deleted)\n`);
|
|
87
|
+
} else {
|
|
88
|
+
out.write(" - remove global package: none\n");
|
|
89
|
+
}
|
|
90
|
+
if (dataTargets.length === 0) {
|
|
91
|
+
out.write(" - local config and data: none\n");
|
|
92
|
+
} else if (purge) {
|
|
93
|
+
out.write(` - local config and data: remove ${dataTargets.join(", ")}\n`);
|
|
94
|
+
} else {
|
|
95
|
+
out.write(` - local config and data: keep ${dataTargets.join(", ")} (use --purge to remove)\n`);
|
|
96
|
+
}
|
|
97
|
+
out.write(" - provider transcripts (~/.claude, ~/.codex, ~/.gemini/antigravity-cli) will not be touched.\n");
|
|
98
|
+
|
|
99
|
+
if (dryRun) {
|
|
100
|
+
out.write("dry run: no changes made\n");
|
|
101
|
+
return 0;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
if (!yes) {
|
|
105
|
+
if (!isTTY) {
|
|
106
|
+
err.write("error: uninstall requires confirmation; pass --yes in non-interactive shells\n");
|
|
107
|
+
return 1;
|
|
108
|
+
}
|
|
109
|
+
const confirm = deps.confirm ?? ((question) => promptConfirm(question, input, out));
|
|
110
|
+
if (!(await confirm("Proceed with uninstall? [y/N] "))) {
|
|
111
|
+
out.write("aborted\n");
|
|
112
|
+
return 0;
|
|
113
|
+
}
|
|
114
|
+
if (!purge && dataTargets.length > 0) {
|
|
115
|
+
if (await confirm(`Also remove local config and archived data (${dataTargets.join(", ")})? [y/N] `)) {
|
|
116
|
+
purge = true;
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
if (servers.length > 0 || staleState) {
|
|
122
|
+
const { stopped, failed } = await (deps.stopRunningServers ?? stopRunningServers)(config);
|
|
123
|
+
if (failed.length > 0) {
|
|
124
|
+
for (const f of failed) err.write(`error: could not stop llmtop serve (pid ${f.pid}): ${f.error}\n`);
|
|
125
|
+
return 1;
|
|
126
|
+
}
|
|
127
|
+
for (const s of stopped) {
|
|
128
|
+
out.write(`stopped llmtop serve (pid ${s.pid}${s.port ? `, port ${s.port}` : ""})\n`);
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
if (packageManager) {
|
|
133
|
+
const res = (deps.runPackageManager ?? runPackageManager)(packageManager, "uninstall", "llmtop");
|
|
134
|
+
if (!res.ok) {
|
|
135
|
+
err.write(`error: uninstall failed (${res.command}): ${res.error || res.stderr.trim() || `exit code ${res.code}`}\n`);
|
|
136
|
+
if (res.permissionDenied) {
|
|
137
|
+
err.write(`hint: try running \`sudo ${res.command}\`\n`);
|
|
138
|
+
}
|
|
139
|
+
if (purge && dataTargets.length > 0) {
|
|
140
|
+
err.write("skipped deleting local config and data because package removal failed\n");
|
|
141
|
+
}
|
|
142
|
+
return 1;
|
|
143
|
+
}
|
|
144
|
+
out.write(`removed global package (${res.command})\n`);
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
if (install.mode === "local") {
|
|
148
|
+
out.write(`kept local checkout at ${install.root}; remove it manually if no longer needed.\n`);
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
if (purge && dataTargets.length > 0) {
|
|
152
|
+
for (const target of dataTargets) {
|
|
153
|
+
remove(target, { recursive: true, force: true });
|
|
154
|
+
}
|
|
155
|
+
const defaultDir = resolve(defaultConfigDir(env, home));
|
|
156
|
+
if (exists(defaultDir) && readdirSync(defaultDir).length === 0) {
|
|
157
|
+
try {
|
|
158
|
+
rmdirSync(defaultDir);
|
|
159
|
+
} catch {
|
|
160
|
+
// Ignore if not removable.
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
for (const target of dataTargets) {
|
|
164
|
+
const parent = dirname(target);
|
|
165
|
+
if (parent === defaultDir && exists(parent) && readdirSync(parent).length === 0) {
|
|
166
|
+
try {
|
|
167
|
+
rmdirSync(parent);
|
|
168
|
+
} catch {
|
|
169
|
+
// Ignore if not removable.
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
out.write(`removed local data: ${dataTargets.join(", ")}\n`);
|
|
174
|
+
} else if (dataTargets.length > 0) {
|
|
175
|
+
out.write(`kept local data at: ${dataTargets.join(", ")}\n`);
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
return 0;
|
|
179
|
+
}
|
package/src/update.mjs
ADDED
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
import { readFileSync } from "node:fs";
|
|
2
|
+
import { join } from "node:path";
|
|
3
|
+
import { ROOT } from "./config.mjs";
|
|
4
|
+
import { detectInstallMode, runPackageManager } from "./install.mjs";
|
|
5
|
+
import { findRunningServers } from "./process.mjs";
|
|
6
|
+
|
|
7
|
+
const VERSION = JSON.parse(readFileSync(join(ROOT, "package.json"), "utf8")).version;
|
|
8
|
+
|
|
9
|
+
function parseSemver(raw) {
|
|
10
|
+
if (typeof raw !== "string") throw new Error(`invalid version: ${raw}`);
|
|
11
|
+
const cleaned = raw.trim().replace(/^v/, "").split("+")[0];
|
|
12
|
+
const match = cleaned.match(/^(\d+)\.(\d+)\.(\d+)(?:-([0-9A-Za-z.-]+))?$/);
|
|
13
|
+
if (!match) throw new Error(`invalid semver: ${raw}`);
|
|
14
|
+
return {
|
|
15
|
+
core: [Number(match[1]), Number(match[2]), Number(match[3])],
|
|
16
|
+
pre: match[4] ? match[4].split(".") : [],
|
|
17
|
+
};
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
export function compareSemver(a, b) {
|
|
21
|
+
const pa = parseSemver(a);
|
|
22
|
+
const pb = parseSemver(b);
|
|
23
|
+
for (let i = 0; i < 3; i++) {
|
|
24
|
+
if (pa.core[i] !== pb.core[i]) return pa.core[i] < pb.core[i] ? -1 : 1;
|
|
25
|
+
}
|
|
26
|
+
if (!pa.pre.length && !pb.pre.length) return 0;
|
|
27
|
+
if (!pa.pre.length) return 1;
|
|
28
|
+
if (!pb.pre.length) return -1;
|
|
29
|
+
const len = Math.max(pa.pre.length, pb.pre.length);
|
|
30
|
+
for (let i = 0; i < len; i++) {
|
|
31
|
+
if (pa.pre[i] === undefined) return -1;
|
|
32
|
+
if (pb.pre[i] === undefined) return 1;
|
|
33
|
+
const na = /^\d+$/.test(pa.pre[i]);
|
|
34
|
+
const nb = /^\d+$/.test(pb.pre[i]);
|
|
35
|
+
if (na && nb) {
|
|
36
|
+
const va = Number(pa.pre[i]);
|
|
37
|
+
const vb = Number(pb.pre[i]);
|
|
38
|
+
if (va !== vb) return va < vb ? -1 : 1;
|
|
39
|
+
} else if (na !== nb) {
|
|
40
|
+
return na ? -1 : 1;
|
|
41
|
+
} else if (pa.pre[i] !== pb.pre[i]) {
|
|
42
|
+
return pa.pre[i] < pb.pre[i] ? -1 : 1;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
return 0;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
export function registryUrl(env = process.env) {
|
|
49
|
+
return (env.LLMTOP_REGISTRY || env.npm_config_registry || "https://registry.npmjs.org").replace(/\/+$/, "");
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
export async function fetchLatestVersion({
|
|
53
|
+
pkgName = "llmtop",
|
|
54
|
+
registry = registryUrl(),
|
|
55
|
+
fetchImpl = globalThis.fetch,
|
|
56
|
+
timeoutMs = 10_000,
|
|
57
|
+
} = {}) {
|
|
58
|
+
const url = `${registry}/${encodeURIComponent(pkgName)}/latest`;
|
|
59
|
+
let response;
|
|
60
|
+
try {
|
|
61
|
+
response = await fetchImpl(url, {
|
|
62
|
+
headers: { accept: "application/json" },
|
|
63
|
+
signal: AbortSignal.timeout(timeoutMs),
|
|
64
|
+
});
|
|
65
|
+
} catch (err) {
|
|
66
|
+
throw new Error(`failed to reach npm registry at ${registry}: ${err?.message ?? String(err)}`);
|
|
67
|
+
}
|
|
68
|
+
if (!response.ok) {
|
|
69
|
+
throw new Error(`npm registry returned HTTP ${response.status} for ${url}`);
|
|
70
|
+
}
|
|
71
|
+
let data;
|
|
72
|
+
try {
|
|
73
|
+
data = await response.json();
|
|
74
|
+
} catch {
|
|
75
|
+
throw new Error(`invalid JSON response from npm registry at ${url}`);
|
|
76
|
+
}
|
|
77
|
+
if (typeof data?.version !== "string" || !data.version.trim()) {
|
|
78
|
+
throw new Error(`npm registry response at ${url} did not contain a version`);
|
|
79
|
+
}
|
|
80
|
+
return data.version.trim();
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
export async function updateCommand({ config, options = {}, out, err = process.stderr, deps = {} }) {
|
|
84
|
+
const current = deps.currentVersion ?? VERSION;
|
|
85
|
+
const env = deps.env ?? process.env;
|
|
86
|
+
const install = (deps.detectInstallMode ?? detectInstallMode)();
|
|
87
|
+
const latest = await (deps.fetchLatestVersion ?? fetchLatestVersion)({ registry: registryUrl(env) });
|
|
88
|
+
const updateAvailable = compareSemver(current, latest) < 0;
|
|
89
|
+
|
|
90
|
+
if (options.check) {
|
|
91
|
+
if (options.json) {
|
|
92
|
+
out.write(`${JSON.stringify({
|
|
93
|
+
current,
|
|
94
|
+
latest,
|
|
95
|
+
updateAvailable,
|
|
96
|
+
installMode: install.mode,
|
|
97
|
+
packageManager: install.packageManager,
|
|
98
|
+
}, null, 1)}\n`);
|
|
99
|
+
} else if (updateAvailable) {
|
|
100
|
+
out.write(`update available: llmtop ${current} -> ${latest}\n`);
|
|
101
|
+
} else {
|
|
102
|
+
out.write(`llmtop ${current} is up to date (latest: ${latest})\n`);
|
|
103
|
+
}
|
|
104
|
+
return 0;
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
if (!updateAvailable && !options.force) {
|
|
108
|
+
out.write(`llmtop ${current} is already up to date (latest: ${latest})\n`);
|
|
109
|
+
return 0;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
if (!options.force) {
|
|
113
|
+
if (install.mode === "local") {
|
|
114
|
+
err.write(`llmtop is running from a local git checkout (${install.root}); run \`git pull && npm run build\`, or pass --force to install globally\n`);
|
|
115
|
+
return 1;
|
|
116
|
+
}
|
|
117
|
+
if (install.mode === "npx") {
|
|
118
|
+
err.write("llmtop is running via npx; run `npx llmtop@latest` or install globally with `npm install -g llmtop@latest` (pass --force to install globally)\n");
|
|
119
|
+
return 1;
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
const pm = install.packageManager || "npm";
|
|
124
|
+
const res = (deps.runPackageManager ?? runPackageManager)(pm, "install", `llmtop@${latest}`);
|
|
125
|
+
if (!res.ok) {
|
|
126
|
+
err.write(`error: update failed (${res.command}): ${res.error || res.stderr.trim() || `exit code ${res.code}`}\n`);
|
|
127
|
+
if (res.permissionDenied) {
|
|
128
|
+
err.write(`hint: try running \`sudo ${res.command}\`\n`);
|
|
129
|
+
}
|
|
130
|
+
return 1;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
out.write(`updated llmtop ${current} -> ${latest}\n`);
|
|
134
|
+
const { servers } = (deps.findRunningServers ?? findRunningServers)(config);
|
|
135
|
+
if (servers.length > 0) {
|
|
136
|
+
const details = servers.map((s) => `pid ${s.pid}${s.port ? ` on port ${s.port}` : ""}`).join(", ");
|
|
137
|
+
out.write(`note: llmtop serve is still running (${details}); run \`llmtop stop\` and \`llmtop serve\` to use ${latest}.\n`);
|
|
138
|
+
}
|
|
139
|
+
return 0;
|
|
140
|
+
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
:root{--brand-ink:#1a1a1a;--brand-paper:#f2f2f2;--brand-white:#fff;--brand-black:#000;--brand-tile-dark:#1a1a1a;--brand-tile-light:#f2f2f2;--brand-donut-1:#1a1a1a;--brand-donut-2:#3f3f3f;--brand-donut-3:#7f7f7f;--brand-donut-4:#d8d8d8;--page:var(--brand-paper);--surface:var(--brand-white);--raised:var(--brand-white);--ink:var(--brand-ink);--ink2:#3f3f3f;--muted:#7f7f7f;--hair:#e0e0e0;--base:#c8c8c8;--wash:#1a1a1a0d;--accent:#2a78d6;--accent-ink:#1c5cab;--s1:#2a78d6;--s2:#eb6834;--s3:#1baf7a;--s4:#eda100;--s5:#e87ba4;--s6:#0e9aa7;--s7:#8b5cf6;--s8:#6b8e23;--s9:#d946ef;--s10:#0284c7;--s11:#dc2626;--s12:#65a30d;--s13:#ea580c;--s14:#0d9488;--s15:#4f46e5;--s16:#ca8a04;--s0:#b9b8b0;--sub:#6d4fe8;--seq:#2a78d6;--v0:#c9c4fb;--v1:#9d93f5;--v2:#6f5ce6;--v3:#4630c0;--v4:#26177a;--k0:#d8d8d8;--k1:#888;--k2:#3f3f3f;--kw:repeating-linear-gradient(135deg, #d8d8d8 0 4px, #bebebe 4px 8px);--ck0:#3b6fd9;--ck1:#7c5bd1;--ck2:#a8864f;--good:#0ca30c;--up:#1c5cab;--neg:#d03b3b;--shadow:0 8px 28px #0000001a;--sb:#0b0b0b2e;--sb-hover:#0b0b0b57}:root[data-theme=dark]{--brand-donut-1:#fff;--brand-donut-2:#d8d8d8;--brand-donut-3:#888;--brand-donut-4:#3f3f3f;--page:#111;--surface:var(--brand-ink);--raised:#242424;--ink:var(--brand-white);--ink2:#d8d8d8;--muted:#888;--hair:#2c2c2c;--base:#3f3f3f;--wash:#ffffff12;--accent:#3987e5;--accent-ink:#86b6ef;--s1:#3987e5;--s2:#d95926;--s3:#199e70;--s4:#c98500;--s5:#d55181;--s6:#18b4c2;--s7:#a27bf8;--s8:#8ab03a;--s9:#e879f9;--s10:#38bdf8;--s11:#f87171;--s12:#a3e635;--s13:#fb923c;--s14:#2dd4bf;--s15:#818cf8;--s16:#facc15;--s0:#5a5a55;--sub:#7b66f0;--seq:#3987e5;--v0:#30286a;--v1:#4e42ae;--v2:#7c6ff0;--v3:#b2abff;--v4:#e4e1ff;--k0:#3f3f3f;--k1:#888;--k2:#d8d8d8;--kw:repeating-linear-gradient(135deg, #3f3f3f 0 4px, #555 4px 8px);--ck0:#5b8def;--ck1:#a07eea;--ck2:#c8a878;--good:#0ca30c;--up:#86b6ef;--neg:#e66767;--shadow:0 8px 28px #00000080;--sb:#ffffff29;--sb-hover:#ffffff52}*{box-sizing:border-box}html{-webkit-text-size-adjust:100%;--lightningcss-light:initial;--lightningcss-dark: ;color-scheme:light}html[data-theme=dark]{--lightningcss-light: ;--lightningcss-dark:initial;color-scheme:dark}body{background:var(--page);color:var(--ink);margin:0;font:14px/1.45 Montserrat,system-ui,-apple-system,Segoe UI,sans-serif}button,select,input{font:inherit;color:inherit}code{font:12.5px/1 Roboto Mono,ui-monospace,SF Mono,Menlo,monospace}.app{grid-template-columns:228px minmax(0,1fr);min-height:100vh;display:grid}.side{border-right:1px solid var(--hair);background:var(--surface);flex-direction:column;height:100vh;padding:22px 14px 16px;display:flex;position:sticky;top:0}.brand{align-items:center;padding:8px 10px 20px;display:flex}.brand .brand-lockup{flex:none;width:132px;height:auto;display:block}.navlabel{color:var(--muted);letter-spacing:.04em;text-transform:uppercase;margin:14px 10px 6px;font-size:11.5px;font-weight:600}.nav{flex-direction:column;gap:2px;display:flex}.nav button{text-align:left;cursor:pointer;width:100%;color:var(--ink2);background:0 0;border:0;border-radius:9px;align-items:center;gap:10px;padding:8px 10px;font-weight:500;display:flex}.nav button:hover{background:var(--wash);color:var(--ink)}.nav button[aria-current=page]{background:var(--wash);color:var(--ink);font-weight:600}.nav svg{stroke:currentColor;fill:none;stroke-width:1.7px;stroke-linecap:round;stroke-linejoin:round;flex:none;width:16px;height:16px}.nav.quiet button{padding:6px 10px;font-size:13px}.side .foot{border-top:1px solid var(--hair);color:var(--ink2);grid-template-columns:minmax(0,1fr);gap:12px;margin-top:auto;padding:12px 0 0;font-size:12.5px;display:grid}.foot .scan{justify-content:space-between;align-items:center;gap:8px;padding-left:10px;display:flex}.foot .si{min-width:0;color:var(--ink2);white-space:nowrap;text-overflow:ellipsis;font-size:12.5px;line-height:1.4;overflow:hidden}.foot .si span{text-overflow:ellipsis;display:block;overflow:hidden}.foot .scan .icon{background:0 0}.foot .scan .icon:hover:not(:disabled){background:var(--wash)}.foot .prefs{justify-content:space-between;align-items:center;gap:8px;display:flex}.foot .icon{width:30px;height:30px;color:var(--ink2);border-radius:8px}.foot .icon:hover:not(:disabled){color:var(--ink)}.sr{clip-path:inset(50%);white-space:nowrap;width:1px;height:1px;position:absolute;overflow:hidden}.mock{border:1px solid var(--base);border-radius:999px;margin-top:8px;padding:2px 8px;font-size:11.5px;font-weight:500;display:inline-block}main{min-width:0;padding:20px 36px 56px}.wrap{max-width:1320px;margin:0 auto}.seg{background:var(--wash);border-radius:10px;padding:3px;display:inline-flex}.seg button{cursor:pointer;color:var(--ink2);white-space:nowrap;background:0 0;border:0;border-radius:7px;padding:5px 11px;font-size:13px;font-weight:500}.seg button:hover{color:var(--ink)}.seg button[aria-pressed=true]{background:color-mix(in srgb, var(--accent) 16%, var(--raised));color:var(--accent-ink);box-shadow:inset 0 0 0 1px color-mix(in srgb, var(--accent) 40%, transparent)}.icon{background:var(--wash);cursor:pointer;border:0;border-radius:10px;place-items:center;width:34px;height:34px;display:grid}.icon svg{stroke:currentColor;fill:none;stroke-width:1.7px;stroke-linecap:round;stroke-linejoin:round;width:16px;height:16px}.filters{flex-wrap:wrap;align-items:center;gap:10px;margin:0 0 22px;display:flex}.field{border:1px solid var(--hair);background:var(--surface);height:34px;color:var(--ink2);border-radius:10px;align-items:center;gap:6px;padding:0 10px;font-size:13px;display:inline-flex}.field input{min-width:0;color:var(--ink);background:0 0;border:0;outline:none;font-size:13px}.clearall{color:var(--ink);cursor:pointer;gap:6px}.clearall svg{fill:none;stroke:currentColor;stroke-width:1.8px;stroke-linecap:round;width:14px;height:14px}.clearall:hover{border-color:var(--base);background:var(--wash)}.rowlink{color:inherit;font:inherit;cursor:pointer;background:0 0;border:0;padding:0}.rowlink:focus-visible,.clearall:focus-visible{outline:2px solid var(--accent);outline-offset:2px}.grid{gap:20px;display:grid}.kpis{grid-template-columns:repeat(3,minmax(0,1fr))}.two{grid-template-columns:minmax(0,2fr) minmax(0,1fr)}.half{grid-template-columns:repeat(2,minmax(0,1fr))}.stack{gap:20px;display:grid}.card{border:1px solid var(--hair);background:var(--surface);border-radius:14px;min-width:0;padding:16px 20px 20px}.card>header{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:8px 12px;min-height:28px;margin-bottom:14px;display:flex}.card>header .segs{flex-wrap:wrap;gap:8px;display:flex}.card>header .seg{padding:2px}.card>header .seg button{padding:3px 10px;line-height:18px}.card>header .field{height:28px}h2{letter-spacing:-.01em;margin:0;font-size:16px;font-weight:650}.hint{color:var(--ink2);font-size:12.5px}.link{color:var(--accent-ink);cursor:pointer;white-space:nowrap;background:0 0;border:0;padding:0;font-size:13px}.kpi{padding:16px 18px 14px}.kpi .l{color:var(--ink2);white-space:nowrap;text-overflow:ellipsis;font-size:13px;overflow:hidden}.kpi .vr{justify-content:space-between;align-items:flex-end;gap:8px;margin-top:6px;display:flex}.kpi .v{letter-spacing:-.02em;min-width:0;font-size:28px;font-weight:620;line-height:1.1}.kpi .v small{letter-spacing:0;color:var(--ink2);white-space:nowrap;font-size:14px;font-weight:500}.kpi .d{color:var(--ink2);white-space:nowrap;text-overflow:ellipsis;margin-top:10px;font-size:12.5px;overflow:hidden}.kpi .d b{color:var(--ink);font-weight:600}.kpi .d b.better{color:var(--good)}.kpi .d b.worse{color:var(--neg)}.kpi .d b.vol{color:var(--up)}.spark{flex:none;width:72px;height:24px;margin-bottom:4px;overflow:visible}.spark polyline{fill:none;stroke:var(--base);stroke-width:1.5px;vector-effect:non-scaling-stroke;stroke-linejoin:round;stroke-linecap:round}td .spark{margin:0}.spark circle{fill:var(--accent);stroke:var(--surface);stroke-width:2px}.legend{color:var(--ink2);flex-wrap:wrap;gap:4px 16px;margin:0 0 12px;padding:0;font-size:12.5px;list-style:none;display:flex}.legend i{vertical-align:-1px;border-radius:3px;width:10px;height:10px;margin-right:6px;display:inline-block}.legend b{color:var(--ink);margin-left:5px;font-weight:600}.v0{background:var(--v0)}.v1{background:var(--v1)}.v2{background:var(--v2)}.v3{background:var(--v3)}.v4{background:var(--v4)}.v5,.v6,.v7,.v8,.v9{background:var(--s0)}.split i.v0,.split i.v1{color:#0b0b0b}:root[data-theme=dark] .split i.v0,:root[data-theme=dark] .split i.v1{color:#fff}:root[data-theme=dark] .split i.v3,:root[data-theme=dark] .split i.v4{color:#0b0b0b}.lead{margin:0 0 16px;font-size:15.5px;line-height:1.5}.lead b{font-weight:650}.lead.accent{border-left:3px solid;padding:2px 0 2px 12px}.shares{grid-template-columns:max-content minmax(0,1fr);align-items:center;gap:10px 14px;display:grid}.shares>span{color:var(--ink2);font-size:12.5px}.shares .split{margin:0}.lv{align-items:center;gap:7px;display:inline-flex}.lv i{border-radius:3px;width:9px;height:9px}.price td{padding-top:12px;padding-bottom:12px}.price td[data-tip]:hover{background:var(--wash)}.price .sub.up{color:var(--ink);font-weight:600}.x1{color:var(--ink2)}.c1{background:var(--s1)}.c2{background:var(--s2)}.c3{background:var(--s3)}.c4{background:var(--s4)}.c5{background:var(--s5)}.c6{background:var(--s6)}.c7{background:var(--s7)}.c8{background:var(--s8)}.c9{background:var(--s9)}.c10{background:var(--s10)}.c11{background:var(--s11)}.c12{background:var(--s12)}.c13{background:var(--s13)}.c14{background:var(--s14)}.c15{background:var(--s15)}.c16{background:var(--s16)}.c0{background:var(--s0)}.csub{background:var(--sub)}.chart{grid-template-columns:44px minmax(0,1fr);padding-top:10px;display:grid}.axis{height:230px;position:relative}.axis span{color:var(--muted);font-variant-numeric:tabular-nums;white-space:nowrap;font-size:11.5px;position:absolute;right:8px;transform:translateY(50%)}.plot{border-bottom:1px solid var(--base);align-items:flex-end;height:230px;display:flex;position:relative}.plot .gl{background:var(--hair);height:1px;position:absolute;left:0;right:0}.col{outline:none;flex:1;justify-content:center;align-items:flex-end;min-width:0;height:100%;display:flex;position:relative}.col:hover,.col:focus-visible{background:var(--wash)}.bars{flex-direction:column;justify-content:flex-end;gap:2px;width:min(22px,64%);height:100%;display:flex}.bars i{min-height:1px;display:block}.bars i:first-child{border-radius:4px 4px 0 0}.col .x{color:var(--muted);white-space:nowrap;margin-top:8px;font-size:11.5px;position:absolute;top:100%}.col .x em{color:var(--ink2);margin-top:1px;font-style:normal;position:absolute;top:100%;left:0}.xpad{height:44px}.rank{grid-template-columns:minmax(84px,auto) minmax(0,1fr) auto;align-items:center;gap:9px 12px;display:grid}.rank .n{white-space:nowrap;text-overflow:ellipsis;max-width:170px;font-weight:550;overflow:hidden}.rank .n i{border-radius:3px;width:9px;height:9px;margin-right:7px;display:inline-block}.rank .b{background:var(--s1);border-radius:0 4px 4px 0;min-width:2px;height:8px;display:block}.rank .t{background:var(--wash);border-radius:4px;height:8px}.rank .val{text-align:right;font-variant-numeric:tabular-nums;white-space:nowrap}.rank .val small{color:var(--ink2);margin-left:6px;font-size:12px}.rank button.n{text-align:left;cursor:pointer;background:0 0;border:0;padding:0}.rank button.n:hover{color:var(--accent-ink)}.scroll{margin-inline:-10px;overflow-x:auto}table{border-collapse:collapse;font-variant-numeric:tabular-nums;width:100%}th,td{text-align:left;vertical-align:top;border-bottom:1px solid var(--hair);white-space:nowrap;padding:10px 14px 10px 0;font-weight:400}tr:last-child td,tr:last-child th{border-bottom:0}th:first-child,td:first-child{padding-left:10px}th:last-child,td:last-child{padding-right:10px}thead th{color:var(--ink2);vertical-align:bottom;padding-top:0;padding-bottom:8px;font-size:12.5px;font-weight:500;border-bottom:1px solid var(--base)!important}thead th button{color:inherit;font:inherit;cursor:pointer;background:0 0;border:0;padding:0}thead th[aria-sort] button{color:var(--ink);font-weight:600}.compare thead th,.wraphead thead th{white-space:normal;text-wrap:balance;min-width:76px}.flag{color:var(--ink2);vertical-align:super;cursor:default;outline-offset:2px;margin-left:2px;font-size:.55em}.num{text-align:right}.name{font-weight:550}.ph{display:none!important}.sub{color:var(--ink2);margin-top:2px;font-size:12.5px;font-weight:400;display:block}.title{white-space:normal;-webkit-line-clamp:2;-webkit-box-orient:vertical;min-width:140px;max-width:260px;display:-webkit-box;overflow:hidden}.sesstable .title,.sesstable td .sub{white-space:normal;max-width:460px}.sesstable .nw{white-space:nowrap}tbody tr.go{cursor:pointer}tbody tr.go:hover td,tbody tr.go:hover th{background:var(--wash)}.mix{gap:2px;width:84px;height:8px;margin-top:5px;display:flex}.mix i{min-width:2px;height:100%;display:block}.mix i:first-child{border-radius:4px 0 0 4px}.mix i:last-child{border-radius:0 4px 4px 0}.mix i:only-child{border-radius:4px}.heat{grid-template-columns:30px repeat(24,minmax(0,1fr));align-items:center;gap:2px;display:grid}.heat .rl{color:var(--ink2);font-size:12px}.heat .cl{color:var(--muted);text-align:left;padding-top:4px;font-size:11px}.heat .cell{aspect-ratio:1;background:color-mix(in srgb, var(--seq) var(--m), var(--wash));border-radius:3px;width:100%;max-height:26px}.heat .cell:hover{outline:2px solid var(--ink);outline-offset:-1px}.hstats{grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin:18px 0 0;display:grid}.hstats div{align-content:start;gap:2px;min-width:0;display:grid}.hstats dt{color:var(--ink2);font-size:12px}.hstats dd{white-space:nowrap;align-items:center;gap:7px;margin:0;font-size:20px;font-weight:650;display:flex}.hstats .sub{color:var(--muted);font-size:12px}.hstats .sub .line{white-space:nowrap;display:block}.hstats dd.err{color:var(--neg)}.hstats+.rank,.hstats+.legend,.hstats+.rows{margin-top:18px}.lead+.hstats,header+.hstats{margin-top:2px}.hstats .gap{height:16px;display:block}.hstats .meter{background:var(--wash);border-radius:3px;height:6px;margin:6px 0 4px;display:block;overflow:hidden}.hstats .meter i{border-radius:3px;height:100%;display:block}.hstats .dots{flex-wrap:wrap;align-items:center;gap:3px;height:7px;margin:5px 0 4px;display:flex}.hstats .dots i{background:var(--wash);width:7px;height:7px;box-shadow:inset 0 0 0 1px var(--base);border-radius:50%}.hstats .dots i.on{background:var(--seq);box-shadow:none}.hstats .hsw{background:color-mix(in srgb, var(--seq) var(--m), var(--wash));border-radius:3px;width:12px;height:12px}.cseq{background:var(--seq)}.cneg{background:var(--neg)}.split{gap:2px;height:28px;margin:4px 0 12px;display:flex}.split i{color:#fff;white-space:nowrap;border-radius:4px;align-items:center;padding:0 9px;font-size:12.5px;font-style:normal;font-weight:600;display:flex;overflow:hidden}.split i:empty{padding:0}.split i.c4,.split i.c12,.split i.c14,.split i.c16{color:#0b0b0b}.split i.c0{color:var(--ink)}.money td.wide,.money th.wide{width:55%}.rank .b.k0{background:var(--k0)}.rank .b.k1{background:var(--k1)}.rank .b.k2{background:var(--k2)}.rank .b.kw{background:var(--kw)}.rank .b.kx{box-shadow:inset 0 0 0 1px var(--base);background:0 0}.split.kinds{cursor:default;min-width:240px;height:24px;margin:0}.k0{background:var(--k0)}.k1{background:var(--k1)}.k2{background:var(--k2)}.kw{background:var(--kw)}.kx{box-shadow:inset 0 0 0 1px var(--base);background:0 0}.split i.k0,.split i.k1,.split i.kw{color:#0b0b0b}.split i.k2{color:#fff}.split i.kx{color:var(--ink2)}:root[data-theme=dark] .split i.k0,:root[data-theme=dark] .split i.k1,:root[data-theme=dark] .split i.kw{color:#fff}:root[data-theme=dark] .split i.k2{color:#0b0b0b}.ck0{background:var(--ck0)}.ck1{background:var(--ck1)}.ck2{background:var(--ck2)}.empty{text-align:center;color:var(--ink2);padding:40px 0}#tip{z-index:9;border:1px solid var(--base);background:var(--raised);min-width:150px;max-width:400px;box-shadow:var(--shadow);pointer-events:none;border-radius:10px;padding:10px 12px;font-size:12.5px;display:none;position:fixed}#tip .h{color:var(--ink2);margin-bottom:6px}#tip .h:last-child{color:var(--ink);margin-bottom:0}#tip .r{align-items:center;gap:8px;display:flex}#tip .r span{flex:1;min-width:0}#tip .r b{white-space:nowrap}#tip .r i{border-radius:2px;flex:none;width:12px;height:3px}#tip .r span{color:var(--ink2)}#tip .r b{font-variant-numeric:tabular-nums;margin-left:auto;padding-left:16px;font-weight:600}::-webkit-scrollbar{width:12px;height:12px}::-webkit-scrollbar-track{background:0 0}::-webkit-scrollbar-corner{background:0 0}::-webkit-scrollbar-thumb{background:var(--sb) padding-box;border:3px solid #0000;border-radius:999px;min-height:36px}::-webkit-scrollbar-thumb:hover{background-color:var(--sb-hover)}@supports not selector(::-webkit-scrollbar){*{scrollbar-width:thin;scrollbar-color:var(--sb) transparent}}.rank.tools .b{justify-content:flex-end;display:flex;overflow:hidden}.rank.tools .b i{background:var(--neg);height:100%}.rank .val small.err{color:var(--neg)}.rank .grp{color:var(--ink2);letter-spacing:.04em;text-transform:uppercase;grid-column:1/-1;margin-top:6px;font-size:11.5px;font-weight:600}.rank .grp:first-child{margin-top:0}.rank .b.parts{background:0 0;justify-content:flex-start;position:relative}.rank .b.parts b{flex:none;height:100%}.rank .b.parts i{position:absolute;top:0;right:0}.card>.disc.more{margin-top:10px}#tip .r i.neg{background:var(--neg)}.money td{vertical-align:middle}.sharebar{grid-template-columns:minmax(80px,1fr) 44px 64px;align-items:center;gap:10px;min-width:220px;padding-right:12px;display:grid}.sharebar .t{background:var(--wash);border-radius:4px;height:8px;overflow:hidden}.sharebar .t i{border-radius:4px;height:100%;display:block}.sharebar b{text-align:right;font-weight:600}.sharebar small{color:var(--ink2);text-align:right;font-size:12.5px}.rows{grid-template-columns:minmax(64px,auto) minmax(0,1fr);align-items:center;gap:10px 14px;display:grid}.rows.total{grid-template-columns:minmax(64px,auto) minmax(0,1fr) auto}.rows .num{color:var(--ink2);text-align:right;font-size:12.5px}.rows .n{white-space:nowrap;font-weight:550}.tree{position:relative}.tile{box-sizing:border-box;border:2px solid var(--surface);color:#fff;font:inherit;text-align:left;cursor:pointer;border-radius:10px;flex-direction:column;justify-content:flex-end;gap:2px;padding:8px 10px;transition:opacity .15s;display:flex;position:absolute;overflow:hidden}.tile b{white-space:nowrap;text-overflow:ellipsis;font-size:13px;font-weight:600;overflow:hidden}.tile span{opacity:.85;white-space:nowrap;text-overflow:ellipsis;font-size:12px;overflow:hidden}.tile.c4{color:#0b0b0b}.tile.c0{color:var(--ink)}.tile:hover{filter:brightness(1.08)}.tile:focus-visible{outline:2px solid var(--accent);outline-offset:-2px}.compare tfoot th,.compare tfoot td{color:var(--ink2);border-bottom:0;font-weight:600}.compare .quiet{color:var(--muted)}.ctl{flex:none;position:relative}.ctl svg,.search svg,.disc svg{fill:none;stroke:currentColor;stroke-width:1.6px;stroke-linecap:round;stroke-linejoin:round;flex:none;width:14px;height:14px}button.field{cursor:pointer}button.field:hover,button.field[aria-expanded=true],.field.search:focus-within{border-color:var(--base)}button.field:focus-visible,.disc:focus-visible,.clear:focus-visible,.cal-step:focus-visible{outline:2px solid var(--accent);outline-offset:1px}.field.pick{color:var(--ink);gap:8px}.pick .pv{text-overflow:ellipsis;white-space:nowrap;max-width:200px;overflow:hidden}.pick .chev{color:var(--muted);transition:transform .15s}.field.pick.on{border-color:color-mix(in srgb, var(--accent) 45%, transparent);background:color-mix(in srgb, var(--accent) 9%, var(--surface));color:var(--accent-ink)}.field.pick.on .chev{color:var(--accent-ink)}.pick[aria-expanded=true] .chev{transform:rotate(180deg)}.pick .cal{color:var(--ink2)}.pop{z-index:8;border:1px solid var(--base);background:var(--raised);min-width:100%;box-shadow:var(--shadow);border-radius:12px;outline:none;padding:6px;position:absolute;top:calc(100% + 6px);left:0}.ttl{align-items:center;gap:6px;display:flex}.ib{width:22px;height:22px;color:var(--muted);cursor:pointer;background:0 0;border:0;border-radius:6px;place-items:center;padding:0;display:grid}.ib:hover,.ib[aria-expanded=true]{background:var(--wash);color:var(--ink)}.ib svg{fill:none;stroke:currentColor;stroke-width:1.4px;stroke-linecap:round;width:15px;height:15px}.pop.note{width:min(340px,100vw - 16px);color:var(--ink2);white-space:normal;padding:12px 14px;font-size:13px;line-height:1.5}.pop.note p{margin:0 0 8px}.pop.note ul{margin:0;padding-left:16px}.pop.note li+li{margin-top:4px}.note b{color:var(--ink);font-weight:600}.list{min-width:190px;max-height:340px;overflow-y:auto}.opt{color:var(--ink2);white-space:nowrap;cursor:pointer;border-radius:8px;justify-content:space-between;align-items:center;gap:16px;padding:7px 10px;font-size:13px;display:flex}.opt.active{background:color-mix(in srgb, var(--accent) 14%, transparent);color:var(--ink)}.opt[aria-selected=true]{color:var(--accent-ink);font-weight:600}.opt .tick{color:var(--accent-ink)}.cal-pop{padding:12px 14px 10px}.cal-nav{pointer-events:none;justify-content:space-between;display:flex;position:absolute;top:12px;left:12px;right:12px}.cal-step{width:28px;height:28px;color:var(--ink2);cursor:pointer;pointer-events:auto;background:0 0;border:0;border-radius:8px;place-items:center;display:grid}.cal-step:hover:not(:disabled){background:var(--wash);color:var(--ink)}.cal-step:disabled{opacity:.3;cursor:default}.cal-months{gap:28px;display:flex}.cal-title{text-align:center;height:28px;margin-bottom:4px;font-size:13.5px;font-weight:600;line-height:28px}.cal-title:first-letter{text-transform:uppercase}.cal-row{grid-template-columns:repeat(7,36px);display:grid}.cal-wd{text-align:center;height:26px;color:var(--muted);font-size:11.5px;line-height:26px}.cal-cell{place-items:center;height:34px;margin:1px 0;display:grid}.cal-cell.in{background:color-mix(in srgb, var(--accent) 13%, transparent)}.cal-cell.lo,.cal-cell.in:first-child,.blank+.cal-cell.in{border-top-left-radius:9px;border-bottom-left-radius:9px}.cal-cell.hi,.cal-cell.in:last-child{border-top-right-radius:9px;border-bottom-right-radius:9px}.cal-cell.in:has(+.blank){border-top-right-radius:9px;border-bottom-right-radius:9px}.cal-day{width:34px;height:34px;color:var(--ink);font-variant-numeric:tabular-nums;cursor:pointer;background:0 0;border:0;border-radius:9px;font-size:13px}.cal-day:hover:not(:disabled){background:var(--wash)}.cal-day.today{box-shadow:inset 0 0 0 1px var(--base)}.cal-day.end,.cal-day.end:hover{background:var(--accent);color:#fff;box-shadow:none;font-weight:600}.cal-day:disabled{color:var(--muted);opacity:.45;cursor:default}.cal-day:focus-visible{outline:2px solid var(--accent);outline-offset:1px}.field.search{gap:7px}.search .mag{color:var(--muted)}.search input{width:200px}.clear{width:22px;height:22px;color:var(--muted);cursor:pointer;background:0 0;border:0;border-radius:6px;place-items:center;margin-right:-5px;display:grid}.clear:hover{background:var(--wash);color:var(--ink)}.disc{color:var(--ink2);cursor:pointer;background:0 0;border:0;border-radius:7px;align-items:center;gap:6px;margin-left:-6px;padding:4px 8px 4px 6px;font-size:12.5px;display:inline-flex}.disc:hover{background:var(--wash);color:var(--ink)}.disc svg{transition:transform .15s}.disc[aria-expanded=true] svg{transform:rotate(90deg)}.disclosure .scroll{margin-top:10px}@media (prefers-reduced-motion:reduce){.pick .chev,.disc svg{transition:none}}@media (width<=1400px){.o3{display:none}.filters{gap:8px}.pick .pv{max-width:112px}.range .pv{max-width:none}.filters .seg button{padding:5px 7px}}@media (width<=1500px){.wraphead .o3{display:none}}@media (width<=1060px){.two,.half{grid-template-columns:minmax(0,1fr)}.o2{display:none}}@media (width<=880px){.app{display:block}.side{border-right:0;border-bottom:1px solid var(--hair);scrollbar-width:none;flex-direction:row;align-items:center;gap:4px 6px;height:auto;padding:10px 16px;position:static;overflow-x:auto}.side::-webkit-scrollbar{display:none}.nav{flex:none}.brand{flex:none;padding:6px 10px 6px 2px}.brand .brand-lockup{width:120px}.navlabel,.foot .si{display:none}.foot .scan{padding:0}.foot .scan .icon{background:var(--wash)}.side .foot{background:var(--surface);border-top:0;align-self:stretch;align-items:center;gap:6px;margin:0 -16px 0 auto;padding:0 16px 0 10px;display:flex;position:sticky;right:-16px}.nav{flex-direction:row}.nav button{white-space:nowrap}.nav svg{display:none}.nav.quiet button{padding:8px 10px;font-size:14px}main{padding:20px 20px 48px}.title{max-width:200px}.filters{gap:8px}.filters .seg button{padding:5px 6px;font-size:12.5px}.field{padding:0 8px}}@media (width<=600px){main{padding:16px 16px 40px}.kpis{grid-template-columns:repeat(2,minmax(0,1fr))}.grid,.stack{gap:14px}.kpi .spark{display:none}.kpi .d{white-space:normal}.kpi .v{font-size:24px}.card{padding:16px}.o1{display:none}.title{max-width:160px}.search input{width:150px}.ph{white-space:normal;max-width:170px;display:block!important}thead th{white-space:normal}.mix.wide{width:84px!important}th,td{padding-right:10px}.axis,.plot{height:190px}.chart{grid-template-columns:38px minmax(0,1fr)}.heat{grid-template-columns:32px repeat(24,minmax(0,1fr));gap:1px}.hstats{grid-template-columns:repeat(2,minmax(0,1fr))}.rank .n{max-width:120px}.price th,.price td{padding-right:8px;font-size:13px}.price .lv{gap:5px}}.refresh:disabled{cursor:progress}.refresh.busy svg{animation:1s linear infinite spin}@keyframes spin{to{transform:rotate(360deg)}}@media (prefers-reduced-motion:reduce){.refresh.busy svg{animation-duration:3s}}.alert{color:var(--neg);margin:-6px 0 0;font-size:12.5px}.loading{text-align:center;color:var(--ink2);padding:80px 0}.boot{place-items:center;min-height:100vh;padding:24px 16px;display:grid}.boot-in{gap:14px;width:min(400px,100%);margin-top:-8vh;display:grid}.boot .brand{padding:8px 0 12px}.boot .brand .brand-lockup{width:160px}.boot-msg{margin:0;font-size:15px;font-weight:550}.boot-err{color:var(--neg);overflow-wrap:anywhere;margin:0;font-size:13px}.boot .clearall{justify-self:start}.boot-bar{background:var(--wash);border-radius:3px;height:6px;overflow:hidden}.boot-bar span{background:var(--accent);border-radius:3px;width:0;height:100%;transition:width .3s;display:block}.boot-bar.wait span{width:30%;animation:1.2s ease-in-out infinite boot-wait}@keyframes boot-wait{0%{transform:translate(-100%)}to{transform:translate(340%)}}.boot-count{color:var(--ink2);font-variant-numeric:tabular-nums;margin:0;font-size:12.5px}@media (prefers-reduced-motion:reduce){.boot-bar span{transition:none}.boot-bar.wait span{opacity:.35;width:100%;animation:none}}.plot .bands,.plot .bands i,.plot .bands svg{pointer-events:none;position:absolute;inset:0}.plot .bands svg{width:100%;height:100%;overflow:visible}.plot .bands i{opacity:.42;-webkit-mask-image:linear-gradient(#000 20%,#00000026);mask-image:linear-gradient(#000 20%,#00000026)}:root[data-theme=dark] .plot .bands i{opacity:.62}.plot .bands polyline{fill:none;stroke:var(--base);stroke-width:2px;vector-effect:non-scaling-stroke;stroke-linejoin:round;stroke-linecap:round}.plot .bands polyline.c0{stroke:var(--s0)}.plot .bands polyline.c1{stroke:var(--s1)}.plot .bands polyline.c2{stroke:var(--s2)}.plot .bands polyline.c3{stroke:var(--s3)}.plot .bands polyline.c4{stroke:var(--s4)}.plot .bands polyline.c5{stroke:var(--s5)}.plot .bands polyline.c6{stroke:var(--s6)}.plot .bands polyline.c7{stroke:var(--s7)}.plot .bands polyline.c8{stroke:var(--s8)}.plot .bands polyline.c9{stroke:var(--s9)}.plot .bands polyline.c10{stroke:var(--s10)}.plot .bands polyline.c11{stroke:var(--s11)}.plot .bands polyline.c12{stroke:var(--s12)}.plot .bands polyline.c13{stroke:var(--s13)}.plot .bands polyline.c14{stroke:var(--s14)}.plot .bands polyline.c15{stroke:var(--s15)}.plot .bands polyline.c16{stroke:var(--s16)}.plot .bands polyline.csub{stroke:var(--sub)}.plot .bands polyline.v0{stroke:var(--v0)}.plot .bands polyline.v1{stroke:var(--v1)}.plot .bands polyline.v2{stroke:var(--v2)}.plot .bands polyline.v3{stroke:var(--v3)}.plot .bands polyline.v4{stroke:var(--v4)}.plot .bands polyline.k0{stroke:var(--k0)}.plot .bands polyline.k1{stroke:var(--k1)}.plot .bands polyline.k2{stroke:var(--k2)}.plot .bands polyline.kw,.plot .bands polyline.kx{stroke:var(--base)}.plot.area .col:hover,.plot.area .col:focus-visible{background:0 0}.plot.area .col:hover:before,.plot.area .col:focus-visible:before{content:"";background:var(--ink);opacity:.55;width:1px;position:absolute;top:0;bottom:0;left:50%}.plot.area .col .dot{z-index:1;width:8px;height:8px;box-shadow:0 0 0 2px var(--surface);pointer-events:none;border-radius:50%;margin:0 0 -4px -4px;display:none;position:absolute;left:50%}.plot.area .col:hover .dot,.plot.area .col:focus-visible .dot{display:block}.spark polygon{stroke:none}.spark .g0{stop-color:var(--ink2);stop-opacity:.2}.spark .g1{stop-color:var(--ink2);stop-opacity:0}.magbar{min-width:56px;padding-bottom:6px;display:inline-block;position:relative}.magbar:after{content:"";height:3px;width:calc(var(--w) * 56px);background:var(--ink2);opacity:.55;border-radius:2px;position:absolute;bottom:0;right:0}.panels{grid-template-columns:repeat(3,minmax(0,1fr));gap:22px 32px;display:grid}.panel h3{color:var(--ink2);margin:0 0 10px;font-size:13px;font-weight:600}@media (width<=1060px){.panels{grid-template-columns:repeat(2,minmax(0,1fr))}}@media (width<=640px){.panels{grid-template-columns:minmax(0,1fr)}}.chartseg button{align-items:center;display:inline-flex}.chartseg svg{fill:none;stroke:currentColor;stroke-width:1.8px;stroke-linecap:round;stroke-linejoin:round;width:16px;height:16px}.card>header .segs{align-items:center}.gauge{margin:2px 0 6px}.gauge .track{gap:2px;height:14px;display:flex}.gauge .track i{height:100%;display:block}.gauge .track i:first-child{border-radius:4px 0 0 4px}.gauge .track i:last-child{border-radius:0 4px 4px 0}.gauge .ticks{height:18px;color:var(--muted);font-variant-numeric:tabular-nums;margin-top:6px;font-size:11.5px;position:relative}.gauge .ticks span{white-space:nowrap;position:absolute;top:0;transform:translate(-50%)}.gauge .ticks span:first-child{transform:none}.gauge .ticks span:last-child{color:var(--ink2);transform:translate(-100%)}.ctx .hstats{grid-template-columns:repeat(3,minmax(0,1fr));margin:16px 0 18px}.ctx .hstats .tipped{cursor:default;-webkit-text-decoration:underline dotted var(--base);text-decoration:underline dotted var(--base);text-underline-offset:5px;outline-offset:3px}.ctx td,.ctx th{vertical-align:middle}.ctx td.lbl{font-weight:550}.ctx td.lbl .sub{margin:0 0 0 6px;display:inline}.ctx tfoot td{border-top:1px solid var(--base);color:var(--ink2);border-bottom:0;font-weight:600}.ctx .better{color:var(--good);font-weight:600}.ctx .worse{color:var(--neg);font-weight:600}.cell-bar{width:42%}td.cell-bar .split.kinds{min-width:0;height:20px;margin:0}.bar1{background:var(--s1);border-radius:0 4px 4px 0;min-width:2px;height:8px;display:block}.est{border:1px dashed var(--base);height:22px;color:var(--ink2);font:inherit;cursor:default;background:0 0;border-radius:999px;align-items:center;padding:0 9px;font-size:12px;font-weight:500;display:inline-flex}.est:hover,.est:focus-visible{color:var(--ink);border-color:var(--ink2)}.chip{background:color-mix(in srgb, var(--accent) 16%, var(--raised));color:var(--accent-ink);vertical-align:1px;border-radius:999px;margin-left:8px;padding:1px 7px;font-size:11.5px;font-weight:600;display:inline-block}.ctx tbody tr.now td{--line:color-mix(in srgb, var(--accent) 45%, transparent);background:color-mix(in srgb, var(--accent) 7%, transparent);box-shadow:inset 0 1px 0 var(--line), inset 0 -1px 0 var(--line)}.ctx tbody tr.now td:first-child{box-shadow:inset 1px 1px 0 var(--line), inset 0 -1px 0 var(--line);border-radius:8px 0 0 8px}.ctx tbody tr.now td:last-child{box-shadow:inset -1px 1px 0 var(--line), inset 0 -1px 0 var(--line);border-radius:0 8px 8px 0}@media (width<=600px){.ctx .hstats{grid-template-columns:repeat(3,minmax(0,1fr))}.ctx .hstats dd{font-size:17px}}.kpi{container-type:inline-size}@container (width<=260px){.kpis:has(.v small) .spark{display:none}}
|
|
File without changes
|