import { z } from 'zod';
import type { LocalizedText } from '@/server/page-layout/types';

export interface Config {
  title: LocalizedText;
  subtitle: LocalizedText;
  bgImage?: string;
}

export const configSchema: z.ZodType<Config> = z.object({
  title: z.object({ he: z.string(), en: z.string() }),
  subtitle: z.object({ he: z.string(), en: z.string() }),
  bgImage: z.string().optional(),
});

export const defaultConfig: Config = {
  title: { he: '', en: '' },
  subtitle: { he: '', en: '' },
};

export const type = 'page-hero' as const;
export const category = 'content' as const;
export const labelKey = 'module_labels.page-hero' as const;
