From 8d23963b6e1c884682c72a0f3f9df92732d4ac21 Mon Sep 17 00:00:00 2001 From: Aslam H Date: Tue, 24 Sep 2024 00:41:40 +0700 Subject: [PATCH] chore: add topics link --- .../custom/sidebar/partial/topic-section.tsx | 17 +++++++---------- web/components/routes/link/list.tsx | 1 - 2 files changed, 7 insertions(+), 11 deletions(-) diff --git a/web/components/custom/sidebar/partial/topic-section.tsx b/web/components/custom/sidebar/partial/topic-section.tsx index 0e1155f7..8f7cba79 100644 --- a/web/components/custom/sidebar/partial/topic-section.tsx +++ b/web/components/custom/sidebar/partial/topic-section.tsx @@ -27,7 +27,7 @@ export const TopicSection: React.FC<{ pathname: string }> = ({ pathname }) => { if (!me) return null return ( -
+
= ({ topicCount, isA isActive ? "bg-accent text-accent-foreground" : "hover:bg-accent hover:text-accent-foreground" )} > - +
) @@ -78,7 +75,7 @@ const List: React.FC = ({ topicsWantToLearn, topicsLearning, topicsLe count={topicsWantToLearn.length} label="To Learn" value="wantToLearn" - href="/me/wantToLearn" + href="#" isActive={pathname === "/me/wantToLearn"} /> = ({ topicsWantToLearn, topicsLearning, topicsLe label="Learning" value="learning" count={topicsLearning.length} - href="/me/learning" + href="#" isActive={pathname === "/me/learning"} /> = ({ topicsWantToLearn, topicsLearning, topicsLe label="Learned" value="learned" count={topicsLearned.length} - href="/me/learned" + href="#" isActive={pathname === "/me/learned"} />
diff --git a/web/components/routes/link/list.tsx b/web/components/routes/link/list.tsx index 9710c83b..d76dfaf2 100644 --- a/web/components/routes/link/list.tsx +++ b/web/components/routes/link/list.tsx @@ -258,7 +258,6 @@ const LinkList: React.FC = () => { setEditId(null) setActiveItemIndex(lastActiveIndexRef.current) setKeyboardActiveIndex(lastActiveIndexRef.current) - console.log(keyboardActiveIndex) }} index={index} onItemSelected={link => setEditId(link.id)}