Commit Graph
58 Commits
Author SHA1 Message Date
imccyu 9ed87a6dba refactor(client): archivedSessionIds public face becomes a plain array
Public snapshot state stays in the store engine's plain-data vocabulary
(immer drafts reject Sets without the MapSet plugin, which stays off):
manager/service/contract carry readonly SessionId[] in Host order, and
the tree derivations build their own transient Set — the
expandedProjects pattern. Membership-unchanged installs still keep the
array reference for Object.is short-circuits.
2026-07-31 14:08:13 +08:00
imccyu c764ed7e64 feat(client-runtime): project the archive set and the archiveSession action
WorkspaceListState gains archivedSessionIds (ReadonlySet, replaced only
on membership change), installed as full snapshots from the list
baseline, the unary echo, and the changed frame. Archiving the current
session clears the selection into the New Session view state. Test
doubles (test-runtime, fake APIs, fixture client) follow the widened
IWorkspaces/IApiClient faces.
2026-07-31 14:08:13 +08:00
Turtle 1332360d53 Merge pull request #1013 from deepseek-harness/fix/node26-vitest-webstorage
fix(test): isolate jsdom storage on Node 26
2026-07-31 10:31:59 +08:00
Turtle aa39d6c6ed Merge remote-tracking branch 'origin/master' into fix/node26-vitest-webstorage
# Conflicts:
#	scripts/run-gates.spec.ts
#	vitest.config.ts
2026-07-31 10:26:05 +08:00
imccyu 810b45a377 Merge remote-tracking branch 'origin/master' into mergebot/pr1008
# Conflicts:
#	apps/web/tests/snapshots/cordis-tool-round/ui.expected.md
#	apps/web/tests/snapshots/fresh-round-trip/ui.expected.md
#	apps/web/tests/snapshots/steering/settled.expected.md
#	packages/client/ui-conversation/src/client/chat/ChatView.tsx
#	packages/client/ui-conversation/src/client/chat/GenericToolCard.tsx
#	packages/client/ui-conversation/src/client/chat/ToolRow.tsx
#	packages/client/ui-conversation/src/client/contract/terminal-card-model.ts
#	packages/client/ui-conversation/src/client/skeleton/DetailsPanel.tsx
#	packages/client/ui-conversation/src/client/toolviews/ask-question-row.tsx
#	packages/client/ui-conversation/src/client/toolviews/bash-sample.tsx
#	packages/client/ui-conversation/src/client/toolviews/todo-row.tsx
#	packages/client/ui-conversation/tests/chat-tool-row.spec.tsx
#	packages/client/ui-conversation/tests/terminal-card.spec.tsx
#	packages/client/ui-trajectory/tests/client-bundle.spec.ts
2026-07-31 03:00:08 +08:00
imccyu 7730ffad4e test(web): refresh plan-review and seeded-history goldens after master merge 2026-07-31 02:45:22 +08:00
imccyu 1e10966ef6 wip
fix: docs
2026-07-31 02:13:53 +08:00
Turtle f04b35c6a4 fix(test): isolate jsdom storage on Node 26 2026-07-30 21:49:33 +08:00
Yif 78e4d36214 feat(web): unify tool-row expand interaction with IN/OUT card and trajectory Inspect
Every expandable tool row shares one interaction (whole-row toggle,
icon-to-chevron hover preview) and one expanded body: an IN/OUT
gutter-labeled card with per-section 150px scroll caps and sticky labels.
toolRowModel derives result output and the error first line, terminalFailed
surfaces a failing exit as the collapsed row's red dot, a hover Inspect
pill jumps to the call's trajectory record through a one-shot store
handoff, and the chat view keeps its scroll offset across view switches.
2026-07-30 21:21:29 +08:00
Yif 86fa88a012 test(web): align trajectory client-bundle spec with the sessionHistory injection 2026-07-30 21:18:51 +08:00
_Kerman daed49ad54 perf(ui-trajectory): reuse finalized stream projections 2026-07-30 18:05:49 +08:00
_Kerman 7ec01dad08 fix(ui-trajectory): bound expensive record previews 2026-07-30 17:55:06 +08:00
_Kerman 287289ddbc feat(ui): highlight trajectory errors 2026-07-30 17:42:02 +08:00
_Kerman 411bbdf2aa feat(ui): compact trajectory role labels 2026-07-30 17:11:07 +08:00
_Kerman 997932ffd6 feat(ui): refine trajectory timeline interaction 2026-07-30 17:00:58 +08:00
Tianyi Cui e1984cbfd9 Merge commit '90bc53cc64dc684dc3d741f45ae6a8d548c188f9' into worktree/retarget-pr885-20260729 2026-07-29 21:40:13 +08:00
imccyu 64acc5874b test(client): cover independent trajectory history 2026-07-29 20:46:02 +08:00
imccyu e0022ff19e refactor(client): isolate trajectory history 2026-07-29 20:21:37 +08:00
Turtle 95a995968b refactor: migrate linting to Oxlint 2026-07-29 14:32:11 +08:00
_Kerman 5d0d28cd0e fix(client): refine trajectory inspection behavior 2026-07-29 11:57:13 +08:00
_Kerman 33afcc913b Revert "fix(ui-conversation): keep composer visible across views"
This reverts commit 978d035d4a8d3578a70844511a42aa793664e5de.
2026-07-29 11:46:14 +08:00
_Kerman 549315256a fix(ui-primitives): preserve raw HTML in text extraction 2026-07-29 11:43:00 +08:00
_Kerman 5939355b1a fix(ui-conversation): keep composer visible across views 2026-07-29 11:30:50 +08:00
_Kerman 943ef7403e fix(client): resolve trajectory review follow-ups 2026-07-28 22:54:46 +08:00
_Kerman f942c30f4b fix(client): address trajectory review feedback 2026-07-28 22:16:45 +08:00
_Kerman 0e1e594314 Merge remote-tracking branch 'origin/master' into xtr/trajectory-timeline
# Conflicts:
#	apps/web/tests/code-mode-fixture.snapshot.ts
#	apps/web/tests/navigation-panes.e2e.ts
#	apps/web/tests/snapshots/navigation-panes/details-open.expected.md
#	packages/client/runtime/src/client/index.ts
#	packages/client/runtime/src/client/sessions/fold-adapter.ts
#	packages/client/ui-trajectory/tests/views.spec.tsx
2026-07-28 18:06:04 +08:00
_Kerman bbd9949d31 feat(client): refine trajectory timeline interaction 2026-07-28 18:02:19 +08:00
_Kerman 1d4a6149cc feat(client): add trajectory timing overview 2026-07-28 16:28:57 +08:00
_Kerman 9096dbb29d fix(client): address trajectory review findings 2026-07-28 15:07:44 +08:00
_Kerman 1ac0eb9611 fix(client): keep trajectory history on the session seam 2026-07-28 13:56:00 +08:00
_Kerman 028ac5c2f6 refactor(client): isolate trajectory history reads 2026-07-28 13:50:46 +08:00
imccyu e2791107c4 ci: clear the snapshots-and-artifacts lane — lint sweep and TUI snapshot re-record
Lint: eslint --fix over the merge-crossed projection/command files (arrow
parens, trailing commas, unnecessary assertions), Extract<> replaces the
keyof-map & string intersections no-redundant-type-constituents rejects,
the fold-adapter's merge loop drops its non-null assertions for a
bounds-carrying cursor, one JSDoc line wrapped under max-len (api-catalog
regenerated). Snapshots: the four TUI goldens re-recorded for the merged
event-count shift (the durable command lifecycle adds one event to the
seeded diagnostics log). The headless advanced-toolchain snapshot passes
on CI and fails locally in this sandbox both with and without these
changes (30s child timeout — environment-bound, tracked in the ledger).
2026-07-28 11:48:01 +08:00
_Kerman 43d9fbaf08 test(ui): close trajectory inspection gates 2026-07-28 10:46:39 +08:00
_Kerman 71f1f36175 fix(ui): align trajectory CI contracts 2026-07-28 10:34:47 +08:00
_Kerman 92081094ae fix(ui): reconcile trajectory ledger with current client contracts 2026-07-28 10:23:44 +08:00
_Kerman fb3e4effba fix(ui): align trajectory checks with inspection ledger 2026-07-28 10:17:44 +08:00
_Kerman a4f4751600 Merge remote-tracking branch 'github/master' into xtr/trajectory-inspection-ui
# Conflicts:
#	packages/client/ui-primitives/src/Menu.tsx
#	packages/client/ui-trajectory/src/client/TrajectoryCell.tsx
#	packages/client/ui-trajectory/src/client/TrajectoryView.tsx
#	packages/client/ui-trajectory/tests/layout.spec.tsx
#	pnpm-lock.yaml
#	pnpm-workspace.yaml
2026-07-28 10:12:29 +08:00
imccyu 90addbf53c feat(gui): useProjection — the fifth framework hook seat through the standard kit
React half of the session-projection client base: the renderer contract gains
an open-key projections face on SessionMaybeProvideInfo (cellOf(key), distinct
from the static hooks roster), web-react mints projectionHook (per-bundle cache;
per-cell uSES binding via the shared observableHook cache; unresolved keys read
undefined through the absent source so hook order stays constant), standardKit
delivers kit.useProjection, and the runtime merges UseProjection into
SessionStandardProps/SessionMaybeStandardProps (overloads mirror useSession).
3 jsdom specs (kit delivery + live re-render, selector over undefined, faceless
bundle = all absent); existing direct-prop-feed specs gain the one-line stub the
new required seat mandates.
2026-07-27 22:58:53 +08:00
imccyu cdd4d59ea0 chore(lint): clear the semantic .tsx backlog
Hand fixes for the findings --fix cannot touch, mirroring the fixes
already applied on the fe-docs feature branch (same file, same shape)
so its eventual rebase resolves cleanly:

- restore the return the no-confusing-void-expression autofix ate in
  useAbsentSnapshot (typed S | undefined; hook call kept for hook-order
  stability, undefined returned explicitly);
- re-type DOM queries the no-unnecessary-type-assertion autofix broke:
  getByRole<HTMLButtonElement>(...) generics instead of the removed
  as-casts (the eslint program and the client tsconfig aggregate
  disagree about these casts; the generic form satisfies both);
- justified eslint-disable for the deliberate legacy paths: keyCode 229
  IME-composition detection, execCommand clipboard fallbacks, lib.dom
  clipboard optionality, and the any-typed Reflect.get/this probes in
  test fakes;
- drop the dead react/no-danger directive (eslint-plugin-react is not
  loaded, so the rule never applied) keeping its shiki rationale;
- delete the tautological 'Z' comparison and the renameTarget null
  check already implied by renameBlocked;
- css-module non-null assertions replaced by type widening
  (Button className, TAG_CLASS Record) per the established pattern;
- misc: max-len comment wraps, void generic drop in the deferred test
  helper, unused type imports, floating selectWorkspace promises voided,
  member-delimiter newlines in inline type literals.
2026-07-27 22:23:41 +08:00
imccyu 49c2e85ac7 chore(lint): apply eslint auto-fixes across the .tsx backlog
Mechanical --fix output over the newly linted .tsx files (indent,
arrow-parens, comma-dangle, member-delimiter-style, unnecessary type
assertions), plus the three generic-arrow test hooks converted to
function declarations up front: the comma-dangle fixer strips the
<T,> disambiguation comma and turns them into parse errors otherwise.
2026-07-27 21:49:40 +08:00
_Kerman 628c1bffe0 feat(ui): add trajectory inspection ledger 2026-07-27 15:47:44 +08:00
imccyu a27be43ac1 feat: slash system / input service / agent scope 2026-07-27 03:28:39 +08:00
Tianyi Cui 835156b038 fix(ui-trajectory): timing provenance on sub-span lanes; assembled snapshot for both views
Responding to ds-review-bot on #664:

- SubSpanLane gains a 'timing' discriminant (measured | running | unknown).
  A settle-only replay entry (callTime null, start outside the window) was
  previously indistinguishable from a measured 0 ms span; it now renders
  hollow with a 'duration unknown' hover title, and durationMs stays null
  for anything unmeasured. Pairs with the client-runtime fix that stopped
  fabricating callTime = settle time (826c3696a on the live-parallel PR).

- The built-client Code Mode fixture snapshot now switches to the
  Trajectory and Waterfall tabs and pins the assembled rendering: three
  Sub cells with real +0.8s durations and three measured lanes with their
  hover titles — product-visible coverage through the real bundle graph,
  not just package-level jsdom fixtures.

Agent Note (both languages) updated for the timing contract; pairing
re-recorded.
2026-07-26 14:20:59 +08:00
Tianyi Cui e715d6cc59 feat(web): Code Mode sub-calls in the trajectory and waterfall views
Trajectory: the layout fold interleaves one subtool cell per sub-dispatch
after its parent Tool cell (assistant-block calls, orphan results, and
running calls alike), indexes sequential across the interleave; settled
durations come from the start/settle pair, running sub-calls show the
em dash. New Sub tag (business tint) + 28px indent.

Waterfall: deriveSubSpans folds the dispatch index into per-turn lanes
with REAL wall time — each parent's window is first start → last settle
and every lane's offset/width is its fraction of it, so parallel
sub-calls visibly overlap; running lanes extend to the window end at
reduced opacity. Lanes draw under the owning turn row.

Both views read codeDispatches through the standard snapshot hook; no
new wire data, replay renders identically to live. Specs pin interleave
order, durations, the running arms, window fractions, and the rendered
lane.
2026-07-26 10:48:33 +08:00
imccyu 9eb9c70a8a feat(web): add workspace-aware session flow 2026-07-25 17:45:26 +08:00
Turtle fac6c35e9a Trim redundant source comments 2026-07-25 13:02:37 +08:00
07akioni 06143b1a86 fix: cr 2026-07-24 14:36:44 +08:00
07akioni 3babb2cd42 feat(trajectory): implement trajectory step cell and layout with bilingual support
- Added TrajectoryCell, TrajectoryGroupHeader, and TrajectoryTurn components for rendering trajectory steps and groups.
- Introduced bilingual support with English and Chinese translations for trajectory notes.
- Updated conversation session models to include timestamps for various message types.
- Enhanced layout logic to handle expanded assistant blocks and tool results with duration metrics.
- Added CSS styles for new components to ensure proper display and alignment.
2026-07-24 13:33:35 +08:00
imccyu d5cd73a9d9 fix(gui): CI activation order + review-bot findings
The session-title snapshot exposed a real activation race: ui-trajectory
and ui-question register into conversation-declared slots but only
injected 'slots', so nothing ordered their applies after ui-conversation's
— register() into the undeclared slot threw and the entry FAILED. Both now
inject 'conversation' as an ordering edge (documented as such; specs stub
the service where the bench declares the slot itself).

Review-bot findings, all three applied: the module loader's load sink
cross-checks the handoff id against the arriving row (a mis-stamped bundle
can no longer register under another entry's identity); the default
execute seam removes the inline script node right after its synchronous
execution (repeated HMR rebuilds no longer accumulate dead nodes); a
throwing onRebuilt subscriber is contained per-listener and routed to
onError instead of escaping the fs.watchFile callback.
2026-07-24 02:09:43 +08:00
imccyu c2e0c16d6a refactor(gui): one plugin-package shape — dshClient manifests, clientBundle preset, purity gate over all nine
Every client plugin package carries dshClient ({platform, inject,
immediately?}) and emits lib/client.js through the shared clientBundle
preset; exports["./client"] points at the bundle. The infrastructure
tier (connection, runtime, ui-theme, i18n, hmr) declares immediately: true
in its manifest — absent means lazy. The bundle purity gate covers all
nine packages: platform modules stay external, INLINE_SAFE wire layers
inline, any other cross-plugin value import is a build error. Migrations
that rule forced: scopeOf became a SessionsService method and
transportError moved into dsh-host-apiproxy's wire layer; the store
engine stays in runtime under a documented temporary exemption
(TODO(webload/store-rehome)).
2026-07-24 02:09:42 +08:00