feat(navigation): add Header entity + use-case + mock/payload repos + DI container
This commit is contained in:
15
packages/navigation/src/entities/header.ts
Normal file
15
packages/navigation/src/entities/header.ts
Normal file
@@ -0,0 +1,15 @@
|
||||
import { z } from "zod";
|
||||
|
||||
export const headerItemSchema = z.object({
|
||||
label: z.string().min(1).max(64),
|
||||
href: z.string().min(1),
|
||||
external: z.boolean().default(false),
|
||||
});
|
||||
|
||||
export const headerSchema = z.object({
|
||||
logoId: z.string().optional(),
|
||||
items: z.array(headerItemSchema),
|
||||
});
|
||||
|
||||
export type Header = z.infer<typeof headerSchema>;
|
||||
export type HeaderItem = z.infer<typeof headerItemSchema>;
|
||||
Reference in New Issue
Block a user