Skip to content

[ANALYTICS-002] Add per-user activity stats - #81

Merged
chev0004 merged 5 commits into
feat/analytics-001from
feat/analytics-002
Jun 30, 2026
Merged

[ANALYTICS-002] Add per-user activity stats#81
chev0004 merged 5 commits into
feat/analytics-001from
feat/analytics-002

Conversation

@chev0004

Copy link
Copy Markdown
Owner

Outline

Summary

Adds a per-user activity stats page so any signed-in user can see their own activity, while keeping identity-revealing engagement insights premium.


Changes & Enhancements

  • Type of Change:
    • Feature
    • Bugfix
    • Refactor
    • Chore
  • Changes:
    • (db):
      • Add getUserAnalyticsEventCounts, scoped to the acting user's internal id over a recent window.
    • (activity):
      • Add an activity stats page showing the user's own profile views, username copies, saves, and bumps.
      • Replace stats with an enable prompt when product analytics is opted out.
      • Show a locked teaser for premium who-viewed-you and who-copied-you insights.
    • (routing):
      • Add the auth-guarded /[lang]/activity route.
    • (navbar):
      • Add an optional activity link to the user menu, wired across the signed-in routes.
    • (i18n):
      • Add Activity strings and a user menu label in en and ja.

Page / App Changes

Affected Next.js Routes (Local):

  • /[lang]/activity
Before (Screenshot)
After (Screenshot)

Component / Storybook Changes

Affected Storybook Components (Local):

Before (Screenshot)
After (Screenshot)

Not Doing


Other (Remarks)

Stacked on feat/analytics-001 (ANALYTICS-001, #80), which is not yet merged and carries the analytics events this PR depends on. Base is set to feat/analytics-001; retarget to develop once #80 merges.


Checklists

  • Code is well-documented (comments, JSDoc, etc.).
  • Existing comments were updated as needed.
  • No out-of-scope changes are included.
  • Write TODO comments where future work is required.
  • Removed unnecessary debug code (e.g., console.log, debugger).
  • Self-reviewed and tested locally.

@chev0004 chev0004 self-assigned this Jun 30, 2026
@chev0004
chev0004 merged commit caafc18 into feat/analytics-001 Jun 30, 2026
1 check 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.

1 participant