diff --git a/dealplustech-astro/src/content.config.ts b/dealplustech-astro/src/content.config.ts deleted file mode 100644 index 276953b95..000000000 --- a/dealplustech-astro/src/content.config.ts +++ /dev/null @@ -1,71 +0,0 @@ -import { defineCollection } from 'astro:content'; -import { glob } from 'astro/loaders'; -import { z } from 'astro/zod'; - -// Product specification schema -const productSpecificationSchema = z.object({ - label: z.string(), - value: z.string(), - unit: z.string().optional(), -}); - -// FAQ item schema -const faqItemSchema = z.object({ - question: z.string(), - answer: z.string(), -}); - -// Product table schema (for specification tables) -const productTableSchema = z.object({ - tableName: z.string(), - headers: z.array(z.string()), - rows: z.array(z.array(z.string())), -}); - -// Product collection schema -const products = defineCollection({ - loader: glob({ pattern: '**/*.md', base: './src/content/products' }), - schema: z.object({ - // Basic info - id: z.string(), - name: z.string(), - nameEn: z.string(), - slug: z.string(), - - // SEO - description: z.string(), - shortDescription: z.string().optional(), - keywords: z.array(z.string()).optional(), - seoContent: z.string().optional(), - - // Images - image: z.string(), - - // Product details - specifications: z.array(productSpecificationSchema).optional(), - features: z.array(z.string()).optional(), - applications: z.array(z.string()).optional(), - certifications: z.array(z.string()).optional(), - - // Tables - productTables: z.array(productTableSchema).optional(), - - // FAQ - faq: z.array(faqItemSchema).optional(), - - // Relations - relatedProductIds: z.array(z.string()).optional(), - - // Schema.org data - schemaData: z.object({ - brand: z.string().optional(), - manufacturer: z.string().optional(), - material: z.string().optional(), - category: z.string().optional(), - }).optional(), - }), -}); - -export const collections = { - products: products, -};