mobilny navbar updatnuty

This commit is contained in:
Noble
2025-01-28 22:18:14 +01:00
parent 86c299c045
commit 608efcf74f
4 changed files with 71 additions and 22 deletions

View File

@@ -184,3 +184,39 @@ export const SearchIcon = (props: IconSvgProps) => (
/>
</svg>
);
export const InstagramIcon = (props: IconSvgProps) => (
<svg
aria-hidden="true"
fill="none"
focusable="false"
height="1em"
role="presentation"
viewBox="0 0 24 24"
width="1em"
{...props}
>
<path
clipRule="evenodd"
d="M12 18C15.3137 18 18 15.3137 18 12C18 8.68629 15.3137 6 12 6C8.68629 6 6 8.68629 6 12C6 15.3137 8.68629 18 12 18ZM12 16C14.2091 16 16 14.2091 16 12C16 9.79086 14.2091 8 12 8C9.79086 8 8 9.79086 8 12C8 14.2091 9.79086 16 12 16Z"
stroke="currentColor"
strokeLinecap="round"
strokeLinejoin="round"
strokeWidth="2"
/>
<path
d="M18 5C17.4477 5 17 5.44772 17 6C17 6.55228 17.4477 7 18 7C18.5523 7 19 6.55228 19 6C19 5.44772 18.5523 5 18 5Z"
stroke="currentColor"
strokeLinecap="round"
strokeLinejoin="round"
strokeWidth="2"
/>
<path
clipRule="evenodd"
d="M1.65396 4.27606C1 5.55953 1 7.23969 1 10.6V13.4C1 16.7603 1 18.4405 1.65396 19.7239C2.2292 20.8529 3.14708 21.7708 4.27606 22.346C5.55953 23 7.23969 23 10.6 23H13.4C16.7603 23 18.4405 23 19.7239 22.346C20.8529 21.7708 21.7708 20.8529 22.346 19.7239C23 18.4405 23 16.7603 23 13.4V10.6C23 7.23969 23 5.55953 22.346 4.27606C21.7708 3.14708 20.8529 2.2292 19.7239 1.65396C18.4405 1 16.7603 1 13.4 1H10.6C7.23969 1 5.55953 1 4.27606 1.65396C3.14708 2.2292 2.2292 3.14708 1.65396 4.27606ZM13.4 3H10.6C8.88684 3 7.72225 3.00156 6.82208 3.0751C5.94524 3.14674 5.49684 3.27659 5.18404 3.43597C4.43139 3.81947 3.81947 4.43139 3.43597 5.18404C3.27659 5.49684 3.14674 5.94524 3.0751 6.82208C3.00156 7.72225 3 8.88684 3 10.6V13.4C3 15.1132 3.00156 16.2777 3.0751 17.1779C3.14674 18.0548 3.27659 18.5032 3.43597 18.816C3.81947 19.5686 4.43139 20.1805 5.18404 20.564C5.49684 20.7234 5.94524 20.8533 6.82208 20.9249C7.72225 20.9984 8.88684 21 10.6 21H13.4C15.1132 21 16.2777 20.9984 17.1779 20.9249C18.0548 20.8533 18.5032 20.7234 18.816 20.564C19.5686 20.1805 20.1805 19.5686 20.564 18.816C20.7234 18.5032 20.8533 18.0548 20.9249 17.1779C20.9984 16.2777 21 15.1132 21 13.4V10.6C21 8.88684 20.9984 7.72225 20.9249 6.82208C20.8533 5.94524 20.7234 5.49684 20.564 5.18404C20.1805 4.43139 19.5686 3.81947 18.816 3.43597C18.5032 3.27659 18.0548 3.14674 17.1779 3.0751C16.2777 3.00156 15.1132 3 13.4 3Z"
stroke="currentColor"
strokeLinecap="round"
strokeLinejoin="round"
strokeWidth="2"
/>
</svg>
);

View File

@@ -14,6 +14,7 @@ import { Input } from "@heroui/input";
import { link as linkStyles } from "@heroui/theme";
import NextLink from "next/link";
import clsx from "clsx";
import { Image } from "@heroui/image";
import { siteConfig } from "@/config/site";
import { ThemeSwitch } from "@/components/theme-switch";
@@ -23,9 +24,8 @@ import {
DiscordIcon,
HeartFilledIcon,
SearchIcon,
Logo,
InstagramIcon,
} from "@/components/icons";
import {Image} from "@heroui/image";
export const Navbar = () => {
const searchInput = (
@@ -54,11 +54,7 @@ export const Navbar = () => {
<NavbarContent className="basis-1/5 sm:basis-full" justify="start">
<NavbarBrand className="gap-3 max-w-fit">
<NextLink className="flex justify-start items-center gap-1" href="/">
<Image
src="/coloradl.svg"
className="size-7"
>
</Image>
<Image className="size-7" src="/coloradl.svg" />
<p className="font-bold text-inherit">Adlerka Space Program</p>
</NextLink>
</NavbarBrand>
@@ -68,7 +64,7 @@ export const Navbar = () => {
<NextLink
className={clsx(
linkStyles({ color: "foreground" }),
"data-[active=true]:text-primary data-[active=true]:font-medium"
"data-[active=true]:text-primary data-[active=true]:font-medium",
)}
color="foreground"
href={item.href}
@@ -91,9 +87,9 @@ export const Navbar = () => {
<Link isExternal href={siteConfig.links.github} title="GitHub">
<GithubIcon className="text-default-500" />
</Link>
<Link isExternal href={siteConfig.links.discord} title="Discord">
<Link isExternal href={siteConfig.links.discord} title="Discord">
<DiscordIcon className="text-default-500" />
</Link>
</Link>
<ThemeSwitch />
</NavbarItem>
<NavbarItem className="hidden md:flex">
@@ -102,8 +98,8 @@ export const Navbar = () => {
as={Link}
className="text-sm font-normal text-default-600 bg-default-100"
href={siteConfig.links.sponsor}
target="_self"
startContent={<HeartFilledIcon className="text-danger" />}
target="_self"
variant="flat"
>
Sponsor
@@ -112,26 +108,28 @@ export const Navbar = () => {
</NavbarContent>
<NavbarContent className="sm:hidden basis-1 pl-4" justify="end">
<Link isExternal href={siteConfig.links.github}>
<GithubIcon className="text-default-500" />
<Link isExternal href={siteConfig.links.instagram}>
<InstagramIcon className="text-default-500" />
</Link>
<ThemeSwitch />
<NavbarMenuToggle />
</NavbarContent>
<NavbarMenu>
<div className="mx-4 mt-2 flex flex-col gap-2">
<div className="mx-4 mt-2 flex flex-col gap-5">
{siteConfig.navMenuItems.map((item, index) => (
<NavbarMenuItem key={`${item}-${index}`}>
<Link
color={
index === 2
index === 1 || index === 2
? "primary"
: index === siteConfig.navMenuItems.length - 1
: index === 3
? "danger"
: "foreground"
: index >= 4 && index <= 6
? "secondary"
: "foreground"
}
href="#"
href={item.href}
size="lg"
>
{item.label}

View File

@@ -2,7 +2,8 @@ export type SiteConfig = typeof siteConfig;
export const siteConfig = {
name: "Adlerka Space Program",
description: "ASP is a team of young engineers who aspire to reach the stars.",
description:
"ASP is a team of young engineers who aspire to reach the stars.",
image: "/whatwedo.png",
navItems: [
{
@@ -36,17 +37,31 @@ export const siteConfig = {
label: "Blog",
href: "/blog",
},
{
label: "SPŠE Adlerka",
href: "https://www.adlerka.sk/",
},
{
label: "Instagram",
href: "https://www.instagram.com/adlerka_space/",
},
{
label: "Twitter / X",
href: "https://x.com/adlerka_space",
},
{
label: "Facebook",
href: "https://www.facebook.com/people/Adlerka-Space-Program/61555850837721/",
},
],
links: {
github: "https://github.com/7Noble",
twitter: "https://x.com/adlerka_space",
docs: "https://heroui.com",
discord: "https://discordapp.com/users/404304818178621440",
instagram: "https://www.instagram.com/adlerka_space/",
facebook:
"https://www.facebook.com/people/Adlerka-Space-Program/61555850837721/",
sponsor: "/sponsor",
},
};

View File

@@ -96,7 +96,7 @@ export default function DocsPage() {
<CardBody>
<p className="pb-2">
We are a team of high school electrical engineering students,
aged 16 to 19, proudly representing Slovakia in the 2025 edition
aged 17 to 19, proudly representing Slovakia in the 2025 edition
of the CanSat project. With a genuine passion for science and
technology, we are excited to embark on our second project in
the field of space exploration.