☁️ Loving our new documentation website? Provide feedback in the CloudCannon Community! ✨

tags

Table of contents

Description:

This key defines which tags are associated with a given value in a Structure.

You can use tags to group and filter Structure options when selecting from a modal.

This key has no default.

Appears in:
└── [*]
    └── tags
Type:
Array<tags[*]>
Items:
[*]string#

This key represents an individual tag string in the values[*].tags array.

The value is a string that specifies a tag associated with a structure value.

Show examplesHide examples

In this example, we have configured the featured and news tags for the entry labeled Blog in the article_information Structure.

Copied to clipboard
_structures:
  article_information:
    values:
      - label: Blog
        tags:
          - featured
          - news
{
  "_structures": {
    "article_information": {
      "values": [
        {
          "label": "Blog",
          "tags": [
            "featured",
            "news"
          ]
        }
      ]
    }
  }
}
Examples:

In this example we have three options for the page_components Structure: Hero Component, Feature Component, and Video Component. We can search the Structure modal using the image, text, button, and video tags to filter Structure values.

Copied to clipboard
_structures:
  page_components:
    style: modal
    values:
      - label: Hero Component
        tags:
          - image
          - text
        value:
          title: 
          description: 
          image_path: 
          link:
            text: 
            url: 
      - label: Feature Component
        tags:
          - image
          - text
          - button
        value:
          image_path: 
          title: 
          description: 
          button:
            link: 
            text: 
          reversed_layout: false
      - label: Video Component
        tags:
          - image
          - video
        value:
          image_path: 
          videoUrl:
{
  "_structures": {
    "page_components": {
      "style": "modal",
      "values": [
        {
          "label": "Hero Component",
          "tags": [
            "image",
            "text"
          ],
          "value": {
            "title": null,
            "description": null,
            "image_path": null,
            "link": {
              "text": null,
              "url": null
            }
          }
        },
        {
          "label": "Feature Component",
          "tags": [
            "image",
            "text",
            "button"
          ],
          "value": {
            "image_path": null,
            "title": null,
            "description": null,
            "button": {
              "link": null,
              "text": null
            },
            "reversed_layout": false
          }
        },
        {
          "label": "Video Component",
          "tags": [
            "image",
            "video"
          ],
          "value": {
            "image_path": null,
            "videoUrl": null
          }
        }
      ]
    }
  }
}
Open in a new tab