Skip to content

fix: prioritize selectable library search cards - #6972

Merged
matthewevans merged 1 commit into
mainfrom
ship/fix-prioritize-selectable-library-search-cards
Aug 3, 2026
Merged

fix: prioritize selectable library search cards#6972
matthewevans merged 1 commit into
mainfrom
ship/fix-prioritize-selectable-library-search-cards

Conversation

@matthewevans

@matthewevans matthewevans commented Aug 3, 2026

Copy link
Copy Markdown
Member

Summary by CodeRabbit

  • Improvements
    • Search results now show selectable cards before cards that cannot be selected.
    • Ineligible cards remain visible but are clearly marked as disabled with grayscale styling.
    • Duplicate cards continue to be removed from the results.

@matthewevans
matthewevans enabled auto-merge August 3, 2026 17:59
@coderabbitai

coderabbitai Bot commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: d5d66b93-8852-4a85-86e7-0c8f6ac7b7fb

📥 Commits

Reviewing files that changed from the base of the PR and between 470b0bf and 4fd3c74.

📒 Files selected for processing (2)
  • client/src/components/modal/CardChoiceModal.tsx
  • client/src/components/modal/__tests__/SearchChoiceModal.test.tsx

📝 Walkthrough

Walkthrough

Search results now place selectable cards before other looked-at cards. Non-selectable cards remain disabled and now use grayscale styling. Tests verify the ordering and disabled state.

Changes

Search card selection

Layer / File(s) Summary
Search card ordering and styling
client/src/components/modal/CardChoiceModal.tsx
SearchModal places legal cards before other looked-at cards while preserving deduplication and disabled state. Non-selectable cards use grayscale styling.
Search card ordering coverage
client/src/components/modal/__tests__/SearchChoiceModal.test.tsx
The test verifies that the selectable card appears before the disabled ineligible card.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Suggested reviewers: andriypolanski, lgray, ntindle

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the main change: prioritizing selectable cards in library search results.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch ship/fix-prioritize-selectable-library-search-cards

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

@matthewevans
matthewevans added this pull request to the merge queue Aug 3, 2026
Merged via the queue into main with commit ec19b52 Aug 3, 2026
15 checks passed
@matthewevans
matthewevans deleted the ship/fix-prioritize-selectable-library-search-cards branch August 3, 2026 18:38
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.

1 participant