Trying to add toggle in blueprint

I am trying to step outside the Blueprint with Kirby. Can some tell me what I am doing wrong because the toggle will not display on the page. I get a message Invalid section type ("")

sidebar:
  cover:
    type: files
    headline: Product Cover
    layout: cards
    info: "{{ file.dimensions }}"
    template: cover
    max: 1
    image:
       cover: true
  gallery:
    type: files
    headline: Product Thumbnails

    fields:
       featured:
         type: toggle
         text: Will be featured on the home page

Looks like an indentation issue. What are gallery and cover supposed to be, fields or sections? The context is not quite clear.

The cover is fields which is the main image.

Yes, but something is definitely wrong here. A field doesn’t have a headline but a label. Could you please post the complete blueprint, please. And if these are supposed to be fields, then the fields key is missing after sidebar

title: Product

preset: page

template: products

# Sorting number scheme that is applied when page status is changed to `listed`
# More about page sorting: https://getkirby.com/docs/reference/panel/blueprints/page#sorting
num: date

# Custom descriptions for each page status depending on use case


status:
  draft:
    label: Draft
    text: The product is still in draft mode. It can only be seen by editors with Panel access.
  unlisted:
    label: In Review
    text: The product is online and can be visited with the direct URL. The team must still give the final go to publish it.
  listed:
    label: Published
    text: The product is online and listed in the product section.

fields:
  type:
    label: Product Model
    help:  Product model
    type: text
    width: 2/3

  colors:
     label: Product Colors
     help: Same product but more colors
     type: number
     width: 1/3

  description:
    label: Description
    type: textarea
    size: large

sidebar:
  cover:
    type: files
    headline: Product Cover
    layout: cards
    info: "{{ file.dimensions }}"
    template: cover
    max: 1
    image:
       cover: true
  gallery:
    type: files
    headline: Product Thumbnails

  fields:
    featured:
        type: toggle
        fields:

          text: Will be featured on the home page

The sidebar should look like this:

sidebar:
  meta:
    type: fields
    fields:
      cover:
        type: files
        label: Product Cover
        layout: cards
        info: "{{ file.dimensions }}"
        template: cover
        max: 1
        image:
          cover: true
      gallery:
        type: files
        label: Product Thumbnails

      featured:
        type: toggle
        text: Will be featured on the home page

Make sure to get the indentation right.

1 Like

How many indentation should be?

Just as I posted it above, 2 spaces per indentation level.

@ODD_CODE Is this solved now?

Thank you so much for the help.