import { Block } from 'payload'

export const DocumentBlock: Block = {
  slug: 'document',
  labels: {
    singular: {
      de: "PDF Dokument"
    },
    plural: {
      de: "PDF Dokumenten"
    }
  },
  fields: [
    {
      name: 'file',
      type: 'upload',
      relationTo: 'documents',
      required: true
    },
    {
      name: 'button',
      label: {
        de: "Button text"
      },
      type: 'text',
      defaultValue: 'Download Flyer',
      required: true,
    },
  ]
}