Skip to content

Conversation

@Shironex
Copy link
Collaborator

@Shironex Shironex commented Dec 22, 2025

Summary by CodeRabbit

  • Refactor
    • Improved the layout and organization of agent information display on cards, repositioning phase and model information for better visual hierarchy.
    • Restructured the Summary section for clearer presentation of approval and verification status.
    • Enhanced dialog availability to ensure consistent access when needed.

✏️ Tip: You can customize this high-level summary in your review settings.

@Shironex Shironex self-assigned this Dec 22, 2025
@coderabbitai
Copy link

coderabbitai bot commented Dec 22, 2025

Walkthrough

This change restructures how the AgentInfoPanel component renders content for non-backlog cards, transitioning from a single div container to a fragment wrapper, repositioning the currentPhase badge alongside the model badge, and consolidating the Summary section inline with improved structural organization.

Changes

Cohort / File(s) Summary
Agent Info Panel Component (UI restructuring)
apps/ui/src/components/views/board-view/components/kanban-card/agent-info-panel.tsx
Reorganized rendering structure from div wrapper to fragment; moved currentPhase badge inline with model badge; reflowed Task List Progress section; consolidated Summary block with cohesive inline layout; ensured SummaryDialog is accessible even when agentInfo is not yet loaded.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

  • Verify structural refactoring: Ensure the fragment wrapper maintains all previous behavior and doesn't introduce unintended layout shifts
  • Conditional rendering logic: Confirm the phase badge appears only when agentInfo.currentPhase exists and placement alongside the model badge is correct
  • Summary block consolidation: Review the inline grouping with header row and Expand button for correct event binding and dialog integration
  • SummaryDialog mounting: Confirm the dialog is properly mounted and accessible even when agentInfo is not yet loaded

Poem

🐰 The cards now flow in fragments bright,
Phase badges dancing side-by-side,
Summary consolidated, oh what a sight!
Structure refined with careful stride,
Hop hop! The panel's reorganized with pride ✨

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main fix: resolving an issue where the summary modal/dialog was not appearing when users clicked the button in the kanban card, which aligns with the primary changes reorganizing SummaryDialog rendering.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch fix/summary-modal-issue

Comment @coderabbitai help to get the list of available commands and usage tips.

@Shironex Shironex added the Bug Something isn't working label Dec 22, 2025
@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @Shironex, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request resolves a critical bug where the summary modal failed to appear when triggered from a Kanban card. The fix involves restructuring the rendering of the SummaryDialog component to prevent it from being inadvertently hidden by parent container styles, thereby ensuring the modal displays as intended.

Highlights

  • Summary Modal Visibility Fix: The SummaryDialog component, responsible for displaying the summary modal, was moved out of a parent div that had overflow-hidden styling. This change ensures the modal renders correctly without being clipped.
  • Event Propagation Prevention: Added onPointerDown and onMouseDown event handlers to the expand summary button to explicitly stop event propagation, preventing unintended interactions with parent elements.

🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console.

Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request fixes an issue where the summary modal was not appearing when its button was clicked on a Kanban card. The fix correctly moves the SummaryDialog component to be rendered alongside the button that triggers it, ensuring it's available in the DOM when needed. The change is logical and effectively resolves the bug. I've added one suggestion to improve the key usage in a list rendering for better stability.

</div>
<div className="space-y-0.5 max-h-16 overflow-y-auto">
{agentInfo.todos.slice(0, 3).map((todo, idx) => (
<div key={idx} className="flex items-center gap-1.5 text-[10px]">
Copy link
Contributor

Choose a reason for hiding this comment

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

medium

Using the array index as a key can lead to performance issues and bugs with dynamic lists. Since todo.content is treated as unique in the parsing logic, it should be used as the key to provide a stable identity to each element.

Suggested change
<div key={idx} className="flex items-center gap-1.5 text-[10px]">
<div key={todo.content} className="flex items-center gap-1.5 text-[10px]">

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (2)
apps/ui/src/components/views/board-view/components/kanban-card/agent-info-panel.tsx (2)

207-219: Consider simplifying event handlers.

The expand button uses three different event handlers (onClick, onPointerDown, onMouseDown) all calling stopPropagation(). The onPointerDown handler should be sufficient for modern browsers as it handles both mouse and touch events. Consider simplifying to:

onClick={(e) => {
  e.stopPropagation();
  setIsSummaryDialogOpen(true);
}}

The current implementation works but the redundant handlers add unnecessary code.

🔎 Proposed refactor
 <button
   onClick={(e) => {
     e.stopPropagation();
     setIsSummaryDialogOpen(true);
   }}
-  onPointerDown={(e) => e.stopPropagation()}
-  onMouseDown={(e) => e.stopPropagation()}
   className="p-0.5 rounded-md hover:bg-muted/80 transition-colors text-muted-foreground/60 hover:text-muted-foreground shrink-0"
   title="View full summary"
   data-testid={`expand-summary-${feature.id}`}
 >
   <Expand className="w-3 h-3" />
 </button>

207-219: Add accessible label for screen readers.

The expand button is icon-only and relies solely on the title attribute for its description. Consider adding an aria-label to improve accessibility for screen reader users:

aria-label="View full summary"
🔎 Proposed improvement
 <button
   onClick={(e) => {
     e.stopPropagation();
     setIsSummaryDialogOpen(true);
   }}
   onPointerDown={(e) => e.stopPropagation()}
   onMouseDown={(e) => e.stopPropagation()}
   className="p-0.5 rounded-md hover:bg-muted/80 transition-colors text-muted-foreground/60 hover:text-muted-foreground shrink-0"
   title="View full summary"
+  aria-label="View full summary"
   data-testid={`expand-summary-${feature.id}`}
 >
   <Expand className="w-3 h-3" />
 </button>
📜 Review details

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 6a8b206 and 4cff240.

📒 Files selected for processing (1)
  • apps/ui/src/components/views/board-view/components/kanban-card/agent-info-panel.tsx
🧰 Additional context used
🧬 Code graph analysis (1)
apps/ui/src/components/views/board-view/components/kanban-card/agent-info-panel.tsx (3)
apps/ui/src/lib/agent-context-parser.ts (2)
  • formatModelName (35-40)
  • DEFAULT_MODEL (30-30)
apps/ui/src/lib/utils.ts (1)
  • cn (5-7)
apps/ui/src/components/views/board-view/components/kanban-card/summary-dialog.tsx (1)
  • SummaryDialog (23-68)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: e2e
🔇 Additional comments (5)
apps/ui/src/components/views/board-view/components/kanban-card/agent-info-panel.tsx (5)

131-154: Good structural improvement!

The change from a single container div to a fragment wrapper is appropriate and allows better flexibility in rendering. The conditional rendering of the phase badge (line 139) prevents displaying empty badges when currentPhase is undefined.


157-195: LGTM!

The task list progress section is well-structured with proper status indicators, limited display for better UX (first 3 tasks), and clear visual feedback for different task states.


198-244: Well-structured summary section!

The conditional rendering handles both summary display and the no-summary fallback gracefully. Good use of line-clamp-3 for truncation and proper spacing/borders for visual separation.


247-253: Core fix for the modal issue!

Rendering the SummaryDialog within the same fragment as the expand button ensures the dialog component is mounted in the React tree when the button is clicked. This properly addresses the PR objective where the modal was not appearing.

The comment at line 246 correctly documents the intent.


260-272: Defensive coding for edge case handling.

This fallback ensures the SummaryDialog remains mounted even if agentInfo temporarily becomes null during a re-render (e.g., during loading state transitions). This prevents the dialog from unmounting unexpectedly if a user has already opened it.

While this adds a small overhead, it's good defensive coding that handles edge cases where state might be in flux during async data loading.

@webdevcody webdevcody merged commit 59cb48b into main Dec 22, 2025
9 checks passed
@webdevcody webdevcody deleted the fix/summary-modal-issue branch December 22, 2025 19:21
@coderabbitai coderabbitai bot mentioned this pull request Jan 4, 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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants