feat(client): workspace

Signed-off-by: Noa Virellia <noa@requiem.garden>
This commit is contained in:
2025-12-24 21:11:20 +08:00
parent 0d3651f923
commit cfe8bd0bfa
35 changed files with 5086 additions and 33 deletions

View File

@@ -0,0 +1,25 @@
import { createFileRoute, redirect } from '@tanstack/react-router';
import { SectionCards } from '@/components/section-cards';
import { hasToken } from '@/lib/token';
export const Route = createFileRoute('/_sidebarLayout/')({
component: Index,
beforeLoad: async ({ location }) => {
if (!hasToken()) {
throw redirect({
to: '/login',
search: {
redirect: location.href,
},
});
}
},
});
function Index() {
return (
<div className="flex flex-col gap-4 py-4 md:gap-6 md:py-6">
<SectionCards />
</div>
);
}