@cartanova/qgrid-cli 2.11.0 → 2.11.1

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.
Files changed (51) hide show
  1. package/bundle/web-dist/client/assets/index-C96h3feE.js +32 -0
  2. package/bundle/web-dist/client/assets/logs-DBM6U0QD.js +1 -0
  3. package/bundle/web-dist/client/assets/monit-BBjXa7vB.js +1 -0
  4. package/bundle/web-dist/client/assets/plus-BsQdY7PS.js +1 -0
  5. package/bundle/web-dist/client/assets/refresh-cw-D9IUmT23.js +1 -0
  6. package/bundle/web-dist/client/assets/request-model-Bpp_rkK8.js +1 -0
  7. package/bundle/web-dist/client/assets/routes-Crz_PQzi.js +5 -0
  8. package/bundle/web-dist/client/assets/{services.generated-CefiDXEv.js → services.generated-B5lc3aIC.js} +1 -1
  9. package/bundle/web-dist/client/assets/settings-Cdwm3OBB.js +1 -0
  10. package/bundle/web-dist/client/assets/show-DBUhALT1.js +2 -0
  11. package/bundle/web-dist/client/assets/tokens-CVQAVJTo.js +1 -0
  12. package/bundle/web-dist/client/assets/use-oauth-login-flow-BfxYI4Oh.js +1 -0
  13. package/bundle/web-dist/client/assets/use-update-token-mutation-qKBC2sn7.js +1 -0
  14. package/bundle/web-dist/client/assets/vendor-react-DH4kUfK2.js +9 -0
  15. package/bundle/web-dist/client/assets/vendor-tanstack-DRPs09ai.js +1 -0
  16. package/bundle/web-dist/client/index.html +4 -4
  17. package/bundle/web-dist/server/assets/{lazyRouteComponent-D8iTIHyn.js → lazyRouteComponent-AKiHfZWp.js} +2 -2
  18. package/bundle/web-dist/server/assets/logs-B7QmGJq3.js +513 -0
  19. package/bundle/web-dist/server/assets/{monit-B2hqorPe.js → monit-DFt7x3bh.js} +117 -375
  20. package/bundle/web-dist/server/assets/plus-DaYQRpBt.js +19 -0
  21. package/bundle/web-dist/server/assets/{react-dom-BIYQzBqG.js → react-dom-Cv23mm1K.js} +1 -1
  22. package/bundle/web-dist/server/assets/refresh-cw-BpXNsAy-.js +23 -0
  23. package/bundle/web-dist/server/assets/{request-model-I6OdODSH.js → request-model-eHE6YbaF.js} +6 -15
  24. package/bundle/web-dist/server/assets/{routes-B95YlUv2.js → routes-_Y-PJfgO.js} +203 -679
  25. package/bundle/web-dist/server/assets/{services.generated-DQATJ6qf.js → services.generated-CMJ8AHbO.js} +3796 -4012
  26. package/bundle/web-dist/server/assets/settings-JwJKxn2e.js +461 -0
  27. package/bundle/web-dist/server/assets/{show-Bxaj3rhH.js → show-BEv6z1v_.js} +368 -1270
  28. package/bundle/web-dist/server/assets/tokens-CNT4mI-f.js +560 -0
  29. package/bundle/web-dist/server/assets/{use-oauth-login-flow-CKDHgc3U.js → use-oauth-login-flow-jkAkT3X6.js} +16 -50
  30. package/bundle/web-dist/server/assets/{use-update-token-mutation-BEbgOzaa.js → use-update-token-mutation-Sm6kh02m.js} +1 -1
  31. package/bundle/web-dist/server/entry-server.generated.js +1130 -2626
  32. package/package.json +1 -1
  33. package/bundle/web-dist/client/assets/index-BA7uQ-6c.js +0 -31
  34. package/bundle/web-dist/client/assets/logs-C47OJGEI.js +0 -1
  35. package/bundle/web-dist/client/assets/monit-BS9no0dU.js +0 -4
  36. package/bundle/web-dist/client/assets/plus-sdACTfH0.js +0 -1
  37. package/bundle/web-dist/client/assets/refresh-cw-CY8o_1cT.js +0 -1
  38. package/bundle/web-dist/client/assets/request-model-BRtFuZvj.js +0 -1
  39. package/bundle/web-dist/client/assets/routes-kqgkUxE8.js +0 -5
  40. package/bundle/web-dist/client/assets/settings-DNDvFGSw.js +0 -1
  41. package/bundle/web-dist/client/assets/show-u8Np69q3.js +0 -2
  42. package/bundle/web-dist/client/assets/tokens-QvP410NW.js +0 -1
  43. package/bundle/web-dist/client/assets/use-oauth-login-flow-Bzdh28Ws.js +0 -1
  44. package/bundle/web-dist/client/assets/use-update-token-mutation-CfJKaxmR.js +0 -1
  45. package/bundle/web-dist/client/assets/vendor-react-CUFFrVN9.js +0 -244
  46. package/bundle/web-dist/client/assets/vendor-tanstack-Bf_jag9G.js +0 -1
  47. package/bundle/web-dist/server/assets/logs-B3OTd9hy.js +0 -825
  48. package/bundle/web-dist/server/assets/plus-DwG7h9kq.js +0 -28
  49. package/bundle/web-dist/server/assets/refresh-cw-mMBkwOq0.js +0 -44
  50. package/bundle/web-dist/server/assets/settings-C3gbGk0m.js +0 -830
  51. package/bundle/web-dist/server/assets/tokens-CZjH3cB7.js +0 -1038
@@ -1,9 +1,9 @@
1
- import { F as require_react, j as useQuery, k as require_jsx_dev_runtime, m as _enum, t as MonitService, tt as __toESM, w as object } from "./services.generated-DQATJ6qf.js";
2
- import { t as require_react_dom } from "./react-dom-BIYQzBqG.js";
1
+ import { $ as __toESM, M as require_jsx_runtime, N as require_react, k as useQuery, m as _enum, t as MonitService, w as object } from "./services.generated-CMJ8AHbO.js";
2
+ import { t as require_react_dom } from "./react-dom-Cv23mm1K.js";
3
3
  import { t as clsx } from "./clsx-D_N5PN_2.js";
4
4
  import { a as Route } from "../entry-server.generated.js";
5
5
  import { t as cacheHitRate } from "./cost-BC9yzyA9.js";
6
- import { t as lucideRefreshCw } from "./refresh-cw-mMBkwOq0.js";
6
+ import { t as lucideRefreshCw } from "./refresh-cw-BpXNsAy-.js";
7
7
  //#region ../../node_modules/.pnpm/@tanstack+virtual-core@3.17.4/node_modules/@tanstack/virtual-core/dist/esm/lazy-measurements.js
8
8
  var import_react = /* @__PURE__ */ __toESM(require_react(), 1);
9
9
  var import_react_dom = /* @__PURE__ */ __toESM(require_react_dom(), 1);
@@ -1183,8 +1183,7 @@ function useVirtualizer(options) {
1183
1183
  }
1184
1184
  //#endregion
1185
1185
  //#region src/components/qgrid/MonitConsole.tsx
1186
- var import_jsx_dev_runtime = require_jsx_dev_runtime();
1187
- var _jsxFileName$1 = "/home/runner/work/qgrid/qgrid/packages/web/src/components/qgrid/MonitConsole.tsx";
1186
+ var import_jsx_runtime = require_jsx_runtime();
1188
1187
  var POLL_INTERVAL_MS = 1e3;
1189
1188
  var STALE_AFTER_MS = 5e3;
1190
1189
  var MIRROR_CAP = 4e3;
@@ -1235,13 +1234,13 @@ function Sparkline({ values }) {
1235
1234
  const y = height - 1 - v / max * (height - 2);
1236
1235
  return `${x.toFixed(1)},${y.toFixed(1)}`;
1237
1236
  }).join(" ");
1238
- return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("svg", {
1237
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
1239
1238
  width,
1240
1239
  height,
1241
1240
  viewBox: `0 0 ${width} ${height}`,
1242
1241
  className: "shrink-0",
1243
1242
  "aria-hidden": "true",
1244
- children: /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("polyline", {
1243
+ children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("polyline", {
1245
1244
  points,
1246
1245
  fill: "none",
1247
1246
  stroke: "currentColor",
@@ -1249,57 +1248,29 @@ function Sparkline({ values }) {
1249
1248
  strokeLinejoin: "round",
1250
1249
  strokeLinecap: "round",
1251
1250
  className: "text-sand-300"
1252
- }, void 0, false, {
1253
- fileName: _jsxFileName$1,
1254
- lineNumber: 100,
1255
- columnNumber: 7
1256
- }, this)
1257
- }, void 0, false, {
1258
- fileName: _jsxFileName$1,
1259
- lineNumber: 93,
1260
- columnNumber: 5
1261
- }, this);
1251
+ })
1252
+ });
1262
1253
  }
1263
1254
  function QuotaGauge({ usedPercent, threshold, blocked }) {
1264
1255
  if (usedPercent === null) return null;
1265
1256
  const clamped = Math.max(0, Math.min(usedPercent, 100));
1266
1257
  const over = blocked || threshold !== null && usedPercent >= threshold;
1267
- return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", {
1258
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", {
1268
1259
  className: "inline-flex items-center gap-1",
1269
- children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", {
1260
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", {
1270
1261
  className: "relative inline-block h-[4px] w-9 overflow-hidden rounded-full bg-sand-100",
1271
- children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", {
1262
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1272
1263
  className: clsx("absolute inset-y-0 left-0 rounded-full", over ? "bg-caution-500" : "bg-sand-400"),
1273
1264
  style: { width: `${clamped}%` }
1274
- }, void 0, false, {
1275
- fileName: _jsxFileName$1,
1276
- lineNumber: 131,
1277
- columnNumber: 9
1278
- }, this), threshold !== null && /* @__PURE__ */ (void 0)("span", {
1265
+ }), threshold !== null && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1279
1266
  className: "absolute inset-y-0 w-px bg-sand-500",
1280
1267
  style: { left: `${Math.min(threshold, 100)}%` }
1281
- }, void 0, false, {
1282
- fileName: _jsxFileName$1,
1283
- lineNumber: 139,
1284
- columnNumber: 11
1285
- }, this)]
1286
- }, void 0, true, {
1287
- fileName: _jsxFileName$1,
1288
- lineNumber: 130,
1289
- columnNumber: 7
1290
- }, this), /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", {
1268
+ })]
1269
+ }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", {
1291
1270
  className: clsx("font-mono text-[10px] tabular-nums", over ? "font-semibold text-caution-500" : "text-sand-500"),
1292
1271
  children: [Math.round(usedPercent), "%"]
1293
- }, void 0, true, {
1294
- fileName: _jsxFileName$1,
1295
- lineNumber: 145,
1296
- columnNumber: 7
1297
- }, this)]
1298
- }, void 0, true, {
1299
- fileName: _jsxFileName$1,
1300
- lineNumber: 129,
1301
- columnNumber: 5
1302
- }, this);
1272
+ })]
1273
+ });
1303
1274
  }
1304
1275
  function MonitConsole({ search, onSearchChange }) {
1305
1276
  const [items, setItems] = (0, import_react.useState)([]);
@@ -1395,43 +1366,27 @@ function MonitConsole({ search, onSearchChange }) {
1395
1366
  const atEnd = virtualizer.isAtEnd();
1396
1367
  const hasFirstData = query.dataUpdatedAt > 0;
1397
1368
  const firstLoadFailed = !hasFirstData && query.isError;
1398
- return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("section", {
1369
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("section", {
1399
1370
  className: "panel overflow-hidden",
1400
1371
  children: [
1401
- /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("header", {
1372
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("header", {
1402
1373
  className: "panel-header flex min-h-11 flex-wrap items-center gap-x-3 gap-y-2 px-4 py-2 sm:px-5",
1403
1374
  children: [
1404
- /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("h2", {
1375
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("h2", {
1405
1376
  className: "text-[13px] font-semibold tracking-[-0.01em] text-sand-800",
1406
1377
  children: "Server logs"
1407
- }, void 0, false, {
1408
- fileName: _jsxFileName$1,
1409
- lineNumber: 294,
1410
- columnNumber: 9
1411
- }, this),
1412
- /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", {
1378
+ }),
1379
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", {
1413
1380
  className: "inline-flex items-center gap-1.5 text-[11px] font-medium text-sand-700",
1414
- children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", { className: clsx("size-1.5 rounded-full", isStale || firstLoadFailed ? "bg-danger-400" : "bg-sienna-500 motion-safe:animate-pulse") }, void 0, false, {
1415
- fileName: _jsxFileName$1,
1416
- lineNumber: 296,
1417
- columnNumber: 11
1418
- }, this), firstLoadFailed ? "Disconnected" : isStale ? "Stale" : hasFirstData ? "Live" : "…"]
1419
- }, void 0, true, {
1420
- fileName: _jsxFileName$1,
1421
- lineNumber: 295,
1422
- columnNumber: 9
1423
- }, this),
1424
- epochRef.current !== void 0 && /* @__PURE__ */ (void 0)("span", {
1381
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: clsx("size-1.5 rounded-full", isStale || firstLoadFailed ? "bg-danger-400" : "bg-sienna-500 motion-safe:animate-pulse") }), firstLoadFailed ? "Disconnected" : isStale ? "Stale" : hasFirstData ? "Live" : "…"]
1382
+ }),
1383
+ epochRef.current !== void 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", {
1425
1384
  className: "text-[11px] text-sand-500",
1426
1385
  children: ["ephemeral · resets on restart · since ", formatTime(epochRef.current)]
1427
- }, void 0, true, {
1428
- fileName: _jsxFileName$1,
1429
- lineNumber: 307,
1430
- columnNumber: 11
1431
- }, this),
1432
- /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
1386
+ }),
1387
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
1433
1388
  className: "ml-auto flex flex-wrap items-center gap-2",
1434
- children: /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
1389
+ children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
1435
1390
  className: "segmented-control inline-flex",
1436
1391
  role: "tablist",
1437
1392
  "aria-label": "Log filter",
@@ -1448,7 +1403,7 @@ function MonitConsole({ search, onSearchChange }) {
1448
1403
  value: "error",
1449
1404
  label: "Err+"
1450
1405
  }
1451
- ].map((option) => /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("button", {
1406
+ ].map((option) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("button", {
1452
1407
  type: "button",
1453
1408
  "data-active": search.level === option.value,
1454
1409
  onClick: () => onSearchChange({
@@ -1457,428 +1412,223 @@ function MonitConsole({ search, onSearchChange }) {
1457
1412
  }),
1458
1413
  className: "rounded-[6px] px-2.5 py-1 text-[11px] font-medium text-sand-500 transition-colors hover:text-sand-800 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-sienna-300 data-[active=true]:text-sand-900",
1459
1414
  children: option.label
1460
- }, option.value, false, {
1461
- fileName: _jsxFileName$1,
1462
- lineNumber: 321,
1463
- columnNumber: 15
1464
- }, this))
1465
- }, void 0, false, {
1466
- fileName: _jsxFileName$1,
1467
- lineNumber: 313,
1468
- columnNumber: 11
1469
- }, this)
1470
- }, void 0, false, {
1471
- fileName: _jsxFileName$1,
1472
- lineNumber: 312,
1473
- columnNumber: 9
1474
- }, this)
1415
+ }, option.value))
1416
+ })
1417
+ })
1475
1418
  ]
1476
- }, void 0, true, {
1477
- fileName: _jsxFileName$1,
1478
- lineNumber: 293,
1479
- columnNumber: 7
1480
- }, this),
1481
- info && /* @__PURE__ */ (void 0)("div", {
1419
+ }),
1420
+ info && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
1482
1421
  className: "flex flex-wrap items-center gap-x-5 gap-y-1 border-b border-sand-100 bg-sand-50/60 px-4 py-2 text-[11px] text-sand-600 sm:px-5",
1483
1422
  children: [
1484
- /* @__PURE__ */ (void 0)("span", { children: ["server ", /* @__PURE__ */ (void 0)("span", {
1423
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: ["server ", /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1485
1424
  className: "font-mono text-sand-800",
1486
1425
  children: info.serverUrl
1487
- }, void 0, false, {
1488
- fileName: _jsxFileName$1,
1489
- lineNumber: 338,
1490
- columnNumber: 20
1491
- }, this)] }, void 0, true, {
1492
- fileName: _jsxFileName$1,
1493
- lineNumber: 337,
1494
- columnNumber: 11
1495
- }, this),
1496
- /* @__PURE__ */ (void 0)("span", { children: [
1426
+ })] }),
1427
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [
1497
1428
  "db",
1498
1429
  " ",
1499
- /* @__PURE__ */ (void 0)("span", {
1430
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", {
1500
1431
  className: "font-mono text-sand-800",
1501
1432
  children: [
1502
1433
  info.dbHost,
1503
1434
  "/",
1504
1435
  info.dbName
1505
1436
  ]
1506
- }, void 0, true, {
1507
- fileName: _jsxFileName$1,
1508
- lineNumber: 342,
1509
- columnNumber: 13
1510
- }, this)
1511
- ] }, void 0, true, {
1512
- fileName: _jsxFileName$1,
1513
- lineNumber: 340,
1514
- columnNumber: 11
1515
- }, this),
1516
- /* @__PURE__ */ (void 0)("span", { children: [
1437
+ })
1438
+ ] }),
1439
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [
1517
1440
  "openai transport",
1518
1441
  " ",
1519
- /* @__PURE__ */ (void 0)("span", {
1442
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1520
1443
  className: "font-mono text-sand-800",
1521
1444
  children: info.openai.transport
1522
- }, void 0, false, {
1523
- fileName: _jsxFileName$1,
1524
- lineNumber: 348,
1525
- columnNumber: 13
1526
- }, this)
1527
- ] }, void 0, true, {
1528
- fileName: _jsxFileName$1,
1529
- lineNumber: 346,
1530
- columnNumber: 11
1531
- }, this),
1532
- vitals && /* @__PURE__ */ (void 0)(import_jsx_dev_runtime.Fragment, { children: [/* @__PURE__ */ (void 0)("span", {
1445
+ })
1446
+ ] }),
1447
+ vitals && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", {
1533
1448
  className: "inline-flex items-center gap-1.5",
1534
1449
  children: [
1535
1450
  "openai in-flight",
1536
1451
  " ",
1537
- /* @__PURE__ */ (void 0)("span", {
1452
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1538
1453
  className: "font-mono text-sand-800",
1539
1454
  children: vitals.openaiInFlight
1540
- }, void 0, false, {
1541
- fileName: _jsxFileName$1,
1542
- lineNumber: 354,
1543
- columnNumber: 17
1544
- }, this),
1545
- /* @__PURE__ */ (void 0)(Sparkline, { values: inFlightSparkRef.current }, void 0, false, {
1546
- fileName: _jsxFileName$1,
1547
- lineNumber: 355,
1548
- columnNumber: 17
1549
- }, this)
1455
+ }),
1456
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Sparkline, { values: inFlightSparkRef.current })
1550
1457
  ]
1551
- }, void 0, true, {
1552
- fileName: _jsxFileName$1,
1553
- lineNumber: 352,
1554
- columnNumber: 15
1555
- }, this), vitals.anthropicTokenCount > 0 && /* @__PURE__ */ (void 0)("span", { children: [
1458
+ }), vitals.anthropicTokenCount > 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [
1556
1459
  "anthropic running",
1557
1460
  " ",
1558
- /* @__PURE__ */ (void 0)("span", {
1461
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1559
1462
  className: "font-mono text-sand-800",
1560
1463
  children: vitals.anthropicInFlight
1561
- }, void 0, false, {
1562
- fileName: _jsxFileName$1,
1563
- lineNumber: 360,
1564
- columnNumber: 19
1565
- }, this)
1566
- ] }, void 0, true, {
1567
- fileName: _jsxFileName$1,
1568
- lineNumber: 358,
1569
- columnNumber: 17
1570
- }, this)] }, void 0, true),
1571
- stats?.providers.map((p) => /* @__PURE__ */ (void 0)("span", {
1464
+ })
1465
+ ] })] }),
1466
+ stats?.providers.map((p) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", {
1572
1467
  className: "text-sand-500",
1573
1468
  children: [
1574
1469
  "1h ",
1575
1470
  p.provider,
1576
1471
  " ",
1577
- /* @__PURE__ */ (void 0)("span", {
1472
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1578
1473
  className: "font-mono text-sand-700",
1579
1474
  children: p.requests
1580
- }, void 0, false, {
1581
- fileName: _jsxFileName$1,
1582
- lineNumber: 368,
1583
- columnNumber: 31
1584
- }, this),
1475
+ }),
1585
1476
  " req",
1586
- p.errors > 0 && /* @__PURE__ */ (void 0)(import_jsx_dev_runtime.Fragment, { children: [
1477
+ p.errors > 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
1587
1478
  " · ",
1588
- /* @__PURE__ */ (void 0)("span", {
1479
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1589
1480
  className: "font-mono font-semibold text-caution-500",
1590
1481
  children: p.errors
1591
- }, void 0, false, {
1592
- fileName: _jsxFileName$1,
1593
- lineNumber: 372,
1594
- columnNumber: 19
1595
- }, this),
1482
+ }),
1596
1483
  " err"
1597
- ] }, void 0, true),
1484
+ ] }),
1598
1485
  " · hit ",
1599
- /* @__PURE__ */ (void 0)("span", {
1486
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1600
1487
  className: "font-mono text-sand-700",
1601
1488
  children: cacheHitRate({
1602
1489
  input_tokens: p.inputTokens,
1603
1490
  cache_read_tokens: p.cacheReadTokens
1604
1491
  })
1605
- }, void 0, false, {
1606
- fileName: _jsxFileName$1,
1607
- lineNumber: 376,
1608
- columnNumber: 15
1609
- }, this)
1492
+ })
1610
1493
  ]
1611
- }, p.provider, true, {
1612
- fileName: _jsxFileName$1,
1613
- lineNumber: 367,
1614
- columnNumber: 13
1615
- }, this))
1494
+ }, p.provider))
1616
1495
  ]
1617
- }, void 0, true, {
1618
- fileName: _jsxFileName$1,
1619
- lineNumber: 336,
1620
- columnNumber: 9
1621
- }, this),
1622
- vitals && (vitals.openaiQuotaByToken.length > 0 || vitals.anthropicTokenNames.length > 0) && /* @__PURE__ */ (void 0)("div", {
1496
+ }),
1497
+ vitals && (vitals.openaiQuotaByToken.length > 0 || vitals.anthropicTokenNames.length > 0) && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
1623
1498
  className: "space-y-1.5 border-b border-sand-100 px-4 py-2.5 sm:px-5",
1624
- children: [vitals.openaiQuotaByToken.length > 0 && /* @__PURE__ */ (void 0)("div", {
1499
+ children: [vitals.openaiQuotaByToken.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
1625
1500
  className: "flex flex-wrap items-center gap-2",
1626
- children: [/* @__PURE__ */ (void 0)("span", {
1501
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1627
1502
  className: "w-[4.5rem] shrink-0 text-[10px] font-medium uppercase tracking-[0.08em] text-sand-400",
1628
1503
  children: "openai"
1629
- }, void 0, false, {
1630
- fileName: _jsxFileName$1,
1631
- lineNumber: 392,
1632
- columnNumber: 17
1633
- }, this), vitals.openaiQuotaByToken.map((quota) => {
1504
+ }), vitals.openaiQuotaByToken.map((quota) => {
1634
1505
  const quotaTitle = quota.usedPercent === null ? "quota not sampled yet" : `quota ${Math.round(quota.usedPercent)}%${quota.threshold !== null ? ` / threshold ${quota.threshold}%` : ""}${quota.resetsAt ? ` · resets ${formatTime(quota.resetsAt)}` : ""}`;
1635
- return /* @__PURE__ */ (void 0)("span", {
1506
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", {
1636
1507
  title: `${quota.name} · ${quotaTitle}`,
1637
1508
  className: "inline-flex items-center gap-1.5 rounded-md border border-sand-200 bg-white px-2 py-1",
1638
1509
  children: [
1639
- /* @__PURE__ */ (void 0)("span", {
1510
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1640
1511
  className: "font-mono text-[11px] text-sand-600",
1641
1512
  children: quota.name.split("/").pop()
1642
- }, void 0, false, {
1643
- fileName: _jsxFileName$1,
1644
- lineNumber: 409,
1645
- columnNumber: 23
1646
- }, this),
1647
- /* @__PURE__ */ (void 0)(QuotaGauge, {
1513
+ }),
1514
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(QuotaGauge, {
1648
1515
  usedPercent: quota.usedPercent,
1649
1516
  threshold: quota.threshold,
1650
1517
  blocked: quota.blocked
1651
- }, void 0, false, {
1652
- fileName: _jsxFileName$1,
1653
- lineNumber: 412,
1654
- columnNumber: 23
1655
- }, this),
1656
- quota.blocked && /* @__PURE__ */ (void 0)("span", {
1518
+ }),
1519
+ quota.blocked && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1657
1520
  className: "rounded-full bg-caution-500/10 px-1.5 py-0.5 text-[9px] font-semibold text-caution-500",
1658
1521
  children: "quota"
1659
- }, void 0, false, {
1660
- fileName: _jsxFileName$1,
1661
- lineNumber: 418,
1662
- columnNumber: 25
1663
- }, this)
1522
+ })
1664
1523
  ]
1665
- }, quota.name, true, {
1666
- fileName: _jsxFileName$1,
1667
- lineNumber: 404,
1668
- columnNumber: 21
1669
- }, this);
1524
+ }, quota.name);
1670
1525
  })]
1671
- }, void 0, true, {
1672
- fileName: _jsxFileName$1,
1673
- lineNumber: 391,
1674
- columnNumber: 15
1675
- }, this), vitals.anthropicTokenNames.length > 0 && /* @__PURE__ */ (void 0)("div", {
1526
+ }), vitals.anthropicTokenNames.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
1676
1527
  className: "flex flex-wrap items-center gap-2",
1677
- children: [/* @__PURE__ */ (void 0)("span", {
1528
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1678
1529
  className: "w-[4.5rem] shrink-0 text-[10px] font-medium uppercase tracking-[0.08em] text-sand-400",
1679
1530
  children: "anthropic"
1680
- }, void 0, false, {
1681
- fileName: _jsxFileName$1,
1682
- lineNumber: 429,
1683
- columnNumber: 17
1684
- }, this), vitals.anthropicTokenNames.map((name) => /* @__PURE__ */ (void 0)("span", {
1531
+ }), vitals.anthropicTokenNames.map((name) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1685
1532
  title: name,
1686
1533
  className: "inline-flex items-baseline rounded-md border border-sand-200 bg-white px-2 py-1 font-mono text-[11px] text-sand-600",
1687
1534
  children: name.split("/").pop()
1688
- }, name, false, {
1689
- fileName: _jsxFileName$1,
1690
- lineNumber: 433,
1691
- columnNumber: 19
1692
- }, this))]
1693
- }, void 0, true, {
1694
- fileName: _jsxFileName$1,
1695
- lineNumber: 428,
1696
- columnNumber: 15
1697
- }, this)]
1698
- }, void 0, true, {
1699
- fileName: _jsxFileName$1,
1700
- lineNumber: 389,
1701
- columnNumber: 11
1702
- }, this),
1703
- /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
1535
+ }, name))]
1536
+ })]
1537
+ }),
1538
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
1704
1539
  className: "relative",
1705
- children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
1540
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
1706
1541
  ref: parentRef,
1707
1542
  role: "log",
1708
1543
  "aria-label": "Server process logs",
1709
1544
  tabIndex: 0,
1710
1545
  className: "main-scroll h-[calc(100vh-232px)] min-h-[320px] overflow-y-auto bg-sand-900 px-4 py-3 font-mono text-[12px] leading-[1.6] focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-sienna-400",
1711
- children: firstLoadFailed ? /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
1546
+ children: firstLoadFailed ? /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
1712
1547
  className: "flex h-full flex-col items-center justify-center gap-3 text-sand-400",
1713
- children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("p", {
1548
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("p", {
1714
1549
  className: "text-[12px]",
1715
- children: ["Could not reach the qgrid server — is it running?", query.error instanceof Error && /* @__PURE__ */ (void 0)("span", {
1550
+ children: ["Could not reach the qgrid server — is it running?", query.error instanceof Error && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1716
1551
  className: "block text-center text-[11px] text-sand-500",
1717
1552
  children: query.error.message
1718
- }, void 0, false, {
1719
- fileName: _jsxFileName$1,
1720
- lineNumber: 459,
1721
- columnNumber: 19
1722
- }, this)]
1723
- }, void 0, true, {
1724
- fileName: _jsxFileName$1,
1725
- lineNumber: 456,
1726
- columnNumber: 15
1727
- }, this), /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("button", {
1553
+ })]
1554
+ }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("button", {
1728
1555
  type: "button",
1729
1556
  onClick: () => void query.refetch(),
1730
1557
  className: "inline-flex items-center gap-1.5 rounded-md border border-sand-600 px-2.5 py-1.5 text-[11px] font-medium text-sand-300 transition-colors hover:bg-sand-800 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-sienna-400",
1731
- children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(lucideRefreshCw, { className: "size-3" }, void 0, false, {
1732
- fileName: _jsxFileName$1,
1733
- lineNumber: 469,
1734
- columnNumber: 17
1735
- }, this), "Retry now"]
1736
- }, void 0, true, {
1737
- fileName: _jsxFileName$1,
1738
- lineNumber: 464,
1739
- columnNumber: 15
1740
- }, this)]
1741
- }, void 0, true, {
1742
- fileName: _jsxFileName$1,
1743
- lineNumber: 455,
1744
- columnNumber: 13
1745
- }, this) : !hasFirstData ? /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
1558
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(lucideRefreshCw, { className: "size-3" }), "Retry now"]
1559
+ })]
1560
+ }) : !hasFirstData ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
1746
1561
  className: "flex h-full items-center justify-center text-[12px] text-sand-500",
1747
1562
  children: "Connecting to server logs…"
1748
- }, void 0, false, {
1749
- fileName: _jsxFileName$1,
1750
- lineNumber: 474,
1751
- columnNumber: 13
1752
- }, this) : visible.length === 0 ? /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
1563
+ }) : visible.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
1753
1564
  className: "flex h-full items-center justify-center text-[12px] text-sand-500",
1754
1565
  children: items.length === 0 ? `No log lines yet — waiting for activity since ${epochRef.current !== void 0 ? formatTime(epochRef.current) : "startup"}.` : "No lines match the current filters."
1755
- }, void 0, false, {
1756
- fileName: _jsxFileName$1,
1757
- lineNumber: 478,
1758
- columnNumber: 13
1759
- }, this) : /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
1566
+ }) : /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
1760
1567
  className: "relative w-full",
1761
1568
  style: { height: `${virtualizer.getTotalSize()}px` },
1762
1569
  children: virtualizer.getVirtualItems().map((virtualRow) => {
1763
1570
  const item = visible[virtualRow.index];
1764
- return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
1571
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
1765
1572
  ref: virtualizer.measureElement,
1766
1573
  "data-index": virtualRow.index,
1767
1574
  className: "absolute left-0 top-0 w-full",
1768
1575
  style: { transform: `translateY(${virtualRow.start}px)` },
1769
- children: /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(LogLine, { item }, void 0, false, {
1770
- fileName: _jsxFileName$1,
1771
- lineNumber: 498,
1772
- columnNumber: 21
1773
- }, this)
1774
- }, virtualRow.key, false, {
1775
- fileName: _jsxFileName$1,
1776
- lineNumber: 491,
1777
- columnNumber: 19
1778
- }, this);
1576
+ children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(LogLine, { item })
1577
+ }, virtualRow.key);
1779
1578
  })
1780
- }, void 0, false, {
1781
- fileName: _jsxFileName$1,
1782
- lineNumber: 486,
1783
- columnNumber: 13
1784
- }, this)
1785
- }, void 0, false, {
1786
- fileName: _jsxFileName$1,
1787
- lineNumber: 447,
1788
- columnNumber: 9
1789
- }, this), hasFirstData && !firstLoadFailed && !atEnd && /* @__PURE__ */ (void 0)("button", {
1579
+ })
1580
+ }), hasFirstData && !firstLoadFailed && !atEnd && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("button", {
1790
1581
  type: "button",
1791
1582
  onClick: () => virtualizer.scrollToEnd(),
1792
1583
  className: "absolute bottom-4 right-5 inline-flex items-center gap-1.5 rounded-full border border-sand-600 bg-sand-800/90 px-3 py-1.5 text-[11px] font-medium text-sand-200 shadow-lg backdrop-blur transition-colors hover:bg-sand-700 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-sienna-400",
1793
1584
  children: "↓ Jump to live"
1794
- }, void 0, false, {
1795
- fileName: _jsxFileName$1,
1796
- lineNumber: 507,
1797
- columnNumber: 11
1798
- }, this)]
1799
- }, void 0, true, {
1800
- fileName: _jsxFileName$1,
1801
- lineNumber: 446,
1802
- columnNumber: 7
1803
- }, this)
1585
+ })]
1586
+ })
1804
1587
  ]
1805
- }, void 0, true, {
1806
- fileName: _jsxFileName$1,
1807
- lineNumber: 292,
1808
- columnNumber: 5
1809
- }, this);
1588
+ });
1810
1589
  }
1811
1590
  function LogLine({ item }) {
1812
- if (item.kind === "restart") return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
1591
+ if (item.kind === "restart") return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
1813
1592
  className: "py-1 text-center text-[11px] text-caution-400",
1814
1593
  children: [
1815
1594
  "── process restarted · ",
1816
1595
  formatTime(item.processStartedAt),
1817
1596
  " ──"
1818
1597
  ]
1819
- }, void 0, true, {
1820
- fileName: _jsxFileName$1,
1821
- lineNumber: 523,
1822
- columnNumber: 7
1823
- }, this);
1824
- if (item.kind === "dropped") return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
1598
+ });
1599
+ if (item.kind === "dropped") return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
1825
1600
  className: "py-1 text-center text-[11px] italic text-sand-500",
1826
1601
  children: [
1827
1602
  "── ",
1828
1603
  item.count,
1829
1604
  " lines dropped (buffer overflow) ──"
1830
1605
  ]
1831
- }, void 0, true, {
1832
- fileName: _jsxFileName$1,
1833
- lineNumber: 531,
1834
- columnNumber: 7
1835
- }, this);
1606
+ });
1836
1607
  const { entry } = item;
1837
- return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
1608
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
1838
1609
  className: "whitespace-pre-wrap break-words text-sand-200",
1839
1610
  children: [
1840
- /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", {
1611
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1841
1612
  className: "text-sand-500",
1842
1613
  children: formatTime(entry.timestamp)
1843
- }, void 0, false, {
1844
- fileName: _jsxFileName$1,
1845
- lineNumber: 541,
1846
- columnNumber: 7
1847
- }, this),
1614
+ }),
1848
1615
  " ",
1849
- /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", {
1616
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1850
1617
  className: clsx("font-semibold", entry.level === "fatal" || entry.level === "error" ? "text-danger-400" : entry.level === "warning" ? "text-caution-400" : "text-sand-400"),
1851
1618
  children: LEVEL_LABEL.get(entry.level) ?? entry.level.slice(0, 3).toUpperCase()
1852
- }, void 0, false, {
1853
- fileName: _jsxFileName$1,
1854
- lineNumber: 542,
1855
- columnNumber: 7
1856
- }, this),
1619
+ }),
1857
1620
  " ",
1858
- /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", {
1621
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1859
1622
  className: "text-sienna-300",
1860
1623
  children: categoryLabel(entry.category)
1861
- }, void 0, false, {
1862
- fileName: _jsxFileName$1,
1863
- lineNumber: 554,
1864
- columnNumber: 7
1865
- }, this),
1624
+ }),
1866
1625
  " ",
1867
- /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", { children: entry.text }, void 0, false, {
1868
- fileName: _jsxFileName$1,
1869
- lineNumber: 555,
1870
- columnNumber: 7
1871
- }, this)
1626
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: entry.text })
1872
1627
  ]
1873
- }, void 0, true, {
1874
- fileName: _jsxFileName$1,
1875
- lineNumber: 540,
1876
- columnNumber: 5
1877
- }, this);
1628
+ });
1878
1629
  }
1879
1630
  //#endregion
1880
1631
  //#region src/routes/monit.tsx?tsr-split=component
1881
- var _jsxFileName = "/home/runner/work/qgrid/qgrid/packages/web/src/routes/monit.tsx?tsr-split=component";
1882
1632
  object({ level: _enum([
1883
1633
  "all",
1884
1634
  "warn",
@@ -1887,24 +1637,16 @@ object({ level: _enum([
1887
1637
  function MonitPage() {
1888
1638
  const search = Route.useSearch();
1889
1639
  const navigate = Route.useNavigate();
1890
- return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
1640
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
1891
1641
  className: "max-w-[100rem] mx-auto",
1892
- children: /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(MonitConsole, {
1642
+ children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(MonitConsole, {
1893
1643
  search,
1894
1644
  onSearchChange: (next) => navigate({
1895
1645
  search: next,
1896
1646
  replace: true
1897
1647
  })
1898
- }, void 0, false, {
1899
- fileName: _jsxFileName,
1900
- lineNumber: 14,
1901
- columnNumber: 7
1902
- }, this)
1903
- }, void 0, false, {
1904
- fileName: _jsxFileName,
1905
- lineNumber: 13,
1906
- columnNumber: 10
1907
- }, this);
1648
+ })
1649
+ });
1908
1650
  }
1909
1651
  //#endregion
1910
1652
  export { MonitPage as component };