-
Notifications
You must be signed in to change notification settings - Fork 445
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
39e2d9f
commit 77b78b7
Showing
12 changed files
with
191 additions
and
109 deletions.
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,17 @@ | ||
import { atom } from "jotai" | ||
import { ActiveSection } from "./types" | ||
|
||
export const isNavStuckAtom = atom(false) | ||
export const isSeachStuckAtom = atom(false) | ||
export const activeSectionAtom = atom(ActiveSection.YourGuilds) | ||
|
||
// const { ref: navToggleRef, isStuck: isNavStuck } = useIsStuck() | ||
// const { ref: searchRef, isStuck: isSearchStuck } = useIsStuck() | ||
// const [activeSection, setActiveSection] = useState<ActiveSection>( | ||
// ActiveSection.YourGuilds | ||
// ) | ||
// const spyActiveSection = useScrollspy(Object.values(ActiveSection), 100) | ||
// useEffect(() => { | ||
// if (!spyActiveSection) return | ||
// setActiveSection(spyActiveSection as ActiveSection) | ||
// }, [spyActiveSection]) |
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
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
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
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
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,7 @@ | ||
export const Banner = () => ( | ||
<div className="absolute inset-0 -bottom-28 -z-10 overflow-hidden"> | ||
<div className="absolute inset-0 bg-[hsl(240deg_4%_16%)]" /> | ||
<div className="absolute inset-0 bg-[url('/banner.png')] bg-[auto_115%] bg-[right_top_10px] bg-no-repeat opacity-10" /> | ||
<div className="absolute inset-0 bg-gradient-to-tr from-[hsl(240deg_2.65%_22.16%)] from-50% to-transparent" /> | ||
</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 |
---|---|---|
@@ -0,0 +1,8 @@ | ||
import { PropsWithChildren } from "react" | ||
import { PageBoundary } from "../PageBoundary" | ||
|
||
export const Footer = ({ children }: PropsWithChildren) => ( | ||
<footer className="mt-auto"> | ||
<PageBoundary>{children}</PageBoundary> | ||
</footer> | ||
) |
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,9 @@ | ||
import { PropsWithChildren } from "react" | ||
import { Header as NavHeader } from "../Header" | ||
|
||
export const Header = ({ children }: PropsWithChildren) => ( | ||
<header className="relative"> | ||
<NavHeader /> | ||
{children} | ||
</header> | ||
) |
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,14 @@ | ||
import { ReactNode } from "react" | ||
import { PageBoundary } from "../PageBoundary" | ||
|
||
interface HeadlineProps { | ||
title: ReactNode | ||
} | ||
|
||
export const Headline = ({ title }: HeadlineProps) => ( | ||
<PageBoundary> | ||
<h1 className="pb-14 pt-9 font-display text-4xl font-bold tracking-tight text-white sm:text-5xl"> | ||
{title} | ||
</h1> | ||
</PageBoundary> | ||
) |
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,8 @@ | ||
import { PropsWithChildren } from "react" | ||
import { PageBoundary } from "../PageBoundary" | ||
|
||
export const Main = ({ children }: PropsWithChildren) => ( | ||
<main> | ||
<PageBoundary>{children}</PageBoundary> | ||
</main> | ||
) |
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,5 @@ | ||
import { PropsWithChildren } from "react" | ||
|
||
export const Root = ({ children }: PropsWithChildren) => ( | ||
<div className="flex min-h-screen flex-col">{children}</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 |
---|---|---|
@@ -0,0 +1,8 @@ | ||
import { Banner } from "./Banner" | ||
import { Footer } from "./Footer" | ||
import { Header } from "./Header" | ||
import { Headline } from "./Headline" | ||
import { Main } from "./Main" | ||
import { Root } from "./Root" | ||
|
||
export const Layout = { Root, Headline, Banner, Header, Footer, Main } |