Repository navigation
Hourly gift: its tokens count on every board, on all eight pages - #40
Merged
Merged
Conversation
The gift panel said gift tokens reach the balance and the all-time total but never the weekly, monthly or yearly boards. That stopped being true on 8 October 2026 (langx/langx#1758): `gift` is no longer one of TOKEN_GRANT_KINDS, so awardTokens credits all four period aggregates for it and every leaderboard period ranks it. Only the sign-up bonus, the welcome-back bonus and a converted v1 balance stay all-time only. Only that sentence changes, in every language; the rest of the panel is as it was. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Oct 27, 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.
Found while building the Token page for langx/langx#2067. Not part of that plan. It is held for Behic to review and merge.
What was wrong
The Hourly gift panel said gift tokens go to the balance and the all-time total, "never to the weekly, monthly or yearly boards". That stopped being true on 8 October 2026, when langx/langx#1758 (Count every reward on the week, month and year leaderboards) merged. Since then a gift counts in every leaderboard period.
Code evidence (langx/langx
mainatd0b2c88ec)packages/shared/src/token.tsL82–89: thegiftkind says "It counts in every period like any other reward".packages/shared/src/token.tsL152–160:TOKEN_GRANT_KINDSis onlylegacyTokenConversion,welcomeBackandsignupBonus.giftis not in it, soisGrantKind('gift')is false.apps/api/src/modules/tokens/gift.tsL52–58:claimGiftrecords the gift withawardTokens(db, { kind: 'gift', … }).apps/api/src/modules/tokens/ledger.tsL124–140:awardTokenscredits only['all']for a grant kind. Any other kind is credited to all four period keys (all,year,month,week) intokenAggregates.apps/api/src/modules/tokens/leaderboard.tsL69–86: every board readstokenAggregatesfiltered by{ periodType, periodKey }, so each board ranks the week, month and year rows the gift wrote.apps/api/src/routes/leaderboard.test.tsL1339–1364: "credits every period — a gift is a reward…" asserts thatweek,monthandyeareach hold the 250-token gift.docs/decisions.mdL9214: The leaderboard counts every reward.What changes
The PR changes the one wrong sentence on all eight pages (
/,tr/,de/,es/,fr/,pt-br/,ru/,ar/). It now says gift tokens count like any others: they go to the balance and to the weekly, monthly, yearly and all-time boards. The rest of the panel, the figures and the FAQ are unchanged. The new text uses none of the brief's banned words.node tools/check-token-rules.mjsagainst langx/langxmain: all 8 pages agree, 60 rules each.Not changed here
docs/token-messaging-brief.md. Lines 109–111 of the brief still say gift tokens "go to the all-time balance only and never move a leaderboard". That is out of date for the same reason and needs its own fix in langx/langx.🤖 Generated with Claude Code