Skip to main content

Variable: patchMessageSchema

const patchMessageSchema: object

Defined in: src/lib/messages/schema.ts:104

JSON schema for a patch message

Type Declaration​

$id​

readonly $id: "paintcanvas/message/patch" = "paintcanvas/message/patch"

additionalProperties​

readonly additionalProperties: false = false

properties​

readonly properties: object

properties.coords​

readonly coords: object

properties.coords.items​

readonly items: object = coordinate

properties.coords.items.maximum​

readonly maximum: 10000 = MAX_MESSAGE_CANVAS_SIZE

properties.coords.items.minimum​

readonly minimum: 0 = 0

properties.coords.items.type​

readonly type: "integer" = "integer"

properties.coords.maxItems​

readonly maxItems: 4 = 4

properties.coords.minItems​

readonly minItems: 4 = 4

properties.coords.type​

readonly type: "array" = "array"

properties.data​

readonly data: object

properties.data.maxLength​

readonly maxLength: number = MAX_PATCH_DATA_LENGTH

properties.data.pattern​

readonly pattern: "^[A-Za-z0-9+/]*={0,2}$" = "^[A-Za-z0-9+/]*={0,2}$"

properties.data.type​

readonly type: "string" = "string"

properties.encoding​

readonly encoding: object

properties.encoding.enum​

readonly enum: ("rgba-deflate" | "png")[]

properties.protocol​

protocol: object

properties.protocol.const​

readonly const: 2 = PROTOCOL_VERSION

properties.type​

readonly type: object

properties.type.const​

readonly const: "patch" = CanvasMessageType.Patch

required​

readonly required: readonly ["protocol", "type", "coords", "encoding", "data"]

type​

readonly type: "object" = "object"