/* Full-bleed host for the React Flow timeline canvas. */ .root { display: flex; flex-direction: column; /* `clip` (not `hidden`) keeps this box from becoming a scroll container, so the toolbar's sticky offset resolves against the host's session scroller (`.scrollBody`) instead of this element. `hidden` remains the fallback. */ overflow: hidden; overflow: clip; /* The host publishes the scrollport size on `.scrollBody`. Binding to it keeps the view exactly one viewport tall: without it the view's height is content driven, so opening the detail sidebar with long content grows the flex row, pushes the canvas (and its controls) below the fold, and turns the whole session body into a scroller. Subtracting the docked composer keeps that seat's height out of the canvas. */ height: calc(var(--dsh-conversation-viewport-height, 100%) - var(--dsh-composer-height, 0px)); max-height: calc(var(--dsh-conversation-viewport-height, 100%) - var(--dsh-composer-height, 0px)); min-height: 0; width: 100%; box-sizing: border-box; color: var(--dsw-alias-label-primary); background: var(--dsw-alias-bg-layer-1); } .empty { display: flex; align-items: center; justify-content: center; flex: 1; color: var(--dsw-alias-label-tertiary); } /* Stays pinned to the top of the host session scrollport while the graph scrolls; the opaque surface keeps canvas dots from showing through. */ .toolbar { position: sticky; top: 0; z-index: 2; flex: none; display: flex; align-items: center; gap: 8px; padding: 8px 16px; border-bottom: 1px solid var(--dsw-alias-border-l1); background: var(--dsw-alias-bg-layer-1); } /* Column-layout toggle (single column vs. default multi-column). */ .layoutToggle { flex: none; height: 32px; padding: 0 12px; border-radius: 6px; border: 1px solid var(--dsw-alias-border-l2); background: var(--dsw-alias-bg-base); color: var(--dsw-alias-label-secondary); font-size: 12px; cursor: pointer; } .layoutToggle:hover { border-color: var(--dsw-alias-state-business-primary); color: var(--dsw-alias-label-primary); } .layoutToggleActive, .layoutToggleActive:hover { border-color: var(--dsw-alias-state-business-primary); background: color-mix(in srgb, var(--dsw-alias-state-business-primary) 14%, var(--dsw-alias-bg-base)); color: var(--dsw-alias-label-primary); } .turnSelect { display: flex; align-items: center; gap: 8px; height: 40px; max-width: 360px; padding: 0 12px; border-radius: 6px; border: 1px solid var(--dsw-alias-border-l2); background: var(--dsw-alias-bg-base); color: var(--dsw-alias-label-primary); font-size: 12px; cursor: pointer; } .turnSelect:hover { border-color: var(--dsw-alias-state-business-primary); } .turnSelectLabel { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: left; } /* Turn menu: keep roughly ten turn rows visible; the pinned footer loads more. Doubling the module class beats `.scrollable`'s single-class max-height. */ .turnMenuList.turnMenuList { max-height: 390px; } .turnSelectChevron { flex: none; color: var(--dsw-alias-label-tertiary); } /* Left React Flow canvas + right persistent detail sidebar, side by side. */ .body { flex: 1; display: flex; min-height: 0; overflow: hidden; } .canvas { flex: 1; min-width: 0; position: relative; overflow: hidden; } /* Save-as-PNG affordance pinned to the canvas's bottom-left corner. */ .exportButton { position: absolute; left: 12px; bottom: 12px; z-index: 5; display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; padding: 0; border: 1px solid var(--dsw-alias-border-l2); border-radius: 6px; background: var(--dsw-alias-bg-base); color: var(--dsw-alias-label-secondary); cursor: pointer; box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08); } .exportButton:hover { border-color: var(--dsw-alias-state-business-primary); color: var(--dsw-alias-label-primary); } /* One node card: React Flow positions the wrapper; this fills it and lays out rows. */ .node { box-sizing: border-box; display: flex; flex-direction: column; justify-content: center; gap: 3px; width: 100%; height: 100%; padding: 6px 10px; border-radius: 8px; border: 1px solid var(--dsw-alias-border-l1); background: var(--dsw-alias-bg-base); font-size: 12px; line-height: 1.3; overflow: hidden; cursor: pointer; } /* The turn's opening human prompt: a distinct neutral-strong accent. */ .userMessage { border-color: var(--dsw-alias-label-tertiary); background: color-mix(in srgb, var(--dsw-alias-label-primary) 8%, var(--dsw-alias-bg-base)); } .requestHeader { border-color: var(--dsw-alias-state-business-tertiary); background: color-mix(in srgb, var(--dsw-alias-state-business-primary) 12%, var(--dsw-alias-bg-base)); } .assistantMessage { border-color: var(--dsw-alias-state-business-primary); background: color-mix(in srgb, var(--dsw-alias-state-business-primary) 18%, var(--dsw-alias-bg-base)); } .toolCall { border-color: var(--dsw-alias-state-warn-primary); background: color-mix(in srgb, var(--dsw-alias-state-warn-primary) 14%, var(--dsw-alias-bg-base)); } .toolResult { border-color: var(--dsw-alias-state-success-tertiary); background: color-mix(in srgb, var(--dsw-alias-state-success-primary) 14%, var(--dsw-alias-bg-base)); } .toolResultError { border-color: var(--dsw-alias-state-error-primary); background: color-mix(in srgb, var(--dsw-alias-state-error-primary) 14%, var(--dsw-alias-bg-base)); } .toolRunning { border-style: dashed; border-color: var(--dsw-alias-state-warn-primary); animation: pulse 1.6s ease-in-out infinite; } @keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.6; } } /* First card row: type label + title + time, all on one line. */ .nodeHeadRow { display: flex; align-items: baseline; gap: 6px; min-width: 0; } /* Small label for the node's kind (e.g. "Tool"), sharing the title's row. * Background-free: a bordered outline keeps the chip shape while staying light. */ .nodeKind { flex: none; padding: 0 4px; border-radius: 4px; border: 1px solid var(--dsw-alias-state-warn-primary); font-size: 10px; font-weight: 600; color: var(--dsw-alias-state-warn-primary); background: transparent; } .nodeTitle { font-weight: 600; color: var(--dsw-alias-label-primary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .nodeSubtitle { color: var(--dsw-alias-label-secondary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .nodeTime { margin-left: auto; flex: none; color: var(--dsw-alias-label-quaternary); font-size: 10px; white-space: nowrap; } /* Assistant-segment fold toggle pinned to the card's right border. */ .nodeFold { flex: none; display: flex; align-items: center; justify-content: center; width: 18px; height: 18px; padding: 0; border: 1px solid transparent; border-radius: 4px; background: transparent; color: var(--dsw-alias-label-secondary); cursor: pointer; } .nodeFold:hover { background: var(--dsw-alias-interactive-bg-hover); color: var(--dsw-alias-label-primary); } /* Fold capsule: a wide pill standing in for a collapsed assistant segment. */ .foldCapsule { display: flex; align-items: center; justify-content: center; gap: 6px; width: 100%; height: 100%; box-sizing: border-box; padding: 0 10px; border: 1px dashed var(--dsw-alias-border-l2); border-radius: 14px; background: color-mix(in srgb, var(--dsw-alias-bg-base) 80%, transparent); color: var(--dsw-alias-label-secondary); font-size: 11px; cursor: pointer; } .foldCapsule:hover { border-color: var(--dsw-alias-state-business-primary); color: var(--dsw-alias-label-primary); } .foldCapsuleLabel { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .foldCapsuleIcon { flex: none; font-size: 13px; font-weight: 600; color: var(--dsw-alias-label-tertiary); } .nodeBadge { flex: none; padding: 0 4px; border-radius: 4px; border: 1px solid var(--dsw-alias-state-error-primary); font-size: 10px; color: var(--dsw-alias-state-error-primary); background: transparent; } /* Second row of a tool-result card: result label on the left, duration on the right. */ .nodeResultRow { display: flex; align-items: baseline; gap: 6px; min-width: 0; } .nodeDuration { margin-left: auto; flex: none; color: var(--dsw-alias-label-quaternary); font-size: 10px; white-space: nowrap; } /* React Flow connection handles: functional anchors, visually muted. */ .handle { width: 6px; height: 6px; border: none; background: var(--dsw-alias-border-l2); opacity: 0.6; } /* Put the scroll-to-top control above React Flow's default zoom-in button. */ .flowControls button:last-child { order: -1; } .capsuleHandle { width: 1px; height: 1px; min-width: 1px; min-height: 1px; border: none; background: transparent; opacity: 0; } /* Drag divider between the canvas and the detail sidebar. */ .resizeHandle { flex: none; width: 8px; cursor: col-resize; display: flex; align-items: center; justify-content: center; border-left: 1px solid var(--dsw-alias-border-l1); background: var(--dsw-alias-bg-layer-1); touch-action: none; } .resizeHandle:hover, .resizeHandleActive { background: color-mix(in srgb, var(--dsw-alias-state-business-primary) 20%, var(--dsw-alias-bg-layer-1)); } /* Grip icon: a short vertical run of dots centered on the divider. */ .resizeGrip { width: 2px; height: 24px; border-radius: 1px; background: radial-gradient(circle, var(--dsw-alias-label-tertiary) 1px, transparent 1px) 0 0 / 2px 5px repeat-y; } .sidebar { position: relative; flex: none; min-width: 320px; max-width: 600px; overflow: auto; background: var(--dsw-alias-bg-layer-1); padding: 12px 16px; box-sizing: border-box; } /* Close affordance pinned to the panel's top-right corner. */ .sidebarClose { position: absolute; top: 8px; right: 8px; display: flex; align-items: center; justify-content: center; width: 24px; height: 24px; padding: 0; border: none; border-radius: 4px; background: transparent; color: var(--dsw-alias-label-tertiary); cursor: pointer; } .sidebarClose:hover { background: var(--dsw-alias-interactive-bg-hover); color: var(--dsw-alias-label-primary); } .detailEmpty { color: var(--dsw-alias-label-tertiary); font-size: 12px; } .detailTitle { font-weight: 600; margin-bottom: 6px; /* Keep the title clear of the top-right close button. */ padding-right: 28px; } /* Title row plus the top-right raw-Markdown copy control. */ .detailHeader { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; /* Keep the row clear of the top-right close button. */ padding-right: 28px; } .detailHeader .detailTitle { flex: 1; min-width: 0; margin-bottom: 0; padding-right: 0; } .detailCopy { flex: none; display: flex; align-items: center; justify-content: center; width: 24px; height: 24px; padding: 0; border: 1px solid var(--dsw-alias-border-l2); border-radius: 6px; background: transparent; color: var(--dsw-alias-label-tertiary); cursor: pointer; } .detailCopy:hover { background: var(--dsw-alias-interactive-bg-hover); color: var(--dsw-alias-label-primary); } /* Rendered Markdown body: keep wide tables/code blocks inside the sidebar. */ .detailMarkdown { overflow-x: auto; font-size: 13px; } .detailMeta { color: var(--dsw-alias-label-quaternary); font-size: 11px; margin-bottom: 6px; } .detailToolName { font-family: var(--dsw-font-family-mono); font-size: 12px; color: var(--dsw-alias-label-primary); padding: 2px 0; } .detailPre { margin: 0; white-space: pre-wrap; word-break: break-word; font-family: var(--dsw-font-mono, monospace); font-size: 12px; color: var(--dsw-alias-label-secondary); } /* Section heading between the Payload tree and the formatted command block. */ .detailSectionLabel { margin: 12px 0 4px; font-size: 11px; font-weight: 600; color: var(--dsw-alias-label-tertiary); text-transform: uppercase; letter-spacing: 0.04em; } .detailSectionLabel:first-of-type { margin-top: 8px; } /* The Payload JSON inspector, sized to the sidebar. */ .payloadTree { max-height: 40vh; overflow: auto; border: 1px solid var(--dsw-alias-border-l1); border-radius: 6px; padding: 6px 8px; background: var(--dsw-alias-bg-base); } /* Formatted shell command: one step per line, wrapping long arguments. */ .commandBlock { margin: 0; padding: 8px 10px; border: 1px solid var(--dsw-alias-border-l1); border-radius: 6px; background: var(--dsw-alias-bg-base); font-family: var(--dsw-font-mono, monospace); font-size: 12px; color: var(--dsw-alias-label-secondary); } .commandLine { white-space: pre-wrap; word-break: break-word; } /* Continuation lines (every step after the first) hang-indent for readability. */ .commandLine + .commandLine { padding-left: 12px; text-indent: -12px; } .fileReadLine { display: flex; gap: 8px; } .fileReadLineNumber { flex: none; width: 3em; text-align: right; color: var(--dsw-alias-label-quaternary); }