aizryu.js 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (343) hide show
  1. package/.cache/replit/__replit_disk_meta.json +1 -0
  2. package/.cache/replit/modules.stamp +0 -0
  3. package/.cache/replit/nix/env.json +1 -0
  4. package/.cache/typescript/5.0/node_modules/.package-lock.json +156 -0
  5. package/.cache/typescript/5.0/node_modules/@types/body-parser/LICENSE +21 -0
  6. package/.cache/typescript/5.0/node_modules/@types/body-parser/README.md +15 -0
  7. package/.cache/typescript/5.0/node_modules/@types/body-parser/index.d.ts +95 -0
  8. package/.cache/typescript/5.0/node_modules/@types/body-parser/package.json +58 -0
  9. package/.cache/typescript/5.0/node_modules/@types/connect/LICENSE +21 -0
  10. package/.cache/typescript/5.0/node_modules/@types/connect/README.md +15 -0
  11. package/.cache/typescript/5.0/node_modules/@types/connect/index.d.ts +91 -0
  12. package/.cache/typescript/5.0/node_modules/@types/connect/package.json +32 -0
  13. package/.cache/typescript/5.0/node_modules/@types/express/LICENSE +21 -0
  14. package/.cache/typescript/5.0/node_modules/@types/express/README.md +15 -0
  15. package/.cache/typescript/5.0/node_modules/@types/express/index.d.ts +128 -0
  16. package/.cache/typescript/5.0/node_modules/@types/express/package.json +45 -0
  17. package/.cache/typescript/5.0/node_modules/@types/express-serve-static-core/LICENSE +21 -0
  18. package/.cache/typescript/5.0/node_modules/@types/express-serve-static-core/README.md +15 -0
  19. package/.cache/typescript/5.0/node_modules/@types/express-serve-static-core/index.d.ts +1261 -0
  20. package/.cache/typescript/5.0/node_modules/@types/express-serve-static-core/package.json +55 -0
  21. package/.cache/typescript/5.0/node_modules/@types/http-errors/LICENSE +21 -0
  22. package/.cache/typescript/5.0/node_modules/@types/http-errors/README.md +15 -0
  23. package/.cache/typescript/5.0/node_modules/@types/http-errors/index.d.ts +77 -0
  24. package/.cache/typescript/5.0/node_modules/@types/http-errors/package.json +30 -0
  25. package/.cache/typescript/5.0/node_modules/@types/jsdom/LICENSE +21 -0
  26. package/.cache/typescript/5.0/node_modules/@types/jsdom/README.md +15 -0
  27. package/.cache/typescript/5.0/node_modules/@types/jsdom/base.d.ts +456 -0
  28. package/.cache/typescript/5.0/node_modules/@types/jsdom/index.d.ts +18 -0
  29. package/.cache/typescript/5.0/node_modules/@types/jsdom/package.json +45 -0
  30. package/.cache/typescript/5.0/node_modules/@types/mime/LICENSE +21 -0
  31. package/.cache/typescript/5.0/node_modules/@types/mime/Mime.d.ts +10 -0
  32. package/.cache/typescript/5.0/node_modules/@types/mime/README.md +15 -0
  33. package/.cache/typescript/5.0/node_modules/@types/mime/index.d.ts +31 -0
  34. package/.cache/typescript/5.0/node_modules/@types/mime/lite.d.ts +7 -0
  35. package/.cache/typescript/5.0/node_modules/@types/mime/package.json +30 -0
  36. package/.cache/typescript/5.0/node_modules/@types/node/LICENSE +21 -0
  37. package/.cache/typescript/5.0/node_modules/@types/node/README.md +15 -0
  38. package/.cache/typescript/5.0/node_modules/@types/node/assert/strict.d.ts +8 -0
  39. package/.cache/typescript/5.0/node_modules/@types/node/assert.d.ts +996 -0
  40. package/.cache/typescript/5.0/node_modules/@types/node/async_hooks.d.ts +539 -0
  41. package/.cache/typescript/5.0/node_modules/@types/node/buffer.d.ts +2362 -0
  42. package/.cache/typescript/5.0/node_modules/@types/node/child_process.d.ts +1540 -0
  43. package/.cache/typescript/5.0/node_modules/@types/node/cluster.d.ts +432 -0
  44. package/.cache/typescript/5.0/node_modules/@types/node/console.d.ts +415 -0
  45. package/.cache/typescript/5.0/node_modules/@types/node/constants.d.ts +19 -0
  46. package/.cache/typescript/5.0/node_modules/@types/node/crypto.d.ts +4456 -0
  47. package/.cache/typescript/5.0/node_modules/@types/node/dgram.d.ts +586 -0
  48. package/.cache/typescript/5.0/node_modules/@types/node/diagnostics_channel.d.ts +191 -0
  49. package/.cache/typescript/5.0/node_modules/@types/node/dns/promises.d.ts +425 -0
  50. package/.cache/typescript/5.0/node_modules/@types/node/dns.d.ts +809 -0
  51. package/.cache/typescript/5.0/node_modules/@types/node/dom-events.d.ts +122 -0
  52. package/.cache/typescript/5.0/node_modules/@types/node/domain.d.ts +170 -0
  53. package/.cache/typescript/5.0/node_modules/@types/node/events.d.ts +879 -0
  54. package/.cache/typescript/5.0/node_modules/@types/node/fs/promises.d.ts +1239 -0
  55. package/.cache/typescript/5.0/node_modules/@types/node/fs.d.ts +4291 -0
  56. package/.cache/typescript/5.0/node_modules/@types/node/globals.d.ts +381 -0
  57. package/.cache/typescript/5.0/node_modules/@types/node/globals.global.d.ts +1 -0
  58. package/.cache/typescript/5.0/node_modules/@types/node/http.d.ts +1888 -0
  59. package/.cache/typescript/5.0/node_modules/@types/node/http2.d.ts +2382 -0
  60. package/.cache/typescript/5.0/node_modules/@types/node/https.d.ts +550 -0
  61. package/.cache/typescript/5.0/node_modules/@types/node/index.d.ts +88 -0
  62. package/.cache/typescript/5.0/node_modules/@types/node/inspector.d.ts +2747 -0
  63. package/.cache/typescript/5.0/node_modules/@types/node/module.d.ts +301 -0
  64. package/.cache/typescript/5.0/node_modules/@types/node/net.d.ts +949 -0
  65. package/.cache/typescript/5.0/node_modules/@types/node/os.d.ts +478 -0
  66. package/.cache/typescript/5.0/node_modules/@types/node/package.json +230 -0
  67. package/.cache/typescript/5.0/node_modules/@types/node/path.d.ts +191 -0
  68. package/.cache/typescript/5.0/node_modules/@types/node/perf_hooks.d.ts +639 -0
  69. package/.cache/typescript/5.0/node_modules/@types/node/process.d.ts +1532 -0
  70. package/.cache/typescript/5.0/node_modules/@types/node/punycode.d.ts +117 -0
  71. package/.cache/typescript/5.0/node_modules/@types/node/querystring.d.ts +141 -0
  72. package/.cache/typescript/5.0/node_modules/@types/node/readline/promises.d.ts +150 -0
  73. package/.cache/typescript/5.0/node_modules/@types/node/readline.d.ts +539 -0
  74. package/.cache/typescript/5.0/node_modules/@types/node/repl.d.ts +430 -0
  75. package/.cache/typescript/5.0/node_modules/@types/node/stream/consumers.d.ts +12 -0
  76. package/.cache/typescript/5.0/node_modules/@types/node/stream/promises.d.ts +83 -0
  77. package/.cache/typescript/5.0/node_modules/@types/node/stream/web.d.ts +350 -0
  78. package/.cache/typescript/5.0/node_modules/@types/node/stream.d.ts +1701 -0
  79. package/.cache/typescript/5.0/node_modules/@types/node/string_decoder.d.ts +67 -0
  80. package/.cache/typescript/5.0/node_modules/@types/node/test.d.ts +1382 -0
  81. package/.cache/typescript/5.0/node_modules/@types/node/timers/promises.d.ts +93 -0
  82. package/.cache/typescript/5.0/node_modules/@types/node/timers.d.ts +240 -0
  83. package/.cache/typescript/5.0/node_modules/@types/node/tls.d.ts +1210 -0
  84. package/.cache/typescript/5.0/node_modules/@types/node/trace_events.d.ts +182 -0
  85. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/assert/strict.d.ts +8 -0
  86. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/assert.d.ts +996 -0
  87. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/async_hooks.d.ts +539 -0
  88. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/buffer.d.ts +2362 -0
  89. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/child_process.d.ts +1540 -0
  90. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/cluster.d.ts +432 -0
  91. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/console.d.ts +415 -0
  92. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/constants.d.ts +19 -0
  93. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/crypto.d.ts +4455 -0
  94. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/dgram.d.ts +586 -0
  95. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/diagnostics_channel.d.ts +191 -0
  96. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/dns/promises.d.ts +425 -0
  97. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/dns.d.ts +809 -0
  98. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/dom-events.d.ts +122 -0
  99. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/domain.d.ts +170 -0
  100. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/events.d.ts +879 -0
  101. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/fs/promises.d.ts +1239 -0
  102. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/fs.d.ts +4291 -0
  103. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/globals.d.ts +381 -0
  104. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/globals.global.d.ts +1 -0
  105. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/http.d.ts +1888 -0
  106. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/http2.d.ts +2382 -0
  107. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/https.d.ts +550 -0
  108. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/index.d.ts +88 -0
  109. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/inspector.d.ts +2747 -0
  110. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/module.d.ts +301 -0
  111. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/net.d.ts +949 -0
  112. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/os.d.ts +478 -0
  113. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/path.d.ts +191 -0
  114. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/perf_hooks.d.ts +639 -0
  115. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/process.d.ts +1532 -0
  116. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/punycode.d.ts +117 -0
  117. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/querystring.d.ts +141 -0
  118. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/readline/promises.d.ts +150 -0
  119. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/readline.d.ts +539 -0
  120. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/repl.d.ts +430 -0
  121. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/stream/consumers.d.ts +12 -0
  122. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/stream/promises.d.ts +83 -0
  123. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/stream/web.d.ts +350 -0
  124. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/stream.d.ts +1701 -0
  125. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/string_decoder.d.ts +67 -0
  126. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/test.d.ts +1382 -0
  127. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/timers/promises.d.ts +93 -0
  128. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/timers.d.ts +240 -0
  129. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/tls.d.ts +1210 -0
  130. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/trace_events.d.ts +182 -0
  131. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/tty.d.ts +208 -0
  132. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/url.d.ts +927 -0
  133. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/util.d.ts +2186 -0
  134. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/v8.d.ts +635 -0
  135. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/vm.d.ts +903 -0
  136. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/wasi.d.ts +158 -0
  137. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/worker_threads.d.ts +691 -0
  138. package/.cache/typescript/5.0/node_modules/@types/node/ts4.8/zlib.d.ts +517 -0
  139. package/.cache/typescript/5.0/node_modules/@types/node/tty.d.ts +208 -0
  140. package/.cache/typescript/5.0/node_modules/@types/node/url.d.ts +927 -0
  141. package/.cache/typescript/5.0/node_modules/@types/node/util.d.ts +2186 -0
  142. package/.cache/typescript/5.0/node_modules/@types/node/v8.d.ts +635 -0
  143. package/.cache/typescript/5.0/node_modules/@types/node/vm.d.ts +903 -0
  144. package/.cache/typescript/5.0/node_modules/@types/node/wasi.d.ts +158 -0
  145. package/.cache/typescript/5.0/node_modules/@types/node/worker_threads.d.ts +691 -0
  146. package/.cache/typescript/5.0/node_modules/@types/node/zlib.d.ts +517 -0
  147. package/.cache/typescript/5.0/node_modules/@types/qs/LICENSE +21 -0
  148. package/.cache/typescript/5.0/node_modules/@types/qs/README.md +75 -0
  149. package/.cache/typescript/5.0/node_modules/@types/qs/index.d.ts +56 -0
  150. package/.cache/typescript/5.0/node_modules/@types/qs/package.json +65 -0
  151. package/.cache/typescript/5.0/node_modules/@types/range-parser/LICENSE +21 -0
  152. package/.cache/typescript/5.0/node_modules/@types/range-parser/README.md +53 -0
  153. package/.cache/typescript/5.0/node_modules/@types/range-parser/index.d.ts +34 -0
  154. package/.cache/typescript/5.0/node_modules/@types/range-parser/package.json +25 -0
  155. package/.cache/typescript/5.0/node_modules/@types/send/LICENSE +21 -0
  156. package/.cache/typescript/5.0/node_modules/@types/send/README.md +15 -0
  157. package/.cache/typescript/5.0/node_modules/@types/send/index.d.ts +225 -0
  158. package/.cache/typescript/5.0/node_modules/@types/send/package.json +33 -0
  159. package/.cache/typescript/5.0/node_modules/@types/serve-static/LICENSE +21 -0
  160. package/.cache/typescript/5.0/node_modules/@types/serve-static/README.md +15 -0
  161. package/.cache/typescript/5.0/node_modules/@types/serve-static/index.d.ts +107 -0
  162. package/.cache/typescript/5.0/node_modules/@types/serve-static/package.json +39 -0
  163. package/.cache/typescript/5.0/node_modules/@types/tough-cookie/LICENSE +21 -0
  164. package/.cache/typescript/5.0/node_modules/@types/tough-cookie/README.md +15 -0
  165. package/.cache/typescript/5.0/node_modules/@types/tough-cookie/index.d.ts +321 -0
  166. package/.cache/typescript/5.0/node_modules/@types/tough-cookie/package.json +35 -0
  167. package/.cache/typescript/5.0/node_modules/entities/LICENSE +11 -0
  168. package/.cache/typescript/5.0/node_modules/entities/lib/decode.d.ts +211 -0
  169. package/.cache/typescript/5.0/node_modules/entities/lib/decode.d.ts.map +1 -0
  170. package/.cache/typescript/5.0/node_modules/entities/lib/decode.js +536 -0
  171. package/.cache/typescript/5.0/node_modules/entities/lib/decode.js.map +1 -0
  172. package/.cache/typescript/5.0/node_modules/entities/lib/decode_codepoint.d.ts +19 -0
  173. package/.cache/typescript/5.0/node_modules/entities/lib/decode_codepoint.d.ts.map +1 -0
  174. package/.cache/typescript/5.0/node_modules/entities/lib/decode_codepoint.js +76 -0
  175. package/.cache/typescript/5.0/node_modules/entities/lib/decode_codepoint.js.map +1 -0
  176. package/.cache/typescript/5.0/node_modules/entities/lib/encode.d.ts +22 -0
  177. package/.cache/typescript/5.0/node_modules/entities/lib/encode.d.ts.map +1 -0
  178. package/.cache/typescript/5.0/node_modules/entities/lib/encode.js +77 -0
  179. package/.cache/typescript/5.0/node_modules/entities/lib/encode.js.map +1 -0
  180. package/.cache/typescript/5.0/node_modules/entities/lib/escape.d.ts +43 -0
  181. package/.cache/typescript/5.0/node_modules/entities/lib/escape.d.ts.map +1 -0
  182. package/.cache/typescript/5.0/node_modules/entities/lib/escape.js +122 -0
  183. package/.cache/typescript/5.0/node_modules/entities/lib/escape.js.map +1 -0
  184. package/.cache/typescript/5.0/node_modules/entities/lib/esm/decode.d.ts +211 -0
  185. package/.cache/typescript/5.0/node_modules/entities/lib/esm/decode.d.ts.map +1 -0
  186. package/.cache/typescript/5.0/node_modules/entities/lib/esm/decode.js +496 -0
  187. package/.cache/typescript/5.0/node_modules/entities/lib/esm/decode.js.map +1 -0
  188. package/.cache/typescript/5.0/node_modules/entities/lib/esm/decode_codepoint.d.ts +19 -0
  189. package/.cache/typescript/5.0/node_modules/entities/lib/esm/decode_codepoint.d.ts.map +1 -0
  190. package/.cache/typescript/5.0/node_modules/entities/lib/esm/decode_codepoint.js +71 -0
  191. package/.cache/typescript/5.0/node_modules/entities/lib/esm/decode_codepoint.js.map +1 -0
  192. package/.cache/typescript/5.0/node_modules/entities/lib/esm/encode.d.ts +22 -0
  193. package/.cache/typescript/5.0/node_modules/entities/lib/esm/encode.d.ts.map +1 -0
  194. package/.cache/typescript/5.0/node_modules/entities/lib/esm/encode.js +69 -0
  195. package/.cache/typescript/5.0/node_modules/entities/lib/esm/encode.js.map +1 -0
  196. package/.cache/typescript/5.0/node_modules/entities/lib/esm/escape.d.ts +43 -0
  197. package/.cache/typescript/5.0/node_modules/entities/lib/esm/escape.d.ts.map +1 -0
  198. package/.cache/typescript/5.0/node_modules/entities/lib/esm/escape.js +116 -0
  199. package/.cache/typescript/5.0/node_modules/entities/lib/esm/escape.js.map +1 -0
  200. package/.cache/typescript/5.0/node_modules/entities/lib/esm/generated/decode-data-html.d.ts +3 -0
  201. package/.cache/typescript/5.0/node_modules/entities/lib/esm/generated/decode-data-html.d.ts.map +1 -0
  202. package/.cache/typescript/5.0/node_modules/entities/lib/esm/generated/decode-data-html.js +7 -0
  203. package/.cache/typescript/5.0/node_modules/entities/lib/esm/generated/decode-data-html.js.map +1 -0
  204. package/.cache/typescript/5.0/node_modules/entities/lib/esm/generated/decode-data-xml.d.ts +3 -0
  205. package/.cache/typescript/5.0/node_modules/entities/lib/esm/generated/decode-data-xml.d.ts.map +1 -0
  206. package/.cache/typescript/5.0/node_modules/entities/lib/esm/generated/decode-data-xml.js +7 -0
  207. package/.cache/typescript/5.0/node_modules/entities/lib/esm/generated/decode-data-xml.js.map +1 -0
  208. package/.cache/typescript/5.0/node_modules/entities/lib/esm/generated/encode-html.d.ts +8 -0
  209. package/.cache/typescript/5.0/node_modules/entities/lib/esm/generated/encode-html.d.ts.map +1 -0
  210. package/.cache/typescript/5.0/node_modules/entities/lib/esm/generated/encode-html.js +10 -0
  211. package/.cache/typescript/5.0/node_modules/entities/lib/esm/generated/encode-html.js.map +1 -0
  212. package/.cache/typescript/5.0/node_modules/entities/lib/esm/index.d.ts +96 -0
  213. package/.cache/typescript/5.0/node_modules/entities/lib/esm/index.d.ts.map +1 -0
  214. package/.cache/typescript/5.0/node_modules/entities/lib/esm/index.js +99 -0
  215. package/.cache/typescript/5.0/node_modules/entities/lib/esm/index.js.map +1 -0
  216. package/.cache/typescript/5.0/node_modules/entities/lib/esm/package.json +1 -0
  217. package/.cache/typescript/5.0/node_modules/entities/lib/generated/decode-data-html.d.ts +3 -0
  218. package/.cache/typescript/5.0/node_modules/entities/lib/generated/decode-data-html.d.ts.map +1 -0
  219. package/.cache/typescript/5.0/node_modules/entities/lib/generated/decode-data-html.js +9 -0
  220. package/.cache/typescript/5.0/node_modules/entities/lib/generated/decode-data-html.js.map +1 -0
  221. package/.cache/typescript/5.0/node_modules/entities/lib/generated/decode-data-xml.d.ts +3 -0
  222. package/.cache/typescript/5.0/node_modules/entities/lib/generated/decode-data-xml.d.ts.map +1 -0
  223. package/.cache/typescript/5.0/node_modules/entities/lib/generated/decode-data-xml.js +9 -0
  224. package/.cache/typescript/5.0/node_modules/entities/lib/generated/decode-data-xml.js.map +1 -0
  225. package/.cache/typescript/5.0/node_modules/entities/lib/generated/encode-html.d.ts +8 -0
  226. package/.cache/typescript/5.0/node_modules/entities/lib/generated/encode-html.d.ts.map +1 -0
  227. package/.cache/typescript/5.0/node_modules/entities/lib/generated/encode-html.js +12 -0
  228. package/.cache/typescript/5.0/node_modules/entities/lib/generated/encode-html.js.map +1 -0
  229. package/.cache/typescript/5.0/node_modules/entities/lib/index.d.ts +96 -0
  230. package/.cache/typescript/5.0/node_modules/entities/lib/index.d.ts.map +1 -0
  231. package/.cache/typescript/5.0/node_modules/entities/lib/index.js +126 -0
  232. package/.cache/typescript/5.0/node_modules/entities/lib/index.js.map +1 -0
  233. package/.cache/typescript/5.0/node_modules/entities/package.json +90 -0
  234. package/.cache/typescript/5.0/node_modules/entities/readme.md +122 -0
  235. package/.cache/typescript/5.0/node_modules/parse5/LICENSE +19 -0
  236. package/.cache/typescript/5.0/node_modules/parse5/README.md +38 -0
  237. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/common/doctype.d.ts +5 -0
  238. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/common/doctype.js +120 -0
  239. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/common/error-codes.d.ts +68 -0
  240. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/common/error-codes.js +67 -0
  241. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/common/foreign-content.d.ts +10 -0
  242. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/common/foreign-content.js +239 -0
  243. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/common/html.d.ts +288 -0
  244. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/common/html.js +529 -0
  245. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/common/token.d.ts +85 -0
  246. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/common/token.js +25 -0
  247. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/common/unicode.d.ts +49 -0
  248. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/common/unicode.js +77 -0
  249. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/index.d.ts +60 -0
  250. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/index.js +57 -0
  251. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/package.json +1 -0
  252. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/parser/formatting-element-list.d.ts +37 -0
  253. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/parser/formatting-element-list.js +115 -0
  254. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/parser/index.d.ts +157 -0
  255. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/parser/index.js +3163 -0
  256. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/parser/open-element-stack.d.ts +53 -0
  257. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/parser/open-element-stack.js +316 -0
  258. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/serializer/index.d.ts +61 -0
  259. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/serializer/index.js +173 -0
  260. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/tokenizer/index.d.ts +248 -0
  261. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/tokenizer/index.js +2908 -0
  262. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/tokenizer/preprocessor.d.ts +37 -0
  263. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/tokenizer/preprocessor.js +199 -0
  264. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/tree-adapters/default.d.ts +85 -0
  265. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/tree-adapters/default.js +177 -0
  266. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/tree-adapters/interface.d.ts +250 -0
  267. package/.cache/typescript/5.0/node_modules/parse5/dist/cjs/tree-adapters/interface.js +3 -0
  268. package/.cache/typescript/5.0/node_modules/parse5/dist/common/doctype.d.ts +5 -0
  269. package/.cache/typescript/5.0/node_modules/parse5/dist/common/doctype.js +115 -0
  270. package/.cache/typescript/5.0/node_modules/parse5/dist/common/error-codes.d.ts +68 -0
  271. package/.cache/typescript/5.0/node_modules/parse5/dist/common/error-codes.js +64 -0
  272. package/.cache/typescript/5.0/node_modules/parse5/dist/common/foreign-content.d.ts +10 -0
  273. package/.cache/typescript/5.0/node_modules/parse5/dist/common/foreign-content.js +230 -0
  274. package/.cache/typescript/5.0/node_modules/parse5/dist/common/html.d.ts +288 -0
  275. package/.cache/typescript/5.0/node_modules/parse5/dist/common/html.js +523 -0
  276. package/.cache/typescript/5.0/node_modules/parse5/dist/common/token.d.ts +85 -0
  277. package/.cache/typescript/5.0/node_modules/parse5/dist/common/token.js +21 -0
  278. package/.cache/typescript/5.0/node_modules/parse5/dist/common/unicode.d.ts +49 -0
  279. package/.cache/typescript/5.0/node_modules/parse5/dist/common/unicode.js +69 -0
  280. package/.cache/typescript/5.0/node_modules/parse5/dist/index.d.ts +60 -0
  281. package/.cache/typescript/5.0/node_modules/parse5/dist/index.js +45 -0
  282. package/.cache/typescript/5.0/node_modules/parse5/dist/parser/formatting-element-list.d.ts +37 -0
  283. package/.cache/typescript/5.0/node_modules/parse5/dist/parser/formatting-element-list.js +111 -0
  284. package/.cache/typescript/5.0/node_modules/parse5/dist/parser/index.d.ts +157 -0
  285. package/.cache/typescript/5.0/node_modules/parse5/dist/parser/index.js +3168 -0
  286. package/.cache/typescript/5.0/node_modules/parse5/dist/parser/open-element-stack.d.ts +53 -0
  287. package/.cache/typescript/5.0/node_modules/parse5/dist/parser/open-element-stack.js +312 -0
  288. package/.cache/typescript/5.0/node_modules/parse5/dist/serializer/index.d.ts +61 -0
  289. package/.cache/typescript/5.0/node_modules/parse5/dist/serializer/index.js +168 -0
  290. package/.cache/typescript/5.0/node_modules/parse5/dist/tokenizer/index.d.ts +248 -0
  291. package/.cache/typescript/5.0/node_modules/parse5/dist/tokenizer/index.js +2904 -0
  292. package/.cache/typescript/5.0/node_modules/parse5/dist/tokenizer/preprocessor.d.ts +37 -0
  293. package/.cache/typescript/5.0/node_modules/parse5/dist/tokenizer/preprocessor.js +195 -0
  294. package/.cache/typescript/5.0/node_modules/parse5/dist/tree-adapters/default.d.ts +85 -0
  295. package/.cache/typescript/5.0/node_modules/parse5/dist/tree-adapters/default.js +174 -0
  296. package/.cache/typescript/5.0/node_modules/parse5/dist/tree-adapters/interface.d.ts +250 -0
  297. package/.cache/typescript/5.0/node_modules/parse5/dist/tree-adapters/interface.js +2 -0
  298. package/.cache/typescript/5.0/node_modules/parse5/package.json +50 -0
  299. package/.cache/typescript/5.0/node_modules/types-registry/README.md +2 -0
  300. package/.cache/typescript/5.0/node_modules/types-registry/index.json +1 -0
  301. package/.cache/typescript/5.0/node_modules/types-registry/package.json +20 -0
  302. package/.cache/typescript/5.0/node_modules/undici-types/README.md +6 -0
  303. package/.cache/typescript/5.0/node_modules/undici-types/agent.d.ts +31 -0
  304. package/.cache/typescript/5.0/node_modules/undici-types/api.d.ts +43 -0
  305. package/.cache/typescript/5.0/node_modules/undici-types/balanced-pool.d.ts +18 -0
  306. package/.cache/typescript/5.0/node_modules/undici-types/cache.d.ts +36 -0
  307. package/.cache/typescript/5.0/node_modules/undici-types/client.d.ts +97 -0
  308. package/.cache/typescript/5.0/node_modules/undici-types/connector.d.ts +34 -0
  309. package/.cache/typescript/5.0/node_modules/undici-types/content-type.d.ts +21 -0
  310. package/.cache/typescript/5.0/node_modules/undici-types/cookies.d.ts +28 -0
  311. package/.cache/typescript/5.0/node_modules/undici-types/diagnostics-channel.d.ts +67 -0
  312. package/.cache/typescript/5.0/node_modules/undici-types/dispatcher.d.ts +241 -0
  313. package/.cache/typescript/5.0/node_modules/undici-types/errors.d.ts +128 -0
  314. package/.cache/typescript/5.0/node_modules/undici-types/fetch.d.ts +209 -0
  315. package/.cache/typescript/5.0/node_modules/undici-types/file.d.ts +39 -0
  316. package/.cache/typescript/5.0/node_modules/undici-types/filereader.d.ts +54 -0
  317. package/.cache/typescript/5.0/node_modules/undici-types/formdata.d.ts +108 -0
  318. package/.cache/typescript/5.0/node_modules/undici-types/global-dispatcher.d.ts +9 -0
  319. package/.cache/typescript/5.0/node_modules/undici-types/global-origin.d.ts +7 -0
  320. package/.cache/typescript/5.0/node_modules/undici-types/handlers.d.ts +9 -0
  321. package/.cache/typescript/5.0/node_modules/undici-types/header.d.ts +4 -0
  322. package/.cache/typescript/5.0/node_modules/undici-types/index.d.ts +63 -0
  323. package/.cache/typescript/5.0/node_modules/undici-types/interceptors.d.ts +5 -0
  324. package/.cache/typescript/5.0/node_modules/undici-types/mock-agent.d.ts +50 -0
  325. package/.cache/typescript/5.0/node_modules/undici-types/mock-client.d.ts +25 -0
  326. package/.cache/typescript/5.0/node_modules/undici-types/mock-errors.d.ts +12 -0
  327. package/.cache/typescript/5.0/node_modules/undici-types/mock-interceptor.d.ts +93 -0
  328. package/.cache/typescript/5.0/node_modules/undici-types/mock-pool.d.ts +25 -0
  329. package/.cache/typescript/5.0/node_modules/undici-types/package.json +55 -0
  330. package/.cache/typescript/5.0/node_modules/undici-types/patch.d.ts +71 -0
  331. package/.cache/typescript/5.0/node_modules/undici-types/pool-stats.d.ts +19 -0
  332. package/.cache/typescript/5.0/node_modules/undici-types/pool.d.ts +28 -0
  333. package/.cache/typescript/5.0/node_modules/undici-types/proxy-agent.d.ts +30 -0
  334. package/.cache/typescript/5.0/node_modules/undici-types/readable.d.ts +61 -0
  335. package/.cache/typescript/5.0/node_modules/undici-types/webidl.d.ts +220 -0
  336. package/.cache/typescript/5.0/node_modules/undici-types/websocket.d.ts +131 -0
  337. package/.cache/typescript/5.0/package-lock.json +166 -0
  338. package/.cache/typescript/5.0/package.json +1 -0
  339. package/.replit +14 -0
  340. package/.upm/store.json +1 -0
  341. package/README.md +24 -0
  342. package/index.js +1 -0
  343. package/package.json +21 -0
@@ -0,0 +1,120 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getDocumentMode = exports.isConforming = void 0;
4
+ const html_js_1 = require("./html.js");
5
+ //Const
6
+ const VALID_DOCTYPE_NAME = 'html';
7
+ const VALID_SYSTEM_ID = 'about:legacy-compat';
8
+ const QUIRKS_MODE_SYSTEM_ID = 'http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd';
9
+ const QUIRKS_MODE_PUBLIC_ID_PREFIXES = [
10
+ '+//silmaril//dtd html pro v0r11 19970101//',
11
+ '-//as//dtd html 3.0 aswedit + extensions//',
12
+ '-//advasoft ltd//dtd html 3.0 aswedit + extensions//',
13
+ '-//ietf//dtd html 2.0 level 1//',
14
+ '-//ietf//dtd html 2.0 level 2//',
15
+ '-//ietf//dtd html 2.0 strict level 1//',
16
+ '-//ietf//dtd html 2.0 strict level 2//',
17
+ '-//ietf//dtd html 2.0 strict//',
18
+ '-//ietf//dtd html 2.0//',
19
+ '-//ietf//dtd html 2.1e//',
20
+ '-//ietf//dtd html 3.0//',
21
+ '-//ietf//dtd html 3.2 final//',
22
+ '-//ietf//dtd html 3.2//',
23
+ '-//ietf//dtd html 3//',
24
+ '-//ietf//dtd html level 0//',
25
+ '-//ietf//dtd html level 1//',
26
+ '-//ietf//dtd html level 2//',
27
+ '-//ietf//dtd html level 3//',
28
+ '-//ietf//dtd html strict level 0//',
29
+ '-//ietf//dtd html strict level 1//',
30
+ '-//ietf//dtd html strict level 2//',
31
+ '-//ietf//dtd html strict level 3//',
32
+ '-//ietf//dtd html strict//',
33
+ '-//ietf//dtd html//',
34
+ '-//metrius//dtd metrius presentational//',
35
+ '-//microsoft//dtd internet explorer 2.0 html strict//',
36
+ '-//microsoft//dtd internet explorer 2.0 html//',
37
+ '-//microsoft//dtd internet explorer 2.0 tables//',
38
+ '-//microsoft//dtd internet explorer 3.0 html strict//',
39
+ '-//microsoft//dtd internet explorer 3.0 html//',
40
+ '-//microsoft//dtd internet explorer 3.0 tables//',
41
+ '-//netscape comm. corp.//dtd html//',
42
+ '-//netscape comm. corp.//dtd strict html//',
43
+ "-//o'reilly and associates//dtd html 2.0//",
44
+ "-//o'reilly and associates//dtd html extended 1.0//",
45
+ "-//o'reilly and associates//dtd html extended relaxed 1.0//",
46
+ '-//sq//dtd html 2.0 hotmetal + extensions//',
47
+ '-//softquad software//dtd hotmetal pro 6.0::19990601::extensions to html 4.0//',
48
+ '-//softquad//dtd hotmetal pro 4.0::19971010::extensions to html 4.0//',
49
+ '-//spyglass//dtd html 2.0 extended//',
50
+ '-//sun microsystems corp.//dtd hotjava html//',
51
+ '-//sun microsystems corp.//dtd hotjava strict html//',
52
+ '-//w3c//dtd html 3 1995-03-24//',
53
+ '-//w3c//dtd html 3.2 draft//',
54
+ '-//w3c//dtd html 3.2 final//',
55
+ '-//w3c//dtd html 3.2//',
56
+ '-//w3c//dtd html 3.2s draft//',
57
+ '-//w3c//dtd html 4.0 frameset//',
58
+ '-//w3c//dtd html 4.0 transitional//',
59
+ '-//w3c//dtd html experimental 19960712//',
60
+ '-//w3c//dtd html experimental 970421//',
61
+ '-//w3c//dtd w3 html//',
62
+ '-//w3o//dtd w3 html 3.0//',
63
+ '-//webtechs//dtd mozilla html 2.0//',
64
+ '-//webtechs//dtd mozilla html//',
65
+ ];
66
+ const QUIRKS_MODE_NO_SYSTEM_ID_PUBLIC_ID_PREFIXES = [
67
+ ...QUIRKS_MODE_PUBLIC_ID_PREFIXES,
68
+ '-//w3c//dtd html 4.01 frameset//',
69
+ '-//w3c//dtd html 4.01 transitional//',
70
+ ];
71
+ const QUIRKS_MODE_PUBLIC_IDS = new Set([
72
+ '-//w3o//dtd w3 html strict 3.0//en//',
73
+ '-/w3c/dtd html 4.0 transitional/en',
74
+ 'html',
75
+ ]);
76
+ const LIMITED_QUIRKS_PUBLIC_ID_PREFIXES = ['-//w3c//dtd xhtml 1.0 frameset//', '-//w3c//dtd xhtml 1.0 transitional//'];
77
+ const LIMITED_QUIRKS_WITH_SYSTEM_ID_PUBLIC_ID_PREFIXES = [
78
+ ...LIMITED_QUIRKS_PUBLIC_ID_PREFIXES,
79
+ '-//w3c//dtd html 4.01 frameset//',
80
+ '-//w3c//dtd html 4.01 transitional//',
81
+ ];
82
+ //Utils
83
+ function hasPrefix(publicId, prefixes) {
84
+ return prefixes.some((prefix) => publicId.startsWith(prefix));
85
+ }
86
+ //API
87
+ function isConforming(token) {
88
+ return (token.name === VALID_DOCTYPE_NAME &&
89
+ token.publicId === null &&
90
+ (token.systemId === null || token.systemId === VALID_SYSTEM_ID));
91
+ }
92
+ exports.isConforming = isConforming;
93
+ function getDocumentMode(token) {
94
+ if (token.name !== VALID_DOCTYPE_NAME) {
95
+ return html_js_1.DOCUMENT_MODE.QUIRKS;
96
+ }
97
+ const { systemId } = token;
98
+ if (systemId && systemId.toLowerCase() === QUIRKS_MODE_SYSTEM_ID) {
99
+ return html_js_1.DOCUMENT_MODE.QUIRKS;
100
+ }
101
+ let { publicId } = token;
102
+ if (publicId !== null) {
103
+ publicId = publicId.toLowerCase();
104
+ if (QUIRKS_MODE_PUBLIC_IDS.has(publicId)) {
105
+ return html_js_1.DOCUMENT_MODE.QUIRKS;
106
+ }
107
+ let prefixes = systemId === null ? QUIRKS_MODE_NO_SYSTEM_ID_PUBLIC_ID_PREFIXES : QUIRKS_MODE_PUBLIC_ID_PREFIXES;
108
+ if (hasPrefix(publicId, prefixes)) {
109
+ return html_js_1.DOCUMENT_MODE.QUIRKS;
110
+ }
111
+ prefixes =
112
+ systemId === null ? LIMITED_QUIRKS_PUBLIC_ID_PREFIXES : LIMITED_QUIRKS_WITH_SYSTEM_ID_PUBLIC_ID_PREFIXES;
113
+ if (hasPrefix(publicId, prefixes)) {
114
+ return html_js_1.DOCUMENT_MODE.LIMITED_QUIRKS;
115
+ }
116
+ }
117
+ return html_js_1.DOCUMENT_MODE.NO_QUIRKS;
118
+ }
119
+ exports.getDocumentMode = getDocumentMode;
120
+ //# sourceMappingURL=doctype.js.map
@@ -0,0 +1,68 @@
1
+ import type { Location } from './token.js';
2
+ export interface ParserError extends Location {
3
+ code: ERR;
4
+ }
5
+ export type ParserErrorHandler = (error: ParserError) => void;
6
+ export declare enum ERR {
7
+ controlCharacterInInputStream = "control-character-in-input-stream",
8
+ noncharacterInInputStream = "noncharacter-in-input-stream",
9
+ surrogateInInputStream = "surrogate-in-input-stream",
10
+ nonVoidHtmlElementStartTagWithTrailingSolidus = "non-void-html-element-start-tag-with-trailing-solidus",
11
+ endTagWithAttributes = "end-tag-with-attributes",
12
+ endTagWithTrailingSolidus = "end-tag-with-trailing-solidus",
13
+ unexpectedSolidusInTag = "unexpected-solidus-in-tag",
14
+ unexpectedNullCharacter = "unexpected-null-character",
15
+ unexpectedQuestionMarkInsteadOfTagName = "unexpected-question-mark-instead-of-tag-name",
16
+ invalidFirstCharacterOfTagName = "invalid-first-character-of-tag-name",
17
+ unexpectedEqualsSignBeforeAttributeName = "unexpected-equals-sign-before-attribute-name",
18
+ missingEndTagName = "missing-end-tag-name",
19
+ unexpectedCharacterInAttributeName = "unexpected-character-in-attribute-name",
20
+ unknownNamedCharacterReference = "unknown-named-character-reference",
21
+ missingSemicolonAfterCharacterReference = "missing-semicolon-after-character-reference",
22
+ unexpectedCharacterAfterDoctypeSystemIdentifier = "unexpected-character-after-doctype-system-identifier",
23
+ unexpectedCharacterInUnquotedAttributeValue = "unexpected-character-in-unquoted-attribute-value",
24
+ eofBeforeTagName = "eof-before-tag-name",
25
+ eofInTag = "eof-in-tag",
26
+ missingAttributeValue = "missing-attribute-value",
27
+ missingWhitespaceBetweenAttributes = "missing-whitespace-between-attributes",
28
+ missingWhitespaceAfterDoctypePublicKeyword = "missing-whitespace-after-doctype-public-keyword",
29
+ missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers = "missing-whitespace-between-doctype-public-and-system-identifiers",
30
+ missingWhitespaceAfterDoctypeSystemKeyword = "missing-whitespace-after-doctype-system-keyword",
31
+ missingQuoteBeforeDoctypePublicIdentifier = "missing-quote-before-doctype-public-identifier",
32
+ missingQuoteBeforeDoctypeSystemIdentifier = "missing-quote-before-doctype-system-identifier",
33
+ missingDoctypePublicIdentifier = "missing-doctype-public-identifier",
34
+ missingDoctypeSystemIdentifier = "missing-doctype-system-identifier",
35
+ abruptDoctypePublicIdentifier = "abrupt-doctype-public-identifier",
36
+ abruptDoctypeSystemIdentifier = "abrupt-doctype-system-identifier",
37
+ cdataInHtmlContent = "cdata-in-html-content",
38
+ incorrectlyOpenedComment = "incorrectly-opened-comment",
39
+ eofInScriptHtmlCommentLikeText = "eof-in-script-html-comment-like-text",
40
+ eofInDoctype = "eof-in-doctype",
41
+ nestedComment = "nested-comment",
42
+ abruptClosingOfEmptyComment = "abrupt-closing-of-empty-comment",
43
+ eofInComment = "eof-in-comment",
44
+ incorrectlyClosedComment = "incorrectly-closed-comment",
45
+ eofInCdata = "eof-in-cdata",
46
+ absenceOfDigitsInNumericCharacterReference = "absence-of-digits-in-numeric-character-reference",
47
+ nullCharacterReference = "null-character-reference",
48
+ surrogateCharacterReference = "surrogate-character-reference",
49
+ characterReferenceOutsideUnicodeRange = "character-reference-outside-unicode-range",
50
+ controlCharacterReference = "control-character-reference",
51
+ noncharacterCharacterReference = "noncharacter-character-reference",
52
+ missingWhitespaceBeforeDoctypeName = "missing-whitespace-before-doctype-name",
53
+ missingDoctypeName = "missing-doctype-name",
54
+ invalidCharacterSequenceAfterDoctypeName = "invalid-character-sequence-after-doctype-name",
55
+ duplicateAttribute = "duplicate-attribute",
56
+ nonConformingDoctype = "non-conforming-doctype",
57
+ missingDoctype = "missing-doctype",
58
+ misplacedDoctype = "misplaced-doctype",
59
+ endTagWithoutMatchingOpenElement = "end-tag-without-matching-open-element",
60
+ closingOfElementWithOpenChildElements = "closing-of-element-with-open-child-elements",
61
+ disallowedContentInNoscriptInHead = "disallowed-content-in-noscript-in-head",
62
+ openElementsLeftAfterEof = "open-elements-left-after-eof",
63
+ abandonedHeadElementChild = "abandoned-head-element-child",
64
+ misplacedStartTagForHeadElement = "misplaced-start-tag-for-head-element",
65
+ nestedNoscriptInHead = "nested-noscript-in-head",
66
+ eofInElementThatCanContainOnlyText = "eof-in-element-that-can-contain-only-text"
67
+ }
68
+ //# sourceMappingURL=error-codes.d.ts.map
@@ -0,0 +1,67 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ERR = void 0;
4
+ var ERR;
5
+ (function (ERR) {
6
+ ERR["controlCharacterInInputStream"] = "control-character-in-input-stream";
7
+ ERR["noncharacterInInputStream"] = "noncharacter-in-input-stream";
8
+ ERR["surrogateInInputStream"] = "surrogate-in-input-stream";
9
+ ERR["nonVoidHtmlElementStartTagWithTrailingSolidus"] = "non-void-html-element-start-tag-with-trailing-solidus";
10
+ ERR["endTagWithAttributes"] = "end-tag-with-attributes";
11
+ ERR["endTagWithTrailingSolidus"] = "end-tag-with-trailing-solidus";
12
+ ERR["unexpectedSolidusInTag"] = "unexpected-solidus-in-tag";
13
+ ERR["unexpectedNullCharacter"] = "unexpected-null-character";
14
+ ERR["unexpectedQuestionMarkInsteadOfTagName"] = "unexpected-question-mark-instead-of-tag-name";
15
+ ERR["invalidFirstCharacterOfTagName"] = "invalid-first-character-of-tag-name";
16
+ ERR["unexpectedEqualsSignBeforeAttributeName"] = "unexpected-equals-sign-before-attribute-name";
17
+ ERR["missingEndTagName"] = "missing-end-tag-name";
18
+ ERR["unexpectedCharacterInAttributeName"] = "unexpected-character-in-attribute-name";
19
+ ERR["unknownNamedCharacterReference"] = "unknown-named-character-reference";
20
+ ERR["missingSemicolonAfterCharacterReference"] = "missing-semicolon-after-character-reference";
21
+ ERR["unexpectedCharacterAfterDoctypeSystemIdentifier"] = "unexpected-character-after-doctype-system-identifier";
22
+ ERR["unexpectedCharacterInUnquotedAttributeValue"] = "unexpected-character-in-unquoted-attribute-value";
23
+ ERR["eofBeforeTagName"] = "eof-before-tag-name";
24
+ ERR["eofInTag"] = "eof-in-tag";
25
+ ERR["missingAttributeValue"] = "missing-attribute-value";
26
+ ERR["missingWhitespaceBetweenAttributes"] = "missing-whitespace-between-attributes";
27
+ ERR["missingWhitespaceAfterDoctypePublicKeyword"] = "missing-whitespace-after-doctype-public-keyword";
28
+ ERR["missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers"] = "missing-whitespace-between-doctype-public-and-system-identifiers";
29
+ ERR["missingWhitespaceAfterDoctypeSystemKeyword"] = "missing-whitespace-after-doctype-system-keyword";
30
+ ERR["missingQuoteBeforeDoctypePublicIdentifier"] = "missing-quote-before-doctype-public-identifier";
31
+ ERR["missingQuoteBeforeDoctypeSystemIdentifier"] = "missing-quote-before-doctype-system-identifier";
32
+ ERR["missingDoctypePublicIdentifier"] = "missing-doctype-public-identifier";
33
+ ERR["missingDoctypeSystemIdentifier"] = "missing-doctype-system-identifier";
34
+ ERR["abruptDoctypePublicIdentifier"] = "abrupt-doctype-public-identifier";
35
+ ERR["abruptDoctypeSystemIdentifier"] = "abrupt-doctype-system-identifier";
36
+ ERR["cdataInHtmlContent"] = "cdata-in-html-content";
37
+ ERR["incorrectlyOpenedComment"] = "incorrectly-opened-comment";
38
+ ERR["eofInScriptHtmlCommentLikeText"] = "eof-in-script-html-comment-like-text";
39
+ ERR["eofInDoctype"] = "eof-in-doctype";
40
+ ERR["nestedComment"] = "nested-comment";
41
+ ERR["abruptClosingOfEmptyComment"] = "abrupt-closing-of-empty-comment";
42
+ ERR["eofInComment"] = "eof-in-comment";
43
+ ERR["incorrectlyClosedComment"] = "incorrectly-closed-comment";
44
+ ERR["eofInCdata"] = "eof-in-cdata";
45
+ ERR["absenceOfDigitsInNumericCharacterReference"] = "absence-of-digits-in-numeric-character-reference";
46
+ ERR["nullCharacterReference"] = "null-character-reference";
47
+ ERR["surrogateCharacterReference"] = "surrogate-character-reference";
48
+ ERR["characterReferenceOutsideUnicodeRange"] = "character-reference-outside-unicode-range";
49
+ ERR["controlCharacterReference"] = "control-character-reference";
50
+ ERR["noncharacterCharacterReference"] = "noncharacter-character-reference";
51
+ ERR["missingWhitespaceBeforeDoctypeName"] = "missing-whitespace-before-doctype-name";
52
+ ERR["missingDoctypeName"] = "missing-doctype-name";
53
+ ERR["invalidCharacterSequenceAfterDoctypeName"] = "invalid-character-sequence-after-doctype-name";
54
+ ERR["duplicateAttribute"] = "duplicate-attribute";
55
+ ERR["nonConformingDoctype"] = "non-conforming-doctype";
56
+ ERR["missingDoctype"] = "missing-doctype";
57
+ ERR["misplacedDoctype"] = "misplaced-doctype";
58
+ ERR["endTagWithoutMatchingOpenElement"] = "end-tag-without-matching-open-element";
59
+ ERR["closingOfElementWithOpenChildElements"] = "closing-of-element-with-open-child-elements";
60
+ ERR["disallowedContentInNoscriptInHead"] = "disallowed-content-in-noscript-in-head";
61
+ ERR["openElementsLeftAfterEof"] = "open-elements-left-after-eof";
62
+ ERR["abandonedHeadElementChild"] = "abandoned-head-element-child";
63
+ ERR["misplacedStartTagForHeadElement"] = "misplaced-start-tag-for-head-element";
64
+ ERR["nestedNoscriptInHead"] = "nested-noscript-in-head";
65
+ ERR["eofInElementThatCanContainOnlyText"] = "eof-in-element-that-can-contain-only-text";
66
+ })(ERR = exports.ERR || (exports.ERR = {}));
67
+ //# sourceMappingURL=error-codes.js.map
@@ -0,0 +1,10 @@
1
+ import { TAG_ID as $, NS } from './html.js';
2
+ import type { TagToken, Attribute } from './token.js';
3
+ export declare const SVG_TAG_NAMES_ADJUSTMENT_MAP: Map<string, string>;
4
+ export declare function causesExit(startTagToken: TagToken): boolean;
5
+ export declare function adjustTokenMathMLAttrs(token: TagToken): void;
6
+ export declare function adjustTokenSVGAttrs(token: TagToken): void;
7
+ export declare function adjustTokenXMLAttrs(token: TagToken): void;
8
+ export declare function adjustTokenSVGTagName(token: TagToken): void;
9
+ export declare function isIntegrationPoint(tn: $, ns: NS, attrs: Attribute[], foreignNS?: NS): boolean;
10
+ //# sourceMappingURL=foreign-content.d.ts.map
@@ -0,0 +1,239 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.isIntegrationPoint = exports.adjustTokenSVGTagName = exports.adjustTokenXMLAttrs = exports.adjustTokenSVGAttrs = exports.adjustTokenMathMLAttrs = exports.causesExit = exports.SVG_TAG_NAMES_ADJUSTMENT_MAP = void 0;
4
+ const html_js_1 = require("./html.js");
5
+ //MIME types
6
+ const MIME_TYPES = {
7
+ TEXT_HTML: 'text/html',
8
+ APPLICATION_XML: 'application/xhtml+xml',
9
+ };
10
+ //Attributes
11
+ const DEFINITION_URL_ATTR = 'definitionurl';
12
+ const ADJUSTED_DEFINITION_URL_ATTR = 'definitionURL';
13
+ const SVG_ATTRS_ADJUSTMENT_MAP = new Map([
14
+ 'attributeName',
15
+ 'attributeType',
16
+ 'baseFrequency',
17
+ 'baseProfile',
18
+ 'calcMode',
19
+ 'clipPathUnits',
20
+ 'diffuseConstant',
21
+ 'edgeMode',
22
+ 'filterUnits',
23
+ 'glyphRef',
24
+ 'gradientTransform',
25
+ 'gradientUnits',
26
+ 'kernelMatrix',
27
+ 'kernelUnitLength',
28
+ 'keyPoints',
29
+ 'keySplines',
30
+ 'keyTimes',
31
+ 'lengthAdjust',
32
+ 'limitingConeAngle',
33
+ 'markerHeight',
34
+ 'markerUnits',
35
+ 'markerWidth',
36
+ 'maskContentUnits',
37
+ 'maskUnits',
38
+ 'numOctaves',
39
+ 'pathLength',
40
+ 'patternContentUnits',
41
+ 'patternTransform',
42
+ 'patternUnits',
43
+ 'pointsAtX',
44
+ 'pointsAtY',
45
+ 'pointsAtZ',
46
+ 'preserveAlpha',
47
+ 'preserveAspectRatio',
48
+ 'primitiveUnits',
49
+ 'refX',
50
+ 'refY',
51
+ 'repeatCount',
52
+ 'repeatDur',
53
+ 'requiredExtensions',
54
+ 'requiredFeatures',
55
+ 'specularConstant',
56
+ 'specularExponent',
57
+ 'spreadMethod',
58
+ 'startOffset',
59
+ 'stdDeviation',
60
+ 'stitchTiles',
61
+ 'surfaceScale',
62
+ 'systemLanguage',
63
+ 'tableValues',
64
+ 'targetX',
65
+ 'targetY',
66
+ 'textLength',
67
+ 'viewBox',
68
+ 'viewTarget',
69
+ 'xChannelSelector',
70
+ 'yChannelSelector',
71
+ 'zoomAndPan',
72
+ ].map((attr) => [attr.toLowerCase(), attr]));
73
+ const XML_ATTRS_ADJUSTMENT_MAP = new Map([
74
+ ['xlink:actuate', { prefix: 'xlink', name: 'actuate', namespace: html_js_1.NS.XLINK }],
75
+ ['xlink:arcrole', { prefix: 'xlink', name: 'arcrole', namespace: html_js_1.NS.XLINK }],
76
+ ['xlink:href', { prefix: 'xlink', name: 'href', namespace: html_js_1.NS.XLINK }],
77
+ ['xlink:role', { prefix: 'xlink', name: 'role', namespace: html_js_1.NS.XLINK }],
78
+ ['xlink:show', { prefix: 'xlink', name: 'show', namespace: html_js_1.NS.XLINK }],
79
+ ['xlink:title', { prefix: 'xlink', name: 'title', namespace: html_js_1.NS.XLINK }],
80
+ ['xlink:type', { prefix: 'xlink', name: 'type', namespace: html_js_1.NS.XLINK }],
81
+ ['xml:base', { prefix: 'xml', name: 'base', namespace: html_js_1.NS.XML }],
82
+ ['xml:lang', { prefix: 'xml', name: 'lang', namespace: html_js_1.NS.XML }],
83
+ ['xml:space', { prefix: 'xml', name: 'space', namespace: html_js_1.NS.XML }],
84
+ ['xmlns', { prefix: '', name: 'xmlns', namespace: html_js_1.NS.XMLNS }],
85
+ ['xmlns:xlink', { prefix: 'xmlns', name: 'xlink', namespace: html_js_1.NS.XMLNS }],
86
+ ]);
87
+ //SVG tag names adjustment map
88
+ exports.SVG_TAG_NAMES_ADJUSTMENT_MAP = new Map([
89
+ 'altGlyph',
90
+ 'altGlyphDef',
91
+ 'altGlyphItem',
92
+ 'animateColor',
93
+ 'animateMotion',
94
+ 'animateTransform',
95
+ 'clipPath',
96
+ 'feBlend',
97
+ 'feColorMatrix',
98
+ 'feComponentTransfer',
99
+ 'feComposite',
100
+ 'feConvolveMatrix',
101
+ 'feDiffuseLighting',
102
+ 'feDisplacementMap',
103
+ 'feDistantLight',
104
+ 'feFlood',
105
+ 'feFuncA',
106
+ 'feFuncB',
107
+ 'feFuncG',
108
+ 'feFuncR',
109
+ 'feGaussianBlur',
110
+ 'feImage',
111
+ 'feMerge',
112
+ 'feMergeNode',
113
+ 'feMorphology',
114
+ 'feOffset',
115
+ 'fePointLight',
116
+ 'feSpecularLighting',
117
+ 'feSpotLight',
118
+ 'feTile',
119
+ 'feTurbulence',
120
+ 'foreignObject',
121
+ 'glyphRef',
122
+ 'linearGradient',
123
+ 'radialGradient',
124
+ 'textPath',
125
+ ].map((tn) => [tn.toLowerCase(), tn]));
126
+ //Tags that causes exit from foreign content
127
+ const EXITS_FOREIGN_CONTENT = new Set([
128
+ html_js_1.TAG_ID.B,
129
+ html_js_1.TAG_ID.BIG,
130
+ html_js_1.TAG_ID.BLOCKQUOTE,
131
+ html_js_1.TAG_ID.BODY,
132
+ html_js_1.TAG_ID.BR,
133
+ html_js_1.TAG_ID.CENTER,
134
+ html_js_1.TAG_ID.CODE,
135
+ html_js_1.TAG_ID.DD,
136
+ html_js_1.TAG_ID.DIV,
137
+ html_js_1.TAG_ID.DL,
138
+ html_js_1.TAG_ID.DT,
139
+ html_js_1.TAG_ID.EM,
140
+ html_js_1.TAG_ID.EMBED,
141
+ html_js_1.TAG_ID.H1,
142
+ html_js_1.TAG_ID.H2,
143
+ html_js_1.TAG_ID.H3,
144
+ html_js_1.TAG_ID.H4,
145
+ html_js_1.TAG_ID.H5,
146
+ html_js_1.TAG_ID.H6,
147
+ html_js_1.TAG_ID.HEAD,
148
+ html_js_1.TAG_ID.HR,
149
+ html_js_1.TAG_ID.I,
150
+ html_js_1.TAG_ID.IMG,
151
+ html_js_1.TAG_ID.LI,
152
+ html_js_1.TAG_ID.LISTING,
153
+ html_js_1.TAG_ID.MENU,
154
+ html_js_1.TAG_ID.META,
155
+ html_js_1.TAG_ID.NOBR,
156
+ html_js_1.TAG_ID.OL,
157
+ html_js_1.TAG_ID.P,
158
+ html_js_1.TAG_ID.PRE,
159
+ html_js_1.TAG_ID.RUBY,
160
+ html_js_1.TAG_ID.S,
161
+ html_js_1.TAG_ID.SMALL,
162
+ html_js_1.TAG_ID.SPAN,
163
+ html_js_1.TAG_ID.STRONG,
164
+ html_js_1.TAG_ID.STRIKE,
165
+ html_js_1.TAG_ID.SUB,
166
+ html_js_1.TAG_ID.SUP,
167
+ html_js_1.TAG_ID.TABLE,
168
+ html_js_1.TAG_ID.TT,
169
+ html_js_1.TAG_ID.U,
170
+ html_js_1.TAG_ID.UL,
171
+ html_js_1.TAG_ID.VAR,
172
+ ]);
173
+ //Check exit from foreign content
174
+ function causesExit(startTagToken) {
175
+ const tn = startTagToken.tagID;
176
+ const isFontWithAttrs = tn === html_js_1.TAG_ID.FONT &&
177
+ startTagToken.attrs.some(({ name }) => name === html_js_1.ATTRS.COLOR || name === html_js_1.ATTRS.SIZE || name === html_js_1.ATTRS.FACE);
178
+ return isFontWithAttrs || EXITS_FOREIGN_CONTENT.has(tn);
179
+ }
180
+ exports.causesExit = causesExit;
181
+ //Token adjustments
182
+ function adjustTokenMathMLAttrs(token) {
183
+ for (let i = 0; i < token.attrs.length; i++) {
184
+ if (token.attrs[i].name === DEFINITION_URL_ATTR) {
185
+ token.attrs[i].name = ADJUSTED_DEFINITION_URL_ATTR;
186
+ break;
187
+ }
188
+ }
189
+ }
190
+ exports.adjustTokenMathMLAttrs = adjustTokenMathMLAttrs;
191
+ function adjustTokenSVGAttrs(token) {
192
+ for (let i = 0; i < token.attrs.length; i++) {
193
+ const adjustedAttrName = SVG_ATTRS_ADJUSTMENT_MAP.get(token.attrs[i].name);
194
+ if (adjustedAttrName != null) {
195
+ token.attrs[i].name = adjustedAttrName;
196
+ }
197
+ }
198
+ }
199
+ exports.adjustTokenSVGAttrs = adjustTokenSVGAttrs;
200
+ function adjustTokenXMLAttrs(token) {
201
+ for (let i = 0; i < token.attrs.length; i++) {
202
+ const adjustedAttrEntry = XML_ATTRS_ADJUSTMENT_MAP.get(token.attrs[i].name);
203
+ if (adjustedAttrEntry) {
204
+ token.attrs[i].prefix = adjustedAttrEntry.prefix;
205
+ token.attrs[i].name = adjustedAttrEntry.name;
206
+ token.attrs[i].namespace = adjustedAttrEntry.namespace;
207
+ }
208
+ }
209
+ }
210
+ exports.adjustTokenXMLAttrs = adjustTokenXMLAttrs;
211
+ function adjustTokenSVGTagName(token) {
212
+ const adjustedTagName = exports.SVG_TAG_NAMES_ADJUSTMENT_MAP.get(token.tagName);
213
+ if (adjustedTagName != null) {
214
+ token.tagName = adjustedTagName;
215
+ token.tagID = (0, html_js_1.getTagID)(token.tagName);
216
+ }
217
+ }
218
+ exports.adjustTokenSVGTagName = adjustTokenSVGTagName;
219
+ //Integration points
220
+ function isMathMLTextIntegrationPoint(tn, ns) {
221
+ return ns === html_js_1.NS.MATHML && (tn === html_js_1.TAG_ID.MI || tn === html_js_1.TAG_ID.MO || tn === html_js_1.TAG_ID.MN || tn === html_js_1.TAG_ID.MS || tn === html_js_1.TAG_ID.MTEXT);
222
+ }
223
+ function isHtmlIntegrationPoint(tn, ns, attrs) {
224
+ if (ns === html_js_1.NS.MATHML && tn === html_js_1.TAG_ID.ANNOTATION_XML) {
225
+ for (let i = 0; i < attrs.length; i++) {
226
+ if (attrs[i].name === html_js_1.ATTRS.ENCODING) {
227
+ const value = attrs[i].value.toLowerCase();
228
+ return value === MIME_TYPES.TEXT_HTML || value === MIME_TYPES.APPLICATION_XML;
229
+ }
230
+ }
231
+ }
232
+ return ns === html_js_1.NS.SVG && (tn === html_js_1.TAG_ID.FOREIGN_OBJECT || tn === html_js_1.TAG_ID.DESC || tn === html_js_1.TAG_ID.TITLE);
233
+ }
234
+ function isIntegrationPoint(tn, ns, attrs, foreignNS) {
235
+ return (((!foreignNS || foreignNS === html_js_1.NS.HTML) && isHtmlIntegrationPoint(tn, ns, attrs)) ||
236
+ ((!foreignNS || foreignNS === html_js_1.NS.MATHML) && isMathMLTextIntegrationPoint(tn, ns)));
237
+ }
238
+ exports.isIntegrationPoint = isIntegrationPoint;
239
+ //# sourceMappingURL=foreign-content.js.map