From ddb0bd8d090d998966333c29befe1633854639f2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tr=C3=A8sAbhi?= <43380238+tresabhi@users.noreply.github.com> Date: Wed, 5 Jun 2024 12:12:18 -0500 Subject: [PATCH] feat: start on expansive footer --- docs/{guide => about}/credits.md | 0 src/app/components/Checks.tsx | 13 ++-- src/app/docs/[directory]/[document]/page.tsx | 31 +++++++++ src/app/legal/[document]/page.tsx | 17 ----- src/components/Footer/index.css.ts | 2 +- src/components/Footer/index.tsx | 70 ++++++++------------ src/components/Navbar/index.tsx | 2 +- 7 files changed, 69 insertions(+), 66 deletions(-) rename docs/{guide => about}/credits.md (100%) create mode 100644 src/app/docs/[directory]/[document]/page.tsx delete mode 100644 src/app/legal/[document]/page.tsx diff --git a/docs/guide/credits.md b/docs/about/credits.md similarity index 100% rename from docs/guide/credits.md rename to docs/about/credits.md diff --git a/src/app/components/Checks.tsx b/src/app/components/Checks.tsx index 7893adef0..a935d348d 100644 --- a/src/app/components/Checks.tsx +++ b/src/app/components/Checks.tsx @@ -116,20 +116,25 @@ export function Checks() { {policiesAgreementIndex === -1 - ? "BlitzKit's cookies" + ? "BlitzKit's policies" : "BlitzKit's policies have changed"} This website utilizes cookies to perform analytics and personalize your experience. You can learn more through{' '} - our privacy policy. - You may opt out of personalized advertizement by visiting{' '} + + our privacy policy + + . You may opt out of personalized advertizement by visiting{' '} Google Ad Settings . By using BlitzKit, you also agree to our{' '} - terms of service. + + terms of service + + . diff --git a/src/app/docs/[directory]/[document]/page.tsx b/src/app/docs/[directory]/[document]/page.tsx new file mode 100644 index 000000000..122127782 --- /dev/null +++ b/src/app/docs/[directory]/[document]/page.tsx @@ -0,0 +1,31 @@ +import Markdown from 'markdown-to-jsx'; +import { use } from 'react'; +import { Link } from '../../../../components/Link'; +import PageWrapper from '../../../../components/PageWrapper'; +import isDev from '../../../../core/blitzkit/isDev'; + +export default function Page({ + params, +}: { + params: { document: string; directory: string }; +}) { + const markdown = use( + fetch( + `https://raw.githubusercontent.com/tresabhi/blitzkit/${isDev() ? 'dev' : 'main'}/docs/${params.directory}/${params.document}.md`, + ).then((response) => response.text()), + ); + + return ( + + + {markdown} + + + ); +} diff --git a/src/app/legal/[document]/page.tsx b/src/app/legal/[document]/page.tsx deleted file mode 100644 index ccb0ff327..000000000 --- a/src/app/legal/[document]/page.tsx +++ /dev/null @@ -1,17 +0,0 @@ -import Markdown from 'markdown-to-jsx'; -import { use } from 'react'; -import PageWrapper from '../../../components/PageWrapper'; - -export default function Page({ params }: { params: { document: string } }) { - const markdown = use( - fetch( - `https://raw.githubusercontent.com/tresabhi/blitzkit/main/docs/legal/${params.document}.md`, - ).then((response) => response.text()), - ); - - return ( - - {markdown} - - ); -} diff --git a/src/components/Footer/index.css.ts b/src/components/Footer/index.css.ts index d4868545d..eafaf4c11 100644 --- a/src/components/Footer/index.css.ts +++ b/src/components/Footer/index.css.ts @@ -3,7 +3,7 @@ import { style } from '@vanilla-extract/css'; export const containerInner = style({ justifyContent: 'space-between', width: '100%', - maxWidth: 800, + maxWidth: 1024, padding: '0 16px', '@media': { diff --git a/src/components/Footer/index.tsx b/src/components/Footer/index.tsx index db496dce4..4b9bba828 100644 --- a/src/components/Footer/index.tsx +++ b/src/components/Footer/index.tsx @@ -1,9 +1,7 @@ 'use client'; -import { Code, Flex, Link, Spinner, Text, Theme } from '@radix-ui/themes'; -import { Suspense } from 'react'; -import packageJSON from '../../../package.json'; -import { WoTBVersion } from './components/WoTBVersion'; +import { Flex, Heading, Text, Theme } from '@radix-ui/themes'; +import { Link } from '../Link'; import * as styles from './index.css'; export function Footer() { @@ -11,54 +9,40 @@ export function Footer() { - - - BlitzKit - - - - {packageJSON.version} - - - - for WoTB - - - }> - - + + BlitzKit + Everything World of Tanks Blitz - - - Made by TrèsAbhi - + + + Legal + + + Privacy policy + + + Terms of service + + + - • - - - Full credits - + + About + + + Credits + + + diff --git a/src/components/Navbar/index.tsx b/src/components/Navbar/index.tsx index 9f5a2bdb1..182fe7f22 100644 --- a/src/components/Navbar/index.tsx +++ b/src/components/Navbar/index.tsx @@ -46,7 +46,7 @@ export default function Navbar() {