Problem
Active-first sorting is applied to MCap and Recent sort modes, but per the spec (#958) it should only apply to Trending.
| Sort |
Active-first? |
Current |
Expected |
| Trending |
Yes |
✅ Yes |
✅ Yes |
| MCap |
No |
❌ Yes |
No |
| Recent |
No |
❌ Yes |
No |
| TVL |
No |
? |
No |
Why
- MCap sort: Users want to see highest market cap stories regardless of active status. An expired story with $10K MCap should rank above an active story with $100 MCap.
- Recent sort: Pure chronological order. Active status is irrelevant.
- TVL sort: Same as MCap — value-based ranking.
Fix
Remove active-first logic from MCap, Recent, and TVL sort functions. Only keep it in the Trending sort.
Check lib/ranking.ts or wherever the sort logic lives:
getMcapStorylines() — remove active-first sort
- Recent query — remove active-first sort
- TVL query — remove active-first sort (if applied)
getTrendingStorylines() — keep active-first sort
Files
lib/ranking.ts or equivalent
src/app/page.tsx or discover page
Acceptance Criteria
Problem
Active-first sorting is applied to MCap and Recent sort modes, but per the spec (#958) it should only apply to Trending.
Why
Fix
Remove active-first logic from MCap, Recent, and TVL sort functions. Only keep it in the Trending sort.
Check
lib/ranking.tsor wherever the sort logic lives:getMcapStorylines()— remove active-first sortgetTrendingStorylines()— keep active-first sortFiles
lib/ranking.tsor equivalentsrc/app/page.tsxor discover pageAcceptance Criteria