forked from git.gladyson/openmonetis
refactor: desacoplar componentes do top-nav-menu em arquivos separados
- nav-styles.ts: constantes de estilo (linkBase, linkIdle, linkActive, triggerClass) - simple-nav-link.tsx: link direto com estado ativo - dropdown-link-list.tsx: lista de itens de dropdown com tipo DropdownLinkItem - mobile-nav-link.tsx: MobileNavLink e MobileSectionLabel para o Sheet mobile - top-nav-menu.tsx: apenas TopNavMenu, importa dos arquivos acima Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
20
components/topbar/nav-styles.ts
Normal file
20
components/topbar/nav-styles.ts
Normal file
@@ -0,0 +1,20 @@
|
||||
export const linkBase =
|
||||
"inline-flex h-9 items-center justify-center rounded-md px-3 py-2 text-sm font-medium transition-colors";
|
||||
|
||||
export const linkIdle = "text-foreground hover:text-foreground hover:underline";
|
||||
|
||||
export const linkActive = "text-primary";
|
||||
|
||||
export const triggerClass = [
|
||||
"text-foreground!",
|
||||
"bg-transparent!",
|
||||
"hover:bg-transparent!",
|
||||
"hover:text-foreground!",
|
||||
"hover:underline!",
|
||||
"focus:bg-transparent!",
|
||||
"focus:text-foreground!",
|
||||
"data-[state=open]:bg-transparent!",
|
||||
"data-[state=open]:text-foreground!",
|
||||
"data-[state=open]:underline!",
|
||||
"px-3!",
|
||||
].join(" ");
|
||||
Reference in New Issue
Block a user