Lesezeichen, Import/Export, Favoriten-Sortierung im Frontend, Favicon-Fix, sortierbare Spalten, Kategorie-Dropdown

This commit is contained in:
2026-07-19 21:56:25 +02:00
parent 31e17ff77b
commit dc91a9aba9
24 changed files with 1655 additions and 180 deletions

View File

@@ -78,3 +78,31 @@ export const CategoryReorderSchema = z
)
.min(1, "mindestens ein Eintrag erforderlich");
export type CategoryReorderInput = z.infer<typeof CategoryReorderSchema>;
export const BookmarkCreateSchema = z.object({
url: z.string().url("url muss eine gültige URL sein"),
// Optional: wird nicht angegeben, versucht das Backend automatisch den
// Seitentitel zu lesen (siehe apps/backend/src/routes/bookmarks.ts).
displayName: z.string().min(1).optional(),
description: z.string().optional(),
category: z.string().optional(),
icon: z.string().optional(),
favorite: z.boolean().optional(),
alias: z.array(z.string()).optional(),
order: z.number().optional(),
});
export type BookmarkCreateInput = z.infer<typeof BookmarkCreateSchema>;
export const BookmarkUpdateSchema = BookmarkCreateSchema.partial();
export type BookmarkUpdateInput = z.infer<typeof BookmarkUpdateSchema>;
/** Für Drag & Drop: neue Reihenfolge mehrerer Lesezeichen auf einmal setzen. */
export const BookmarkReorderSchema = z
.array(
z.object({
id: z.string().min(1),
order: z.number(),
})
)
.min(1, "mindestens ein Eintrag erforderlich");
export type BookmarkReorderInput = z.infer<typeof BookmarkReorderSchema>;