@workflow/web 5.0.0-beta.6 → 5.0.0-beta.7

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 (21) hide show
  1. package/build/client/assets/{encryption-DU49MAQV.js → encryption-C69WMRfh.js} +11 -5
  2. package/build/client/assets/{highlighted-body-B3W2YXNL-BZLzBNxn.js → highlighted-body-B3W2YXNL-Cq4feDhL.js} +1 -1
  3. package/build/client/assets/{home-DmK2qlF4.js → home-B-DWbULo.js} +2 -2
  4. package/build/client/assets/{manifest-f8f46e3c.js → manifest-21016363.js} +1 -1
  5. package/build/client/assets/{mermaid-3ZIDBTTL-D3hhpLut.js → mermaid-3ZIDBTTL-PK-k2mDG.js} +188 -102
  6. package/build/client/assets/root-B527kgKt.css +1 -0
  7. package/build/client/assets/{root-DCSDR-Tx.js → root-DDT0W3fG.js} +1 -1
  8. package/build/client/assets/{run-detail-qu2t8u4x.js → run-detail-COyTZwjr.js} +30 -6
  9. package/build/client/assets/server-build-BUmla00D.css +1 -0
  10. package/build/client/assets/{workflow-graph-viewer-Bl8eU-PY.js → workflow-graph-viewer-CVUKAMV1.js} +1 -1
  11. package/build/server/assets/{app-C_Lhht8k.js → app-CASBD2Jz.js} +1 -1
  12. package/build/server/assets/{highlighted-body-B3W2YXNL-DOOlKIMb.js → highlighted-body-B3W2YXNL-DtYGrm0G.js} +2 -2
  13. package/build/server/assets/{index-CRYPN_tt.js → index-B_Gtun0B.js} +3 -3
  14. package/build/server/assets/{mermaid-3ZIDBTTL-CglyhPap.js → mermaid-3ZIDBTTL-D37Y2lwn.js} +2 -2
  15. package/build/server/assets/{server-build-CeQwCbX_.js → server-build-BZS28Q46.js} +1165 -973
  16. package/build/server/assets/{token-CZpVopko.js → token-98GkKm4t.js} +2 -2
  17. package/build/server/assets/{token-util-DUvMx9Gj.js → token-util-CHxt50WW.js} +2 -2
  18. package/build/server/index.js +1 -1
  19. package/package.json +6 -6
  20. package/build/client/assets/root-5XHFuftH.css +0 -1
  21. package/build/client/assets/server-build-olrGumlh.css +0 -1
@@ -3,14 +3,20 @@ import "./index-BsV8i_Jn.js";
3
3
  const NONCE_LENGTH = 12;
4
4
  const TAG_LENGTH = 128;
5
5
  const KEY_LENGTH = 32;
6
- async function importKey(raw) {
6
+ async function importKey(raw, usages = ["encrypt", "decrypt"]) {
7
7
  if (raw.byteLength !== KEY_LENGTH) {
8
8
  throw new WorkflowRuntimeError(`Encryption key must be exactly ${KEY_LENGTH} bytes, got ${raw.byteLength}`);
9
9
  }
10
- return globalThis.crypto.subtle.importKey("raw", raw, "AES-GCM", false, [
11
- "encrypt",
12
- "decrypt"
13
- ]);
10
+ return globalThis.crypto.subtle.importKey(
11
+ "raw",
12
+ raw,
13
+ "AES-GCM",
14
+ false,
15
+ // `KeyUsage` is a DOM-lib type that's not in scope under `es2022`.
16
+ // The `ReadonlyArray<'encrypt' | 'decrypt'>` parameter type matches
17
+ // a strict subset of `KeyUsage[]`, so this cast is sound.
18
+ usages
19
+ );
14
20
  }
15
21
  async function decrypt(key, data) {
16
22
  const minLength = NONCE_LENGTH + TAG_LENGTH / 8;
@@ -1,4 +1,4 @@
1
- import { R, K as Ks, Q as Qe } from "./mermaid-3ZIDBTTL-D3hhpLut.js";
1
+ import { R, K as Ks, Q as Qe } from "./mermaid-3ZIDBTTL-PK-k2mDG.js";
2
2
  import { r as reactExports, j as jsxRuntimeExports } from "./index-BsV8i_Jn.js";
3
3
  var L = ({ code: s, language: t, raw: e, className: n, ...d$1 }) => {
4
4
  let { shikiTheme: l } = reactExports.useContext(R), o = Ks(), [m, i] = reactExports.useState(e);
@@ -1,6 +1,6 @@
1
1
  import { r as reactExports, D as ReactDOM, j as jsxRuntimeExports, A as Link, f as reactDomExports, C as useSearchParams, B as useNavigate, G as useLocation, w as withComponentProps } from "./index-BsV8i_Jn.js";
2
- import { R as ResolveHookModal, S as Send, a as Skeleton, u as unwrapOrThrow, W as WorkflowWebAPIError, b as RelativeTime, A as Alert, C as CircleAlert, c as AlertTitle, d as AlertDescription, g as getErrorMessage, e as CopyableText, D as DropdownMenu, f as DropdownMenuTrigger, E as Ellipsis, h as DropdownMenuContent, i as DropdownMenuItem, j as ChevronRight, r as resumeHook, k as createCollection, l as hideOthers, m as ReactRemoveScroll, n as useDirection, o as ChevronDown, p as Check, X, q as useControllableState$1, P as Primitive$1, s as composeEventHandlers$1, t as Presence, v as useSize, w as createContextScope$1, x as cancelRun, y as reenqueueRun, z as parseWorkflowName, B as StatusBadge, Z as Zap, F as CircleX, G as RunActionsDropdownItems, H as unwrapServerActionResult, I as WorkflowGraphViewer, T as Tabs, J as TabsList, K as TabsTrigger, L as TabsContent, M as ErrorBoundary } from "./workflow-graph-viewer-Bl8eU-PY.js";
3
- import { g as useLayoutEffect2, P as Primitive, c as createLucideIcon, h as useToast, d as cn, D as DEFAULT_PAGE_SIZE, i as fetchRuns, j as fetchHooks, k as getPaginationDisplay, T as Tooltip, a as TooltipTrigger, B as Button, b as TooltipContent, l as fetchEvents, m as useCallbackRef, n as useComposedRefs, A as Anchor, o as composeEventHandlers, p as useId, q as createPopperScope, s as DismissableLayer, v as createContextScope, w as createSlot, C as Content$1, x as useControllableState, y as Root2$1, V as VISUALLY_HIDDEN_STYLES, z as Arrow, E as useComposedRefs$1, u as useServerConfig, t as toast, L as LoaderCircle, F as fetchRun, G as cva, H as Presence$1, I as createContext2, J as fetchWorkflowsManifest } from "./mermaid-3ZIDBTTL-D3hhpLut.js";
2
+ import { R as ResolveHookModal, S as Send, a as Skeleton, u as unwrapOrThrow, W as WorkflowWebAPIError, b as RelativeTime, A as Alert, C as CircleAlert, c as AlertTitle, d as AlertDescription, g as getErrorMessage, e as CopyableText, D as DropdownMenu, f as DropdownMenuTrigger, E as Ellipsis, h as DropdownMenuContent, i as DropdownMenuItem, j as ChevronRight, r as resumeHook, k as createCollection, l as hideOthers, m as ReactRemoveScroll, n as useDirection, o as ChevronDown, p as Check, X, q as useControllableState$1, P as Primitive$1, s as composeEventHandlers$1, t as Presence, v as useSize, w as createContextScope$1, x as cancelRun, y as reenqueueRun, z as parseWorkflowName, B as StatusBadge, Z as Zap, F as CircleX, G as RunActionsDropdownItems, H as unwrapServerActionResult, I as WorkflowGraphViewer, T as Tabs, J as TabsList, K as TabsTrigger, L as TabsContent, M as ErrorBoundary } from "./workflow-graph-viewer-CVUKAMV1.js";
3
+ import { g as useLayoutEffect2, P as Primitive, c as createLucideIcon, h as useToast, d as cn, D as DEFAULT_PAGE_SIZE, i as fetchRuns, j as fetchHooks, k as getPaginationDisplay, T as Tooltip, a as TooltipTrigger, B as Button, b as TooltipContent, l as fetchEvents, m as useCallbackRef, n as useComposedRefs, A as Anchor, o as composeEventHandlers, p as useId, q as createPopperScope, s as DismissableLayer, v as createContextScope, w as createSlot, C as Content$1, x as useControllableState, y as Root2$1, V as VISUALLY_HIDDEN_STYLES, z as Arrow, E as useComposedRefs$1, u as useServerConfig, t as toast, L as LoaderCircle, F as fetchRun, G as cva, H as Presence$1, I as createContext2, J as fetchWorkflowsManifest } from "./mermaid-3ZIDBTTL-PK-k2mDG.js";
4
4
  import "./index-Byi8AWfe.js";
5
5
  var PORTAL_NAME$2 = "Portal";
6
6
  var Portal$2 = reactExports.forwardRef((props, forwardedRef) => {
@@ -1 +1 @@
1
- window.__reactRouterManifest={"entry":{"module":"/assets/entry.client-DtOpLtMQ.js","imports":["/assets/index-BsV8i_Jn.js"],"css":[]},"routes":{"root":{"id":"root","path":"","hasAction":true,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasClientMiddleware":false,"hasDefaultExport":true,"hasErrorBoundary":true,"module":"/assets/root-DCSDR-Tx.js","imports":["/assets/index-BsV8i_Jn.js","/assets/mermaid-3ZIDBTTL-D3hhpLut.js"],"css":["/assets/root-5XHFuftH.css","/assets/mermaid-3ZIDBTTL-DKxHcEOp.css"]},"routes/home":{"id":"routes/home","parentId":"root","index":true,"hasAction":false,"hasLoader":false,"hasClientAction":false,"hasClientLoader":false,"hasClientMiddleware":false,"hasDefaultExport":true,"hasErrorBoundary":false,"module":"/assets/home-DmK2qlF4.js","imports":["/assets/index-BsV8i_Jn.js","/assets/workflow-graph-viewer-Bl8eU-PY.js","/assets/mermaid-3ZIDBTTL-D3hhpLut.js","/assets/index-Byi8AWfe.js"],"css":["/assets/workflow-graph-viewer-DnlNuQQH.css","/assets/mermaid-3ZIDBTTL-DKxHcEOp.css"]},"routes/run-detail":{"id":"routes/run-detail","parentId":"root","path":"run/:runId","hasAction":false,"hasLoader":false,"hasClientAction":false,"hasClientLoader":false,"hasClientMiddleware":false,"hasDefaultExport":true,"hasErrorBoundary":false,"module":"/assets/run-detail-qu2t8u4x.js","imports":["/assets/index-BsV8i_Jn.js","/assets/workflow-graph-viewer-Bl8eU-PY.js","/assets/mermaid-3ZIDBTTL-D3hhpLut.js","/assets/encryption-DU49MAQV.js","/assets/index-Byi8AWfe.js"],"css":["/assets/workflow-graph-viewer-DnlNuQQH.css","/assets/mermaid-3ZIDBTTL-DKxHcEOp.css"]},"routes/api.rpc":{"id":"routes/api.rpc","parentId":"root","path":"api/rpc","hasAction":true,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasClientMiddleware":false,"hasDefaultExport":false,"hasErrorBoundary":false,"module":"/assets/api.rpc-l0sNRNKZ.js","imports":[],"css":[]},"routes/api.stream.$streamId":{"id":"routes/api.stream.$streamId","parentId":"root","path":"api/stream/:streamId","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasClientMiddleware":false,"hasDefaultExport":false,"hasErrorBoundary":false,"module":"/assets/api.stream._streamId-l0sNRNKZ.js","imports":[],"css":[]}},"url":"/assets/manifest-f8f46e3c.js","version":"f8f46e3c"};
1
+ window.__reactRouterManifest={"entry":{"module":"/assets/entry.client-DtOpLtMQ.js","imports":["/assets/index-BsV8i_Jn.js"],"css":[]},"routes":{"root":{"id":"root","path":"","hasAction":true,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasClientMiddleware":false,"hasDefaultExport":true,"hasErrorBoundary":true,"module":"/assets/root-DDT0W3fG.js","imports":["/assets/index-BsV8i_Jn.js","/assets/mermaid-3ZIDBTTL-PK-k2mDG.js"],"css":["/assets/root-B527kgKt.css","/assets/mermaid-3ZIDBTTL-DKxHcEOp.css"]},"routes/home":{"id":"routes/home","parentId":"root","index":true,"hasAction":false,"hasLoader":false,"hasClientAction":false,"hasClientLoader":false,"hasClientMiddleware":false,"hasDefaultExport":true,"hasErrorBoundary":false,"module":"/assets/home-B-DWbULo.js","imports":["/assets/index-BsV8i_Jn.js","/assets/workflow-graph-viewer-CVUKAMV1.js","/assets/mermaid-3ZIDBTTL-PK-k2mDG.js","/assets/index-Byi8AWfe.js"],"css":["/assets/workflow-graph-viewer-DnlNuQQH.css","/assets/mermaid-3ZIDBTTL-DKxHcEOp.css"]},"routes/run-detail":{"id":"routes/run-detail","parentId":"root","path":"run/:runId","hasAction":false,"hasLoader":false,"hasClientAction":false,"hasClientLoader":false,"hasClientMiddleware":false,"hasDefaultExport":true,"hasErrorBoundary":false,"module":"/assets/run-detail-COyTZwjr.js","imports":["/assets/index-BsV8i_Jn.js","/assets/workflow-graph-viewer-CVUKAMV1.js","/assets/mermaid-3ZIDBTTL-PK-k2mDG.js","/assets/encryption-C69WMRfh.js","/assets/index-Byi8AWfe.js"],"css":["/assets/workflow-graph-viewer-DnlNuQQH.css","/assets/mermaid-3ZIDBTTL-DKxHcEOp.css"]},"routes/api.rpc":{"id":"routes/api.rpc","parentId":"root","path":"api/rpc","hasAction":true,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasClientMiddleware":false,"hasDefaultExport":false,"hasErrorBoundary":false,"module":"/assets/api.rpc-l0sNRNKZ.js","imports":[],"css":[]},"routes/api.stream.$streamId":{"id":"routes/api.stream.$streamId","parentId":"root","path":"api/stream/:streamId","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasClientMiddleware":false,"hasDefaultExport":false,"hasErrorBoundary":false,"module":"/assets/api.stream._streamId-l0sNRNKZ.js","imports":[],"css":[]}},"url":"/assets/manifest-21016363.js","version":"21016363"};
@@ -1,4 +1,4 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/encryption-DU49MAQV.js","assets/index-Byi8AWfe.js","assets/index-BsV8i_Jn.js","assets/highlighted-body-B3W2YXNL-BZLzBNxn.js"])))=>i.map(i=>d[i]);
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/encryption-C69WMRfh.js","assets/index-Byi8AWfe.js","assets/index-BsV8i_Jn.js","assets/highlighted-body-B3W2YXNL-Cq4feDhL.js"])))=>i.map(i=>d[i]);
2
2
  var __defProp = Object.defineProperty;
3
3
  var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
4
4
  var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
@@ -10359,7 +10359,7 @@ function hydrateData(value, revivers) {
10359
10359
  async function hydrateDataWithKey(value, revivers, key) {
10360
10360
  if (value instanceof Uint8Array && isEncryptedData(value) && key) {
10361
10361
  const { decrypt } = await __vitePreload(async () => {
10362
- const { decrypt: decrypt2 } = await import("./encryption-DU49MAQV.js");
10362
+ const { decrypt: decrypt2 } = await import("./encryption-C69WMRfh.js");
10363
10363
  return { decrypt: decrypt2 };
10364
10364
  }, true ? __vite__mapDeps([0,1,2]) : void 0);
10365
10365
  const { payload } = decodeFormatPrefix(value);
@@ -15360,6 +15360,7 @@ const StepCompletedEventSchema = BaseEventSchema.extend({
15360
15360
  eventType: literal("step_completed"),
15361
15361
  correlationId: string$2(),
15362
15362
  eventData: object({
15363
+ stepName: string$2().optional(),
15363
15364
  result: SerializedDataSchema
15364
15365
  })
15365
15366
  });
@@ -15367,6 +15368,7 @@ const StepFailedEventSchema = BaseEventSchema.extend({
15367
15368
  eventType: literal("step_failed"),
15368
15369
  correlationId: string$2(),
15369
15370
  eventData: object({
15371
+ stepName: string$2().optional(),
15370
15372
  // The thrown value, serialized via the workflow serialization pipeline.
15371
15373
  // Can be any JavaScript value (string, number, object, Error, etc.)
15372
15374
  error: SerializedDataSchema
@@ -15376,6 +15378,7 @@ const StepRetryingEventSchema = BaseEventSchema.extend({
15376
15378
  eventType: literal("step_retrying"),
15377
15379
  correlationId: string$2(),
15378
15380
  eventData: object({
15381
+ stepName: string$2().optional(),
15379
15382
  // The thrown value, serialized via the workflow serialization pipeline.
15380
15383
  // Can be any JavaScript value (string, number, object, Error, etc.)
15381
15384
  error: SerializedDataSchema,
@@ -15386,6 +15389,7 @@ const StepStartedEventSchema = BaseEventSchema.extend({
15386
15389
  eventType: literal("step_started"),
15387
15390
  correlationId: string$2(),
15388
15391
  eventData: object({
15392
+ stepName: string$2().optional(),
15389
15393
  attempt: number$2().optional()
15390
15394
  }).optional()
15391
15395
  });
@@ -15411,12 +15415,16 @@ const HookReceivedEventSchema = BaseEventSchema.extend({
15411
15415
  eventType: literal("hook_received"),
15412
15416
  correlationId: string$2(),
15413
15417
  eventData: object({
15418
+ token: string$2().optional(),
15414
15419
  payload: SerializedDataSchema
15415
15420
  })
15416
15421
  });
15417
15422
  const HookDisposedEventSchema = BaseEventSchema.extend({
15418
15423
  eventType: literal("hook_disposed"),
15419
- correlationId: string$2()
15424
+ correlationId: string$2(),
15425
+ eventData: object({
15426
+ token: string$2().optional()
15427
+ }).optional()
15420
15428
  });
15421
15429
  const HookConflictEventSchema = BaseEventSchema.extend({
15422
15430
  eventType: literal("hook_conflict"),
@@ -15437,7 +15445,10 @@ const WaitCreatedEventSchema = BaseEventSchema.extend({
15437
15445
  });
15438
15446
  const WaitCompletedEventSchema = BaseEventSchema.extend({
15439
15447
  eventType: literal("wait_completed"),
15440
- correlationId: string$2()
15448
+ correlationId: string$2(),
15449
+ eventData: object({
15450
+ resumeAt: date().optional()
15451
+ }).optional()
15441
15452
  });
15442
15453
  const RunCreatedEventSchema = BaseEventSchema.extend({
15443
15454
  eventType: literal("run_created"),
@@ -15689,7 +15700,7 @@ object({
15689
15700
  message: string$2(),
15690
15701
  stack: string$2().optional(),
15691
15702
  code: string$2().optional()
15692
- // Populated with RunErrorCode values (USER_ERROR, RUNTIME_ERROR) for run_failed events
15703
+ // Populated with RunErrorCode values (USER_ERROR, RUNTIME_ERROR, etc.) for run_failed events
15693
15704
  });
15694
15705
  const StepStatusSchema = _enum([
15695
15706
  "pending",
@@ -16015,7 +16026,7 @@ async function hydrateResourceIOWithKey(resource, key) {
16015
16026
  return { hydrateDataWithKey: hydrateDataWithKey3 };
16016
16027
  }, true ? void 0 : void 0);
16017
16028
  const { importKey } = await __vitePreload(async () => {
16018
- const { importKey: importKey2 } = await import("./encryption-DU49MAQV.js");
16029
+ const { importKey: importKey2 } = await import("./encryption-C69WMRfh.js");
16019
16030
  return { importKey: importKey2 };
16020
16031
  }, true ? __vite__mapDeps([0,1,2]) : void 0);
16021
16032
  const cryptoKey = await importKey(key);
@@ -43147,7 +43158,7 @@ var tn = f("block", "before:content-[counter(line)]", "before:inline-block", "be
43147
43158
  var et = ({ className: e, language: t, style: o, isIncomplete: n, ...s2 }) => jsxRuntimeExports.jsx("div", { className: f("my-4 flex w-full flex-col gap-2 rounded-xl border border-border bg-sidebar p-2", e), "data-incomplete": n || void 0, "data-language": t, "data-streamdown": "code-block", style: { contentVisibility: "auto", containIntrinsicSize: "auto 200px", ...o }, ...s2 });
43148
43159
  var Se = reactExports.createContext({ code: "" }), de = () => reactExports.useContext(Se);
43149
43160
  var ot = ({ language: e }) => jsxRuntimeExports.jsx("div", { className: "flex h-8 items-center text-muted-foreground text-xs", "data-language": e, "data-streamdown": "code-block-header", children: jsxRuntimeExports.jsx("span", { className: "ml-1 font-mono lowercase", children: e }) });
43150
- var cn$1 = /\n+$/, dn = reactExports.lazy(() => __vitePreload(() => import("./highlighted-body-B3W2YXNL-BZLzBNxn.js"), true ? __vite__mapDeps([3,2]) : void 0).then((e) => ({ default: e.HighlightedCodeBlockBody }))), rt = ({ code: e, language: t, className: o, children: n, isIncomplete: s2 = false, ...r2 }) => {
43161
+ var cn$1 = /\n+$/, dn = reactExports.lazy(() => __vitePreload(() => import("./highlighted-body-B3W2YXNL-Cq4feDhL.js"), true ? __vite__mapDeps([3,2]) : void 0).then((e) => ({ default: e.HighlightedCodeBlockBody }))), rt = ({ code: e, language: t, className: o, children: n, isIncomplete: s2 = false, ...r2 }) => {
43151
43162
  let i = reactExports.useMemo(() => e.replace(cn$1, ""), [e]), c = reactExports.useMemo(() => ({ bg: "transparent", fg: "inherit", tokens: i.split(`
43152
43163
  `).map((a2) => [{ content: a2, color: "inherit", bgColor: "transparent", htmlStyle: {}, offset: 0 }]) }), [i]);
43153
43164
  return jsxRuntimeExports.jsx(Se.Provider, { value: { code: e }, children: jsxRuntimeExports.jsxs(et, { isIncomplete: s2, language: t, children: [jsxRuntimeExports.jsx(ot, { language: t }), n ? jsxRuntimeExports.jsx("div", { className: "pointer-events-none sticky top-2 z-10 -mt-10 flex h-8 items-center justify-end", children: jsxRuntimeExports.jsx("div", { className: "pointer-events-auto flex shrink-0 items-center gap-2 rounded-md border border-sidebar bg-sidebar/80 px-1.5 py-1 supports-[backdrop-filter]:bg-sidebar/70 supports-[backdrop-filter]:backdrop-blur", "data-streamdown": "code-block-actions", children: n }) }) : null, jsxRuntimeExports.jsx(reactExports.Suspense, { fallback: jsxRuntimeExports.jsx(Qe, { className: o, language: t, result: c, ...r2 }), children: jsxRuntimeExports.jsx(dn, { className: o, code: i, language: t, raw: c, ...r2 }) })] }) });
@@ -43914,7 +43925,7 @@ var Nt = ({ chart: e, className: t, config: o, fullscreen: n = false, showContro
43914
43925
  const MAP_HEIGHT = 56;
43915
43926
  const TIMELINE_PADDING = 8;
43916
43927
  const ROW_PADDING = 2;
43917
- const ROW_HEIGHT$1 = 24;
43928
+ const ROW_HEIGHT = 24;
43918
43929
  const MARKER_HEIGHT = 24;
43919
43930
  const initialState = {
43920
43931
  root: {
@@ -44650,17 +44661,17 @@ function computeIsNearRightSide(node2, root2, scrollSnapshotRef, isHovered) {
44650
44661
  }
44651
44662
  function computeDefaultLayout(node2, root2, scale, scrollSnapshotRef) {
44652
44663
  const left = (node2.startTime - root2.startTime) * scale;
44653
- let top = MARKER_HEIGHT + (ROW_HEIGHT$1 + ROW_PADDING) * node2.row;
44664
+ let top = MARKER_HEIGHT + (ROW_HEIGHT + ROW_PADDING) * node2.row;
44654
44665
  const actualWidth = node2.duration * scale;
44655
44666
  const width = Math.max(actualWidth, MIN_SPAN_WIDTH);
44656
- let height = ROW_HEIGHT$1;
44667
+ let height = ROW_HEIGHT;
44657
44668
  const isHuge = computeIsHuge(actualWidth);
44658
44669
  const isSmall = computeIsSmall(actualWidth);
44659
44670
  const isHovered = computeIsHovered(node2, isHuge);
44660
44671
  const isExpanded = isHovered || Boolean(node2.isSelected);
44661
44672
  if (isSmall && !isExpanded) {
44662
44673
  height *= 0.4;
44663
- top += (ROW_HEIGHT$1 - height) * 0.5;
44674
+ top += (ROW_HEIGHT - height) * 0.5;
44664
44675
  }
44665
44676
  const isNearRightSide = computeIsNearRightSide(node2, root2, scrollSnapshotRef, isExpanded);
44666
44677
  return {
@@ -44826,8 +44837,8 @@ const SpanComponent = reactExports.memo(function SpanComponent2({ node: node2, r
44826
44837
  layout.isSmall = liveActualWidth < 64;
44827
44838
  layout.isHuge = liveActualWidth >= 500;
44828
44839
  if (!layout.isSmall) {
44829
- layout.height = ROW_HEIGHT$1;
44830
- layout.top = MARKER_HEIGHT + (ROW_HEIGHT$1 + ROW_PADDING) * segmentNode.row;
44840
+ layout.height = ROW_HEIGHT;
44841
+ layout.top = MARKER_HEIGHT + (ROW_HEIGHT + ROW_PADDING) * segmentNode.row;
44831
44842
  }
44832
44843
  }
44833
44844
  reactExports.useEffect(() => {
@@ -44902,7 +44913,7 @@ const SpanEventComponent = reactExports.memo(function SpanEventComponent2({ even
44902
44913
  }
44903
44914
  }
44904
44915
  const left = (event.timestamp - root2.startTime) * scale;
44905
- const top = MARKER_HEIGHT + (ROW_HEIGHT$1 + ROW_PADDING) * node2.row;
44916
+ const top = MARKER_HEIGHT + (ROW_HEIGHT + ROW_PADDING) * node2.row;
44906
44917
  const isLeftAligned = node2.duration <= 0 || (event.timestamp - node2.startTime) / node2.duration < 0.5;
44907
44918
  const customClassName = customSpanEventClassNameFunc ? customSpanEventClassNameFunc(event) : "";
44908
44919
  return jsxRuntimeExports.jsxs("div", { title: phaseDuration ? `${displayLabel} ${timestamp}
@@ -45284,11 +45295,36 @@ function computeSpanGaps(spans, viewStart, viewEnd) {
45284
45295
  return gaps;
45285
45296
  }
45286
45297
  const RESOURCE_COLORS = {
45287
- run: { bar: "var(--ds-blue-700)", errorBar: "var(--ds-red-700)" },
45288
- step: { bar: "var(--ds-green-700)", errorBar: "var(--ds-red-700)" },
45289
- hook: { bar: "var(--ds-amber-700)", errorBar: "var(--ds-red-700)" },
45290
- sleep: { bar: "var(--ds-purple-700)", errorBar: "var(--ds-red-700)" },
45291
- default: { bar: "var(--ds-gray-500)", errorBar: "var(--ds-red-700)" }
45298
+ run: {
45299
+ bg: "var(--ds-blue-200)",
45300
+ border: "var(--ds-blue-500)",
45301
+ errorBg: "var(--ds-red-200)",
45302
+ errorBorder: "var(--ds-red-500)"
45303
+ },
45304
+ step: {
45305
+ bg: "var(--ds-green-200)",
45306
+ border: "var(--ds-green-500)",
45307
+ errorBg: "var(--ds-red-200)",
45308
+ errorBorder: "var(--ds-red-500)"
45309
+ },
45310
+ hook: {
45311
+ bg: "var(--ds-amber-200)",
45312
+ border: "var(--ds-amber-500)",
45313
+ errorBg: "var(--ds-red-200)",
45314
+ errorBorder: "var(--ds-red-500)"
45315
+ },
45316
+ sleep: {
45317
+ bg: "var(--ds-purple-200)",
45318
+ border: "var(--ds-purple-500)",
45319
+ errorBg: "var(--ds-red-200)",
45320
+ errorBorder: "var(--ds-red-500)"
45321
+ },
45322
+ default: {
45323
+ bg: "var(--ds-gray-200)",
45324
+ border: "var(--ds-gray-500)",
45325
+ errorBg: "var(--ds-red-200)",
45326
+ errorBorder: "var(--ds-red-500)"
45327
+ }
45292
45328
  };
45293
45329
  function getResourceColor(resource) {
45294
45330
  return RESOURCE_COLORS[resource] ?? RESOURCE_COLORS.default;
@@ -45481,87 +45517,143 @@ function computeSpanSegments(span) {
45481
45517
  return [];
45482
45518
  }
45483
45519
  }
45484
- const SEGMENT_CONFIG = {
45485
- queued: { className: "bg-gray-500" },
45486
- retrying: {
45487
- className: "box-border bg-gray-500"
45488
- },
45489
- waiting: { className: "bg-gray-500" },
45490
- running: { className: "bg-blue-700" },
45491
- failed: { className: "bg-red-700" },
45492
- succeeded: { className: "bg-green-700" },
45493
- sleeping: { className: "bg-gray-500" },
45494
- received: { className: "bg-blue-700" }
45495
- };
45496
- const BAR_HEIGHT_PX = 24;
45497
45520
  const TINY_BAR_BOX_SIZE_PX = 24;
45498
45521
  const TINY_BAR_WIDTH_PX = 4;
45499
- const SEGMENT_GAP_PX = 1;
45500
- const ROW_HEIGHT = 40;
45501
- const CONTAINER_PAD_Y = 8;
45502
- const END_CAP_HEIGHT = 8;
45503
45522
  const TIMELINE_PADDING_PX = 16;
45504
- const ORIGIN_MARKER_EPSILON = 1e-6;
45505
- const DeltaIndicator = reactExports.memo(function DeltaIndicator2({ leftFrac, rightFrac, label, rowIndex }) {
45506
- const centerY = CONTAINER_PAD_Y + (rowIndex + 1) * ROW_HEIGHT;
45507
- return jsxRuntimeExports.jsxs("div", { className: "absolute pointer-events-none", style: {
45508
- left: `${leftFrac * 100}%`,
45509
- width: `${(rightFrac - leftFrac) * 100}%`,
45510
- top: centerY - END_CAP_HEIGHT / 2,
45511
- height: END_CAP_HEIGHT
45512
- }, children: [jsxRuntimeExports.jsx("div", { className: "absolute left-0 top-0 w-px h-full bg-amber-800" }), jsxRuntimeExports.jsx("div", { className: "absolute left-0 right-0 top-1/2 h-px bg-amber-800" }), jsxRuntimeExports.jsx("div", { className: "absolute right-0 top-0 w-px h-full bg-amber-800" }), jsxRuntimeExports.jsx("span", { className: "absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 text-label-12 leading-none whitespace-nowrap rounded-xs px-1 py-0.5 text-gray-100 bg-amber-800", children: label })] });
45513
- });
45514
- const TimelineBar = reactExports.memo(function TimelineBar2({ span, viewStart, viewDuration, containerWidth, isSelected, onClick }) {
45523
+ const SEGMENT_CLASSES = {
45524
+ queued: "bg-gray-400 border border-gray-500",
45525
+ retrying: "bg-gray-400 border border-gray-500",
45526
+ waiting: "bg-gray-400 border border-gray-500",
45527
+ running: "bg-blue-200 border border-blue-500",
45528
+ failed: "bg-red-200 border border-red-500",
45529
+ succeeded: "bg-green-200 border border-green-500",
45530
+ sleeping: "bg-gray-400 border border-gray-500",
45531
+ received: "bg-blue-200 border border-blue-500"
45532
+ };
45533
+ const TIMELINE_INSET_STYLE = {
45534
+ left: TIMELINE_PADDING_PX,
45535
+ right: TIMELINE_PADDING_PX
45536
+ };
45537
+ function computeBarGeometry(startMs, endMs, viewStart, viewEnd, containerWidth) {
45538
+ const viewDuration = viewEnd - viewStart;
45539
+ const visibleStartMs = Math.max(startMs, viewStart);
45540
+ const visibleEndMs = Math.min(endMs, viewEnd);
45541
+ const visibleDurationMs = Math.max(0, visibleEndMs - visibleStartMs);
45542
+ const widthFrac = viewDuration > 0 ? visibleDurationMs / viewDuration : 0;
45543
+ const visiblePixelWidth = widthFrac * containerWidth;
45544
+ const isTiny = containerWidth > 0 && visiblePixelWidth < TINY_BAR_BOX_SIZE_PX;
45545
+ const extendsOffLeft = startMs < viewStart;
45546
+ const extendsOffRight = endMs > viewEnd;
45547
+ const mode = isTiny && (extendsOffLeft || extendsOffRight) ? { kind: "arrow", direction: extendsOffRight ? "right" : "left" } : isTiny ? { kind: "tiny" } : { kind: "full" };
45548
+ return {
45549
+ mode,
45550
+ leftPct: viewDuration > 0 ? (visibleStartMs - viewStart) / viewDuration * 100 : 0,
45551
+ widthPct: widthFrac * 100,
45552
+ visibleStartMs,
45553
+ visibleEndMs,
45554
+ visiblePixelWidth
45555
+ };
45556
+ }
45557
+ function getBarPositionStyle(geometry) {
45558
+ switch (geometry.mode.kind) {
45559
+ case "arrow":
45560
+ return {
45561
+ left: geometry.mode.direction === "right" ? `calc(100% - ${TINY_BAR_BOX_SIZE_PX}px)` : "0px",
45562
+ width: `${TINY_BAR_BOX_SIZE_PX}px`
45563
+ };
45564
+ case "tiny":
45565
+ return {
45566
+ left: `min(${geometry.leftPct}%, calc(100% - ${TINY_BAR_WIDTH_PX}px))`,
45567
+ width: `${TINY_BAR_WIDTH_PX}px`
45568
+ };
45569
+ case "full":
45570
+ return {
45571
+ left: `${geometry.leftPct}%`,
45572
+ width: `max(${geometry.widthPct}%, 4px)`
45573
+ };
45574
+ }
45575
+ }
45576
+ function projectSegments(segments, spanStartMs, spanDurationMs, geometry) {
45577
+ const visibleDurationMs = geometry.visibleEndMs - geometry.visibleStartMs;
45578
+ if (visibleDurationMs <= 0)
45579
+ return [];
45580
+ return segments.flatMap((seg) => {
45581
+ const segStartMs = spanStartMs + seg.startFraction * spanDurationMs;
45582
+ const segEndMs = spanStartMs + seg.endFraction * spanDurationMs;
45583
+ const startMs = Math.max(segStartMs, geometry.visibleStartMs);
45584
+ const endMs = Math.min(segEndMs, geometry.visibleEndMs);
45585
+ if (endMs <= startMs)
45586
+ return [];
45587
+ const widthFrac = (endMs - startMs) / visibleDurationMs;
45588
+ return [
45589
+ {
45590
+ status: seg.status,
45591
+ leftPct: (startMs - geometry.visibleStartMs) / visibleDurationMs * 100,
45592
+ widthPct: widthFrac * 100,
45593
+ pixelWidth: widthFrac * geometry.visiblePixelWidth,
45594
+ fullDurationMs: (seg.endFraction - seg.startFraction) * spanDurationMs
45595
+ }
45596
+ ];
45597
+ });
45598
+ }
45599
+ function DurationLabel({ label }) {
45600
+ return jsxRuntimeExports.jsx("span", { className: "pointer-events-none absolute inset-0 flex items-center justify-start overflow-hidden px-1 text-[10px] font-mono font-medium leading-none whitespace-nowrap text-left text-gray-1000 tabular-nums opacity-0 group-hover/timeline-row:opacity-100", children: label });
45601
+ }
45602
+ function BoundaryArrow({ direction }) {
45603
+ const Icon2 = direction === "right" ? ArrowRight : ArrowLeft;
45604
+ return jsxRuntimeExports.jsx("div", { className: "flex h-6 w-6 items-center justify-center rounded-[0.25rem]", children: jsxRuntimeExports.jsx(Icon2, { className: "size-3 text-gray-900" }) });
45605
+ }
45606
+ function PlainBar({ bg, border, label }) {
45607
+ return jsxRuntimeExports.jsx("div", { className: "relative h-6 w-full min-w-1 rounded-[0.25rem] border", style: { background: bg, borderColor: border }, children: label ? jsxRuntimeExports.jsx(DurationLabel, { label }) : null });
45608
+ }
45609
+ function SegmentBar({ segments }) {
45610
+ return jsxRuntimeExports.jsx("div", { className: "relative h-6 w-full", children: segments.map((seg, i) => {
45611
+ const label = formatDuration(seg.fullDurationMs);
45612
+ const showLabel = seg.pixelWidth >= Math.max(40, label.length * 6 + 12);
45613
+ const isNarrowQueued = seg.status === "queued" && seg.pixelWidth < 20;
45614
+ const overrideBg = isNarrowQueued ? "var(--ds-gray-400)" : void 0;
45615
+ const overrideBorder = isNarrowQueued ? "var(--ds-gray-500)" : void 0;
45616
+ return jsxRuntimeExports.jsx("div", { className: cn$4("absolute h-full rounded-[0.25rem]", SEGMENT_CLASSES[seg.status]), style: {
45617
+ // 1px gap between adjacent segments, distributed equally.
45618
+ left: `calc(${seg.leftPct}% + 0.5px)`,
45619
+ width: `calc(${seg.widthPct}% - 1px)`,
45620
+ minWidth: 1,
45621
+ background: overrideBg,
45622
+ borderColor: overrideBorder
45623
+ }, children: showLabel ? jsxRuntimeExports.jsx(DurationLabel, { label }) : null }, `${seg.status}-${i}`);
45624
+ }) });
45625
+ }
45626
+ const TimelineBar = reactExports.memo(function TimelineBar2({ span, viewStart, viewDuration, containerWidth, isSelected, onSelect }) {
45515
45627
  var _a3;
45516
- const startTime = getHighResInMs(span.startTime);
45517
- const endTime = getHighResInMs(span.endTime);
45628
+ const startMs = getHighResInMs(span.startTime);
45629
+ const endMs = getHighResInMs(span.endTime);
45518
45630
  const totalDurationMs = getSpanDurationMs(span);
45519
- const leftFracRaw = viewDuration > 0 ? (startTime - viewStart) / viewDuration : 0;
45520
- const rightFracRaw = viewDuration > 0 ? (endTime - viewStart) / viewDuration : 0;
45521
- const widthFrac = rightFracRaw - leftFracRaw;
45522
- const leftPct = leftFracRaw * 100;
45523
- const widthPct = widthFrac * 100;
45524
- const pixelWidth = widthFrac * containerWidth;
45525
- const visibleLeftFrac = Math.max(0, Math.min(1, leftFracRaw));
45526
- const visibleRightFrac = Math.max(0, Math.min(1, rightFracRaw));
45527
- const visiblePixelWidth = Math.max(0, visibleRightFrac - visibleLeftFrac) * containerWidth;
45528
- const isTinyBar = containerWidth > 0 && visiblePixelWidth < TINY_BAR_BOX_SIZE_PX;
45529
- const [isRowHovered, setIsRowHovered] = reactExports.useState(false);
45530
- const segments = reactExports.useMemo(() => computeSpanSegments(span), [span]);
45631
+ const geometry = reactExports.useMemo(() => computeBarGeometry(startMs, endMs, viewStart, viewStart + viewDuration, containerWidth), [startMs, endMs, viewStart, viewDuration, containerWidth]);
45632
+ const baseSegments = reactExports.useMemo(() => computeSpanSegments(span), [span]);
45633
+ const segments = reactExports.useMemo(() => geometry.mode.kind === "full" ? projectSegments(baseSegments, startMs, totalDurationMs, geometry) : [], [geometry, baseSegments, startMs, totalDurationMs]);
45531
45634
  const workflowStatus = (_a3 = span.attributes.data) == null ? void 0 : _a3.status;
45532
45635
  const isErrored = span.status.code === 2 || workflowStatus === "failed";
45533
45636
  const colors = getResourceColor(span.resource);
45534
- const fallbackColor = isErrored ? colors.errorBar ?? "var(--ds-red-700)" : colors.bar;
45535
- const renderDurationLabel = (label) => jsxRuntimeExports.jsx("span", { className: "pointer-events-none absolute inset-0 flex items-center justify-start overflow-hidden px-1 text-[10px] font-mono font-medium leading-none whitespace-nowrap text-left text-white tabular-nums", style: { textShadow: "0 1px 1px rgba(0, 0, 0, 0.45)" }, children: label });
45536
- const getMinDurationLabelWidthPx = (label) => Math.max(40, label.length * 6 + 12);
45537
- const totalDurationLabel = formatDuration(totalDurationMs);
45538
- const showBarDurationLabel = isRowHovered && pixelWidth >= getMinDurationLabelWidthPx(totalDurationLabel);
45539
- const showBoundaryArrow = isTinyBar && (leftFracRaw < 0 || rightFracRaw > 1);
45540
- const BoundaryArrow = leftFracRaw < 0.5 ? ArrowLeft : ArrowRight;
45541
- const barContent = showBoundaryArrow ? jsxRuntimeExports.jsx("div", { className: "flex h-6 w-6 items-center justify-center rounded-[0.25rem]", children: jsxRuntimeExports.jsx(BoundaryArrow, { className: "size-3 text-gray-900" }) }) : isTinyBar ? jsxRuntimeExports.jsx("div", { className: "h-6 rounded-[0.25rem]", style: { background: fallbackColor } }) : segments.length > 0 ? jsxRuntimeExports.jsx("div", { className: "relative h-6 w-full", children: segments.map((seg, i) => {
45542
- const segPixelWidth = (seg.endFraction - seg.startFraction) * pixelWidth;
45543
- const segDurationLabel = formatDuration((seg.endFraction - seg.startFraction) * totalDurationMs);
45544
- const showSegmentDurationLabel = isRowHovered && segPixelWidth >= getMinDurationLabelWidthPx(segDurationLabel);
45545
- const segStyle = seg.status === "queued" && segPixelWidth < 20 ? { background: "var(--ds-gray-500)" } : SEGMENT_CONFIG[seg.status].style;
45546
- return jsxRuntimeExports.jsx("div", { className: cn$4("absolute h-full rounded-[0.25rem]", SEGMENT_CONFIG[seg.status].className), style: {
45547
- left: `calc(${seg.startFraction * 100}% + ${SEGMENT_GAP_PX / 2}px)`,
45548
- width: `calc(${(seg.endFraction - seg.startFraction) * 100}% - ${SEGMENT_GAP_PX}px)`,
45549
- minWidth: 1,
45550
- ...segStyle
45551
- }, children: showSegmentDurationLabel ? renderDurationLabel(segDurationLabel) : null }, `${seg.status}-${i}`);
45552
- }) }) : jsxRuntimeExports.jsx("div", { className: "relative h-6 rounded-[0.25rem]", style: {
45553
- width: "100%",
45554
- minWidth: 4,
45555
- background: fallbackColor
45556
- }, children: showBarDurationLabel ? renderDurationLabel(totalDurationLabel) : null });
45557
- return jsxRuntimeExports.jsx("div", { role: "treeitem", "aria-selected": isSelected, "aria-expanded": isSelected, "aria-level": 1, className: cn$4("h-10 relative flex items-center hover:bg-gray-100 aria-selected:bg-gray-100 aria-selected:hover:bg-gray-200"), onMouseEnter: () => setIsRowHovered(true), onMouseLeave: () => setIsRowHovered(false), onClick, children: jsxRuntimeExports.jsx("div", { className: "absolute inset-y-0", style: {
45558
- left: TIMELINE_PADDING_PX,
45559
- right: TIMELINE_PADDING_PX
45560
- }, children: jsxRuntimeExports.jsx("div", { className: "absolute top-1/2 -translate-y-1/2", style: {
45561
- left: showBoundaryArrow ? `min(max(${leftPct}%, 0px), calc(100% - ${TINY_BAR_BOX_SIZE_PX}px))` : isTinyBar ? `min(${leftPct}%, calc(100% - ${TINY_BAR_WIDTH_PX}px))` : `${leftPct}%`,
45562
- width: showBoundaryArrow ? `${TINY_BAR_BOX_SIZE_PX}px` : isTinyBar ? `${TINY_BAR_WIDTH_PX}px` : `max(${widthPct}%, 4px)`,
45563
- height: BAR_HEIGHT_PX
45564
- }, children: barContent }) }) });
45637
+ const fallbackBg = isErrored ? colors.errorBg ?? "var(--ds-red-200)" : colors.bg;
45638
+ const fallbackBorder = isErrored ? colors.errorBorder ?? "var(--ds-red-500)" : colors.border;
45639
+ const totalLabel = formatDuration(totalDurationMs);
45640
+ const showTotalLabel = geometry.visiblePixelWidth >= Math.max(40, totalLabel.length * 6 + 12);
45641
+ const handleClick = reactExports.useCallback(() => {
45642
+ onSelect(span.spanId);
45643
+ }, [onSelect, span.spanId]);
45644
+ return jsxRuntimeExports.jsx("div", { role: "treeitem", "aria-selected": isSelected, "aria-expanded": isSelected, "aria-level": 1, className: "group/timeline-row h-10 relative flex items-center hover:bg-gray-100 aria-selected:bg-gray-100 aria-selected:hover:bg-gray-200", onClick: handleClick, children: jsxRuntimeExports.jsx("div", { className: "absolute inset-y-0", style: TIMELINE_INSET_STYLE, children: jsxRuntimeExports.jsx("div", { className: "absolute top-1/2 h-6 -translate-y-1/2", style: getBarPositionStyle(geometry), children: geometry.mode.kind === "arrow" ? jsxRuntimeExports.jsx(BoundaryArrow, { direction: geometry.mode.direction }) : geometry.mode.kind === "tiny" ? jsxRuntimeExports.jsx("div", { className: "h-6 rounded-[0.25rem] border", style: { background: fallbackBg, borderColor: fallbackBorder } }) : segments.length > 0 ? jsxRuntimeExports.jsx(SegmentBar, { segments }) : jsxRuntimeExports.jsx(PlainBar, { bg: fallbackBg, border: fallbackBorder, label: showTotalLabel ? totalLabel : null }) }) }) });
45645
+ });
45646
+ const DELTA_ROW_HEIGHT_PX = 40;
45647
+ const DELTA_CAP_HEIGHT_PX = 8;
45648
+ const DELTA_ROW_OFFSET_PX = 8;
45649
+ const DeltaIndicator = reactExports.memo(function DeltaIndicator2({ leftFrac, rightFrac, label, rowIndex }) {
45650
+ const centerY = DELTA_ROW_OFFSET_PX + (rowIndex + 1) * DELTA_ROW_HEIGHT_PX;
45651
+ return jsxRuntimeExports.jsxs("div", { className: "absolute pointer-events-none", style: {
45652
+ left: `${leftFrac * 100}%`,
45653
+ width: `${(rightFrac - leftFrac) * 100}%`,
45654
+ top: centerY - DELTA_CAP_HEIGHT_PX / 2,
45655
+ height: DELTA_CAP_HEIGHT_PX
45656
+ }, children: [jsxRuntimeExports.jsx("div", { className: "absolute left-0 top-0 w-px h-full bg-amber-800" }), jsxRuntimeExports.jsx("div", { className: "absolute left-0 right-0 top-1/2 h-px bg-amber-800" }), jsxRuntimeExports.jsx("div", { className: "absolute right-0 top-0 w-px h-full bg-amber-800" }), jsxRuntimeExports.jsx("span", { className: "absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 text-label-12 leading-none whitespace-nowrap rounded-xs px-1 py-0.5 text-gray-100 bg-amber-800", children: label })] });
45565
45657
  });
45566
45658
  function TimelineHeader({ markers: markers2, hoverInfo: hoverInfo2 }) {
45567
45659
  return jsxRuntimeExports.jsx("div", { className: "relative bg-background-100 border-b border-gray-alpha-400 h-10 min-h-10 flex items-end px-4 pb-1", children: jsxRuntimeExports.jsxs("div", { className: "relative h-full flex-1", children: [markers2.map((m2) => jsxRuntimeExports.jsx("span", { className: "absolute bottom-1 font-mono text-xs font-normal leading-4 text-gray-900 whitespace-nowrap", style: { left: `${m2.position * 100}%` }, children: m2.label }, `${m2.position}-${m2.label}`)), hoverInfo2 && jsxRuntimeExports.jsx("span", { className: "absolute top-1 pointer-events-none z-10 font-mono text-[11px] leading-4 text-gray-1000 whitespace-nowrap bg-background-100 border border-gray-alpha-400 rounded px-1 -translate-x-1/2", style: { left: `${hoverInfo2.fraction * 100}%` }, children: hoverInfo2.label })] }) });
@@ -45582,16 +45674,10 @@ function Timeline({ spans, viewStart, viewEnd, markers: markers2, selectedId, on
45582
45674
  return () => ro2.disconnect();
45583
45675
  }, []);
45584
45676
  const gaps = reactExports.useMemo(() => computeSpanGaps(spans, viewStart, viewEnd), [spans, viewStart, viewEnd]);
45585
- return jsxRuntimeExports.jsxs("div", { ref: containerRef, className: "relative h-full overflow-hidden", children: [jsxRuntimeExports.jsx("div", { "aria-hidden": true, className: "absolute inset-y-0 pointer-events-none", style: {
45586
- left: TIMELINE_PADDING_PX,
45587
- right: TIMELINE_PADDING_PX
45588
- }, children: markers2.map((marker2) => Math.abs(marker2.value) > ORIGIN_MARKER_EPSILON ? jsxRuntimeExports.jsx("div", { className: "absolute top-0 bottom-0 w-px bg-gray-alpha-300", style: { left: `${marker2.position * 100}%` } }, `${marker2.position}-${marker2.label}`) : null) }), hoverFraction != null && jsxRuntimeExports.jsx("div", { className: "absolute inset-y-0 pointer-events-none z-10", style: {
45589
- left: TIMELINE_PADDING_PX,
45590
- right: TIMELINE_PADDING_PX
45591
- }, children: jsxRuntimeExports.jsx("div", { className: "absolute top-0 bottom-0 w-px bg-gray-alpha-400", style: { left: `${hoverFraction * 100}%` } }) }), spans.map((span) => jsxRuntimeExports.jsx(TimelineBar, { span, viewStart, viewDuration, containerWidth: timelineWidth, isSelected: selectedId === span.spanId, onClick: () => onSelect(span.spanId) }, span.spanId)), altHeld && jsxRuntimeExports.jsx("div", { "aria-hidden": true, className: "absolute inset-y-0 pointer-events-none", style: {
45592
- left: TIMELINE_PADDING_PX,
45593
- right: TIMELINE_PADDING_PX
45594
- }, children: gaps.map((gap) => jsxRuntimeExports.jsx(DeltaIndicator, { leftFrac: gap.leftFrac, rightFrac: gap.rightFrac, label: formatDuration(gap.gapMs, true), rowIndex: gap.rowIndex }, gap.rowIndex)) })] });
45677
+ return jsxRuntimeExports.jsxs("div", { ref: containerRef, className: "relative h-full overflow-hidden", children: [jsxRuntimeExports.jsx("div", { "aria-hidden": true, className: "absolute inset-y-0 pointer-events-none", style: TIMELINE_INSET_STYLE, children: markers2.map((marker2) => (
45678
+ // Skip the "0s" origin marker since the left edge already implies it.
45679
+ Math.abs(marker2.value) > 1e-6 ? jsxRuntimeExports.jsx("div", { className: "absolute top-0 bottom-0 w-px bg-gray-alpha-300", style: { left: `${marker2.position * 100}%` } }, `${marker2.position}-${marker2.label}`) : null
45680
+ )) }), hoverFraction != null && jsxRuntimeExports.jsx("div", { className: "absolute inset-y-0 pointer-events-none z-10", style: TIMELINE_INSET_STYLE, children: jsxRuntimeExports.jsx("div", { className: "absolute top-0 bottom-0 w-px bg-gray-alpha-500", style: { left: `${hoverFraction * 100}%` } }) }), spans.map((span) => jsxRuntimeExports.jsx(TimelineBar, { span, viewStart, viewDuration, containerWidth: timelineWidth, isSelected: selectedId === span.spanId, onSelect }, span.spanId)), altHeld && jsxRuntimeExports.jsx("div", { "aria-hidden": true, className: "absolute inset-y-0 pointer-events-none", style: TIMELINE_INSET_STYLE, children: gaps.map((gap) => jsxRuntimeExports.jsx(DeltaIndicator, { leftFrac: gap.leftFrac, rightFrac: gap.rightFrac, label: formatDuration(gap.gapMs, true), rowIndex: gap.rowIndex }, gap.rowIndex)) })] });
45595
45681
  }
45596
45682
  const ActiveSpanContext = reactExports.createContext(null);
45597
45683
  ActiveSpanContext.displayName = "ActiveSpanContext";