feat(webview): surface inline-subtask transitions as distinct chat banners - #26
Open
easonLiangWorldedtech wants to merge 8 commits into
Open
feat(webview): surface inline-subtask transitions as distinct chat banners#26easonLiangWorldedtech wants to merge 8 commits into
easonLiangWorldedtech wants to merge 8 commits into
Conversation
Part 1/8 of the task-tree series (upstream-ready recomposition). Adds `depth` to HistoryItem and a cycle-safe `backfillTaskDepth()` that propagates parent depth through the delegation tree, so every task knows its nesting level. Depth is surfaced for later use by settings validation, environment details, and history-tree display. Includes the single-open-invariant spec mock for backfillTaskDepth (folded in from the series' CI fix) so this PR passes unit tests standalone. Depth contract hardening: - Children inherit their live parent's depth authority instead of assuming it, so a legacy non-authoritative parent never stamps its placeholder depth onto the child as a persisted fact (regression test added). - computeTaskDepth now processes an ancestor reached after exactly MAX_DEPTH_WALK hops; only strictly longer chains are rejected (boundary regression test added).
…ound-trip Part 2/8 of the task-tree series (upstream-ready recomposition). Adds two global settings that control subtask delegation: - `maxNestingDepth` (default 2, range 0-5): how many levels a subtask may nest. A value of 0 disables delegation entirely — every new_task runs inline. - `autoFlattenOnLimit` (default true): when the limit is reached, flatten the subtask into the current conversation instead of opening a new tab; when disabled such requests are rejected so you can continue directly. Full round trip: global-settings schema + defaults, ExtensionState, SettingsView control bound to cachedState with save payload, webviewMessageHandler persistence through ContextProxy, ClineProvider getState/getStateToPostToWebview, runtime consumers using the shared defaults. Includes focused tests for UI binding/save, persistence, and the saved value returned to the webview. Also completes the taskTree translation keys in all 17 non-English locales so check-translations passes standalone (folded in from the series' CI fix).
…ached (#12) Co-authored-by: Eason Liang <easonliang28@gmail.com>
Adds a three-level new_task chain e2e (root -> child -> depth-2 task) where the depth-2 task's own new_task call exceeds maxNestingDepth and is flattened inline. Asserts exactly 3 tasks exist, the flattened work completes in the depth-2 task's own conversation, parent/child resume correctly, and the task stack never holds a fourth task. Hand-written aimock fixtures (no API key needed) use unique FLATTEN_E2E_ markers with predicate matching to avoid cross-suite collisions.
…n history tree (#13) Co-authored-by: Eason Liang <easonliang28@gmail.com>
…hods (#14) Co-authored-by: Eason Liang <easonliang28@gmail.com>
Co-authored-by: Eason Liang <easonliang28@gmail.com>
…nners (#17) * feat(webview): surface inline-subtask transitions as distinct chat banners * fix(webview): localize inline-subtask banner details and task-tree settings keys --------- Co-authored-by: Eason Liang <easonliang28@gmail.com>
easonLiangWorldedtech
marked this pull request as ready for review
August 17, 2026 02:58
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part 7/8 of the task-tree series (builds on parts 1-6).
Description
Inline-subtask lifecycle events (started / rejected at limit) are surfaced as distinct, localized chat banners instead of generic tool output, and the settings view deep-links to the relevant context-management controls. All locales updated.
Test Procedure
pnpm --dir webview-ui exec vitest run src/components/chat/__tests__/ChatRow.inline-subtask.spec.tsx src/components/settings/__tests__/ContextManagementSettings.spec.tsx(deep-link cases)Pre-Submission Checklist