Hi,
I am trying to modify the forms in the admin side for the carousel I have on the home page. I managed to add a filepicker to the form but I can’t seem to send the uploaded image name to the twig correctly.
What am I missing? I am guessing something is wrong with the way the twig line is formatted but couldn’t figure it out.
this is my carousel.yaml
title: Carousel
'@extends':
    type: default
form:
  fields:
    tabs:
      type: tabs
      active: 1
      fields:
        slides:
          type: tab 
          title: Slides 
          fields:
            header.slides:
              name: slides
              type: list
              label: Slides
              fields:
                .heading:
                  type: text
                  label: Heading
                  help: Slide's heading.
                .description:
                  type: textarea
                  label: Description
                  help: Slide's description.
                .background_image:
                  type: file
                  destination: '@self'
                  multiple: false
                  accept:
                    - image/*
                  label: Background Image
                  help: Slide's background image.
                .background_image_description:
                  type: text
                  label: Background Image's Description
                  help: Description for slide's background image.
This is the line where I get the error in carousel.html.twig
{{ page.media.images[slide.background_image].html('', slide.background_image_description) }}
And this is my carousel.md
title: Carousel
visible: true
slides:
    -
        heading: 'It''s simple, smart and occasionally magical.'
        description: 'Intrinsicly negotiate corporate synergy rather than user-centric web services. Synergistically<br>transition emerging schemas and.'
        background_image_description: 'It''s simple, smart and occasionally magical.'
    -
        heading: 'It''s profitable and successful!'
        description: 'Synergistically enhance low-risk high-yield testing procedures with clicks-and-mortar architectures.<br>Compellingly revolutionize future-proof interfaces and.'
        background_image_description: 'It''s profitable and successful!'
    -
        heading: 'Good solutions for your business!'
        description: 'Monotonectally envisioneer 24/7 bandwidth with reliable imperatives. Continually unleash unique<br>niches after go forward.'
        background_image_description: 'Good solutions for your business!'
Thanks.