@blogmcp/sdk 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (340) hide show
  1. package/dist/_virtual/_plugin-vue_export-helper.js +9 -0
  2. package/dist/_virtual/constants.js +4 -0
  3. package/dist/_virtual/index.js +2 -0
  4. package/dist/_virtual/index2.js +4 -0
  5. package/dist/_virtual/index3.js +2 -0
  6. package/dist/_virtual/re.js +4 -0
  7. package/dist/core/article-seo.d.ts +27 -0
  8. package/dist/core/article-seo.js +25 -0
  9. package/dist/core/auth.d.ts +34 -0
  10. package/dist/core/auth.js +89 -0
  11. package/dist/core/blog-config.d.ts +5 -0
  12. package/dist/core/blog-config.js +14 -0
  13. package/dist/core/client-types.d.ts +51 -0
  14. package/dist/core/client.d.ts +159 -0
  15. package/dist/core/client.js +82 -0
  16. package/dist/core/i18n.d.ts +29 -0
  17. package/dist/core/i18n.js +34 -0
  18. package/dist/core/index.d.ts +26 -0
  19. package/dist/core/index.js +67 -0
  20. package/dist/core/markdown.d.ts +69 -0
  21. package/dist/core/markdown.js +47 -0
  22. package/dist/core/navigation.d.ts +70 -0
  23. package/dist/core/navigation.js +71 -0
  24. package/dist/core/queries.d.ts +34 -0
  25. package/dist/core/queries.js +363 -0
  26. package/dist/core/retry.d.ts +9 -0
  27. package/dist/core/retry.js +14 -0
  28. package/dist/core/seo.d.ts +142 -0
  29. package/dist/core/seo.js +166 -0
  30. package/dist/core/theme.d.ts +41 -0
  31. package/dist/core/theme.js +60 -0
  32. package/dist/core/translations/cs.json.js +27 -0
  33. package/dist/core/translations/en.json.js +27 -0
  34. package/dist/core/types.d.ts +184 -0
  35. package/dist/core/types.js +9 -0
  36. package/dist/core/view-model.d.ts +53 -0
  37. package/dist/core/view-model.js +47 -0
  38. package/dist/node_modules/@braintree/sanitize-url/dist/constants.js +8 -0
  39. package/dist/node_modules/@braintree/sanitize-url/dist/index.js +60 -0
  40. package/dist/node_modules/dompurify/dist/purify.es.js +662 -0
  41. package/dist/node_modules/semver/classes/comparator.js +56 -0
  42. package/dist/node_modules/semver/classes/range.js +148 -0
  43. package/dist/node_modules/semver/classes/semver.js +169 -0
  44. package/dist/node_modules/semver/functions/clean.js +14 -0
  45. package/dist/node_modules/semver/functions/cmp.js +39 -0
  46. package/dist/node_modules/semver/functions/coerce.js +33 -0
  47. package/dist/node_modules/semver/functions/compare-build.js +14 -0
  48. package/dist/node_modules/semver/functions/compare-loose.js +11 -0
  49. package/dist/node_modules/semver/functions/compare.js +11 -0
  50. package/dist/node_modules/semver/functions/diff.js +24 -0
  51. package/dist/node_modules/semver/functions/eq.js +11 -0
  52. package/dist/node_modules/semver/functions/gt.js +11 -0
  53. package/dist/node_modules/semver/functions/gte.js +11 -0
  54. package/dist/node_modules/semver/functions/inc.js +21 -0
  55. package/dist/node_modules/semver/functions/lt.js +11 -0
  56. package/dist/node_modules/semver/functions/lte.js +11 -0
  57. package/dist/node_modules/semver/functions/major.js +11 -0
  58. package/dist/node_modules/semver/functions/minor.js +11 -0
  59. package/dist/node_modules/semver/functions/neq.js +11 -0
  60. package/dist/node_modules/semver/functions/parse.js +21 -0
  61. package/dist/node_modules/semver/functions/patch.js +11 -0
  62. package/dist/node_modules/semver/functions/prerelease.js +14 -0
  63. package/dist/node_modules/semver/functions/rcompare.js +11 -0
  64. package/dist/node_modules/semver/functions/rsort.js +11 -0
  65. package/dist/node_modules/semver/functions/satisfies.js +18 -0
  66. package/dist/node_modules/semver/functions/sort.js +11 -0
  67. package/dist/node_modules/semver/functions/valid.js +14 -0
  68. package/dist/node_modules/semver/index.js +97 -0
  69. package/dist/node_modules/semver/internal/constants.js +28 -0
  70. package/dist/node_modules/semver/internal/debug.js +8 -0
  71. package/dist/node_modules/semver/internal/identifiers.js +18 -0
  72. package/dist/node_modules/semver/internal/lrucache.js +32 -0
  73. package/dist/node_modules/semver/internal/parse-options.js +10 -0
  74. package/dist/node_modules/semver/internal/re.js +32 -0
  75. package/dist/node_modules/semver/ranges/gtr.js +11 -0
  76. package/dist/node_modules/semver/ranges/intersects.js +11 -0
  77. package/dist/node_modules/semver/ranges/ltr.js +11 -0
  78. package/dist/node_modules/semver/ranges/max-satisfying.js +22 -0
  79. package/dist/node_modules/semver/ranges/min-satisfying.js +22 -0
  80. package/dist/node_modules/semver/ranges/min-version.js +42 -0
  81. package/dist/node_modules/semver/ranges/outside.js +44 -0
  82. package/dist/node_modules/semver/ranges/simplify.js +24 -0
  83. package/dist/node_modules/semver/ranges/subset.js +94 -0
  84. package/dist/node_modules/semver/ranges/to-comparators.js +11 -0
  85. package/dist/node_modules/semver/ranges/valid.js +17 -0
  86. package/dist/nuxt/composables/useAsyncKb.d.ts +32 -0
  87. package/dist/nuxt/composables/useAsyncKb.js +34 -0
  88. package/dist/nuxt/index.d.ts +1 -0
  89. package/dist/nuxt/index.js +6 -0
  90. package/dist/packages/mdx-render-vue/dist/_virtual/_plugin-vue_export-helper.js +9 -0
  91. package/dist/packages/mdx-render-vue/dist/_virtual/constants.js +4 -0
  92. package/dist/packages/mdx-render-vue/dist/_virtual/index.js +5 -0
  93. package/dist/packages/mdx-render-vue/dist/_virtual/index2.js +4 -0
  94. package/dist/packages/mdx-render-vue/dist/composables/useAudioPlayer.js +40 -0
  95. package/dist/packages/mdx-render-vue/dist/composables/useCallout.js +66 -0
  96. package/dist/packages/mdx-render-vue/dist/composables/useCodeBlock.js +62 -0
  97. package/dist/packages/mdx-render-vue/dist/composables/useGallery.js +68 -0
  98. package/dist/packages/mdx-render-vue/dist/composables/useMedia.js +9 -0
  99. package/dist/packages/mdx-render-vue/dist/composables/useYouTube.js +24 -0
  100. package/dist/packages/mdx-render-vue/dist/edit/AlertEdit.vue.js +4 -0
  101. package/dist/packages/mdx-render-vue/dist/edit/AlertEdit.vue2.js +16 -0
  102. package/dist/packages/mdx-render-vue/dist/edit/AudioPlayerEdit.vue.js +102 -0
  103. package/dist/packages/mdx-render-vue/dist/edit/AudioPlayerEdit.vue2.js +4 -0
  104. package/dist/packages/mdx-render-vue/dist/edit/BadgeEdit.vue.js +4 -0
  105. package/dist/packages/mdx-render-vue/dist/edit/BadgeEdit.vue2.js +11 -0
  106. package/dist/packages/mdx-render-vue/dist/edit/ButtonEdit.vue.js +4 -0
  107. package/dist/packages/mdx-render-vue/dist/edit/ButtonEdit.vue2.js +11 -0
  108. package/dist/packages/mdx-render-vue/dist/edit/CalloutEdit.vue.js +78 -0
  109. package/dist/packages/mdx-render-vue/dist/edit/CalloutEdit.vue2.js +4 -0
  110. package/dist/packages/mdx-render-vue/dist/edit/CardEdit.vue.js +4 -0
  111. package/dist/packages/mdx-render-vue/dist/edit/CardEdit.vue2.js +16 -0
  112. package/dist/packages/mdx-render-vue/dist/edit/CodeBlockEdit.vue.js +6 -0
  113. package/dist/packages/mdx-render-vue/dist/edit/CodeBlockEdit.vue2.js +74 -0
  114. package/dist/packages/mdx-render-vue/dist/edit/GalleryEdit.vue.js +56 -0
  115. package/dist/packages/mdx-render-vue/dist/edit/GalleryEdit.vue2.js +4 -0
  116. package/dist/packages/mdx-render-vue/dist/edit/IconEdit.vue.js +4 -0
  117. package/dist/packages/mdx-render-vue/dist/edit/IconEdit.vue2.js +11 -0
  118. package/dist/packages/mdx-render-vue/dist/edit/TooltipEdit.vue.js +4 -0
  119. package/dist/packages/mdx-render-vue/dist/edit/TooltipEdit.vue2.js +20 -0
  120. package/dist/packages/mdx-render-vue/dist/edit/YouTubeEdit.vue.js +34 -0
  121. package/dist/packages/mdx-render-vue/dist/edit/YouTubeEdit.vue2.js +4 -0
  122. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/_virtual/_rolldown/runtime.js +11 -0
  123. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/factory.js +29 -0
  124. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/presence/use-presence-context.js +6 -0
  125. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/presence/use-presence.js +32 -0
  126. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/tooltip-arrow-tip.js +5 -0
  127. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/tooltip-arrow-tip.vue_vue_type_script_setup_true_lang.js +18 -0
  128. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/tooltip-arrow.js +5 -0
  129. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/tooltip-arrow.vue_vue_type_script_setup_true_lang.js +18 -0
  130. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/tooltip-content.js +5 -0
  131. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/tooltip-content.vue_vue_type_script_setup_true_lang.js +20 -0
  132. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/tooltip-context.js +5 -0
  133. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/tooltip-context.vue_vue_type_script_setup_true_lang.js +12 -0
  134. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/tooltip-positioner.js +5 -0
  135. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/tooltip-positioner.vue_vue_type_script_setup_true_lang.js +19 -0
  136. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/tooltip-root-provider.js +5 -0
  137. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/tooltip-root-provider.vue_vue_type_script_setup_true_lang.js +29 -0
  138. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/tooltip-root.js +5 -0
  139. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/tooltip-root.vue_vue_type_script_setup_true_lang.js +59 -0
  140. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/tooltip-trigger.js +5 -0
  141. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/tooltip-trigger.vue_vue_type_script_setup_true_lang.js +21 -0
  142. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/tooltip.js +22 -0
  143. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/use-tooltip-context.js +6 -0
  144. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/components/tooltip/use-tooltip.js +29 -0
  145. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/providers/environment/use-environment-context.js +12 -0
  146. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/providers/locale/use-locale-context.js +11 -0
  147. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/utils/clean-props.js +8 -0
  148. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/utils/create-context.js +12 -0
  149. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/utils/dynamic.js +25 -0
  150. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/utils/unref-element.js +8 -0
  151. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/utils/use-forward-expose.js +36 -0
  152. package/dist/packages/mdx-render-vue/dist/node_modules/@ark-ui/vue/dist/utils/use-render-strategy.js +5 -0
  153. package/dist/packages/mdx-render-vue/dist/node_modules/@braintree/sanitize-url/dist/constants.js +8 -0
  154. package/dist/packages/mdx-render-vue/dist/node_modules/@braintree/sanitize-url/dist/index.js +60 -0
  155. package/dist/packages/mdx-render-vue/dist/node_modules/@floating-ui/core/dist/floating-ui.core.js +532 -0
  156. package/dist/packages/mdx-render-vue/dist/node_modules/@floating-ui/dom/dist/floating-ui.dom.js +403 -0
  157. package/dist/packages/mdx-render-vue/dist/node_modules/@floating-ui/utils/dist/floating-ui.utils.dom.js +136 -0
  158. package/dist/packages/mdx-render-vue/dist/node_modules/@floating-ui/utils/dist/floating-ui.utils.js +128 -0
  159. package/dist/packages/mdx-render-vue/dist/node_modules/@iconify/vue/dist/iconify.js +1192 -0
  160. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/anatomy/dist/create-anatomy.js +26 -0
  161. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/core/dist/create-machine.js +21 -0
  162. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/core/dist/merge-props.js +45 -0
  163. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/core/dist/scope.js +16 -0
  164. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/core/dist/state.js +136 -0
  165. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/core/dist/types.js +5 -0
  166. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/dom-query/dist/chunk-QZ7TP4HQ.js +4 -0
  167. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/dom-query/dist/computed-style.js +8 -0
  168. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/dom-query/dist/event.js +31 -0
  169. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/dom-query/dist/node.js +49 -0
  170. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/dom-query/dist/overflow.js +19 -0
  171. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/dom-query/dist/platform.js +16 -0
  172. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/dom-query/dist/query.js +6 -0
  173. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/dom-query/dist/raf.js +41 -0
  174. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/dom-query/dist/set.js +14 -0
  175. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/dom-query/dist/shared.js +7 -0
  176. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/focus-visible/dist/index.js +90 -0
  177. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/popper/dist/get-anchor.js +34 -0
  178. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/popper/dist/get-placement.js +187 -0
  179. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/popper/dist/get-styles.js +47 -0
  180. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/popper/dist/middleware.js +56 -0
  181. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/popper/dist/placement.js +7 -0
  182. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/presence/dist/presence.connect.js +16 -0
  183. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/presence/dist/presence.machine.js +147 -0
  184. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/tooltip/dist/tooltip.anatomy.js +6 -0
  185. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/tooltip/dist/tooltip.connect.js +119 -0
  186. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/tooltip/dist/tooltip.dom.js +15 -0
  187. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/tooltip/dist/tooltip.machine.js +375 -0
  188. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/tooltip/dist/tooltip.store.js +9 -0
  189. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/types/dist/prop-types.js +10 -0
  190. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/utils/dist/array.js +6 -0
  191. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/utils/dist/equal.js +27 -0
  192. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/utils/dist/functions.js +10 -0
  193. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/utils/dist/guard.js +15 -0
  194. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/utils/dist/object.js +13 -0
  195. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/utils/dist/store.js +25 -0
  196. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/utils/dist/warning.js +25 -0
  197. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/vue/dist/bindable.js +37 -0
  198. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/vue/dist/machine.js +205 -0
  199. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/vue/dist/normalize-props.js +30 -0
  200. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/vue/dist/refs.js +14 -0
  201. package/dist/packages/mdx-render-vue/dist/node_modules/@zag-js/vue/dist/track.js +19 -0
  202. package/dist/packages/mdx-render-vue/dist/node_modules/dompurify/dist/purify.es.js +659 -0
  203. package/dist/packages/mdx-render-vue/dist/registry.js +154 -0
  204. package/dist/packages/mdx-render-vue/dist/render/alert/Alert.vue.js +4 -0
  205. package/dist/packages/mdx-render-vue/dist/render/alert/Alert.vue2.js +37 -0
  206. package/dist/packages/mdx-render-vue/dist/render/audioplayer/AudioPlayerDefault.vue.js +102 -0
  207. package/dist/packages/mdx-render-vue/dist/render/audioplayer/AudioPlayerDefault.vue2.js +4 -0
  208. package/dist/packages/mdx-render-vue/dist/render/badge/Badge.vue.js +4 -0
  209. package/dist/packages/mdx-render-vue/dist/render/badge/Badge.vue2.js +25 -0
  210. package/dist/packages/mdx-render-vue/dist/render/button/Button.vue.js +4 -0
  211. package/dist/packages/mdx-render-vue/dist/render/button/Button.vue2.js +37 -0
  212. package/dist/packages/mdx-render-vue/dist/render/callout/CalloutDefault.vue.js +79 -0
  213. package/dist/packages/mdx-render-vue/dist/render/callout/CalloutDefault.vue2.js +4 -0
  214. package/dist/packages/mdx-render-vue/dist/render/callout/CalloutMinimal.vue.js +22 -0
  215. package/dist/packages/mdx-render-vue/dist/render/callout/CalloutMinimal.vue2.js +4 -0
  216. package/dist/packages/mdx-render-vue/dist/render/card/Card.vue.js +4 -0
  217. package/dist/packages/mdx-render-vue/dist/render/card/Card.vue2.js +24 -0
  218. package/dist/packages/mdx-render-vue/dist/render/codeblock/CodeBlockDefault.vue.js +6 -0
  219. package/dist/packages/mdx-render-vue/dist/render/codeblock/CodeBlockDefault.vue2.js +77 -0
  220. package/dist/packages/mdx-render-vue/dist/render/gallery/GalleryGrid.vue.js +103 -0
  221. package/dist/packages/mdx-render-vue/dist/render/gallery/GalleryGrid.vue2.js +4 -0
  222. package/dist/packages/mdx-render-vue/dist/render/gallery/GalleryLightbox.vue.js +6 -0
  223. package/dist/packages/mdx-render-vue/dist/render/gallery/GalleryLightbox.vue2.js +142 -0
  224. package/dist/packages/mdx-render-vue/dist/render/icon/Icon.vue.js +4 -0
  225. package/dist/packages/mdx-render-vue/dist/render/icon/Icon.vue2.js +23 -0
  226. package/dist/packages/mdx-render-vue/dist/render/tooltip/Tooltip.vue.js +4 -0
  227. package/dist/packages/mdx-render-vue/dist/render/tooltip/Tooltip.vue2.js +54 -0
  228. package/dist/packages/mdx-render-vue/dist/render/youtube/YouTubeDefault.vue.js +69 -0
  229. package/dist/packages/mdx-render-vue/dist/render/youtube/YouTubeDefault.vue2.js +4 -0
  230. package/dist/packages/mdx-schema/dist/composables/useMdxParsing.js +139 -0
  231. package/dist/packages/mdx-schema/dist/metadata/index.js +415 -0
  232. package/dist/packages/mdx-schema/dist/prepareProps.js +46 -0
  233. package/dist/packages/mdx-schema/dist/styles/index.js +119 -0
  234. package/dist/packages/mdx-schema/dist/types/index.js +26 -0
  235. package/dist/packages/sanitize/dist/html.js +41 -0
  236. package/dist/react/KbMdxContent.d.ts +35 -0
  237. package/dist/react/KbMdxContent.js +102 -0
  238. package/dist/react/context.d.ts +11 -0
  239. package/dist/react/context.js +5 -0
  240. package/dist/react/hooks/useImageRenderer.d.ts +6 -0
  241. package/dist/react/hooks/useImageRenderer.js +9 -0
  242. package/dist/react/hooks/useKbClient.d.ts +3 -0
  243. package/dist/react/hooks/useKbClient.js +7 -0
  244. package/dist/react/hooks/useKbContext.d.ts +3 -0
  245. package/dist/react/hooks/useKbContext.js +11 -0
  246. package/dist/react/hooks/useKbI18n.d.ts +7 -0
  247. package/dist/react/hooks/useKbI18n.js +8 -0
  248. package/dist/react/hooks/useKbLanguage.d.ts +21 -0
  249. package/dist/react/hooks/useKbLanguage.js +63 -0
  250. package/dist/react/hooks/useKbSearch.d.ts +20 -0
  251. package/dist/react/hooks/useKbSearch.js +22 -0
  252. package/dist/react/hooks/useMdxContent.d.ts +18 -0
  253. package/dist/react/hooks/useMdxContent.js +11 -0
  254. package/dist/react/index.d.ts +21 -0
  255. package/dist/react/index.js +20 -0
  256. package/dist/react/provider.d.ts +25 -0
  257. package/dist/react/provider.js +29 -0
  258. package/dist/react/server/index.d.ts +38 -0
  259. package/dist/react/server/index.js +26 -0
  260. package/dist/sdk.css +1 -0
  261. package/dist/vue/components/KbAccessGate.vue.d.ts +36 -0
  262. package/dist/vue/components/KbAccessGate.vue.js +74 -0
  263. package/dist/vue/components/KbAccessGate.vue2.js +4 -0
  264. package/dist/vue/components/KbArticleCard.vue.d.ts +34 -0
  265. package/dist/vue/components/KbArticleCard.vue.js +87 -0
  266. package/dist/vue/components/KbArticleCard.vue2.js +4 -0
  267. package/dist/vue/components/KbMdxContent.vue.d.ts +5 -0
  268. package/dist/vue/components/KbMdxContent.vue.js +7 -0
  269. package/dist/vue/components/KbMdxContent.vue2.js +82 -0
  270. package/dist/vue/composables/useArticles.d.ts +30 -0
  271. package/dist/vue/composables/useArticles.js +36 -0
  272. package/dist/vue/composables/useImageRenderer.d.ts +6 -0
  273. package/dist/vue/composables/useImageRenderer.js +9 -0
  274. package/dist/vue/composables/useKbAuth.d.ts +27 -0
  275. package/dist/vue/composables/useKbAuth.js +83 -0
  276. package/dist/vue/composables/useKbClient.d.ts +6 -0
  277. package/dist/vue/composables/useKbClient.js +13 -0
  278. package/dist/vue/composables/useKbComments.d.ts +37 -0
  279. package/dist/vue/composables/useKbComments.js +160 -0
  280. package/dist/vue/composables/useKbI18n.d.ts +6 -0
  281. package/dist/vue/composables/useKbI18n.js +8 -0
  282. package/dist/vue/composables/useKbLanguage.d.ts +22 -0
  283. package/dist/vue/composables/useKbLanguage.js +63 -0
  284. package/dist/vue/composables/useNavigation.d.ts +18 -0
  285. package/dist/vue/composables/useNavigation.js +20 -0
  286. package/dist/vue/composables/useSearch.d.ts +21 -0
  287. package/dist/vue/composables/useSearch.js +20 -0
  288. package/dist/vue/composables/useTags.d.ts +17 -0
  289. package/dist/vue/composables/useTags.js +36 -0
  290. package/dist/vue/index.d.ts +22 -0
  291. package/dist/vue/index.js +36 -0
  292. package/dist/vue/plugin.d.ts +30 -0
  293. package/dist/vue/plugin.js +17 -0
  294. package/package.json +97 -0
  295. package/src/core/article-seo.ts +101 -0
  296. package/src/core/auth.ts +138 -0
  297. package/src/core/blog-config.ts +30 -0
  298. package/src/core/client-types.ts +58 -0
  299. package/src/core/client.ts +287 -0
  300. package/src/core/i18n.ts +84 -0
  301. package/src/core/index.ts +147 -0
  302. package/src/core/markdown.ts +178 -0
  303. package/src/core/navigation.ts +152 -0
  304. package/src/core/queries.ts +414 -0
  305. package/src/core/retry.ts +19 -0
  306. package/src/core/seo.ts +374 -0
  307. package/src/core/theme.ts +128 -0
  308. package/src/core/translations/cs.json +225 -0
  309. package/src/core/translations/en.json +225 -0
  310. package/src/core/types.ts +231 -0
  311. package/src/core/view-model.ts +98 -0
  312. package/src/nuxt/composables/useAsyncKb.ts +119 -0
  313. package/src/nuxt/index.ts +6 -0
  314. package/src/react/KbMdxContent.tsx +215 -0
  315. package/src/react/context.ts +25 -0
  316. package/src/react/hooks/useImageRenderer.ts +15 -0
  317. package/src/react/hooks/useKbClient.ts +9 -0
  318. package/src/react/hooks/useKbContext.ts +13 -0
  319. package/src/react/hooks/useKbI18n.ts +15 -0
  320. package/src/react/hooks/useKbLanguage.ts +105 -0
  321. package/src/react/hooks/useKbSearch.ts +50 -0
  322. package/src/react/hooks/useMdxContent.tsx +33 -0
  323. package/src/react/index.ts +31 -0
  324. package/src/react/provider.tsx +70 -0
  325. package/src/react/server/index.ts +70 -0
  326. package/src/vue/components/KbAccessGate.vue +86 -0
  327. package/src/vue/components/KbArticleCard.vue +102 -0
  328. package/src/vue/components/KbMdxContent.vue +211 -0
  329. package/src/vue/composables/useArticles.ts +78 -0
  330. package/src/vue/composables/useImageRenderer.ts +12 -0
  331. package/src/vue/composables/useKbAuth.ts +131 -0
  332. package/src/vue/composables/useKbClient.ts +17 -0
  333. package/src/vue/composables/useKbComments.ts +281 -0
  334. package/src/vue/composables/useKbI18n.ts +11 -0
  335. package/src/vue/composables/useKbLanguage.ts +103 -0
  336. package/src/vue/composables/useNavigation.ts +38 -0
  337. package/src/vue/composables/useSearch.ts +52 -0
  338. package/src/vue/composables/useTags.ts +64 -0
  339. package/src/vue/index.ts +27 -0
  340. package/src/vue/plugin.ts +73 -0
@@ -0,0 +1,659 @@
1
+ function yt(n, o) {
2
+ (o == null || o > n.length) && (o = n.length);
3
+ for (var a = 0, s = Array(o); a < o; a++) s[a] = n[a];
4
+ return s;
5
+ }
6
+ function nn(n) {
7
+ if (Array.isArray(n)) return n;
8
+ }
9
+ function on(n, o) {
10
+ var a = n == null ? null : typeof Symbol < "u" && n[Symbol.iterator] || n["@@iterator"];
11
+ if (a != null) {
12
+ var s, f, p, b, te = [], I = !0, ne = !1;
13
+ try {
14
+ if (p = (a = a.call(n)).next, o !== 0) for (; !(I = (s = p.call(a)).done) && (te.push(s.value), te.length !== o); I = !0) ;
15
+ } catch (Le) {
16
+ ne = !0, f = Le;
17
+ } finally {
18
+ try {
19
+ if (!I && a.return != null && (b = a.return(), Object(b) !== b)) return;
20
+ } finally {
21
+ if (ne) throw f;
22
+ }
23
+ }
24
+ return te;
25
+ }
26
+ }
27
+ function rn() {
28
+ throw new TypeError(`Invalid attempt to destructure non-iterable instance.
29
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
30
+ }
31
+ function an(n, o) {
32
+ return nn(n) || on(n, o) || sn(n, o) || rn();
33
+ }
34
+ function sn(n, o) {
35
+ if (n) {
36
+ if (typeof n == "string") return yt(n, o);
37
+ var a = {}.toString.call(n).slice(8, -1);
38
+ return a === "Object" && n.constructor && (a = n.constructor.name), a === "Map" || a === "Set" ? Array.from(n) : a === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a) ? yt(n, o) : void 0;
39
+ }
40
+ }
41
+ const kt = Object.entries, bt = Object.setPrototypeOf, ln = Object.isFrozen, cn = Object.getPrototypeOf, fn = Object.getOwnPropertyDescriptor;
42
+ let D = Object.freeze, C = Object.seal, ee = Object.create, vt = typeof Reflect < "u" && Reflect, Ke = vt.apply, Ze = vt.construct;
43
+ D || (D = function(o) {
44
+ return o;
45
+ });
46
+ C || (C = function(o) {
47
+ return o;
48
+ });
49
+ Ke || (Ke = function(o, a) {
50
+ for (var s = arguments.length, f = new Array(s > 2 ? s - 2 : 0), p = 2; p < s; p++)
51
+ f[p - 2] = arguments[p];
52
+ return o.apply(a, f);
53
+ });
54
+ Ze || (Ze = function(o) {
55
+ for (var a = arguments.length, s = new Array(a > 1 ? a - 1 : 0), f = 1; f < a; f++)
56
+ s[f - 1] = arguments[f];
57
+ return new o(...s);
58
+ });
59
+ const Z = A(Array.prototype.forEach), un = A(Array.prototype.lastIndexOf), Rt = A(Array.prototype.pop), J = A(Array.prototype.push), mn = A(Array.prototype.splice), N = Array.isArray, ue = A(String.prototype.toLowerCase), Ye = A(String.prototype.toString), Ot = A(String.prototype.match), Q = A(String.prototype.replace), Nt = A(String.prototype.indexOf), pn = A(String.prototype.trim), Tn = A(Number.prototype.toString), dn = A(Boolean.prototype.toString), Dt = typeof BigInt > "u" ? null : A(BigInt.prototype.toString), It = typeof Symbol > "u" ? null : A(Symbol.prototype.toString), T = A(Object.prototype.hasOwnProperty), ce = A(Object.prototype.toString), y = A(RegExp.prototype.test), fe = gn(TypeError);
60
+ function A(n) {
61
+ return function(o) {
62
+ o instanceof RegExp && (o.lastIndex = 0);
63
+ for (var a = arguments.length, s = new Array(a > 1 ? a - 1 : 0), f = 1; f < a; f++)
64
+ s[f - 1] = arguments[f];
65
+ return Ke(n, o, s);
66
+ };
67
+ }
68
+ function gn(n) {
69
+ return function() {
70
+ for (var o = arguments.length, a = new Array(o), s = 0; s < o; s++)
71
+ a[s] = arguments[s];
72
+ return Ze(n, a);
73
+ };
74
+ }
75
+ function l(n, o) {
76
+ let a = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : ue;
77
+ if (bt && bt(n, null), !N(o))
78
+ return n;
79
+ let s = o.length;
80
+ for (; s--; ) {
81
+ let f = o[s];
82
+ if (typeof f == "string") {
83
+ const p = a(f);
84
+ p !== f && (ln(o) || (o[s] = p), f = p);
85
+ }
86
+ n[f] = !0;
87
+ }
88
+ return n;
89
+ }
90
+ function _n(n) {
91
+ for (let o = 0; o < n.length; o++)
92
+ T(n, o) || (n[o] = null);
93
+ return n;
94
+ }
95
+ function R(n) {
96
+ const o = ee(null);
97
+ for (const s of kt(n)) {
98
+ var a = an(s, 2);
99
+ const f = a[0], p = a[1];
100
+ T(n, f) && (N(p) ? o[f] = _n(p) : p && typeof p == "object" && p.constructor === Object ? o[f] = R(p) : o[f] = p);
101
+ }
102
+ return o;
103
+ }
104
+ function hn(n) {
105
+ switch (typeof n) {
106
+ case "string":
107
+ return n;
108
+ case "number":
109
+ return Tn(n);
110
+ case "boolean":
111
+ return dn(n);
112
+ case "bigint":
113
+ return Dt ? Dt(n) : "0";
114
+ case "symbol":
115
+ return It ? It(n) : "Symbol()";
116
+ case "undefined":
117
+ return ce(n);
118
+ case "function":
119
+ case "object": {
120
+ if (n === null)
121
+ return ce(n);
122
+ const o = n, a = U(o, "toString");
123
+ if (typeof a == "function") {
124
+ const s = a(o);
125
+ return typeof s == "string" ? s : ce(s);
126
+ }
127
+ return ce(n);
128
+ }
129
+ default:
130
+ return ce(n);
131
+ }
132
+ }
133
+ function U(n, o) {
134
+ for (; n !== null; ) {
135
+ const s = fn(n, o);
136
+ if (s) {
137
+ if (s.get)
138
+ return A(s.get);
139
+ if (typeof s.value == "function")
140
+ return A(s.value);
141
+ }
142
+ n = cn(n);
143
+ }
144
+ function a() {
145
+ return null;
146
+ }
147
+ return a;
148
+ }
149
+ function An(n) {
150
+ try {
151
+ return y(n, ""), !0;
152
+ } catch {
153
+ return !1;
154
+ }
155
+ }
156
+ const Lt = D(["a", "abbr", "acronym", "address", "area", "article", "aside", "audio", "b", "bdi", "bdo", "big", "blink", "blockquote", "body", "br", "button", "canvas", "caption", "center", "cite", "code", "col", "colgroup", "content", "data", "datalist", "dd", "decorator", "del", "details", "dfn", "dialog", "dir", "div", "dl", "dt", "element", "em", "fieldset", "figcaption", "figure", "font", "footer", "form", "h1", "h2", "h3", "h4", "h5", "h6", "head", "header", "hgroup", "hr", "html", "i", "img", "input", "ins", "kbd", "label", "legend", "li", "main", "map", "mark", "marquee", "menu", "menuitem", "meter", "nav", "nobr", "ol", "optgroup", "option", "output", "p", "picture", "pre", "progress", "q", "rp", "rt", "ruby", "s", "samp", "search", "section", "select", "shadow", "slot", "small", "source", "spacer", "span", "strike", "strong", "style", "sub", "summary", "sup", "table", "tbody", "td", "template", "textarea", "tfoot", "th", "thead", "time", "tr", "track", "tt", "u", "ul", "var", "video", "wbr"]), $e = D(["svg", "a", "altglyph", "altglyphdef", "altglyphitem", "animatecolor", "animatemotion", "animatetransform", "circle", "clippath", "defs", "desc", "ellipse", "enterkeyhint", "exportparts", "filter", "font", "g", "glyph", "glyphref", "hkern", "image", "inputmode", "line", "lineargradient", "marker", "mask", "metadata", "mpath", "part", "path", "pattern", "polygon", "polyline", "radialgradient", "rect", "stop", "style", "switch", "symbol", "text", "textpath", "title", "tref", "tspan", "view", "vkern"]), Xe = D(["feBlend", "feColorMatrix", "feComponentTransfer", "feComposite", "feConvolveMatrix", "feDiffuseLighting", "feDisplacementMap", "feDistantLight", "feDropShadow", "feFlood", "feFuncA", "feFuncB", "feFuncG", "feFuncR", "feGaussianBlur", "feImage", "feMerge", "feMergeNode", "feMorphology", "feOffset", "fePointLight", "feSpecularLighting", "feSpotLight", "feTile", "feTurbulence"]), En = D(["animate", "color-profile", "cursor", "discard", "font-face", "font-face-format", "font-face-name", "font-face-src", "font-face-uri", "foreignobject", "hatch", "hatchpath", "mesh", "meshgradient", "meshpatch", "meshrow", "missing-glyph", "script", "set", "solidcolor", "unknown", "use"]), Ve = D(["math", "menclose", "merror", "mfenced", "mfrac", "mglyph", "mi", "mlabeledtr", "mmultiscripts", "mn", "mo", "mover", "mpadded", "mphantom", "mroot", "mrow", "ms", "mspace", "msqrt", "mstyle", "msub", "msup", "msubsup", "mtable", "mtd", "mtext", "mtr", "munder", "munderover", "mprescripts"]), Sn = D(["maction", "maligngroup", "malignmark", "mlongdiv", "mscarries", "mscarry", "msgroup", "mstack", "msline", "msrow", "semantics", "annotation", "annotation-xml", "mprescripts", "none"]), Ct = D(["#text"]), wt = D(["accept", "action", "align", "alt", "autocapitalize", "autocomplete", "autopictureinpicture", "autoplay", "background", "bgcolor", "border", "capture", "cellpadding", "cellspacing", "checked", "cite", "class", "clear", "color", "cols", "colspan", "command", "commandfor", "controls", "controlslist", "coords", "crossorigin", "datetime", "decoding", "default", "dir", "disabled", "disablepictureinpicture", "disableremoteplayback", "download", "draggable", "enctype", "enterkeyhint", "exportparts", "face", "for", "headers", "height", "hidden", "high", "href", "hreflang", "id", "inert", "inputmode", "integrity", "ismap", "kind", "label", "lang", "list", "loading", "loop", "low", "max", "maxlength", "media", "method", "min", "minlength", "multiple", "muted", "name", "nonce", "noshade", "novalidate", "nowrap", "open", "optimum", "part", "pattern", "placeholder", "playsinline", "popover", "popovertarget", "popovertargetaction", "poster", "preload", "pubdate", "radiogroup", "readonly", "rel", "required", "rev", "reversed", "role", "rows", "rowspan", "spellcheck", "scope", "selected", "shape", "size", "sizes", "slot", "span", "srclang", "start", "src", "srcset", "step", "style", "summary", "tabindex", "title", "translate", "type", "usemap", "valign", "value", "width", "wrap", "xmlns"]), qe = D(["accent-height", "accumulate", "additive", "alignment-baseline", "amplitude", "ascent", "attributename", "attributetype", "azimuth", "basefrequency", "baseline-shift", "begin", "bias", "by", "class", "clip", "clippathunits", "clip-path", "clip-rule", "color", "color-interpolation", "color-interpolation-filters", "color-profile", "color-rendering", "cx", "cy", "d", "dx", "dy", "diffuseconstant", "direction", "display", "divisor", "dur", "edgemode", "elevation", "end", "exponent", "fill", "fill-opacity", "fill-rule", "filter", "filterunits", "flood-color", "flood-opacity", "font-family", "font-size", "font-size-adjust", "font-stretch", "font-style", "font-variant", "font-weight", "fx", "fy", "g1", "g2", "glyph-name", "glyphref", "gradientunits", "gradienttransform", "height", "href", "id", "image-rendering", "in", "in2", "intercept", "k", "k1", "k2", "k3", "k4", "kerning", "keypoints", "keysplines", "keytimes", "lang", "lengthadjust", "letter-spacing", "kernelmatrix", "kernelunitlength", "lighting-color", "local", "marker-end", "marker-mid", "marker-start", "markerheight", "markerunits", "markerwidth", "maskcontentunits", "maskunits", "max", "mask", "mask-type", "media", "method", "mode", "min", "name", "numoctaves", "offset", "operator", "opacity", "order", "orient", "orientation", "origin", "overflow", "paint-order", "path", "pathlength", "patterncontentunits", "patterntransform", "patternunits", "points", "preservealpha", "preserveaspectratio", "primitiveunits", "r", "rx", "ry", "radius", "refx", "refy", "repeatcount", "repeatdur", "restart", "result", "rotate", "scale", "seed", "shape-rendering", "slope", "specularconstant", "specularexponent", "spreadmethod", "startoffset", "stddeviation", "stitchtiles", "stop-color", "stop-opacity", "stroke-dasharray", "stroke-dashoffset", "stroke-linecap", "stroke-linejoin", "stroke-miterlimit", "stroke-opacity", "stroke", "stroke-width", "style", "surfacescale", "systemlanguage", "tabindex", "tablevalues", "targetx", "targety", "transform", "transform-origin", "text-anchor", "text-decoration", "text-rendering", "textlength", "type", "u1", "u2", "unicode", "values", "viewbox", "visibility", "version", "vert-adv-y", "vert-origin-x", "vert-origin-y", "width", "word-spacing", "wrap", "writing-mode", "xchannelselector", "ychannelselector", "x", "x1", "x2", "xmlns", "y", "y1", "y2", "z", "zoomandpan"]), Mt = D(["accent", "accentunder", "align", "bevelled", "close", "columnalign", "columnlines", "columnspacing", "columnspan", "denomalign", "depth", "dir", "display", "displaystyle", "encoding", "fence", "frame", "height", "href", "id", "largeop", "length", "linethickness", "lquote", "lspace", "mathbackground", "mathcolor", "mathsize", "mathvariant", "maxsize", "minsize", "movablelimits", "notation", "numalign", "open", "rowalign", "rowlines", "rowspacing", "rowspan", "rspace", "rquote", "scriptlevel", "scriptminsize", "scriptsizemultiplier", "selection", "separator", "separators", "stretchy", "subscriptshift", "supscriptshift", "symmetric", "voffset", "width", "xmlns"]), Ie = D(["xlink:href", "xml:id", "xlink:title", "xml:space", "xmlns:xlink"]), yn = C(/{{[\w\W]*|^[\w\W]*}}/g), bn = C(/<%[\w\W]*|^[\w\W]*%>/g), Rn = C(/\${[\w\W]*/g), On = C(/^data-[\-\w.\u00B7-\uFFFF]+$/), Nn = C(/^aria-[\-\w]+$/), xt = C(
157
+ /^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i
158
+ // eslint-disable-line no-useless-escape
159
+ ), Dn = C(/^(?:\w+script|data):/i), In = C(
160
+ /[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g
161
+ // eslint-disable-line no-control-regex
162
+ ), Ln = C(/^html$/i), Cn = C(/^[a-z][.\w]*(-[.\w]+)+$/i), F = {
163
+ element: 1,
164
+ attribute: 2,
165
+ text: 3,
166
+ cdataSection: 4,
167
+ entityReference: 5,
168
+ // Deprecated
169
+ entityNode: 6,
170
+ // Deprecated
171
+ progressingInstruction: 7,
172
+ comment: 8,
173
+ document: 9,
174
+ documentType: 10,
175
+ documentFragment: 11,
176
+ notation: 12
177
+ // Deprecated
178
+ }, wn = function() {
179
+ return typeof window > "u" ? null : window;
180
+ }, Mn = function(o, a) {
181
+ if (typeof o != "object" || typeof o.createPolicy != "function")
182
+ return null;
183
+ let s = null;
184
+ const f = "data-tt-policy-suffix";
185
+ a && a.hasAttribute(f) && (s = a.getAttribute(f));
186
+ const p = "dompurify" + (s ? "#" + s : "");
187
+ try {
188
+ return o.createPolicy(p, {
189
+ createHTML(b) {
190
+ return b;
191
+ },
192
+ createScriptURL(b) {
193
+ return b;
194
+ }
195
+ });
196
+ } catch {
197
+ return console.warn("TrustedTypes policy " + p + " could not be created."), null;
198
+ }
199
+ }, Pt = function() {
200
+ return {
201
+ afterSanitizeAttributes: [],
202
+ afterSanitizeElements: [],
203
+ afterSanitizeShadowDOM: [],
204
+ beforeSanitizeAttributes: [],
205
+ beforeSanitizeElements: [],
206
+ beforeSanitizeShadowDOM: [],
207
+ uponSanitizeAttribute: [],
208
+ uponSanitizeElement: [],
209
+ uponSanitizeShadowNode: []
210
+ };
211
+ };
212
+ function Ft() {
213
+ let n = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : wn();
214
+ const o = (i) => Ft(i);
215
+ if (o.version = "3.4.7", o.removed = [], !n || !n.document || n.document.nodeType !== F.document || !n.Element)
216
+ return o.isSupported = !1, o;
217
+ let a = n.document;
218
+ const s = a, f = s.currentScript;
219
+ n.DocumentFragment;
220
+ const p = n.HTMLTemplateElement, b = n.Node, te = n.Element, I = n.NodeFilter, ne = n.NamedNodeMap;
221
+ ne === void 0 && (n.NamedNodeMap || n.MozNamedAttrMap), n.HTMLFormElement;
222
+ const Le = n.DOMParser, me = n.trustedTypes, W = te.prototype, Ut = U(W, "cloneNode"), Ht = U(W, "remove"), zt = U(W, "nextSibling"), pe = U(W, "childNodes"), Te = U(W, "parentNode"), de = U(W, "shadowRoot"), Gt = U(W, "attributes"), w = b && b.prototype ? U(b.prototype, "nodeType") : null, Y = b && b.prototype ? U(b.prototype, "nodeName") : null;
223
+ if (typeof p == "function") {
224
+ const i = a.createElement("template");
225
+ i.content && i.content.ownerDocument && (a = i.content.ownerDocument);
226
+ }
227
+ let O, oe = "";
228
+ const ge = a, Ce = ge.implementation, Je = ge.createNodeIterator, Wt = ge.createDocumentFragment, Bt = ge.getElementsByTagName, jt = s.importNode;
229
+ let E = Pt();
230
+ o.isSupported = typeof kt == "function" && typeof Te == "function" && Ce && Ce.createHTMLDocument !== void 0;
231
+ const _e = yn, he = bn, Ae = Rn, Yt = On, $t = Nn, Xt = Dn, Qe = In, Vt = Cn;
232
+ let et = xt, d = null;
233
+ const we = l({}, [...Lt, ...$e, ...Xe, ...Ve, ...Ct]);
234
+ let h = null;
235
+ const Me = l({}, [...wt, ...qe, ...Mt, ...Ie]);
236
+ let g = Object.seal(ee(null, {
237
+ tagNameCheck: {
238
+ writable: !0,
239
+ configurable: !1,
240
+ enumerable: !0,
241
+ value: null
242
+ },
243
+ attributeNameCheck: {
244
+ writable: !0,
245
+ configurable: !1,
246
+ enumerable: !0,
247
+ value: null
248
+ },
249
+ allowCustomizedBuiltInElements: {
250
+ writable: !0,
251
+ configurable: !1,
252
+ enumerable: !0,
253
+ value: !1
254
+ }
255
+ })), re = null, Ee = null;
256
+ const z = Object.seal(ee(null, {
257
+ tagCheck: {
258
+ writable: !0,
259
+ configurable: !1,
260
+ enumerable: !0,
261
+ value: null
262
+ },
263
+ attributeCheck: {
264
+ writable: !0,
265
+ configurable: !1,
266
+ enumerable: !0,
267
+ value: null
268
+ }
269
+ }));
270
+ let tt = !0, xe = !0, nt = !1, ot = !0, G = !1, ie = !0, B = !1, Pe = !1, ke = !1, $ = !1, Se = !1, ye = !1, rt = !0, it = !1;
271
+ const at = "user-content-";
272
+ let ve = !0, ae = !1, X = {}, P = null;
273
+ const Fe = l({}, ["annotation-xml", "audio", "colgroup", "desc", "foreignobject", "head", "iframe", "math", "mi", "mn", "mo", "ms", "mtext", "noembed", "noframes", "noscript", "plaintext", "script", "style", "svg", "template", "thead", "title", "video", "xmp"]);
274
+ let st = null;
275
+ const lt = l({}, ["audio", "video", "img", "source", "image", "track"]);
276
+ let Ue = null;
277
+ const ct = l({}, ["alt", "class", "for", "id", "label", "name", "pattern", "placeholder", "role", "summary", "title", "value", "style", "xmlns"]), be = "http://www.w3.org/1998/Math/MathML", Re = "http://www.w3.org/2000/svg", k = "http://www.w3.org/1999/xhtml";
278
+ let V = k, He = !1, ze = null;
279
+ const qt = l({}, [be, Re, k], Ye);
280
+ let Ge = l({}, ["mi", "mo", "mn", "ms", "mtext"]), We = l({}, ["annotation-xml"]);
281
+ const Kt = l({}, ["title", "style", "font", "a", "script"]);
282
+ let se = null;
283
+ const Zt = ["application/xhtml+xml", "text/html"], Jt = "text/html";
284
+ let _ = null, q = null;
285
+ const Qt = a.createElement("form"), ft = function(e) {
286
+ return e instanceof RegExp || e instanceof Function;
287
+ }, Be = function() {
288
+ let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
289
+ if (q && q === e)
290
+ return;
291
+ (!e || typeof e != "object") && (e = {}), e = R(e), se = // eslint-disable-next-line unicorn/prefer-includes
292
+ Zt.indexOf(e.PARSER_MEDIA_TYPE) === -1 ? Jt : e.PARSER_MEDIA_TYPE, _ = se === "application/xhtml+xml" ? Ye : ue, d = T(e, "ALLOWED_TAGS") && N(e.ALLOWED_TAGS) ? l({}, e.ALLOWED_TAGS, _) : we, h = T(e, "ALLOWED_ATTR") && N(e.ALLOWED_ATTR) ? l({}, e.ALLOWED_ATTR, _) : Me, ze = T(e, "ALLOWED_NAMESPACES") && N(e.ALLOWED_NAMESPACES) ? l({}, e.ALLOWED_NAMESPACES, Ye) : qt, Ue = T(e, "ADD_URI_SAFE_ATTR") && N(e.ADD_URI_SAFE_ATTR) ? l(R(ct), e.ADD_URI_SAFE_ATTR, _) : ct, st = T(e, "ADD_DATA_URI_TAGS") && N(e.ADD_DATA_URI_TAGS) ? l(R(lt), e.ADD_DATA_URI_TAGS, _) : lt, P = T(e, "FORBID_CONTENTS") && N(e.FORBID_CONTENTS) ? l({}, e.FORBID_CONTENTS, _) : Fe, re = T(e, "FORBID_TAGS") && N(e.FORBID_TAGS) ? l({}, e.FORBID_TAGS, _) : R({}), Ee = T(e, "FORBID_ATTR") && N(e.FORBID_ATTR) ? l({}, e.FORBID_ATTR, _) : R({}), X = T(e, "USE_PROFILES") ? e.USE_PROFILES && typeof e.USE_PROFILES == "object" ? R(e.USE_PROFILES) : e.USE_PROFILES : !1, tt = e.ALLOW_ARIA_ATTR !== !1, xe = e.ALLOW_DATA_ATTR !== !1, nt = e.ALLOW_UNKNOWN_PROTOCOLS || !1, ot = e.ALLOW_SELF_CLOSE_IN_ATTR !== !1, G = e.SAFE_FOR_TEMPLATES || !1, ie = e.SAFE_FOR_XML !== !1, B = e.WHOLE_DOCUMENT || !1, $ = e.RETURN_DOM || !1, Se = e.RETURN_DOM_FRAGMENT || !1, ye = e.RETURN_TRUSTED_TYPE || !1, ke = e.FORCE_BODY || !1, rt = e.SANITIZE_DOM !== !1, it = e.SANITIZE_NAMED_PROPS || !1, ve = e.KEEP_CONTENT !== !1, ae = e.IN_PLACE || !1, et = An(e.ALLOWED_URI_REGEXP) ? e.ALLOWED_URI_REGEXP : xt, V = typeof e.NAMESPACE == "string" ? e.NAMESPACE : k, Ge = T(e, "MATHML_TEXT_INTEGRATION_POINTS") && e.MATHML_TEXT_INTEGRATION_POINTS && typeof e.MATHML_TEXT_INTEGRATION_POINTS == "object" ? R(e.MATHML_TEXT_INTEGRATION_POINTS) : l({}, ["mi", "mo", "mn", "ms", "mtext"]), We = T(e, "HTML_INTEGRATION_POINTS") && e.HTML_INTEGRATION_POINTS && typeof e.HTML_INTEGRATION_POINTS == "object" ? R(e.HTML_INTEGRATION_POINTS) : l({}, ["annotation-xml"]);
293
+ const t = T(e, "CUSTOM_ELEMENT_HANDLING") && e.CUSTOM_ELEMENT_HANDLING && typeof e.CUSTOM_ELEMENT_HANDLING == "object" ? R(e.CUSTOM_ELEMENT_HANDLING) : ee(null);
294
+ if (g = ee(null), T(t, "tagNameCheck") && ft(t.tagNameCheck) && (g.tagNameCheck = t.tagNameCheck), T(t, "attributeNameCheck") && ft(t.attributeNameCheck) && (g.attributeNameCheck = t.attributeNameCheck), T(t, "allowCustomizedBuiltInElements") && typeof t.allowCustomizedBuiltInElements == "boolean" && (g.allowCustomizedBuiltInElements = t.allowCustomizedBuiltInElements), G && (xe = !1), Se && ($ = !0), X && (d = l({}, Ct), h = ee(null), X.html === !0 && (l(d, Lt), l(h, wt)), X.svg === !0 && (l(d, $e), l(h, qe), l(h, Ie)), X.svgFilters === !0 && (l(d, Xe), l(h, qe), l(h, Ie)), X.mathMl === !0 && (l(d, Ve), l(h, Mt), l(h, Ie))), z.tagCheck = null, z.attributeCheck = null, T(e, "ADD_TAGS") && (typeof e.ADD_TAGS == "function" ? z.tagCheck = e.ADD_TAGS : N(e.ADD_TAGS) && (d === we && (d = R(d)), l(d, e.ADD_TAGS, _))), T(e, "ADD_ATTR") && (typeof e.ADD_ATTR == "function" ? z.attributeCheck = e.ADD_ATTR : N(e.ADD_ATTR) && (h === Me && (h = R(h)), l(h, e.ADD_ATTR, _))), T(e, "ADD_URI_SAFE_ATTR") && N(e.ADD_URI_SAFE_ATTR) && l(Ue, e.ADD_URI_SAFE_ATTR, _), T(e, "FORBID_CONTENTS") && N(e.FORBID_CONTENTS) && (P === Fe && (P = R(P)), l(P, e.FORBID_CONTENTS, _)), T(e, "ADD_FORBID_CONTENTS") && N(e.ADD_FORBID_CONTENTS) && (P === Fe && (P = R(P)), l(P, e.ADD_FORBID_CONTENTS, _)), ve && (d["#text"] = !0), B && l(d, ["html", "head", "body"]), d.table && (l(d, ["tbody"]), delete re.tbody), e.TRUSTED_TYPES_POLICY) {
295
+ if (typeof e.TRUSTED_TYPES_POLICY.createHTML != "function")
296
+ throw fe('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');
297
+ if (typeof e.TRUSTED_TYPES_POLICY.createScriptURL != "function")
298
+ throw fe('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');
299
+ O = e.TRUSTED_TYPES_POLICY, oe = O.createHTML("");
300
+ } else
301
+ O === void 0 && (O = Mn(me, f)), O !== null && typeof oe == "string" && (oe = O.createHTML(""));
302
+ (E.uponSanitizeElement.length > 0 || E.uponSanitizeAttribute.length > 0) && d === we && (d = R(d)), E.uponSanitizeAttribute.length > 0 && h === Me && (h = R(h)), D && D(e), q = e;
303
+ }, ut = l({}, [...$e, ...Xe, ...En]), mt = l({}, [...Ve, ...Sn]), en = function(e) {
304
+ let t = Te(e);
305
+ (!t || !t.tagName) && (t = {
306
+ namespaceURI: V,
307
+ tagName: "template"
308
+ });
309
+ const r = ue(e.tagName), u = ue(t.tagName);
310
+ return ze[e.namespaceURI] ? e.namespaceURI === Re ? t.namespaceURI === k ? r === "svg" : t.namespaceURI === be ? r === "svg" && (u === "annotation-xml" || Ge[u]) : !!ut[r] : e.namespaceURI === be ? t.namespaceURI === k ? r === "math" : t.namespaceURI === Re ? r === "math" && We[u] : !!mt[r] : e.namespaceURI === k ? t.namespaceURI === Re && !We[u] || t.namespaceURI === be && !Ge[u] ? !1 : !mt[r] && (Kt[r] || !ut[r]) : !!(se === "application/xhtml+xml" && ze[e.namespaceURI]) : !1;
311
+ }, M = function(e) {
312
+ J(o.removed, {
313
+ element: e
314
+ });
315
+ try {
316
+ Te(e).removeChild(e);
317
+ } catch {
318
+ Ht(e);
319
+ }
320
+ }, j = function(e, t) {
321
+ try {
322
+ J(o.removed, {
323
+ attribute: t.getAttributeNode(e),
324
+ from: t
325
+ });
326
+ } catch {
327
+ J(o.removed, {
328
+ attribute: null,
329
+ from: t
330
+ });
331
+ }
332
+ if (t.removeAttribute(e), e === "is")
333
+ if ($ || Se)
334
+ try {
335
+ M(t);
336
+ } catch {
337
+ }
338
+ else
339
+ try {
340
+ t.setAttribute(e, "");
341
+ } catch {
342
+ }
343
+ }, pt = function(e) {
344
+ let t = null, r = null;
345
+ if (ke)
346
+ e = "<remove></remove>" + e;
347
+ else {
348
+ const m = Ot(e, /^[\r\n\t ]+/);
349
+ r = m && m[0];
350
+ }
351
+ se === "application/xhtml+xml" && V === k && (e = '<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>' + e + "</body></html>");
352
+ const u = O ? O.createHTML(e) : e;
353
+ if (V === k)
354
+ try {
355
+ t = new Le().parseFromString(u, se);
356
+ } catch {
357
+ }
358
+ if (!t || !t.documentElement) {
359
+ t = Ce.createDocument(V, "template", null);
360
+ try {
361
+ t.documentElement.innerHTML = He ? oe : u;
362
+ } catch {
363
+ }
364
+ }
365
+ const c = t.body || t.documentElement;
366
+ return e && r && c.insertBefore(a.createTextNode(r), c.childNodes[0] || null), V === k ? Bt.call(t, B ? "html" : "body")[0] : B ? t.documentElement : c;
367
+ }, Tt = function(e) {
368
+ return Je.call(
369
+ e.ownerDocument || e,
370
+ e,
371
+ // eslint-disable-next-line no-bitwise
372
+ I.SHOW_ELEMENT | I.SHOW_COMMENT | I.SHOW_TEXT | I.SHOW_PROCESSING_INSTRUCTION | I.SHOW_CDATA_SECTION,
373
+ null
374
+ );
375
+ }, dt = function(e) {
376
+ e.normalize();
377
+ const t = Je.call(
378
+ e.ownerDocument || e,
379
+ e,
380
+ // eslint-disable-next-line no-bitwise
381
+ I.SHOW_TEXT | I.SHOW_COMMENT | I.SHOW_CDATA_SECTION | I.SHOW_PROCESSING_INSTRUCTION,
382
+ null
383
+ );
384
+ let r = t.nextNode();
385
+ for (; r; ) {
386
+ let u = r.data;
387
+ Z([_e, he, Ae], (c) => {
388
+ u = Q(u, c, " ");
389
+ }), r.data = u, r = t.nextNode();
390
+ }
391
+ }, Oe = function(e) {
392
+ const t = Y ? Y(e) : null;
393
+ return typeof t != "string" || _(t) !== "form" ? !1 : typeof e.nodeName != "string" || typeof e.textContent != "string" || typeof e.removeChild != "function" || // Realm-safe NamedNodeMap detection: equality against the cached
394
+ // prototype getter. Clobbered .attributes (e.g. <input name="attributes">)
395
+ // makes the direct read diverge from the cached read; a clean form
396
+ // (same-realm OR foreign-realm) has both reads pointing at the same
397
+ // canonical NamedNodeMap.
398
+ e.attributes !== Gt(e) || typeof e.removeAttribute != "function" || typeof e.setAttribute != "function" || typeof e.namespaceURI != "string" || typeof e.insertBefore != "function" || typeof e.hasChildNodes != "function" || // NodeType clobbering probe. Cached Node.prototype.nodeType getter
399
+ // returns the integer 1 for any Element regardless of realm; direct
400
+ // read on a clobbered form (e.g. <input name="nodeType">) returns
401
+ // the named child element. Cheap addition — nodeType is read from
402
+ // an internal slot, no serialization cost — and removes a residual
403
+ // clobbering surface used by several mXSS / PI / comment branches
404
+ // in _sanitizeElements that compare currentNode.nodeType directly.
405
+ e.nodeType !== w(e) || // HTMLFormElement has [LegacyOverrideBuiltIns]: a descendant named
406
+ // "childNodes" shadows the prototype getter. Direct reads of
407
+ // form.childNodes from a clobbered form return the named child
408
+ // instead of the real NodeList, so any walk that reads it directly
409
+ // skips the form's real children. Compare the direct read to the
410
+ // cached Node.prototype getter — when the form's named-property
411
+ // getter intercepts the read, the two values differ and we flag
412
+ // the form. This catches every clobbering child type (input,
413
+ // select, etc.) regardless of whether the named child happens to
414
+ // carry a numeric .length, which a typeof-based probe would miss
415
+ // (e.g. HTMLSelectElement.length is a defined unsigned-long).
416
+ e.childNodes !== pe(e);
417
+ }, le = function(e) {
418
+ if (!w || typeof e != "object" || e === null)
419
+ return !1;
420
+ try {
421
+ return w(e) === F.documentFragment;
422
+ } catch {
423
+ return !1;
424
+ }
425
+ }, Ne = function(e) {
426
+ if (!w || typeof e != "object" || e === null)
427
+ return !1;
428
+ try {
429
+ return typeof w(e) == "number";
430
+ } catch {
431
+ return !1;
432
+ }
433
+ };
434
+ function H(i, e, t) {
435
+ Z(i, (r) => {
436
+ r.call(o, e, t, q);
437
+ });
438
+ }
439
+ const gt = function(e) {
440
+ let t = null;
441
+ if (H(E.beforeSanitizeElements, e, null), Oe(e))
442
+ return M(e), !0;
443
+ const r = _(e.nodeName);
444
+ if (H(E.uponSanitizeElement, e, {
445
+ tagName: r,
446
+ allowedTags: d
447
+ }), ie && e.hasChildNodes() && !Ne(e.firstElementChild) && y(/<[/\w!]/g, e.innerHTML) && y(/<[/\w!]/g, e.textContent) || ie && e.namespaceURI === k && r === "style" && Ne(e.firstElementChild) || e.nodeType === F.progressingInstruction || ie && e.nodeType === F.comment && y(/<[/\w]/g, e.data))
448
+ return M(e), !0;
449
+ if (re[r] || !(z.tagCheck instanceof Function && z.tagCheck(r)) && !d[r]) {
450
+ if (!re[r] && ht(r) && (g.tagNameCheck instanceof RegExp && y(g.tagNameCheck, r) || g.tagNameCheck instanceof Function && g.tagNameCheck(r)))
451
+ return !1;
452
+ if (ve && !P[r]) {
453
+ const c = Te(e), m = pe(e);
454
+ if (m && c) {
455
+ const L = m.length;
456
+ for (let v = L - 1; v >= 0; --v) {
457
+ const x = Ut(m[v], !0);
458
+ c.insertBefore(x, zt(e));
459
+ }
460
+ }
461
+ }
462
+ return M(e), !0;
463
+ }
464
+ return (w ? w(e) : e.nodeType) === F.element && !en(e) || (r === "noscript" || r === "noembed" || r === "noframes") && y(/<\/no(script|embed|frames)/i, e.innerHTML) ? (M(e), !0) : (G && e.nodeType === F.text && (t = e.textContent, Z([_e, he, Ae], (c) => {
465
+ t = Q(t, c, " ");
466
+ }), e.textContent !== t && (J(o.removed, {
467
+ element: e.cloneNode()
468
+ }), e.textContent = t)), H(E.afterSanitizeElements, e, null), !1);
469
+ }, _t = function(e, t, r) {
470
+ if (Ee[t] || rt && (t === "id" || t === "name") && (r in a || r in Qt))
471
+ return !1;
472
+ const u = h[t] || z.attributeCheck instanceof Function && z.attributeCheck(t, e);
473
+ if (!(xe && !Ee[t] && y(Yt, t))) {
474
+ if (!(tt && y($t, t))) {
475
+ if (!u || Ee[t]) {
476
+ if (
477
+ // First condition does a very basic check if a) it's basically a valid custom element tagname AND
478
+ // b) if the tagName passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
479
+ // and c) if the attribute name passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.attributeNameCheck
480
+ !(ht(e) && (g.tagNameCheck instanceof RegExp && y(g.tagNameCheck, e) || g.tagNameCheck instanceof Function && g.tagNameCheck(e)) && (g.attributeNameCheck instanceof RegExp && y(g.attributeNameCheck, t) || g.attributeNameCheck instanceof Function && g.attributeNameCheck(t, e)) || // Alternative, second condition checks if it's an `is`-attribute, AND
481
+ // the value passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
482
+ t === "is" && g.allowCustomizedBuiltInElements && (g.tagNameCheck instanceof RegExp && y(g.tagNameCheck, r) || g.tagNameCheck instanceof Function && g.tagNameCheck(r)))
483
+ ) return !1;
484
+ } else if (!Ue[t]) {
485
+ if (!y(et, Q(r, Qe, ""))) {
486
+ if (!((t === "src" || t === "xlink:href" || t === "href") && e !== "script" && Nt(r, "data:") === 0 && st[e])) {
487
+ if (!(nt && !y(Xt, Q(r, Qe, "")))) {
488
+ if (r)
489
+ return !1;
490
+ }
491
+ }
492
+ }
493
+ }
494
+ }
495
+ }
496
+ return !0;
497
+ }, tn = l({}, ["annotation-xml", "color-profile", "font-face", "font-face-format", "font-face-name", "font-face-src", "font-face-uri", "missing-glyph"]), ht = function(e) {
498
+ return !tn[ue(e)] && y(Vt, e);
499
+ }, At = function(e) {
500
+ H(E.beforeSanitizeAttributes, e, null);
501
+ const t = e.attributes;
502
+ if (!t || Oe(e))
503
+ return;
504
+ const r = {
505
+ attrName: "",
506
+ attrValue: "",
507
+ keepAttr: !0,
508
+ allowedAttributes: h,
509
+ forceKeepAttr: void 0
510
+ };
511
+ let u = t.length;
512
+ for (; u--; ) {
513
+ const c = t[u], m = c.name, L = c.namespaceURI, v = c.value, x = _(m), je = v;
514
+ let S = m === "value" ? je : pn(je);
515
+ if (r.attrName = x, r.attrValue = S, r.keepAttr = !0, r.forceKeepAttr = void 0, H(E.uponSanitizeAttribute, e, r), S = r.attrValue, it && (x === "id" || x === "name") && Nt(S, at) !== 0 && (j(m, e), S = at + S), ie && y(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i, S)) {
516
+ j(m, e);
517
+ continue;
518
+ }
519
+ if (x === "attributename" && Ot(S, "href")) {
520
+ j(m, e);
521
+ continue;
522
+ }
523
+ if (r.forceKeepAttr)
524
+ continue;
525
+ if (!r.keepAttr) {
526
+ j(m, e);
527
+ continue;
528
+ }
529
+ if (!ot && y(/\/>/i, S)) {
530
+ j(m, e);
531
+ continue;
532
+ }
533
+ G && Z([_e, he, Ae], (St) => {
534
+ S = Q(S, St, " ");
535
+ });
536
+ const Et = _(e.nodeName);
537
+ if (!_t(Et, x, S)) {
538
+ j(m, e);
539
+ continue;
540
+ }
541
+ if (O && typeof me == "object" && typeof me.getAttributeType == "function" && !L)
542
+ switch (me.getAttributeType(Et, x)) {
543
+ case "TrustedHTML": {
544
+ S = O.createHTML(S);
545
+ break;
546
+ }
547
+ case "TrustedScriptURL": {
548
+ S = O.createScriptURL(S);
549
+ break;
550
+ }
551
+ }
552
+ if (S !== je)
553
+ try {
554
+ L ? e.setAttributeNS(L, m, S) : e.setAttribute(m, S), Oe(e) ? M(e) : Rt(o.removed);
555
+ } catch {
556
+ j(m, e);
557
+ }
558
+ }
559
+ H(E.afterSanitizeAttributes, e, null);
560
+ }, De = function(e) {
561
+ let t = null;
562
+ const r = Tt(e);
563
+ for (H(E.beforeSanitizeShadowDOM, e, null); t = r.nextNode(); )
564
+ if (H(E.uponSanitizeShadowNode, t, null), gt(t), At(t), le(t.content) && De(t.content), (w ? w(t) : t.nodeType) === F.element) {
565
+ const c = de ? de(t) : t.shadowRoot;
566
+ le(c) && (K(c), De(c));
567
+ }
568
+ H(E.afterSanitizeShadowDOM, e, null);
569
+ }, K = function(e) {
570
+ const t = w ? w(e) : e.nodeType;
571
+ if (t === F.element) {
572
+ const c = de ? de(e) : e.shadowRoot;
573
+ le(c) && (K(c), De(c));
574
+ }
575
+ const r = pe ? pe(e) : e.childNodes;
576
+ if (!r)
577
+ return;
578
+ const u = [];
579
+ Z(r, (c) => {
580
+ J(u, c);
581
+ });
582
+ for (const c of u)
583
+ K(c);
584
+ if (t === F.element) {
585
+ const c = Y ? Y(e) : null;
586
+ if (typeof c == "string" && _(c) === "template") {
587
+ const m = e.content;
588
+ le(m) && K(m);
589
+ }
590
+ }
591
+ };
592
+ return o.sanitize = function(i) {
593
+ let e = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, t = null, r = null, u = null, c = null;
594
+ if (He = !i, He && (i = "<!-->"), typeof i != "string" && !Ne(i) && (i = hn(i), typeof i != "string"))
595
+ throw fe("dirty is not a string, aborting");
596
+ if (!o.isSupported)
597
+ return i;
598
+ if (Pe || Be(e), o.removed = [], typeof i == "string" && (ae = !1), ae) {
599
+ const v = Y ? Y(i) : i.nodeName;
600
+ if (typeof v == "string") {
601
+ const x = _(v);
602
+ if (!d[x] || re[x])
603
+ throw fe("root node is forbidden and cannot be sanitized in-place");
604
+ }
605
+ if (Oe(i))
606
+ throw fe("root node is clobbered and cannot be sanitized in-place");
607
+ K(i);
608
+ } else if (Ne(i))
609
+ t = pt("<!---->"), r = t.ownerDocument.importNode(i, !0), r.nodeType === F.element && r.nodeName === "BODY" || r.nodeName === "HTML" ? t = r : t.appendChild(r), K(r);
610
+ else {
611
+ if (!$ && !G && !B && // eslint-disable-next-line unicorn/prefer-includes
612
+ i.indexOf("<") === -1)
613
+ return O && ye ? O.createHTML(i) : i;
614
+ if (t = pt(i), !t)
615
+ return $ ? null : ye ? oe : "";
616
+ }
617
+ t && ke && M(t.firstChild);
618
+ const m = Tt(ae ? i : t);
619
+ for (; u = m.nextNode(); )
620
+ gt(u), At(u), le(u.content) && De(u.content);
621
+ if (ae)
622
+ return G && dt(i), i;
623
+ if ($) {
624
+ if (G && dt(t), Se)
625
+ for (c = Wt.call(t.ownerDocument); t.firstChild; )
626
+ c.appendChild(t.firstChild);
627
+ else
628
+ c = t;
629
+ return (h.shadowroot || h.shadowrootmode) && (c = jt.call(s, c, !0)), c;
630
+ }
631
+ let L = B ? t.outerHTML : t.innerHTML;
632
+ return B && d["!doctype"] && t.ownerDocument && t.ownerDocument.doctype && t.ownerDocument.doctype.name && y(Ln, t.ownerDocument.doctype.name) && (L = "<!DOCTYPE " + t.ownerDocument.doctype.name + `>
633
+ ` + L), G && Z([_e, he, Ae], (v) => {
634
+ L = Q(L, v, " ");
635
+ }), O && ye ? O.createHTML(L) : L;
636
+ }, o.setConfig = function() {
637
+ let i = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
638
+ Be(i), Pe = !0;
639
+ }, o.clearConfig = function() {
640
+ q = null, Pe = !1;
641
+ }, o.isValidAttribute = function(i, e, t) {
642
+ q || Be({});
643
+ const r = _(i), u = _(e);
644
+ return _t(r, u, t);
645
+ }, o.addHook = function(i, e) {
646
+ typeof e == "function" && J(E[i], e);
647
+ }, o.removeHook = function(i, e) {
648
+ if (e !== void 0) {
649
+ const t = un(E[i], e);
650
+ return t === -1 ? void 0 : mn(E[i], t, 1)[0];
651
+ }
652
+ return Rt(E[i]);
653
+ }, o.removeHooks = function(i) {
654
+ E[i] = [];
655
+ }, o.removeAllHooks = function() {
656
+ E = Pt();
657
+ }, o;
658
+ }
659
+ Ft();