Skip to content

feat: add chat project folders to the sidebar - #29583

Merged
jaaydenh merged 262 commits into
mainfrom
f0ssel/chat-projects-ui-folders
Oct 6, 2026
Merged

jaaydenh merged 262 commits into
mainfrom
f0ssel/chat-projects-ui-folders

Conversation

@f0ssel

@f0ssel f0ssel commented Sep 18, 2026 •

Copy link
Copy Markdown
Member
Screenshots (taken before the Oct 5 review changes)

Sidebar folders
Folder menu

Review history

The Sep 30 review threads, and where each was addressed (commit d9082fdf7c):

Thread Change
AgentCreatePage JSDoc Removed (now in #30379)
ChatsSidebar dialog trigger ref, document.activeElement, requestAnimationFrame; ProjectFolders refs Removed. Dialogs no longer restore focus by hand; the block is regrouped into state, create/edit and delete
rowMenuEvents.ts indirection; ChatTreeNode change File deleted, ChatTreeNode matches main, the guards are inline in ProjectFolders
projectChats story fixture Renamed mockProjectChats
resolveOrganization readability Split into blank-line-separated steps, nested ternary replaced with if/else (now in #30378)
ProjectComposerHeader vs footer location The footer moved to its own ProjectComposerFooter.tsx next to the header (#30379)

Also fixed from the Sep 23 review and a re-audit of all of it: a finished project delete no longer closes a newer delete dialog (regression test added); the project-specific denial copy shows only when chats are otherwise allowed; the sidebar lists the API's projects without refiltering by owner; stale comments and fixture organizations are corrected. The work is split into four PRs to address the size finding.


Generated with Coder Agents on behalf of @f0ssel.

Personal memory reused the project guidance, so the model was told to
save project people, decisions, deadlines, and links into a scope the
intro said was personal. Guidance now follows the memory scope.

Also drops the memory Storybook stories in favor of Vitest coverage of
the loading and error states.
…olidate memories in the background

The system prompt keeps only the memory guidance so it stays stable across
turns; the read_memory tool description carries the current index. After
extraction, a detached consolidation pass merges duplicates and prunes
superseded memories under strict caps (8 mutations, 24h debounce, per
scope advisory lock, fresh memories protected) and records each run in
chat_memory_consolidations, pruned to the newest 20 per scope.
…solidation in the memory section

Adds mock-based tests for the consolidation debounce, lock, cap, protect
window, journaling, pruning, and failure paths, and surfaces the newest
successful consolidation as a one-line summary under the memory list.
…tion tests

Revalidation now reads rows FOR UPDATE inside the apply transaction so an
edit committed after the reread cannot be overwritten. Candidates are the
unprotected memories oldest first, so the input cap trims recent entries
rather than the stale duplicates consolidation exists to remove. At the
cap only a run that shrank the scope bypasses the debounce. Journal
mutations are always an array.

Extraction tests use an afterMemoryExtraction seam instead of spawning
consolidation goroutines against strict mocks.
Sidebar project list with create, edit, and delete gated on the
authcheck result, a project page at /agents/projects/:projectId, new
chat in project, and move-to-project from the chat menu. Behind the
chat-projects experiment.
Collapsed memory rows expand to show the description, body, and edit
and delete controls. Delete failures surface an error alert.
Adds /agents/settings/memory with the personal memory toggle and the
per-organization memory list, and generalizes the project memory
components to serve both scopes.
Summarizes the newest successful consolidation run in one line under
the memory list.
@f0ssel f0ssel changed the title feat(site): show chat projects as sidebar folders with a project-framed composer (experiment) feat(site): add the chat projects UI (experiment) Sep 18, 2026
@f0ssel
f0ssel changed the base branch from f0ssel/chat-projects-ui to f0ssel/chat-memory-consolidation September 18, 2026 18:53
@f0ssel f0ssel added the experimental Changes that might not necessarily be merged, until its approved to proceed with. label Sep 18, 2026
@f0ssel

f0ssel commented Sep 18, 2026

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 18, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-06T14:05:37.606062Z 456d2d5 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

const isShowingEmptyState = visibleRootIDs.length === 0;

P2 Badge Render an empty state when all chats are filed

When every visible root chat is an unpinned owned chat assigned to a loaded project, grouping removes all of them from chatSections, but this check remains false because visibleRootIDs still contains those chats. With no pinned or shared chats, the Chats section consequently renders as a blank region beneath its heading. Base the empty state on the buckets actually rendered in that section, or omit the section deliberately.

AGENTS.md reference: site/AGENTS.md:L11-L11

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

…ct folder review feedback

- Show an empty state when every visible chat is filed in a project.
- Reuse the chat list empty-state copy for empty folders.
- Make the projects loading and error props required.
- Rename ProjectDialogMode to ProjectDialogState.
- Add mock prefixes to new test fixtures.
- Add stories for loading, error, and empty emoji-icon folder states.
@jaaydenh

jaaydenh commented Oct 6, 2026

Copy link
Copy Markdown
Collaborator

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5340351421

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

…lar empty state when every chat is in a project

Project chats live only in their folders, so the Chats section uses its
usual empty-state copy when nothing outside a project remains.
…folders open when navigating between projects

A folder that was open because its project was active now stays open
when the user opens a chat in another project. Only an explicit toggle
collapses a folder.
@jaaydenh

jaaydenh commented Oct 6, 2026

Copy link
Copy Markdown
Collaborator

@codex review

…t folders with the chat list

The Projects section no longer has its own bounded scroll area. It sits
in the sidebar's scroll area above the Chats section, so expanding a
folder pushes the chats down.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9b634dc727

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

…coder/coder into f0ssel/chat-projects-ui-folders

# Conflicts:
#	site/src/pages/AgentsPage/components/ChatsSidebar/chats/ChatsPanel.tsx
@jaaydenh

jaaydenh commented Oct 6, 2026

Copy link
Copy Markdown
Collaborator

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b7cfcbf11a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@jaaydenh

jaaydenh commented Oct 6, 2026

Copy link
Copy Markdown
Collaborator

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: f621f93a88

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

…s empty state while projects load

When every chat belongs to a project, those chats are held back until
the project list loads. The Chats section showed "No agents yet" in the
meantime, which falsely told users their chats did not exist.
@jaaydenh

jaaydenh commented Oct 6, 2026

Copy link
Copy Markdown
Collaborator

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 🎉

Reviewed commit: 456d2d526b

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@DanielleMaywood DanielleMaywood left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we need to start doing some code cleanup of areas this touches. They are getting too large and complex

Comment on lines 10 to 17
if (settingsMatch) {
return { panel: "settings", section: settingsMatch[1] };
}
const projectMatch = pathname.match(/^\/agents\/projects\/([^/]+)/);
if (projectMatch) {
return { panel: "chats", projectId: projectMatch[1] };
}
return { panel: "chats" };

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We so need to do this differently (pre-existing, non-blocking)

Comment on lines +345 to +354
isSubmitting={
projectDialog.mode === "edit"
? updateProjectMutation.isPending
: createProjectMutation.isPending
}
error={
projectDialog.mode === "edit"
? updateProjectMutation.error
: createProjectMutation.error
}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

kinda interesting, not sure what is happening here

readonly currentUserId: string;
};

export const ChatsPanel: React.FC<ChatsPanelProps> = ({

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This component is now too complex, we need to split it up better.

@jaaydenh
jaaydenh merged commit ee63db3 into main Oct 6, 2026
27 checks passed
@jaaydenh
jaaydenh deleted the f0ssel/chat-projects-ui-folders branch October 6, 2026 15:57
@github-actions github-actions Bot locked and limited conversation to collaborators Oct 6, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

experimental Changes that might not necessarily be merged, until its approved to proceed with.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants