Skip to content

feat(history): render nested subtasks as recursive tree#11299

Merged
hannesrudolph merged 3 commits intomainfrom
feat/history-nested-subtask-tree
Feb 8, 2026
Merged

feat(history): render nested subtasks as recursive tree#11299
hannesrudolph merged 3 commits intomainfrom
feat/history-nested-subtask-tree

Conversation

@hannesrudolph
Copy link
Collaborator

@hannesrudolph hannesrudolph commented Feb 8, 2026

Summary

image

Add recursive subtask rendering to the History UI so nested subtasks can be expanded and navigated at arbitrary depth using the existing visual pattern.

Changes

  • Introduce a recursive subtask tree model (SubtaskTreeNode) and recursive counter utility (countAllSubtasks) in history types.
  • Refactor grouped task construction to build nested subtask trees via buildSubtree while preserving root-level grouping and search behavior.
  • Update history rendering to support nested expand/collapse and depth-based indentation in TaskGroupItem and SubtaskRow.
  • Wire nested toggle handlers through history containers (HistoryView, HistoryPreview).
  • Add a new unit test suite for nested row behavior (SubtaskRow.spec.tsx).
  • Expand existing tests for grouped task tree construction and recursive subtask counts.
  • Update task group tests to validate nested rendering and recursive counts.

Verification

  • cd webview-ui && npx vitest run src/components/history/tests/useGroupedTasks.spec.ts src/components/history/tests/TaskGroupItem.spec.tsx src/components/history/tests/SubtaskRow.spec.tsx

@dosubot dosubot bot added size:XL This PR changes 500-999 lines, ignoring generated files. Enhancement New feature or request labels Feb 8, 2026
@roomote
Copy link
Contributor

roomote bot commented Feb 8, 2026

Rooviewer Clock   See task

Re-reviewed after f8ff70f. Both previously flagged issues are now resolved. No new issues found.

  • HistoryView.tsx: Duplicate countAll function -- reuse the exported countAllSubtasks from types.ts instead of redefining it locally.
  • SubtaskRow.tsx: max-h-[500px] on the nested children container may clip expanded content for nodes with many subtasks. Consider increasing to match the max-h-[2000px] used in TaskGroupItem.
Previous reviews

Mention @roomote in a comment to request specific changes to this pull request or fix all unresolved issues.

…ax-h

- HistoryView: replace local countAll with imported countAllSubtasks from types.ts
- SubtaskRow: increase nested children max-h from 500px to 2000px to match TaskGroupItem
@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Feb 8, 2026
@hannesrudolph hannesrudolph merged commit 7db4bfe into main Feb 8, 2026
13 checks passed
@hannesrudolph hannesrudolph deleted the feat/history-nested-subtask-tree branch February 8, 2026 04:39
@github-project-automation github-project-automation bot moved this from New to Done in Roo Code Roadmap Feb 8, 2026
roomote bot pushed a commit that referenced this pull request Feb 8, 2026
* feat(history): render nested subtasks as recursive tree

* fix(lockfile): resolve missing ai-sdk provider entry

* fix: address review feedback — dedupe countAll, increase SubtaskRow max-h

- HistoryView: replace local countAll with imported countAllSubtasks from types.ts
- SubtaskRow: increase nested children max-h from 500px to 2000px to match TaskGroupItem
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Enhancement New feature or request lgtm This PR has been approved by a maintainer size:XL This PR changes 500-999 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants