Commit Graph
25 Commits
Author SHA1 Message Date
Yichen Jiang dacbc37209 Merge remote-tracking branch 'origin/master' into feat/forge-review-threads
# Conflicts:
#	docs/config-catalog.md
#	docs/config-catalog.zh.md
#	packages/experimental/client-ui-forge/README.i18n.yaml
#	packages/experimental/client-ui-forge/README.md
#	packages/experimental/client-ui-forge/README.zh.md
#	packages/experimental/client-ui-forge/src/client/ChangesTab.tsx
#	packages/experimental/client-ui-forge/src/client/DiffFile.tsx
#	packages/experimental/forge-github/README.i18n.yaml
#	packages/experimental/forge-github/README.md
#	packages/experimental/forge-github/README.zh.md
#	packages/experimental/forge/README.i18n.yaml
#	packages/experimental/forge/src/index.ts
#	packages/extensions/tool-cordis/src/api-catalog.ts
2026-11-09 14:28:39 +08:00
Yichen Jiang e7e5ed638d Merge remote-tracking branch 'origin/master' into feat/forge-review-threads
# Conflicts:
#	apps/web/tests/forge-panel.e2e.ts
#	packages/experimental/client-ui-forge/README.i18n.yaml
#	packages/experimental/client-ui-forge/src/client/DiffFile.tsx
#	scripts/type-equiv.manifest.json
2026-11-09 11:38:53 +08:00
Yichen Jiang b07f93af18 feat(forge-panel): filter review threads by resolution and fit the thread list to narrow views
The thread list chooses Unresolved, Resolved, or All in the segmented radio group the lens uses, and drops the
Outdated and Awaiting my reply filters with the Awaiting my reply tag. Its footer keeps only View on GitHub, after a
note when the read was truncated, and each file group names the file before its directory.

The list's width rules queried the changes view's container by name, which CSS Modules rename per file, so they never
applied and a narrow view squeezed the files beside a 320px list. The rules now query the nearest container: a view
at least 1040px wide docks the list; a narrower one floats it over the files with a scrim, moves the focus into it,
and closes it before opening a thread; below 480px it takes the files' whole width with Back to changes. Escape, the
scrim, and the close actions return the focus to the Threads button. Below 480px a file header shows the unresolved
count alone and thread cards keep 6px margins.
2026-11-07 16:46:56 +08:00
Yichen Jiang d4a2df736b Merge remote-tracking branch 'origin/master' into perf/forge-changes-view 2026-11-07 16:22:57 +08:00
Yichen Jiang 1754e2ea98 perf(forge-panel): draw only what changes and what the reader reaches
- Read a change request's patch and .gitattributes together.
- Publish a panel state only when it differs from the published one.
- File sections receive stable values and redraw only when theirs change;
  tab visibility reaches only the menus that need it.
- An expanded file draws its lines once its section comes within reach of
  the scrollport, and highlights them in idle time in bounded fragments,
  again only when its segments or its language's grammar change.
- A jumped-to file stays aligned while the sections around it draw.
2026-11-07 16:22:26 +08:00
Yichen Jiang 63e00f87ec fix(forge): keep narrow file header actions inside the card
The card's overflow clip cut off the viewed mark and the file menu when a
narrow header also held a long path, the changed tag, and a rename badge;
before the cards, the list could still scroll sideways to them.

The icon, path, changed tag, and badge now share one box that shrinks to
any width, so the counts, the viewed mark, and the menu after it stay
whole. The path and badge shorten in proportion to their widths, the
changed tag is capped at 30% of the box with an ellipsis, and the path
keeps its full-path tooltip.

A 390px e2e renames a long file, changes it after it is marked viewed,
and checks that the mark and menu stay inside the card, the mark still
toggles, and hovering the name shows both paths.
2026-11-07 15:46:36 +08:00
Yichen Jiang a39bcaec12 feat(forge-panel): overlay GitHub review threads on the changes view
Threads read at the shown head sit under the row of their last line, or
after the collapsed lines that hold it; resolved threads fold into one
row, file threads open their file, and outdated threads gather after the
lines with the end of their recorded hunk and the file at the commit
they were written on. Chosen commits place only new-side threads whose
lines number the last chosen commit.

The file tree and file headers count unresolved threads, and a thread
list filters unresolved, outdated, resolved, and awaiting-my-reply
threads by file and opens each at its place. A thread offers only Add to
input, which quotes the whole thread, and View on GitHub.
2026-11-07 14:28:39 +08:00
Yichen Jiang e2237f26b9 feat(forge): show each changed file as a card
A file's trailing collapsed-context strip, the next file's header, and that file's leading strip read as three adjacent rows, so the boundary between files was hard to see. Each file is now a card with an R16 border and a gap before the next one, and its header takes a tint over the view background. The header still sticks to the top of the scroll area while its lines scroll, flush with the edge rather than inside the list's padding. The collapsed-context strips keep their style.

Resolves #8104
2026-11-07 14:23:33 +08:00
Yichen Jiang c313392bf8 feat(forge-panel): review changes by layer, mark files viewed, and view chosen commits
The changes view gains a lens of All, Interface, Implementation, and Tests
that spans the file tree above it, a switch that hides test files from the
tree and the diff, and a viewed checkbox on each file header that collapses
the file. The toolbar counts viewed files and V toggles the file being read.
Marks are kept per Session, source, path, and change digest in browser
storage, so a file that changes again reads as changed since viewed. All
commits beside Submit review, and beside the base branch of the Branch scope,
shows one commit or a Shift run of commits.
2026-11-06 17:51:22 +08:00
Yichen Jiang a012eef69a fix(forge): keep comment pluses reachable in unified rows and refuse stale presses
In unified rows that show both line numbers, the left plus now moves past the right number into the sign column, where the right plus already sits. It paints above that number's padding, the sticky file header stays above it, and a row that shows the labeled plus offers no second hover plus. The labeled plus of a left context line is reachable again, and a deleted line's plus no longer jumps one column.

A drag that starts on a hover plus extends through every row with a line on its starting side, wherever the pointer crosses the row. A press whose range is refused, such as Shift across hunks, keeps the previous selection and no longer opens the editor for it on release.

The README describes the checks mark as the filled head branch end.

Refs #7937
2026-11-05 16:27:33 +08:00
Yichen Jiang 4b07f24d8a feat(forge): open inline comments from a hover plus and restyle the checks mark
Show a comment plus beside the line number of the hovered diff line. Pressing it selects the line, dragging extends the range on that side, and releasing opens the editor, replacing the separate select and plus clicks for mouse users. Touch and keyboard users keep the existing path through the line number. Two-column code reserves an empty lane for the plus, so the number and the code stay reachable.

Draw the Session row's checks outcome inside the change request glyph as a filled head branch end, smaller and without the ring, so it cannot drift from the glyph's outline.

Refs #7937
2026-11-05 15:05:08 +08:00
Turtle 2099 0f9a7601ce Merge pull request #6888 from deepseek-harness/turtle/icons-plugin-tokens-e20dec90761c
refactor(client): route feature colors through theme aliases
2026-11-05 11:25:51 +08:00
Yichen Jiang fcc1becf11 feat(forge): choose the base branch of local changes
The Branch scope of the local changes view compared only with the
automatic fork point. Its header now names the checked-out branch and a
searchable base branch menu that lists the automatic fork point, then
remote-tracking and local branches; a chosen branch compares with its
merge base with HEAD. The choice lives in the view tab, a missing or
unrelated branch offers the default instead of a retry, and local Branch
review quotes name the base they were compared with.

Refs #7781
2026-11-03 13:49:13 +08:00
Yichen Jiang 50f3f50e1e fix(forge): preserve review position across hidden layouts 2026-10-28 14:51:04 +08:00
Yichen Jiang cf29844580 feat(forge): navigate diff files with horizontal arrow keys 2026-10-28 14:03:33 +08:00
Yichen Jiang aab3033c37 Merge master into worktree/forge-ui-polish 2026-10-28 13:16:42 +08:00
Yichen Jiang 3ac8daef66 fix(forge): clarify worktree controls and align change panels 2026-10-28 12:34:58 +08:00
Yichen Jiang bd1c30cd81 feat(forge): add file tree and inline review comments 2026-10-28 11:42:45 +08:00
Yichen Jiang 17b9e1536d fix(forge): release inactive diff subscriptions and menus 2026-10-27 10:46:40 +08:00
Yichen Jiang c1b1d9b71f fix(forge): keep retained diffs from scroll anchoring on session switches 2026-10-26 22:08:57 +08:00
Yichen Jiang 57716b544f fix(forge): preserve diff review state and copy header paths 2026-10-26 21:44:38 +08:00
Yichen Jiang 4b07c32b93 fix(forge): follow master's hover, tooltip, and plugin metadata rules
Master now limits CSS hover styles to hover-capable primary input, opens
tooltips from pointer events, requires a model on every Agent and a model
selection on agent/pre-step, and requires Japanese plugin metadata.

- The panel's hover styles move under @media (hover: hover); expanded,
  pressed, and focus-visible styles stay outside it.
- The hover tests enter with pointer events.
- The test Agent carries an unsupported model, and proposed steps carry a
  model selection.
- The panel and the forge bundle ship Japanese titles and descriptions.
2026-10-22 17:45:15 +08:00
Yichen Jiang 2ee6dfb671 feat(forge): name changed files before their directories and drop the header branch label
The changes view cut each changed path from its end, so a long path lost
its file name, and the Session header's branch label crowded the actions
beside the title.

- A changed file in the files menu, a file's header, and the local
  changes card shows its name, then its directory in smaller subdued
  type. The directory shortens first, then the name shortens in the
  middle and keeps its end; hovering shows the complete path, and both
  paths of a renamed file. Assistive technology reads the complete path.
  A rename badge names the old file name, or the old path when only the
  directory changed.
- The checkout row draws a folder for the project directory and a
  branch for a worktree.
- The Session header no longer carries the branch label; the tab's
  checkout row names the branch, the kind of checkout, and its path.
- The README describes the collapsed strip of a large file, and the
  forge bundle README lists the gh commands and branches that bind
  change requests.
2026-10-20 18:15:10 +08:00
Yichen Jiang 891ea9bd33 feat(forge): show a collapsed large file as the strip of unchanged lines
A large file in the changes view started behind a notice and an outlined
button. It now starts as one strip drawn and opened like the collapsed
unchanged lines, which names its changed line count. Binary files and
files too large to show use the same strip without an action.
2026-10-20 14:30:46 +08:00
Yichen Jiang d0fc1f6458 feat(forge): show the changes of a Session and of its change requests
The forge panel opens a changes view in the right sidebar for the
checkout's local changes and for the diff of each change request.

- ForgePanelController reads local diffs in the branch, uncommitted,
  unstaged, and staged scopes through Git in the Session's read-only
  sandbox, change request diffs through the forge provider, and the text
  of a changed file to expand unchanged lines. Change request patches stay
  cached by head commit and base branch within maxCachedDiffBytes. A local
  diff over maxDiffBytes fails as forgePanel/diff-too-large, and a provider
  read over its output limit fails as too-large, which the view explains
  with a link to the code host; a gh timeout fails as unavailable.
- forge adds the diff, fileText, and fileUrl provider methods and the
  too-large failure code, and forge-github implements them with gh.
- The panel shows a local changes card that opens the view and asks the
  Agent for a change request. The view collapses files past a line
  budget, draws lines side by side or in one column with optional
  wrapping, expands unchanged lines on request, and collapses or expands
  every file from its toolbar; file headers use a bare chevron.
- The checkout row copies the worktree or project directory path, the
  refresh glyph turns while a refresh runs, change request cards keep
  their actions while collapsed, and the header entry uses the shared
  compact button.
- client-ui-forge classifies changeRequestKey and FsError as
  peer-required Host imports, which keeps forge and dsh-fs as its peers.
2026-10-20 13:34:27 +08:00