Fix: use unfiltered total count for EmptyState; stable scroll handler…#527
Conversation
|
Someone is attempting to deploy a commit to the ritik4ever's projects Team on Vercel. A member of the Team first needs to authorize it. |
|
Caution Review failedFailed to post review comments 📝 WalkthroughWalkthroughThis PR adds an ChangesStreams UI, Controls, and Metrics
IssueBacklog Simplification
Build and Configuration Updates
Sequence Diagram(s)sequenceDiagram
participant User
participant App
participant CreateStreamForm
participant StreamsTable
participant EmptyState
participant API
User->>App: Apply filter (status/sender/etc)
App->>StreamsTable: Pass filtered results + totalStreamCount
StreamsTable->>StreamsTable: Filter list empty && totalStreamCount > 0?
StreamsTable->>EmptyState: Render with active filter context
EmptyState->>User: Show "No streams for [filter]" + "Clear Filters"
User->>EmptyState: Click "Clear Filters"
EmptyState->>App: onClearFilters()
App->>API: Fetch streams (no filter)
API-->>App: Full stream list
App->>StreamsTable: Pass all results
StreamsTable->>User: Display table or empty state
User->>StreamsTable: Click timeline toggle
StreamsTable->>App: toggleTimeline() → onOpenStream(id)
App->>User: Open stream detail
User->>CreateStreamForm: Submit new stream
CreateStreamForm->>API: POST /streams
API-->>App: Success
App->>App: Refresh filtered streams + totalUnfilteredCount
App->>App: scrollToCreateStream()
App->>User: Scroll to form, show success toast
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Poem
🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
|
@boalambo Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@frontend/src/components/StreamsTable.tsx`:
- Around line 219-225: The inline timeline expansion state (expandedStreamId) is
never toggled because toggleTimeline is not wired to the row button/StreamRow;
currently the expand button calls onOpenStream directly so isExpanded remains
false and the expanded timeline never renders. Fix by wiring toggleTimeline into
the row open handler (pass toggleTimeline into StreamRow or have the expand
button call toggleTimeline(streamId) instead of onOpenStream(streamId)) so
setExpandedStreamId runs and isExpanded becomes true; note toggleTimeline
already invokes onOpenStream(streamId) so the drawer will still open—if you want
inline-only expansion, remove that onOpenStream call from toggleTimeline, or
conversely remove expandedStreamId/toggleTimeline and the isExpanded timeline
row if only the drawer UX is desired.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: a90352b4-3d74-460a-a01f-802d00b8f1b7
📒 Files selected for processing (4)
frontend/src/App.tsxfrontend/src/components/EmptyState.tsxfrontend/src/components/StreamsTable.test.tsxfrontend/src/components/StreamsTable.tsx
|
👋 Friendly bump! This PR is ready for review. CodeRabbit and CI checks passed. Let me know if any adjustments are needed. Payment: USDC Stellar |
Hi! I noticed contributors are including a payment address in their PR comments. Should I add the new payment address as well? |
…e tests from tsc; guard VitePWA in CI; add StreamsTable optional props
Closes #398
…; tests
What changed
Testing done
Related issues
Closes #
Checklist
Summary by CodeRabbit
New Features
Bug Fixes
Tests
Refactor
Chores