title: Article
icon: article

status:
  draft:
    label: Brouillon
    text: L'article n'est pas visible
  unlisted:
    label: Non listé
    text: L'article est accessible mais pas dans la liste
  listed:
    label: Publié
    text: L'article est visible publiquement
tabs:
  content:
    label: Contenu
    icon: text
    columns:
      # Colonne principale
      main:
        width: 2/3
        sections:
          # En-tête
          header:
            type: fields
            fields:
              intro:
                label: Introduction
                type: writer
                nodes:
                  - heading
                headings:
                  - 1
                buttons: false
                help: "Résumé ou accroche de l'article"

          # Contenu
          content:
            type: fields
            fields:
              article_content:
                label: Contenu de l'article
                type: blocks
                fieldsets:
                  heading:
                    extends: blocks/heading
                    fields:
                      level:
                        default: h3
                        options:
                          h3: Titre H3
                  text:
                    extends: blocks/text
                    fields:
                      text:
                        marks:
                          - bold
                          - italic
                          - green
                          - pixel
                          - underline
                          - strike
                          - clear
                          - link
                  list:
                    extends: blocks/list
                  quote:
                    extends: blocks/quote
                  image:
                    extends: blocks/image
                  video:
                    extends: blocks/video
                  jeu:
                    extends: blocks/jeu

      # Sidebar
      sidebar:
        width: 1/3
        sections:
          # Métadonnées
          meta:
            type: fields
            fields:
              date:
                label: Date de publication
                type: date
                display: DD/MM/YYYY
                required: true
                default: today
                translate: false
              cover:
                label: Image de couverture
                type: files
                layout: cards
                max: 1
                accept: image/*
                translate: false
                image:
                  cover: true
                  ratio: 16/9
                uploads:
                  template: image

          # Recommandations
          related:
            type: fields
            fields:
              related_articles:
                label: Articles recommandés
                type: pages
                query: site.find('blog').children.listed
                max: 3
                help: "Articles similaires à afficher en bas de page"
