Skip to content
Grav 2.0 is officially stable. Read the announcement →

Community guidelines

Please keep discussions civil and on-topic. Repeated violations may lead to a temporary ban.

Forms & Blueprints

Multiple column in admin form

admin

Started by julien 8 years ago · 0 replies · 555 views
8 years ago

Hi everyone,

I've been building a page with its own blueprint. And I want to display certain fields using columns. I managed to do it but only once. Meaning that after my first set of columns, I have a "type: spacer", I am unable to have other fields in columns. They just stack each other as they do without columns.

Am I missing something. I can't find any where saying that you can only have one set of columns and neither if there is anything special to do like closing tag "columns:".

Thank you in advance.

here is what I have in my blueprint

YAML
        hero_title:
          type: spacer
          title: Header Banner

        columns:
          type: columns
          fields:
            column3:
              type: column
              fields:
                header.hero_title:
                  type: text
                  autofocus: true
                  style: vertical
                  label: Header Banner Title
                  description: 'If no title is added, the page title will be used'

            column4:
              type: column
              fields:
                header.hero_image:
                  type: filepicker
                  style: vertical
                  label: Header Banner Image
                  preview_images: true
                  description: 'This is the image showing at the top of the page'

        services_title:
          type: spacer
          title: Services

        header.service-one_title:
          type: text
          autofocus: true
          style: vertical
          label: Service 1 Title

        header.service1_image:
          type: filepicker
          style: vertical
          label: Service 1 Background Image
          preview_images: true

Suggested topics

Topic Participants Replies Views Activity
Forms & Blueprints · by Ton Haarmans, 5 years ago
13 1140 4 months ago
Forms & Blueprints · by Hugo Oliveira, 5 months ago
0 63 5 months ago
Forms & Blueprints · by Flachy Joe, 6 months ago
9 138 6 months ago
Forms & Blueprints · by Augustus, 7 months ago
7 114 7 months ago
Forms & Blueprints · by Julien, 7 months ago
10 132 7 months ago