From b4b1e8e070e2b9284bc67a632b79fee7444f4864 Mon Sep 17 00:00:00 2001 From: comnk Date: Sun, 4 May 2025 08:30:30 -0700 Subject: [PATCH 1/5] added styling to profile dropdown --- src/app/assets/GalleryIcon.tsx | 30 +++++++++++++++++++++++++++++ src/app/assets/MyCardsIcon.tsx | 12 ++++++++++++ src/app/components/SignInButton.tsx | 20 ++++++++++++++----- 3 files changed, 57 insertions(+), 5 deletions(-) create mode 100644 src/app/assets/GalleryIcon.tsx create mode 100644 src/app/assets/MyCardsIcon.tsx diff --git a/src/app/assets/GalleryIcon.tsx b/src/app/assets/GalleryIcon.tsx new file mode 100644 index 0000000..34bdb77 --- /dev/null +++ b/src/app/assets/GalleryIcon.tsx @@ -0,0 +1,30 @@ +export default function GalleryIcon() { + return ( + + + + + + + ); +} diff --git a/src/app/assets/MyCardsIcon.tsx b/src/app/assets/MyCardsIcon.tsx new file mode 100644 index 0000000..047f99d --- /dev/null +++ b/src/app/assets/MyCardsIcon.tsx @@ -0,0 +1,12 @@ +export default function MyCardsIcon() { + return ( + + + + ); +} diff --git a/src/app/components/SignInButton.tsx b/src/app/components/SignInButton.tsx index 9ab3392..00c34db 100644 --- a/src/app/components/SignInButton.tsx +++ b/src/app/components/SignInButton.tsx @@ -1,5 +1,5 @@ import { memo, useState } from 'react'; -import { useRouter } from 'next/navigation'; +import { usePathname, useRouter } from 'next/navigation'; import { authClient } from '@/lib/auth-client'; import LoginIcon from '../assets/LoginIcon'; import GlassButton from './GlassButton/GlassButton'; @@ -13,6 +13,8 @@ import { import ProfileIcon from '../assets/ProfileIcon'; import { Session } from '@/lib/auth'; import Modal from './Modal'; +import MyCardsIcon from '../assets/MyCardsIcon'; +import GalleryIcon from '../assets/GalleryIcon'; interface SignInButtonProps { session: Session | null; @@ -22,6 +24,7 @@ interface SignInButtonProps { function SignInButton({ session, className }: SignInButtonProps) { const [openLoginModal, setOpenLoginModal] = useState(false); const [openSignOutModal, setOpenSignOutModal] = useState(false); + const pathname = usePathname(); const router = useRouter(); const handleSignOut = async () => { @@ -68,10 +71,17 @@ function SignInButton({ session, className }: SignInButtonProps) { - - router.push('/my-cards')}>My Cards{' '} - {/* Placeholder for now */} - setOpenSignOutModal(true)}>Sign Out + + router.push(pathname === '/my-cards' ? '/' : '/my-cards')} + > + {pathname === '/my-cards' ? : } + {pathname === '/my-cards' ? 'Gallery' : 'My Cards'} + + setOpenSignOutModal(true)}> + + Sign Out + From 23257b68df81bf5780f833cbec655b7123df415e Mon Sep 17 00:00:00 2001 From: comnk Date: Sun, 4 May 2025 08:43:08 -0700 Subject: [PATCH 2/5] added divider line between two profile dropdown items --- src/app/components/SignInButton.tsx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/app/components/SignInButton.tsx b/src/app/components/SignInButton.tsx index 00c34db..61fc55f 100644 --- a/src/app/components/SignInButton.tsx +++ b/src/app/components/SignInButton.tsx @@ -78,9 +78,11 @@ function SignInButton({ session, className }: SignInButtonProps) { {pathname === '/my-cards' ? : } {pathname === '/my-cards' ? 'Gallery' : 'My Cards'} + {/* Divider Line*/} +
setOpenSignOutModal(true)}> - Sign Out + Log Out From a167d3132f887de0987a1ca9528405f77fe629aa Mon Sep 17 00:00:00 2001 From: comnk Date: Sun, 4 May 2025 08:45:16 -0700 Subject: [PATCH 3/5] made corners of profile dropdown content more rounded --- src/app/components/SignInButton.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/app/components/SignInButton.tsx b/src/app/components/SignInButton.tsx index 61fc55f..f2cec0a 100644 --- a/src/app/components/SignInButton.tsx +++ b/src/app/components/SignInButton.tsx @@ -71,7 +71,7 @@ function SignInButton({ session, className }: SignInButtonProps) { - + router.push(pathname === '/my-cards' ? '/' : '/my-cards')} > From 6e19747de75022a3f1593a68f2d483090f41e740 Mon Sep 17 00:00:00 2001 From: comnk Date: Sun, 4 May 2025 08:55:48 -0700 Subject: [PATCH 4/5] added styling to the sections dropdown --- src/app/assets/AgendaIcon.tsx | 15 ++++++++++++ src/app/assets/FAQIcon.tsx | 22 ++++++++++++++++++ .../components/ExpandedCard/ExpandedCard.tsx | 23 +++++++++++++++---- 3 files changed, 56 insertions(+), 4 deletions(-) create mode 100644 src/app/assets/AgendaIcon.tsx create mode 100644 src/app/assets/FAQIcon.tsx diff --git a/src/app/assets/AgendaIcon.tsx b/src/app/assets/AgendaIcon.tsx new file mode 100644 index 0000000..1728413 --- /dev/null +++ b/src/app/assets/AgendaIcon.tsx @@ -0,0 +1,15 @@ +export default function AgendaIcon() { + return ( + + + + + + + ); +} diff --git a/src/app/assets/FAQIcon.tsx b/src/app/assets/FAQIcon.tsx new file mode 100644 index 0000000..be551fb --- /dev/null +++ b/src/app/assets/FAQIcon.tsx @@ -0,0 +1,22 @@ +export default function FAQIcon() { + return ( + + + + + + ); +} diff --git a/src/app/components/ExpandedCard/ExpandedCard.tsx b/src/app/components/ExpandedCard/ExpandedCard.tsx index cc4ec8b..5b4cc58 100644 --- a/src/app/components/ExpandedCard/ExpandedCard.tsx +++ b/src/app/components/ExpandedCard/ExpandedCard.tsx @@ -17,6 +17,9 @@ import { import GlassButton from '../GlassButton/GlassButton'; import SectionsIcon from '@/app/assets/SectionsIcon'; import { getCardLogo } from '@/app/util/getCardLogo'; +import ProfileIcon from '@/app/assets/ProfileIcon'; +import AgendaIcon from '@/app/assets/AgendaIcon'; +import FAQIcon from '@/app/assets/FAQIcon'; export type SectionId = 'faq' | 'agenda' | 'judges'; @@ -142,10 +145,22 @@ const ExpandedCardComponent = ({ showExpanded }: ExpandedCardProps) => { - - scrollToSection('faq')}>FAQ{' '} - scrollToSection('agenda')}>Agenda - scrollToSection('judges')}>Judges + + scrollToSection('faq')}> + + FAQ + {' '} + {/* Divider Line*/} +
+ scrollToSection('agenda')}> + + Agenda + +
+ scrollToSection('judges')}> + + Judges +
From af862bf8dac09585920bfe2c78c13a090cba591d Mon Sep 17 00:00:00 2001 From: comnk Date: Sun, 4 May 2025 09:02:35 -0700 Subject: [PATCH 5/5] changed naming from FAQIcon to AboutIcon --- src/app/assets/{FAQIcon.tsx => AboutIcon.tsx} | 2 +- src/app/components/ExpandedCard/ExpandedCard.tsx | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) rename src/app/assets/{FAQIcon.tsx => AboutIcon.tsx} (94%) diff --git a/src/app/assets/FAQIcon.tsx b/src/app/assets/AboutIcon.tsx similarity index 94% rename from src/app/assets/FAQIcon.tsx rename to src/app/assets/AboutIcon.tsx index be551fb..eee333e 100644 --- a/src/app/assets/FAQIcon.tsx +++ b/src/app/assets/AboutIcon.tsx @@ -1,4 +1,4 @@ -export default function FAQIcon() { +export default function AboutIcon() { return ( { scrollToSection('faq')}> - - FAQ + + About {' '} {/* Divider Line*/}