{
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "$id": "https://usechartory.com/schemas/shipment-journey.json",
 "description": "The data prop of <ShipmentJourney> (Chartory chart 096).",
 "type": "object",
 "title": "ShipmentJourneyData",
 "properties": {
  "t0": {
   "type": "number",
   "description": "The start time."
  },
  "t1": {
   "type": "number",
   "description": "The end time."
  },
  "now": {
   "type": "number",
   "description": "Where now is on the axis."
  },
  "phases": {
   "type": "array",
   "items": {
    "type": "array",
    "prefixItems": [
     {
      "type": "number"
     },
     {
      "type": "number"
     },
     {
      "type": "string"
     }
    ],
    "minItems": 3,
    "maxItems": 3
   },
   "description": "The phases: [start, end, colour token]."
  },
  "events": {
   "type": "array",
   "items": {
    "type": "object",
    "title": "ShipmentJourneyEvent",
    "properties": {
     "t": {
      "type": "number",
      "description": "Where the event sits on the time axis."
     },
     "label": {
      "type": "string",
      "description": "The name shown on the chart."
     },
     "date": {
      "type": "string",
      "description": "The date as shown."
     },
     "up": {
      "type": "boolean",
      "description": "Draws the event's stem above the line."
     }
    },
    "required": [
     "t",
     "label",
     "date",
     "up"
    ]
   },
   "description": "One entry per event."
  },
  "xl": {
   "type": "array",
   "items": {
    "type": "array",
    "prefixItems": [
     {
      "type": "number"
     },
     {
      "type": "string"
     }
    ],
    "minItems": 2,
    "maxItems": 2
   },
   "description": "The x axis labels: [position, label] pairs."
  }
 },
 "required": [
  "t0",
  "t1",
  "now",
  "phases",
  "events",
  "xl"
 ]
}
