Skip to main content
Validate event schedule component schema

Properties

  • title (string) - maxLength: 50 - Title of the event
  • startDate (string) (required)
  • endDate (string)
  • timeZone (string) (required)
  • repeat (boolean)
  • recurrence (string) - enum: daily, weekly, monthly, yearly
  • allDayEvent (boolean) - default: False
  • timeFormat (string) - enum: 12h, 24h - default: 24h
  • dateFormat (string) - enum: MM-dd-yyyy, dd-MM-yyyy, yyyy-MM-dd, M/dd/yyyy, MMM d, yyyy - default: MM-dd-yyyy
  • separator (object - ref: separator)
  • addToCalender (object)
  • formatting (object)
    • textStyle (object - style component reference)
    • cardStyle (object - style component reference)

Used in Categories

This component is used in the following categories:

Schema

{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "definitions": {},
  "title": "Event Schedule component",
  "description": "Validate event schedule component schema",
  "type": "object",
  "additionalProperties": false,
  "required": [
    "startDate",
    "timeZone"
  ],
  "properties": {
    "title": {
      "type": "string",
      "maxLength": 50,
      "description": "Title of the event"
    },
    "startDate": {
      "type": "string"
    },
    "endDate": {
      "type": "string"
    },
    "timeZone": {
      "type": "string"
    },
    "repeat": {
      "type": "boolean"
    },
    "recurrence": {
      "type": "string",
      "enum": [
        "daily",
        "weekly",
        "monthly",
        "yearly"
      ]
    },
    "allDayEvent": {
      "type": "boolean",
      "default": false
    },
    "timeFormat": {
      "type": "string",
      "default": "24h",
      "enum": [
        "12h",
        "24h"
      ]
    },
    "dateFormat": {
      "type": "string",
      "default": "MM-dd-yyyy",
      "enum": [
        "MM-dd-yyyy",
        "dd-MM-yyyy",
        "yyyy-MM-dd",
        "M/dd/yyyy",
        "MMM d, yyyy"
      ]
    },
    "separator": {
      "$ref": "separator.json"
    },
    "addToCalender": {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "tracking": {
          "$ref": "event_tracking.json"
        }
      }
    },
    "formatting": {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "textStyle": {
          "$ref": "style/text.json"
        },
        "cardStyle": {
          "$ref": "style/card.json"
        }
      }
    }
  },
  "if": {
    "properties": {
      "allDayEvent": {
        "const": false
      }
    },
    "required": [
      "allDayEvent"
    ]
  },
  "then": {
    "required": [
      "endDate"
    ]
  }
}