@cartanova/qgrid-cli 1.3.0 → 1.5.0

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 (24) hide show
  1. package/bundle/dist/application/qgrid/pool.js +6 -3
  2. package/bundle/dist/sonamu.config.js +4 -2
  3. package/bundle/src/application/qgrid/pool.ts +6 -2
  4. package/bundle/src/sonamu.config.ts +2 -0
  5. package/bundle/web-dist/client/assets/index-CJbMnvkl.css +1 -0
  6. package/bundle/web-dist/client/assets/index-DhqeOdaq.js +116 -0
  7. package/bundle/web-dist/client/assets/logs-BzY81a5V.js +1 -0
  8. package/bundle/web-dist/client/assets/preload-helper-ca-nBW7U.js +1 -0
  9. package/bundle/web-dist/client/assets/routes-C8VZv8Ii.js +5 -0
  10. package/bundle/web-dist/client/assets/{show-CFGLH8f_.js → show-B9Z-snx2.js} +1 -1
  11. package/bundle/web-dist/client/assets/{tokens-Bib8aQbc.js → tokens-Dk4_IBwI.js} +1 -1
  12. package/bundle/web-dist/client/index.html +3 -2
  13. package/bundle/web-dist/server/assets/lazyRouteComponent-Dyl_0WZs.js +1982 -0
  14. package/bundle/web-dist/server/assets/logs-bLRMIO1J.js +244 -0
  15. package/bundle/web-dist/server/assets/{routes-Dx59lTlD.js → routes-qwzTPLE2.js} +14 -388
  16. package/bundle/web-dist/server/assets/{show-BEFi1cKV.js → show-Btv2c6zd.js} +2 -1
  17. package/bundle/web-dist/server/assets/{tokens-Dyi6qMmP.js → tokens-BYhGItkk.js} +1 -1
  18. package/bundle/web-dist/server/entry-server.generated.js +70 -2008
  19. package/dist/cli.js +25 -4
  20. package/package.json +1 -1
  21. package/bundle/web-dist/client/assets/index-BP0XRvKL.css +0 -1
  22. package/bundle/web-dist/client/assets/index-CgXTSTgN.js +0 -116
  23. package/bundle/web-dist/client/assets/routes-DvViUcG1.js +0 -5
  24. /package/bundle/web-dist/client/assets/{services.generated-CAJQk7Wk.js → services.generated-1X7EKUWg.js} +0 -0
@@ -1,333 +1,8 @@
1
1
  import { S as require_react, b as useQueryClient, nt as __toESM, v as require_react_dom, x as require_jsx_runtime } from "./sd.generated-BeEKgSOs.js";
2
- import { n as RequestLogService, r as TokenService, t as QgridService } from "./services.generated-DjxCLdMu.js";
3
- import { i as lucideKeyRound, o as useNavigate } from "../entry-server.generated.js";
4
- //#region ~icons/lucide/activity.jsx
5
- var import_react = /* @__PURE__ */ __toESM(require_react());
6
- var import_jsx_runtime = require_jsx_runtime();
7
- var lucideActivity = (props) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
8
- viewBox: "0 0 24 24",
9
- width: "1.2em",
10
- height: "1.2em",
11
- ...props,
12
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", {
13
- fill: "none",
14
- stroke: "currentColor",
15
- strokeLinecap: "round",
16
- strokeLinejoin: "round",
17
- strokeWidth: 2,
18
- d: "M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2"
19
- })
20
- });
21
- //#endregion
22
- //#region ~icons/lucide/cpu.jsx
23
- var lucideCpu = (props) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
24
- viewBox: "0 0 24 24",
25
- width: "1.2em",
26
- height: "1.2em",
27
- ...props,
28
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("g", {
29
- fill: "none",
30
- stroke: "currentColor",
31
- strokeLinecap: "round",
32
- strokeLinejoin: "round",
33
- strokeWidth: 2,
34
- children: [
35
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { d: "M12 20v2m0-20v2m5 16v2m0-20v2M2 12h2m-2 5h2M2 7h2m16 5h2m-2 5h2M20 7h2M7 20v2M7 2v2" }),
36
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("rect", {
37
- width: 16,
38
- height: 16,
39
- x: 4,
40
- y: 4,
41
- rx: 2
42
- }),
43
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("rect", {
44
- width: 8,
45
- height: 8,
46
- x: 8,
47
- y: 8,
48
- rx: 1
49
- })
50
- ]
51
- })
52
- });
53
- //#endregion
54
- //#region src/components/qgrid/HealthCard.tsx
55
- function MetricCard({ label, icon: Icon, children }) {
56
- return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
57
- className: "rounded-lg bg-sand-50 px-5 py-4",
58
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
59
- className: "flex items-center justify-between mb-2",
60
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
61
- className: "text-[10px] uppercase tracking-wider text-sand-400 font-medium",
62
- children: label
63
- }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Icon, { className: "size-4 text-sand-400" })]
64
- }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { children })]
65
- });
66
- }
67
- function HealthCard({ data, isLoading, isError }) {
68
- if (isLoading) return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
69
- className: "grid grid-cols-1 sm:grid-cols-3 gap-4",
70
- children: Array.from({ length: 3 }).map((_, i) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
71
- className: "rounded-lg bg-sand-50 px-5 py-4 animate-pulse",
72
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "h-3 w-16 bg-sand-200 rounded mb-3" }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "h-6 w-12 bg-sand-200 rounded" })]
73
- }, `skeleton-${i}`))
74
- });
75
- const isOnline = (isError ? "offline" : data?.status ?? "unknown") === "ok";
76
- return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
77
- className: "grid grid-cols-1 sm:grid-cols-3 gap-4",
78
- children: [
79
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(MetricCard, {
80
- label: "Status",
81
- icon: lucideActivity,
82
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
83
- className: "flex items-center gap-2",
84
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: `size-2 rounded-full ${isOnline ? "bg-sage-400" : "bg-red-400"}` }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
85
- className: "text-base font-semibold text-sand-800",
86
- children: isOnline ? "Online" : "Offline"
87
- })]
88
- })
89
- }),
90
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(MetricCard, {
91
- label: "Workers",
92
- icon: lucideCpu,
93
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
94
- className: "text-base font-semibold text-sand-800",
95
- children: data?.workers ?? 0
96
- })
97
- }),
98
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(MetricCard, {
99
- label: "Active Tokens",
100
- icon: lucideKeyRound,
101
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
102
- className: "text-base font-semibold text-sand-800",
103
- children: data?.activeTokens ?? 0
104
- })
105
- })
106
- ]
107
- });
108
- }
109
- //#endregion
110
- //#region ~icons/lucide/chevron-left.jsx
111
- var lucideChevronLeft = (props) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
112
- viewBox: "0 0 24 24",
113
- width: "1.2em",
114
- height: "1.2em",
115
- ...props,
116
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", {
117
- fill: "none",
118
- stroke: "currentColor",
119
- strokeLinecap: "round",
120
- strokeLinejoin: "round",
121
- strokeWidth: 2,
122
- d: "m15 18l-6-6l6-6"
123
- })
124
- });
125
- //#endregion
126
- //#region ~icons/lucide/chevron-right.jsx
127
- var lucideChevronRight = (props) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
128
- viewBox: "0 0 24 24",
129
- width: "1.2em",
130
- height: "1.2em",
131
- ...props,
132
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", {
133
- fill: "none",
134
- stroke: "currentColor",
135
- strokeLinecap: "round",
136
- strokeLinejoin: "round",
137
- strokeWidth: 2,
138
- d: "m9 18l6-6l-6-6"
139
- })
140
- });
141
- //#endregion
142
- //#region src/components/qgrid/RequestLogTable.tsx
143
- var PAGE_SIZE$1 = 50;
144
- function formatDateTime(iso) {
145
- const d = new Date(iso);
146
- return `${String(d.getMonth() + 1).padStart(2, "0")}-${String(d.getDate()).padStart(2, "0")} ${String(d.getHours()).padStart(2, "0")}:${String(d.getMinutes()).padStart(2, "0")}`;
147
- }
148
- function formatNum(n) {
149
- return n.toLocaleString();
150
- }
151
- function calcCacheHitRate(row) {
152
- const denom = row.input_tokens + row.cache_read_tokens + row.cache_creation_tokens;
153
- if (denom === 0) return "—";
154
- return `${Math.round(row.cache_read_tokens / denom * 100)}%`;
155
- }
156
- function trimQuery(q, maxLen = 30) {
157
- return q.length > maxLen ? `${q.slice(0, maxLen)}...` : q;
158
- }
159
- function RequestLogTable() {
160
- const navigate = useNavigate();
161
- const [page, setPage] = (0, import_react.useState)(1);
162
- const [tokenFilter, setTokenFilter] = (0, import_react.useState)("");
163
- const { data: tokensData } = TokenService.useTokens("A");
164
- const tokenNames = (tokensData?.rows ?? []).map((t) => t.name).filter(Boolean);
165
- const { data, isLoading } = RequestLogService.useRequestLogs("A", {
166
- num: PAGE_SIZE$1,
167
- page,
168
- orderBy: "id-desc",
169
- ...tokenFilter ? { token_name: tokenFilter } : {}
170
- });
171
- const rows = data?.rows ?? [];
172
- const total = data?.total ?? 0;
173
- const totalPages = Math.ceil(total / PAGE_SIZE$1);
174
- return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
175
- className: "flex items-center gap-2 mb-3 flex-wrap",
176
- children: [tokenNames.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("select", {
177
- value: tokenFilter,
178
- onChange: (e) => {
179
- setTokenFilter(e.target.value);
180
- setPage(1);
181
- },
182
- className: "border border-sand-200 rounded-md px-2 py-1 text-xs text-sand-700 bg-white focus:outline-none focus:border-sienna-300",
183
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("option", {
184
- value: "",
185
- children: "All Tokens"
186
- }), tokenNames.map((name) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("option", {
187
- value: name,
188
- children: name
189
- }, name))]
190
- }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", {
191
- className: "text-[11px] text-sand-400",
192
- children: [total, " results"]
193
- })]
194
- }), isLoading ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
195
- className: "space-y-2",
196
- children: Array.from({ length: 5 }).map((_, i) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "h-8 bg-sand-100 rounded animate-pulse" }, `skel-${i}`))
197
- }) : rows.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
198
- className: "text-sand-400 text-center py-12 text-sm",
199
- children: "No requests yet."
200
- }) : /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
201
- className: "rounded-lg bg-sand-50 overflow-hidden",
202
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("table", {
203
- className: "w-full text-sm",
204
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("thead", { children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("tr", {
205
- className: "border-b border-sand-200",
206
- children: [
207
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("th", {
208
- className: "text-left px-3 py-2.5 text-[10px] uppercase tracking-wider text-sand-400 font-medium",
209
- children: "Date"
210
- }),
211
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("th", {
212
- className: "text-left px-3 py-2.5 text-[10px] uppercase tracking-wider text-sand-400 font-medium",
213
- children: "Token"
214
- }),
215
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("th", {
216
- className: "text-left px-3 py-2.5 text-[10px] uppercase tracking-wider text-sand-400 font-medium",
217
- children: "Query"
218
- }),
219
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("th", {
220
- className: "text-right px-3 py-2.5 text-[10px] uppercase tracking-wider text-sand-400 font-medium",
221
- children: "In"
222
- }),
223
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("th", {
224
- className: "text-right px-3 py-2.5 text-[10px] uppercase tracking-wider text-sand-400 font-medium",
225
- children: "Out"
226
- }),
227
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("th", {
228
- className: "text-right px-3 py-2.5 text-[10px] uppercase tracking-wider text-sand-400 font-medium",
229
- children: "C.Read"
230
- }),
231
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("th", {
232
- className: "text-right px-3 py-2.5 text-[10px] uppercase tracking-wider text-sand-400 font-medium",
233
- children: "C.Write"
234
- }),
235
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("th", {
236
- className: "text-right px-3 py-2.5 text-[10px] uppercase tracking-wider text-sand-400 font-medium",
237
- children: "Hit"
238
- }),
239
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("th", { className: "w-8 px-2 py-2.5" })
240
- ]
241
- }) }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("tbody", {
242
- className: "divide-y divide-sand-200/60",
243
- children: rows.map((row) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("tr", {
244
- className: "transition-colors duration-150 hover:bg-sand-100/60 cursor-pointer",
245
- onClick: () => navigate({
246
- to: "/requests/show",
247
- search: { id: row.id }
248
- }),
249
- children: [
250
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("td", {
251
- className: "px-3 py-2.5",
252
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
253
- className: "text-[10px] text-sand-400 tabular-nums whitespace-nowrap",
254
- children: formatDateTime(row.created_at)
255
- })
256
- }),
257
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("td", {
258
- className: "px-3 py-2.5",
259
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
260
- className: "text-xs text-sand-500",
261
- children: row.token_name
262
- })
263
- }),
264
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("td", {
265
- className: "px-3 py-2.5",
266
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
267
- className: "text-sand-800 truncate max-w-48",
268
- title: row.query,
269
- children: trimQuery(row.query)
270
- })
271
- }),
272
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("td", {
273
- className: "px-3 py-2.5 text-right tabular-nums text-sand-700",
274
- children: formatNum(row.input_tokens)
275
- }),
276
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("td", {
277
- className: "px-3 py-2.5 text-right tabular-nums text-sand-700",
278
- children: formatNum(row.output_tokens)
279
- }),
280
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("td", {
281
- className: "px-3 py-2.5 text-right tabular-nums text-sand-700",
282
- children: formatNum(row.cache_read_tokens)
283
- }),
284
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("td", {
285
- className: "px-3 py-2.5 text-right tabular-nums text-sand-700",
286
- children: formatNum(row.cache_creation_tokens)
287
- }),
288
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("td", {
289
- className: "px-3 py-2.5 text-right tabular-nums text-sand-700",
290
- children: calcCacheHitRate(row)
291
- }),
292
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("td", {
293
- className: "px-2 py-2.5",
294
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(lucideChevronRight, { className: "size-4 text-sand-400" })
295
- })
296
- ]
297
- }, row.id))
298
- })]
299
- })
300
- }), totalPages > 1 && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
301
- className: "flex items-center justify-center gap-3 mt-3",
302
- children: [
303
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("button", {
304
- type: "button",
305
- className: "p-1 rounded text-sand-400 hover:text-sand-600 disabled:opacity-30 transition-colors",
306
- disabled: page === 1,
307
- onClick: () => setPage((p) => p - 1),
308
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(lucideChevronLeft, { className: "size-4" })
309
- }),
310
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", {
311
- className: "text-[11px] text-sand-400 tabular-nums",
312
- children: [
313
- page,
314
- " / ",
315
- totalPages
316
- ]
317
- }),
318
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("button", {
319
- type: "button",
320
- className: "p-1 rounded text-sand-400 hover:text-sand-600 disabled:opacity-30 transition-colors",
321
- disabled: page === totalPages,
322
- onClick: () => setPage((p) => p + 1),
323
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(lucideChevronRight, { className: "size-4" })
324
- })
325
- ]
326
- })] })] });
327
- }
328
- //#endregion
2
+ import { r as TokenService, t as QgridService } from "./services.generated-DjxCLdMu.js";
329
3
  //#region ../../node_modules/.pnpm/@dnd-kit+utilities@3.2.2_react@19.2.4/node_modules/@dnd-kit/utilities/dist/utilities.esm.js
330
4
  var import_react_dom = /* @__PURE__ */ __toESM(require_react_dom());
5
+ var import_react = /* @__PURE__ */ __toESM(require_react());
331
6
  function useCombinedRefs() {
332
7
  for (var _len = arguments.length, refs = new Array(_len), _key = 0; _key < _len; _key++) refs[_key] = arguments[_key];
333
8
  return (0, import_react.useMemo)(() => (node) => {
@@ -2556,6 +2231,7 @@ function useSortable({ animateLayoutChanges = defaultAnimateLayoutChanges, attri
2556
2231
  KeyboardCode.Down, KeyboardCode.Right, KeyboardCode.Up, KeyboardCode.Left;
2557
2232
  //#endregion
2558
2233
  //#region ~icons/lucide/grip-vertical.jsx
2234
+ var import_jsx_runtime = require_jsx_runtime();
2559
2235
  var lucideGripVertical = (props) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
2560
2236
  viewBox: "0 0 24 24",
2561
2237
  width: "1.2em",
@@ -2724,9 +2400,7 @@ function SortableTokenCard({ token }) {
2724
2400
  }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TokenUsage, { token })]
2725
2401
  });
2726
2402
  }
2727
- var PAGE_SIZE = 8;
2728
2403
  function UsageCard() {
2729
- const [page, setPage] = (0, import_react.useState)(0);
2730
2404
  const { data, isLoading } = TokenService.useTokens("A", { orderBy: "ord-asc" });
2731
2405
  const queryClient = useQueryClient();
2732
2406
  const reorderMutation = TokenService.useReorderMutation();
@@ -2775,80 +2449,32 @@ function UsageCard() {
2775
2449
  children: "No tokens registered"
2776
2450
  })
2777
2451
  });
2778
- const totalPages = Math.ceil(localTokens.length / PAGE_SIZE);
2779
- const safePage = Math.min(page, totalPages - 1);
2780
- const pageTokens = localTokens.slice(safePage * PAGE_SIZE, (safePage + 1) * PAGE_SIZE);
2781
- return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DndContext, {
2452
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DndContext, {
2782
2453
  sensors,
2783
2454
  collisionDetection: closestCenter,
2784
2455
  onDragEnd: handleDragEnd,
2785
2456
  children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SortableContext, {
2786
- items: pageTokens.map((t) => String(t.id)),
2457
+ items: localTokens.map((t) => String(t.id)),
2787
2458
  strategy: rectSortingStrategy,
2788
2459
  children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
2789
2460
  className: "grid grid-cols-2 gap-3",
2790
- children: pageTokens.map((token) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SortableTokenCard, { token }, token.id))
2461
+ children: localTokens.map((token) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SortableTokenCard, { token }, token.id))
2791
2462
  })
2792
2463
  })
2793
- }), totalPages > 1 && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
2794
- className: "flex items-center justify-center gap-2 mt-3",
2795
- children: [
2796
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("button", {
2797
- type: "button",
2798
- className: "p-0.5 rounded text-sand-400 hover:text-sand-600 disabled:opacity-30 transition-colors",
2799
- disabled: safePage === 0,
2800
- onClick: () => setPage(safePage - 1),
2801
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(lucideChevronLeft, { className: "size-4" })
2802
- }),
2803
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", {
2804
- className: "text-[10px] text-sand-400 tabular-nums",
2805
- children: [
2806
- safePage + 1,
2807
- " / ",
2808
- totalPages
2809
- ]
2810
- }),
2811
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("button", {
2812
- type: "button",
2813
- className: "p-0.5 rounded text-sand-400 hover:text-sand-600 disabled:opacity-30 transition-colors",
2814
- disabled: safePage === totalPages - 1,
2815
- onClick: () => setPage(safePage + 1),
2816
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(lucideChevronRight, { className: "size-4" })
2817
- })
2818
- ]
2819
- })] });
2464
+ });
2820
2465
  }
2821
2466
  //#endregion
2822
2467
  //#region src/routes/index.tsx?tsr-split=component
2823
2468
  function Dashboard() {
2824
- const { data: healthData, isLoading: healthLoading, isError: healthError } = QgridService.useHealth();
2825
2469
  return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
2826
2470
  className: "space-y-5 max-w-300 mx-auto -translate-x-4",
2827
- children: [
2828
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("h1", {
2829
- className: "text-xl font-medium text-sand-900 tracking-tight",
2830
- children: "Dashboard"
2831
- }),
2832
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(HealthCard, {
2833
- data: healthData,
2834
- isLoading: healthLoading,
2835
- isError: healthError
2836
- }),
2837
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
2838
- className: "text-[10px] uppercase tracking-wider text-sand-500 font-medium",
2839
- children: "Usage"
2840
- }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
2841
- className: "mt-2",
2842
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(UsageCard, {})
2843
- })] }),
2844
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
2845
- className: "text-[10px] uppercase tracking-wider text-sand-500 font-medium",
2846
- children: "Request Log"
2847
- }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
2848
- className: "mt-2",
2849
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(RequestLogTable, {})
2850
- })] })
2851
- ]
2471
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("h1", {
2472
+ className: "text-xl font-medium text-sand-900 tracking-tight",
2473
+ children: "Dashboard"
2474
+ }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
2475
+ className: "pt-12",
2476
+ children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(UsageCard, {})
2477
+ })]
2852
2478
  });
2853
2479
  }
2854
2480
  //#endregion
@@ -1,6 +1,7 @@
1
1
  import { $ as __commonJSMin, S as require_react, et as __exportAll, nt as __toESM, x as require_jsx_runtime } from "./sd.generated-BeEKgSOs.js";
2
2
  import { n as RequestLogService } from "./services.generated-DjxCLdMu.js";
3
- import { a as Link, t as Route } from "../entry-server.generated.js";
3
+ import { a as Link } from "./lazyRouteComponent-Dyl_0WZs.js";
4
+ import { t as Route } from "../entry-server.generated.js";
4
5
  import minpath from "node:path";
5
6
  import minproc from "node:process";
6
7
  import { fileURLToPath as urlToPath } from "node:url";
@@ -1,6 +1,6 @@
1
1
  import { S as require_react, b as useQueryClient, c as array, d as custom, f as date, g as string, h as object, i as SonamuQueryMode, l as bigint, m as number, nt as __toESM, o as zArrayable, p as int, s as _enum, u as boolean, x as require_jsx_runtime } from "./sd.generated-BeEKgSOs.js";
2
2
  import { r as TokenService, t as QgridService } from "./services.generated-DjxCLdMu.js";
3
- import { i as lucideKeyRound, n as m5, r as mn } from "../entry-server.generated.js";
3
+ import { a as lucideKeyRound, i as mn, r as m5 } from "../entry-server.generated.js";
4
4
  //#region ~icons/lucide/eye.jsx
5
5
  var import_react = /* @__PURE__ */ __toESM(require_react());
6
6
  var import_jsx_runtime = require_jsx_runtime();