diff --git a/redirects.json b/redirects.json index 999d445e..e5a21cf9 100644 --- a/redirects.json +++ b/redirects.json @@ -1,14 +1,47 @@ [ - { "source": "/docs/what-is-javaistic", "destination": "/", "permanent": false }, + { + "source": "/blog", + "destination": "https://blog-javaistic.vercel.app/", + "permanent": false + }, + { + "source": "/changelog", + "destination": "https://changelog-javaistic.vercel.app/", + "permanent": false + }, + { + "source": "/community", + "destination": "https://discord.gg/RkHJqvK9r8", + "permanent": false + }, + { + "source": "/discord", + "destination": "https://discord.gg/RkHJqvK9r8", + "permanent": false + }, + { + "source": "/docs/what-is-javaistic", + "destination": "/", + "permanent": false + }, { "source": "/forum", "destination": "https://github.com/javaistic/javaistic/discussions", "permanent": false }, - { "source": "/community", "destination": "https://discord.gg/RkHJqvK9r8", "permanent": false }, - { "source": "/changelog", "destination": "https://javaistic-changelog.vercel.app/", "permanent": false }, - { "source": "/license", "destination": "https://raw.githubusercontent.com/javaistic/javaistic/main/LICENSE", "permanent": false }, - { "source": "/discord", "destination": "https://discord.gg/RkHJqvK9r8", "permanent": false }, - { "source": "/status", "destination": "https://javaistic.betteruptime.com/", "permanent": false }, - { "source": "/stats", "destination": "https://javaistic.betteruptime.com/", "permanent": false } -] + { + "source": "/license", + "destination": "https://raw.githubusercontent.com/javaistic/javaistic/main/LICENSE", + "permanent": false + }, + { + "source": "/stats", + "destination": "https://javaistic.betteruptime.com/", + "permanent": false + }, + { + "source": "/status", + "destination": "https://javaistic.betteruptime.com/", + "permanent": false + } +] \ No newline at end of file diff --git a/src/components/Header.js b/src/components/Header.js index e4999531..b2841b11 100644 --- a/src/components/Header.js +++ b/src/components/Header.js @@ -3,8 +3,8 @@ import { Search } from '@/components/Search' import clsx from 'clsx' import Link from 'next/link' import Router from 'next/router' -import ThemeChanger from './ThemeChanger' import MenuButton from './home/Menu' +import ThemeChanger from './ThemeChanger' export function Header({ navIsOpen, onNavToggle }) { return ( @@ -29,7 +29,6 @@ export function Header({ navIsOpen, onNavToggle }) {
- ) } + +export function LogoMark(props) { + return ( + + + + + ) +} diff --git a/src/components/LogoMark.js b/src/components/LogoMark.js deleted file mode 100644 index 4c470477..00000000 --- a/src/components/LogoMark.js +++ /dev/null @@ -1,18 +0,0 @@ -export function LogoMark(props) { - return ( - - - - - ) -} diff --git a/src/components/Logos.js b/src/components/Logos.js new file mode 100644 index 00000000..e7e46230 --- /dev/null +++ b/src/components/Logos.js @@ -0,0 +1,92 @@ +export function GitHub(props) { + return ( + + + + ) +} + +export function Twitter(props) { + return ( + + + + ) +} + +export function Vercel(props) { + return ( + + + + ) +} + +export function IndianFlag(props) { + return ( + + + + + + + + + + + + + + + + + + ) +} diff --git a/src/components/Vercel.js b/src/components/Vercel.js deleted file mode 100644 index 61e95321..00000000 --- a/src/components/Vercel.js +++ /dev/null @@ -1,10 +0,0 @@ -export function Vercel(props) { - return ( - - - - ) -} diff --git a/src/components/home/Footer.js b/src/components/home/Footer.js index 495517ad..6b2a8299 100644 --- a/src/components/home/Footer.js +++ b/src/components/home/Footer.js @@ -1,37 +1,11 @@ import { Logo } from '@/components/Logo' -import { Vercel } from '@/components/Vercel' +import { GitHub, Twitter, Vercel } from '@/components/Logos' import { documentationNav } from '@/navs/documentation' import { programsNav } from '@/navs/program' import clsx from 'clsx' import Link from 'next/link' import styles from './Footer.module.css' -const GitHub = () => ( - - - -) - -const Twitter = () => ( - - - -) - const footerNav = { 'Getting started': { className: 'row-span-2', @@ -56,7 +30,7 @@ const footerNav = { items: [ { title: 'Brand', href: '/brand' }, { title: 'Sponsors', href: '/sponsors' }, - { title: 'Changelog', href: 'https://javaistic-changelog.vercel.app/' }, + { title: 'Changelog', href: '/changelog' }, { title: 'Open Source', href: '/' }, ], }, @@ -65,7 +39,7 @@ const footerNav = { { title: 'GitHub', href: 'https://github.com/javaistic/javaistic' }, { title: 'Discord', href: '/discord' }, { title: 'Twitter', href: 'https://twitter.com/javaistic' }, - { title: 'Blog', href: '/' }, + { title: 'Blog', href: '/blog' }, ], }, } @@ -75,18 +49,18 @@ export function Footer() {
diff --git a/src/components/home/Hero.js b/src/components/home/Hero.js index 5fd1ea22..bd9a10b9 100644 --- a/src/components/home/Hero.js +++ b/src/components/home/Hero.js @@ -37,7 +37,8 @@ const { lines } = tokenizeWithLines.java(`class BinarySearch { else System.out.println("Element found at index " + result); } -}`) +} +`) function CompletionDemo() { const { ref } = useInView({ threshold: 0.5, triggerOnce: true }) diff --git a/src/layouts/ContentsLayout.js b/src/layouts/ContentsLayout.js index 44a5b3e0..885442d6 100644 --- a/src/layouts/ContentsLayout.js +++ b/src/layouts/ContentsLayout.js @@ -2,6 +2,7 @@ import { ClassTable } from '@/components/ClassTable' import { PageHeader } from '@/components/PageHeader' import { usePrevNext } from '@/hooks/usePrevNext' import { SidebarContext, SidebarLayout } from '@/layouts/SidebarLayout' +import { ArrowLeftIcon, ArrowRightIcon } from '@heroicons/react/outline' import clsx from 'clsx' import Link from 'next/link' import { useRouter } from 'next/router' @@ -191,21 +192,17 @@ export function ContentsLayout({ children, meta, classes, tableOfContents }) {
{prev && ( - - + + {prev.shortTitle || prev.title} )} {next && ( - + {next.shortTitle || next.title} - + )} diff --git a/src/layouts/SidebarLayout.js b/src/layouts/SidebarLayout.js index 1a4c5dd1..72a0e7af 100644 --- a/src/layouts/SidebarLayout.js +++ b/src/layouts/SidebarLayout.js @@ -201,7 +201,7 @@ function TopLevelNav() { Programs } > - Practice + Blog