@digi-frontend/dgate-api-documentation 1.0.39 → 1.0.50

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 (430) hide show
  1. package/.editorconfig +12 -12
  2. package/.prettierignore +7 -7
  3. package/.prettierrc +15 -15
  4. package/dist/{a7568b270e175038.svg → 070dc6ecd197bc80.svg} +8 -8
  5. package/dist/16702d92fd6d1730.svg +6 -0
  6. package/dist/2b546d6e9fdf604a.svg +3 -0
  7. package/dist/2c3c6c2c3b835504.svg +5 -0
  8. package/dist/{43595976d1fdccbf.svg → 2e10bbdb265df50e.svg} +4 -4
  9. package/dist/55b5994c5781482b.svg +5 -0
  10. package/dist/60bef8083c55f46b.svg +6 -0
  11. package/dist/68c710e0583e19e6.svg +5 -0
  12. package/dist/731221b3f242672d.svg +4 -0
  13. package/dist/{b82c7612e73342f3.svg → 7f54eeb0bb2d1150.svg} +3 -3
  14. package/dist/8520b6792278d9df.svg +6 -0
  15. package/dist/{56dc416b683db280.svg → 8789eb84283ea95b.svg} +5 -5
  16. package/dist/9506ef7a26a74147.svg +12 -0
  17. package/dist/9b7aee27757b5036.svg +3 -0
  18. package/dist/{af16a554be8c4d69.svg → 9bdff13f8d8fa48a.svg} +3 -3
  19. package/dist/_virtual/core.js +2 -0
  20. package/dist/_virtual/core.js.map +1 -0
  21. package/dist/_virtual/core2.js +2 -0
  22. package/dist/_virtual/core2.js.map +1 -0
  23. package/dist/_virtual/format.js +2 -0
  24. package/dist/_virtual/format.js.map +1 -0
  25. package/dist/_virtual/index3.js +1 -1
  26. package/dist/_virtual/index6.js +1 -1
  27. package/dist/{64efc2716808c4a4.svg → bb8b87cace25e052.svg} +3 -3
  28. package/dist/cceb1e5dc06b0b85.svg +4 -0
  29. package/dist/d140a601c85bac25.svg +3 -0
  30. package/dist/{72db3b05a96dd600.svg → d32ce84bbd78babd.svg} +3 -3
  31. package/dist/{844eba3f2e42a9eb.svg → d501922060662842.svg} +3 -3
  32. package/dist/d6d0a98ec38e6b77.svg +3 -0
  33. package/dist/e04479ad425e7d58.svg +4 -0
  34. package/dist/f4452c3ebcf0d5da.svg +4 -0
  35. package/dist/f4a32992f02af522.svg +5 -0
  36. package/dist/node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js +2 -0
  37. package/dist/node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js.map +1 -0
  38. package/dist/node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js +2 -0
  39. package/dist/node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js.map +1 -0
  40. package/dist/node_modules/@babel/runtime/helpers/esm/defineProperty.js +2 -0
  41. package/dist/node_modules/@babel/runtime/helpers/esm/defineProperty.js.map +1 -0
  42. package/dist/node_modules/@babel/runtime/helpers/esm/extends.js +2 -0
  43. package/dist/node_modules/@babel/runtime/helpers/esm/extends.js.map +1 -0
  44. package/dist/node_modules/@babel/runtime/helpers/esm/iterableToArray.js +2 -0
  45. package/dist/node_modules/@babel/runtime/helpers/esm/iterableToArray.js.map +1 -0
  46. package/dist/node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js +2 -0
  47. package/dist/node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js.map +1 -0
  48. package/dist/node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js +2 -0
  49. package/dist/node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js.map +1 -0
  50. package/dist/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js +2 -0
  51. package/dist/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js.map +1 -0
  52. package/dist/node_modules/@babel/runtime/helpers/esm/toConsumableArray.js +2 -0
  53. package/dist/node_modules/@babel/runtime/helpers/esm/toConsumableArray.js.map +1 -0
  54. package/dist/node_modules/@babel/runtime/helpers/esm/toPrimitive.js +2 -0
  55. package/dist/node_modules/@babel/runtime/helpers/esm/toPrimitive.js.map +1 -0
  56. package/dist/node_modules/@babel/runtime/helpers/esm/toPropertyKey.js +2 -0
  57. package/dist/node_modules/@babel/runtime/helpers/esm/toPropertyKey.js.map +1 -0
  58. package/dist/node_modules/@babel/runtime/helpers/esm/typeof.js +2 -0
  59. package/dist/node_modules/@babel/runtime/helpers/esm/typeof.js.map +1 -0
  60. package/dist/node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js +2 -0
  61. package/dist/node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js.map +1 -0
  62. package/dist/node_modules/dom-serializer/lib/foreignNames.js +2 -0
  63. package/dist/node_modules/dom-serializer/lib/foreignNames.js.map +1 -0
  64. package/dist/node_modules/dom-serializer/lib/index.js +2 -0
  65. package/dist/node_modules/dom-serializer/lib/index.js.map +1 -0
  66. package/dist/node_modules/dom-serializer/node_modules/entities/lib/decode.js +2 -0
  67. package/dist/node_modules/dom-serializer/node_modules/entities/lib/decode.js.map +1 -0
  68. package/dist/node_modules/dom-serializer/node_modules/entities/lib/decode_codepoint.js +2 -0
  69. package/dist/node_modules/dom-serializer/node_modules/entities/lib/decode_codepoint.js.map +1 -0
  70. package/dist/node_modules/dom-serializer/node_modules/entities/lib/encode.js +2 -0
  71. package/dist/node_modules/dom-serializer/node_modules/entities/lib/encode.js.map +1 -0
  72. package/dist/node_modules/dom-serializer/node_modules/entities/lib/escape.js +2 -0
  73. package/dist/node_modules/dom-serializer/node_modules/entities/lib/escape.js.map +1 -0
  74. package/dist/node_modules/dom-serializer/node_modules/entities/lib/generated/decode-data-html.js +2 -0
  75. package/dist/node_modules/dom-serializer/node_modules/entities/lib/generated/decode-data-html.js.map +1 -0
  76. package/dist/node_modules/dom-serializer/node_modules/entities/lib/generated/decode-data-xml.js +2 -0
  77. package/dist/node_modules/dom-serializer/node_modules/entities/lib/generated/decode-data-xml.js.map +1 -0
  78. package/dist/node_modules/dom-serializer/node_modules/entities/lib/generated/encode-html.js +2 -0
  79. package/dist/node_modules/dom-serializer/node_modules/entities/lib/generated/encode-html.js.map +1 -0
  80. package/dist/node_modules/dom-serializer/node_modules/entities/lib/index.js +2 -0
  81. package/dist/node_modules/dom-serializer/node_modules/entities/lib/index.js.map +1 -0
  82. package/dist/node_modules/domhandler/lib/index.js +2 -0
  83. package/dist/node_modules/domhandler/lib/index.js.map +1 -0
  84. package/dist/node_modules/domhandler/lib/node.js +2 -0
  85. package/dist/node_modules/domhandler/lib/node.js.map +1 -0
  86. package/dist/node_modules/domutils/lib/feeds.js +2 -0
  87. package/dist/node_modules/domutils/lib/feeds.js.map +1 -0
  88. package/dist/node_modules/domutils/lib/helpers.js +2 -0
  89. package/dist/node_modules/domutils/lib/helpers.js.map +1 -0
  90. package/dist/node_modules/domutils/lib/index.js +2 -0
  91. package/dist/node_modules/domutils/lib/index.js.map +1 -0
  92. package/dist/node_modules/domutils/lib/legacy.js +2 -0
  93. package/dist/node_modules/domutils/lib/legacy.js.map +1 -0
  94. package/dist/node_modules/domutils/lib/manipulation.js +2 -0
  95. package/dist/node_modules/domutils/lib/manipulation.js.map +1 -0
  96. package/dist/node_modules/domutils/lib/querying.js +2 -0
  97. package/dist/node_modules/domutils/lib/querying.js.map +1 -0
  98. package/dist/node_modules/domutils/lib/stringify.js +2 -0
  99. package/dist/node_modules/domutils/lib/stringify.js.map +1 -0
  100. package/dist/node_modules/domutils/lib/traversal.js +2 -0
  101. package/dist/node_modules/domutils/lib/traversal.js.map +1 -0
  102. package/dist/node_modules/entities/dist/commonjs/decode-codepoint.js +2 -0
  103. package/dist/node_modules/entities/dist/commonjs/decode-codepoint.js.map +1 -0
  104. package/dist/node_modules/entities/dist/commonjs/decode.js +2 -0
  105. package/dist/node_modules/entities/dist/commonjs/decode.js.map +1 -0
  106. package/dist/node_modules/entities/dist/commonjs/generated/decode-data-html.js +2 -0
  107. package/dist/node_modules/entities/dist/commonjs/generated/decode-data-html.js.map +1 -0
  108. package/dist/node_modules/entities/dist/commonjs/generated/decode-data-xml.js +2 -0
  109. package/dist/node_modules/entities/dist/commonjs/generated/decode-data-xml.js.map +1 -0
  110. package/dist/node_modules/fault/index.js +2 -0
  111. package/dist/node_modules/fault/index.js.map +1 -0
  112. package/dist/node_modules/format/format.js +2 -0
  113. package/dist/node_modules/format/format.js.map +1 -0
  114. package/dist/node_modules/highlight.js/lib/core.js +2 -0
  115. package/dist/node_modules/highlight.js/lib/core.js.map +1 -0
  116. package/dist/node_modules/html-dom-parser/lib/server/html-to-dom.js +1 -1
  117. package/dist/node_modules/html-dom-parser/lib/server/html-to-dom.js.map +1 -1
  118. package/dist/node_modules/html-react-parser/lib/index.js +1 -1
  119. package/dist/node_modules/html-react-parser/lib/index.js.map +1 -1
  120. package/dist/node_modules/htmlparser2/dist/commonjs/Parser.js +1 -1
  121. package/dist/node_modules/htmlparser2/dist/commonjs/Parser.js.map +1 -1
  122. package/dist/node_modules/htmlparser2/dist/commonjs/Tokenizer.js +1 -1
  123. package/dist/node_modules/htmlparser2/dist/commonjs/Tokenizer.js.map +1 -1
  124. package/dist/node_modules/htmlparser2/dist/commonjs/index.js +1 -1
  125. package/dist/node_modules/htmlparser2/dist/commonjs/index.js.map +1 -1
  126. package/dist/node_modules/lowlight/lib/core.js +2 -0
  127. package/dist/node_modules/lowlight/lib/core.js.map +1 -0
  128. package/dist/node_modules/nanoid/index.js +2 -0
  129. package/dist/node_modules/nanoid/index.js.map +1 -0
  130. package/dist/node_modules/nanoid/url-alphabet/index.js +2 -0
  131. package/dist/node_modules/nanoid/url-alphabet/index.js.map +1 -0
  132. package/dist/node_modules/react-syntax-highlighter/dist/esm/checkForListedLanguage.js +2 -0
  133. package/dist/node_modules/react-syntax-highlighter/dist/esm/checkForListedLanguage.js.map +1 -0
  134. package/dist/node_modules/react-syntax-highlighter/dist/esm/create-element.js +2 -0
  135. package/dist/node_modules/react-syntax-highlighter/dist/esm/create-element.js.map +1 -0
  136. package/dist/node_modules/react-syntax-highlighter/dist/esm/highlight.js +2 -0
  137. package/dist/node_modules/react-syntax-highlighter/dist/esm/highlight.js.map +1 -0
  138. package/dist/node_modules/react-syntax-highlighter/dist/esm/light.js +2 -0
  139. package/dist/node_modules/react-syntax-highlighter/dist/esm/light.js.map +1 -0
  140. package/dist/node_modules/react-syntax-highlighter/dist/esm/styles/hljs/stackoverflow-dark.js +2 -0
  141. package/dist/node_modules/react-syntax-highlighter/dist/esm/styles/hljs/stackoverflow-dark.js.map +1 -0
  142. package/dist/node_modules/react-syntax-highlighter/dist/esm/styles/hljs/stackoverflow-light.js +2 -0
  143. package/dist/node_modules/react-syntax-highlighter/dist/esm/styles/hljs/stackoverflow-light.js.map +1 -0
  144. package/dist/node_modules/style-to-object/cjs/index.js +1 -1
  145. package/dist/node_modules/yup/index.esm.js +1 -1
  146. package/dist/src/assets/icons/AddRow.svg.js +1 -1
  147. package/dist/src/assets/icons/AddRow.svg.js.map +1 -1
  148. package/dist/src/assets/icons/ApiIcon.svg.js +2 -0
  149. package/dist/src/assets/icons/ApiIcon.svg.js.map +1 -0
  150. package/dist/src/assets/icons/ArrowBack.svg.js +2 -0
  151. package/dist/src/assets/icons/ArrowBack.svg.js.map +1 -0
  152. package/dist/src/assets/icons/BookIcon.svg.js +2 -0
  153. package/dist/src/assets/icons/BookIcon.svg.js.map +1 -0
  154. package/dist/src/assets/icons/CopySticker.svg.js +2 -0
  155. package/dist/src/assets/icons/CopySticker.svg.js.map +1 -0
  156. package/dist/src/assets/icons/DeleteIcon.svg.js +1 -1
  157. package/dist/src/assets/icons/DeleteIcon.svg.js.map +1 -1
  158. package/dist/src/assets/icons/DeleteOutlinedIcon.svg.js +2 -0
  159. package/dist/src/assets/icons/DeleteOutlinedIcon.svg.js.map +1 -0
  160. package/dist/src/assets/icons/DownArrow.svg.js +1 -1
  161. package/dist/src/assets/icons/DownArrow.svg.js.map +1 -1
  162. package/dist/src/assets/icons/EditIcon.svg.js +1 -1
  163. package/dist/src/assets/icons/EditIcon.svg.js.map +1 -1
  164. package/dist/src/assets/icons/FilterIcon.svg.js +2 -0
  165. package/dist/src/assets/icons/FilterIcon.svg.js.map +1 -0
  166. package/dist/src/assets/icons/Plus.svg.js +2 -0
  167. package/dist/src/assets/icons/Plus.svg.js.map +1 -0
  168. package/dist/src/assets/icons/PlusSquare.svg.js +2 -0
  169. package/dist/src/assets/icons/PlusSquare.svg.js.map +1 -0
  170. package/dist/src/assets/icons/RequestOption.svg.js +2 -0
  171. package/dist/src/assets/icons/RequestOption.svg.js.map +1 -0
  172. package/dist/src/assets/icons/UpArrow.svg.js +1 -1
  173. package/dist/src/assets/icons/UpArrow.svg.js.map +1 -1
  174. package/dist/src/assets/icons/arrowDownGray.svg.js +2 -0
  175. package/dist/src/assets/icons/arrowDownGray.svg.js.map +1 -0
  176. package/dist/src/assets/icons/arrowRightGray.svg.js +2 -0
  177. package/dist/src/assets/icons/arrowRightGray.svg.js.map +1 -0
  178. package/dist/src/assets/icons/close-circle.svg.js +2 -0
  179. package/dist/src/assets/icons/close-circle.svg.js.map +1 -0
  180. package/dist/src/assets/icons/copy.svg.js +2 -0
  181. package/dist/src/assets/icons/copy.svg.js.map +1 -0
  182. package/dist/src/assets/icons/document.svg.js +2 -0
  183. package/dist/src/assets/icons/document.svg.js.map +1 -0
  184. package/dist/src/assets/icons/eye.svg.js +2 -0
  185. package/dist/src/assets/icons/eye.svg.js.map +1 -0
  186. package/dist/src/assets/icons/infoIcon.svg.js +2 -0
  187. package/dist/src/assets/icons/infoIcon.svg.js.map +1 -0
  188. package/dist/src/assets/icons/searchIcon.svg.js +2 -0
  189. package/dist/src/assets/icons/searchIcon.svg.js.map +1 -0
  190. package/dist/src/components/InfoForm/InfoForm.js +1 -1
  191. package/dist/src/components/InfoForm/InfoForm.js.map +1 -1
  192. package/dist/src/components/JsonInput/JsonInput.js.map +1 -1
  193. package/dist/src/components/LivePreview/LivePreview.js +1 -1
  194. package/dist/src/components/LivePreview/LivePreview.js.map +1 -1
  195. package/dist/src/components/MethodAccordion/MethodAccordion.js +1 -1
  196. package/dist/src/components/MethodAccordion/MethodAccordion.js.map +1 -1
  197. package/dist/src/components/SVGLoader/SVGLoader.js.map +1 -1
  198. package/dist/src/components/SectionHead/SectionHead.js.map +1 -1
  199. package/dist/src/components/SimpleLabelValue/SimpleLabelValue.js.map +1 -1
  200. package/dist/src/components/Tooltip/Tooltip.js.map +1 -1
  201. package/dist/src/components/dialog/index.js +1 -1
  202. package/dist/src/components/dialog/index.js.map +1 -1
  203. package/dist/src/components/table/table.js +1 -1
  204. package/dist/src/components/table/table.js.map +1 -1
  205. package/dist/src/components/table/tags-table.js.map +1 -1
  206. package/dist/src/constants/index.js +1 -1
  207. package/dist/src/constants/index.js.map +1 -1
  208. package/dist/src/constants/methods.constant.js +2 -0
  209. package/dist/src/constants/methods.constant.js.map +1 -0
  210. package/dist/src/constants/regex.js.map +1 -1
  211. package/dist/src/helpers/docs.helper.js +2 -0
  212. package/dist/src/helpers/docs.helper.js.map +1 -0
  213. package/dist/src/helpers/layout.helper.js +1 -1
  214. package/dist/src/helpers/layout.helper.js.map +1 -1
  215. package/dist/src/helpers/methodAccordion.helper.js.map +1 -1
  216. package/dist/src/index.js +1 -1
  217. package/dist/src/layout/docsComponents/Codebox/Codebox.js +2 -0
  218. package/dist/src/layout/docsComponents/Codebox/Codebox.js.map +1 -0
  219. package/dist/src/layout/docsComponents/Codebox/style.module.scss.js +2 -0
  220. package/dist/src/layout/docsComponents/Codebox/style.module.scss.js.map +1 -0
  221. package/dist/src/layout/docsComponents/DocsAside/DocsAside.js +2 -0
  222. package/dist/src/layout/docsComponents/DocsAside/DocsAside.js.map +1 -0
  223. package/dist/src/layout/docsComponents/DocsAside/style.module.scss.js +2 -0
  224. package/dist/src/layout/docsComponents/DocsAside/style.module.scss.js.map +1 -0
  225. package/dist/src/layout/docsComponents/DocsContent/DocsContent.js +2 -0
  226. package/dist/src/layout/docsComponents/DocsContent/DocsContent.js.map +1 -0
  227. package/dist/src/layout/docsComponents/DocsContent/EndpointPage/index.js +2 -0
  228. package/dist/src/layout/docsComponents/DocsContent/EndpointPage/index.js.map +1 -0
  229. package/dist/src/layout/docsComponents/DocsContent/TagPage/index.js +2 -0
  230. package/dist/src/layout/docsComponents/DocsContent/TagPage/index.js.map +1 -0
  231. package/dist/src/layout/docsComponents/DocsHeader/DocsHeader.js +2 -0
  232. package/dist/src/layout/docsComponents/DocsHeader/DocsHeader.js.map +1 -0
  233. package/dist/src/layout/docsComponents/DocsHeader/DocsHeader.module.scss.js +2 -0
  234. package/dist/src/layout/docsComponents/DocsHeader/DocsHeader.module.scss.js.map +1 -0
  235. package/dist/src/layout/docsComponents/DocsSideMenuTree/DocsSideMenuTree.js +2 -0
  236. package/dist/src/layout/docsComponents/DocsSideMenuTree/DocsSideMenuTree.js.map +1 -0
  237. package/dist/src/layout/docsComponents/index.js +2 -0
  238. package/dist/src/layout/docsComponents/index.js.map +1 -0
  239. package/dist/src/layout/docsLayout.js +2 -0
  240. package/dist/src/layout/docsLayout.js.map +1 -0
  241. package/dist/src/layout/layout.js +1 -1
  242. package/dist/src/layout/layout.js.map +1 -1
  243. package/dist/src/layout/layout.module.css.js +1 -1
  244. package/dist/src/utils/index.js +2 -0
  245. package/dist/src/utils/index.js.map +1 -0
  246. package/dist/src/validator/form.scheme.js +1 -1
  247. package/dist/src/validator/form.scheme.js.map +1 -1
  248. package/dist/styles.css +1646 -348
  249. package/dist/types/assets/icons/index.d.ts +17 -1
  250. package/dist/types/components/LivePreview/LivePreview.d.ts +1 -0
  251. package/dist/types/components/MethodAccordion/MethodAccordion.d.ts +2 -1
  252. package/dist/types/components/dialog/dialog.d.ts +4 -0
  253. package/dist/types/components/dialog/index.d.ts +1 -1
  254. package/dist/types/components/table/table.d.ts +2 -1
  255. package/dist/types/constants/methods.constant.d.ts +16 -0
  256. package/dist/types/helpers/docs.helper.d.ts +3 -0
  257. package/dist/types/index.d.ts +1 -0
  258. package/dist/types/layout/docsComponents/Codebox/Codebox.d.ts +4 -0
  259. package/dist/types/layout/docsComponents/DocsAside/DocsAside.d.ts +5 -0
  260. package/dist/types/layout/docsComponents/DocsContent/DocsContent.d.ts +6 -0
  261. package/dist/types/layout/docsComponents/DocsContent/EndpointPage/index.d.ts +4 -0
  262. package/dist/types/layout/docsComponents/DocsContent/TagPage/index.d.ts +4 -0
  263. package/dist/types/layout/docsComponents/DocsHeader/DocsHeader.d.ts +3 -0
  264. package/dist/types/layout/docsComponents/DocsSideMenuTree/DocsSideMenuTree.d.ts +9 -0
  265. package/dist/types/layout/docsComponents/index.d.ts +17 -0
  266. package/dist/types/layout/docsLayout.d.ts +33 -0
  267. package/dist/types/layout/layout.d.ts +2 -1
  268. package/dist/types/types/layout.type.d.ts +1 -0
  269. package/dist/types/types/openApi.d.ts +4 -4
  270. package/dist/types/utils/index.d.ts +1 -0
  271. package/dist/types/validator/form.scheme.d.ts +10 -2
  272. package/package.json +46 -43
  273. package/rollup.config.js +37 -35
  274. package/src/assets/icons/AddRow.svg +3 -3
  275. package/src/assets/icons/ApiIcon.svg +12 -0
  276. package/src/assets/icons/ArrowBack.svg +3 -0
  277. package/src/assets/icons/BookIcon.svg +6 -0
  278. package/src/assets/icons/CheckMarkSquare.svg +5 -5
  279. package/src/assets/icons/CloseIcon.svg +4 -4
  280. package/src/assets/icons/CopySticker.svg +6 -0
  281. package/src/assets/icons/DeleteIcon.svg +3 -3
  282. package/src/assets/icons/DeleteOutlinedIcon.svg +8 -0
  283. package/src/assets/icons/DownArrow.svg +3 -3
  284. package/src/assets/icons/EditIcon.svg +3 -3
  285. package/src/assets/icons/FilterIcon.svg +4 -0
  286. package/src/assets/icons/Plus.svg +5 -0
  287. package/src/assets/icons/PlusSquare.svg +3 -0
  288. package/src/assets/icons/RequestOption.svg +5 -0
  289. package/src/assets/icons/UpArrow.svg +3 -3
  290. package/src/assets/icons/arrowDownGray.svg +3 -0
  291. package/src/assets/icons/arrowRightGray.svg +3 -0
  292. package/src/assets/icons/close-circle.svg +5 -0
  293. package/src/assets/icons/copy.svg +4 -0
  294. package/src/assets/icons/deleteOutlinedIcon.svg +8 -8
  295. package/src/assets/icons/document.svg +6 -0
  296. package/src/assets/icons/eye.svg +4 -0
  297. package/src/assets/icons/index.ts +24 -8
  298. package/src/assets/icons/infoIcon.svg +5 -0
  299. package/src/assets/icons/searchIcon.svg +4 -0
  300. package/src/components/Chips/Chips.tsx +87 -87
  301. package/src/components/Chips/style.scss +147 -147
  302. package/src/components/InfoForm/InfoForm.module.scss +165 -165
  303. package/src/components/InfoForm/InfoForm.tsx +423 -428
  304. package/src/components/JsonInput/JsonInput.tsx +149 -149
  305. package/src/components/JsonInput/style.module.scss +133 -133
  306. package/src/components/LivePreview/LivePreview.module.scss +180 -24
  307. package/src/components/LivePreview/LivePreview.tsx +226 -191
  308. package/src/components/MethodAccordion/MethodAccordion.module.scss +395 -338
  309. package/src/components/MethodAccordion/MethodAccordion.tsx +678 -514
  310. package/src/components/SVGLoader/SVGLoader.tsx +96 -94
  311. package/src/components/SectionHead/SectionHead.scss +29 -29
  312. package/src/components/SectionHead/SectionHead.tsx +22 -22
  313. package/src/components/SimpleLabelValue/SimpleLabelValue.tsx +31 -31
  314. package/src/components/SimpleLabelValue/index.ts +1 -1
  315. package/src/components/SimpleLabelValue/style.scss +30 -30
  316. package/src/components/Tooltip/Tooltip.scss +133 -133
  317. package/src/components/Tooltip/Tooltip.tsx +85 -85
  318. package/src/components/_global.scss +337 -337
  319. package/src/components/dialog/dialog.ts +58 -54
  320. package/src/components/dialog/index.tsx +89 -85
  321. package/src/components/dialog/style.scss +188 -104
  322. package/src/components/table/style.scss +217 -190
  323. package/src/components/table/table.tsx +493 -327
  324. package/src/components/table/tags-table.tsx +348 -348
  325. package/src/constants/index.ts +95 -93
  326. package/src/constants/methods.constant.ts +26 -0
  327. package/src/constants/regex.ts +7 -7
  328. package/src/global.d.ts +13 -13
  329. package/src/helpers/docs.helper.ts +28 -0
  330. package/src/helpers/layout.helper.ts +176 -174
  331. package/src/helpers/methodAccordion.helper.ts +19 -19
  332. package/src/index.ts +2 -1
  333. package/src/layout/docsComponents/Codebox/Codebox.tsx +61 -0
  334. package/src/layout/docsComponents/Codebox/style.module.scss +43 -0
  335. package/src/layout/docsComponents/DocsAside/DocsAside.tsx +94 -0
  336. package/src/layout/docsComponents/DocsAside/style.module.scss +113 -0
  337. package/src/layout/docsComponents/DocsContent/DocsContent.tsx +14 -0
  338. package/src/layout/docsComponents/DocsContent/EndpointPage/index.tsx +184 -0
  339. package/src/layout/docsComponents/DocsContent/EndpointPage/style.scss +230 -0
  340. package/src/layout/docsComponents/DocsContent/TagPage/index.tsx +82 -0
  341. package/src/layout/docsComponents/DocsContent/TagPage/style.scss +283 -0
  342. package/src/layout/docsComponents/DocsContent/style.scss +0 -0
  343. package/src/layout/docsComponents/DocsHeader/DocsHeader.module.scss +271 -0
  344. package/src/layout/docsComponents/DocsHeader/DocsHeader.tsx +156 -0
  345. package/src/layout/docsComponents/DocsSideMenuTree/DocsSideMenuTree.tsx +188 -0
  346. package/src/layout/docsComponents/DocsSideMenuTree/style.scss +195 -0
  347. package/src/layout/docsComponents/index.scss +49 -0
  348. package/src/layout/docsComponents/index.tsx +28 -0
  349. package/src/layout/docsLayout.tsx +72 -0
  350. package/src/layout/layout.module.css +65 -62
  351. package/src/layout/layout.tsx +162 -150
  352. package/src/types/layout.type.ts +31 -30
  353. package/src/types/openApi.ts +108 -108
  354. package/src/types/transformedOpenApi.ts +52 -52
  355. package/src/utils/index.ts +7 -0
  356. package/src/validator/form.scheme.ts +88 -70
  357. package/tsconfig.json +33 -33
  358. package/dist/_virtual/index20.js +0 -2
  359. package/dist/_virtual/index20.js.map +0 -1
  360. package/dist/_virtual/index21.js +0 -2
  361. package/dist/_virtual/index21.js.map +0 -1
  362. package/dist/_virtual/node2.js +0 -2
  363. package/dist/_virtual/node2.js.map +0 -1
  364. package/dist/_virtual/node3.js +0 -2
  365. package/dist/_virtual/node3.js.map +0 -1
  366. package/dist/node_modules/html-dom-parser/node_modules/domhandler/lib/index.js +0 -2
  367. package/dist/node_modules/html-dom-parser/node_modules/domhandler/lib/index.js.map +0 -1
  368. package/dist/node_modules/html-dom-parser/node_modules/domhandler/lib/node.js +0 -2
  369. package/dist/node_modules/html-dom-parser/node_modules/domhandler/lib/node.js.map +0 -1
  370. package/dist/node_modules/html-react-parser/node_modules/domhandler/lib/index.js +0 -2
  371. package/dist/node_modules/html-react-parser/node_modules/domhandler/lib/index.js.map +0 -1
  372. package/dist/node_modules/html-react-parser/node_modules/domhandler/lib/node.js +0 -2
  373. package/dist/node_modules/html-react-parser/node_modules/domhandler/lib/node.js.map +0 -1
  374. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/lib/foreignNames.js +0 -2
  375. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/lib/foreignNames.js.map +0 -1
  376. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/lib/index.js +0 -2
  377. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/lib/index.js.map +0 -1
  378. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/decode.js +0 -2
  379. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/decode.js.map +0 -1
  380. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/decode_codepoint.js +0 -2
  381. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/decode_codepoint.js.map +0 -1
  382. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/encode.js +0 -2
  383. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/encode.js.map +0 -1
  384. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/escape.js +0 -2
  385. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/escape.js.map +0 -1
  386. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/generated/decode-data-html.js +0 -2
  387. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/generated/decode-data-html.js.map +0 -1
  388. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/generated/decode-data-xml.js +0 -2
  389. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/generated/decode-data-xml.js.map +0 -1
  390. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/generated/encode-html.js +0 -2
  391. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/generated/encode-html.js.map +0 -1
  392. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/index.js +0 -2
  393. package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/index.js.map +0 -1
  394. package/dist/node_modules/htmlparser2/node_modules/domhandler/lib/index.js +0 -2
  395. package/dist/node_modules/htmlparser2/node_modules/domhandler/lib/index.js.map +0 -1
  396. package/dist/node_modules/htmlparser2/node_modules/domhandler/lib/node.js +0 -2
  397. package/dist/node_modules/htmlparser2/node_modules/domhandler/lib/node.js.map +0 -1
  398. package/dist/node_modules/htmlparser2/node_modules/domutils/lib/feeds.js +0 -2
  399. package/dist/node_modules/htmlparser2/node_modules/domutils/lib/feeds.js.map +0 -1
  400. package/dist/node_modules/htmlparser2/node_modules/domutils/lib/helpers.js +0 -2
  401. package/dist/node_modules/htmlparser2/node_modules/domutils/lib/helpers.js.map +0 -1
  402. package/dist/node_modules/htmlparser2/node_modules/domutils/lib/index.js +0 -2
  403. package/dist/node_modules/htmlparser2/node_modules/domutils/lib/index.js.map +0 -1
  404. package/dist/node_modules/htmlparser2/node_modules/domutils/lib/legacy.js +0 -2
  405. package/dist/node_modules/htmlparser2/node_modules/domutils/lib/legacy.js.map +0 -1
  406. package/dist/node_modules/htmlparser2/node_modules/domutils/lib/manipulation.js +0 -2
  407. package/dist/node_modules/htmlparser2/node_modules/domutils/lib/manipulation.js.map +0 -1
  408. package/dist/node_modules/htmlparser2/node_modules/domutils/lib/querying.js +0 -2
  409. package/dist/node_modules/htmlparser2/node_modules/domutils/lib/querying.js.map +0 -1
  410. package/dist/node_modules/htmlparser2/node_modules/domutils/lib/stringify.js +0 -2
  411. package/dist/node_modules/htmlparser2/node_modules/domutils/lib/stringify.js.map +0 -1
  412. package/dist/node_modules/htmlparser2/node_modules/domutils/lib/traversal.js +0 -2
  413. package/dist/node_modules/htmlparser2/node_modules/domutils/lib/traversal.js.map +0 -1
  414. package/dist/node_modules/htmlparser2/node_modules/entities/dist/commonjs/decode-codepoint.js +0 -2
  415. package/dist/node_modules/htmlparser2/node_modules/entities/dist/commonjs/decode-codepoint.js.map +0 -1
  416. package/dist/node_modules/htmlparser2/node_modules/entities/dist/commonjs/decode.js +0 -2
  417. package/dist/node_modules/htmlparser2/node_modules/entities/dist/commonjs/decode.js.map +0 -1
  418. package/dist/node_modules/htmlparser2/node_modules/entities/dist/commonjs/generated/decode-data-html.js +0 -2
  419. package/dist/node_modules/htmlparser2/node_modules/entities/dist/commonjs/generated/decode-data-html.js.map +0 -1
  420. package/dist/node_modules/htmlparser2/node_modules/entities/dist/commonjs/generated/decode-data-xml.js +0 -2
  421. package/dist/node_modules/htmlparser2/node_modules/entities/dist/commonjs/generated/decode-data-xml.js.map +0 -1
  422. package/dist/src/assets/icons/CheckMarkSquare.svg.js +0 -2
  423. package/dist/src/assets/icons/CheckMarkSquare.svg.js.map +0 -1
  424. package/dist/src/assets/icons/CloseIcon.svg.js +0 -2
  425. package/dist/src/assets/icons/CloseIcon.svg.js.map +0 -1
  426. package/dist/src/assets/icons/deleteOutlinedIcon.svg.js +0 -2
  427. package/dist/src/assets/icons/deleteOutlinedIcon.svg.js.map +0 -1
  428. package/dist/src/components/Chips/Chips.js +0 -2
  429. package/dist/src/components/Chips/Chips.js.map +0 -1
  430. package/dist/types/types/index.d.ts +0 -18
@@ -1,2 +1,2 @@
1
- import{__exports as t}from"../../../../_virtual/Tokenizer.js";import{__require as e}from"../../node_modules/entities/dist/commonjs/decode.js";var i;function s(){if(i)return t;i=1,Object.defineProperty(t,"__esModule",{value:!0}),t.QuoteType=void 0;const s=e();var a,n,r;function h(t){return t===a.Space||t===a.NewLine||t===a.Tab||t===a.FormFeed||t===a.CarriageReturn}function o(t){return t===a.Slash||t===a.Gt||h(t)}!function(t){t[t.Tab=9]="Tab",t[t.NewLine=10]="NewLine",t[t.FormFeed=12]="FormFeed",t[t.CarriageReturn=13]="CarriageReturn",t[t.Space=32]="Space",t[t.ExclamationMark=33]="ExclamationMark",t[t.Number=35]="Number",t[t.Amp=38]="Amp",t[t.SingleQuote=39]="SingleQuote",t[t.DoubleQuote=34]="DoubleQuote",t[t.Dash=45]="Dash",t[t.Slash=47]="Slash",t[t.Zero=48]="Zero",t[t.Nine=57]="Nine",t[t.Semi=59]="Semi",t[t.Lt=60]="Lt",t[t.Eq=61]="Eq",t[t.Gt=62]="Gt",t[t.Questionmark=63]="Questionmark",t[t.UpperA=65]="UpperA",t[t.LowerA=97]="LowerA",t[t.UpperF=70]="UpperF",t[t.LowerF=102]="LowerF",t[t.UpperZ=90]="UpperZ",t[t.LowerZ=122]="LowerZ",t[t.LowerX=120]="LowerX",t[t.OpeningSquareBracket=91]="OpeningSquareBracket"}(a||(a={})),function(t){t[t.Text=1]="Text",t[t.BeforeTagName=2]="BeforeTagName",t[t.InTagName=3]="InTagName",t[t.InSelfClosingTag=4]="InSelfClosingTag",t[t.BeforeClosingTagName=5]="BeforeClosingTagName",t[t.InClosingTagName=6]="InClosingTagName",t[t.AfterClosingTagName=7]="AfterClosingTagName",t[t.BeforeAttributeName=8]="BeforeAttributeName",t[t.InAttributeName=9]="InAttributeName",t[t.AfterAttributeName=10]="AfterAttributeName",t[t.BeforeAttributeValue=11]="BeforeAttributeValue",t[t.InAttributeValueDq=12]="InAttributeValueDq",t[t.InAttributeValueSq=13]="InAttributeValueSq",t[t.InAttributeValueNq=14]="InAttributeValueNq",t[t.BeforeDeclaration=15]="BeforeDeclaration",t[t.InDeclaration=16]="InDeclaration",t[t.InProcessingInstruction=17]="InProcessingInstruction",t[t.BeforeComment=18]="BeforeComment",t[t.CDATASequence=19]="CDATASequence",t[t.InSpecialComment=20]="InSpecialComment",t[t.InCommentLike=21]="InCommentLike",t[t.BeforeSpecialS=22]="BeforeSpecialS",t[t.BeforeSpecialT=23]="BeforeSpecialT",t[t.SpecialStartSequence=24]="SpecialStartSequence",t[t.InSpecialTag=25]="InSpecialTag",t[t.InEntity=26]="InEntity"}(n||(n={})),function(t){t[t.NoValue=0]="NoValue",t[t.Unquoted=1]="Unquoted",t[t.Single=2]="Single",t[t.Double=3]="Double"}(r||(t.QuoteType=r={}));const c={Cdata:new Uint8Array([67,68,65,84,65,91]),CdataEnd:new Uint8Array([93,93,62]),CommentEnd:new Uint8Array([45,45,62]),ScriptEnd:new Uint8Array([60,47,115,99,114,105,112,116]),StyleEnd:new Uint8Array([60,47,115,116,121,108,101]),TitleEnd:new Uint8Array([60,47,116,105,116,108,101]),TextareaEnd:new Uint8Array([60,47,116,101,120,116,97,114,101,97]),XmpEnd:new Uint8Array([60,47,120,109,112])};return t.default=class{constructor({xmlMode:t=!1,decodeEntities:e=!0},i){this.cbs=i,this.state=n.Text,this.buffer="",this.sectionStart=0,this.index=0,this.entityStart=0,this.baseState=n.Text,this.isSpecial=!1,this.running=!0,this.offset=0,this.currentSequence=void 0,this.sequenceIndex=0,this.xmlMode=t,this.decodeEntities=e,this.entityDecoder=new s.EntityDecoder(t?s.xmlDecodeTree:s.htmlDecodeTree,((t,e)=>this.emitCodePoint(t,e)))}reset(){this.state=n.Text,this.buffer="",this.sectionStart=0,this.index=0,this.baseState=n.Text,this.currentSequence=void 0,this.running=!0,this.offset=0}write(t){this.offset+=this.buffer.length,this.buffer=t,this.parse()}end(){this.running&&this.finish()}pause(){this.running=!1}resume(){this.running=!0,this.index<this.buffer.length+this.offset&&this.parse()}stateText(t){t===a.Lt||!this.decodeEntities&&this.fastForwardTo(a.Lt)?(this.index>this.sectionStart&&this.cbs.ontext(this.sectionStart,this.index),this.state=n.BeforeTagName,this.sectionStart=this.index):this.decodeEntities&&t===a.Amp&&this.startEntity()}stateSpecialStartSequence(t){const e=this.sequenceIndex===this.currentSequence.length;if(e?o(t):(32|t)===this.currentSequence[this.sequenceIndex]){if(!e)return void this.sequenceIndex++}else this.isSpecial=!1;this.sequenceIndex=0,this.state=n.InTagName,this.stateInTagName(t)}stateInSpecialTag(t){if(this.sequenceIndex===this.currentSequence.length){if(t===a.Gt||h(t)){const e=this.index-this.currentSequence.length;if(this.sectionStart<e){const t=this.index;this.index=e,this.cbs.ontext(this.sectionStart,e),this.index=t}return this.isSpecial=!1,this.sectionStart=e+2,void this.stateInClosingTagName(t)}this.sequenceIndex=0}(32|t)===this.currentSequence[this.sequenceIndex]?this.sequenceIndex+=1:0===this.sequenceIndex?this.currentSequence===c.TitleEnd?this.decodeEntities&&t===a.Amp&&this.startEntity():this.fastForwardTo(a.Lt)&&(this.sequenceIndex=1):this.sequenceIndex=Number(t===a.Lt)}stateCDATASequence(t){t===c.Cdata[this.sequenceIndex]?++this.sequenceIndex===c.Cdata.length&&(this.state=n.InCommentLike,this.currentSequence=c.CdataEnd,this.sequenceIndex=0,this.sectionStart=this.index+1):(this.sequenceIndex=0,this.state=n.InDeclaration,this.stateInDeclaration(t))}fastForwardTo(t){for(;++this.index<this.buffer.length+this.offset;)if(this.buffer.charCodeAt(this.index-this.offset)===t)return!0;return this.index=this.buffer.length+this.offset-1,!1}stateInCommentLike(t){t===this.currentSequence[this.sequenceIndex]?++this.sequenceIndex===this.currentSequence.length&&(this.currentSequence===c.CdataEnd?this.cbs.oncdata(this.sectionStart,this.index,2):this.cbs.oncomment(this.sectionStart,this.index,2),this.sequenceIndex=0,this.sectionStart=this.index+1,this.state=n.Text):0===this.sequenceIndex?this.fastForwardTo(this.currentSequence[0])&&(this.sequenceIndex=1):t!==this.currentSequence[this.sequenceIndex-1]&&(this.sequenceIndex=0)}isTagStartChar(t){return this.xmlMode?!o(t):function(t){return t>=a.LowerA&&t<=a.LowerZ||t>=a.UpperA&&t<=a.UpperZ}(t)}startSpecial(t,e){this.isSpecial=!0,this.currentSequence=t,this.sequenceIndex=e,this.state=n.SpecialStartSequence}stateBeforeTagName(t){if(t===a.ExclamationMark)this.state=n.BeforeDeclaration,this.sectionStart=this.index+1;else if(t===a.Questionmark)this.state=n.InProcessingInstruction,this.sectionStart=this.index+1;else if(this.isTagStartChar(t)){const e=32|t;this.sectionStart=this.index,this.xmlMode?this.state=n.InTagName:e===c.ScriptEnd[2]?this.state=n.BeforeSpecialS:e===c.TitleEnd[2]||e===c.XmpEnd[2]?this.state=n.BeforeSpecialT:this.state=n.InTagName}else t===a.Slash?this.state=n.BeforeClosingTagName:(this.state=n.Text,this.stateText(t))}stateInTagName(t){o(t)&&(this.cbs.onopentagname(this.sectionStart,this.index),this.sectionStart=-1,this.state=n.BeforeAttributeName,this.stateBeforeAttributeName(t))}stateBeforeClosingTagName(t){h(t)||(t===a.Gt?this.state=n.Text:(this.state=this.isTagStartChar(t)?n.InClosingTagName:n.InSpecialComment,this.sectionStart=this.index))}stateInClosingTagName(t){(t===a.Gt||h(t))&&(this.cbs.onclosetag(this.sectionStart,this.index),this.sectionStart=-1,this.state=n.AfterClosingTagName,this.stateAfterClosingTagName(t))}stateAfterClosingTagName(t){(t===a.Gt||this.fastForwardTo(a.Gt))&&(this.state=n.Text,this.sectionStart=this.index+1)}stateBeforeAttributeName(t){t===a.Gt?(this.cbs.onopentagend(this.index),this.isSpecial?(this.state=n.InSpecialTag,this.sequenceIndex=0):this.state=n.Text,this.sectionStart=this.index+1):t===a.Slash?this.state=n.InSelfClosingTag:h(t)||(this.state=n.InAttributeName,this.sectionStart=this.index)}stateInSelfClosingTag(t){t===a.Gt?(this.cbs.onselfclosingtag(this.index),this.state=n.Text,this.sectionStart=this.index+1,this.isSpecial=!1):h(t)||(this.state=n.BeforeAttributeName,this.stateBeforeAttributeName(t))}stateInAttributeName(t){(t===a.Eq||o(t))&&(this.cbs.onattribname(this.sectionStart,this.index),this.sectionStart=this.index,this.state=n.AfterAttributeName,this.stateAfterAttributeName(t))}stateAfterAttributeName(t){t===a.Eq?this.state=n.BeforeAttributeValue:t===a.Slash||t===a.Gt?(this.cbs.onattribend(r.NoValue,this.sectionStart),this.sectionStart=-1,this.state=n.BeforeAttributeName,this.stateBeforeAttributeName(t)):h(t)||(this.cbs.onattribend(r.NoValue,this.sectionStart),this.state=n.InAttributeName,this.sectionStart=this.index)}stateBeforeAttributeValue(t){t===a.DoubleQuote?(this.state=n.InAttributeValueDq,this.sectionStart=this.index+1):t===a.SingleQuote?(this.state=n.InAttributeValueSq,this.sectionStart=this.index+1):h(t)||(this.sectionStart=this.index,this.state=n.InAttributeValueNq,this.stateInAttributeValueNoQuotes(t))}handleInAttributeValue(t,e){t===e||!this.decodeEntities&&this.fastForwardTo(e)?(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=-1,this.cbs.onattribend(e===a.DoubleQuote?r.Double:r.Single,this.index+1),this.state=n.BeforeAttributeName):this.decodeEntities&&t===a.Amp&&this.startEntity()}stateInAttributeValueDoubleQuotes(t){this.handleInAttributeValue(t,a.DoubleQuote)}stateInAttributeValueSingleQuotes(t){this.handleInAttributeValue(t,a.SingleQuote)}stateInAttributeValueNoQuotes(t){h(t)||t===a.Gt?(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=-1,this.cbs.onattribend(r.Unquoted,this.index),this.state=n.BeforeAttributeName,this.stateBeforeAttributeName(t)):this.decodeEntities&&t===a.Amp&&this.startEntity()}stateBeforeDeclaration(t){t===a.OpeningSquareBracket?(this.state=n.CDATASequence,this.sequenceIndex=0):this.state=t===a.Dash?n.BeforeComment:n.InDeclaration}stateInDeclaration(t){(t===a.Gt||this.fastForwardTo(a.Gt))&&(this.cbs.ondeclaration(this.sectionStart,this.index),this.state=n.Text,this.sectionStart=this.index+1)}stateInProcessingInstruction(t){(t===a.Gt||this.fastForwardTo(a.Gt))&&(this.cbs.onprocessinginstruction(this.sectionStart,this.index),this.state=n.Text,this.sectionStart=this.index+1)}stateBeforeComment(t){t===a.Dash?(this.state=n.InCommentLike,this.currentSequence=c.CommentEnd,this.sequenceIndex=2,this.sectionStart=this.index+1):this.state=n.InDeclaration}stateInSpecialComment(t){(t===a.Gt||this.fastForwardTo(a.Gt))&&(this.cbs.oncomment(this.sectionStart,this.index,0),this.state=n.Text,this.sectionStart=this.index+1)}stateBeforeSpecialS(t){const e=32|t;e===c.ScriptEnd[3]?this.startSpecial(c.ScriptEnd,4):e===c.StyleEnd[3]?this.startSpecial(c.StyleEnd,4):(this.state=n.InTagName,this.stateInTagName(t))}stateBeforeSpecialT(t){switch(32|t){case c.TitleEnd[3]:this.startSpecial(c.TitleEnd,4);break;case c.TextareaEnd[3]:this.startSpecial(c.TextareaEnd,4);break;case c.XmpEnd[3]:this.startSpecial(c.XmpEnd,4);break;default:this.state=n.InTagName,this.stateInTagName(t)}}startEntity(){this.baseState=this.state,this.state=n.InEntity,this.entityStart=this.index,this.entityDecoder.startEntity(this.xmlMode?s.DecodingMode.Strict:this.baseState===n.Text||this.baseState===n.InSpecialTag?s.DecodingMode.Legacy:s.DecodingMode.Attribute)}stateInEntity(){const t=this.entityDecoder.write(this.buffer,this.index-this.offset);t>=0?(this.state=this.baseState,0===t&&(this.index=this.entityStart)):this.index=this.offset+this.buffer.length-1}cleanup(){this.running&&this.sectionStart!==this.index&&(this.state===n.Text||this.state===n.InSpecialTag&&0===this.sequenceIndex?(this.cbs.ontext(this.sectionStart,this.index),this.sectionStart=this.index):this.state!==n.InAttributeValueDq&&this.state!==n.InAttributeValueSq&&this.state!==n.InAttributeValueNq||(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=this.index))}shouldContinue(){return this.index<this.buffer.length+this.offset&&this.running}parse(){for(;this.shouldContinue();){const t=this.buffer.charCodeAt(this.index-this.offset);switch(this.state){case n.Text:this.stateText(t);break;case n.SpecialStartSequence:this.stateSpecialStartSequence(t);break;case n.InSpecialTag:this.stateInSpecialTag(t);break;case n.CDATASequence:this.stateCDATASequence(t);break;case n.InAttributeValueDq:this.stateInAttributeValueDoubleQuotes(t);break;case n.InAttributeName:this.stateInAttributeName(t);break;case n.InCommentLike:this.stateInCommentLike(t);break;case n.InSpecialComment:this.stateInSpecialComment(t);break;case n.BeforeAttributeName:this.stateBeforeAttributeName(t);break;case n.InTagName:this.stateInTagName(t);break;case n.InClosingTagName:this.stateInClosingTagName(t);break;case n.BeforeTagName:this.stateBeforeTagName(t);break;case n.AfterAttributeName:this.stateAfterAttributeName(t);break;case n.InAttributeValueSq:this.stateInAttributeValueSingleQuotes(t);break;case n.BeforeAttributeValue:this.stateBeforeAttributeValue(t);break;case n.BeforeClosingTagName:this.stateBeforeClosingTagName(t);break;case n.AfterClosingTagName:this.stateAfterClosingTagName(t);break;case n.BeforeSpecialS:this.stateBeforeSpecialS(t);break;case n.BeforeSpecialT:this.stateBeforeSpecialT(t);break;case n.InAttributeValueNq:this.stateInAttributeValueNoQuotes(t);break;case n.InSelfClosingTag:this.stateInSelfClosingTag(t);break;case n.InDeclaration:this.stateInDeclaration(t);break;case n.BeforeDeclaration:this.stateBeforeDeclaration(t);break;case n.BeforeComment:this.stateBeforeComment(t);break;case n.InProcessingInstruction:this.stateInProcessingInstruction(t);break;case n.InEntity:this.stateInEntity()}this.index++}this.cleanup()}finish(){this.state===n.InEntity&&(this.entityDecoder.end(),this.state=this.baseState),this.handleTrailingData(),this.cbs.onend()}handleTrailingData(){const t=this.buffer.length+this.offset;this.sectionStart>=t||(this.state===n.InCommentLike?this.currentSequence===c.CdataEnd?this.cbs.oncdata(this.sectionStart,t,0):this.cbs.oncomment(this.sectionStart,t,0):this.state===n.InTagName||this.state===n.BeforeAttributeName||this.state===n.BeforeAttributeValue||this.state===n.AfterAttributeName||this.state===n.InAttributeName||this.state===n.InAttributeValueSq||this.state===n.InAttributeValueDq||this.state===n.InAttributeValueNq||this.state===n.InClosingTagName||this.cbs.ontext(this.sectionStart,t))}emitCodePoint(t,e){this.baseState!==n.Text&&this.baseState!==n.InSpecialTag?(this.sectionStart<this.entityStart&&this.cbs.onattribdata(this.sectionStart,this.entityStart),this.sectionStart=this.entityStart+e,this.index=this.sectionStart-1,this.cbs.onattribentity(t)):(this.sectionStart<this.entityStart&&this.cbs.ontext(this.sectionStart,this.entityStart),this.sectionStart=this.entityStart+e,this.index=this.sectionStart-1,this.cbs.ontextentity(t,this.sectionStart))}},t}export{s as __require};
1
+ import{__exports as t}from"../../../../_virtual/Tokenizer.js";import{__require as e}from"../../../entities/dist/commonjs/decode.js";var i;function s(){if(i)return t;i=1,Object.defineProperty(t,"__esModule",{value:!0}),t.QuoteType=void 0;const s=e();var a,n,r;function h(t){return t===a.Space||t===a.NewLine||t===a.Tab||t===a.FormFeed||t===a.CarriageReturn}function o(t){return t===a.Slash||t===a.Gt||h(t)}!function(t){t[t.Tab=9]="Tab",t[t.NewLine=10]="NewLine",t[t.FormFeed=12]="FormFeed",t[t.CarriageReturn=13]="CarriageReturn",t[t.Space=32]="Space",t[t.ExclamationMark=33]="ExclamationMark",t[t.Number=35]="Number",t[t.Amp=38]="Amp",t[t.SingleQuote=39]="SingleQuote",t[t.DoubleQuote=34]="DoubleQuote",t[t.Dash=45]="Dash",t[t.Slash=47]="Slash",t[t.Zero=48]="Zero",t[t.Nine=57]="Nine",t[t.Semi=59]="Semi",t[t.Lt=60]="Lt",t[t.Eq=61]="Eq",t[t.Gt=62]="Gt",t[t.Questionmark=63]="Questionmark",t[t.UpperA=65]="UpperA",t[t.LowerA=97]="LowerA",t[t.UpperF=70]="UpperF",t[t.LowerF=102]="LowerF",t[t.UpperZ=90]="UpperZ",t[t.LowerZ=122]="LowerZ",t[t.LowerX=120]="LowerX",t[t.OpeningSquareBracket=91]="OpeningSquareBracket"}(a||(a={})),function(t){t[t.Text=1]="Text",t[t.BeforeTagName=2]="BeforeTagName",t[t.InTagName=3]="InTagName",t[t.InSelfClosingTag=4]="InSelfClosingTag",t[t.BeforeClosingTagName=5]="BeforeClosingTagName",t[t.InClosingTagName=6]="InClosingTagName",t[t.AfterClosingTagName=7]="AfterClosingTagName",t[t.BeforeAttributeName=8]="BeforeAttributeName",t[t.InAttributeName=9]="InAttributeName",t[t.AfterAttributeName=10]="AfterAttributeName",t[t.BeforeAttributeValue=11]="BeforeAttributeValue",t[t.InAttributeValueDq=12]="InAttributeValueDq",t[t.InAttributeValueSq=13]="InAttributeValueSq",t[t.InAttributeValueNq=14]="InAttributeValueNq",t[t.BeforeDeclaration=15]="BeforeDeclaration",t[t.InDeclaration=16]="InDeclaration",t[t.InProcessingInstruction=17]="InProcessingInstruction",t[t.BeforeComment=18]="BeforeComment",t[t.CDATASequence=19]="CDATASequence",t[t.InSpecialComment=20]="InSpecialComment",t[t.InCommentLike=21]="InCommentLike",t[t.BeforeSpecialS=22]="BeforeSpecialS",t[t.BeforeSpecialT=23]="BeforeSpecialT",t[t.SpecialStartSequence=24]="SpecialStartSequence",t[t.InSpecialTag=25]="InSpecialTag",t[t.InEntity=26]="InEntity"}(n||(n={})),function(t){t[t.NoValue=0]="NoValue",t[t.Unquoted=1]="Unquoted",t[t.Single=2]="Single",t[t.Double=3]="Double"}(r||(t.QuoteType=r={}));const c={Cdata:new Uint8Array([67,68,65,84,65,91]),CdataEnd:new Uint8Array([93,93,62]),CommentEnd:new Uint8Array([45,45,62]),ScriptEnd:new Uint8Array([60,47,115,99,114,105,112,116]),StyleEnd:new Uint8Array([60,47,115,116,121,108,101]),TitleEnd:new Uint8Array([60,47,116,105,116,108,101]),TextareaEnd:new Uint8Array([60,47,116,101,120,116,97,114,101,97]),XmpEnd:new Uint8Array([60,47,120,109,112])};return t.default=class{constructor({xmlMode:t=!1,decodeEntities:e=!0},i){this.cbs=i,this.state=n.Text,this.buffer="",this.sectionStart=0,this.index=0,this.entityStart=0,this.baseState=n.Text,this.isSpecial=!1,this.running=!0,this.offset=0,this.currentSequence=void 0,this.sequenceIndex=0,this.xmlMode=t,this.decodeEntities=e,this.entityDecoder=new s.EntityDecoder(t?s.xmlDecodeTree:s.htmlDecodeTree,((t,e)=>this.emitCodePoint(t,e)))}reset(){this.state=n.Text,this.buffer="",this.sectionStart=0,this.index=0,this.baseState=n.Text,this.currentSequence=void 0,this.running=!0,this.offset=0}write(t){this.offset+=this.buffer.length,this.buffer=t,this.parse()}end(){this.running&&this.finish()}pause(){this.running=!1}resume(){this.running=!0,this.index<this.buffer.length+this.offset&&this.parse()}stateText(t){t===a.Lt||!this.decodeEntities&&this.fastForwardTo(a.Lt)?(this.index>this.sectionStart&&this.cbs.ontext(this.sectionStart,this.index),this.state=n.BeforeTagName,this.sectionStart=this.index):this.decodeEntities&&t===a.Amp&&this.startEntity()}stateSpecialStartSequence(t){const e=this.sequenceIndex===this.currentSequence.length;if(e?o(t):(32|t)===this.currentSequence[this.sequenceIndex]){if(!e)return void this.sequenceIndex++}else this.isSpecial=!1;this.sequenceIndex=0,this.state=n.InTagName,this.stateInTagName(t)}stateInSpecialTag(t){if(this.sequenceIndex===this.currentSequence.length){if(t===a.Gt||h(t)){const e=this.index-this.currentSequence.length;if(this.sectionStart<e){const t=this.index;this.index=e,this.cbs.ontext(this.sectionStart,e),this.index=t}return this.isSpecial=!1,this.sectionStart=e+2,void this.stateInClosingTagName(t)}this.sequenceIndex=0}(32|t)===this.currentSequence[this.sequenceIndex]?this.sequenceIndex+=1:0===this.sequenceIndex?this.currentSequence===c.TitleEnd?this.decodeEntities&&t===a.Amp&&this.startEntity():this.fastForwardTo(a.Lt)&&(this.sequenceIndex=1):this.sequenceIndex=Number(t===a.Lt)}stateCDATASequence(t){t===c.Cdata[this.sequenceIndex]?++this.sequenceIndex===c.Cdata.length&&(this.state=n.InCommentLike,this.currentSequence=c.CdataEnd,this.sequenceIndex=0,this.sectionStart=this.index+1):(this.sequenceIndex=0,this.state=n.InDeclaration,this.stateInDeclaration(t))}fastForwardTo(t){for(;++this.index<this.buffer.length+this.offset;)if(this.buffer.charCodeAt(this.index-this.offset)===t)return!0;return this.index=this.buffer.length+this.offset-1,!1}stateInCommentLike(t){t===this.currentSequence[this.sequenceIndex]?++this.sequenceIndex===this.currentSequence.length&&(this.currentSequence===c.CdataEnd?this.cbs.oncdata(this.sectionStart,this.index,2):this.cbs.oncomment(this.sectionStart,this.index,2),this.sequenceIndex=0,this.sectionStart=this.index+1,this.state=n.Text):0===this.sequenceIndex?this.fastForwardTo(this.currentSequence[0])&&(this.sequenceIndex=1):t!==this.currentSequence[this.sequenceIndex-1]&&(this.sequenceIndex=0)}isTagStartChar(t){return this.xmlMode?!o(t):function(t){return t>=a.LowerA&&t<=a.LowerZ||t>=a.UpperA&&t<=a.UpperZ}(t)}startSpecial(t,e){this.isSpecial=!0,this.currentSequence=t,this.sequenceIndex=e,this.state=n.SpecialStartSequence}stateBeforeTagName(t){if(t===a.ExclamationMark)this.state=n.BeforeDeclaration,this.sectionStart=this.index+1;else if(t===a.Questionmark)this.state=n.InProcessingInstruction,this.sectionStart=this.index+1;else if(this.isTagStartChar(t)){const e=32|t;this.sectionStart=this.index,this.xmlMode?this.state=n.InTagName:e===c.ScriptEnd[2]?this.state=n.BeforeSpecialS:e===c.TitleEnd[2]||e===c.XmpEnd[2]?this.state=n.BeforeSpecialT:this.state=n.InTagName}else t===a.Slash?this.state=n.BeforeClosingTagName:(this.state=n.Text,this.stateText(t))}stateInTagName(t){o(t)&&(this.cbs.onopentagname(this.sectionStart,this.index),this.sectionStart=-1,this.state=n.BeforeAttributeName,this.stateBeforeAttributeName(t))}stateBeforeClosingTagName(t){h(t)||(t===a.Gt?this.state=n.Text:(this.state=this.isTagStartChar(t)?n.InClosingTagName:n.InSpecialComment,this.sectionStart=this.index))}stateInClosingTagName(t){(t===a.Gt||h(t))&&(this.cbs.onclosetag(this.sectionStart,this.index),this.sectionStart=-1,this.state=n.AfterClosingTagName,this.stateAfterClosingTagName(t))}stateAfterClosingTagName(t){(t===a.Gt||this.fastForwardTo(a.Gt))&&(this.state=n.Text,this.sectionStart=this.index+1)}stateBeforeAttributeName(t){t===a.Gt?(this.cbs.onopentagend(this.index),this.isSpecial?(this.state=n.InSpecialTag,this.sequenceIndex=0):this.state=n.Text,this.sectionStart=this.index+1):t===a.Slash?this.state=n.InSelfClosingTag:h(t)||(this.state=n.InAttributeName,this.sectionStart=this.index)}stateInSelfClosingTag(t){t===a.Gt?(this.cbs.onselfclosingtag(this.index),this.state=n.Text,this.sectionStart=this.index+1,this.isSpecial=!1):h(t)||(this.state=n.BeforeAttributeName,this.stateBeforeAttributeName(t))}stateInAttributeName(t){(t===a.Eq||o(t))&&(this.cbs.onattribname(this.sectionStart,this.index),this.sectionStart=this.index,this.state=n.AfterAttributeName,this.stateAfterAttributeName(t))}stateAfterAttributeName(t){t===a.Eq?this.state=n.BeforeAttributeValue:t===a.Slash||t===a.Gt?(this.cbs.onattribend(r.NoValue,this.sectionStart),this.sectionStart=-1,this.state=n.BeforeAttributeName,this.stateBeforeAttributeName(t)):h(t)||(this.cbs.onattribend(r.NoValue,this.sectionStart),this.state=n.InAttributeName,this.sectionStart=this.index)}stateBeforeAttributeValue(t){t===a.DoubleQuote?(this.state=n.InAttributeValueDq,this.sectionStart=this.index+1):t===a.SingleQuote?(this.state=n.InAttributeValueSq,this.sectionStart=this.index+1):h(t)||(this.sectionStart=this.index,this.state=n.InAttributeValueNq,this.stateInAttributeValueNoQuotes(t))}handleInAttributeValue(t,e){t===e||!this.decodeEntities&&this.fastForwardTo(e)?(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=-1,this.cbs.onattribend(e===a.DoubleQuote?r.Double:r.Single,this.index+1),this.state=n.BeforeAttributeName):this.decodeEntities&&t===a.Amp&&this.startEntity()}stateInAttributeValueDoubleQuotes(t){this.handleInAttributeValue(t,a.DoubleQuote)}stateInAttributeValueSingleQuotes(t){this.handleInAttributeValue(t,a.SingleQuote)}stateInAttributeValueNoQuotes(t){h(t)||t===a.Gt?(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=-1,this.cbs.onattribend(r.Unquoted,this.index),this.state=n.BeforeAttributeName,this.stateBeforeAttributeName(t)):this.decodeEntities&&t===a.Amp&&this.startEntity()}stateBeforeDeclaration(t){t===a.OpeningSquareBracket?(this.state=n.CDATASequence,this.sequenceIndex=0):this.state=t===a.Dash?n.BeforeComment:n.InDeclaration}stateInDeclaration(t){(t===a.Gt||this.fastForwardTo(a.Gt))&&(this.cbs.ondeclaration(this.sectionStart,this.index),this.state=n.Text,this.sectionStart=this.index+1)}stateInProcessingInstruction(t){(t===a.Gt||this.fastForwardTo(a.Gt))&&(this.cbs.onprocessinginstruction(this.sectionStart,this.index),this.state=n.Text,this.sectionStart=this.index+1)}stateBeforeComment(t){t===a.Dash?(this.state=n.InCommentLike,this.currentSequence=c.CommentEnd,this.sequenceIndex=2,this.sectionStart=this.index+1):this.state=n.InDeclaration}stateInSpecialComment(t){(t===a.Gt||this.fastForwardTo(a.Gt))&&(this.cbs.oncomment(this.sectionStart,this.index,0),this.state=n.Text,this.sectionStart=this.index+1)}stateBeforeSpecialS(t){const e=32|t;e===c.ScriptEnd[3]?this.startSpecial(c.ScriptEnd,4):e===c.StyleEnd[3]?this.startSpecial(c.StyleEnd,4):(this.state=n.InTagName,this.stateInTagName(t))}stateBeforeSpecialT(t){switch(32|t){case c.TitleEnd[3]:this.startSpecial(c.TitleEnd,4);break;case c.TextareaEnd[3]:this.startSpecial(c.TextareaEnd,4);break;case c.XmpEnd[3]:this.startSpecial(c.XmpEnd,4);break;default:this.state=n.InTagName,this.stateInTagName(t)}}startEntity(){this.baseState=this.state,this.state=n.InEntity,this.entityStart=this.index,this.entityDecoder.startEntity(this.xmlMode?s.DecodingMode.Strict:this.baseState===n.Text||this.baseState===n.InSpecialTag?s.DecodingMode.Legacy:s.DecodingMode.Attribute)}stateInEntity(){const t=this.entityDecoder.write(this.buffer,this.index-this.offset);t>=0?(this.state=this.baseState,0===t&&(this.index=this.entityStart)):this.index=this.offset+this.buffer.length-1}cleanup(){this.running&&this.sectionStart!==this.index&&(this.state===n.Text||this.state===n.InSpecialTag&&0===this.sequenceIndex?(this.cbs.ontext(this.sectionStart,this.index),this.sectionStart=this.index):this.state!==n.InAttributeValueDq&&this.state!==n.InAttributeValueSq&&this.state!==n.InAttributeValueNq||(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=this.index))}shouldContinue(){return this.index<this.buffer.length+this.offset&&this.running}parse(){for(;this.shouldContinue();){const t=this.buffer.charCodeAt(this.index-this.offset);switch(this.state){case n.Text:this.stateText(t);break;case n.SpecialStartSequence:this.stateSpecialStartSequence(t);break;case n.InSpecialTag:this.stateInSpecialTag(t);break;case n.CDATASequence:this.stateCDATASequence(t);break;case n.InAttributeValueDq:this.stateInAttributeValueDoubleQuotes(t);break;case n.InAttributeName:this.stateInAttributeName(t);break;case n.InCommentLike:this.stateInCommentLike(t);break;case n.InSpecialComment:this.stateInSpecialComment(t);break;case n.BeforeAttributeName:this.stateBeforeAttributeName(t);break;case n.InTagName:this.stateInTagName(t);break;case n.InClosingTagName:this.stateInClosingTagName(t);break;case n.BeforeTagName:this.stateBeforeTagName(t);break;case n.AfterAttributeName:this.stateAfterAttributeName(t);break;case n.InAttributeValueSq:this.stateInAttributeValueSingleQuotes(t);break;case n.BeforeAttributeValue:this.stateBeforeAttributeValue(t);break;case n.BeforeClosingTagName:this.stateBeforeClosingTagName(t);break;case n.AfterClosingTagName:this.stateAfterClosingTagName(t);break;case n.BeforeSpecialS:this.stateBeforeSpecialS(t);break;case n.BeforeSpecialT:this.stateBeforeSpecialT(t);break;case n.InAttributeValueNq:this.stateInAttributeValueNoQuotes(t);break;case n.InSelfClosingTag:this.stateInSelfClosingTag(t);break;case n.InDeclaration:this.stateInDeclaration(t);break;case n.BeforeDeclaration:this.stateBeforeDeclaration(t);break;case n.BeforeComment:this.stateBeforeComment(t);break;case n.InProcessingInstruction:this.stateInProcessingInstruction(t);break;case n.InEntity:this.stateInEntity()}this.index++}this.cleanup()}finish(){this.state===n.InEntity&&(this.entityDecoder.end(),this.state=this.baseState),this.handleTrailingData(),this.cbs.onend()}handleTrailingData(){const t=this.buffer.length+this.offset;this.sectionStart>=t||(this.state===n.InCommentLike?this.currentSequence===c.CdataEnd?this.cbs.oncdata(this.sectionStart,t,0):this.cbs.oncomment(this.sectionStart,t,0):this.state===n.InTagName||this.state===n.BeforeAttributeName||this.state===n.BeforeAttributeValue||this.state===n.AfterAttributeName||this.state===n.InAttributeName||this.state===n.InAttributeValueSq||this.state===n.InAttributeValueDq||this.state===n.InAttributeValueNq||this.state===n.InClosingTagName||this.cbs.ontext(this.sectionStart,t))}emitCodePoint(t,e){this.baseState!==n.Text&&this.baseState!==n.InSpecialTag?(this.sectionStart<this.entityStart&&this.cbs.onattribdata(this.sectionStart,this.entityStart),this.sectionStart=this.entityStart+e,this.index=this.sectionStart-1,this.cbs.onattribentity(t)):(this.sectionStart<this.entityStart&&this.cbs.ontext(this.sectionStart,this.entityStart),this.sectionStart=this.entityStart+e,this.index=this.sectionStart-1,this.cbs.ontextentity(t,this.sectionStart))}},t}export{s as __require};
2
2
  //# sourceMappingURL=Tokenizer.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Tokenizer.js","sources":["../../../../../node_modules/htmlparser2/dist/commonjs/Tokenizer.js"],"sourcesContent":["\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.QuoteType = void 0;\nconst decode_1 = require(\"entities/decode\");\nvar CharCodes;\n(function (CharCodes) {\n CharCodes[CharCodes[\"Tab\"] = 9] = \"Tab\";\n CharCodes[CharCodes[\"NewLine\"] = 10] = \"NewLine\";\n CharCodes[CharCodes[\"FormFeed\"] = 12] = \"FormFeed\";\n CharCodes[CharCodes[\"CarriageReturn\"] = 13] = \"CarriageReturn\";\n CharCodes[CharCodes[\"Space\"] = 32] = \"Space\";\n CharCodes[CharCodes[\"ExclamationMark\"] = 33] = \"ExclamationMark\";\n CharCodes[CharCodes[\"Number\"] = 35] = \"Number\";\n CharCodes[CharCodes[\"Amp\"] = 38] = \"Amp\";\n CharCodes[CharCodes[\"SingleQuote\"] = 39] = \"SingleQuote\";\n CharCodes[CharCodes[\"DoubleQuote\"] = 34] = \"DoubleQuote\";\n CharCodes[CharCodes[\"Dash\"] = 45] = \"Dash\";\n CharCodes[CharCodes[\"Slash\"] = 47] = \"Slash\";\n CharCodes[CharCodes[\"Zero\"] = 48] = \"Zero\";\n CharCodes[CharCodes[\"Nine\"] = 57] = \"Nine\";\n CharCodes[CharCodes[\"Semi\"] = 59] = \"Semi\";\n CharCodes[CharCodes[\"Lt\"] = 60] = \"Lt\";\n CharCodes[CharCodes[\"Eq\"] = 61] = \"Eq\";\n CharCodes[CharCodes[\"Gt\"] = 62] = \"Gt\";\n CharCodes[CharCodes[\"Questionmark\"] = 63] = \"Questionmark\";\n CharCodes[CharCodes[\"UpperA\"] = 65] = \"UpperA\";\n CharCodes[CharCodes[\"LowerA\"] = 97] = \"LowerA\";\n CharCodes[CharCodes[\"UpperF\"] = 70] = \"UpperF\";\n CharCodes[CharCodes[\"LowerF\"] = 102] = \"LowerF\";\n CharCodes[CharCodes[\"UpperZ\"] = 90] = \"UpperZ\";\n CharCodes[CharCodes[\"LowerZ\"] = 122] = \"LowerZ\";\n CharCodes[CharCodes[\"LowerX\"] = 120] = \"LowerX\";\n CharCodes[CharCodes[\"OpeningSquareBracket\"] = 91] = \"OpeningSquareBracket\";\n})(CharCodes || (CharCodes = {}));\n/** All the states the tokenizer can be in. */\nvar State;\n(function (State) {\n State[State[\"Text\"] = 1] = \"Text\";\n State[State[\"BeforeTagName\"] = 2] = \"BeforeTagName\";\n State[State[\"InTagName\"] = 3] = \"InTagName\";\n State[State[\"InSelfClosingTag\"] = 4] = \"InSelfClosingTag\";\n State[State[\"BeforeClosingTagName\"] = 5] = \"BeforeClosingTagName\";\n State[State[\"InClosingTagName\"] = 6] = \"InClosingTagName\";\n State[State[\"AfterClosingTagName\"] = 7] = \"AfterClosingTagName\";\n // Attributes\n State[State[\"BeforeAttributeName\"] = 8] = \"BeforeAttributeName\";\n State[State[\"InAttributeName\"] = 9] = \"InAttributeName\";\n State[State[\"AfterAttributeName\"] = 10] = \"AfterAttributeName\";\n State[State[\"BeforeAttributeValue\"] = 11] = \"BeforeAttributeValue\";\n State[State[\"InAttributeValueDq\"] = 12] = \"InAttributeValueDq\";\n State[State[\"InAttributeValueSq\"] = 13] = \"InAttributeValueSq\";\n State[State[\"InAttributeValueNq\"] = 14] = \"InAttributeValueNq\";\n // Declarations\n State[State[\"BeforeDeclaration\"] = 15] = \"BeforeDeclaration\";\n State[State[\"InDeclaration\"] = 16] = \"InDeclaration\";\n // Processing instructions\n State[State[\"InProcessingInstruction\"] = 17] = \"InProcessingInstruction\";\n // Comments & CDATA\n State[State[\"BeforeComment\"] = 18] = \"BeforeComment\";\n State[State[\"CDATASequence\"] = 19] = \"CDATASequence\";\n State[State[\"InSpecialComment\"] = 20] = \"InSpecialComment\";\n State[State[\"InCommentLike\"] = 21] = \"InCommentLike\";\n // Special tags\n State[State[\"BeforeSpecialS\"] = 22] = \"BeforeSpecialS\";\n State[State[\"BeforeSpecialT\"] = 23] = \"BeforeSpecialT\";\n State[State[\"SpecialStartSequence\"] = 24] = \"SpecialStartSequence\";\n State[State[\"InSpecialTag\"] = 25] = \"InSpecialTag\";\n State[State[\"InEntity\"] = 26] = \"InEntity\";\n})(State || (State = {}));\nfunction isWhitespace(c) {\n return (c === CharCodes.Space ||\n c === CharCodes.NewLine ||\n c === CharCodes.Tab ||\n c === CharCodes.FormFeed ||\n c === CharCodes.CarriageReturn);\n}\nfunction isEndOfTagSection(c) {\n return c === CharCodes.Slash || c === CharCodes.Gt || isWhitespace(c);\n}\nfunction isASCIIAlpha(c) {\n return ((c >= CharCodes.LowerA && c <= CharCodes.LowerZ) ||\n (c >= CharCodes.UpperA && c <= CharCodes.UpperZ));\n}\nvar QuoteType;\n(function (QuoteType) {\n QuoteType[QuoteType[\"NoValue\"] = 0] = \"NoValue\";\n QuoteType[QuoteType[\"Unquoted\"] = 1] = \"Unquoted\";\n QuoteType[QuoteType[\"Single\"] = 2] = \"Single\";\n QuoteType[QuoteType[\"Double\"] = 3] = \"Double\";\n})(QuoteType || (exports.QuoteType = QuoteType = {}));\n/**\n * Sequences used to match longer strings.\n *\n * We don't have `Script`, `Style`, or `Title` here. Instead, we re-use the *End\n * sequences with an increased offset.\n */\nconst Sequences = {\n Cdata: new Uint8Array([0x43, 0x44, 0x41, 0x54, 0x41, 0x5b]), // CDATA[\n CdataEnd: new Uint8Array([0x5d, 0x5d, 0x3e]), // ]]>\n CommentEnd: new Uint8Array([0x2d, 0x2d, 0x3e]), // `-->`\n ScriptEnd: new Uint8Array([0x3c, 0x2f, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74]), // `</script`\n StyleEnd: new Uint8Array([0x3c, 0x2f, 0x73, 0x74, 0x79, 0x6c, 0x65]), // `</style`\n TitleEnd: new Uint8Array([0x3c, 0x2f, 0x74, 0x69, 0x74, 0x6c, 0x65]), // `</title`\n TextareaEnd: new Uint8Array([\n 0x3c, 0x2f, 0x74, 0x65, 0x78, 0x74, 0x61, 0x72, 0x65, 0x61,\n ]), // `</textarea`\n XmpEnd: new Uint8Array([0x3c, 0x2f, 0x78, 0x6d, 0x70]), // `</xmp`\n};\nclass Tokenizer {\n constructor({ xmlMode = false, decodeEntities = true, }, cbs) {\n this.cbs = cbs;\n /** The current state the tokenizer is in. */\n this.state = State.Text;\n /** The read buffer. */\n this.buffer = \"\";\n /** The beginning of the section that is currently being read. */\n this.sectionStart = 0;\n /** The index within the buffer that we are currently looking at. */\n this.index = 0;\n /** The start of the last entity. */\n this.entityStart = 0;\n /** Some behavior, eg. when decoding entities, is done while we are in another state. This keeps track of the other state type. */\n this.baseState = State.Text;\n /** For special parsing behavior inside of script and style tags. */\n this.isSpecial = false;\n /** Indicates whether the tokenizer has been paused. */\n this.running = true;\n /** The offset of the current buffer. */\n this.offset = 0;\n this.currentSequence = undefined;\n this.sequenceIndex = 0;\n this.xmlMode = xmlMode;\n this.decodeEntities = decodeEntities;\n this.entityDecoder = new decode_1.EntityDecoder(xmlMode ? decode_1.xmlDecodeTree : decode_1.htmlDecodeTree, (cp, consumed) => this.emitCodePoint(cp, consumed));\n }\n reset() {\n this.state = State.Text;\n this.buffer = \"\";\n this.sectionStart = 0;\n this.index = 0;\n this.baseState = State.Text;\n this.currentSequence = undefined;\n this.running = true;\n this.offset = 0;\n }\n write(chunk) {\n this.offset += this.buffer.length;\n this.buffer = chunk;\n this.parse();\n }\n end() {\n if (this.running)\n this.finish();\n }\n pause() {\n this.running = false;\n }\n resume() {\n this.running = true;\n if (this.index < this.buffer.length + this.offset) {\n this.parse();\n }\n }\n stateText(c) {\n if (c === CharCodes.Lt ||\n (!this.decodeEntities && this.fastForwardTo(CharCodes.Lt))) {\n if (this.index > this.sectionStart) {\n this.cbs.ontext(this.sectionStart, this.index);\n }\n this.state = State.BeforeTagName;\n this.sectionStart = this.index;\n }\n else if (this.decodeEntities && c === CharCodes.Amp) {\n this.startEntity();\n }\n }\n stateSpecialStartSequence(c) {\n const isEnd = this.sequenceIndex === this.currentSequence.length;\n const isMatch = isEnd\n ? // If we are at the end of the sequence, make sure the tag name has ended\n isEndOfTagSection(c)\n : // Otherwise, do a case-insensitive comparison\n (c | 0x20) === this.currentSequence[this.sequenceIndex];\n if (!isMatch) {\n this.isSpecial = false;\n }\n else if (!isEnd) {\n this.sequenceIndex++;\n return;\n }\n this.sequenceIndex = 0;\n this.state = State.InTagName;\n this.stateInTagName(c);\n }\n /** Look for an end tag. For <title> tags, also decode entities. */\n stateInSpecialTag(c) {\n if (this.sequenceIndex === this.currentSequence.length) {\n if (c === CharCodes.Gt || isWhitespace(c)) {\n const endOfText = this.index - this.currentSequence.length;\n if (this.sectionStart < endOfText) {\n // Spoof the index so that reported locations match up.\n const actualIndex = this.index;\n this.index = endOfText;\n this.cbs.ontext(this.sectionStart, endOfText);\n this.index = actualIndex;\n }\n this.isSpecial = false;\n this.sectionStart = endOfText + 2; // Skip over the `</`\n this.stateInClosingTagName(c);\n return; // We are done; skip the rest of the function.\n }\n this.sequenceIndex = 0;\n }\n if ((c | 0x20) === this.currentSequence[this.sequenceIndex]) {\n this.sequenceIndex += 1;\n }\n else if (this.sequenceIndex === 0) {\n if (this.currentSequence === Sequences.TitleEnd) {\n // We have to parse entities in <title> tags.\n if (this.decodeEntities && c === CharCodes.Amp) {\n this.startEntity();\n }\n }\n else if (this.fastForwardTo(CharCodes.Lt)) {\n // Outside of <title> tags, we can fast-forward.\n this.sequenceIndex = 1;\n }\n }\n else {\n // If we see a `<`, set the sequence index to 1; useful for eg. `<</script>`.\n this.sequenceIndex = Number(c === CharCodes.Lt);\n }\n }\n stateCDATASequence(c) {\n if (c === Sequences.Cdata[this.sequenceIndex]) {\n if (++this.sequenceIndex === Sequences.Cdata.length) {\n this.state = State.InCommentLike;\n this.currentSequence = Sequences.CdataEnd;\n this.sequenceIndex = 0;\n this.sectionStart = this.index + 1;\n }\n }\n else {\n this.sequenceIndex = 0;\n this.state = State.InDeclaration;\n this.stateInDeclaration(c); // Reconsume the character\n }\n }\n /**\n * When we wait for one specific character, we can speed things up\n * by skipping through the buffer until we find it.\n *\n * @returns Whether the character was found.\n */\n fastForwardTo(c) {\n while (++this.index < this.buffer.length + this.offset) {\n if (this.buffer.charCodeAt(this.index - this.offset) === c) {\n return true;\n }\n }\n /*\n * We increment the index at the end of the `parse` loop,\n * so set it to `buffer.length - 1` here.\n *\n * TODO: Refactor `parse` to increment index before calling states.\n */\n this.index = this.buffer.length + this.offset - 1;\n return false;\n }\n /**\n * Comments and CDATA end with `-->` and `]]>`.\n *\n * Their common qualities are:\n * - Their end sequences have a distinct character they start with.\n * - That character is then repeated, so we have to check multiple repeats.\n * - All characters but the start character of the sequence can be skipped.\n */\n stateInCommentLike(c) {\n if (c === this.currentSequence[this.sequenceIndex]) {\n if (++this.sequenceIndex === this.currentSequence.length) {\n if (this.currentSequence === Sequences.CdataEnd) {\n this.cbs.oncdata(this.sectionStart, this.index, 2);\n }\n else {\n this.cbs.oncomment(this.sectionStart, this.index, 2);\n }\n this.sequenceIndex = 0;\n this.sectionStart = this.index + 1;\n this.state = State.Text;\n }\n }\n else if (this.sequenceIndex === 0) {\n // Fast-forward to the first character of the sequence\n if (this.fastForwardTo(this.currentSequence[0])) {\n this.sequenceIndex = 1;\n }\n }\n else if (c !== this.currentSequence[this.sequenceIndex - 1]) {\n // Allow long sequences, eg. --->, ]]]>\n this.sequenceIndex = 0;\n }\n }\n /**\n * HTML only allows ASCII alpha characters (a-z and A-Z) at the beginning of a tag name.\n *\n * XML allows a lot more characters here (@see https://www.w3.org/TR/REC-xml/#NT-NameStartChar).\n * We allow anything that wouldn't end the tag.\n */\n isTagStartChar(c) {\n return this.xmlMode ? !isEndOfTagSection(c) : isASCIIAlpha(c);\n }\n startSpecial(sequence, offset) {\n this.isSpecial = true;\n this.currentSequence = sequence;\n this.sequenceIndex = offset;\n this.state = State.SpecialStartSequence;\n }\n stateBeforeTagName(c) {\n if (c === CharCodes.ExclamationMark) {\n this.state = State.BeforeDeclaration;\n this.sectionStart = this.index + 1;\n }\n else if (c === CharCodes.Questionmark) {\n this.state = State.InProcessingInstruction;\n this.sectionStart = this.index + 1;\n }\n else if (this.isTagStartChar(c)) {\n const lower = c | 0x20;\n this.sectionStart = this.index;\n if (this.xmlMode) {\n this.state = State.InTagName;\n }\n else if (lower === Sequences.ScriptEnd[2]) {\n this.state = State.BeforeSpecialS;\n }\n else if (lower === Sequences.TitleEnd[2] ||\n lower === Sequences.XmpEnd[2]) {\n this.state = State.BeforeSpecialT;\n }\n else {\n this.state = State.InTagName;\n }\n }\n else if (c === CharCodes.Slash) {\n this.state = State.BeforeClosingTagName;\n }\n else {\n this.state = State.Text;\n this.stateText(c);\n }\n }\n stateInTagName(c) {\n if (isEndOfTagSection(c)) {\n this.cbs.onopentagname(this.sectionStart, this.index);\n this.sectionStart = -1;\n this.state = State.BeforeAttributeName;\n this.stateBeforeAttributeName(c);\n }\n }\n stateBeforeClosingTagName(c) {\n if (isWhitespace(c)) {\n // Ignore\n }\n else if (c === CharCodes.Gt) {\n this.state = State.Text;\n }\n else {\n this.state = this.isTagStartChar(c)\n ? State.InClosingTagName\n : State.InSpecialComment;\n this.sectionStart = this.index;\n }\n }\n stateInClosingTagName(c) {\n if (c === CharCodes.Gt || isWhitespace(c)) {\n this.cbs.onclosetag(this.sectionStart, this.index);\n this.sectionStart = -1;\n this.state = State.AfterClosingTagName;\n this.stateAfterClosingTagName(c);\n }\n }\n stateAfterClosingTagName(c) {\n // Skip everything until \">\"\n if (c === CharCodes.Gt || this.fastForwardTo(CharCodes.Gt)) {\n this.state = State.Text;\n this.sectionStart = this.index + 1;\n }\n }\n stateBeforeAttributeName(c) {\n if (c === CharCodes.Gt) {\n this.cbs.onopentagend(this.index);\n if (this.isSpecial) {\n this.state = State.InSpecialTag;\n this.sequenceIndex = 0;\n }\n else {\n this.state = State.Text;\n }\n this.sectionStart = this.index + 1;\n }\n else if (c === CharCodes.Slash) {\n this.state = State.InSelfClosingTag;\n }\n else if (!isWhitespace(c)) {\n this.state = State.InAttributeName;\n this.sectionStart = this.index;\n }\n }\n stateInSelfClosingTag(c) {\n if (c === CharCodes.Gt) {\n this.cbs.onselfclosingtag(this.index);\n this.state = State.Text;\n this.sectionStart = this.index + 1;\n this.isSpecial = false; // Reset special state, in case of self-closing special tags\n }\n else if (!isWhitespace(c)) {\n this.state = State.BeforeAttributeName;\n this.stateBeforeAttributeName(c);\n }\n }\n stateInAttributeName(c) {\n if (c === CharCodes.Eq || isEndOfTagSection(c)) {\n this.cbs.onattribname(this.sectionStart, this.index);\n this.sectionStart = this.index;\n this.state = State.AfterAttributeName;\n this.stateAfterAttributeName(c);\n }\n }\n stateAfterAttributeName(c) {\n if (c === CharCodes.Eq) {\n this.state = State.BeforeAttributeValue;\n }\n else if (c === CharCodes.Slash || c === CharCodes.Gt) {\n this.cbs.onattribend(QuoteType.NoValue, this.sectionStart);\n this.sectionStart = -1;\n this.state = State.BeforeAttributeName;\n this.stateBeforeAttributeName(c);\n }\n else if (!isWhitespace(c)) {\n this.cbs.onattribend(QuoteType.NoValue, this.sectionStart);\n this.state = State.InAttributeName;\n this.sectionStart = this.index;\n }\n }\n stateBeforeAttributeValue(c) {\n if (c === CharCodes.DoubleQuote) {\n this.state = State.InAttributeValueDq;\n this.sectionStart = this.index + 1;\n }\n else if (c === CharCodes.SingleQuote) {\n this.state = State.InAttributeValueSq;\n this.sectionStart = this.index + 1;\n }\n else if (!isWhitespace(c)) {\n this.sectionStart = this.index;\n this.state = State.InAttributeValueNq;\n this.stateInAttributeValueNoQuotes(c); // Reconsume token\n }\n }\n handleInAttributeValue(c, quote) {\n if (c === quote ||\n (!this.decodeEntities && this.fastForwardTo(quote))) {\n this.cbs.onattribdata(this.sectionStart, this.index);\n this.sectionStart = -1;\n this.cbs.onattribend(quote === CharCodes.DoubleQuote\n ? QuoteType.Double\n : QuoteType.Single, this.index + 1);\n this.state = State.BeforeAttributeName;\n }\n else if (this.decodeEntities && c === CharCodes.Amp) {\n this.startEntity();\n }\n }\n stateInAttributeValueDoubleQuotes(c) {\n this.handleInAttributeValue(c, CharCodes.DoubleQuote);\n }\n stateInAttributeValueSingleQuotes(c) {\n this.handleInAttributeValue(c, CharCodes.SingleQuote);\n }\n stateInAttributeValueNoQuotes(c) {\n if (isWhitespace(c) || c === CharCodes.Gt) {\n this.cbs.onattribdata(this.sectionStart, this.index);\n this.sectionStart = -1;\n this.cbs.onattribend(QuoteType.Unquoted, this.index);\n this.state = State.BeforeAttributeName;\n this.stateBeforeAttributeName(c);\n }\n else if (this.decodeEntities && c === CharCodes.Amp) {\n this.startEntity();\n }\n }\n stateBeforeDeclaration(c) {\n if (c === CharCodes.OpeningSquareBracket) {\n this.state = State.CDATASequence;\n this.sequenceIndex = 0;\n }\n else {\n this.state =\n c === CharCodes.Dash\n ? State.BeforeComment\n : State.InDeclaration;\n }\n }\n stateInDeclaration(c) {\n if (c === CharCodes.Gt || this.fastForwardTo(CharCodes.Gt)) {\n this.cbs.ondeclaration(this.sectionStart, this.index);\n this.state = State.Text;\n this.sectionStart = this.index + 1;\n }\n }\n stateInProcessingInstruction(c) {\n if (c === CharCodes.Gt || this.fastForwardTo(CharCodes.Gt)) {\n this.cbs.onprocessinginstruction(this.sectionStart, this.index);\n this.state = State.Text;\n this.sectionStart = this.index + 1;\n }\n }\n stateBeforeComment(c) {\n if (c === CharCodes.Dash) {\n this.state = State.InCommentLike;\n this.currentSequence = Sequences.CommentEnd;\n // Allow short comments (eg. <!-->)\n this.sequenceIndex = 2;\n this.sectionStart = this.index + 1;\n }\n else {\n this.state = State.InDeclaration;\n }\n }\n stateInSpecialComment(c) {\n if (c === CharCodes.Gt || this.fastForwardTo(CharCodes.Gt)) {\n this.cbs.oncomment(this.sectionStart, this.index, 0);\n this.state = State.Text;\n this.sectionStart = this.index + 1;\n }\n }\n stateBeforeSpecialS(c) {\n const lower = c | 0x20;\n if (lower === Sequences.ScriptEnd[3]) {\n this.startSpecial(Sequences.ScriptEnd, 4);\n }\n else if (lower === Sequences.StyleEnd[3]) {\n this.startSpecial(Sequences.StyleEnd, 4);\n }\n else {\n this.state = State.InTagName;\n this.stateInTagName(c); // Consume the token again\n }\n }\n stateBeforeSpecialT(c) {\n const lower = c | 0x20;\n switch (lower) {\n case Sequences.TitleEnd[3]: {\n this.startSpecial(Sequences.TitleEnd, 4);\n break;\n }\n case Sequences.TextareaEnd[3]: {\n this.startSpecial(Sequences.TextareaEnd, 4);\n break;\n }\n case Sequences.XmpEnd[3]: {\n this.startSpecial(Sequences.XmpEnd, 4);\n break;\n }\n default: {\n this.state = State.InTagName;\n this.stateInTagName(c); // Consume the token again\n }\n }\n }\n startEntity() {\n this.baseState = this.state;\n this.state = State.InEntity;\n this.entityStart = this.index;\n this.entityDecoder.startEntity(this.xmlMode\n ? decode_1.DecodingMode.Strict\n : this.baseState === State.Text ||\n this.baseState === State.InSpecialTag\n ? decode_1.DecodingMode.Legacy\n : decode_1.DecodingMode.Attribute);\n }\n stateInEntity() {\n const length = this.entityDecoder.write(this.buffer, this.index - this.offset);\n // If `length` is positive, we are done with the entity.\n if (length >= 0) {\n this.state = this.baseState;\n if (length === 0) {\n this.index = this.entityStart;\n }\n }\n else {\n // Mark buffer as consumed.\n this.index = this.offset + this.buffer.length - 1;\n }\n }\n /**\n * Remove data that has already been consumed from the buffer.\n */\n cleanup() {\n // If we are inside of text or attributes, emit what we already have.\n if (this.running && this.sectionStart !== this.index) {\n if (this.state === State.Text ||\n (this.state === State.InSpecialTag && this.sequenceIndex === 0)) {\n this.cbs.ontext(this.sectionStart, this.index);\n this.sectionStart = this.index;\n }\n else if (this.state === State.InAttributeValueDq ||\n this.state === State.InAttributeValueSq ||\n this.state === State.InAttributeValueNq) {\n this.cbs.onattribdata(this.sectionStart, this.index);\n this.sectionStart = this.index;\n }\n }\n }\n shouldContinue() {\n return this.index < this.buffer.length + this.offset && this.running;\n }\n /**\n * Iterates through the buffer, calling the function corresponding to the current state.\n *\n * States that are more likely to be hit are higher up, as a performance improvement.\n */\n parse() {\n while (this.shouldContinue()) {\n const c = this.buffer.charCodeAt(this.index - this.offset);\n switch (this.state) {\n case State.Text: {\n this.stateText(c);\n break;\n }\n case State.SpecialStartSequence: {\n this.stateSpecialStartSequence(c);\n break;\n }\n case State.InSpecialTag: {\n this.stateInSpecialTag(c);\n break;\n }\n case State.CDATASequence: {\n this.stateCDATASequence(c);\n break;\n }\n case State.InAttributeValueDq: {\n this.stateInAttributeValueDoubleQuotes(c);\n break;\n }\n case State.InAttributeName: {\n this.stateInAttributeName(c);\n break;\n }\n case State.InCommentLike: {\n this.stateInCommentLike(c);\n break;\n }\n case State.InSpecialComment: {\n this.stateInSpecialComment(c);\n break;\n }\n case State.BeforeAttributeName: {\n this.stateBeforeAttributeName(c);\n break;\n }\n case State.InTagName: {\n this.stateInTagName(c);\n break;\n }\n case State.InClosingTagName: {\n this.stateInClosingTagName(c);\n break;\n }\n case State.BeforeTagName: {\n this.stateBeforeTagName(c);\n break;\n }\n case State.AfterAttributeName: {\n this.stateAfterAttributeName(c);\n break;\n }\n case State.InAttributeValueSq: {\n this.stateInAttributeValueSingleQuotes(c);\n break;\n }\n case State.BeforeAttributeValue: {\n this.stateBeforeAttributeValue(c);\n break;\n }\n case State.BeforeClosingTagName: {\n this.stateBeforeClosingTagName(c);\n break;\n }\n case State.AfterClosingTagName: {\n this.stateAfterClosingTagName(c);\n break;\n }\n case State.BeforeSpecialS: {\n this.stateBeforeSpecialS(c);\n break;\n }\n case State.BeforeSpecialT: {\n this.stateBeforeSpecialT(c);\n break;\n }\n case State.InAttributeValueNq: {\n this.stateInAttributeValueNoQuotes(c);\n break;\n }\n case State.InSelfClosingTag: {\n this.stateInSelfClosingTag(c);\n break;\n }\n case State.InDeclaration: {\n this.stateInDeclaration(c);\n break;\n }\n case State.BeforeDeclaration: {\n this.stateBeforeDeclaration(c);\n break;\n }\n case State.BeforeComment: {\n this.stateBeforeComment(c);\n break;\n }\n case State.InProcessingInstruction: {\n this.stateInProcessingInstruction(c);\n break;\n }\n case State.InEntity: {\n this.stateInEntity();\n break;\n }\n }\n this.index++;\n }\n this.cleanup();\n }\n finish() {\n if (this.state === State.InEntity) {\n this.entityDecoder.end();\n this.state = this.baseState;\n }\n this.handleTrailingData();\n this.cbs.onend();\n }\n /** Handle any trailing data. */\n handleTrailingData() {\n const endIndex = this.buffer.length + this.offset;\n // If there is no remaining data, we are done.\n if (this.sectionStart >= endIndex) {\n return;\n }\n if (this.state === State.InCommentLike) {\n if (this.currentSequence === Sequences.CdataEnd) {\n this.cbs.oncdata(this.sectionStart, endIndex, 0);\n }\n else {\n this.cbs.oncomment(this.sectionStart, endIndex, 0);\n }\n }\n else if (this.state === State.InTagName ||\n this.state === State.BeforeAttributeName ||\n this.state === State.BeforeAttributeValue ||\n this.state === State.AfterAttributeName ||\n this.state === State.InAttributeName ||\n this.state === State.InAttributeValueSq ||\n this.state === State.InAttributeValueDq ||\n this.state === State.InAttributeValueNq ||\n this.state === State.InClosingTagName) {\n /*\n * If we are currently in an opening or closing tag, us not calling the\n * respective callback signals that the tag should be ignored.\n */\n }\n else {\n this.cbs.ontext(this.sectionStart, endIndex);\n }\n }\n emitCodePoint(cp, consumed) {\n if (this.baseState !== State.Text &&\n this.baseState !== State.InSpecialTag) {\n if (this.sectionStart < this.entityStart) {\n this.cbs.onattribdata(this.sectionStart, this.entityStart);\n }\n this.sectionStart = this.entityStart + consumed;\n this.index = this.sectionStart - 1;\n this.cbs.onattribentity(cp);\n }\n else {\n if (this.sectionStart < this.entityStart) {\n this.cbs.ontext(this.sectionStart, this.entityStart);\n }\n this.sectionStart = this.entityStart + consumed;\n this.index = this.sectionStart - 1;\n this.cbs.ontextentity(cp, this.sectionStart);\n }\n }\n}\nexports.default = Tokenizer;\n//# sourceMappingURL=Tokenizer.js.map"],"names":["Object","defineProperty","Tokenizer_1","value","QuoteType","decode_1","require$$0","CharCodes","State","isWhitespace","c","Space","NewLine","Tab","FormFeed","CarriageReturn","isEndOfTagSection","Slash","Gt","Sequences","Cdata","Uint8Array","CdataEnd","CommentEnd","ScriptEnd","StyleEnd","TitleEnd","TextareaEnd","XmpEnd","default","constructor","xmlMode","decodeEntities","cbs","this","state","Text","buffer","sectionStart","index","entityStart","baseState","isSpecial","running","offset","currentSequence","undefined","sequenceIndex","entityDecoder","EntityDecoder","xmlDecodeTree","htmlDecodeTree","cp","consumed","emitCodePoint","reset","write","chunk","length","parse","end","finish","pause","resume","stateText","Lt","fastForwardTo","ontext","BeforeTagName","Amp","startEntity","stateSpecialStartSequence","isEnd","InTagName","stateInTagName","stateInSpecialTag","endOfText","actualIndex","stateInClosingTagName","Number","stateCDATASequence","InCommentLike","InDeclaration","stateInDeclaration","charCodeAt","stateInCommentLike","oncdata","oncomment","isTagStartChar","LowerA","LowerZ","UpperA","UpperZ","isASCIIAlpha","startSpecial","sequence","SpecialStartSequence","stateBeforeTagName","ExclamationMark","BeforeDeclaration","Questionmark","InProcessingInstruction","lower","BeforeSpecialS","BeforeSpecialT","BeforeClosingTagName","onopentagname","BeforeAttributeName","stateBeforeAttributeName","stateBeforeClosingTagName","InClosingTagName","InSpecialComment","onclosetag","AfterClosingTagName","stateAfterClosingTagName","onopentagend","InSpecialTag","InSelfClosingTag","InAttributeName","stateInSelfClosingTag","onselfclosingtag","stateInAttributeName","Eq","onattribname","AfterAttributeName","stateAfterAttributeName","BeforeAttributeValue","onattribend","NoValue","stateBeforeAttributeValue","DoubleQuote","InAttributeValueDq","SingleQuote","InAttributeValueSq","InAttributeValueNq","stateInAttributeValueNoQuotes","handleInAttributeValue","quote","onattribdata","Double","Single","stateInAttributeValueDoubleQuotes","stateInAttributeValueSingleQuotes","Unquoted","stateBeforeDeclaration","OpeningSquareBracket","CDATASequence","Dash","BeforeComment","ondeclaration","stateInProcessingInstruction","onprocessinginstruction","stateBeforeComment","stateInSpecialComment","stateBeforeSpecialS","stateBeforeSpecialT","InEntity","DecodingMode","Strict","Legacy","Attribute","stateInEntity","cleanup","shouldContinue","handleTrailingData","onend","endIndex","onattribentity","ontextentity"],"mappings":"mLACAA,OAAOC,eAAeC,EAAS,aAAc,CAAEC,OAAO,IACrCD,EAAAE,eAAG,EACpB,MAAMC,EAAqCC,IAC3C,IAAIC,EA+BAC,EAgDAJ,EAdJ,SAASK,EAAaC,GAClB,OAAQA,IAAMH,EAAUI,OACpBD,IAAMH,EAAUK,SAChBF,IAAMH,EAAUM,KAChBH,IAAMH,EAAUO,UAChBJ,IAAMH,EAAUQ,cACxB,CACA,SAASC,EAAkBN,GACvB,OAAOA,IAAMH,EAAUU,OAASP,IAAMH,EAAUW,IAAMT,EAAaC,EACvE,EAzEA,SAAWH,GACPA,EAAUA,EAAe,IAAI,GAAK,MAClCA,EAAUA,EAAmB,QAAI,IAAM,UACvCA,EAAUA,EAAoB,SAAI,IAAM,WACxCA,EAAUA,EAA0B,eAAI,IAAM,iBAC9CA,EAAUA,EAAiB,MAAI,IAAM,QACrCA,EAAUA,EAA2B,gBAAI,IAAM,kBAC/CA,EAAUA,EAAkB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1B,EAAUG,SACnCY,KAAKD,IAAIqD,QAAQpD,KAAKI,aAAcgI,EAAU,GAG9CpI,KAAKD,IAAIsD,UAAUrD,KAAKI,aAAcgI,EAAU,GAG/CpI,KAAKC,QAAU3B,EAAMiE,WAC1BvC,KAAKC,QAAU3B,EAAMmG,qBACrBzE,KAAKC,QAAU3B,EAAMsH,sBACrB5F,KAAKC,QAAU3B,EAAMoH,oBACrB1F,KAAKC,QAAU3B,EAAM8G,iBACrBpF,KAAKC,QAAU3B,EAAM6H,oBACrBnG,KAAKC,QAAU3B,EAAM2H,oBACrBjG,KAAKC,QAAU3B,EAAM8H,oBACrBpG,KAAKC,QAAU3B,EAAMsG,kBAOrB5E,KAAKD,IAAIkC,OAAOjC,KAAKI,aAAcgI,GAE/C,CACI,aAAAhH,CAAcF,EAAIC,GACVnB,KAAKO,YAAcjC,EAAM4B,MACzBF,KAAKO,YAAcjC,EAAM4G,cACrBlF,KAAKI,aAAeJ,KAAKM,aACzBN,KAAKD,IAAIyG,aAAaxG,KAAKI,aAAcJ,KAAKM,aAElDN,KAAKI,aAAeJ,KAAKM,YAAca,EACvCnB,KAAKK,MAAQL,KAAKI,aAAe,EACjCJ,KAAKD,IAAIsI,eAAenH,KAGpBlB,KAAKI,aAAeJ,KAAKM,aACzBN,KAAKD,IAAIkC,OAAOjC,KAAKI,aAAcJ,KAAKM,aAE5CN,KAAKI,aAAeJ,KAAKM,YAAca,EACvCnB,KAAKK,MAAQL,KAAKI,aAAe,EACjCJ,KAAKD,IAAIuI,aAAapH,EAAIlB,KAAKI,cAE3C"}
1
+ {"version":3,"file":"Tokenizer.js","sources":["../../../../../node_modules/htmlparser2/dist/commonjs/Tokenizer.js"],"sourcesContent":["\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.QuoteType = void 0;\nconst decode_1 = require(\"entities/decode\");\nvar CharCodes;\n(function (CharCodes) {\n CharCodes[CharCodes[\"Tab\"] = 9] = \"Tab\";\n CharCodes[CharCodes[\"NewLine\"] = 10] = \"NewLine\";\n CharCodes[CharCodes[\"FormFeed\"] = 12] = \"FormFeed\";\n CharCodes[CharCodes[\"CarriageReturn\"] = 13] = \"CarriageReturn\";\n CharCodes[CharCodes[\"Space\"] = 32] = \"Space\";\n CharCodes[CharCodes[\"ExclamationMark\"] = 33] = \"ExclamationMark\";\n CharCodes[CharCodes[\"Number\"] = 35] = \"Number\";\n CharCodes[CharCodes[\"Amp\"] = 38] = \"Amp\";\n CharCodes[CharCodes[\"SingleQuote\"] = 39] = \"SingleQuote\";\n CharCodes[CharCodes[\"DoubleQuote\"] = 34] = \"DoubleQuote\";\n CharCodes[CharCodes[\"Dash\"] = 45] = \"Dash\";\n CharCodes[CharCodes[\"Slash\"] = 47] = \"Slash\";\n CharCodes[CharCodes[\"Zero\"] = 48] = \"Zero\";\n CharCodes[CharCodes[\"Nine\"] = 57] = \"Nine\";\n CharCodes[CharCodes[\"Semi\"] = 59] = \"Semi\";\n CharCodes[CharCodes[\"Lt\"] = 60] = \"Lt\";\n CharCodes[CharCodes[\"Eq\"] = 61] = \"Eq\";\n CharCodes[CharCodes[\"Gt\"] = 62] = \"Gt\";\n CharCodes[CharCodes[\"Questionmark\"] = 63] = \"Questionmark\";\n CharCodes[CharCodes[\"UpperA\"] = 65] = \"UpperA\";\n CharCodes[CharCodes[\"LowerA\"] = 97] = \"LowerA\";\n CharCodes[CharCodes[\"UpperF\"] = 70] = \"UpperF\";\n CharCodes[CharCodes[\"LowerF\"] = 102] = \"LowerF\";\n CharCodes[CharCodes[\"UpperZ\"] = 90] = \"UpperZ\";\n CharCodes[CharCodes[\"LowerZ\"] = 122] = \"LowerZ\";\n CharCodes[CharCodes[\"LowerX\"] = 120] = \"LowerX\";\n CharCodes[CharCodes[\"OpeningSquareBracket\"] = 91] = \"OpeningSquareBracket\";\n})(CharCodes || (CharCodes = {}));\n/** All the states the tokenizer can be in. */\nvar State;\n(function (State) {\n State[State[\"Text\"] = 1] = \"Text\";\n State[State[\"BeforeTagName\"] = 2] = \"BeforeTagName\";\n State[State[\"InTagName\"] = 3] = \"InTagName\";\n State[State[\"InSelfClosingTag\"] = 4] = \"InSelfClosingTag\";\n State[State[\"BeforeClosingTagName\"] = 5] = \"BeforeClosingTagName\";\n State[State[\"InClosingTagName\"] = 6] = \"InClosingTagName\";\n State[State[\"AfterClosingTagName\"] = 7] = \"AfterClosingTagName\";\n // Attributes\n State[State[\"BeforeAttributeName\"] = 8] = \"BeforeAttributeName\";\n State[State[\"InAttributeName\"] = 9] = \"InAttributeName\";\n State[State[\"AfterAttributeName\"] = 10] = \"AfterAttributeName\";\n State[State[\"BeforeAttributeValue\"] = 11] = \"BeforeAttributeValue\";\n State[State[\"InAttributeValueDq\"] = 12] = \"InAttributeValueDq\";\n State[State[\"InAttributeValueSq\"] = 13] = \"InAttributeValueSq\";\n State[State[\"InAttributeValueNq\"] = 14] = \"InAttributeValueNq\";\n // Declarations\n State[State[\"BeforeDeclaration\"] = 15] = \"BeforeDeclaration\";\n State[State[\"InDeclaration\"] = 16] = \"InDeclaration\";\n // Processing instructions\n State[State[\"InProcessingInstruction\"] = 17] = \"InProcessingInstruction\";\n // Comments & CDATA\n State[State[\"BeforeComment\"] = 18] = \"BeforeComment\";\n State[State[\"CDATASequence\"] = 19] = \"CDATASequence\";\n State[State[\"InSpecialComment\"] = 20] = \"InSpecialComment\";\n State[State[\"InCommentLike\"] = 21] = \"InCommentLike\";\n // Special tags\n State[State[\"BeforeSpecialS\"] = 22] = \"BeforeSpecialS\";\n State[State[\"BeforeSpecialT\"] = 23] = \"BeforeSpecialT\";\n State[State[\"SpecialStartSequence\"] = 24] = \"SpecialStartSequence\";\n State[State[\"InSpecialTag\"] = 25] = \"InSpecialTag\";\n State[State[\"InEntity\"] = 26] = \"InEntity\";\n})(State || (State = {}));\nfunction isWhitespace(c) {\n return (c === CharCodes.Space ||\n c === CharCodes.NewLine ||\n c === CharCodes.Tab ||\n c === CharCodes.FormFeed ||\n c === CharCodes.CarriageReturn);\n}\nfunction isEndOfTagSection(c) {\n return c === CharCodes.Slash || c === CharCodes.Gt || isWhitespace(c);\n}\nfunction isASCIIAlpha(c) {\n return ((c >= CharCodes.LowerA && c <= CharCodes.LowerZ) ||\n (c >= CharCodes.UpperA && c <= CharCodes.UpperZ));\n}\nvar QuoteType;\n(function (QuoteType) {\n QuoteType[QuoteType[\"NoValue\"] = 0] = \"NoValue\";\n QuoteType[QuoteType[\"Unquoted\"] = 1] = \"Unquoted\";\n QuoteType[QuoteType[\"Single\"] = 2] = \"Single\";\n QuoteType[QuoteType[\"Double\"] = 3] = \"Double\";\n})(QuoteType || (exports.QuoteType = QuoteType = {}));\n/**\n * Sequences used to match longer strings.\n *\n * We don't have `Script`, `Style`, or `Title` here. Instead, we re-use the *End\n * sequences with an increased offset.\n */\nconst Sequences = {\n Cdata: new Uint8Array([0x43, 0x44, 0x41, 0x54, 0x41, 0x5b]), // CDATA[\n CdataEnd: new Uint8Array([0x5d, 0x5d, 0x3e]), // ]]>\n CommentEnd: new Uint8Array([0x2d, 0x2d, 0x3e]), // `-->`\n ScriptEnd: new Uint8Array([0x3c, 0x2f, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74]), // `</script`\n StyleEnd: new Uint8Array([0x3c, 0x2f, 0x73, 0x74, 0x79, 0x6c, 0x65]), // `</style`\n TitleEnd: new Uint8Array([0x3c, 0x2f, 0x74, 0x69, 0x74, 0x6c, 0x65]), // `</title`\n TextareaEnd: new Uint8Array([\n 0x3c, 0x2f, 0x74, 0x65, 0x78, 0x74, 0x61, 0x72, 0x65, 0x61,\n ]), // `</textarea`\n XmpEnd: new Uint8Array([0x3c, 0x2f, 0x78, 0x6d, 0x70]), // `</xmp`\n};\nclass Tokenizer {\n constructor({ xmlMode = false, decodeEntities = true, }, cbs) {\n this.cbs = cbs;\n /** The current state the tokenizer is in. */\n this.state = State.Text;\n /** The read buffer. */\n this.buffer = \"\";\n /** The beginning of the section that is currently being read. */\n this.sectionStart = 0;\n /** The index within the buffer that we are currently looking at. */\n this.index = 0;\n /** The start of the last entity. */\n this.entityStart = 0;\n /** Some behavior, eg. when decoding entities, is done while we are in another state. This keeps track of the other state type. */\n this.baseState = State.Text;\n /** For special parsing behavior inside of script and style tags. */\n this.isSpecial = false;\n /** Indicates whether the tokenizer has been paused. */\n this.running = true;\n /** The offset of the current buffer. */\n this.offset = 0;\n this.currentSequence = undefined;\n this.sequenceIndex = 0;\n this.xmlMode = xmlMode;\n this.decodeEntities = decodeEntities;\n this.entityDecoder = new decode_1.EntityDecoder(xmlMode ? decode_1.xmlDecodeTree : decode_1.htmlDecodeTree, (cp, consumed) => this.emitCodePoint(cp, consumed));\n }\n reset() {\n this.state = State.Text;\n this.buffer = \"\";\n this.sectionStart = 0;\n this.index = 0;\n this.baseState = State.Text;\n this.currentSequence = undefined;\n this.running = true;\n this.offset = 0;\n }\n write(chunk) {\n this.offset += this.buffer.length;\n this.buffer = chunk;\n this.parse();\n }\n end() {\n if (this.running)\n this.finish();\n }\n pause() {\n this.running = false;\n }\n resume() {\n this.running = true;\n if (this.index < this.buffer.length + this.offset) {\n this.parse();\n }\n }\n stateText(c) {\n if (c === CharCodes.Lt ||\n (!this.decodeEntities && this.fastForwardTo(CharCodes.Lt))) {\n if (this.index > this.sectionStart) {\n this.cbs.ontext(this.sectionStart, this.index);\n }\n this.state = State.BeforeTagName;\n this.sectionStart = this.index;\n }\n else if (this.decodeEntities && c === CharCodes.Amp) {\n this.startEntity();\n }\n }\n stateSpecialStartSequence(c) {\n const isEnd = this.sequenceIndex === this.currentSequence.length;\n const isMatch = isEnd\n ? // If we are at the end of the sequence, make sure the tag name has ended\n isEndOfTagSection(c)\n : // Otherwise, do a case-insensitive comparison\n (c | 0x20) === this.currentSequence[this.sequenceIndex];\n if (!isMatch) {\n this.isSpecial = false;\n }\n else if (!isEnd) {\n this.sequenceIndex++;\n return;\n }\n this.sequenceIndex = 0;\n this.state = State.InTagName;\n this.stateInTagName(c);\n }\n /** Look for an end tag. For <title> tags, also decode entities. */\n stateInSpecialTag(c) {\n if (this.sequenceIndex === this.currentSequence.length) {\n if (c === CharCodes.Gt || isWhitespace(c)) {\n const endOfText = this.index - this.currentSequence.length;\n if (this.sectionStart < endOfText) {\n // Spoof the index so that reported locations match up.\n const actualIndex = this.index;\n this.index = endOfText;\n this.cbs.ontext(this.sectionStart, endOfText);\n this.index = actualIndex;\n }\n this.isSpecial = false;\n this.sectionStart = endOfText + 2; // Skip over the `</`\n this.stateInClosingTagName(c);\n return; // We are done; skip the rest of the function.\n }\n this.sequenceIndex = 0;\n }\n if ((c | 0x20) === this.currentSequence[this.sequenceIndex]) {\n this.sequenceIndex += 1;\n }\n else if (this.sequenceIndex === 0) {\n if (this.currentSequence === Sequences.TitleEnd) {\n // We have to parse entities in <title> tags.\n if (this.decodeEntities && c === CharCodes.Amp) {\n this.startEntity();\n }\n }\n else if (this.fastForwardTo(CharCodes.Lt)) {\n // Outside of <title> tags, we can fast-forward.\n this.sequenceIndex = 1;\n }\n }\n else {\n // If we see a `<`, set the sequence index to 1; useful for eg. `<</script>`.\n this.sequenceIndex = Number(c === CharCodes.Lt);\n }\n }\n stateCDATASequence(c) {\n if (c === Sequences.Cdata[this.sequenceIndex]) {\n if (++this.sequenceIndex === Sequences.Cdata.length) {\n this.state = State.InCommentLike;\n this.currentSequence = Sequences.CdataEnd;\n this.sequenceIndex = 0;\n this.sectionStart = this.index + 1;\n }\n }\n else {\n this.sequenceIndex = 0;\n this.state = State.InDeclaration;\n this.stateInDeclaration(c); // Reconsume the character\n }\n }\n /**\n * When we wait for one specific character, we can speed things up\n * by skipping through the buffer until we find it.\n *\n * @returns Whether the character was found.\n */\n fastForwardTo(c) {\n while (++this.index < this.buffer.length + this.offset) {\n if (this.buffer.charCodeAt(this.index - this.offset) === c) {\n return true;\n }\n }\n /*\n * We increment the index at the end of the `parse` loop,\n * so set it to `buffer.length - 1` here.\n *\n * TODO: Refactor `parse` to increment index before calling states.\n */\n this.index = this.buffer.length + this.offset - 1;\n return false;\n }\n /**\n * Comments and CDATA end with `-->` and `]]>`.\n *\n * Their common qualities are:\n * - Their end sequences have a distinct character they start with.\n * - That character is then repeated, so we have to check multiple repeats.\n * - All characters but the start character of the sequence can be skipped.\n */\n stateInCommentLike(c) {\n if (c === this.currentSequence[this.sequenceIndex]) {\n if (++this.sequenceIndex === this.currentSequence.length) {\n if (this.currentSequence === Sequences.CdataEnd) {\n this.cbs.oncdata(this.sectionStart, this.index, 2);\n }\n else {\n this.cbs.oncomment(this.sectionStart, this.index, 2);\n }\n this.sequenceIndex = 0;\n this.sectionStart = this.index + 1;\n this.state = State.Text;\n }\n }\n else if (this.sequenceIndex === 0) {\n // Fast-forward to the first character of the sequence\n if (this.fastForwardTo(this.currentSequence[0])) {\n this.sequenceIndex = 1;\n }\n }\n else if (c !== this.currentSequence[this.sequenceIndex - 1]) {\n // Allow long sequences, eg. --->, ]]]>\n this.sequenceIndex = 0;\n }\n }\n /**\n * HTML only allows ASCII alpha characters (a-z and A-Z) at the beginning of a tag name.\n *\n * XML allows a lot more characters here (@see https://www.w3.org/TR/REC-xml/#NT-NameStartChar).\n * We allow anything that wouldn't end the tag.\n */\n isTagStartChar(c) {\n return this.xmlMode ? !isEndOfTagSection(c) : isASCIIAlpha(c);\n }\n startSpecial(sequence, offset) {\n this.isSpecial = true;\n this.currentSequence = sequence;\n this.sequenceIndex = offset;\n this.state = State.SpecialStartSequence;\n }\n stateBeforeTagName(c) {\n if (c === CharCodes.ExclamationMark) {\n this.state = State.BeforeDeclaration;\n this.sectionStart = this.index + 1;\n }\n else if (c === CharCodes.Questionmark) {\n this.state = State.InProcessingInstruction;\n this.sectionStart = this.index + 1;\n }\n else if (this.isTagStartChar(c)) {\n const lower = c | 0x20;\n this.sectionStart = this.index;\n if (this.xmlMode) {\n this.state = State.InTagName;\n }\n else if (lower === Sequences.ScriptEnd[2]) {\n this.state = State.BeforeSpecialS;\n }\n else if (lower === Sequences.TitleEnd[2] ||\n lower === Sequences.XmpEnd[2]) {\n this.state = State.BeforeSpecialT;\n }\n else {\n this.state = State.InTagName;\n }\n }\n else if (c === CharCodes.Slash) {\n this.state = State.BeforeClosingTagName;\n }\n else {\n this.state = State.Text;\n this.stateText(c);\n }\n }\n stateInTagName(c) {\n if (isEndOfTagSection(c)) {\n this.cbs.onopentagname(this.sectionStart, this.index);\n this.sectionStart = -1;\n this.state = State.BeforeAttributeName;\n this.stateBeforeAttributeName(c);\n }\n }\n stateBeforeClosingTagName(c) {\n if (isWhitespace(c)) {\n // Ignore\n }\n else if (c === CharCodes.Gt) {\n this.state = State.Text;\n }\n else {\n this.state = this.isTagStartChar(c)\n ? State.InClosingTagName\n : State.InSpecialComment;\n this.sectionStart = this.index;\n }\n }\n stateInClosingTagName(c) {\n if (c === CharCodes.Gt || isWhitespace(c)) {\n this.cbs.onclosetag(this.sectionStart, this.index);\n this.sectionStart = -1;\n this.state = State.AfterClosingTagName;\n this.stateAfterClosingTagName(c);\n }\n }\n stateAfterClosingTagName(c) {\n // Skip everything until \">\"\n if (c === CharCodes.Gt || this.fastForwardTo(CharCodes.Gt)) {\n this.state = State.Text;\n this.sectionStart = this.index + 1;\n }\n }\n stateBeforeAttributeName(c) {\n if (c === CharCodes.Gt) {\n this.cbs.onopentagend(this.index);\n if (this.isSpecial) {\n this.state = State.InSpecialTag;\n this.sequenceIndex = 0;\n }\n else {\n this.state = State.Text;\n }\n this.sectionStart = this.index + 1;\n }\n else if (c === CharCodes.Slash) {\n this.state = State.InSelfClosingTag;\n }\n else if (!isWhitespace(c)) {\n this.state = State.InAttributeName;\n this.sectionStart = this.index;\n }\n }\n stateInSelfClosingTag(c) {\n if (c === CharCodes.Gt) {\n this.cbs.onselfclosingtag(this.index);\n this.state = State.Text;\n this.sectionStart = this.index + 1;\n this.isSpecial = false; // Reset special state, in case of self-closing special tags\n }\n else if (!isWhitespace(c)) {\n this.state = State.BeforeAttributeName;\n this.stateBeforeAttributeName(c);\n }\n }\n stateInAttributeName(c) {\n if (c === CharCodes.Eq || isEndOfTagSection(c)) {\n this.cbs.onattribname(this.sectionStart, this.index);\n this.sectionStart = this.index;\n this.state = State.AfterAttributeName;\n this.stateAfterAttributeName(c);\n }\n }\n stateAfterAttributeName(c) {\n if (c === CharCodes.Eq) {\n this.state = State.BeforeAttributeValue;\n }\n else if (c === CharCodes.Slash || c === CharCodes.Gt) {\n this.cbs.onattribend(QuoteType.NoValue, this.sectionStart);\n this.sectionStart = -1;\n this.state = State.BeforeAttributeName;\n this.stateBeforeAttributeName(c);\n }\n else if (!isWhitespace(c)) {\n this.cbs.onattribend(QuoteType.NoValue, this.sectionStart);\n this.state = State.InAttributeName;\n this.sectionStart = this.index;\n }\n }\n stateBeforeAttributeValue(c) {\n if (c === CharCodes.DoubleQuote) {\n this.state = State.InAttributeValueDq;\n this.sectionStart = this.index + 1;\n }\n else if (c === CharCodes.SingleQuote) {\n this.state = State.InAttributeValueSq;\n this.sectionStart = this.index + 1;\n }\n else if (!isWhitespace(c)) {\n this.sectionStart = this.index;\n this.state = State.InAttributeValueNq;\n this.stateInAttributeValueNoQuotes(c); // Reconsume token\n }\n }\n handleInAttributeValue(c, quote) {\n if (c === quote ||\n (!this.decodeEntities && this.fastForwardTo(quote))) {\n this.cbs.onattribdata(this.sectionStart, this.index);\n this.sectionStart = -1;\n this.cbs.onattribend(quote === CharCodes.DoubleQuote\n ? QuoteType.Double\n : QuoteType.Single, this.index + 1);\n this.state = State.BeforeAttributeName;\n }\n else if (this.decodeEntities && c === CharCodes.Amp) {\n this.startEntity();\n }\n }\n stateInAttributeValueDoubleQuotes(c) {\n this.handleInAttributeValue(c, CharCodes.DoubleQuote);\n }\n stateInAttributeValueSingleQuotes(c) {\n this.handleInAttributeValue(c, CharCodes.SingleQuote);\n }\n stateInAttributeValueNoQuotes(c) {\n if (isWhitespace(c) || c === CharCodes.Gt) {\n this.cbs.onattribdata(this.sectionStart, this.index);\n this.sectionStart = -1;\n this.cbs.onattribend(QuoteType.Unquoted, this.index);\n this.state = State.BeforeAttributeName;\n this.stateBeforeAttributeName(c);\n }\n else if (this.decodeEntities && c === CharCodes.Amp) {\n this.startEntity();\n }\n }\n stateBeforeDeclaration(c) {\n if (c === CharCodes.OpeningSquareBracket) {\n this.state = State.CDATASequence;\n this.sequenceIndex = 0;\n }\n else {\n this.state =\n c === CharCodes.Dash\n ? State.BeforeComment\n : State.InDeclaration;\n }\n }\n stateInDeclaration(c) {\n if (c === CharCodes.Gt || this.fastForwardTo(CharCodes.Gt)) {\n this.cbs.ondeclaration(this.sectionStart, this.index);\n this.state = State.Text;\n this.sectionStart = this.index + 1;\n }\n }\n stateInProcessingInstruction(c) {\n if (c === CharCodes.Gt || this.fastForwardTo(CharCodes.Gt)) {\n this.cbs.onprocessinginstruction(this.sectionStart, this.index);\n this.state = State.Text;\n this.sectionStart = this.index + 1;\n }\n }\n stateBeforeComment(c) {\n if (c === CharCodes.Dash) {\n this.state = State.InCommentLike;\n this.currentSequence = Sequences.CommentEnd;\n // Allow short comments (eg. <!-->)\n this.sequenceIndex = 2;\n this.sectionStart = this.index + 1;\n }\n else {\n this.state = State.InDeclaration;\n }\n }\n stateInSpecialComment(c) {\n if (c === CharCodes.Gt || this.fastForwardTo(CharCodes.Gt)) {\n this.cbs.oncomment(this.sectionStart, this.index, 0);\n this.state = State.Text;\n this.sectionStart = this.index + 1;\n }\n }\n stateBeforeSpecialS(c) {\n const lower = c | 0x20;\n if (lower === Sequences.ScriptEnd[3]) {\n this.startSpecial(Sequences.ScriptEnd, 4);\n }\n else if (lower === Sequences.StyleEnd[3]) {\n this.startSpecial(Sequences.StyleEnd, 4);\n }\n else {\n this.state = State.InTagName;\n this.stateInTagName(c); // Consume the token again\n }\n }\n stateBeforeSpecialT(c) {\n const lower = c | 0x20;\n switch (lower) {\n case Sequences.TitleEnd[3]: {\n this.startSpecial(Sequences.TitleEnd, 4);\n break;\n }\n case Sequences.TextareaEnd[3]: {\n this.startSpecial(Sequences.TextareaEnd, 4);\n break;\n }\n case Sequences.XmpEnd[3]: {\n this.startSpecial(Sequences.XmpEnd, 4);\n break;\n }\n default: {\n this.state = State.InTagName;\n this.stateInTagName(c); // Consume the token again\n }\n }\n }\n startEntity() {\n this.baseState = this.state;\n this.state = State.InEntity;\n this.entityStart = this.index;\n this.entityDecoder.startEntity(this.xmlMode\n ? decode_1.DecodingMode.Strict\n : this.baseState === State.Text ||\n this.baseState === State.InSpecialTag\n ? decode_1.DecodingMode.Legacy\n : decode_1.DecodingMode.Attribute);\n }\n stateInEntity() {\n const length = this.entityDecoder.write(this.buffer, this.index - this.offset);\n // If `length` is positive, we are done with the entity.\n if (length >= 0) {\n this.state = this.baseState;\n if (length === 0) {\n this.index = this.entityStart;\n }\n }\n else {\n // Mark buffer as consumed.\n this.index = this.offset + this.buffer.length - 1;\n }\n }\n /**\n * Remove data that has already been consumed from the buffer.\n */\n cleanup() {\n // If we are inside of text or attributes, emit what we already have.\n if (this.running && this.sectionStart !== this.index) {\n if (this.state === State.Text ||\n (this.state === State.InSpecialTag && this.sequenceIndex === 0)) {\n this.cbs.ontext(this.sectionStart, this.index);\n this.sectionStart = this.index;\n }\n else if (this.state === State.InAttributeValueDq ||\n this.state === State.InAttributeValueSq ||\n this.state === State.InAttributeValueNq) {\n this.cbs.onattribdata(this.sectionStart, this.index);\n this.sectionStart = this.index;\n }\n }\n }\n shouldContinue() {\n return this.index < this.buffer.length + this.offset && this.running;\n }\n /**\n * Iterates through the buffer, calling the function corresponding to the current state.\n *\n * States that are more likely to be hit are higher up, as a performance improvement.\n */\n parse() {\n while (this.shouldContinue()) {\n const c = this.buffer.charCodeAt(this.index - this.offset);\n switch (this.state) {\n case State.Text: {\n this.stateText(c);\n break;\n }\n case State.SpecialStartSequence: {\n this.stateSpecialStartSequence(c);\n break;\n }\n case State.InSpecialTag: {\n this.stateInSpecialTag(c);\n break;\n }\n case State.CDATASequence: {\n this.stateCDATASequence(c);\n break;\n }\n case State.InAttributeValueDq: {\n this.stateInAttributeValueDoubleQuotes(c);\n break;\n }\n case State.InAttributeName: {\n this.stateInAttributeName(c);\n break;\n }\n case State.InCommentLike: {\n this.stateInCommentLike(c);\n break;\n }\n case State.InSpecialComment: {\n this.stateInSpecialComment(c);\n break;\n }\n case State.BeforeAttributeName: {\n this.stateBeforeAttributeName(c);\n break;\n }\n case State.InTagName: {\n this.stateInTagName(c);\n break;\n }\n case State.InClosingTagName: {\n this.stateInClosingTagName(c);\n break;\n }\n case State.BeforeTagName: {\n this.stateBeforeTagName(c);\n break;\n }\n case State.AfterAttributeName: {\n this.stateAfterAttributeName(c);\n break;\n }\n case State.InAttributeValueSq: {\n this.stateInAttributeValueSingleQuotes(c);\n break;\n }\n case State.BeforeAttributeValue: {\n this.stateBeforeAttributeValue(c);\n break;\n }\n case State.BeforeClosingTagName: {\n this.stateBeforeClosingTagName(c);\n break;\n }\n case State.AfterClosingTagName: {\n this.stateAfterClosingTagName(c);\n break;\n }\n case State.BeforeSpecialS: {\n this.stateBeforeSpecialS(c);\n break;\n }\n case State.BeforeSpecialT: {\n this.stateBeforeSpecialT(c);\n break;\n }\n case State.InAttributeValueNq: {\n this.stateInAttributeValueNoQuotes(c);\n break;\n }\n case State.InSelfClosingTag: {\n this.stateInSelfClosingTag(c);\n break;\n }\n case State.InDeclaration: {\n this.stateInDeclaration(c);\n break;\n }\n case State.BeforeDeclaration: {\n this.stateBeforeDeclaration(c);\n break;\n }\n case State.BeforeComment: {\n this.stateBeforeComment(c);\n break;\n }\n case State.InProcessingInstruction: {\n this.stateInProcessingInstruction(c);\n break;\n }\n case State.InEntity: {\n this.stateInEntity();\n break;\n }\n }\n this.index++;\n }\n this.cleanup();\n }\n finish() {\n if (this.state === State.InEntity) {\n this.entityDecoder.end();\n this.state = this.baseState;\n }\n this.handleTrailingData();\n this.cbs.onend();\n }\n /** Handle any trailing data. */\n handleTrailingData() {\n const endIndex = this.buffer.length + this.offset;\n // If there is no remaining data, we are done.\n if (this.sectionStart >= endIndex) {\n return;\n }\n if (this.state === State.InCommentLike) {\n if (this.currentSequence === Sequences.CdataEnd) {\n this.cbs.oncdata(this.sectionStart, endIndex, 0);\n }\n else {\n this.cbs.oncomment(this.sectionStart, endIndex, 0);\n }\n }\n else if (this.state === State.InTagName ||\n this.state === State.BeforeAttributeName ||\n this.state === State.BeforeAttributeValue ||\n this.state === State.AfterAttributeName ||\n this.state === State.InAttributeName ||\n this.state === State.InAttributeValueSq ||\n this.state === State.InAttributeValueDq ||\n this.state === State.InAttributeValueNq ||\n this.state === State.InClosingTagName) {\n /*\n * If we are currently in an opening or closing tag, us not calling the\n * respective callback signals that the tag should be ignored.\n */\n }\n else {\n this.cbs.ontext(this.sectionStart, endIndex);\n }\n }\n emitCodePoint(cp, consumed) {\n if (this.baseState !== State.Text &&\n this.baseState !== State.InSpecialTag) {\n if (this.sectionStart < this.entityStart) {\n this.cbs.onattribdata(this.sectionStart, this.entityStart);\n }\n this.sectionStart = this.entityStart + consumed;\n this.index = this.sectionStart - 1;\n this.cbs.onattribentity(cp);\n }\n else {\n if (this.sectionStart < this.entityStart) {\n this.cbs.ontext(this.sectionStart, this.entityStart);\n }\n this.sectionStart = this.entityStart + consumed;\n this.index = this.sectionStart - 1;\n this.cbs.ontextentity(cp, this.sectionStart);\n }\n }\n}\nexports.default = Tokenizer;\n//# sourceMappingURL=Tokenizer.js.map"],"names":["Object","defineProperty","Tokenizer_1","value","QuoteType","decode_1","require$$0","CharCodes","State","isWhitespace","c","Space","NewLine","Tab","FormFeed","CarriageReturn","isEndOfTagSection","Slash","Gt","Sequences","Cdata","Uint8Array","CdataEnd","CommentEnd","ScriptEnd","StyleEnd","TitleEnd","TextareaEnd","XmpEnd","default","constructor","xmlMode","decodeEntities","cbs","this","state","Text","buffer","sectionStart","index","entityStart","baseState","isSpecial","running","offset","currentSequence","undefined","sequenceIndex","entityDecoder","EntityDecoder","xmlDecodeTree","htmlDecodeTree","cp","consumed","emitCodePoint","reset","write","chunk","length","parse","end","finish","pause","resume","stateText","Lt","fastForwardTo","ontext","BeforeTagName","Amp","startEntity","stateSpecialStartSequence","isEnd","InTagName","stateInTagName","stateInSpecialTag","endOfText","actualIndex","stateInClosingTagName","Number","stateCDATASequence","InCommentLike","InDeclaration","stateInDeclaration","charCodeAt","stateInCommentLike","oncdata","oncomment","isTagStartChar","LowerA","LowerZ","UpperA","UpperZ","isASCIIAlpha","startSpecial","sequence","SpecialStartSequence","stateBeforeTagName","ExclamationMark","BeforeDeclaration","Questionmark","InProcessingInstruction","lower","BeforeSpecialS","BeforeSpecialT","BeforeClosingTagName","onopentagname","BeforeAttributeName","stateBeforeAttributeName","stateBeforeClosingTagName","InClosingTagName","InSpecialComment","onclosetag","AfterClosingTagName","stateAfterClosingTagName","onopentagend","InSpecialTag","InSelfClosingTag","InAttributeName","stateInSelfClosingTag","onselfclosingtag","stateInAttributeName","Eq","onattribname","AfterAttributeName","stateAfterAttributeName","BeforeAttributeValue","onattribend","NoValue","stateBeforeAttributeValue","DoubleQuote","InAttributeValueDq","SingleQuote","InAttributeValueSq","InAttributeValueNq","stateInAttributeValueNoQuotes","handleInAttributeValue","quote","onattribdata","Double","Single","stateInAttributeValueDoubleQuotes","stateInAttributeValueSingleQuotes","Unquoted","stateBeforeDeclaration","OpeningSquareBracket","CDATASequence","Dash","BeforeComment","ondeclaration","stateInProcessingInstruction","onprocessinginstruction","stateBeforeComment","stateInSpecialComment","stateBeforeSpecialS","stateBeforeSpecialT","InEntity","DecodingMode","Strict","Legacy","Attribute","stateInEntity","cleanup","shouldContinue","handleTrailingData","onend","endIndex","onattribentity","ontextentity"],"mappings":"yKACAA,OAAOC,eAAeC,EAAS,aAAc,CAAEC,OAAO,IACrCD,EAAAE,eAAG,EACpB,MAAMC,EAAqCC,IAC3C,IAAIC,EA+BAC,EAgDAJ,EAdJ,SAASK,EAAaC,GAClB,OAAQA,IAAMH,EAAUI,OACpBD,IAAMH,EAAUK,SAChBF,IAAMH,EAAUM,KAChBH,IAAMH,EAAUO,UAChBJ,IAAMH,EAAUQ,cACxB,CACA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AAKI,aAAe,EACjCJ,KAAKD,IAAIuI,aAAapH,EAAIlB,KAAKI,cAE3C"}
@@ -1,2 +1,2 @@
1
- import{__exports as e}from"../../../../_virtual/index16.js";import{__require as r}from"./Parser.js";import{__require as t}from"../../node_modules/domhandler/lib/index.js";import{__require as n}from"./Tokenizer.js";import{__require as o}from"../../../domelementtype/lib/index.js";import{__require as u}from"../../node_modules/domutils/lib/index.js";var i;function a(){return i||(i=1,function(i){var a,l=e&&e.__createBinding||(Object.create?function(e,r,t,n){void 0===n&&(n=t);var o=Object.getOwnPropertyDescriptor(r,t);o&&!("get"in o?!r.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return r[t]}}),Object.defineProperty(e,n,o)}:function(e,r,t,n){void 0===n&&(n=t),e[n]=r[t]}),c=e&&e.__setModuleDefault||(Object.create?function(e,r){Object.defineProperty(e,"default",{enumerable:!0,value:r})}:function(e,r){e.default=r}),d=e&&e.__importStar||(a=function(e){return a=Object.getOwnPropertyNames||function(e){var r=[];for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&(r[r.length]=t);return r},a(e)},function(e){if(e&&e.__esModule)return e;var r={};if(null!=e)for(var t=a(e),n=0;n<t.length;n++)"default"!==t[n]&&l(r,e,t[n]);return c(r,e),r}),f=e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(i,"__esModule",{value:!0}),i.DomUtils=i.getFeed=i.ElementType=i.QuoteType=i.Tokenizer=i.DefaultHandler=i.DomHandler=i.Parser=void 0,i.parseDocument=b,i.parseDOM=j,i.createDocumentStream=function(e,r,t){const n=new p.DomHandler((r=>e(r,n.root)),r,t);return new m.Parser(n,r)},i.createDomStream=function(e,r,t){const n=new p.DomHandler(e,r,t);return new m.Parser(n,r)},i.parseFeed=function(e,r=v){return(0,P.getFeed)(j(e,r))};const m=r();var s=r();Object.defineProperty(i,"Parser",{enumerable:!0,get:function(){return s.Parser}});const p=t();var _=t();function b(e,r){const t=new p.DomHandler(void 0,r);return new m.Parser(t,r).end(e),t.root}function j(e,r){return b(e,r).children}Object.defineProperty(i,"DomHandler",{enumerable:!0,get:function(){return _.DomHandler}}),Object.defineProperty(i,"DefaultHandler",{enumerable:!0,get:function(){return _.DomHandler}});var y=n();Object.defineProperty(i,"Tokenizer",{enumerable:!0,get:function(){return f(y).default}}),Object.defineProperty(i,"QuoteType",{enumerable:!0,get:function(){return y.QuoteType}}),i.ElementType=d(o());const P=u();var g=u();Object.defineProperty(i,"getFeed",{enumerable:!0,get:function(){return g.getFeed}});const v={xmlMode:!0};i.DomUtils=d(u())}(e)),e}export{a as __require};
1
+ import{__exports as e}from"../../../../_virtual/index15.js";import{__require as r}from"./Parser.js";import{__require as t}from"../../../domhandler/lib/index.js";import{__require as n}from"./Tokenizer.js";import{__require as o}from"../../../domelementtype/lib/index.js";import{__require as u}from"../../../domutils/lib/index.js";var i;function a(){return i||(i=1,function(i){var a,c=e&&e.__createBinding||(Object.create?function(e,r,t,n){void 0===n&&(n=t);var o=Object.getOwnPropertyDescriptor(r,t);o&&!("get"in o?!r.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return r[t]}}),Object.defineProperty(e,n,o)}:function(e,r,t,n){void 0===n&&(n=t),e[n]=r[t]}),l=e&&e.__setModuleDefault||(Object.create?function(e,r){Object.defineProperty(e,"default",{enumerable:!0,value:r})}:function(e,r){e.default=r}),f=e&&e.__importStar||(a=function(e){return a=Object.getOwnPropertyNames||function(e){var r=[];for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&(r[r.length]=t);return r},a(e)},function(e){if(e&&e.__esModule)return e;var r={};if(null!=e)for(var t=a(e),n=0;n<t.length;n++)"default"!==t[n]&&c(r,e,t[n]);return l(r,e),r}),d=e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(i,"__esModule",{value:!0}),i.DomUtils=i.getFeed=i.ElementType=i.QuoteType=i.Tokenizer=i.DefaultHandler=i.DomHandler=i.Parser=void 0,i.parseDocument=b,i.parseDOM=j,i.createDocumentStream=function(e,r,t){const n=new p.DomHandler((r=>e(r,n.root)),r,t);return new m.Parser(n,r)},i.createDomStream=function(e,r,t){const n=new p.DomHandler(e,r,t);return new m.Parser(n,r)},i.parseFeed=function(e,r=v){return(0,P.getFeed)(j(e,r))};const m=r();var s=r();Object.defineProperty(i,"Parser",{enumerable:!0,get:function(){return s.Parser}});const p=t();var _=t();function b(e,r){const t=new p.DomHandler(void 0,r);return new m.Parser(t,r).end(e),t.root}function j(e,r){return b(e,r).children}Object.defineProperty(i,"DomHandler",{enumerable:!0,get:function(){return _.DomHandler}}),Object.defineProperty(i,"DefaultHandler",{enumerable:!0,get:function(){return _.DomHandler}});var y=n();Object.defineProperty(i,"Tokenizer",{enumerable:!0,get:function(){return d(y).default}}),Object.defineProperty(i,"QuoteType",{enumerable:!0,get:function(){return y.QuoteType}}),i.ElementType=f(o());const P=u();var g=u();Object.defineProperty(i,"getFeed",{enumerable:!0,get:function(){return g.getFeed}});const v={xmlMode:!0};i.DomUtils=f(u())}(e)),e}export{a as __require};
2
2
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../../../node_modules/htmlparser2/dist/commonjs/index.js"],"sourcesContent":["\"use strict\";\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n var desc = Object.getOwnPropertyDescriptor(m, k);\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\n desc = { enumerable: true, get: function() { return m[k]; } };\n }\n Object.defineProperty(o, k2, desc);\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n});\nvar __importStar = (this && this.__importStar) || (function () {\n var ownKeys = function(o) {\n ownKeys = Object.getOwnPropertyNames || function (o) {\n var ar = [];\n for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;\n return ar;\n };\n return ownKeys(o);\n };\n return function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== \"default\") __createBinding(result, mod, k[i]);\n __setModuleDefault(result, mod);\n return result;\n };\n})();\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.DomUtils = exports.getFeed = exports.ElementType = exports.QuoteType = exports.Tokenizer = exports.DefaultHandler = exports.DomHandler = exports.Parser = void 0;\nexports.parseDocument = parseDocument;\nexports.parseDOM = parseDOM;\nexports.createDocumentStream = createDocumentStream;\nexports.createDomStream = createDomStream;\nexports.parseFeed = parseFeed;\nconst Parser_js_1 = require(\"./Parser.js\");\nvar Parser_js_2 = require(\"./Parser.js\");\nObject.defineProperty(exports, \"Parser\", { enumerable: true, get: function () { return Parser_js_2.Parser; } });\nconst domhandler_1 = require(\"domhandler\");\nvar domhandler_2 = require(\"domhandler\");\nObject.defineProperty(exports, \"DomHandler\", { enumerable: true, get: function () { return domhandler_2.DomHandler; } });\n// Old name for DomHandler\nObject.defineProperty(exports, \"DefaultHandler\", { enumerable: true, get: function () { return domhandler_2.DomHandler; } });\n// Helper methods\n/**\n * Parses the data, returns the resulting document.\n *\n * @param data The data that should be parsed.\n * @param options Optional options for the parser and DOM handler.\n */\nfunction parseDocument(data, options) {\n const handler = new domhandler_1.DomHandler(undefined, options);\n new Parser_js_1.Parser(handler, options).end(data);\n return handler.root;\n}\n/**\n * Parses data, returns an array of the root nodes.\n *\n * Note that the root nodes still have a `Document` node as their parent.\n * Use `parseDocument` to get the `Document` node instead.\n *\n * @param data The data that should be parsed.\n * @param options Optional options for the parser and DOM handler.\n * @deprecated Use `parseDocument` instead.\n */\nfunction parseDOM(data, options) {\n return parseDocument(data, options).children;\n}\n/**\n * Creates a parser instance, with an attached DOM handler.\n *\n * @param callback A callback that will be called once parsing has been completed, with the resulting document.\n * @param options Optional options for the parser and DOM handler.\n * @param elementCallback An optional callback that will be called every time a tag has been completed inside of the DOM.\n */\nfunction createDocumentStream(callback, options, elementCallback) {\n const handler = new domhandler_1.DomHandler((error) => callback(error, handler.root), options, elementCallback);\n return new Parser_js_1.Parser(handler, options);\n}\n/**\n * Creates a parser instance, with an attached DOM handler.\n *\n * @param callback A callback that will be called once parsing has been completed, with an array of root nodes.\n * @param options Optional options for the parser and DOM handler.\n * @param elementCallback An optional callback that will be called every time a tag has been completed inside of the DOM.\n * @deprecated Use `createDocumentStream` instead.\n */\nfunction createDomStream(callback, options, elementCallback) {\n const handler = new domhandler_1.DomHandler(callback, options, elementCallback);\n return new Parser_js_1.Parser(handler, options);\n}\nvar Tokenizer_js_1 = require(\"./Tokenizer.js\");\nObject.defineProperty(exports, \"Tokenizer\", { enumerable: true, get: function () { return __importDefault(Tokenizer_js_1).default; } });\nObject.defineProperty(exports, \"QuoteType\", { enumerable: true, get: function () { return Tokenizer_js_1.QuoteType; } });\n/*\n * All of the following exports exist for backwards-compatibility.\n * They should probably be removed eventually.\n */\nexports.ElementType = __importStar(require(\"domelementtype\"));\nconst domutils_1 = require(\"domutils\");\nvar domutils_2 = require(\"domutils\");\nObject.defineProperty(exports, \"getFeed\", { enumerable: true, get: function () { return domutils_2.getFeed; } });\nconst parseFeedDefaultOptions = { xmlMode: true };\n/**\n * Parse a feed.\n *\n * @param feed The feed that should be parsed, as a string.\n * @param options Optionally, options for parsing. When using this, you should set `xmlMode` to `true`.\n */\nfunction parseFeed(feed, options = parseFeedDefaultOptions) {\n return (0, domutils_1.getFeed)(parseDOM(feed, options));\n}\nexports.DomUtils = __importStar(require(\"domutils\"));\n//# sourceMappingURL=index.js.map"],"names":["ownKeys","__createBinding","this","Object","create","o","m","k","k2","undefined","desc","getOwnPropertyDescriptor","__esModule","writable","configurable","enumerable","get","defineProperty","__setModuleDefault","v","value","__importStar","getOwnPropertyNames","ar","prototype","hasOwnProperty","call","length","mod","result","i","__importDefault","default","exports","DomUtils","getFeed","QuoteType","Tokenizer","DomHandler","Parser","parseDocument","parseDOM","createDocumentStream","callback","options","elementCallback","handler","domhandler_1","error","root","Parser_js_1","createDomStream","parseFeed","feed","parseFeedDefaultOptions","domutils_1","require$$0","Parser_js_2","require$$1","domhandler_2","data","end","children","Tokenizer_js_1","require$$2","ElementType","require$$3","require$$4","domutils_2","xmlMode"],"mappings":"0YACA,IAiBQA,EAjBJC,EAAmBC,GAAQA,EAAKD,kBAAqBE,OAAOC,OAAM,SAAaC,EAAGC,EAAGC,EAAGC,QAC7EC,IAAPD,IAAkBA,EAAKD,GAC3B,IAAIG,EAAOP,OAAOQ,yBAAyBL,EAAGC,GACzCG,KAAS,QAASA,GAAQJ,EAAEM,WAAaF,EAAKG,UAAYH,EAAKI,gBAClEJ,EAAO,CAAEK,YAAY,EAAMC,IAAK,WAAa,OAAOV,EAAEC,EAAG,IAE3DJ,OAAOc,eAAeZ,EAAGG,EAAIE,EAChC,EAAA,SAAcL,EAAGC,EAAGC,EAAGC,QACTC,IAAPD,IAAkBA,EAAKD,GAC3BF,EAAEG,GAAMF,EAAEC,EACb,GACGW,EAAsBhB,GAAQA,EAAKgB,qBAAwBf,OAAOC,OAAM,SAAaC,EAAGc,GACxFhB,OAAOc,eAAeZ,EAAG,UAAW,CAAEU,YAAY,EAAMK,MAAOD,GAClE,EAAI,SAASd,EAAGc,GACbd,EAAW,QAAIc,CACnB,GACIE,EAAgBnB,GAAQA,EAAKmB,eACzBrB,EAAU,SAASK,GAMnB,OALAL,EAAUG,OAAOmB,qBAAuB,SAAUjB,GAC9C,IAAIkB,EAAK,GACT,IAAK,IAAIhB,KAAKF,EAAOF,OAAOqB,UAAUC,eAAeC,KAAKrB,EAAGE,KAAIgB,EAAGA,EAAGI,QAAUpB,GACjF,OAAOgB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AWxC,SAASlB,EAAcoB,EAAMhB,GACzB,MAAME,EAAU,IAAIC,EAAaT,gBAAW7B,EAAWmC,GAEvD,OADA,IAAIM,EAAYX,OAAOO,EAASF,GAASiB,IAAID,GACtCd,EAAQG,IACnB,CAWA,SAASR,EAASmB,EAAMhB,GACpB,OAAOJ,EAAcoB,EAAMhB,GAASkB,QACxC,CA3BA3D,OAAOc,eAAegB,EAAS,aAAc,CAAElB,YAAY,EAAMC,IAAK,WAAc,OAAO2C,EAAarB,UAAW,IAEnHnC,OAAOc,eAAegB,EAAS,iBAAkB,CAAElB,YAAY,EAAMC,IAAK,WAAc,OAAO2C,EAAarB,UAAW,IAiDvH,IAAIyB,EAAiBC,IACrB7D,OAAOc,eAAegB,EAAS,YAAa,CAAElB,YAAY,EAAMC,IAAK,WAAc,OAAOe,EAAgBgC,GAAgB/B,OAAQ,IAClI7B,OAAOc,eAAegB,EAAS,YAAa,CAAElB,YAAY,EAAMC,IAAK,WAAc,OAAO+C,EAAe3B,SAAU,IAKnHH,EAAsBgC,YAAA5C,EAAa6C,KACnC,MAAMX,EAAgCY,IACtC,IAAIC,EAAgCD,IACpChE,OAAOc,eAAegB,EAAS,UAAW,CAAElB,YAAY,EAAMC,IAAK,WAAc,OAAOoD,EAAWjC,OAAQ,IAC3G,MAAMmB,EAA0B,CAAEe,SAAS,GAU3CpC,EAAmBC,SAAAb,EAAa8C"}
1
+ {"version":3,"file":"index.js","sources":["../../../../../node_modules/htmlparser2/dist/commonjs/index.js"],"sourcesContent":["\"use strict\";\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n var desc = Object.getOwnPropertyDescriptor(m, k);\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\n desc = { enumerable: true, get: function() { return m[k]; } };\n }\n Object.defineProperty(o, k2, desc);\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n});\nvar __importStar = (this && this.__importStar) || (function () {\n var ownKeys = function(o) {\n ownKeys = Object.getOwnPropertyNames || function (o) {\n var ar = [];\n for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;\n return ar;\n };\n return ownKeys(o);\n };\n return function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== \"default\") __createBinding(result, mod, k[i]);\n __setModuleDefault(result, mod);\n return result;\n };\n})();\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.DomUtils = exports.getFeed = exports.ElementType = exports.QuoteType = exports.Tokenizer = exports.DefaultHandler = exports.DomHandler = exports.Parser = void 0;\nexports.parseDocument = parseDocument;\nexports.parseDOM = parseDOM;\nexports.createDocumentStream = createDocumentStream;\nexports.createDomStream = createDomStream;\nexports.parseFeed = parseFeed;\nconst Parser_js_1 = require(\"./Parser.js\");\nvar Parser_js_2 = require(\"./Parser.js\");\nObject.defineProperty(exports, \"Parser\", { enumerable: true, get: function () { return Parser_js_2.Parser; } });\nconst domhandler_1 = require(\"domhandler\");\nvar domhandler_2 = require(\"domhandler\");\nObject.defineProperty(exports, \"DomHandler\", { enumerable: true, get: function () { return domhandler_2.DomHandler; } });\n// Old name for DomHandler\nObject.defineProperty(exports, \"DefaultHandler\", { enumerable: true, get: function () { return domhandler_2.DomHandler; } });\n// Helper methods\n/**\n * Parses the data, returns the resulting document.\n *\n * @param data The data that should be parsed.\n * @param options Optional options for the parser and DOM handler.\n */\nfunction parseDocument(data, options) {\n const handler = new domhandler_1.DomHandler(undefined, options);\n new Parser_js_1.Parser(handler, options).end(data);\n return handler.root;\n}\n/**\n * Parses data, returns an array of the root nodes.\n *\n * Note that the root nodes still have a `Document` node as their parent.\n * Use `parseDocument` to get the `Document` node instead.\n *\n * @param data The data that should be parsed.\n * @param options Optional options for the parser and DOM handler.\n * @deprecated Use `parseDocument` instead.\n */\nfunction parseDOM(data, options) {\n return parseDocument(data, options).children;\n}\n/**\n * Creates a parser instance, with an attached DOM handler.\n *\n * @param callback A callback that will be called once parsing has been completed, with the resulting document.\n * @param options Optional options for the parser and DOM handler.\n * @param elementCallback An optional callback that will be called every time a tag has been completed inside of the DOM.\n */\nfunction createDocumentStream(callback, options, elementCallback) {\n const handler = new domhandler_1.DomHandler((error) => callback(error, handler.root), options, elementCallback);\n return new Parser_js_1.Parser(handler, options);\n}\n/**\n * Creates a parser instance, with an attached DOM handler.\n *\n * @param callback A callback that will be called once parsing has been completed, with an array of root nodes.\n * @param options Optional options for the parser and DOM handler.\n * @param elementCallback An optional callback that will be called every time a tag has been completed inside of the DOM.\n * @deprecated Use `createDocumentStream` instead.\n */\nfunction createDomStream(callback, options, elementCallback) {\n const handler = new domhandler_1.DomHandler(callback, options, elementCallback);\n return new Parser_js_1.Parser(handler, options);\n}\nvar Tokenizer_js_1 = require(\"./Tokenizer.js\");\nObject.defineProperty(exports, \"Tokenizer\", { enumerable: true, get: function () { return __importDefault(Tokenizer_js_1).default; } });\nObject.defineProperty(exports, \"QuoteType\", { enumerable: true, get: function () { return Tokenizer_js_1.QuoteType; } });\n/*\n * All of the following exports exist for backwards-compatibility.\n * They should probably be removed eventually.\n */\nexports.ElementType = __importStar(require(\"domelementtype\"));\nconst domutils_1 = require(\"domutils\");\nvar domutils_2 = require(\"domutils\");\nObject.defineProperty(exports, \"getFeed\", { enumerable: true, get: function () { return domutils_2.getFeed; } });\nconst parseFeedDefaultOptions = { xmlMode: true };\n/**\n * Parse a feed.\n *\n * @param feed The feed that should be parsed, as a string.\n * @param options Optionally, options for parsing. When using this, you should set `xmlMode` to `true`.\n */\nfunction parseFeed(feed, options = parseFeedDefaultOptions) {\n return (0, domutils_1.getFeed)(parseDOM(feed, options));\n}\nexports.DomUtils = __importStar(require(\"domutils\"));\n//# sourceMappingURL=index.js.map"],"names":["ownKeys","__createBinding","this","Object","create","o","m","k","k2","undefined","desc","getOwnPropertyDescriptor","__esModule","writable","configurable","enumerable","get","defineProperty","__setModuleDefault","v","value","__importStar","getOwnPropertyNames","ar","prototype","hasOwnProperty","call","length","mod","result","i","__importDefault","default","exports","DomUtils","getFeed","QuoteType","Tokenizer","DomHandler","Parser","parseDocument","parseDOM","createDocumentStream","callback","options","elementCallback","handler","domhandler_1","error","root","Parser_js_1","createDomStream","parseFeed","feed","parseFeedDefaultOptions","domutils_1","require$$0","Parser_js_2","require$$1","domhandler_2","data","end","children","Tokenizer_js_1","require$$2","ElementType","require$$3","require$$4","domutils_2","xmlMode"],"mappings":"sXACA,IAiBQA,EAjBJC,EAAmBC,GAAQA,EAAKD,kBAAqBE,OAAOC,OAAM,SAAaC,EAAGC,EAAGC,EAAGC,QAC7EC,IAAPD,IAAkBA,EAAKD,GAC3B,IAAIG,EAAOP,OAAOQ,yBAAyBL,EAAGC,GACzCG,KAAS,QAASA,GAAQJ,EAAEM,WAAaF,EAAKG,UAAYH,EAAKI,gBAClEJ,EAAO,CAAEK,YAAY,EAAMC,IAAK,WAAa,OAAOV,EAAEC,EAAG,IAE3DJ,OAAOc,eAAeZ,EAAGG,EAAIE,EAChC,EAAA,SAAcL,EAAGC,EAAGC,EAAGC,QACTC,IAAPD,IAAkBA,EAAKD,GAC3BF,EAAEG,GAAMF,EAAEC,EACb,GACGW,EAAsBhB,GAAQA,EAAKgB,qBAAwBf,OAAOC,OAAM,SAAaC,EAAGc,GACxFhB,OAAOc,eAAeZ,EAAG,UAAW,CAAEU,YAAY,EAAMK,MAAOD,GAClE,EAAI,SAASd,EAAGc,GACbd,EAAW,QAAIc,CACnB,GACIE,EAAgBnB,GAAQA,EAAKmB,eACzBrB,EAAU,SAASK,GAMnB,OALAL,EAA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,EAAcM,IACpB,IAAIC,EAAcD,IAClBrD,OAAOc,eAAegB,EAAS,SAAU,CAAElB,YAAY,EAAMC,IAAK,WAAc,OAAOyC,EAAYlB,MAAO,IAC1G,MAAMQ,EAAoCW,IAC1C,IAAIC,EAAoCD,IAWxC,SAASlB,EAAcoB,EAAMhB,GACzB,MAAME,EAAU,IAAIC,EAAaT,gBAAW7B,EAAWmC,GAEvD,OADA,IAAIM,EAAYX,OAAOO,EAASF,GAASiB,IAAID,GACtCd,EAAQG,IACnB,CAWA,SAASR,EAASmB,EAAMhB,GACpB,OAAOJ,EAAcoB,EAAMhB,GAASkB,QACxC,CA3BA3D,OAAOc,eAAegB,EAAS,aAAc,CAAElB,YAAY,EAAMC,IAAK,WAAc,OAAO2C,EAAarB,UAAW,IAEnHnC,OAAOc,eAAegB,EAAS,iBAAkB,CAAElB,YAAY,EAAMC,IAAK,WAAc,OAAO2C,EAAarB,UAAW,IAiDvH,IAAIyB,EAAiBC,IACrB7D,OAAOc,eAAegB,EAAS,YAAa,CAAElB,YAAY,EAAMC,IAAK,WAAc,OAAOe,EAAgBgC,GAAgB/B,OAAQ,IAClI7B,OAAOc,eAAegB,EAAS,YAAa,CAAElB,YAAY,EAAMC,IAAK,WAAc,OAAO+C,EAAe3B,SAAU,IAKnHH,EAAsBgC,YAAA5C,EAAa6C,KACnC,MAAMX,EAAgCY,IACtC,IAAIC,EAAgCD,IACpChE,OAAOc,eAAegB,EAAS,UAAW,CAAElB,YAAY,EAAMC,IAAK,WAAc,OAAOoD,EAAWjC,OAAQ,IAC3G,MAAMmB,EAA0B,CAAEe,SAAS,GAU3CpC,EAAmBC,SAAAb,EAAa8C"}
@@ -0,0 +1,2 @@
1
+ import{__exports as e}from"../../../_virtual/core2.js";import{__require as t}from"../../highlight.js/lib/core.js";import{__require as r}from"../../fault/index.js";var n;function o(){if(n)return e;n=1;var o=t(),i=r();e.highlight=s,e.highlightAuto=function(e,t){var r=t||{},n=r.subset||o.listLanguages();r.prefix;var a,l,g,u,c=n.length,h=-1;if("string"!=typeof e)throw i("Expected `string` for value, got `%s`",e);l={relevance:0,language:null,value:[]},a={relevance:0,language:null,value:[]};for(;++h<c;)u=n[h],o.getLanguage(u)&&((g=s(u,e,t)).language=u,g.relevance>l.relevance&&(l=g),g.relevance>a.relevance&&(l=a,a=g));l.language&&(a.secondBest=l);return a},e.registerLanguage=function(e,t){o.registerLanguage(e,t)},e.listLanguages=function(){return o.listLanguages()},e.registerAlias=function(e,t){var r,n=e;t&&((n={})[e]=t);for(r in n)o.registerAliases(n[r],{languageName:r})},l.prototype.addText=function(e){var t,r,n=this.stack;if(""===e)return;t=n[n.length-1],(r=t.children[t.children.length-1])&&"text"===r.type?r.value+=e:t.children.push({type:"text",value:e})},l.prototype.addKeyword=function(e,t){this.openNode(t),this.addText(e),this.closeNode()},l.prototype.addSublanguage=function(e,t){var r=this.stack,n=r[r.length-1],o=e.rootNode.children,i=t?{type:"element",tagName:"span",properties:{className:[t]},children:o}:o;n.children=n.children.concat(i)},l.prototype.openNode=function(e){var t=this.stack,r=this.options.classPrefix+e,n=t[t.length-1],o={type:"element",tagName:"span",properties:{className:[r]},children:[]};n.children.push(o),t.push(o)},l.prototype.closeNode=function(){this.stack.pop()},l.prototype.closeAllNodes=g,l.prototype.finalize=g,l.prototype.toHTML=function(){return""};var a="hljs-";function s(e,t,r){var n,s=o.configure({}),g=(r||{}).prefix;if("string"!=typeof e)throw i("Expected `string` for name, got `%s`",e);if(!o.getLanguage(e))throw i("Unknown language: `%s` is not registered",e);if("string"!=typeof t)throw i("Expected `string` for value, got `%s`",t);if(null==g&&(g=a),o.configure({__emitter:l,classPrefix:g}),n=o.highlight(t,{language:e,ignoreIllegals:!0}),o.configure(s||{}),n.errorRaised)throw n.errorRaised;return{relevance:n.relevance,language:n.language,value:n.emitter.rootNode.children}}function l(e){this.options=e,this.rootNode={children:[]},this.stack=[this.rootNode]}function g(){}return e}export{o as __require};
2
+ //# sourceMappingURL=core.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"core.js","sources":["../../../../node_modules/lowlight/lib/core.js"],"sourcesContent":["'use strict'\n\nvar high = require('highlight.js/lib/core')\nvar fault = require('fault')\n\nexports.highlight = highlight\nexports.highlightAuto = highlightAuto\nexports.registerLanguage = registerLanguage\nexports.listLanguages = listLanguages\nexports.registerAlias = registerAlias\n\nEmitter.prototype.addText = text\nEmitter.prototype.addKeyword = addKeyword\nEmitter.prototype.addSublanguage = addSublanguage\nEmitter.prototype.openNode = open\nEmitter.prototype.closeNode = close\nEmitter.prototype.closeAllNodes = noop\nEmitter.prototype.finalize = noop\nEmitter.prototype.toHTML = toHtmlNoop\n\nvar defaultPrefix = 'hljs-'\n\n// Highlighting `value` in the language `name`.\nfunction highlight(name, value, options) {\n var before = high.configure({})\n var settings = options || {}\n var prefix = settings.prefix\n var result\n\n if (typeof name !== 'string') {\n throw fault('Expected `string` for name, got `%s`', name)\n }\n\n if (!high.getLanguage(name)) {\n throw fault('Unknown language: `%s` is not registered', name)\n }\n\n if (typeof value !== 'string') {\n throw fault('Expected `string` for value, got `%s`', value)\n }\n\n if (prefix === null || prefix === undefined) {\n prefix = defaultPrefix\n }\n\n high.configure({__emitter: Emitter, classPrefix: prefix})\n\n result = high.highlight(value, {language: name, ignoreIllegals: true})\n\n high.configure(before || {})\n\n /* istanbul ignore if - Highlight.js seems to use this (currently) for broken\n * grammars, so let’s keep it in there just to be sure. */\n if (result.errorRaised) {\n throw result.errorRaised\n }\n\n return {\n relevance: result.relevance,\n language: result.language,\n value: result.emitter.rootNode.children\n }\n}\n\nfunction highlightAuto(value, options) {\n var settings = options || {}\n var subset = settings.subset || high.listLanguages()\n var prefix = settings.prefix\n var length = subset.length\n var index = -1\n var result\n var secondBest\n var current\n var name\n\n if (prefix === null || prefix === undefined) {\n prefix = defaultPrefix\n }\n\n if (typeof value !== 'string') {\n throw fault('Expected `string` for value, got `%s`', value)\n }\n\n secondBest = {relevance: 0, language: null, value: []}\n result = {relevance: 0, language: null, value: []}\n\n while (++index < length) {\n name = subset[index]\n\n if (!high.getLanguage(name)) {\n continue\n }\n\n current = highlight(name, value, options)\n current.language = name\n\n if (current.relevance > secondBest.relevance) {\n secondBest = current\n }\n\n if (current.relevance > result.relevance) {\n secondBest = result\n result = current\n }\n }\n\n if (secondBest.language) {\n result.secondBest = secondBest\n }\n\n return result\n}\n\n// Register a language.\nfunction registerLanguage(name, syntax) {\n high.registerLanguage(name, syntax)\n}\n\n// Get a list of all registered languages.\nfunction listLanguages() {\n return high.listLanguages()\n}\n\n// Register more aliases for an already registered language.\nfunction registerAlias(name, alias) {\n var map = name\n var key\n\n if (alias) {\n map = {}\n map[name] = alias\n }\n\n for (key in map) {\n high.registerAliases(map[key], {languageName: key})\n }\n}\n\nfunction Emitter(options) {\n this.options = options\n this.rootNode = {children: []}\n this.stack = [this.rootNode]\n}\n\nfunction addKeyword(value, name) {\n this.openNode(name)\n this.addText(value)\n this.closeNode()\n}\n\nfunction addSublanguage(other, name) {\n var stack = this.stack\n var current = stack[stack.length - 1]\n var results = other.rootNode.children\n var node = name\n ? {\n type: 'element',\n tagName: 'span',\n properties: {className: [name]},\n children: results\n }\n : results\n\n current.children = current.children.concat(node)\n}\n\nfunction text(value) {\n var stack = this.stack\n var current\n var tail\n\n if (value === '') return\n\n current = stack[stack.length - 1]\n tail = current.children[current.children.length - 1]\n\n if (tail && tail.type === 'text') {\n tail.value += value\n } else {\n current.children.push({type: 'text', value: value})\n }\n}\n\nfunction open(name) {\n var stack = this.stack\n var className = this.options.classPrefix + name\n var current = stack[stack.length - 1]\n var child = {\n type: 'element',\n tagName: 'span',\n properties: {className: [className]},\n children: []\n }\n\n current.children.push(child)\n stack.push(child)\n}\n\nfunction close() {\n this.stack.pop()\n}\n\nfunction toHtmlNoop() {\n return ''\n}\n\nfunction noop() {}\n"],"names":["high","require$$0","fault","require$$1","core","highlight","highlightAuto","value","options","settings","subset","listLanguages","prefix","result","secondBest","current","name","length","index","relevance","language","getLanguage","registerLanguage","syntax","registerAlias","alias","key","map","registerAliases","languageName","Emitter","prototype","addText","tail","stack","this","children","type","push","addKeyword","openNode","closeNode","addSublanguage","other","results","rootNode","node","tagName","properties","className","concat","classPrefix","child","pop","closeAllNodes","noop","finalize","toHTML","defaultPrefix","before","configure","__emitter","ignoreIllegals","errorRaised","emitter"],"mappings":"wMAEA,IAAIA,EAAOC,IACPC,EAAQC,IAEZC,EAAAC,UAAoBA,EACpBD,EAAAE,cA0DA,SAAuBC,EAAOC,GAC5B,IAAIC,EAAWD,GAAW,CAAA,EACtBE,EAASD,EAASC,QAAUV,EAAKW,gBACxBF,EAASG,OACtB,IAEIC,EACAC,EACAC,EACAC,EALAC,EAASP,EAAOO,OAChBC,GAAS,EAUb,GAAqB,iBAAVX,EACT,MAAML,EAAM,wCAAyCK,GAGvDO,EAAa,CAACK,UAAW,EAAGC,SAAU,KAAMb,MAAO,IACnDM,EAAS,CAACM,UAAW,EAAGC,SAAU,KAAMb,MAAO,IAE/C,OAASW,EAAQD,GACfD,EAAON,EAAOQ,GAETlB,EAAKqB,YAAYL,MAItBD,EAAUV,EAAUW,EAAMT,EAAOC,IACzBY,SAAWJ,EAEfD,EAAQI,UAAYL,EAAWK,YACjCL,EAAaC,GAGXA,EAAQI,UAAYN,EAAOM,YAC7BL,EAAaD,EACbA,EAASE,IAITD,EAAWM,WACbP,EAAOC,WAAaA,GAGtB,OAAOD,CACT,EAxGAT,EAAAkB,iBA2GA,SAA0BN,EAAMO,GAC9BvB,EAAKsB,iBAAiBN,EAAMO,EAC9B,EA5GAnB,EAAAO,cA+GA,WACE,OAAOX,EAAKW,eACd,EAhHAP,EAAAoB,cAmHA,SAAuBR,EAAMS,GAC3B,IACIC,EADAC,EAAMX,EAGNS,KACFE,EAAM,CAAA,GACFX,GAAQS,GAGd,IAAKC,KAAOC,EACV3B,EAAK4B,gBAAgBD,EAAID,GAAM,CAACG,aAAcH,GAElD,EA7HAI,EAAQC,UAAUC,QA2JlB,SAAczB,GACZ,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,EAAK4D,UAAU,IAExBhD,GADWJ,GAAW,CAAA,GACJI,OAGtB,GAAoB,iBAATI,EACT,MAAMd,EAAM,uCAAwCc,GAGtD,IAAKhB,EAAKqB,YAAYL,GACpB,MAAMd,EAAM,2CAA4Cc,GAG1D,GAAqB,iBAAVT,EACT,MAAML,EAAM,wCAAyCK,GAevD,GAZIK,UACFA,EAAS8C,GAGX1D,EAAK4D,UAAU,CAACC,UAAW/B,EAASqB,YAAavC,IAEjDC,EAASb,EAAKK,UAAUE,EAAO,CAACa,SAAUJ,EAAM8C,gBAAgB,IAEhE9D,EAAK4D,UAAUD,GAAU,IAIrB9C,EAAOkD,YACT,MAAMlD,EAAOkD,YAGf,MAAO,CACL5C,UAAWN,EAAOM,UAClBC,SAAUP,EAAOO,SACjBb,MAAOM,EAAOmD,QAAQnB,SAAST,SAEnC,CA4EA,SAASN,EAAQtB,GACf2B,KAAK3B,QAAUA,EACf2B,KAAKU,SAAW,CAACT,SAAU,IAC3BD,KAAKD,MAAQ,CAACC,KAAKU,SACrB,CAgEA,SAASU,IAAO"}
@@ -0,0 +1,2 @@
1
+ import{webcrypto as e}from"node:crypto";import{urlAlphabet as t}from"./url-alphabet/index.js";export{urlAlphabet}from"./url-alphabet/index.js";let r,l;function o(o=21){var a;a=o|=0,!r||r.length<a?(r=Buffer.allocUnsafe(128*a),e.getRandomValues(r),l=0):l+a>r.length&&(e.getRandomValues(r),l=0),l+=a;let n="";for(let e=l-o;e<l;e++)n+=t[63&r[e]];return n}export{o as nanoid};
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sources":["../../../node_modules/nanoid/index.js"],"sourcesContent":["import { webcrypto as crypto } from 'node:crypto'\nimport { urlAlphabet as scopedUrlAlphabet } from './url-alphabet/index.js'\nexport { urlAlphabet } from './url-alphabet/index.js'\nconst POOL_SIZE_MULTIPLIER = 128\nlet pool, poolOffset\nfunction fillPool(bytes) {\n if (!pool || pool.length < bytes) {\n pool = Buffer.allocUnsafe(bytes * POOL_SIZE_MULTIPLIER)\n crypto.getRandomValues(pool)\n poolOffset = 0\n } else if (poolOffset + bytes > pool.length) {\n crypto.getRandomValues(pool)\n poolOffset = 0\n }\n poolOffset += bytes\n}\nexport function random(bytes) {\n fillPool((bytes |= 0))\n return pool.subarray(poolOffset - bytes, poolOffset)\n}\nexport function customRandom(alphabet, defaultSize, getRandom) {\n let mask = (2 << (31 - Math.clz32((alphabet.length - 1) | 1))) - 1\n let step = Math.ceil((1.6 * mask * defaultSize) / alphabet.length)\n return (size = defaultSize) => {\n let id = ''\n while (true) {\n let bytes = getRandom(step)\n let i = step\n while (i--) {\n id += alphabet[bytes[i] & mask] || ''\n if (id.length >= size) return id\n }\n }\n }\n}\nexport function customAlphabet(alphabet, size = 21) {\n return customRandom(alphabet, size, random)\n}\nexport function nanoid(size = 21) {\n fillPool((size |= 0))\n let id = ''\n for (let i = poolOffset - size; i < poolOffset; i++) {\n id += scopedUrlAlphabet[pool[i] & 63]\n }\n return id\n}\n"],"names":["pool","poolOffset","nanoid","size","bytes","length","Buffer","allocUnsafe","crypto","getRandomValues","id","i","scopedUrlAlphabet"],"mappings":"+IAIA,IAAIA,EAAMC,EAkCH,SAASC,EAAOC,EAAO,IAjC9B,IAAkBC,IAkCND,GAAQ,GAjCbH,GAAQA,EAAKK,OAASD,GACzBJ,EAAOM,OAAOC,YAJW,IAICH,GAC1BI,EAAOC,gBAAgBT,GACvBC,EAAa,GACJA,EAAaG,EAAQJ,EAAKK,SACnCG,EAAOC,gBAAgBT,GACvBC,EAAa,GAEfA,GAAcG,EA0Bd,IAAIM,EAAK,GACT,IAAK,IAAIC,EAAIV,EAAaE,EAAMQ,EAAIV,EAAYU,IAC9CD,GAAME,EAA4B,GAAVZ,EAAKW,IAE/B,OAAOD,CACT"}
@@ -0,0 +1,2 @@
1
+ const o="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";export{o as urlAlphabet};
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sources":["../../../../node_modules/nanoid/url-alphabet/index.js"],"sourcesContent":["export const urlAlphabet =\n 'useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict'\n"],"names":["urlAlphabet"],"mappings":"AAAY,MAACA,EACX"}
@@ -0,0 +1,2 @@
1
+ var a=function(a,e){return-1!==a.listLanguages().indexOf(e)};export{a as default};
2
+ //# sourceMappingURL=checkForListedLanguage.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"checkForListedLanguage.js","sources":["../../../../../node_modules/react-syntax-highlighter/dist/esm/checkForListedLanguage.js"],"sourcesContent":["export default (function (astGenerator, language) {\n var langs = astGenerator.listLanguages();\n return langs.indexOf(language) !== -1;\n});"],"names":["checkForListedLanguage","astGenerator","language","listLanguages","indexOf"],"mappings":"AAAA,IAAAA,EAAe,SAAWC,EAAcC,GAEtC,OAAoC,IADxBD,EAAaE,gBACZC,QAAQF,EACtB"}
@@ -0,0 +1,2 @@
1
+ import c from"../../../@babel/runtime/helpers/esm/extends.js";import t from"../../../@babel/runtime/helpers/esm/defineProperty.js";import n from"react";function o(c,t){var n=Object.keys(c);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(c);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(c,t).enumerable}))),n.push.apply(n,o)}return n}function a(c){for(var n=1;n<arguments.length;n++){var a=null!=arguments[n]?arguments[n]:{};n%2?o(Object(a),!0).forEach((function(n){t(c,n,a[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(c,Object.getOwnPropertyDescriptors(a)):o(Object(a)).forEach((function(t){Object.defineProperty(c,t,Object.getOwnPropertyDescriptor(a,t))}))}return c}var e={};function r(c){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0;return function(c){if(0===c.length||1===c.length)return c;var t,n,o=c.join(".");return e[o]||(e[o]=0===(n=(t=c).length)||1===n?t:2===n?[t[0],t[1],"".concat(t[0],".").concat(t[1]),"".concat(t[1],".").concat(t[0])]:3===n?[t[0],t[1],t[2],"".concat(t[0],".").concat(t[1]),"".concat(t[0],".").concat(t[2]),"".concat(t[1],".").concat(t[0]),"".concat(t[1],".").concat(t[2]),"".concat(t[2],".").concat(t[0]),"".concat(t[2],".").concat(t[1]),"".concat(t[0],".").concat(t[1],".").concat(t[2]),"".concat(t[0],".").concat(t[2],".").concat(t[1]),"".concat(t[1],".").concat(t[0],".").concat(t[2]),"".concat(t[1],".").concat(t[2],".").concat(t[0]),"".concat(t[2],".").concat(t[0],".").concat(t[1]),"".concat(t[2],".").concat(t[1],".").concat(t[0])]:n>=4?[t[0],t[1],t[2],t[3],"".concat(t[0],".").concat(t[1]),"".concat(t[0],".").concat(t[2]),"".concat(t[0],".").concat(t[3]),"".concat(t[1],".").concat(t[0]),"".concat(t[1],".").concat(t[2]),"".concat(t[1],".").concat(t[3]),"".concat(t[2],".").concat(t[0]),"".concat(t[2],".").concat(t[1]),"".concat(t[2],".").concat(t[3]),"".concat(t[3],".").concat(t[0]),"".concat(t[3],".").concat(t[1]),"".concat(t[3],".").concat(t[2]),"".concat(t[0],".").concat(t[1],".").concat(t[2]),"".concat(t[0],".").concat(t[1],".").concat(t[3]),"".concat(t[0],".").concat(t[2],".").concat(t[1]),"".concat(t[0],".").concat(t[2],".").concat(t[3]),"".concat(t[0],".").concat(t[3],".").concat(t[1]),"".concat(t[0],".").concat(t[3],".").concat(t[2]),"".concat(t[1],".").concat(t[0],".").concat(t[2]),"".concat(t[1],".").concat(t[0],".").concat(t[3]),"".concat(t[1],".").concat(t[2],".").concat(t[0]),"".concat(t[1],".").concat(t[2],".").concat(t[3]),"".concat(t[1],".").concat(t[3],".").concat(t[0]),"".concat(t[1],".").concat(t[3],".").concat(t[2]),"".concat(t[2],".").concat(t[0],".").concat(t[1]),"".concat(t[2],".").concat(t[0],".").concat(t[3]),"".concat(t[2],".").concat(t[1],".").concat(t[0]),"".concat(t[2],".").concat(t[1],".").concat(t[3]),"".concat(t[2],".").concat(t[3],".").concat(t[0]),"".concat(t[2],".").concat(t[3],".").concat(t[1]),"".concat(t[3],".").concat(t[0],".").concat(t[1]),"".concat(t[3],".").concat(t[0],".").concat(t[2]),"".concat(t[3],".").concat(t[1],".").concat(t[0]),"".concat(t[3],".").concat(t[1],".").concat(t[2]),"".concat(t[3],".").concat(t[2],".").concat(t[0]),"".concat(t[3],".").concat(t[2],".").concat(t[1]),"".concat(t[0],".").concat(t[1],".").concat(t[2],".").concat(t[3]),"".concat(t[0],".").concat(t[1],".").concat(t[3],".").concat(t[2]),"".concat(t[0],".").concat(t[2],".").concat(t[1],".").concat(t[3]),"".concat(t[0],".").concat(t[2],".").concat(t[3],".").concat(t[1]),"".concat(t[0],".").concat(t[3],".").concat(t[1],".").concat(t[2]),"".concat(t[0],".").concat(t[3],".").concat(t[2],".").concat(t[1]),"".concat(t[1],".").concat(t[0],".").concat(t[2],".").concat(t[3]),"".concat(t[1],".").concat(t[0],".").concat(t[3],".").concat(t[2]),"".concat(t[1],".").concat(t[2],".").concat(t[0],".").concat(t[3]),"".concat(t[1],".").concat(t[2],".").concat(t[3],".").concat(t[0]),"".concat(t[1],".").concat(t[3],".").concat(t[0],".").concat(t[2]),"".concat(t[1],".").concat(t[3],".").concat(t[2],".").concat(t[0]),"".concat(t[2],".").concat(t[0],".").concat(t[1],".").concat(t[3]),"".concat(t[2],".").concat(t[0],".").concat(t[3],".").concat(t[1]),"".concat(t[2],".").concat(t[1],".").concat(t[0],".").concat(t[3]),"".concat(t[2],".").concat(t[1],".").concat(t[3],".").concat(t[0]),"".concat(t[2],".").concat(t[3],".").concat(t[0],".").concat(t[1]),"".concat(t[2],".").concat(t[3],".").concat(t[1],".").concat(t[0]),"".concat(t[3],".").concat(t[0],".").concat(t[1],".").concat(t[2]),"".concat(t[3],".").concat(t[0],".").concat(t[2],".").concat(t[1]),"".concat(t[3],".").concat(t[1],".").concat(t[0],".").concat(t[2]),"".concat(t[3],".").concat(t[1],".").concat(t[2],".").concat(t[0]),"".concat(t[3],".").concat(t[2],".").concat(t[0],".").concat(t[1]),"".concat(t[3],".").concat(t[2],".").concat(t[1],".").concat(t[0])]:void 0),e[o]}(c.filter((function(c){return"token"!==c}))).reduce((function(c,t){return a(a({},c),n[t])}),t)}function s(c){return c.join(" ")}function i(c,t){var n=0;return function(o){return n+=1,o.map((function(o,a){return u({node:o,stylesheet:c,useInlineStyles:t,key:"code-segment-".concat(n,"-").concat(a)})}))}}function u(t){var o=t.node,e=t.stylesheet,u=t.style,l=void 0===u?{}:u,f=t.useInlineStyles,p=t.key,m=o.properties,y=o.type,b=o.tagName,d=o.value;if("text"===y)return d;if(b){var O,v=i(e,f);if(f){var j=Object.keys(e).reduce((function(c,t){return t.split(".").forEach((function(t){c.includes(t)||c.push(t)})),c}),[]),h=m.className&&m.className.includes("token")?["token"]:[],g=m.className&&h.concat(m.className.filter((function(c){return!j.includes(c)})));O=a(a({},m),{},{className:s(g)||void 0,style:r(m.className,Object.assign({},m.style,l),e)})}else O=a(a({},m),{},{className:s(m.className)});var N=v(o.children);return n.createElement(b,c({key:p},O),N)}}export{i as createChildren,s as createClassNameString,r as createStyleObject,u as default};
2
+ //# sourceMappingURL=create-element.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"create-element.js","sources":["../../../../../node_modules/react-syntax-highlighter/dist/esm/create-element.js"],"sourcesContent":["import _extends from \"@babel/runtime/helpers/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nfunction ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }\nimport React from 'react';\n\n// Get all possible permutations of all power sets\n//\n// Super simple, non-algorithmic solution since the\n// number of class names will not be greater than 4\nfunction powerSetPermutations(arr) {\n var arrLength = arr.length;\n if (arrLength === 0 || arrLength === 1) return arr;\n if (arrLength === 2) {\n // prettier-ignore\n return [arr[0], arr[1], \"\".concat(arr[0], \".\").concat(arr[1]), \"\".concat(arr[1], \".\").concat(arr[0])];\n }\n if (arrLength === 3) {\n return [arr[0], arr[1], arr[2], \"\".concat(arr[0], \".\").concat(arr[1]), \"\".concat(arr[0], \".\").concat(arr[2]), \"\".concat(arr[1], \".\").concat(arr[0]), \"\".concat(arr[1], \".\").concat(arr[2]), \"\".concat(arr[2], \".\").concat(arr[0]), \"\".concat(arr[2], \".\").concat(arr[1]), \"\".concat(arr[0], \".\").concat(arr[1], \".\").concat(arr[2]), \"\".concat(arr[0], \".\").concat(arr[2], \".\").concat(arr[1]), \"\".concat(arr[1], \".\").concat(arr[0], \".\").concat(arr[2]), \"\".concat(arr[1], \".\").concat(arr[2], \".\").concat(arr[0]), \"\".concat(arr[2], \".\").concat(arr[0], \".\").concat(arr[1]), \"\".concat(arr[2], \".\").concat(arr[1], \".\").concat(arr[0])];\n }\n if (arrLength >= 4) {\n // Currently does not support more than 4 extra\n // class names (after `.token` has been removed)\n return [arr[0], arr[1], arr[2], arr[3], \"\".concat(arr[0], \".\").concat(arr[1]), \"\".concat(arr[0], \".\").concat(arr[2]), \"\".concat(arr[0], \".\").concat(arr[3]), \"\".concat(arr[1], \".\").concat(arr[0]), \"\".concat(arr[1], \".\").concat(arr[2]), \"\".concat(arr[1], \".\").concat(arr[3]), \"\".concat(arr[2], \".\").concat(arr[0]), \"\".concat(arr[2], \".\").concat(arr[1]), \"\".concat(arr[2], \".\").concat(arr[3]), \"\".concat(arr[3], \".\").concat(arr[0]), \"\".concat(arr[3], \".\").concat(arr[1]), \"\".concat(arr[3], \".\").concat(arr[2]), \"\".concat(arr[0], \".\").concat(arr[1], \".\").concat(arr[2]), \"\".concat(arr[0], \".\").concat(arr[1], \".\").concat(arr[3]), \"\".concat(arr[0], \".\").concat(arr[2], \".\").concat(arr[1]), \"\".concat(arr[0], \".\").concat(arr[2], \".\").concat(arr[3]), \"\".concat(arr[0], \".\").concat(arr[3], \".\").concat(arr[1]), \"\".concat(arr[0], \".\").concat(arr[3], \".\").concat(arr[2]), \"\".concat(arr[1], \".\").concat(arr[0], \".\").concat(arr[2]), \"\".concat(arr[1], \".\").concat(arr[0], \".\").concat(arr[3]), \"\".concat(arr[1], \".\").concat(arr[2], \".\").concat(arr[0]), \"\".concat(arr[1], \".\").concat(arr[2], \".\").concat(arr[3]), \"\".concat(arr[1], \".\").concat(arr[3], \".\").concat(arr[0]), \"\".concat(arr[1], \".\").concat(arr[3], \".\").concat(arr[2]), \"\".concat(arr[2], \".\").concat(arr[0], \".\").concat(arr[1]), \"\".concat(arr[2], \".\").concat(arr[0], \".\").concat(arr[3]), \"\".concat(arr[2], \".\").concat(arr[1], \".\").concat(arr[0]), \"\".concat(arr[2], \".\").concat(arr[1], \".\").concat(arr[3]), \"\".concat(arr[2], \".\").concat(arr[3], \".\").concat(arr[0]), \"\".concat(arr[2], \".\").concat(arr[3], \".\").concat(arr[1]), \"\".concat(arr[3], \".\").concat(arr[0], \".\").concat(arr[1]), \"\".concat(arr[3], \".\").concat(arr[0], \".\").concat(arr[2]), \"\".concat(arr[3], \".\").concat(arr[1], \".\").concat(arr[0]), \"\".concat(arr[3], \".\").concat(arr[1], \".\").concat(arr[2]), \"\".concat(arr[3], \".\").concat(arr[2], \".\").concat(arr[0]), \"\".concat(arr[3], \".\").concat(arr[2], \".\").concat(arr[1]), \"\".concat(arr[0], \".\").concat(arr[1], \".\").concat(arr[2], \".\").concat(arr[3]), \"\".concat(arr[0], \".\").concat(arr[1], \".\").concat(arr[3], \".\").concat(arr[2]), \"\".concat(arr[0], \".\").concat(arr[2], \".\").concat(arr[1], \".\").concat(arr[3]), \"\".concat(arr[0], \".\").concat(arr[2], \".\").concat(arr[3], \".\").concat(arr[1]), \"\".concat(arr[0], \".\").concat(arr[3], \".\").concat(arr[1], \".\").concat(arr[2]), \"\".concat(arr[0], \".\").concat(arr[3], \".\").concat(arr[2], \".\").concat(arr[1]), \"\".concat(arr[1], \".\").concat(arr[0], \".\").concat(arr[2], \".\").concat(arr[3]), \"\".concat(arr[1], \".\").concat(arr[0], \".\").concat(arr[3], \".\").concat(arr[2]), \"\".concat(arr[1], \".\").concat(arr[2], \".\").concat(arr[0], \".\").concat(arr[3]), \"\".concat(arr[1], \".\").concat(arr[2], \".\").concat(arr[3], \".\").concat(arr[0]), \"\".concat(arr[1], \".\").concat(arr[3], \".\").concat(arr[0], \".\").concat(arr[2]), \"\".concat(arr[1], \".\").concat(arr[3], \".\").concat(arr[2], \".\").concat(arr[0]), \"\".concat(arr[2], \".\").concat(arr[0], \".\").concat(arr[1], \".\").concat(arr[3]), \"\".concat(arr[2], \".\").concat(arr[0], \".\").concat(arr[3], \".\").concat(arr[1]), \"\".concat(arr[2], \".\").concat(arr[1], \".\").concat(arr[0], \".\").concat(arr[3]), \"\".concat(arr[2], \".\").concat(arr[1], \".\").concat(arr[3], \".\").concat(arr[0]), \"\".concat(arr[2], \".\").concat(arr[3], \".\").concat(arr[0], \".\").concat(arr[1]), \"\".concat(arr[2], \".\").concat(arr[3], \".\").concat(arr[1], \".\").concat(arr[0]), \"\".concat(arr[3], \".\").concat(arr[0], \".\").concat(arr[1], \".\").concat(arr[2]), \"\".concat(arr[3], \".\").concat(arr[0], \".\").concat(arr[2], \".\").concat(arr[1]), \"\".concat(arr[3], \".\").concat(arr[1], \".\").concat(arr[0], \".\").concat(arr[2]), \"\".concat(arr[3], \".\").concat(arr[1], \".\").concat(arr[2], \".\").concat(arr[0]), \"\".concat(arr[3], \".\").concat(arr[2], \".\").concat(arr[0], \".\").concat(arr[1]), \"\".concat(arr[3], \".\").concat(arr[2], \".\").concat(arr[1], \".\").concat(arr[0])];\n }\n}\nvar classNameCombinations = {};\nfunction getClassNameCombinations(classNames) {\n if (classNames.length === 0 || classNames.length === 1) return classNames;\n var key = classNames.join('.');\n if (!classNameCombinations[key]) {\n classNameCombinations[key] = powerSetPermutations(classNames);\n }\n return classNameCombinations[key];\n}\nexport function createStyleObject(classNames) {\n var elementStyle = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n var stylesheet = arguments.length > 2 ? arguments[2] : undefined;\n var nonTokenClassNames = classNames.filter(function (className) {\n return className !== 'token';\n });\n var classNamesCombinations = getClassNameCombinations(nonTokenClassNames);\n return classNamesCombinations.reduce(function (styleObject, className) {\n return _objectSpread(_objectSpread({}, styleObject), stylesheet[className]);\n }, elementStyle);\n}\nexport function createClassNameString(classNames) {\n return classNames.join(' ');\n}\nexport function createChildren(stylesheet, useInlineStyles) {\n var childrenCount = 0;\n return function (children) {\n childrenCount += 1;\n return children.map(function (child, i) {\n return createElement({\n node: child,\n stylesheet: stylesheet,\n useInlineStyles: useInlineStyles,\n key: \"code-segment-\".concat(childrenCount, \"-\").concat(i)\n });\n });\n };\n}\nexport default function createElement(_ref) {\n var node = _ref.node,\n stylesheet = _ref.stylesheet,\n _ref$style = _ref.style,\n style = _ref$style === void 0 ? {} : _ref$style,\n useInlineStyles = _ref.useInlineStyles,\n key = _ref.key;\n var properties = node.properties,\n type = node.type,\n TagName = node.tagName,\n value = node.value;\n if (type === 'text') {\n return value;\n } else if (TagName) {\n var childrenCreator = createChildren(stylesheet, useInlineStyles);\n var props;\n if (!useInlineStyles) {\n props = _objectSpread(_objectSpread({}, properties), {}, {\n className: createClassNameString(properties.className)\n });\n } else {\n var allStylesheetSelectors = Object.keys(stylesheet).reduce(function (classes, selector) {\n selector.split('.').forEach(function (className) {\n if (!classes.includes(className)) classes.push(className);\n });\n return classes;\n }, []);\n\n // For compatibility with older versions of react-syntax-highlighter\n var startingClassName = properties.className && properties.className.includes('token') ? ['token'] : [];\n var className = properties.className && startingClassName.concat(properties.className.filter(function (className) {\n return !allStylesheetSelectors.includes(className);\n }));\n props = _objectSpread(_objectSpread({}, properties), {}, {\n className: createClassNameString(className) || undefined,\n style: createStyleObject(properties.className, Object.assign({}, properties.style, style), stylesheet)\n });\n }\n var children = childrenCreator(node.children);\n return /*#__PURE__*/React.createElement(TagName, _extends({\n key: key\n }, props), children);\n }\n}"],"names":["ownKeys","e","r","t","Object","keys","getOwnPropertySymbols","o","filter","getOwnPropertyDescriptor","enumerable","push","apply","_objectSpread","arguments","length","forEach","_defineProperty","getOwnPropertyDescriptors","defineProperties","defineProperty","classNameCombinations","createStyleObject","classNames","elementStyle","undefined","stylesheet","arr","arrLength","key","join","concat","getClassNameCombinations","className","reduce","styleObject","createClassNameString","createChildren","useInlineStyles","childrenCount","children","map","child","i","createElement","node","_ref","_ref$style","style","properties","type","TagName","tagName","value","props","childrenCreator","allStylesheetSelectors","classes","selector","split","includes","startingClassName","assign","React","_extends"],"mappings":"wJAEA,SAASA,EAAQC,EAAGC,GAAK,IAAIC,EAAIC,OAAOC,KAAKJ,GAAI,GAAIG,OAAOE,sBAAuB,CAAE,IAAIC,EAAIH,OAAOE,sBAAsBL,GAAIC,IAAMK,EAAIA,EAAEC,QAAO,SAAUN,GAAK,OAAOE,OAAOK,yBAAyBR,EAAGC,GAAGQ,UAAW,KAAMP,EAAEQ,KAAKC,MAAMT,EAAGI,EAAG,CAAG,OAAOJ,CAAI,CAC/P,SAASU,EAAcZ,GAAK,IAAK,IAAIC,EAAI,EAAGA,EAAIY,UAAUC,OAAQb,IAAK,CAAE,IAAIC,EAAI,MAAQW,UAAUZ,GAAKY,UAAUZ,GAAK,CAAE,EAAEA,EAAI,EAAIF,EAAQI,OAAOD,IAAI,GAAIa,SAAQ,SAAUd,GAAKe,EAAgBhB,EAAG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EAAWhB,aAoBhD,IAAIO,EAAWe,EAAgBV,EAAKL,UACpC,OAAoBuB,EAAMnB,cAAcO,EAASa,EAAS,CACxDnC,IAAKA,GACJyB,GAAQd,EACZ,CACH"}
@@ -0,0 +1,2 @@
1
+ import e from"../../../@babel/runtime/helpers/esm/objectWithoutProperties.js";import t from"../../../@babel/runtime/helpers/esm/toConsumableArray.js";import n from"../../../@babel/runtime/helpers/esm/defineProperty.js";import r from"react";import a from"./create-element.js";import i from"./checkForListedLanguage.js";var l=["language","children","style","customStyle","codeTagProps","useInlineStyles","showLineNumbers","showInlineLineNumbers","startingLineNumber","lineNumberContainerStyle","lineNumberStyle","wrapLines","wrapLongLines","lineProps","renderer","PreTag","CodeTag","code","astGenerator"];function s(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function o(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?s(Object(r),!0).forEach((function(t){n(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):s(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}var c=/\n/g;function u(e){var t=e.codeString,n=e.codeStyle,a=e.containerStyle,i=void 0===a?{float:"left",paddingRight:"10px"}:a,l=e.numberStyle,s=void 0===l?{}:l,o=e.startingLineNumber;return r.createElement("code",{style:Object.assign({},n,i)},function(e){var t=e.lines,n=e.startingLineNumber,a=e.style;return t.map((function(e,t){var i=t+n;return r.createElement("span",{key:"line-".concat(t),className:"react-syntax-highlighter-line-number",style:"function"==typeof a?a(i):a},"".concat(i,"\n"))}))}({lines:t.replace(/\n$/,"").split("\n"),style:s,startingLineNumber:o}))}function p(e,t){return{type:"element",tagName:"span",properties:{key:"line-number--".concat(e),className:["comment","linenumber","react-syntax-highlighter-line-number"],style:t},children:[{type:"text",value:e}]}}function m(e,t,n){var r,a={display:"inline-block",minWidth:(r=n,"".concat(r.toString().length,".25em")),paddingRight:"1em",textAlign:"right",userSelect:"none"},i="function"==typeof e?e(t):e;return o(o({},a),i)}function g(e){var n=e.children,r=e.lineNumber,a=e.lineNumberStyle,i=e.largestLineNumber,l=e.showInlineLineNumbers,s=e.lineProps,c=void 0===s?{}:s,u=e.className,g=void 0===u?[]:u,h=e.showLineNumbers,v=e.wrapLongLines,d=e.wrapLines,f=void 0!==d&&d?o({},"function"==typeof c?c(r):c):{};if(f.className=f.className?[].concat(t(f.className.trim().split(/\s+/)),t(g)):g,r&&l){var y=m(a,r,i);n.unshift(p(r,y))}return v&h&&(f.style=o({display:"flex"},f.style)),{type:"element",tagName:"span",properties:f,children:n}}function h(e){for(var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],a=0;a<e.length;a++){var i=e[a];if("text"===i.type)r.push(g({children:[i],className:t(new Set(n))}));else if(i.children){var l=n.concat(i.properties.className);h(i.children,l).forEach((function(e){return r.push(e)}))}}return r}function v(e,t,n,r,a,i,l,s,o){var u,v=h(e.value),d=[],f=-1,y=0;function b(e,i){var c=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[];return t||c.length>0?function(e,i){return g({children:e,lineNumber:i,lineNumberStyle:s,largestLineNumber:l,showInlineLineNumbers:a,lineProps:n,className:arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],showLineNumbers:r,wrapLongLines:o,wrapLines:t})}(e,i,c):function(e,t){if(r&&t&&a){var n=m(s,t,l);e.unshift(p(t,n))}return e}(e,i)}for(var N=function(){var e=v[y],t=e.children[0].value;if(t.match(c)){var n=t.split("\n");n.forEach((function(t,a){var l=r&&d.length+i,s={type:"text",value:"".concat(t,"\n")};if(0===a){var o=b(v.slice(f+1,y).concat(g({children:[s],className:e.properties.className})),l);d.push(o)}else if(a===n.length-1){var c=v[y+1]&&v[y+1].children&&v[y+1].children[0],u={type:"text",value:"".concat(t)};if(c){var p=g({children:[u],className:e.properties.className});v.splice(y+1,0,p)}else{var m=b([u],l,e.properties.className);d.push(m)}}else{var h=b([s],l,e.properties.className);d.push(h)}})),f=y}y++};y<v.length;)N();if(f!==v.length-1){var L=v.slice(f+1,v.length);if(L&&L.length){var w=b(L,r&&d.length+i);d.push(w)}}return t?d:(u=[]).concat.apply(u,d)}function d(e){var t=e.rows,n=e.stylesheet,r=e.useInlineStyles;return t.map((function(e,t){return a({node:e,stylesheet:n,useInlineStyles:r,key:"code-segement".concat(t)})}))}function f(e){return e&&void 0!==e.highlightAuto}function y(t,n){return function(a){var s=a.language,c=a.children,p=a.style,m=void 0===p?n:p,g=a.customStyle,h=void 0===g?{}:g,y=a.codeTagProps,b=void 0===y?{className:s?"language-".concat(s):void 0,style:o(o({},m['code[class*="language-"]']),m['code[class*="language-'.concat(s,'"]')])}:y,N=a.useInlineStyles,L=void 0===N||N,w=a.showLineNumbers,S=void 0!==w&&w,j=a.showInlineLineNumbers,O=void 0===j||j,P=a.startingLineNumber,x=void 0===P?1:P,E=a.lineNumberContainerStyle,I=a.lineNumberStyle,C=void 0===I?{}:I,k=a.wrapLines,A=a.wrapLongLines,T=void 0!==A&&A,D=a.lineProps,G=void 0===D?{}:D,R=a.renderer,V=a.PreTag,W=void 0===V?"pre":V,F=a.CodeTag,$=void 0===F?"code":F,q=a.code,z=void 0===q?(Array.isArray(c)?c[0]:c)||"":q,B=a.astGenerator,H=e(a,l);B=B||t;var J=S?r.createElement(u,{containerStyle:E,codeStyle:b.style||{},numberStyle:C,startingLineNumber:x,codeString:z}):null,K=m.hljs||m['pre[class*="language-"]']||{backgroundColor:"#fff"},M=f(B)?"hljs":"prismjs",Q=L?Object.assign({},H,{style:Object.assign({},K,h)}):Object.assign({},H,{className:H.className?"".concat(M," ").concat(H.className):M,style:Object.assign({},h)});if(b.style=o(T?{whiteSpace:"pre-wrap"}:{whiteSpace:"pre"},b.style),!B)return r.createElement(W,Q,J,r.createElement($,b,z));(void 0===k&&R||T)&&(k=!0),R=R||d;var U=[{type:"text",value:z}],X=function(e){var t=e.astGenerator,n=e.language,r=e.code,a=e.defaultCodeValue;if(f(t)){var l=i(t,n);return"text"===n?{value:a,language:"text"}:l?t.highlight(n,r):t.highlightAuto(r)}try{return n&&"text"!==n?{value:t.highlight(r,n)}:{value:a}}catch(e){return{value:a}}}({astGenerator:B,language:s,code:z,defaultCodeValue:U});null===X.language&&(X.value=U);var Y=X.value.length;1===Y&&"text"===X.value[0].type&&(Y=X.value[0].value.split("\n").length);var Z=v(X,k,G,S,O,x,Y+x,C,T);return r.createElement(W,Q,r.createElement($,b,!O&&J,R({rows:Z,stylesheet:m,useInlineStyles:L})))}}export{y as default};
2
+ //# sourceMappingURL=highlight.js.map