Skip to content

Commit

Permalink
Navigation Path Modifications
Browse files Browse the repository at this point in the history
  • Loading branch information
Shanks0465 committed Aug 28, 2024
1 parent a26bc2b commit 3a30162
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 11 deletions.
21 changes: 11 additions & 10 deletions frontend/components/Navbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -241,35 +241,36 @@ interface NavItem {
href?: string;
}

const basePath = process.env.NEXT_PUBLIC_BASE_PATH || "";
const NAV_ITEMS: Array<NavItem> = [
{ label: "Home", href: "/" },
{ label: "Home", href: `${basePath}/` },
{
label: "Areas",
children: [
{ label: "Transliteration", href: "/areas/xlit" },
{ label: "Transliteration", href: `${basePath}/areas/xlit` },
{
label: "Machine Translation",
href: "/areas/nmt",
href: `${basePath}/areas/nmt`,
},
{
label: "Automatic Speech Recognition",
href: "/areas/asr",
href: `${basePath}/areas/asr`,
},
{
label: "Speech Synthesis",
href: "/areas/tts",
href: `${basePath}/areas/tts`,
},
{
label: "Large Language Models",
href: "/areas/llm",
href: `${basePath}/areas/llm`,
},
],
},
{
label: "Tools",
href: "/tools",
href: `${basePath}/tools`,
},
{ label: "Publications", href: "/publications" },
{ label: "People", href: "/people" },
{ label: "Careers", href: "/careers" },
{ label: "Publications", href: `${basePath}/publications` },
{ label: "People", href: `${basePath}/people` },
{ label: "Careers", href: `${basePath}/careers` },
];
4 changes: 3 additions & 1 deletion frontend/next.config.mjs
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
/** @type {import('next').NextConfig} */
const isProd = process.env.NODE_ENV === "production";

const nextConfig = {
basePath: "/ai4b-website",
basePath: isProd ? "/ai4b-website" : "",
output: "export",
eslint: {
ignoreDuringBuilds: true,
Expand Down

0 comments on commit 3a30162

Please sign in to comment.