refactor: update navigation links and search parameters across authenticated routes

This commit is contained in:
2025-08-29 16:51:22 -06:00
parent f8de39e6d1
commit 6c3dd54d5f
6 changed files with 41 additions and 26 deletions

View File

@@ -53,7 +53,7 @@ const planesKeys = {
all: () => [...planesKeys.root, 'all'] as const,
}
async function fetchPlanIdsByScope(search: Pick<SearchState, 'planId'|'carreraId'|'facultadId'>): Promise<string[] | null> {
async function fetchPlanIdsByScope(search: Pick<SearchState, 'planId' | 'carreraId' | 'facultadId'>): Promise<string[] | null> {
const { planId, carreraId, facultadId } = search
if (planId) return [planId]
if (carreraId) {
@@ -369,7 +369,7 @@ function RouteComponent() {
<Link
to="/planes"
className="hidden sm:inline-flex items-center gap-2 rounded-xl border px-3 py-2 text-sm hover:bg-neutral-50"
search={{ crear: 'asignatura' }}
search={{ plan: '' }}
>
<Icons.Plus className="w-4 h-4" /> Nueva asignatura
</Link>