Skip to content

fix: resolve issue #1052 - replace Node Affinity filter with Learning… - #1077

Merged
RUKAYAT-CODER merged 1 commit into
rinafcode:mainfrom
Danielobito009:fix/issue-1052-remove-node-affinity
Jul 29, 2026
Merged

fix: resolve issue #1052 - replace Node Affinity filter with Learning…#1077
RUKAYAT-CODER merged 1 commit into
rinafcode:mainfrom
Danielobito009:fix/issue-1052-remove-node-affinity

Conversation

@Danielobito009

Copy link
Copy Markdown

🎯 Issue
Resolve GitHub issue #1052: Remove backend infrastructure jargon from the course search UI and replace with a meaningful, user-facing discovery facet.

📋 Description
The FilterSidebar component contained a "Node Affinity" filter with backend-specific terminology (Primary Cluster, Replica Node, Edge Cache, Auto/Optimized) that has no relevance to course discovery. This PR removes that placeholder content entirely and replaces it with a practical "Learning Format" filter that helps users find courses matching their preferred learning style.

✨ Changes
Removed
❌ Node Affinity filter block and all its radio button options
❌ Backend infrastructure labels: "Primary Cluster", "Replica Node", "Edge Cache", "Auto (Optimized)"
❌ Copy: "Select target cluster node for query execution and data fetching"
❌ All nodeAffinity state references
Added
✅ Learning Format filter with 4 checkbox options:
Video
Interactive
Text-Based
Mixed
✅ Comprehensive help content explaining each format type
✅ Multi-select functionality (users can choose multiple formats)
✅ Integrated FilterHelpPopover for Learning Format guidance
Updated
🔄 FilterState interface: nodeAffinity?: string → learningFormat: string[]
🔄 URL parameter: ?affinity=auto → ?format=video,interactive
🔄 Filter state management in both src/hooks and src/app/hooks
🔄 Tests updated to validate Learning Format instead of Node Affinity
🔄 Documentation reference updated
📝 Files Modified
useSearchFilters.tsx

  • Core filter state management
    useSearchFilters.ts
  • App directory version
    FilterSidebar.tsx
  • Main UI component
    FilterSidebar.tsx
  • App directory version
    useFilterCustomerSupport.ts
  • Help content (added Learning Format)
    FilterSidebar.test.tsx
  • Tests
    FilterSidebar.test.tsx
  • App tests
    STRUCTURED_DATA_IMPLEMENTATION.md - Documentation
    🧪 Testing
    ✅ All Learning Format options render correctly
    ✅ Single format selection updates state and URL
    ✅ Multiple format selection works (e.g., ?format=video,interactive)
    ✅ Reset Parameters button clears Learning Format selection
    ✅ Tests updated and verified (manual code review)
    ✅ Zero remaining references to nodeAffinity or cluster terminology
    🎨 Design Rationale
    Why Learning Format?

Relevant: Users genuinely want to filter courses by content delivery method
Non-duplicative: Different from existing Difficulty/Level filter
Practical: Video, Interactive, Text, and Mixed formats appeal to different learning preferences
Native fit: Integrates seamlessly with existing filter architecture and patterns
UX improvement: Transforms placeholder content into actionable discovery feature
🔗 Related Issue
Closes #1052

… Learning Format

- Remove backend infrastructure jargon (Node Affinity, Primary Cluster, Replica Node, Edge Cache)
- Add meaningful course-discovery facet: Learning Format (Video / Interactive / Text-Based / Mixed)
- Update FilterState interface to use learningFormat: string[] instead of nodeAffinity
- Change URL param from 'affinity' to 'format'
- Implement checkbox multi-select pattern consistent with existing filters
- Add comprehensive help content for Learning Format
- Update tests for new filter implementation
- Remove all nodeAffinity references from codebase
- Sync changes across both src/hooks and src/app/hooks
- Update both FilterSidebar components and test files
@drips-wave

drips-wave Bot commented Jul 29, 2026

Copy link
Copy Markdown

@Danielobito009 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! 🚀

Learn more about application limits

@RUKAYAT-CODER

Copy link
Copy Markdown
Contributor

Thank you for contributing to the project

@RUKAYAT-CODER
RUKAYAT-CODER merged commit 22383b8 into rinafcode:main Jul 29, 2026
6 checks passed
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.

Remove the nonsensical Node Affinity filter from FilterSidebar

3 participants