From a7f0b768a58499c70888519d457e289be755bf91 Mon Sep 17 00:00:00 2001 From: tresabhi <43380238+tresabhi@users.noreply.github.com> Date: Wed, 18 Nov 2026 23:26:24 -0600 Subject: [PATCH] both! --- .../src/components/NavbarDesktop.astro | 8 +- .../website/src/components/NavbarMobile.astro | 218 ++++++++++++++---- scripts/dev-website.sh | 2 +- 3 files changed, 179 insertions(+), 49 deletions(-) diff --git a/packages/website/src/components/NavbarDesktop.astro b/packages/website/src/components/NavbarDesktop.astro index c63164bf0..2f110f0da 100644 --- a/packages/website/src/components/NavbarDesktop.astro +++ b/packages/website/src/components/NavbarDesktop.astro @@ -1,19 +1,21 @@ --- import { GearIcon } from "@radix-ui/react-icons"; import { api } from "../api/dynamic"; -import { tools } from "../constants/tools"; +import { tools, type Tool } from "../constants/tools"; import type { LocaleAcceptorProps } from "../hooks/useLocale"; import { Logo } from "../icons/Logo"; import { LinkI18nWrapper } from "./LinkI18nWrapper"; import { Text } from "./Text"; -type Props = LocaleAcceptorProps; +export type Props = LocaleAcceptorProps & { + tool: Tool; +}; const { locale } = Astro.props; const strings = await api.strings(locale); -const filtered = Object.values(tools).filter( +export const filtered = Object.values(tools).filter( (tool) => !tool.href && (tool.navbar ?? true), ); --- diff --git a/packages/website/src/components/NavbarMobile.astro b/packages/website/src/components/NavbarMobile.astro index f71671795..b5fcd095e 100644 --- a/packages/website/src/components/NavbarMobile.astro +++ b/packages/website/src/components/NavbarMobile.astro @@ -1,14 +1,12 @@ --- import { CaretUpIcon, GearIcon } from "@radix-ui/react-icons"; import { api } from "../api/dynamic"; -import type { Tool } from "../constants/tools"; -import type { LocaleAcceptorProps } from "../hooks/useLocale"; import { Logo } from "../icons/Logo"; +import { LinkI18nWrapper } from "./LinkI18nWrapper"; +import { filtered } from "./NavbarDesktop.astro"; +import { Scroller, ScrollerOrientation } from "./Scroller"; import { Text } from "./Text"; - -type Props = LocaleAcceptorProps & { - tool: Tool; -}; +export { type Props } from "./NavbarDesktop.astro"; const { locale, tool } = Astro.props; @@ -18,73 +16,164 @@ const strings = await api.strings(locale); -