Skip to content

Conversation

@junaway
Copy link
Contributor

@junaway junaway commented Feb 9, 2026

Copilot AI review requested due to automatic review settings February 9, 2026 17:57
@dosubot dosubot bot added the size:L This PR changes 100-499 lines, ignoring generated files. label Feb 9, 2026
@vercel
Copy link

vercel bot commented Feb 9, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
agenta-documentation Ready Ready Preview, Comment Feb 10, 2026 11:28am

Request Review

Copy link
Contributor

@devin-ai-integration devin-ai-integration bot left a comment

Choose a reason for hiding this comment

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

Devin Review found 1 potential issue.

View 7 additional findings in Devin Review.

Open in Devin Review

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates the sidebar and legacy app APIs to support folder-based app organization and selection, addressing issues where folder assignments were not reflected/maintained.

Changes:

  • Reworks sidebar navigation to separate “project” vs “app” sections and adds an app selector dropdown that can display apps within folders.
  • Adds folder_id to legacy app conversion outputs and ensures app updates can persist folder changes.
  • Persists folder_id during artifact edits in the Postgres git DAO.

Reviewed changes

Copilot reviewed 6 out of 7 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
web/oss/src/components/Sidebar/types.d.ts Replaces header with isAppSection to split sidebar sections.
web/oss/src/components/Sidebar/hooks/useSidebarConfig/index.tsx Marks app-scoped links with isAppSection and removes the old header entry.
web/oss/src/components/Sidebar/components/SidebarMenu.tsx Removes rendering logic for the old header group item type.
web/oss/src/components/Sidebar/components/ListOfApps.tsx New dropdown to select apps via folder tree structure.
web/oss/src/components/Sidebar/Sidebar.tsx Renders project/app/bottom sections separately and inserts the app selector UI.
api/oss/src/services/legacy_adapter.py Adds folder-aware update behavior and includes folder_id in legacy App conversion.
api/oss/src/dbs/postgres/git/dao.py Writes folder_id into the artifact DB row during edits.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@mmabrouk
Copy link
Member

Closes #3694

Copy link
Member

@mmabrouk mmabrouk left a comment

Choose a reason for hiding this comment

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

Thanks @jp-agenta

I think you mistakingly mixed two PRs in one. My comments are about the second PR, I did not check the UI yet, but expected an issue (which the AI confirmed).

I suggested cleaning up this one to solve the bug, and then have maybe Ashraf or Kaosi clean up the UI for the second one.

label: (
<div className="flex items-center gap-2">
<FolderOpenOutlined style={{fontSize: 14}} />
<span className="truncate">{node.name}</span>
Copy link
Member

Choose a reason for hiding this comment

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

The truncate class on folder and app names inside the ListOfApps dropdown doesn't actually truncate anything. Ant Design's Dropdown menu has no default max-width, so the menu just stretches to fit long names. The existing ListOfProjects component solves this with max-w-[300px] on the item wrapper. ListOfApps should do the same. I've proposed edits that add max-w-[300px] and title tooltips to both folder and app labels in the dropdown.

Copy link
Member

Choose a reason for hiding this comment

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

How long names are handled
There are two places where long names appear: the dropdown trigger button and the dropdown menu items. They are handled differently, and the menu items have a gap.

The trigger button (the selected app name)
The button text is constrained by a hard max-width on the at ListOfApps.tsx:109:

<span className={clsx("truncate", collapsed ? "max-w-[52px]" : "max-w-[180px]")}>
{appLabel}

Tailwind's truncate applies overflow: hidden, text-overflow: ellipsis, and white-space: nowrap. Combined with max-w-[180px], any app name longer than about 180px of rendered text gets clipped with an ellipsis. Users can still see the full name via the native browser tooltip (title={appLabel} on line 110).

When the sidebar is collapsed, the cap drops to 52px.

The dropdown menu items (the problem)
Inside the dropdown, folder names (ListOfApps.tsx:47) and app names (ListOfApps.tsx:57) both use truncate on their elements. However, truncate alone does nothing unless the element has a constrained width. Ant Design's Dropdown menu does not enforce a max-width on its items. The menu will simply grow wider to fit the longest name.

Compare this with the existing ListOfProjects component in the same codebase, which wraps each item in a div with max-w-[300px] to make truncation work. ListOfApps does not do this.

So in practice: a very long app or folder name will cause the dropdown to stretch horizontally. The truncate class on the inner spans is effectively a no-op because nothing constrains their width.

Summary
Location Constrained? Truncation works?
Trigger button Yes (max-w-[180px]) Yes, with tooltip
Folder names in dropdown No No, menu stretches
App names in dropdown No No, menu stretches
To fix this, the dropdown menu items need a max-width on their container (similar to how ListOfProjects uses max-w-[300px]). Without it, the truncate class is decorative. Here is one way to fix it:

Edited ListOfApps.tsx(#1)
return {
key: folder:${node.id},
label: (



<FolderOpenOutlined style={{fontSize: 14}} />
{node.name}
{node.name}

),
children,
Edited ListOfApps.tsx(#2)
keyMap[key] = node.app_id
return {
key,
label: {node.app_name},
label: (

{node.app_name}

),
}
}
})
These edits add max-w-[300px] to both folder and app labels inside the dropdown (consistent with ListOfProjects), and add title attributes so users can hover to see the full name. Without the max-width constraint, the existing truncate classes were not doing anything.

Copy link
Member

Choose a reason for hiding this comment

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

@mmabrouk correct, wrong branch out.
Let me check this.
@bekossy is already doing CR / QA on the other branch

@jp-agenta jp-agenta changed the base branch from main to release/v0.85.2 February 10, 2026 11:09
@jp-agenta jp-agenta changed the base branch from release/v0.85.2 to chore/disable-name-editing-temporarily February 10, 2026 11:14
@jp-agenta jp-agenta changed the base branch from chore/disable-name-editing-temporarily to feat/add-apps-dropdown-in-side-menu February 10, 2026 11:16
@jp-agenta jp-agenta changed the base branch from feat/add-apps-dropdown-in-side-menu to release/v0.85.2 February 10, 2026 11:20
@jp-agenta jp-agenta changed the base branch from release/v0.85.2 to feat/add-apps-dropdown-in-side-menu February 10, 2026 11:22
Copilot AI review requested due to automatic review settings February 10, 2026 11:23
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

@dosubot dosubot bot added size:XS This PR changes 0-9 lines, ignoring generated files. and removed size:L This PR changes 100-499 lines, ignoring generated files. labels Feb 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working size:XS This PR changes 0-9 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants