@dudousxd/nestjs-telescope-ui 4.2.0 → 4.3.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.
- package/CHANGELOG.md +8 -0
- package/README.md +6 -0
- package/dist/react/components/batch-timeline.d.ts +1 -1
- package/dist/react/components/batch-timeline.d.ts.map +1 -1
- package/dist/react/components/cache-badge.d.ts +1 -1
- package/dist/react/components/cache-badge.d.ts.map +1 -1
- package/dist/react/components/charts/area-chart-card.d.ts +2 -2
- package/dist/react/components/charts/area-chart-card.d.ts.map +1 -1
- package/dist/react/components/charts/area-chart-card.js +1 -1
- package/dist/react/components/charts/bar-chart-card.d.ts +2 -2
- package/dist/react/components/charts/bar-chart-card.d.ts.map +1 -1
- package/dist/react/components/charts/bar-chart-card.js +1 -1
- package/dist/react/components/charts/breakdown-card.d.ts +1 -2
- package/dist/react/components/charts/breakdown-card.d.ts.map +1 -1
- package/dist/react/components/charts/chart-card.d.ts +2 -2
- package/dist/react/components/charts/chart-card.d.ts.map +1 -1
- package/dist/react/components/charts/chart-card.js +1 -1
- package/dist/react/components/charts/chart-card.js.map +1 -1
- package/dist/react/components/charts/chart-theme.d.ts +1 -1
- package/dist/react/components/charts/chart-theme.d.ts.map +1 -1
- package/dist/react/components/charts/chart-theme.js +1 -1
- package/dist/react/components/charts/chart-theme.js.map +1 -1
- package/dist/react/components/charts/distribution-chart-card.d.ts +1 -2
- package/dist/react/components/charts/distribution-chart-card.d.ts.map +1 -1
- package/dist/react/components/charts/distribution-chart-card.js +1 -1
- package/dist/react/components/charts/gauge-card.d.ts +1 -2
- package/dist/react/components/charts/gauge-card.d.ts.map +1 -1
- package/dist/react/components/charts/stacked-area-chart-card.d.ts +2 -2
- package/dist/react/components/charts/stacked-area-chart-card.d.ts.map +1 -1
- package/dist/react/components/charts/stacked-area-chart-card.js +1 -1
- package/dist/react/components/entries-table.d.ts +1 -1
- package/dist/react/components/entries-table.d.ts.map +1 -1
- package/dist/react/components/entries-table.js +3 -2
- package/dist/react/components/entries-table.js.map +1 -1
- package/dist/react/components/entry-detail.d.ts +1 -1
- package/dist/react/components/entry-detail.d.ts.map +1 -1
- package/dist/react/components/entry-detail.js +11 -11
- package/dist/react/components/entry-detail.js.map +1 -1
- package/dist/react/components/entry-insights.d.ts +1 -1
- package/dist/react/components/entry-insights.d.ts.map +1 -1
- package/dist/react/components/entry-insights.js +6 -6
- package/dist/react/components/entry-insights.js.map +1 -1
- package/dist/react/components/export-json-toolbar.d.ts +1 -1
- package/dist/react/components/export-json-toolbar.d.ts.map +1 -1
- package/dist/react/components/extensions/panel-actions.d.ts +3 -3
- package/dist/react/components/extensions/panel-actions.d.ts.map +1 -1
- package/dist/react/components/extensions/panel-column-menu.d.ts +1 -2
- package/dist/react/components/extensions/panel-column-menu.d.ts.map +1 -1
- package/dist/react/components/extensions/panel-renderer.d.ts +1 -2
- package/dist/react/components/extensions/panel-renderer.d.ts.map +1 -1
- package/dist/react/components/extensions/panel-renderer.js +3 -3
- package/dist/react/components/extensions/panel-renderer.js.map +1 -1
- package/dist/react/components/extensions/panel-table-header.d.ts +2 -3
- package/dist/react/components/extensions/panel-table-header.d.ts.map +1 -1
- package/dist/react/components/extensions/panel-table.d.ts +1 -2
- package/dist/react/components/extensions/panel-table.d.ts.map +1 -1
- package/dist/react/components/extensions/stat-card.d.ts +1 -2
- package/dist/react/components/extensions/stat-card.d.ts.map +1 -1
- package/dist/react/components/extensions/stat-card.js +2 -2
- package/dist/react/components/extensions/stat-card.js.map +1 -1
- package/dist/react/components/extensions/table-columns.js +1 -1
- package/dist/react/components/extensions/table-columns.js.map +1 -1
- package/dist/react/components/flamegraph-view.d.ts +1 -2
- package/dist/react/components/flamegraph-view.d.ts.map +1 -1
- package/dist/react/components/flamegraph-view.js +1 -1
- package/dist/react/components/flamegraph-view.js.map +1 -1
- package/dist/react/components/inertia-badge.d.ts +1 -1
- package/dist/react/components/inertia-badge.d.ts.map +1 -1
- package/dist/react/components/inertia-body.d.ts +1 -1
- package/dist/react/components/inertia-body.d.ts.map +1 -1
- package/dist/react/components/inertia-body.js +9 -9
- package/dist/react/components/inertia-body.js.map +1 -1
- package/dist/react/components/official-event.d.ts +1 -1
- package/dist/react/components/official-event.d.ts.map +1 -1
- package/dist/react/components/official-event.js +1 -1
- package/dist/react/components/official-event.js.map +1 -1
- package/dist/react/components/pulse-panel.d.ts +1 -1
- package/dist/react/components/pulse-panel.d.ts.map +1 -1
- package/dist/react/components/pulse-panel.js +2 -2
- package/dist/react/components/pulse-panel.js.map +1 -1
- package/dist/react/components/queue-sparkline.d.ts +2 -2
- package/dist/react/components/queue-sparkline.d.ts.map +1 -1
- package/dist/react/components/queue-sparkline.js +1 -1
- package/dist/react/components/queue-sparkline.js.map +1 -1
- package/dist/react/components/queues/EnqueueJobForm.d.ts +1 -1
- package/dist/react/components/queues/EnqueueJobForm.d.ts.map +1 -1
- package/dist/react/components/queues/EnqueueJobForm.js +1 -1
- package/dist/react/components/queues/EnqueueJobForm.js.map +1 -1
- package/dist/react/components/queues/JobActions.d.ts +3 -3
- package/dist/react/components/queues/JobActions.d.ts.map +1 -1
- package/dist/react/components/queues/JobDetailDrawer.d.ts +1 -1
- package/dist/react/components/queues/JobDetailDrawer.d.ts.map +1 -1
- package/dist/react/components/queues/JobDetailDrawer.js +4 -4
- package/dist/react/components/queues/JobDetailDrawer.js.map +1 -1
- package/dist/react/components/queues/JobTable.d.ts +1 -1
- package/dist/react/components/queues/JobTable.d.ts.map +1 -1
- package/dist/react/components/queues/QueueList.d.ts +1 -1
- package/dist/react/components/queues/QueueList.d.ts.map +1 -1
- package/dist/react/components/queues/QueueList.js +2 -2
- package/dist/react/components/queues/QueueList.js.map +1 -1
- package/dist/react/components/queues/QueueStateTabs.d.ts +1 -1
- package/dist/react/components/queues/QueueStateTabs.d.ts.map +1 -1
- package/dist/react/components/queues-panel.d.ts +1 -1
- package/dist/react/components/queues-panel.d.ts.map +1 -1
- package/dist/react/components/request-timeline.d.ts +1 -1
- package/dist/react/components/request-timeline.d.ts.map +1 -1
- package/dist/react/components/retention-indicator.d.ts +1 -1
- package/dist/react/components/retention-indicator.d.ts.map +1 -1
- package/dist/react/components/retention-indicator.js +1 -1
- package/dist/react/components/retention-indicator.js.map +1 -1
- package/dist/react/components/sparkline.d.ts +1 -1
- package/dist/react/components/sparkline.d.ts.map +1 -1
- package/dist/react/components/stacked-bars.d.ts +1 -1
- package/dist/react/components/stacked-bars.d.ts.map +1 -1
- package/dist/react/components/tag-autocomplete.d.ts +1 -1
- package/dist/react/components/tag-autocomplete.d.ts.map +1 -1
- package/dist/react/components/waterfall-view.d.ts +1 -1
- package/dist/react/components/waterfall-view.d.ts.map +1 -1
- package/dist/react/components/waterfall-view.js +1 -1
- package/dist/react/components/waterfall-view.js.map +1 -1
- package/dist/react/components/window-select.d.ts +1 -1
- package/dist/react/components/window-select.d.ts.map +1 -1
- package/dist/react/telescope-context.d.ts +1 -1
- package/dist/react/telescope-context.d.ts.map +1 -1
- package/dist/react/ui/badge.d.ts +1 -1
- package/dist/react/ui/badge.d.ts.map +1 -1
- package/dist/react/ui/chart.d.ts +5 -5
- package/dist/react/ui/chart.d.ts.map +1 -1
- package/dist/react/ui/chart.js +2 -2
- package/dist/react/ui/chart.js.map +1 -1
- package/dist/react/ui/select.d.ts.map +1 -1
- package/dist/react/ui/select.js +1 -1
- package/dist/react/ui/select.js.map +1 -1
- package/dist/react/ui/table.js +1 -1
- package/dist/react/ui/table.js.map +1 -1
- package/dist/server/console-shell.d.ts +53 -0
- package/dist/server/console-shell.d.ts.map +1 -0
- package/dist/server/console-shell.js +130 -0
- package/dist/server/console-shell.js.map +1 -0
- package/dist/server/index.d.ts +1 -0
- package/dist/server/index.d.ts.map +1 -1
- package/dist/server/index.js +2 -0
- package/dist/server/index.js.map +1 -1
- package/dist/server/telescope-ui.controller.d.ts +2 -1
- package/dist/server/telescope-ui.controller.d.ts.map +1 -1
- package/dist/server/telescope-ui.controller.js +30 -11
- package/dist/server/telescope-ui.controller.js.map +1 -1
- package/dist/server/telescope-ui.options.d.ts +25 -0
- package/dist/server/telescope-ui.options.d.ts.map +1 -1
- package/dist/server/telescope-ui.options.js.map +1 -1
- package/dist/spa/assets/index-B5IIRiHt.js +228 -0
- package/dist/spa/assets/index-C2zgCbqj.css +1 -0
- package/dist/spa/assets/jetbrains-mono-latin-400-normal-6-qcROiO.woff +0 -0
- package/dist/spa/assets/jetbrains-mono-latin-400-normal-V6pRDFza.woff2 +0 -0
- package/dist/spa/assets/jetbrains-mono-latin-500-normal-BWZEU5yA.woff2 +0 -0
- package/dist/spa/assets/jetbrains-mono-latin-500-normal-CJOVTJB7.woff +0 -0
- package/dist/spa/assets/jetbrains-mono-latin-600-normal-BfsvjouI.woff +0 -0
- package/dist/spa/assets/jetbrains-mono-latin-600-normal-C8RAYTDA.woff2 +0 -0
- package/dist/spa/assets/sora-latin-400-normal-CRt88UEn.woff2 +0 -0
- package/dist/spa/assets/sora-latin-400-normal-OW7qkl5a.woff +0 -0
- package/dist/spa/assets/sora-latin-500-normal-01eiPEn0.woff2 +0 -0
- package/dist/spa/assets/sora-latin-500-normal-w58xtEt9.woff +0 -0
- package/dist/spa/assets/sora-latin-600-normal-1_7fyUAY.woff +0 -0
- package/dist/spa/assets/sora-latin-600-normal-Cdg4DaK0.woff2 +0 -0
- package/dist/spa/assets/sora-latin-700-normal-9waGdLWo.woff2 +0 -0
- package/dist/spa/assets/sora-latin-700-normal-BKPfQAnC.woff +0 -0
- package/dist/spa/index.html +8 -2
- package/package.json +19 -13
- package/dist/spa/assets/index-BNCovQ2Z.js +0 -159
- package/dist/spa/assets/index-DdEYuSwo.css +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @dudousxd/nestjs-telescope-ui
|
|
2
2
|
|
|
3
|
+
## 4.3.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#195](https://github.com/DavideCarvalho/nestjs-telescope/pull/195) [`633da31`](https://github.com/DavideCarvalho/nestjs-telescope/commit/633da31c315028e79211444d20da3388a0dccf3b) Thanks [@DavideCarvalho](https://github.com/DavideCarvalho)! - The console moves onto the shared Aviary console kit: a sidebar shell (console switcher, MONITOR · Overview / Pulse / Exceptions, EXPLORE · Entries / Traces / AI / Profiles, OPERATIONS · Queues / Schedules, DASHBOARDS · the contributed ones, WATCHERS · one dot per entry type (folded), DATA · Exports / Prunes, signed-in user, light/dark toggle, sign-out), a topbar with the organization, the retention, the live / pause toggle and ⌘K, bundled Sora + JetBrains Mono (mono for data only, no more all-monospace shell), Tailwind 4 + React 19 inside the bundle, page headers, shaped skeletons, error boundaries and empty states, light mode on the kit's palette, and a phone-width drawer. Every page, route, deep link and the access-denied page are kept. The theme is now remembered under `aviary-telescope-theme` (a choice saved under `telescope-theme` is kept as the default).
|
|
8
|
+
|
|
9
|
+
⌘K lists Telescope's pages and entry types first, then searches each console on its own, streaming the groups in as they answer: `GET <path>/api/consoles/search?q=&console=<id>` answers for one console (`searchVisibleConsoles` takes the id as a new last argument). New `TelescopeUiModule.forRoot` / `forRootAsync` options feed the sidebar footer: `viewer: (request) => ({ label, email?, role? })` (default: `request.user` read structurally) and `signOut: '/path' | { href } | { action, csrfToken? } | false` (default: the `account.signOut` an account console announces on the Aviary consoles registry). `TelescopeUiController.index()` is now async and takes the request: a host subclass that overrides `index()` must make its override async too (`async index(request?): Promise<string>`). `isSameOriginPath` now rejects a backslash or control character anywhere in the path; `.woff` / `.woff2` assets are served with font content types. The published `/react` components keep their API and React 18/19 peer range; their class names follow the kit's tokens.
|
|
10
|
+
|
|
3
11
|
## 4.2.0
|
|
4
12
|
|
|
5
13
|
### Minor Changes
|
package/README.md
CHANGED
|
@@ -54,6 +54,12 @@ Without `authorize` the page is open outside production; with
|
|
|
54
54
|
`decorators` (e.g. `[UseGuards(AuthenticationGuard)]`) still run first. See
|
|
55
55
|
[Protecting the routes](../../README.md#protecting-the-routes).
|
|
56
56
|
|
|
57
|
+
The console's sidebar footer shows who is signed in and a sign-out. `viewer: (req) => ({ label,
|
|
58
|
+
email?, role? })` (sync or async) defaults to `request.user`, read structurally and never triggering
|
|
59
|
+
an authentication. `signOut: '/logout' | { href } | { action, csrfToken? } | false` defaults to the
|
|
60
|
+
`account.signOut` an account console announced on the Aviary consoles registry, else none. Only
|
|
61
|
+
same-origin paths reach the page.
|
|
62
|
+
|
|
57
63
|
To link to the console from your app, `telescopeConsoleUrl(basePath)` (from
|
|
58
64
|
`@dudousxd/nestjs-telescope-ui/client`) gives its URL.
|
|
59
65
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"batch-timeline.d.ts","sourceRoot":"","sources":["../../../src/react/components/batch-timeline.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,uBAAuB,CAAC;AAGnD,wBAAgB,aAAa,CAAC,EAC5B,KAAK,EACL,SAAS,EACT,QAAQ,GACT,EAAE;IACD,KAAK,EAAE,KAAK,EAAE,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAC,GAAG,SAAS,CAAC;CAC/C,GAAG,GAAG,CAAC,OAAO,
|
|
1
|
+
{"version":3,"file":"batch-timeline.d.ts","sourceRoot":"","sources":["../../../src/react/components/batch-timeline.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,uBAAuB,CAAC;AAGnD,wBAAgB,aAAa,CAAC,EAC5B,KAAK,EACL,SAAS,EACT,QAAQ,GACT,EAAE;IACD,KAAK,EAAE,KAAK,EAAE,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAC,GAAG,SAAS,CAAC;CAC/C,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CA2BpB"}
|
|
@@ -24,5 +24,5 @@ export declare function cacheBadge(content: unknown): CacheBadgeInfo | null;
|
|
|
24
24
|
/** Small cache hit/miss/set status pill; renders nothing for non-cache content. */
|
|
25
25
|
export declare function CacheBadge({ content }: {
|
|
26
26
|
content: unknown;
|
|
27
|
-
}): JSX.Element | null;
|
|
27
|
+
}): React.JSX.Element | null;
|
|
28
28
|
//# sourceMappingURL=cache-badge.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cache-badge.d.ts","sourceRoot":"","sources":["../../../src/react/components/cache-badge.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EAAS,KAAK,UAAU,EAAiB,MAAM,gBAAgB,CAAC;AAsBvE,MAAM,WAAW,cAAc;IAC7B,KAAK,EAAE,MAAM,CAAC;IACd;;;;OAIG;IACH,OAAO,EAAE,WAAW,CAAC,UAAU,CAAC,SAAS,CAAC,CAAC,CAAC;IAC5C,sFAAsF;IACtF,SAAS,EAAE,MAAM,CAAC;CACnB;AAMD;;;GAGG;AACH,wBAAgB,UAAU,CAAC,OAAO,EAAE,OAAO,GAAG,cAAc,GAAG,IAAI,CAalE;AAED,mFAAmF;AACnF,wBAAgB,UAAU,CAAC,EAAE,OAAO,EAAE,EAAE;IAAE,OAAO,EAAE,OAAO,CAAA;CAAE,GAAG,GAAG,CAAC,OAAO,GAAG,IAAI,
|
|
1
|
+
{"version":3,"file":"cache-badge.d.ts","sourceRoot":"","sources":["../../../src/react/components/cache-badge.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EAAS,KAAK,UAAU,EAAiB,MAAM,gBAAgB,CAAC;AAsBvE,MAAM,WAAW,cAAc;IAC7B,KAAK,EAAE,MAAM,CAAC;IACd;;;;OAIG;IACH,OAAO,EAAE,WAAW,CAAC,UAAU,CAAC,SAAS,CAAC,CAAC,CAAC;IAC5C,sFAAsF;IACtF,SAAS,EAAE,MAAM,CAAC;CACnB;AAMD;;;GAGG;AACH,wBAAgB,UAAU,CAAC,OAAO,EAAE,OAAO,GAAG,cAAc,GAAG,IAAI,CAalE;AAED,mFAAmF;AACnF,wBAAgB,UAAU,CAAC,EAAE,OAAO,EAAE,EAAE;IAAE,OAAO,EAAE,OAAO,CAAA;CAAE,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,GAAG,IAAI,CAItF"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
2
|
import { type ChartSelection } from './chart-selection.js';
|
|
3
3
|
export interface AreaChartPoint {
|
|
4
4
|
/** X-axis label (e.g. formatted time). */
|
|
@@ -20,5 +20,5 @@ export declare function AreaChartCard({ title, data, right, color, valueLabel, h
|
|
|
20
20
|
valueFormatter?: (value: number) => ReactNode;
|
|
21
21
|
/** Drill-down: called with the point under a click. Omit and the chart is inert. */
|
|
22
22
|
onSelect?: (selection: ChartSelection) => void;
|
|
23
|
-
}): JSX.Element;
|
|
23
|
+
}): React.JSX.Element;
|
|
24
24
|
//# sourceMappingURL=area-chart-card.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"area-chart-card.d.ts","sourceRoot":"","sources":["../../../../src/react/components/charts/area-chart-card.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"area-chart-card.d.ts","sourceRoot":"","sources":["../../../../src/react/components/charts/area-chart-card.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAO,SAAS,EAAE,MAAM,OAAO,CAAC;AAW5C,OAAO,EAAE,KAAK,cAAc,EAAoC,MAAM,sBAAsB,CAAC;AAG7F,MAAM,WAAW,cAAc;IAC7B,0CAA0C;IAC1C,KAAK,EAAE,MAAM,CAAC;IACd,oBAAoB;IACpB,KAAK,EAAE,MAAM,CAAC;CACf;AAWD,8FAA8F;AAC9F,wBAAgB,aAAa,CAAC,EAC5B,KAAK,EACL,IAAI,EACJ,KAAK,EACL,KAAkB,EAClB,UAAoB,EACpB,MAAY,EACZ,KAAK,EACL,cAAc,EACd,QAAQ,GACT,EAAE;IACD,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,cAAc,EAAE,CAAC;IACvB,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,+EAA+E;IAC/E,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,mEAAmE;IACnE,cAAc,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,SAAS,CAAC;IAC9C,oFAAoF;IACpF,QAAQ,CAAC,EAAE,CAAC,SAAS,EAAE,cAAc,KAAK,IAAI,CAAC;CAChD,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CA0EpB"}
|
|
@@ -34,6 +34,6 @@ export function AreaChartCard({ title, data, right, color = ACCENT_HEX, valueLab
|
|
|
34
34
|
className: 'cursor-pointer',
|
|
35
35
|
}
|
|
36
36
|
: {};
|
|
37
|
-
return (_jsx(ChartCard, { title: title, right: right, height: bodyHeight, children: data.length === 0 ? (_jsx(ChartEmptyState, { height: bodyHeight })) : (_jsx(ChartContainer, { config: config, children: _jsxs(AreaChart, { data: data, margin: { top: 4, right: 8, bottom: 0, left: -16 }, ...clickProps, children: [_jsx("defs", { children: _jsxs("linearGradient", { id: gradientId, x1: "0", y1: "0", x2: "0", y2: "1", children: [_jsx("stop", { offset: "0%", stopColor: chartColorVar('value'), stopOpacity: 0.35 }), _jsx("stop", { offset: "100%", stopColor: chartColorVar('value'), stopOpacity: 0 })] }) }), _jsx(CartesianGrid, { vertical: false }), _jsx(XAxis, { dataKey: "label", tickLine: false, minTickGap: 24 }), _jsx(YAxis, { tickLine: false, width:
|
|
37
|
+
return (_jsx(ChartCard, { title: title, right: right, height: bodyHeight, children: data.length === 0 ? (_jsx(ChartEmptyState, { height: bodyHeight })) : (_jsx(ChartContainer, { config: config, children: _jsxs(AreaChart, { data: data, margin: { top: 4, right: 8, bottom: 0, left: -16 }, ...clickProps, children: [_jsx("defs", { children: _jsxs("linearGradient", { id: gradientId, x1: "0", y1: "0", x2: "0", y2: "1", children: [_jsx("stop", { offset: "0%", stopColor: chartColorVar('value'), stopOpacity: 0.35 }), _jsx("stop", { offset: "100%", stopColor: chartColorVar('value'), stopOpacity: 0 })] }) }), _jsx(CartesianGrid, { vertical: false }), _jsx(XAxis, { dataKey: "label", tickLine: false, minTickGap: 24 }), _jsx(YAxis, { tickLine: false, width: 52, allowDecimals: false }), _jsx(ChartTooltip, { cursor: { stroke: 'var(--line)' }, content: _jsx(ChartTooltipContent, { ...(valueFormatter ? { valueFormatter: (v) => valueFormatter(v) } : {}) }) }), _jsx(Area, { type: "monotone", dataKey: "value", name: valueLabel, stroke: chartColorVar('value'), strokeWidth: 2, fill: `url(#${gradientId})`, isAnimationActive: false, dot: false, activeDot: { r: 3 } }), showBrush && _jsx(Brush, { ...chartBrushProps, dataKey: "label" })] }) })) }));
|
|
38
38
|
}
|
|
39
39
|
//# sourceMappingURL=area-chart-card.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
2
|
import { type ChartSelection } from './chart-selection.js';
|
|
3
3
|
export interface BarChartDatum {
|
|
4
4
|
/** Category label on the x-axis (or y-axis when horizontal). */
|
|
@@ -27,5 +27,5 @@ export interface BarChartCardProps {
|
|
|
27
27
|
onSelect?: (selection: ChartSelection) => void;
|
|
28
28
|
}
|
|
29
29
|
/** Categorical bar chart (e.g. per-queue failure rate) with a hover card. */
|
|
30
|
-
export declare function BarChartCard({ title, data, right, color, valueLabel, height, horizontal, truncateLabel, valueFormatter, onSelect, }: BarChartCardProps): JSX.Element;
|
|
30
|
+
export declare function BarChartCard({ title, data, right, color, valueLabel, height, horizontal, truncateLabel, valueFormatter, onSelect, }: BarChartCardProps): React.JSX.Element;
|
|
31
31
|
//# sourceMappingURL=bar-chart-card.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bar-chart-card.d.ts","sourceRoot":"","sources":["../../../../src/react/components/charts/bar-chart-card.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"bar-chart-card.d.ts","sourceRoot":"","sources":["../../../../src/react/components/charts/bar-chart-card.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAO,SAAS,EAAE,MAAM,OAAO,CAAC;AAU5C,OAAO,EAAE,KAAK,cAAc,EAAkB,MAAM,sBAAsB,CAAC;AAG3E,MAAM,WAAW,aAAa;IAC5B,gEAAgE;IAChE,KAAK,EAAE,MAAM,CAAC;IACd,iBAAiB;IACjB,KAAK,EAAE,MAAM,CAAC;IACd,uCAAuC;IACvC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,wFAAwF;IACxF,EAAE,CAAC,EAAE,MAAM,CAAC;CACb;AAQD,MAAM,WAAW,iBAAiB;IAChC,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,aAAa,EAAE,CAAC;IACtB,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,gFAAgF;IAChF,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,oFAAoF;IACpF,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,mEAAmE;IACnE,cAAc,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,SAAS,CAAC;IAC9C,kFAAkF;IAClF,QAAQ,CAAC,EAAE,CAAC,SAAS,EAAE,cAAc,KAAK,IAAI,CAAC;CAChD;AAED,6EAA6E;AAC7E,wBAAgB,YAAY,CAAC,EAC3B,KAAK,EACL,IAAI,EACJ,KAAK,EACL,KAAkB,EAClB,UAAoB,EACpB,MAAY,EACZ,UAAkB,EAClB,aAAa,EACb,cAAc,EACd,QAAQ,GACT,EAAE,iBAAiB,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CAqFvC"}
|
|
@@ -30,6 +30,6 @@ export function BarChartCard({ title, data, right, color = ACCENT_HEX, valueLabe
|
|
|
30
30
|
const barInteractionProps = interactive
|
|
31
31
|
? { onClick: handleBarClick, cursor: 'pointer' }
|
|
32
32
|
: {};
|
|
33
|
-
return (_jsx(ChartCard, { title: title, right: right, height: bodyHeight, children: data.length === 0 ? (_jsx(ChartEmptyState, { height: bodyHeight })) : (_jsx(ChartContainer, { config: config, children: _jsxs(BarChart, { data: data, layout: horizontal ? 'vertical' : 'horizontal', margin: { top: 4, right: 8, bottom: 0, left: horizontal ? 8 : -16 }, children: [_jsx(CartesianGrid, { horizontal: !horizontal, vertical: horizontal }), horizontal ? (_jsx(XAxis, { type: "number", tickLine: false, allowDecimals: false })) : (_jsx(XAxis, { dataKey: "label", tickLine: false, interval: 0, ...tickFormatterProps })), horizontal ? (_jsx(YAxis, { type: "category", dataKey: "label", tickLine: false, width: 160, interval: 0, ...tickFormatterProps })) : (_jsx(YAxis, { tickLine: false, width:
|
|
33
|
+
return (_jsx(ChartCard, { title: title, right: right, height: bodyHeight, children: data.length === 0 ? (_jsx(ChartEmptyState, { height: bodyHeight })) : (_jsx(ChartContainer, { config: config, children: _jsxs(BarChart, { data: data, layout: horizontal ? 'vertical' : 'horizontal', margin: { top: 4, right: 8, bottom: 0, left: horizontal ? 8 : -16 }, children: [_jsx(CartesianGrid, { horizontal: !horizontal, vertical: horizontal }), horizontal ? (_jsx(XAxis, { type: "number", tickLine: false, allowDecimals: false })) : (_jsx(XAxis, { dataKey: "label", tickLine: false, interval: 0, ...tickFormatterProps })), horizontal ? (_jsx(YAxis, { type: "category", dataKey: "label", tickLine: false, width: 160, interval: 0, ...tickFormatterProps })) : (_jsx(YAxis, { tickLine: false, width: 52, allowDecimals: false })), _jsx(ChartTooltip, { cursor: { fill: 'color-mix(in srgb, var(--text) 5%, transparent)' }, content: _jsx(ChartTooltipContent, { ...(valueFormatter ? { valueFormatter: (v) => valueFormatter(v) } : {}) }) }), _jsx(Bar, { dataKey: "value", name: valueLabel, fill: chartColorVar('value'), radius: horizontal ? [0, 3, 3, 0] : [3, 3, 0, 0], isAnimationActive: false, ...barInteractionProps, children: data.map((datum) => (_jsx(Cell, { fill: datum.color ?? chartColorVar('value') }, datum.id ?? datum.label))) })] }) })) }));
|
|
34
34
|
}
|
|
35
35
|
//# sourceMappingURL=bar-chart-card.js.map
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import type { JSX } from 'react';
|
|
2
1
|
import { type ChartSelection } from './chart-selection.js';
|
|
3
2
|
export interface BreakdownSegment {
|
|
4
3
|
label: string;
|
|
@@ -13,5 +12,5 @@ export declare function BreakdownCard({ title, segments, style, height, onSelect
|
|
|
13
12
|
height?: number;
|
|
14
13
|
/** Drill-down: called with the segment under a click. Omit and the chart is inert. */
|
|
15
14
|
onSelect?: (selection: ChartSelection) => void;
|
|
16
|
-
}): JSX.Element;
|
|
15
|
+
}): React.JSX.Element;
|
|
17
16
|
//# sourceMappingURL=breakdown-card.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"breakdown-card.d.ts","sourceRoot":"","sources":["../../../../src/react/components/charts/breakdown-card.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"breakdown-card.d.ts","sourceRoot":"","sources":["../../../../src/react/components/charts/breakdown-card.tsx"],"names":[],"mappings":"AAWA,OAAO,EAAE,KAAK,cAAc,EAAkB,MAAM,sBAAsB,CAAC;AAG3E,MAAM,WAAW,gBAAgB;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,oFAAoF;AACpF,wBAAgB,aAAa,CAAC,EAC5B,KAAK,EACL,QAAQ,EACR,KAAe,EACf,MAAY,EACZ,QAAQ,GACT,EAAE;IACD,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,gBAAgB,EAAE,CAAC;IAC7B,KAAK,CAAC,EAAE,OAAO,GAAG,KAAK,CAAC;IACxB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,sFAAsF;IACtF,QAAQ,CAAC,EAAE,CAAC,SAAS,EAAE,cAAc,KAAK,IAAI,CAAC;CAChD,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CA2FpB"}
|
|
@@ -4,7 +4,7 @@ export declare function ChartCard({ title, right, height, children, }: {
|
|
|
4
4
|
right?: React.ReactNode;
|
|
5
5
|
height?: number;
|
|
6
6
|
children: React.ReactNode;
|
|
7
|
-
}): JSX.Element;
|
|
7
|
+
}): React.JSX.Element;
|
|
8
8
|
/**
|
|
9
9
|
* "Nothing in this window" body. `height` is optional: given one it reserves
|
|
10
10
|
* exactly the space the chart would have taken, and without one it fills its
|
|
@@ -14,5 +14,5 @@ export declare function ChartCard({ title, right, height, children, }: {
|
|
|
14
14
|
*/
|
|
15
15
|
export declare function ChartEmptyState({ height }: {
|
|
16
16
|
height?: number;
|
|
17
|
-
}): JSX.Element;
|
|
17
|
+
}): React.JSX.Element;
|
|
18
18
|
//# sourceMappingURL=chart-card.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"chart-card.d.ts","sourceRoot":"","sources":["../../../../src/react/components/charts/chart-card.tsx"],"names":[],"mappings":"AAAA,yFAAyF;AACzF,wBAAgB,SAAS,CAAC,EACxB,KAAK,EACL,KAAK,EACL,MAAY,EACZ,QAAQ,GACT,EAAE;IACD,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACxB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B,GAAG,GAAG,CAAC,OAAO,
|
|
1
|
+
{"version":3,"file":"chart-card.d.ts","sourceRoot":"","sources":["../../../../src/react/components/charts/chart-card.tsx"],"names":[],"mappings":"AAAA,yFAAyF;AACzF,wBAAgB,SAAS,CAAC,EACxB,KAAK,EACL,KAAK,EACL,MAAY,EACZ,QAAQ,GACT,EAAE;IACD,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACxB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CAUpB;AAED;;;;;;GAMG;AACH,wBAAgB,eAAe,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,CAAC,EAAE,MAAM,CAAA;CAAE,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CASlF"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
/** Shared card chrome (title, optional right slot, framed body) for every chart card. */
|
|
3
3
|
export function ChartCard({ title, right, height = 220, children, }) {
|
|
4
|
-
return (_jsxs("section", { className: "rounded-lg border border-
|
|
4
|
+
return (_jsxs("section", { className: "aviary-surface rounded-lg border border-border p-4", children: [_jsxs("header", { className: "-mx-4 -mt-4 mb-3 flex items-center justify-between gap-3 border-b border-border px-4 py-3", children: [_jsx("h3", { className: "text-[12.5px] font-semibold tracking-[0.02em] text-fg", children: title }), right] }), _jsx("div", { style: { height }, children: children })] }));
|
|
5
5
|
}
|
|
6
6
|
/**
|
|
7
7
|
* "Nothing in this window" body. `height` is optional: given one it reserves
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"chart-card.js","sourceRoot":"","sources":["../../../../src/react/components/charts/chart-card.tsx"],"names":[],"mappings":";AAAA,yFAAyF;AACzF,MAAM,UAAU,SAAS,CAAC,EACxB,KAAK,EACL,KAAK,EACL,MAAM,GAAG,GAAG,EACZ,QAAQ,GAMT;IACC,OAAO,CACL,mBAAS,SAAS,EAAC
|
|
1
|
+
{"version":3,"file":"chart-card.js","sourceRoot":"","sources":["../../../../src/react/components/charts/chart-card.tsx"],"names":[],"mappings":";AAAA,yFAAyF;AACzF,MAAM,UAAU,SAAS,CAAC,EACxB,KAAK,EACL,KAAK,EACL,MAAM,GAAG,GAAG,EACZ,QAAQ,GAMT;IACC,OAAO,CACL,mBAAS,SAAS,EAAC,oDAAoD,aACrE,kBAAQ,SAAS,EAAC,2FAA2F,aAC3G,aAAI,SAAS,EAAC,uDAAuD,YAAE,KAAK,GAAM,EACjF,KAAK,IACC,EACT,cAAK,KAAK,EAAE,EAAE,MAAM,EAAE,YAAG,QAAQ,GAAO,IAChC,CACX,CAAC;AACJ,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,eAAe,CAAC,EAAE,MAAM,EAAuB;IAC7D,OAAO,CACL,cACE,SAAS,EAAC,uEAAuE,EACjF,KAAK,EAAE,MAAM,KAAK,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,mCAGhD,CACP,CAAC;AACJ,CAAC"}
|
|
@@ -16,7 +16,7 @@ import type { ChartConfig } from '../../ui/chart.js';
|
|
|
16
16
|
/** Resolved hex colors for known entry types (matches the `fill-*` tokens used elsewhere). */
|
|
17
17
|
export declare const TYPE_HEX: Record<string, string>;
|
|
18
18
|
/** Primary throughput accent — the console `--accent`, not a status hue. */
|
|
19
|
-
export declare const ACCENT_HEX = "var(--accent)";
|
|
19
|
+
export declare const ACCENT_HEX = "var(--aviary-accent-ink, var(--accent))";
|
|
20
20
|
export declare function hexForType(type: string, fallbackIndex?: number): string;
|
|
21
21
|
/**
|
|
22
22
|
* Colour for one breakdown/pie segment: an author's explicit `color` wins, then
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"chart-theme.d.ts","sourceRoot":"","sources":["../../../../src/react/components/charts/chart-theme.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAErD;;;;;;;;;;;;;GAaG;AAEH,8FAA8F;AAC9F,eAAO,MAAM,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAO3C,CAAC;AAYF,4EAA4E;AAC5E,eAAO,MAAM,UAAU,
|
|
1
|
+
{"version":3,"file":"chart-theme.d.ts","sourceRoot":"","sources":["../../../../src/react/components/charts/chart-theme.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAErD;;;;;;;;;;;;;GAaG;AAEH,8FAA8F;AAC9F,eAAO,MAAM,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAO3C,CAAC;AAYF,4EAA4E;AAC5E,eAAO,MAAM,UAAU,4CAA4C,CAAC;AAEpE,wBAAgB,UAAU,CAAC,IAAI,EAAE,MAAM,EAAE,aAAa,SAAI,GAAG,MAAM,CAGlE;AAED;;;;;;;;GAQG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,CAIrF;AAED;;;;;GAKG;AACH,wBAAgB,WAAW,CACzB,IAAI,EAAE,MAAM,EAAE,EACd,QAAQ,EAAE,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,MAAM,EAChD,QAAQ,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,GACjC,WAAW,CAMb"}
|
|
@@ -30,7 +30,7 @@ const FALLBACK_PALETTE = ['#71717a', '#a1a1aa', '#22d3ee', '#c084fc', '#fb923c',
|
|
|
30
30
|
*/
|
|
31
31
|
const SEGMENT_PALETTE = ['#34d399', '#fbbf24', '#f87171', '#38bdf8', '#a78bfa'];
|
|
32
32
|
/** Primary throughput accent — the console `--accent`, not a status hue. */
|
|
33
|
-
export const ACCENT_HEX = 'var(--accent)';
|
|
33
|
+
export const ACCENT_HEX = 'var(--aviary-accent-ink, var(--accent))';
|
|
34
34
|
export function hexForType(type, fallbackIndex = 0) {
|
|
35
35
|
const fallback = FALLBACK_PALETTE[fallbackIndex % FALLBACK_PALETTE.length];
|
|
36
36
|
return TYPE_HEX[type] ?? fallback ?? '#71717a';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"chart-theme.js","sourceRoot":"","sources":["../../../../src/react/components/charts/chart-theme.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;GAaG;AAEH,8FAA8F;AAC9F,MAAM,CAAC,MAAM,QAAQ,GAA2B;IAC9C,OAAO,EAAE,SAAS,EAAE,cAAc;IAClC,KAAK,EAAE,SAAS,EAAE,UAAU;IAC5B,GAAG,EAAE,SAAS,EAAE,aAAa;IAC7B,SAAS,EAAE,SAAS,EAAE,UAAU;IAChC,WAAW,EAAE,SAAS,EAAE,YAAY;IACpC,IAAI,EAAE,SAAS,EAAE,WAAW;CAC7B,CAAC;AAEF,wEAAwE;AACxE,MAAM,gBAAgB,GAAG,CAAC,SAAS,EAAE,SAAS,EAAE,SAAS,EAAE,SAAS,EAAE,SAAS,EAAE,SAAS,CAAC,CAAC;AAE5F;;;;GAIG;AACH,MAAM,eAAe,GAAG,CAAC,SAAS,EAAE,SAAS,EAAE,SAAS,EAAE,SAAS,EAAE,SAAS,CAAC,CAAC;AAEhF,4EAA4E;AAC5E,MAAM,CAAC,MAAM,UAAU,GAAG,
|
|
1
|
+
{"version":3,"file":"chart-theme.js","sourceRoot":"","sources":["../../../../src/react/components/charts/chart-theme.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;GAaG;AAEH,8FAA8F;AAC9F,MAAM,CAAC,MAAM,QAAQ,GAA2B;IAC9C,OAAO,EAAE,SAAS,EAAE,cAAc;IAClC,KAAK,EAAE,SAAS,EAAE,UAAU;IAC5B,GAAG,EAAE,SAAS,EAAE,aAAa;IAC7B,SAAS,EAAE,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AG,EAAE,KAAK,CAAC,EAAE,CAAC;IAC/E,CAAC,CAAC,CAAC;IACH,OAAO,MAAM,CAAC;AAChB,CAAC"}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import type { JSX } from 'react';
|
|
2
1
|
import { type ChartSelection } from './chart-selection.js';
|
|
3
2
|
/** Latency histogram with p50/p95/p99 chips above it. */
|
|
4
3
|
export declare function DistributionChartCard({ title, buckets, p50, p95, p99, height, onSelect, }: {
|
|
@@ -13,5 +12,5 @@ export declare function DistributionChartCard({ title, buckets, p50, p95, p99, h
|
|
|
13
12
|
height?: number;
|
|
14
13
|
/** Drill-down: called with the bucket under a click. Omit and the chart is inert. */
|
|
15
14
|
onSelect?: (selection: ChartSelection) => void;
|
|
16
|
-
}): JSX.Element;
|
|
15
|
+
}): React.JSX.Element;
|
|
17
16
|
//# sourceMappingURL=distribution-chart-card.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"distribution-chart-card.d.ts","sourceRoot":"","sources":["../../../../src/react/components/charts/distribution-chart-card.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"distribution-chart-card.d.ts","sourceRoot":"","sources":["../../../../src/react/components/charts/distribution-chart-card.tsx"],"names":[],"mappings":"AAUA,OAAO,EAAE,KAAK,cAAc,EAAkB,MAAM,sBAAsB,CAAC;AAoB3E,yDAAyD;AACzD,wBAAgB,qBAAqB,CAAC,EACpC,KAAK,EACL,OAAO,EACP,GAAG,EACH,GAAG,EACH,GAAG,EACH,MAAY,EACZ,QAAQ,GACT,EAAE;IACD,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;IAC5C,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,qFAAqF;IACrF,QAAQ,CAAC,EAAE,CAAC,SAAS,EAAE,cAAc,KAAK,IAAI,CAAC;CAChD,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CAgEpB"}
|
|
@@ -41,6 +41,6 @@ export function DistributionChartCard({ title, buckets, p50, p95, p99, height =
|
|
|
41
41
|
cursor: 'pointer',
|
|
42
42
|
}
|
|
43
43
|
: {};
|
|
44
|
-
return (_jsx(ChartCard, { title: title, height: bodyHeight, children: _jsxs("div", { className: "flex h-full flex-col", children: [chips.length > 0 && (_jsx("div", { className: "mb-1.5 flex flex-wrap gap-2", children: chips.map(([value, name]) => (_jsxs("span", { className: `rounded border px-1.5 text-[10px] tabular-nums ${MARKER_TINT[name]}`, children: [name, ": ", formatDuration(value)] }, name))) })), _jsx("div", { className: "min-h-0 flex-1", children: buckets.length === 0 ? (_jsx(ChartEmptyState, {})) : (_jsx(ChartContainer, { config: config, children: _jsxs(BarChart, { data: buckets, margin: { top: 4, right: 8, bottom: 0, left: -16 }, children: [_jsx(CartesianGrid, { vertical: false }), _jsx(XAxis, { dataKey: "label", tickLine: false }), _jsx(YAxis, { tickLine: false, allowDecimals: false, width:
|
|
44
|
+
return (_jsx(ChartCard, { title: title, height: bodyHeight, children: _jsxs("div", { className: "flex h-full flex-col", children: [chips.length > 0 && (_jsx("div", { className: "mb-1.5 flex flex-wrap gap-2", children: chips.map(([value, name]) => (_jsxs("span", { className: `rounded border px-1.5 text-[10px] tabular-nums ${MARKER_TINT[name]}`, children: [name, ": ", formatDuration(value)] }, name))) })), _jsx("div", { className: "min-h-0 flex-1", children: buckets.length === 0 ? (_jsx(ChartEmptyState, {})) : (_jsx(ChartContainer, { config: config, children: _jsxs(BarChart, { data: buckets, margin: { top: 4, right: 8, bottom: 0, left: -16 }, children: [_jsx(CartesianGrid, { vertical: false }), _jsx(XAxis, { dataKey: "label", tickLine: false }), _jsx(YAxis, { tickLine: false, allowDecimals: false, width: 52 }), _jsx(ChartTooltip, { cursor: { fill: 'color-mix(in srgb, var(--text) 5%, transparent)' }, content: _jsx(ChartTooltipContent, {}) }), _jsx(Bar, { dataKey: "count", name: "count", fill: chartColorVar('count'), radius: [3, 3, 0, 0], isAnimationActive: false, ...clickProps })] }) })) })] }) }));
|
|
45
45
|
}
|
|
46
46
|
//# sourceMappingURL=distribution-chart-card.js.map
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import type { JSX } from 'react';
|
|
2
1
|
/** Half-dial gauge: one value against a min/max, with the reading over the arc. */
|
|
3
2
|
export declare function GaugeCard({ title, value, min, max, label, color, height, }: {
|
|
4
3
|
title: string;
|
|
@@ -8,5 +7,5 @@ export declare function GaugeCard({ title, value, min, max, label, color, height
|
|
|
8
7
|
label?: string;
|
|
9
8
|
color?: string;
|
|
10
9
|
height?: number;
|
|
11
|
-
}): JSX.Element;
|
|
10
|
+
}): React.JSX.Element;
|
|
12
11
|
//# sourceMappingURL=gauge-card.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"gauge-card.d.ts","sourceRoot":"","sources":["../../../../src/react/components/charts/gauge-card.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"gauge-card.d.ts","sourceRoot":"","sources":["../../../../src/react/components/charts/gauge-card.tsx"],"names":[],"mappings":"AAOA,mFAAmF;AACnF,wBAAgB,SAAS,CAAC,EACxB,KAAK,EACL,KAAK,EACL,GAAO,EACP,GAAO,EACP,KAAK,EACL,KAAqB,EACrB,MAAY,GACb,EAAE;IACD,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CAiDpB"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
2
|
import { type ChartSelection } from './chart-selection.js';
|
|
3
3
|
/** Each row carries the x-axis `label` plus one numeric key per series. */
|
|
4
4
|
export type StackedAreaRow = {
|
|
@@ -24,5 +24,5 @@ export declare function StackedAreaChartCard({ title, data, series, right, heigh
|
|
|
24
24
|
onSelect?: (selection: ChartSelection) => void;
|
|
25
25
|
/** Explicit series colours; series not listed fall back to the entry-type palette. */
|
|
26
26
|
colors?: Record<string, string>;
|
|
27
|
-
}): JSX.Element;
|
|
27
|
+
}): React.JSX.Element;
|
|
28
28
|
//# sourceMappingURL=stacked-area-chart-card.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"stacked-area-chart-card.d.ts","sourceRoot":"","sources":["../../../../src/react/components/charts/stacked-area-chart-card.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"stacked-area-chart-card.d.ts","sourceRoot":"","sources":["../../../../src/react/components/charts/stacked-area-chart-card.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAO,SAAS,EAAE,MAAM,OAAO,CAAC;AAc5C,OAAO,EAAE,KAAK,cAAc,EAAoC,MAAM,sBAAsB,CAAC;AAG7F,2EAA2E;AAC3E,MAAM,MAAM,cAAc,GAAG;IAAE,KAAK,EAAE,MAAM,CAAA;CAAE,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC,CAAC;AAKjF;;;;;;GAMG;AACH,wBAAgB,oBAAoB,CAAC,EACnC,KAAK,EACL,IAAI,EACJ,MAAM,EACN,KAAK,EACL,MAAY,EACZ,KAAK,EACL,QAAQ,EACR,MAAM,GACP,EAAE;IACD,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,cAAc,EAAE,CAAC;IACvB,+DAA+D;IAC/D,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,+EAA+E;IAC/E,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,qFAAqF;IACrF,QAAQ,CAAC,EAAE,CAAC,SAAS,EAAE,cAAc,KAAK,IAAI,CAAC;IAC/C,sFAAsF;IACtF,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CACjC,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CA0DpB"}
|
|
@@ -31,6 +31,6 @@ export function StackedAreaChartCard({ title, data, series, right, height = 240,
|
|
|
31
31
|
className: 'cursor-pointer',
|
|
32
32
|
}
|
|
33
33
|
: {};
|
|
34
|
-
return (_jsx(ChartCard, { title: title, right: right, height: bodyHeight, children: data.length === 0 || series.length === 0 ? (_jsx(ChartEmptyState, { height: bodyHeight })) : (_jsx(ChartContainer, { config: config, children: _jsxs(AreaChart, { data: data, margin: { top: 4, right: 8, bottom: 0, left: -16 }, ...clickProps, children: [_jsx(CartesianGrid, { vertical: false }), _jsx(XAxis, { dataKey: "label", tickLine: false, minTickGap: 24 }), _jsx(YAxis, { tickLine: false, width:
|
|
34
|
+
return (_jsx(ChartCard, { title: title, right: right, height: bodyHeight, children: data.length === 0 || series.length === 0 ? (_jsx(ChartEmptyState, { height: bodyHeight })) : (_jsx(ChartContainer, { config: config, children: _jsxs(AreaChart, { data: data, margin: { top: 4, right: 8, bottom: 0, left: -16 }, ...clickProps, children: [_jsx(CartesianGrid, { vertical: false }), _jsx(XAxis, { dataKey: "label", tickLine: false, minTickGap: 24 }), _jsx(YAxis, { tickLine: false, width: 52, allowDecimals: false }), _jsx(ChartTooltip, { cursor: { stroke: 'var(--line)' }, content: _jsx(ChartTooltipContent, {}) }), _jsx(ChartLegend, { content: _jsx(ChartLegendContent, { hidden: hidden, onToggle: toggle }) }), series.map((key) => (_jsx(Area, { type: "monotone", dataKey: key, name: key, stackId: "1", stroke: chartColorVar(key), strokeWidth: 1.5, fill: chartColorVar(key), fillOpacity: 0.25, hide: isHidden(key), isAnimationActive: false }, key))), showBrush && _jsx(Brush, { ...chartBrushProps, dataKey: "label" })] }) })) }));
|
|
35
35
|
}
|
|
36
36
|
//# sourceMappingURL=stacked-area-chart-card.js.map
|
|
@@ -7,5 +7,5 @@ export declare function dumpValuePreview(value: unknown): string;
|
|
|
7
7
|
export declare function EntriesTable({ entries, onSelect, }: {
|
|
8
8
|
entries: Entry[];
|
|
9
9
|
onSelect?: (id: string) => void;
|
|
10
|
-
}): JSX.Element;
|
|
10
|
+
}): React.JSX.Element;
|
|
11
11
|
//# sourceMappingURL=entries-table.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"entries-table.d.ts","sourceRoot":"","sources":["../../../src/react/components/entries-table.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,uBAAuB,CAAC;
|
|
1
|
+
{"version":3,"file":"entries-table.d.ts","sourceRoot":"","sources":["../../../src/react/components/entries-table.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,uBAAuB,CAAC;AAQnD,wBAAgB,UAAU,CAAC,KAAK,EAAE,KAAK,GAAG,MAAM,CA4C/C;AAED,8EAA8E;AAC9E,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,OAAO,GAAG,MAAM,CAItD;AAED,wEAAwE;AACxE,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,CASvD;AAED,wBAAgB,YAAY,CAAC,EAC3B,OAAO,EACP,QAAQ,GACT,EAAE;IAAE,OAAO,EAAE,KAAK,EAAE,CAAC;IAAC,QAAQ,CAAC,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAA;CAAE,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CA8E3E"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { Table, TableBody, TableCell, TableHead, TableHeader, TableRow } from '../ui/index.js';
|
|
3
3
|
import { CacheBadge } from './cache-badge.js';
|
|
4
|
+
import { dotForType } from './entry-types.js';
|
|
4
5
|
import { InertiaBadge } from './inertia-badge.js';
|
|
5
6
|
import { isOfficialEventType, officialEventLabel } from './official-event.js';
|
|
6
7
|
import { buildUserActivityHref, findUserTag, userTagId } from './user-tag.js';
|
|
@@ -75,13 +76,13 @@ export function dumpValuePreview(value) {
|
|
|
75
76
|
return text.length > 80 ? `${text.slice(0, 80)}…` : text;
|
|
76
77
|
}
|
|
77
78
|
export function EntriesTable({ entries, onSelect, }) {
|
|
78
|
-
return (_jsxs(Table, { className: "text-left", children: [_jsx(TableHeader, { children: _jsxs(TableRow, { children: [_jsx(TableHead, { className: "
|
|
79
|
+
return (_jsxs(Table, { className: "text-left", children: [_jsx(TableHeader, { children: _jsxs(TableRow, { children: [_jsx(TableHead, { className: "py-2.5 pr-3 pl-4", children: "Time" }), _jsx(TableHead, { className: "px-3", children: "Type" }), _jsx(TableHead, { className: "px-3", children: "Summary" }), _jsx(TableHead, { className: "px-3 text-right", children: "Duration" }), _jsx(TableHead, { className: "hidden pr-4 pl-3 md:table-cell", children: "Tags" })] }) }), _jsx(TableBody, { children: entries.map((entry) => {
|
|
79
80
|
const userTag = findUserTag(entry.tags);
|
|
80
81
|
const otherTags = entry.tags.filter((tag) => tag !== userTag);
|
|
81
82
|
return (_jsxs(TableRow, { onClick: () => onSelect?.(entry.id), onKeyDown: (event) => {
|
|
82
83
|
if (event.key === 'Enter' || event.key === ' ')
|
|
83
84
|
onSelect?.(entry.id);
|
|
84
|
-
}, className: "cursor-pointer hover:bg-
|
|
85
|
+
}, className: "cursor-pointer transition-colors hover:bg-hover", children: [_jsx(TableCell, { className: "py-2 pr-3 pl-4 align-middle font-mono whitespace-nowrap tabular-nums text-faint", children: new Date(entry.createdAt).toLocaleTimeString() }), _jsx(TableCell, { className: "px-3 py-2 align-middle whitespace-nowrap text-fg-2", children: _jsxs("span", { className: "inline-flex items-center gap-1.5", children: [_jsx("span", { className: `size-[7px] shrink-0 rounded-full ${dotForType(entry.type)}`, "aria-hidden": "true" }), entry.type] }) }), _jsx(TableCell, { className: "max-w-md truncate px-3 py-2 align-middle font-mono text-foreground", children: _jsxs("span", { className: "inline-flex items-center gap-1.5", children: [entry.type === 'cache' ? _jsx(CacheBadge, { content: entry.content }) : null, entry.type === 'inertia' ? _jsx(InertiaBadge, { content: entry.content }) : null, _jsx("span", { className: "truncate", children: entryLabel(entry) })] }) }), _jsx(TableCell, { className: "px-3 py-2 text-right align-middle font-mono whitespace-nowrap tabular-nums text-fg-2", children: entry.durationMs != null ? `${entry.durationMs}ms` : '—' }), _jsx(TableCell, { className: "hidden py-2 pr-4 pl-3 align-middle font-mono text-[11px] text-faint md:table-cell", children: _jsxs("span", { className: "inline-flex items-center gap-1.5", children: [entry.traceId !== null && (_jsxs("a", { href: `#/traces/${entry.traceId}`, title: `View trace ${entry.traceId}`, onClick: (event) => event.stopPropagation(), className: "rounded border border-brand-border bg-brand-soft px-1.5 py-0.5 font-mono text-[10px] text-brand hover:bg-panel-2", children: ["trace:", entry.traceId.slice(0, 6)] })), userTag !== null && (_jsx("a", { href: buildUserActivityHref(userTag), title: `View all activity for user ${userTagId(userTag)}`, onClick: (event) => event.stopPropagation(), className: "rounded border border-good/25 bg-good/10 px-1.5 py-0.5 font-mono text-[10px] text-good hover:bg-good/15", children: userTag })), otherTags.length > 0 && _jsx("span", { children: otherTags.join(' ') })] }) })] }, entry.id));
|
|
85
86
|
}) })] }));
|
|
86
87
|
}
|
|
87
88
|
//# sourceMappingURL=entries-table.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"entries-table.js","sourceRoot":"","sources":["../../../src/react/components/entries-table.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,SA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AElH,OAAO,GACN,CACL,EACA,SAAS,CAAC,MAAM,GAAG,CAAC,IAAI,yBAAO,SAAS,CAAC,IAAI,CAAC,GAAG,CAAC,GAAQ,IACtD,GACG,KArDP,KAAK,CAAC,EAAE,CAsDJ,CACZ,CAAC;gBACJ,CAAC,CAAC,GACQ,IACN,CACT,CAAC;AACJ,CAAC"}
|
|
@@ -2,7 +2,7 @@ import type { EntryWithBatch } from '../../client/index.js';
|
|
|
2
2
|
export declare function EntryDetail({ entry, onSelect, }: {
|
|
3
3
|
entry: EntryWithBatch;
|
|
4
4
|
onSelect?: (id: string) => void;
|
|
5
|
-
}): JSX.Element;
|
|
5
|
+
}): React.JSX.Element;
|
|
6
6
|
/** Pretty-print a dump value to JSON, falling back to String() if not serializable. */
|
|
7
7
|
export declare function prettyJson(value: unknown): string;
|
|
8
8
|
//# sourceMappingURL=entry-detail.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"entry-detail.d.ts","sourceRoot":"","sources":["../../../src/react/components/entry-detail.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAkB,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAY5E,wBAAgB,WAAW,CAAC,EAC1B,KAAK,EACL,QAAQ,GACT,EAAE;IAAE,KAAK,EAAE,cAAc,CAAC;IAAC,QAAQ,CAAC,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAA;CAAE,GAAG,GAAG,CAAC,OAAO,
|
|
1
|
+
{"version":3,"file":"entry-detail.d.ts","sourceRoot":"","sources":["../../../src/react/components/entry-detail.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAkB,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAY5E,wBAAgB,WAAW,CAAC,EAC1B,KAAK,EACL,QAAQ,GACT,EAAE;IAAE,KAAK,EAAE,cAAc,CAAC;IAAC,QAAQ,CAAC,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAA;CAAE,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CAkGhF;AAoDD,uFAAuF;AACvF,wBAAgB,UAAU,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,CAMjD"}
|
|
@@ -14,7 +14,7 @@ export function EntryDetail({ entry, onSelect, }) {
|
|
|
14
14
|
const { data: meta } = useMeta();
|
|
15
15
|
const showTimeline = entry.type === 'request' && entry.batch.length > 1;
|
|
16
16
|
const userTag = findUserTag(entry.tags);
|
|
17
|
-
return (_jsxs("div", { className: "grid grid-cols-3 gap-6", children: [_jsxs("section", { className: "col-span-2", children: [_jsxs("div", { className: "mb-2 flex items-center justify-between gap-2", children: [_jsxs("h2", { className: "flex items-center gap-2 text-sm text-brand", children: [entry.type, entry.type === 'cache' ? _jsx(CacheBadge, { content: entry.content }) : null, entry.type === 'inertia' ? _jsx(InertiaBadge, { content: entry.content }) : null] }), _jsx(ExportJsonToolbar, { value: entry, filename: `telescope-entry-${entry.id}.json` })] }), showTimeline ? (_jsxs("div", { className: "mb-4", children: [_jsx("h3", { className: "mb-2 text-
|
|
17
|
+
return (_jsxs("div", { className: "grid grid-cols-3 gap-6", children: [_jsxs("section", { className: "col-span-2", children: [_jsxs("div", { className: "mb-2 flex items-center justify-between gap-2", children: [_jsxs("h2", { className: "flex items-center gap-2 text-sm text-brand", children: [entry.type, entry.type === 'cache' ? _jsx(CacheBadge, { content: entry.content }) : null, entry.type === 'inertia' ? _jsx(InertiaBadge, { content: entry.content }) : null] }), _jsx(ExportJsonToolbar, { value: entry, filename: `telescope-entry-${entry.id}.json` })] }), showTimeline ? (_jsxs("div", { className: "mb-4", children: [_jsx("h3", { className: "mb-2 text-[10px] font-semibold uppercase tracking-[0.12em] text-faint", children: "Timeline" }), _jsx(RequestTimeline, { batch: entry.batch, requestId: entry.id, onSelect: onSelect })] })) : null, entry.type === 'dump' ? (_jsx(DumpBody, { content: entry.content })) : entry.type === 'event' ? (_jsx(EventBody, { content: entry.content })) : entry.type === 'log' ? (_jsx(LogBody, { content: entry.content })) : entry.type === 'model' ? (_jsx(ModelBody, { content: entry.content })) : entry.type === 'redis' ? (_jsx(RedisBody, { content: entry.content })) : entry.type === 'inertia' ? (_jsx(InertiaBody, { content: entry.content })) : entry.type === 'client_exception' ? (_jsxs(_Fragment, { children: [_jsx(ClientExceptionBody, { content: entry.content }), _jsx(DiagnosePanel, { entryId: entry.id, aiEnabled: meta?.ai?.enabled ?? false })] })) : entry.type === 'exception' ? (_jsxs(_Fragment, { children: [_jsx("pre", { className: "overflow-auto rounded bg-panel p-3 text-xs text-foreground", children: JSON.stringify(entry.content, null, 2) }), _jsx(DiagnosePanel, { entryId: entry.id, aiEnabled: meta?.ai?.enabled ?? false })] })) : entry.type === 'request' ? (_jsx(RequestBody, { content: entry.content })) : isOfficialEventType(entry.type) ? (_jsx(OfficialEventBody, { type: entry.type, content: entry.content })) : entry.type === 'query' ? (_jsx(QueryBody, { entryId: entry.id, content: entry.content, explainEnabled: meta?.explainEnabled ?? false })) : (_jsx("pre", { className: "overflow-auto rounded bg-panel p-3 text-xs text-foreground", children: JSON.stringify(entry.content, null, 2) }))] }), _jsxs("aside", { children: [userTag !== null ? (_jsxs("div", { className: "mb-4", children: [_jsx("h3", { className: "mb-2 text-[10px] font-semibold uppercase tracking-[0.12em] text-faint", children: "User" }), _jsx("div", { className: "font-mono text-[11px] text-foreground", children: userTagId(userTag) }), _jsx("a", { href: buildUserActivityHref(userTag), className: "mt-1 inline-block text-[11px] text-brand hover:underline", children: "View all activity for this user" })] })) : null, entry.traceId ? (_jsxs("div", { className: "mb-4", children: [_jsx("h3", { className: "mb-2 text-[10px] font-semibold uppercase tracking-[0.12em] text-faint", children: "Trace" }), _jsx(TraceRow, { traceId: entry.traceId, spanId: entry.spanId, traceLink: meta?.traceLink ?? null })] })) : null, _jsx(RelatedLinks, { entry: entry }), _jsxs("h3", { className: "mb-2 text-[10px] font-semibold uppercase tracking-[0.12em] text-faint", children: ["Batch (", entry.batch.length, ")"] }), _jsx(BatchTimeline, { batch: entry.batch, currentId: entry.id, onSelect: onSelect })] })] }));
|
|
18
18
|
}
|
|
19
19
|
/**
|
|
20
20
|
* Quick navigation from an entry to the things it relates to — the debugging
|
|
@@ -45,7 +45,7 @@ function RelatedLinks({ entry }) {
|
|
|
45
45
|
}
|
|
46
46
|
if (links.length === 0)
|
|
47
47
|
return null;
|
|
48
|
-
return (_jsxs("div", { className: "mb-4", children: [_jsx("h3", { className: "mb-2 text-
|
|
48
|
+
return (_jsxs("div", { className: "mb-4", children: [_jsx("h3", { className: "mb-2 text-[10px] font-semibold uppercase tracking-[0.12em] text-faint", children: "Related" }), _jsx("div", { className: "flex flex-col gap-1", children: links.map((link) => (_jsxs("a", { href: link.href, className: "text-[11px] text-brand hover:underline", children: [link.label, " \u2192"] }, `${link.href}:${link.label}`))) })] }));
|
|
49
49
|
}
|
|
50
50
|
/** Pretty-print a dump value to JSON, falling back to String() if not serializable. */
|
|
51
51
|
export function prettyJson(value) {
|
|
@@ -59,7 +59,7 @@ export function prettyJson(value) {
|
|
|
59
59
|
function DumpBody({ content }) {
|
|
60
60
|
const record = typeof content === 'object' && content !== null ? content : {};
|
|
61
61
|
const label = typeof record.label === 'string' ? record.label : null;
|
|
62
|
-
return (_jsxs("div", { children: [label ? _jsx("h3", { className: "mb-2 font-mono text-sm text-
|
|
62
|
+
return (_jsxs("div", { children: [label ? _jsx("h3", { className: "mb-2 font-mono text-sm text-brand", children: label }) : null, _jsx("pre", { className: "overflow-auto rounded bg-panel p-3 text-xs text-foreground", children: prettyJson(record.value) })] }));
|
|
63
63
|
}
|
|
64
64
|
/** Tailwind text color for a log level badge. */
|
|
65
65
|
function logLevelColor(level) {
|
|
@@ -79,7 +79,7 @@ function EventBody({ content }) {
|
|
|
79
79
|
const record = typeof content === 'object' && content !== null ? content : {};
|
|
80
80
|
const name = typeof record.name === 'string' ? record.name : String(record.name ?? '');
|
|
81
81
|
const listenerCount = typeof record.listenerCount === 'number' ? record.listenerCount : null;
|
|
82
|
-
return (_jsxs("div", { children: [_jsxs("h3", { className: "mb-2 flex items-center gap-2 font-mono text-sm text-
|
|
82
|
+
return (_jsxs("div", { children: [_jsxs("h3", { className: "mb-2 flex items-center gap-2 font-mono text-sm text-violet", children: [name, listenerCount !== null ? (_jsxs("span", { className: "rounded bg-panel px-1.5 py-0.5 text-[10px] text-muted-foreground", children: [listenerCount, " listener", listenerCount === 1 ? '' : 's'] })) : null] }), _jsx("pre", { className: "overflow-auto rounded bg-panel p-3 text-xs text-foreground", children: prettyJson(record.payload) })] }));
|
|
83
83
|
}
|
|
84
84
|
/** Tailwind text color for a model action badge. */
|
|
85
85
|
function modelActionColor(action) {
|
|
@@ -99,7 +99,7 @@ function ModelBody({ content }) {
|
|
|
99
99
|
const action = typeof record.action === 'string' ? record.action : 'update';
|
|
100
100
|
const entity = typeof record.entity === 'string' ? record.entity : String(record.entity ?? '');
|
|
101
101
|
const id = record.id === null || record.id === undefined ? null : String(record.id);
|
|
102
|
-
return (_jsxs("div", { children: [_jsxs("h3", { className: "mb-2 flex items-center gap-2 font-mono text-sm text-
|
|
102
|
+
return (_jsxs("div", { children: [_jsxs("h3", { className: "mb-2 flex items-center gap-2 font-mono text-sm text-good", children: [_jsx("span", { className: `rounded bg-panel px-1.5 py-0.5 text-[10px] uppercase ${modelActionColor(action)}`, children: action }), _jsx("span", { children: entity }), id !== null ? _jsxs("span", { className: "text-muted-foreground", children: ["#", id] }) : null] }), _jsx("pre", { className: "overflow-auto rounded bg-panel p-3 text-xs text-foreground", children: prettyJson(record.changes) })] }));
|
|
103
103
|
}
|
|
104
104
|
function RedisBody({ content }) {
|
|
105
105
|
const record = typeof content === 'object' && content !== null ? content : {};
|
|
@@ -113,7 +113,7 @@ function RedisBody({ content }) {
|
|
|
113
113
|
* empty fence. The orange accent matches the `client_exception` type dot.
|
|
114
114
|
*/
|
|
115
115
|
function StackBlock({ label, value }) {
|
|
116
|
-
return (_jsxs("div", { className: "mb-4", children: [_jsx("h3", { className: "mb-2 text-
|
|
116
|
+
return (_jsxs("div", { className: "mb-4", children: [_jsx("h3", { className: "mb-2 text-[10px] font-semibold uppercase tracking-[0.12em] text-faint", children: label }), _jsx("pre", { className: "overflow-auto rounded bg-panel p-3 text-xs leading-relaxed text-foreground", children: value })] }));
|
|
117
117
|
}
|
|
118
118
|
/**
|
|
119
119
|
* Renders a browser-reported `client_exception`: the name + message header,
|
|
@@ -131,7 +131,7 @@ function ClientExceptionBody({ content }) {
|
|
|
131
131
|
const release = typeof record.release === 'string' ? record.release : null;
|
|
132
132
|
const stack = typeof record.stack === 'string' ? record.stack : null;
|
|
133
133
|
const componentStack = typeof record.componentStack === 'string' ? record.componentStack : null;
|
|
134
|
-
return (_jsxs("div", { children: [_jsxs("h3", { className: "mb-3 flex flex-wrap items-center gap-2 font-mono text-sm text-
|
|
134
|
+
return (_jsxs("div", { children: [_jsxs("h3", { className: "mb-3 flex flex-wrap items-center gap-2 font-mono text-sm text-warn", children: [name ? (_jsx("span", { className: "rounded bg-panel px-1.5 py-0.5 text-[10px] uppercase", children: name })) : null, _jsx("span", { className: "text-foreground", children: message }), release ? _jsx("span", { className: "text-[10px] text-muted-foreground", children: release }) : null] }), url ? (_jsxs("div", { className: "mb-4", children: [_jsx("h3", { className: "mb-2 text-[10px] font-semibold uppercase tracking-[0.12em] text-faint", children: "URL" }), _jsx("div", { className: "break-all font-mono text-xs text-foreground", children: url })] })) : null, userAgent ? (_jsxs("div", { className: "mb-4", children: [_jsx("h3", { className: "mb-2 text-[10px] font-semibold uppercase tracking-[0.12em] text-faint", children: "User agent" }), _jsx("div", { className: "break-all font-mono text-[11px] text-muted-foreground", children: userAgent })] })) : null, stack ? _jsx(StackBlock, { label: "Stack", value: stack }) : null, componentStack ? _jsx(StackBlock, { label: "Component stack", value: componentStack }) : null, hasContent(record.extra) ? (_jsxs("div", { className: "mb-4", children: [_jsx("h3", { className: "mb-2 text-[10px] font-semibold uppercase tracking-[0.12em] text-faint", children: "Extra" }), _jsx("pre", { className: "overflow-auto rounded bg-panel p-3 text-xs text-foreground", children: prettyJson(record.extra) })] })) : null] }));
|
|
135
135
|
}
|
|
136
136
|
/** True when a value is a non-null object or non-empty array (worth rendering). */
|
|
137
137
|
function hasContent(value) {
|
|
@@ -145,7 +145,7 @@ function hasContent(value) {
|
|
|
145
145
|
}
|
|
146
146
|
function RequestHeaders({ headers }) {
|
|
147
147
|
const entries = Object.entries(headers);
|
|
148
|
-
return (_jsxs("details", { className: "mb-4", children: [_jsxs("summary", { className: "cursor-pointer text-
|
|
148
|
+
return (_jsxs("details", { className: "mb-4", children: [_jsxs("summary", { className: "cursor-pointer text-[10px] font-semibold uppercase tracking-[0.12em] text-faint", children: ["Headers (", entries.length, ")"] }), _jsx("dl", { className: "mt-2 grid grid-cols-[max-content_1fr] gap-x-3 gap-y-1 rounded bg-panel p-3 text-xs", children: entries.map(([key, value]) => (_jsxs("div", { className: "contents", children: [_jsx("dt", { className: "font-mono text-muted-foreground", children: key }), _jsx("dd", { className: "break-all font-mono text-foreground", children: typeof value === 'string' ? value : prettyJson(value) })] }, key))) })] }));
|
|
149
149
|
}
|
|
150
150
|
function RequestBody({ content }) {
|
|
151
151
|
const record = typeof content === 'object' && content !== null ? content : {};
|
|
@@ -157,7 +157,7 @@ function RequestBody({ content }) {
|
|
|
157
157
|
const statusCode = typeof record.statusCode === 'number' ? record.statusCode : null;
|
|
158
158
|
const ip = typeof record.ip === 'string' ? record.ip : null;
|
|
159
159
|
const hasUser = 'user' in record && record.user !== null && record.user !== undefined;
|
|
160
|
-
return (_jsxs("div", { children: [_jsxs("h3", { className: "mb-3 flex items-center gap-2 font-mono text-sm text-brand", children: [_jsx("span", { className: "rounded bg-panel px-1.5 py-0.5 text-[10px] uppercase", children: method }), _jsx("span", { className: "text-foreground", children: uri }), statusCode !== null ? (_jsx("span", { className: "rounded bg-panel px-1.5 py-0.5 text-[10px] text-muted-foreground", children: statusCode })) : null, ip ? _jsx("span", { className: "text-[10px] text-muted-foreground", children: ip }) : null] }), _jsx(RequestHeaders, { headers: headers }), _jsx("h3", { className: "mb-2 text-
|
|
160
|
+
return (_jsxs("div", { children: [_jsxs("h3", { className: "mb-3 flex items-center gap-2 font-mono text-sm text-brand", children: [_jsx("span", { className: "rounded bg-panel px-1.5 py-0.5 text-[10px] uppercase", children: method }), _jsx("span", { className: "text-foreground", children: uri }), statusCode !== null ? (_jsx("span", { className: "rounded bg-panel px-1.5 py-0.5 text-[10px] text-muted-foreground", children: statusCode })) : null, ip ? _jsx("span", { className: "text-[10px] text-muted-foreground", children: ip }) : null] }), _jsx(RequestHeaders, { headers: headers }), _jsx("h3", { className: "mb-2 text-[10px] font-semibold uppercase tracking-[0.12em] text-faint", children: "Payload" }), hasContent(record.payload) ? (_jsx("pre", { className: "mb-4 overflow-auto rounded bg-panel p-3 text-xs text-foreground", children: prettyJson(record.payload) })) : (_jsx("p", { className: "mb-4 text-xs text-muted-foreground", children: "No payload" })), _jsx("h3", { className: "mb-2 text-[10px] font-semibold uppercase tracking-[0.12em] text-faint", children: "User" }), hasUser ? (_jsx("pre", { className: "overflow-auto rounded bg-panel p-3 text-xs text-foreground", children: prettyJson(record.user) })) : (_jsx("p", { className: "text-xs text-muted-foreground", children: "anonymous" }))] }));
|
|
161
161
|
}
|
|
162
162
|
function QueryBody({ entryId, content, explainEnabled, }) {
|
|
163
163
|
const record = typeof content === 'object' && content !== null ? content : {};
|
|
@@ -174,7 +174,7 @@ function QueryBody({ entryId, content, explainEnabled, }) {
|
|
|
174
174
|
// expected 404/503 outcomes into a non-throwing `{ ok: false }` result.
|
|
175
175
|
}
|
|
176
176
|
}
|
|
177
|
-
return (_jsxs("div", { children: [_jsxs("div", { className: "mb-2 flex items-center justify-between gap-2", children: [_jsxs("h3", { className: "flex items-center gap-2 font-mono text-sm text-
|
|
177
|
+
return (_jsxs("div", { children: [_jsxs("div", { className: "mb-2 flex items-center justify-between gap-2", children: [_jsxs("h3", { className: "flex items-center gap-2 font-mono text-sm text-info", children: ["query", slow ? (_jsx("span", { className: "rounded bg-panel px-1.5 py-0.5 text-[10px] text-warn", children: "slow" })) : null] }), explainEnabled ? (_jsx("button", { type: "button", onClick: onExplain, disabled: explain.isPending, className: "rounded border border-line px-2 py-1 text-[11px] text-foreground hover:border-brand hover:text-brand disabled:cursor-not-allowed disabled:opacity-50", children: explain.isPending ? 'Explaining…' : 'Explain' })) : null] }), _jsx("pre", { className: "overflow-auto rounded bg-panel p-3 text-xs text-foreground", children: sql }), Array.isArray(record.bindings) && record.bindings.length > 0 ? (_jsxs(_Fragment, { children: [_jsx("h3", { className: "mt-3 mb-2 text-[10px] font-semibold uppercase tracking-[0.12em] text-faint", children: "Bindings" }), _jsx("pre", { className: "overflow-auto rounded bg-panel p-3 text-xs text-foreground", children: prettyJson(record.bindings) })] })) : null, explain.isPending ? (_jsx("p", { className: "mt-3 text-xs text-muted-foreground", children: "Running EXPLAIN\u2026" })) : result === undefined ? null : result.ok ? (_jsxs(_Fragment, { children: [_jsx("h3", { className: "mt-3 mb-2 text-[10px] font-semibold uppercase tracking-[0.12em] text-faint", children: "Query plan" }), _jsx("pre", { className: "overflow-auto rounded bg-panel p-3 text-xs text-foreground", children: prettyJson(result.plan) })] })) : (_jsx("p", { className: "mt-3 rounded bg-panel p-3 text-xs text-bad", children: result.message }))] }));
|
|
178
178
|
}
|
|
179
179
|
function LogBody({ content }) {
|
|
180
180
|
const record = typeof content === 'object' && content !== null ? content : {};
|
|
@@ -234,7 +234,7 @@ function DiagnosePanel({ entryId, aiEnabled, }) {
|
|
|
234
234
|
// Subtle initial-load state: still resolving the cache lookup and the user
|
|
235
235
|
// hasn't clicked yet. Avoids flashing the button before a cached result lands.
|
|
236
236
|
const checkingCache = ranResult === null && cachedQuery.isLoading;
|
|
237
|
-
return (_jsxs("div", { className: "mt-4 rounded border border-line p-3", children: [_jsxs("div", { className: "mb-2 flex items-center justify-between gap-2", children: [_jsxs("h3", { className: "flex items-center gap-2 text-
|
|
237
|
+
return (_jsxs("div", { className: "mt-4 rounded border border-line p-3", children: [_jsxs("div", { className: "mb-2 flex items-center justify-between gap-2", children: [_jsxs("h3", { className: "flex items-center gap-2 text-[10px] font-semibold uppercase tracking-[0.12em] text-faint", children: ["AI diagnosis", isCached ? (_jsx("span", { className: "rounded bg-panel px-1.5 py-0.5 text-[10px] normal-case text-warn", children: "cached" })) : null] }), _jsx("div", { className: "flex items-center gap-2", children: checkingCache ? null : hasResult ? (_jsx("button", { type: "button", onClick: () => run(true), disabled: diagnose.isPending, className: "rounded border border-line px-2 py-1 text-[11px] text-foreground hover:border-brand hover:text-brand disabled:cursor-not-allowed disabled:opacity-50", children: diagnose.isPending ? 'Re-running…' : 'Re-run' })) : (_jsx("button", { type: "button", onClick: () => run(false), disabled: diagnose.isPending, className: "rounded border border-line px-2 py-1 text-[11px] text-brand hover:border-brand disabled:cursor-not-allowed disabled:opacity-50", children: diagnose.isPending ? 'Diagnosing…' : 'Diagnose with AI' })) })] }), diagnose.isPending ? (_jsx("p", { className: "text-xs text-muted-foreground", children: "Asking the model\u2026" })) : checkingCache ? (_jsx("p", { className: "text-xs text-muted-foreground", children: "Checking for an existing diagnosis\u2026" })) : ranResult !== null ? (ranResult.ok ? (_jsx(Markdown, { source: ranResult.markdown })) : (_jsx("p", { className: "rounded bg-panel p-3 text-xs text-bad", children: ranResult.message }))) : cachedHit !== null ? (_jsx(Markdown, { source: cachedHit.markdown })) : (_jsx("p", { className: "text-xs text-muted-foreground", children: "Get an AI-generated probable cause, where to look, and a suggested fix." }))] }));
|
|
238
238
|
}
|
|
239
239
|
/** Parse the (small, fixed-shape) markdown into a typed block list with stable
|
|
240
240
|
* keys, so rendering never relies on array indices as React keys. */
|