@keymanapp/common-types 18.0.41-alpha → 18.0.46-alpha

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 (189) hide show
  1. package/build/src/consts/virtual-key-constants.d.ts +191 -191
  2. package/build/src/consts/virtual-key-constants.js +221 -221
  3. package/build/src/consts/virtual-key-constants.js.map +1 -1
  4. package/build/src/keyman-touch-layout/keyman-touch-layout-file-reader.d.ts +5 -5
  5. package/build/src/keyman-touch-layout/keyman-touch-layout-file-reader.js +72 -72
  6. package/build/src/keyman-touch-layout/keyman-touch-layout-file-reader.js.map +1 -1
  7. package/build/src/keyman-touch-layout/keyman-touch-layout-file-writer.d.ts +28 -28
  8. package/build/src/keyman-touch-layout/keyman-touch-layout-file-writer.js +120 -120
  9. package/build/src/keyman-touch-layout/keyman-touch-layout-file-writer.js.map +1 -1
  10. package/build/src/keyman-touch-layout/keyman-touch-layout-file.d.ts +95 -95
  11. package/build/src/keyman-touch-layout/keyman-touch-layout-file.js +52 -52
  12. package/build/src/kmx/element-string.d.ts +23 -23
  13. package/build/src/kmx/element-string.js +125 -125
  14. package/build/src/kmx/element-string.js.map +1 -1
  15. package/build/src/kmx/keyman-targets.d.ts +20 -20
  16. package/build/src/kmx/keyman-targets.js +79 -79
  17. package/build/src/kmx/keyman-targets.js.map +1 -1
  18. package/build/src/kmx/kmx-builder.d.ts +32 -32
  19. package/build/src/kmx/kmx-builder.js +189 -189
  20. package/build/src/kmx/kmx-builder.js.map +1 -1
  21. package/build/src/kmx/kmx-file-reader.d.ts +13 -13
  22. package/build/src/kmx/kmx-file-reader.js +134 -134
  23. package/build/src/kmx/kmx-file-reader.js.map +1 -1
  24. package/build/src/kmx/kmx-plus-builder/build-disp.d.ts +18 -18
  25. package/build/src/kmx/kmx-plus-builder/build-disp.js +27 -27
  26. package/build/src/kmx/kmx-plus-builder/build-disp.js.map +1 -1
  27. package/build/src/kmx/kmx-plus-builder/build-elem.d.ts +28 -28
  28. package/build/src/kmx/kmx-plus-builder/build-elem.js +89 -89
  29. package/build/src/kmx/kmx-plus-builder/build-elem.js.map +1 -1
  30. package/build/src/kmx/kmx-plus-builder/build-keys.d.ts +56 -56
  31. package/build/src/kmx/kmx-plus-builder/build-keys.js +107 -107
  32. package/build/src/kmx/kmx-plus-builder/build-keys.js.map +1 -1
  33. package/build/src/kmx/kmx-plus-builder/build-layr.d.ts +53 -53
  34. package/build/src/kmx/kmx-plus-builder/build-layr.js +101 -101
  35. package/build/src/kmx/kmx-plus-builder/build-layr.js.map +1 -1
  36. package/build/src/kmx/kmx-plus-builder/build-list.d.ts +35 -35
  37. package/build/src/kmx/kmx-plus-builder/build-list.js +66 -66
  38. package/build/src/kmx/kmx-plus-builder/build-list.js.map +1 -1
  39. package/build/src/kmx/kmx-plus-builder/build-loca.d.ts +11 -11
  40. package/build/src/kmx/kmx-plus-builder/build-loca.js +21 -21
  41. package/build/src/kmx/kmx-plus-builder/build-loca.js.map +1 -1
  42. package/build/src/kmx/kmx-plus-builder/build-meta.d.ts +16 -16
  43. package/build/src/kmx/kmx-plus-builder/build-meta.js +20 -20
  44. package/build/src/kmx/kmx-plus-builder/build-sect.d.ts +15 -15
  45. package/build/src/kmx/kmx-plus-builder/build-sect.js +15 -15
  46. package/build/src/kmx/kmx-plus-builder/build-sect.js.map +1 -1
  47. package/build/src/kmx/kmx-plus-builder/build-strs.d.ts +22 -22
  48. package/build/src/kmx/kmx-plus-builder/build-strs.js +46 -46
  49. package/build/src/kmx/kmx-plus-builder/build-strs.js.map +1 -1
  50. package/build/src/kmx/kmx-plus-builder/build-tran.d.ts +32 -32
  51. package/build/src/kmx/kmx-plus-builder/build-tran.js +69 -69
  52. package/build/src/kmx/kmx-plus-builder/build-tran.js.map +1 -1
  53. package/build/src/kmx/kmx-plus-builder/build-uset.d.ts +30 -30
  54. package/build/src/kmx/kmx-plus-builder/build-uset.js +60 -60
  55. package/build/src/kmx/kmx-plus-builder/build-uset.js.map +1 -1
  56. package/build/src/kmx/kmx-plus-builder/build-vars.d.ts +21 -21
  57. package/build/src/kmx/kmx-plus-builder/build-vars.js +48 -48
  58. package/build/src/kmx/kmx-plus-builder/build-vars.js.map +1 -1
  59. package/build/src/kmx/kmx-plus-builder/builder-section.d.ts +9 -9
  60. package/build/src/kmx/kmx-plus-builder/builder-section.js +2 -2
  61. package/build/src/kmx/kmx-plus-builder/kmx-plus-builder.d.ts +42 -42
  62. package/build/src/kmx/kmx-plus-builder/kmx-plus-builder.js +137 -137
  63. package/build/src/kmx/kmx-plus-builder/kmx-plus-builder.js.map +1 -1
  64. package/build/src/kmx/kmx-plus.d.ts +322 -322
  65. package/build/src/kmx/kmx-plus.js +830 -830
  66. package/build/src/kmx/kmx-plus.js.map +1 -1
  67. package/build/src/kmx/kmx.d.ts +233 -233
  68. package/build/src/kmx/kmx.js +302 -302
  69. package/build/src/kmx/kmx.js.map +1 -1
  70. package/build/src/kmx/string-list.d.ts +35 -35
  71. package/build/src/kmx/string-list.js +88 -88
  72. package/build/src/kmx/string-list.js.map +1 -1
  73. package/build/src/kpj/keyman-developer-project.d.ts +78 -78
  74. package/build/src/kpj/keyman-developer-project.js +195 -195
  75. package/build/src/kpj/keyman-developer-project.js.map +1 -1
  76. package/build/src/kpj/kpj-file-reader.d.ts +18 -18
  77. package/build/src/kpj/kpj-file-reader.js +119 -119
  78. package/build/src/kpj/kpj-file-reader.js.map +1 -1
  79. package/build/src/kpj/kpj-file.d.ts +39 -39
  80. package/build/src/kpj/kpj-file.js +10 -10
  81. package/build/src/kvk/kvk-file-reader.d.ts +4 -4
  82. package/build/src/kvk/kvk-file-reader.js +37 -37
  83. package/build/src/kvk/kvk-file-reader.js.map +1 -1
  84. package/build/src/kvk/kvk-file-writer.d.ts +19 -19
  85. package/build/src/kvk/kvk-file-writer.js +77 -77
  86. package/build/src/kvk/kvk-file-writer.js.map +1 -1
  87. package/build/src/kvk/kvk-file.d.ts +66 -66
  88. package/build/src/kvk/kvk-file.d.ts.map +1 -1
  89. package/build/src/kvk/kvk-file.js +90 -90
  90. package/build/src/kvk/kvk-file.js.map +1 -1
  91. package/build/src/kvk/kvks-file-reader.d.ts +23 -23
  92. package/build/src/kvk/kvks-file-reader.js +175 -175
  93. package/build/src/kvk/kvks-file-reader.js.map +1 -1
  94. package/build/src/kvk/kvks-file-writer.d.ts +6 -6
  95. package/build/src/kvk/kvks-file-writer.js +106 -106
  96. package/build/src/kvk/kvks-file-writer.js.map +1 -1
  97. package/build/src/kvk/kvks-file.d.ts +43 -43
  98. package/build/src/kvk/kvks-file.js +9 -9
  99. package/build/src/kvk/visual-keyboard.d.ts +44 -44
  100. package/build/src/kvk/visual-keyboard.js +75 -75
  101. package/build/src/kvk/visual-keyboard.js.map +1 -1
  102. package/build/src/ldml-keyboard/ldml-keyboard-testdata-xml.d.ts +60 -60
  103. package/build/src/ldml-keyboard/ldml-keyboard-testdata-xml.js +19 -19
  104. package/build/src/ldml-keyboard/ldml-keyboard-xml-reader.d.ts +95 -95
  105. package/build/src/ldml-keyboard/ldml-keyboard-xml-reader.js +409 -409
  106. package/build/src/ldml-keyboard/ldml-keyboard-xml-reader.js.map +1 -1
  107. package/build/src/ldml-keyboard/ldml-keyboard-xml.d.ts +170 -170
  108. package/build/src/ldml-keyboard/ldml-keyboard-xml.js +55 -55
  109. package/build/src/ldml-keyboard/pattern-parser.d.ts +201 -201
  110. package/build/src/ldml-keyboard/pattern-parser.js +490 -490
  111. package/build/src/ldml-keyboard/pattern-parser.js.map +1 -1
  112. package/build/src/ldml-keyboard/unicodeset-parser-api.d.ts +37 -37
  113. package/build/src/ldml-keyboard/unicodeset-parser-api.js +27 -27
  114. package/build/src/main.d.ts +33 -33
  115. package/build/src/main.js +32 -32
  116. package/build/src/package/kmp-json-file.d.ts +115 -115
  117. package/build/src/package/kmp-json-file.js +1 -1
  118. package/build/src/package/kps-file.d.ts +175 -175
  119. package/build/src/package/kps-file.js +15 -15
  120. package/build/src/schema-validators.d.ts +13 -13
  121. package/build/src/schema-validators.js +25 -25
  122. package/build/src/schemas/displaymap.schema.d.ts +57 -57
  123. package/build/src/schemas/displaymap.schema.js +35 -35
  124. package/build/src/schemas/displaymap.schema.validator.d.mts +2 -2
  125. package/build/src/schemas/displaymap.schema.validator.mjs +266 -266
  126. package/build/src/schemas/displaymap.schema.validator.mjs.map +1 -1
  127. package/build/src/schemas/keyboard_info.schema.d.ts +209 -209
  128. package/build/src/schemas/keyboard_info.schema.js +98 -98
  129. package/build/src/schemas/keyboard_info.schema.validator.d.mts +2 -2
  130. package/build/src/schemas/keyboard_info.schema.validator.mjs +1160 -1160
  131. package/build/src/schemas/keyboard_info.schema.validator.mjs.map +1 -1
  132. package/build/src/schemas/keyman-touch-layout.clean.spec.d.ts +227 -227
  133. package/build/src/schemas/keyman-touch-layout.clean.spec.js +151 -151
  134. package/build/src/schemas/keyman-touch-layout.clean.spec.validator.d.mts +2 -2
  135. package/build/src/schemas/keyman-touch-layout.clean.spec.validator.mjs +1094 -1094
  136. package/build/src/schemas/keyman-touch-layout.clean.spec.validator.mjs.map +1 -1
  137. package/build/src/schemas/keyman-touch-layout.spec.d.ts +229 -229
  138. package/build/src/schemas/keyman-touch-layout.spec.js +140 -140
  139. package/build/src/schemas/keyman-touch-layout.spec.validator.d.mts +2 -2
  140. package/build/src/schemas/keyman-touch-layout.spec.validator.mjs +1436 -1436
  141. package/build/src/schemas/keyman-touch-layout.spec.validator.mjs.map +1 -1
  142. package/build/src/schemas/kmp.schema.d.ts +324 -324
  143. package/build/src/schemas/kmp.schema.js +353 -353
  144. package/build/src/schemas/kmp.schema.validator.d.mts +2 -2
  145. package/build/src/schemas/kmp.schema.validator.mjs +1627 -1627
  146. package/build/src/schemas/kmp.schema.validator.mjs.map +1 -1
  147. package/build/src/schemas/kpj-9.0.schema.d.ts +152 -152
  148. package/build/src/schemas/kpj-9.0.schema.js +131 -131
  149. package/build/src/schemas/kpj-9.0.schema.validator.d.mts +2 -2
  150. package/build/src/schemas/kpj-9.0.schema.validator.mjs +655 -655
  151. package/build/src/schemas/kpj-9.0.schema.validator.mjs.map +1 -1
  152. package/build/src/schemas/kpj.schema.d.ts +122 -122
  153. package/build/src/schemas/kpj.schema.js +129 -129
  154. package/build/src/schemas/kpj.schema.validator.d.mts +2 -2
  155. package/build/src/schemas/kpj.schema.validator.mjs +515 -515
  156. package/build/src/schemas/kpj.schema.validator.mjs.map +1 -1
  157. package/build/src/schemas/kvks.schema.d.ts +160 -160
  158. package/build/src/schemas/kvks.schema.js +182 -182
  159. package/build/src/schemas/kvks.schema.validator.d.mts +2 -2
  160. package/build/src/schemas/kvks.schema.validator.mjs +625 -625
  161. package/build/src/schemas/kvks.schema.validator.mjs.map +1 -1
  162. package/build/src/schemas/ldml-keyboard3.schema.d.ts +635 -635
  163. package/build/src/schemas/ldml-keyboard3.schema.js +696 -696
  164. package/build/src/schemas/ldml-keyboard3.schema.validator.d.mts +2 -2
  165. package/build/src/schemas/ldml-keyboard3.schema.validator.mjs +3117 -3117
  166. package/build/src/schemas/ldml-keyboard3.schema.validator.mjs.map +1 -1
  167. package/build/src/schemas/ldml-keyboardtest3.schema.d.ts +192 -192
  168. package/build/src/schemas/ldml-keyboardtest3.schema.js +225 -225
  169. package/build/src/schemas/ldml-keyboardtest3.schema.validator.d.mts +2 -2
  170. package/build/src/schemas/ldml-keyboardtest3.schema.validator.mjs +744 -744
  171. package/build/src/schemas/ldml-keyboardtest3.schema.validator.mjs.map +1 -1
  172. package/build/src/schemas.d.ts +2300 -2300
  173. package/build/src/schemas.js +23 -23
  174. package/build/src/util/common-events.d.ts +44 -44
  175. package/build/src/util/common-events.js +26 -26
  176. package/build/src/util/compiler-interfaces.d.ts +371 -371
  177. package/build/src/util/compiler-interfaces.d.ts.map +1 -1
  178. package/build/src/util/compiler-interfaces.js +380 -380
  179. package/build/src/util/compiler-interfaces.js.map +1 -1
  180. package/build/src/util/errors.d.ts +5 -5
  181. package/build/src/util/errors.js +5 -5
  182. package/build/src/util/file-types.d.ts +93 -93
  183. package/build/src/util/file-types.d.ts.map +1 -1
  184. package/build/src/util/file-types.js +142 -142
  185. package/build/src/util/file-types.js.map +1 -1
  186. package/build/src/util/util.d.ts +98 -98
  187. package/build/src/util/util.js +368 -368
  188. package/build/src/util/util.js.map +1 -1
  189. package/package.json +3 -3
@@ -1,1096 +1,1096 @@
1
1
 
2
- !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},n=(new Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="8510fa96-2f2f-524a-9352-4bf15241be06")}catch(e){}}();
3
- var __getOwnPropNames = Object.getOwnPropertyNames;
4
- var __commonJS = (cb, mod) => function __require() {
5
- return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
6
- };
7
- // obj/schemas/keyman-touch-layout.clean.spec.validator.cjs
8
- var require_keyman_touch_layout_clean_spec_validator = __commonJS({
9
- "obj/schemas/keyman-touch-layout.clean.spec.validator.cjs"(exports, module) {
10
- module.exports = validate20;
11
- module.exports.default = validate20;
12
- var schema24 = { "type": "object", "properties": { "font": { "$ref": "#/definitions/font-spec" }, "fontsize": { "$ref": "#/definitions/fontsize-spec" }, "layer": { "$ref": "#/definitions/layers" }, "displayUnderlying": { "type": "boolean" }, "defaultHint": { "type": "string", "enum": ["none", "dot", "longpress", "multitap", "flick", "flick-n", "flick-ne", "flick-e", "flick-se", "flick-s", "flick-sw", "flick-w", "flick-nw"] } }, "required": ["layer"], "additionalProperties": false };
13
- var pattern0 = new RegExp("^[a-zA-Z0-9_-]+$", "u");
14
- var schema34 = { "type": "object", "properties": { "id": { "$ref": "#/definitions/key-id" }, "text": { "type": "string" }, "layer": { "$ref": "#/definitions/layer-id" }, "nextlayer": { "$ref": "#/definitions/layer-id" }, "font": { "$ref": "#/definitions/font-spec" }, "fontsize": { "$ref": "#/definitions/fontsize-spec" }, "sp": { "$ref": "#/definitions/key-sp" }, "pad": { "$ref": "#/definitions/key-pad" }, "width": { "$ref": "#/definitions/key-width" }, "sk": { "$ref": "#/definitions/subkeys" }, "flick": { "$ref": "#/definitions/flick" }, "multitap": { "$ref": "#/definitions/subkeys" }, "hint": { "type": "string" } }, "anyOf": [{ "required": ["id"] }, { "required": ["sp"] }, { "required": ["sk"] }, { "required": ["flick"] }, { "required": ["multitap"] }], "additionalProperties": false };
15
- var schema40 = { "type": "integer", "enum": [0, 1, 2, 8, 9, 10] };
16
- var func4 = Object.prototype.hasOwnProperty;
17
- var pattern1 = new RegExp("^[TKUtku]_[a-zA-Z0-9_]+$", "u");
18
- var schema44 = { "type": "object", "properties": { "id": { "$ref": "#/definitions/key-id" }, "text": { "type": "string" }, "layer": { "$ref": "#/definitions/layer-id" }, "nextlayer": { "$ref": "#/definitions/layer-id" }, "font": { "$ref": "#/definitions/font-spec" }, "fontsize": { "$ref": "#/definitions/fontsize-spec" }, "sp": { "$ref": "#/definitions/key-sp" }, "pad": { "$ref": "#/definitions/key-pad" }, "width": { "$ref": "#/definitions/key-width" } }, "required": ["id"], "additionalProperties": false };
19
- function validate30(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
20
- let vErrors = null;
21
- let errors = 0;
22
- if (errors === 0) {
23
- if (data && typeof data == "object" && !Array.isArray(data)) {
24
- let missing0;
25
- if (data.id === void 0 && (missing0 = "id")) {
26
- validate30.errors = [{ instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: missing0 }, message: "must have required property '" + missing0 + "'" }];
27
- return false;
28
- }
29
- else {
30
- const _errs1 = errors;
31
- for (const key0 in data) {
32
- if (!func4.call(schema44.properties, key0)) {
33
- validate30.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
34
- return false;
35
- break;
36
- }
37
- }
38
- if (_errs1 === errors) {
39
- if (data.id !== void 0) {
40
- let data0 = data.id;
41
- const _errs2 = errors;
42
- const _errs3 = errors;
43
- if (errors === _errs3) {
44
- if (typeof data0 === "string") {
45
- if (!pattern1.test(data0)) {
46
- validate30.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/key-id/pattern", keyword: "pattern", params: { pattern: "^[TKUtku]_[a-zA-Z0-9_]+$" }, message: 'must match pattern "^[TKUtku]_[a-zA-Z0-9_]+$"' }];
47
- return false;
48
- }
49
- }
50
- else {
51
- validate30.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/key-id/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
52
- return false;
53
- }
54
- }
55
- var valid0 = _errs2 === errors;
56
- }
57
- else {
58
- var valid0 = true;
59
- }
60
- if (valid0) {
61
- if (data.text !== void 0) {
62
- const _errs5 = errors;
63
- if (typeof data.text !== "string") {
64
- validate30.errors = [{ instancePath: instancePath + "/text", schemaPath: "#/properties/text/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
65
- return false;
66
- }
67
- var valid0 = _errs5 === errors;
68
- }
69
- else {
70
- var valid0 = true;
71
- }
72
- if (valid0) {
73
- if (data.layer !== void 0) {
74
- let data2 = data.layer;
75
- const _errs7 = errors;
76
- const _errs8 = errors;
77
- if (errors === _errs8) {
78
- if (typeof data2 === "string") {
79
- if (!pattern0.test(data2)) {
80
- validate30.errors = [{ instancePath: instancePath + "/layer", schemaPath: "#/definitions/layer-id/pattern", keyword: "pattern", params: { pattern: "^[a-zA-Z0-9_-]+$" }, message: 'must match pattern "^[a-zA-Z0-9_-]+$"' }];
81
- return false;
82
- }
83
- }
84
- else {
85
- validate30.errors = [{ instancePath: instancePath + "/layer", schemaPath: "#/definitions/layer-id/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
86
- return false;
87
- }
88
- }
89
- var valid0 = _errs7 === errors;
90
- }
91
- else {
92
- var valid0 = true;
93
- }
94
- if (valid0) {
95
- if (data.nextlayer !== void 0) {
96
- let data3 = data.nextlayer;
97
- const _errs10 = errors;
98
- const _errs11 = errors;
99
- if (errors === _errs11) {
100
- if (typeof data3 === "string") {
101
- if (!pattern0.test(data3)) {
102
- validate30.errors = [{ instancePath: instancePath + "/nextlayer", schemaPath: "#/definitions/layer-id/pattern", keyword: "pattern", params: { pattern: "^[a-zA-Z0-9_-]+$" }, message: 'must match pattern "^[a-zA-Z0-9_-]+$"' }];
103
- return false;
104
- }
105
- }
106
- else {
107
- validate30.errors = [{ instancePath: instancePath + "/nextlayer", schemaPath: "#/definitions/layer-id/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
108
- return false;
109
- }
110
- }
111
- var valid0 = _errs10 === errors;
112
- }
113
- else {
114
- var valid0 = true;
115
- }
116
- if (valid0) {
117
- if (data.font !== void 0) {
118
- const _errs13 = errors;
119
- if (typeof data.font !== "string") {
120
- validate30.errors = [{ instancePath: instancePath + "/font", schemaPath: "#/definitions/font-spec/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
121
- return false;
122
- }
123
- var valid0 = _errs13 === errors;
124
- }
125
- else {
126
- var valid0 = true;
127
- }
128
- if (valid0) {
129
- if (data.fontsize !== void 0) {
130
- const _errs16 = errors;
131
- if (typeof data.fontsize !== "string") {
132
- validate30.errors = [{ instancePath: instancePath + "/fontsize", schemaPath: "#/definitions/fontsize-spec/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
133
- return false;
134
- }
135
- var valid0 = _errs16 === errors;
136
- }
137
- else {
138
- var valid0 = true;
139
- }
140
- if (valid0) {
141
- if (data.sp !== void 0) {
142
- let data6 = data.sp;
143
- const _errs19 = errors;
144
- if (!(typeof data6 == "number" && (!(data6 % 1) && !isNaN(data6)) && isFinite(data6))) {
145
- validate30.errors = [{ instancePath: instancePath + "/sp", schemaPath: "#/definitions/key-sp/type", keyword: "type", params: { type: "integer" }, message: "must be integer" }];
146
- return false;
147
- }
148
- if (!(data6 === 0 || data6 === 1 || data6 === 2 || data6 === 8 || data6 === 9 || data6 === 10)) {
149
- validate30.errors = [{ instancePath: instancePath + "/sp", schemaPath: "#/definitions/key-sp/enum", keyword: "enum", params: { allowedValues: schema40.enum }, message: "must be equal to one of the allowed values" }];
150
- return false;
151
- }
152
- var valid0 = _errs19 === errors;
153
- }
154
- else {
155
- var valid0 = true;
156
- }
157
- if (valid0) {
158
- if (data.pad !== void 0) {
159
- let data7 = data.pad;
160
- const _errs22 = errors;
161
- const _errs23 = errors;
162
- if (errors === _errs23) {
163
- if (typeof data7 == "number" && isFinite(data7)) {
164
- if (data7 > 1e5 || isNaN(data7)) {
165
- validate30.errors = [{ instancePath: instancePath + "/pad", schemaPath: "#/definitions/key-pad/maximum", keyword: "maximum", params: { comparison: "<=", limit: 1e5 }, message: "must be <= 100000" }];
166
- return false;
167
- }
168
- else {
169
- if (data7 < 0 || isNaN(data7)) {
170
- validate30.errors = [{ instancePath: instancePath + "/pad", schemaPath: "#/definitions/key-pad/minimum", keyword: "minimum", params: { comparison: ">=", limit: 0 }, message: "must be >= 0" }];
171
- return false;
172
- }
173
- }
174
- }
175
- else {
176
- validate30.errors = [{ instancePath: instancePath + "/pad", schemaPath: "#/definitions/key-pad/type", keyword: "type", params: { type: "number" }, message: "must be number" }];
177
- return false;
178
- }
179
- }
180
- var valid0 = _errs22 === errors;
181
- }
182
- else {
183
- var valid0 = true;
184
- }
185
- if (valid0) {
186
- if (data.width !== void 0) {
187
- let data8 = data.width;
188
- const _errs25 = errors;
189
- const _errs26 = errors;
190
- if (errors === _errs26) {
191
- if (typeof data8 == "number" && isFinite(data8)) {
192
- if (data8 > 1e5 || isNaN(data8)) {
193
- validate30.errors = [{ instancePath: instancePath + "/width", schemaPath: "#/definitions/key-width/maximum", keyword: "maximum", params: { comparison: "<=", limit: 1e5 }, message: "must be <= 100000" }];
194
- return false;
195
- }
196
- else {
197
- if (data8 < 0 || isNaN(data8)) {
198
- validate30.errors = [{ instancePath: instancePath + "/width", schemaPath: "#/definitions/key-width/minimum", keyword: "minimum", params: { comparison: ">=", limit: 0 }, message: "must be >= 0" }];
199
- return false;
200
- }
201
- }
202
- }
203
- else {
204
- validate30.errors = [{ instancePath: instancePath + "/width", schemaPath: "#/definitions/key-width/type", keyword: "type", params: { type: "number" }, message: "must be number" }];
205
- return false;
206
- }
207
- }
208
- var valid0 = _errs25 === errors;
209
- }
210
- else {
211
- var valid0 = true;
212
- }
213
- }
214
- }
215
- }
216
- }
217
- }
218
- }
219
- }
220
- }
221
- }
222
- }
223
- }
224
- else {
225
- validate30.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
226
- return false;
227
- }
228
- }
229
- validate30.errors = vErrors;
230
- return errors === 0;
231
- }
232
- function validate29(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
233
- let vErrors = null;
234
- let errors = 0;
235
- if (errors === 0) {
236
- if (Array.isArray(data)) {
237
- if (data.length < 1) {
238
- validate29.errors = [{ instancePath, schemaPath: "#/minItems", keyword: "minItems", params: { limit: 1 }, message: "must NOT have fewer than 1 items" }];
239
- return false;
240
- }
241
- else {
242
- var valid0 = true;
243
- const len0 = data.length;
244
- for (let i0 = 0; i0 < len0; i0++) {
245
- const _errs1 = errors;
246
- if (!validate30(data[i0], { instancePath: instancePath + "/" + i0, parentData: data, parentDataProperty: i0, rootData })) {
247
- vErrors = vErrors === null ? validate30.errors : vErrors.concat(validate30.errors);
248
- errors = vErrors.length;
249
- }
250
- var valid0 = _errs1 === errors;
251
- if (!valid0) {
252
- break;
253
- }
254
- }
255
- }
256
- }
257
- else {
258
- validate29.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
259
- return false;
260
- }
261
- }
262
- validate29.errors = vErrors;
263
- return errors === 0;
264
- }
265
- var pattern7 = new RegExp("^(n|s|e|w|ne|nw|se|sw)$", "u");
266
- function validate33(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
267
- let vErrors = null;
268
- let errors = 0;
269
- if (errors === 0) {
270
- if (data && typeof data == "object" && !Array.isArray(data)) {
271
- if (Object.keys(data).length < 1) {
272
- validate33.errors = [{ instancePath, schemaPath: "#/minProperties", keyword: "minProperties", params: { limit: 1 }, message: "must NOT have fewer than 1 properties" }];
273
- return false;
274
- }
275
- else {
276
- const _errs1 = errors;
277
- for (const key0 in data) {
278
- if (!pattern7.test(key0)) {
279
- validate33.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
280
- return false;
281
- break;
282
- }
283
- }
284
- if (_errs1 === errors) {
285
- var valid0 = true;
286
- for (const key1 in data) {
287
- if (pattern7.test(key1)) {
288
- const _errs2 = errors;
289
- if (!validate30(data[key1], { instancePath: instancePath + "/" + key1.replace(/~/g, "~0").replace(/\//g, "~1"), parentData: data, parentDataProperty: key1, rootData })) {
290
- vErrors = vErrors === null ? validate30.errors : vErrors.concat(validate30.errors);
291
- errors = vErrors.length;
292
- }
293
- var valid0 = _errs2 === errors;
294
- if (!valid0) {
295
- break;
296
- }
297
- }
298
- }
299
- }
300
- }
301
- }
302
- else {
303
- validate33.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
304
- return false;
305
- }
306
- }
307
- validate33.errors = vErrors;
308
- return errors === 0;
309
- }
310
- function validate28(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
311
- let vErrors = null;
312
- let errors = 0;
313
- const _errs1 = errors;
314
- let valid0 = false;
315
- const _errs2 = errors;
316
- if (data && typeof data == "object" && !Array.isArray(data)) {
317
- let missing0;
318
- if (data.id === void 0 && (missing0 = "id")) {
319
- const err0 = { instancePath, schemaPath: "#/anyOf/0/required", keyword: "required", params: { missingProperty: missing0 }, message: "must have required property '" + missing0 + "'" };
320
- if (vErrors === null) {
321
- vErrors = [err0];
322
- }
323
- else {
324
- vErrors.push(err0);
325
- }
326
- errors++;
327
- }
328
- }
329
- var _valid0 = _errs2 === errors;
330
- valid0 = valid0 || _valid0;
331
- if (!valid0) {
332
- const _errs3 = errors;
333
- if (data && typeof data == "object" && !Array.isArray(data)) {
334
- let missing1;
335
- if (data.sp === void 0 && (missing1 = "sp")) {
336
- const err1 = { instancePath, schemaPath: "#/anyOf/1/required", keyword: "required", params: { missingProperty: missing1 }, message: "must have required property '" + missing1 + "'" };
337
- if (vErrors === null) {
338
- vErrors = [err1];
339
- }
340
- else {
341
- vErrors.push(err1);
342
- }
343
- errors++;
344
- }
345
- }
346
- var _valid0 = _errs3 === errors;
347
- valid0 = valid0 || _valid0;
348
- if (!valid0) {
349
- const _errs4 = errors;
350
- if (data && typeof data == "object" && !Array.isArray(data)) {
351
- let missing2;
352
- if (data.sk === void 0 && (missing2 = "sk")) {
353
- const err2 = { instancePath, schemaPath: "#/anyOf/2/required", keyword: "required", params: { missingProperty: missing2 }, message: "must have required property '" + missing2 + "'" };
354
- if (vErrors === null) {
355
- vErrors = [err2];
356
- }
357
- else {
358
- vErrors.push(err2);
359
- }
360
- errors++;
361
- }
362
- }
363
- var _valid0 = _errs4 === errors;
364
- valid0 = valid0 || _valid0;
365
- if (!valid0) {
366
- const _errs5 = errors;
367
- if (data && typeof data == "object" && !Array.isArray(data)) {
368
- let missing3;
369
- if (data.flick === void 0 && (missing3 = "flick")) {
370
- const err3 = { instancePath, schemaPath: "#/anyOf/3/required", keyword: "required", params: { missingProperty: missing3 }, message: "must have required property '" + missing3 + "'" };
371
- if (vErrors === null) {
372
- vErrors = [err3];
373
- }
374
- else {
375
- vErrors.push(err3);
376
- }
377
- errors++;
378
- }
379
- }
380
- var _valid0 = _errs5 === errors;
381
- valid0 = valid0 || _valid0;
382
- if (!valid0) {
383
- const _errs6 = errors;
384
- if (data && typeof data == "object" && !Array.isArray(data)) {
385
- let missing4;
386
- if (data.multitap === void 0 && (missing4 = "multitap")) {
387
- const err4 = { instancePath, schemaPath: "#/anyOf/4/required", keyword: "required", params: { missingProperty: missing4 }, message: "must have required property '" + missing4 + "'" };
388
- if (vErrors === null) {
389
- vErrors = [err4];
390
- }
391
- else {
392
- vErrors.push(err4);
393
- }
394
- errors++;
395
- }
396
- }
397
- var _valid0 = _errs6 === errors;
398
- valid0 = valid0 || _valid0;
399
- }
400
- }
401
- }
402
- }
403
- if (!valid0) {
404
- const err5 = { instancePath, schemaPath: "#/anyOf", keyword: "anyOf", params: {}, message: "must match a schema in anyOf" };
405
- if (vErrors === null) {
406
- vErrors = [err5];
407
- }
408
- else {
409
- vErrors.push(err5);
410
- }
411
- errors++;
412
- validate28.errors = vErrors;
413
- return false;
414
- }
415
- else {
416
- errors = _errs1;
417
- if (vErrors !== null) {
418
- if (_errs1) {
419
- vErrors.length = _errs1;
420
- }
421
- else {
422
- vErrors = null;
423
- }
424
- }
425
- }
426
- if (errors === 0) {
427
- if (data && typeof data == "object" && !Array.isArray(data)) {
428
- const _errs7 = errors;
429
- for (const key0 in data) {
430
- if (!func4.call(schema34.properties, key0)) {
431
- validate28.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
432
- return false;
433
- break;
434
- }
435
- }
436
- if (_errs7 === errors) {
437
- if (data.id !== void 0) {
438
- let data0 = data.id;
439
- const _errs8 = errors;
440
- const _errs9 = errors;
441
- if (errors === _errs9) {
442
- if (typeof data0 === "string") {
443
- if (!pattern1.test(data0)) {
444
- validate28.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/key-id/pattern", keyword: "pattern", params: { pattern: "^[TKUtku]_[a-zA-Z0-9_]+$" }, message: 'must match pattern "^[TKUtku]_[a-zA-Z0-9_]+$"' }];
445
- return false;
446
- }
447
- }
448
- else {
449
- validate28.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/key-id/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
450
- return false;
451
- }
452
- }
453
- var valid1 = _errs8 === errors;
454
- }
455
- else {
456
- var valid1 = true;
457
- }
458
- if (valid1) {
459
- if (data.text !== void 0) {
460
- const _errs11 = errors;
461
- if (typeof data.text !== "string") {
462
- validate28.errors = [{ instancePath: instancePath + "/text", schemaPath: "#/properties/text/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
463
- return false;
464
- }
465
- var valid1 = _errs11 === errors;
466
- }
467
- else {
468
- var valid1 = true;
469
- }
470
- if (valid1) {
471
- if (data.layer !== void 0) {
472
- let data2 = data.layer;
473
- const _errs13 = errors;
474
- const _errs14 = errors;
475
- if (errors === _errs14) {
476
- if (typeof data2 === "string") {
477
- if (!pattern0.test(data2)) {
478
- validate28.errors = [{ instancePath: instancePath + "/layer", schemaPath: "#/definitions/layer-id/pattern", keyword: "pattern", params: { pattern: "^[a-zA-Z0-9_-]+$" }, message: 'must match pattern "^[a-zA-Z0-9_-]+$"' }];
479
- return false;
480
- }
481
- }
482
- else {
483
- validate28.errors = [{ instancePath: instancePath + "/layer", schemaPath: "#/definitions/layer-id/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
484
- return false;
485
- }
486
- }
487
- var valid1 = _errs13 === errors;
488
- }
489
- else {
490
- var valid1 = true;
491
- }
492
- if (valid1) {
493
- if (data.nextlayer !== void 0) {
494
- let data3 = data.nextlayer;
495
- const _errs16 = errors;
496
- const _errs17 = errors;
497
- if (errors === _errs17) {
498
- if (typeof data3 === "string") {
499
- if (!pattern0.test(data3)) {
500
- validate28.errors = [{ instancePath: instancePath + "/nextlayer", schemaPath: "#/definitions/layer-id/pattern", keyword: "pattern", params: { pattern: "^[a-zA-Z0-9_-]+$" }, message: 'must match pattern "^[a-zA-Z0-9_-]+$"' }];
501
- return false;
502
- }
503
- }
504
- else {
505
- validate28.errors = [{ instancePath: instancePath + "/nextlayer", schemaPath: "#/definitions/layer-id/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
506
- return false;
507
- }
508
- }
509
- var valid1 = _errs16 === errors;
510
- }
511
- else {
512
- var valid1 = true;
513
- }
514
- if (valid1) {
515
- if (data.font !== void 0) {
516
- const _errs19 = errors;
517
- if (typeof data.font !== "string") {
518
- validate28.errors = [{ instancePath: instancePath + "/font", schemaPath: "#/definitions/font-spec/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
519
- return false;
520
- }
521
- var valid1 = _errs19 === errors;
522
- }
523
- else {
524
- var valid1 = true;
525
- }
526
- if (valid1) {
527
- if (data.fontsize !== void 0) {
528
- const _errs22 = errors;
529
- if (typeof data.fontsize !== "string") {
530
- validate28.errors = [{ instancePath: instancePath + "/fontsize", schemaPath: "#/definitions/fontsize-spec/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
531
- return false;
532
- }
533
- var valid1 = _errs22 === errors;
534
- }
535
- else {
536
- var valid1 = true;
537
- }
538
- if (valid1) {
539
- if (data.sp !== void 0) {
540
- let data6 = data.sp;
541
- const _errs25 = errors;
542
- if (!(typeof data6 == "number" && (!(data6 % 1) && !isNaN(data6)) && isFinite(data6))) {
543
- validate28.errors = [{ instancePath: instancePath + "/sp", schemaPath: "#/definitions/key-sp/type", keyword: "type", params: { type: "integer" }, message: "must be integer" }];
544
- return false;
545
- }
546
- if (!(data6 === 0 || data6 === 1 || data6 === 2 || data6 === 8 || data6 === 9 || data6 === 10)) {
547
- validate28.errors = [{ instancePath: instancePath + "/sp", schemaPath: "#/definitions/key-sp/enum", keyword: "enum", params: { allowedValues: schema40.enum }, message: "must be equal to one of the allowed values" }];
548
- return false;
549
- }
550
- var valid1 = _errs25 === errors;
551
- }
552
- else {
553
- var valid1 = true;
554
- }
555
- if (valid1) {
556
- if (data.pad !== void 0) {
557
- let data7 = data.pad;
558
- const _errs28 = errors;
559
- const _errs29 = errors;
560
- if (errors === _errs29) {
561
- if (typeof data7 == "number" && isFinite(data7)) {
562
- if (data7 > 1e5 || isNaN(data7)) {
563
- validate28.errors = [{ instancePath: instancePath + "/pad", schemaPath: "#/definitions/key-pad/maximum", keyword: "maximum", params: { comparison: "<=", limit: 1e5 }, message: "must be <= 100000" }];
564
- return false;
565
- }
566
- else {
567
- if (data7 < 0 || isNaN(data7)) {
568
- validate28.errors = [{ instancePath: instancePath + "/pad", schemaPath: "#/definitions/key-pad/minimum", keyword: "minimum", params: { comparison: ">=", limit: 0 }, message: "must be >= 0" }];
569
- return false;
570
- }
571
- }
572
- }
573
- else {
574
- validate28.errors = [{ instancePath: instancePath + "/pad", schemaPath: "#/definitions/key-pad/type", keyword: "type", params: { type: "number" }, message: "must be number" }];
575
- return false;
576
- }
577
- }
578
- var valid1 = _errs28 === errors;
579
- }
580
- else {
581
- var valid1 = true;
582
- }
583
- if (valid1) {
584
- if (data.width !== void 0) {
585
- let data8 = data.width;
586
- const _errs31 = errors;
587
- const _errs32 = errors;
588
- if (errors === _errs32) {
589
- if (typeof data8 == "number" && isFinite(data8)) {
590
- if (data8 > 1e5 || isNaN(data8)) {
591
- validate28.errors = [{ instancePath: instancePath + "/width", schemaPath: "#/definitions/key-width/maximum", keyword: "maximum", params: { comparison: "<=", limit: 1e5 }, message: "must be <= 100000" }];
592
- return false;
593
- }
594
- else {
595
- if (data8 < 0 || isNaN(data8)) {
596
- validate28.errors = [{ instancePath: instancePath + "/width", schemaPath: "#/definitions/key-width/minimum", keyword: "minimum", params: { comparison: ">=", limit: 0 }, message: "must be >= 0" }];
597
- return false;
598
- }
599
- }
600
- }
601
- else {
602
- validate28.errors = [{ instancePath: instancePath + "/width", schemaPath: "#/definitions/key-width/type", keyword: "type", params: { type: "number" }, message: "must be number" }];
603
- return false;
604
- }
605
- }
606
- var valid1 = _errs31 === errors;
607
- }
608
- else {
609
- var valid1 = true;
610
- }
611
- if (valid1) {
612
- if (data.sk !== void 0) {
613
- const _errs34 = errors;
614
- if (!validate29(data.sk, { instancePath: instancePath + "/sk", parentData: data, parentDataProperty: "sk", rootData })) {
615
- vErrors = vErrors === null ? validate29.errors : vErrors.concat(validate29.errors);
616
- errors = vErrors.length;
617
- }
618
- var valid1 = _errs34 === errors;
619
- }
620
- else {
621
- var valid1 = true;
622
- }
623
- if (valid1) {
624
- if (data.flick !== void 0) {
625
- const _errs35 = errors;
626
- if (!validate33(data.flick, { instancePath: instancePath + "/flick", parentData: data, parentDataProperty: "flick", rootData })) {
627
- vErrors = vErrors === null ? validate33.errors : vErrors.concat(validate33.errors);
628
- errors = vErrors.length;
629
- }
630
- var valid1 = _errs35 === errors;
631
- }
632
- else {
633
- var valid1 = true;
634
- }
635
- if (valid1) {
636
- if (data.multitap !== void 0) {
637
- const _errs36 = errors;
638
- if (!validate29(data.multitap, { instancePath: instancePath + "/multitap", parentData: data, parentDataProperty: "multitap", rootData })) {
639
- vErrors = vErrors === null ? validate29.errors : vErrors.concat(validate29.errors);
640
- errors = vErrors.length;
641
- }
642
- var valid1 = _errs36 === errors;
643
- }
644
- else {
645
- var valid1 = true;
646
- }
647
- if (valid1) {
648
- if (data.hint !== void 0) {
649
- const _errs37 = errors;
650
- if (typeof data.hint !== "string") {
651
- validate28.errors = [{ instancePath: instancePath + "/hint", schemaPath: "#/properties/hint/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
652
- return false;
653
- }
654
- var valid1 = _errs37 === errors;
655
- }
656
- else {
657
- var valid1 = true;
658
- }
659
- }
660
- }
661
- }
662
- }
663
- }
664
- }
665
- }
666
- }
667
- }
668
- }
669
- }
670
- }
671
- }
672
- }
673
- else {
674
- validate28.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
675
- return false;
676
- }
677
- }
678
- validate28.errors = vErrors;
679
- return errors === 0;
680
- }
681
- function validate27(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
682
- let vErrors = null;
683
- let errors = 0;
684
- if (errors === 0) {
685
- if (Array.isArray(data)) {
686
- if (data.length < 1) {
687
- validate27.errors = [{ instancePath, schemaPath: "#/minItems", keyword: "minItems", params: { limit: 1 }, message: "must NOT have fewer than 1 items" }];
688
- return false;
689
- }
690
- else {
691
- var valid0 = true;
692
- const len0 = data.length;
693
- for (let i0 = 0; i0 < len0; i0++) {
694
- const _errs1 = errors;
695
- if (!validate28(data[i0], { instancePath: instancePath + "/" + i0, parentData: data, parentDataProperty: i0, rootData })) {
696
- vErrors = vErrors === null ? validate28.errors : vErrors.concat(validate28.errors);
697
- errors = vErrors.length;
698
- }
699
- var valid0 = _errs1 === errors;
700
- if (!valid0) {
701
- break;
702
- }
703
- }
704
- }
705
- }
706
- else {
707
- validate27.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
708
- return false;
709
- }
710
- }
711
- validate27.errors = vErrors;
712
- return errors === 0;
713
- }
714
- function validate26(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
715
- let vErrors = null;
716
- let errors = 0;
717
- if (errors === 0) {
718
- if (data && typeof data == "object" && !Array.isArray(data)) {
719
- let missing0;
720
- if (data.id === void 0 && (missing0 = "id") || data.key === void 0 && (missing0 = "key")) {
721
- validate26.errors = [{ instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: missing0 }, message: "must have required property '" + missing0 + "'" }];
722
- return false;
723
- }
724
- else {
725
- const _errs1 = errors;
726
- for (const key0 in data) {
727
- if (!(key0 === "id" || key0 === "key")) {
728
- validate26.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
729
- return false;
730
- break;
731
- }
732
- }
733
- if (_errs1 === errors) {
734
- if (data.id !== void 0) {
735
- let data0 = data.id;
736
- const _errs2 = errors;
737
- const _errs3 = errors;
738
- if (!(typeof data0 == "number" && (!(data0 % 1) && !isNaN(data0)) && isFinite(data0))) {
739
- validate26.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/row-id/type", keyword: "type", params: { type: "integer" }, message: "must be integer" }];
740
- return false;
741
- }
742
- if (errors === _errs3) {
743
- if (typeof data0 == "number" && isFinite(data0)) {
744
- if (data0 > 100 || isNaN(data0)) {
745
- validate26.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/row-id/maximum", keyword: "maximum", params: { comparison: "<=", limit: 100 }, message: "must be <= 100" }];
746
- return false;
747
- }
748
- else {
749
- if (data0 < 0 || isNaN(data0)) {
750
- validate26.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/row-id/minimum", keyword: "minimum", params: { comparison: ">=", limit: 0 }, message: "must be >= 0" }];
751
- return false;
752
- }
753
- }
754
- }
755
- }
756
- var valid0 = _errs2 === errors;
757
- }
758
- else {
759
- var valid0 = true;
760
- }
761
- if (valid0) {
762
- if (data.key !== void 0) {
763
- const _errs5 = errors;
764
- if (!validate27(data.key, { instancePath: instancePath + "/key", parentData: data, parentDataProperty: "key", rootData })) {
765
- vErrors = vErrors === null ? validate27.errors : vErrors.concat(validate27.errors);
766
- errors = vErrors.length;
767
- }
768
- var valid0 = _errs5 === errors;
769
- }
770
- else {
771
- var valid0 = true;
772
- }
773
- }
774
- }
775
- }
776
- }
777
- else {
778
- validate26.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
779
- return false;
780
- }
781
- }
782
- validate26.errors = vErrors;
783
- return errors === 0;
784
- }
785
- function validate25(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
786
- let vErrors = null;
787
- let errors = 0;
788
- if (errors === 0) {
789
- if (Array.isArray(data)) {
790
- if (data.length < 1) {
791
- validate25.errors = [{ instancePath, schemaPath: "#/minItems", keyword: "minItems", params: { limit: 1 }, message: "must NOT have fewer than 1 items" }];
792
- return false;
793
- }
794
- else {
795
- var valid0 = true;
796
- const len0 = data.length;
797
- for (let i0 = 0; i0 < len0; i0++) {
798
- const _errs1 = errors;
799
- if (!validate26(data[i0], { instancePath: instancePath + "/" + i0, parentData: data, parentDataProperty: i0, rootData })) {
800
- vErrors = vErrors === null ? validate26.errors : vErrors.concat(validate26.errors);
801
- errors = vErrors.length;
802
- }
803
- var valid0 = _errs1 === errors;
804
- if (!valid0) {
805
- break;
806
- }
807
- }
808
- }
809
- }
810
- else {
811
- validate25.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
812
- return false;
813
- }
814
- }
815
- validate25.errors = vErrors;
816
- return errors === 0;
817
- }
818
- function validate24(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
819
- let vErrors = null;
820
- let errors = 0;
821
- if (errors === 0) {
822
- if (data && typeof data == "object" && !Array.isArray(data)) {
823
- let missing0;
824
- if (data.id === void 0 && (missing0 = "id") || data.row === void 0 && (missing0 = "row")) {
825
- validate24.errors = [{ instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: missing0 }, message: "must have required property '" + missing0 + "'" }];
826
- return false;
827
- }
828
- else {
829
- const _errs1 = errors;
830
- for (const key0 in data) {
831
- if (!(key0 === "id" || key0 === "row")) {
832
- validate24.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
833
- return false;
834
- break;
835
- }
836
- }
837
- if (_errs1 === errors) {
838
- if (data.id !== void 0) {
839
- let data0 = data.id;
840
- const _errs2 = errors;
841
- const _errs3 = errors;
842
- if (errors === _errs3) {
843
- if (typeof data0 === "string") {
844
- if (!pattern0.test(data0)) {
845
- validate24.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/layer-id/pattern", keyword: "pattern", params: { pattern: "^[a-zA-Z0-9_-]+$" }, message: 'must match pattern "^[a-zA-Z0-9_-]+$"' }];
846
- return false;
847
- }
848
- }
849
- else {
850
- validate24.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/layer-id/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
851
- return false;
852
- }
853
- }
854
- var valid0 = _errs2 === errors;
855
- }
856
- else {
857
- var valid0 = true;
858
- }
859
- if (valid0) {
860
- if (data.row !== void 0) {
861
- const _errs5 = errors;
862
- if (!validate25(data.row, { instancePath: instancePath + "/row", parentData: data, parentDataProperty: "row", rootData })) {
863
- vErrors = vErrors === null ? validate25.errors : vErrors.concat(validate25.errors);
864
- errors = vErrors.length;
865
- }
866
- var valid0 = _errs5 === errors;
867
- }
868
- else {
869
- var valid0 = true;
870
- }
871
- }
872
- }
873
- }
874
- }
875
- else {
876
- validate24.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
877
- return false;
878
- }
879
- }
880
- validate24.errors = vErrors;
881
- return errors === 0;
882
- }
883
- function validate23(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
884
- let vErrors = null;
885
- let errors = 0;
886
- if (errors === 0) {
887
- if (Array.isArray(data)) {
888
- if (data.length < 1) {
889
- validate23.errors = [{ instancePath, schemaPath: "#/minItems", keyword: "minItems", params: { limit: 1 }, message: "must NOT have fewer than 1 items" }];
890
- return false;
891
- }
892
- else {
893
- var valid0 = true;
894
- const len0 = data.length;
895
- for (let i0 = 0; i0 < len0; i0++) {
896
- const _errs1 = errors;
897
- if (!validate24(data[i0], { instancePath: instancePath + "/" + i0, parentData: data, parentDataProperty: i0, rootData })) {
898
- vErrors = vErrors === null ? validate24.errors : vErrors.concat(validate24.errors);
899
- errors = vErrors.length;
900
- }
901
- var valid0 = _errs1 === errors;
902
- if (!valid0) {
903
- break;
904
- }
905
- }
906
- }
907
- }
908
- else {
909
- validate23.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
910
- return false;
911
- }
912
- }
913
- validate23.errors = vErrors;
914
- return errors === 0;
915
- }
916
- function validate22(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
917
- let vErrors = null;
918
- let errors = 0;
919
- if (errors === 0) {
920
- if (data && typeof data == "object" && !Array.isArray(data)) {
921
- let missing0;
922
- if (data.layer === void 0 && (missing0 = "layer")) {
923
- validate22.errors = [{ instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: missing0 }, message: "must have required property '" + missing0 + "'" }];
924
- return false;
925
- }
926
- else {
927
- const _errs1 = errors;
928
- for (const key0 in data) {
929
- if (!(key0 === "font" || key0 === "fontsize" || key0 === "layer" || key0 === "displayUnderlying" || key0 === "defaultHint")) {
930
- validate22.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
931
- return false;
932
- break;
933
- }
934
- }
935
- if (_errs1 === errors) {
936
- if (data.font !== void 0) {
937
- const _errs2 = errors;
938
- if (typeof data.font !== "string") {
939
- validate22.errors = [{ instancePath: instancePath + "/font", schemaPath: "#/definitions/font-spec/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
940
- return false;
941
- }
942
- var valid0 = _errs2 === errors;
943
- }
944
- else {
945
- var valid0 = true;
946
- }
947
- if (valid0) {
948
- if (data.fontsize !== void 0) {
949
- const _errs5 = errors;
950
- if (typeof data.fontsize !== "string") {
951
- validate22.errors = [{ instancePath: instancePath + "/fontsize", schemaPath: "#/definitions/fontsize-spec/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
952
- return false;
953
- }
954
- var valid0 = _errs5 === errors;
955
- }
956
- else {
957
- var valid0 = true;
958
- }
959
- if (valid0) {
960
- if (data.layer !== void 0) {
961
- const _errs8 = errors;
962
- if (!validate23(data.layer, { instancePath: instancePath + "/layer", parentData: data, parentDataProperty: "layer", rootData })) {
963
- vErrors = vErrors === null ? validate23.errors : vErrors.concat(validate23.errors);
964
- errors = vErrors.length;
965
- }
966
- var valid0 = _errs8 === errors;
967
- }
968
- else {
969
- var valid0 = true;
970
- }
971
- if (valid0) {
972
- if (data.displayUnderlying !== void 0) {
973
- const _errs9 = errors;
974
- if (typeof data.displayUnderlying !== "boolean") {
975
- validate22.errors = [{ instancePath: instancePath + "/displayUnderlying", schemaPath: "#/properties/displayUnderlying/type", keyword: "type", params: { type: "boolean" }, message: "must be boolean" }];
976
- return false;
977
- }
978
- var valid0 = _errs9 === errors;
979
- }
980
- else {
981
- var valid0 = true;
982
- }
983
- if (valid0) {
984
- if (data.defaultHint !== void 0) {
985
- let data4 = data.defaultHint;
986
- const _errs11 = errors;
987
- if (typeof data4 !== "string") {
988
- validate22.errors = [{ instancePath: instancePath + "/defaultHint", schemaPath: "#/properties/defaultHint/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
989
- return false;
990
- }
991
- if (!(data4 === "none" || data4 === "dot" || data4 === "longpress" || data4 === "multitap" || data4 === "flick" || data4 === "flick-n" || data4 === "flick-ne" || data4 === "flick-e" || data4 === "flick-se" || data4 === "flick-s" || data4 === "flick-sw" || data4 === "flick-w" || data4 === "flick-nw")) {
992
- validate22.errors = [{ instancePath: instancePath + "/defaultHint", schemaPath: "#/properties/defaultHint/enum", keyword: "enum", params: { allowedValues: schema24.properties.defaultHint.enum }, message: "must be equal to one of the allowed values" }];
993
- return false;
994
- }
995
- var valid0 = _errs11 === errors;
996
- }
997
- else {
998
- var valid0 = true;
999
- }
1000
- }
1001
- }
1002
- }
1003
- }
1004
- }
1005
- }
1006
- }
1007
- else {
1008
- validate22.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
1009
- return false;
1010
- }
1011
- }
1012
- validate22.errors = vErrors;
1013
- return errors === 0;
1014
- }
1015
- function validate21(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
1016
- let vErrors = null;
1017
- let errors = 0;
1018
- if (errors === 0) {
1019
- if (data && typeof data == "object" && !Array.isArray(data)) {
1020
- if (Object.keys(data).length < 1) {
1021
- validate21.errors = [{ instancePath, schemaPath: "#/minProperties", keyword: "minProperties", params: { limit: 1 }, message: "must NOT have fewer than 1 properties" }];
1022
- return false;
1023
- }
1024
- else {
1025
- const _errs1 = errors;
1026
- for (const key0 in data) {
1027
- if (!(key0 === "tablet" || key0 === "phone" || key0 === "desktop")) {
1028
- validate21.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
1029
- return false;
1030
- break;
1031
- }
1032
- }
1033
- if (_errs1 === errors) {
1034
- if (data.tablet !== void 0) {
1035
- const _errs2 = errors;
1036
- if (!validate22(data.tablet, { instancePath: instancePath + "/tablet", parentData: data, parentDataProperty: "tablet", rootData })) {
1037
- vErrors = vErrors === null ? validate22.errors : vErrors.concat(validate22.errors);
1038
- errors = vErrors.length;
1039
- }
1040
- var valid0 = _errs2 === errors;
1041
- }
1042
- else {
1043
- var valid0 = true;
1044
- }
1045
- if (valid0) {
1046
- if (data.phone !== void 0) {
1047
- const _errs3 = errors;
1048
- if (!validate22(data.phone, { instancePath: instancePath + "/phone", parentData: data, parentDataProperty: "phone", rootData })) {
1049
- vErrors = vErrors === null ? validate22.errors : vErrors.concat(validate22.errors);
1050
- errors = vErrors.length;
1051
- }
1052
- var valid0 = _errs3 === errors;
1053
- }
1054
- else {
1055
- var valid0 = true;
1056
- }
1057
- if (valid0) {
1058
- if (data.desktop !== void 0) {
1059
- const _errs4 = errors;
1060
- if (!validate22(data.desktop, { instancePath: instancePath + "/desktop", parentData: data, parentDataProperty: "desktop", rootData })) {
1061
- vErrors = vErrors === null ? validate22.errors : vErrors.concat(validate22.errors);
1062
- errors = vErrors.length;
1063
- }
1064
- var valid0 = _errs4 === errors;
1065
- }
1066
- else {
1067
- var valid0 = true;
1068
- }
1069
- }
1070
- }
1071
- }
1072
- }
1073
- }
1074
- else {
1075
- validate21.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
1076
- return false;
1077
- }
1078
- }
1079
- validate21.errors = vErrors;
1080
- return errors === 0;
1081
- }
1082
- function validate20(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
1083
- let vErrors = null;
1084
- let errors = 0;
1085
- if (!validate21(data, { instancePath, parentData, parentDataProperty, rootData })) {
1086
- vErrors = vErrors === null ? validate21.errors : vErrors.concat(validate21.errors);
1087
- errors = vErrors.length;
1088
- }
1089
- validate20.errors = vErrors;
1090
- return errors === 0;
1091
- }
1092
- }
1093
- });
1094
- export default require_keyman_touch_layout_clean_spec_validator();
2
+ !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},n=(new Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="3b0b36e6-39c2-543d-9b0e-24fd344b9af5")}catch(e){}}();
3
+ var __getOwnPropNames = Object.getOwnPropertyNames;
4
+ var __commonJS = (cb, mod) => function __require() {
5
+ return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
6
+ };
7
+ // obj/schemas/keyman-touch-layout.clean.spec.validator.cjs
8
+ var require_keyman_touch_layout_clean_spec_validator = __commonJS({
9
+ "obj/schemas/keyman-touch-layout.clean.spec.validator.cjs"(exports, module) {
10
+ module.exports = validate20;
11
+ module.exports.default = validate20;
12
+ var schema24 = { "type": "object", "properties": { "font": { "$ref": "#/definitions/font-spec" }, "fontsize": { "$ref": "#/definitions/fontsize-spec" }, "layer": { "$ref": "#/definitions/layers" }, "displayUnderlying": { "type": "boolean" }, "defaultHint": { "type": "string", "enum": ["none", "dot", "longpress", "multitap", "flick", "flick-n", "flick-ne", "flick-e", "flick-se", "flick-s", "flick-sw", "flick-w", "flick-nw"] } }, "required": ["layer"], "additionalProperties": false };
13
+ var pattern0 = new RegExp("^[a-zA-Z0-9_-]+$", "u");
14
+ var schema34 = { "type": "object", "properties": { "id": { "$ref": "#/definitions/key-id" }, "text": { "type": "string" }, "layer": { "$ref": "#/definitions/layer-id" }, "nextlayer": { "$ref": "#/definitions/layer-id" }, "font": { "$ref": "#/definitions/font-spec" }, "fontsize": { "$ref": "#/definitions/fontsize-spec" }, "sp": { "$ref": "#/definitions/key-sp" }, "pad": { "$ref": "#/definitions/key-pad" }, "width": { "$ref": "#/definitions/key-width" }, "sk": { "$ref": "#/definitions/subkeys" }, "flick": { "$ref": "#/definitions/flick" }, "multitap": { "$ref": "#/definitions/subkeys" }, "hint": { "type": "string" } }, "anyOf": [{ "required": ["id"] }, { "required": ["sp"] }, { "required": ["sk"] }, { "required": ["flick"] }, { "required": ["multitap"] }], "additionalProperties": false };
15
+ var schema40 = { "type": "integer", "enum": [0, 1, 2, 8, 9, 10] };
16
+ var func4 = Object.prototype.hasOwnProperty;
17
+ var pattern1 = new RegExp("^[TKUtku]_[a-zA-Z0-9_]+$", "u");
18
+ var schema44 = { "type": "object", "properties": { "id": { "$ref": "#/definitions/key-id" }, "text": { "type": "string" }, "layer": { "$ref": "#/definitions/layer-id" }, "nextlayer": { "$ref": "#/definitions/layer-id" }, "font": { "$ref": "#/definitions/font-spec" }, "fontsize": { "$ref": "#/definitions/fontsize-spec" }, "sp": { "$ref": "#/definitions/key-sp" }, "pad": { "$ref": "#/definitions/key-pad" }, "width": { "$ref": "#/definitions/key-width" } }, "required": ["id"], "additionalProperties": false };
19
+ function validate30(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
20
+ let vErrors = null;
21
+ let errors = 0;
22
+ if (errors === 0) {
23
+ if (data && typeof data == "object" && !Array.isArray(data)) {
24
+ let missing0;
25
+ if (data.id === void 0 && (missing0 = "id")) {
26
+ validate30.errors = [{ instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: missing0 }, message: "must have required property '" + missing0 + "'" }];
27
+ return false;
28
+ }
29
+ else {
30
+ const _errs1 = errors;
31
+ for (const key0 in data) {
32
+ if (!func4.call(schema44.properties, key0)) {
33
+ validate30.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
34
+ return false;
35
+ break;
36
+ }
37
+ }
38
+ if (_errs1 === errors) {
39
+ if (data.id !== void 0) {
40
+ let data0 = data.id;
41
+ const _errs2 = errors;
42
+ const _errs3 = errors;
43
+ if (errors === _errs3) {
44
+ if (typeof data0 === "string") {
45
+ if (!pattern1.test(data0)) {
46
+ validate30.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/key-id/pattern", keyword: "pattern", params: { pattern: "^[TKUtku]_[a-zA-Z0-9_]+$" }, message: 'must match pattern "^[TKUtku]_[a-zA-Z0-9_]+$"' }];
47
+ return false;
48
+ }
49
+ }
50
+ else {
51
+ validate30.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/key-id/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
52
+ return false;
53
+ }
54
+ }
55
+ var valid0 = _errs2 === errors;
56
+ }
57
+ else {
58
+ var valid0 = true;
59
+ }
60
+ if (valid0) {
61
+ if (data.text !== void 0) {
62
+ const _errs5 = errors;
63
+ if (typeof data.text !== "string") {
64
+ validate30.errors = [{ instancePath: instancePath + "/text", schemaPath: "#/properties/text/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
65
+ return false;
66
+ }
67
+ var valid0 = _errs5 === errors;
68
+ }
69
+ else {
70
+ var valid0 = true;
71
+ }
72
+ if (valid0) {
73
+ if (data.layer !== void 0) {
74
+ let data2 = data.layer;
75
+ const _errs7 = errors;
76
+ const _errs8 = errors;
77
+ if (errors === _errs8) {
78
+ if (typeof data2 === "string") {
79
+ if (!pattern0.test(data2)) {
80
+ validate30.errors = [{ instancePath: instancePath + "/layer", schemaPath: "#/definitions/layer-id/pattern", keyword: "pattern", params: { pattern: "^[a-zA-Z0-9_-]+$" }, message: 'must match pattern "^[a-zA-Z0-9_-]+$"' }];
81
+ return false;
82
+ }
83
+ }
84
+ else {
85
+ validate30.errors = [{ instancePath: instancePath + "/layer", schemaPath: "#/definitions/layer-id/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
86
+ return false;
87
+ }
88
+ }
89
+ var valid0 = _errs7 === errors;
90
+ }
91
+ else {
92
+ var valid0 = true;
93
+ }
94
+ if (valid0) {
95
+ if (data.nextlayer !== void 0) {
96
+ let data3 = data.nextlayer;
97
+ const _errs10 = errors;
98
+ const _errs11 = errors;
99
+ if (errors === _errs11) {
100
+ if (typeof data3 === "string") {
101
+ if (!pattern0.test(data3)) {
102
+ validate30.errors = [{ instancePath: instancePath + "/nextlayer", schemaPath: "#/definitions/layer-id/pattern", keyword: "pattern", params: { pattern: "^[a-zA-Z0-9_-]+$" }, message: 'must match pattern "^[a-zA-Z0-9_-]+$"' }];
103
+ return false;
104
+ }
105
+ }
106
+ else {
107
+ validate30.errors = [{ instancePath: instancePath + "/nextlayer", schemaPath: "#/definitions/layer-id/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
108
+ return false;
109
+ }
110
+ }
111
+ var valid0 = _errs10 === errors;
112
+ }
113
+ else {
114
+ var valid0 = true;
115
+ }
116
+ if (valid0) {
117
+ if (data.font !== void 0) {
118
+ const _errs13 = errors;
119
+ if (typeof data.font !== "string") {
120
+ validate30.errors = [{ instancePath: instancePath + "/font", schemaPath: "#/definitions/font-spec/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
121
+ return false;
122
+ }
123
+ var valid0 = _errs13 === errors;
124
+ }
125
+ else {
126
+ var valid0 = true;
127
+ }
128
+ if (valid0) {
129
+ if (data.fontsize !== void 0) {
130
+ const _errs16 = errors;
131
+ if (typeof data.fontsize !== "string") {
132
+ validate30.errors = [{ instancePath: instancePath + "/fontsize", schemaPath: "#/definitions/fontsize-spec/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
133
+ return false;
134
+ }
135
+ var valid0 = _errs16 === errors;
136
+ }
137
+ else {
138
+ var valid0 = true;
139
+ }
140
+ if (valid0) {
141
+ if (data.sp !== void 0) {
142
+ let data6 = data.sp;
143
+ const _errs19 = errors;
144
+ if (!(typeof data6 == "number" && (!(data6 % 1) && !isNaN(data6)) && isFinite(data6))) {
145
+ validate30.errors = [{ instancePath: instancePath + "/sp", schemaPath: "#/definitions/key-sp/type", keyword: "type", params: { type: "integer" }, message: "must be integer" }];
146
+ return false;
147
+ }
148
+ if (!(data6 === 0 || data6 === 1 || data6 === 2 || data6 === 8 || data6 === 9 || data6 === 10)) {
149
+ validate30.errors = [{ instancePath: instancePath + "/sp", schemaPath: "#/definitions/key-sp/enum", keyword: "enum", params: { allowedValues: schema40.enum }, message: "must be equal to one of the allowed values" }];
150
+ return false;
151
+ }
152
+ var valid0 = _errs19 === errors;
153
+ }
154
+ else {
155
+ var valid0 = true;
156
+ }
157
+ if (valid0) {
158
+ if (data.pad !== void 0) {
159
+ let data7 = data.pad;
160
+ const _errs22 = errors;
161
+ const _errs23 = errors;
162
+ if (errors === _errs23) {
163
+ if (typeof data7 == "number" && isFinite(data7)) {
164
+ if (data7 > 1e5 || isNaN(data7)) {
165
+ validate30.errors = [{ instancePath: instancePath + "/pad", schemaPath: "#/definitions/key-pad/maximum", keyword: "maximum", params: { comparison: "<=", limit: 1e5 }, message: "must be <= 100000" }];
166
+ return false;
167
+ }
168
+ else {
169
+ if (data7 < 0 || isNaN(data7)) {
170
+ validate30.errors = [{ instancePath: instancePath + "/pad", schemaPath: "#/definitions/key-pad/minimum", keyword: "minimum", params: { comparison: ">=", limit: 0 }, message: "must be >= 0" }];
171
+ return false;
172
+ }
173
+ }
174
+ }
175
+ else {
176
+ validate30.errors = [{ instancePath: instancePath + "/pad", schemaPath: "#/definitions/key-pad/type", keyword: "type", params: { type: "number" }, message: "must be number" }];
177
+ return false;
178
+ }
179
+ }
180
+ var valid0 = _errs22 === errors;
181
+ }
182
+ else {
183
+ var valid0 = true;
184
+ }
185
+ if (valid0) {
186
+ if (data.width !== void 0) {
187
+ let data8 = data.width;
188
+ const _errs25 = errors;
189
+ const _errs26 = errors;
190
+ if (errors === _errs26) {
191
+ if (typeof data8 == "number" && isFinite(data8)) {
192
+ if (data8 > 1e5 || isNaN(data8)) {
193
+ validate30.errors = [{ instancePath: instancePath + "/width", schemaPath: "#/definitions/key-width/maximum", keyword: "maximum", params: { comparison: "<=", limit: 1e5 }, message: "must be <= 100000" }];
194
+ return false;
195
+ }
196
+ else {
197
+ if (data8 < 0 || isNaN(data8)) {
198
+ validate30.errors = [{ instancePath: instancePath + "/width", schemaPath: "#/definitions/key-width/minimum", keyword: "minimum", params: { comparison: ">=", limit: 0 }, message: "must be >= 0" }];
199
+ return false;
200
+ }
201
+ }
202
+ }
203
+ else {
204
+ validate30.errors = [{ instancePath: instancePath + "/width", schemaPath: "#/definitions/key-width/type", keyword: "type", params: { type: "number" }, message: "must be number" }];
205
+ return false;
206
+ }
207
+ }
208
+ var valid0 = _errs25 === errors;
209
+ }
210
+ else {
211
+ var valid0 = true;
212
+ }
213
+ }
214
+ }
215
+ }
216
+ }
217
+ }
218
+ }
219
+ }
220
+ }
221
+ }
222
+ }
223
+ }
224
+ else {
225
+ validate30.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
226
+ return false;
227
+ }
228
+ }
229
+ validate30.errors = vErrors;
230
+ return errors === 0;
231
+ }
232
+ function validate29(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
233
+ let vErrors = null;
234
+ let errors = 0;
235
+ if (errors === 0) {
236
+ if (Array.isArray(data)) {
237
+ if (data.length < 1) {
238
+ validate29.errors = [{ instancePath, schemaPath: "#/minItems", keyword: "minItems", params: { limit: 1 }, message: "must NOT have fewer than 1 items" }];
239
+ return false;
240
+ }
241
+ else {
242
+ var valid0 = true;
243
+ const len0 = data.length;
244
+ for (let i0 = 0; i0 < len0; i0++) {
245
+ const _errs1 = errors;
246
+ if (!validate30(data[i0], { instancePath: instancePath + "/" + i0, parentData: data, parentDataProperty: i0, rootData })) {
247
+ vErrors = vErrors === null ? validate30.errors : vErrors.concat(validate30.errors);
248
+ errors = vErrors.length;
249
+ }
250
+ var valid0 = _errs1 === errors;
251
+ if (!valid0) {
252
+ break;
253
+ }
254
+ }
255
+ }
256
+ }
257
+ else {
258
+ validate29.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
259
+ return false;
260
+ }
261
+ }
262
+ validate29.errors = vErrors;
263
+ return errors === 0;
264
+ }
265
+ var pattern7 = new RegExp("^(n|s|e|w|ne|nw|se|sw)$", "u");
266
+ function validate33(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
267
+ let vErrors = null;
268
+ let errors = 0;
269
+ if (errors === 0) {
270
+ if (data && typeof data == "object" && !Array.isArray(data)) {
271
+ if (Object.keys(data).length < 1) {
272
+ validate33.errors = [{ instancePath, schemaPath: "#/minProperties", keyword: "minProperties", params: { limit: 1 }, message: "must NOT have fewer than 1 properties" }];
273
+ return false;
274
+ }
275
+ else {
276
+ const _errs1 = errors;
277
+ for (const key0 in data) {
278
+ if (!pattern7.test(key0)) {
279
+ validate33.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
280
+ return false;
281
+ break;
282
+ }
283
+ }
284
+ if (_errs1 === errors) {
285
+ var valid0 = true;
286
+ for (const key1 in data) {
287
+ if (pattern7.test(key1)) {
288
+ const _errs2 = errors;
289
+ if (!validate30(data[key1], { instancePath: instancePath + "/" + key1.replace(/~/g, "~0").replace(/\//g, "~1"), parentData: data, parentDataProperty: key1, rootData })) {
290
+ vErrors = vErrors === null ? validate30.errors : vErrors.concat(validate30.errors);
291
+ errors = vErrors.length;
292
+ }
293
+ var valid0 = _errs2 === errors;
294
+ if (!valid0) {
295
+ break;
296
+ }
297
+ }
298
+ }
299
+ }
300
+ }
301
+ }
302
+ else {
303
+ validate33.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
304
+ return false;
305
+ }
306
+ }
307
+ validate33.errors = vErrors;
308
+ return errors === 0;
309
+ }
310
+ function validate28(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
311
+ let vErrors = null;
312
+ let errors = 0;
313
+ const _errs1 = errors;
314
+ let valid0 = false;
315
+ const _errs2 = errors;
316
+ if (data && typeof data == "object" && !Array.isArray(data)) {
317
+ let missing0;
318
+ if (data.id === void 0 && (missing0 = "id")) {
319
+ const err0 = { instancePath, schemaPath: "#/anyOf/0/required", keyword: "required", params: { missingProperty: missing0 }, message: "must have required property '" + missing0 + "'" };
320
+ if (vErrors === null) {
321
+ vErrors = [err0];
322
+ }
323
+ else {
324
+ vErrors.push(err0);
325
+ }
326
+ errors++;
327
+ }
328
+ }
329
+ var _valid0 = _errs2 === errors;
330
+ valid0 = valid0 || _valid0;
331
+ if (!valid0) {
332
+ const _errs3 = errors;
333
+ if (data && typeof data == "object" && !Array.isArray(data)) {
334
+ let missing1;
335
+ if (data.sp === void 0 && (missing1 = "sp")) {
336
+ const err1 = { instancePath, schemaPath: "#/anyOf/1/required", keyword: "required", params: { missingProperty: missing1 }, message: "must have required property '" + missing1 + "'" };
337
+ if (vErrors === null) {
338
+ vErrors = [err1];
339
+ }
340
+ else {
341
+ vErrors.push(err1);
342
+ }
343
+ errors++;
344
+ }
345
+ }
346
+ var _valid0 = _errs3 === errors;
347
+ valid0 = valid0 || _valid0;
348
+ if (!valid0) {
349
+ const _errs4 = errors;
350
+ if (data && typeof data == "object" && !Array.isArray(data)) {
351
+ let missing2;
352
+ if (data.sk === void 0 && (missing2 = "sk")) {
353
+ const err2 = { instancePath, schemaPath: "#/anyOf/2/required", keyword: "required", params: { missingProperty: missing2 }, message: "must have required property '" + missing2 + "'" };
354
+ if (vErrors === null) {
355
+ vErrors = [err2];
356
+ }
357
+ else {
358
+ vErrors.push(err2);
359
+ }
360
+ errors++;
361
+ }
362
+ }
363
+ var _valid0 = _errs4 === errors;
364
+ valid0 = valid0 || _valid0;
365
+ if (!valid0) {
366
+ const _errs5 = errors;
367
+ if (data && typeof data == "object" && !Array.isArray(data)) {
368
+ let missing3;
369
+ if (data.flick === void 0 && (missing3 = "flick")) {
370
+ const err3 = { instancePath, schemaPath: "#/anyOf/3/required", keyword: "required", params: { missingProperty: missing3 }, message: "must have required property '" + missing3 + "'" };
371
+ if (vErrors === null) {
372
+ vErrors = [err3];
373
+ }
374
+ else {
375
+ vErrors.push(err3);
376
+ }
377
+ errors++;
378
+ }
379
+ }
380
+ var _valid0 = _errs5 === errors;
381
+ valid0 = valid0 || _valid0;
382
+ if (!valid0) {
383
+ const _errs6 = errors;
384
+ if (data && typeof data == "object" && !Array.isArray(data)) {
385
+ let missing4;
386
+ if (data.multitap === void 0 && (missing4 = "multitap")) {
387
+ const err4 = { instancePath, schemaPath: "#/anyOf/4/required", keyword: "required", params: { missingProperty: missing4 }, message: "must have required property '" + missing4 + "'" };
388
+ if (vErrors === null) {
389
+ vErrors = [err4];
390
+ }
391
+ else {
392
+ vErrors.push(err4);
393
+ }
394
+ errors++;
395
+ }
396
+ }
397
+ var _valid0 = _errs6 === errors;
398
+ valid0 = valid0 || _valid0;
399
+ }
400
+ }
401
+ }
402
+ }
403
+ if (!valid0) {
404
+ const err5 = { instancePath, schemaPath: "#/anyOf", keyword: "anyOf", params: {}, message: "must match a schema in anyOf" };
405
+ if (vErrors === null) {
406
+ vErrors = [err5];
407
+ }
408
+ else {
409
+ vErrors.push(err5);
410
+ }
411
+ errors++;
412
+ validate28.errors = vErrors;
413
+ return false;
414
+ }
415
+ else {
416
+ errors = _errs1;
417
+ if (vErrors !== null) {
418
+ if (_errs1) {
419
+ vErrors.length = _errs1;
420
+ }
421
+ else {
422
+ vErrors = null;
423
+ }
424
+ }
425
+ }
426
+ if (errors === 0) {
427
+ if (data && typeof data == "object" && !Array.isArray(data)) {
428
+ const _errs7 = errors;
429
+ for (const key0 in data) {
430
+ if (!func4.call(schema34.properties, key0)) {
431
+ validate28.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
432
+ return false;
433
+ break;
434
+ }
435
+ }
436
+ if (_errs7 === errors) {
437
+ if (data.id !== void 0) {
438
+ let data0 = data.id;
439
+ const _errs8 = errors;
440
+ const _errs9 = errors;
441
+ if (errors === _errs9) {
442
+ if (typeof data0 === "string") {
443
+ if (!pattern1.test(data0)) {
444
+ validate28.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/key-id/pattern", keyword: "pattern", params: { pattern: "^[TKUtku]_[a-zA-Z0-9_]+$" }, message: 'must match pattern "^[TKUtku]_[a-zA-Z0-9_]+$"' }];
445
+ return false;
446
+ }
447
+ }
448
+ else {
449
+ validate28.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/key-id/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
450
+ return false;
451
+ }
452
+ }
453
+ var valid1 = _errs8 === errors;
454
+ }
455
+ else {
456
+ var valid1 = true;
457
+ }
458
+ if (valid1) {
459
+ if (data.text !== void 0) {
460
+ const _errs11 = errors;
461
+ if (typeof data.text !== "string") {
462
+ validate28.errors = [{ instancePath: instancePath + "/text", schemaPath: "#/properties/text/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
463
+ return false;
464
+ }
465
+ var valid1 = _errs11 === errors;
466
+ }
467
+ else {
468
+ var valid1 = true;
469
+ }
470
+ if (valid1) {
471
+ if (data.layer !== void 0) {
472
+ let data2 = data.layer;
473
+ const _errs13 = errors;
474
+ const _errs14 = errors;
475
+ if (errors === _errs14) {
476
+ if (typeof data2 === "string") {
477
+ if (!pattern0.test(data2)) {
478
+ validate28.errors = [{ instancePath: instancePath + "/layer", schemaPath: "#/definitions/layer-id/pattern", keyword: "pattern", params: { pattern: "^[a-zA-Z0-9_-]+$" }, message: 'must match pattern "^[a-zA-Z0-9_-]+$"' }];
479
+ return false;
480
+ }
481
+ }
482
+ else {
483
+ validate28.errors = [{ instancePath: instancePath + "/layer", schemaPath: "#/definitions/layer-id/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
484
+ return false;
485
+ }
486
+ }
487
+ var valid1 = _errs13 === errors;
488
+ }
489
+ else {
490
+ var valid1 = true;
491
+ }
492
+ if (valid1) {
493
+ if (data.nextlayer !== void 0) {
494
+ let data3 = data.nextlayer;
495
+ const _errs16 = errors;
496
+ const _errs17 = errors;
497
+ if (errors === _errs17) {
498
+ if (typeof data3 === "string") {
499
+ if (!pattern0.test(data3)) {
500
+ validate28.errors = [{ instancePath: instancePath + "/nextlayer", schemaPath: "#/definitions/layer-id/pattern", keyword: "pattern", params: { pattern: "^[a-zA-Z0-9_-]+$" }, message: 'must match pattern "^[a-zA-Z0-9_-]+$"' }];
501
+ return false;
502
+ }
503
+ }
504
+ else {
505
+ validate28.errors = [{ instancePath: instancePath + "/nextlayer", schemaPath: "#/definitions/layer-id/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
506
+ return false;
507
+ }
508
+ }
509
+ var valid1 = _errs16 === errors;
510
+ }
511
+ else {
512
+ var valid1 = true;
513
+ }
514
+ if (valid1) {
515
+ if (data.font !== void 0) {
516
+ const _errs19 = errors;
517
+ if (typeof data.font !== "string") {
518
+ validate28.errors = [{ instancePath: instancePath + "/font", schemaPath: "#/definitions/font-spec/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
519
+ return false;
520
+ }
521
+ var valid1 = _errs19 === errors;
522
+ }
523
+ else {
524
+ var valid1 = true;
525
+ }
526
+ if (valid1) {
527
+ if (data.fontsize !== void 0) {
528
+ const _errs22 = errors;
529
+ if (typeof data.fontsize !== "string") {
530
+ validate28.errors = [{ instancePath: instancePath + "/fontsize", schemaPath: "#/definitions/fontsize-spec/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
531
+ return false;
532
+ }
533
+ var valid1 = _errs22 === errors;
534
+ }
535
+ else {
536
+ var valid1 = true;
537
+ }
538
+ if (valid1) {
539
+ if (data.sp !== void 0) {
540
+ let data6 = data.sp;
541
+ const _errs25 = errors;
542
+ if (!(typeof data6 == "number" && (!(data6 % 1) && !isNaN(data6)) && isFinite(data6))) {
543
+ validate28.errors = [{ instancePath: instancePath + "/sp", schemaPath: "#/definitions/key-sp/type", keyword: "type", params: { type: "integer" }, message: "must be integer" }];
544
+ return false;
545
+ }
546
+ if (!(data6 === 0 || data6 === 1 || data6 === 2 || data6 === 8 || data6 === 9 || data6 === 10)) {
547
+ validate28.errors = [{ instancePath: instancePath + "/sp", schemaPath: "#/definitions/key-sp/enum", keyword: "enum", params: { allowedValues: schema40.enum }, message: "must be equal to one of the allowed values" }];
548
+ return false;
549
+ }
550
+ var valid1 = _errs25 === errors;
551
+ }
552
+ else {
553
+ var valid1 = true;
554
+ }
555
+ if (valid1) {
556
+ if (data.pad !== void 0) {
557
+ let data7 = data.pad;
558
+ const _errs28 = errors;
559
+ const _errs29 = errors;
560
+ if (errors === _errs29) {
561
+ if (typeof data7 == "number" && isFinite(data7)) {
562
+ if (data7 > 1e5 || isNaN(data7)) {
563
+ validate28.errors = [{ instancePath: instancePath + "/pad", schemaPath: "#/definitions/key-pad/maximum", keyword: "maximum", params: { comparison: "<=", limit: 1e5 }, message: "must be <= 100000" }];
564
+ return false;
565
+ }
566
+ else {
567
+ if (data7 < 0 || isNaN(data7)) {
568
+ validate28.errors = [{ instancePath: instancePath + "/pad", schemaPath: "#/definitions/key-pad/minimum", keyword: "minimum", params: { comparison: ">=", limit: 0 }, message: "must be >= 0" }];
569
+ return false;
570
+ }
571
+ }
572
+ }
573
+ else {
574
+ validate28.errors = [{ instancePath: instancePath + "/pad", schemaPath: "#/definitions/key-pad/type", keyword: "type", params: { type: "number" }, message: "must be number" }];
575
+ return false;
576
+ }
577
+ }
578
+ var valid1 = _errs28 === errors;
579
+ }
580
+ else {
581
+ var valid1 = true;
582
+ }
583
+ if (valid1) {
584
+ if (data.width !== void 0) {
585
+ let data8 = data.width;
586
+ const _errs31 = errors;
587
+ const _errs32 = errors;
588
+ if (errors === _errs32) {
589
+ if (typeof data8 == "number" && isFinite(data8)) {
590
+ if (data8 > 1e5 || isNaN(data8)) {
591
+ validate28.errors = [{ instancePath: instancePath + "/width", schemaPath: "#/definitions/key-width/maximum", keyword: "maximum", params: { comparison: "<=", limit: 1e5 }, message: "must be <= 100000" }];
592
+ return false;
593
+ }
594
+ else {
595
+ if (data8 < 0 || isNaN(data8)) {
596
+ validate28.errors = [{ instancePath: instancePath + "/width", schemaPath: "#/definitions/key-width/minimum", keyword: "minimum", params: { comparison: ">=", limit: 0 }, message: "must be >= 0" }];
597
+ return false;
598
+ }
599
+ }
600
+ }
601
+ else {
602
+ validate28.errors = [{ instancePath: instancePath + "/width", schemaPath: "#/definitions/key-width/type", keyword: "type", params: { type: "number" }, message: "must be number" }];
603
+ return false;
604
+ }
605
+ }
606
+ var valid1 = _errs31 === errors;
607
+ }
608
+ else {
609
+ var valid1 = true;
610
+ }
611
+ if (valid1) {
612
+ if (data.sk !== void 0) {
613
+ const _errs34 = errors;
614
+ if (!validate29(data.sk, { instancePath: instancePath + "/sk", parentData: data, parentDataProperty: "sk", rootData })) {
615
+ vErrors = vErrors === null ? validate29.errors : vErrors.concat(validate29.errors);
616
+ errors = vErrors.length;
617
+ }
618
+ var valid1 = _errs34 === errors;
619
+ }
620
+ else {
621
+ var valid1 = true;
622
+ }
623
+ if (valid1) {
624
+ if (data.flick !== void 0) {
625
+ const _errs35 = errors;
626
+ if (!validate33(data.flick, { instancePath: instancePath + "/flick", parentData: data, parentDataProperty: "flick", rootData })) {
627
+ vErrors = vErrors === null ? validate33.errors : vErrors.concat(validate33.errors);
628
+ errors = vErrors.length;
629
+ }
630
+ var valid1 = _errs35 === errors;
631
+ }
632
+ else {
633
+ var valid1 = true;
634
+ }
635
+ if (valid1) {
636
+ if (data.multitap !== void 0) {
637
+ const _errs36 = errors;
638
+ if (!validate29(data.multitap, { instancePath: instancePath + "/multitap", parentData: data, parentDataProperty: "multitap", rootData })) {
639
+ vErrors = vErrors === null ? validate29.errors : vErrors.concat(validate29.errors);
640
+ errors = vErrors.length;
641
+ }
642
+ var valid1 = _errs36 === errors;
643
+ }
644
+ else {
645
+ var valid1 = true;
646
+ }
647
+ if (valid1) {
648
+ if (data.hint !== void 0) {
649
+ const _errs37 = errors;
650
+ if (typeof data.hint !== "string") {
651
+ validate28.errors = [{ instancePath: instancePath + "/hint", schemaPath: "#/properties/hint/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
652
+ return false;
653
+ }
654
+ var valid1 = _errs37 === errors;
655
+ }
656
+ else {
657
+ var valid1 = true;
658
+ }
659
+ }
660
+ }
661
+ }
662
+ }
663
+ }
664
+ }
665
+ }
666
+ }
667
+ }
668
+ }
669
+ }
670
+ }
671
+ }
672
+ }
673
+ else {
674
+ validate28.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
675
+ return false;
676
+ }
677
+ }
678
+ validate28.errors = vErrors;
679
+ return errors === 0;
680
+ }
681
+ function validate27(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
682
+ let vErrors = null;
683
+ let errors = 0;
684
+ if (errors === 0) {
685
+ if (Array.isArray(data)) {
686
+ if (data.length < 1) {
687
+ validate27.errors = [{ instancePath, schemaPath: "#/minItems", keyword: "minItems", params: { limit: 1 }, message: "must NOT have fewer than 1 items" }];
688
+ return false;
689
+ }
690
+ else {
691
+ var valid0 = true;
692
+ const len0 = data.length;
693
+ for (let i0 = 0; i0 < len0; i0++) {
694
+ const _errs1 = errors;
695
+ if (!validate28(data[i0], { instancePath: instancePath + "/" + i0, parentData: data, parentDataProperty: i0, rootData })) {
696
+ vErrors = vErrors === null ? validate28.errors : vErrors.concat(validate28.errors);
697
+ errors = vErrors.length;
698
+ }
699
+ var valid0 = _errs1 === errors;
700
+ if (!valid0) {
701
+ break;
702
+ }
703
+ }
704
+ }
705
+ }
706
+ else {
707
+ validate27.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
708
+ return false;
709
+ }
710
+ }
711
+ validate27.errors = vErrors;
712
+ return errors === 0;
713
+ }
714
+ function validate26(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
715
+ let vErrors = null;
716
+ let errors = 0;
717
+ if (errors === 0) {
718
+ if (data && typeof data == "object" && !Array.isArray(data)) {
719
+ let missing0;
720
+ if (data.id === void 0 && (missing0 = "id") || data.key === void 0 && (missing0 = "key")) {
721
+ validate26.errors = [{ instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: missing0 }, message: "must have required property '" + missing0 + "'" }];
722
+ return false;
723
+ }
724
+ else {
725
+ const _errs1 = errors;
726
+ for (const key0 in data) {
727
+ if (!(key0 === "id" || key0 === "key")) {
728
+ validate26.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
729
+ return false;
730
+ break;
731
+ }
732
+ }
733
+ if (_errs1 === errors) {
734
+ if (data.id !== void 0) {
735
+ let data0 = data.id;
736
+ const _errs2 = errors;
737
+ const _errs3 = errors;
738
+ if (!(typeof data0 == "number" && (!(data0 % 1) && !isNaN(data0)) && isFinite(data0))) {
739
+ validate26.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/row-id/type", keyword: "type", params: { type: "integer" }, message: "must be integer" }];
740
+ return false;
741
+ }
742
+ if (errors === _errs3) {
743
+ if (typeof data0 == "number" && isFinite(data0)) {
744
+ if (data0 > 100 || isNaN(data0)) {
745
+ validate26.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/row-id/maximum", keyword: "maximum", params: { comparison: "<=", limit: 100 }, message: "must be <= 100" }];
746
+ return false;
747
+ }
748
+ else {
749
+ if (data0 < 0 || isNaN(data0)) {
750
+ validate26.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/row-id/minimum", keyword: "minimum", params: { comparison: ">=", limit: 0 }, message: "must be >= 0" }];
751
+ return false;
752
+ }
753
+ }
754
+ }
755
+ }
756
+ var valid0 = _errs2 === errors;
757
+ }
758
+ else {
759
+ var valid0 = true;
760
+ }
761
+ if (valid0) {
762
+ if (data.key !== void 0) {
763
+ const _errs5 = errors;
764
+ if (!validate27(data.key, { instancePath: instancePath + "/key", parentData: data, parentDataProperty: "key", rootData })) {
765
+ vErrors = vErrors === null ? validate27.errors : vErrors.concat(validate27.errors);
766
+ errors = vErrors.length;
767
+ }
768
+ var valid0 = _errs5 === errors;
769
+ }
770
+ else {
771
+ var valid0 = true;
772
+ }
773
+ }
774
+ }
775
+ }
776
+ }
777
+ else {
778
+ validate26.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
779
+ return false;
780
+ }
781
+ }
782
+ validate26.errors = vErrors;
783
+ return errors === 0;
784
+ }
785
+ function validate25(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
786
+ let vErrors = null;
787
+ let errors = 0;
788
+ if (errors === 0) {
789
+ if (Array.isArray(data)) {
790
+ if (data.length < 1) {
791
+ validate25.errors = [{ instancePath, schemaPath: "#/minItems", keyword: "minItems", params: { limit: 1 }, message: "must NOT have fewer than 1 items" }];
792
+ return false;
793
+ }
794
+ else {
795
+ var valid0 = true;
796
+ const len0 = data.length;
797
+ for (let i0 = 0; i0 < len0; i0++) {
798
+ const _errs1 = errors;
799
+ if (!validate26(data[i0], { instancePath: instancePath + "/" + i0, parentData: data, parentDataProperty: i0, rootData })) {
800
+ vErrors = vErrors === null ? validate26.errors : vErrors.concat(validate26.errors);
801
+ errors = vErrors.length;
802
+ }
803
+ var valid0 = _errs1 === errors;
804
+ if (!valid0) {
805
+ break;
806
+ }
807
+ }
808
+ }
809
+ }
810
+ else {
811
+ validate25.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
812
+ return false;
813
+ }
814
+ }
815
+ validate25.errors = vErrors;
816
+ return errors === 0;
817
+ }
818
+ function validate24(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
819
+ let vErrors = null;
820
+ let errors = 0;
821
+ if (errors === 0) {
822
+ if (data && typeof data == "object" && !Array.isArray(data)) {
823
+ let missing0;
824
+ if (data.id === void 0 && (missing0 = "id") || data.row === void 0 && (missing0 = "row")) {
825
+ validate24.errors = [{ instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: missing0 }, message: "must have required property '" + missing0 + "'" }];
826
+ return false;
827
+ }
828
+ else {
829
+ const _errs1 = errors;
830
+ for (const key0 in data) {
831
+ if (!(key0 === "id" || key0 === "row")) {
832
+ validate24.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
833
+ return false;
834
+ break;
835
+ }
836
+ }
837
+ if (_errs1 === errors) {
838
+ if (data.id !== void 0) {
839
+ let data0 = data.id;
840
+ const _errs2 = errors;
841
+ const _errs3 = errors;
842
+ if (errors === _errs3) {
843
+ if (typeof data0 === "string") {
844
+ if (!pattern0.test(data0)) {
845
+ validate24.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/layer-id/pattern", keyword: "pattern", params: { pattern: "^[a-zA-Z0-9_-]+$" }, message: 'must match pattern "^[a-zA-Z0-9_-]+$"' }];
846
+ return false;
847
+ }
848
+ }
849
+ else {
850
+ validate24.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/definitions/layer-id/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
851
+ return false;
852
+ }
853
+ }
854
+ var valid0 = _errs2 === errors;
855
+ }
856
+ else {
857
+ var valid0 = true;
858
+ }
859
+ if (valid0) {
860
+ if (data.row !== void 0) {
861
+ const _errs5 = errors;
862
+ if (!validate25(data.row, { instancePath: instancePath + "/row", parentData: data, parentDataProperty: "row", rootData })) {
863
+ vErrors = vErrors === null ? validate25.errors : vErrors.concat(validate25.errors);
864
+ errors = vErrors.length;
865
+ }
866
+ var valid0 = _errs5 === errors;
867
+ }
868
+ else {
869
+ var valid0 = true;
870
+ }
871
+ }
872
+ }
873
+ }
874
+ }
875
+ else {
876
+ validate24.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
877
+ return false;
878
+ }
879
+ }
880
+ validate24.errors = vErrors;
881
+ return errors === 0;
882
+ }
883
+ function validate23(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
884
+ let vErrors = null;
885
+ let errors = 0;
886
+ if (errors === 0) {
887
+ if (Array.isArray(data)) {
888
+ if (data.length < 1) {
889
+ validate23.errors = [{ instancePath, schemaPath: "#/minItems", keyword: "minItems", params: { limit: 1 }, message: "must NOT have fewer than 1 items" }];
890
+ return false;
891
+ }
892
+ else {
893
+ var valid0 = true;
894
+ const len0 = data.length;
895
+ for (let i0 = 0; i0 < len0; i0++) {
896
+ const _errs1 = errors;
897
+ if (!validate24(data[i0], { instancePath: instancePath + "/" + i0, parentData: data, parentDataProperty: i0, rootData })) {
898
+ vErrors = vErrors === null ? validate24.errors : vErrors.concat(validate24.errors);
899
+ errors = vErrors.length;
900
+ }
901
+ var valid0 = _errs1 === errors;
902
+ if (!valid0) {
903
+ break;
904
+ }
905
+ }
906
+ }
907
+ }
908
+ else {
909
+ validate23.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
910
+ return false;
911
+ }
912
+ }
913
+ validate23.errors = vErrors;
914
+ return errors === 0;
915
+ }
916
+ function validate22(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
917
+ let vErrors = null;
918
+ let errors = 0;
919
+ if (errors === 0) {
920
+ if (data && typeof data == "object" && !Array.isArray(data)) {
921
+ let missing0;
922
+ if (data.layer === void 0 && (missing0 = "layer")) {
923
+ validate22.errors = [{ instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: missing0 }, message: "must have required property '" + missing0 + "'" }];
924
+ return false;
925
+ }
926
+ else {
927
+ const _errs1 = errors;
928
+ for (const key0 in data) {
929
+ if (!(key0 === "font" || key0 === "fontsize" || key0 === "layer" || key0 === "displayUnderlying" || key0 === "defaultHint")) {
930
+ validate22.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
931
+ return false;
932
+ break;
933
+ }
934
+ }
935
+ if (_errs1 === errors) {
936
+ if (data.font !== void 0) {
937
+ const _errs2 = errors;
938
+ if (typeof data.font !== "string") {
939
+ validate22.errors = [{ instancePath: instancePath + "/font", schemaPath: "#/definitions/font-spec/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
940
+ return false;
941
+ }
942
+ var valid0 = _errs2 === errors;
943
+ }
944
+ else {
945
+ var valid0 = true;
946
+ }
947
+ if (valid0) {
948
+ if (data.fontsize !== void 0) {
949
+ const _errs5 = errors;
950
+ if (typeof data.fontsize !== "string") {
951
+ validate22.errors = [{ instancePath: instancePath + "/fontsize", schemaPath: "#/definitions/fontsize-spec/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
952
+ return false;
953
+ }
954
+ var valid0 = _errs5 === errors;
955
+ }
956
+ else {
957
+ var valid0 = true;
958
+ }
959
+ if (valid0) {
960
+ if (data.layer !== void 0) {
961
+ const _errs8 = errors;
962
+ if (!validate23(data.layer, { instancePath: instancePath + "/layer", parentData: data, parentDataProperty: "layer", rootData })) {
963
+ vErrors = vErrors === null ? validate23.errors : vErrors.concat(validate23.errors);
964
+ errors = vErrors.length;
965
+ }
966
+ var valid0 = _errs8 === errors;
967
+ }
968
+ else {
969
+ var valid0 = true;
970
+ }
971
+ if (valid0) {
972
+ if (data.displayUnderlying !== void 0) {
973
+ const _errs9 = errors;
974
+ if (typeof data.displayUnderlying !== "boolean") {
975
+ validate22.errors = [{ instancePath: instancePath + "/displayUnderlying", schemaPath: "#/properties/displayUnderlying/type", keyword: "type", params: { type: "boolean" }, message: "must be boolean" }];
976
+ return false;
977
+ }
978
+ var valid0 = _errs9 === errors;
979
+ }
980
+ else {
981
+ var valid0 = true;
982
+ }
983
+ if (valid0) {
984
+ if (data.defaultHint !== void 0) {
985
+ let data4 = data.defaultHint;
986
+ const _errs11 = errors;
987
+ if (typeof data4 !== "string") {
988
+ validate22.errors = [{ instancePath: instancePath + "/defaultHint", schemaPath: "#/properties/defaultHint/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
989
+ return false;
990
+ }
991
+ if (!(data4 === "none" || data4 === "dot" || data4 === "longpress" || data4 === "multitap" || data4 === "flick" || data4 === "flick-n" || data4 === "flick-ne" || data4 === "flick-e" || data4 === "flick-se" || data4 === "flick-s" || data4 === "flick-sw" || data4 === "flick-w" || data4 === "flick-nw")) {
992
+ validate22.errors = [{ instancePath: instancePath + "/defaultHint", schemaPath: "#/properties/defaultHint/enum", keyword: "enum", params: { allowedValues: schema24.properties.defaultHint.enum }, message: "must be equal to one of the allowed values" }];
993
+ return false;
994
+ }
995
+ var valid0 = _errs11 === errors;
996
+ }
997
+ else {
998
+ var valid0 = true;
999
+ }
1000
+ }
1001
+ }
1002
+ }
1003
+ }
1004
+ }
1005
+ }
1006
+ }
1007
+ else {
1008
+ validate22.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
1009
+ return false;
1010
+ }
1011
+ }
1012
+ validate22.errors = vErrors;
1013
+ return errors === 0;
1014
+ }
1015
+ function validate21(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
1016
+ let vErrors = null;
1017
+ let errors = 0;
1018
+ if (errors === 0) {
1019
+ if (data && typeof data == "object" && !Array.isArray(data)) {
1020
+ if (Object.keys(data).length < 1) {
1021
+ validate21.errors = [{ instancePath, schemaPath: "#/minProperties", keyword: "minProperties", params: { limit: 1 }, message: "must NOT have fewer than 1 properties" }];
1022
+ return false;
1023
+ }
1024
+ else {
1025
+ const _errs1 = errors;
1026
+ for (const key0 in data) {
1027
+ if (!(key0 === "tablet" || key0 === "phone" || key0 === "desktop")) {
1028
+ validate21.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
1029
+ return false;
1030
+ break;
1031
+ }
1032
+ }
1033
+ if (_errs1 === errors) {
1034
+ if (data.tablet !== void 0) {
1035
+ const _errs2 = errors;
1036
+ if (!validate22(data.tablet, { instancePath: instancePath + "/tablet", parentData: data, parentDataProperty: "tablet", rootData })) {
1037
+ vErrors = vErrors === null ? validate22.errors : vErrors.concat(validate22.errors);
1038
+ errors = vErrors.length;
1039
+ }
1040
+ var valid0 = _errs2 === errors;
1041
+ }
1042
+ else {
1043
+ var valid0 = true;
1044
+ }
1045
+ if (valid0) {
1046
+ if (data.phone !== void 0) {
1047
+ const _errs3 = errors;
1048
+ if (!validate22(data.phone, { instancePath: instancePath + "/phone", parentData: data, parentDataProperty: "phone", rootData })) {
1049
+ vErrors = vErrors === null ? validate22.errors : vErrors.concat(validate22.errors);
1050
+ errors = vErrors.length;
1051
+ }
1052
+ var valid0 = _errs3 === errors;
1053
+ }
1054
+ else {
1055
+ var valid0 = true;
1056
+ }
1057
+ if (valid0) {
1058
+ if (data.desktop !== void 0) {
1059
+ const _errs4 = errors;
1060
+ if (!validate22(data.desktop, { instancePath: instancePath + "/desktop", parentData: data, parentDataProperty: "desktop", rootData })) {
1061
+ vErrors = vErrors === null ? validate22.errors : vErrors.concat(validate22.errors);
1062
+ errors = vErrors.length;
1063
+ }
1064
+ var valid0 = _errs4 === errors;
1065
+ }
1066
+ else {
1067
+ var valid0 = true;
1068
+ }
1069
+ }
1070
+ }
1071
+ }
1072
+ }
1073
+ }
1074
+ else {
1075
+ validate21.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
1076
+ return false;
1077
+ }
1078
+ }
1079
+ validate21.errors = vErrors;
1080
+ return errors === 0;
1081
+ }
1082
+ function validate20(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
1083
+ let vErrors = null;
1084
+ let errors = 0;
1085
+ if (!validate21(data, { instancePath, parentData, parentDataProperty, rootData })) {
1086
+ vErrors = vErrors === null ? validate21.errors : vErrors.concat(validate21.errors);
1087
+ errors = vErrors.length;
1088
+ }
1089
+ validate20.errors = vErrors;
1090
+ return errors === 0;
1091
+ }
1092
+ }
1093
+ });
1094
+ export default require_keyman_touch_layout_clean_spec_validator();
1095
1095
  //# sourceMappingURL=keyman-touch-layout.clean.spec.validator.mjs.map
1096
- //# debugId=8510fa96-2f2f-524a-9352-4bf15241be06
1096
+ //# debugId=3b0b36e6-39c2-543d-9b0e-24fd344b9af5