@baron1996/kline-scene-schema 0.2.3 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (85) hide show
  1. package/dist/decimal-normalization.d.ts +6 -0
  2. package/dist/decimal-normalization.d.ts.map +1 -0
  3. package/dist/decimal-normalization.js +47 -0
  4. package/dist/drawable-workspace-canonical-json.d.ts +3 -0
  5. package/dist/drawable-workspace-canonical-json.d.ts.map +1 -0
  6. package/dist/drawable-workspace-canonical-json.js +15 -0
  7. package/dist/drawable-workspace-canonicalize.d.ts +3 -0
  8. package/dist/drawable-workspace-canonicalize.d.ts.map +1 -0
  9. package/dist/drawable-workspace-canonicalize.js +19 -0
  10. package/dist/drawable-workspace-errors.d.ts +14 -0
  11. package/dist/drawable-workspace-errors.d.ts.map +1 -0
  12. package/dist/drawable-workspace-errors.js +12 -0
  13. package/dist/drawable-workspace-semantic-validator.d.ts +5 -0
  14. package/dist/drawable-workspace-semantic-validator.d.ts.map +1 -0
  15. package/dist/drawable-workspace-semantic-validator.js +127 -0
  16. package/dist/drawable-workspace-validator.d.ts +4 -0
  17. package/dist/drawable-workspace-validator.d.ts.map +1 -0
  18. package/dist/drawable-workspace-validator.js +74 -0
  19. package/dist/drawing-canonical-json.d.ts +3 -0
  20. package/dist/drawing-canonical-json.d.ts.map +1 -0
  21. package/dist/drawing-canonical-json.js +15 -0
  22. package/dist/drawing-canonicalize.d.ts +3 -0
  23. package/dist/drawing-canonicalize.d.ts.map +1 -0
  24. package/dist/drawing-canonicalize.js +19 -0
  25. package/dist/drawing-errors.d.ts +13 -0
  26. package/dist/drawing-errors.d.ts.map +1 -0
  27. package/dist/drawing-errors.js +12 -0
  28. package/dist/drawing-semantic-validator.d.ts +6 -0
  29. package/dist/drawing-semantic-validator.d.ts.map +1 -0
  30. package/dist/drawing-semantic-validator.js +123 -0
  31. package/dist/drawing-validator.d.ts +4 -0
  32. package/dist/drawing-validator.d.ts.map +1 -0
  33. package/dist/drawing-validator.js +66 -0
  34. package/dist/generated/chart-scene.d.ts +11 -1
  35. package/dist/generated/chart-scene.d.ts.map +1 -1
  36. package/dist/generated/drawable-workspace.d.ts +526 -0
  37. package/dist/generated/drawable-workspace.d.ts.map +1 -0
  38. package/dist/generated/drawable-workspace.js +2 -0
  39. package/dist/generated/drawing-document.d.ts +216 -0
  40. package/dist/generated/drawing-document.d.ts.map +1 -0
  41. package/dist/generated/drawing-document.js +2 -0
  42. package/dist/generated/schemas.d.ts +1062 -17
  43. package/dist/generated/schemas.d.ts.map +1 -1
  44. package/dist/generated/schemas.js +1391 -28
  45. package/dist/generated/time-series-scene.d.ts +88 -0
  46. package/dist/generated/time-series-scene.d.ts.map +1 -0
  47. package/dist/generated/time-series-scene.js +2 -0
  48. package/dist/generated/validate-chart-scene.d.ts.map +1 -1
  49. package/dist/generated/validate-chart-scene.js +550 -237
  50. package/dist/generated/validate-drawable-workspace.d.ts +15 -0
  51. package/dist/generated/validate-drawable-workspace.d.ts.map +1 -0
  52. package/dist/generated/validate-drawable-workspace.js +13449 -0
  53. package/dist/generated/validate-drawing-document.d.ts +15 -0
  54. package/dist/generated/validate-drawing-document.d.ts.map +1 -0
  55. package/dist/generated/validate-drawing-document.js +4307 -0
  56. package/dist/generated/validate-time-series-scene.d.ts +15 -0
  57. package/dist/generated/validate-time-series-scene.d.ts.map +1 -0
  58. package/dist/generated/validate-time-series-scene.js +2359 -0
  59. package/dist/index.d.ts +20 -1
  60. package/dist/index.d.ts.map +1 -1
  61. package/dist/index.js +19 -1
  62. package/dist/time-series-canonical-json.d.ts +3 -0
  63. package/dist/time-series-canonical-json.d.ts.map +1 -0
  64. package/dist/time-series-canonical-json.js +15 -0
  65. package/dist/time-series-canonicalize.d.ts +3 -0
  66. package/dist/time-series-canonicalize.d.ts.map +1 -0
  67. package/dist/time-series-canonicalize.js +19 -0
  68. package/dist/time-series-errors.d.ts +13 -0
  69. package/dist/time-series-errors.d.ts.map +1 -0
  70. package/dist/time-series-errors.js +12 -0
  71. package/dist/time-series-semantic-validator.d.ts +5 -0
  72. package/dist/time-series-semantic-validator.d.ts.map +1 -0
  73. package/dist/time-series-semantic-validator.js +81 -0
  74. package/dist/time-series-validator.d.ts +4 -0
  75. package/dist/time-series-validator.d.ts.map +1 -0
  76. package/dist/time-series-validator.js +52 -0
  77. package/package.json +1 -1
  78. package/schema/chart-config.schema.json +68 -1
  79. package/schema/chart-scene.schema.json +1 -27
  80. package/schema/common.schema.json +26 -0
  81. package/schema/drawable-workspace.schema.json +110 -0
  82. package/schema/drawing-document.schema.json +811 -0
  83. package/schema/time-series-chart-config.schema.json +75 -0
  84. package/schema/time-series-runtime.schema.json +13 -0
  85. package/schema/time-series-scene.schema.json +145 -0
@@ -0,0 +1,4307 @@
1
+ // @ts-nocheck -- generated standalone validator
2
+ "use strict";
3
+ export const validateDrawingDocument = validate20;
4
+ const schema31 = { "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://baron.dev/kline-scene/drawing-document.schema.json", "title": "DrawingDocument", "type": "object", "additionalProperties": false, "required": ["schema", "version", "scopeKey", "coordinateSystem", "drawings", "metadata"], "properties": { "schema": { "const": "@baron1996/drawing-document" }, "version": { "const": 1 }, "scopeKey": { "type": "string", "minLength": 1, "maxLength": 256 }, "coordinateSystem": { "$ref": "#/$defs/coordinateSystem" }, "drawings": { "type": "array", "maxItems": 10000, "items": { "$ref": "#/$defs/drawing" } }, "metadata": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/metadata" } }, "$defs": { "coordinateSystem": { "type": "object", "additionalProperties": false, "required": ["timezone", "valueAxes"], "properties": { "timezone": { "$ref": "#/$defs/timezone" }, "valueAxes": { "$ref": "#/$defs/valueAxes" } } }, "timezone": { "type": "string", "minLength": 1, "maxLength": 128, "pattern": "^[A-Za-z_+-]+(?:/[A-Za-z0-9_+-]+)*$" }, "valueAxes": { "type": "array", "minItems": 1, "maxItems": 64, "items": { "$ref": "#/$defs/valueAxis" } }, "valueAxis": { "type": "object", "additionalProperties": false, "required": ["paneRole", "yAxisRole", "valuePrecision"], "properties": { "paneRole": { "type": "string", "minLength": 1, "maxLength": 128 }, "yAxisRole": { "type": "string", "minLength": 1, "maxLength": 128 }, "valuePrecision": { "type": "integer", "minimum": 0, "maximum": 16 } } }, "target": { "type": "object", "additionalProperties": false, "required": ["paneRole", "yAxisRole"], "properties": { "paneRole": { "type": "string", "minLength": 1, "maxLength": 128 }, "yAxisRole": { "type": "string", "minLength": 1, "maxLength": 128 } } }, "drawingStyles": { "type": "object", "additionalProperties": false, "required": ["line", "fill", "text"], "properties": { "line": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/lineStyle" }, "fill": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/fillStyle" }, "text": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/textStyle" } } }, "drawingBase": { "type": "object", "additionalProperties": false, "required": ["id", "target", "visible", "locked", "zLevel", "mode", "styles"], "properties": { "id": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/stableId" }, "groupId": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/stableId" }, "target": { "$ref": "#/$defs/target" }, "visible": { "type": "boolean" }, "locked": { "type": "boolean" }, "zLevel": { "type": "integer", "minimum": -1000, "maximum": 1000 }, "mode": { "enum": ["normal", "weak_magnet", "strong_magnet"] }, "styles": { "$ref": "#/$defs/drawingStyles" }, "metadata": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/metadata" } } }, "drawingTimeAnchor": { "type": "object", "additionalProperties": false, "required": ["timestamp", "granularity"], "properties": { "timestamp": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger" }, "granularity": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/period" } } }, "timeValuePoint": { "type": "object", "additionalProperties": false, "required": ["timestamp", "granularity", "value"], "properties": { "timestamp": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger" }, "granularity": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/period" }, "value": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber" } } }, "geometryValue": { "type": "object", "additionalProperties": false, "required": ["value"], "properties": { "value": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber" } } }, "geometryValueText": { "type": "object", "additionalProperties": false, "required": ["value", "text"], "properties": { "value": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber" }, "text": { "type": "string", "maxLength": 4096 } } }, "geometryTime": { "type": "object", "additionalProperties": false, "required": ["time"], "properties": { "time": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger" } } }, "geometryValueSpan": { "type": "object", "additionalProperties": false, "required": ["value", "startTime", "endTime"], "properties": { "value": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber" }, "startTime": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger" }, "endTime": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger" } } }, "geometryTimeSpan": { "type": "object", "additionalProperties": false, "required": ["time", "startValue", "endValue"], "properties": { "time": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger" }, "startValue": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber" }, "endValue": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber" } } }, "geometryTwoPoints": { "type": "object", "additionalProperties": false, "required": ["points"], "properties": { "points": { "type": "array", "minItems": 2, "maxItems": 2, "items": { "$ref": "#/$defs/timeValuePoint" } } } }, "geometryThreePoints": { "type": "object", "additionalProperties": false, "required": ["points"], "properties": { "points": { "type": "array", "minItems": 3, "maxItems": 3, "items": { "$ref": "#/$defs/timeValuePoint" } } } }, "geometryBrushPoints": { "type": "object", "additionalProperties": false, "required": ["points"], "properties": { "points": { "type": "array", "minItems": 2, "maxItems": 256, "items": { "$ref": "#/$defs/timeValuePoint" } } } }, "geometryPointText": { "type": "object", "additionalProperties": false, "required": ["point", "text"], "properties": { "point": { "$ref": "#/$defs/timeValuePoint" }, "text": { "type": "string", "maxLength": 4096 } } }, "geometryPoint": { "type": "object", "additionalProperties": false, "required": ["point"], "properties": { "point": { "$ref": "#/$defs/timeValuePoint" } } }, "geometryStartEnd": { "type": "object", "additionalProperties": false, "required": ["start", "end"], "properties": { "start": { "$ref": "#/$defs/timeValuePoint" }, "end": { "$ref": "#/$defs/timeValuePoint" } } }, "drawing": { "type": "object", "additionalProperties": false, "required": ["id", "target", "visible", "locked", "zLevel", "mode", "styles", "type", "geometry"], "properties": { "id": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/stableId" }, "groupId": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/stableId" }, "target": { "$ref": "#/$defs/target" }, "visible": { "type": "boolean" }, "locked": { "type": "boolean" }, "zLevel": { "type": "integer", "minimum": -1000, "maximum": 1000 }, "mode": { "enum": ["normal", "weak_magnet", "strong_magnet"] }, "styles": { "$ref": "#/$defs/drawingStyles" }, "metadata": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/metadata" }, "type": { "enum": ["horizontalStraightLine", "priceLine", "simpleTag", "verticalStraightLine", "horizontalRayLine", "horizontalSegment", "verticalRayLine", "verticalSegment", "rayLine", "segment", "straightLine", "fibonacciLine", "priceChannelLine", "parallelStraightLine", "brush", "simpleAnnotation", "callout", "text", "crossLine", "rectangle", "arrow", "priceMeasurement"] }, "geometry": { "type": "object" } }, "oneOf": [{ "title": "DrawingHorizontalStraightLine", "properties": { "type": { "const": "horizontalStraightLine" }, "geometry": { "$ref": "#/$defs/geometryValue" } }, "required": ["type", "geometry"] }, { "title": "DrawingPriceLine", "properties": { "type": { "const": "priceLine" }, "geometry": { "$ref": "#/$defs/geometryValue" } }, "required": ["type", "geometry"] }, { "title": "DrawingSimpleTag", "properties": { "type": { "const": "simpleTag" }, "geometry": { "$ref": "#/$defs/geometryValueText" } }, "required": ["type", "geometry"] }, { "title": "DrawingVerticalStraightLine", "properties": { "type": { "const": "verticalStraightLine" }, "geometry": { "$ref": "#/$defs/geometryTime" } }, "required": ["type", "geometry"] }, { "title": "DrawingHorizontalRayLine", "properties": { "type": { "const": "horizontalRayLine" }, "geometry": { "$ref": "#/$defs/geometryValueSpan" } }, "required": ["type", "geometry"] }, { "title": "DrawingHorizontalSegment", "properties": { "type": { "const": "horizontalSegment" }, "geometry": { "$ref": "#/$defs/geometryValueSpan" } }, "required": ["type", "geometry"] }, { "title": "DrawingVerticalRayLine", "properties": { "type": { "const": "verticalRayLine" }, "geometry": { "$ref": "#/$defs/geometryTimeSpan" } }, "required": ["type", "geometry"] }, { "title": "DrawingVerticalSegment", "properties": { "type": { "const": "verticalSegment" }, "geometry": { "$ref": "#/$defs/geometryTimeSpan" } }, "required": ["type", "geometry"] }, { "title": "DrawingRayLine", "properties": { "type": { "const": "rayLine" }, "geometry": { "$ref": "#/$defs/geometryTwoPoints" } }, "required": ["type", "geometry"] }, { "title": "DrawingSegment", "properties": { "type": { "const": "segment" }, "geometry": { "$ref": "#/$defs/geometryTwoPoints" } }, "required": ["type", "geometry"] }, { "title": "DrawingStraightLine", "properties": { "type": { "const": "straightLine" }, "geometry": { "$ref": "#/$defs/geometryTwoPoints" } }, "required": ["type", "geometry"] }, { "title": "DrawingFibonacciLine", "properties": { "type": { "const": "fibonacciLine" }, "geometry": { "$ref": "#/$defs/geometryTwoPoints" } }, "required": ["type", "geometry"] }, { "title": "DrawingPriceChannelLine", "properties": { "type": { "const": "priceChannelLine" }, "geometry": { "$ref": "#/$defs/geometryThreePoints" } }, "required": ["type", "geometry"] }, { "title": "DrawingParallelStraightLine", "properties": { "type": { "const": "parallelStraightLine" }, "geometry": { "$ref": "#/$defs/geometryThreePoints" } }, "required": ["type", "geometry"] }, { "title": "DrawingBrush", "properties": { "type": { "const": "brush" }, "geometry": { "$ref": "#/$defs/geometryBrushPoints" } }, "required": ["type", "geometry"] }, { "title": "DrawingSimpleAnnotation", "properties": { "type": { "const": "simpleAnnotation" }, "geometry": { "$ref": "#/$defs/geometryPointText" } }, "required": ["type", "geometry"] }, { "title": "DrawingCallout", "properties": { "type": { "const": "callout" }, "geometry": { "$ref": "#/$defs/geometryPointText" } }, "required": ["type", "geometry"] }, { "title": "DrawingText", "properties": { "type": { "const": "text" }, "geometry": { "$ref": "#/$defs/geometryPointText" } }, "required": ["type", "geometry"] }, { "title": "DrawingCrossLine", "properties": { "type": { "const": "crossLine" }, "geometry": { "$ref": "#/$defs/geometryPoint" } }, "required": ["type", "geometry"] }, { "title": "DrawingRectangle", "properties": { "type": { "const": "rectangle" }, "geometry": { "$ref": "#/$defs/geometryStartEnd" } }, "required": ["type", "geometry"] }, { "title": "DrawingArrow", "properties": { "type": { "const": "arrow" }, "geometry": { "$ref": "#/$defs/geometryStartEnd" } }, "required": ["type", "geometry"] }, { "title": "DrawingPriceMeasurement", "properties": { "type": { "const": "priceMeasurement" }, "geometry": { "$ref": "#/$defs/geometryStartEnd" } }, "required": ["type", "geometry"] }] } } };
5
+ const func1 = (value) => { let length = 0; for (const _character of value)
6
+ length++; return length; };
7
+ const schema32 = { "type": "object", "additionalProperties": false, "required": ["timezone", "valueAxes"], "properties": { "timezone": { "$ref": "#/$defs/timezone" }, "valueAxes": { "$ref": "#/$defs/valueAxes" } } };
8
+ const schema33 = { "type": "string", "minLength": 1, "maxLength": 128, "pattern": "^[A-Za-z_+-]+(?:/[A-Za-z0-9_+-]+)*$" };
9
+ const pattern4 = new RegExp("^[A-Za-z_+-]+(?:/[A-Za-z0-9_+-]+)*$", "u");
10
+ const schema34 = { "type": "array", "minItems": 1, "maxItems": 64, "items": { "$ref": "#/$defs/valueAxis" } };
11
+ const schema35 = { "type": "object", "additionalProperties": false, "required": ["paneRole", "yAxisRole", "valuePrecision"], "properties": { "paneRole": { "type": "string", "minLength": 1, "maxLength": 128 }, "yAxisRole": { "type": "string", "minLength": 1, "maxLength": 128 }, "valuePrecision": { "type": "integer", "minimum": 0, "maximum": 16 } } };
12
+ function validate22(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate22.evaluated; if (evaluated0.dynamicProps) {
13
+ evaluated0.props = undefined;
14
+ } if (evaluated0.dynamicItems) {
15
+ evaluated0.items = undefined;
16
+ } if (Array.isArray(data)) {
17
+ if (data.length > 64) {
18
+ const err0 = { instancePath, schemaPath: "#/maxItems", keyword: "maxItems", params: { limit: 64 }, message: "must NOT have more than 64 items" };
19
+ if (vErrors === null) {
20
+ vErrors = [err0];
21
+ }
22
+ else {
23
+ vErrors.push(err0);
24
+ }
25
+ errors++;
26
+ }
27
+ if (data.length < 1) {
28
+ const err1 = { instancePath, schemaPath: "#/minItems", keyword: "minItems", params: { limit: 1 }, message: "must NOT have fewer than 1 items" };
29
+ if (vErrors === null) {
30
+ vErrors = [err1];
31
+ }
32
+ else {
33
+ vErrors.push(err1);
34
+ }
35
+ errors++;
36
+ }
37
+ const len0 = data.length;
38
+ for (let i0 = 0; i0 < len0; i0++) {
39
+ let data0 = data[i0];
40
+ if (data0 && typeof data0 == "object" && !Array.isArray(data0)) {
41
+ if (data0.paneRole === undefined) {
42
+ const err2 = { instancePath: instancePath + "/" + i0, schemaPath: "#/$defs/valueAxis/required", keyword: "required", params: { missingProperty: "paneRole" }, message: "must have required property '" + "paneRole" + "'" };
43
+ if (vErrors === null) {
44
+ vErrors = [err2];
45
+ }
46
+ else {
47
+ vErrors.push(err2);
48
+ }
49
+ errors++;
50
+ }
51
+ if (data0.yAxisRole === undefined) {
52
+ const err3 = { instancePath: instancePath + "/" + i0, schemaPath: "#/$defs/valueAxis/required", keyword: "required", params: { missingProperty: "yAxisRole" }, message: "must have required property '" + "yAxisRole" + "'" };
53
+ if (vErrors === null) {
54
+ vErrors = [err3];
55
+ }
56
+ else {
57
+ vErrors.push(err3);
58
+ }
59
+ errors++;
60
+ }
61
+ if (data0.valuePrecision === undefined) {
62
+ const err4 = { instancePath: instancePath + "/" + i0, schemaPath: "#/$defs/valueAxis/required", keyword: "required", params: { missingProperty: "valuePrecision" }, message: "must have required property '" + "valuePrecision" + "'" };
63
+ if (vErrors === null) {
64
+ vErrors = [err4];
65
+ }
66
+ else {
67
+ vErrors.push(err4);
68
+ }
69
+ errors++;
70
+ }
71
+ for (const key0 in data0) {
72
+ if (!(((key0 === "paneRole") || (key0 === "yAxisRole")) || (key0 === "valuePrecision"))) {
73
+ const err5 = { instancePath: instancePath + "/" + i0, schemaPath: "#/$defs/valueAxis/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
74
+ if (vErrors === null) {
75
+ vErrors = [err5];
76
+ }
77
+ else {
78
+ vErrors.push(err5);
79
+ }
80
+ errors++;
81
+ }
82
+ }
83
+ if (data0.paneRole !== undefined) {
84
+ let data1 = data0.paneRole;
85
+ if (typeof data1 === "string") {
86
+ if (func1(data1) > 128) {
87
+ const err6 = { instancePath: instancePath + "/" + i0 + "/paneRole", schemaPath: "#/$defs/valueAxis/properties/paneRole/maxLength", keyword: "maxLength", params: { limit: 128 }, message: "must NOT have more than 128 characters" };
88
+ if (vErrors === null) {
89
+ vErrors = [err6];
90
+ }
91
+ else {
92
+ vErrors.push(err6);
93
+ }
94
+ errors++;
95
+ }
96
+ if (func1(data1) < 1) {
97
+ const err7 = { instancePath: instancePath + "/" + i0 + "/paneRole", schemaPath: "#/$defs/valueAxis/properties/paneRole/minLength", keyword: "minLength", params: { limit: 1 }, message: "must NOT have fewer than 1 characters" };
98
+ if (vErrors === null) {
99
+ vErrors = [err7];
100
+ }
101
+ else {
102
+ vErrors.push(err7);
103
+ }
104
+ errors++;
105
+ }
106
+ }
107
+ else {
108
+ const err8 = { instancePath: instancePath + "/" + i0 + "/paneRole", schemaPath: "#/$defs/valueAxis/properties/paneRole/type", keyword: "type", params: { type: "string" }, message: "must be string" };
109
+ if (vErrors === null) {
110
+ vErrors = [err8];
111
+ }
112
+ else {
113
+ vErrors.push(err8);
114
+ }
115
+ errors++;
116
+ }
117
+ }
118
+ if (data0.yAxisRole !== undefined) {
119
+ let data2 = data0.yAxisRole;
120
+ if (typeof data2 === "string") {
121
+ if (func1(data2) > 128) {
122
+ const err9 = { instancePath: instancePath + "/" + i0 + "/yAxisRole", schemaPath: "#/$defs/valueAxis/properties/yAxisRole/maxLength", keyword: "maxLength", params: { limit: 128 }, message: "must NOT have more than 128 characters" };
123
+ if (vErrors === null) {
124
+ vErrors = [err9];
125
+ }
126
+ else {
127
+ vErrors.push(err9);
128
+ }
129
+ errors++;
130
+ }
131
+ if (func1(data2) < 1) {
132
+ const err10 = { instancePath: instancePath + "/" + i0 + "/yAxisRole", schemaPath: "#/$defs/valueAxis/properties/yAxisRole/minLength", keyword: "minLength", params: { limit: 1 }, message: "must NOT have fewer than 1 characters" };
133
+ if (vErrors === null) {
134
+ vErrors = [err10];
135
+ }
136
+ else {
137
+ vErrors.push(err10);
138
+ }
139
+ errors++;
140
+ }
141
+ }
142
+ else {
143
+ const err11 = { instancePath: instancePath + "/" + i0 + "/yAxisRole", schemaPath: "#/$defs/valueAxis/properties/yAxisRole/type", keyword: "type", params: { type: "string" }, message: "must be string" };
144
+ if (vErrors === null) {
145
+ vErrors = [err11];
146
+ }
147
+ else {
148
+ vErrors.push(err11);
149
+ }
150
+ errors++;
151
+ }
152
+ }
153
+ if (data0.valuePrecision !== undefined) {
154
+ let data3 = data0.valuePrecision;
155
+ if (!(((typeof data3 == "number") && (!(data3 % 1) && !isNaN(data3))) && (isFinite(data3)))) {
156
+ const err12 = { instancePath: instancePath + "/" + i0 + "/valuePrecision", schemaPath: "#/$defs/valueAxis/properties/valuePrecision/type", keyword: "type", params: { type: "integer" }, message: "must be integer" };
157
+ if (vErrors === null) {
158
+ vErrors = [err12];
159
+ }
160
+ else {
161
+ vErrors.push(err12);
162
+ }
163
+ errors++;
164
+ }
165
+ if ((typeof data3 == "number") && (isFinite(data3))) {
166
+ if (data3 > 16 || isNaN(data3)) {
167
+ const err13 = { instancePath: instancePath + "/" + i0 + "/valuePrecision", schemaPath: "#/$defs/valueAxis/properties/valuePrecision/maximum", keyword: "maximum", params: { comparison: "<=", limit: 16 }, message: "must be <= 16" };
168
+ if (vErrors === null) {
169
+ vErrors = [err13];
170
+ }
171
+ else {
172
+ vErrors.push(err13);
173
+ }
174
+ errors++;
175
+ }
176
+ if (data3 < 0 || isNaN(data3)) {
177
+ const err14 = { instancePath: instancePath + "/" + i0 + "/valuePrecision", schemaPath: "#/$defs/valueAxis/properties/valuePrecision/minimum", keyword: "minimum", params: { comparison: ">=", limit: 0 }, message: "must be >= 0" };
178
+ if (vErrors === null) {
179
+ vErrors = [err14];
180
+ }
181
+ else {
182
+ vErrors.push(err14);
183
+ }
184
+ errors++;
185
+ }
186
+ }
187
+ }
188
+ }
189
+ else {
190
+ const err15 = { instancePath: instancePath + "/" + i0, schemaPath: "#/$defs/valueAxis/type", keyword: "type", params: { type: "object" }, message: "must be object" };
191
+ if (vErrors === null) {
192
+ vErrors = [err15];
193
+ }
194
+ else {
195
+ vErrors.push(err15);
196
+ }
197
+ errors++;
198
+ }
199
+ }
200
+ }
201
+ else {
202
+ const err16 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "array" }, message: "must be array" };
203
+ if (vErrors === null) {
204
+ vErrors = [err16];
205
+ }
206
+ else {
207
+ vErrors.push(err16);
208
+ }
209
+ errors++;
210
+ } validate22.errors = vErrors; return errors === 0; }
211
+ validate22.evaluated = { "items": true, "dynamicProps": false, "dynamicItems": false };
212
+ function validate21(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate21.evaluated; if (evaluated0.dynamicProps) {
213
+ evaluated0.props = undefined;
214
+ } if (evaluated0.dynamicItems) {
215
+ evaluated0.items = undefined;
216
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
217
+ if (data.timezone === undefined) {
218
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "timezone" }, message: "must have required property '" + "timezone" + "'" };
219
+ if (vErrors === null) {
220
+ vErrors = [err0];
221
+ }
222
+ else {
223
+ vErrors.push(err0);
224
+ }
225
+ errors++;
226
+ }
227
+ if (data.valueAxes === undefined) {
228
+ const err1 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "valueAxes" }, message: "must have required property '" + "valueAxes" + "'" };
229
+ if (vErrors === null) {
230
+ vErrors = [err1];
231
+ }
232
+ else {
233
+ vErrors.push(err1);
234
+ }
235
+ errors++;
236
+ }
237
+ for (const key0 in data) {
238
+ if (!((key0 === "timezone") || (key0 === "valueAxes"))) {
239
+ const err2 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
240
+ if (vErrors === null) {
241
+ vErrors = [err2];
242
+ }
243
+ else {
244
+ vErrors.push(err2);
245
+ }
246
+ errors++;
247
+ }
248
+ }
249
+ if (data.timezone !== undefined) {
250
+ let data0 = data.timezone;
251
+ if (typeof data0 === "string") {
252
+ if (func1(data0) > 128) {
253
+ const err3 = { instancePath: instancePath + "/timezone", schemaPath: "#/$defs/timezone/maxLength", keyword: "maxLength", params: { limit: 128 }, message: "must NOT have more than 128 characters" };
254
+ if (vErrors === null) {
255
+ vErrors = [err3];
256
+ }
257
+ else {
258
+ vErrors.push(err3);
259
+ }
260
+ errors++;
261
+ }
262
+ if (func1(data0) < 1) {
263
+ const err4 = { instancePath: instancePath + "/timezone", schemaPath: "#/$defs/timezone/minLength", keyword: "minLength", params: { limit: 1 }, message: "must NOT have fewer than 1 characters" };
264
+ if (vErrors === null) {
265
+ vErrors = [err4];
266
+ }
267
+ else {
268
+ vErrors.push(err4);
269
+ }
270
+ errors++;
271
+ }
272
+ if (!pattern4.test(data0)) {
273
+ const err5 = { instancePath: instancePath + "/timezone", schemaPath: "#/$defs/timezone/pattern", keyword: "pattern", params: { pattern: "^[A-Za-z_+-]+(?:/[A-Za-z0-9_+-]+)*$" }, message: "must match pattern \"" + "^[A-Za-z_+-]+(?:/[A-Za-z0-9_+-]+)*$" + "\"" };
274
+ if (vErrors === null) {
275
+ vErrors = [err5];
276
+ }
277
+ else {
278
+ vErrors.push(err5);
279
+ }
280
+ errors++;
281
+ }
282
+ }
283
+ else {
284
+ const err6 = { instancePath: instancePath + "/timezone", schemaPath: "#/$defs/timezone/type", keyword: "type", params: { type: "string" }, message: "must be string" };
285
+ if (vErrors === null) {
286
+ vErrors = [err6];
287
+ }
288
+ else {
289
+ vErrors.push(err6);
290
+ }
291
+ errors++;
292
+ }
293
+ }
294
+ if (data.valueAxes !== undefined) {
295
+ if (!(validate22(data.valueAxes, { instancePath: instancePath + "/valueAxes", parentData: data, parentDataProperty: "valueAxes", rootData, dynamicAnchors }))) {
296
+ vErrors = vErrors === null ? validate22.errors : vErrors.concat(validate22.errors);
297
+ errors = vErrors.length;
298
+ }
299
+ }
300
+ }
301
+ else {
302
+ const err7 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
303
+ if (vErrors === null) {
304
+ vErrors = [err7];
305
+ }
306
+ else {
307
+ vErrors.push(err7);
308
+ }
309
+ errors++;
310
+ } validate21.errors = vErrors; return errors === 0; }
311
+ validate21.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
312
+ const schema36 = { "type": "object", "additionalProperties": false, "required": ["id", "target", "visible", "locked", "zLevel", "mode", "styles", "type", "geometry"], "properties": { "id": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/stableId" }, "groupId": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/stableId" }, "target": { "$ref": "#/$defs/target" }, "visible": { "type": "boolean" }, "locked": { "type": "boolean" }, "zLevel": { "type": "integer", "minimum": -1000, "maximum": 1000 }, "mode": { "enum": ["normal", "weak_magnet", "strong_magnet"] }, "styles": { "$ref": "#/$defs/drawingStyles" }, "metadata": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/metadata" }, "type": { "enum": ["horizontalStraightLine", "priceLine", "simpleTag", "verticalStraightLine", "horizontalRayLine", "horizontalSegment", "verticalRayLine", "verticalSegment", "rayLine", "segment", "straightLine", "fibonacciLine", "priceChannelLine", "parallelStraightLine", "brush", "simpleAnnotation", "callout", "text", "crossLine", "rectangle", "arrow", "priceMeasurement"] }, "geometry": { "type": "object" } }, "oneOf": [{ "title": "DrawingHorizontalStraightLine", "properties": { "type": { "const": "horizontalStraightLine" }, "geometry": { "$ref": "#/$defs/geometryValue" } }, "required": ["type", "geometry"] }, { "title": "DrawingPriceLine", "properties": { "type": { "const": "priceLine" }, "geometry": { "$ref": "#/$defs/geometryValue" } }, "required": ["type", "geometry"] }, { "title": "DrawingSimpleTag", "properties": { "type": { "const": "simpleTag" }, "geometry": { "$ref": "#/$defs/geometryValueText" } }, "required": ["type", "geometry"] }, { "title": "DrawingVerticalStraightLine", "properties": { "type": { "const": "verticalStraightLine" }, "geometry": { "$ref": "#/$defs/geometryTime" } }, "required": ["type", "geometry"] }, { "title": "DrawingHorizontalRayLine", "properties": { "type": { "const": "horizontalRayLine" }, "geometry": { "$ref": "#/$defs/geometryValueSpan" } }, "required": ["type", "geometry"] }, { "title": "DrawingHorizontalSegment", "properties": { "type": { "const": "horizontalSegment" }, "geometry": { "$ref": "#/$defs/geometryValueSpan" } }, "required": ["type", "geometry"] }, { "title": "DrawingVerticalRayLine", "properties": { "type": { "const": "verticalRayLine" }, "geometry": { "$ref": "#/$defs/geometryTimeSpan" } }, "required": ["type", "geometry"] }, { "title": "DrawingVerticalSegment", "properties": { "type": { "const": "verticalSegment" }, "geometry": { "$ref": "#/$defs/geometryTimeSpan" } }, "required": ["type", "geometry"] }, { "title": "DrawingRayLine", "properties": { "type": { "const": "rayLine" }, "geometry": { "$ref": "#/$defs/geometryTwoPoints" } }, "required": ["type", "geometry"] }, { "title": "DrawingSegment", "properties": { "type": { "const": "segment" }, "geometry": { "$ref": "#/$defs/geometryTwoPoints" } }, "required": ["type", "geometry"] }, { "title": "DrawingStraightLine", "properties": { "type": { "const": "straightLine" }, "geometry": { "$ref": "#/$defs/geometryTwoPoints" } }, "required": ["type", "geometry"] }, { "title": "DrawingFibonacciLine", "properties": { "type": { "const": "fibonacciLine" }, "geometry": { "$ref": "#/$defs/geometryTwoPoints" } }, "required": ["type", "geometry"] }, { "title": "DrawingPriceChannelLine", "properties": { "type": { "const": "priceChannelLine" }, "geometry": { "$ref": "#/$defs/geometryThreePoints" } }, "required": ["type", "geometry"] }, { "title": "DrawingParallelStraightLine", "properties": { "type": { "const": "parallelStraightLine" }, "geometry": { "$ref": "#/$defs/geometryThreePoints" } }, "required": ["type", "geometry"] }, { "title": "DrawingBrush", "properties": { "type": { "const": "brush" }, "geometry": { "$ref": "#/$defs/geometryBrushPoints" } }, "required": ["type", "geometry"] }, { "title": "DrawingSimpleAnnotation", "properties": { "type": { "const": "simpleAnnotation" }, "geometry": { "$ref": "#/$defs/geometryPointText" } }, "required": ["type", "geometry"] }, { "title": "DrawingCallout", "properties": { "type": { "const": "callout" }, "geometry": { "$ref": "#/$defs/geometryPointText" } }, "required": ["type", "geometry"] }, { "title": "DrawingText", "properties": { "type": { "const": "text" }, "geometry": { "$ref": "#/$defs/geometryPointText" } }, "required": ["type", "geometry"] }, { "title": "DrawingCrossLine", "properties": { "type": { "const": "crossLine" }, "geometry": { "$ref": "#/$defs/geometryPoint" } }, "required": ["type", "geometry"] }, { "title": "DrawingRectangle", "properties": { "type": { "const": "rectangle" }, "geometry": { "$ref": "#/$defs/geometryStartEnd" } }, "required": ["type", "geometry"] }, { "title": "DrawingArrow", "properties": { "type": { "const": "arrow" }, "geometry": { "$ref": "#/$defs/geometryStartEnd" } }, "required": ["type", "geometry"] }, { "title": "DrawingPriceMeasurement", "properties": { "type": { "const": "priceMeasurement" }, "geometry": { "$ref": "#/$defs/geometryStartEnd" } }, "required": ["type", "geometry"] }] };
313
+ const schema62 = { "type": "string", "minLength": 1, "maxLength": 128, "pattern": "^[A-Za-z][A-Za-z0-9._:-]*$" };
314
+ const schema64 = { "type": "object", "additionalProperties": false, "required": ["paneRole", "yAxisRole"], "properties": { "paneRole": { "type": "string", "minLength": 1, "maxLength": 128 }, "yAxisRole": { "type": "string", "minLength": 1, "maxLength": 128 } } };
315
+ const schema37 = { "type": "object", "additionalProperties": false, "required": ["value"], "properties": { "value": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber" } } };
316
+ const schema39 = { "type": "number", "minimum": -1.7976931348623157e+308, "maximum": 1.7976931348623157e+308 };
317
+ function validate26(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate26.evaluated; if (evaluated0.dynamicProps) {
318
+ evaluated0.props = undefined;
319
+ } if (evaluated0.dynamicItems) {
320
+ evaluated0.items = undefined;
321
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
322
+ if (data.value === undefined) {
323
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "value" }, message: "must have required property '" + "value" + "'" };
324
+ if (vErrors === null) {
325
+ vErrors = [err0];
326
+ }
327
+ else {
328
+ vErrors.push(err0);
329
+ }
330
+ errors++;
331
+ }
332
+ for (const key0 in data) {
333
+ if (!(key0 === "value")) {
334
+ const err1 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
335
+ if (vErrors === null) {
336
+ vErrors = [err1];
337
+ }
338
+ else {
339
+ vErrors.push(err1);
340
+ }
341
+ errors++;
342
+ }
343
+ }
344
+ if (data.value !== undefined) {
345
+ let data0 = data.value;
346
+ if ((typeof data0 == "number") && (isFinite(data0))) {
347
+ if (data0 > 1.7976931348623157e+308 || isNaN(data0)) {
348
+ const err2 = { instancePath: instancePath + "/value", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/maximum", keyword: "maximum", params: { comparison: "<=", limit: 1.7976931348623157e+308 }, message: "must be <= 1.7976931348623157e+308" };
349
+ if (vErrors === null) {
350
+ vErrors = [err2];
351
+ }
352
+ else {
353
+ vErrors.push(err2);
354
+ }
355
+ errors++;
356
+ }
357
+ if (data0 < -1.7976931348623157e+308 || isNaN(data0)) {
358
+ const err3 = { instancePath: instancePath + "/value", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/minimum", keyword: "minimum", params: { comparison: ">=", limit: -1.7976931348623157e+308 }, message: "must be >= -1.7976931348623157e+308" };
359
+ if (vErrors === null) {
360
+ vErrors = [err3];
361
+ }
362
+ else {
363
+ vErrors.push(err3);
364
+ }
365
+ errors++;
366
+ }
367
+ }
368
+ else {
369
+ const err4 = { instancePath: instancePath + "/value", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/type", keyword: "type", params: { type: "number" }, message: "must be number" };
370
+ if (vErrors === null) {
371
+ vErrors = [err4];
372
+ }
373
+ else {
374
+ vErrors.push(err4);
375
+ }
376
+ errors++;
377
+ }
378
+ }
379
+ }
380
+ else {
381
+ const err5 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
382
+ if (vErrors === null) {
383
+ vErrors = [err5];
384
+ }
385
+ else {
386
+ vErrors.push(err5);
387
+ }
388
+ errors++;
389
+ } validate26.errors = vErrors; return errors === 0; }
390
+ validate26.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
391
+ const schema40 = { "type": "object", "additionalProperties": false, "required": ["value", "text"], "properties": { "value": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber" }, "text": { "type": "string", "maxLength": 4096 } } };
392
+ function validate30(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate30.evaluated; if (evaluated0.dynamicProps) {
393
+ evaluated0.props = undefined;
394
+ } if (evaluated0.dynamicItems) {
395
+ evaluated0.items = undefined;
396
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
397
+ if (data.value === undefined) {
398
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "value" }, message: "must have required property '" + "value" + "'" };
399
+ if (vErrors === null) {
400
+ vErrors = [err0];
401
+ }
402
+ else {
403
+ vErrors.push(err0);
404
+ }
405
+ errors++;
406
+ }
407
+ if (data.text === undefined) {
408
+ const err1 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "text" }, message: "must have required property '" + "text" + "'" };
409
+ if (vErrors === null) {
410
+ vErrors = [err1];
411
+ }
412
+ else {
413
+ vErrors.push(err1);
414
+ }
415
+ errors++;
416
+ }
417
+ for (const key0 in data) {
418
+ if (!((key0 === "value") || (key0 === "text"))) {
419
+ const err2 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
420
+ if (vErrors === null) {
421
+ vErrors = [err2];
422
+ }
423
+ else {
424
+ vErrors.push(err2);
425
+ }
426
+ errors++;
427
+ }
428
+ }
429
+ if (data.value !== undefined) {
430
+ let data0 = data.value;
431
+ if ((typeof data0 == "number") && (isFinite(data0))) {
432
+ if (data0 > 1.7976931348623157e+308 || isNaN(data0)) {
433
+ const err3 = { instancePath: instancePath + "/value", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/maximum", keyword: "maximum", params: { comparison: "<=", limit: 1.7976931348623157e+308 }, message: "must be <= 1.7976931348623157e+308" };
434
+ if (vErrors === null) {
435
+ vErrors = [err3];
436
+ }
437
+ else {
438
+ vErrors.push(err3);
439
+ }
440
+ errors++;
441
+ }
442
+ if (data0 < -1.7976931348623157e+308 || isNaN(data0)) {
443
+ const err4 = { instancePath: instancePath + "/value", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/minimum", keyword: "minimum", params: { comparison: ">=", limit: -1.7976931348623157e+308 }, message: "must be >= -1.7976931348623157e+308" };
444
+ if (vErrors === null) {
445
+ vErrors = [err4];
446
+ }
447
+ else {
448
+ vErrors.push(err4);
449
+ }
450
+ errors++;
451
+ }
452
+ }
453
+ else {
454
+ const err5 = { instancePath: instancePath + "/value", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/type", keyword: "type", params: { type: "number" }, message: "must be number" };
455
+ if (vErrors === null) {
456
+ vErrors = [err5];
457
+ }
458
+ else {
459
+ vErrors.push(err5);
460
+ }
461
+ errors++;
462
+ }
463
+ }
464
+ if (data.text !== undefined) {
465
+ let data1 = data.text;
466
+ if (typeof data1 === "string") {
467
+ if (func1(data1) > 4096) {
468
+ const err6 = { instancePath: instancePath + "/text", schemaPath: "#/properties/text/maxLength", keyword: "maxLength", params: { limit: 4096 }, message: "must NOT have more than 4096 characters" };
469
+ if (vErrors === null) {
470
+ vErrors = [err6];
471
+ }
472
+ else {
473
+ vErrors.push(err6);
474
+ }
475
+ errors++;
476
+ }
477
+ }
478
+ else {
479
+ const err7 = { instancePath: instancePath + "/text", schemaPath: "#/properties/text/type", keyword: "type", params: { type: "string" }, message: "must be string" };
480
+ if (vErrors === null) {
481
+ vErrors = [err7];
482
+ }
483
+ else {
484
+ vErrors.push(err7);
485
+ }
486
+ errors++;
487
+ }
488
+ }
489
+ }
490
+ else {
491
+ const err8 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
492
+ if (vErrors === null) {
493
+ vErrors = [err8];
494
+ }
495
+ else {
496
+ vErrors.push(err8);
497
+ }
498
+ errors++;
499
+ } validate30.errors = vErrors; return errors === 0; }
500
+ validate30.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
501
+ const schema42 = { "type": "object", "additionalProperties": false, "required": ["time"], "properties": { "time": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger" } } };
502
+ const schema43 = { "type": "integer", "minimum": -9007199254740991, "maximum": 9007199254740991 };
503
+ function validate32(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate32.evaluated; if (evaluated0.dynamicProps) {
504
+ evaluated0.props = undefined;
505
+ } if (evaluated0.dynamicItems) {
506
+ evaluated0.items = undefined;
507
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
508
+ if (data.time === undefined) {
509
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "time" }, message: "must have required property '" + "time" + "'" };
510
+ if (vErrors === null) {
511
+ vErrors = [err0];
512
+ }
513
+ else {
514
+ vErrors.push(err0);
515
+ }
516
+ errors++;
517
+ }
518
+ for (const key0 in data) {
519
+ if (!(key0 === "time")) {
520
+ const err1 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
521
+ if (vErrors === null) {
522
+ vErrors = [err1];
523
+ }
524
+ else {
525
+ vErrors.push(err1);
526
+ }
527
+ errors++;
528
+ }
529
+ }
530
+ if (data.time !== undefined) {
531
+ let data0 = data.time;
532
+ if (!(((typeof data0 == "number") && (!(data0 % 1) && !isNaN(data0))) && (isFinite(data0)))) {
533
+ const err2 = { instancePath: instancePath + "/time", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger/type", keyword: "type", params: { type: "integer" }, message: "must be integer" };
534
+ if (vErrors === null) {
535
+ vErrors = [err2];
536
+ }
537
+ else {
538
+ vErrors.push(err2);
539
+ }
540
+ errors++;
541
+ }
542
+ if ((typeof data0 == "number") && (isFinite(data0))) {
543
+ if (data0 > 9007199254740991 || isNaN(data0)) {
544
+ const err3 = { instancePath: instancePath + "/time", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger/maximum", keyword: "maximum", params: { comparison: "<=", limit: 9007199254740991 }, message: "must be <= 9007199254740991" };
545
+ if (vErrors === null) {
546
+ vErrors = [err3];
547
+ }
548
+ else {
549
+ vErrors.push(err3);
550
+ }
551
+ errors++;
552
+ }
553
+ if (data0 < -9007199254740991 || isNaN(data0)) {
554
+ const err4 = { instancePath: instancePath + "/time", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger/minimum", keyword: "minimum", params: { comparison: ">=", limit: -9007199254740991 }, message: "must be >= -9007199254740991" };
555
+ if (vErrors === null) {
556
+ vErrors = [err4];
557
+ }
558
+ else {
559
+ vErrors.push(err4);
560
+ }
561
+ errors++;
562
+ }
563
+ }
564
+ }
565
+ }
566
+ else {
567
+ const err5 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
568
+ if (vErrors === null) {
569
+ vErrors = [err5];
570
+ }
571
+ else {
572
+ vErrors.push(err5);
573
+ }
574
+ errors++;
575
+ } validate32.errors = vErrors; return errors === 0; }
576
+ validate32.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
577
+ const schema44 = { "type": "object", "additionalProperties": false, "required": ["value", "startTime", "endTime"], "properties": { "value": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber" }, "startTime": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger" }, "endTime": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger" } } };
578
+ function validate34(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate34.evaluated; if (evaluated0.dynamicProps) {
579
+ evaluated0.props = undefined;
580
+ } if (evaluated0.dynamicItems) {
581
+ evaluated0.items = undefined;
582
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
583
+ if (data.value === undefined) {
584
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "value" }, message: "must have required property '" + "value" + "'" };
585
+ if (vErrors === null) {
586
+ vErrors = [err0];
587
+ }
588
+ else {
589
+ vErrors.push(err0);
590
+ }
591
+ errors++;
592
+ }
593
+ if (data.startTime === undefined) {
594
+ const err1 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "startTime" }, message: "must have required property '" + "startTime" + "'" };
595
+ if (vErrors === null) {
596
+ vErrors = [err1];
597
+ }
598
+ else {
599
+ vErrors.push(err1);
600
+ }
601
+ errors++;
602
+ }
603
+ if (data.endTime === undefined) {
604
+ const err2 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "endTime" }, message: "must have required property '" + "endTime" + "'" };
605
+ if (vErrors === null) {
606
+ vErrors = [err2];
607
+ }
608
+ else {
609
+ vErrors.push(err2);
610
+ }
611
+ errors++;
612
+ }
613
+ for (const key0 in data) {
614
+ if (!(((key0 === "value") || (key0 === "startTime")) || (key0 === "endTime"))) {
615
+ const err3 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
616
+ if (vErrors === null) {
617
+ vErrors = [err3];
618
+ }
619
+ else {
620
+ vErrors.push(err3);
621
+ }
622
+ errors++;
623
+ }
624
+ }
625
+ if (data.value !== undefined) {
626
+ let data0 = data.value;
627
+ if ((typeof data0 == "number") && (isFinite(data0))) {
628
+ if (data0 > 1.7976931348623157e+308 || isNaN(data0)) {
629
+ const err4 = { instancePath: instancePath + "/value", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/maximum", keyword: "maximum", params: { comparison: "<=", limit: 1.7976931348623157e+308 }, message: "must be <= 1.7976931348623157e+308" };
630
+ if (vErrors === null) {
631
+ vErrors = [err4];
632
+ }
633
+ else {
634
+ vErrors.push(err4);
635
+ }
636
+ errors++;
637
+ }
638
+ if (data0 < -1.7976931348623157e+308 || isNaN(data0)) {
639
+ const err5 = { instancePath: instancePath + "/value", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/minimum", keyword: "minimum", params: { comparison: ">=", limit: -1.7976931348623157e+308 }, message: "must be >= -1.7976931348623157e+308" };
640
+ if (vErrors === null) {
641
+ vErrors = [err5];
642
+ }
643
+ else {
644
+ vErrors.push(err5);
645
+ }
646
+ errors++;
647
+ }
648
+ }
649
+ else {
650
+ const err6 = { instancePath: instancePath + "/value", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/type", keyword: "type", params: { type: "number" }, message: "must be number" };
651
+ if (vErrors === null) {
652
+ vErrors = [err6];
653
+ }
654
+ else {
655
+ vErrors.push(err6);
656
+ }
657
+ errors++;
658
+ }
659
+ }
660
+ if (data.startTime !== undefined) {
661
+ let data1 = data.startTime;
662
+ if (!(((typeof data1 == "number") && (!(data1 % 1) && !isNaN(data1))) && (isFinite(data1)))) {
663
+ const err7 = { instancePath: instancePath + "/startTime", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger/type", keyword: "type", params: { type: "integer" }, message: "must be integer" };
664
+ if (vErrors === null) {
665
+ vErrors = [err7];
666
+ }
667
+ else {
668
+ vErrors.push(err7);
669
+ }
670
+ errors++;
671
+ }
672
+ if ((typeof data1 == "number") && (isFinite(data1))) {
673
+ if (data1 > 9007199254740991 || isNaN(data1)) {
674
+ const err8 = { instancePath: instancePath + "/startTime", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger/maximum", keyword: "maximum", params: { comparison: "<=", limit: 9007199254740991 }, message: "must be <= 9007199254740991" };
675
+ if (vErrors === null) {
676
+ vErrors = [err8];
677
+ }
678
+ else {
679
+ vErrors.push(err8);
680
+ }
681
+ errors++;
682
+ }
683
+ if (data1 < -9007199254740991 || isNaN(data1)) {
684
+ const err9 = { instancePath: instancePath + "/startTime", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger/minimum", keyword: "minimum", params: { comparison: ">=", limit: -9007199254740991 }, message: "must be >= -9007199254740991" };
685
+ if (vErrors === null) {
686
+ vErrors = [err9];
687
+ }
688
+ else {
689
+ vErrors.push(err9);
690
+ }
691
+ errors++;
692
+ }
693
+ }
694
+ }
695
+ if (data.endTime !== undefined) {
696
+ let data2 = data.endTime;
697
+ if (!(((typeof data2 == "number") && (!(data2 % 1) && !isNaN(data2))) && (isFinite(data2)))) {
698
+ const err10 = { instancePath: instancePath + "/endTime", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger/type", keyword: "type", params: { type: "integer" }, message: "must be integer" };
699
+ if (vErrors === null) {
700
+ vErrors = [err10];
701
+ }
702
+ else {
703
+ vErrors.push(err10);
704
+ }
705
+ errors++;
706
+ }
707
+ if ((typeof data2 == "number") && (isFinite(data2))) {
708
+ if (data2 > 9007199254740991 || isNaN(data2)) {
709
+ const err11 = { instancePath: instancePath + "/endTime", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger/maximum", keyword: "maximum", params: { comparison: "<=", limit: 9007199254740991 }, message: "must be <= 9007199254740991" };
710
+ if (vErrors === null) {
711
+ vErrors = [err11];
712
+ }
713
+ else {
714
+ vErrors.push(err11);
715
+ }
716
+ errors++;
717
+ }
718
+ if (data2 < -9007199254740991 || isNaN(data2)) {
719
+ const err12 = { instancePath: instancePath + "/endTime", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger/minimum", keyword: "minimum", params: { comparison: ">=", limit: -9007199254740991 }, message: "must be >= -9007199254740991" };
720
+ if (vErrors === null) {
721
+ vErrors = [err12];
722
+ }
723
+ else {
724
+ vErrors.push(err12);
725
+ }
726
+ errors++;
727
+ }
728
+ }
729
+ }
730
+ }
731
+ else {
732
+ const err13 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
733
+ if (vErrors === null) {
734
+ vErrors = [err13];
735
+ }
736
+ else {
737
+ vErrors.push(err13);
738
+ }
739
+ errors++;
740
+ } validate34.errors = vErrors; return errors === 0; }
741
+ validate34.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
742
+ const schema48 = { "type": "object", "additionalProperties": false, "required": ["time", "startValue", "endValue"], "properties": { "time": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger" }, "startValue": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber" }, "endValue": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber" } } };
743
+ function validate37(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate37.evaluated; if (evaluated0.dynamicProps) {
744
+ evaluated0.props = undefined;
745
+ } if (evaluated0.dynamicItems) {
746
+ evaluated0.items = undefined;
747
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
748
+ if (data.time === undefined) {
749
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "time" }, message: "must have required property '" + "time" + "'" };
750
+ if (vErrors === null) {
751
+ vErrors = [err0];
752
+ }
753
+ else {
754
+ vErrors.push(err0);
755
+ }
756
+ errors++;
757
+ }
758
+ if (data.startValue === undefined) {
759
+ const err1 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "startValue" }, message: "must have required property '" + "startValue" + "'" };
760
+ if (vErrors === null) {
761
+ vErrors = [err1];
762
+ }
763
+ else {
764
+ vErrors.push(err1);
765
+ }
766
+ errors++;
767
+ }
768
+ if (data.endValue === undefined) {
769
+ const err2 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "endValue" }, message: "must have required property '" + "endValue" + "'" };
770
+ if (vErrors === null) {
771
+ vErrors = [err2];
772
+ }
773
+ else {
774
+ vErrors.push(err2);
775
+ }
776
+ errors++;
777
+ }
778
+ for (const key0 in data) {
779
+ if (!(((key0 === "time") || (key0 === "startValue")) || (key0 === "endValue"))) {
780
+ const err3 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
781
+ if (vErrors === null) {
782
+ vErrors = [err3];
783
+ }
784
+ else {
785
+ vErrors.push(err3);
786
+ }
787
+ errors++;
788
+ }
789
+ }
790
+ if (data.time !== undefined) {
791
+ let data0 = data.time;
792
+ if (!(((typeof data0 == "number") && (!(data0 % 1) && !isNaN(data0))) && (isFinite(data0)))) {
793
+ const err4 = { instancePath: instancePath + "/time", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger/type", keyword: "type", params: { type: "integer" }, message: "must be integer" };
794
+ if (vErrors === null) {
795
+ vErrors = [err4];
796
+ }
797
+ else {
798
+ vErrors.push(err4);
799
+ }
800
+ errors++;
801
+ }
802
+ if ((typeof data0 == "number") && (isFinite(data0))) {
803
+ if (data0 > 9007199254740991 || isNaN(data0)) {
804
+ const err5 = { instancePath: instancePath + "/time", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger/maximum", keyword: "maximum", params: { comparison: "<=", limit: 9007199254740991 }, message: "must be <= 9007199254740991" };
805
+ if (vErrors === null) {
806
+ vErrors = [err5];
807
+ }
808
+ else {
809
+ vErrors.push(err5);
810
+ }
811
+ errors++;
812
+ }
813
+ if (data0 < -9007199254740991 || isNaN(data0)) {
814
+ const err6 = { instancePath: instancePath + "/time", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger/minimum", keyword: "minimum", params: { comparison: ">=", limit: -9007199254740991 }, message: "must be >= -9007199254740991" };
815
+ if (vErrors === null) {
816
+ vErrors = [err6];
817
+ }
818
+ else {
819
+ vErrors.push(err6);
820
+ }
821
+ errors++;
822
+ }
823
+ }
824
+ }
825
+ if (data.startValue !== undefined) {
826
+ let data1 = data.startValue;
827
+ if ((typeof data1 == "number") && (isFinite(data1))) {
828
+ if (data1 > 1.7976931348623157e+308 || isNaN(data1)) {
829
+ const err7 = { instancePath: instancePath + "/startValue", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/maximum", keyword: "maximum", params: { comparison: "<=", limit: 1.7976931348623157e+308 }, message: "must be <= 1.7976931348623157e+308" };
830
+ if (vErrors === null) {
831
+ vErrors = [err7];
832
+ }
833
+ else {
834
+ vErrors.push(err7);
835
+ }
836
+ errors++;
837
+ }
838
+ if (data1 < -1.7976931348623157e+308 || isNaN(data1)) {
839
+ const err8 = { instancePath: instancePath + "/startValue", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/minimum", keyword: "minimum", params: { comparison: ">=", limit: -1.7976931348623157e+308 }, message: "must be >= -1.7976931348623157e+308" };
840
+ if (vErrors === null) {
841
+ vErrors = [err8];
842
+ }
843
+ else {
844
+ vErrors.push(err8);
845
+ }
846
+ errors++;
847
+ }
848
+ }
849
+ else {
850
+ const err9 = { instancePath: instancePath + "/startValue", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/type", keyword: "type", params: { type: "number" }, message: "must be number" };
851
+ if (vErrors === null) {
852
+ vErrors = [err9];
853
+ }
854
+ else {
855
+ vErrors.push(err9);
856
+ }
857
+ errors++;
858
+ }
859
+ }
860
+ if (data.endValue !== undefined) {
861
+ let data2 = data.endValue;
862
+ if ((typeof data2 == "number") && (isFinite(data2))) {
863
+ if (data2 > 1.7976931348623157e+308 || isNaN(data2)) {
864
+ const err10 = { instancePath: instancePath + "/endValue", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/maximum", keyword: "maximum", params: { comparison: "<=", limit: 1.7976931348623157e+308 }, message: "must be <= 1.7976931348623157e+308" };
865
+ if (vErrors === null) {
866
+ vErrors = [err10];
867
+ }
868
+ else {
869
+ vErrors.push(err10);
870
+ }
871
+ errors++;
872
+ }
873
+ if (data2 < -1.7976931348623157e+308 || isNaN(data2)) {
874
+ const err11 = { instancePath: instancePath + "/endValue", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/minimum", keyword: "minimum", params: { comparison: ">=", limit: -1.7976931348623157e+308 }, message: "must be >= -1.7976931348623157e+308" };
875
+ if (vErrors === null) {
876
+ vErrors = [err11];
877
+ }
878
+ else {
879
+ vErrors.push(err11);
880
+ }
881
+ errors++;
882
+ }
883
+ }
884
+ else {
885
+ const err12 = { instancePath: instancePath + "/endValue", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/type", keyword: "type", params: { type: "number" }, message: "must be number" };
886
+ if (vErrors === null) {
887
+ vErrors = [err12];
888
+ }
889
+ else {
890
+ vErrors.push(err12);
891
+ }
892
+ errors++;
893
+ }
894
+ }
895
+ }
896
+ else {
897
+ const err13 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
898
+ if (vErrors === null) {
899
+ vErrors = [err13];
900
+ }
901
+ else {
902
+ vErrors.push(err13);
903
+ }
904
+ errors++;
905
+ } validate37.errors = vErrors; return errors === 0; }
906
+ validate37.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
907
+ const schema52 = { "type": "object", "additionalProperties": false, "required": ["points"], "properties": { "points": { "type": "array", "minItems": 2, "maxItems": 2, "items": { "$ref": "#/$defs/timeValuePoint" } } } };
908
+ const schema53 = { "type": "object", "additionalProperties": false, "required": ["timestamp", "granularity", "value"], "properties": { "timestamp": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger" }, "granularity": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/period" }, "value": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber" } } };
909
+ const schema55 = { "type": "object", "additionalProperties": false, "required": ["span", "type"], "properties": { "span": { "type": "integer", "minimum": 1, "maximum": 100000 }, "type": { "enum": ["second", "minute", "hour", "day", "week", "month", "year"] } } };
910
+ function validate41(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate41.evaluated; if (evaluated0.dynamicProps) {
911
+ evaluated0.props = undefined;
912
+ } if (evaluated0.dynamicItems) {
913
+ evaluated0.items = undefined;
914
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
915
+ if (data.timestamp === undefined) {
916
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "timestamp" }, message: "must have required property '" + "timestamp" + "'" };
917
+ if (vErrors === null) {
918
+ vErrors = [err0];
919
+ }
920
+ else {
921
+ vErrors.push(err0);
922
+ }
923
+ errors++;
924
+ }
925
+ if (data.granularity === undefined) {
926
+ const err1 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "granularity" }, message: "must have required property '" + "granularity" + "'" };
927
+ if (vErrors === null) {
928
+ vErrors = [err1];
929
+ }
930
+ else {
931
+ vErrors.push(err1);
932
+ }
933
+ errors++;
934
+ }
935
+ if (data.value === undefined) {
936
+ const err2 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "value" }, message: "must have required property '" + "value" + "'" };
937
+ if (vErrors === null) {
938
+ vErrors = [err2];
939
+ }
940
+ else {
941
+ vErrors.push(err2);
942
+ }
943
+ errors++;
944
+ }
945
+ for (const key0 in data) {
946
+ if (!(((key0 === "timestamp") || (key0 === "granularity")) || (key0 === "value"))) {
947
+ const err3 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
948
+ if (vErrors === null) {
949
+ vErrors = [err3];
950
+ }
951
+ else {
952
+ vErrors.push(err3);
953
+ }
954
+ errors++;
955
+ }
956
+ }
957
+ if (data.timestamp !== undefined) {
958
+ let data0 = data.timestamp;
959
+ if (!(((typeof data0 == "number") && (!(data0 % 1) && !isNaN(data0))) && (isFinite(data0)))) {
960
+ const err4 = { instancePath: instancePath + "/timestamp", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger/type", keyword: "type", params: { type: "integer" }, message: "must be integer" };
961
+ if (vErrors === null) {
962
+ vErrors = [err4];
963
+ }
964
+ else {
965
+ vErrors.push(err4);
966
+ }
967
+ errors++;
968
+ }
969
+ if ((typeof data0 == "number") && (isFinite(data0))) {
970
+ if (data0 > 9007199254740991 || isNaN(data0)) {
971
+ const err5 = { instancePath: instancePath + "/timestamp", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger/maximum", keyword: "maximum", params: { comparison: "<=", limit: 9007199254740991 }, message: "must be <= 9007199254740991" };
972
+ if (vErrors === null) {
973
+ vErrors = [err5];
974
+ }
975
+ else {
976
+ vErrors.push(err5);
977
+ }
978
+ errors++;
979
+ }
980
+ if (data0 < -9007199254740991 || isNaN(data0)) {
981
+ const err6 = { instancePath: instancePath + "/timestamp", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/safeInteger/minimum", keyword: "minimum", params: { comparison: ">=", limit: -9007199254740991 }, message: "must be >= -9007199254740991" };
982
+ if (vErrors === null) {
983
+ vErrors = [err6];
984
+ }
985
+ else {
986
+ vErrors.push(err6);
987
+ }
988
+ errors++;
989
+ }
990
+ }
991
+ }
992
+ if (data.granularity !== undefined) {
993
+ let data1 = data.granularity;
994
+ if (data1 && typeof data1 == "object" && !Array.isArray(data1)) {
995
+ if (data1.span === undefined) {
996
+ const err7 = { instancePath: instancePath + "/granularity", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/period/required", keyword: "required", params: { missingProperty: "span" }, message: "must have required property '" + "span" + "'" };
997
+ if (vErrors === null) {
998
+ vErrors = [err7];
999
+ }
1000
+ else {
1001
+ vErrors.push(err7);
1002
+ }
1003
+ errors++;
1004
+ }
1005
+ if (data1.type === undefined) {
1006
+ const err8 = { instancePath: instancePath + "/granularity", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/period/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
1007
+ if (vErrors === null) {
1008
+ vErrors = [err8];
1009
+ }
1010
+ else {
1011
+ vErrors.push(err8);
1012
+ }
1013
+ errors++;
1014
+ }
1015
+ for (const key1 in data1) {
1016
+ if (!((key1 === "span") || (key1 === "type"))) {
1017
+ const err9 = { instancePath: instancePath + "/granularity", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/period/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key1 }, message: "must NOT have additional properties" };
1018
+ if (vErrors === null) {
1019
+ vErrors = [err9];
1020
+ }
1021
+ else {
1022
+ vErrors.push(err9);
1023
+ }
1024
+ errors++;
1025
+ }
1026
+ }
1027
+ if (data1.span !== undefined) {
1028
+ let data2 = data1.span;
1029
+ if (!(((typeof data2 == "number") && (!(data2 % 1) && !isNaN(data2))) && (isFinite(data2)))) {
1030
+ const err10 = { instancePath: instancePath + "/granularity/span", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/period/properties/span/type", keyword: "type", params: { type: "integer" }, message: "must be integer" };
1031
+ if (vErrors === null) {
1032
+ vErrors = [err10];
1033
+ }
1034
+ else {
1035
+ vErrors.push(err10);
1036
+ }
1037
+ errors++;
1038
+ }
1039
+ if ((typeof data2 == "number") && (isFinite(data2))) {
1040
+ if (data2 > 100000 || isNaN(data2)) {
1041
+ const err11 = { instancePath: instancePath + "/granularity/span", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/period/properties/span/maximum", keyword: "maximum", params: { comparison: "<=", limit: 100000 }, message: "must be <= 100000" };
1042
+ if (vErrors === null) {
1043
+ vErrors = [err11];
1044
+ }
1045
+ else {
1046
+ vErrors.push(err11);
1047
+ }
1048
+ errors++;
1049
+ }
1050
+ if (data2 < 1 || isNaN(data2)) {
1051
+ const err12 = { instancePath: instancePath + "/granularity/span", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/period/properties/span/minimum", keyword: "minimum", params: { comparison: ">=", limit: 1 }, message: "must be >= 1" };
1052
+ if (vErrors === null) {
1053
+ vErrors = [err12];
1054
+ }
1055
+ else {
1056
+ vErrors.push(err12);
1057
+ }
1058
+ errors++;
1059
+ }
1060
+ }
1061
+ }
1062
+ if (data1.type !== undefined) {
1063
+ let data3 = data1.type;
1064
+ if (!(((((((data3 === "second") || (data3 === "minute")) || (data3 === "hour")) || (data3 === "day")) || (data3 === "week")) || (data3 === "month")) || (data3 === "year"))) {
1065
+ const err13 = { instancePath: instancePath + "/granularity/type", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/period/properties/type/enum", keyword: "enum", params: { allowedValues: schema55.properties.type.enum }, message: "must be equal to one of the allowed values" };
1066
+ if (vErrors === null) {
1067
+ vErrors = [err13];
1068
+ }
1069
+ else {
1070
+ vErrors.push(err13);
1071
+ }
1072
+ errors++;
1073
+ }
1074
+ }
1075
+ }
1076
+ else {
1077
+ const err14 = { instancePath: instancePath + "/granularity", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/period/type", keyword: "type", params: { type: "object" }, message: "must be object" };
1078
+ if (vErrors === null) {
1079
+ vErrors = [err14];
1080
+ }
1081
+ else {
1082
+ vErrors.push(err14);
1083
+ }
1084
+ errors++;
1085
+ }
1086
+ }
1087
+ if (data.value !== undefined) {
1088
+ let data4 = data.value;
1089
+ if ((typeof data4 == "number") && (isFinite(data4))) {
1090
+ if (data4 > 1.7976931348623157e+308 || isNaN(data4)) {
1091
+ const err15 = { instancePath: instancePath + "/value", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/maximum", keyword: "maximum", params: { comparison: "<=", limit: 1.7976931348623157e+308 }, message: "must be <= 1.7976931348623157e+308" };
1092
+ if (vErrors === null) {
1093
+ vErrors = [err15];
1094
+ }
1095
+ else {
1096
+ vErrors.push(err15);
1097
+ }
1098
+ errors++;
1099
+ }
1100
+ if (data4 < -1.7976931348623157e+308 || isNaN(data4)) {
1101
+ const err16 = { instancePath: instancePath + "/value", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/minimum", keyword: "minimum", params: { comparison: ">=", limit: -1.7976931348623157e+308 }, message: "must be >= -1.7976931348623157e+308" };
1102
+ if (vErrors === null) {
1103
+ vErrors = [err16];
1104
+ }
1105
+ else {
1106
+ vErrors.push(err16);
1107
+ }
1108
+ errors++;
1109
+ }
1110
+ }
1111
+ else {
1112
+ const err17 = { instancePath: instancePath + "/value", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/finiteNumber/type", keyword: "type", params: { type: "number" }, message: "must be number" };
1113
+ if (vErrors === null) {
1114
+ vErrors = [err17];
1115
+ }
1116
+ else {
1117
+ vErrors.push(err17);
1118
+ }
1119
+ errors++;
1120
+ }
1121
+ }
1122
+ }
1123
+ else {
1124
+ const err18 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
1125
+ if (vErrors === null) {
1126
+ vErrors = [err18];
1127
+ }
1128
+ else {
1129
+ vErrors.push(err18);
1130
+ }
1131
+ errors++;
1132
+ } validate41.errors = vErrors; return errors === 0; }
1133
+ validate41.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
1134
+ function validate40(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate40.evaluated; if (evaluated0.dynamicProps) {
1135
+ evaluated0.props = undefined;
1136
+ } if (evaluated0.dynamicItems) {
1137
+ evaluated0.items = undefined;
1138
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
1139
+ if (data.points === undefined) {
1140
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "points" }, message: "must have required property '" + "points" + "'" };
1141
+ if (vErrors === null) {
1142
+ vErrors = [err0];
1143
+ }
1144
+ else {
1145
+ vErrors.push(err0);
1146
+ }
1147
+ errors++;
1148
+ }
1149
+ for (const key0 in data) {
1150
+ if (!(key0 === "points")) {
1151
+ const err1 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
1152
+ if (vErrors === null) {
1153
+ vErrors = [err1];
1154
+ }
1155
+ else {
1156
+ vErrors.push(err1);
1157
+ }
1158
+ errors++;
1159
+ }
1160
+ }
1161
+ if (data.points !== undefined) {
1162
+ let data0 = data.points;
1163
+ if (Array.isArray(data0)) {
1164
+ if (data0.length > 2) {
1165
+ const err2 = { instancePath: instancePath + "/points", schemaPath: "#/properties/points/maxItems", keyword: "maxItems", params: { limit: 2 }, message: "must NOT have more than 2 items" };
1166
+ if (vErrors === null) {
1167
+ vErrors = [err2];
1168
+ }
1169
+ else {
1170
+ vErrors.push(err2);
1171
+ }
1172
+ errors++;
1173
+ }
1174
+ if (data0.length < 2) {
1175
+ const err3 = { instancePath: instancePath + "/points", schemaPath: "#/properties/points/minItems", keyword: "minItems", params: { limit: 2 }, message: "must NOT have fewer than 2 items" };
1176
+ if (vErrors === null) {
1177
+ vErrors = [err3];
1178
+ }
1179
+ else {
1180
+ vErrors.push(err3);
1181
+ }
1182
+ errors++;
1183
+ }
1184
+ const len0 = data0.length;
1185
+ for (let i0 = 0; i0 < len0; i0++) {
1186
+ if (!(validate41(data0[i0], { instancePath: instancePath + "/points/" + i0, parentData: data0, parentDataProperty: i0, rootData, dynamicAnchors }))) {
1187
+ vErrors = vErrors === null ? validate41.errors : vErrors.concat(validate41.errors);
1188
+ errors = vErrors.length;
1189
+ }
1190
+ }
1191
+ }
1192
+ else {
1193
+ const err4 = { instancePath: instancePath + "/points", schemaPath: "#/properties/points/type", keyword: "type", params: { type: "array" }, message: "must be array" };
1194
+ if (vErrors === null) {
1195
+ vErrors = [err4];
1196
+ }
1197
+ else {
1198
+ vErrors.push(err4);
1199
+ }
1200
+ errors++;
1201
+ }
1202
+ }
1203
+ }
1204
+ else {
1205
+ const err5 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
1206
+ if (vErrors === null) {
1207
+ vErrors = [err5];
1208
+ }
1209
+ else {
1210
+ vErrors.push(err5);
1211
+ }
1212
+ errors++;
1213
+ } validate40.errors = vErrors; return errors === 0; }
1214
+ validate40.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
1215
+ const schema57 = { "type": "object", "additionalProperties": false, "required": ["points"], "properties": { "points": { "type": "array", "minItems": 3, "maxItems": 3, "items": { "$ref": "#/$defs/timeValuePoint" } } } };
1216
+ function validate47(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate47.evaluated; if (evaluated0.dynamicProps) {
1217
+ evaluated0.props = undefined;
1218
+ } if (evaluated0.dynamicItems) {
1219
+ evaluated0.items = undefined;
1220
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
1221
+ if (data.points === undefined) {
1222
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "points" }, message: "must have required property '" + "points" + "'" };
1223
+ if (vErrors === null) {
1224
+ vErrors = [err0];
1225
+ }
1226
+ else {
1227
+ vErrors.push(err0);
1228
+ }
1229
+ errors++;
1230
+ }
1231
+ for (const key0 in data) {
1232
+ if (!(key0 === "points")) {
1233
+ const err1 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
1234
+ if (vErrors === null) {
1235
+ vErrors = [err1];
1236
+ }
1237
+ else {
1238
+ vErrors.push(err1);
1239
+ }
1240
+ errors++;
1241
+ }
1242
+ }
1243
+ if (data.points !== undefined) {
1244
+ let data0 = data.points;
1245
+ if (Array.isArray(data0)) {
1246
+ if (data0.length > 3) {
1247
+ const err2 = { instancePath: instancePath + "/points", schemaPath: "#/properties/points/maxItems", keyword: "maxItems", params: { limit: 3 }, message: "must NOT have more than 3 items" };
1248
+ if (vErrors === null) {
1249
+ vErrors = [err2];
1250
+ }
1251
+ else {
1252
+ vErrors.push(err2);
1253
+ }
1254
+ errors++;
1255
+ }
1256
+ if (data0.length < 3) {
1257
+ const err3 = { instancePath: instancePath + "/points", schemaPath: "#/properties/points/minItems", keyword: "minItems", params: { limit: 3 }, message: "must NOT have fewer than 3 items" };
1258
+ if (vErrors === null) {
1259
+ vErrors = [err3];
1260
+ }
1261
+ else {
1262
+ vErrors.push(err3);
1263
+ }
1264
+ errors++;
1265
+ }
1266
+ const len0 = data0.length;
1267
+ for (let i0 = 0; i0 < len0; i0++) {
1268
+ if (!(validate41(data0[i0], { instancePath: instancePath + "/points/" + i0, parentData: data0, parentDataProperty: i0, rootData, dynamicAnchors }))) {
1269
+ vErrors = vErrors === null ? validate41.errors : vErrors.concat(validate41.errors);
1270
+ errors = vErrors.length;
1271
+ }
1272
+ }
1273
+ }
1274
+ else {
1275
+ const err4 = { instancePath: instancePath + "/points", schemaPath: "#/properties/points/type", keyword: "type", params: { type: "array" }, message: "must be array" };
1276
+ if (vErrors === null) {
1277
+ vErrors = [err4];
1278
+ }
1279
+ else {
1280
+ vErrors.push(err4);
1281
+ }
1282
+ errors++;
1283
+ }
1284
+ }
1285
+ }
1286
+ else {
1287
+ const err5 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
1288
+ if (vErrors === null) {
1289
+ vErrors = [err5];
1290
+ }
1291
+ else {
1292
+ vErrors.push(err5);
1293
+ }
1294
+ errors++;
1295
+ } validate47.errors = vErrors; return errors === 0; }
1296
+ validate47.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
1297
+ const schema58 = { "type": "object", "additionalProperties": false, "required": ["points"], "properties": { "points": { "type": "array", "minItems": 2, "maxItems": 256, "items": { "$ref": "#/$defs/timeValuePoint" } } } };
1298
+ function validate51(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate51.evaluated; if (evaluated0.dynamicProps) {
1299
+ evaluated0.props = undefined;
1300
+ } if (evaluated0.dynamicItems) {
1301
+ evaluated0.items = undefined;
1302
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
1303
+ if (data.points === undefined) {
1304
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "points" }, message: "must have required property '" + "points" + "'" };
1305
+ if (vErrors === null) {
1306
+ vErrors = [err0];
1307
+ }
1308
+ else {
1309
+ vErrors.push(err0);
1310
+ }
1311
+ errors++;
1312
+ }
1313
+ for (const key0 in data) {
1314
+ if (!(key0 === "points")) {
1315
+ const err1 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
1316
+ if (vErrors === null) {
1317
+ vErrors = [err1];
1318
+ }
1319
+ else {
1320
+ vErrors.push(err1);
1321
+ }
1322
+ errors++;
1323
+ }
1324
+ }
1325
+ if (data.points !== undefined) {
1326
+ let data0 = data.points;
1327
+ if (Array.isArray(data0)) {
1328
+ if (data0.length > 256) {
1329
+ const err2 = { instancePath: instancePath + "/points", schemaPath: "#/properties/points/maxItems", keyword: "maxItems", params: { limit: 256 }, message: "must NOT have more than 256 items" };
1330
+ if (vErrors === null) {
1331
+ vErrors = [err2];
1332
+ }
1333
+ else {
1334
+ vErrors.push(err2);
1335
+ }
1336
+ errors++;
1337
+ }
1338
+ if (data0.length < 2) {
1339
+ const err3 = { instancePath: instancePath + "/points", schemaPath: "#/properties/points/minItems", keyword: "minItems", params: { limit: 2 }, message: "must NOT have fewer than 2 items" };
1340
+ if (vErrors === null) {
1341
+ vErrors = [err3];
1342
+ }
1343
+ else {
1344
+ vErrors.push(err3);
1345
+ }
1346
+ errors++;
1347
+ }
1348
+ const len0 = data0.length;
1349
+ for (let i0 = 0; i0 < len0; i0++) {
1350
+ if (!(validate41(data0[i0], { instancePath: instancePath + "/points/" + i0, parentData: data0, parentDataProperty: i0, rootData, dynamicAnchors }))) {
1351
+ vErrors = vErrors === null ? validate41.errors : vErrors.concat(validate41.errors);
1352
+ errors = vErrors.length;
1353
+ }
1354
+ }
1355
+ }
1356
+ else {
1357
+ const err4 = { instancePath: instancePath + "/points", schemaPath: "#/properties/points/type", keyword: "type", params: { type: "array" }, message: "must be array" };
1358
+ if (vErrors === null) {
1359
+ vErrors = [err4];
1360
+ }
1361
+ else {
1362
+ vErrors.push(err4);
1363
+ }
1364
+ errors++;
1365
+ }
1366
+ }
1367
+ }
1368
+ else {
1369
+ const err5 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
1370
+ if (vErrors === null) {
1371
+ vErrors = [err5];
1372
+ }
1373
+ else {
1374
+ vErrors.push(err5);
1375
+ }
1376
+ errors++;
1377
+ } validate51.errors = vErrors; return errors === 0; }
1378
+ validate51.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
1379
+ const schema59 = { "type": "object", "additionalProperties": false, "required": ["point", "text"], "properties": { "point": { "$ref": "#/$defs/timeValuePoint" }, "text": { "type": "string", "maxLength": 4096 } } };
1380
+ function validate54(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate54.evaluated; if (evaluated0.dynamicProps) {
1381
+ evaluated0.props = undefined;
1382
+ } if (evaluated0.dynamicItems) {
1383
+ evaluated0.items = undefined;
1384
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
1385
+ if (data.point === undefined) {
1386
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "point" }, message: "must have required property '" + "point" + "'" };
1387
+ if (vErrors === null) {
1388
+ vErrors = [err0];
1389
+ }
1390
+ else {
1391
+ vErrors.push(err0);
1392
+ }
1393
+ errors++;
1394
+ }
1395
+ if (data.text === undefined) {
1396
+ const err1 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "text" }, message: "must have required property '" + "text" + "'" };
1397
+ if (vErrors === null) {
1398
+ vErrors = [err1];
1399
+ }
1400
+ else {
1401
+ vErrors.push(err1);
1402
+ }
1403
+ errors++;
1404
+ }
1405
+ for (const key0 in data) {
1406
+ if (!((key0 === "point") || (key0 === "text"))) {
1407
+ const err2 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
1408
+ if (vErrors === null) {
1409
+ vErrors = [err2];
1410
+ }
1411
+ else {
1412
+ vErrors.push(err2);
1413
+ }
1414
+ errors++;
1415
+ }
1416
+ }
1417
+ if (data.point !== undefined) {
1418
+ if (!(validate41(data.point, { instancePath: instancePath + "/point", parentData: data, parentDataProperty: "point", rootData, dynamicAnchors }))) {
1419
+ vErrors = vErrors === null ? validate41.errors : vErrors.concat(validate41.errors);
1420
+ errors = vErrors.length;
1421
+ }
1422
+ }
1423
+ if (data.text !== undefined) {
1424
+ let data1 = data.text;
1425
+ if (typeof data1 === "string") {
1426
+ if (func1(data1) > 4096) {
1427
+ const err3 = { instancePath: instancePath + "/text", schemaPath: "#/properties/text/maxLength", keyword: "maxLength", params: { limit: 4096 }, message: "must NOT have more than 4096 characters" };
1428
+ if (vErrors === null) {
1429
+ vErrors = [err3];
1430
+ }
1431
+ else {
1432
+ vErrors.push(err3);
1433
+ }
1434
+ errors++;
1435
+ }
1436
+ }
1437
+ else {
1438
+ const err4 = { instancePath: instancePath + "/text", schemaPath: "#/properties/text/type", keyword: "type", params: { type: "string" }, message: "must be string" };
1439
+ if (vErrors === null) {
1440
+ vErrors = [err4];
1441
+ }
1442
+ else {
1443
+ vErrors.push(err4);
1444
+ }
1445
+ errors++;
1446
+ }
1447
+ }
1448
+ }
1449
+ else {
1450
+ const err5 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
1451
+ if (vErrors === null) {
1452
+ vErrors = [err5];
1453
+ }
1454
+ else {
1455
+ vErrors.push(err5);
1456
+ }
1457
+ errors++;
1458
+ } validate54.errors = vErrors; return errors === 0; }
1459
+ validate54.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
1460
+ const schema60 = { "type": "object", "additionalProperties": false, "required": ["point"], "properties": { "point": { "$ref": "#/$defs/timeValuePoint" } } };
1461
+ function validate59(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate59.evaluated; if (evaluated0.dynamicProps) {
1462
+ evaluated0.props = undefined;
1463
+ } if (evaluated0.dynamicItems) {
1464
+ evaluated0.items = undefined;
1465
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
1466
+ if (data.point === undefined) {
1467
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "point" }, message: "must have required property '" + "point" + "'" };
1468
+ if (vErrors === null) {
1469
+ vErrors = [err0];
1470
+ }
1471
+ else {
1472
+ vErrors.push(err0);
1473
+ }
1474
+ errors++;
1475
+ }
1476
+ for (const key0 in data) {
1477
+ if (!(key0 === "point")) {
1478
+ const err1 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
1479
+ if (vErrors === null) {
1480
+ vErrors = [err1];
1481
+ }
1482
+ else {
1483
+ vErrors.push(err1);
1484
+ }
1485
+ errors++;
1486
+ }
1487
+ }
1488
+ if (data.point !== undefined) {
1489
+ if (!(validate41(data.point, { instancePath: instancePath + "/point", parentData: data, parentDataProperty: "point", rootData, dynamicAnchors }))) {
1490
+ vErrors = vErrors === null ? validate41.errors : vErrors.concat(validate41.errors);
1491
+ errors = vErrors.length;
1492
+ }
1493
+ }
1494
+ }
1495
+ else {
1496
+ const err2 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
1497
+ if (vErrors === null) {
1498
+ vErrors = [err2];
1499
+ }
1500
+ else {
1501
+ vErrors.push(err2);
1502
+ }
1503
+ errors++;
1504
+ } validate59.errors = vErrors; return errors === 0; }
1505
+ validate59.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
1506
+ const schema61 = { "type": "object", "additionalProperties": false, "required": ["start", "end"], "properties": { "start": { "$ref": "#/$defs/timeValuePoint" }, "end": { "$ref": "#/$defs/timeValuePoint" } } };
1507
+ function validate62(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate62.evaluated; if (evaluated0.dynamicProps) {
1508
+ evaluated0.props = undefined;
1509
+ } if (evaluated0.dynamicItems) {
1510
+ evaluated0.items = undefined;
1511
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
1512
+ if (data.start === undefined) {
1513
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "start" }, message: "must have required property '" + "start" + "'" };
1514
+ if (vErrors === null) {
1515
+ vErrors = [err0];
1516
+ }
1517
+ else {
1518
+ vErrors.push(err0);
1519
+ }
1520
+ errors++;
1521
+ }
1522
+ if (data.end === undefined) {
1523
+ const err1 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "end" }, message: "must have required property '" + "end" + "'" };
1524
+ if (vErrors === null) {
1525
+ vErrors = [err1];
1526
+ }
1527
+ else {
1528
+ vErrors.push(err1);
1529
+ }
1530
+ errors++;
1531
+ }
1532
+ for (const key0 in data) {
1533
+ if (!((key0 === "start") || (key0 === "end"))) {
1534
+ const err2 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
1535
+ if (vErrors === null) {
1536
+ vErrors = [err2];
1537
+ }
1538
+ else {
1539
+ vErrors.push(err2);
1540
+ }
1541
+ errors++;
1542
+ }
1543
+ }
1544
+ if (data.start !== undefined) {
1545
+ if (!(validate41(data.start, { instancePath: instancePath + "/start", parentData: data, parentDataProperty: "start", rootData, dynamicAnchors }))) {
1546
+ vErrors = vErrors === null ? validate41.errors : vErrors.concat(validate41.errors);
1547
+ errors = vErrors.length;
1548
+ }
1549
+ }
1550
+ if (data.end !== undefined) {
1551
+ if (!(validate41(data.end, { instancePath: instancePath + "/end", parentData: data, parentDataProperty: "end", rootData, dynamicAnchors }))) {
1552
+ vErrors = vErrors === null ? validate41.errors : vErrors.concat(validate41.errors);
1553
+ errors = vErrors.length;
1554
+ }
1555
+ }
1556
+ }
1557
+ else {
1558
+ const err3 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
1559
+ if (vErrors === null) {
1560
+ vErrors = [err3];
1561
+ }
1562
+ else {
1563
+ vErrors.push(err3);
1564
+ }
1565
+ errors++;
1566
+ } validate62.errors = vErrors; return errors === 0; }
1567
+ validate62.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
1568
+ const schema65 = { "type": "object", "additionalProperties": false, "required": ["line", "fill", "text"], "properties": { "line": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/lineStyle" }, "fill": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/fillStyle" }, "text": { "$ref": "https://baron.dev/kline-scene/common.schema.json#/$defs/textStyle" } } };
1569
+ const schema66 = { "type": "object", "additionalProperties": false, "required": ["color", "size", "style"], "properties": { "color": { "$ref": "#/$defs/rgbaColor" }, "size": { "type": "number", "exclusiveMinimum": 0, "maximum": 20 }, "style": { "enum": ["solid", "dashed", "dotted"] } } };
1570
+ const schema67 = { "type": "string", "pattern": "^rgba\\(\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*(?:0(?:\\.[0-9]+)?|1(?:\\.0+)?)\\s*\\)$" };
1571
+ const pattern7 = new RegExp("^rgba\\(\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*(?:0(?:\\.[0-9]+)?|1(?:\\.0+)?)\\s*\\)$", "u");
1572
+ function validate69(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate69.evaluated; if (evaluated0.dynamicProps) {
1573
+ evaluated0.props = undefined;
1574
+ } if (evaluated0.dynamicItems) {
1575
+ evaluated0.items = undefined;
1576
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
1577
+ if (data.color === undefined) {
1578
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "color" }, message: "must have required property '" + "color" + "'" };
1579
+ if (vErrors === null) {
1580
+ vErrors = [err0];
1581
+ }
1582
+ else {
1583
+ vErrors.push(err0);
1584
+ }
1585
+ errors++;
1586
+ }
1587
+ if (data.size === undefined) {
1588
+ const err1 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "size" }, message: "must have required property '" + "size" + "'" };
1589
+ if (vErrors === null) {
1590
+ vErrors = [err1];
1591
+ }
1592
+ else {
1593
+ vErrors.push(err1);
1594
+ }
1595
+ errors++;
1596
+ }
1597
+ if (data.style === undefined) {
1598
+ const err2 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "style" }, message: "must have required property '" + "style" + "'" };
1599
+ if (vErrors === null) {
1600
+ vErrors = [err2];
1601
+ }
1602
+ else {
1603
+ vErrors.push(err2);
1604
+ }
1605
+ errors++;
1606
+ }
1607
+ for (const key0 in data) {
1608
+ if (!(((key0 === "color") || (key0 === "size")) || (key0 === "style"))) {
1609
+ const err3 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
1610
+ if (vErrors === null) {
1611
+ vErrors = [err3];
1612
+ }
1613
+ else {
1614
+ vErrors.push(err3);
1615
+ }
1616
+ errors++;
1617
+ }
1618
+ }
1619
+ if (data.color !== undefined) {
1620
+ let data0 = data.color;
1621
+ if (typeof data0 === "string") {
1622
+ if (!pattern7.test(data0)) {
1623
+ const err4 = { instancePath: instancePath + "/color", schemaPath: "#/$defs/rgbaColor/pattern", keyword: "pattern", params: { pattern: "^rgba\\(\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*(?:0(?:\\.[0-9]+)?|1(?:\\.0+)?)\\s*\\)$" }, message: "must match pattern \"" + "^rgba\\(\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*(?:0(?:\\.[0-9]+)?|1(?:\\.0+)?)\\s*\\)$" + "\"" };
1624
+ if (vErrors === null) {
1625
+ vErrors = [err4];
1626
+ }
1627
+ else {
1628
+ vErrors.push(err4);
1629
+ }
1630
+ errors++;
1631
+ }
1632
+ }
1633
+ else {
1634
+ const err5 = { instancePath: instancePath + "/color", schemaPath: "#/$defs/rgbaColor/type", keyword: "type", params: { type: "string" }, message: "must be string" };
1635
+ if (vErrors === null) {
1636
+ vErrors = [err5];
1637
+ }
1638
+ else {
1639
+ vErrors.push(err5);
1640
+ }
1641
+ errors++;
1642
+ }
1643
+ }
1644
+ if (data.size !== undefined) {
1645
+ let data1 = data.size;
1646
+ if ((typeof data1 == "number") && (isFinite(data1))) {
1647
+ if (data1 > 20 || isNaN(data1)) {
1648
+ const err6 = { instancePath: instancePath + "/size", schemaPath: "#/properties/size/maximum", keyword: "maximum", params: { comparison: "<=", limit: 20 }, message: "must be <= 20" };
1649
+ if (vErrors === null) {
1650
+ vErrors = [err6];
1651
+ }
1652
+ else {
1653
+ vErrors.push(err6);
1654
+ }
1655
+ errors++;
1656
+ }
1657
+ if (data1 <= 0 || isNaN(data1)) {
1658
+ const err7 = { instancePath: instancePath + "/size", schemaPath: "#/properties/size/exclusiveMinimum", keyword: "exclusiveMinimum", params: { comparison: ">", limit: 0 }, message: "must be > 0" };
1659
+ if (vErrors === null) {
1660
+ vErrors = [err7];
1661
+ }
1662
+ else {
1663
+ vErrors.push(err7);
1664
+ }
1665
+ errors++;
1666
+ }
1667
+ }
1668
+ else {
1669
+ const err8 = { instancePath: instancePath + "/size", schemaPath: "#/properties/size/type", keyword: "type", params: { type: "number" }, message: "must be number" };
1670
+ if (vErrors === null) {
1671
+ vErrors = [err8];
1672
+ }
1673
+ else {
1674
+ vErrors.push(err8);
1675
+ }
1676
+ errors++;
1677
+ }
1678
+ }
1679
+ if (data.style !== undefined) {
1680
+ let data2 = data.style;
1681
+ if (!(((data2 === "solid") || (data2 === "dashed")) || (data2 === "dotted"))) {
1682
+ const err9 = { instancePath: instancePath + "/style", schemaPath: "#/properties/style/enum", keyword: "enum", params: { allowedValues: schema66.properties.style.enum }, message: "must be equal to one of the allowed values" };
1683
+ if (vErrors === null) {
1684
+ vErrors = [err9];
1685
+ }
1686
+ else {
1687
+ vErrors.push(err9);
1688
+ }
1689
+ errors++;
1690
+ }
1691
+ }
1692
+ }
1693
+ else {
1694
+ const err10 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
1695
+ if (vErrors === null) {
1696
+ vErrors = [err10];
1697
+ }
1698
+ else {
1699
+ vErrors.push(err10);
1700
+ }
1701
+ errors++;
1702
+ } validate69.errors = vErrors; return errors === 0; }
1703
+ validate69.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
1704
+ const schema68 = { "type": "object", "additionalProperties": false, "required": ["color"], "properties": { "color": { "$ref": "#/$defs/rgbaColor" } } };
1705
+ function validate71(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate71.evaluated; if (evaluated0.dynamicProps) {
1706
+ evaluated0.props = undefined;
1707
+ } if (evaluated0.dynamicItems) {
1708
+ evaluated0.items = undefined;
1709
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
1710
+ if (data.color === undefined) {
1711
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "color" }, message: "must have required property '" + "color" + "'" };
1712
+ if (vErrors === null) {
1713
+ vErrors = [err0];
1714
+ }
1715
+ else {
1716
+ vErrors.push(err0);
1717
+ }
1718
+ errors++;
1719
+ }
1720
+ for (const key0 in data) {
1721
+ if (!(key0 === "color")) {
1722
+ const err1 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
1723
+ if (vErrors === null) {
1724
+ vErrors = [err1];
1725
+ }
1726
+ else {
1727
+ vErrors.push(err1);
1728
+ }
1729
+ errors++;
1730
+ }
1731
+ }
1732
+ if (data.color !== undefined) {
1733
+ let data0 = data.color;
1734
+ if (typeof data0 === "string") {
1735
+ if (!pattern7.test(data0)) {
1736
+ const err2 = { instancePath: instancePath + "/color", schemaPath: "#/$defs/rgbaColor/pattern", keyword: "pattern", params: { pattern: "^rgba\\(\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*(?:0(?:\\.[0-9]+)?|1(?:\\.0+)?)\\s*\\)$" }, message: "must match pattern \"" + "^rgba\\(\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*(?:0(?:\\.[0-9]+)?|1(?:\\.0+)?)\\s*\\)$" + "\"" };
1737
+ if (vErrors === null) {
1738
+ vErrors = [err2];
1739
+ }
1740
+ else {
1741
+ vErrors.push(err2);
1742
+ }
1743
+ errors++;
1744
+ }
1745
+ }
1746
+ else {
1747
+ const err3 = { instancePath: instancePath + "/color", schemaPath: "#/$defs/rgbaColor/type", keyword: "type", params: { type: "string" }, message: "must be string" };
1748
+ if (vErrors === null) {
1749
+ vErrors = [err3];
1750
+ }
1751
+ else {
1752
+ vErrors.push(err3);
1753
+ }
1754
+ errors++;
1755
+ }
1756
+ }
1757
+ }
1758
+ else {
1759
+ const err4 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
1760
+ if (vErrors === null) {
1761
+ vErrors = [err4];
1762
+ }
1763
+ else {
1764
+ vErrors.push(err4);
1765
+ }
1766
+ errors++;
1767
+ } validate71.errors = vErrors; return errors === 0; }
1768
+ validate71.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
1769
+ const schema70 = { "type": "object", "additionalProperties": false, "required": ["color", "size", "family", "weight", "backgroundColor", "borderColor"], "properties": { "color": { "$ref": "#/$defs/rgbaColor" }, "size": { "type": "number", "minimum": 8, "maximum": 72 }, "family": { "type": "string", "minLength": 1, "maxLength": 128 }, "weight": { "oneOf": [{ "type": "integer", "minimum": 100, "maximum": 900, "multipleOf": 100 }, { "enum": ["normal", "bold"] }] }, "backgroundColor": { "$ref": "#/$defs/rgbaColor" }, "borderColor": { "$ref": "#/$defs/rgbaColor" } } };
1770
+ function validate73(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate73.evaluated; if (evaluated0.dynamicProps) {
1771
+ evaluated0.props = undefined;
1772
+ } if (evaluated0.dynamicItems) {
1773
+ evaluated0.items = undefined;
1774
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
1775
+ if (data.color === undefined) {
1776
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "color" }, message: "must have required property '" + "color" + "'" };
1777
+ if (vErrors === null) {
1778
+ vErrors = [err0];
1779
+ }
1780
+ else {
1781
+ vErrors.push(err0);
1782
+ }
1783
+ errors++;
1784
+ }
1785
+ if (data.size === undefined) {
1786
+ const err1 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "size" }, message: "must have required property '" + "size" + "'" };
1787
+ if (vErrors === null) {
1788
+ vErrors = [err1];
1789
+ }
1790
+ else {
1791
+ vErrors.push(err1);
1792
+ }
1793
+ errors++;
1794
+ }
1795
+ if (data.family === undefined) {
1796
+ const err2 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "family" }, message: "must have required property '" + "family" + "'" };
1797
+ if (vErrors === null) {
1798
+ vErrors = [err2];
1799
+ }
1800
+ else {
1801
+ vErrors.push(err2);
1802
+ }
1803
+ errors++;
1804
+ }
1805
+ if (data.weight === undefined) {
1806
+ const err3 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "weight" }, message: "must have required property '" + "weight" + "'" };
1807
+ if (vErrors === null) {
1808
+ vErrors = [err3];
1809
+ }
1810
+ else {
1811
+ vErrors.push(err3);
1812
+ }
1813
+ errors++;
1814
+ }
1815
+ if (data.backgroundColor === undefined) {
1816
+ const err4 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "backgroundColor" }, message: "must have required property '" + "backgroundColor" + "'" };
1817
+ if (vErrors === null) {
1818
+ vErrors = [err4];
1819
+ }
1820
+ else {
1821
+ vErrors.push(err4);
1822
+ }
1823
+ errors++;
1824
+ }
1825
+ if (data.borderColor === undefined) {
1826
+ const err5 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "borderColor" }, message: "must have required property '" + "borderColor" + "'" };
1827
+ if (vErrors === null) {
1828
+ vErrors = [err5];
1829
+ }
1830
+ else {
1831
+ vErrors.push(err5);
1832
+ }
1833
+ errors++;
1834
+ }
1835
+ for (const key0 in data) {
1836
+ if (!((((((key0 === "color") || (key0 === "size")) || (key0 === "family")) || (key0 === "weight")) || (key0 === "backgroundColor")) || (key0 === "borderColor"))) {
1837
+ const err6 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
1838
+ if (vErrors === null) {
1839
+ vErrors = [err6];
1840
+ }
1841
+ else {
1842
+ vErrors.push(err6);
1843
+ }
1844
+ errors++;
1845
+ }
1846
+ }
1847
+ if (data.color !== undefined) {
1848
+ let data0 = data.color;
1849
+ if (typeof data0 === "string") {
1850
+ if (!pattern7.test(data0)) {
1851
+ const err7 = { instancePath: instancePath + "/color", schemaPath: "#/$defs/rgbaColor/pattern", keyword: "pattern", params: { pattern: "^rgba\\(\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*(?:0(?:\\.[0-9]+)?|1(?:\\.0+)?)\\s*\\)$" }, message: "must match pattern \"" + "^rgba\\(\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*(?:0(?:\\.[0-9]+)?|1(?:\\.0+)?)\\s*\\)$" + "\"" };
1852
+ if (vErrors === null) {
1853
+ vErrors = [err7];
1854
+ }
1855
+ else {
1856
+ vErrors.push(err7);
1857
+ }
1858
+ errors++;
1859
+ }
1860
+ }
1861
+ else {
1862
+ const err8 = { instancePath: instancePath + "/color", schemaPath: "#/$defs/rgbaColor/type", keyword: "type", params: { type: "string" }, message: "must be string" };
1863
+ if (vErrors === null) {
1864
+ vErrors = [err8];
1865
+ }
1866
+ else {
1867
+ vErrors.push(err8);
1868
+ }
1869
+ errors++;
1870
+ }
1871
+ }
1872
+ if (data.size !== undefined) {
1873
+ let data1 = data.size;
1874
+ if ((typeof data1 == "number") && (isFinite(data1))) {
1875
+ if (data1 > 72 || isNaN(data1)) {
1876
+ const err9 = { instancePath: instancePath + "/size", schemaPath: "#/properties/size/maximum", keyword: "maximum", params: { comparison: "<=", limit: 72 }, message: "must be <= 72" };
1877
+ if (vErrors === null) {
1878
+ vErrors = [err9];
1879
+ }
1880
+ else {
1881
+ vErrors.push(err9);
1882
+ }
1883
+ errors++;
1884
+ }
1885
+ if (data1 < 8 || isNaN(data1)) {
1886
+ const err10 = { instancePath: instancePath + "/size", schemaPath: "#/properties/size/minimum", keyword: "minimum", params: { comparison: ">=", limit: 8 }, message: "must be >= 8" };
1887
+ if (vErrors === null) {
1888
+ vErrors = [err10];
1889
+ }
1890
+ else {
1891
+ vErrors.push(err10);
1892
+ }
1893
+ errors++;
1894
+ }
1895
+ }
1896
+ else {
1897
+ const err11 = { instancePath: instancePath + "/size", schemaPath: "#/properties/size/type", keyword: "type", params: { type: "number" }, message: "must be number" };
1898
+ if (vErrors === null) {
1899
+ vErrors = [err11];
1900
+ }
1901
+ else {
1902
+ vErrors.push(err11);
1903
+ }
1904
+ errors++;
1905
+ }
1906
+ }
1907
+ if (data.family !== undefined) {
1908
+ let data2 = data.family;
1909
+ if (typeof data2 === "string") {
1910
+ if (func1(data2) > 128) {
1911
+ const err12 = { instancePath: instancePath + "/family", schemaPath: "#/properties/family/maxLength", keyword: "maxLength", params: { limit: 128 }, message: "must NOT have more than 128 characters" };
1912
+ if (vErrors === null) {
1913
+ vErrors = [err12];
1914
+ }
1915
+ else {
1916
+ vErrors.push(err12);
1917
+ }
1918
+ errors++;
1919
+ }
1920
+ if (func1(data2) < 1) {
1921
+ const err13 = { instancePath: instancePath + "/family", schemaPath: "#/properties/family/minLength", keyword: "minLength", params: { limit: 1 }, message: "must NOT have fewer than 1 characters" };
1922
+ if (vErrors === null) {
1923
+ vErrors = [err13];
1924
+ }
1925
+ else {
1926
+ vErrors.push(err13);
1927
+ }
1928
+ errors++;
1929
+ }
1930
+ }
1931
+ else {
1932
+ const err14 = { instancePath: instancePath + "/family", schemaPath: "#/properties/family/type", keyword: "type", params: { type: "string" }, message: "must be string" };
1933
+ if (vErrors === null) {
1934
+ vErrors = [err14];
1935
+ }
1936
+ else {
1937
+ vErrors.push(err14);
1938
+ }
1939
+ errors++;
1940
+ }
1941
+ }
1942
+ if (data.weight !== undefined) {
1943
+ let data3 = data.weight;
1944
+ const _errs10 = errors;
1945
+ let valid2 = false;
1946
+ let passing0 = null;
1947
+ const _errs11 = errors;
1948
+ if (!(((typeof data3 == "number") && (!(data3 % 1) && !isNaN(data3))) && (isFinite(data3)))) {
1949
+ const err15 = { instancePath: instancePath + "/weight", schemaPath: "#/properties/weight/oneOf/0/type", keyword: "type", params: { type: "integer" }, message: "must be integer" };
1950
+ if (vErrors === null) {
1951
+ vErrors = [err15];
1952
+ }
1953
+ else {
1954
+ vErrors.push(err15);
1955
+ }
1956
+ errors++;
1957
+ }
1958
+ if ((typeof data3 == "number") && (isFinite(data3))) {
1959
+ if (data3 > 900 || isNaN(data3)) {
1960
+ const err16 = { instancePath: instancePath + "/weight", schemaPath: "#/properties/weight/oneOf/0/maximum", keyword: "maximum", params: { comparison: "<=", limit: 900 }, message: "must be <= 900" };
1961
+ if (vErrors === null) {
1962
+ vErrors = [err16];
1963
+ }
1964
+ else {
1965
+ vErrors.push(err16);
1966
+ }
1967
+ errors++;
1968
+ }
1969
+ if (data3 < 100 || isNaN(data3)) {
1970
+ const err17 = { instancePath: instancePath + "/weight", schemaPath: "#/properties/weight/oneOf/0/minimum", keyword: "minimum", params: { comparison: ">=", limit: 100 }, message: "must be >= 100" };
1971
+ if (vErrors === null) {
1972
+ vErrors = [err17];
1973
+ }
1974
+ else {
1975
+ vErrors.push(err17);
1976
+ }
1977
+ errors++;
1978
+ }
1979
+ let res0;
1980
+ if ((100 === 0 || (res0 = data3 / 100, res0 !== parseInt(res0)))) {
1981
+ const err18 = { instancePath: instancePath + "/weight", schemaPath: "#/properties/weight/oneOf/0/multipleOf", keyword: "multipleOf", params: { multipleOf: 100 }, message: "must be multiple of 100" };
1982
+ if (vErrors === null) {
1983
+ vErrors = [err18];
1984
+ }
1985
+ else {
1986
+ vErrors.push(err18);
1987
+ }
1988
+ errors++;
1989
+ }
1990
+ }
1991
+ var _valid0 = _errs11 === errors;
1992
+ if (_valid0) {
1993
+ valid2 = true;
1994
+ passing0 = 0;
1995
+ }
1996
+ const _errs13 = errors;
1997
+ if (!((data3 === "normal") || (data3 === "bold"))) {
1998
+ const err19 = { instancePath: instancePath + "/weight", schemaPath: "#/properties/weight/oneOf/1/enum", keyword: "enum", params: { allowedValues: schema70.properties.weight.oneOf[1].enum }, message: "must be equal to one of the allowed values" };
1999
+ if (vErrors === null) {
2000
+ vErrors = [err19];
2001
+ }
2002
+ else {
2003
+ vErrors.push(err19);
2004
+ }
2005
+ errors++;
2006
+ }
2007
+ var _valid0 = _errs13 === errors;
2008
+ if (_valid0 && valid2) {
2009
+ valid2 = false;
2010
+ passing0 = [passing0, 1];
2011
+ }
2012
+ else {
2013
+ if (_valid0) {
2014
+ valid2 = true;
2015
+ passing0 = 1;
2016
+ }
2017
+ }
2018
+ if (!valid2) {
2019
+ const err20 = { instancePath: instancePath + "/weight", schemaPath: "#/properties/weight/oneOf", keyword: "oneOf", params: { passingSchemas: passing0 }, message: "must match exactly one schema in oneOf" };
2020
+ if (vErrors === null) {
2021
+ vErrors = [err20];
2022
+ }
2023
+ else {
2024
+ vErrors.push(err20);
2025
+ }
2026
+ errors++;
2027
+ }
2028
+ else {
2029
+ errors = _errs10;
2030
+ if (vErrors !== null) {
2031
+ if (_errs10) {
2032
+ vErrors.length = _errs10;
2033
+ }
2034
+ else {
2035
+ vErrors = null;
2036
+ }
2037
+ }
2038
+ }
2039
+ }
2040
+ if (data.backgroundColor !== undefined) {
2041
+ let data4 = data.backgroundColor;
2042
+ if (typeof data4 === "string") {
2043
+ if (!pattern7.test(data4)) {
2044
+ const err21 = { instancePath: instancePath + "/backgroundColor", schemaPath: "#/$defs/rgbaColor/pattern", keyword: "pattern", params: { pattern: "^rgba\\(\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*(?:0(?:\\.[0-9]+)?|1(?:\\.0+)?)\\s*\\)$" }, message: "must match pattern \"" + "^rgba\\(\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*(?:0(?:\\.[0-9]+)?|1(?:\\.0+)?)\\s*\\)$" + "\"" };
2045
+ if (vErrors === null) {
2046
+ vErrors = [err21];
2047
+ }
2048
+ else {
2049
+ vErrors.push(err21);
2050
+ }
2051
+ errors++;
2052
+ }
2053
+ }
2054
+ else {
2055
+ const err22 = { instancePath: instancePath + "/backgroundColor", schemaPath: "#/$defs/rgbaColor/type", keyword: "type", params: { type: "string" }, message: "must be string" };
2056
+ if (vErrors === null) {
2057
+ vErrors = [err22];
2058
+ }
2059
+ else {
2060
+ vErrors.push(err22);
2061
+ }
2062
+ errors++;
2063
+ }
2064
+ }
2065
+ if (data.borderColor !== undefined) {
2066
+ let data5 = data.borderColor;
2067
+ if (typeof data5 === "string") {
2068
+ if (!pattern7.test(data5)) {
2069
+ const err23 = { instancePath: instancePath + "/borderColor", schemaPath: "#/$defs/rgbaColor/pattern", keyword: "pattern", params: { pattern: "^rgba\\(\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*(?:0(?:\\.[0-9]+)?|1(?:\\.0+)?)\\s*\\)$" }, message: "must match pattern \"" + "^rgba\\(\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*[0-9]{1,3}\\s*,\\s*(?:0(?:\\.[0-9]+)?|1(?:\\.0+)?)\\s*\\)$" + "\"" };
2070
+ if (vErrors === null) {
2071
+ vErrors = [err23];
2072
+ }
2073
+ else {
2074
+ vErrors.push(err23);
2075
+ }
2076
+ errors++;
2077
+ }
2078
+ }
2079
+ else {
2080
+ const err24 = { instancePath: instancePath + "/borderColor", schemaPath: "#/$defs/rgbaColor/type", keyword: "type", params: { type: "string" }, message: "must be string" };
2081
+ if (vErrors === null) {
2082
+ vErrors = [err24];
2083
+ }
2084
+ else {
2085
+ vErrors.push(err24);
2086
+ }
2087
+ errors++;
2088
+ }
2089
+ }
2090
+ }
2091
+ else {
2092
+ const err25 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
2093
+ if (vErrors === null) {
2094
+ vErrors = [err25];
2095
+ }
2096
+ else {
2097
+ vErrors.push(err25);
2098
+ }
2099
+ errors++;
2100
+ } validate73.errors = vErrors; return errors === 0; }
2101
+ validate73.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
2102
+ function validate68(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate68.evaluated; if (evaluated0.dynamicProps) {
2103
+ evaluated0.props = undefined;
2104
+ } if (evaluated0.dynamicItems) {
2105
+ evaluated0.items = undefined;
2106
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
2107
+ if (data.line === undefined) {
2108
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "line" }, message: "must have required property '" + "line" + "'" };
2109
+ if (vErrors === null) {
2110
+ vErrors = [err0];
2111
+ }
2112
+ else {
2113
+ vErrors.push(err0);
2114
+ }
2115
+ errors++;
2116
+ }
2117
+ if (data.fill === undefined) {
2118
+ const err1 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "fill" }, message: "must have required property '" + "fill" + "'" };
2119
+ if (vErrors === null) {
2120
+ vErrors = [err1];
2121
+ }
2122
+ else {
2123
+ vErrors.push(err1);
2124
+ }
2125
+ errors++;
2126
+ }
2127
+ if (data.text === undefined) {
2128
+ const err2 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "text" }, message: "must have required property '" + "text" + "'" };
2129
+ if (vErrors === null) {
2130
+ vErrors = [err2];
2131
+ }
2132
+ else {
2133
+ vErrors.push(err2);
2134
+ }
2135
+ errors++;
2136
+ }
2137
+ for (const key0 in data) {
2138
+ if (!(((key0 === "line") || (key0 === "fill")) || (key0 === "text"))) {
2139
+ const err3 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
2140
+ if (vErrors === null) {
2141
+ vErrors = [err3];
2142
+ }
2143
+ else {
2144
+ vErrors.push(err3);
2145
+ }
2146
+ errors++;
2147
+ }
2148
+ }
2149
+ if (data.line !== undefined) {
2150
+ if (!(validate69(data.line, { instancePath: instancePath + "/line", parentData: data, parentDataProperty: "line", rootData, dynamicAnchors }))) {
2151
+ vErrors = vErrors === null ? validate69.errors : vErrors.concat(validate69.errors);
2152
+ errors = vErrors.length;
2153
+ }
2154
+ }
2155
+ if (data.fill !== undefined) {
2156
+ if (!(validate71(data.fill, { instancePath: instancePath + "/fill", parentData: data, parentDataProperty: "fill", rootData, dynamicAnchors }))) {
2157
+ vErrors = vErrors === null ? validate71.errors : vErrors.concat(validate71.errors);
2158
+ errors = vErrors.length;
2159
+ }
2160
+ }
2161
+ if (data.text !== undefined) {
2162
+ if (!(validate73(data.text, { instancePath: instancePath + "/text", parentData: data, parentDataProperty: "text", rootData, dynamicAnchors }))) {
2163
+ vErrors = vErrors === null ? validate73.errors : vErrors.concat(validate73.errors);
2164
+ errors = vErrors.length;
2165
+ }
2166
+ }
2167
+ }
2168
+ else {
2169
+ const err4 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
2170
+ if (vErrors === null) {
2171
+ vErrors = [err4];
2172
+ }
2173
+ else {
2174
+ vErrors.push(err4);
2175
+ }
2176
+ errors++;
2177
+ } validate68.errors = vErrors; return errors === 0; }
2178
+ validate68.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
2179
+ const schema74 = { "type": "object", "maxProperties": 1000, "additionalProperties": { "$ref": "#/$defs/jsonValue" } };
2180
+ const schema75 = { "oneOf": [{ "type": "null" }, { "type": "boolean" }, { "$ref": "#/$defs/finiteNumber" }, { "type": "string" }, { "type": "array", "maxItems": 1000, "items": { "$ref": "#/$defs/jsonValue" } }, { "type": "object", "maxProperties": 1000, "additionalProperties": { "$ref": "#/$defs/jsonValue" } }] };
2181
+ const wrapper0 = { validate: validate77 };
2182
+ function validate77(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate77.evaluated; if (evaluated0.dynamicProps) {
2183
+ evaluated0.props = undefined;
2184
+ } if (evaluated0.dynamicItems) {
2185
+ evaluated0.items = undefined;
2186
+ } const _errs0 = errors; let valid0 = false; let passing0 = null; const _errs1 = errors; if (data !== null) {
2187
+ const err0 = { instancePath, schemaPath: "#/oneOf/0/type", keyword: "type", params: { type: "null" }, message: "must be null" };
2188
+ if (vErrors === null) {
2189
+ vErrors = [err0];
2190
+ }
2191
+ else {
2192
+ vErrors.push(err0);
2193
+ }
2194
+ errors++;
2195
+ } var _valid0 = _errs1 === errors; if (_valid0) {
2196
+ valid0 = true;
2197
+ passing0 = 0;
2198
+ } const _errs3 = errors; if (typeof data !== "boolean") {
2199
+ const err1 = { instancePath, schemaPath: "#/oneOf/1/type", keyword: "type", params: { type: "boolean" }, message: "must be boolean" };
2200
+ if (vErrors === null) {
2201
+ vErrors = [err1];
2202
+ }
2203
+ else {
2204
+ vErrors.push(err1);
2205
+ }
2206
+ errors++;
2207
+ } var _valid0 = _errs3 === errors; if (_valid0 && valid0) {
2208
+ valid0 = false;
2209
+ passing0 = [passing0, 1];
2210
+ }
2211
+ else {
2212
+ if (_valid0) {
2213
+ valid0 = true;
2214
+ passing0 = 1;
2215
+ }
2216
+ const _errs5 = errors;
2217
+ if ((typeof data == "number") && (isFinite(data))) {
2218
+ if (data > 1.7976931348623157e+308 || isNaN(data)) {
2219
+ const err2 = { instancePath, schemaPath: "#/$defs/finiteNumber/maximum", keyword: "maximum", params: { comparison: "<=", limit: 1.7976931348623157e+308 }, message: "must be <= 1.7976931348623157e+308" };
2220
+ if (vErrors === null) {
2221
+ vErrors = [err2];
2222
+ }
2223
+ else {
2224
+ vErrors.push(err2);
2225
+ }
2226
+ errors++;
2227
+ }
2228
+ if (data < -1.7976931348623157e+308 || isNaN(data)) {
2229
+ const err3 = { instancePath, schemaPath: "#/$defs/finiteNumber/minimum", keyword: "minimum", params: { comparison: ">=", limit: -1.7976931348623157e+308 }, message: "must be >= -1.7976931348623157e+308" };
2230
+ if (vErrors === null) {
2231
+ vErrors = [err3];
2232
+ }
2233
+ else {
2234
+ vErrors.push(err3);
2235
+ }
2236
+ errors++;
2237
+ }
2238
+ }
2239
+ else {
2240
+ const err4 = { instancePath, schemaPath: "#/$defs/finiteNumber/type", keyword: "type", params: { type: "number" }, message: "must be number" };
2241
+ if (vErrors === null) {
2242
+ vErrors = [err4];
2243
+ }
2244
+ else {
2245
+ vErrors.push(err4);
2246
+ }
2247
+ errors++;
2248
+ }
2249
+ var _valid0 = _errs5 === errors;
2250
+ if (_valid0 && valid0) {
2251
+ valid0 = false;
2252
+ passing0 = [passing0, 2];
2253
+ }
2254
+ else {
2255
+ if (_valid0) {
2256
+ valid0 = true;
2257
+ passing0 = 2;
2258
+ }
2259
+ const _errs8 = errors;
2260
+ if (typeof data !== "string") {
2261
+ const err5 = { instancePath, schemaPath: "#/oneOf/3/type", keyword: "type", params: { type: "string" }, message: "must be string" };
2262
+ if (vErrors === null) {
2263
+ vErrors = [err5];
2264
+ }
2265
+ else {
2266
+ vErrors.push(err5);
2267
+ }
2268
+ errors++;
2269
+ }
2270
+ var _valid0 = _errs8 === errors;
2271
+ if (_valid0 && valid0) {
2272
+ valid0 = false;
2273
+ passing0 = [passing0, 3];
2274
+ }
2275
+ else {
2276
+ if (_valid0) {
2277
+ valid0 = true;
2278
+ passing0 = 3;
2279
+ }
2280
+ const _errs10 = errors;
2281
+ if (Array.isArray(data)) {
2282
+ if (data.length > 1000) {
2283
+ const err6 = { instancePath, schemaPath: "#/oneOf/4/maxItems", keyword: "maxItems", params: { limit: 1000 }, message: "must NOT have more than 1000 items" };
2284
+ if (vErrors === null) {
2285
+ vErrors = [err6];
2286
+ }
2287
+ else {
2288
+ vErrors.push(err6);
2289
+ }
2290
+ errors++;
2291
+ }
2292
+ const len0 = data.length;
2293
+ for (let i0 = 0; i0 < len0; i0++) {
2294
+ if (!(wrapper0.validate(data[i0], { instancePath: instancePath + "/" + i0, parentData: data, parentDataProperty: i0, rootData, dynamicAnchors }))) {
2295
+ vErrors = vErrors === null ? wrapper0.validate.errors : vErrors.concat(wrapper0.validate.errors);
2296
+ errors = vErrors.length;
2297
+ }
2298
+ }
2299
+ }
2300
+ else {
2301
+ const err7 = { instancePath, schemaPath: "#/oneOf/4/type", keyword: "type", params: { type: "array" }, message: "must be array" };
2302
+ if (vErrors === null) {
2303
+ vErrors = [err7];
2304
+ }
2305
+ else {
2306
+ vErrors.push(err7);
2307
+ }
2308
+ errors++;
2309
+ }
2310
+ var _valid0 = _errs10 === errors;
2311
+ if (_valid0 && valid0) {
2312
+ valid0 = false;
2313
+ passing0 = [passing0, 4];
2314
+ }
2315
+ else {
2316
+ if (_valid0) {
2317
+ valid0 = true;
2318
+ passing0 = 4;
2319
+ var items1 = true;
2320
+ }
2321
+ const _errs13 = errors;
2322
+ if (data && typeof data == "object" && !Array.isArray(data)) {
2323
+ if (Object.keys(data).length > 1000) {
2324
+ const err8 = { instancePath, schemaPath: "#/oneOf/5/maxProperties", keyword: "maxProperties", params: { limit: 1000 }, message: "must NOT have more than 1000 properties" };
2325
+ if (vErrors === null) {
2326
+ vErrors = [err8];
2327
+ }
2328
+ else {
2329
+ vErrors.push(err8);
2330
+ }
2331
+ errors++;
2332
+ }
2333
+ for (const key0 in data) {
2334
+ if (!(wrapper0.validate(data[key0], { instancePath: instancePath + "/" + key0.replace(/~/g, "~0").replace(/\//g, "~1"), parentData: data, parentDataProperty: key0, rootData, dynamicAnchors }))) {
2335
+ vErrors = vErrors === null ? wrapper0.validate.errors : vErrors.concat(wrapper0.validate.errors);
2336
+ errors = vErrors.length;
2337
+ }
2338
+ }
2339
+ }
2340
+ else {
2341
+ const err9 = { instancePath, schemaPath: "#/oneOf/5/type", keyword: "type", params: { type: "object" }, message: "must be object" };
2342
+ if (vErrors === null) {
2343
+ vErrors = [err9];
2344
+ }
2345
+ else {
2346
+ vErrors.push(err9);
2347
+ }
2348
+ errors++;
2349
+ }
2350
+ var _valid0 = _errs13 === errors;
2351
+ if (_valid0 && valid0) {
2352
+ valid0 = false;
2353
+ passing0 = [passing0, 5];
2354
+ }
2355
+ else {
2356
+ if (_valid0) {
2357
+ valid0 = true;
2358
+ passing0 = 5;
2359
+ var props2 = true;
2360
+ }
2361
+ }
2362
+ }
2363
+ }
2364
+ }
2365
+ } if (!valid0) {
2366
+ const err10 = { instancePath, schemaPath: "#/oneOf", keyword: "oneOf", params: { passingSchemas: passing0 }, message: "must match exactly one schema in oneOf" };
2367
+ if (vErrors === null) {
2368
+ vErrors = [err10];
2369
+ }
2370
+ else {
2371
+ vErrors.push(err10);
2372
+ }
2373
+ errors++;
2374
+ }
2375
+ else {
2376
+ errors = _errs0;
2377
+ if (vErrors !== null) {
2378
+ if (_errs0) {
2379
+ vErrors.length = _errs0;
2380
+ }
2381
+ else {
2382
+ vErrors = null;
2383
+ }
2384
+ }
2385
+ } validate77.errors = vErrors; evaluated0.props = props2; evaluated0.items = items1; return errors === 0; }
2386
+ validate77.evaluated = { "dynamicProps": true, "dynamicItems": true };
2387
+ function validate76(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate76.evaluated; if (evaluated0.dynamicProps) {
2388
+ evaluated0.props = undefined;
2389
+ } if (evaluated0.dynamicItems) {
2390
+ evaluated0.items = undefined;
2391
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
2392
+ if (Object.keys(data).length > 1000) {
2393
+ const err0 = { instancePath, schemaPath: "#/maxProperties", keyword: "maxProperties", params: { limit: 1000 }, message: "must NOT have more than 1000 properties" };
2394
+ if (vErrors === null) {
2395
+ vErrors = [err0];
2396
+ }
2397
+ else {
2398
+ vErrors.push(err0);
2399
+ }
2400
+ errors++;
2401
+ }
2402
+ for (const key0 in data) {
2403
+ if (!(validate77(data[key0], { instancePath: instancePath + "/" + key0.replace(/~/g, "~0").replace(/\//g, "~1"), parentData: data, parentDataProperty: key0, rootData, dynamicAnchors }))) {
2404
+ vErrors = vErrors === null ? validate77.errors : vErrors.concat(validate77.errors);
2405
+ errors = vErrors.length;
2406
+ }
2407
+ }
2408
+ }
2409
+ else {
2410
+ const err1 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
2411
+ if (vErrors === null) {
2412
+ vErrors = [err1];
2413
+ }
2414
+ else {
2415
+ vErrors.push(err1);
2416
+ }
2417
+ errors++;
2418
+ } validate76.errors = vErrors; return errors === 0; }
2419
+ validate76.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
2420
+ const func11 = Object.prototype.hasOwnProperty;
2421
+ const pattern5 = new RegExp("^[A-Za-z][A-Za-z0-9._:-]*$", "u");
2422
+ function validate25(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { let vErrors = null; let errors = 0; const evaluated0 = validate25.evaluated; if (evaluated0.dynamicProps) {
2423
+ evaluated0.props = undefined;
2424
+ } if (evaluated0.dynamicItems) {
2425
+ evaluated0.items = undefined;
2426
+ } const _errs1 = errors; let valid0 = false; let passing0 = null; const _errs2 = errors; if (data && typeof data == "object" && !Array.isArray(data)) {
2427
+ if (data.type === undefined) {
2428
+ const err0 = { instancePath, schemaPath: "#/oneOf/0/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
2429
+ if (vErrors === null) {
2430
+ vErrors = [err0];
2431
+ }
2432
+ else {
2433
+ vErrors.push(err0);
2434
+ }
2435
+ errors++;
2436
+ }
2437
+ if (data.geometry === undefined) {
2438
+ const err1 = { instancePath, schemaPath: "#/oneOf/0/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
2439
+ if (vErrors === null) {
2440
+ vErrors = [err1];
2441
+ }
2442
+ else {
2443
+ vErrors.push(err1);
2444
+ }
2445
+ errors++;
2446
+ }
2447
+ if (data.type !== undefined) {
2448
+ if ("horizontalStraightLine" !== data.type) {
2449
+ const err2 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/0/properties/type/const", keyword: "const", params: { allowedValue: "horizontalStraightLine" }, message: "must be equal to constant" };
2450
+ if (vErrors === null) {
2451
+ vErrors = [err2];
2452
+ }
2453
+ else {
2454
+ vErrors.push(err2);
2455
+ }
2456
+ errors++;
2457
+ }
2458
+ }
2459
+ if (data.geometry !== undefined) {
2460
+ if (!(validate26(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
2461
+ vErrors = vErrors === null ? validate26.errors : vErrors.concat(validate26.errors);
2462
+ errors = vErrors.length;
2463
+ }
2464
+ }
2465
+ } var _valid0 = _errs2 === errors; if (_valid0) {
2466
+ valid0 = true;
2467
+ passing0 = 0;
2468
+ var props0 = {};
2469
+ props0.type = true;
2470
+ props0.geometry = true;
2471
+ } const _errs5 = errors; if (data && typeof data == "object" && !Array.isArray(data)) {
2472
+ if (data.type === undefined) {
2473
+ const err3 = { instancePath, schemaPath: "#/oneOf/1/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
2474
+ if (vErrors === null) {
2475
+ vErrors = [err3];
2476
+ }
2477
+ else {
2478
+ vErrors.push(err3);
2479
+ }
2480
+ errors++;
2481
+ }
2482
+ if (data.geometry === undefined) {
2483
+ const err4 = { instancePath, schemaPath: "#/oneOf/1/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
2484
+ if (vErrors === null) {
2485
+ vErrors = [err4];
2486
+ }
2487
+ else {
2488
+ vErrors.push(err4);
2489
+ }
2490
+ errors++;
2491
+ }
2492
+ if (data.type !== undefined) {
2493
+ if ("priceLine" !== data.type) {
2494
+ const err5 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/1/properties/type/const", keyword: "const", params: { allowedValue: "priceLine" }, message: "must be equal to constant" };
2495
+ if (vErrors === null) {
2496
+ vErrors = [err5];
2497
+ }
2498
+ else {
2499
+ vErrors.push(err5);
2500
+ }
2501
+ errors++;
2502
+ }
2503
+ }
2504
+ if (data.geometry !== undefined) {
2505
+ if (!(validate26(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
2506
+ vErrors = vErrors === null ? validate26.errors : vErrors.concat(validate26.errors);
2507
+ errors = vErrors.length;
2508
+ }
2509
+ }
2510
+ } var _valid0 = _errs5 === errors; if (_valid0 && valid0) {
2511
+ valid0 = false;
2512
+ passing0 = [passing0, 1];
2513
+ }
2514
+ else {
2515
+ if (_valid0) {
2516
+ valid0 = true;
2517
+ passing0 = 1;
2518
+ if (props0 !== true) {
2519
+ props0 = props0 || {};
2520
+ props0.type = true;
2521
+ props0.geometry = true;
2522
+ }
2523
+ }
2524
+ const _errs8 = errors;
2525
+ if (data && typeof data == "object" && !Array.isArray(data)) {
2526
+ if (data.type === undefined) {
2527
+ const err6 = { instancePath, schemaPath: "#/oneOf/2/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
2528
+ if (vErrors === null) {
2529
+ vErrors = [err6];
2530
+ }
2531
+ else {
2532
+ vErrors.push(err6);
2533
+ }
2534
+ errors++;
2535
+ }
2536
+ if (data.geometry === undefined) {
2537
+ const err7 = { instancePath, schemaPath: "#/oneOf/2/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
2538
+ if (vErrors === null) {
2539
+ vErrors = [err7];
2540
+ }
2541
+ else {
2542
+ vErrors.push(err7);
2543
+ }
2544
+ errors++;
2545
+ }
2546
+ if (data.type !== undefined) {
2547
+ if ("simpleTag" !== data.type) {
2548
+ const err8 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/2/properties/type/const", keyword: "const", params: { allowedValue: "simpleTag" }, message: "must be equal to constant" };
2549
+ if (vErrors === null) {
2550
+ vErrors = [err8];
2551
+ }
2552
+ else {
2553
+ vErrors.push(err8);
2554
+ }
2555
+ errors++;
2556
+ }
2557
+ }
2558
+ if (data.geometry !== undefined) {
2559
+ if (!(validate30(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
2560
+ vErrors = vErrors === null ? validate30.errors : vErrors.concat(validate30.errors);
2561
+ errors = vErrors.length;
2562
+ }
2563
+ }
2564
+ }
2565
+ var _valid0 = _errs8 === errors;
2566
+ if (_valid0 && valid0) {
2567
+ valid0 = false;
2568
+ passing0 = [passing0, 2];
2569
+ }
2570
+ else {
2571
+ if (_valid0) {
2572
+ valid0 = true;
2573
+ passing0 = 2;
2574
+ if (props0 !== true) {
2575
+ props0 = props0 || {};
2576
+ props0.type = true;
2577
+ props0.geometry = true;
2578
+ }
2579
+ }
2580
+ const _errs11 = errors;
2581
+ if (data && typeof data == "object" && !Array.isArray(data)) {
2582
+ if (data.type === undefined) {
2583
+ const err9 = { instancePath, schemaPath: "#/oneOf/3/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
2584
+ if (vErrors === null) {
2585
+ vErrors = [err9];
2586
+ }
2587
+ else {
2588
+ vErrors.push(err9);
2589
+ }
2590
+ errors++;
2591
+ }
2592
+ if (data.geometry === undefined) {
2593
+ const err10 = { instancePath, schemaPath: "#/oneOf/3/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
2594
+ if (vErrors === null) {
2595
+ vErrors = [err10];
2596
+ }
2597
+ else {
2598
+ vErrors.push(err10);
2599
+ }
2600
+ errors++;
2601
+ }
2602
+ if (data.type !== undefined) {
2603
+ if ("verticalStraightLine" !== data.type) {
2604
+ const err11 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/3/properties/type/const", keyword: "const", params: { allowedValue: "verticalStraightLine" }, message: "must be equal to constant" };
2605
+ if (vErrors === null) {
2606
+ vErrors = [err11];
2607
+ }
2608
+ else {
2609
+ vErrors.push(err11);
2610
+ }
2611
+ errors++;
2612
+ }
2613
+ }
2614
+ if (data.geometry !== undefined) {
2615
+ if (!(validate32(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
2616
+ vErrors = vErrors === null ? validate32.errors : vErrors.concat(validate32.errors);
2617
+ errors = vErrors.length;
2618
+ }
2619
+ }
2620
+ }
2621
+ var _valid0 = _errs11 === errors;
2622
+ if (_valid0 && valid0) {
2623
+ valid0 = false;
2624
+ passing0 = [passing0, 3];
2625
+ }
2626
+ else {
2627
+ if (_valid0) {
2628
+ valid0 = true;
2629
+ passing0 = 3;
2630
+ if (props0 !== true) {
2631
+ props0 = props0 || {};
2632
+ props0.type = true;
2633
+ props0.geometry = true;
2634
+ }
2635
+ }
2636
+ const _errs14 = errors;
2637
+ if (data && typeof data == "object" && !Array.isArray(data)) {
2638
+ if (data.type === undefined) {
2639
+ const err12 = { instancePath, schemaPath: "#/oneOf/4/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
2640
+ if (vErrors === null) {
2641
+ vErrors = [err12];
2642
+ }
2643
+ else {
2644
+ vErrors.push(err12);
2645
+ }
2646
+ errors++;
2647
+ }
2648
+ if (data.geometry === undefined) {
2649
+ const err13 = { instancePath, schemaPath: "#/oneOf/4/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
2650
+ if (vErrors === null) {
2651
+ vErrors = [err13];
2652
+ }
2653
+ else {
2654
+ vErrors.push(err13);
2655
+ }
2656
+ errors++;
2657
+ }
2658
+ if (data.type !== undefined) {
2659
+ if ("horizontalRayLine" !== data.type) {
2660
+ const err14 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/4/properties/type/const", keyword: "const", params: { allowedValue: "horizontalRayLine" }, message: "must be equal to constant" };
2661
+ if (vErrors === null) {
2662
+ vErrors = [err14];
2663
+ }
2664
+ else {
2665
+ vErrors.push(err14);
2666
+ }
2667
+ errors++;
2668
+ }
2669
+ }
2670
+ if (data.geometry !== undefined) {
2671
+ if (!(validate34(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
2672
+ vErrors = vErrors === null ? validate34.errors : vErrors.concat(validate34.errors);
2673
+ errors = vErrors.length;
2674
+ }
2675
+ }
2676
+ }
2677
+ var _valid0 = _errs14 === errors;
2678
+ if (_valid0 && valid0) {
2679
+ valid0 = false;
2680
+ passing0 = [passing0, 4];
2681
+ }
2682
+ else {
2683
+ if (_valid0) {
2684
+ valid0 = true;
2685
+ passing0 = 4;
2686
+ if (props0 !== true) {
2687
+ props0 = props0 || {};
2688
+ props0.type = true;
2689
+ props0.geometry = true;
2690
+ }
2691
+ }
2692
+ const _errs17 = errors;
2693
+ if (data && typeof data == "object" && !Array.isArray(data)) {
2694
+ if (data.type === undefined) {
2695
+ const err15 = { instancePath, schemaPath: "#/oneOf/5/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
2696
+ if (vErrors === null) {
2697
+ vErrors = [err15];
2698
+ }
2699
+ else {
2700
+ vErrors.push(err15);
2701
+ }
2702
+ errors++;
2703
+ }
2704
+ if (data.geometry === undefined) {
2705
+ const err16 = { instancePath, schemaPath: "#/oneOf/5/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
2706
+ if (vErrors === null) {
2707
+ vErrors = [err16];
2708
+ }
2709
+ else {
2710
+ vErrors.push(err16);
2711
+ }
2712
+ errors++;
2713
+ }
2714
+ if (data.type !== undefined) {
2715
+ if ("horizontalSegment" !== data.type) {
2716
+ const err17 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/5/properties/type/const", keyword: "const", params: { allowedValue: "horizontalSegment" }, message: "must be equal to constant" };
2717
+ if (vErrors === null) {
2718
+ vErrors = [err17];
2719
+ }
2720
+ else {
2721
+ vErrors.push(err17);
2722
+ }
2723
+ errors++;
2724
+ }
2725
+ }
2726
+ if (data.geometry !== undefined) {
2727
+ if (!(validate34(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
2728
+ vErrors = vErrors === null ? validate34.errors : vErrors.concat(validate34.errors);
2729
+ errors = vErrors.length;
2730
+ }
2731
+ }
2732
+ }
2733
+ var _valid0 = _errs17 === errors;
2734
+ if (_valid0 && valid0) {
2735
+ valid0 = false;
2736
+ passing0 = [passing0, 5];
2737
+ }
2738
+ else {
2739
+ if (_valid0) {
2740
+ valid0 = true;
2741
+ passing0 = 5;
2742
+ if (props0 !== true) {
2743
+ props0 = props0 || {};
2744
+ props0.type = true;
2745
+ props0.geometry = true;
2746
+ }
2747
+ }
2748
+ const _errs20 = errors;
2749
+ if (data && typeof data == "object" && !Array.isArray(data)) {
2750
+ if (data.type === undefined) {
2751
+ const err18 = { instancePath, schemaPath: "#/oneOf/6/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
2752
+ if (vErrors === null) {
2753
+ vErrors = [err18];
2754
+ }
2755
+ else {
2756
+ vErrors.push(err18);
2757
+ }
2758
+ errors++;
2759
+ }
2760
+ if (data.geometry === undefined) {
2761
+ const err19 = { instancePath, schemaPath: "#/oneOf/6/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
2762
+ if (vErrors === null) {
2763
+ vErrors = [err19];
2764
+ }
2765
+ else {
2766
+ vErrors.push(err19);
2767
+ }
2768
+ errors++;
2769
+ }
2770
+ if (data.type !== undefined) {
2771
+ if ("verticalRayLine" !== data.type) {
2772
+ const err20 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/6/properties/type/const", keyword: "const", params: { allowedValue: "verticalRayLine" }, message: "must be equal to constant" };
2773
+ if (vErrors === null) {
2774
+ vErrors = [err20];
2775
+ }
2776
+ else {
2777
+ vErrors.push(err20);
2778
+ }
2779
+ errors++;
2780
+ }
2781
+ }
2782
+ if (data.geometry !== undefined) {
2783
+ if (!(validate37(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
2784
+ vErrors = vErrors === null ? validate37.errors : vErrors.concat(validate37.errors);
2785
+ errors = vErrors.length;
2786
+ }
2787
+ }
2788
+ }
2789
+ var _valid0 = _errs20 === errors;
2790
+ if (_valid0 && valid0) {
2791
+ valid0 = false;
2792
+ passing0 = [passing0, 6];
2793
+ }
2794
+ else {
2795
+ if (_valid0) {
2796
+ valid0 = true;
2797
+ passing0 = 6;
2798
+ if (props0 !== true) {
2799
+ props0 = props0 || {};
2800
+ props0.type = true;
2801
+ props0.geometry = true;
2802
+ }
2803
+ }
2804
+ const _errs23 = errors;
2805
+ if (data && typeof data == "object" && !Array.isArray(data)) {
2806
+ if (data.type === undefined) {
2807
+ const err21 = { instancePath, schemaPath: "#/oneOf/7/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
2808
+ if (vErrors === null) {
2809
+ vErrors = [err21];
2810
+ }
2811
+ else {
2812
+ vErrors.push(err21);
2813
+ }
2814
+ errors++;
2815
+ }
2816
+ if (data.geometry === undefined) {
2817
+ const err22 = { instancePath, schemaPath: "#/oneOf/7/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
2818
+ if (vErrors === null) {
2819
+ vErrors = [err22];
2820
+ }
2821
+ else {
2822
+ vErrors.push(err22);
2823
+ }
2824
+ errors++;
2825
+ }
2826
+ if (data.type !== undefined) {
2827
+ if ("verticalSegment" !== data.type) {
2828
+ const err23 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/7/properties/type/const", keyword: "const", params: { allowedValue: "verticalSegment" }, message: "must be equal to constant" };
2829
+ if (vErrors === null) {
2830
+ vErrors = [err23];
2831
+ }
2832
+ else {
2833
+ vErrors.push(err23);
2834
+ }
2835
+ errors++;
2836
+ }
2837
+ }
2838
+ if (data.geometry !== undefined) {
2839
+ if (!(validate37(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
2840
+ vErrors = vErrors === null ? validate37.errors : vErrors.concat(validate37.errors);
2841
+ errors = vErrors.length;
2842
+ }
2843
+ }
2844
+ }
2845
+ var _valid0 = _errs23 === errors;
2846
+ if (_valid0 && valid0) {
2847
+ valid0 = false;
2848
+ passing0 = [passing0, 7];
2849
+ }
2850
+ else {
2851
+ if (_valid0) {
2852
+ valid0 = true;
2853
+ passing0 = 7;
2854
+ if (props0 !== true) {
2855
+ props0 = props0 || {};
2856
+ props0.type = true;
2857
+ props0.geometry = true;
2858
+ }
2859
+ }
2860
+ const _errs26 = errors;
2861
+ if (data && typeof data == "object" && !Array.isArray(data)) {
2862
+ if (data.type === undefined) {
2863
+ const err24 = { instancePath, schemaPath: "#/oneOf/8/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
2864
+ if (vErrors === null) {
2865
+ vErrors = [err24];
2866
+ }
2867
+ else {
2868
+ vErrors.push(err24);
2869
+ }
2870
+ errors++;
2871
+ }
2872
+ if (data.geometry === undefined) {
2873
+ const err25 = { instancePath, schemaPath: "#/oneOf/8/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
2874
+ if (vErrors === null) {
2875
+ vErrors = [err25];
2876
+ }
2877
+ else {
2878
+ vErrors.push(err25);
2879
+ }
2880
+ errors++;
2881
+ }
2882
+ if (data.type !== undefined) {
2883
+ if ("rayLine" !== data.type) {
2884
+ const err26 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/8/properties/type/const", keyword: "const", params: { allowedValue: "rayLine" }, message: "must be equal to constant" };
2885
+ if (vErrors === null) {
2886
+ vErrors = [err26];
2887
+ }
2888
+ else {
2889
+ vErrors.push(err26);
2890
+ }
2891
+ errors++;
2892
+ }
2893
+ }
2894
+ if (data.geometry !== undefined) {
2895
+ if (!(validate40(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
2896
+ vErrors = vErrors === null ? validate40.errors : vErrors.concat(validate40.errors);
2897
+ errors = vErrors.length;
2898
+ }
2899
+ }
2900
+ }
2901
+ var _valid0 = _errs26 === errors;
2902
+ if (_valid0 && valid0) {
2903
+ valid0 = false;
2904
+ passing0 = [passing0, 8];
2905
+ }
2906
+ else {
2907
+ if (_valid0) {
2908
+ valid0 = true;
2909
+ passing0 = 8;
2910
+ if (props0 !== true) {
2911
+ props0 = props0 || {};
2912
+ props0.type = true;
2913
+ props0.geometry = true;
2914
+ }
2915
+ }
2916
+ const _errs29 = errors;
2917
+ if (data && typeof data == "object" && !Array.isArray(data)) {
2918
+ if (data.type === undefined) {
2919
+ const err27 = { instancePath, schemaPath: "#/oneOf/9/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
2920
+ if (vErrors === null) {
2921
+ vErrors = [err27];
2922
+ }
2923
+ else {
2924
+ vErrors.push(err27);
2925
+ }
2926
+ errors++;
2927
+ }
2928
+ if (data.geometry === undefined) {
2929
+ const err28 = { instancePath, schemaPath: "#/oneOf/9/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
2930
+ if (vErrors === null) {
2931
+ vErrors = [err28];
2932
+ }
2933
+ else {
2934
+ vErrors.push(err28);
2935
+ }
2936
+ errors++;
2937
+ }
2938
+ if (data.type !== undefined) {
2939
+ if ("segment" !== data.type) {
2940
+ const err29 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/9/properties/type/const", keyword: "const", params: { allowedValue: "segment" }, message: "must be equal to constant" };
2941
+ if (vErrors === null) {
2942
+ vErrors = [err29];
2943
+ }
2944
+ else {
2945
+ vErrors.push(err29);
2946
+ }
2947
+ errors++;
2948
+ }
2949
+ }
2950
+ if (data.geometry !== undefined) {
2951
+ if (!(validate40(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
2952
+ vErrors = vErrors === null ? validate40.errors : vErrors.concat(validate40.errors);
2953
+ errors = vErrors.length;
2954
+ }
2955
+ }
2956
+ }
2957
+ var _valid0 = _errs29 === errors;
2958
+ if (_valid0 && valid0) {
2959
+ valid0 = false;
2960
+ passing0 = [passing0, 9];
2961
+ }
2962
+ else {
2963
+ if (_valid0) {
2964
+ valid0 = true;
2965
+ passing0 = 9;
2966
+ if (props0 !== true) {
2967
+ props0 = props0 || {};
2968
+ props0.type = true;
2969
+ props0.geometry = true;
2970
+ }
2971
+ }
2972
+ const _errs32 = errors;
2973
+ if (data && typeof data == "object" && !Array.isArray(data)) {
2974
+ if (data.type === undefined) {
2975
+ const err30 = { instancePath, schemaPath: "#/oneOf/10/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
2976
+ if (vErrors === null) {
2977
+ vErrors = [err30];
2978
+ }
2979
+ else {
2980
+ vErrors.push(err30);
2981
+ }
2982
+ errors++;
2983
+ }
2984
+ if (data.geometry === undefined) {
2985
+ const err31 = { instancePath, schemaPath: "#/oneOf/10/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
2986
+ if (vErrors === null) {
2987
+ vErrors = [err31];
2988
+ }
2989
+ else {
2990
+ vErrors.push(err31);
2991
+ }
2992
+ errors++;
2993
+ }
2994
+ if (data.type !== undefined) {
2995
+ if ("straightLine" !== data.type) {
2996
+ const err32 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/10/properties/type/const", keyword: "const", params: { allowedValue: "straightLine" }, message: "must be equal to constant" };
2997
+ if (vErrors === null) {
2998
+ vErrors = [err32];
2999
+ }
3000
+ else {
3001
+ vErrors.push(err32);
3002
+ }
3003
+ errors++;
3004
+ }
3005
+ }
3006
+ if (data.geometry !== undefined) {
3007
+ if (!(validate40(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
3008
+ vErrors = vErrors === null ? validate40.errors : vErrors.concat(validate40.errors);
3009
+ errors = vErrors.length;
3010
+ }
3011
+ }
3012
+ }
3013
+ var _valid0 = _errs32 === errors;
3014
+ if (_valid0 && valid0) {
3015
+ valid0 = false;
3016
+ passing0 = [passing0, 10];
3017
+ }
3018
+ else {
3019
+ if (_valid0) {
3020
+ valid0 = true;
3021
+ passing0 = 10;
3022
+ if (props0 !== true) {
3023
+ props0 = props0 || {};
3024
+ props0.type = true;
3025
+ props0.geometry = true;
3026
+ }
3027
+ }
3028
+ const _errs35 = errors;
3029
+ if (data && typeof data == "object" && !Array.isArray(data)) {
3030
+ if (data.type === undefined) {
3031
+ const err33 = { instancePath, schemaPath: "#/oneOf/11/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
3032
+ if (vErrors === null) {
3033
+ vErrors = [err33];
3034
+ }
3035
+ else {
3036
+ vErrors.push(err33);
3037
+ }
3038
+ errors++;
3039
+ }
3040
+ if (data.geometry === undefined) {
3041
+ const err34 = { instancePath, schemaPath: "#/oneOf/11/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
3042
+ if (vErrors === null) {
3043
+ vErrors = [err34];
3044
+ }
3045
+ else {
3046
+ vErrors.push(err34);
3047
+ }
3048
+ errors++;
3049
+ }
3050
+ if (data.type !== undefined) {
3051
+ if ("fibonacciLine" !== data.type) {
3052
+ const err35 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/11/properties/type/const", keyword: "const", params: { allowedValue: "fibonacciLine" }, message: "must be equal to constant" };
3053
+ if (vErrors === null) {
3054
+ vErrors = [err35];
3055
+ }
3056
+ else {
3057
+ vErrors.push(err35);
3058
+ }
3059
+ errors++;
3060
+ }
3061
+ }
3062
+ if (data.geometry !== undefined) {
3063
+ if (!(validate40(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
3064
+ vErrors = vErrors === null ? validate40.errors : vErrors.concat(validate40.errors);
3065
+ errors = vErrors.length;
3066
+ }
3067
+ }
3068
+ }
3069
+ var _valid0 = _errs35 === errors;
3070
+ if (_valid0 && valid0) {
3071
+ valid0 = false;
3072
+ passing0 = [passing0, 11];
3073
+ }
3074
+ else {
3075
+ if (_valid0) {
3076
+ valid0 = true;
3077
+ passing0 = 11;
3078
+ if (props0 !== true) {
3079
+ props0 = props0 || {};
3080
+ props0.type = true;
3081
+ props0.geometry = true;
3082
+ }
3083
+ }
3084
+ const _errs38 = errors;
3085
+ if (data && typeof data == "object" && !Array.isArray(data)) {
3086
+ if (data.type === undefined) {
3087
+ const err36 = { instancePath, schemaPath: "#/oneOf/12/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
3088
+ if (vErrors === null) {
3089
+ vErrors = [err36];
3090
+ }
3091
+ else {
3092
+ vErrors.push(err36);
3093
+ }
3094
+ errors++;
3095
+ }
3096
+ if (data.geometry === undefined) {
3097
+ const err37 = { instancePath, schemaPath: "#/oneOf/12/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
3098
+ if (vErrors === null) {
3099
+ vErrors = [err37];
3100
+ }
3101
+ else {
3102
+ vErrors.push(err37);
3103
+ }
3104
+ errors++;
3105
+ }
3106
+ if (data.type !== undefined) {
3107
+ if ("priceChannelLine" !== data.type) {
3108
+ const err38 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/12/properties/type/const", keyword: "const", params: { allowedValue: "priceChannelLine" }, message: "must be equal to constant" };
3109
+ if (vErrors === null) {
3110
+ vErrors = [err38];
3111
+ }
3112
+ else {
3113
+ vErrors.push(err38);
3114
+ }
3115
+ errors++;
3116
+ }
3117
+ }
3118
+ if (data.geometry !== undefined) {
3119
+ if (!(validate47(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
3120
+ vErrors = vErrors === null ? validate47.errors : vErrors.concat(validate47.errors);
3121
+ errors = vErrors.length;
3122
+ }
3123
+ }
3124
+ }
3125
+ var _valid0 = _errs38 === errors;
3126
+ if (_valid0 && valid0) {
3127
+ valid0 = false;
3128
+ passing0 = [passing0, 12];
3129
+ }
3130
+ else {
3131
+ if (_valid0) {
3132
+ valid0 = true;
3133
+ passing0 = 12;
3134
+ if (props0 !== true) {
3135
+ props0 = props0 || {};
3136
+ props0.type = true;
3137
+ props0.geometry = true;
3138
+ }
3139
+ }
3140
+ const _errs41 = errors;
3141
+ if (data && typeof data == "object" && !Array.isArray(data)) {
3142
+ if (data.type === undefined) {
3143
+ const err39 = { instancePath, schemaPath: "#/oneOf/13/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
3144
+ if (vErrors === null) {
3145
+ vErrors = [err39];
3146
+ }
3147
+ else {
3148
+ vErrors.push(err39);
3149
+ }
3150
+ errors++;
3151
+ }
3152
+ if (data.geometry === undefined) {
3153
+ const err40 = { instancePath, schemaPath: "#/oneOf/13/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
3154
+ if (vErrors === null) {
3155
+ vErrors = [err40];
3156
+ }
3157
+ else {
3158
+ vErrors.push(err40);
3159
+ }
3160
+ errors++;
3161
+ }
3162
+ if (data.type !== undefined) {
3163
+ if ("parallelStraightLine" !== data.type) {
3164
+ const err41 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/13/properties/type/const", keyword: "const", params: { allowedValue: "parallelStraightLine" }, message: "must be equal to constant" };
3165
+ if (vErrors === null) {
3166
+ vErrors = [err41];
3167
+ }
3168
+ else {
3169
+ vErrors.push(err41);
3170
+ }
3171
+ errors++;
3172
+ }
3173
+ }
3174
+ if (data.geometry !== undefined) {
3175
+ if (!(validate47(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
3176
+ vErrors = vErrors === null ? validate47.errors : vErrors.concat(validate47.errors);
3177
+ errors = vErrors.length;
3178
+ }
3179
+ }
3180
+ }
3181
+ var _valid0 = _errs41 === errors;
3182
+ if (_valid0 && valid0) {
3183
+ valid0 = false;
3184
+ passing0 = [passing0, 13];
3185
+ }
3186
+ else {
3187
+ if (_valid0) {
3188
+ valid0 = true;
3189
+ passing0 = 13;
3190
+ if (props0 !== true) {
3191
+ props0 = props0 || {};
3192
+ props0.type = true;
3193
+ props0.geometry = true;
3194
+ }
3195
+ }
3196
+ const _errs44 = errors;
3197
+ if (data && typeof data == "object" && !Array.isArray(data)) {
3198
+ if (data.type === undefined) {
3199
+ const err42 = { instancePath, schemaPath: "#/oneOf/14/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
3200
+ if (vErrors === null) {
3201
+ vErrors = [err42];
3202
+ }
3203
+ else {
3204
+ vErrors.push(err42);
3205
+ }
3206
+ errors++;
3207
+ }
3208
+ if (data.geometry === undefined) {
3209
+ const err43 = { instancePath, schemaPath: "#/oneOf/14/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
3210
+ if (vErrors === null) {
3211
+ vErrors = [err43];
3212
+ }
3213
+ else {
3214
+ vErrors.push(err43);
3215
+ }
3216
+ errors++;
3217
+ }
3218
+ if (data.type !== undefined) {
3219
+ if ("brush" !== data.type) {
3220
+ const err44 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/14/properties/type/const", keyword: "const", params: { allowedValue: "brush" }, message: "must be equal to constant" };
3221
+ if (vErrors === null) {
3222
+ vErrors = [err44];
3223
+ }
3224
+ else {
3225
+ vErrors.push(err44);
3226
+ }
3227
+ errors++;
3228
+ }
3229
+ }
3230
+ if (data.geometry !== undefined) {
3231
+ if (!(validate51(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
3232
+ vErrors = vErrors === null ? validate51.errors : vErrors.concat(validate51.errors);
3233
+ errors = vErrors.length;
3234
+ }
3235
+ }
3236
+ }
3237
+ var _valid0 = _errs44 === errors;
3238
+ if (_valid0 && valid0) {
3239
+ valid0 = false;
3240
+ passing0 = [passing0, 14];
3241
+ }
3242
+ else {
3243
+ if (_valid0) {
3244
+ valid0 = true;
3245
+ passing0 = 14;
3246
+ if (props0 !== true) {
3247
+ props0 = props0 || {};
3248
+ props0.type = true;
3249
+ props0.geometry = true;
3250
+ }
3251
+ }
3252
+ const _errs47 = errors;
3253
+ if (data && typeof data == "object" && !Array.isArray(data)) {
3254
+ if (data.type === undefined) {
3255
+ const err45 = { instancePath, schemaPath: "#/oneOf/15/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
3256
+ if (vErrors === null) {
3257
+ vErrors = [err45];
3258
+ }
3259
+ else {
3260
+ vErrors.push(err45);
3261
+ }
3262
+ errors++;
3263
+ }
3264
+ if (data.geometry === undefined) {
3265
+ const err46 = { instancePath, schemaPath: "#/oneOf/15/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
3266
+ if (vErrors === null) {
3267
+ vErrors = [err46];
3268
+ }
3269
+ else {
3270
+ vErrors.push(err46);
3271
+ }
3272
+ errors++;
3273
+ }
3274
+ if (data.type !== undefined) {
3275
+ if ("simpleAnnotation" !== data.type) {
3276
+ const err47 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/15/properties/type/const", keyword: "const", params: { allowedValue: "simpleAnnotation" }, message: "must be equal to constant" };
3277
+ if (vErrors === null) {
3278
+ vErrors = [err47];
3279
+ }
3280
+ else {
3281
+ vErrors.push(err47);
3282
+ }
3283
+ errors++;
3284
+ }
3285
+ }
3286
+ if (data.geometry !== undefined) {
3287
+ if (!(validate54(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
3288
+ vErrors = vErrors === null ? validate54.errors : vErrors.concat(validate54.errors);
3289
+ errors = vErrors.length;
3290
+ }
3291
+ }
3292
+ }
3293
+ var _valid0 = _errs47 === errors;
3294
+ if (_valid0 && valid0) {
3295
+ valid0 = false;
3296
+ passing0 = [passing0, 15];
3297
+ }
3298
+ else {
3299
+ if (_valid0) {
3300
+ valid0 = true;
3301
+ passing0 = 15;
3302
+ if (props0 !== true) {
3303
+ props0 = props0 || {};
3304
+ props0.type = true;
3305
+ props0.geometry = true;
3306
+ }
3307
+ }
3308
+ const _errs50 = errors;
3309
+ if (data && typeof data == "object" && !Array.isArray(data)) {
3310
+ if (data.type === undefined) {
3311
+ const err48 = { instancePath, schemaPath: "#/oneOf/16/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
3312
+ if (vErrors === null) {
3313
+ vErrors = [err48];
3314
+ }
3315
+ else {
3316
+ vErrors.push(err48);
3317
+ }
3318
+ errors++;
3319
+ }
3320
+ if (data.geometry === undefined) {
3321
+ const err49 = { instancePath, schemaPath: "#/oneOf/16/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
3322
+ if (vErrors === null) {
3323
+ vErrors = [err49];
3324
+ }
3325
+ else {
3326
+ vErrors.push(err49);
3327
+ }
3328
+ errors++;
3329
+ }
3330
+ if (data.type !== undefined) {
3331
+ if ("callout" !== data.type) {
3332
+ const err50 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/16/properties/type/const", keyword: "const", params: { allowedValue: "callout" }, message: "must be equal to constant" };
3333
+ if (vErrors === null) {
3334
+ vErrors = [err50];
3335
+ }
3336
+ else {
3337
+ vErrors.push(err50);
3338
+ }
3339
+ errors++;
3340
+ }
3341
+ }
3342
+ if (data.geometry !== undefined) {
3343
+ if (!(validate54(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
3344
+ vErrors = vErrors === null ? validate54.errors : vErrors.concat(validate54.errors);
3345
+ errors = vErrors.length;
3346
+ }
3347
+ }
3348
+ }
3349
+ var _valid0 = _errs50 === errors;
3350
+ if (_valid0 && valid0) {
3351
+ valid0 = false;
3352
+ passing0 = [passing0, 16];
3353
+ }
3354
+ else {
3355
+ if (_valid0) {
3356
+ valid0 = true;
3357
+ passing0 = 16;
3358
+ if (props0 !== true) {
3359
+ props0 = props0 || {};
3360
+ props0.type = true;
3361
+ props0.geometry = true;
3362
+ }
3363
+ }
3364
+ const _errs53 = errors;
3365
+ if (data && typeof data == "object" && !Array.isArray(data)) {
3366
+ if (data.type === undefined) {
3367
+ const err51 = { instancePath, schemaPath: "#/oneOf/17/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
3368
+ if (vErrors === null) {
3369
+ vErrors = [err51];
3370
+ }
3371
+ else {
3372
+ vErrors.push(err51);
3373
+ }
3374
+ errors++;
3375
+ }
3376
+ if (data.geometry === undefined) {
3377
+ const err52 = { instancePath, schemaPath: "#/oneOf/17/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
3378
+ if (vErrors === null) {
3379
+ vErrors = [err52];
3380
+ }
3381
+ else {
3382
+ vErrors.push(err52);
3383
+ }
3384
+ errors++;
3385
+ }
3386
+ if (data.type !== undefined) {
3387
+ if ("text" !== data.type) {
3388
+ const err53 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/17/properties/type/const", keyword: "const", params: { allowedValue: "text" }, message: "must be equal to constant" };
3389
+ if (vErrors === null) {
3390
+ vErrors = [err53];
3391
+ }
3392
+ else {
3393
+ vErrors.push(err53);
3394
+ }
3395
+ errors++;
3396
+ }
3397
+ }
3398
+ if (data.geometry !== undefined) {
3399
+ if (!(validate54(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
3400
+ vErrors = vErrors === null ? validate54.errors : vErrors.concat(validate54.errors);
3401
+ errors = vErrors.length;
3402
+ }
3403
+ }
3404
+ }
3405
+ var _valid0 = _errs53 === errors;
3406
+ if (_valid0 && valid0) {
3407
+ valid0 = false;
3408
+ passing0 = [passing0, 17];
3409
+ }
3410
+ else {
3411
+ if (_valid0) {
3412
+ valid0 = true;
3413
+ passing0 = 17;
3414
+ if (props0 !== true) {
3415
+ props0 = props0 || {};
3416
+ props0.type = true;
3417
+ props0.geometry = true;
3418
+ }
3419
+ }
3420
+ const _errs56 = errors;
3421
+ if (data && typeof data == "object" && !Array.isArray(data)) {
3422
+ if (data.type === undefined) {
3423
+ const err54 = { instancePath, schemaPath: "#/oneOf/18/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
3424
+ if (vErrors === null) {
3425
+ vErrors = [err54];
3426
+ }
3427
+ else {
3428
+ vErrors.push(err54);
3429
+ }
3430
+ errors++;
3431
+ }
3432
+ if (data.geometry === undefined) {
3433
+ const err55 = { instancePath, schemaPath: "#/oneOf/18/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
3434
+ if (vErrors === null) {
3435
+ vErrors = [err55];
3436
+ }
3437
+ else {
3438
+ vErrors.push(err55);
3439
+ }
3440
+ errors++;
3441
+ }
3442
+ if (data.type !== undefined) {
3443
+ if ("crossLine" !== data.type) {
3444
+ const err56 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/18/properties/type/const", keyword: "const", params: { allowedValue: "crossLine" }, message: "must be equal to constant" };
3445
+ if (vErrors === null) {
3446
+ vErrors = [err56];
3447
+ }
3448
+ else {
3449
+ vErrors.push(err56);
3450
+ }
3451
+ errors++;
3452
+ }
3453
+ }
3454
+ if (data.geometry !== undefined) {
3455
+ if (!(validate59(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
3456
+ vErrors = vErrors === null ? validate59.errors : vErrors.concat(validate59.errors);
3457
+ errors = vErrors.length;
3458
+ }
3459
+ }
3460
+ }
3461
+ var _valid0 = _errs56 === errors;
3462
+ if (_valid0 && valid0) {
3463
+ valid0 = false;
3464
+ passing0 = [passing0, 18];
3465
+ }
3466
+ else {
3467
+ if (_valid0) {
3468
+ valid0 = true;
3469
+ passing0 = 18;
3470
+ if (props0 !== true) {
3471
+ props0 = props0 || {};
3472
+ props0.type = true;
3473
+ props0.geometry = true;
3474
+ }
3475
+ }
3476
+ const _errs59 = errors;
3477
+ if (data && typeof data == "object" && !Array.isArray(data)) {
3478
+ if (data.type === undefined) {
3479
+ const err57 = { instancePath, schemaPath: "#/oneOf/19/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
3480
+ if (vErrors === null) {
3481
+ vErrors = [err57];
3482
+ }
3483
+ else {
3484
+ vErrors.push(err57);
3485
+ }
3486
+ errors++;
3487
+ }
3488
+ if (data.geometry === undefined) {
3489
+ const err58 = { instancePath, schemaPath: "#/oneOf/19/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
3490
+ if (vErrors === null) {
3491
+ vErrors = [err58];
3492
+ }
3493
+ else {
3494
+ vErrors.push(err58);
3495
+ }
3496
+ errors++;
3497
+ }
3498
+ if (data.type !== undefined) {
3499
+ if ("rectangle" !== data.type) {
3500
+ const err59 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/19/properties/type/const", keyword: "const", params: { allowedValue: "rectangle" }, message: "must be equal to constant" };
3501
+ if (vErrors === null) {
3502
+ vErrors = [err59];
3503
+ }
3504
+ else {
3505
+ vErrors.push(err59);
3506
+ }
3507
+ errors++;
3508
+ }
3509
+ }
3510
+ if (data.geometry !== undefined) {
3511
+ if (!(validate62(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
3512
+ vErrors = vErrors === null ? validate62.errors : vErrors.concat(validate62.errors);
3513
+ errors = vErrors.length;
3514
+ }
3515
+ }
3516
+ }
3517
+ var _valid0 = _errs59 === errors;
3518
+ if (_valid0 && valid0) {
3519
+ valid0 = false;
3520
+ passing0 = [passing0, 19];
3521
+ }
3522
+ else {
3523
+ if (_valid0) {
3524
+ valid0 = true;
3525
+ passing0 = 19;
3526
+ if (props0 !== true) {
3527
+ props0 = props0 || {};
3528
+ props0.type = true;
3529
+ props0.geometry = true;
3530
+ }
3531
+ }
3532
+ const _errs62 = errors;
3533
+ if (data && typeof data == "object" && !Array.isArray(data)) {
3534
+ if (data.type === undefined) {
3535
+ const err60 = { instancePath, schemaPath: "#/oneOf/20/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
3536
+ if (vErrors === null) {
3537
+ vErrors = [err60];
3538
+ }
3539
+ else {
3540
+ vErrors.push(err60);
3541
+ }
3542
+ errors++;
3543
+ }
3544
+ if (data.geometry === undefined) {
3545
+ const err61 = { instancePath, schemaPath: "#/oneOf/20/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
3546
+ if (vErrors === null) {
3547
+ vErrors = [err61];
3548
+ }
3549
+ else {
3550
+ vErrors.push(err61);
3551
+ }
3552
+ errors++;
3553
+ }
3554
+ if (data.type !== undefined) {
3555
+ if ("arrow" !== data.type) {
3556
+ const err62 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/20/properties/type/const", keyword: "const", params: { allowedValue: "arrow" }, message: "must be equal to constant" };
3557
+ if (vErrors === null) {
3558
+ vErrors = [err62];
3559
+ }
3560
+ else {
3561
+ vErrors.push(err62);
3562
+ }
3563
+ errors++;
3564
+ }
3565
+ }
3566
+ if (data.geometry !== undefined) {
3567
+ if (!(validate62(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
3568
+ vErrors = vErrors === null ? validate62.errors : vErrors.concat(validate62.errors);
3569
+ errors = vErrors.length;
3570
+ }
3571
+ }
3572
+ }
3573
+ var _valid0 = _errs62 === errors;
3574
+ if (_valid0 && valid0) {
3575
+ valid0 = false;
3576
+ passing0 = [passing0, 20];
3577
+ }
3578
+ else {
3579
+ if (_valid0) {
3580
+ valid0 = true;
3581
+ passing0 = 20;
3582
+ if (props0 !== true) {
3583
+ props0 = props0 || {};
3584
+ props0.type = true;
3585
+ props0.geometry = true;
3586
+ }
3587
+ }
3588
+ const _errs65 = errors;
3589
+ if (data && typeof data == "object" && !Array.isArray(data)) {
3590
+ if (data.type === undefined) {
3591
+ const err63 = { instancePath, schemaPath: "#/oneOf/21/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
3592
+ if (vErrors === null) {
3593
+ vErrors = [err63];
3594
+ }
3595
+ else {
3596
+ vErrors.push(err63);
3597
+ }
3598
+ errors++;
3599
+ }
3600
+ if (data.geometry === undefined) {
3601
+ const err64 = { instancePath, schemaPath: "#/oneOf/21/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
3602
+ if (vErrors === null) {
3603
+ vErrors = [err64];
3604
+ }
3605
+ else {
3606
+ vErrors.push(err64);
3607
+ }
3608
+ errors++;
3609
+ }
3610
+ if (data.type !== undefined) {
3611
+ if ("priceMeasurement" !== data.type) {
3612
+ const err65 = { instancePath: instancePath + "/type", schemaPath: "#/oneOf/21/properties/type/const", keyword: "const", params: { allowedValue: "priceMeasurement" }, message: "must be equal to constant" };
3613
+ if (vErrors === null) {
3614
+ vErrors = [err65];
3615
+ }
3616
+ else {
3617
+ vErrors.push(err65);
3618
+ }
3619
+ errors++;
3620
+ }
3621
+ }
3622
+ if (data.geometry !== undefined) {
3623
+ if (!(validate62(data.geometry, { instancePath: instancePath + "/geometry", parentData: data, parentDataProperty: "geometry", rootData, dynamicAnchors }))) {
3624
+ vErrors = vErrors === null ? validate62.errors : vErrors.concat(validate62.errors);
3625
+ errors = vErrors.length;
3626
+ }
3627
+ }
3628
+ }
3629
+ var _valid0 = _errs65 === errors;
3630
+ if (_valid0 && valid0) {
3631
+ valid0 = false;
3632
+ passing0 = [passing0, 21];
3633
+ }
3634
+ else {
3635
+ if (_valid0) {
3636
+ valid0 = true;
3637
+ passing0 = 21;
3638
+ if (props0 !== true) {
3639
+ props0 = props0 || {};
3640
+ props0.type = true;
3641
+ props0.geometry = true;
3642
+ }
3643
+ }
3644
+ }
3645
+ }
3646
+ }
3647
+ }
3648
+ }
3649
+ }
3650
+ }
3651
+ }
3652
+ }
3653
+ }
3654
+ }
3655
+ }
3656
+ }
3657
+ }
3658
+ }
3659
+ }
3660
+ }
3661
+ }
3662
+ }
3663
+ }
3664
+ } if (!valid0) {
3665
+ const err66 = { instancePath, schemaPath: "#/oneOf", keyword: "oneOf", params: { passingSchemas: passing0 }, message: "must match exactly one schema in oneOf" };
3666
+ if (vErrors === null) {
3667
+ vErrors = [err66];
3668
+ }
3669
+ else {
3670
+ vErrors.push(err66);
3671
+ }
3672
+ errors++;
3673
+ }
3674
+ else {
3675
+ errors = _errs1;
3676
+ if (vErrors !== null) {
3677
+ if (_errs1) {
3678
+ vErrors.length = _errs1;
3679
+ }
3680
+ else {
3681
+ vErrors = null;
3682
+ }
3683
+ }
3684
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
3685
+ if (data.id === undefined) {
3686
+ const err67 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "id" }, message: "must have required property '" + "id" + "'" };
3687
+ if (vErrors === null) {
3688
+ vErrors = [err67];
3689
+ }
3690
+ else {
3691
+ vErrors.push(err67);
3692
+ }
3693
+ errors++;
3694
+ }
3695
+ if (data.target === undefined) {
3696
+ const err68 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "target" }, message: "must have required property '" + "target" + "'" };
3697
+ if (vErrors === null) {
3698
+ vErrors = [err68];
3699
+ }
3700
+ else {
3701
+ vErrors.push(err68);
3702
+ }
3703
+ errors++;
3704
+ }
3705
+ if (data.visible === undefined) {
3706
+ const err69 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "visible" }, message: "must have required property '" + "visible" + "'" };
3707
+ if (vErrors === null) {
3708
+ vErrors = [err69];
3709
+ }
3710
+ else {
3711
+ vErrors.push(err69);
3712
+ }
3713
+ errors++;
3714
+ }
3715
+ if (data.locked === undefined) {
3716
+ const err70 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "locked" }, message: "must have required property '" + "locked" + "'" };
3717
+ if (vErrors === null) {
3718
+ vErrors = [err70];
3719
+ }
3720
+ else {
3721
+ vErrors.push(err70);
3722
+ }
3723
+ errors++;
3724
+ }
3725
+ if (data.zLevel === undefined) {
3726
+ const err71 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "zLevel" }, message: "must have required property '" + "zLevel" + "'" };
3727
+ if (vErrors === null) {
3728
+ vErrors = [err71];
3729
+ }
3730
+ else {
3731
+ vErrors.push(err71);
3732
+ }
3733
+ errors++;
3734
+ }
3735
+ if (data.mode === undefined) {
3736
+ const err72 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "mode" }, message: "must have required property '" + "mode" + "'" };
3737
+ if (vErrors === null) {
3738
+ vErrors = [err72];
3739
+ }
3740
+ else {
3741
+ vErrors.push(err72);
3742
+ }
3743
+ errors++;
3744
+ }
3745
+ if (data.styles === undefined) {
3746
+ const err73 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "styles" }, message: "must have required property '" + "styles" + "'" };
3747
+ if (vErrors === null) {
3748
+ vErrors = [err73];
3749
+ }
3750
+ else {
3751
+ vErrors.push(err73);
3752
+ }
3753
+ errors++;
3754
+ }
3755
+ if (data.type === undefined) {
3756
+ const err74 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "type" }, message: "must have required property '" + "type" + "'" };
3757
+ if (vErrors === null) {
3758
+ vErrors = [err74];
3759
+ }
3760
+ else {
3761
+ vErrors.push(err74);
3762
+ }
3763
+ errors++;
3764
+ }
3765
+ if (data.geometry === undefined) {
3766
+ const err75 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "geometry" }, message: "must have required property '" + "geometry" + "'" };
3767
+ if (vErrors === null) {
3768
+ vErrors = [err75];
3769
+ }
3770
+ else {
3771
+ vErrors.push(err75);
3772
+ }
3773
+ errors++;
3774
+ }
3775
+ for (const key0 in data) {
3776
+ if (!(func11.call(schema36.properties, key0))) {
3777
+ const err76 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
3778
+ if (vErrors === null) {
3779
+ vErrors = [err76];
3780
+ }
3781
+ else {
3782
+ vErrors.push(err76);
3783
+ }
3784
+ errors++;
3785
+ }
3786
+ }
3787
+ if (data.id !== undefined) {
3788
+ let data44 = data.id;
3789
+ if (typeof data44 === "string") {
3790
+ if (func1(data44) > 128) {
3791
+ const err77 = { instancePath: instancePath + "/id", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/stableId/maxLength", keyword: "maxLength", params: { limit: 128 }, message: "must NOT have more than 128 characters" };
3792
+ if (vErrors === null) {
3793
+ vErrors = [err77];
3794
+ }
3795
+ else {
3796
+ vErrors.push(err77);
3797
+ }
3798
+ errors++;
3799
+ }
3800
+ if (func1(data44) < 1) {
3801
+ const err78 = { instancePath: instancePath + "/id", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/stableId/minLength", keyword: "minLength", params: { limit: 1 }, message: "must NOT have fewer than 1 characters" };
3802
+ if (vErrors === null) {
3803
+ vErrors = [err78];
3804
+ }
3805
+ else {
3806
+ vErrors.push(err78);
3807
+ }
3808
+ errors++;
3809
+ }
3810
+ if (!pattern5.test(data44)) {
3811
+ const err79 = { instancePath: instancePath + "/id", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/stableId/pattern", keyword: "pattern", params: { pattern: "^[A-Za-z][A-Za-z0-9._:-]*$" }, message: "must match pattern \"" + "^[A-Za-z][A-Za-z0-9._:-]*$" + "\"" };
3812
+ if (vErrors === null) {
3813
+ vErrors = [err79];
3814
+ }
3815
+ else {
3816
+ vErrors.push(err79);
3817
+ }
3818
+ errors++;
3819
+ }
3820
+ }
3821
+ else {
3822
+ const err80 = { instancePath: instancePath + "/id", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/stableId/type", keyword: "type", params: { type: "string" }, message: "must be string" };
3823
+ if (vErrors === null) {
3824
+ vErrors = [err80];
3825
+ }
3826
+ else {
3827
+ vErrors.push(err80);
3828
+ }
3829
+ errors++;
3830
+ }
3831
+ }
3832
+ if (data.groupId !== undefined) {
3833
+ let data45 = data.groupId;
3834
+ if (typeof data45 === "string") {
3835
+ if (func1(data45) > 128) {
3836
+ const err81 = { instancePath: instancePath + "/groupId", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/stableId/maxLength", keyword: "maxLength", params: { limit: 128 }, message: "must NOT have more than 128 characters" };
3837
+ if (vErrors === null) {
3838
+ vErrors = [err81];
3839
+ }
3840
+ else {
3841
+ vErrors.push(err81);
3842
+ }
3843
+ errors++;
3844
+ }
3845
+ if (func1(data45) < 1) {
3846
+ const err82 = { instancePath: instancePath + "/groupId", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/stableId/minLength", keyword: "minLength", params: { limit: 1 }, message: "must NOT have fewer than 1 characters" };
3847
+ if (vErrors === null) {
3848
+ vErrors = [err82];
3849
+ }
3850
+ else {
3851
+ vErrors.push(err82);
3852
+ }
3853
+ errors++;
3854
+ }
3855
+ if (!pattern5.test(data45)) {
3856
+ const err83 = { instancePath: instancePath + "/groupId", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/stableId/pattern", keyword: "pattern", params: { pattern: "^[A-Za-z][A-Za-z0-9._:-]*$" }, message: "must match pattern \"" + "^[A-Za-z][A-Za-z0-9._:-]*$" + "\"" };
3857
+ if (vErrors === null) {
3858
+ vErrors = [err83];
3859
+ }
3860
+ else {
3861
+ vErrors.push(err83);
3862
+ }
3863
+ errors++;
3864
+ }
3865
+ }
3866
+ else {
3867
+ const err84 = { instancePath: instancePath + "/groupId", schemaPath: "https://baron.dev/kline-scene/common.schema.json#/$defs/stableId/type", keyword: "type", params: { type: "string" }, message: "must be string" };
3868
+ if (vErrors === null) {
3869
+ vErrors = [err84];
3870
+ }
3871
+ else {
3872
+ vErrors.push(err84);
3873
+ }
3874
+ errors++;
3875
+ }
3876
+ }
3877
+ if (data.target !== undefined) {
3878
+ let data46 = data.target;
3879
+ if (data46 && typeof data46 == "object" && !Array.isArray(data46)) {
3880
+ if (data46.paneRole === undefined) {
3881
+ const err85 = { instancePath: instancePath + "/target", schemaPath: "#/$defs/target/required", keyword: "required", params: { missingProperty: "paneRole" }, message: "must have required property '" + "paneRole" + "'" };
3882
+ if (vErrors === null) {
3883
+ vErrors = [err85];
3884
+ }
3885
+ else {
3886
+ vErrors.push(err85);
3887
+ }
3888
+ errors++;
3889
+ }
3890
+ if (data46.yAxisRole === undefined) {
3891
+ const err86 = { instancePath: instancePath + "/target", schemaPath: "#/$defs/target/required", keyword: "required", params: { missingProperty: "yAxisRole" }, message: "must have required property '" + "yAxisRole" + "'" };
3892
+ if (vErrors === null) {
3893
+ vErrors = [err86];
3894
+ }
3895
+ else {
3896
+ vErrors.push(err86);
3897
+ }
3898
+ errors++;
3899
+ }
3900
+ for (const key1 in data46) {
3901
+ if (!((key1 === "paneRole") || (key1 === "yAxisRole"))) {
3902
+ const err87 = { instancePath: instancePath + "/target", schemaPath: "#/$defs/target/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key1 }, message: "must NOT have additional properties" };
3903
+ if (vErrors === null) {
3904
+ vErrors = [err87];
3905
+ }
3906
+ else {
3907
+ vErrors.push(err87);
3908
+ }
3909
+ errors++;
3910
+ }
3911
+ }
3912
+ if (data46.paneRole !== undefined) {
3913
+ let data47 = data46.paneRole;
3914
+ if (typeof data47 === "string") {
3915
+ if (func1(data47) > 128) {
3916
+ const err88 = { instancePath: instancePath + "/target/paneRole", schemaPath: "#/$defs/target/properties/paneRole/maxLength", keyword: "maxLength", params: { limit: 128 }, message: "must NOT have more than 128 characters" };
3917
+ if (vErrors === null) {
3918
+ vErrors = [err88];
3919
+ }
3920
+ else {
3921
+ vErrors.push(err88);
3922
+ }
3923
+ errors++;
3924
+ }
3925
+ if (func1(data47) < 1) {
3926
+ const err89 = { instancePath: instancePath + "/target/paneRole", schemaPath: "#/$defs/target/properties/paneRole/minLength", keyword: "minLength", params: { limit: 1 }, message: "must NOT have fewer than 1 characters" };
3927
+ if (vErrors === null) {
3928
+ vErrors = [err89];
3929
+ }
3930
+ else {
3931
+ vErrors.push(err89);
3932
+ }
3933
+ errors++;
3934
+ }
3935
+ }
3936
+ else {
3937
+ const err90 = { instancePath: instancePath + "/target/paneRole", schemaPath: "#/$defs/target/properties/paneRole/type", keyword: "type", params: { type: "string" }, message: "must be string" };
3938
+ if (vErrors === null) {
3939
+ vErrors = [err90];
3940
+ }
3941
+ else {
3942
+ vErrors.push(err90);
3943
+ }
3944
+ errors++;
3945
+ }
3946
+ }
3947
+ if (data46.yAxisRole !== undefined) {
3948
+ let data48 = data46.yAxisRole;
3949
+ if (typeof data48 === "string") {
3950
+ if (func1(data48) > 128) {
3951
+ const err91 = { instancePath: instancePath + "/target/yAxisRole", schemaPath: "#/$defs/target/properties/yAxisRole/maxLength", keyword: "maxLength", params: { limit: 128 }, message: "must NOT have more than 128 characters" };
3952
+ if (vErrors === null) {
3953
+ vErrors = [err91];
3954
+ }
3955
+ else {
3956
+ vErrors.push(err91);
3957
+ }
3958
+ errors++;
3959
+ }
3960
+ if (func1(data48) < 1) {
3961
+ const err92 = { instancePath: instancePath + "/target/yAxisRole", schemaPath: "#/$defs/target/properties/yAxisRole/minLength", keyword: "minLength", params: { limit: 1 }, message: "must NOT have fewer than 1 characters" };
3962
+ if (vErrors === null) {
3963
+ vErrors = [err92];
3964
+ }
3965
+ else {
3966
+ vErrors.push(err92);
3967
+ }
3968
+ errors++;
3969
+ }
3970
+ }
3971
+ else {
3972
+ const err93 = { instancePath: instancePath + "/target/yAxisRole", schemaPath: "#/$defs/target/properties/yAxisRole/type", keyword: "type", params: { type: "string" }, message: "must be string" };
3973
+ if (vErrors === null) {
3974
+ vErrors = [err93];
3975
+ }
3976
+ else {
3977
+ vErrors.push(err93);
3978
+ }
3979
+ errors++;
3980
+ }
3981
+ }
3982
+ }
3983
+ else {
3984
+ const err94 = { instancePath: instancePath + "/target", schemaPath: "#/$defs/target/type", keyword: "type", params: { type: "object" }, message: "must be object" };
3985
+ if (vErrors === null) {
3986
+ vErrors = [err94];
3987
+ }
3988
+ else {
3989
+ vErrors.push(err94);
3990
+ }
3991
+ errors++;
3992
+ }
3993
+ }
3994
+ if (data.visible !== undefined) {
3995
+ if (typeof data.visible !== "boolean") {
3996
+ const err95 = { instancePath: instancePath + "/visible", schemaPath: "#/properties/visible/type", keyword: "type", params: { type: "boolean" }, message: "must be boolean" };
3997
+ if (vErrors === null) {
3998
+ vErrors = [err95];
3999
+ }
4000
+ else {
4001
+ vErrors.push(err95);
4002
+ }
4003
+ errors++;
4004
+ }
4005
+ }
4006
+ if (data.locked !== undefined) {
4007
+ if (typeof data.locked !== "boolean") {
4008
+ const err96 = { instancePath: instancePath + "/locked", schemaPath: "#/properties/locked/type", keyword: "type", params: { type: "boolean" }, message: "must be boolean" };
4009
+ if (vErrors === null) {
4010
+ vErrors = [err96];
4011
+ }
4012
+ else {
4013
+ vErrors.push(err96);
4014
+ }
4015
+ errors++;
4016
+ }
4017
+ }
4018
+ if (data.zLevel !== undefined) {
4019
+ let data51 = data.zLevel;
4020
+ if (!(((typeof data51 == "number") && (!(data51 % 1) && !isNaN(data51))) && (isFinite(data51)))) {
4021
+ const err97 = { instancePath: instancePath + "/zLevel", schemaPath: "#/properties/zLevel/type", keyword: "type", params: { type: "integer" }, message: "must be integer" };
4022
+ if (vErrors === null) {
4023
+ vErrors = [err97];
4024
+ }
4025
+ else {
4026
+ vErrors.push(err97);
4027
+ }
4028
+ errors++;
4029
+ }
4030
+ if ((typeof data51 == "number") && (isFinite(data51))) {
4031
+ if (data51 > 1000 || isNaN(data51)) {
4032
+ const err98 = { instancePath: instancePath + "/zLevel", schemaPath: "#/properties/zLevel/maximum", keyword: "maximum", params: { comparison: "<=", limit: 1000 }, message: "must be <= 1000" };
4033
+ if (vErrors === null) {
4034
+ vErrors = [err98];
4035
+ }
4036
+ else {
4037
+ vErrors.push(err98);
4038
+ }
4039
+ errors++;
4040
+ }
4041
+ if (data51 < -1000 || isNaN(data51)) {
4042
+ const err99 = { instancePath: instancePath + "/zLevel", schemaPath: "#/properties/zLevel/minimum", keyword: "minimum", params: { comparison: ">=", limit: -1000 }, message: "must be >= -1000" };
4043
+ if (vErrors === null) {
4044
+ vErrors = [err99];
4045
+ }
4046
+ else {
4047
+ vErrors.push(err99);
4048
+ }
4049
+ errors++;
4050
+ }
4051
+ }
4052
+ }
4053
+ if (data.mode !== undefined) {
4054
+ let data52 = data.mode;
4055
+ if (!(((data52 === "normal") || (data52 === "weak_magnet")) || (data52 === "strong_magnet"))) {
4056
+ const err100 = { instancePath: instancePath + "/mode", schemaPath: "#/properties/mode/enum", keyword: "enum", params: { allowedValues: schema36.properties.mode.enum }, message: "must be equal to one of the allowed values" };
4057
+ if (vErrors === null) {
4058
+ vErrors = [err100];
4059
+ }
4060
+ else {
4061
+ vErrors.push(err100);
4062
+ }
4063
+ errors++;
4064
+ }
4065
+ }
4066
+ if (data.styles !== undefined) {
4067
+ if (!(validate68(data.styles, { instancePath: instancePath + "/styles", parentData: data, parentDataProperty: "styles", rootData, dynamicAnchors }))) {
4068
+ vErrors = vErrors === null ? validate68.errors : vErrors.concat(validate68.errors);
4069
+ errors = vErrors.length;
4070
+ }
4071
+ }
4072
+ if (data.metadata !== undefined) {
4073
+ if (!(validate76(data.metadata, { instancePath: instancePath + "/metadata", parentData: data, parentDataProperty: "metadata", rootData, dynamicAnchors }))) {
4074
+ vErrors = vErrors === null ? validate76.errors : vErrors.concat(validate76.errors);
4075
+ errors = vErrors.length;
4076
+ }
4077
+ }
4078
+ if (data.type !== undefined) {
4079
+ let data55 = data.type;
4080
+ if (!((((((((((((((((((((((data55 === "horizontalStraightLine") || (data55 === "priceLine")) || (data55 === "simpleTag")) || (data55 === "verticalStraightLine")) || (data55 === "horizontalRayLine")) || (data55 === "horizontalSegment")) || (data55 === "verticalRayLine")) || (data55 === "verticalSegment")) || (data55 === "rayLine")) || (data55 === "segment")) || (data55 === "straightLine")) || (data55 === "fibonacciLine")) || (data55 === "priceChannelLine")) || (data55 === "parallelStraightLine")) || (data55 === "brush")) || (data55 === "simpleAnnotation")) || (data55 === "callout")) || (data55 === "text")) || (data55 === "crossLine")) || (data55 === "rectangle")) || (data55 === "arrow")) || (data55 === "priceMeasurement"))) {
4081
+ const err101 = { instancePath: instancePath + "/type", schemaPath: "#/properties/type/enum", keyword: "enum", params: { allowedValues: schema36.properties.type.enum }, message: "must be equal to one of the allowed values" };
4082
+ if (vErrors === null) {
4083
+ vErrors = [err101];
4084
+ }
4085
+ else {
4086
+ vErrors.push(err101);
4087
+ }
4088
+ errors++;
4089
+ }
4090
+ }
4091
+ if (data.geometry !== undefined) {
4092
+ let data56 = data.geometry;
4093
+ if (!(data56 && typeof data56 == "object" && !Array.isArray(data56))) {
4094
+ const err102 = { instancePath: instancePath + "/geometry", schemaPath: "#/properties/geometry/type", keyword: "type", params: { type: "object" }, message: "must be object" };
4095
+ if (vErrors === null) {
4096
+ vErrors = [err102];
4097
+ }
4098
+ else {
4099
+ vErrors.push(err102);
4100
+ }
4101
+ errors++;
4102
+ }
4103
+ }
4104
+ }
4105
+ else {
4106
+ const err103 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
4107
+ if (vErrors === null) {
4108
+ vErrors = [err103];
4109
+ }
4110
+ else {
4111
+ vErrors.push(err103);
4112
+ }
4113
+ errors++;
4114
+ } validate25.errors = vErrors; return errors === 0; }
4115
+ validate25.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };
4116
+ function validate20(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) { /*# sourceURL="https://baron.dev/kline-scene/drawing-document.schema.json" */ ; let vErrors = null; let errors = 0; const evaluated0 = validate20.evaluated; if (evaluated0.dynamicProps) {
4117
+ evaluated0.props = undefined;
4118
+ } if (evaluated0.dynamicItems) {
4119
+ evaluated0.items = undefined;
4120
+ } if (data && typeof data == "object" && !Array.isArray(data)) {
4121
+ if (data.schema === undefined) {
4122
+ const err0 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "schema" }, message: "must have required property '" + "schema" + "'" };
4123
+ if (vErrors === null) {
4124
+ vErrors = [err0];
4125
+ }
4126
+ else {
4127
+ vErrors.push(err0);
4128
+ }
4129
+ errors++;
4130
+ }
4131
+ if (data.version === undefined) {
4132
+ const err1 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "version" }, message: "must have required property '" + "version" + "'" };
4133
+ if (vErrors === null) {
4134
+ vErrors = [err1];
4135
+ }
4136
+ else {
4137
+ vErrors.push(err1);
4138
+ }
4139
+ errors++;
4140
+ }
4141
+ if (data.scopeKey === undefined) {
4142
+ const err2 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "scopeKey" }, message: "must have required property '" + "scopeKey" + "'" };
4143
+ if (vErrors === null) {
4144
+ vErrors = [err2];
4145
+ }
4146
+ else {
4147
+ vErrors.push(err2);
4148
+ }
4149
+ errors++;
4150
+ }
4151
+ if (data.coordinateSystem === undefined) {
4152
+ const err3 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "coordinateSystem" }, message: "must have required property '" + "coordinateSystem" + "'" };
4153
+ if (vErrors === null) {
4154
+ vErrors = [err3];
4155
+ }
4156
+ else {
4157
+ vErrors.push(err3);
4158
+ }
4159
+ errors++;
4160
+ }
4161
+ if (data.drawings === undefined) {
4162
+ const err4 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "drawings" }, message: "must have required property '" + "drawings" + "'" };
4163
+ if (vErrors === null) {
4164
+ vErrors = [err4];
4165
+ }
4166
+ else {
4167
+ vErrors.push(err4);
4168
+ }
4169
+ errors++;
4170
+ }
4171
+ if (data.metadata === undefined) {
4172
+ const err5 = { instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: "metadata" }, message: "must have required property '" + "metadata" + "'" };
4173
+ if (vErrors === null) {
4174
+ vErrors = [err5];
4175
+ }
4176
+ else {
4177
+ vErrors.push(err5);
4178
+ }
4179
+ errors++;
4180
+ }
4181
+ for (const key0 in data) {
4182
+ if (!((((((key0 === "schema") || (key0 === "version")) || (key0 === "scopeKey")) || (key0 === "coordinateSystem")) || (key0 === "drawings")) || (key0 === "metadata"))) {
4183
+ const err6 = { instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" };
4184
+ if (vErrors === null) {
4185
+ vErrors = [err6];
4186
+ }
4187
+ else {
4188
+ vErrors.push(err6);
4189
+ }
4190
+ errors++;
4191
+ }
4192
+ }
4193
+ if (data.schema !== undefined) {
4194
+ if ("@baron1996/drawing-document" !== data.schema) {
4195
+ const err7 = { instancePath: instancePath + "/schema", schemaPath: "#/properties/schema/const", keyword: "const", params: { allowedValue: "@baron1996/drawing-document" }, message: "must be equal to constant" };
4196
+ if (vErrors === null) {
4197
+ vErrors = [err7];
4198
+ }
4199
+ else {
4200
+ vErrors.push(err7);
4201
+ }
4202
+ errors++;
4203
+ }
4204
+ }
4205
+ if (data.version !== undefined) {
4206
+ if (1 !== data.version) {
4207
+ const err8 = { instancePath: instancePath + "/version", schemaPath: "#/properties/version/const", keyword: "const", params: { allowedValue: 1 }, message: "must be equal to constant" };
4208
+ if (vErrors === null) {
4209
+ vErrors = [err8];
4210
+ }
4211
+ else {
4212
+ vErrors.push(err8);
4213
+ }
4214
+ errors++;
4215
+ }
4216
+ }
4217
+ if (data.scopeKey !== undefined) {
4218
+ let data2 = data.scopeKey;
4219
+ if (typeof data2 === "string") {
4220
+ if (func1(data2) > 256) {
4221
+ const err9 = { instancePath: instancePath + "/scopeKey", schemaPath: "#/properties/scopeKey/maxLength", keyword: "maxLength", params: { limit: 256 }, message: "must NOT have more than 256 characters" };
4222
+ if (vErrors === null) {
4223
+ vErrors = [err9];
4224
+ }
4225
+ else {
4226
+ vErrors.push(err9);
4227
+ }
4228
+ errors++;
4229
+ }
4230
+ if (func1(data2) < 1) {
4231
+ const err10 = { instancePath: instancePath + "/scopeKey", schemaPath: "#/properties/scopeKey/minLength", keyword: "minLength", params: { limit: 1 }, message: "must NOT have fewer than 1 characters" };
4232
+ if (vErrors === null) {
4233
+ vErrors = [err10];
4234
+ }
4235
+ else {
4236
+ vErrors.push(err10);
4237
+ }
4238
+ errors++;
4239
+ }
4240
+ }
4241
+ else {
4242
+ const err11 = { instancePath: instancePath + "/scopeKey", schemaPath: "#/properties/scopeKey/type", keyword: "type", params: { type: "string" }, message: "must be string" };
4243
+ if (vErrors === null) {
4244
+ vErrors = [err11];
4245
+ }
4246
+ else {
4247
+ vErrors.push(err11);
4248
+ }
4249
+ errors++;
4250
+ }
4251
+ }
4252
+ if (data.coordinateSystem !== undefined) {
4253
+ if (!(validate21(data.coordinateSystem, { instancePath: instancePath + "/coordinateSystem", parentData: data, parentDataProperty: "coordinateSystem", rootData, dynamicAnchors }))) {
4254
+ vErrors = vErrors === null ? validate21.errors : vErrors.concat(validate21.errors);
4255
+ errors = vErrors.length;
4256
+ }
4257
+ }
4258
+ if (data.drawings !== undefined) {
4259
+ let data4 = data.drawings;
4260
+ if (Array.isArray(data4)) {
4261
+ if (data4.length > 10000) {
4262
+ const err12 = { instancePath: instancePath + "/drawings", schemaPath: "#/properties/drawings/maxItems", keyword: "maxItems", params: { limit: 10000 }, message: "must NOT have more than 10000 items" };
4263
+ if (vErrors === null) {
4264
+ vErrors = [err12];
4265
+ }
4266
+ else {
4267
+ vErrors.push(err12);
4268
+ }
4269
+ errors++;
4270
+ }
4271
+ const len0 = data4.length;
4272
+ for (let i0 = 0; i0 < len0; i0++) {
4273
+ if (!(validate25(data4[i0], { instancePath: instancePath + "/drawings/" + i0, parentData: data4, parentDataProperty: i0, rootData, dynamicAnchors }))) {
4274
+ vErrors = vErrors === null ? validate25.errors : vErrors.concat(validate25.errors);
4275
+ errors = vErrors.length;
4276
+ }
4277
+ }
4278
+ }
4279
+ else {
4280
+ const err13 = { instancePath: instancePath + "/drawings", schemaPath: "#/properties/drawings/type", keyword: "type", params: { type: "array" }, message: "must be array" };
4281
+ if (vErrors === null) {
4282
+ vErrors = [err13];
4283
+ }
4284
+ else {
4285
+ vErrors.push(err13);
4286
+ }
4287
+ errors++;
4288
+ }
4289
+ }
4290
+ if (data.metadata !== undefined) {
4291
+ if (!(validate76(data.metadata, { instancePath: instancePath + "/metadata", parentData: data, parentDataProperty: "metadata", rootData, dynamicAnchors }))) {
4292
+ vErrors = vErrors === null ? validate76.errors : vErrors.concat(validate76.errors);
4293
+ errors = vErrors.length;
4294
+ }
4295
+ }
4296
+ }
4297
+ else {
4298
+ const err14 = { instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" };
4299
+ if (vErrors === null) {
4300
+ vErrors = [err14];
4301
+ }
4302
+ else {
4303
+ vErrors.push(err14);
4304
+ }
4305
+ errors++;
4306
+ } validate20.errors = vErrors; return errors === 0; }
4307
+ validate20.evaluated = { "props": true, "dynamicProps": false, "dynamicItems": false };