@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,1162 +1,1162 @@
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]="25d80a0a-d910-56f5-8fbe-768ce970fcaf")}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
- // ../../../node_modules/ajv-formats/dist/formats.js
8
- var require_formats = __commonJS({
9
- "../../../node_modules/ajv-formats/dist/formats.js"(exports) {
10
- "use strict";
11
- Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.formatNames = exports.fastFormats = exports.fullFormats = void 0;
13
- function fmtDef(validate, compare) {
14
- return { validate, compare };
15
- }
16
- exports.fullFormats = {
17
- date: fmtDef(date, compareDate),
18
- time: fmtDef(time, compareTime),
19
- "date-time": fmtDef(date_time, compareDateTime),
20
- duration: /^P(?!$)((\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?|(\d+W)?)$/,
21
- uri,
22
- "uri-reference": /^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,
23
- "uri-template": /^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,
24
- url: /^(?:https?|ftp):\/\/(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)(?:\.(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)*(?:\.(?:[a-z\u{00a1}-\u{ffff}]{2,})))(?::\d{2,5})?(?:\/[^\s]*)?$/iu,
25
- email: /^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,
26
- hostname: /^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,
27
- ipv4: /^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,
28
- ipv6: /^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))$/i,
29
- regex,
30
- uuid: /^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,
31
- "json-pointer": /^(?:\/(?:[^~/]|~0|~1)*)*$/,
32
- "json-pointer-uri-fragment": /^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,
33
- "relative-json-pointer": /^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/,
34
- byte,
35
- int32: { type: "number", validate: validateInt32 },
36
- int64: { type: "number", validate: validateInt64 },
37
- float: { type: "number", validate: validateNumber },
38
- double: { type: "number", validate: validateNumber },
39
- password: true,
40
- binary: true
41
- };
42
- exports.fastFormats = {
43
- ...exports.fullFormats,
44
- date: fmtDef(/^\d\d\d\d-[0-1]\d-[0-3]\d$/, compareDate),
45
- time: fmtDef(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i, compareTime),
46
- "date-time": fmtDef(/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i, compareDateTime),
47
- uri: /^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,
48
- "uri-reference": /^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,
49
- email: /^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i
50
- };
51
- exports.formatNames = Object.keys(exports.fullFormats);
52
- function isLeapYear(year) {
53
- return year % 4 === 0 && (year % 100 !== 0 || year % 400 === 0);
54
- }
55
- var DATE = /^(\d\d\d\d)-(\d\d)-(\d\d)$/;
56
- var DAYS = [0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];
57
- function date(str) {
58
- const matches = DATE.exec(str);
59
- if (!matches)
60
- return false;
61
- const year = +matches[1];
62
- const month = +matches[2];
63
- const day = +matches[3];
64
- return month >= 1 && month <= 12 && day >= 1 && day <= (month === 2 && isLeapYear(year) ? 29 : DAYS[month]);
65
- }
66
- function compareDate(d1, d2) {
67
- if (!(d1 && d2))
68
- return void 0;
69
- if (d1 > d2)
70
- return 1;
71
- if (d1 < d2)
72
- return -1;
73
- return 0;
74
- }
75
- var TIME = /^(\d\d):(\d\d):(\d\d)(\.\d+)?(z|[+-]\d\d(?::?\d\d)?)?$/i;
76
- function time(str, withTimeZone) {
77
- const matches = TIME.exec(str);
78
- if (!matches)
79
- return false;
80
- const hour = +matches[1];
81
- const minute = +matches[2];
82
- const second = +matches[3];
83
- const timeZone = matches[5];
84
- return (hour <= 23 && minute <= 59 && second <= 59 || hour === 23 && minute === 59 && second === 60) && (!withTimeZone || timeZone !== "");
85
- }
86
- function compareTime(t1, t2) {
87
- if (!(t1 && t2))
88
- return void 0;
89
- const a1 = TIME.exec(t1);
90
- const a2 = TIME.exec(t2);
91
- if (!(a1 && a2))
92
- return void 0;
93
- t1 = a1[1] + a1[2] + a1[3] + (a1[4] || "");
94
- t2 = a2[1] + a2[2] + a2[3] + (a2[4] || "");
95
- if (t1 > t2)
96
- return 1;
97
- if (t1 < t2)
98
- return -1;
99
- return 0;
100
- }
101
- var DATE_TIME_SEPARATOR = /t|\s/i;
102
- function date_time(str) {
103
- const dateTime = str.split(DATE_TIME_SEPARATOR);
104
- return dateTime.length === 2 && date(dateTime[0]) && time(dateTime[1], true);
105
- }
106
- function compareDateTime(dt1, dt2) {
107
- if (!(dt1 && dt2))
108
- return void 0;
109
- const [d1, t1] = dt1.split(DATE_TIME_SEPARATOR);
110
- const [d2, t2] = dt2.split(DATE_TIME_SEPARATOR);
111
- const res = compareDate(d1, d2);
112
- if (res === void 0)
113
- return void 0;
114
- return res || compareTime(t1, t2);
115
- }
116
- var NOT_URI_FRAGMENT = /\/|:/;
117
- var URI = /^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;
118
- function uri(str) {
119
- return NOT_URI_FRAGMENT.test(str) && URI.test(str);
120
- }
121
- var BYTE = /^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;
122
- function byte(str) {
123
- BYTE.lastIndex = 0;
124
- return BYTE.test(str);
125
- }
126
- var MIN_INT32 = -(2 ** 31);
127
- var MAX_INT32 = 2 ** 31 - 1;
128
- function validateInt32(value) {
129
- return Number.isInteger(value) && value <= MAX_INT32 && value >= MIN_INT32;
130
- }
131
- function validateInt64(value) {
132
- return Number.isInteger(value);
133
- }
134
- function validateNumber() {
135
- return true;
136
- }
137
- var Z_ANCHOR = /[^\\]\\Z/;
138
- function regex(str) {
139
- if (Z_ANCHOR.test(str))
140
- return false;
141
- try {
142
- new RegExp(str);
143
- return true;
144
- }
145
- catch (e) {
146
- return false;
147
- }
148
- }
149
- }
150
- });
151
- // obj/schemas/keyboard_info.schema.validator.cjs
152
- var require_keyboard_info_schema_validator = __commonJS({
153
- "obj/schemas/keyboard_info.schema.validator.cjs"(exports, module) {
154
- module.exports = validate20;
155
- module.exports.default = validate20;
156
- var schema23 = { "type": "object", "properties": { "id": { "type": "string" }, "name": { "type": "string" }, "authorName": { "type": "string" }, "authorEmail": { "type": "string", "format": "email" }, "description": { "type": "string" }, "license": { "type": "string", "enum": ["freeware", "shareware", "commercial", "mit", "other"] }, "languages": { "anyOf": [{ "type": "array", "items": { "type": "string" }, "uniqueItems": true }, { "$ref": "#/definitions/KeyboardLanguageInfo" }] }, "lastModifiedDate": { "type": "string", "format": "date-time" }, "packageFilename": { "type": "string", "pattern": "\\.km[xp]$" }, "packageFileSize": { "type": "number" }, "jsFilename": { "type": "string", "pattern": "\\.js$" }, "jsFileSize": { "type": "number" }, "isRTL": { "type": "boolean" }, "encodings": { "type": "array", "items": { "type": "string", "enum": ["ansi", "unicode"] } }, "packageIncludes": { "type": "array", "items": { "type": "string", "enum": ["welcome", "documentation", "fonts", "visualKeyboard"] } }, "version": { "type": "string" }, "minKeymanVersion": { "type": "string", "pattern": "^\\d+\\.\\d$" }, "helpLink": { "type": "string", "pattern": "^https://help\\.keyman\\.com/keyboard/" }, "platformSupport": { "$ref": "#/definitions/KeyboardPlatformInfo" }, "sourcePath": { "type": "string", "pattern": "^(release|legacy|experimental)/.+/.+$" }, "related": { "type": "object", "patternProperties": { ".": { "$ref": "#/definitions/KeyboardRelatedInfo" } }, "additionalProperties": false }, "deprecated": { "type": "boolean" } }, "required": ["id", "name", "license", "languages", "lastModifiedDate", "platformSupport"] };
157
- var schema29 = { "type": "object", "patternProperties": { "^(windows|macos|desktopWeb|ios|android|mobileWeb|linux)$": { "type": "string", "enum": ["dictionary", "full", "basic", "none"] } }, "required": [], "additionalProperties": false };
158
- var formats0 = /^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i;
159
- var formats2 = require_formats().fullFormats["date-time"];
160
- var pattern0 = new RegExp(".", "u");
161
- function validate23(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
162
- let vErrors = null;
163
- let errors = 0;
164
- if (errors === 0) {
165
- if (data && typeof data == "object" && !Array.isArray(data)) {
166
- const _errs1 = errors;
167
- for (const key0 in data) {
168
- if (!(key0 === "font" || key0 === "oskFont" || key0 === "examples" || key0 === "displayName" || key0 === "languageName" || key0 === "scriptName" || key0 === "regionName")) {
169
- validate23.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
170
- return false;
171
- break;
172
- }
173
- }
174
- if (_errs1 === errors) {
175
- if (data.font !== void 0) {
176
- let data0 = data.font;
177
- const _errs2 = errors;
178
- const _errs3 = errors;
179
- if (errors === _errs3) {
180
- if (data0 && typeof data0 == "object" && !Array.isArray(data0)) {
181
- let missing0;
182
- if (data0.family === void 0 && (missing0 = "family") || data0.source === void 0 && (missing0 = "source")) {
183
- validate23.errors = [{ instancePath: instancePath + "/font", schemaPath: "#/definitions/KeyboardFontInfo/required", keyword: "required", params: { missingProperty: missing0 }, message: "must have required property '" + missing0 + "'" }];
184
- return false;
185
- }
186
- else {
187
- const _errs5 = errors;
188
- for (const key1 in data0) {
189
- if (!(key1 === "family" || key1 === "source")) {
190
- validate23.errors = [{ instancePath: instancePath + "/font", schemaPath: "#/definitions/KeyboardFontInfo/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key1 }, message: "must NOT have additional properties" }];
191
- return false;
192
- break;
193
- }
194
- }
195
- if (_errs5 === errors) {
196
- if (data0.family !== void 0) {
197
- const _errs6 = errors;
198
- if (typeof data0.family !== "string") {
199
- validate23.errors = [{ instancePath: instancePath + "/font/family", schemaPath: "#/definitions/KeyboardFontInfo/properties/family/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
200
- return false;
201
- }
202
- var valid2 = _errs6 === errors;
203
- }
204
- else {
205
- var valid2 = true;
206
- }
207
- if (valid2) {
208
- if (data0.source !== void 0) {
209
- let data2 = data0.source;
210
- const _errs8 = errors;
211
- if (errors === _errs8) {
212
- if (Array.isArray(data2)) {
213
- var valid3 = true;
214
- const len0 = data2.length;
215
- for (let i0 = 0; i0 < len0; i0++) {
216
- const _errs10 = errors;
217
- if (typeof data2[i0] !== "string") {
218
- validate23.errors = [{ instancePath: instancePath + "/font/source/" + i0, schemaPath: "#/definitions/KeyboardFontInfo/properties/source/items/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
219
- return false;
220
- }
221
- var valid3 = _errs10 === errors;
222
- if (!valid3) {
223
- break;
224
- }
225
- }
226
- }
227
- else {
228
- validate23.errors = [{ instancePath: instancePath + "/font/source", schemaPath: "#/definitions/KeyboardFontInfo/properties/source/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
229
- return false;
230
- }
231
- }
232
- var valid2 = _errs8 === errors;
233
- }
234
- else {
235
- var valid2 = true;
236
- }
237
- }
238
- }
239
- }
240
- }
241
- else {
242
- validate23.errors = [{ instancePath: instancePath + "/font", schemaPath: "#/definitions/KeyboardFontInfo/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
243
- return false;
244
- }
245
- }
246
- var valid0 = _errs2 === errors;
247
- }
248
- else {
249
- var valid0 = true;
250
- }
251
- if (valid0) {
252
- if (data.oskFont !== void 0) {
253
- let data4 = data.oskFont;
254
- const _errs12 = errors;
255
- const _errs13 = errors;
256
- if (errors === _errs13) {
257
- if (data4 && typeof data4 == "object" && !Array.isArray(data4)) {
258
- let missing1;
259
- if (data4.family === void 0 && (missing1 = "family") || data4.source === void 0 && (missing1 = "source")) {
260
- validate23.errors = [{ instancePath: instancePath + "/oskFont", schemaPath: "#/definitions/KeyboardFontInfo/required", keyword: "required", params: { missingProperty: missing1 }, message: "must have required property '" + missing1 + "'" }];
261
- return false;
262
- }
263
- else {
264
- const _errs15 = errors;
265
- for (const key2 in data4) {
266
- if (!(key2 === "family" || key2 === "source")) {
267
- validate23.errors = [{ instancePath: instancePath + "/oskFont", schemaPath: "#/definitions/KeyboardFontInfo/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key2 }, message: "must NOT have additional properties" }];
268
- return false;
269
- break;
270
- }
271
- }
272
- if (_errs15 === errors) {
273
- if (data4.family !== void 0) {
274
- const _errs16 = errors;
275
- if (typeof data4.family !== "string") {
276
- validate23.errors = [{ instancePath: instancePath + "/oskFont/family", schemaPath: "#/definitions/KeyboardFontInfo/properties/family/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
277
- return false;
278
- }
279
- var valid5 = _errs16 === errors;
280
- }
281
- else {
282
- var valid5 = true;
283
- }
284
- if (valid5) {
285
- if (data4.source !== void 0) {
286
- let data6 = data4.source;
287
- const _errs18 = errors;
288
- if (errors === _errs18) {
289
- if (Array.isArray(data6)) {
290
- var valid6 = true;
291
- const len1 = data6.length;
292
- for (let i1 = 0; i1 < len1; i1++) {
293
- const _errs20 = errors;
294
- if (typeof data6[i1] !== "string") {
295
- validate23.errors = [{ instancePath: instancePath + "/oskFont/source/" + i1, schemaPath: "#/definitions/KeyboardFontInfo/properties/source/items/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
296
- return false;
297
- }
298
- var valid6 = _errs20 === errors;
299
- if (!valid6) {
300
- break;
301
- }
302
- }
303
- }
304
- else {
305
- validate23.errors = [{ instancePath: instancePath + "/oskFont/source", schemaPath: "#/definitions/KeyboardFontInfo/properties/source/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
306
- return false;
307
- }
308
- }
309
- var valid5 = _errs18 === errors;
310
- }
311
- else {
312
- var valid5 = true;
313
- }
314
- }
315
- }
316
- }
317
- }
318
- else {
319
- validate23.errors = [{ instancePath: instancePath + "/oskFont", schemaPath: "#/definitions/KeyboardFontInfo/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
320
- return false;
321
- }
322
- }
323
- var valid0 = _errs12 === errors;
324
- }
325
- else {
326
- var valid0 = true;
327
- }
328
- if (valid0) {
329
- if (data.examples !== void 0) {
330
- let data8 = data.examples;
331
- const _errs22 = errors;
332
- if (errors === _errs22) {
333
- if (Array.isArray(data8)) {
334
- var valid7 = true;
335
- const len2 = data8.length;
336
- for (let i2 = 0; i2 < len2; i2++) {
337
- let data9 = data8[i2];
338
- const _errs24 = errors;
339
- const _errs25 = errors;
340
- if (errors === _errs25) {
341
- if (data9 && typeof data9 == "object" && !Array.isArray(data9)) {
342
- let missing2;
343
- if (data9.keys === void 0 && (missing2 = "keys") || data9.text === void 0 && (missing2 = "text")) {
344
- validate23.errors = [{ instancePath: instancePath + "/examples/" + i2, schemaPath: "#/definitions/KeyboardExampleInfo/required", keyword: "required", params: { missingProperty: missing2 }, message: "must have required property '" + missing2 + "'" }];
345
- return false;
346
- }
347
- else {
348
- const _errs27 = errors;
349
- for (const key3 in data9) {
350
- if (!(key3 === "keys" || key3 === "text" || key3 === "note")) {
351
- validate23.errors = [{ instancePath: instancePath + "/examples/" + i2, schemaPath: "#/definitions/KeyboardExampleInfo/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key3 }, message: "must NOT have additional properties" }];
352
- return false;
353
- break;
354
- }
355
- }
356
- if (_errs27 === errors) {
357
- if (data9.keys !== void 0) {
358
- const _errs28 = errors;
359
- if (typeof data9.keys !== "string") {
360
- validate23.errors = [{ instancePath: instancePath + "/examples/" + i2 + "/keys", schemaPath: "#/definitions/KeyboardExampleInfo/properties/keys/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
361
- return false;
362
- }
363
- var valid9 = _errs28 === errors;
364
- }
365
- else {
366
- var valid9 = true;
367
- }
368
- if (valid9) {
369
- if (data9.text !== void 0) {
370
- const _errs30 = errors;
371
- if (typeof data9.text !== "string") {
372
- validate23.errors = [{ instancePath: instancePath + "/examples/" + i2 + "/text", schemaPath: "#/definitions/KeyboardExampleInfo/properties/text/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
373
- return false;
374
- }
375
- var valid9 = _errs30 === errors;
376
- }
377
- else {
378
- var valid9 = true;
379
- }
380
- if (valid9) {
381
- if (data9.note !== void 0) {
382
- const _errs32 = errors;
383
- if (typeof data9.note !== "string") {
384
- validate23.errors = [{ instancePath: instancePath + "/examples/" + i2 + "/note", schemaPath: "#/definitions/KeyboardExampleInfo/properties/note/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
385
- return false;
386
- }
387
- var valid9 = _errs32 === errors;
388
- }
389
- else {
390
- var valid9 = true;
391
- }
392
- }
393
- }
394
- }
395
- }
396
- }
397
- else {
398
- validate23.errors = [{ instancePath: instancePath + "/examples/" + i2, schemaPath: "#/definitions/KeyboardExampleInfo/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
399
- return false;
400
- }
401
- }
402
- var valid7 = _errs24 === errors;
403
- if (!valid7) {
404
- break;
405
- }
406
- }
407
- }
408
- else {
409
- validate23.errors = [{ instancePath: instancePath + "/examples", schemaPath: "#/properties/examples/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
410
- return false;
411
- }
412
- }
413
- var valid0 = _errs22 === errors;
414
- }
415
- else {
416
- var valid0 = true;
417
- }
418
- if (valid0) {
419
- if (data.displayName !== void 0) {
420
- const _errs34 = errors;
421
- if (typeof data.displayName !== "string") {
422
- validate23.errors = [{ instancePath: instancePath + "/displayName", schemaPath: "#/properties/displayName/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
423
- return false;
424
- }
425
- var valid0 = _errs34 === errors;
426
- }
427
- else {
428
- var valid0 = true;
429
- }
430
- if (valid0) {
431
- if (data.languageName !== void 0) {
432
- const _errs36 = errors;
433
- if (typeof data.languageName !== "string") {
434
- validate23.errors = [{ instancePath: instancePath + "/languageName", schemaPath: "#/properties/languageName/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
435
- return false;
436
- }
437
- var valid0 = _errs36 === errors;
438
- }
439
- else {
440
- var valid0 = true;
441
- }
442
- if (valid0) {
443
- if (data.scriptName !== void 0) {
444
- const _errs38 = errors;
445
- if (typeof data.scriptName !== "string") {
446
- validate23.errors = [{ instancePath: instancePath + "/scriptName", schemaPath: "#/properties/scriptName/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
447
- return false;
448
- }
449
- var valid0 = _errs38 === errors;
450
- }
451
- else {
452
- var valid0 = true;
453
- }
454
- if (valid0) {
455
- if (data.regionName !== void 0) {
456
- const _errs40 = errors;
457
- if (typeof data.regionName !== "string") {
458
- validate23.errors = [{ instancePath: instancePath + "/regionName", schemaPath: "#/properties/regionName/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
459
- return false;
460
- }
461
- var valid0 = _errs40 === errors;
462
- }
463
- else {
464
- var valid0 = true;
465
- }
466
- }
467
- }
468
- }
469
- }
470
- }
471
- }
472
- }
473
- }
474
- else {
475
- validate23.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
476
- return false;
477
- }
478
- }
479
- validate23.errors = vErrors;
480
- return errors === 0;
481
- }
482
- function validate22(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
483
- let vErrors = null;
484
- let errors = 0;
485
- if (errors === 0) {
486
- if (data && typeof data == "object" && !Array.isArray(data)) {
487
- const _errs1 = errors;
488
- for (const key0 in data) {
489
- if (!pattern0.test(key0)) {
490
- validate22.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
491
- return false;
492
- break;
493
- }
494
- }
495
- if (_errs1 === errors) {
496
- var valid0 = true;
497
- for (const key1 in data) {
498
- if (pattern0.test(key1)) {
499
- const _errs2 = errors;
500
- if (!validate23(data[key1], { instancePath: instancePath + "/" + key1.replace(/~/g, "~0").replace(/\//g, "~1"), parentData: data, parentDataProperty: key1, rootData })) {
501
- vErrors = vErrors === null ? validate23.errors : vErrors.concat(validate23.errors);
502
- errors = vErrors.length;
503
- }
504
- var valid0 = _errs2 === errors;
505
- if (!valid0) {
506
- break;
507
- }
508
- }
509
- }
510
- }
511
- }
512
- else {
513
- validate22.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
514
- return false;
515
- }
516
- }
517
- validate22.errors = vErrors;
518
- return errors === 0;
519
- }
520
- var pattern2 = new RegExp("\\.km[xp]$", "u");
521
- var pattern3 = new RegExp("\\.js$", "u");
522
- var pattern4 = new RegExp("^\\d+\\.\\d$", "u");
523
- var pattern5 = new RegExp("^https://help\\.keyman\\.com/keyboard/", "u");
524
- var pattern6 = new RegExp("^(windows|macos|desktopWeb|ios|android|mobileWeb|linux)$", "u");
525
- var pattern8 = new RegExp("^(release|legacy|experimental)/.+/.+$", "u");
526
- function validate21(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
527
- let vErrors = null;
528
- let errors = 0;
529
- if (errors === 0) {
530
- if (data && typeof data == "object" && !Array.isArray(data)) {
531
- let missing0;
532
- if (data.id === void 0 && (missing0 = "id") || data.name === void 0 && (missing0 = "name") || data.license === void 0 && (missing0 = "license") || data.languages === void 0 && (missing0 = "languages") || data.lastModifiedDate === void 0 && (missing0 = "lastModifiedDate") || data.platformSupport === void 0 && (missing0 = "platformSupport")) {
533
- validate21.errors = [{ instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: missing0 }, message: "must have required property '" + missing0 + "'" }];
534
- return false;
535
- }
536
- else {
537
- if (data.id !== void 0) {
538
- const _errs1 = errors;
539
- if (typeof data.id !== "string") {
540
- validate21.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/properties/id/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
541
- return false;
542
- }
543
- var valid0 = _errs1 === errors;
544
- }
545
- else {
546
- var valid0 = true;
547
- }
548
- if (valid0) {
549
- if (data.name !== void 0) {
550
- const _errs3 = errors;
551
- if (typeof data.name !== "string") {
552
- validate21.errors = [{ instancePath: instancePath + "/name", schemaPath: "#/properties/name/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
553
- return false;
554
- }
555
- var valid0 = _errs3 === errors;
556
- }
557
- else {
558
- var valid0 = true;
559
- }
560
- if (valid0) {
561
- if (data.authorName !== void 0) {
562
- const _errs5 = errors;
563
- if (typeof data.authorName !== "string") {
564
- validate21.errors = [{ instancePath: instancePath + "/authorName", schemaPath: "#/properties/authorName/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
565
- return false;
566
- }
567
- var valid0 = _errs5 === errors;
568
- }
569
- else {
570
- var valid0 = true;
571
- }
572
- if (valid0) {
573
- if (data.authorEmail !== void 0) {
574
- let data3 = data.authorEmail;
575
- const _errs7 = errors;
576
- if (errors === _errs7) {
577
- if (errors === _errs7) {
578
- if (typeof data3 === "string") {
579
- if (!formats0.test(data3)) {
580
- validate21.errors = [{ instancePath: instancePath + "/authorEmail", schemaPath: "#/properties/authorEmail/format", keyword: "format", params: { format: "email" }, message: 'must match format "email"' }];
581
- return false;
582
- }
583
- }
584
- else {
585
- validate21.errors = [{ instancePath: instancePath + "/authorEmail", schemaPath: "#/properties/authorEmail/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
586
- return false;
587
- }
588
- }
589
- }
590
- var valid0 = _errs7 === errors;
591
- }
592
- else {
593
- var valid0 = true;
594
- }
595
- if (valid0) {
596
- if (data.description !== void 0) {
597
- const _errs9 = errors;
598
- if (typeof data.description !== "string") {
599
- validate21.errors = [{ instancePath: instancePath + "/description", schemaPath: "#/properties/description/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
600
- return false;
601
- }
602
- var valid0 = _errs9 === errors;
603
- }
604
- else {
605
- var valid0 = true;
606
- }
607
- if (valid0) {
608
- if (data.license !== void 0) {
609
- let data5 = data.license;
610
- const _errs11 = errors;
611
- if (typeof data5 !== "string") {
612
- validate21.errors = [{ instancePath: instancePath + "/license", schemaPath: "#/properties/license/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
613
- return false;
614
- }
615
- if (!(data5 === "freeware" || data5 === "shareware" || data5 === "commercial" || data5 === "mit" || data5 === "other")) {
616
- validate21.errors = [{ instancePath: instancePath + "/license", schemaPath: "#/properties/license/enum", keyword: "enum", params: { allowedValues: schema23.properties.license.enum }, message: "must be equal to one of the allowed values" }];
617
- return false;
618
- }
619
- var valid0 = _errs11 === errors;
620
- }
621
- else {
622
- var valid0 = true;
623
- }
624
- if (valid0) {
625
- if (data.languages !== void 0) {
626
- let data6 = data.languages;
627
- const _errs13 = errors;
628
- const _errs14 = errors;
629
- let valid1 = false;
630
- const _errs15 = errors;
631
- if (errors === _errs15) {
632
- if (Array.isArray(data6)) {
633
- var valid2 = true;
634
- const len0 = data6.length;
635
- for (let i0 = 0; i0 < len0; i0++) {
636
- const _errs17 = errors;
637
- if (typeof data6[i0] !== "string") {
638
- const err0 = { instancePath: instancePath + "/languages/" + i0, schemaPath: "#/properties/languages/anyOf/0/items/type", keyword: "type", params: { type: "string" }, message: "must be string" };
639
- if (vErrors === null) {
640
- vErrors = [err0];
641
- }
642
- else {
643
- vErrors.push(err0);
644
- }
645
- errors++;
646
- }
647
- var valid2 = _errs17 === errors;
648
- if (!valid2) {
649
- break;
650
- }
651
- }
652
- if (valid2) {
653
- let i1 = data6.length;
654
- let j0;
655
- if (i1 > 1) {
656
- const indices0 = {};
657
- for (; i1--;) {
658
- let item0 = data6[i1];
659
- if (typeof item0 !== "string") {
660
- continue;
661
- }
662
- if (typeof indices0[item0] == "number") {
663
- j0 = indices0[item0];
664
- const err1 = { instancePath: instancePath + "/languages", schemaPath: "#/properties/languages/anyOf/0/uniqueItems", keyword: "uniqueItems", params: { i: i1, j: j0 }, message: "must NOT have duplicate items (items ## " + j0 + " and " + i1 + " are identical)" };
665
- if (vErrors === null) {
666
- vErrors = [err1];
667
- }
668
- else {
669
- vErrors.push(err1);
670
- }
671
- errors++;
672
- break;
673
- }
674
- indices0[item0] = i1;
675
- }
676
- }
677
- }
678
- }
679
- else {
680
- const err2 = { instancePath: instancePath + "/languages", schemaPath: "#/properties/languages/anyOf/0/type", keyword: "type", params: { type: "array" }, message: "must be array" };
681
- if (vErrors === null) {
682
- vErrors = [err2];
683
- }
684
- else {
685
- vErrors.push(err2);
686
- }
687
- errors++;
688
- }
689
- }
690
- var _valid0 = _errs15 === errors;
691
- valid1 = valid1 || _valid0;
692
- if (!valid1) {
693
- const _errs19 = errors;
694
- if (!validate22(data6, { instancePath: instancePath + "/languages", parentData: data, parentDataProperty: "languages", rootData })) {
695
- vErrors = vErrors === null ? validate22.errors : vErrors.concat(validate22.errors);
696
- errors = vErrors.length;
697
- }
698
- var _valid0 = _errs19 === errors;
699
- valid1 = valid1 || _valid0;
700
- }
701
- if (!valid1) {
702
- const err3 = { instancePath: instancePath + "/languages", schemaPath: "#/properties/languages/anyOf", keyword: "anyOf", params: {}, message: "must match a schema in anyOf" };
703
- if (vErrors === null) {
704
- vErrors = [err3];
705
- }
706
- else {
707
- vErrors.push(err3);
708
- }
709
- errors++;
710
- validate21.errors = vErrors;
711
- return false;
712
- }
713
- else {
714
- errors = _errs14;
715
- if (vErrors !== null) {
716
- if (_errs14) {
717
- vErrors.length = _errs14;
718
- }
719
- else {
720
- vErrors = null;
721
- }
722
- }
723
- }
724
- var valid0 = _errs13 === errors;
725
- }
726
- else {
727
- var valid0 = true;
728
- }
729
- if (valid0) {
730
- if (data.lastModifiedDate !== void 0) {
731
- let data8 = data.lastModifiedDate;
732
- const _errs20 = errors;
733
- if (errors === _errs20) {
734
- if (errors === _errs20) {
735
- if (typeof data8 === "string") {
736
- if (!formats2.validate(data8)) {
737
- validate21.errors = [{ instancePath: instancePath + "/lastModifiedDate", schemaPath: "#/properties/lastModifiedDate/format", keyword: "format", params: { format: "date-time" }, message: 'must match format "date-time"' }];
738
- return false;
739
- }
740
- }
741
- else {
742
- validate21.errors = [{ instancePath: instancePath + "/lastModifiedDate", schemaPath: "#/properties/lastModifiedDate/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
743
- return false;
744
- }
745
- }
746
- }
747
- var valid0 = _errs20 === errors;
748
- }
749
- else {
750
- var valid0 = true;
751
- }
752
- if (valid0) {
753
- if (data.packageFilename !== void 0) {
754
- let data9 = data.packageFilename;
755
- const _errs22 = errors;
756
- if (errors === _errs22) {
757
- if (typeof data9 === "string") {
758
- if (!pattern2.test(data9)) {
759
- validate21.errors = [{ instancePath: instancePath + "/packageFilename", schemaPath: "#/properties/packageFilename/pattern", keyword: "pattern", params: { pattern: "\\.km[xp]$" }, message: 'must match pattern "\\.km[xp]$"' }];
760
- return false;
761
- }
762
- }
763
- else {
764
- validate21.errors = [{ instancePath: instancePath + "/packageFilename", schemaPath: "#/properties/packageFilename/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
765
- return false;
766
- }
767
- }
768
- var valid0 = _errs22 === errors;
769
- }
770
- else {
771
- var valid0 = true;
772
- }
773
- if (valid0) {
774
- if (data.packageFileSize !== void 0) {
775
- let data10 = data.packageFileSize;
776
- const _errs24 = errors;
777
- if (!(typeof data10 == "number" && isFinite(data10))) {
778
- validate21.errors = [{ instancePath: instancePath + "/packageFileSize", schemaPath: "#/properties/packageFileSize/type", keyword: "type", params: { type: "number" }, message: "must be number" }];
779
- return false;
780
- }
781
- var valid0 = _errs24 === errors;
782
- }
783
- else {
784
- var valid0 = true;
785
- }
786
- if (valid0) {
787
- if (data.jsFilename !== void 0) {
788
- let data11 = data.jsFilename;
789
- const _errs26 = errors;
790
- if (errors === _errs26) {
791
- if (typeof data11 === "string") {
792
- if (!pattern3.test(data11)) {
793
- validate21.errors = [{ instancePath: instancePath + "/jsFilename", schemaPath: "#/properties/jsFilename/pattern", keyword: "pattern", params: { pattern: "\\.js$" }, message: 'must match pattern "\\.js$"' }];
794
- return false;
795
- }
796
- }
797
- else {
798
- validate21.errors = [{ instancePath: instancePath + "/jsFilename", schemaPath: "#/properties/jsFilename/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
799
- return false;
800
- }
801
- }
802
- var valid0 = _errs26 === errors;
803
- }
804
- else {
805
- var valid0 = true;
806
- }
807
- if (valid0) {
808
- if (data.jsFileSize !== void 0) {
809
- let data12 = data.jsFileSize;
810
- const _errs28 = errors;
811
- if (!(typeof data12 == "number" && isFinite(data12))) {
812
- validate21.errors = [{ instancePath: instancePath + "/jsFileSize", schemaPath: "#/properties/jsFileSize/type", keyword: "type", params: { type: "number" }, message: "must be number" }];
813
- return false;
814
- }
815
- var valid0 = _errs28 === errors;
816
- }
817
- else {
818
- var valid0 = true;
819
- }
820
- if (valid0) {
821
- if (data.isRTL !== void 0) {
822
- const _errs30 = errors;
823
- if (typeof data.isRTL !== "boolean") {
824
- validate21.errors = [{ instancePath: instancePath + "/isRTL", schemaPath: "#/properties/isRTL/type", keyword: "type", params: { type: "boolean" }, message: "must be boolean" }];
825
- return false;
826
- }
827
- var valid0 = _errs30 === errors;
828
- }
829
- else {
830
- var valid0 = true;
831
- }
832
- if (valid0) {
833
- if (data.encodings !== void 0) {
834
- let data14 = data.encodings;
835
- const _errs32 = errors;
836
- if (errors === _errs32) {
837
- if (Array.isArray(data14)) {
838
- var valid4 = true;
839
- const len1 = data14.length;
840
- for (let i2 = 0; i2 < len1; i2++) {
841
- let data15 = data14[i2];
842
- const _errs34 = errors;
843
- if (typeof data15 !== "string") {
844
- validate21.errors = [{ instancePath: instancePath + "/encodings/" + i2, schemaPath: "#/properties/encodings/items/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
845
- return false;
846
- }
847
- if (!(data15 === "ansi" || data15 === "unicode")) {
848
- validate21.errors = [{ instancePath: instancePath + "/encodings/" + i2, schemaPath: "#/properties/encodings/items/enum", keyword: "enum", params: { allowedValues: schema23.properties.encodings.items.enum }, message: "must be equal to one of the allowed values" }];
849
- return false;
850
- }
851
- var valid4 = _errs34 === errors;
852
- if (!valid4) {
853
- break;
854
- }
855
- }
856
- }
857
- else {
858
- validate21.errors = [{ instancePath: instancePath + "/encodings", schemaPath: "#/properties/encodings/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
859
- return false;
860
- }
861
- }
862
- var valid0 = _errs32 === errors;
863
- }
864
- else {
865
- var valid0 = true;
866
- }
867
- if (valid0) {
868
- if (data.packageIncludes !== void 0) {
869
- let data16 = data.packageIncludes;
870
- const _errs36 = errors;
871
- if (errors === _errs36) {
872
- if (Array.isArray(data16)) {
873
- var valid5 = true;
874
- const len2 = data16.length;
875
- for (let i3 = 0; i3 < len2; i3++) {
876
- let data17 = data16[i3];
877
- const _errs38 = errors;
878
- if (typeof data17 !== "string") {
879
- validate21.errors = [{ instancePath: instancePath + "/packageIncludes/" + i3, schemaPath: "#/properties/packageIncludes/items/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
880
- return false;
881
- }
882
- if (!(data17 === "welcome" || data17 === "documentation" || data17 === "fonts" || data17 === "visualKeyboard")) {
883
- validate21.errors = [{ instancePath: instancePath + "/packageIncludes/" + i3, schemaPath: "#/properties/packageIncludes/items/enum", keyword: "enum", params: { allowedValues: schema23.properties.packageIncludes.items.enum }, message: "must be equal to one of the allowed values" }];
884
- return false;
885
- }
886
- var valid5 = _errs38 === errors;
887
- if (!valid5) {
888
- break;
889
- }
890
- }
891
- }
892
- else {
893
- validate21.errors = [{ instancePath: instancePath + "/packageIncludes", schemaPath: "#/properties/packageIncludes/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
894
- return false;
895
- }
896
- }
897
- var valid0 = _errs36 === errors;
898
- }
899
- else {
900
- var valid0 = true;
901
- }
902
- if (valid0) {
903
- if (data.version !== void 0) {
904
- const _errs40 = errors;
905
- if (typeof data.version !== "string") {
906
- validate21.errors = [{ instancePath: instancePath + "/version", schemaPath: "#/properties/version/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
907
- return false;
908
- }
909
- var valid0 = _errs40 === errors;
910
- }
911
- else {
912
- var valid0 = true;
913
- }
914
- if (valid0) {
915
- if (data.minKeymanVersion !== void 0) {
916
- let data19 = data.minKeymanVersion;
917
- const _errs42 = errors;
918
- if (errors === _errs42) {
919
- if (typeof data19 === "string") {
920
- if (!pattern4.test(data19)) {
921
- validate21.errors = [{ instancePath: instancePath + "/minKeymanVersion", schemaPath: "#/properties/minKeymanVersion/pattern", keyword: "pattern", params: { pattern: "^\\d+\\.\\d$" }, message: 'must match pattern "^\\d+\\.\\d$"' }];
922
- return false;
923
- }
924
- }
925
- else {
926
- validate21.errors = [{ instancePath: instancePath + "/minKeymanVersion", schemaPath: "#/properties/minKeymanVersion/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
927
- return false;
928
- }
929
- }
930
- var valid0 = _errs42 === errors;
931
- }
932
- else {
933
- var valid0 = true;
934
- }
935
- if (valid0) {
936
- if (data.helpLink !== void 0) {
937
- let data20 = data.helpLink;
938
- const _errs44 = errors;
939
- if (errors === _errs44) {
940
- if (typeof data20 === "string") {
941
- if (!pattern5.test(data20)) {
942
- validate21.errors = [{ instancePath: instancePath + "/helpLink", schemaPath: "#/properties/helpLink/pattern", keyword: "pattern", params: { pattern: "^https://help\\.keyman\\.com/keyboard/" }, message: 'must match pattern "^https://help\\.keyman\\.com/keyboard/"' }];
943
- return false;
944
- }
945
- }
946
- else {
947
- validate21.errors = [{ instancePath: instancePath + "/helpLink", schemaPath: "#/properties/helpLink/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
948
- return false;
949
- }
950
- }
951
- var valid0 = _errs44 === errors;
952
- }
953
- else {
954
- var valid0 = true;
955
- }
956
- if (valid0) {
957
- if (data.platformSupport !== void 0) {
958
- let data21 = data.platformSupport;
959
- const _errs46 = errors;
960
- const _errs47 = errors;
961
- if (errors === _errs47) {
962
- if (data21 && typeof data21 == "object" && !Array.isArray(data21)) {
963
- const _errs49 = errors;
964
- for (const key0 in data21) {
965
- if (!pattern6.test(key0)) {
966
- validate21.errors = [{ instancePath: instancePath + "/platformSupport", schemaPath: "#/definitions/KeyboardPlatformInfo/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
967
- return false;
968
- break;
969
- }
970
- }
971
- if (_errs49 === errors) {
972
- var valid7 = true;
973
- for (const key1 in data21) {
974
- if (pattern6.test(key1)) {
975
- let data22 = data21[key1];
976
- const _errs50 = errors;
977
- if (typeof data22 !== "string") {
978
- validate21.errors = [{ instancePath: instancePath + "/platformSupport/" + key1.replace(/~/g, "~0").replace(/\//g, "~1"), schemaPath: "#/definitions/KeyboardPlatformInfo/patternProperties/%5E(windows%7Cmacos%7CdesktopWeb%7Cios%7Candroid%7CmobileWeb%7Clinux)%24/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
979
- return false;
980
- }
981
- if (!(data22 === "dictionary" || data22 === "full" || data22 === "basic" || data22 === "none")) {
982
- validate21.errors = [{ instancePath: instancePath + "/platformSupport/" + key1.replace(/~/g, "~0").replace(/\//g, "~1"), schemaPath: "#/definitions/KeyboardPlatformInfo/patternProperties/%5E(windows%7Cmacos%7CdesktopWeb%7Cios%7Candroid%7CmobileWeb%7Clinux)%24/enum", keyword: "enum", params: { allowedValues: schema29.patternProperties["^(windows|macos|desktopWeb|ios|android|mobileWeb|linux)$"].enum }, message: "must be equal to one of the allowed values" }];
983
- return false;
984
- }
985
- var valid7 = _errs50 === errors;
986
- if (!valid7) {
987
- break;
988
- }
989
- }
990
- }
991
- }
992
- }
993
- else {
994
- validate21.errors = [{ instancePath: instancePath + "/platformSupport", schemaPath: "#/definitions/KeyboardPlatformInfo/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
995
- return false;
996
- }
997
- }
998
- var valid0 = _errs46 === errors;
999
- }
1000
- else {
1001
- var valid0 = true;
1002
- }
1003
- if (valid0) {
1004
- if (data.sourcePath !== void 0) {
1005
- let data23 = data.sourcePath;
1006
- const _errs52 = errors;
1007
- if (errors === _errs52) {
1008
- if (typeof data23 === "string") {
1009
- if (!pattern8.test(data23)) {
1010
- validate21.errors = [{ instancePath: instancePath + "/sourcePath", schemaPath: "#/properties/sourcePath/pattern", keyword: "pattern", params: { pattern: "^(release|legacy|experimental)/.+/.+$" }, message: 'must match pattern "^(release|legacy|experimental)/.+/.+$"' }];
1011
- return false;
1012
- }
1013
- }
1014
- else {
1015
- validate21.errors = [{ instancePath: instancePath + "/sourcePath", schemaPath: "#/properties/sourcePath/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
1016
- return false;
1017
- }
1018
- }
1019
- var valid0 = _errs52 === errors;
1020
- }
1021
- else {
1022
- var valid0 = true;
1023
- }
1024
- if (valid0) {
1025
- if (data.related !== void 0) {
1026
- let data24 = data.related;
1027
- const _errs54 = errors;
1028
- if (errors === _errs54) {
1029
- if (data24 && typeof data24 == "object" && !Array.isArray(data24)) {
1030
- const _errs56 = errors;
1031
- for (const key2 in data24) {
1032
- if (!pattern0.test(key2)) {
1033
- validate21.errors = [{ instancePath: instancePath + "/related", schemaPath: "#/properties/related/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key2 }, message: "must NOT have additional properties" }];
1034
- return false;
1035
- break;
1036
- }
1037
- }
1038
- if (_errs56 === errors) {
1039
- var valid8 = true;
1040
- for (const key3 in data24) {
1041
- if (pattern0.test(key3)) {
1042
- let data25 = data24[key3];
1043
- const _errs57 = errors;
1044
- const _errs58 = errors;
1045
- if (errors === _errs58) {
1046
- if (data25 && typeof data25 == "object" && !Array.isArray(data25)) {
1047
- const _errs60 = errors;
1048
- for (const key4 in data25) {
1049
- if (!(key4 === "deprecates" || key4 === "deprecatedBy")) {
1050
- validate21.errors = [{ instancePath: instancePath + "/related/" + key3.replace(/~/g, "~0").replace(/\//g, "~1"), schemaPath: "#/definitions/KeyboardRelatedInfo/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key4 }, message: "must NOT have additional properties" }];
1051
- return false;
1052
- break;
1053
- }
1054
- }
1055
- if (_errs60 === errors) {
1056
- if (data25.deprecates !== void 0) {
1057
- const _errs61 = errors;
1058
- if (typeof data25.deprecates !== "boolean") {
1059
- validate21.errors = [{ instancePath: instancePath + "/related/" + key3.replace(/~/g, "~0").replace(/\//g, "~1") + "/deprecates", schemaPath: "#/definitions/KeyboardRelatedInfo/properties/deprecates/type", keyword: "type", params: { type: "boolean" }, message: "must be boolean" }];
1060
- return false;
1061
- }
1062
- var valid10 = _errs61 === errors;
1063
- }
1064
- else {
1065
- var valid10 = true;
1066
- }
1067
- if (valid10) {
1068
- if (data25.deprecatedBy !== void 0) {
1069
- const _errs63 = errors;
1070
- if (typeof data25.deprecatedBy !== "boolean") {
1071
- validate21.errors = [{ instancePath: instancePath + "/related/" + key3.replace(/~/g, "~0").replace(/\//g, "~1") + "/deprecatedBy", schemaPath: "#/definitions/KeyboardRelatedInfo/properties/deprecatedBy/type", keyword: "type", params: { type: "boolean" }, message: "must be boolean" }];
1072
- return false;
1073
- }
1074
- var valid10 = _errs63 === errors;
1075
- }
1076
- else {
1077
- var valid10 = true;
1078
- }
1079
- }
1080
- }
1081
- }
1082
- else {
1083
- validate21.errors = [{ instancePath: instancePath + "/related/" + key3.replace(/~/g, "~0").replace(/\//g, "~1"), schemaPath: "#/definitions/KeyboardRelatedInfo/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
1084
- return false;
1085
- }
1086
- }
1087
- var valid8 = _errs57 === errors;
1088
- if (!valid8) {
1089
- break;
1090
- }
1091
- }
1092
- }
1093
- }
1094
- }
1095
- else {
1096
- validate21.errors = [{ instancePath: instancePath + "/related", schemaPath: "#/properties/related/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
1097
- return false;
1098
- }
1099
- }
1100
- var valid0 = _errs54 === errors;
1101
- }
1102
- else {
1103
- var valid0 = true;
1104
- }
1105
- if (valid0) {
1106
- if (data.deprecated !== void 0) {
1107
- const _errs65 = errors;
1108
- if (typeof data.deprecated !== "boolean") {
1109
- validate21.errors = [{ instancePath: instancePath + "/deprecated", schemaPath: "#/properties/deprecated/type", keyword: "type", params: { type: "boolean" }, message: "must be boolean" }];
1110
- return false;
1111
- }
1112
- var valid0 = _errs65 === errors;
1113
- }
1114
- else {
1115
- var valid0 = true;
1116
- }
1117
- }
1118
- }
1119
- }
1120
- }
1121
- }
1122
- }
1123
- }
1124
- }
1125
- }
1126
- }
1127
- }
1128
- }
1129
- }
1130
- }
1131
- }
1132
- }
1133
- }
1134
- }
1135
- }
1136
- }
1137
- }
1138
- }
1139
- }
1140
- else {
1141
- validate21.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
1142
- return false;
1143
- }
1144
- }
1145
- validate21.errors = vErrors;
1146
- return errors === 0;
1147
- }
1148
- function validate20(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
1149
- let vErrors = null;
1150
- let errors = 0;
1151
- if (!validate21(data, { instancePath, parentData, parentDataProperty, rootData })) {
1152
- vErrors = vErrors === null ? validate21.errors : vErrors.concat(validate21.errors);
1153
- errors = vErrors.length;
1154
- }
1155
- validate20.errors = vErrors;
1156
- return errors === 0;
1157
- }
1158
- }
1159
- });
1160
- export default require_keyboard_info_schema_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]="fc87f4de-21b0-5624-ab1c-b4b7dbf24c10")}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
+ // ../../../node_modules/ajv-formats/dist/formats.js
8
+ var require_formats = __commonJS({
9
+ "../../../node_modules/ajv-formats/dist/formats.js"(exports) {
10
+ "use strict";
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.formatNames = exports.fastFormats = exports.fullFormats = void 0;
13
+ function fmtDef(validate, compare) {
14
+ return { validate, compare };
15
+ }
16
+ exports.fullFormats = {
17
+ date: fmtDef(date, compareDate),
18
+ time: fmtDef(time, compareTime),
19
+ "date-time": fmtDef(date_time, compareDateTime),
20
+ duration: /^P(?!$)((\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?|(\d+W)?)$/,
21
+ uri,
22
+ "uri-reference": /^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,
23
+ "uri-template": /^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,
24
+ url: /^(?:https?|ftp):\/\/(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)(?:\.(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)*(?:\.(?:[a-z\u{00a1}-\u{ffff}]{2,})))(?::\d{2,5})?(?:\/[^\s]*)?$/iu,
25
+ email: /^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,
26
+ hostname: /^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,
27
+ ipv4: /^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,
28
+ ipv6: /^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))$/i,
29
+ regex,
30
+ uuid: /^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,
31
+ "json-pointer": /^(?:\/(?:[^~/]|~0|~1)*)*$/,
32
+ "json-pointer-uri-fragment": /^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,
33
+ "relative-json-pointer": /^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/,
34
+ byte,
35
+ int32: { type: "number", validate: validateInt32 },
36
+ int64: { type: "number", validate: validateInt64 },
37
+ float: { type: "number", validate: validateNumber },
38
+ double: { type: "number", validate: validateNumber },
39
+ password: true,
40
+ binary: true
41
+ };
42
+ exports.fastFormats = {
43
+ ...exports.fullFormats,
44
+ date: fmtDef(/^\d\d\d\d-[0-1]\d-[0-3]\d$/, compareDate),
45
+ time: fmtDef(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i, compareTime),
46
+ "date-time": fmtDef(/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i, compareDateTime),
47
+ uri: /^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,
48
+ "uri-reference": /^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,
49
+ email: /^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i
50
+ };
51
+ exports.formatNames = Object.keys(exports.fullFormats);
52
+ function isLeapYear(year) {
53
+ return year % 4 === 0 && (year % 100 !== 0 || year % 400 === 0);
54
+ }
55
+ var DATE = /^(\d\d\d\d)-(\d\d)-(\d\d)$/;
56
+ var DAYS = [0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];
57
+ function date(str) {
58
+ const matches = DATE.exec(str);
59
+ if (!matches)
60
+ return false;
61
+ const year = +matches[1];
62
+ const month = +matches[2];
63
+ const day = +matches[3];
64
+ return month >= 1 && month <= 12 && day >= 1 && day <= (month === 2 && isLeapYear(year) ? 29 : DAYS[month]);
65
+ }
66
+ function compareDate(d1, d2) {
67
+ if (!(d1 && d2))
68
+ return void 0;
69
+ if (d1 > d2)
70
+ return 1;
71
+ if (d1 < d2)
72
+ return -1;
73
+ return 0;
74
+ }
75
+ var TIME = /^(\d\d):(\d\d):(\d\d)(\.\d+)?(z|[+-]\d\d(?::?\d\d)?)?$/i;
76
+ function time(str, withTimeZone) {
77
+ const matches = TIME.exec(str);
78
+ if (!matches)
79
+ return false;
80
+ const hour = +matches[1];
81
+ const minute = +matches[2];
82
+ const second = +matches[3];
83
+ const timeZone = matches[5];
84
+ return (hour <= 23 && minute <= 59 && second <= 59 || hour === 23 && minute === 59 && second === 60) && (!withTimeZone || timeZone !== "");
85
+ }
86
+ function compareTime(t1, t2) {
87
+ if (!(t1 && t2))
88
+ return void 0;
89
+ const a1 = TIME.exec(t1);
90
+ const a2 = TIME.exec(t2);
91
+ if (!(a1 && a2))
92
+ return void 0;
93
+ t1 = a1[1] + a1[2] + a1[3] + (a1[4] || "");
94
+ t2 = a2[1] + a2[2] + a2[3] + (a2[4] || "");
95
+ if (t1 > t2)
96
+ return 1;
97
+ if (t1 < t2)
98
+ return -1;
99
+ return 0;
100
+ }
101
+ var DATE_TIME_SEPARATOR = /t|\s/i;
102
+ function date_time(str) {
103
+ const dateTime = str.split(DATE_TIME_SEPARATOR);
104
+ return dateTime.length === 2 && date(dateTime[0]) && time(dateTime[1], true);
105
+ }
106
+ function compareDateTime(dt1, dt2) {
107
+ if (!(dt1 && dt2))
108
+ return void 0;
109
+ const [d1, t1] = dt1.split(DATE_TIME_SEPARATOR);
110
+ const [d2, t2] = dt2.split(DATE_TIME_SEPARATOR);
111
+ const res = compareDate(d1, d2);
112
+ if (res === void 0)
113
+ return void 0;
114
+ return res || compareTime(t1, t2);
115
+ }
116
+ var NOT_URI_FRAGMENT = /\/|:/;
117
+ var URI = /^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;
118
+ function uri(str) {
119
+ return NOT_URI_FRAGMENT.test(str) && URI.test(str);
120
+ }
121
+ var BYTE = /^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;
122
+ function byte(str) {
123
+ BYTE.lastIndex = 0;
124
+ return BYTE.test(str);
125
+ }
126
+ var MIN_INT32 = -(2 ** 31);
127
+ var MAX_INT32 = 2 ** 31 - 1;
128
+ function validateInt32(value) {
129
+ return Number.isInteger(value) && value <= MAX_INT32 && value >= MIN_INT32;
130
+ }
131
+ function validateInt64(value) {
132
+ return Number.isInteger(value);
133
+ }
134
+ function validateNumber() {
135
+ return true;
136
+ }
137
+ var Z_ANCHOR = /[^\\]\\Z/;
138
+ function regex(str) {
139
+ if (Z_ANCHOR.test(str))
140
+ return false;
141
+ try {
142
+ new RegExp(str);
143
+ return true;
144
+ }
145
+ catch (e) {
146
+ return false;
147
+ }
148
+ }
149
+ }
150
+ });
151
+ // obj/schemas/keyboard_info.schema.validator.cjs
152
+ var require_keyboard_info_schema_validator = __commonJS({
153
+ "obj/schemas/keyboard_info.schema.validator.cjs"(exports, module) {
154
+ module.exports = validate20;
155
+ module.exports.default = validate20;
156
+ var schema23 = { "type": "object", "properties": { "id": { "type": "string" }, "name": { "type": "string" }, "authorName": { "type": "string" }, "authorEmail": { "type": "string", "format": "email" }, "description": { "type": "string" }, "license": { "type": "string", "enum": ["freeware", "shareware", "commercial", "mit", "other"] }, "languages": { "anyOf": [{ "type": "array", "items": { "type": "string" }, "uniqueItems": true }, { "$ref": "#/definitions/KeyboardLanguageInfo" }] }, "lastModifiedDate": { "type": "string", "format": "date-time" }, "packageFilename": { "type": "string", "pattern": "\\.km[xp]$" }, "packageFileSize": { "type": "number" }, "jsFilename": { "type": "string", "pattern": "\\.js$" }, "jsFileSize": { "type": "number" }, "isRTL": { "type": "boolean" }, "encodings": { "type": "array", "items": { "type": "string", "enum": ["ansi", "unicode"] } }, "packageIncludes": { "type": "array", "items": { "type": "string", "enum": ["welcome", "documentation", "fonts", "visualKeyboard"] } }, "version": { "type": "string" }, "minKeymanVersion": { "type": "string", "pattern": "^\\d+\\.\\d$" }, "helpLink": { "type": "string", "pattern": "^https://help\\.keyman\\.com/keyboard/" }, "platformSupport": { "$ref": "#/definitions/KeyboardPlatformInfo" }, "sourcePath": { "type": "string", "pattern": "^(release|legacy|experimental)/.+/.+$" }, "related": { "type": "object", "patternProperties": { ".": { "$ref": "#/definitions/KeyboardRelatedInfo" } }, "additionalProperties": false }, "deprecated": { "type": "boolean" } }, "required": ["id", "name", "license", "languages", "lastModifiedDate", "platformSupport"] };
157
+ var schema29 = { "type": "object", "patternProperties": { "^(windows|macos|desktopWeb|ios|android|mobileWeb|linux)$": { "type": "string", "enum": ["dictionary", "full", "basic", "none"] } }, "required": [], "additionalProperties": false };
158
+ var formats0 = /^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i;
159
+ var formats2 = require_formats().fullFormats["date-time"];
160
+ var pattern0 = new RegExp(".", "u");
161
+ function validate23(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
162
+ let vErrors = null;
163
+ let errors = 0;
164
+ if (errors === 0) {
165
+ if (data && typeof data == "object" && !Array.isArray(data)) {
166
+ const _errs1 = errors;
167
+ for (const key0 in data) {
168
+ if (!(key0 === "font" || key0 === "oskFont" || key0 === "examples" || key0 === "displayName" || key0 === "languageName" || key0 === "scriptName" || key0 === "regionName")) {
169
+ validate23.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
170
+ return false;
171
+ break;
172
+ }
173
+ }
174
+ if (_errs1 === errors) {
175
+ if (data.font !== void 0) {
176
+ let data0 = data.font;
177
+ const _errs2 = errors;
178
+ const _errs3 = errors;
179
+ if (errors === _errs3) {
180
+ if (data0 && typeof data0 == "object" && !Array.isArray(data0)) {
181
+ let missing0;
182
+ if (data0.family === void 0 && (missing0 = "family") || data0.source === void 0 && (missing0 = "source")) {
183
+ validate23.errors = [{ instancePath: instancePath + "/font", schemaPath: "#/definitions/KeyboardFontInfo/required", keyword: "required", params: { missingProperty: missing0 }, message: "must have required property '" + missing0 + "'" }];
184
+ return false;
185
+ }
186
+ else {
187
+ const _errs5 = errors;
188
+ for (const key1 in data0) {
189
+ if (!(key1 === "family" || key1 === "source")) {
190
+ validate23.errors = [{ instancePath: instancePath + "/font", schemaPath: "#/definitions/KeyboardFontInfo/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key1 }, message: "must NOT have additional properties" }];
191
+ return false;
192
+ break;
193
+ }
194
+ }
195
+ if (_errs5 === errors) {
196
+ if (data0.family !== void 0) {
197
+ const _errs6 = errors;
198
+ if (typeof data0.family !== "string") {
199
+ validate23.errors = [{ instancePath: instancePath + "/font/family", schemaPath: "#/definitions/KeyboardFontInfo/properties/family/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
200
+ return false;
201
+ }
202
+ var valid2 = _errs6 === errors;
203
+ }
204
+ else {
205
+ var valid2 = true;
206
+ }
207
+ if (valid2) {
208
+ if (data0.source !== void 0) {
209
+ let data2 = data0.source;
210
+ const _errs8 = errors;
211
+ if (errors === _errs8) {
212
+ if (Array.isArray(data2)) {
213
+ var valid3 = true;
214
+ const len0 = data2.length;
215
+ for (let i0 = 0; i0 < len0; i0++) {
216
+ const _errs10 = errors;
217
+ if (typeof data2[i0] !== "string") {
218
+ validate23.errors = [{ instancePath: instancePath + "/font/source/" + i0, schemaPath: "#/definitions/KeyboardFontInfo/properties/source/items/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
219
+ return false;
220
+ }
221
+ var valid3 = _errs10 === errors;
222
+ if (!valid3) {
223
+ break;
224
+ }
225
+ }
226
+ }
227
+ else {
228
+ validate23.errors = [{ instancePath: instancePath + "/font/source", schemaPath: "#/definitions/KeyboardFontInfo/properties/source/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
229
+ return false;
230
+ }
231
+ }
232
+ var valid2 = _errs8 === errors;
233
+ }
234
+ else {
235
+ var valid2 = true;
236
+ }
237
+ }
238
+ }
239
+ }
240
+ }
241
+ else {
242
+ validate23.errors = [{ instancePath: instancePath + "/font", schemaPath: "#/definitions/KeyboardFontInfo/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
243
+ return false;
244
+ }
245
+ }
246
+ var valid0 = _errs2 === errors;
247
+ }
248
+ else {
249
+ var valid0 = true;
250
+ }
251
+ if (valid0) {
252
+ if (data.oskFont !== void 0) {
253
+ let data4 = data.oskFont;
254
+ const _errs12 = errors;
255
+ const _errs13 = errors;
256
+ if (errors === _errs13) {
257
+ if (data4 && typeof data4 == "object" && !Array.isArray(data4)) {
258
+ let missing1;
259
+ if (data4.family === void 0 && (missing1 = "family") || data4.source === void 0 && (missing1 = "source")) {
260
+ validate23.errors = [{ instancePath: instancePath + "/oskFont", schemaPath: "#/definitions/KeyboardFontInfo/required", keyword: "required", params: { missingProperty: missing1 }, message: "must have required property '" + missing1 + "'" }];
261
+ return false;
262
+ }
263
+ else {
264
+ const _errs15 = errors;
265
+ for (const key2 in data4) {
266
+ if (!(key2 === "family" || key2 === "source")) {
267
+ validate23.errors = [{ instancePath: instancePath + "/oskFont", schemaPath: "#/definitions/KeyboardFontInfo/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key2 }, message: "must NOT have additional properties" }];
268
+ return false;
269
+ break;
270
+ }
271
+ }
272
+ if (_errs15 === errors) {
273
+ if (data4.family !== void 0) {
274
+ const _errs16 = errors;
275
+ if (typeof data4.family !== "string") {
276
+ validate23.errors = [{ instancePath: instancePath + "/oskFont/family", schemaPath: "#/definitions/KeyboardFontInfo/properties/family/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
277
+ return false;
278
+ }
279
+ var valid5 = _errs16 === errors;
280
+ }
281
+ else {
282
+ var valid5 = true;
283
+ }
284
+ if (valid5) {
285
+ if (data4.source !== void 0) {
286
+ let data6 = data4.source;
287
+ const _errs18 = errors;
288
+ if (errors === _errs18) {
289
+ if (Array.isArray(data6)) {
290
+ var valid6 = true;
291
+ const len1 = data6.length;
292
+ for (let i1 = 0; i1 < len1; i1++) {
293
+ const _errs20 = errors;
294
+ if (typeof data6[i1] !== "string") {
295
+ validate23.errors = [{ instancePath: instancePath + "/oskFont/source/" + i1, schemaPath: "#/definitions/KeyboardFontInfo/properties/source/items/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
296
+ return false;
297
+ }
298
+ var valid6 = _errs20 === errors;
299
+ if (!valid6) {
300
+ break;
301
+ }
302
+ }
303
+ }
304
+ else {
305
+ validate23.errors = [{ instancePath: instancePath + "/oskFont/source", schemaPath: "#/definitions/KeyboardFontInfo/properties/source/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
306
+ return false;
307
+ }
308
+ }
309
+ var valid5 = _errs18 === errors;
310
+ }
311
+ else {
312
+ var valid5 = true;
313
+ }
314
+ }
315
+ }
316
+ }
317
+ }
318
+ else {
319
+ validate23.errors = [{ instancePath: instancePath + "/oskFont", schemaPath: "#/definitions/KeyboardFontInfo/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
320
+ return false;
321
+ }
322
+ }
323
+ var valid0 = _errs12 === errors;
324
+ }
325
+ else {
326
+ var valid0 = true;
327
+ }
328
+ if (valid0) {
329
+ if (data.examples !== void 0) {
330
+ let data8 = data.examples;
331
+ const _errs22 = errors;
332
+ if (errors === _errs22) {
333
+ if (Array.isArray(data8)) {
334
+ var valid7 = true;
335
+ const len2 = data8.length;
336
+ for (let i2 = 0; i2 < len2; i2++) {
337
+ let data9 = data8[i2];
338
+ const _errs24 = errors;
339
+ const _errs25 = errors;
340
+ if (errors === _errs25) {
341
+ if (data9 && typeof data9 == "object" && !Array.isArray(data9)) {
342
+ let missing2;
343
+ if (data9.keys === void 0 && (missing2 = "keys") || data9.text === void 0 && (missing2 = "text")) {
344
+ validate23.errors = [{ instancePath: instancePath + "/examples/" + i2, schemaPath: "#/definitions/KeyboardExampleInfo/required", keyword: "required", params: { missingProperty: missing2 }, message: "must have required property '" + missing2 + "'" }];
345
+ return false;
346
+ }
347
+ else {
348
+ const _errs27 = errors;
349
+ for (const key3 in data9) {
350
+ if (!(key3 === "keys" || key3 === "text" || key3 === "note")) {
351
+ validate23.errors = [{ instancePath: instancePath + "/examples/" + i2, schemaPath: "#/definitions/KeyboardExampleInfo/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key3 }, message: "must NOT have additional properties" }];
352
+ return false;
353
+ break;
354
+ }
355
+ }
356
+ if (_errs27 === errors) {
357
+ if (data9.keys !== void 0) {
358
+ const _errs28 = errors;
359
+ if (typeof data9.keys !== "string") {
360
+ validate23.errors = [{ instancePath: instancePath + "/examples/" + i2 + "/keys", schemaPath: "#/definitions/KeyboardExampleInfo/properties/keys/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
361
+ return false;
362
+ }
363
+ var valid9 = _errs28 === errors;
364
+ }
365
+ else {
366
+ var valid9 = true;
367
+ }
368
+ if (valid9) {
369
+ if (data9.text !== void 0) {
370
+ const _errs30 = errors;
371
+ if (typeof data9.text !== "string") {
372
+ validate23.errors = [{ instancePath: instancePath + "/examples/" + i2 + "/text", schemaPath: "#/definitions/KeyboardExampleInfo/properties/text/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
373
+ return false;
374
+ }
375
+ var valid9 = _errs30 === errors;
376
+ }
377
+ else {
378
+ var valid9 = true;
379
+ }
380
+ if (valid9) {
381
+ if (data9.note !== void 0) {
382
+ const _errs32 = errors;
383
+ if (typeof data9.note !== "string") {
384
+ validate23.errors = [{ instancePath: instancePath + "/examples/" + i2 + "/note", schemaPath: "#/definitions/KeyboardExampleInfo/properties/note/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
385
+ return false;
386
+ }
387
+ var valid9 = _errs32 === errors;
388
+ }
389
+ else {
390
+ var valid9 = true;
391
+ }
392
+ }
393
+ }
394
+ }
395
+ }
396
+ }
397
+ else {
398
+ validate23.errors = [{ instancePath: instancePath + "/examples/" + i2, schemaPath: "#/definitions/KeyboardExampleInfo/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
399
+ return false;
400
+ }
401
+ }
402
+ var valid7 = _errs24 === errors;
403
+ if (!valid7) {
404
+ break;
405
+ }
406
+ }
407
+ }
408
+ else {
409
+ validate23.errors = [{ instancePath: instancePath + "/examples", schemaPath: "#/properties/examples/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
410
+ return false;
411
+ }
412
+ }
413
+ var valid0 = _errs22 === errors;
414
+ }
415
+ else {
416
+ var valid0 = true;
417
+ }
418
+ if (valid0) {
419
+ if (data.displayName !== void 0) {
420
+ const _errs34 = errors;
421
+ if (typeof data.displayName !== "string") {
422
+ validate23.errors = [{ instancePath: instancePath + "/displayName", schemaPath: "#/properties/displayName/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
423
+ return false;
424
+ }
425
+ var valid0 = _errs34 === errors;
426
+ }
427
+ else {
428
+ var valid0 = true;
429
+ }
430
+ if (valid0) {
431
+ if (data.languageName !== void 0) {
432
+ const _errs36 = errors;
433
+ if (typeof data.languageName !== "string") {
434
+ validate23.errors = [{ instancePath: instancePath + "/languageName", schemaPath: "#/properties/languageName/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
435
+ return false;
436
+ }
437
+ var valid0 = _errs36 === errors;
438
+ }
439
+ else {
440
+ var valid0 = true;
441
+ }
442
+ if (valid0) {
443
+ if (data.scriptName !== void 0) {
444
+ const _errs38 = errors;
445
+ if (typeof data.scriptName !== "string") {
446
+ validate23.errors = [{ instancePath: instancePath + "/scriptName", schemaPath: "#/properties/scriptName/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
447
+ return false;
448
+ }
449
+ var valid0 = _errs38 === errors;
450
+ }
451
+ else {
452
+ var valid0 = true;
453
+ }
454
+ if (valid0) {
455
+ if (data.regionName !== void 0) {
456
+ const _errs40 = errors;
457
+ if (typeof data.regionName !== "string") {
458
+ validate23.errors = [{ instancePath: instancePath + "/regionName", schemaPath: "#/properties/regionName/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
459
+ return false;
460
+ }
461
+ var valid0 = _errs40 === errors;
462
+ }
463
+ else {
464
+ var valid0 = true;
465
+ }
466
+ }
467
+ }
468
+ }
469
+ }
470
+ }
471
+ }
472
+ }
473
+ }
474
+ else {
475
+ validate23.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
476
+ return false;
477
+ }
478
+ }
479
+ validate23.errors = vErrors;
480
+ return errors === 0;
481
+ }
482
+ function validate22(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
483
+ let vErrors = null;
484
+ let errors = 0;
485
+ if (errors === 0) {
486
+ if (data && typeof data == "object" && !Array.isArray(data)) {
487
+ const _errs1 = errors;
488
+ for (const key0 in data) {
489
+ if (!pattern0.test(key0)) {
490
+ validate22.errors = [{ instancePath, schemaPath: "#/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
491
+ return false;
492
+ break;
493
+ }
494
+ }
495
+ if (_errs1 === errors) {
496
+ var valid0 = true;
497
+ for (const key1 in data) {
498
+ if (pattern0.test(key1)) {
499
+ const _errs2 = errors;
500
+ if (!validate23(data[key1], { instancePath: instancePath + "/" + key1.replace(/~/g, "~0").replace(/\//g, "~1"), parentData: data, parentDataProperty: key1, rootData })) {
501
+ vErrors = vErrors === null ? validate23.errors : vErrors.concat(validate23.errors);
502
+ errors = vErrors.length;
503
+ }
504
+ var valid0 = _errs2 === errors;
505
+ if (!valid0) {
506
+ break;
507
+ }
508
+ }
509
+ }
510
+ }
511
+ }
512
+ else {
513
+ validate22.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
514
+ return false;
515
+ }
516
+ }
517
+ validate22.errors = vErrors;
518
+ return errors === 0;
519
+ }
520
+ var pattern2 = new RegExp("\\.km[xp]$", "u");
521
+ var pattern3 = new RegExp("\\.js$", "u");
522
+ var pattern4 = new RegExp("^\\d+\\.\\d$", "u");
523
+ var pattern5 = new RegExp("^https://help\\.keyman\\.com/keyboard/", "u");
524
+ var pattern6 = new RegExp("^(windows|macos|desktopWeb|ios|android|mobileWeb|linux)$", "u");
525
+ var pattern8 = new RegExp("^(release|legacy|experimental)/.+/.+$", "u");
526
+ function validate21(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
527
+ let vErrors = null;
528
+ let errors = 0;
529
+ if (errors === 0) {
530
+ if (data && typeof data == "object" && !Array.isArray(data)) {
531
+ let missing0;
532
+ if (data.id === void 0 && (missing0 = "id") || data.name === void 0 && (missing0 = "name") || data.license === void 0 && (missing0 = "license") || data.languages === void 0 && (missing0 = "languages") || data.lastModifiedDate === void 0 && (missing0 = "lastModifiedDate") || data.platformSupport === void 0 && (missing0 = "platformSupport")) {
533
+ validate21.errors = [{ instancePath, schemaPath: "#/required", keyword: "required", params: { missingProperty: missing0 }, message: "must have required property '" + missing0 + "'" }];
534
+ return false;
535
+ }
536
+ else {
537
+ if (data.id !== void 0) {
538
+ const _errs1 = errors;
539
+ if (typeof data.id !== "string") {
540
+ validate21.errors = [{ instancePath: instancePath + "/id", schemaPath: "#/properties/id/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
541
+ return false;
542
+ }
543
+ var valid0 = _errs1 === errors;
544
+ }
545
+ else {
546
+ var valid0 = true;
547
+ }
548
+ if (valid0) {
549
+ if (data.name !== void 0) {
550
+ const _errs3 = errors;
551
+ if (typeof data.name !== "string") {
552
+ validate21.errors = [{ instancePath: instancePath + "/name", schemaPath: "#/properties/name/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
553
+ return false;
554
+ }
555
+ var valid0 = _errs3 === errors;
556
+ }
557
+ else {
558
+ var valid0 = true;
559
+ }
560
+ if (valid0) {
561
+ if (data.authorName !== void 0) {
562
+ const _errs5 = errors;
563
+ if (typeof data.authorName !== "string") {
564
+ validate21.errors = [{ instancePath: instancePath + "/authorName", schemaPath: "#/properties/authorName/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
565
+ return false;
566
+ }
567
+ var valid0 = _errs5 === errors;
568
+ }
569
+ else {
570
+ var valid0 = true;
571
+ }
572
+ if (valid0) {
573
+ if (data.authorEmail !== void 0) {
574
+ let data3 = data.authorEmail;
575
+ const _errs7 = errors;
576
+ if (errors === _errs7) {
577
+ if (errors === _errs7) {
578
+ if (typeof data3 === "string") {
579
+ if (!formats0.test(data3)) {
580
+ validate21.errors = [{ instancePath: instancePath + "/authorEmail", schemaPath: "#/properties/authorEmail/format", keyword: "format", params: { format: "email" }, message: 'must match format "email"' }];
581
+ return false;
582
+ }
583
+ }
584
+ else {
585
+ validate21.errors = [{ instancePath: instancePath + "/authorEmail", schemaPath: "#/properties/authorEmail/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
586
+ return false;
587
+ }
588
+ }
589
+ }
590
+ var valid0 = _errs7 === errors;
591
+ }
592
+ else {
593
+ var valid0 = true;
594
+ }
595
+ if (valid0) {
596
+ if (data.description !== void 0) {
597
+ const _errs9 = errors;
598
+ if (typeof data.description !== "string") {
599
+ validate21.errors = [{ instancePath: instancePath + "/description", schemaPath: "#/properties/description/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
600
+ return false;
601
+ }
602
+ var valid0 = _errs9 === errors;
603
+ }
604
+ else {
605
+ var valid0 = true;
606
+ }
607
+ if (valid0) {
608
+ if (data.license !== void 0) {
609
+ let data5 = data.license;
610
+ const _errs11 = errors;
611
+ if (typeof data5 !== "string") {
612
+ validate21.errors = [{ instancePath: instancePath + "/license", schemaPath: "#/properties/license/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
613
+ return false;
614
+ }
615
+ if (!(data5 === "freeware" || data5 === "shareware" || data5 === "commercial" || data5 === "mit" || data5 === "other")) {
616
+ validate21.errors = [{ instancePath: instancePath + "/license", schemaPath: "#/properties/license/enum", keyword: "enum", params: { allowedValues: schema23.properties.license.enum }, message: "must be equal to one of the allowed values" }];
617
+ return false;
618
+ }
619
+ var valid0 = _errs11 === errors;
620
+ }
621
+ else {
622
+ var valid0 = true;
623
+ }
624
+ if (valid0) {
625
+ if (data.languages !== void 0) {
626
+ let data6 = data.languages;
627
+ const _errs13 = errors;
628
+ const _errs14 = errors;
629
+ let valid1 = false;
630
+ const _errs15 = errors;
631
+ if (errors === _errs15) {
632
+ if (Array.isArray(data6)) {
633
+ var valid2 = true;
634
+ const len0 = data6.length;
635
+ for (let i0 = 0; i0 < len0; i0++) {
636
+ const _errs17 = errors;
637
+ if (typeof data6[i0] !== "string") {
638
+ const err0 = { instancePath: instancePath + "/languages/" + i0, schemaPath: "#/properties/languages/anyOf/0/items/type", keyword: "type", params: { type: "string" }, message: "must be string" };
639
+ if (vErrors === null) {
640
+ vErrors = [err0];
641
+ }
642
+ else {
643
+ vErrors.push(err0);
644
+ }
645
+ errors++;
646
+ }
647
+ var valid2 = _errs17 === errors;
648
+ if (!valid2) {
649
+ break;
650
+ }
651
+ }
652
+ if (valid2) {
653
+ let i1 = data6.length;
654
+ let j0;
655
+ if (i1 > 1) {
656
+ const indices0 = {};
657
+ for (; i1--;) {
658
+ let item0 = data6[i1];
659
+ if (typeof item0 !== "string") {
660
+ continue;
661
+ }
662
+ if (typeof indices0[item0] == "number") {
663
+ j0 = indices0[item0];
664
+ const err1 = { instancePath: instancePath + "/languages", schemaPath: "#/properties/languages/anyOf/0/uniqueItems", keyword: "uniqueItems", params: { i: i1, j: j0 }, message: "must NOT have duplicate items (items ## " + j0 + " and " + i1 + " are identical)" };
665
+ if (vErrors === null) {
666
+ vErrors = [err1];
667
+ }
668
+ else {
669
+ vErrors.push(err1);
670
+ }
671
+ errors++;
672
+ break;
673
+ }
674
+ indices0[item0] = i1;
675
+ }
676
+ }
677
+ }
678
+ }
679
+ else {
680
+ const err2 = { instancePath: instancePath + "/languages", schemaPath: "#/properties/languages/anyOf/0/type", keyword: "type", params: { type: "array" }, message: "must be array" };
681
+ if (vErrors === null) {
682
+ vErrors = [err2];
683
+ }
684
+ else {
685
+ vErrors.push(err2);
686
+ }
687
+ errors++;
688
+ }
689
+ }
690
+ var _valid0 = _errs15 === errors;
691
+ valid1 = valid1 || _valid0;
692
+ if (!valid1) {
693
+ const _errs19 = errors;
694
+ if (!validate22(data6, { instancePath: instancePath + "/languages", parentData: data, parentDataProperty: "languages", rootData })) {
695
+ vErrors = vErrors === null ? validate22.errors : vErrors.concat(validate22.errors);
696
+ errors = vErrors.length;
697
+ }
698
+ var _valid0 = _errs19 === errors;
699
+ valid1 = valid1 || _valid0;
700
+ }
701
+ if (!valid1) {
702
+ const err3 = { instancePath: instancePath + "/languages", schemaPath: "#/properties/languages/anyOf", keyword: "anyOf", params: {}, message: "must match a schema in anyOf" };
703
+ if (vErrors === null) {
704
+ vErrors = [err3];
705
+ }
706
+ else {
707
+ vErrors.push(err3);
708
+ }
709
+ errors++;
710
+ validate21.errors = vErrors;
711
+ return false;
712
+ }
713
+ else {
714
+ errors = _errs14;
715
+ if (vErrors !== null) {
716
+ if (_errs14) {
717
+ vErrors.length = _errs14;
718
+ }
719
+ else {
720
+ vErrors = null;
721
+ }
722
+ }
723
+ }
724
+ var valid0 = _errs13 === errors;
725
+ }
726
+ else {
727
+ var valid0 = true;
728
+ }
729
+ if (valid0) {
730
+ if (data.lastModifiedDate !== void 0) {
731
+ let data8 = data.lastModifiedDate;
732
+ const _errs20 = errors;
733
+ if (errors === _errs20) {
734
+ if (errors === _errs20) {
735
+ if (typeof data8 === "string") {
736
+ if (!formats2.validate(data8)) {
737
+ validate21.errors = [{ instancePath: instancePath + "/lastModifiedDate", schemaPath: "#/properties/lastModifiedDate/format", keyword: "format", params: { format: "date-time" }, message: 'must match format "date-time"' }];
738
+ return false;
739
+ }
740
+ }
741
+ else {
742
+ validate21.errors = [{ instancePath: instancePath + "/lastModifiedDate", schemaPath: "#/properties/lastModifiedDate/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
743
+ return false;
744
+ }
745
+ }
746
+ }
747
+ var valid0 = _errs20 === errors;
748
+ }
749
+ else {
750
+ var valid0 = true;
751
+ }
752
+ if (valid0) {
753
+ if (data.packageFilename !== void 0) {
754
+ let data9 = data.packageFilename;
755
+ const _errs22 = errors;
756
+ if (errors === _errs22) {
757
+ if (typeof data9 === "string") {
758
+ if (!pattern2.test(data9)) {
759
+ validate21.errors = [{ instancePath: instancePath + "/packageFilename", schemaPath: "#/properties/packageFilename/pattern", keyword: "pattern", params: { pattern: "\\.km[xp]$" }, message: 'must match pattern "\\.km[xp]$"' }];
760
+ return false;
761
+ }
762
+ }
763
+ else {
764
+ validate21.errors = [{ instancePath: instancePath + "/packageFilename", schemaPath: "#/properties/packageFilename/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
765
+ return false;
766
+ }
767
+ }
768
+ var valid0 = _errs22 === errors;
769
+ }
770
+ else {
771
+ var valid0 = true;
772
+ }
773
+ if (valid0) {
774
+ if (data.packageFileSize !== void 0) {
775
+ let data10 = data.packageFileSize;
776
+ const _errs24 = errors;
777
+ if (!(typeof data10 == "number" && isFinite(data10))) {
778
+ validate21.errors = [{ instancePath: instancePath + "/packageFileSize", schemaPath: "#/properties/packageFileSize/type", keyword: "type", params: { type: "number" }, message: "must be number" }];
779
+ return false;
780
+ }
781
+ var valid0 = _errs24 === errors;
782
+ }
783
+ else {
784
+ var valid0 = true;
785
+ }
786
+ if (valid0) {
787
+ if (data.jsFilename !== void 0) {
788
+ let data11 = data.jsFilename;
789
+ const _errs26 = errors;
790
+ if (errors === _errs26) {
791
+ if (typeof data11 === "string") {
792
+ if (!pattern3.test(data11)) {
793
+ validate21.errors = [{ instancePath: instancePath + "/jsFilename", schemaPath: "#/properties/jsFilename/pattern", keyword: "pattern", params: { pattern: "\\.js$" }, message: 'must match pattern "\\.js$"' }];
794
+ return false;
795
+ }
796
+ }
797
+ else {
798
+ validate21.errors = [{ instancePath: instancePath + "/jsFilename", schemaPath: "#/properties/jsFilename/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
799
+ return false;
800
+ }
801
+ }
802
+ var valid0 = _errs26 === errors;
803
+ }
804
+ else {
805
+ var valid0 = true;
806
+ }
807
+ if (valid0) {
808
+ if (data.jsFileSize !== void 0) {
809
+ let data12 = data.jsFileSize;
810
+ const _errs28 = errors;
811
+ if (!(typeof data12 == "number" && isFinite(data12))) {
812
+ validate21.errors = [{ instancePath: instancePath + "/jsFileSize", schemaPath: "#/properties/jsFileSize/type", keyword: "type", params: { type: "number" }, message: "must be number" }];
813
+ return false;
814
+ }
815
+ var valid0 = _errs28 === errors;
816
+ }
817
+ else {
818
+ var valid0 = true;
819
+ }
820
+ if (valid0) {
821
+ if (data.isRTL !== void 0) {
822
+ const _errs30 = errors;
823
+ if (typeof data.isRTL !== "boolean") {
824
+ validate21.errors = [{ instancePath: instancePath + "/isRTL", schemaPath: "#/properties/isRTL/type", keyword: "type", params: { type: "boolean" }, message: "must be boolean" }];
825
+ return false;
826
+ }
827
+ var valid0 = _errs30 === errors;
828
+ }
829
+ else {
830
+ var valid0 = true;
831
+ }
832
+ if (valid0) {
833
+ if (data.encodings !== void 0) {
834
+ let data14 = data.encodings;
835
+ const _errs32 = errors;
836
+ if (errors === _errs32) {
837
+ if (Array.isArray(data14)) {
838
+ var valid4 = true;
839
+ const len1 = data14.length;
840
+ for (let i2 = 0; i2 < len1; i2++) {
841
+ let data15 = data14[i2];
842
+ const _errs34 = errors;
843
+ if (typeof data15 !== "string") {
844
+ validate21.errors = [{ instancePath: instancePath + "/encodings/" + i2, schemaPath: "#/properties/encodings/items/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
845
+ return false;
846
+ }
847
+ if (!(data15 === "ansi" || data15 === "unicode")) {
848
+ validate21.errors = [{ instancePath: instancePath + "/encodings/" + i2, schemaPath: "#/properties/encodings/items/enum", keyword: "enum", params: { allowedValues: schema23.properties.encodings.items.enum }, message: "must be equal to one of the allowed values" }];
849
+ return false;
850
+ }
851
+ var valid4 = _errs34 === errors;
852
+ if (!valid4) {
853
+ break;
854
+ }
855
+ }
856
+ }
857
+ else {
858
+ validate21.errors = [{ instancePath: instancePath + "/encodings", schemaPath: "#/properties/encodings/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
859
+ return false;
860
+ }
861
+ }
862
+ var valid0 = _errs32 === errors;
863
+ }
864
+ else {
865
+ var valid0 = true;
866
+ }
867
+ if (valid0) {
868
+ if (data.packageIncludes !== void 0) {
869
+ let data16 = data.packageIncludes;
870
+ const _errs36 = errors;
871
+ if (errors === _errs36) {
872
+ if (Array.isArray(data16)) {
873
+ var valid5 = true;
874
+ const len2 = data16.length;
875
+ for (let i3 = 0; i3 < len2; i3++) {
876
+ let data17 = data16[i3];
877
+ const _errs38 = errors;
878
+ if (typeof data17 !== "string") {
879
+ validate21.errors = [{ instancePath: instancePath + "/packageIncludes/" + i3, schemaPath: "#/properties/packageIncludes/items/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
880
+ return false;
881
+ }
882
+ if (!(data17 === "welcome" || data17 === "documentation" || data17 === "fonts" || data17 === "visualKeyboard")) {
883
+ validate21.errors = [{ instancePath: instancePath + "/packageIncludes/" + i3, schemaPath: "#/properties/packageIncludes/items/enum", keyword: "enum", params: { allowedValues: schema23.properties.packageIncludes.items.enum }, message: "must be equal to one of the allowed values" }];
884
+ return false;
885
+ }
886
+ var valid5 = _errs38 === errors;
887
+ if (!valid5) {
888
+ break;
889
+ }
890
+ }
891
+ }
892
+ else {
893
+ validate21.errors = [{ instancePath: instancePath + "/packageIncludes", schemaPath: "#/properties/packageIncludes/type", keyword: "type", params: { type: "array" }, message: "must be array" }];
894
+ return false;
895
+ }
896
+ }
897
+ var valid0 = _errs36 === errors;
898
+ }
899
+ else {
900
+ var valid0 = true;
901
+ }
902
+ if (valid0) {
903
+ if (data.version !== void 0) {
904
+ const _errs40 = errors;
905
+ if (typeof data.version !== "string") {
906
+ validate21.errors = [{ instancePath: instancePath + "/version", schemaPath: "#/properties/version/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
907
+ return false;
908
+ }
909
+ var valid0 = _errs40 === errors;
910
+ }
911
+ else {
912
+ var valid0 = true;
913
+ }
914
+ if (valid0) {
915
+ if (data.minKeymanVersion !== void 0) {
916
+ let data19 = data.minKeymanVersion;
917
+ const _errs42 = errors;
918
+ if (errors === _errs42) {
919
+ if (typeof data19 === "string") {
920
+ if (!pattern4.test(data19)) {
921
+ validate21.errors = [{ instancePath: instancePath + "/minKeymanVersion", schemaPath: "#/properties/minKeymanVersion/pattern", keyword: "pattern", params: { pattern: "^\\d+\\.\\d$" }, message: 'must match pattern "^\\d+\\.\\d$"' }];
922
+ return false;
923
+ }
924
+ }
925
+ else {
926
+ validate21.errors = [{ instancePath: instancePath + "/minKeymanVersion", schemaPath: "#/properties/minKeymanVersion/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
927
+ return false;
928
+ }
929
+ }
930
+ var valid0 = _errs42 === errors;
931
+ }
932
+ else {
933
+ var valid0 = true;
934
+ }
935
+ if (valid0) {
936
+ if (data.helpLink !== void 0) {
937
+ let data20 = data.helpLink;
938
+ const _errs44 = errors;
939
+ if (errors === _errs44) {
940
+ if (typeof data20 === "string") {
941
+ if (!pattern5.test(data20)) {
942
+ validate21.errors = [{ instancePath: instancePath + "/helpLink", schemaPath: "#/properties/helpLink/pattern", keyword: "pattern", params: { pattern: "^https://help\\.keyman\\.com/keyboard/" }, message: 'must match pattern "^https://help\\.keyman\\.com/keyboard/"' }];
943
+ return false;
944
+ }
945
+ }
946
+ else {
947
+ validate21.errors = [{ instancePath: instancePath + "/helpLink", schemaPath: "#/properties/helpLink/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
948
+ return false;
949
+ }
950
+ }
951
+ var valid0 = _errs44 === errors;
952
+ }
953
+ else {
954
+ var valid0 = true;
955
+ }
956
+ if (valid0) {
957
+ if (data.platformSupport !== void 0) {
958
+ let data21 = data.platformSupport;
959
+ const _errs46 = errors;
960
+ const _errs47 = errors;
961
+ if (errors === _errs47) {
962
+ if (data21 && typeof data21 == "object" && !Array.isArray(data21)) {
963
+ const _errs49 = errors;
964
+ for (const key0 in data21) {
965
+ if (!pattern6.test(key0)) {
966
+ validate21.errors = [{ instancePath: instancePath + "/platformSupport", schemaPath: "#/definitions/KeyboardPlatformInfo/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key0 }, message: "must NOT have additional properties" }];
967
+ return false;
968
+ break;
969
+ }
970
+ }
971
+ if (_errs49 === errors) {
972
+ var valid7 = true;
973
+ for (const key1 in data21) {
974
+ if (pattern6.test(key1)) {
975
+ let data22 = data21[key1];
976
+ const _errs50 = errors;
977
+ if (typeof data22 !== "string") {
978
+ validate21.errors = [{ instancePath: instancePath + "/platformSupport/" + key1.replace(/~/g, "~0").replace(/\//g, "~1"), schemaPath: "#/definitions/KeyboardPlatformInfo/patternProperties/%5E(windows%7Cmacos%7CdesktopWeb%7Cios%7Candroid%7CmobileWeb%7Clinux)%24/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
979
+ return false;
980
+ }
981
+ if (!(data22 === "dictionary" || data22 === "full" || data22 === "basic" || data22 === "none")) {
982
+ validate21.errors = [{ instancePath: instancePath + "/platformSupport/" + key1.replace(/~/g, "~0").replace(/\//g, "~1"), schemaPath: "#/definitions/KeyboardPlatformInfo/patternProperties/%5E(windows%7Cmacos%7CdesktopWeb%7Cios%7Candroid%7CmobileWeb%7Clinux)%24/enum", keyword: "enum", params: { allowedValues: schema29.patternProperties["^(windows|macos|desktopWeb|ios|android|mobileWeb|linux)$"].enum }, message: "must be equal to one of the allowed values" }];
983
+ return false;
984
+ }
985
+ var valid7 = _errs50 === errors;
986
+ if (!valid7) {
987
+ break;
988
+ }
989
+ }
990
+ }
991
+ }
992
+ }
993
+ else {
994
+ validate21.errors = [{ instancePath: instancePath + "/platformSupport", schemaPath: "#/definitions/KeyboardPlatformInfo/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
995
+ return false;
996
+ }
997
+ }
998
+ var valid0 = _errs46 === errors;
999
+ }
1000
+ else {
1001
+ var valid0 = true;
1002
+ }
1003
+ if (valid0) {
1004
+ if (data.sourcePath !== void 0) {
1005
+ let data23 = data.sourcePath;
1006
+ const _errs52 = errors;
1007
+ if (errors === _errs52) {
1008
+ if (typeof data23 === "string") {
1009
+ if (!pattern8.test(data23)) {
1010
+ validate21.errors = [{ instancePath: instancePath + "/sourcePath", schemaPath: "#/properties/sourcePath/pattern", keyword: "pattern", params: { pattern: "^(release|legacy|experimental)/.+/.+$" }, message: 'must match pattern "^(release|legacy|experimental)/.+/.+$"' }];
1011
+ return false;
1012
+ }
1013
+ }
1014
+ else {
1015
+ validate21.errors = [{ instancePath: instancePath + "/sourcePath", schemaPath: "#/properties/sourcePath/type", keyword: "type", params: { type: "string" }, message: "must be string" }];
1016
+ return false;
1017
+ }
1018
+ }
1019
+ var valid0 = _errs52 === errors;
1020
+ }
1021
+ else {
1022
+ var valid0 = true;
1023
+ }
1024
+ if (valid0) {
1025
+ if (data.related !== void 0) {
1026
+ let data24 = data.related;
1027
+ const _errs54 = errors;
1028
+ if (errors === _errs54) {
1029
+ if (data24 && typeof data24 == "object" && !Array.isArray(data24)) {
1030
+ const _errs56 = errors;
1031
+ for (const key2 in data24) {
1032
+ if (!pattern0.test(key2)) {
1033
+ validate21.errors = [{ instancePath: instancePath + "/related", schemaPath: "#/properties/related/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key2 }, message: "must NOT have additional properties" }];
1034
+ return false;
1035
+ break;
1036
+ }
1037
+ }
1038
+ if (_errs56 === errors) {
1039
+ var valid8 = true;
1040
+ for (const key3 in data24) {
1041
+ if (pattern0.test(key3)) {
1042
+ let data25 = data24[key3];
1043
+ const _errs57 = errors;
1044
+ const _errs58 = errors;
1045
+ if (errors === _errs58) {
1046
+ if (data25 && typeof data25 == "object" && !Array.isArray(data25)) {
1047
+ const _errs60 = errors;
1048
+ for (const key4 in data25) {
1049
+ if (!(key4 === "deprecates" || key4 === "deprecatedBy")) {
1050
+ validate21.errors = [{ instancePath: instancePath + "/related/" + key3.replace(/~/g, "~0").replace(/\//g, "~1"), schemaPath: "#/definitions/KeyboardRelatedInfo/additionalProperties", keyword: "additionalProperties", params: { additionalProperty: key4 }, message: "must NOT have additional properties" }];
1051
+ return false;
1052
+ break;
1053
+ }
1054
+ }
1055
+ if (_errs60 === errors) {
1056
+ if (data25.deprecates !== void 0) {
1057
+ const _errs61 = errors;
1058
+ if (typeof data25.deprecates !== "boolean") {
1059
+ validate21.errors = [{ instancePath: instancePath + "/related/" + key3.replace(/~/g, "~0").replace(/\//g, "~1") + "/deprecates", schemaPath: "#/definitions/KeyboardRelatedInfo/properties/deprecates/type", keyword: "type", params: { type: "boolean" }, message: "must be boolean" }];
1060
+ return false;
1061
+ }
1062
+ var valid10 = _errs61 === errors;
1063
+ }
1064
+ else {
1065
+ var valid10 = true;
1066
+ }
1067
+ if (valid10) {
1068
+ if (data25.deprecatedBy !== void 0) {
1069
+ const _errs63 = errors;
1070
+ if (typeof data25.deprecatedBy !== "boolean") {
1071
+ validate21.errors = [{ instancePath: instancePath + "/related/" + key3.replace(/~/g, "~0").replace(/\//g, "~1") + "/deprecatedBy", schemaPath: "#/definitions/KeyboardRelatedInfo/properties/deprecatedBy/type", keyword: "type", params: { type: "boolean" }, message: "must be boolean" }];
1072
+ return false;
1073
+ }
1074
+ var valid10 = _errs63 === errors;
1075
+ }
1076
+ else {
1077
+ var valid10 = true;
1078
+ }
1079
+ }
1080
+ }
1081
+ }
1082
+ else {
1083
+ validate21.errors = [{ instancePath: instancePath + "/related/" + key3.replace(/~/g, "~0").replace(/\//g, "~1"), schemaPath: "#/definitions/KeyboardRelatedInfo/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
1084
+ return false;
1085
+ }
1086
+ }
1087
+ var valid8 = _errs57 === errors;
1088
+ if (!valid8) {
1089
+ break;
1090
+ }
1091
+ }
1092
+ }
1093
+ }
1094
+ }
1095
+ else {
1096
+ validate21.errors = [{ instancePath: instancePath + "/related", schemaPath: "#/properties/related/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
1097
+ return false;
1098
+ }
1099
+ }
1100
+ var valid0 = _errs54 === errors;
1101
+ }
1102
+ else {
1103
+ var valid0 = true;
1104
+ }
1105
+ if (valid0) {
1106
+ if (data.deprecated !== void 0) {
1107
+ const _errs65 = errors;
1108
+ if (typeof data.deprecated !== "boolean") {
1109
+ validate21.errors = [{ instancePath: instancePath + "/deprecated", schemaPath: "#/properties/deprecated/type", keyword: "type", params: { type: "boolean" }, message: "must be boolean" }];
1110
+ return false;
1111
+ }
1112
+ var valid0 = _errs65 === errors;
1113
+ }
1114
+ else {
1115
+ var valid0 = true;
1116
+ }
1117
+ }
1118
+ }
1119
+ }
1120
+ }
1121
+ }
1122
+ }
1123
+ }
1124
+ }
1125
+ }
1126
+ }
1127
+ }
1128
+ }
1129
+ }
1130
+ }
1131
+ }
1132
+ }
1133
+ }
1134
+ }
1135
+ }
1136
+ }
1137
+ }
1138
+ }
1139
+ }
1140
+ else {
1141
+ validate21.errors = [{ instancePath, schemaPath: "#/type", keyword: "type", params: { type: "object" }, message: "must be object" }];
1142
+ return false;
1143
+ }
1144
+ }
1145
+ validate21.errors = vErrors;
1146
+ return errors === 0;
1147
+ }
1148
+ function validate20(data, { instancePath = "", parentData, parentDataProperty, rootData = data } = {}) {
1149
+ let vErrors = null;
1150
+ let errors = 0;
1151
+ if (!validate21(data, { instancePath, parentData, parentDataProperty, rootData })) {
1152
+ vErrors = vErrors === null ? validate21.errors : vErrors.concat(validate21.errors);
1153
+ errors = vErrors.length;
1154
+ }
1155
+ validate20.errors = vErrors;
1156
+ return errors === 0;
1157
+ }
1158
+ }
1159
+ });
1160
+ export default require_keyboard_info_schema_validator();
1161
1161
  //# sourceMappingURL=keyboard_info.schema.validator.mjs.map
1162
- //# debugId=25d80a0a-d910-56f5-8fbe-768ce970fcaf
1162
+ //# debugId=fc87f4de-21b0-5624-ab1c-b4b7dbf24c10