0
0
mirror of https://github.com/PostHog/posthog.git synced 2024-12-01 04:12:23 +01:00
posthog/ee/frontend/mobile-replay/schema/mobile/rr-mobile-schema.json
Paul D'Ambra 1cedcd95cb
feat: explicit screenshot support in the mobile replay schema (#21965)
Co-authored-by: David Newell <d.newell1@outlook.com>
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-04-30 11:43:17 +01:00

1350 lines
52 KiB
JSON

{
"$schema": "http://json-schema.org/draft-07/schema#",
"anyOf": [
{
"additionalProperties": false,
"properties": {
"data": {
"additionalProperties": false,
"properties": {
"initialOffset": {
"additionalProperties": false,
"properties": {
"left": {
"type": "number"
},
"top": {
"type": "number"
}
},
"required": ["top", "left"],
"type": "object"
},
"wireframes": {
"description": "This mimics the RRWeb full snapshot event type, except instead of reporting a serialized DOM it reports a wireframe representation of the screen.",
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
}
},
"required": ["wireframes", "initialOffset"],
"type": "object"
},
"delay": {
"type": "number"
},
"timestamp": {
"type": "number"
},
"type": {
"$ref": "#/definitions/EventType.FullSnapshot"
}
},
"required": ["data", "timestamp", "type"],
"type": "object"
},
{
"additionalProperties": false,
"properties": {
"data": {
"additionalProperties": false,
"properties": {
"height": {
"type": "number"
},
"href": {
"type": "string"
},
"width": {
"type": "number"
}
},
"required": ["width", "height"],
"type": "object"
},
"delay": {
"type": "number"
},
"timestamp": {
"type": "number"
},
"type": {
"$ref": "#/definitions/EventType.Meta"
}
},
"required": ["data", "timestamp", "type"],
"type": "object"
},
{
"additionalProperties": false,
"properties": {
"data": {
"additionalProperties": false,
"properties": {
"payload": {},
"tag": {
"type": "string"
}
},
"required": ["tag", "payload"],
"type": "object"
},
"delay": {
"type": "number"
},
"timestamp": {
"type": "number"
},
"type": {
"$ref": "#/definitions/EventType.Custom"
}
},
"required": ["data", "timestamp", "type"],
"type": "object"
},
{
"additionalProperties": false,
"properties": {
"data": {},
"delay": {
"type": "number"
},
"timestamp": {
"type": "number"
},
"type": {
"$ref": "#/definitions/EventType.IncrementalSnapshot"
}
},
"required": ["data", "timestamp", "type"],
"type": "object"
},
{
"additionalProperties": false,
"properties": {
"data": {
"$ref": "#/definitions/MobileNodeMutationData",
"description": "This sits alongside the RRWeb incremental snapshot event type, mobile replay can send any of the RRWeb incremental snapshot event types, which will be passed unchanged to the player - for example to send touch events. removed node mutations are passed unchanged to the player."
},
"delay": {
"type": "number"
},
"timestamp": {
"type": "number"
},
"type": {
"$ref": "#/definitions/EventType.IncrementalSnapshot"
}
},
"required": ["data", "timestamp", "type"],
"type": "object"
},
{
"additionalProperties": false,
"properties": {
"data": {
"additionalProperties": false,
"properties": {
"payload": {
"anyOf": [
{
"additionalProperties": false,
"properties": {
"height": {
"type": "number"
},
"open": {
"const": true,
"type": "boolean"
},
"styles": {
"$ref": "#/definitions/MobileStyles"
},
"width": {
"type": "number"
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present then the keyboard is at the bottom of the screen",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["open", "height"],
"type": "object"
},
{
"additionalProperties": false,
"properties": {
"open": {
"const": false,
"type": "boolean"
}
},
"required": ["open"],
"type": "object"
}
]
},
"tag": {
"const": "keyboard",
"type": "string"
}
},
"required": ["tag", "payload"],
"type": "object"
},
"delay": {
"type": "number"
},
"timestamp": {
"type": "number"
},
"type": {
"$ref": "#/definitions/EventType.Custom"
}
},
"required": ["data", "timestamp", "type"],
"type": "object"
}
],
"definitions": {
"EventType.Custom": {
"const": 5,
"type": "number"
},
"EventType.FullSnapshot": {
"const": 2,
"type": "number"
},
"EventType.IncrementalSnapshot": {
"const": 3,
"type": "number"
},
"EventType.Meta": {
"const": 4,
"type": "number"
},
"IncrementalSource.Mutation": {
"const": 0,
"type": "number"
},
"MobileNodeMutation": {
"additionalProperties": false,
"properties": {
"parentId": {
"type": "number"
},
"wireframe": {
"$ref": "#/definitions/wireframe"
}
},
"required": ["parentId", "wireframe"],
"type": "object"
},
"MobileNodeMutationData": {
"additionalProperties": false,
"properties": {
"adds": {
"items": {
"$ref": "#/definitions/MobileNodeMutation"
},
"type": "array"
},
"removes": {
"description": "A mobile remove is identical to a web remove",
"items": {
"$ref": "#/definitions/removedNodeMutation"
},
"type": "array"
},
"source": {
"$ref": "#/definitions/IncrementalSource.Mutation"
},
"updates": {
"description": "An update is implemented as a remove and then an add, so the updates array contains the ID of the removed node and the wireframe for the added node",
"items": {
"$ref": "#/definitions/MobileNodeMutation"
},
"type": "array"
}
},
"required": ["source"],
"type": "object"
},
"MobileNodeType": {
"enum": [
"text",
"image",
"screenshot",
"rectangle",
"placeholder",
"web_view",
"input",
"div",
"radio_group",
"status_bar",
"navigation_bar"
],
"type": "string"
},
"MobileStyles": {
"additionalProperties": false,
"properties": {
"backgroundColor": {
"description": "maps to CSS background-color. Accepts any valid CSS color value. Expects a #RGB value e.g. #000 or #000000",
"type": "string"
},
"backgroundImage": {
"description": "if provided this will be used as a base64 encoded image source for the backgroundImage css property, with no other attributes it is assumed to be a PNG",
"type": "string"
},
"backgroundSize": {
"description": "can be used alongside the background image property to specify how the image is rendered. Accepts a subset of the valid values for CSS background-size property. If not provided (and backgroundImage is present) defaults to 'auto'",
"enum": ["contain", "cover", "auto"],
"type": "string"
},
"borderColor": {
"description": "if borderColor is present, then border style is assumed to be solid",
"type": "string"
},
"borderRadius": {
"description": "if borderRadius is present, then border style is assumed to be solid",
"type": ["string", "number"]
},
"borderWidth": {
"description": "if borderWidth is present, then border style is assumed to be solid",
"type": ["string", "number"]
},
"color": {
"description": "maps to CSS color. Accepts any valid CSS color value. Expects a #RGB value e.g. #000 or #000000",
"type": "string"
},
"fontFamily": {
"description": "maps to CSS font-family. Accepts any valid CSS font-family value.",
"type": "string"
},
"fontSize": {
"description": "maps to CSS font-size. Accepts any valid CSS font-size value. Expects a number (treated as pixels) or a string that is a number followed by px e.g. 16px",
"type": ["string", "number"]
},
"horizontalAlign": {
"description": "horizontal alignment with respect to its parent",
"enum": ["left", "right", "center"],
"type": "string"
},
"paddingBottom": {
"description": "maps to CSS padding-bottom. Expects a number (treated as pixels) or a string that is a number followed by px e.g. 16px",
"type": ["string", "number"]
},
"paddingLeft": {
"description": "maps to CSS padding-left. Expects a number (treated as pixels) or a string that is a number followed by px e.g. 16px",
"type": ["string", "number"]
},
"paddingRight": {
"description": "maps to CSS padding-right. Expects a number (treated as pixels) or a string that is a number followed by px e.g. 16px",
"type": ["string", "number"]
},
"paddingTop": {
"description": "maps to CSS padding-top. Expects a number (treated as pixels) or a string that is a number followed by px e.g. 16px",
"type": ["string", "number"]
},
"verticalAlign": {
"description": "vertical alignment with respect to its parent",
"enum": ["top", "bottom", "center"],
"type": "string"
}
},
"type": "object"
},
"removedNodeMutation": {
"additionalProperties": false,
"properties": {
"id": {
"type": "number"
},
"isShadow": {
"type": "boolean"
},
"parentId": {
"type": "number"
}
},
"required": ["parentId", "id"],
"type": "object"
},
"wireframe": {
"anyOf": [
{
"$ref": "#/definitions/wireframeText"
},
{
"$ref": "#/definitions/wireframeImage"
},
{
"$ref": "#/definitions/wireframeScreenshot"
},
{
"$ref": "#/definitions/wireframeRectangle"
},
{
"$ref": "#/definitions/wireframeDiv"
},
{
"$ref": "#/definitions/wireframeInputComponent"
},
{
"$ref": "#/definitions/wireframeRadioGroup"
},
{
"$ref": "#/definitions/wireframeWebView"
},
{
"$ref": "#/definitions/wireframePlaceholder"
},
{
"$ref": "#/definitions/wireframeStatusBar"
},
{
"$ref": "#/definitions/wireframeNavigationBar"
}
]
},
"wireframeButton": {
"additionalProperties": false,
"properties": {
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"disabled": {
"description": "for several attributes we technically only care about true or absent as values. They are represented as bare attributes in HTML <input disabled>. When true that attribute is added to the HTML element, when absent that attribute is not added to the HTML element. When false or absent they are not added to the element.",
"type": "boolean"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"inputType": {
"const": "button",
"type": "string"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"value": {
"description": "this is the text that is displayed on the button, if not sent then you must send childNodes with the button content",
"type": "string"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["disabled", "height", "id", "inputType", "type", "width"],
"type": "object"
},
"wireframeCheckBox": {
"additionalProperties": false,
"properties": {
"checked": {
"description": "for several attributes we technically only care about true or absent as values. They are represented as bare attributes in HTML <input checked>. When true that attribute is added to the HTML element, when absent that attribute is not added to the HTML element. When false or absent they are not added to the element.",
"type": "boolean"
},
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"disabled": {
"description": "for several attributes we technically only care about true or absent as values. They are represented as bare attributes in HTML <input disabled>. When true that attribute is added to the HTML element, when absent that attribute is not added to the HTML element. When false or absent they are not added to the element.",
"type": "boolean"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"inputType": {
"const": "checkbox",
"type": "string"
},
"label": {
"type": "string"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["checked", "disabled", "height", "id", "inputType", "type", "width"],
"type": "object"
},
"wireframeDiv": {
"additionalProperties": false,
"properties": {
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["height", "id", "type", "width"],
"type": "object"
},
"wireframeImage": {
"additionalProperties": false,
"properties": {
"base64": {
"description": "this will be used as base64 encoded image source, with no other attributes it is assumed to be a PNG, if omitted a placeholder is rendered",
"type": "string"
},
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["height", "id", "type", "width"],
"type": "object"
},
"wireframeInput": {
"additionalProperties": false,
"properties": {
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"disabled": {
"description": "for several attributes we technically only care about true or absent as values. They are represented as bare attributes in HTML <input disabled>. When true that attribute is added to the HTML element, when absent that attribute is not added to the HTML element. When false or absent they are not added to the element.",
"type": "boolean"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"inputType": {
"enum": ["text", "password", "email", "number", "search", "tel", "url"],
"type": "string"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"value": {
"type": "string"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["disabled", "height", "id", "inputType", "type", "width"],
"type": "object"
},
"wireframeInputComponent": {
"anyOf": [
{
"$ref": "#/definitions/wireframeCheckBox"
},
{
"$ref": "#/definitions/wireframeRadio"
},
{
"$ref": "#/definitions/wireframeInput"
},
{
"$ref": "#/definitions/wireframeSelect"
},
{
"$ref": "#/definitions/wireframeTextArea"
},
{
"$ref": "#/definitions/wireframeButton"
},
{
"$ref": "#/definitions/wireframeProgress"
},
{
"$ref": "#/definitions/wireframeToggle"
}
]
},
"wireframeNavigationBar": {
"additionalProperties": false,
"description": "the navigation bar respects styling and positioning, but it is expected to be at the bottom of the screen with limited styling and no child elements",
"properties": {
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["height", "id", "type", "width"],
"type": "object"
},
"wireframePlaceholder": {
"additionalProperties": false,
"properties": {
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"label": {
"type": "string"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["height", "id", "type", "width"],
"type": "object"
},
"wireframeProgress": {
"additionalProperties": false,
"properties": {
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"disabled": {
"description": "for several attributes we technically only care about true or absent as values. They are represented as bare attributes in HTML <input disabled>. When true that attribute is added to the HTML element, when absent that attribute is not added to the HTML element. When false or absent they are not added to the element.",
"type": "boolean"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"inputType": {
"const": "progress",
"type": "string"
},
"max": {
"description": "The max attribute, if present, must have a value greater than 0 and be a valid floating point number. The default value is 1. When bar style is rating this is the number of stars.",
"type": "number"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"value": {
"description": "This attribute specifies how much of the task that has been completed. It must be a valid floating point number between 0 and max, or between 0 and 1 if max is omitted. If there is no value attribute, the progress bar is indeterminate; this indicates that an activity is ongoing with no indication of how long it is expected to take. When bar style is rating this is the number of filled stars.",
"type": "number"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["disabled", "height", "id", "inputType", "type", "width"],
"type": "object"
},
"wireframeRadio": {
"additionalProperties": false,
"properties": {
"checked": {
"description": "for several attributes we technically only care about true or absent as values. They are represented as bare attributes in HTML <input checked>. When true that attribute is added to the HTML element, when absent that attribute is not added to the HTML element. When false or absent they are not added to the element.",
"type": "boolean"
},
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"disabled": {
"description": "for several attributes we technically only care about true or absent as values. They are represented as bare attributes in HTML <input disabled>. When true that attribute is added to the HTML element, when absent that attribute is not added to the HTML element. When false or absent they are not added to the element.",
"type": "boolean"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"inputType": {
"const": "radio",
"type": "string"
},
"label": {
"type": "string"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["checked", "disabled", "height", "id", "inputType", "type", "width"],
"type": "object"
},
"wireframeRadioGroup": {
"additionalProperties": false,
"properties": {
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["height", "id", "type", "width"],
"type": "object"
},
"wireframeRectangle": {
"additionalProperties": false,
"properties": {
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["height", "id", "type", "width"],
"type": "object"
},
"wireframeScreenshot": {
"additionalProperties": false,
"description": "a screenshot behaves exactly like an image, but it is expected to be a screenshot of the screen at the time of the event, when sent as a mutation it must always attached to the root of the playback, when sent as an initial snapshot it must be sent as the first or only snapshot so that it attaches to the body of the playback",
"properties": {
"base64": {
"description": "this will be used as base64 encoded image source, with no other attributes it is assumed to be a PNG, if omitted a placeholder is rendered",
"type": "string"
},
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["height", "id", "type", "width"],
"type": "object"
},
"wireframeSelect": {
"additionalProperties": false,
"properties": {
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"disabled": {
"description": "for several attributes we technically only care about true or absent as values. They are represented as bare attributes in HTML <input disabled>. When true that attribute is added to the HTML element, when absent that attribute is not added to the HTML element. When false or absent they are not added to the element.",
"type": "boolean"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"inputType": {
"const": "select",
"type": "string"
},
"options": {
"items": {
"type": "string"
},
"type": "array"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"value": {
"type": "string"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["disabled", "height", "id", "inputType", "type", "width"],
"type": "object"
},
"wireframeStatusBar": {
"additionalProperties": false,
"description": "the status bar respects styling and positioning, but it is expected to be at the top of the screen with limited styling and no child elements",
"properties": {
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["height", "id", "type", "width"],
"type": "object"
},
"wireframeText": {
"additionalProperties": false,
"properties": {
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"text": {
"type": "string"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["height", "id", "text", "type", "width"],
"type": "object"
},
"wireframeTextArea": {
"additionalProperties": false,
"properties": {
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"disabled": {
"description": "for several attributes we technically only care about true or absent as values. They are represented as bare attributes in HTML <input disabled>. When true that attribute is added to the HTML element, when absent that attribute is not added to the HTML element. When false or absent they are not added to the element.",
"type": "boolean"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"inputType": {
"const": "text_area",
"type": "string"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"value": {
"type": "string"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["disabled", "height", "id", "inputType", "type", "width"],
"type": "object"
},
"wireframeToggle": {
"additionalProperties": false,
"properties": {
"checked": {
"type": "boolean"
},
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"disabled": {
"description": "for several attributes we technically only care about true or absent as values. They are represented as bare attributes in HTML <input disabled>. When true that attribute is added to the HTML element, when absent that attribute is not added to the HTML element. When false or absent they are not added to the element.",
"type": "boolean"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"inputType": {
"const": "toggle",
"type": "string"
},
"label": {
"type": "string"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["checked", "disabled", "height", "id", "inputType", "type", "width"],
"type": "object"
},
"wireframeWebView": {
"additionalProperties": false,
"properties": {
"childWireframes": {
"items": {
"$ref": "#/definitions/wireframe"
},
"type": "array"
},
"height": {
"type": "number"
},
"id": {
"type": "number"
},
"style": {
"$ref": "#/definitions/MobileStyles"
},
"type": {
"$ref": "#/definitions/MobileNodeType"
},
"url": {
"type": "string"
},
"width": {
"anyOf": [
{
"type": "number"
},
{
"const": "100vw",
"type": "string"
}
]
},
"x": {
"description": "x and y are the top left corner of the element, if they are present then the element is absolutely positioned, if they are not present this is equivalent to setting them to 0",
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["height", "id", "type", "width"],
"type": "object"
}
}
}