mirror of
https://github.com/tuono-labs/tuono
synced 2026-07-29 13:52:46 -07:00
feat: remove home page from documentation website (#187)
Co-authored-by: Valerio Ageno <valerio.ageno@qonto.com>
This commit is contained in:
@@ -28,12 +28,6 @@ export default function TuonoBreadcrumbs({
|
|||||||
"position": 1,
|
"position": 1,
|
||||||
"name": "Tuono - The React/Rust fullstack framework",
|
"name": "Tuono - The React/Rust fullstack framework",
|
||||||
"item": "https://tuono.dev"
|
"item": "https://tuono.dev"
|
||||||
},
|
|
||||||
{
|
|
||||||
"@type": "ListItem",
|
|
||||||
"position": 2,
|
|
||||||
"name": "Tuono - Documentation",
|
|
||||||
"item": "https://tuono.dev/documentation"
|
|
||||||
}${breadcrumbs.length > 0 ? ',' : ''}
|
}${breadcrumbs.length > 0 ? ',' : ''}
|
||||||
${breadcrumbs
|
${breadcrumbs
|
||||||
.map((br, i) =>
|
.map((br, i) =>
|
||||||
@@ -54,13 +48,7 @@ export default function TuonoBreadcrumbs({
|
|||||||
mb="md"
|
mb="md"
|
||||||
mt="md"
|
mt="md"
|
||||||
>
|
>
|
||||||
<Button
|
<Button href="/" component={Link} variant="subtle" radius="xl" p={5}>
|
||||||
href="/documentation"
|
|
||||||
component={Link}
|
|
||||||
variant="subtle"
|
|
||||||
radius="xl"
|
|
||||||
p={5}
|
|
||||||
>
|
|
||||||
<IconBolt />
|
<IconBolt />
|
||||||
</Button>
|
</Button>
|
||||||
{breadcrumbs.map((br) => (
|
{breadcrumbs.map((br) => (
|
||||||
|
|||||||
@@ -1,11 +1,6 @@
|
|||||||
import type { JSX } from 'react'
|
import type { JSX } from 'react'
|
||||||
import { Flex, Button, ActionIcon, Group } from '@mantine/core'
|
import { Flex, ActionIcon, Group } from '@mantine/core'
|
||||||
import {
|
import { IconBrandGithub, IconBrandDiscord } from '@tabler/icons-react'
|
||||||
IconBrandGithub,
|
|
||||||
IconBook,
|
|
||||||
IconBrandDiscord,
|
|
||||||
} from '@tabler/icons-react'
|
|
||||||
import { Link } from 'tuono'
|
|
||||||
|
|
||||||
import ThemeBtn from '../theme-btn'
|
import ThemeBtn from '../theme-btn'
|
||||||
|
|
||||||
@@ -13,16 +8,6 @@ export default function Actions(): JSX.Element {
|
|||||||
return (
|
return (
|
||||||
<Flex gap={8}>
|
<Flex gap={8}>
|
||||||
<Group gap={8}>
|
<Group gap={8}>
|
||||||
<Button
|
|
||||||
component={Link}
|
|
||||||
href="/documentation"
|
|
||||||
visibleFrom="sm"
|
|
||||||
size="compact-lg"
|
|
||||||
rightSection={<IconBook />}
|
|
||||||
autoContrast
|
|
||||||
>
|
|
||||||
Get started
|
|
||||||
</Button>
|
|
||||||
<ActionIcon
|
<ActionIcon
|
||||||
variant="default"
|
variant="default"
|
||||||
size="lg"
|
size="lg"
|
||||||
|
|||||||
@@ -10,11 +10,7 @@ interface SidebarProps {
|
|||||||
export default function Sidebar({ close }: SidebarProps): JSX.Element {
|
export default function Sidebar({ close }: SidebarProps): JSX.Element {
|
||||||
return (
|
return (
|
||||||
<AppShell.Navbar p="md">
|
<AppShell.Navbar p="md">
|
||||||
<SidebarLink
|
<SidebarLink href="/" label="Home" onClick={close} />
|
||||||
href="/documentation"
|
|
||||||
label="Getting started"
|
|
||||||
onClick={close}
|
|
||||||
/>
|
|
||||||
<SidebarLink
|
<SidebarLink
|
||||||
href="/documentation/installation"
|
href="/documentation/installation"
|
||||||
label="Installation"
|
label="Installation"
|
||||||
|
|||||||
@@ -1,13 +1,17 @@
|
|||||||
import type { ReactNode, JSX } from 'react'
|
import type { ReactNode, JSX } from 'react'
|
||||||
|
|
||||||
import {
|
import {
|
||||||
ColorSchemeScript,
|
ColorSchemeScript,
|
||||||
createTheme,
|
createTheme,
|
||||||
MantineProvider,
|
MantineProvider,
|
||||||
AppShell,
|
AppShell,
|
||||||
|
Container,
|
||||||
} from '@mantine/core'
|
} from '@mantine/core'
|
||||||
import { useDisclosure } from '@mantine/hooks'
|
import { useDisclosure } from '@mantine/hooks'
|
||||||
import { Head, useRouter } from 'tuono'
|
import { Head } from 'tuono'
|
||||||
|
|
||||||
|
import EditPage from '@/components/edit-page'
|
||||||
|
import MdxProvider from '@/components/mdx-provider'
|
||||||
import Navbar from '@/components/navbar'
|
import Navbar from '@/components/navbar'
|
||||||
import Sidebar from '@/components/sidebar'
|
import Sidebar from '@/components/sidebar'
|
||||||
|
|
||||||
@@ -61,8 +65,6 @@ const theme = createTheme({
|
|||||||
export default function RootRoute({ children }: RootRouteProps): JSX.Element {
|
export default function RootRoute({ children }: RootRouteProps): JSX.Element {
|
||||||
const [opened, { toggle }] = useDisclosure()
|
const [opened, { toggle }] = useDisclosure()
|
||||||
|
|
||||||
const { pathname } = useRouter()
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<Head>
|
<Head>
|
||||||
@@ -98,8 +100,13 @@ export default function RootRoute({ children }: RootRouteProps): JSX.Element {
|
|||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<Navbar opened={opened} toggle={toggle} />
|
<Navbar opened={opened} toggle={toggle} />
|
||||||
{pathname.startsWith('/documentation') && <Sidebar close={toggle} />}
|
<Sidebar close={toggle} />
|
||||||
{children}
|
<AppShell.Main>
|
||||||
|
<Container id="mdx-root" component="article" size="md" p={20}>
|
||||||
|
<MdxProvider>{children}</MdxProvider>
|
||||||
|
<EditPage />
|
||||||
|
</Container>
|
||||||
|
</AppShell.Main>
|
||||||
</AppShell>
|
</AppShell>
|
||||||
</MantineProvider>
|
</MantineProvider>
|
||||||
</>
|
</>
|
||||||
|
|||||||
@@ -1,20 +0,0 @@
|
|||||||
import type { ReactNode, JSX } from 'react'
|
|
||||||
import { AppShell, Container } from '@mantine/core'
|
|
||||||
|
|
||||||
import MdxProvider from '@/components/mdx-provider'
|
|
||||||
import EditPage from '@/components/edit-page'
|
|
||||||
|
|
||||||
interface RootRouteProps {
|
|
||||||
children: ReactNode
|
|
||||||
}
|
|
||||||
|
|
||||||
export default function RootRoute({ children }: RootRouteProps): JSX.Element {
|
|
||||||
return (
|
|
||||||
<AppShell.Main>
|
|
||||||
<Container id="mdx-root" component="article" size="md" p={20}>
|
|
||||||
<MdxProvider>{children}</MdxProvider>
|
|
||||||
<EditPage />
|
|
||||||
</Container>
|
|
||||||
</AppShell.Main>
|
|
||||||
)
|
|
||||||
}
|
|
||||||
+1
-1
@@ -2,7 +2,7 @@ import MetaTags from '@/components/meta-tags'
|
|||||||
|
|
||||||
<MetaTags
|
<MetaTags
|
||||||
title="Tuono - Documentation"
|
title="Tuono - Documentation"
|
||||||
canonical="https://tuono.dev/documentation"
|
canonical="https://tuono.dev"
|
||||||
description="Tuono is a full-stack framework for building React applications using Rust as the backend."
|
description="Tuono is a full-stack framework for building React applications using Rust as the backend."
|
||||||
/>
|
/>
|
||||||
|
|
||||||
@@ -1,17 +0,0 @@
|
|||||||
import type { JSX } from 'react'
|
|
||||||
|
|
||||||
import Hero from '@/components/hero'
|
|
||||||
import MetaTags from '@/components/meta-tags'
|
|
||||||
|
|
||||||
export default function IndexPage(): JSX.Element {
|
|
||||||
return (
|
|
||||||
<>
|
|
||||||
<MetaTags
|
|
||||||
title="Tuono - The React/Rust full-stack framework"
|
|
||||||
canonical="https://tuono.dev"
|
|
||||||
description="The technologies we love seamlessly working together to unleash the highest web performance ever met on React"
|
|
||||||
/>
|
|
||||||
<Hero />
|
|
||||||
</>
|
|
||||||
)
|
|
||||||
}
|
|
||||||
Reference in New Issue
Block a user