qazaq-legacy-foundation-web/src/globals/Home.ts
Peppa ab5a495f2f
Some checks failed
peppa/install install: failure за 0с
ci / checks (pull_request) Failing after 3s
deploy / deploy (pull_request) Successful in 1m46s
QLFW-4: главная страница фонда (Next.js, Tailwind, Payload)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-16 15:35:52 +05:00

21 lines
1.1 KiB
TypeScript

import type { GlobalConfig } from 'payload'
const item = [
{ name: 'title', label: 'Название', type: 'text', required: true, localized: true },
{ name: 'text', label: 'Описание', type: 'textarea', localized: true },
] as const
/** Подтверждённый контент главной. Пустое поле — сайт покажет «нужно уточнить» или скроет блок. */
export const Home: GlobalConfig = {
slug: 'home',
label: 'Главная страница',
access: { read: () => true },
fields: [
{ name: 'mission', label: 'Миссия фонда', type: 'textarea', localized: true },
{ name: 'directions', label: 'Направления деятельности', type: 'array', localized: false, fields: [...item] },
{ name: 'projects', label: 'Проекты', type: 'array', fields: [...item] },
{ name: 'collaboration', label: 'Приглашение к сотрудничеству', type: 'textarea', localized: true },
{ name: 'contactEmail', label: 'Почта для связи', type: 'email' },
],
}