Skip to content

Commit

Permalink
add the link to main app and change the title
Browse files Browse the repository at this point in the history
  • Loading branch information
ItsukiKigoshi committed Jul 30, 2024
1 parent 8d5e6fe commit e220b11
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 15 deletions.
9 changes: 7 additions & 2 deletions docusaurus.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import type { Config } from "@docusaurus/types";
import type * as Preset from "@docusaurus/preset-classic";

const config: Config = {
title: "ICU Catalogue",
title: "ICU Catalogue Docs",
tagline: "Academic Planning Made Easy",
favicon: "img/favicon.ico",

Expand Down Expand Up @@ -59,7 +59,7 @@ const config: Config = {
// Replace with your project's social card
image: "img/docusaurus-social-card.jpg",
navbar: {
title: "ICU Catalogue",
title: "ICU Catalogue Docs",
logo: {
alt: "ICU Catalogue Logo",
src: "img/logo.svg",
Expand All @@ -72,6 +72,11 @@ const config: Config = {
label: "Tutorial",
},
{ to: "/blog", label: "Blog", position: "left" },
{
href: "https://www.catalogue.icu/",
label: "ICU Catalogue",
position: "right",
},
{
href: "https://github.com/ItsukiKigoshi/icu-catalogue",
label: "GitHub",
Expand Down
28 changes: 15 additions & 13 deletions src/pages/index.tsx
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
import clsx from 'clsx';
import Link from '@docusaurus/Link';
import useDocusaurusContext from '@docusaurus/useDocusaurusContext';
import Layout from '@theme/Layout';
import HomepageFeatures from '@site/src/components/HomepageFeatures';
import Heading from '@theme/Heading';
import clsx from "clsx";
import Link from "@docusaurus/Link";
import useDocusaurusContext from "@docusaurus/useDocusaurusContext";
import Layout from "@theme/Layout";
import HomepageFeatures from "@site/src/components/HomepageFeatures";
import Heading from "@theme/Heading";

import styles from './index.module.css';
import styles from "./index.module.css";

function HomepageHeader() {
const {siteConfig} = useDocusaurusContext();
const { siteConfig } = useDocusaurusContext();
return (
<header className={clsx('hero hero--primary', styles.heroBanner)}>
<header className={clsx("hero hero--primary", styles.heroBanner)}>
<div className="container">
<Heading as="h1" className="hero__title">
{siteConfig.title}
Expand All @@ -19,8 +19,9 @@ function HomepageHeader() {
<div className={styles.buttons}>
<Link
className="button button--secondary button--lg"
to="/docs/intro">
Docusaurus Tutorial - 5min ⏱️
to="/docs/intro"
>
Go to Docs
</Link>
</div>
</div>
Expand All @@ -29,11 +30,12 @@ function HomepageHeader() {
}

export default function Home(): JSX.Element {
const {siteConfig} = useDocusaurusContext();
const { siteConfig } = useDocusaurusContext();
return (
<Layout
title={`Hello from ${siteConfig.title}`}
description="Description will go into a meta tag in <head />">
description="Description will go into a meta tag in <head />"
>
<HomepageHeader />
<main>
<HomepageFeatures />
Expand Down

0 comments on commit e220b11

Please sign in to comment.