Skip to content

Commit 32a2183

Browse files
authored
Merge pull request #1950 from cprussin/add-legal-footer-links
feat(staking): add legal links to footer & tos page
2 parents 9a2c37d + ff8e1f3 commit 32a2183

File tree

4 files changed

+1130
-16
lines changed

4 files changed

+1130
-16
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export { TermsOfService as default } from "../../components/TermsOfService";

apps/staking/src/components/Footer/index.tsx

Lines changed: 42 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -38,33 +38,61 @@ export const Footer = ({
3838
}: Omit<HTMLAttributes<HTMLElement>, "children">) => (
3939
<footer
4040
className={clsx(
41-
"text-xs font-light sm:sticky sm:bottom-0 lg:px-4",
41+
"text-xs font-light lg:sticky lg:bottom-0 lg:px-4",
4242
className,
4343
)}
4444
{...props}
4545
>
4646
<div className="border-t border-neutral-600/50 bg-pythpurple-800 lg:border-x">
47-
<MaxWidth className="flex h-48 flex-col items-center justify-between overflow-hidden py-8 sm:h-16 sm:flex-row sm:gap-10 lg:-mx-4">
48-
<div className="flex flex-col items-center gap-2 sm:flex-row sm:gap-4 md:gap-8">
49-
<Link href="https://www.pyth.network" target="_blank">
50-
<Logo className="h-10 sm:h-8" />
47+
<MaxWidth className="flex h-48 flex-col items-center justify-between overflow-hidden pb-4 pt-8 text-center lg:-mx-4 lg:h-16 lg:flex-row lg:gap-10 lg:py-0">
48+
<div className="flex flex-col items-center gap-2 lg:flex-row lg:gap-8">
49+
<Link
50+
href="https://www.pyth.network"
51+
target="_blank"
52+
className="focus:outline-none focus-visible:ring-1 focus-visible:ring-pythpurple-400"
53+
>
54+
<Logo className="h-10 lg:h-8" />
5155
<span className="sr-only">Pyth homepage</span>
5256
</Link>
5357
<div>© 2024 Pyth Data Association</div>
5458
</div>
55-
<div className="relative flex h-full items-center sm:-right-3">
56-
{SOCIAL_LINKS.map(({ name, icon: Icon, href }) => (
59+
<div className="flex flex-col items-center gap-6 lg:flex-row-reverse lg:gap-8 xl:gap-16">
60+
<div className="relative flex h-full items-center lg:-right-3">
61+
{SOCIAL_LINKS.map(({ name, icon: Icon, href }) => (
62+
<Link
63+
target="_blank"
64+
href={href}
65+
key={name}
66+
className="grid h-full place-content-center px-3 transition hover:text-pythpurple-400 focus:outline-none focus-visible:ring-1 focus-visible:ring-pythpurple-400"
67+
rel="noreferrer"
68+
>
69+
<Icon className="size-4" />
70+
<span className="sr-only">{name}</span>
71+
</Link>
72+
))}
73+
</div>
74+
<div className="flex flex-row gap-1 xl:gap-4">
5775
<Link
76+
className="-my-1 px-2 py-1 focus:outline-none focus-visible:ring-1 focus-visible:ring-pythpurple-400"
5877
target="_blank"
59-
href={href}
60-
key={name}
61-
className="grid h-full place-content-center px-3 hover:text-pythpurple-400"
62-
rel="noreferrer"
78+
href="https://pythdataassociation.com/privacy-policy"
6379
>
64-
<Icon className="size-4" />
65-
<span className="sr-only">{name}</span>
80+
Privacy Policy
6681
</Link>
67-
))}
82+
<Link
83+
className="-my-1 px-2 py-1 focus:outline-none focus-visible:ring-1 focus-visible:ring-pythpurple-400"
84+
target="_blank"
85+
href="https://pythdataassociation.com/terms-of-use"
86+
>
87+
Terms of Use
88+
</Link>
89+
<Link
90+
className="-my-1 px-2 py-1 focus:outline-none focus-visible:ring-1 focus-visible:ring-pythpurple-400"
91+
href="/terms-of-service"
92+
>
93+
Terms of Service
94+
</Link>
95+
</div>
6896
</div>
6997
</MaxWidth>
7098
</div>

apps/staking/src/components/Header/index.tsx

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import { CurrentStakeAccount } from "./current-stake-account";
55
import { HelpMenu } from "./help-menu";
66
import Logo from "./logo.svg";
77
import Logomark from "./logomark.svg";
8+
import { Link } from "../Link";
89
import { MaxWidth } from "../MaxWidth";
910
import { WalletButton } from "../WalletButton";
1011

@@ -15,8 +16,13 @@ export const Header = ({
1516
<header className={clsx("sticky top-0 w-full lg:px-4", className)} {...props}>
1617
<div className="border-b border-neutral-600/50 bg-pythpurple-800 lg:border-x">
1718
<MaxWidth className="flex h-header items-center justify-between gap-2 lg:-mx-4">
18-
<Logo className="hidden max-h-full py-4 text-pythpurple-100 sm:block" />
19-
<Logomark className="max-h-full py-4 text-pythpurple-100 sm:hidden" />
19+
<Link
20+
href="/"
21+
className="-mx-2 h-[calc(var(--header-height)_-_0.5rem)] rounded-sm p-2 text-pythpurple-100 focus:outline-none focus-visible:ring-1 focus-visible:ring-pythpurple-400"
22+
>
23+
<Logo className="hidden h-full sm:block" />
24+
<Logomark className="h-full sm:hidden" />
25+
</Link>
2026
<div className="flex flex-none flex-row items-stretch gap-4 sm:gap-8">
2127
<CurrentStakeAccount />
2228
<WalletButton className="flex-none" />

0 commit comments

Comments
 (0)