Files
gruperly/apps/web/src/components/layout/Header.tsx
Jose Selesan 90f31290d4 feat(web): pulido mobile de ficha de grupo, alumno, nuevo grupo y ajustes
- Ficha de grupo: "Agregar miembro" a todo el ancho y debajo Estadísticas,
  Cobrar y Compartir con icono y texto (antes iconos sueltos en mobile).
  Los mensajes automáticos de WhatsApp quedan en una fila plegable que
  arranca cerrada si no hay ninguno activo.
- Historial del alumno: arranca en la primera clase registrada si es
  anterior al alta, como la lista y la regla de riesgo ("1 de 5" en ambos).
- Nuevo grupo: cupo 10 por defecto, precio vacío obligatorio y foco
  inicial en el nombre.
- Ajustes: chevron en Seguridad; el botón de tema del header queda solo
  en desktop (en mobile vive en Apariencia).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 14:33:37 -03:00

32 lines
1.3 KiB
TypeScript

import { Link } from '@tanstack/react-router'
import { Logo } from '../brand'
import { Breadcrumb } from './Breadcrumb'
import { ThemeToggle } from './ThemeToggle'
import { UserMenu } from './UserMenu'
export function Header() {
return (
<header className="sticky top-0 z-40 h-16 w-full border-b border-border bg-background/90 backdrop-blur">
<div className="mx-auto flex h-full w-full max-w-7xl items-center justify-between px-4 lg:px-6">
<div className="flex min-w-0 items-center">
{/* `Link` and not `<a>`: on mobile the logo is the only way back to the
home screen and an anchor would reload the whole document, losing
the in-memory state (React Query cache, install event). */}
<Link to="/" className="flex items-center lg:hidden" aria-label="Gruperly inicio">
<Logo className="h-8" />
</Link>
<Breadcrumb />
</div>
<div className="flex items-center gap-2">
{/* On mobile the theme lives only in Ajustes → Apariencia: in the
header it took the space next to the avatar for something you
change once. On desktop there is room for the shortcut. */}
<div className="hidden lg:block">
<ThemeToggle />
</div>
<UserMenu />
</div>
</div>
</header>
)
}