# yaml-language-server: $schema=https://unpkg.com/@sveltia/cms/schema/sveltia-cms.json

collections:
  - name: about
    label: About page
    icon: info
    files:
      - name: seo
        label: "Search & Social"
        file: src/content/about/seo.json
        icon: search
        fields:
          - label: Meta Title
            name: meta_title
            widget: string
          - label: Meta Description
            name: meta_description
            widget: text

      - name: hero
        label: "Hero"
        file: src/content/about/hero.json
        icon: featured_video
        fields:
          - label: Eyebrow
            name: eyebrow
            widget: string
          - label: Page Title
            name: title
            widget: string
          - label: Intro
            name: intro
            widget: text

      - name: cpe
        label: "About CPE"
        file: src/content/about/about-cpe.json
        icon: info
        fields:
          - label: Eyebrow
            name: eyebrow
            widget: string
          - label: Title
            name: title
            widget: string
            hint: This section is linked from the header menu as /about#about-cpe.
          - label: Paragraphs
            name: paragraphs
            widget: list
            label_singular: Paragraph
            field:
              label: Paragraph
              name: paragraph
              widget: text
          - label: Image
            name: image
            widget: image
            required: false
            hint: A placeholder box with the alt text shows until this is set.
          - label: Image Alt Text
            name: image_alt
            widget: string

      - name: history
        label: "Our History"
        file: src/content/about/history.json
        icon: history
        fields:
          - label: Eyebrow
            name: eyebrow
            widget: string
          - label: Title
            name: title
            widget: string
          - label: Milestones
            name: items
            widget: list
            label_singular: Milestone
            summary: "{{fields.title}}"
            fields:
              - label: Year
                name: year
                widget: string
                required: false
              - label: Icon
                name: icon
                widget: select
                required: false
                options:
                  - lucide:history
                  - lucide:compass
                  - lucide:flag
                  - lucide:award
                  - lucide:building-2
                  - lucide:graduation-cap
                  - lucide:users
              - label: Title
                name: title
                widget: string
              - label: Description
                name: description
                widget: text

      - name: vision-mission
        label: "Vision and Mission"
        file: src/content/about/vision-mission.json
        icon: visibility
        fields:
          - label: Vision
            name: vision
            widget: object
            fields:
              - label: Eyebrow
                name: eyebrow
                widget: string
              - label: Statement
                name: title
                widget: text
                hint: >-
                  This section is linked from the header menu as
                  /about#vision-mission.
              - label: Description
                name: description
                widget: text
                required: false
          - label: Mission
            name: mission
            widget: object
            fields:
              - label: Eyebrow
                name: eyebrow
                widget: string
              - label: Commitments
                name: items
                widget: list
                label_singular: Commitment
                field:
                  label: Commitment
                  name: item
                  widget: text
          - label: Core Values
            name: core_values
            widget: object
            fields:
              - label: Eyebrow
                name: eyebrow
                widget: string
              - label: Values
                name: items
                widget: list
                label_singular: Value
                summary: "{{fields.name}}"
                fields:
                  - label: Name
                    name: name
                    widget: string
                  - label: Description
                    name: description
                    widget: string
          - label: Classroom Image
            name: image
            widget: image
          - label: Image Alt Text
            name: image_alt
            widget: string

      - name: impact
        label: "Our Impact"
        file: src/content/about/impact.json
        icon: trophy
        fields:
          - { label: Eyebrow, name: eyebrow, widget: string }
          - { label: Title, name: title, widget: string }
          - label: Statistics
            name: items
            widget: list
            summary: "{{fields.value}} — {{fields.label}}"
            fields:
              - { label: Icon, name: icon, widget: string }
              - { label: Value, name: value, widget: string }
              - { label: Label, name: label, widget: string }

      - name: admissions-banner
        label: "Admissions Banner"
        file: src/content/about/admissions-banner.json
        icon: campaign
        fields:
          - { label: Eyebrow, name: kicker, widget: string }
          - { label: Title, name: title, widget: string }
          - { label: Description, name: description, widget: text }
          - label: Button
            name: cta
            widget: object
            fields:
              - { label: Label, name: label, widget: string }
              - { label: Link, name: href, widget: string }

      - name: why-choose
        label: "Why Choose CPE"
        file: src/content/about/why-choose.json
        icon: star
        fields:
          - label: Eyebrow
            name: eyebrow
            widget: string
          - label: Title
            name: title
            widget: string
          - label: Reasons
            name: items
            widget: list
            label_singular: Reason
            summary: "{{fields.title}}"
            fields:
              - label: Title
                name: title
                widget: string
              - label: Description
                name: description
                widget: text

      - name: leadership
        label: "Leadership"
        file: src/content/about/leadership.json
        icon: groups
        fields:
          - label: Eyebrow
            name: eyebrow
            widget: string
          - label: Title
            name: title
            widget: string
            hint: >-
              This section is linked from the header menu as /about#leadership.
              The people themselves are managed under the Leadership singleton.
          - label: Description
            name: description
            widget: text
            required: false
          - label: Button
            name: cta
            widget: object
            fields:
              - { label: Label, name: label, widget: string }
              - { label: Link, name: href, widget: string }
