Skip to content

Show only the top 10 promoters with downloads on the leaderboard - #183

Merged
mostafazh merged 1 commit into
mainfrom
leaderboard-top-10
Oct 14, 2026
Merged

mostafazh merged 1 commit into
mainfrom
leaderboard-top-10

Conversation

@mostafazh

Copy link
Copy Markdown
Collaborator

Why

The leaderboard listed every approved promoter in every window. Most have 0 downloads, and because equal counts share a rank, everyone behind first place showed up tied at 🥈. On https://ppm.techforpalestine.org/leaderboard that was 14 rows of zeros under one real entry.

What

  • The board shows the top 10 promoters with at least one download, in all three windows (Today, Last 7 days, All time).
  • The viewer's own approved row is always kept, even outside the top 10 or at 0 downloads, with its real rank.
  • When people are listed but nobody has downloads in the window, it says "No downloads yet." ("Nobody is listed yet." stays for an empty registry.)
  • The API is unchanged: it still returns every approved promoter, and the page trims what it displays.

Tests

  • New e2e specs: top-10 cap plus own row, and the "No downloads yet." state.
  • Type-check and lint are clean, and e2e/leaderboard.spec.ts passes on Chromium (12/12). Firefox and WebKit were not run locally; CI covers them.

A quiet window listed every approved promoter, most at 0 downloads and all
tied for second place. The board now shows the top 10 with at least one
download, and always keeps the viewer's own row.
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Oct 14, 2026 •

Copy link
Copy Markdown

Deploying palestine-pfp-maker with  Cloudflare Pages  Cloudflare Pages

Latest commit: 999698a
Status: ✅  Deploy successful!
Preview URL: https://a40fa146.palestine-pfp-maker.pages.dev
Branch Preview URL: https://leaderboard-top-10.palestine-pfp-maker.pages.dev

View logs

@mostafazh
mostafazh merged commit 019353c into main Oct 14, 2026
8 checks passed
@mostafazh
mostafazh deleted the leaderboard-top-10 branch October 14, 2026 23:45
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.

2 participants