Skip to content
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

Day Timer Trying out with OBS #110

Merged
merged 1 commit into from
Apr 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,24 @@ export default function LandingEvent() {
<div className={styles.clouds}>
<Clouds />
</div>
<div className={styles.grass}>
<Grass />
</div>
{!isDayTimer && (
<div className={styles.grass}>
<Grass />
</div>
)}
</div>
</main>
);
}
// .grass{
// position: relative;
// z-index: 2;
// margin-top: -12vw;
// @media(max-width: $tablet-breakpoint){
// margin-top: -130px;
// }

// @media(max-width: $mobile-breakpoint){
// margin-top: -250px;
// }
// }
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import DOECountDown from './_components/DOECountDown';
import Image from 'next/image';
import HackDavisLogo from 'public/navbar/logo.svg';
import { TiLocation } from 'react-icons/ti';
import { usePathname } from 'next/navigation'; // Import useRouter

type ButtonLink = {
title: string;
Expand Down Expand Up @@ -34,6 +35,8 @@ const buttonLinks: ButtonLink[] = [
export default function Timer() {
const startTime = new Date('2024-04-27T14:00:00-07:00');
const endTime = new Date('2024-04-28T14:00:00-07:00');
const pathname = usePathname();
const isDayTimer = pathname.includes('dayTimer');
return (
<main className="">
<div className="tw-flex tw-flex-col tw-items-center tw-justify-center tw-gap-6">
Expand All @@ -49,22 +52,24 @@ export default function Timer() {
</div>
<DOECountDown startTime={startTime} endTime={endTime} />

<div className="tw-flex tw-items-center tw-justify-center tw-gap-4">
{buttonLinks.map((button, index) => (
<Link key={index} href={button.url}>
<button
className="tw-flex tw-items-center tw-justify-center tw-gap-2 tw-rounded-3xl tw-p-2 tw-px-6 tw-text-sm tw-font-semibold md:tw-text-base"
style={{
backgroundColor: button.bgColor,
color: button.textColor,
}}
>
{button.icon ? <span>{button.icon}</span> : <></>}
<span className="tw-mt-1">{button.title}</span>
</button>
</Link>
))}
</div>
{!isDayTimer && (
<div className="tw-flex tw-items-center tw-justify-center tw-gap-4">
{buttonLinks.map((button, index) => (
<Link key={index} href={button.url}>
<button
className="tw-flex tw-items-center tw-justify-center tw-gap-2 tw-rounded-3xl tw-p-2 tw-px-6 tw-text-sm tw-font-semibold md:tw-text-base"
style={{
backgroundColor: button.bgColor,
color: button.textColor,
}}
>
{button.icon ? <span>{button.icon}</span> : <></>}
<span className="tw-mt-1">{button.title}</span>
</button>
</Link>
))}
</div>
)}
<div
className="tw-flex tw-gap-1 tw-font-medium tw-text-dark-blue"
style={{
Expand Down