From 3dafca711f544fd4d83967a81c3da98095a39597 Mon Sep 17 00:00:00 2001 From: Augustin Hiebel Date: Thu, 7 Dec 2023 13:56:38 +0100 Subject: [PATCH] Prototype: profile changes --- pages/stryda/components/FeedItemDetailsMatch.js | 4 +++- pages/stryda/components/TopbarHighlights.js | 4 ++-- pages/stryda/components/TopbarSidebar.js | 5 ++++- pages/stryda/components/WidgetUser.js | 2 +- pages/stryda/profile/[user_id]/index.js | 2 +- 5 files changed, 11 insertions(+), 6 deletions(-) diff --git a/pages/stryda/components/FeedItemDetailsMatch.js b/pages/stryda/components/FeedItemDetailsMatch.js index b4ea453c..06c99ae6 100644 --- a/pages/stryda/components/FeedItemDetailsMatch.js +++ b/pages/stryda/components/FeedItemDetailsMatch.js @@ -24,6 +24,8 @@ export default function FeedItemDetailsMatch(props) { const defaultTab = selectedTab != "default" ? selectedTab : (match.meta.media?.videoUrl ? "highlight" : "summary"); const [activeTab, setActiveTab] = useState(defaultTab); + console.log(props.selectedTab, selectedTab, item, match); + useEffect(() => { history.pushState(null, "", `${url}${item.id}`); }, []); @@ -169,7 +171,7 @@ export default function FeedItemDetailsMatch(props) { className={activeTab === "highlight" ? "is-active" : ""} onClick={() => setActiveTab("highlight")} > - Highlight + Recap )} diff --git a/pages/stryda/components/TopbarHighlights.js b/pages/stryda/components/TopbarHighlights.js index 21bab92a..dd22f796 100644 --- a/pages/stryda/components/TopbarHighlights.js +++ b/pages/stryda/components/TopbarHighlights.js @@ -217,8 +217,8 @@ export default function TopbarHighlights() { {buttonState === 0 && ""} - {buttonState === 1 && "New highlights recorded"} - {buttonState === 2 && "Highlights ready"} + {buttonState === 1 && "New matches recorded"} + {buttonState === 2 && "Recaps ready"} diff --git a/pages/stryda/components/TopbarSidebar.js b/pages/stryda/components/TopbarSidebar.js index dedb65a9..6116da47 100644 --- a/pages/stryda/components/TopbarSidebar.js +++ b/pages/stryda/components/TopbarSidebar.js @@ -60,7 +60,10 @@ export default function TopbarSidebar() { router.pathname.includes("ladders") ? "is-active" : "" }`} > - Ladders + + Ladders + + diff --git a/pages/stryda/components/WidgetUser.js b/pages/stryda/components/WidgetUser.js index 6ceafed4..6618f73b 100644 --- a/pages/stryda/components/WidgetUser.js +++ b/pages/stryda/components/WidgetUser.js @@ -311,7 +311,7 @@ export default function WidgetUser(props) { type="button" className="interactive leading-tight" > -
Highlights
+
Recaps
{selectedUser.stats.followers === 0 || state === "empty" ? ( diff --git a/pages/stryda/profile/[user_id]/index.js b/pages/stryda/profile/[user_id]/index.js index 9602c0ad..e3c5e851 100644 --- a/pages/stryda/profile/[user_id]/index.js +++ b/pages/stryda/profile/[user_id]/index.js @@ -182,7 +182,7 @@ export default function Profile() { }, { label: "Recaps", - url: "recaps", + url: "highlight", component: TabProfileHighlights, number: 9, },