Skip to content

feat(ui): make Pulse component collapsible - #340

Merged
2witstudios merged 2 commits into
masterfrom
claude/collapsible-pulse-jifD9
Feb 3, 2026
Merged

2witstudios merged 2 commits into
masterfrom
claude/collapsible-pulse-jifD9

Conversation

@2witstudios

@2witstudios 2witstudios commented Feb 2, 2026 •

Copy link
Copy Markdown
Owner

Add collapsible functionality to the Pulse summary component:

  • Wrap content in Radix UI Collapsible component
  • Add ChevronDown icon with rotation animation
  • Persist collapse state in useLayoutStore with localStorage
  • Keep refresh button accessible in collapsed header
  • Update skeleton to match new structure

https://claude.ai/code/session_015mCMx2j2yFwjFnzWHiTFEX

Summary by CodeRabbit

Release Notes

  • New Features
    • The Pulse panel is now collapsible, allowing you to expand and collapse it as needed.
    • Added a refresh button and collapse indicator in the panel header.
    • Your collapse preference is saved and restored across sessions.

Add collapsible functionality to the Pulse summary component:
- Wrap content in Radix UI Collapsible component
- Add ChevronDown icon with rotation animation
- Persist collapse state in useLayoutStore with localStorage
- Keep refresh button accessible in collapsed header
- Update skeleton to match new structure

https://claude.ai/code/session_015mCMx2j2yFwjFnzWHiTFEX
@coderabbitai

coderabbitai Bot commented Feb 2, 2026 •

Copy link
Copy Markdown
Contributor

Warning

Rate limit exceeded

@2witstudios has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 28 minutes and 52 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

📝 Walkthrough

Walkthrough

The Pulse panel UI component has been refactored to support collapsible functionality. A static card layout was replaced with a Collapsible component wrapper, the refresh button was restructured into an icon button group with a rotating chevron indicator, and collapse state is now persisted via a new layout store field.

Changes

Cohort / File(s) Summary
Pulse Panel Collapsible UI
apps/web/src/components/layout/left-sidebar/Pulse.tsx
Restructured Pulse panel to use Collapsible component with collapsed/expanded states. Replaced standalone Refresh button with RefreshCw icon button and rotating ChevronDown indicator. Updated PulseSkeleton styling to align with new layout structure including action icon placeholders.
Layout Store State Management
apps/web/src/stores/useLayoutStore.ts
Added pulseCollapsed boolean field to LayoutState with default value false. Introduced setPulseCollapsed setter method. Configured state persistence via partialize to retain collapse state across sessions.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Poem

🐰 A panel that folds, a chevron that spins,
State persists through the store where it grins,
Collapsible magic, expand and collapse,
No more static panels caught in a gap! ✨

🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ 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%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ 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 summarizes the main change: adding collapsible functionality to the Pulse component. It is concise, specific, and directly reflects the primary objective of the pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch claude/collapsible-pulse-jifD9

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

@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: 506a9e3337

ℹ️ 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".

Comment thread apps/web/src/components/layout/left-sidebar/Pulse.tsx Outdated

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In `@apps/web/src/components/layout/left-sidebar/Pulse.tsx`:
- Around line 88-118: The CollapsibleTrigger Button currently contains another
interactive Button (the refresh control), creating invalid nested <button>
elements; move the refresh control out of the CollapsibleTrigger so the DOM
renders two sibling controls instead of a button inside a button. Concretely: in
the JSX that uses CollapsibleTrigger and Button (symbols: CollapsibleTrigger,
Button, RefreshCw, handleRefresh, isGenerating, pulseCollapsed, cn), render the
CollapsibleTrigger as the main trigger Button containing the "Pulse" heading and
the ChevronDown only, and render the refresh Button as a sibling element
immediately adjacent to that trigger (keeping its onClick with
e.stopPropagation(), disabled={isGenerating}, title/aria-label and the RefreshCw
icon with the animate-spin class). Ensure styling/layout classes are adjusted so
the two controls appear in the same row and the refresh click does not toggle
the collapsible.

Comment thread apps/web/src/components/layout/left-sidebar/Pulse.tsx Outdated
… buttons

Addresses review feedback from CodeRabbit and Codex about invalid HTML
caused by nesting a Button inside the CollapsibleTrigger Button.

Changes:
- Wrap trigger and refresh button in a flex container
- Move refresh button outside CollapsibleTrigger as a sibling element
- Adjust styling to maintain the same visual layout
- Add aria-label for accessibility
@2witstudios
2witstudios merged commit bdfd191 into master Feb 3, 2026
3 checks passed
@2witstudios
2witstudios deleted the claude/collapsible-pulse-jifD9 branch February 6, 2026 01:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants