Commit faf22f1
committed
Dashboard: Fix team links in header on pages outside /team layout (#6981)
<!--
## 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 -->1 parent 49479d4 commit faf22f1
File tree
1 file changed
+7
-2
lines changed- apps/dashboard/src/app/(app)/team/components/TeamHeader
1 file changed
+7
-2
lines changedLines changed: 7 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
93 | 93 | | |
94 | 94 | | |
95 | 95 | | |
96 | | - | |
97 | | - | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
98 | 103 | | |
99 | 104 | | |
100 | 105 | | |
| |||
0 commit comments