refactor: move old design to separate layout tree

This commit is contained in:
2026-08-27 19:22:28 +05:00
parent dfb2311e32
commit f08af41568
8 changed files with 198 additions and 163 deletions
+14
View File
@@ -0,0 +1,14 @@
import { error } from '@sveltejs/kit';
import { getTool, TOOLS } from '$lib/registry';
import { t } from '$lib/i18n/t';
import type { EntryGenerator, PageLoad } from './$types';
export const entries: EntryGenerator = () => TOOLS.map((tool) => ({ id: tool.id }));
export const load: PageLoad = ({ params }) => {
const tool = getTool(params.id);
if (!tool) {
error(404, t('errors.notFound'));
}
return { id: tool.id };
};