-
Notifications
You must be signed in to change notification settings - Fork 539
Dashboard: Fix team links in header on pages outside /team layout #6981
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dashboard: Fix team links in header on pages outside /team layout #6981
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
|
How to use the Graphite Merge QueueAdd either label to this PR to merge it via the merge queue:
You must have a Graphite account in order to use the merge queue. Sign up using this link. An organization admin has enabled the Graphite Merge Queue in this repository. Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue. This stack of pull requests is managed by Graphite. Learn more about stacking. |
c1489a5
to
377fb4c
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #6981 +/- ##
=======================================
Coverage 54.60% 54.60%
=======================================
Files 903 903
Lines 57934 57934
Branches 3970 3970
=======================================
Hits 31632 31632
Misses 26202 26202
Partials 100 100
🚀 New features to boost your workflow:
|
size-limit report 📦
|
Merge activity
|
) <!-- ## title your PR with this format: "[SDK/Dashboard/Portal] Feature/Fix: Concise title for the changes" If you did not copy the branch name from Linear, paste the issue tag here (format is TEAM-0000): ## Notes for the reviewer Anything important to call out? Be sure to also clarify these in your comments. ## How to test Unit tests, playground, etc. --> <!-- start pr-codex --> --- ## PR-Codex overview This PR modifies the `href` attribute of a `Link` component in the `TeamSelectionUI.tsx` file to ensure that the URL is correctly updated when navigating between teams, specifically when on the `/team` page. ### Detailed summary - Updated the `href` logic in the `Link` component. - Added a condition to check if `pathname` starts with `/team`. - Changed the replacement logic to include the `/team/` prefix for both `currentTeam` and `team`. > ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}` <!-- end pr-codex -->
377fb4c
to
75163ec
Compare
apps/dashboard/src/app/(app)/team/components/TeamHeader/TeamSelectionUI.tsx
Show resolved
Hide resolved
) <!-- ## title your PR with this format: "[SDK/Dashboard/Portal] Feature/Fix: Concise title for the changes" If you did not copy the branch name from Linear, paste the issue tag here (format is TEAM-0000): ## Notes for the reviewer Anything important to call out? Be sure to also clarify these in your comments. ## How to test Unit tests, playground, etc. --> <!-- start pr-codex --> --- ## PR-Codex overview This PR modifies the `href` attribute of a `Link` component in the `TeamSelectionUI.tsx` file to ensure that the URL is correctly updated when navigating between teams, specifically when on the `/team` page. ### Detailed summary - Updated the `href` logic in the `Link` component. - Added a condition to check if `pathname` starts with `/team`. - Changed the replacement logic to include the `/team/` prefix for both `currentTeam` and `team`. > ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}` <!-- end pr-codex -->
75163ec
to
faf22f1
Compare
) <!-- ## title your PR with this format: "[SDK/Dashboard/Portal] Feature/Fix: Concise title for the changes" If you did not copy the branch name from Linear, paste the issue tag here (format is TEAM-0000): ## Notes for the reviewer Anything important to call out? Be sure to also clarify these in your comments. ## How to test Unit tests, playground, etc. --> <!-- start pr-codex --> --- ## PR-Codex overview This PR modifies the `href` attribute of the `Link` component in the `TeamSelectionUI.tsx` file to ensure that the URL path is correctly constructed when navigating between team pages. ### Detailed summary - Updated the `href` logic to check if `pathname` starts with `/team`. - Changed the `replace` method to use the full path for `currentTeam.slug` and `team.slug`. - Ensured that the fallback URL for the `Link` defaults to `/team/${team.slug}` when conditions are not met. > ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}` <!-- end pr-codex -->
faf22f1
to
ccb9cd5
Compare
PR-Codex overview
This PR focuses on updating the
href
property of theLink
component in theTeamSelectionUI.tsx
file to ensure it correctly replaces the team slug in the URL only when certain conditions are met.Detailed summary
href
property of theLink
component.pathname
starts with/team
before replacing the current team slug.