-
Notifications
You must be signed in to change notification settings - Fork 20
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
feat: Added loader! #54
Open
prateekjha1204
wants to merge
4
commits into
BitByte-TPC:master
Choose a base branch
from
prateekjha1204:prateek
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,120 @@ | ||
import Navbar from "@/components/Navbar"; | ||
import { Button } from "@/components/ui/button"; | ||
import { ArrowTopRightIcon } from "@radix-ui/react-icons"; | ||
import hackbyteLogo from "@/public/hackbyteLogo.png"; | ||
import Image from "next/image"; | ||
|
||
export default function Home() { | ||
return ( | ||
<> | ||
<div | ||
className="flex flex-col justify-around min-h-screen | ||
bg-cover bg-no-repeat p-4 md:px-12 md:py-8" | ||
style={{ | ||
backgroundImage: "url(/background.webp)", | ||
backgroundAttachment: "fixed", | ||
backgroundPositionY: "bottom", | ||
}} | ||
> | ||
<Navbar /> | ||
<div className="flex flex-wrap justify-between items-center gap-4 lg:gap-0"> | ||
<div className="flex flex-col items-start w-full lg:w-1/2"> | ||
{/* <p | ||
className="text-[#FAF8ED] text-[1.25rem] font-medium uppercase | ||
lg:text-[1.5rem]" | ||
> | ||
This year's theme :{" "} | ||
</p> */} | ||
<p | ||
className="text-[#FAF8ED] text-[2.375rem] font-medium leading-[1.2] | ||
lg:leading-[1.1] lg:text-[3rem]" | ||
> | ||
This year's theme <br /> unveils in April ... | ||
</p> | ||
</div> | ||
<div className="flex flex-col items-start gap-3 w-full lg:items-end lg:w-1/2"> | ||
<p | ||
className="text-[#FAF8ED] text-[1.25rem] font-medium text-left | ||
lg:text-right lg:text-[1.5rem]" | ||
> | ||
— Round 1 kicks off at | ||
<br /> 5 April 2024, IIIT Jabalpur | ||
</p> | ||
<Button | ||
size="sm" | ||
className="bg-[#FAF8ED] text-black text-[1.125rem] font-medium uppercase | ||
p-6 rounded-none hover:bg-[#FAF8ED] hover:text-black" | ||
style={{ | ||
boxShadow: | ||
"0px 1px 1px 0px rgba(0, 0, 0, 0.12), 0px 0px 0px 1px rgba(103, 110, 118, 0.16), 0px 2px 5px 0px rgba(103, 110, 118, 0.08)", | ||
}} | ||
> | ||
Explore Challenge | ||
<ArrowTopRightIcon className="w-5 h-5 ml-1" /> | ||
</Button> | ||
</div> | ||
</div> | ||
|
||
<div className="flex items-center justify-center my-12 xl:my-4"> | ||
<Image | ||
src={hackbyteLogo} | ||
alt="HackByte Logo" | ||
className="max-w-[32rem] min-w-[15rem] w-[75%] 2xl:max-w-[40rem]" | ||
priority | ||
/> | ||
</div> | ||
|
||
<div className="flex items-center justify-between gap-4 mt-8 xl:mt-4"> | ||
<div className="flex flex-col items-start gap-2"> | ||
<p | ||
className="text-[#FAF8ED] text-[1rem] font-[600] | ||
md:text-[1.125rem]" | ||
> | ||
HackByte: Empower Your Digital Odyssey! | ||
</p> | ||
<div className="flex items-stretch"> | ||
<div | ||
className="flex justify-center items-center py-2 md:py-2.5 px-4 md:px-6" | ||
style={{ border: "1.275px solid #FAF8ED" }} | ||
> | ||
<div className="flex justify-center items-center gap-4"> | ||
<img | ||
src="/tpcLogo.svg" | ||
alt="TPC Logo" | ||
className="w-[4rem] h-[2.125rem]" | ||
/> | ||
<p className="text-[#FAF8ED] text-[0.75rem] font-[600]"> | ||
Organised by | ||
<br className="hidden md:block" /> The Programming Club of | ||
IIITDMJ | ||
</p> | ||
</div> | ||
</div> | ||
<div | ||
className="flex justify-center items-center py-2 md:py-2.5 px-4 md:px-6" | ||
style={{ border: "1.275px solid #FAF8ED" }} | ||
> | ||
<div className="flex justify-center items-center"> | ||
<img | ||
src="/iiitdmjLogo.svg" | ||
alt="IIITDMJ Logo" | ||
className="w-[5.5rem] h-[2rem]" | ||
/> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
<div className="hidden lg:flex lg:flex-col lg:items-end lg:max-w-[24rem] xl:max-w-md"> | ||
<p className="text-[#FAF8ED] text-[1rem] xl:text-[1.125rem] font-[600] text-right"> | ||
HackByte: Empower Your Digital Odyssey! | ||
</p> | ||
<p className="text-[#FAF8ED] text-[1rem] xl:text-[1.125rem] font-normal text-right uppercase"> | ||
Embark on an enriching voyage with HackByte, where the fusion of | ||
tech expertise and boundless innovation unfolds. | ||
</p> | ||
</div> | ||
</div> | ||
</div> | ||
</> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,119 +1,13 @@ | ||
import Navbar from "@/components/Navbar"; | ||
import { Button } from "@/components/ui/button"; | ||
import { ArrowTopRightIcon } from "@radix-ui/react-icons"; | ||
import hackbyteLogo from "@/public/hackbyteLogo.png"; | ||
import Image from "next/image"; | ||
import React from "react"; | ||
import dynamic from "next/dynamic"; | ||
import Loading from "@/components/Loader"; | ||
|
||
export default function Home() { | ||
return ( | ||
<div | ||
className="flex flex-col justify-around min-h-screen | ||
bg-cover bg-no-repeat p-4 md:px-12 md:py-8" | ||
style={{ | ||
backgroundColor: "#000", | ||
backgroundImage: "url(/background.webp)", | ||
backgroundAttachment: "fixed", | ||
backgroundPositionY: "bottom", | ||
}} | ||
> | ||
<Navbar /> | ||
<div className="flex flex-wrap justify-between items-center gap-4 lg:gap-0"> | ||
<div className="flex flex-col items-start w-full lg:w-1/2"> | ||
{/* <p | ||
className="text-[#FAF8ED] text-[1.25rem] font-medium uppercase | ||
lg:text-[1.5rem]" | ||
> | ||
This year's theme :{" "} | ||
</p> */} | ||
<p | ||
className="text-[#FAF8ED] text-[2.375rem] font-medium leading-[1.2] | ||
lg:leading-[1.1] lg:text-[3rem]" | ||
> | ||
This year's theme <br /> unveils in April ... | ||
</p> | ||
</div> | ||
<div className="flex flex-col items-start gap-3 w-full lg:items-end lg:w-1/2"> | ||
<p | ||
className="text-[#FAF8ED] text-[1.25rem] font-medium text-left | ||
lg:text-right lg:text-[1.5rem]" | ||
> | ||
— Round 1 kicks off at | ||
<br /> 5 April 2024, IIIT Jabalpur | ||
</p> | ||
<Button | ||
size="sm" | ||
className="bg-[#FAF8ED] text-black text-[1.125rem] font-medium uppercase | ||
p-6 rounded-none hover:bg-[#FAF8ED] hover:text-black" | ||
style={{ | ||
boxShadow: | ||
"0px 1px 1px 0px rgba(0, 0, 0, 0.12), 0px 0px 0px 1px rgba(103, 110, 118, 0.16), 0px 2px 5px 0px rgba(103, 110, 118, 0.08)", | ||
}} | ||
> | ||
Explore Challenge | ||
<ArrowTopRightIcon className="w-5 h-5 ml-1" /> | ||
</Button> | ||
</div> | ||
</div> | ||
const Home = dynamic(() => import("../app/Home"), { | ||
loading: () => <Loading />, | ||
ssr: false, | ||
}); | ||
const HomePage = () => { | ||
return <Home />; | ||
}; | ||
|
||
<div className="flex items-center justify-center my-12 xl:my-4"> | ||
<Image | ||
src={hackbyteLogo} | ||
alt="HackByte Logo" | ||
className="max-w-[32rem] min-w-[15rem] w-[75%] 2xl:max-w-[40rem]" | ||
priority | ||
/> | ||
</div> | ||
|
||
<div className="flex items-center justify-between gap-4 mt-8 xl:mt-4"> | ||
<div className="flex flex-col items-start gap-2"> | ||
<p | ||
className="text-[#FAF8ED] text-[1rem] font-[600] | ||
md:text-[1.125rem]" | ||
> | ||
HackByte: Empower Your Digital Odyssey! | ||
</p> | ||
<div className="flex items-stretch"> | ||
<div | ||
className="flex justify-center items-center py-2 md:py-2.5 px-4 md:px-6" | ||
style={{ border: "1.275px solid #FAF8ED" }} | ||
> | ||
<div className="flex justify-center items-center gap-4"> | ||
<img | ||
src="/tpcLogo.svg" | ||
alt="TPC Logo" | ||
className="w-[4rem] h-[2.125rem]" | ||
/> | ||
<p className="text-[#FAF8ED] text-[0.75rem] font-[600]"> | ||
Organised by | ||
<br className="hidden md:block" /> The Programming Club of | ||
IIITDMJ | ||
</p> | ||
</div> | ||
</div> | ||
<div | ||
className="flex justify-center items-center py-2 md:py-2.5 px-4 md:px-6" | ||
style={{ border: "1.275px solid #FAF8ED" }} | ||
> | ||
<div className="flex justify-center items-center"> | ||
<img | ||
src="/iiitdmjLogo.svg" | ||
alt="IIITDMJ Logo" | ||
className="w-[5.5rem] h-[2rem]" | ||
/> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
<div className="hidden lg:flex lg:flex-col lg:items-end lg:max-w-[24rem] xl:max-w-md"> | ||
<p className="text-[#FAF8ED] text-[1rem] xl:text-[1.125rem] font-[600] text-right"> | ||
HackByte: Empower Your Digital Odyssey! | ||
</p> | ||
<p className="text-[#FAF8ED] text-[1rem] xl:text-[1.125rem] font-normal text-right uppercase"> | ||
Embark on an enriching voyage with HackByte, where the fusion of | ||
tech expertise and boundless innovation unfolds. | ||
</p> | ||
</div> | ||
</div> | ||
</div> | ||
); | ||
} | ||
export default HomePage; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
const Loading = () => { | ||
const elements = ["N", "I", "D", "A", "O", "L"]; | ||
return ( | ||
<div className="relative bg-black h-screen "> | ||
<div className=" fixed top-1/2 left-1/2 transform -translate-x-1/2 -translate-y-1/2 "> | ||
<div className=" absolute w-[600px] h-[36px] left-1/2 top-[40%] -ml-[300px] overflow-visible select-none cursor-default "> | ||
{elements.map((element, index) => ( | ||
<div | ||
key={index} | ||
className=" absolute w-[48px] h-[56px] opacity-0 font-semibold animate-move rotate-180 text-[#006eff] font-sans " | ||
style={{ | ||
animationDelay: `${200 * index}ms`, | ||
}} | ||
> | ||
{element} | ||
</div> | ||
))} | ||
</div> | ||
</div> | ||
</div> | ||
); | ||
}; | ||
export default Loading; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Utilize Tailwind CSS wherever possible, avoiding the use of plain CSS.