You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Added a CopyLinkButton client component that copies the public profile URL to clipboard on click, with a 2-second "✓ Copied!" visual feedback. Button is placed in the profile page header next to the username.
CopyLinkButton is placed in DashboardHeader.tsx and copies window.location.href — which is the dashboard URL (/dashboard), not the public profile URL. Issue #192 is about the public profile page (/u/username).
Either:
Move the button to src/app/u/[username]/page.tsx (the public profile page), where window.location.href is already the profile URL, or
Keep it in the dashboard header but copy ${window.location.origin}/u/${session.githubLogin} using the session login
2. tsconfig.json change already merged
jsx: "react-jsx" → "preserve" was already merged via PR #358. This will cause a merge conflict. Remove the tsconfig change from this PR.
Hey @Priyanshu-byte-coder, I've addressed both the issues. The button now copies the correct public profile URL using session?.githubLogin. Please take a look when you get a chance.
Closing in favor of PR #269 which correctly places the copy link button on the public profile page (/u/[username]). Issue #192 asked for the button on the public profile, not the dashboard header. PR #269 has been merged.
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
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.
Summary
Added a CopyLinkButton client component that copies the public profile URL to clipboard on click, with a 2-second "✓ Copied!" visual feedback. Button is placed in the profile page header next to the username.
Closes #192
Type of Change
Changes Made
src/components/CopyLinkButton.tsxas a'use client'component.navigator.clipboard.writeText(window.location.href).✓ Copied!for 2 seconds after clicking.aria-label="Copy profile link"for accessibility.CopyLinkButtoninsrc/app/u/[username]/page.tsxnext to the username.How to Test
Steps for the reviewer to verify this works:
/u/[username]✓ Copied!for 2 seconds then resetsScreenshots (if UI change)
Checklist
npm run lintpasses locallynpm run type-check)