{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "http://schema.mydesignsystem.com/header.schema.json",
  "title": "Header",
  "description": "Header layered on top by the CMS",
  "type": "object",
  "properties": {
    "logo": {
      "title": "Logo",
      "type": "object",
      "properties": {
        "src": {
          "title": "Source",
          "description": "Picture source",
          "type": "string",
          "format": "image"
        },
        "srcInverted": {
          "title": "Source",
          "description": "Picture source",
          "type": "string",
          "format": "image"
        },
        "alt": {
          "title": "Alt text",
          "description": "Alt text to display for picture",
          "type": "string"
        },
        "homepageHref": {
          "type": "string",
          "format": "uri",
          "default": "/"
        },
        "width": {
          "title": "Width",
          "description": "Width of the picture",
          "type": "integer",
          "minimum": 0,
          "examples": [
            300
          ]
        },
        "height": {
          "title": "Height",
          "description": "Height of the picture",
          "type": "integer",
          "minimum": 0,
          "examples": [
            300
          ]
        }
      },
      "additionalProperties": false
    },
    "flyoutInverted": {
      "type": "boolean",
      "title": "Flyout Inverted",
      "description": "Toggle the inversion of the flyout navigation",
      "default": false
    },
    "dropdownInverted": {
      "type": "boolean",
      "title": "Dropdown Inverted",
      "description": "Toggle the inversion of the dropdown navigation",
      "default": false
    },
    "floating": {
      "type": "boolean",
      "title": "Floating",
      "description": "Make the header float over the first Section",
      "default": false
    },
    "inverted": {
      "type": "boolean",
      "title": "Inverted",
      "description": "Invert the color scheme of the header",
      "default": false
    },
    "navItems": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "url": {
            "type": "string",
            "format": "uri"
          },
          "label": {
            "type": "string"
          },
          "active": {
            "type": "boolean"
          },
          "items": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "url": {
                  "type": "string",
                  "format": "uri"
                },
                "label": {
                  "type": "string"
                },
                "active": {
                  "type": "boolean"
                }
              },
              "additionalProperties": false
            }
          }
        },
        "additionalProperties": false,
        "required": [
          "url",
          "label"
        ]
      },
      "examples": [
        [
          {
            "label": "Active Item",
            "url": "#",
            "active": true
          },
          {
            "label": "Navigation Item",
            "url": "#"
          },
          {
            "label": "Dropdown",
            "url": "#",
            "items": [
              {
                "label": "Level 2 Item",
                "url": "#"
              },
              {
                "label": "Active Item",
                "active": true,
                "url": "#"
              },
              {
                "label": "An Item with a longer Label",
                "url": "#"
              },
              {
                "label": "And One last one",
                "url": "#"
              }
            ]
          },
          {
            "label": "One more Item",
            "url": "#"
          },
          {
            "label": "Last Item",
            "url": "#"
          }
        ]
      ]
    }
  },
  "additionalProperties": false
}