[
  {
    "name": "itemHeadingLevel",
    "type": "number",
    "required": true,
    "description": "The heading level which represents an element from `<h1>` through to `<h6>` for each of the accordion items."
  },
  {
    "name": "itemHeadingSize",
    "type": "string",
    "required": false,
    "description": "The physical size of the accordion item titles (`xl`, `l`, `m`, `s` or `xs`). This will be ignored if JavaScript is enabled and the items will have a small heading.",
    "default": "s"
  },
  {
    "name": "items",
    "type": "array",
    "required": true,
    "description": "The sections within the accordion.",
    "params": [
      {
        "name": "title",
        "type": "string",
        "required": true,
        "description": "The heading of each accordion section."
      },
      {
        "name": "body",
        "type": "string",
        "required": false,
        "description": "The HTML for the main body of the accordion item. Not displayed if `text` is set."
      },
      {
        "name": "text",
        "type": "string",
        "required": false,
        "description": "The text for the accordion item which will be inserted into a `<p>` element. Overwrites `body` if it is set."
      },
      {
        "name": "open",
        "type": "boolean",
        "required": false,
        "description": "If `true`, open the accordion item. If a `group` is set, only one item in that group can be open.",
        "default": false
      }
    ]
  },
  {
    "name": "id",
    "type": "string",
    "required": true,
    "description": "A unique ID for the accordion group."
  },
  {
    "name": "singleOpenItem",
    "type": "boolean",
    "required": false,
    "description": "If `true`, only one accordion items can be opened at a time.",
    "default": false
  },
  {
    "name": "toggleAllButton",
    "type": "object",
    "required": false,
    "description": "Allows the user to open or close all sections.",
    "params": [
      {
        "name": "enabled",
        "type": "boolean",
        "required": true,
        "description": "If `true`, add a button above the accordion that allows the user to open or close all sections.",
        "default": false
      },
      {
        "name": "openAllLabel",
        "type": "string",
        "required": false,
        "description": "The label for the button when all sections are closed.",
        "default": "Show all sections"
      },
      {
        "name": "closeAllLabel",
        "type": "string",
        "required": false,
        "description": "The label for the button when all sections are open.",
        "default": "Hide all sections"
      }
    ]
  },
  {
    "name": "classes",
    "type": "string",
    "required": false,
    "description": "Classes to add to the accordion."
  },
  {
    "name": "attributes",
    "type": "object",
    "required": false,
    "description": "HTML attributes (for example data attributes) to add to the accordion."
  }
]
