fix: Add loading placeholder for resource card category labels - #170
Merged
Conversation
During streaming, resources may not have referral_type set yet. This caused the Remove button to collide with the card header because: - No top border was rendered - No category label was rendered Added: - Gray placeholder border (border-t-gray-300) while loading - Animated placeholder for category label with pulse animation This maintains consistent spacing before/after streaming completes. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
…al type The test expected empty string for undefined referral_type but the fix now returns a gray loading state border to maintain spacing. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Coverage report for
|
St.❔ |
Category | Percentage | Covered / Total |
|---|---|---|---|
| 🔴 | Statements | 48.73% (-0.05% 🔻) |
498/1022 |
| 🔴 | Branches | 47.69% | 196/411 |
| 🟡 | Functions | 63.51% | 94/148 |
| 🔴 | Lines | 48.51% (-0.05% 🔻) |
472/973 |
Show files with reduced coverage 🔻
St.❔ |
File | Statements | Branches | Functions | Lines |
|---|---|---|---|---|---|
| 🟢 | ... / ResourcesList.tsx |
97.22% (-0.08% 🔻) |
96.97% | 100% | 97.06% (-0.08% 🔻) |
Test suite run success
95 tests passing in 8 suites.
Report generated by 🧪jest coverage report action from f094be2
michelle-hadfield-nava
approved these changes
Jan 29, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Problem
During streaming, resources may not have
referral_typeset yet, causing:Solution
Added default cases in both functions:
getCardBorderClass: Returns gray border (border-t-gray-300) while loadingreferralTypeIndicator: Returns animated skeleton placeholder with pulse animationTest plan
🤖 Generated with Claude Code
Preview environment for app
♻️ Environment destroyed ♻️
Preview environment for frontend