{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "http://schema.mydesignsystem.com/blog-aside.schema.json",
  "title": "Blog Aside",
  "description": "Meta info for a singular blog entry",
  "type": "object",
  "properties": {
    "author": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "$id": "http://schema.mydesignsystem.com/blog-author.schema.json",
      "type": "object",
      "title": "Blog Author",
      "description": "The author of the blog post",
      "properties": {
        "name": {
          "title": "Name",
          "description": "The name of the author",
          "type": "string",
          "examples": [
            "John Doe"
          ]
        },
        "byline": {
          "title": "Byline",
          "description": "The byline of the author",
          "type": "string",
          "examples": [
            "CEO at Company"
          ]
        },
        "image": {
          "type": "object",
          "properties": {
            "src": {
              "type": "string",
              "format": "image",
              "title": "Image Source",
              "description": "URL of the image to display",
              "examples": [
                "img/people/author-emily.png"
              ]
            },
            "alt": {
              "type": "string",
              "title": "Alt Text",
              "description": "Alt text of the image",
              "examples": [
                "Picture of Isabella Doe"
              ]
            },
            "fullWidth": {
              "type": "boolean",
              "title": "Full Width",
              "description": "Image uses all the horizontal space vailable",
              "default": false
            },
            "aspectRatio": {
              "type": "string",
              "title": "aspectRatio",
              "description": "Aspect Ratio of the Images",
              "enum": [
                "wide",
                "square",
                "vertical"
              ],
              "default": "square"
            }
          },
          "additionalProperties": false
        },
        "links": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "icon": {
                "type": "string",
                "format": "icon"
              },
              "label": {
                "type": "string"
              },
              "url": {
                "type": "string",
                "format": "uri"
              },
              "newTab": {
                "title": "Open link in new Tab",
                "description": "Open link in new Tab",
                "type": "boolean",
                "default": false
              },
              "ariaLabel": {
                "title": "Aria Label",
                "description": "Aria label for the link",
                "type": "string",
                "examples": [
                  "Link to Isabella Doe's social media profile"
                ]
              }
            },
            "additionalProperties": false
          },
          "examples": [
            [
              {
                "icon": "phone",
                "label": "0228 / 688 966 20",
                "url": "tel:+4922868896620"
              },
              {
                "icon": "email",
                "label": "mail@example.com",
                "url": "mailto:mail@example.com"
              }
            ]
          ]
        }
      },
      "additionalProperties": false,
      "required": [
        "name"
      ]
    },
    "socialSharing": {
      "type": "array",
      "title": "Social Sharing",
      "description": "The social sharing links for the blog post",
      "items": {
        "type": "object",
        "properties": {
          "icon": {
            "title": "Icon",
            "description": "The icon name for the social link",
            "type": "string",
            "format": "icon",
            "examples": [
              "twitter",
              "facebook"
            ]
          },
          "url": {
            "title": "URL",
            "description": "The url for the social link",
            "type": "string",
            "format": "uri",
            "examples": [
              "https://twitter.com/share?text=Check%20this%20out!&url=https://example.com"
            ]
          },
          "title": {
            "title": "Title",
            "description": "The title for the social link",
            "type": "string",
            "examples": [
              "Share on Twitter"
            ]
          }
        },
        "additionalProperties": false,
        "required": [
          "icon",
          "url",
          "title"
        ]
      }
    },
    "readingTime": {
      "title": "Reading Time",
      "description": "The reading time for the blog post",
      "type": "string",
      "examples": [
        "5 min read"
      ]
    },
    "date": {
      "title": "Published Date",
      "description": "The date when the blog post was published",
      "type": "string",
      "format": "date",
      "examples": [
        "12/30/2022"
      ]
    },
    "className": {
      "type": "string"
    }
  },
  "additionalProperties": false,
  "required": [
    "author",
    "date"
  ]
}