The carousel slot is designed to contain a single carousel item. As with the banner slot, the structure of this slot is very simple, with a property named "carouselslot" that holds a reference to a single carousel content item chosen by the user.

The full carousel slot type is shown below.

{
  "$schema": "http://bigcontent.io/cms/schema/v1/schema#",
  "id": "https://s3-eu-west-1.amazonaws.com/amp-product/tutorials/dynamiccontenttutorials/carouselslot.json",
  "title": "Feature page carousel slot",
  "description": "Slot to contain the feature carousel",
  "allOf": [
    {
      "$ref": "http://bigcontent.io/cms/schema/v1/core#/definitions/content"
    }
  ],
  "type": "object",
  "properties": {
    "carouselslot": {
      "title": "Feature page carousel",
      "description": "The carousel for the feature page",
      "allOf": [
        {
          "$ref": "http://bigcontent.io/cms/schema/v1/core#/definitions/content-link"
        },
        {
          "properties": {
            "contentType": {
              "title": "content",
              "enum": [
                "https://s3-eu-west-1.amazonaws.com/amp-product/tutorials/dynamiccontenttutorials/democarousel.json"
              ]
            }
          }
        }
      ]
    }
  }
}

To register the carousel slot, register it on your hub using the URI specified in the id field of the slot type and enable it on one or more repositories. For more information see the registering content types page. In most cases you won't include a visualization or card for a slot, but providing your own icon will help to identify this slot type in the slot library.

Here's an example of adding content to a carousel slot item. We have created a slot item called "feature page carousel slot" used to contain the carousel that will be displayed on this particular page.

To consume the content when it's published or within a content preview app, we'd find the slot id, as explained in the Banner slot step by step example.

Adding content to a carousel slot item
Adding content to a carousel slot item

results matching ""

    No results matching ""