refactor(web): rutas de la app de alumnos en inglés
/acceso → /access, /alumno/* → /student/* (welcome, classes, payments, profile, notify-absence, report-payment). El link del mail de confirmación pasa a /access/email/:token. AGENTS.md documenta que los paths van en inglés. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -65,7 +65,7 @@ bun --filter @gruperly/web icons # regenera los iconos PWA de apps/web
|
|||||||
- **zod en v3.24 (pin exacto)**, no v4: `better-call` (transitiva de better-auth) pide `zod ^4` — ese peer warning es conocido y aceptado. `validator` de hono (`hono/validator`) sustituyó a `@hono/zod-validator` (sus tipos duales zod v3/v4 causaban TS2589/exhaustion no resolubles con `ZodTypeAny`); las rutas tipan `c.req.valid` vía el `ValidationInput` derivado del schema.
|
- **zod en v3.24 (pin exacto)**, no v4: `better-call` (transitiva de better-auth) pide `zod ^4` — ese peer warning es conocido y aceptado. `validator` de hono (`hono/validator`) sustituyó a `@hono/zod-validator` (sus tipos duales zod v3/v4 causaban TS2589/exhaustion no resolubles con `ZodTypeAny`); las rutas tipan `c.req.valid` vía el `ValidationInput` derivado del schema.
|
||||||
- **PWA (`apps/web`)**: Workbox precachea todo lo que emite Vite, así que el tamaño del precache es un costo real de arranque offline. Cuatro trampas ya pisadas: (1) `globIgnores: ['**/workbox-*.js']` matchea también `workbox-window.*.js`, que es el módulo cliente de `virtual:pwa-register` — excluirlo rompe el registro del SW en cada carga; solo se excluye `**/sw.js`. (2) Importar `@fontsource-variable/inter/wght.css` arrastra los 7 subsets (~220 KB que el navegador nunca baja); por eso los `@font-face` de `latin`/`latin-ext` están escritos a mano en `src/index.css`. **No re-agregar `<link>` a `fonts.googleapis.com`**: rompe el offline. (3) El SW necesita contexto seguro (HTTPS o `localhost`); por IP de LAN sobre `http://` no se registra y no avisa. (4) El aviso de instalación vive en `PwaProvider` (fuera del `RouterProvider`, así que sigue la ruta con `router.subscribe('onResolved')`) y **no** en `RootLayout`: `AppLayoutGuard` desmonta `RootLayout` cada vez que su query de onboarding vuelve a `pending`, y un `settled` de dwell en el hijo se perdería en cada navegación.
|
- **PWA (`apps/web`)**: Workbox precachea todo lo que emite Vite, así que el tamaño del precache es un costo real de arranque offline. Cuatro trampas ya pisadas: (1) `globIgnores: ['**/workbox-*.js']` matchea también `workbox-window.*.js`, que es el módulo cliente de `virtual:pwa-register` — excluirlo rompe el registro del SW en cada carga; solo se excluye `**/sw.js`. (2) Importar `@fontsource-variable/inter/wght.css` arrastra los 7 subsets (~220 KB que el navegador nunca baja); por eso los `@font-face` de `latin`/`latin-ext` están escritos a mano en `src/index.css`. **No re-agregar `<link>` a `fonts.googleapis.com`**: rompe el offline. (3) El SW necesita contexto seguro (HTTPS o `localhost`); por IP de LAN sobre `http://` no se registra y no avisa. (4) El aviso de instalación vive en `PwaProvider` (fuera del `RouterProvider`, así que sigue la ruta con `router.subscribe('onResolved')`) y **no** en `RootLayout`: `AppLayoutGuard` desmonta `RootLayout` cada vez que su query de onboarding vuelve a `pending`, y un `settled` de dwell en el hijo se perdería en cada navegación.
|
||||||
- **Aviso de instalación (`src/features/pwa/`)**: se ofrece solo con **sesión iniciada**, fuera de `/onboarding` y tras **20 s seguidos en la misma ruta** (navegar antes reinicia la cuenta; después de armado ya no se oculta). El descarte es definitivo vía `localStorage['pwa-install-dismissed']`. Ojo: `_authenticated` **no** es un guard de sesión —`AppLayoutGuard` renderiza `RootLayout` aunque no haya `user`—, así que el gate se chequea en el provider. Safari en iOS no dispara `beforeinstallprompt`: ahí se muestra `IosInstallHint` con la instrucción de Compartir → Agregar a pantalla de inicio (excluye CriOS/FxiOS/EdgiOS, que también usan WebKit pero se instalan desde Safari).
|
- **Aviso de instalación (`src/features/pwa/`)**: se ofrece solo con **sesión iniciada**, fuera de `/onboarding` y tras **20 s seguidos en la misma ruta** (navegar antes reinicia la cuenta; después de armado ya no se oculta). El descarte es definitivo vía `localStorage['pwa-install-dismissed']`. Ojo: `_authenticated` **no** es un guard de sesión —`AppLayoutGuard` renderiza `RootLayout` aunque no haya `user`—, así que el gate se chequea en el provider. Safari en iOS no dispara `beforeinstallprompt`: ahí se muestra `IosInstallHint` con la instrucción de Compartir → Agregar a pantalla de inicio (excluye CriOS/FxiOS/EdgiOS, que también usan WebKit pero se instalan desde Safari).
|
||||||
- **App de alumnos (`modules/student-portal`, `modules/student-access`, web `/i/$token`, `/acceso`, `/alumno/*`)**: acceso sin contraseña y sin datos obligatorios nuevos. Ojo con esto:
|
- **App de alumnos (`modules/student-portal`, `modules/student-access`, web `/i/$token`, `/access`, `/student/*`)**: acceso sin contraseña y sin datos obligatorios nuevos. Ojo con esto:
|
||||||
1. **No pasa por Better Auth**: tablas propias (`student_*`), cookie propia (`gruperly_student`, `__Host-` con HTTPS, 90 días deslizante, se reescribe como mucho cada 1 h) y middleware propio (`studentSession`). Todo `/api/v1/student-portal` está en `isPublicApiRequest` del profe; cada ruta privada declara `studentSession`. Así una sesión de alumno no llega a endpoints del profe y al revés. Nunca montes rutas del profe bajo `/student-portal`.
|
1. **No pasa por Better Auth**: tablas propias (`student_*`), cookie propia (`gruperly_student`, `__Host-` con HTTPS, 90 días deslizante, se reescribe como mucho cada 1 h) y middleware propio (`studentSession`). Todo `/api/v1/student-portal` está en `isPublicApiRequest` del profe; cada ruta privada declara `studentSession`. Así una sesión de alumno no llega a endpoints del profe y al revés. Nunca montes rutas del profe bajo `/student-portal`.
|
||||||
2. Tokens de 32 bytes base64url; **en la base solo el SHA-256**. Invitación 72 h, recuperación 15 min, confirmación de mail 24 h. El **GET del link no consume** (vistas previas de WhatsApp); el POST consume con `updateMany` condicional (`used_at IS NULL AND revoked_at IS NULL AND expires_at > now`) y `count === 1` gana. Todo link inválido responde el mismo `{ status: 'invalid' }` / 410.
|
2. Tokens de 32 bytes base64url; **en la base solo el SHA-256**. Invitación 72 h, recuperación 15 min, confirmación de mail 24 h. El **GET del link no consume** (vistas previas de WhatsApp); el POST consume con `updateMany` condicional (`used_at IS NULL AND revoked_at IS NULL AND expires_at > now`) y `count === 1` gana. Todo link inválido responde el mismo `{ status: 'invalid' }` / 410.
|
||||||
3. **Reinvitar reinicia el acceso**: revoca tokens pendientes y sesiones, **borra las passkeys** y resetea `welcomed_at`.
|
3. **Reinvitar reinicia el acceso**: revoca tokens pendientes y sesiones, **borra las passkeys** y resetea `welcomed_at`.
|
||||||
@@ -81,6 +81,7 @@ bun --filter @gruperly/web icons # regenera los iconos PWA de apps/web
|
|||||||
## Convenciones repo-específicas
|
## Convenciones repo-específicas
|
||||||
|
|
||||||
- **Frontend en español**: copy de UI, comentarios y textos en español.
|
- **Frontend en español**: copy de UI, comentarios y textos en español.
|
||||||
|
- **Paths de rutas en inglés**: aunque el copy esté en español, los segmentos de URL van siempre en inglés, tanto en la web (nombres de archivo en `apps/web/src/routes/`, `createFileRoute`, `to=`/`navigate`) como en la API y en los links que arma el backend (p. ej. `/student/payments`, no `/alumno/pagos`; `/access`, no `/acceso`).
|
||||||
- **Base de datos**: todas las tablas y columnas físicas usan **snake_case**. Los modelos declaran `@@map` (p. ej. `User` → `users`, `WaitlistEntry` → `waitlist_entries`) y todo campo Prisma camelCase que cree una columna debe declarar `@map("nombre_campo")` (p. ej. `createdAt @map("created_at")`). Al agregar un modelo o campo nuevo, incluir siempre el mapping correspondiente sin cambiar la API camelCase de Prisma Client.
|
- **Base de datos**: todas las tablas y columnas físicas usan **snake_case**. Los modelos declaran `@@map` (p. ej. `User` → `users`, `WaitlistEntry` → `waitlist_entries`) y todo campo Prisma camelCase que cree una columna debe declarar `@map("nombre_campo")` (p. ej. `createdAt @map("created_at")`). Al agregar un modelo o campo nuevo, incluir siempre el mapping correspondiente sin cambiar la API camelCase de Prisma Client.
|
||||||
- **API** responde errores en **Problem Details RFC 7807** (`application/problem+json`) y resultados como `{ data, pagination }`; los "use cases" devuelven `Result` y nunca lanzan excepciones de dominio.
|
- **API** responde errores en **Problem Details RFC 7807** (`application/problem+json`) y resultados como `{ data, pagination }`; los "use cases" devuelven `Result` y nunca lanzan excepciones de dominio.
|
||||||
- **Tailwind v4** con tokens en `@theme` dentro de `apps/web/src/index.css` (p. ej. `--color-accent: #1e90ff`). Se usan como clases auto-generadas: `text-accent`, `bg-success-soft`, etc. Radius por defecto `0.75rem` (`rounded-xl`).
|
- **Tailwind v4** con tokens en `@theme` dentro de `apps/web/src/index.css` (p. ej. `--color-accent: #1e90ff`). Se usan como clases auto-generadas: `text-accent`, `bg-success-soft`, etc. Radius por defecto `0.75rem` (`rounded-xl`).
|
||||||
|
|||||||
@@ -75,7 +75,7 @@ export class SetRecoveryEmail {
|
|||||||
await sender.sendStudentEmailConfirmation({
|
await sender.sendStudentEmailConfirmation({
|
||||||
email,
|
email,
|
||||||
name: account.name,
|
name: account.name,
|
||||||
url: `${webUrl()}/acceso/mail/${token}`,
|
url: `${webUrl()}/access/email/${token}`,
|
||||||
});
|
});
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
logger.error({ error, accountId }, 'Student recovery email confirmation could not be sent');
|
logger.error({ error, accountId }, 'Student recovery email confirmation could not be sent');
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ export function ConfirmRecoveryEmailView({ token }: { token: string }) {
|
|||||||
Si algún día perdés el acceso, pedí un link a <strong className="text-primary">{mutation.data.email}</strong>.
|
Si algún día perdés el acceso, pedí un link a <strong className="text-primary">{mutation.data.email}</strong>.
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<Link to="/alumno" className="inline-flex h-12 w-full items-center justify-center rounded-xl bg-accent font-medium text-on-accent hover:bg-accent-strong">
|
<Link to="/student" className="inline-flex h-12 w-full items-center justify-center rounded-xl bg-accent font-medium text-on-accent hover:bg-accent-strong">
|
||||||
Ir a gruperly
|
Ir a gruperly
|
||||||
</Link>
|
</Link>
|
||||||
</>
|
</>
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ export function PasskeyLoginButton() {
|
|||||||
try {
|
try {
|
||||||
await loginWithPasskey()
|
await loginWithPasskey()
|
||||||
await queryClient.invalidateQueries({ queryKey: ['student'] })
|
await queryClient.invalidateQueries({ queryKey: ['student'] })
|
||||||
await navigate({ to: '/alumno', replace: true })
|
await navigate({ to: '/student', replace: true })
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
if (!isPasskeyCancel(error)) setFailed(true)
|
if (!isPasskeyCancel(error)) setFailed(true)
|
||||||
} finally {
|
} finally {
|
||||||
|
|||||||
@@ -34,7 +34,7 @@ export function StudentLinkProvider({ token, children }: { token: string; childr
|
|||||||
mutationFn: () => consumeStudentLink(token),
|
mutationFn: () => consumeStudentLink(token),
|
||||||
onSuccess: async ({ firstLogin }) => {
|
onSuccess: async ({ firstLogin }) => {
|
||||||
queryClient.removeQueries({ queryKey: ['student'] })
|
queryClient.removeQueries({ queryKey: ['student'] })
|
||||||
await navigate({ to: firstLogin ? '/alumno/bienvenida' : '/alumno', replace: true })
|
await navigate({ to: firstLogin ? '/student/welcome' : '/student', replace: true })
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|||||||
@@ -33,7 +33,7 @@ export function FeeCard({ fees }: { fees: StudentFee[] }) {
|
|||||||
</div>
|
</div>
|
||||||
{toReport.length > 0 ? (
|
{toReport.length > 0 ? (
|
||||||
<Link
|
<Link
|
||||||
to="/alumno/informar-pago"
|
to="/student/report-payment"
|
||||||
className="mt-4 flex min-h-12 items-center justify-center gap-2 rounded-xl bg-accent font-semibold text-on-accent hover:bg-accent-strong"
|
className="mt-4 flex min-h-12 items-center justify-center gap-2 rounded-xl bg-accent font-semibold text-on-accent hover:bg-accent-strong"
|
||||||
>
|
>
|
||||||
<Receipt className="size-5" aria-hidden="true" />
|
<Receipt className="size-5" aria-hidden="true" />
|
||||||
|
|||||||
@@ -34,7 +34,7 @@ export function NextClassCard({ item, timeZone }: NextClassCardProps) {
|
|||||||
</p>
|
</p>
|
||||||
) : (
|
) : (
|
||||||
<Link
|
<Link
|
||||||
to="/alumno/avisar"
|
to="/student/notify-absence"
|
||||||
search={{ clase: item.startsAt }}
|
search={{ clase: item.startsAt }}
|
||||||
className="mt-4 flex min-h-12 items-center justify-center gap-2 rounded-xl bg-white font-semibold text-brand-night hover:bg-brand-cloud"
|
className="mt-4 flex min-h-12 items-center justify-center gap-2 rounded-xl bg-white font-semibold text-brand-night hover:bg-brand-cloud"
|
||||||
>
|
>
|
||||||
|
|||||||
@@ -33,10 +33,10 @@ export function NotifyAbsenceView({ preselected }: { preselected?: string }) {
|
|||||||
<FlowDone title={`Listo, le avisamos a ${teacher}`}>
|
<FlowDone title={`Listo, le avisamos a ${teacher}`}>
|
||||||
<p className="text-sm text-secondary">Si cambiás de idea, podés deshacerlo desde Clases mientras la clase no haya empezado.</p>
|
<p className="text-sm text-secondary">Si cambiás de idea, podés deshacerlo desde Clases mientras la clase no haya empezado.</p>
|
||||||
<div className="space-y-2 pt-2">
|
<div className="space-y-2 pt-2">
|
||||||
<Link to="/alumno" className="flex min-h-12 items-center justify-center rounded-xl bg-accent font-semibold text-on-accent hover:bg-accent-strong">
|
<Link to="/student" className="flex min-h-12 items-center justify-center rounded-xl bg-accent font-semibold text-on-accent hover:bg-accent-strong">
|
||||||
Volver al inicio
|
Volver al inicio
|
||||||
</Link>
|
</Link>
|
||||||
<Link to="/alumno/clases" className="flex min-h-12 items-center justify-center rounded-xl border border-border font-medium text-primary hover:bg-primary-soft">
|
<Link to="/student/classes" className="flex min-h-12 items-center justify-center rounded-xl border border-border font-medium text-primary hover:bg-primary-soft">
|
||||||
Ver mis clases
|
Ver mis clases
|
||||||
</Link>
|
</Link>
|
||||||
</div>
|
</div>
|
||||||
@@ -61,7 +61,7 @@ export function NotifyAbsenceView({ preselected }: { preselected?: string }) {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="space-y-6">
|
<div className="space-y-6">
|
||||||
<Link to="/alumno" className="hidden items-center gap-1 text-sm text-secondary hover:text-primary lg:inline-flex">
|
<Link to="/student" className="hidden items-center gap-1 text-sm text-secondary hover:text-primary lg:inline-flex">
|
||||||
<ArrowLeft className="size-4" aria-hidden="true" />
|
<ArrowLeft className="size-4" aria-hidden="true" />
|
||||||
Volver
|
Volver
|
||||||
</Link>
|
</Link>
|
||||||
|
|||||||
@@ -34,7 +34,7 @@ export function ReportPaymentView() {
|
|||||||
<p className="text-sm text-secondary">
|
<p className="text-sm text-secondary">
|
||||||
{teacher} va a revisar el comprobante. Te avisamos acá cuando lo confirme.
|
{teacher} va a revisar el comprobante. Te avisamos acá cuando lo confirme.
|
||||||
</p>
|
</p>
|
||||||
<Link to="/alumno" className="flex min-h-12 items-center justify-center rounded-xl bg-accent font-semibold text-on-accent hover:bg-accent-strong">
|
<Link to="/student" className="flex min-h-12 items-center justify-center rounded-xl bg-accent font-semibold text-on-accent hover:bg-accent-strong">
|
||||||
Volver al inicio
|
Volver al inicio
|
||||||
</Link>
|
</Link>
|
||||||
</FlowDone>
|
</FlowDone>
|
||||||
@@ -63,7 +63,7 @@ export function ReportPaymentView() {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="space-y-6">
|
<div className="space-y-6">
|
||||||
<Link to="/alumno/pagos" className="hidden items-center gap-1 text-sm text-secondary hover:text-primary lg:inline-flex">
|
<Link to="/student/payments" className="hidden items-center gap-1 text-sm text-secondary hover:text-primary lg:inline-flex">
|
||||||
<ArrowLeft className="size-4" aria-hidden="true" />
|
<ArrowLeft className="size-4" aria-hidden="true" />
|
||||||
Volver
|
Volver
|
||||||
</Link>
|
</Link>
|
||||||
|
|||||||
@@ -94,7 +94,7 @@ function useReportPayment(attendeeId: string | null) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* State of the student app: the session ("me"), the selected attendee and its
|
/* State of the student app: the session ("me"), the selected attendee and its
|
||||||
classes and fees. Without a session (401) it sends the student to /acceso. */
|
classes and fees. Without a session (401) it sends the student to /access. */
|
||||||
export function StudentAppProvider({ children }: { children: ReactNode }) {
|
export function StudentAppProvider({ children }: { children: ReactNode }) {
|
||||||
const navigate = useNavigate()
|
const navigate = useNavigate()
|
||||||
const queryClient = useQueryClient()
|
const queryClient = useQueryClient()
|
||||||
@@ -104,7 +104,7 @@ export function StudentAppProvider({ children }: { children: ReactNode }) {
|
|||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (meQuery.error instanceof ApiError && meQuery.error.status === 401) {
|
if (meQuery.error instanceof ApiError && meQuery.error.status === 401) {
|
||||||
void navigate({ to: '/acceso', replace: true })
|
void navigate({ to: '/access', replace: true })
|
||||||
}
|
}
|
||||||
}, [meQuery.error, navigate])
|
}, [meQuery.error, navigate])
|
||||||
|
|
||||||
@@ -145,7 +145,7 @@ export function StudentAppProvider({ children }: { children: ReactNode }) {
|
|||||||
mutationFn: logoutStudent,
|
mutationFn: logoutStudent,
|
||||||
onSettled: async () => {
|
onSettled: async () => {
|
||||||
queryClient.removeQueries({ queryKey: ['student'] })
|
queryClient.removeQueries({ queryKey: ['student'] })
|
||||||
await navigate({ to: '/acceso', replace: true })
|
await navigate({ to: '/access', replace: true })
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ export function StudentClassesView() {
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<Link
|
<Link
|
||||||
to="/alumno/avisar"
|
to="/student/notify-absence"
|
||||||
className="flex min-h-12 items-center justify-center gap-2 rounded-xl bg-accent font-semibold text-on-accent hover:bg-accent-strong"
|
className="flex min-h-12 items-center justify-center gap-2 rounded-xl bg-accent font-semibold text-on-accent hover:bg-accent-strong"
|
||||||
>
|
>
|
||||||
<CalendarX2 className="size-5" aria-hidden="true" />
|
<CalendarX2 className="size-5" aria-hidden="true" />
|
||||||
|
|||||||
@@ -34,7 +34,7 @@ export function StudentLayout() {
|
|||||||
<div className="flex justify-center py-20" role="status" aria-label="Cargando">
|
<div className="flex justify-center py-20" role="status" aria-label="Cargando">
|
||||||
<Loader2 className="size-8 animate-spin text-accent" aria-hidden="true" />
|
<Loader2 className="size-8 animate-spin text-accent" aria-hidden="true" />
|
||||||
</div>
|
</div>
|
||||||
) : !student && !location.pathname.startsWith('/alumno/perfil') ? (
|
) : !student && !location.pathname.startsWith('/student/profile') ? (
|
||||||
<div className="mt-10 space-y-3 rounded-2xl border border-border bg-surface p-6 text-center">
|
<div className="mt-10 space-y-3 rounded-2xl border border-border bg-surface p-6 text-center">
|
||||||
<UserX className="mx-auto size-8 text-foreground" aria-hidden="true" />
|
<UserX className="mx-auto size-8 text-foreground" aria-hidden="true" />
|
||||||
<h1 className="text-lg font-bold text-primary">No tenés grupos activos</h1>
|
<h1 className="text-lg font-bold text-primary">No tenés grupos activos</h1>
|
||||||
|
|||||||
@@ -69,7 +69,7 @@ export function StudentPaymentsView() {
|
|||||||
)}
|
)}
|
||||||
{canReport ? (
|
{canReport ? (
|
||||||
<Link
|
<Link
|
||||||
to="/alumno/informar-pago"
|
to="/student/report-payment"
|
||||||
className="flex min-h-12 items-center justify-center gap-2 rounded-xl bg-accent font-semibold text-on-accent hover:bg-accent-strong"
|
className="flex min-h-12 items-center justify-center gap-2 rounded-xl bg-accent font-semibold text-on-accent hover:bg-accent-strong"
|
||||||
>
|
>
|
||||||
<Receipt className="size-5" aria-hidden="true" />
|
<Receipt className="size-5" aria-hidden="true" />
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ export function WelcomeView() {
|
|||||||
const [email, setEmail] = useState('')
|
const [email, setEmail] = useState('')
|
||||||
|
|
||||||
const goHome = () =>
|
const goHome = () =>
|
||||||
finishWelcome.mutate(undefined, { onSettled: () => void navigate({ to: '/alumno', replace: true }) })
|
finishWelcome.mutate(undefined, { onSettled: () => void navigate({ to: '/student', replace: true }) })
|
||||||
|
|
||||||
const handleContinue = () => {
|
const handleContinue = () => {
|
||||||
const value = email.trim()
|
const value = email.trim()
|
||||||
|
|||||||
@@ -3,17 +3,17 @@ import type { NavItem } from '../../components/layout/nav-items'
|
|||||||
|
|
||||||
// Bottom nav of the student app: the single source for StudentBottomNav.
|
// Bottom nav of the student app: the single source for StudentBottomNav.
|
||||||
export const STUDENT_NAV_ITEMS: NavItem[] = [
|
export const STUDENT_NAV_ITEMS: NavItem[] = [
|
||||||
{ label: 'Inicio', to: '/alumno', icon: Home },
|
{ label: 'Inicio', to: '/student', icon: Home },
|
||||||
{ label: 'Clases', to: '/alumno/clases', icon: CalendarDays },
|
{ label: 'Clases', to: '/student/classes', icon: CalendarDays },
|
||||||
{ label: 'Pagos', to: '/alumno/pagos', icon: Wallet },
|
{ label: 'Pagos', to: '/student/payments', icon: Wallet },
|
||||||
{ label: 'Perfil', to: '/alumno/perfil', icon: User },
|
{ label: 'Perfil', to: '/student/profile', icon: User },
|
||||||
]
|
]
|
||||||
|
|
||||||
/* Flow screens with their own fixed bottom button: no nav there. */
|
/* Flow screens with their own fixed bottom button: no nav there. */
|
||||||
export const STUDENT_FLOW_PATHS = ['/alumno/bienvenida', '/alumno/avisar', '/alumno/informar-pago']
|
export const STUDENT_FLOW_PATHS = ['/student/welcome', '/student/notify-absence', '/student/report-payment']
|
||||||
|
|
||||||
export function isStudentNavItemActive(pathname: string, to: string): boolean {
|
export function isStudentNavItemActive(pathname: string, to: string): boolean {
|
||||||
const path = pathname.replace(/\/$/, '') || '/'
|
const path = pathname.replace(/\/$/, '') || '/'
|
||||||
if (to === '/alumno') return path === '/alumno'
|
if (to === '/student') return path === '/student'
|
||||||
return path === to || path.startsWith(`${to}/`)
|
return path === to || path.startsWith(`${to}/`)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ import { Route as AuthenticatedPaymentsRouteImport } from './routes/_authenticat
|
|||||||
import { Route as AuthenticatedProfileRouteImport } from './routes/_authenticated/profile'
|
import { Route as AuthenticatedProfileRouteImport } from './routes/_authenticated/profile'
|
||||||
import { Route as AuthenticatedSecurityRouteImport } from './routes/_authenticated/security'
|
import { Route as AuthenticatedSecurityRouteImport } from './routes/_authenticated/security'
|
||||||
import { Route as AuthenticatedSettingsRouteImport } from './routes/_authenticated/settings'
|
import { Route as AuthenticatedSettingsRouteImport } from './routes/_authenticated/settings'
|
||||||
import { Route as AccesoIndexRouteImport } from './routes/acceso.index'
|
import { Route as AccessIndexRouteImport } from './routes/access.index'
|
||||||
import { Route as AdminIndexRouteImport } from './routes/admin/index'
|
import { Route as AdminIndexRouteImport } from './routes/admin/index'
|
||||||
import { Route as ITokenRouteImport } from './routes/i.$token'
|
import { Route as ITokenRouteImport } from './routes/i.$token'
|
||||||
import { Route as JoinTokenRouteImport } from './routes/join.$token'
|
import { Route as JoinTokenRouteImport } from './routes/join.$token'
|
||||||
@@ -32,14 +32,14 @@ import { Route as ReportAbsenceTokenRouteImport } from './routes/report-absence.
|
|||||||
import { Route as AuthenticatedGroupsIndexRouteImport } from './routes/_authenticated/groups/index'
|
import { Route as AuthenticatedGroupsIndexRouteImport } from './routes/_authenticated/groups/index'
|
||||||
import { Route as AuthenticatedGroupsAttentionRouteImport } from './routes/_authenticated/groups/attention'
|
import { Route as AuthenticatedGroupsAttentionRouteImport } from './routes/_authenticated/groups/attention'
|
||||||
import { Route as AuthenticatedGroupsNewRouteImport } from './routes/_authenticated/groups/new'
|
import { Route as AuthenticatedGroupsNewRouteImport } from './routes/_authenticated/groups/new'
|
||||||
import { Route as StudentAlumnoIndexRouteImport } from './routes/_student/alumno.index'
|
import { Route as StudentStudentIndexRouteImport } from './routes/_student/student.index'
|
||||||
import { Route as StudentAlumnoAvisarRouteImport } from './routes/_student/alumno.avisar'
|
import { Route as StudentStudentClassesRouteImport } from './routes/_student/student.classes'
|
||||||
import { Route as StudentAlumnoBienvenidaRouteImport } from './routes/_student/alumno.bienvenida'
|
import { Route as StudentStudentNotifyAbsenceRouteImport } from './routes/_student/student.notify-absence'
|
||||||
import { Route as StudentAlumnoClasesRouteImport } from './routes/_student/alumno.clases'
|
import { Route as StudentStudentPaymentsRouteImport } from './routes/_student/student.payments'
|
||||||
import { Route as StudentAlumnoInformarPagoRouteImport } from './routes/_student/alumno.informar-pago'
|
import { Route as StudentStudentProfileRouteImport } from './routes/_student/student.profile'
|
||||||
import { Route as StudentAlumnoPagosRouteImport } from './routes/_student/alumno.pagos'
|
import { Route as StudentStudentReportPaymentRouteImport } from './routes/_student/student.report-payment'
|
||||||
import { Route as StudentAlumnoPerfilRouteImport } from './routes/_student/alumno.perfil'
|
import { Route as StudentStudentWelcomeRouteImport } from './routes/_student/student.welcome'
|
||||||
import { Route as AccesoMailTokenRouteImport } from './routes/acceso.mail.$token'
|
import { Route as AccessEmailTokenRouteImport } from './routes/access.email.$token'
|
||||||
import { Route as AdminAccountsAccountIdRouteImport } from './routes/admin/accounts.$accountId'
|
import { Route as AdminAccountsAccountIdRouteImport } from './routes/admin/accounts.$accountId'
|
||||||
import { Route as AuthenticatedClassSessionIdAttendanceRouteImport } from './routes/_authenticated/class/$sessionId/attendance'
|
import { Route as AuthenticatedClassSessionIdAttendanceRouteImport } from './routes/_authenticated/class/$sessionId/attendance'
|
||||||
import { Route as AuthenticatedGroupsGroupIdIndexRouteImport } from './routes/_authenticated/groups/$groupId/index'
|
import { Route as AuthenticatedGroupsGroupIdIndexRouteImport } from './routes/_authenticated/groups/$groupId/index'
|
||||||
@@ -120,9 +120,9 @@ const AuthenticatedSettingsRoute = AuthenticatedSettingsRouteImport.update({
|
|||||||
path: '/settings',
|
path: '/settings',
|
||||||
getParentRoute: () => AuthenticatedRoute,
|
getParentRoute: () => AuthenticatedRoute,
|
||||||
} as any)
|
} as any)
|
||||||
const AccesoIndexRoute = AccesoIndexRouteImport.update({
|
const AccessIndexRoute = AccessIndexRouteImport.update({
|
||||||
id: '/acceso/',
|
id: '/access/',
|
||||||
path: '/acceso/',
|
path: '/access/',
|
||||||
getParentRoute: () => rootRouteImport,
|
getParentRoute: () => rootRouteImport,
|
||||||
} as any)
|
} as any)
|
||||||
const AdminIndexRoute = AdminIndexRouteImport.update({
|
const AdminIndexRoute = AdminIndexRouteImport.update({
|
||||||
@@ -162,45 +162,46 @@ const AuthenticatedGroupsNewRoute = AuthenticatedGroupsNewRouteImport.update({
|
|||||||
path: '/groups/new',
|
path: '/groups/new',
|
||||||
getParentRoute: () => AuthenticatedRoute,
|
getParentRoute: () => AuthenticatedRoute,
|
||||||
} as any)
|
} as any)
|
||||||
const StudentAlumnoIndexRoute = StudentAlumnoIndexRouteImport.update({
|
const StudentStudentIndexRoute = StudentStudentIndexRouteImport.update({
|
||||||
id: '/alumno/',
|
id: '/student/',
|
||||||
path: '/alumno/',
|
path: '/student/',
|
||||||
getParentRoute: () => StudentRoute,
|
getParentRoute: () => StudentRoute,
|
||||||
} as any)
|
} as any)
|
||||||
const StudentAlumnoAvisarRoute = StudentAlumnoAvisarRouteImport.update({
|
const StudentStudentClassesRoute = StudentStudentClassesRouteImport.update({
|
||||||
id: '/alumno/avisar',
|
id: '/student/classes',
|
||||||
path: '/alumno/avisar',
|
path: '/student/classes',
|
||||||
getParentRoute: () => StudentRoute,
|
getParentRoute: () => StudentRoute,
|
||||||
} as any)
|
} as any)
|
||||||
const StudentAlumnoBienvenidaRoute = StudentAlumnoBienvenidaRouteImport.update({
|
const StudentStudentNotifyAbsenceRoute =
|
||||||
id: '/alumno/bienvenida',
|
StudentStudentNotifyAbsenceRouteImport.update({
|
||||||
path: '/alumno/bienvenida',
|
id: '/student/notify-absence',
|
||||||
getParentRoute: () => StudentRoute,
|
path: '/student/notify-absence',
|
||||||
} as any)
|
|
||||||
const StudentAlumnoClasesRoute = StudentAlumnoClasesRouteImport.update({
|
|
||||||
id: '/alumno/clases',
|
|
||||||
path: '/alumno/clases',
|
|
||||||
getParentRoute: () => StudentRoute,
|
|
||||||
} as any)
|
|
||||||
const StudentAlumnoInformarPagoRoute =
|
|
||||||
StudentAlumnoInformarPagoRouteImport.update({
|
|
||||||
id: '/alumno/informar-pago',
|
|
||||||
path: '/alumno/informar-pago',
|
|
||||||
getParentRoute: () => StudentRoute,
|
getParentRoute: () => StudentRoute,
|
||||||
} as any)
|
} as any)
|
||||||
const StudentAlumnoPagosRoute = StudentAlumnoPagosRouteImport.update({
|
const StudentStudentPaymentsRoute = StudentStudentPaymentsRouteImport.update({
|
||||||
id: '/alumno/pagos',
|
id: '/student/payments',
|
||||||
path: '/alumno/pagos',
|
path: '/student/payments',
|
||||||
getParentRoute: () => StudentRoute,
|
getParentRoute: () => StudentRoute,
|
||||||
} as any)
|
} as any)
|
||||||
const StudentAlumnoPerfilRoute = StudentAlumnoPerfilRouteImport.update({
|
const StudentStudentProfileRoute = StudentStudentProfileRouteImport.update({
|
||||||
id: '/alumno/perfil',
|
id: '/student/profile',
|
||||||
path: '/alumno/perfil',
|
path: '/student/profile',
|
||||||
getParentRoute: () => StudentRoute,
|
getParentRoute: () => StudentRoute,
|
||||||
} as any)
|
} as any)
|
||||||
const AccesoMailTokenRoute = AccesoMailTokenRouteImport.update({
|
const StudentStudentReportPaymentRoute =
|
||||||
id: '/acceso/mail/$token',
|
StudentStudentReportPaymentRouteImport.update({
|
||||||
path: '/acceso/mail/$token',
|
id: '/student/report-payment',
|
||||||
|
path: '/student/report-payment',
|
||||||
|
getParentRoute: () => StudentRoute,
|
||||||
|
} as any)
|
||||||
|
const StudentStudentWelcomeRoute = StudentStudentWelcomeRouteImport.update({
|
||||||
|
id: '/student/welcome',
|
||||||
|
path: '/student/welcome',
|
||||||
|
getParentRoute: () => StudentRoute,
|
||||||
|
} as any)
|
||||||
|
const AccessEmailTokenRoute = AccessEmailTokenRouteImport.update({
|
||||||
|
id: '/access/email/$token',
|
||||||
|
path: '/access/email/$token',
|
||||||
getParentRoute: () => rootRouteImport,
|
getParentRoute: () => rootRouteImport,
|
||||||
} as any)
|
} as any)
|
||||||
const AdminAccountsAccountIdRoute = AdminAccountsAccountIdRouteImport.update({
|
const AdminAccountsAccountIdRoute = AdminAccountsAccountIdRouteImport.update({
|
||||||
@@ -256,20 +257,20 @@ export interface FileRoutesByFullPath {
|
|||||||
'/i/$token': typeof ITokenRoute
|
'/i/$token': typeof ITokenRoute
|
||||||
'/join/$token': typeof JoinTokenRoute
|
'/join/$token': typeof JoinTokenRoute
|
||||||
'/report-absence/$token': typeof ReportAbsenceTokenRoute
|
'/report-absence/$token': typeof ReportAbsenceTokenRoute
|
||||||
'/acceso/': typeof AccesoIndexRoute
|
'/access/': typeof AccessIndexRoute
|
||||||
'/admin/': typeof AdminIndexRoute
|
'/admin/': typeof AdminIndexRoute
|
||||||
'/groups/attention': typeof AuthenticatedGroupsAttentionRoute
|
'/groups/attention': typeof AuthenticatedGroupsAttentionRoute
|
||||||
'/groups/new': typeof AuthenticatedGroupsNewRoute
|
'/groups/new': typeof AuthenticatedGroupsNewRoute
|
||||||
'/alumno/avisar': typeof StudentAlumnoAvisarRoute
|
'/student/classes': typeof StudentStudentClassesRoute
|
||||||
'/alumno/bienvenida': typeof StudentAlumnoBienvenidaRoute
|
'/student/notify-absence': typeof StudentStudentNotifyAbsenceRoute
|
||||||
'/alumno/clases': typeof StudentAlumnoClasesRoute
|
'/student/payments': typeof StudentStudentPaymentsRoute
|
||||||
'/alumno/informar-pago': typeof StudentAlumnoInformarPagoRoute
|
'/student/profile': typeof StudentStudentProfileRoute
|
||||||
'/alumno/pagos': typeof StudentAlumnoPagosRoute
|
'/student/report-payment': typeof StudentStudentReportPaymentRoute
|
||||||
'/alumno/perfil': typeof StudentAlumnoPerfilRoute
|
'/student/welcome': typeof StudentStudentWelcomeRoute
|
||||||
'/acceso/mail/$token': typeof AccesoMailTokenRoute
|
'/access/email/$token': typeof AccessEmailTokenRoute
|
||||||
'/admin/accounts/$accountId': typeof AdminAccountsAccountIdRoute
|
'/admin/accounts/$accountId': typeof AdminAccountsAccountIdRoute
|
||||||
'/groups/': typeof AuthenticatedGroupsIndexRoute
|
'/groups/': typeof AuthenticatedGroupsIndexRoute
|
||||||
'/alumno/': typeof StudentAlumnoIndexRoute
|
'/student/': typeof StudentStudentIndexRoute
|
||||||
'/class/$sessionId/attendance': typeof AuthenticatedClassSessionIdAttendanceRoute
|
'/class/$sessionId/attendance': typeof AuthenticatedClassSessionIdAttendanceRoute
|
||||||
'/groups/$groupId/analytics': typeof AuthenticatedGroupsGroupIdAnalyticsRoute
|
'/groups/$groupId/analytics': typeof AuthenticatedGroupsGroupIdAnalyticsRoute
|
||||||
'/groups/$groupId/': typeof AuthenticatedGroupsGroupIdIndexRoute
|
'/groups/$groupId/': typeof AuthenticatedGroupsGroupIdIndexRoute
|
||||||
@@ -292,20 +293,20 @@ export interface FileRoutesByTo {
|
|||||||
'/i/$token': typeof ITokenRoute
|
'/i/$token': typeof ITokenRoute
|
||||||
'/join/$token': typeof JoinTokenRoute
|
'/join/$token': typeof JoinTokenRoute
|
||||||
'/report-absence/$token': typeof ReportAbsenceTokenRoute
|
'/report-absence/$token': typeof ReportAbsenceTokenRoute
|
||||||
'/acceso': typeof AccesoIndexRoute
|
'/access': typeof AccessIndexRoute
|
||||||
'/admin': typeof AdminIndexRoute
|
'/admin': typeof AdminIndexRoute
|
||||||
'/groups/attention': typeof AuthenticatedGroupsAttentionRoute
|
'/groups/attention': typeof AuthenticatedGroupsAttentionRoute
|
||||||
'/groups/new': typeof AuthenticatedGroupsNewRoute
|
'/groups/new': typeof AuthenticatedGroupsNewRoute
|
||||||
'/alumno/avisar': typeof StudentAlumnoAvisarRoute
|
'/student/classes': typeof StudentStudentClassesRoute
|
||||||
'/alumno/bienvenida': typeof StudentAlumnoBienvenidaRoute
|
'/student/notify-absence': typeof StudentStudentNotifyAbsenceRoute
|
||||||
'/alumno/clases': typeof StudentAlumnoClasesRoute
|
'/student/payments': typeof StudentStudentPaymentsRoute
|
||||||
'/alumno/informar-pago': typeof StudentAlumnoInformarPagoRoute
|
'/student/profile': typeof StudentStudentProfileRoute
|
||||||
'/alumno/pagos': typeof StudentAlumnoPagosRoute
|
'/student/report-payment': typeof StudentStudentReportPaymentRoute
|
||||||
'/alumno/perfil': typeof StudentAlumnoPerfilRoute
|
'/student/welcome': typeof StudentStudentWelcomeRoute
|
||||||
'/acceso/mail/$token': typeof AccesoMailTokenRoute
|
'/access/email/$token': typeof AccessEmailTokenRoute
|
||||||
'/admin/accounts/$accountId': typeof AdminAccountsAccountIdRoute
|
'/admin/accounts/$accountId': typeof AdminAccountsAccountIdRoute
|
||||||
'/groups': typeof AuthenticatedGroupsIndexRoute
|
'/groups': typeof AuthenticatedGroupsIndexRoute
|
||||||
'/alumno': typeof StudentAlumnoIndexRoute
|
'/student': typeof StudentStudentIndexRoute
|
||||||
'/class/$sessionId/attendance': typeof AuthenticatedClassSessionIdAttendanceRoute
|
'/class/$sessionId/attendance': typeof AuthenticatedClassSessionIdAttendanceRoute
|
||||||
'/groups/$groupId/analytics': typeof AuthenticatedGroupsGroupIdAnalyticsRoute
|
'/groups/$groupId/analytics': typeof AuthenticatedGroupsGroupIdAnalyticsRoute
|
||||||
'/groups/$groupId': typeof AuthenticatedGroupsGroupIdIndexRoute
|
'/groups/$groupId': typeof AuthenticatedGroupsGroupIdIndexRoute
|
||||||
@@ -332,20 +333,20 @@ export interface FileRoutesById {
|
|||||||
'/join/$token': typeof JoinTokenRoute
|
'/join/$token': typeof JoinTokenRoute
|
||||||
'/report-absence/$token': typeof ReportAbsenceTokenRoute
|
'/report-absence/$token': typeof ReportAbsenceTokenRoute
|
||||||
'/_authenticated/': typeof AuthenticatedIndexRoute
|
'/_authenticated/': typeof AuthenticatedIndexRoute
|
||||||
'/acceso/': typeof AccesoIndexRoute
|
'/access/': typeof AccessIndexRoute
|
||||||
'/admin/': typeof AdminIndexRoute
|
'/admin/': typeof AdminIndexRoute
|
||||||
'/_authenticated/groups/attention': typeof AuthenticatedGroupsAttentionRoute
|
'/_authenticated/groups/attention': typeof AuthenticatedGroupsAttentionRoute
|
||||||
'/_authenticated/groups/new': typeof AuthenticatedGroupsNewRoute
|
'/_authenticated/groups/new': typeof AuthenticatedGroupsNewRoute
|
||||||
'/_student/alumno/avisar': typeof StudentAlumnoAvisarRoute
|
'/_student/student/classes': typeof StudentStudentClassesRoute
|
||||||
'/_student/alumno/bienvenida': typeof StudentAlumnoBienvenidaRoute
|
'/_student/student/notify-absence': typeof StudentStudentNotifyAbsenceRoute
|
||||||
'/_student/alumno/clases': typeof StudentAlumnoClasesRoute
|
'/_student/student/payments': typeof StudentStudentPaymentsRoute
|
||||||
'/_student/alumno/informar-pago': typeof StudentAlumnoInformarPagoRoute
|
'/_student/student/profile': typeof StudentStudentProfileRoute
|
||||||
'/_student/alumno/pagos': typeof StudentAlumnoPagosRoute
|
'/_student/student/report-payment': typeof StudentStudentReportPaymentRoute
|
||||||
'/_student/alumno/perfil': typeof StudentAlumnoPerfilRoute
|
'/_student/student/welcome': typeof StudentStudentWelcomeRoute
|
||||||
'/acceso/mail/$token': typeof AccesoMailTokenRoute
|
'/access/email/$token': typeof AccessEmailTokenRoute
|
||||||
'/admin/accounts/$accountId': typeof AdminAccountsAccountIdRoute
|
'/admin/accounts/$accountId': typeof AdminAccountsAccountIdRoute
|
||||||
'/_authenticated/groups/': typeof AuthenticatedGroupsIndexRoute
|
'/_authenticated/groups/': typeof AuthenticatedGroupsIndexRoute
|
||||||
'/_student/alumno/': typeof StudentAlumnoIndexRoute
|
'/_student/student/': typeof StudentStudentIndexRoute
|
||||||
'/_authenticated/class/$sessionId/attendance': typeof AuthenticatedClassSessionIdAttendanceRoute
|
'/_authenticated/class/$sessionId/attendance': typeof AuthenticatedClassSessionIdAttendanceRoute
|
||||||
'/_authenticated/groups/$groupId/analytics': typeof AuthenticatedGroupsGroupIdAnalyticsRoute
|
'/_authenticated/groups/$groupId/analytics': typeof AuthenticatedGroupsGroupIdAnalyticsRoute
|
||||||
'/_authenticated/groups/$groupId/': typeof AuthenticatedGroupsGroupIdIndexRoute
|
'/_authenticated/groups/$groupId/': typeof AuthenticatedGroupsGroupIdIndexRoute
|
||||||
@@ -371,20 +372,20 @@ export interface FileRouteTypes {
|
|||||||
| '/i/$token'
|
| '/i/$token'
|
||||||
| '/join/$token'
|
| '/join/$token'
|
||||||
| '/report-absence/$token'
|
| '/report-absence/$token'
|
||||||
| '/acceso/'
|
| '/access/'
|
||||||
| '/admin/'
|
| '/admin/'
|
||||||
| '/groups/attention'
|
| '/groups/attention'
|
||||||
| '/groups/new'
|
| '/groups/new'
|
||||||
| '/alumno/avisar'
|
| '/student/classes'
|
||||||
| '/alumno/bienvenida'
|
| '/student/notify-absence'
|
||||||
| '/alumno/clases'
|
| '/student/payments'
|
||||||
| '/alumno/informar-pago'
|
| '/student/profile'
|
||||||
| '/alumno/pagos'
|
| '/student/report-payment'
|
||||||
| '/alumno/perfil'
|
| '/student/welcome'
|
||||||
| '/acceso/mail/$token'
|
| '/access/email/$token'
|
||||||
| '/admin/accounts/$accountId'
|
| '/admin/accounts/$accountId'
|
||||||
| '/groups/'
|
| '/groups/'
|
||||||
| '/alumno/'
|
| '/student/'
|
||||||
| '/class/$sessionId/attendance'
|
| '/class/$sessionId/attendance'
|
||||||
| '/groups/$groupId/analytics'
|
| '/groups/$groupId/analytics'
|
||||||
| '/groups/$groupId/'
|
| '/groups/$groupId/'
|
||||||
@@ -407,20 +408,20 @@ export interface FileRouteTypes {
|
|||||||
| '/i/$token'
|
| '/i/$token'
|
||||||
| '/join/$token'
|
| '/join/$token'
|
||||||
| '/report-absence/$token'
|
| '/report-absence/$token'
|
||||||
| '/acceso'
|
| '/access'
|
||||||
| '/admin'
|
| '/admin'
|
||||||
| '/groups/attention'
|
| '/groups/attention'
|
||||||
| '/groups/new'
|
| '/groups/new'
|
||||||
| '/alumno/avisar'
|
| '/student/classes'
|
||||||
| '/alumno/bienvenida'
|
| '/student/notify-absence'
|
||||||
| '/alumno/clases'
|
| '/student/payments'
|
||||||
| '/alumno/informar-pago'
|
| '/student/profile'
|
||||||
| '/alumno/pagos'
|
| '/student/report-payment'
|
||||||
| '/alumno/perfil'
|
| '/student/welcome'
|
||||||
| '/acceso/mail/$token'
|
| '/access/email/$token'
|
||||||
| '/admin/accounts/$accountId'
|
| '/admin/accounts/$accountId'
|
||||||
| '/groups'
|
| '/groups'
|
||||||
| '/alumno'
|
| '/student'
|
||||||
| '/class/$sessionId/attendance'
|
| '/class/$sessionId/attendance'
|
||||||
| '/groups/$groupId/analytics'
|
| '/groups/$groupId/analytics'
|
||||||
| '/groups/$groupId'
|
| '/groups/$groupId'
|
||||||
@@ -446,20 +447,20 @@ export interface FileRouteTypes {
|
|||||||
| '/join/$token'
|
| '/join/$token'
|
||||||
| '/report-absence/$token'
|
| '/report-absence/$token'
|
||||||
| '/_authenticated/'
|
| '/_authenticated/'
|
||||||
| '/acceso/'
|
| '/access/'
|
||||||
| '/admin/'
|
| '/admin/'
|
||||||
| '/_authenticated/groups/attention'
|
| '/_authenticated/groups/attention'
|
||||||
| '/_authenticated/groups/new'
|
| '/_authenticated/groups/new'
|
||||||
| '/_student/alumno/avisar'
|
| '/_student/student/classes'
|
||||||
| '/_student/alumno/bienvenida'
|
| '/_student/student/notify-absence'
|
||||||
| '/_student/alumno/clases'
|
| '/_student/student/payments'
|
||||||
| '/_student/alumno/informar-pago'
|
| '/_student/student/profile'
|
||||||
| '/_student/alumno/pagos'
|
| '/_student/student/report-payment'
|
||||||
| '/_student/alumno/perfil'
|
| '/_student/student/welcome'
|
||||||
| '/acceso/mail/$token'
|
| '/access/email/$token'
|
||||||
| '/admin/accounts/$accountId'
|
| '/admin/accounts/$accountId'
|
||||||
| '/_authenticated/groups/'
|
| '/_authenticated/groups/'
|
||||||
| '/_student/alumno/'
|
| '/_student/student/'
|
||||||
| '/_authenticated/class/$sessionId/attendance'
|
| '/_authenticated/class/$sessionId/attendance'
|
||||||
| '/_authenticated/groups/$groupId/analytics'
|
| '/_authenticated/groups/$groupId/analytics'
|
||||||
| '/_authenticated/groups/$groupId/'
|
| '/_authenticated/groups/$groupId/'
|
||||||
@@ -480,8 +481,8 @@ export interface RootRouteChildren {
|
|||||||
ITokenRoute: typeof ITokenRoute
|
ITokenRoute: typeof ITokenRoute
|
||||||
JoinTokenRoute: typeof JoinTokenRoute
|
JoinTokenRoute: typeof JoinTokenRoute
|
||||||
ReportAbsenceTokenRoute: typeof ReportAbsenceTokenRoute
|
ReportAbsenceTokenRoute: typeof ReportAbsenceTokenRoute
|
||||||
AccesoIndexRoute: typeof AccesoIndexRoute
|
AccessIndexRoute: typeof AccessIndexRoute
|
||||||
AccesoMailTokenRoute: typeof AccesoMailTokenRoute
|
AccessEmailTokenRoute: typeof AccessEmailTokenRoute
|
||||||
}
|
}
|
||||||
|
|
||||||
declare module '@tanstack/react-router' {
|
declare module '@tanstack/react-router' {
|
||||||
@@ -591,11 +592,11 @@ declare module '@tanstack/react-router' {
|
|||||||
preLoaderRoute: typeof AuthenticatedSettingsRouteImport
|
preLoaderRoute: typeof AuthenticatedSettingsRouteImport
|
||||||
parentRoute: typeof AuthenticatedRoute
|
parentRoute: typeof AuthenticatedRoute
|
||||||
}
|
}
|
||||||
'/acceso/': {
|
'/access/': {
|
||||||
id: '/acceso/'
|
id: '/access/'
|
||||||
path: '/acceso'
|
path: '/access'
|
||||||
fullPath: '/acceso/'
|
fullPath: '/access/'
|
||||||
preLoaderRoute: typeof AccesoIndexRouteImport
|
preLoaderRoute: typeof AccessIndexRouteImport
|
||||||
parentRoute: typeof rootRouteImport
|
parentRoute: typeof rootRouteImport
|
||||||
}
|
}
|
||||||
'/admin/': {
|
'/admin/': {
|
||||||
@@ -647,60 +648,60 @@ declare module '@tanstack/react-router' {
|
|||||||
preLoaderRoute: typeof AuthenticatedGroupsNewRouteImport
|
preLoaderRoute: typeof AuthenticatedGroupsNewRouteImport
|
||||||
parentRoute: typeof AuthenticatedRoute
|
parentRoute: typeof AuthenticatedRoute
|
||||||
}
|
}
|
||||||
'/_student/alumno/': {
|
'/_student/student/': {
|
||||||
id: '/_student/alumno/'
|
id: '/_student/student/'
|
||||||
path: '/alumno'
|
path: '/student'
|
||||||
fullPath: '/alumno/'
|
fullPath: '/student/'
|
||||||
preLoaderRoute: typeof StudentAlumnoIndexRouteImport
|
preLoaderRoute: typeof StudentStudentIndexRouteImport
|
||||||
parentRoute: typeof StudentRoute
|
parentRoute: typeof StudentRoute
|
||||||
}
|
}
|
||||||
'/_student/alumno/avisar': {
|
'/_student/student/classes': {
|
||||||
id: '/_student/alumno/avisar'
|
id: '/_student/student/classes'
|
||||||
path: '/alumno/avisar'
|
path: '/student/classes'
|
||||||
fullPath: '/alumno/avisar'
|
fullPath: '/student/classes'
|
||||||
preLoaderRoute: typeof StudentAlumnoAvisarRouteImport
|
preLoaderRoute: typeof StudentStudentClassesRouteImport
|
||||||
parentRoute: typeof StudentRoute
|
parentRoute: typeof StudentRoute
|
||||||
}
|
}
|
||||||
'/_student/alumno/bienvenida': {
|
'/_student/student/notify-absence': {
|
||||||
id: '/_student/alumno/bienvenida'
|
id: '/_student/student/notify-absence'
|
||||||
path: '/alumno/bienvenida'
|
path: '/student/notify-absence'
|
||||||
fullPath: '/alumno/bienvenida'
|
fullPath: '/student/notify-absence'
|
||||||
preLoaderRoute: typeof StudentAlumnoBienvenidaRouteImport
|
preLoaderRoute: typeof StudentStudentNotifyAbsenceRouteImport
|
||||||
parentRoute: typeof StudentRoute
|
parentRoute: typeof StudentRoute
|
||||||
}
|
}
|
||||||
'/_student/alumno/clases': {
|
'/_student/student/payments': {
|
||||||
id: '/_student/alumno/clases'
|
id: '/_student/student/payments'
|
||||||
path: '/alumno/clases'
|
path: '/student/payments'
|
||||||
fullPath: '/alumno/clases'
|
fullPath: '/student/payments'
|
||||||
preLoaderRoute: typeof StudentAlumnoClasesRouteImport
|
preLoaderRoute: typeof StudentStudentPaymentsRouteImport
|
||||||
parentRoute: typeof StudentRoute
|
parentRoute: typeof StudentRoute
|
||||||
}
|
}
|
||||||
'/_student/alumno/informar-pago': {
|
'/_student/student/profile': {
|
||||||
id: '/_student/alumno/informar-pago'
|
id: '/_student/student/profile'
|
||||||
path: '/alumno/informar-pago'
|
path: '/student/profile'
|
||||||
fullPath: '/alumno/informar-pago'
|
fullPath: '/student/profile'
|
||||||
preLoaderRoute: typeof StudentAlumnoInformarPagoRouteImport
|
preLoaderRoute: typeof StudentStudentProfileRouteImport
|
||||||
parentRoute: typeof StudentRoute
|
parentRoute: typeof StudentRoute
|
||||||
}
|
}
|
||||||
'/_student/alumno/pagos': {
|
'/_student/student/report-payment': {
|
||||||
id: '/_student/alumno/pagos'
|
id: '/_student/student/report-payment'
|
||||||
path: '/alumno/pagos'
|
path: '/student/report-payment'
|
||||||
fullPath: '/alumno/pagos'
|
fullPath: '/student/report-payment'
|
||||||
preLoaderRoute: typeof StudentAlumnoPagosRouteImport
|
preLoaderRoute: typeof StudentStudentReportPaymentRouteImport
|
||||||
parentRoute: typeof StudentRoute
|
parentRoute: typeof StudentRoute
|
||||||
}
|
}
|
||||||
'/_student/alumno/perfil': {
|
'/_student/student/welcome': {
|
||||||
id: '/_student/alumno/perfil'
|
id: '/_student/student/welcome'
|
||||||
path: '/alumno/perfil'
|
path: '/student/welcome'
|
||||||
fullPath: '/alumno/perfil'
|
fullPath: '/student/welcome'
|
||||||
preLoaderRoute: typeof StudentAlumnoPerfilRouteImport
|
preLoaderRoute: typeof StudentStudentWelcomeRouteImport
|
||||||
parentRoute: typeof StudentRoute
|
parentRoute: typeof StudentRoute
|
||||||
}
|
}
|
||||||
'/acceso/mail/$token': {
|
'/access/email/$token': {
|
||||||
id: '/acceso/mail/$token'
|
id: '/access/email/$token'
|
||||||
path: '/acceso/mail/$token'
|
path: '/access/email/$token'
|
||||||
fullPath: '/acceso/mail/$token'
|
fullPath: '/access/email/$token'
|
||||||
preLoaderRoute: typeof AccesoMailTokenRouteImport
|
preLoaderRoute: typeof AccessEmailTokenRouteImport
|
||||||
parentRoute: typeof rootRouteImport
|
parentRoute: typeof rootRouteImport
|
||||||
}
|
}
|
||||||
'/admin/accounts/$accountId': {
|
'/admin/accounts/$accountId': {
|
||||||
@@ -791,23 +792,23 @@ const AuthenticatedRouteWithChildren = AuthenticatedRoute._addFileChildren(
|
|||||||
)
|
)
|
||||||
|
|
||||||
interface StudentRouteChildren {
|
interface StudentRouteChildren {
|
||||||
StudentAlumnoAvisarRoute: typeof StudentAlumnoAvisarRoute
|
StudentStudentClassesRoute: typeof StudentStudentClassesRoute
|
||||||
StudentAlumnoBienvenidaRoute: typeof StudentAlumnoBienvenidaRoute
|
StudentStudentNotifyAbsenceRoute: typeof StudentStudentNotifyAbsenceRoute
|
||||||
StudentAlumnoClasesRoute: typeof StudentAlumnoClasesRoute
|
StudentStudentPaymentsRoute: typeof StudentStudentPaymentsRoute
|
||||||
StudentAlumnoInformarPagoRoute: typeof StudentAlumnoInformarPagoRoute
|
StudentStudentProfileRoute: typeof StudentStudentProfileRoute
|
||||||
StudentAlumnoPagosRoute: typeof StudentAlumnoPagosRoute
|
StudentStudentReportPaymentRoute: typeof StudentStudentReportPaymentRoute
|
||||||
StudentAlumnoPerfilRoute: typeof StudentAlumnoPerfilRoute
|
StudentStudentWelcomeRoute: typeof StudentStudentWelcomeRoute
|
||||||
StudentAlumnoIndexRoute: typeof StudentAlumnoIndexRoute
|
StudentStudentIndexRoute: typeof StudentStudentIndexRoute
|
||||||
}
|
}
|
||||||
|
|
||||||
const StudentRouteChildren: StudentRouteChildren = {
|
const StudentRouteChildren: StudentRouteChildren = {
|
||||||
StudentAlumnoAvisarRoute: StudentAlumnoAvisarRoute,
|
StudentStudentClassesRoute: StudentStudentClassesRoute,
|
||||||
StudentAlumnoBienvenidaRoute: StudentAlumnoBienvenidaRoute,
|
StudentStudentNotifyAbsenceRoute: StudentStudentNotifyAbsenceRoute,
|
||||||
StudentAlumnoClasesRoute: StudentAlumnoClasesRoute,
|
StudentStudentPaymentsRoute: StudentStudentPaymentsRoute,
|
||||||
StudentAlumnoInformarPagoRoute: StudentAlumnoInformarPagoRoute,
|
StudentStudentProfileRoute: StudentStudentProfileRoute,
|
||||||
StudentAlumnoPagosRoute: StudentAlumnoPagosRoute,
|
StudentStudentReportPaymentRoute: StudentStudentReportPaymentRoute,
|
||||||
StudentAlumnoPerfilRoute: StudentAlumnoPerfilRoute,
|
StudentStudentWelcomeRoute: StudentStudentWelcomeRoute,
|
||||||
StudentAlumnoIndexRoute: StudentAlumnoIndexRoute,
|
StudentStudentIndexRoute: StudentStudentIndexRoute,
|
||||||
}
|
}
|
||||||
|
|
||||||
const StudentRouteWithChildren =
|
const StudentRouteWithChildren =
|
||||||
@@ -838,8 +839,8 @@ const rootRouteChildren: RootRouteChildren = {
|
|||||||
ITokenRoute: ITokenRoute,
|
ITokenRoute: ITokenRoute,
|
||||||
JoinTokenRoute: JoinTokenRoute,
|
JoinTokenRoute: JoinTokenRoute,
|
||||||
ReportAbsenceTokenRoute: ReportAbsenceTokenRoute,
|
ReportAbsenceTokenRoute: ReportAbsenceTokenRoute,
|
||||||
AccesoIndexRoute: AccesoIndexRoute,
|
AccessIndexRoute: AccessIndexRoute,
|
||||||
AccesoMailTokenRoute: AccesoMailTokenRoute,
|
AccessEmailTokenRoute: AccessEmailTokenRoute,
|
||||||
}
|
}
|
||||||
export const routeTree = rootRouteImport
|
export const routeTree = rootRouteImport
|
||||||
._addFileChildren(rootRouteChildren)
|
._addFileChildren(rootRouteChildren)
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import { createFileRoute } from '@tanstack/react-router'
|
import { createFileRoute } from '@tanstack/react-router'
|
||||||
import { StudentClassesView } from '../../features/student-app/StudentClassesView'
|
import { StudentClassesView } from '../../features/student-app/StudentClassesView'
|
||||||
|
|
||||||
export const Route = createFileRoute('/_student/alumno/clases')({
|
export const Route = createFileRoute('/_student/student/classes')({
|
||||||
component: StudentClassesView,
|
component: StudentClassesView,
|
||||||
})
|
})
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
import { createFileRoute } from '@tanstack/react-router'
|
import { createFileRoute } from '@tanstack/react-router'
|
||||||
import { StudentHomeView } from '../../features/student-app/StudentHomeView'
|
import { StudentHomeView } from '../../features/student-app/StudentHomeView'
|
||||||
|
|
||||||
export const Route = createFileRoute('/_student/alumno/')({
|
export const Route = createFileRoute('/_student/student/')({
|
||||||
component: StudentHomeView,
|
component: StudentHomeView,
|
||||||
})
|
})
|
||||||
@@ -6,7 +6,7 @@ function NotifyAbsenceRoute() {
|
|||||||
return <NotifyAbsenceView preselected={clase} />
|
return <NotifyAbsenceView preselected={clase} />
|
||||||
}
|
}
|
||||||
|
|
||||||
export const Route = createFileRoute('/_student/alumno/avisar')({
|
export const Route = createFileRoute('/_student/student/notify-absence')({
|
||||||
validateSearch: (search: Record<string, unknown>): { clase?: string } =>
|
validateSearch: (search: Record<string, unknown>): { clase?: string } =>
|
||||||
typeof search.clase === 'string' ? { clase: search.clase } : {},
|
typeof search.clase === 'string' ? { clase: search.clase } : {},
|
||||||
component: NotifyAbsenceRoute,
|
component: NotifyAbsenceRoute,
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
import { createFileRoute } from '@tanstack/react-router'
|
import { createFileRoute } from '@tanstack/react-router'
|
||||||
import { StudentPaymentsView } from '../../features/student-app/StudentPaymentsView'
|
import { StudentPaymentsView } from '../../features/student-app/StudentPaymentsView'
|
||||||
|
|
||||||
export const Route = createFileRoute('/_student/alumno/pagos')({
|
export const Route = createFileRoute('/_student/student/payments')({
|
||||||
component: StudentPaymentsView,
|
component: StudentPaymentsView,
|
||||||
})
|
})
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
import { createFileRoute } from '@tanstack/react-router'
|
import { createFileRoute } from '@tanstack/react-router'
|
||||||
import { StudentProfileView } from '../../features/student-app/StudentProfileView'
|
import { StudentProfileView } from '../../features/student-app/StudentProfileView'
|
||||||
|
|
||||||
export const Route = createFileRoute('/_student/alumno/perfil')({
|
export const Route = createFileRoute('/_student/student/profile')({
|
||||||
component: StudentProfileView,
|
component: StudentProfileView,
|
||||||
})
|
})
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
import { createFileRoute } from '@tanstack/react-router'
|
import { createFileRoute } from '@tanstack/react-router'
|
||||||
import { ReportPaymentView } from '../../features/student-app/ReportPaymentView'
|
import { ReportPaymentView } from '../../features/student-app/ReportPaymentView'
|
||||||
|
|
||||||
export const Route = createFileRoute('/_student/alumno/informar-pago')({
|
export const Route = createFileRoute('/_student/student/report-payment')({
|
||||||
component: ReportPaymentView,
|
component: ReportPaymentView,
|
||||||
})
|
})
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
import { createFileRoute } from '@tanstack/react-router'
|
import { createFileRoute } from '@tanstack/react-router'
|
||||||
import { WelcomeView } from '../../features/student-app/WelcomeView'
|
import { WelcomeView } from '../../features/student-app/WelcomeView'
|
||||||
|
|
||||||
export const Route = createFileRoute('/_student/alumno/bienvenida')({
|
export const Route = createFileRoute('/_student/student/welcome')({
|
||||||
component: WelcomeView,
|
component: WelcomeView,
|
||||||
})
|
})
|
||||||
@@ -6,6 +6,6 @@ function ConfirmRecoveryEmailRoute() {
|
|||||||
return <ConfirmRecoveryEmailView token={token} />
|
return <ConfirmRecoveryEmailView token={token} />
|
||||||
}
|
}
|
||||||
|
|
||||||
export const Route = createFileRoute('/acceso/mail/$token')({
|
export const Route = createFileRoute('/access/email/$token')({
|
||||||
component: ConfirmRecoveryEmailRoute,
|
component: ConfirmRecoveryEmailRoute,
|
||||||
})
|
})
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
import { createFileRoute } from '@tanstack/react-router'
|
import { createFileRoute } from '@tanstack/react-router'
|
||||||
import { LinkUsedView } from '../features/student-access/LinkUsedView'
|
import { LinkUsedView } from '../features/student-access/LinkUsedView'
|
||||||
|
|
||||||
export const Route = createFileRoute('/acceso/')({
|
export const Route = createFileRoute('/access/')({
|
||||||
component: () => <LinkUsedView variant="signed-out" />,
|
component: () => <LinkUsedView variant="signed-out" />,
|
||||||
})
|
})
|
||||||
Reference in New Issue
Block a user