Skip to content

feat(public-profile): enhance public profile route and OpenGraph card… - #3256

Open
Nareshkumawat-star wants to merge 1 commit into
Priyanshu-byte-coder:mainfrom
Nareshkumawat-star:feature/public-profile-sharing
Open

feat(public-profile): enhance public profile route and OpenGraph card…#3256
Nareshkumawat-star wants to merge 1 commit into
Priyanshu-byte-coder:mainfrom
Nareshkumawat-star:feature/public-profile-sharing

Conversation

@Nareshkumawat-star

Copy link
Copy Markdown

Summary

Adds public profile sharing capabilities (/u/[username]) and dynamic OpenGraph image generation (/u/[username]/opengraph-image.tsx). This allows developers to showcase their commit streaks, 30-day contribution activity, top repositories, and languages on social platforms (Twitter, LinkedIn) and GitHub READMEs while keeping data strictly opt-in via user privacy settings (is_public).


#closes : #3249

Type of Change

  • 🐛 Bug fix (non-breaking change that fixes an issue)
  • ✨ New feature (non-breaking change that adds functionality)
  • 💥 Breaking change (fix or feature that changes existing behavior)
  • 📝 Documentation update
  • ♻️ Refactor / code cleanup (no functional change)
  • ⚡ Performance improvement
  • 🔒 Security fix
  • 🧪 Tests only

What Changed

  • src/app/u/[username]/page.tsx: Public profile page displaying GitHub avatar, handle, current & longest streak, 30-day contributions, top repositories, PR breakdown, top languages, and achievements.
  • src/app/u/[username]/opengraph-image.tsx: Dynamic OpenGraph card generation using Next.js ImageResponse (@vercel/og) displaying avatar, streak count, and 30d commits for social embeds.
  • src/app/api/public/[username]/route.ts: API route serving public profile payload gated by is_public column in users table.
  • ShareProfileSection.tsx & CopyLinkButton.tsx: Dashboard share widget for copying public profile URLs and generating QR codes.

How to Test

  1. Navigate to /dashboard/settings and enable Public Profile.
  2. Visit /u/[your-username].
  3. Verify that stats, streak numbers, top repositories, and badges display correctly.
  4. Copy the public profile link via the "Share Profile" button on the dashboard and verify it opens in an incognito window without requiring login.
  5. Inspect the OpenGraph meta tag image URL (/u/[username]/opengraph-image.tsx).

Checklist

  • Self-reviewed my own diff
  • No unnecessary console.log or debug code
  • Opt-in privacy (is_public) enforced
  • Tested responsive layout and OpenGraph image rendering

@github-actions github-actions Bot added gssoc26 GSSoC 2026 contribution type:feature GSSoC type bonus: new feature labels Jul 28, 2026
@github-actions

Copy link
Copy Markdown

GSSoC Label Checklist 🏷️

@Priyanshu-byte-coder — please apply the appropriate labels before merging:

Difficulty (pick one):

  • level:beginner — 20 pts
  • level:intermediate — 35 pts
  • level:advanced — 55 pts
  • level:critical — 80 pts

Quality (optional):

  • quality:clean — ×1.2 multiplier
  • quality:exceptional — ×1.5 multiplier

Validation (required to score):

  • gssoc:approved — counts for points
  • gssoc:invalid / gssoc:spam / gssoc:ai-slop — does not score

Type labels (type:*) are auto-detected from files and title. Review and adjust if needed.
Points formula: (difficulty × quality_multiplier) + type_bonus

@github-actions github-actions Bot added type:bug GSSoC type bonus: bug fix type:performance GSSoC type bonus: performance (+15 pts) labels Jul 28, 2026
@Nareshkumawat-star

Copy link
Copy Markdown
Author

Hi @Priyanshu-byte-coder kindly review and merge it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

gssoc26 GSSoC 2026 contribution type:bug GSSoC type bonus: bug fix type:feature GSSoC type bonus: new feature type:performance GSSoC type bonus: performance (+15 pts)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEAT] Add shareable public profile card — generate a read-only stats URL for social sharing

1 participant