Skip to content

Comments

feat(achievement): add Recent Unlocks component#4589

Open
wescopeland wants to merge 1 commit intoRetroAchievements:masterfrom
wescopeland:ach2-recent-unlocks
Open

feat(achievement): add Recent Unlocks component#4589
wescopeland wants to merge 1 commit intoRetroAchievements:masterfrom
wescopeland:ach2-recent-unlocks

Conversation

@wescopeland
Copy link
Member

This PR populates the "Recent Unlocks" tab in achievement2. The implementation is fairly straightforward and almost identical to the existing PHP UI with a few subtle changes:

  • If it's a very recent unlock (within the day), a DiffTimestamp is shown.
  • For performance, the rows themselves are deferred to a client-side fetch rather than being eagerly put into server-side props.

http://localhost:64000/achievement2/9?tab=unlocks

Screenshot 2026-02-22 at 4 30 06 PM Screenshot 2026-02-22 at 4 30 18 PM

@wescopeland wescopeland requested a review from a team February 22, 2026 21:32
const { t } = useTranslation();
const { formatDate } = useFormatDate();

const placeholderRowCount = Math.min(achievement.unlocksTotal ?? 0, 50);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if it would make sense to restrict this to a smaller number (maybe 10?). I'm not sure how players would use this information other than to ask a recent earner how they did it.

Conversely, it would be nice to have a "more..." link.

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