50753b9cc7
- Add site singleton for global settings (name, description, URL, contact, social media) - Add brand mark (globe icon) to KeyStatic header - Add entry layout grouping (Ana Bilgiler, Medya, Sınıflandırma, Özet, İçerik) - Add preview URL configuration for local development - Add published, featured, and relatedPosts fields - Use local storage for development, GitHub storage for production - Update Astro content schema with new fields Co-Authored-By: Claude <noreply@anthropic.com>
24 lines
684 B
TypeScript
24 lines
684 B
TypeScript
import { defineCollection, z } from 'astro:content';
|
|
import { glob } from 'astro/loaders';
|
|
|
|
const post = defineCollection({
|
|
loader: glob({ pattern: '**/*.mdoc', base: './src/data/post' }),
|
|
schema: z.object({
|
|
title: z.string(),
|
|
date: z.date(),
|
|
author: z.string().default('TA1SPH'),
|
|
published: z.boolean().default(true),
|
|
featured: z.boolean().default(false),
|
|
categories: z.array(z.string()).default([]),
|
|
tags: z.array(z.string()).default([]),
|
|
layout: z.string().default('post'),
|
|
image: z.string().optional(),
|
|
excerpt: z.string().optional(),
|
|
relatedPosts: z.array(z.string()).optional(),
|
|
}),
|
|
});
|
|
|
|
export const collections = {
|
|
post,
|
|
};
|