@touchvue/chat 1.0.0-beta.3 → 1.0.0-beta.30

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 (1012) hide show
  1. package/README.md +70 -70
  2. package/es/index.mjs.map +1 -1
  3. package/es/node_modules/.pnpm/dompurify@3.3.0/node_modules/dompurify/dist/purify.es.mjs +1380 -0
  4. package/es/node_modules/.pnpm/dompurify@3.3.0/node_modules/dompurify/dist/purify.es.mjs.map +1 -0
  5. package/es/node_modules/.pnpm/entities@4.5.0/node_modules/entities/lib/esm/decode.mjs +469 -0
  6. package/es/node_modules/.pnpm/entities@4.5.0/node_modules/entities/lib/esm/decode.mjs.map +1 -0
  7. package/es/node_modules/.pnpm/entities@4.5.0/node_modules/entities/lib/esm/decode_codepoint.mjs +63 -0
  8. package/es/node_modules/.pnpm/entities@4.5.0/node_modules/entities/lib/esm/decode_codepoint.mjs.map +1 -0
  9. package/es/node_modules/.pnpm/entities@4.5.0/node_modules/entities/lib/esm/generated/decode-data-html.mjs +9 -0
  10. package/es/node_modules/.pnpm/entities@4.5.0/node_modules/entities/lib/esm/generated/decode-data-html.mjs.map +1 -0
  11. package/es/node_modules/.pnpm/entities@4.5.0/node_modules/entities/lib/esm/generated/decode-data-xml.mjs +9 -0
  12. package/es/node_modules/.pnpm/entities@4.5.0/node_modules/entities/lib/esm/generated/decode-data-xml.mjs.map +1 -0
  13. package/es/node_modules/.pnpm/html2canvas@1.4.1/node_modules/html2canvas/dist/html2canvas.esm.mjs +7824 -0
  14. package/es/node_modules/.pnpm/html2canvas@1.4.1/node_modules/html2canvas/dist/html2canvas.esm.mjs.map +1 -0
  15. package/es/node_modules/.pnpm/linkify-it@5.0.0/node_modules/linkify-it/index.mjs +643 -0
  16. package/es/node_modules/.pnpm/linkify-it@5.0.0/node_modules/linkify-it/index.mjs.map +1 -0
  17. package/es/node_modules/.pnpm/linkify-it@5.0.0/node_modules/linkify-it/lib/re.mjs +195 -0
  18. package/es/node_modules/.pnpm/linkify-it@5.0.0/node_modules/linkify-it/lib/re.mjs.map +1 -0
  19. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/common/html_blocks.mjs +70 -0
  20. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/common/html_blocks.mjs.map +1 -0
  21. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/common/html_re.mjs +26 -0
  22. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/common/html_re.mjs.map +1 -0
  23. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/common/utils.mjs +291 -0
  24. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/common/utils.mjs.map +1 -0
  25. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/helpers/index.mjs +6 -0
  26. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/helpers/index.mjs.map +1 -0
  27. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/helpers/parse_link_destination.mjs +81 -0
  28. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/helpers/parse_link_destination.mjs.map +1 -0
  29. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/helpers/parse_link_label.mjs +52 -0
  30. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/helpers/parse_link_label.mjs.map +1 -0
  31. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/helpers/parse_link_title.mjs +70 -0
  32. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/helpers/parse_link_title.mjs.map +1 -0
  33. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/index.mjs +570 -0
  34. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/index.mjs.map +1 -0
  35. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/parser_block.mjs +135 -0
  36. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/parser_block.mjs.map +1 -0
  37. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/parser_core.mjs +63 -0
  38. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/parser_core.mjs.map +1 -0
  39. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/parser_inline.mjs +197 -0
  40. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/parser_inline.mjs.map +1 -0
  41. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/presets/commonmark.mjs +91 -0
  42. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/presets/commonmark.mjs.map +1 -0
  43. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/presets/default.mjs +50 -0
  44. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/presets/default.mjs.map +1 -0
  45. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/presets/zero.mjs +73 -0
  46. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/presets/zero.mjs.map +1 -0
  47. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/renderer.mjs +323 -0
  48. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/renderer.mjs.map +1 -0
  49. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/ruler.mjs +341 -0
  50. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/ruler.mjs.map +1 -0
  51. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/blockquote.mjs +213 -0
  52. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/blockquote.mjs.map +1 -0
  53. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/code.mjs +33 -0
  54. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/code.mjs.map +1 -0
  55. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/fence.mjs +97 -0
  56. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/fence.mjs.map +1 -0
  57. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/heading.mjs +55 -0
  58. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/heading.mjs.map +1 -0
  59. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/hr.mjs +44 -0
  60. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/hr.mjs.map +1 -0
  61. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/html_block.mjs +73 -0
  62. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/html_block.mjs.map +1 -0
  63. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/lheading.mjs +85 -0
  64. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/lheading.mjs.map +1 -0
  65. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/list.mjs +335 -0
  66. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/list.mjs.map +1 -0
  67. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/paragraph.mjs +49 -0
  68. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/paragraph.mjs.map +1 -0
  69. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/reference.mjs +211 -0
  70. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/reference.mjs.map +1 -0
  71. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/state_block.mjs +222 -0
  72. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/state_block.mjs.map +1 -0
  73. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/table.mjs +232 -0
  74. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/table.mjs.map +1 -0
  75. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/block.mjs +16 -0
  76. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/block.mjs.map +1 -0
  77. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/inline.mjs +14 -0
  78. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/inline.mjs.map +1 -0
  79. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/linkify.mjs +138 -0
  80. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/linkify.mjs.map +1 -0
  81. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/normalize.mjs +20 -0
  82. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/normalize.mjs.map +1 -0
  83. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/replacements.mjs +104 -0
  84. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/replacements.mjs.map +1 -0
  85. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/smartquotes.mjs +197 -0
  86. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/smartquotes.mjs.map +1 -0
  87. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/state_core.mjs +19 -0
  88. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/state_core.mjs.map +1 -0
  89. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/text_join.mjs +46 -0
  90. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/text_join.mjs.map +1 -0
  91. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/autolink.mjs +75 -0
  92. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/autolink.mjs.map +1 -0
  93. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/backticks.mjs +63 -0
  94. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/backticks.mjs.map +1 -0
  95. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/balance_pairs.mjs +127 -0
  96. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/balance_pairs.mjs.map +1 -0
  97. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/emphasis.mjs +126 -0
  98. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/emphasis.mjs.map +1 -0
  99. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/entity.mjs +55 -0
  100. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/entity.mjs.map +1 -0
  101. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/escape.mjs +73 -0
  102. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/escape.mjs.map +1 -0
  103. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/fragments_join.mjs +41 -0
  104. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/fragments_join.mjs.map +1 -0
  105. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/html_inline.mjs +54 -0
  106. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/html_inline.mjs.map +1 -0
  107. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/image.mjs +142 -0
  108. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/image.mjs.map +1 -0
  109. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/link.mjs +143 -0
  110. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/link.mjs.map +1 -0
  111. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/linkify.mjs +59 -0
  112. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/linkify.mjs.map +1 -0
  113. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/newline.mjs +46 -0
  114. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/newline.mjs.map +1 -0
  115. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/state_inline.mjs +125 -0
  116. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/state_inline.mjs.map +1 -0
  117. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/strikethrough.mjs +130 -0
  118. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/strikethrough.mjs.map +1 -0
  119. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/text.mjs +89 -0
  120. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/text.mjs.map +1 -0
  121. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/token.mjs +192 -0
  122. package/es/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/token.mjs.map +1 -0
  123. package/es/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/index.mjs +5 -0
  124. package/es/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/index.mjs.map +1 -0
  125. package/es/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/lib/decode.mjs +113 -0
  126. package/es/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/lib/decode.mjs.map +1 -0
  127. package/es/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/lib/encode.mjs +90 -0
  128. package/es/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/lib/encode.mjs.map +1 -0
  129. package/es/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/lib/format.mjs +24 -0
  130. package/es/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/lib/format.mjs.map +1 -0
  131. package/es/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/lib/parse.mjs +309 -0
  132. package/es/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/lib/parse.mjs.map +1 -0
  133. package/es/node_modules/.pnpm/punycode.js@2.3.1/node_modules/punycode.js/punycode.es6.mjs +443 -0
  134. package/es/node_modules/.pnpm/punycode.js@2.3.1/node_modules/punycode.js/punycode.es6.mjs.map +1 -0
  135. package/es/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/Cc/regex.mjs +4 -0
  136. package/es/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/Cc/regex.mjs.map +1 -0
  137. package/es/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/Cf/regex.mjs +4 -0
  138. package/es/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/Cf/regex.mjs.map +1 -0
  139. package/es/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/P/regex.mjs +4 -0
  140. package/es/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/P/regex.mjs.map +1 -0
  141. package/es/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/S/regex.mjs +4 -0
  142. package/es/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/S/regex.mjs.map +1 -0
  143. package/es/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/Z/regex.mjs +4 -0
  144. package/es/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/Z/regex.mjs.map +1 -0
  145. package/es/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/index.mjs +7 -0
  146. package/es/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/index.mjs.map +1 -0
  147. package/es/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/properties/Any/regex.mjs +4 -0
  148. package/es/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/properties/Any/regex.mjs.map +1 -0
  149. package/es/package.json.css +1 -1
  150. package/es/package.json.mjs +1 -1
  151. package/es/packages/components/index.mjs +1 -1
  152. package/es/packages/components/resolver.mjs.map +1 -1
  153. package/es/packages/components/touchchat/component/AiRobot/HelloChat.vue.mjs +7 -0
  154. package/es/packages/components/touchchat/component/AiRobot/HelloChat.vue2.mjs +270 -0
  155. package/es/packages/components/touchchat/component/AiRobot/HelloChat.vue2.mjs.map +1 -0
  156. package/es/packages/components/touchchat/component/AiRobot/face.vue.mjs +7 -0
  157. package/es/packages/components/touchchat/component/AiRobot/face.vue2.mjs +92 -0
  158. package/es/packages/components/touchchat/component/AiRobot/face.vue2.mjs.map +1 -0
  159. package/es/packages/components/touchchat/component/AiRobot/letter.vue.mjs +7 -0
  160. package/es/packages/components/touchchat/component/AiRobot/letter.vue2.mjs +189 -0
  161. package/es/packages/components/touchchat/component/AiRobot/letter.vue2.mjs.map +1 -0
  162. package/es/packages/components/touchchat/component/AiRobot/meterialPrepare.vue.mjs +7 -0
  163. package/es/packages/components/touchchat/component/AiRobot/meterialPrepare.vue2.mjs +44 -0
  164. package/es/packages/components/touchchat/component/AiRobot/meterialPrepare.vue2.mjs.map +1 -0
  165. package/es/packages/components/touchchat/component/AiRobot/start.vue.mjs +7 -0
  166. package/es/packages/components/touchchat/component/AiRobot/start.vue2.mjs +43 -0
  167. package/es/packages/components/touchchat/component/AiRobot/start.vue2.mjs.map +1 -0
  168. package/es/packages/components/touchchat/component/CardView.vue2.mjs.map +1 -1
  169. package/es/packages/components/touchchat/component/FileContent.vue.mjs +7 -0
  170. package/es/packages/components/touchchat/component/FileContent.vue.mjs.map +1 -0
  171. package/es/packages/components/touchchat/component/FileContent.vue2.mjs +201 -0
  172. package/es/packages/components/touchchat/component/FileContent.vue2.mjs.map +1 -0
  173. package/es/packages/components/touchchat/component/FileView.vue2.mjs +2 -2
  174. package/es/packages/components/touchchat/component/FileView.vue2.mjs.map +1 -1
  175. package/es/packages/components/touchchat/component/HelloChat.vue2.mjs +2 -2
  176. package/es/packages/components/touchchat/component/HelloChat.vue2.mjs.map +1 -1
  177. package/es/packages/components/touchchat/component/ImageFile.vue.mjs +7 -0
  178. package/es/packages/components/touchchat/component/ImageFile.vue.mjs.map +1 -0
  179. package/es/packages/components/touchchat/component/ImageFile.vue2.mjs +162 -0
  180. package/es/packages/components/touchchat/component/ImageFile.vue2.mjs.map +1 -0
  181. package/es/packages/components/touchchat/component/ImageView.vue2.mjs +1 -1
  182. package/es/packages/components/touchchat/component/ImageView.vue2.mjs.map +1 -1
  183. package/es/packages/components/touchchat/component/LinkView.vue2.mjs +4 -4
  184. package/es/packages/components/touchchat/component/LinkView.vue2.mjs.map +1 -1
  185. package/es/packages/components/touchchat/component/MarkLayer.vue.mjs +7 -0
  186. package/es/packages/components/touchchat/component/MarkLayer.vue.mjs.map +1 -0
  187. package/es/packages/components/touchchat/component/MarkLayer.vue2.mjs +56 -0
  188. package/es/packages/components/touchchat/component/MarkLayer.vue2.mjs.map +1 -0
  189. package/es/packages/components/touchchat/component/ModuleSelect.vue.mjs +7 -0
  190. package/es/packages/components/touchchat/component/ModuleSelect.vue.mjs.map +1 -0
  191. package/es/packages/components/touchchat/component/ModuleSelect.vue2.mjs +121 -0
  192. package/es/packages/components/touchchat/component/ModuleSelect.vue2.mjs.map +1 -0
  193. package/es/packages/components/touchchat/component/PDFFile.vue.mjs +7 -0
  194. package/es/packages/components/touchchat/component/PDFFile.vue.mjs.map +1 -0
  195. package/es/packages/components/touchchat/component/PDFFile.vue2.mjs +205 -0
  196. package/es/packages/components/touchchat/component/PDFFile.vue2.mjs.map +1 -0
  197. package/es/packages/components/touchchat/component/RealtimeVoice.vue.mjs +7 -0
  198. package/es/packages/components/touchchat/component/RealtimeVoice.vue.mjs.map +1 -0
  199. package/es/packages/components/touchchat/component/RealtimeVoice.vue2.mjs +162 -0
  200. package/es/packages/components/touchchat/component/RealtimeVoice.vue2.mjs.map +1 -0
  201. package/es/packages/components/touchchat/component/Screenshot.vue.mjs +7 -0
  202. package/es/packages/components/touchchat/component/Screenshot.vue.mjs.map +1 -0
  203. package/es/packages/components/touchchat/component/Screenshot.vue2.mjs +201 -0
  204. package/es/packages/components/touchchat/component/Screenshot.vue2.mjs.map +1 -0
  205. package/es/packages/components/touchchat/component/ThoughtChain.vue.mjs +7 -0
  206. package/es/packages/components/touchchat/component/ThoughtChain.vue.mjs.map +1 -0
  207. package/es/packages/components/touchchat/component/ThoughtChain.vue2.mjs +69 -0
  208. package/es/packages/components/touchchat/component/ThoughtChain.vue2.mjs.map +1 -0
  209. package/es/packages/components/touchchat/component/UploadView.vue.mjs +7 -0
  210. package/es/packages/components/touchchat/component/UploadView.vue.mjs.map +1 -0
  211. package/es/packages/components/touchchat/component/UploadView.vue2.mjs +146 -0
  212. package/es/packages/components/touchchat/component/UploadView.vue2.mjs.map +1 -0
  213. package/es/packages/components/touchchat/component/UploadView_api.vue.mjs +7 -0
  214. package/es/packages/components/touchchat/component/UploadView_api.vue.mjs.map +1 -0
  215. package/es/packages/components/touchchat/component/UploadView_api.vue2.mjs +166 -0
  216. package/es/packages/components/touchchat/component/UploadView_api.vue2.mjs.map +1 -0
  217. package/es/packages/components/touchchat/component/VoiceView.vue.mjs +7 -0
  218. package/es/packages/components/touchchat/component/VoiceView.vue.mjs.map +1 -0
  219. package/es/packages/components/touchchat/component/VoiceView.vue2.mjs +167 -0
  220. package/es/packages/components/touchchat/component/VoiceView.vue2.mjs.map +1 -0
  221. package/es/packages/components/touchchat/img/aiAvatar.png.mjs +4 -0
  222. package/es/packages/components/touchchat/img/aiAvatar.png.mjs.map +1 -0
  223. package/es/packages/components/touchchat/img/file/doc.png.mjs +4 -0
  224. package/es/packages/components/touchchat/img/file/doc.png.mjs.map +1 -0
  225. package/es/packages/components/touchchat/img/file/docx.png.mjs +4 -0
  226. package/es/packages/components/touchchat/img/file/docx.png.mjs.map +1 -0
  227. package/es/packages/components/touchchat/img/file/gif.png.mjs +4 -0
  228. package/es/packages/components/touchchat/img/file/gif.png.mjs.map +1 -0
  229. package/es/packages/components/touchchat/img/file/html.png.mjs +4 -0
  230. package/es/packages/components/touchchat/img/file/html.png.mjs.map +1 -0
  231. package/es/packages/components/touchchat/img/file/jpg.png.mjs +4 -0
  232. package/es/packages/components/touchchat/img/file/jpg.png.mjs.map +1 -0
  233. package/es/packages/components/touchchat/img/file/mp3.png.mjs +4 -0
  234. package/es/packages/components/touchchat/img/file/mp3.png.mjs.map +1 -0
  235. package/es/packages/components/touchchat/img/file/mp4.png.mjs +4 -0
  236. package/es/packages/components/touchchat/img/file/mp4.png.mjs.map +1 -0
  237. package/es/packages/components/touchchat/img/file/music.png.mjs +4 -0
  238. package/es/packages/components/touchchat/img/file/music.png.mjs.map +1 -0
  239. package/es/packages/components/touchchat/img/file/pdf.png.mjs +4 -0
  240. package/es/packages/components/touchchat/img/file/pdf.png.mjs.map +1 -0
  241. package/es/packages/components/touchchat/img/file/png.png.mjs +4 -0
  242. package/es/packages/components/touchchat/img/file/png.png.mjs.map +1 -0
  243. package/es/packages/components/touchchat/img/file/ppt.png.mjs +4 -0
  244. package/es/packages/components/touchchat/img/file/ppt.png.mjs.map +1 -0
  245. package/es/packages/components/touchchat/img/file/pptx.png.mjs +4 -0
  246. package/es/packages/components/touchchat/img/file/pptx.png.mjs.map +1 -0
  247. package/es/packages/components/touchchat/img/file/txt.png.mjs +4 -0
  248. package/es/packages/components/touchchat/img/file/txt.png.mjs.map +1 -0
  249. package/es/packages/components/touchchat/img/file/xls.png.mjs +4 -0
  250. package/es/packages/components/touchchat/img/file/xls.png.mjs.map +1 -0
  251. package/es/packages/components/touchchat/img/file/xlsx.png.mjs +4 -0
  252. package/es/packages/components/touchchat/img/file/xlsx.png.mjs.map +1 -0
  253. package/es/packages/components/touchchat/img/icon.png.mjs.map +1 -0
  254. package/es/packages/components/touchchat/img/svg/reset.svg.mjs +4 -0
  255. package/es/packages/components/touchchat/img/svg/reset.svg.mjs.map +1 -0
  256. package/es/packages/components/touchchat/img/userAvatar.png.mjs +4 -0
  257. package/es/packages/components/touchchat/img/userAvatar.png.mjs.map +1 -0
  258. package/es/packages/components/touchchat/index.mjs +5 -5
  259. package/es/packages/components/touchchat/index.mjs.map +1 -1
  260. package/es/packages/components/touchchat/src/AiChat/AgentsView.vue.mjs +7 -0
  261. package/es/packages/components/touchchat/src/AiChat/AgentsView.vue.mjs.map +1 -0
  262. package/es/packages/components/touchchat/src/AiChat/AgentsView.vue2.mjs +59 -0
  263. package/es/packages/components/touchchat/src/AiChat/AgentsView.vue2.mjs.map +1 -0
  264. package/es/packages/components/touchchat/src/AiChat/AiMessage.vue2.mjs +223 -281
  265. package/es/packages/components/touchchat/src/AiChat/AiMessage.vue2.mjs.map +1 -1
  266. package/es/packages/components/touchchat/src/AiChat/Chat/TouchChat.mjs +18 -0
  267. package/es/packages/components/touchchat/src/AiChat/Chat/TouchChat.mjs.map +1 -0
  268. package/es/packages/components/touchchat/src/AiChat/ChatInput.vue2.mjs +439 -158
  269. package/es/packages/components/touchchat/src/AiChat/ChatInput.vue2.mjs.map +1 -1
  270. package/es/packages/components/touchchat/src/AiChat/HistoryList.vue2.mjs +118 -149
  271. package/es/packages/components/touchchat/src/AiChat/HistoryList.vue2.mjs.map +1 -1
  272. package/es/packages/components/touchchat/src/AiChat/HistorySidebar.vue2.mjs +51 -64
  273. package/es/packages/components/touchchat/src/AiChat/HistorySidebar.vue2.mjs.map +1 -1
  274. package/es/packages/components/touchchat/src/AiChat/MessageActions.vue2.mjs +127 -227
  275. package/es/packages/components/touchchat/src/AiChat/MessageActions.vue2.mjs.map +1 -1
  276. package/es/packages/components/touchchat/src/AiChat/SiderBarView.vue.mjs +7 -0
  277. package/es/packages/components/touchchat/src/AiChat/SiderBarView.vue.mjs.map +1 -0
  278. package/es/packages/components/touchchat/src/AiChat/SiderBarView.vue2.mjs +31 -0
  279. package/es/packages/components/touchchat/src/AiChat/SiderBarView.vue2.mjs.map +1 -0
  280. package/es/packages/components/touchchat/src/AiChat/TouchAgent.vue.mjs +7 -0
  281. package/es/packages/components/touchchat/src/AiChat/TouchAgent.vue.mjs.map +1 -0
  282. package/es/packages/components/touchchat/src/AiChat/TouchAgent.vue2.mjs +929 -0
  283. package/es/packages/components/touchchat/src/AiChat/TouchAgent.vue2.mjs.map +1 -0
  284. package/es/packages/components/touchchat/src/AiChat/TouchChat.vue2.mjs +1068 -521
  285. package/es/packages/components/touchchat/src/AiChat/TouchChat.vue2.mjs.map +1 -1
  286. package/es/packages/components/touchchat/src/AiChat/TouchHistory.vue2.mjs +365 -136
  287. package/es/packages/components/touchchat/src/AiChat/TouchHistory.vue2.mjs.map +1 -1
  288. package/es/packages/components/touchchat/src/AiChat/UserMessage.vue2.mjs +129 -66
  289. package/es/packages/components/touchchat/src/AiChat/UserMessage.vue2.mjs.map +1 -1
  290. package/es/packages/components/touchchat/src/index.vue.mjs +2 -2
  291. package/es/packages/components/touchchat/src/index.vue2.mjs +180 -117
  292. package/es/packages/components/touchchat/src/index.vue2.mjs.map +1 -1
  293. package/es/packages/components/touchchat/src/types/a2a.mjs +11 -0
  294. package/es/packages/components/touchchat/src/types/a2a.mjs.map +1 -0
  295. package/es/packages/components/touchchat/utils/a2aService.mjs +292 -0
  296. package/es/packages/components/touchchat/utils/a2aService.mjs.map +1 -0
  297. package/es/packages/components/touchchat/utils/fetchStream.mjs +6 -1
  298. package/es/packages/components/touchchat/utils/fetchStream.mjs.map +1 -1
  299. package/es/packages/components/touchchat/utils/markdown.mjs +3 -3
  300. package/es/packages/components/touchchat/utils/markdown.mjs.map +1 -1
  301. package/es/packages/utils/config.mjs.map +1 -1
  302. package/es/packages/utils/types.mjs.map +1 -1
  303. package/global.d.ts +2 -2
  304. package/lib/index.js.map +1 -1
  305. package/lib/node_modules/.pnpm/dompurify@3.3.0/node_modules/dompurify/dist/purify.es.js +1384 -0
  306. package/lib/node_modules/.pnpm/dompurify@3.3.0/node_modules/dompurify/dist/purify.es.js.map +1 -0
  307. package/lib/node_modules/.pnpm/entities@4.5.0/node_modules/entities/lib/esm/decode.js +477 -0
  308. package/lib/node_modules/.pnpm/entities@4.5.0/node_modules/entities/lib/esm/decode.js.map +1 -0
  309. package/lib/node_modules/.pnpm/entities@4.5.0/node_modules/entities/lib/esm/decode_codepoint.js +66 -0
  310. package/lib/node_modules/.pnpm/entities@4.5.0/node_modules/entities/lib/esm/decode_codepoint.js.map +1 -0
  311. package/lib/node_modules/.pnpm/entities@4.5.0/node_modules/entities/lib/esm/generated/decode-data-html.js +13 -0
  312. package/lib/node_modules/.pnpm/entities@4.5.0/node_modules/entities/lib/esm/generated/decode-data-html.js.map +1 -0
  313. package/lib/node_modules/.pnpm/entities@4.5.0/node_modules/entities/lib/esm/generated/decode-data-xml.js +13 -0
  314. package/lib/node_modules/.pnpm/entities@4.5.0/node_modules/entities/lib/esm/generated/decode-data-xml.js.map +1 -0
  315. package/lib/node_modules/.pnpm/html2canvas@1.4.1/node_modules/html2canvas/dist/html2canvas.esm.js +7828 -0
  316. package/lib/node_modules/.pnpm/html2canvas@1.4.1/node_modules/html2canvas/dist/html2canvas.esm.js.map +1 -0
  317. package/lib/node_modules/.pnpm/linkify-it@5.0.0/node_modules/linkify-it/index.js +647 -0
  318. package/lib/node_modules/.pnpm/linkify-it@5.0.0/node_modules/linkify-it/index.js.map +1 -0
  319. package/lib/node_modules/.pnpm/linkify-it@5.0.0/node_modules/linkify-it/lib/re.js +199 -0
  320. package/lib/node_modules/.pnpm/linkify-it@5.0.0/node_modules/linkify-it/lib/re.js.map +1 -0
  321. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/common/html_blocks.js +74 -0
  322. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/common/html_blocks.js.map +1 -0
  323. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/common/html_re.js +29 -0
  324. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/common/html_re.js.map +1 -0
  325. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/common/utils.js +308 -0
  326. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/common/utils.js.map +1 -0
  327. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/helpers/index.js +12 -0
  328. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/helpers/index.js.map +1 -0
  329. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/helpers/parse_link_destination.js +85 -0
  330. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/helpers/parse_link_destination.js.map +1 -0
  331. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/helpers/parse_link_label.js +56 -0
  332. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/helpers/parse_link_label.js.map +1 -0
  333. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/helpers/parse_link_title.js +74 -0
  334. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/helpers/parse_link_title.js.map +1 -0
  335. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/index.js +573 -0
  336. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/index.js.map +1 -0
  337. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/parser_block.js +139 -0
  338. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/parser_block.js.map +1 -0
  339. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/parser_core.js +67 -0
  340. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/parser_core.js.map +1 -0
  341. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/parser_inline.js +201 -0
  342. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/parser_inline.js.map +1 -0
  343. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/presets/commonmark.js +95 -0
  344. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/presets/commonmark.js.map +1 -0
  345. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/presets/default.js +54 -0
  346. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/presets/default.js.map +1 -0
  347. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/presets/zero.js +77 -0
  348. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/presets/zero.js.map +1 -0
  349. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/renderer.js +327 -0
  350. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/renderer.js.map +1 -0
  351. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/ruler.js +345 -0
  352. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/ruler.js.map +1 -0
  353. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/blockquote.js +217 -0
  354. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/blockquote.js.map +1 -0
  355. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/code.js +37 -0
  356. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/code.js.map +1 -0
  357. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/fence.js +101 -0
  358. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/fence.js.map +1 -0
  359. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/heading.js +59 -0
  360. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/heading.js.map +1 -0
  361. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/hr.js +48 -0
  362. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/hr.js.map +1 -0
  363. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/html_block.js +77 -0
  364. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/html_block.js.map +1 -0
  365. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/lheading.js +89 -0
  366. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/lheading.js.map +1 -0
  367. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/list.js +339 -0
  368. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/list.js.map +1 -0
  369. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/paragraph.js +53 -0
  370. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/paragraph.js.map +1 -0
  371. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/reference.js +215 -0
  372. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/reference.js.map +1 -0
  373. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/state_block.js +226 -0
  374. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/state_block.js.map +1 -0
  375. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/table.js +236 -0
  376. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_block/table.js.map +1 -0
  377. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/block.js +20 -0
  378. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/block.js.map +1 -0
  379. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/inline.js +18 -0
  380. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/inline.js.map +1 -0
  381. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/linkify.js +142 -0
  382. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/linkify.js.map +1 -0
  383. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/normalize.js +24 -0
  384. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/normalize.js.map +1 -0
  385. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/replacements.js +108 -0
  386. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/replacements.js.map +1 -0
  387. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/smartquotes.js +201 -0
  388. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/smartquotes.js.map +1 -0
  389. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/state_core.js +23 -0
  390. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/state_core.js.map +1 -0
  391. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/text_join.js +50 -0
  392. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_core/text_join.js.map +1 -0
  393. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/autolink.js +79 -0
  394. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/autolink.js.map +1 -0
  395. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/backticks.js +67 -0
  396. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/backticks.js.map +1 -0
  397. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/balance_pairs.js +131 -0
  398. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/balance_pairs.js.map +1 -0
  399. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/emphasis.js +130 -0
  400. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/emphasis.js.map +1 -0
  401. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/entity.js +59 -0
  402. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/entity.js.map +1 -0
  403. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/escape.js +77 -0
  404. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/escape.js.map +1 -0
  405. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/fragments_join.js +45 -0
  406. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/fragments_join.js.map +1 -0
  407. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/html_inline.js +58 -0
  408. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/html_inline.js.map +1 -0
  409. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/image.js +146 -0
  410. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/image.js.map +1 -0
  411. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/link.js +147 -0
  412. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/link.js.map +1 -0
  413. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/linkify.js +63 -0
  414. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/linkify.js.map +1 -0
  415. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/newline.js +50 -0
  416. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/newline.js.map +1 -0
  417. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/state_inline.js +129 -0
  418. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/state_inline.js.map +1 -0
  419. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/strikethrough.js +134 -0
  420. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/strikethrough.js.map +1 -0
  421. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/text.js +93 -0
  422. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/rules_inline/text.js.map +1 -0
  423. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/token.js +196 -0
  424. package/lib/node_modules/.pnpm/markdown-it@14.1.0/node_modules/markdown-it/lib/token.js.map +1 -0
  425. package/lib/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/index.js +14 -0
  426. package/lib/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/index.js.map +1 -0
  427. package/lib/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/lib/decode.js +117 -0
  428. package/lib/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/lib/decode.js.map +1 -0
  429. package/lib/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/lib/encode.js +94 -0
  430. package/lib/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/lib/encode.js.map +1 -0
  431. package/lib/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/lib/format.js +28 -0
  432. package/lib/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/lib/format.js.map +1 -0
  433. package/lib/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/lib/parse.js +313 -0
  434. package/lib/node_modules/.pnpm/mdurl@2.0.0/node_modules/mdurl/lib/parse.js.map +1 -0
  435. package/lib/node_modules/.pnpm/punycode.js@2.3.1/node_modules/punycode.js/punycode.es6.js +453 -0
  436. package/lib/node_modules/.pnpm/punycode.js@2.3.1/node_modules/punycode.js/punycode.es6.js.map +1 -0
  437. package/lib/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/Cc/regex.js +8 -0
  438. package/lib/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/Cc/regex.js.map +1 -0
  439. package/lib/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/Cf/regex.js +8 -0
  440. package/lib/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/Cf/regex.js.map +1 -0
  441. package/lib/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/P/regex.js +8 -0
  442. package/lib/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/P/regex.js.map +1 -0
  443. package/lib/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/S/regex.js +8 -0
  444. package/lib/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/S/regex.js.map +1 -0
  445. package/lib/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/Z/regex.js +8 -0
  446. package/lib/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/categories/Z/regex.js.map +1 -0
  447. package/lib/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/index.js +18 -0
  448. package/lib/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/index.js.map +1 -0
  449. package/lib/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/properties/Any/regex.js +8 -0
  450. package/lib/node_modules/.pnpm/uc.micro@2.1.0/node_modules/uc.micro/properties/Any/regex.js.map +1 -0
  451. package/lib/package.json.css +1 -1
  452. package/lib/package.json.js +1 -1
  453. package/lib/packages/components/index.js +2 -2
  454. package/lib/packages/components/resolver.js.map +1 -1
  455. package/lib/packages/components/touchchat/component/AiRobot/HelloChat.vue.js +11 -0
  456. package/lib/packages/components/touchchat/component/AiRobot/HelloChat.vue2.js +274 -0
  457. package/lib/packages/components/touchchat/component/AiRobot/HelloChat.vue2.js.map +1 -0
  458. package/lib/packages/components/touchchat/component/AiRobot/face.vue.js +11 -0
  459. package/lib/packages/components/touchchat/component/AiRobot/face.vue2.js +96 -0
  460. package/lib/packages/components/touchchat/component/AiRobot/face.vue2.js.map +1 -0
  461. package/lib/packages/components/touchchat/component/AiRobot/letter.vue.js +11 -0
  462. package/lib/packages/components/touchchat/component/AiRobot/letter.vue2.js +193 -0
  463. package/lib/packages/components/touchchat/component/AiRobot/letter.vue2.js.map +1 -0
  464. package/lib/packages/components/touchchat/component/AiRobot/meterialPrepare.vue.js +11 -0
  465. package/lib/packages/components/touchchat/component/AiRobot/meterialPrepare.vue2.js +48 -0
  466. package/lib/packages/components/touchchat/component/AiRobot/meterialPrepare.vue2.js.map +1 -0
  467. package/lib/packages/components/touchchat/component/AiRobot/start.vue.js +11 -0
  468. package/lib/packages/components/touchchat/component/AiRobot/start.vue2.js +47 -0
  469. package/lib/packages/components/touchchat/component/AiRobot/start.vue2.js.map +1 -0
  470. package/lib/packages/components/touchchat/component/CardView.vue2.js.map +1 -1
  471. package/lib/packages/components/touchchat/component/FileContent.vue.js +11 -0
  472. package/lib/packages/components/touchchat/component/FileContent.vue.js.map +1 -0
  473. package/lib/packages/components/touchchat/component/FileContent.vue2.js +205 -0
  474. package/lib/packages/components/touchchat/component/FileContent.vue2.js.map +1 -0
  475. package/lib/packages/components/touchchat/component/FileView.vue2.js +2 -2
  476. package/lib/packages/components/touchchat/component/FileView.vue2.js.map +1 -1
  477. package/lib/packages/components/touchchat/component/HelloChat.vue2.js +2 -2
  478. package/lib/packages/components/touchchat/component/HelloChat.vue2.js.map +1 -1
  479. package/lib/packages/components/touchchat/component/ImageFile.vue.js +11 -0
  480. package/lib/packages/components/touchchat/component/ImageFile.vue.js.map +1 -0
  481. package/lib/packages/components/touchchat/component/ImageFile.vue2.js +166 -0
  482. package/lib/packages/components/touchchat/component/ImageFile.vue2.js.map +1 -0
  483. package/lib/packages/components/touchchat/component/ImageView.vue2.js +1 -1
  484. package/lib/packages/components/touchchat/component/ImageView.vue2.js.map +1 -1
  485. package/lib/packages/components/touchchat/component/LinkView.vue2.js +4 -4
  486. package/lib/packages/components/touchchat/component/LinkView.vue2.js.map +1 -1
  487. package/lib/packages/components/touchchat/component/MarkLayer.vue.js +11 -0
  488. package/lib/packages/components/touchchat/component/MarkLayer.vue.js.map +1 -0
  489. package/lib/packages/components/touchchat/component/MarkLayer.vue2.js +60 -0
  490. package/lib/packages/components/touchchat/component/MarkLayer.vue2.js.map +1 -0
  491. package/lib/packages/components/touchchat/component/ModuleSelect.vue.js +11 -0
  492. package/lib/packages/components/touchchat/component/ModuleSelect.vue.js.map +1 -0
  493. package/lib/packages/components/touchchat/component/ModuleSelect.vue2.js +125 -0
  494. package/lib/packages/components/touchchat/component/ModuleSelect.vue2.js.map +1 -0
  495. package/lib/packages/components/touchchat/component/PDFFile.vue.js +11 -0
  496. package/lib/packages/components/touchchat/component/PDFFile.vue.js.map +1 -0
  497. package/lib/packages/components/touchchat/component/PDFFile.vue2.js +209 -0
  498. package/lib/packages/components/touchchat/component/PDFFile.vue2.js.map +1 -0
  499. package/lib/packages/components/touchchat/component/RealtimeVoice.vue.js +11 -0
  500. package/lib/packages/components/touchchat/component/RealtimeVoice.vue.js.map +1 -0
  501. package/lib/packages/components/touchchat/component/RealtimeVoice.vue2.js +166 -0
  502. package/lib/packages/components/touchchat/component/RealtimeVoice.vue2.js.map +1 -0
  503. package/lib/packages/components/touchchat/component/Screenshot.vue.js +11 -0
  504. package/lib/packages/components/touchchat/component/Screenshot.vue.js.map +1 -0
  505. package/lib/packages/components/touchchat/component/Screenshot.vue2.js +205 -0
  506. package/lib/packages/components/touchchat/component/Screenshot.vue2.js.map +1 -0
  507. package/lib/packages/components/touchchat/component/ThoughtChain.vue.js +11 -0
  508. package/lib/packages/components/touchchat/component/ThoughtChain.vue.js.map +1 -0
  509. package/lib/packages/components/touchchat/component/ThoughtChain.vue2.js +73 -0
  510. package/lib/packages/components/touchchat/component/ThoughtChain.vue2.js.map +1 -0
  511. package/lib/packages/components/touchchat/component/UploadView.vue.js +11 -0
  512. package/lib/packages/components/touchchat/component/UploadView.vue.js.map +1 -0
  513. package/lib/packages/components/touchchat/component/UploadView.vue2.js +150 -0
  514. package/lib/packages/components/touchchat/component/UploadView.vue2.js.map +1 -0
  515. package/lib/packages/components/touchchat/component/UploadView_api.vue.js +11 -0
  516. package/lib/packages/components/touchchat/component/UploadView_api.vue.js.map +1 -0
  517. package/lib/packages/components/touchchat/component/UploadView_api.vue2.js +170 -0
  518. package/lib/packages/components/touchchat/component/UploadView_api.vue2.js.map +1 -0
  519. package/lib/packages/components/touchchat/component/VoiceView.vue.js +11 -0
  520. package/lib/packages/components/touchchat/component/VoiceView.vue.js.map +1 -0
  521. package/lib/packages/components/touchchat/component/VoiceView.vue2.js +171 -0
  522. package/lib/packages/components/touchchat/component/VoiceView.vue2.js.map +1 -0
  523. package/lib/packages/components/touchchat/img/aiAvatar.png.js +8 -0
  524. package/lib/packages/components/touchchat/img/aiAvatar.png.js.map +1 -0
  525. package/lib/packages/components/touchchat/img/file/doc.png.js +8 -0
  526. package/lib/packages/components/touchchat/img/file/doc.png.js.map +1 -0
  527. package/lib/packages/components/touchchat/img/file/docx.png.js +8 -0
  528. package/lib/packages/components/touchchat/img/file/docx.png.js.map +1 -0
  529. package/lib/packages/components/touchchat/img/file/gif.png.js +8 -0
  530. package/lib/packages/components/touchchat/img/file/gif.png.js.map +1 -0
  531. package/lib/packages/components/touchchat/img/file/html.png.js +8 -0
  532. package/lib/packages/components/touchchat/img/file/html.png.js.map +1 -0
  533. package/lib/packages/components/touchchat/img/file/jpg.png.js +8 -0
  534. package/lib/packages/components/touchchat/img/file/jpg.png.js.map +1 -0
  535. package/lib/packages/components/touchchat/img/file/mp3.png.js +8 -0
  536. package/lib/packages/components/touchchat/img/file/mp3.png.js.map +1 -0
  537. package/lib/packages/components/touchchat/img/file/mp4.png.js +8 -0
  538. package/lib/packages/components/touchchat/img/file/mp4.png.js.map +1 -0
  539. package/lib/packages/components/touchchat/img/file/music.png.js +8 -0
  540. package/lib/packages/components/touchchat/img/file/music.png.js.map +1 -0
  541. package/lib/packages/components/touchchat/img/file/pdf.png.js +8 -0
  542. package/lib/packages/components/touchchat/img/file/pdf.png.js.map +1 -0
  543. package/lib/packages/components/touchchat/img/file/png.png.js +8 -0
  544. package/lib/packages/components/touchchat/img/file/png.png.js.map +1 -0
  545. package/lib/packages/components/touchchat/img/file/ppt.png.js +8 -0
  546. package/lib/packages/components/touchchat/img/file/ppt.png.js.map +1 -0
  547. package/lib/packages/components/touchchat/img/file/pptx.png.js +8 -0
  548. package/lib/packages/components/touchchat/img/file/pptx.png.js.map +1 -0
  549. package/lib/packages/components/touchchat/img/file/txt.png.js +8 -0
  550. package/lib/packages/components/touchchat/img/file/txt.png.js.map +1 -0
  551. package/lib/packages/components/touchchat/img/file/xls.png.js +8 -0
  552. package/lib/packages/components/touchchat/img/file/xls.png.js.map +1 -0
  553. package/lib/packages/components/touchchat/img/file/xlsx.png.js +8 -0
  554. package/lib/packages/components/touchchat/img/file/xlsx.png.js.map +1 -0
  555. package/lib/packages/components/touchchat/img/icon.png.js.map +1 -0
  556. package/lib/packages/components/touchchat/img/svg/reset.svg.js +8 -0
  557. package/lib/packages/components/touchchat/img/svg/reset.svg.js.map +1 -0
  558. package/lib/packages/components/touchchat/img/userAvatar.png.js +8 -0
  559. package/lib/packages/components/touchchat/img/userAvatar.png.js.map +1 -0
  560. package/lib/packages/components/touchchat/index.js +5 -5
  561. package/lib/packages/components/touchchat/index.js.map +1 -1
  562. package/lib/packages/components/touchchat/src/AiChat/AgentsView.vue.js +11 -0
  563. package/lib/packages/components/touchchat/src/AiChat/AgentsView.vue.js.map +1 -0
  564. package/lib/packages/components/touchchat/src/AiChat/AgentsView.vue2.js +63 -0
  565. package/lib/packages/components/touchchat/src/AiChat/AgentsView.vue2.js.map +1 -0
  566. package/lib/packages/components/touchchat/src/AiChat/AiMessage.vue2.js +223 -281
  567. package/lib/packages/components/touchchat/src/AiChat/AiMessage.vue2.js.map +1 -1
  568. package/lib/packages/components/touchchat/src/AiChat/Chat/TouchChat.js +21 -0
  569. package/lib/packages/components/touchchat/src/AiChat/Chat/TouchChat.js.map +1 -0
  570. package/lib/packages/components/touchchat/src/AiChat/ChatInput.vue2.js +438 -157
  571. package/lib/packages/components/touchchat/src/AiChat/ChatInput.vue2.js.map +1 -1
  572. package/lib/packages/components/touchchat/src/AiChat/HistoryList.vue2.js +117 -148
  573. package/lib/packages/components/touchchat/src/AiChat/HistoryList.vue2.js.map +1 -1
  574. package/lib/packages/components/touchchat/src/AiChat/HistorySidebar.vue2.js +50 -63
  575. package/lib/packages/components/touchchat/src/AiChat/HistorySidebar.vue2.js.map +1 -1
  576. package/lib/packages/components/touchchat/src/AiChat/MessageActions.vue2.js +126 -226
  577. package/lib/packages/components/touchchat/src/AiChat/MessageActions.vue2.js.map +1 -1
  578. package/lib/packages/components/touchchat/src/AiChat/SiderBarView.vue.js +11 -0
  579. package/lib/packages/components/touchchat/src/AiChat/SiderBarView.vue.js.map +1 -0
  580. package/lib/packages/components/touchchat/src/AiChat/SiderBarView.vue2.js +35 -0
  581. package/lib/packages/components/touchchat/src/AiChat/SiderBarView.vue2.js.map +1 -0
  582. package/lib/packages/components/touchchat/src/AiChat/TouchAgent.vue.js +11 -0
  583. package/lib/packages/components/touchchat/src/AiChat/TouchAgent.vue.js.map +1 -0
  584. package/lib/packages/components/touchchat/src/AiChat/TouchAgent.vue2.js +933 -0
  585. package/lib/packages/components/touchchat/src/AiChat/TouchAgent.vue2.js.map +1 -0
  586. package/lib/packages/components/touchchat/src/AiChat/TouchChat.vue2.js +1067 -520
  587. package/lib/packages/components/touchchat/src/AiChat/TouchChat.vue2.js.map +1 -1
  588. package/lib/packages/components/touchchat/src/AiChat/TouchHistory.vue2.js +364 -135
  589. package/lib/packages/components/touchchat/src/AiChat/TouchHistory.vue2.js.map +1 -1
  590. package/lib/packages/components/touchchat/src/AiChat/UserMessage.vue2.js +128 -65
  591. package/lib/packages/components/touchchat/src/AiChat/UserMessage.vue2.js.map +1 -1
  592. package/lib/packages/components/touchchat/src/index.vue.js +2 -2
  593. package/lib/packages/components/touchchat/src/index.vue2.js +179 -116
  594. package/lib/packages/components/touchchat/src/index.vue2.js.map +1 -1
  595. package/lib/packages/components/touchchat/src/types/a2a.js +13 -0
  596. package/lib/packages/components/touchchat/src/types/a2a.js.map +1 -0
  597. package/lib/packages/components/touchchat/utils/a2aService.js +295 -0
  598. package/lib/packages/components/touchchat/utils/a2aService.js.map +1 -0
  599. package/lib/packages/components/touchchat/utils/fetchStream.js +6 -1
  600. package/lib/packages/components/touchchat/utils/fetchStream.js.map +1 -1
  601. package/lib/packages/components/touchchat/utils/markdown.js +2 -2
  602. package/lib/packages/components/touchchat/utils/markdown.js.map +1 -1
  603. package/lib/packages/utils/config.js.map +1 -1
  604. package/lib/packages/utils/types.js.map +1 -1
  605. package/package.json +81 -81
  606. package/theme/components/index.css +1980 -1684
  607. package/theme/font/iconfont.woff +0 -0
  608. package/theme/font/iconfont.woff2 +0 -0
  609. package/theme/img/aiArrow.png +0 -0
  610. package/theme/img/loading.png +0 -0
  611. package/theme/img/logo.png +0 -0
  612. package/theme/img/userArrow.png +0 -0
  613. package/theme/index.css +1980 -1684
  614. package/theme/skin/default.css +1980 -1684
  615. package/types/global.d.ts +2 -2
  616. package/es/_virtual/emphasis.mjs +0 -4
  617. package/es/_virtual/emphasis.mjs.map +0 -1
  618. package/es/_virtual/html_re.mjs +0 -4
  619. package/es/_virtual/html_re.mjs.map +0 -1
  620. package/es/_virtual/index.mjs +0 -4
  621. package/es/_virtual/index.mjs.map +0 -1
  622. package/es/_virtual/index2.mjs +0 -4
  623. package/es/_virtual/index2.mjs.map +0 -1
  624. package/es/_virtual/index3.mjs +0 -4
  625. package/es/_virtual/index3.mjs.map +0 -1
  626. package/es/_virtual/strikethrough.mjs +0 -4
  627. package/es/_virtual/strikethrough.mjs.map +0 -1
  628. package/es/_virtual/utils.mjs +0 -4
  629. package/es/_virtual/utils.mjs.map +0 -1
  630. package/es/node_modules/.pnpm/entities@2.1.0/node_modules/entities/lib/maps/entities.json.mjs +0 -4253
  631. package/es/node_modules/.pnpm/entities@2.1.0/node_modules/entities/lib/maps/entities.json.mjs.map +0 -1
  632. package/es/node_modules/.pnpm/linkify-it@3.0.3/node_modules/linkify-it/index.mjs +0 -638
  633. package/es/node_modules/.pnpm/linkify-it@3.0.3/node_modules/linkify-it/index.mjs.map +0 -1
  634. package/es/node_modules/.pnpm/linkify-it@3.0.3/node_modules/linkify-it/lib/re.mjs +0 -196
  635. package/es/node_modules/.pnpm/linkify-it@3.0.3/node_modules/linkify-it/lib/re.mjs.map +0 -1
  636. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/index.mjs +0 -9
  637. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/index.mjs.map +0 -1
  638. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/common/entities.mjs +0 -7
  639. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/common/entities.mjs.map +0 -1
  640. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/common/html_blocks.mjs +0 -67
  641. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/common/html_blocks.mjs.map +0 -1
  642. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/common/html_re.mjs +0 -29
  643. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/common/html_re.mjs.map +0 -1
  644. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/common/utils.mjs +0 -324
  645. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/common/utils.mjs.map +0 -1
  646. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/helpers/index.mjs +0 -11
  647. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/helpers/index.mjs.map +0 -1
  648. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/helpers/parse_link_destination.mjs +0 -83
  649. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/helpers/parse_link_destination.mjs.map +0 -1
  650. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/helpers/parse_link_label.mjs +0 -44
  651. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/helpers/parse_link_label.mjs.map +0 -1
  652. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/helpers/parse_link_title.mjs +0 -56
  653. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/helpers/parse_link_title.mjs.map +0 -1
  654. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/index.mjs +0 -596
  655. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/index.mjs.map +0 -1
  656. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/parser_block.mjs +0 -138
  657. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/parser_block.mjs.map +0 -1
  658. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/parser_core.mjs +0 -69
  659. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/parser_core.mjs.map +0 -1
  660. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/parser_inline.mjs +0 -197
  661. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/parser_inline.mjs.map +0 -1
  662. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/presets/commonmark.mjs +0 -78
  663. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/presets/commonmark.mjs.map +0 -1
  664. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/presets/default.mjs +0 -39
  665. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/presets/default.mjs.map +0 -1
  666. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/presets/zero.mjs +0 -59
  667. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/presets/zero.mjs.map +0 -1
  668. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/renderer.mjs +0 -346
  669. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/renderer.mjs.map +0 -1
  670. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/ruler.mjs +0 -354
  671. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/ruler.mjs.map +0 -1
  672. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/blockquote.mjs +0 -286
  673. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/blockquote.mjs.map +0 -1
  674. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/code.mjs +0 -32
  675. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/code.mjs.map +0 -1
  676. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/fence.mjs +0 -96
  677. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/fence.mjs.map +0 -1
  678. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/heading.mjs +0 -57
  679. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/heading.mjs.map +0 -1
  680. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/hr.mjs +0 -47
  681. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/hr.mjs.map +0 -1
  682. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/html_block.mjs +0 -76
  683. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/html_block.mjs.map +0 -1
  684. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/lheading.mjs +0 -81
  685. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/lheading.mjs.map +0 -1
  686. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/list.mjs +0 -366
  687. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/list.mjs.map +0 -1
  688. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/paragraph.mjs +0 -50
  689. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/paragraph.mjs.map +0 -1
  690. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/reference.mjs +0 -197
  691. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/reference.mjs.map +0 -1
  692. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/state_block.mjs +0 -234
  693. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/state_block.mjs.map +0 -1
  694. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/table.mjs +0 -223
  695. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/table.mjs.map +0 -1
  696. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/block.mjs +0 -16
  697. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/block.mjs.map +0 -1
  698. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/inline.mjs +0 -14
  699. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/inline.mjs.map +0 -1
  700. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/linkify.mjs +0 -132
  701. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/linkify.mjs.map +0 -1
  702. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/normalize.mjs +0 -19
  703. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/normalize.mjs.map +0 -1
  704. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/replacements.mjs +0 -97
  705. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/replacements.mjs.map +0 -1
  706. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/smartquotes.mjs +0 -202
  707. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/smartquotes.mjs.map +0 -1
  708. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/state_core.mjs +0 -21
  709. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/state_core.mjs.map +0 -1
  710. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/autolink.mjs +0 -74
  711. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/autolink.mjs.map +0 -1
  712. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/backticks.mjs +0 -61
  713. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/backticks.mjs.map +0 -1
  714. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/balance_pairs.mjs +0 -128
  715. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/balance_pairs.mjs.map +0 -1
  716. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/emphasis.mjs +0 -130
  717. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/emphasis.mjs.map +0 -1
  718. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/entity.mjs +0 -51
  719. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/entity.mjs.map +0 -1
  720. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/escape.mjs +0 -54
  721. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/escape.mjs.map +0 -1
  722. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/html_inline.mjs +0 -48
  723. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/html_inline.mjs.map +0 -1
  724. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/image.mjs +0 -154
  725. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/image.mjs.map +0 -1
  726. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/link.mjs +0 -150
  727. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/link.mjs.map +0 -1
  728. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/newline.mjs +0 -48
  729. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/newline.mjs.map +0 -1
  730. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/state_inline.mjs +0 -156
  731. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/state_inline.mjs.map +0 -1
  732. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/strikethrough.mjs +0 -130
  733. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/strikethrough.mjs.map +0 -1
  734. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/text.mjs +0 -56
  735. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/text.mjs.map +0 -1
  736. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/text_collapse.mjs +0 -33
  737. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/text_collapse.mjs.map +0 -1
  738. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/token.mjs +0 -199
  739. package/es/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/token.mjs.map +0 -1
  740. package/es/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/decode.mjs +0 -121
  741. package/es/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/decode.mjs.map +0 -1
  742. package/es/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/encode.mjs +0 -97
  743. package/es/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/encode.mjs.map +0 -1
  744. package/es/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/format.mjs +0 -24
  745. package/es/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/format.mjs.map +0 -1
  746. package/es/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/index.mjs +0 -13
  747. package/es/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/index.mjs.map +0 -1
  748. package/es/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/parse.mjs +0 -292
  749. package/es/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/parse.mjs.map +0 -1
  750. package/es/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/categories/Cc/regex.mjs +0 -12
  751. package/es/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/categories/Cc/regex.mjs.map +0 -1
  752. package/es/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/categories/Cf/regex.mjs +0 -12
  753. package/es/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/categories/Cf/regex.mjs.map +0 -1
  754. package/es/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/categories/P/regex.mjs +0 -4
  755. package/es/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/categories/P/regex.mjs.map +0 -1
  756. package/es/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/categories/Z/regex.mjs +0 -12
  757. package/es/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/categories/Z/regex.mjs.map +0 -1
  758. package/es/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/index.mjs +0 -23
  759. package/es/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/index.mjs.map +0 -1
  760. package/es/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/properties/Any/regex.mjs +0 -12
  761. package/es/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/properties/Any/regex.mjs.map +0 -1
  762. package/es/packages/components/touchchat/img/AI.png.mjs +0 -4
  763. package/es/packages/components/touchchat/img/AI.png.mjs.map +0 -1
  764. package/es/packages/components/touchchat/img/asir.png.mjs +0 -4
  765. package/es/packages/components/touchchat/img/asir.png.mjs.map +0 -1
  766. package/es/packages/components/touchchat/src/AiRobot/ChatPanel.vue.mjs +0 -7
  767. package/es/packages/components/touchchat/src/AiRobot/ChatPanel.vue.mjs.map +0 -1
  768. package/es/packages/components/touchchat/src/AiRobot/ChatPanel.vue2.mjs +0 -632
  769. package/es/packages/components/touchchat/src/AiRobot/ChatPanel.vue2.mjs.map +0 -1
  770. package/es/packages/components/touchchat/src/AiRobot/Content.vue.mjs +0 -7
  771. package/es/packages/components/touchchat/src/AiRobot/Content.vue.mjs.map +0 -1
  772. package/es/packages/components/touchchat/src/AiRobot/Content.vue2.mjs +0 -263
  773. package/es/packages/components/touchchat/src/AiRobot/Content.vue2.mjs.map +0 -1
  774. package/es/packages/components/touchchat/src/AiRobot/Header.vue.mjs +0 -7
  775. package/es/packages/components/touchchat/src/AiRobot/Header.vue.mjs.map +0 -1
  776. package/es/packages/components/touchchat/src/AiRobot/Header.vue2.mjs +0 -197
  777. package/es/packages/components/touchchat/src/AiRobot/Header.vue2.mjs.map +0 -1
  778. package/es/packages/components/touchchat/src/AiRobot/Input.vue.mjs +0 -7
  779. package/es/packages/components/touchchat/src/AiRobot/Input.vue.mjs.map +0 -1
  780. package/es/packages/components/touchchat/src/AiRobot/Input.vue2.mjs +0 -69
  781. package/es/packages/components/touchchat/src/AiRobot/Input.vue2.mjs.map +0 -1
  782. package/es/packages/components/touchchat/src/AiRobot/Scene.vue.mjs +0 -7
  783. package/es/packages/components/touchchat/src/AiRobot/Scene.vue.mjs.map +0 -1
  784. package/es/packages/components/touchchat/src/AiRobot/Scene.vue2.mjs +0 -48
  785. package/es/packages/components/touchchat/src/AiRobot/Scene.vue2.mjs.map +0 -1
  786. package/es/packages/components/touchchat/src/AiRobot/component/HelloChat.vue.mjs +0 -7
  787. package/es/packages/components/touchchat/src/AiRobot/component/HelloChat.vue2.mjs +0 -270
  788. package/es/packages/components/touchchat/src/AiRobot/component/HelloChat.vue2.mjs.map +0 -1
  789. package/es/packages/components/touchchat/src/AiRobot/component/face.vue.mjs +0 -7
  790. package/es/packages/components/touchchat/src/AiRobot/component/face.vue2.mjs +0 -89
  791. package/es/packages/components/touchchat/src/AiRobot/component/face.vue2.mjs.map +0 -1
  792. package/es/packages/components/touchchat/src/AiRobot/component/letter.vue.mjs +0 -7
  793. package/es/packages/components/touchchat/src/AiRobot/component/letter.vue2.mjs +0 -64
  794. package/es/packages/components/touchchat/src/AiRobot/component/letter.vue2.mjs.map +0 -1
  795. package/es/packages/components/touchchat/src/AiRobot/component/meterialPrepare.vue.mjs +0 -7
  796. package/es/packages/components/touchchat/src/AiRobot/component/meterialPrepare.vue2.mjs +0 -36
  797. package/es/packages/components/touchchat/src/AiRobot/component/meterialPrepare.vue2.mjs.map +0 -1
  798. package/es/packages/components/touchchat/src/AiRobot/component/start.vue.mjs +0 -7
  799. package/es/packages/components/touchchat/src/AiRobot/component/start.vue2.mjs +0 -36
  800. package/es/packages/components/touchchat/src/AiRobot/component/start.vue2.mjs.map +0 -1
  801. package/es/packages/components/touchchat/src/AiRobot/img/Avatar-AI.png.mjs +0 -4
  802. package/es/packages/components/touchchat/src/AiRobot/img/Avatar-AI.png.mjs.map +0 -1
  803. package/es/packages/components/touchchat/src/AiRobot/img/icon.png.mjs.map +0 -1
  804. package/es/packages/components/touchchat/src/AiRobot/index.vue.mjs +0 -7
  805. package/es/packages/components/touchchat/src/AiRobot/index.vue.mjs.map +0 -1
  806. package/es/packages/components/touchchat/src/AiRobot/index.vue2.mjs +0 -135
  807. package/es/packages/components/touchchat/src/AiRobot/index.vue2.mjs.map +0 -1
  808. package/lib/_virtual/emphasis.js +0 -6
  809. package/lib/_virtual/emphasis.js.map +0 -1
  810. package/lib/_virtual/html_re.js +0 -6
  811. package/lib/_virtual/html_re.js.map +0 -1
  812. package/lib/_virtual/index.js +0 -6
  813. package/lib/_virtual/index.js.map +0 -1
  814. package/lib/_virtual/index2.js +0 -6
  815. package/lib/_virtual/index2.js.map +0 -1
  816. package/lib/_virtual/index3.js +0 -6
  817. package/lib/_virtual/index3.js.map +0 -1
  818. package/lib/_virtual/strikethrough.js +0 -6
  819. package/lib/_virtual/strikethrough.js.map +0 -1
  820. package/lib/_virtual/utils.js +0 -6
  821. package/lib/_virtual/utils.js.map +0 -1
  822. package/lib/node_modules/.pnpm/entities@2.1.0/node_modules/entities/lib/maps/entities.json.js +0 -6380
  823. package/lib/node_modules/.pnpm/entities@2.1.0/node_modules/entities/lib/maps/entities.json.js.map +0 -1
  824. package/lib/node_modules/.pnpm/linkify-it@3.0.3/node_modules/linkify-it/index.js +0 -640
  825. package/lib/node_modules/.pnpm/linkify-it@3.0.3/node_modules/linkify-it/index.js.map +0 -1
  826. package/lib/node_modules/.pnpm/linkify-it@3.0.3/node_modules/linkify-it/lib/re.js +0 -198
  827. package/lib/node_modules/.pnpm/linkify-it@3.0.3/node_modules/linkify-it/lib/re.js.map +0 -1
  828. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/index.js +0 -13
  829. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/index.js.map +0 -1
  830. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/common/entities.js +0 -9
  831. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/common/entities.js.map +0 -1
  832. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/common/html_blocks.js +0 -69
  833. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/common/html_blocks.js.map +0 -1
  834. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/common/html_re.js +0 -33
  835. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/common/html_re.js.map +0 -1
  836. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/common/utils.js +0 -326
  837. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/common/utils.js.map +0 -1
  838. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/helpers/index.js +0 -15
  839. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/helpers/index.js.map +0 -1
  840. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/helpers/parse_link_destination.js +0 -85
  841. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/helpers/parse_link_destination.js.map +0 -1
  842. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/helpers/parse_link_label.js +0 -46
  843. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/helpers/parse_link_label.js.map +0 -1
  844. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/helpers/parse_link_title.js +0 -58
  845. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/helpers/parse_link_title.js.map +0 -1
  846. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/index.js +0 -598
  847. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/index.js.map +0 -1
  848. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/parser_block.js +0 -140
  849. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/parser_block.js.map +0 -1
  850. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/parser_core.js +0 -71
  851. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/parser_core.js.map +0 -1
  852. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/parser_inline.js +0 -199
  853. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/parser_inline.js.map +0 -1
  854. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/presets/commonmark.js +0 -80
  855. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/presets/commonmark.js.map +0 -1
  856. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/presets/default.js +0 -41
  857. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/presets/default.js.map +0 -1
  858. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/presets/zero.js +0 -61
  859. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/presets/zero.js.map +0 -1
  860. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/renderer.js +0 -348
  861. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/renderer.js.map +0 -1
  862. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/ruler.js +0 -356
  863. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/ruler.js.map +0 -1
  864. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/blockquote.js +0 -288
  865. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/blockquote.js.map +0 -1
  866. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/code.js +0 -34
  867. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/code.js.map +0 -1
  868. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/fence.js +0 -98
  869. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/fence.js.map +0 -1
  870. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/heading.js +0 -59
  871. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/heading.js.map +0 -1
  872. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/hr.js +0 -49
  873. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/hr.js.map +0 -1
  874. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/html_block.js +0 -78
  875. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/html_block.js.map +0 -1
  876. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/lheading.js +0 -83
  877. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/lheading.js.map +0 -1
  878. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/list.js +0 -368
  879. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/list.js.map +0 -1
  880. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/paragraph.js +0 -52
  881. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/paragraph.js.map +0 -1
  882. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/reference.js +0 -199
  883. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/reference.js.map +0 -1
  884. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/state_block.js +0 -236
  885. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/state_block.js.map +0 -1
  886. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/table.js +0 -225
  887. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_block/table.js.map +0 -1
  888. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/block.js +0 -18
  889. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/block.js.map +0 -1
  890. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/inline.js +0 -16
  891. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/inline.js.map +0 -1
  892. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/linkify.js +0 -134
  893. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/linkify.js.map +0 -1
  894. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/normalize.js +0 -21
  895. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/normalize.js.map +0 -1
  896. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/replacements.js +0 -99
  897. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/replacements.js.map +0 -1
  898. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/smartquotes.js +0 -204
  899. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/smartquotes.js.map +0 -1
  900. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/state_core.js +0 -23
  901. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_core/state_core.js.map +0 -1
  902. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/autolink.js +0 -76
  903. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/autolink.js.map +0 -1
  904. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/backticks.js +0 -63
  905. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/backticks.js.map +0 -1
  906. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/balance_pairs.js +0 -130
  907. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/balance_pairs.js.map +0 -1
  908. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/emphasis.js +0 -134
  909. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/emphasis.js.map +0 -1
  910. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/entity.js +0 -53
  911. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/entity.js.map +0 -1
  912. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/escape.js +0 -56
  913. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/escape.js.map +0 -1
  914. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/html_inline.js +0 -50
  915. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/html_inline.js.map +0 -1
  916. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/image.js +0 -156
  917. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/image.js.map +0 -1
  918. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/link.js +0 -152
  919. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/link.js.map +0 -1
  920. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/newline.js +0 -50
  921. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/newline.js.map +0 -1
  922. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/state_inline.js +0 -158
  923. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/state_inline.js.map +0 -1
  924. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/strikethrough.js +0 -134
  925. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/strikethrough.js.map +0 -1
  926. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/text.js +0 -58
  927. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/text.js.map +0 -1
  928. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/text_collapse.js +0 -35
  929. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/rules_inline/text_collapse.js.map +0 -1
  930. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/token.js +0 -201
  931. package/lib/node_modules/.pnpm/markdown-it@12.3.2/node_modules/markdown-it/lib/token.js.map +0 -1
  932. package/lib/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/decode.js +0 -123
  933. package/lib/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/decode.js.map +0 -1
  934. package/lib/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/encode.js +0 -99
  935. package/lib/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/encode.js.map +0 -1
  936. package/lib/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/format.js +0 -26
  937. package/lib/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/format.js.map +0 -1
  938. package/lib/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/index.js +0 -17
  939. package/lib/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/index.js.map +0 -1
  940. package/lib/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/parse.js +0 -294
  941. package/lib/node_modules/.pnpm/mdurl@1.0.1/node_modules/mdurl/parse.js.map +0 -1
  942. package/lib/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/categories/Cc/regex.js +0 -14
  943. package/lib/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/categories/Cc/regex.js.map +0 -1
  944. package/lib/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/categories/Cf/regex.js +0 -14
  945. package/lib/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/categories/Cf/regex.js.map +0 -1
  946. package/lib/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/categories/P/regex.js +0 -6
  947. package/lib/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/categories/P/regex.js.map +0 -1
  948. package/lib/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/categories/Z/regex.js +0 -14
  949. package/lib/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/categories/Z/regex.js.map +0 -1
  950. package/lib/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/index.js +0 -25
  951. package/lib/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/index.js.map +0 -1
  952. package/lib/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/properties/Any/regex.js +0 -14
  953. package/lib/node_modules/.pnpm/uc.micro@1.0.6/node_modules/uc.micro/properties/Any/regex.js.map +0 -1
  954. package/lib/packages/components/touchchat/img/AI.png.js +0 -8
  955. package/lib/packages/components/touchchat/img/AI.png.js.map +0 -1
  956. package/lib/packages/components/touchchat/img/asir.png.js +0 -8
  957. package/lib/packages/components/touchchat/img/asir.png.js.map +0 -1
  958. package/lib/packages/components/touchchat/src/AiRobot/ChatPanel.vue.js +0 -11
  959. package/lib/packages/components/touchchat/src/AiRobot/ChatPanel.vue.js.map +0 -1
  960. package/lib/packages/components/touchchat/src/AiRobot/ChatPanel.vue2.js +0 -636
  961. package/lib/packages/components/touchchat/src/AiRobot/ChatPanel.vue2.js.map +0 -1
  962. package/lib/packages/components/touchchat/src/AiRobot/Content.vue.js +0 -11
  963. package/lib/packages/components/touchchat/src/AiRobot/Content.vue.js.map +0 -1
  964. package/lib/packages/components/touchchat/src/AiRobot/Content.vue2.js +0 -267
  965. package/lib/packages/components/touchchat/src/AiRobot/Content.vue2.js.map +0 -1
  966. package/lib/packages/components/touchchat/src/AiRobot/Header.vue.js +0 -11
  967. package/lib/packages/components/touchchat/src/AiRobot/Header.vue.js.map +0 -1
  968. package/lib/packages/components/touchchat/src/AiRobot/Header.vue2.js +0 -201
  969. package/lib/packages/components/touchchat/src/AiRobot/Header.vue2.js.map +0 -1
  970. package/lib/packages/components/touchchat/src/AiRobot/Input.vue.js +0 -11
  971. package/lib/packages/components/touchchat/src/AiRobot/Input.vue.js.map +0 -1
  972. package/lib/packages/components/touchchat/src/AiRobot/Input.vue2.js +0 -73
  973. package/lib/packages/components/touchchat/src/AiRobot/Input.vue2.js.map +0 -1
  974. package/lib/packages/components/touchchat/src/AiRobot/Scene.vue.js +0 -11
  975. package/lib/packages/components/touchchat/src/AiRobot/Scene.vue.js.map +0 -1
  976. package/lib/packages/components/touchchat/src/AiRobot/Scene.vue2.js +0 -52
  977. package/lib/packages/components/touchchat/src/AiRobot/Scene.vue2.js.map +0 -1
  978. package/lib/packages/components/touchchat/src/AiRobot/component/HelloChat.vue.js +0 -11
  979. package/lib/packages/components/touchchat/src/AiRobot/component/HelloChat.vue2.js +0 -274
  980. package/lib/packages/components/touchchat/src/AiRobot/component/HelloChat.vue2.js.map +0 -1
  981. package/lib/packages/components/touchchat/src/AiRobot/component/face.vue.js +0 -11
  982. package/lib/packages/components/touchchat/src/AiRobot/component/face.vue2.js +0 -93
  983. package/lib/packages/components/touchchat/src/AiRobot/component/face.vue2.js.map +0 -1
  984. package/lib/packages/components/touchchat/src/AiRobot/component/letter.vue.js +0 -11
  985. package/lib/packages/components/touchchat/src/AiRobot/component/letter.vue2.js +0 -68
  986. package/lib/packages/components/touchchat/src/AiRobot/component/letter.vue2.js.map +0 -1
  987. package/lib/packages/components/touchchat/src/AiRobot/component/meterialPrepare.vue.js +0 -11
  988. package/lib/packages/components/touchchat/src/AiRobot/component/meterialPrepare.vue2.js +0 -40
  989. package/lib/packages/components/touchchat/src/AiRobot/component/meterialPrepare.vue2.js.map +0 -1
  990. package/lib/packages/components/touchchat/src/AiRobot/component/start.vue.js +0 -11
  991. package/lib/packages/components/touchchat/src/AiRobot/component/start.vue2.js +0 -40
  992. package/lib/packages/components/touchchat/src/AiRobot/component/start.vue2.js.map +0 -1
  993. package/lib/packages/components/touchchat/src/AiRobot/img/Avatar-AI.png.js +0 -8
  994. package/lib/packages/components/touchchat/src/AiRobot/img/Avatar-AI.png.js.map +0 -1
  995. package/lib/packages/components/touchchat/src/AiRobot/img/icon.png.js.map +0 -1
  996. package/lib/packages/components/touchchat/src/AiRobot/index.vue.js +0 -11
  997. package/lib/packages/components/touchchat/src/AiRobot/index.vue.js.map +0 -1
  998. package/lib/packages/components/touchchat/src/AiRobot/index.vue2.js +0 -139
  999. package/lib/packages/components/touchchat/src/AiRobot/index.vue2.js.map +0 -1
  1000. package/theme/img/default.png +0 -0
  1001. /package/es/packages/components/touchchat/{src/AiRobot/component → component/AiRobot}/HelloChat.vue.mjs.map +0 -0
  1002. /package/es/packages/components/touchchat/{src/AiRobot/component → component/AiRobot}/face.vue.mjs.map +0 -0
  1003. /package/es/packages/components/touchchat/{src/AiRobot/component → component/AiRobot}/letter.vue.mjs.map +0 -0
  1004. /package/es/packages/components/touchchat/{src/AiRobot/component → component/AiRobot}/meterialPrepare.vue.mjs.map +0 -0
  1005. /package/es/packages/components/touchchat/{src/AiRobot/component → component/AiRobot}/start.vue.mjs.map +0 -0
  1006. /package/es/packages/components/touchchat/{src/AiRobot/img → img}/icon.png.mjs +0 -0
  1007. /package/lib/packages/components/touchchat/{src/AiRobot/component → component/AiRobot}/HelloChat.vue.js.map +0 -0
  1008. /package/lib/packages/components/touchchat/{src/AiRobot/component → component/AiRobot}/face.vue.js.map +0 -0
  1009. /package/lib/packages/components/touchchat/{src/AiRobot/component → component/AiRobot}/letter.vue.js.map +0 -0
  1010. /package/lib/packages/components/touchchat/{src/AiRobot/component → component/AiRobot}/meterialPrepare.vue.js.map +0 -0
  1011. /package/lib/packages/components/touchchat/{src/AiRobot/component → component/AiRobot}/start.vue.js.map +0 -0
  1012. /package/lib/packages/components/touchchat/{src/AiRobot/img → img}/icon.png.js +0 -0
@@ -0,0 +1,1380 @@
1
+ /*! @license DOMPurify 3.3.0 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.3.0/LICENSE */
2
+
3
+ const {
4
+ entries,
5
+ setPrototypeOf,
6
+ isFrozen,
7
+ getPrototypeOf,
8
+ getOwnPropertyDescriptor
9
+ } = Object;
10
+ let {
11
+ freeze,
12
+ seal,
13
+ create
14
+ } = Object; // eslint-disable-line import/no-mutable-exports
15
+ let {
16
+ apply,
17
+ construct
18
+ } = typeof Reflect !== 'undefined' && Reflect;
19
+ if (!freeze) {
20
+ freeze = function freeze(x) {
21
+ return x;
22
+ };
23
+ }
24
+ if (!seal) {
25
+ seal = function seal(x) {
26
+ return x;
27
+ };
28
+ }
29
+ if (!apply) {
30
+ apply = function apply(func, thisArg) {
31
+ for (var _len = arguments.length, args = new Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) {
32
+ args[_key - 2] = arguments[_key];
33
+ }
34
+ return func.apply(thisArg, args);
35
+ };
36
+ }
37
+ if (!construct) {
38
+ construct = function construct(Func) {
39
+ for (var _len2 = arguments.length, args = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
40
+ args[_key2 - 1] = arguments[_key2];
41
+ }
42
+ return new Func(...args);
43
+ };
44
+ }
45
+ const arrayForEach = unapply(Array.prototype.forEach);
46
+ const arrayLastIndexOf = unapply(Array.prototype.lastIndexOf);
47
+ const arrayPop = unapply(Array.prototype.pop);
48
+ const arrayPush = unapply(Array.prototype.push);
49
+ const arraySplice = unapply(Array.prototype.splice);
50
+ const stringToLowerCase = unapply(String.prototype.toLowerCase);
51
+ const stringToString = unapply(String.prototype.toString);
52
+ const stringMatch = unapply(String.prototype.match);
53
+ const stringReplace = unapply(String.prototype.replace);
54
+ const stringIndexOf = unapply(String.prototype.indexOf);
55
+ const stringTrim = unapply(String.prototype.trim);
56
+ const objectHasOwnProperty = unapply(Object.prototype.hasOwnProperty);
57
+ const regExpTest = unapply(RegExp.prototype.test);
58
+ const typeErrorCreate = unconstruct(TypeError);
59
+ /**
60
+ * Creates a new function that calls the given function with a specified thisArg and arguments.
61
+ *
62
+ * @param func - The function to be wrapped and called.
63
+ * @returns A new function that calls the given function with a specified thisArg and arguments.
64
+ */
65
+ function unapply(func) {
66
+ return function (thisArg) {
67
+ if (thisArg instanceof RegExp) {
68
+ thisArg.lastIndex = 0;
69
+ }
70
+ for (var _len3 = arguments.length, args = new Array(_len3 > 1 ? _len3 - 1 : 0), _key3 = 1; _key3 < _len3; _key3++) {
71
+ args[_key3 - 1] = arguments[_key3];
72
+ }
73
+ return apply(func, thisArg, args);
74
+ };
75
+ }
76
+ /**
77
+ * Creates a new function that constructs an instance of the given constructor function with the provided arguments.
78
+ *
79
+ * @param func - The constructor function to be wrapped and called.
80
+ * @returns A new function that constructs an instance of the given constructor function with the provided arguments.
81
+ */
82
+ function unconstruct(Func) {
83
+ return function () {
84
+ for (var _len4 = arguments.length, args = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {
85
+ args[_key4] = arguments[_key4];
86
+ }
87
+ return construct(Func, args);
88
+ };
89
+ }
90
+ /**
91
+ * Add properties to a lookup table
92
+ *
93
+ * @param set - The set to which elements will be added.
94
+ * @param array - The array containing elements to be added to the set.
95
+ * @param transformCaseFunc - An optional function to transform the case of each element before adding to the set.
96
+ * @returns The modified set with added elements.
97
+ */
98
+ function addToSet(set, array) {
99
+ let transformCaseFunc = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : stringToLowerCase;
100
+ if (setPrototypeOf) {
101
+ // Make 'in' and truthy checks like Boolean(set.constructor)
102
+ // independent of any properties defined on Object.prototype.
103
+ // Prevent prototype setters from intercepting set as a this value.
104
+ setPrototypeOf(set, null);
105
+ }
106
+ let l = array.length;
107
+ while (l--) {
108
+ let element = array[l];
109
+ if (typeof element === 'string') {
110
+ const lcElement = transformCaseFunc(element);
111
+ if (lcElement !== element) {
112
+ // Config presets (e.g. tags.js, attrs.js) are immutable.
113
+ if (!isFrozen(array)) {
114
+ array[l] = lcElement;
115
+ }
116
+ element = lcElement;
117
+ }
118
+ }
119
+ set[element] = true;
120
+ }
121
+ return set;
122
+ }
123
+ /**
124
+ * Clean up an array to harden against CSPP
125
+ *
126
+ * @param array - The array to be cleaned.
127
+ * @returns The cleaned version of the array
128
+ */
129
+ function cleanArray(array) {
130
+ for (let index = 0; index < array.length; index++) {
131
+ const isPropertyExist = objectHasOwnProperty(array, index);
132
+ if (!isPropertyExist) {
133
+ array[index] = null;
134
+ }
135
+ }
136
+ return array;
137
+ }
138
+ /**
139
+ * Shallow clone an object
140
+ *
141
+ * @param object - The object to be cloned.
142
+ * @returns A new object that copies the original.
143
+ */
144
+ function clone(object) {
145
+ const newObject = create(null);
146
+ for (const [property, value] of entries(object)) {
147
+ const isPropertyExist = objectHasOwnProperty(object, property);
148
+ if (isPropertyExist) {
149
+ if (Array.isArray(value)) {
150
+ newObject[property] = cleanArray(value);
151
+ } else if (value && typeof value === 'object' && value.constructor === Object) {
152
+ newObject[property] = clone(value);
153
+ } else {
154
+ newObject[property] = value;
155
+ }
156
+ }
157
+ }
158
+ return newObject;
159
+ }
160
+ /**
161
+ * This method automatically checks if the prop is function or getter and behaves accordingly.
162
+ *
163
+ * @param object - The object to look up the getter function in its prototype chain.
164
+ * @param prop - The property name for which to find the getter function.
165
+ * @returns The getter function found in the prototype chain or a fallback function.
166
+ */
167
+ function lookupGetter(object, prop) {
168
+ while (object !== null) {
169
+ const desc = getOwnPropertyDescriptor(object, prop);
170
+ if (desc) {
171
+ if (desc.get) {
172
+ return unapply(desc.get);
173
+ }
174
+ if (typeof desc.value === 'function') {
175
+ return unapply(desc.value);
176
+ }
177
+ }
178
+ object = getPrototypeOf(object);
179
+ }
180
+ function fallbackValue() {
181
+ return null;
182
+ }
183
+ return fallbackValue;
184
+ }
185
+
186
+ const html$1 = freeze(['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']);
187
+ const svg$1 = freeze(['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']);
188
+ const svgFilters = freeze(['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']);
189
+ // List of SVG elements that are disallowed by default.
190
+ // We still need to know them so that we can do namespace
191
+ // checks properly in case one wants to add them to
192
+ // allow-list.
193
+ const svgDisallowed = freeze(['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']);
194
+ const mathMl$1 = freeze(['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']);
195
+ // Similarly to SVG, we want to know all MathML elements,
196
+ // even those that we disallow by default.
197
+ const mathMlDisallowed = freeze(['maction', 'maligngroup', 'malignmark', 'mlongdiv', 'mscarries', 'mscarry', 'msgroup', 'mstack', 'msline', 'msrow', 'semantics', 'annotation', 'annotation-xml', 'mprescripts', 'none']);
198
+ const text = freeze(['#text']);
199
+
200
+ const html = freeze(['accept', 'action', 'align', 'alt', 'autocapitalize', 'autocomplete', 'autopictureinpicture', 'autoplay', 'background', 'bgcolor', 'border', 'capture', 'cellpadding', 'cellspacing', 'checked', 'cite', 'class', 'clear', 'color', 'cols', 'colspan', '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', 'slot']);
201
+ const svg = freeze(['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']);
202
+ const mathMl = freeze(['accent', 'accentunder', 'align', 'bevelled', 'close', 'columnsalign', 'columnlines', 'columnspan', 'denomalign', 'depth', 'dir', 'display', 'displaystyle', 'encoding', 'fence', 'frame', 'height', 'href', 'id', 'largeop', 'length', 'linethickness', 'lspace', 'lquote', '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']);
203
+ const xml = freeze(['xlink:href', 'xml:id', 'xlink:title', 'xml:space', 'xmlns:xlink']);
204
+
205
+ // eslint-disable-next-line unicorn/better-regex
206
+ const MUSTACHE_EXPR = seal(/\{\{[\w\W]*|[\w\W]*\}\}/gm); // Specify template detection regex for SAFE_FOR_TEMPLATES mode
207
+ const ERB_EXPR = seal(/<%[\w\W]*|[\w\W]*%>/gm);
208
+ const TMPLIT_EXPR = seal(/\$\{[\w\W]*/gm); // eslint-disable-line unicorn/better-regex
209
+ const DATA_ATTR = seal(/^data-[\-\w.\u00B7-\uFFFF]+$/); // eslint-disable-line no-useless-escape
210
+ const ARIA_ATTR = seal(/^aria-[\-\w]+$/); // eslint-disable-line no-useless-escape
211
+ const IS_ALLOWED_URI = seal(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i // eslint-disable-line no-useless-escape
212
+ );
213
+ const IS_SCRIPT_OR_DATA = seal(/^(?:\w+script|data):/i);
214
+ const ATTR_WHITESPACE = seal(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g // eslint-disable-line no-control-regex
215
+ );
216
+ const DOCTYPE_NAME = seal(/^html$/i);
217
+ const CUSTOM_ELEMENT = seal(/^[a-z][.\w]*(-[.\w]+)+$/i);
218
+
219
+ var EXPRESSIONS = /*#__PURE__*/Object.freeze({
220
+ __proto__: null,
221
+ ARIA_ATTR: ARIA_ATTR,
222
+ ATTR_WHITESPACE: ATTR_WHITESPACE,
223
+ CUSTOM_ELEMENT: CUSTOM_ELEMENT,
224
+ DATA_ATTR: DATA_ATTR,
225
+ DOCTYPE_NAME: DOCTYPE_NAME,
226
+ ERB_EXPR: ERB_EXPR,
227
+ IS_ALLOWED_URI: IS_ALLOWED_URI,
228
+ IS_SCRIPT_OR_DATA: IS_SCRIPT_OR_DATA,
229
+ MUSTACHE_EXPR: MUSTACHE_EXPR,
230
+ TMPLIT_EXPR: TMPLIT_EXPR
231
+ });
232
+
233
+ /* eslint-disable @typescript-eslint/indent */
234
+ // https://developer.mozilla.org/en-US/docs/Web/API/Node/nodeType
235
+ const NODE_TYPE = {
236
+ element: 1,
237
+ attribute: 2,
238
+ text: 3,
239
+ cdataSection: 4,
240
+ entityReference: 5,
241
+ // Deprecated
242
+ entityNode: 6,
243
+ // Deprecated
244
+ progressingInstruction: 7,
245
+ comment: 8,
246
+ document: 9,
247
+ documentType: 10,
248
+ documentFragment: 11,
249
+ notation: 12 // Deprecated
250
+ };
251
+ const getGlobal = function getGlobal() {
252
+ return typeof window === 'undefined' ? null : window;
253
+ };
254
+ /**
255
+ * Creates a no-op policy for internal use only.
256
+ * Don't export this function outside this module!
257
+ * @param trustedTypes The policy factory.
258
+ * @param purifyHostElement The Script element used to load DOMPurify (to determine policy name suffix).
259
+ * @return The policy created (or null, if Trusted Types
260
+ * are not supported or creating the policy failed).
261
+ */
262
+ const _createTrustedTypesPolicy = function _createTrustedTypesPolicy(trustedTypes, purifyHostElement) {
263
+ if (typeof trustedTypes !== 'object' || typeof trustedTypes.createPolicy !== 'function') {
264
+ return null;
265
+ }
266
+ // Allow the callers to control the unique policy name
267
+ // by adding a data-tt-policy-suffix to the script element with the DOMPurify.
268
+ // Policy creation with duplicate names throws in Trusted Types.
269
+ let suffix = null;
270
+ const ATTR_NAME = 'data-tt-policy-suffix';
271
+ if (purifyHostElement && purifyHostElement.hasAttribute(ATTR_NAME)) {
272
+ suffix = purifyHostElement.getAttribute(ATTR_NAME);
273
+ }
274
+ const policyName = 'dompurify' + (suffix ? '#' + suffix : '');
275
+ try {
276
+ return trustedTypes.createPolicy(policyName, {
277
+ createHTML(html) {
278
+ return html;
279
+ },
280
+ createScriptURL(scriptUrl) {
281
+ return scriptUrl;
282
+ }
283
+ });
284
+ } catch (_) {
285
+ // Policy creation failed (most likely another DOMPurify script has
286
+ // already run). Skip creating the policy, as this will only cause errors
287
+ // if TT are enforced.
288
+ console.warn('TrustedTypes policy ' + policyName + ' could not be created.');
289
+ return null;
290
+ }
291
+ };
292
+ const _createHooksMap = function _createHooksMap() {
293
+ return {
294
+ afterSanitizeAttributes: [],
295
+ afterSanitizeElements: [],
296
+ afterSanitizeShadowDOM: [],
297
+ beforeSanitizeAttributes: [],
298
+ beforeSanitizeElements: [],
299
+ beforeSanitizeShadowDOM: [],
300
+ uponSanitizeAttribute: [],
301
+ uponSanitizeElement: [],
302
+ uponSanitizeShadowNode: []
303
+ };
304
+ };
305
+ function createDOMPurify() {
306
+ let window = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : getGlobal();
307
+ const DOMPurify = root => createDOMPurify(root);
308
+ DOMPurify.version = '3.3.0';
309
+ DOMPurify.removed = [];
310
+ if (!window || !window.document || window.document.nodeType !== NODE_TYPE.document || !window.Element) {
311
+ // Not running in a browser, provide a factory function
312
+ // so that you can pass your own Window
313
+ DOMPurify.isSupported = false;
314
+ return DOMPurify;
315
+ }
316
+ let {
317
+ document
318
+ } = window;
319
+ const originalDocument = document;
320
+ const currentScript = originalDocument.currentScript;
321
+ const {
322
+ DocumentFragment,
323
+ HTMLTemplateElement,
324
+ Node,
325
+ Element,
326
+ NodeFilter,
327
+ NamedNodeMap = window.NamedNodeMap || window.MozNamedAttrMap,
328
+ HTMLFormElement,
329
+ DOMParser,
330
+ trustedTypes
331
+ } = window;
332
+ const ElementPrototype = Element.prototype;
333
+ const cloneNode = lookupGetter(ElementPrototype, 'cloneNode');
334
+ const remove = lookupGetter(ElementPrototype, 'remove');
335
+ const getNextSibling = lookupGetter(ElementPrototype, 'nextSibling');
336
+ const getChildNodes = lookupGetter(ElementPrototype, 'childNodes');
337
+ const getParentNode = lookupGetter(ElementPrototype, 'parentNode');
338
+ // As per issue #47, the web-components registry is inherited by a
339
+ // new document created via createHTMLDocument. As per the spec
340
+ // (http://w3c.github.io/webcomponents/spec/custom/#creating-and-passing-registries)
341
+ // a new empty registry is used when creating a template contents owner
342
+ // document, so we use that as our parent document to ensure nothing
343
+ // is inherited.
344
+ if (typeof HTMLTemplateElement === 'function') {
345
+ const template = document.createElement('template');
346
+ if (template.content && template.content.ownerDocument) {
347
+ document = template.content.ownerDocument;
348
+ }
349
+ }
350
+ let trustedTypesPolicy;
351
+ let emptyHTML = '';
352
+ const {
353
+ implementation,
354
+ createNodeIterator,
355
+ createDocumentFragment,
356
+ getElementsByTagName
357
+ } = document;
358
+ const {
359
+ importNode
360
+ } = originalDocument;
361
+ let hooks = _createHooksMap();
362
+ /**
363
+ * Expose whether this browser supports running the full DOMPurify.
364
+ */
365
+ DOMPurify.isSupported = typeof entries === 'function' && typeof getParentNode === 'function' && implementation && implementation.createHTMLDocument !== undefined;
366
+ const {
367
+ MUSTACHE_EXPR,
368
+ ERB_EXPR,
369
+ TMPLIT_EXPR,
370
+ DATA_ATTR,
371
+ ARIA_ATTR,
372
+ IS_SCRIPT_OR_DATA,
373
+ ATTR_WHITESPACE,
374
+ CUSTOM_ELEMENT
375
+ } = EXPRESSIONS;
376
+ let {
377
+ IS_ALLOWED_URI: IS_ALLOWED_URI$1
378
+ } = EXPRESSIONS;
379
+ /**
380
+ * We consider the elements and attributes below to be safe. Ideally
381
+ * don't add any new ones but feel free to remove unwanted ones.
382
+ */
383
+ /* allowed element names */
384
+ let ALLOWED_TAGS = null;
385
+ const DEFAULT_ALLOWED_TAGS = addToSet({}, [...html$1, ...svg$1, ...svgFilters, ...mathMl$1, ...text]);
386
+ /* Allowed attribute names */
387
+ let ALLOWED_ATTR = null;
388
+ const DEFAULT_ALLOWED_ATTR = addToSet({}, [...html, ...svg, ...mathMl, ...xml]);
389
+ /*
390
+ * Configure how DOMPurify should handle custom elements and their attributes as well as customized built-in elements.
391
+ * @property {RegExp|Function|null} tagNameCheck one of [null, regexPattern, predicate]. Default: `null` (disallow any custom elements)
392
+ * @property {RegExp|Function|null} attributeNameCheck one of [null, regexPattern, predicate]. Default: `null` (disallow any attributes not on the allow list)
393
+ * @property {boolean} allowCustomizedBuiltInElements allow custom elements derived from built-ins if they pass CUSTOM_ELEMENT_HANDLING.tagNameCheck. Default: `false`.
394
+ */
395
+ let CUSTOM_ELEMENT_HANDLING = Object.seal(create(null, {
396
+ tagNameCheck: {
397
+ writable: true,
398
+ configurable: false,
399
+ enumerable: true,
400
+ value: null
401
+ },
402
+ attributeNameCheck: {
403
+ writable: true,
404
+ configurable: false,
405
+ enumerable: true,
406
+ value: null
407
+ },
408
+ allowCustomizedBuiltInElements: {
409
+ writable: true,
410
+ configurable: false,
411
+ enumerable: true,
412
+ value: false
413
+ }
414
+ }));
415
+ /* Explicitly forbidden tags (overrides ALLOWED_TAGS/ADD_TAGS) */
416
+ let FORBID_TAGS = null;
417
+ /* Explicitly forbidden attributes (overrides ALLOWED_ATTR/ADD_ATTR) */
418
+ let FORBID_ATTR = null;
419
+ /* Config object to store ADD_TAGS/ADD_ATTR functions (when used as functions) */
420
+ const EXTRA_ELEMENT_HANDLING = Object.seal(create(null, {
421
+ tagCheck: {
422
+ writable: true,
423
+ configurable: false,
424
+ enumerable: true,
425
+ value: null
426
+ },
427
+ attributeCheck: {
428
+ writable: true,
429
+ configurable: false,
430
+ enumerable: true,
431
+ value: null
432
+ }
433
+ }));
434
+ /* Decide if ARIA attributes are okay */
435
+ let ALLOW_ARIA_ATTR = true;
436
+ /* Decide if custom data attributes are okay */
437
+ let ALLOW_DATA_ATTR = true;
438
+ /* Decide if unknown protocols are okay */
439
+ let ALLOW_UNKNOWN_PROTOCOLS = false;
440
+ /* Decide if self-closing tags in attributes are allowed.
441
+ * Usually removed due to a mXSS issue in jQuery 3.0 */
442
+ let ALLOW_SELF_CLOSE_IN_ATTR = true;
443
+ /* Output should be safe for common template engines.
444
+ * This means, DOMPurify removes data attributes, mustaches and ERB
445
+ */
446
+ let SAFE_FOR_TEMPLATES = false;
447
+ /* Output should be safe even for XML used within HTML and alike.
448
+ * This means, DOMPurify removes comments when containing risky content.
449
+ */
450
+ let SAFE_FOR_XML = true;
451
+ /* Decide if document with <html>... should be returned */
452
+ let WHOLE_DOCUMENT = false;
453
+ /* Track whether config is already set on this instance of DOMPurify. */
454
+ let SET_CONFIG = false;
455
+ /* Decide if all elements (e.g. style, script) must be children of
456
+ * document.body. By default, browsers might move them to document.head */
457
+ let FORCE_BODY = false;
458
+ /* Decide if a DOM `HTMLBodyElement` should be returned, instead of a html
459
+ * string (or a TrustedHTML object if Trusted Types are supported).
460
+ * If `WHOLE_DOCUMENT` is enabled a `HTMLHtmlElement` will be returned instead
461
+ */
462
+ let RETURN_DOM = false;
463
+ /* Decide if a DOM `DocumentFragment` should be returned, instead of a html
464
+ * string (or a TrustedHTML object if Trusted Types are supported) */
465
+ let RETURN_DOM_FRAGMENT = false;
466
+ /* Try to return a Trusted Type object instead of a string, return a string in
467
+ * case Trusted Types are not supported */
468
+ let RETURN_TRUSTED_TYPE = false;
469
+ /* Output should be free from DOM clobbering attacks?
470
+ * This sanitizes markups named with colliding, clobberable built-in DOM APIs.
471
+ */
472
+ let SANITIZE_DOM = true;
473
+ /* Achieve full DOM Clobbering protection by isolating the namespace of named
474
+ * properties and JS variables, mitigating attacks that abuse the HTML/DOM spec rules.
475
+ *
476
+ * HTML/DOM spec rules that enable DOM Clobbering:
477
+ * - Named Access on Window (§7.3.3)
478
+ * - DOM Tree Accessors (§3.1.5)
479
+ * - Form Element Parent-Child Relations (§4.10.3)
480
+ * - Iframe srcdoc / Nested WindowProxies (§4.8.5)
481
+ * - HTMLCollection (§4.2.10.2)
482
+ *
483
+ * Namespace isolation is implemented by prefixing `id` and `name` attributes
484
+ * with a constant string, i.e., `user-content-`
485
+ */
486
+ let SANITIZE_NAMED_PROPS = false;
487
+ const SANITIZE_NAMED_PROPS_PREFIX = 'user-content-';
488
+ /* Keep element content when removing element? */
489
+ let KEEP_CONTENT = true;
490
+ /* If a `Node` is passed to sanitize(), then performs sanitization in-place instead
491
+ * of importing it into a new Document and returning a sanitized copy */
492
+ let IN_PLACE = false;
493
+ /* Allow usage of profiles like html, svg and mathMl */
494
+ let USE_PROFILES = {};
495
+ /* Tags to ignore content of when KEEP_CONTENT is true */
496
+ let FORBID_CONTENTS = null;
497
+ const DEFAULT_FORBID_CONTENTS = addToSet({}, ['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']);
498
+ /* Tags that are safe for data: URIs */
499
+ let DATA_URI_TAGS = null;
500
+ const DEFAULT_DATA_URI_TAGS = addToSet({}, ['audio', 'video', 'img', 'source', 'image', 'track']);
501
+ /* Attributes safe for values like "javascript:" */
502
+ let URI_SAFE_ATTRIBUTES = null;
503
+ const DEFAULT_URI_SAFE_ATTRIBUTES = addToSet({}, ['alt', 'class', 'for', 'id', 'label', 'name', 'pattern', 'placeholder', 'role', 'summary', 'title', 'value', 'style', 'xmlns']);
504
+ const MATHML_NAMESPACE = 'http://www.w3.org/1998/Math/MathML';
505
+ const SVG_NAMESPACE = 'http://www.w3.org/2000/svg';
506
+ const HTML_NAMESPACE = 'http://www.w3.org/1999/xhtml';
507
+ /* Document namespace */
508
+ let NAMESPACE = HTML_NAMESPACE;
509
+ let IS_EMPTY_INPUT = false;
510
+ /* Allowed XHTML+XML namespaces */
511
+ let ALLOWED_NAMESPACES = null;
512
+ const DEFAULT_ALLOWED_NAMESPACES = addToSet({}, [MATHML_NAMESPACE, SVG_NAMESPACE, HTML_NAMESPACE], stringToString);
513
+ let MATHML_TEXT_INTEGRATION_POINTS = addToSet({}, ['mi', 'mo', 'mn', 'ms', 'mtext']);
514
+ let HTML_INTEGRATION_POINTS = addToSet({}, ['annotation-xml']);
515
+ // Certain elements are allowed in both SVG and HTML
516
+ // namespace. We need to specify them explicitly
517
+ // so that they don't get erroneously deleted from
518
+ // HTML namespace.
519
+ const COMMON_SVG_AND_HTML_ELEMENTS = addToSet({}, ['title', 'style', 'font', 'a', 'script']);
520
+ /* Parsing of strict XHTML documents */
521
+ let PARSER_MEDIA_TYPE = null;
522
+ const SUPPORTED_PARSER_MEDIA_TYPES = ['application/xhtml+xml', 'text/html'];
523
+ const DEFAULT_PARSER_MEDIA_TYPE = 'text/html';
524
+ let transformCaseFunc = null;
525
+ /* Keep a reference to config to pass to hooks */
526
+ let CONFIG = null;
527
+ /* Ideally, do not touch anything below this line */
528
+ /* ______________________________________________ */
529
+ const formElement = document.createElement('form');
530
+ const isRegexOrFunction = function isRegexOrFunction(testValue) {
531
+ return testValue instanceof RegExp || testValue instanceof Function;
532
+ };
533
+ /**
534
+ * _parseConfig
535
+ *
536
+ * @param cfg optional config literal
537
+ */
538
+ // eslint-disable-next-line complexity
539
+ const _parseConfig = function _parseConfig() {
540
+ let cfg = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
541
+ if (CONFIG && CONFIG === cfg) {
542
+ return;
543
+ }
544
+ /* Shield configuration object from tampering */
545
+ if (!cfg || typeof cfg !== 'object') {
546
+ cfg = {};
547
+ }
548
+ /* Shield configuration object from prototype pollution */
549
+ cfg = clone(cfg);
550
+ PARSER_MEDIA_TYPE =
551
+ // eslint-disable-next-line unicorn/prefer-includes
552
+ SUPPORTED_PARSER_MEDIA_TYPES.indexOf(cfg.PARSER_MEDIA_TYPE) === -1 ? DEFAULT_PARSER_MEDIA_TYPE : cfg.PARSER_MEDIA_TYPE;
553
+ // HTML tags and attributes are not case-sensitive, converting to lowercase. Keeping XHTML as is.
554
+ transformCaseFunc = PARSER_MEDIA_TYPE === 'application/xhtml+xml' ? stringToString : stringToLowerCase;
555
+ /* Set configuration parameters */
556
+ ALLOWED_TAGS = objectHasOwnProperty(cfg, 'ALLOWED_TAGS') ? addToSet({}, cfg.ALLOWED_TAGS, transformCaseFunc) : DEFAULT_ALLOWED_TAGS;
557
+ ALLOWED_ATTR = objectHasOwnProperty(cfg, 'ALLOWED_ATTR') ? addToSet({}, cfg.ALLOWED_ATTR, transformCaseFunc) : DEFAULT_ALLOWED_ATTR;
558
+ ALLOWED_NAMESPACES = objectHasOwnProperty(cfg, 'ALLOWED_NAMESPACES') ? addToSet({}, cfg.ALLOWED_NAMESPACES, stringToString) : DEFAULT_ALLOWED_NAMESPACES;
559
+ URI_SAFE_ATTRIBUTES = objectHasOwnProperty(cfg, 'ADD_URI_SAFE_ATTR') ? addToSet(clone(DEFAULT_URI_SAFE_ATTRIBUTES), cfg.ADD_URI_SAFE_ATTR, transformCaseFunc) : DEFAULT_URI_SAFE_ATTRIBUTES;
560
+ DATA_URI_TAGS = objectHasOwnProperty(cfg, 'ADD_DATA_URI_TAGS') ? addToSet(clone(DEFAULT_DATA_URI_TAGS), cfg.ADD_DATA_URI_TAGS, transformCaseFunc) : DEFAULT_DATA_URI_TAGS;
561
+ FORBID_CONTENTS = objectHasOwnProperty(cfg, 'FORBID_CONTENTS') ? addToSet({}, cfg.FORBID_CONTENTS, transformCaseFunc) : DEFAULT_FORBID_CONTENTS;
562
+ FORBID_TAGS = objectHasOwnProperty(cfg, 'FORBID_TAGS') ? addToSet({}, cfg.FORBID_TAGS, transformCaseFunc) : clone({});
563
+ FORBID_ATTR = objectHasOwnProperty(cfg, 'FORBID_ATTR') ? addToSet({}, cfg.FORBID_ATTR, transformCaseFunc) : clone({});
564
+ USE_PROFILES = objectHasOwnProperty(cfg, 'USE_PROFILES') ? cfg.USE_PROFILES : false;
565
+ ALLOW_ARIA_ATTR = cfg.ALLOW_ARIA_ATTR !== false; // Default true
566
+ ALLOW_DATA_ATTR = cfg.ALLOW_DATA_ATTR !== false; // Default true
567
+ ALLOW_UNKNOWN_PROTOCOLS = cfg.ALLOW_UNKNOWN_PROTOCOLS || false; // Default false
568
+ ALLOW_SELF_CLOSE_IN_ATTR = cfg.ALLOW_SELF_CLOSE_IN_ATTR !== false; // Default true
569
+ SAFE_FOR_TEMPLATES = cfg.SAFE_FOR_TEMPLATES || false; // Default false
570
+ SAFE_FOR_XML = cfg.SAFE_FOR_XML !== false; // Default true
571
+ WHOLE_DOCUMENT = cfg.WHOLE_DOCUMENT || false; // Default false
572
+ RETURN_DOM = cfg.RETURN_DOM || false; // Default false
573
+ RETURN_DOM_FRAGMENT = cfg.RETURN_DOM_FRAGMENT || false; // Default false
574
+ RETURN_TRUSTED_TYPE = cfg.RETURN_TRUSTED_TYPE || false; // Default false
575
+ FORCE_BODY = cfg.FORCE_BODY || false; // Default false
576
+ SANITIZE_DOM = cfg.SANITIZE_DOM !== false; // Default true
577
+ SANITIZE_NAMED_PROPS = cfg.SANITIZE_NAMED_PROPS || false; // Default false
578
+ KEEP_CONTENT = cfg.KEEP_CONTENT !== false; // Default true
579
+ IN_PLACE = cfg.IN_PLACE || false; // Default false
580
+ IS_ALLOWED_URI$1 = cfg.ALLOWED_URI_REGEXP || IS_ALLOWED_URI;
581
+ NAMESPACE = cfg.NAMESPACE || HTML_NAMESPACE;
582
+ MATHML_TEXT_INTEGRATION_POINTS = cfg.MATHML_TEXT_INTEGRATION_POINTS || MATHML_TEXT_INTEGRATION_POINTS;
583
+ HTML_INTEGRATION_POINTS = cfg.HTML_INTEGRATION_POINTS || HTML_INTEGRATION_POINTS;
584
+ CUSTOM_ELEMENT_HANDLING = cfg.CUSTOM_ELEMENT_HANDLING || {};
585
+ if (cfg.CUSTOM_ELEMENT_HANDLING && isRegexOrFunction(cfg.CUSTOM_ELEMENT_HANDLING.tagNameCheck)) {
586
+ CUSTOM_ELEMENT_HANDLING.tagNameCheck = cfg.CUSTOM_ELEMENT_HANDLING.tagNameCheck;
587
+ }
588
+ if (cfg.CUSTOM_ELEMENT_HANDLING && isRegexOrFunction(cfg.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)) {
589
+ CUSTOM_ELEMENT_HANDLING.attributeNameCheck = cfg.CUSTOM_ELEMENT_HANDLING.attributeNameCheck;
590
+ }
591
+ if (cfg.CUSTOM_ELEMENT_HANDLING && typeof cfg.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements === 'boolean') {
592
+ CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements = cfg.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements;
593
+ }
594
+ if (SAFE_FOR_TEMPLATES) {
595
+ ALLOW_DATA_ATTR = false;
596
+ }
597
+ if (RETURN_DOM_FRAGMENT) {
598
+ RETURN_DOM = true;
599
+ }
600
+ /* Parse profile info */
601
+ if (USE_PROFILES) {
602
+ ALLOWED_TAGS = addToSet({}, text);
603
+ ALLOWED_ATTR = [];
604
+ if (USE_PROFILES.html === true) {
605
+ addToSet(ALLOWED_TAGS, html$1);
606
+ addToSet(ALLOWED_ATTR, html);
607
+ }
608
+ if (USE_PROFILES.svg === true) {
609
+ addToSet(ALLOWED_TAGS, svg$1);
610
+ addToSet(ALLOWED_ATTR, svg);
611
+ addToSet(ALLOWED_ATTR, xml);
612
+ }
613
+ if (USE_PROFILES.svgFilters === true) {
614
+ addToSet(ALLOWED_TAGS, svgFilters);
615
+ addToSet(ALLOWED_ATTR, svg);
616
+ addToSet(ALLOWED_ATTR, xml);
617
+ }
618
+ if (USE_PROFILES.mathMl === true) {
619
+ addToSet(ALLOWED_TAGS, mathMl$1);
620
+ addToSet(ALLOWED_ATTR, mathMl);
621
+ addToSet(ALLOWED_ATTR, xml);
622
+ }
623
+ }
624
+ /* Merge configuration parameters */
625
+ if (cfg.ADD_TAGS) {
626
+ if (typeof cfg.ADD_TAGS === 'function') {
627
+ EXTRA_ELEMENT_HANDLING.tagCheck = cfg.ADD_TAGS;
628
+ } else {
629
+ if (ALLOWED_TAGS === DEFAULT_ALLOWED_TAGS) {
630
+ ALLOWED_TAGS = clone(ALLOWED_TAGS);
631
+ }
632
+ addToSet(ALLOWED_TAGS, cfg.ADD_TAGS, transformCaseFunc);
633
+ }
634
+ }
635
+ if (cfg.ADD_ATTR) {
636
+ if (typeof cfg.ADD_ATTR === 'function') {
637
+ EXTRA_ELEMENT_HANDLING.attributeCheck = cfg.ADD_ATTR;
638
+ } else {
639
+ if (ALLOWED_ATTR === DEFAULT_ALLOWED_ATTR) {
640
+ ALLOWED_ATTR = clone(ALLOWED_ATTR);
641
+ }
642
+ addToSet(ALLOWED_ATTR, cfg.ADD_ATTR, transformCaseFunc);
643
+ }
644
+ }
645
+ if (cfg.ADD_URI_SAFE_ATTR) {
646
+ addToSet(URI_SAFE_ATTRIBUTES, cfg.ADD_URI_SAFE_ATTR, transformCaseFunc);
647
+ }
648
+ if (cfg.FORBID_CONTENTS) {
649
+ if (FORBID_CONTENTS === DEFAULT_FORBID_CONTENTS) {
650
+ FORBID_CONTENTS = clone(FORBID_CONTENTS);
651
+ }
652
+ addToSet(FORBID_CONTENTS, cfg.FORBID_CONTENTS, transformCaseFunc);
653
+ }
654
+ /* Add #text in case KEEP_CONTENT is set to true */
655
+ if (KEEP_CONTENT) {
656
+ ALLOWED_TAGS['#text'] = true;
657
+ }
658
+ /* Add html, head and body to ALLOWED_TAGS in case WHOLE_DOCUMENT is true */
659
+ if (WHOLE_DOCUMENT) {
660
+ addToSet(ALLOWED_TAGS, ['html', 'head', 'body']);
661
+ }
662
+ /* Add tbody to ALLOWED_TAGS in case tables are permitted, see #286, #365 */
663
+ if (ALLOWED_TAGS.table) {
664
+ addToSet(ALLOWED_TAGS, ['tbody']);
665
+ delete FORBID_TAGS.tbody;
666
+ }
667
+ if (cfg.TRUSTED_TYPES_POLICY) {
668
+ if (typeof cfg.TRUSTED_TYPES_POLICY.createHTML !== 'function') {
669
+ throw typeErrorCreate('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');
670
+ }
671
+ if (typeof cfg.TRUSTED_TYPES_POLICY.createScriptURL !== 'function') {
672
+ throw typeErrorCreate('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');
673
+ }
674
+ // Overwrite existing TrustedTypes policy.
675
+ trustedTypesPolicy = cfg.TRUSTED_TYPES_POLICY;
676
+ // Sign local variables required by `sanitize`.
677
+ emptyHTML = trustedTypesPolicy.createHTML('');
678
+ } else {
679
+ // Uninitialized policy, attempt to initialize the internal dompurify policy.
680
+ if (trustedTypesPolicy === undefined) {
681
+ trustedTypesPolicy = _createTrustedTypesPolicy(trustedTypes, currentScript);
682
+ }
683
+ // If creating the internal policy succeeded sign internal variables.
684
+ if (trustedTypesPolicy !== null && typeof emptyHTML === 'string') {
685
+ emptyHTML = trustedTypesPolicy.createHTML('');
686
+ }
687
+ }
688
+ // Prevent further manipulation of configuration.
689
+ // Not available in IE8, Safari 5, etc.
690
+ if (freeze) {
691
+ freeze(cfg);
692
+ }
693
+ CONFIG = cfg;
694
+ };
695
+ /* Keep track of all possible SVG and MathML tags
696
+ * so that we can perform the namespace checks
697
+ * correctly. */
698
+ const ALL_SVG_TAGS = addToSet({}, [...svg$1, ...svgFilters, ...svgDisallowed]);
699
+ const ALL_MATHML_TAGS = addToSet({}, [...mathMl$1, ...mathMlDisallowed]);
700
+ /**
701
+ * @param element a DOM element whose namespace is being checked
702
+ * @returns Return false if the element has a
703
+ * namespace that a spec-compliant parser would never
704
+ * return. Return true otherwise.
705
+ */
706
+ const _checkValidNamespace = function _checkValidNamespace(element) {
707
+ let parent = getParentNode(element);
708
+ // In JSDOM, if we're inside shadow DOM, then parentNode
709
+ // can be null. We just simulate parent in this case.
710
+ if (!parent || !parent.tagName) {
711
+ parent = {
712
+ namespaceURI: NAMESPACE,
713
+ tagName: 'template'
714
+ };
715
+ }
716
+ const tagName = stringToLowerCase(element.tagName);
717
+ const parentTagName = stringToLowerCase(parent.tagName);
718
+ if (!ALLOWED_NAMESPACES[element.namespaceURI]) {
719
+ return false;
720
+ }
721
+ if (element.namespaceURI === SVG_NAMESPACE) {
722
+ // The only way to switch from HTML namespace to SVG
723
+ // is via <svg>. If it happens via any other tag, then
724
+ // it should be killed.
725
+ if (parent.namespaceURI === HTML_NAMESPACE) {
726
+ return tagName === 'svg';
727
+ }
728
+ // The only way to switch from MathML to SVG is via`
729
+ // svg if parent is either <annotation-xml> or MathML
730
+ // text integration points.
731
+ if (parent.namespaceURI === MATHML_NAMESPACE) {
732
+ return tagName === 'svg' && (parentTagName === 'annotation-xml' || MATHML_TEXT_INTEGRATION_POINTS[parentTagName]);
733
+ }
734
+ // We only allow elements that are defined in SVG
735
+ // spec. All others are disallowed in SVG namespace.
736
+ return Boolean(ALL_SVG_TAGS[tagName]);
737
+ }
738
+ if (element.namespaceURI === MATHML_NAMESPACE) {
739
+ // The only way to switch from HTML namespace to MathML
740
+ // is via <math>. If it happens via any other tag, then
741
+ // it should be killed.
742
+ if (parent.namespaceURI === HTML_NAMESPACE) {
743
+ return tagName === 'math';
744
+ }
745
+ // The only way to switch from SVG to MathML is via
746
+ // <math> and HTML integration points
747
+ if (parent.namespaceURI === SVG_NAMESPACE) {
748
+ return tagName === 'math' && HTML_INTEGRATION_POINTS[parentTagName];
749
+ }
750
+ // We only allow elements that are defined in MathML
751
+ // spec. All others are disallowed in MathML namespace.
752
+ return Boolean(ALL_MATHML_TAGS[tagName]);
753
+ }
754
+ if (element.namespaceURI === HTML_NAMESPACE) {
755
+ // The only way to switch from SVG to HTML is via
756
+ // HTML integration points, and from MathML to HTML
757
+ // is via MathML text integration points
758
+ if (parent.namespaceURI === SVG_NAMESPACE && !HTML_INTEGRATION_POINTS[parentTagName]) {
759
+ return false;
760
+ }
761
+ if (parent.namespaceURI === MATHML_NAMESPACE && !MATHML_TEXT_INTEGRATION_POINTS[parentTagName]) {
762
+ return false;
763
+ }
764
+ // We disallow tags that are specific for MathML
765
+ // or SVG and should never appear in HTML namespace
766
+ return !ALL_MATHML_TAGS[tagName] && (COMMON_SVG_AND_HTML_ELEMENTS[tagName] || !ALL_SVG_TAGS[tagName]);
767
+ }
768
+ // For XHTML and XML documents that support custom namespaces
769
+ if (PARSER_MEDIA_TYPE === 'application/xhtml+xml' && ALLOWED_NAMESPACES[element.namespaceURI]) {
770
+ return true;
771
+ }
772
+ // The code should never reach this place (this means
773
+ // that the element somehow got namespace that is not
774
+ // HTML, SVG, MathML or allowed via ALLOWED_NAMESPACES).
775
+ // Return false just in case.
776
+ return false;
777
+ };
778
+ /**
779
+ * _forceRemove
780
+ *
781
+ * @param node a DOM node
782
+ */
783
+ const _forceRemove = function _forceRemove(node) {
784
+ arrayPush(DOMPurify.removed, {
785
+ element: node
786
+ });
787
+ try {
788
+ // eslint-disable-next-line unicorn/prefer-dom-node-remove
789
+ getParentNode(node).removeChild(node);
790
+ } catch (_) {
791
+ remove(node);
792
+ }
793
+ };
794
+ /**
795
+ * _removeAttribute
796
+ *
797
+ * @param name an Attribute name
798
+ * @param element a DOM node
799
+ */
800
+ const _removeAttribute = function _removeAttribute(name, element) {
801
+ try {
802
+ arrayPush(DOMPurify.removed, {
803
+ attribute: element.getAttributeNode(name),
804
+ from: element
805
+ });
806
+ } catch (_) {
807
+ arrayPush(DOMPurify.removed, {
808
+ attribute: null,
809
+ from: element
810
+ });
811
+ }
812
+ element.removeAttribute(name);
813
+ // We void attribute values for unremovable "is" attributes
814
+ if (name === 'is') {
815
+ if (RETURN_DOM || RETURN_DOM_FRAGMENT) {
816
+ try {
817
+ _forceRemove(element);
818
+ } catch (_) {}
819
+ } else {
820
+ try {
821
+ element.setAttribute(name, '');
822
+ } catch (_) {}
823
+ }
824
+ }
825
+ };
826
+ /**
827
+ * _initDocument
828
+ *
829
+ * @param dirty - a string of dirty markup
830
+ * @return a DOM, filled with the dirty markup
831
+ */
832
+ const _initDocument = function _initDocument(dirty) {
833
+ /* Create a HTML document */
834
+ let doc = null;
835
+ let leadingWhitespace = null;
836
+ if (FORCE_BODY) {
837
+ dirty = '<remove></remove>' + dirty;
838
+ } else {
839
+ /* If FORCE_BODY isn't used, leading whitespace needs to be preserved manually */
840
+ const matches = stringMatch(dirty, /^[\r\n\t ]+/);
841
+ leadingWhitespace = matches && matches[0];
842
+ }
843
+ if (PARSER_MEDIA_TYPE === 'application/xhtml+xml' && NAMESPACE === HTML_NAMESPACE) {
844
+ // Root of XHTML doc must contain xmlns declaration (see https://www.w3.org/TR/xhtml1/normative.html#strict)
845
+ dirty = '<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>' + dirty + '</body></html>';
846
+ }
847
+ const dirtyPayload = trustedTypesPolicy ? trustedTypesPolicy.createHTML(dirty) : dirty;
848
+ /*
849
+ * Use the DOMParser API by default, fallback later if needs be
850
+ * DOMParser not work for svg when has multiple root element.
851
+ */
852
+ if (NAMESPACE === HTML_NAMESPACE) {
853
+ try {
854
+ doc = new DOMParser().parseFromString(dirtyPayload, PARSER_MEDIA_TYPE);
855
+ } catch (_) {}
856
+ }
857
+ /* Use createHTMLDocument in case DOMParser is not available */
858
+ if (!doc || !doc.documentElement) {
859
+ doc = implementation.createDocument(NAMESPACE, 'template', null);
860
+ try {
861
+ doc.documentElement.innerHTML = IS_EMPTY_INPUT ? emptyHTML : dirtyPayload;
862
+ } catch (_) {
863
+ // Syntax error if dirtyPayload is invalid xml
864
+ }
865
+ }
866
+ const body = doc.body || doc.documentElement;
867
+ if (dirty && leadingWhitespace) {
868
+ body.insertBefore(document.createTextNode(leadingWhitespace), body.childNodes[0] || null);
869
+ }
870
+ /* Work on whole document or just its body */
871
+ if (NAMESPACE === HTML_NAMESPACE) {
872
+ return getElementsByTagName.call(doc, WHOLE_DOCUMENT ? 'html' : 'body')[0];
873
+ }
874
+ return WHOLE_DOCUMENT ? doc.documentElement : body;
875
+ };
876
+ /**
877
+ * Creates a NodeIterator object that you can use to traverse filtered lists of nodes or elements in a document.
878
+ *
879
+ * @param root The root element or node to start traversing on.
880
+ * @return The created NodeIterator
881
+ */
882
+ const _createNodeIterator = function _createNodeIterator(root) {
883
+ return createNodeIterator.call(root.ownerDocument || root, root,
884
+ // eslint-disable-next-line no-bitwise
885
+ NodeFilter.SHOW_ELEMENT | NodeFilter.SHOW_COMMENT | NodeFilter.SHOW_TEXT | NodeFilter.SHOW_PROCESSING_INSTRUCTION | NodeFilter.SHOW_CDATA_SECTION, null);
886
+ };
887
+ /**
888
+ * _isClobbered
889
+ *
890
+ * @param element element to check for clobbering attacks
891
+ * @return true if clobbered, false if safe
892
+ */
893
+ const _isClobbered = function _isClobbered(element) {
894
+ return element instanceof HTMLFormElement && (typeof element.nodeName !== 'string' || typeof element.textContent !== 'string' || typeof element.removeChild !== 'function' || !(element.attributes instanceof NamedNodeMap) || typeof element.removeAttribute !== 'function' || typeof element.setAttribute !== 'function' || typeof element.namespaceURI !== 'string' || typeof element.insertBefore !== 'function' || typeof element.hasChildNodes !== 'function');
895
+ };
896
+ /**
897
+ * Checks whether the given object is a DOM node.
898
+ *
899
+ * @param value object to check whether it's a DOM node
900
+ * @return true is object is a DOM node
901
+ */
902
+ const _isNode = function _isNode(value) {
903
+ return typeof Node === 'function' && value instanceof Node;
904
+ };
905
+ function _executeHooks(hooks, currentNode, data) {
906
+ arrayForEach(hooks, hook => {
907
+ hook.call(DOMPurify, currentNode, data, CONFIG);
908
+ });
909
+ }
910
+ /**
911
+ * _sanitizeElements
912
+ *
913
+ * @protect nodeName
914
+ * @protect textContent
915
+ * @protect removeChild
916
+ * @param currentNode to check for permission to exist
917
+ * @return true if node was killed, false if left alive
918
+ */
919
+ const _sanitizeElements = function _sanitizeElements(currentNode) {
920
+ let content = null;
921
+ /* Execute a hook if present */
922
+ _executeHooks(hooks.beforeSanitizeElements, currentNode, null);
923
+ /* Check if element is clobbered or can clobber */
924
+ if (_isClobbered(currentNode)) {
925
+ _forceRemove(currentNode);
926
+ return true;
927
+ }
928
+ /* Now let's check the element's type and name */
929
+ const tagName = transformCaseFunc(currentNode.nodeName);
930
+ /* Execute a hook if present */
931
+ _executeHooks(hooks.uponSanitizeElement, currentNode, {
932
+ tagName,
933
+ allowedTags: ALLOWED_TAGS
934
+ });
935
+ /* Detect mXSS attempts abusing namespace confusion */
936
+ if (SAFE_FOR_XML && currentNode.hasChildNodes() && !_isNode(currentNode.firstElementChild) && regExpTest(/<[/\w!]/g, currentNode.innerHTML) && regExpTest(/<[/\w!]/g, currentNode.textContent)) {
937
+ _forceRemove(currentNode);
938
+ return true;
939
+ }
940
+ /* Remove any occurrence of processing instructions */
941
+ if (currentNode.nodeType === NODE_TYPE.progressingInstruction) {
942
+ _forceRemove(currentNode);
943
+ return true;
944
+ }
945
+ /* Remove any kind of possibly harmful comments */
946
+ if (SAFE_FOR_XML && currentNode.nodeType === NODE_TYPE.comment && regExpTest(/<[/\w]/g, currentNode.data)) {
947
+ _forceRemove(currentNode);
948
+ return true;
949
+ }
950
+ /* Remove element if anything forbids its presence */
951
+ if (!(EXTRA_ELEMENT_HANDLING.tagCheck instanceof Function && EXTRA_ELEMENT_HANDLING.tagCheck(tagName)) && (!ALLOWED_TAGS[tagName] || FORBID_TAGS[tagName])) {
952
+ /* Check if we have a custom element to handle */
953
+ if (!FORBID_TAGS[tagName] && _isBasicCustomElement(tagName)) {
954
+ if (CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof RegExp && regExpTest(CUSTOM_ELEMENT_HANDLING.tagNameCheck, tagName)) {
955
+ return false;
956
+ }
957
+ if (CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof Function && CUSTOM_ELEMENT_HANDLING.tagNameCheck(tagName)) {
958
+ return false;
959
+ }
960
+ }
961
+ /* Keep content except for bad-listed elements */
962
+ if (KEEP_CONTENT && !FORBID_CONTENTS[tagName]) {
963
+ const parentNode = getParentNode(currentNode) || currentNode.parentNode;
964
+ const childNodes = getChildNodes(currentNode) || currentNode.childNodes;
965
+ if (childNodes && parentNode) {
966
+ const childCount = childNodes.length;
967
+ for (let i = childCount - 1; i >= 0; --i) {
968
+ const childClone = cloneNode(childNodes[i], true);
969
+ childClone.__removalCount = (currentNode.__removalCount || 0) + 1;
970
+ parentNode.insertBefore(childClone, getNextSibling(currentNode));
971
+ }
972
+ }
973
+ }
974
+ _forceRemove(currentNode);
975
+ return true;
976
+ }
977
+ /* Check whether element has a valid namespace */
978
+ if (currentNode instanceof Element && !_checkValidNamespace(currentNode)) {
979
+ _forceRemove(currentNode);
980
+ return true;
981
+ }
982
+ /* Make sure that older browsers don't get fallback-tag mXSS */
983
+ if ((tagName === 'noscript' || tagName === 'noembed' || tagName === 'noframes') && regExpTest(/<\/no(script|embed|frames)/i, currentNode.innerHTML)) {
984
+ _forceRemove(currentNode);
985
+ return true;
986
+ }
987
+ /* Sanitize element content to be template-safe */
988
+ if (SAFE_FOR_TEMPLATES && currentNode.nodeType === NODE_TYPE.text) {
989
+ /* Get the element's text content */
990
+ content = currentNode.textContent;
991
+ arrayForEach([MUSTACHE_EXPR, ERB_EXPR, TMPLIT_EXPR], expr => {
992
+ content = stringReplace(content, expr, ' ');
993
+ });
994
+ if (currentNode.textContent !== content) {
995
+ arrayPush(DOMPurify.removed, {
996
+ element: currentNode.cloneNode()
997
+ });
998
+ currentNode.textContent = content;
999
+ }
1000
+ }
1001
+ /* Execute a hook if present */
1002
+ _executeHooks(hooks.afterSanitizeElements, currentNode, null);
1003
+ return false;
1004
+ };
1005
+ /**
1006
+ * _isValidAttribute
1007
+ *
1008
+ * @param lcTag Lowercase tag name of containing element.
1009
+ * @param lcName Lowercase attribute name.
1010
+ * @param value Attribute value.
1011
+ * @return Returns true if `value` is valid, otherwise false.
1012
+ */
1013
+ // eslint-disable-next-line complexity
1014
+ const _isValidAttribute = function _isValidAttribute(lcTag, lcName, value) {
1015
+ /* Make sure attribute cannot clobber */
1016
+ if (SANITIZE_DOM && (lcName === 'id' || lcName === 'name') && (value in document || value in formElement)) {
1017
+ return false;
1018
+ }
1019
+ /* Allow valid data-* attributes: At least one character after "-"
1020
+ (https://html.spec.whatwg.org/multipage/dom.html#embedding-custom-non-visible-data-with-the-data-*-attributes)
1021
+ XML-compatible (https://html.spec.whatwg.org/multipage/infrastructure.html#xml-compatible and http://www.w3.org/TR/xml/#d0e804)
1022
+ We don't need to check the value; it's always URI safe. */
1023
+ if (ALLOW_DATA_ATTR && !FORBID_ATTR[lcName] && regExpTest(DATA_ATTR, lcName)) ; else if (ALLOW_ARIA_ATTR && regExpTest(ARIA_ATTR, lcName)) ; else if (EXTRA_ELEMENT_HANDLING.attributeCheck instanceof Function && EXTRA_ELEMENT_HANDLING.attributeCheck(lcName, lcTag)) ; else if (!ALLOWED_ATTR[lcName] || FORBID_ATTR[lcName]) {
1024
+ if (
1025
+ // First condition does a very basic check if a) it's basically a valid custom element tagname AND
1026
+ // b) if the tagName passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
1027
+ // and c) if the attribute name passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.attributeNameCheck
1028
+ _isBasicCustomElement(lcTag) && (CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof RegExp && regExpTest(CUSTOM_ELEMENT_HANDLING.tagNameCheck, lcTag) || CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof Function && CUSTOM_ELEMENT_HANDLING.tagNameCheck(lcTag)) && (CUSTOM_ELEMENT_HANDLING.attributeNameCheck instanceof RegExp && regExpTest(CUSTOM_ELEMENT_HANDLING.attributeNameCheck, lcName) || CUSTOM_ELEMENT_HANDLING.attributeNameCheck instanceof Function && CUSTOM_ELEMENT_HANDLING.attributeNameCheck(lcName, lcTag)) ||
1029
+ // Alternative, second condition checks if it's an `is`-attribute, AND
1030
+ // the value passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
1031
+ lcName === 'is' && CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements && (CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof RegExp && regExpTest(CUSTOM_ELEMENT_HANDLING.tagNameCheck, value) || CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof Function && CUSTOM_ELEMENT_HANDLING.tagNameCheck(value))) ; else {
1032
+ return false;
1033
+ }
1034
+ /* Check value is safe. First, is attr inert? If so, is safe */
1035
+ } else if (URI_SAFE_ATTRIBUTES[lcName]) ; else if (regExpTest(IS_ALLOWED_URI$1, stringReplace(value, ATTR_WHITESPACE, ''))) ; else if ((lcName === 'src' || lcName === 'xlink:href' || lcName === 'href') && lcTag !== 'script' && stringIndexOf(value, 'data:') === 0 && DATA_URI_TAGS[lcTag]) ; else if (ALLOW_UNKNOWN_PROTOCOLS && !regExpTest(IS_SCRIPT_OR_DATA, stringReplace(value, ATTR_WHITESPACE, ''))) ; else if (value) {
1036
+ return false;
1037
+ } else ;
1038
+ return true;
1039
+ };
1040
+ /**
1041
+ * _isBasicCustomElement
1042
+ * checks if at least one dash is included in tagName, and it's not the first char
1043
+ * for more sophisticated checking see https://github.com/sindresorhus/validate-element-name
1044
+ *
1045
+ * @param tagName name of the tag of the node to sanitize
1046
+ * @returns Returns true if the tag name meets the basic criteria for a custom element, otherwise false.
1047
+ */
1048
+ const _isBasicCustomElement = function _isBasicCustomElement(tagName) {
1049
+ return tagName !== 'annotation-xml' && stringMatch(tagName, CUSTOM_ELEMENT);
1050
+ };
1051
+ /**
1052
+ * _sanitizeAttributes
1053
+ *
1054
+ * @protect attributes
1055
+ * @protect nodeName
1056
+ * @protect removeAttribute
1057
+ * @protect setAttribute
1058
+ *
1059
+ * @param currentNode to sanitize
1060
+ */
1061
+ const _sanitizeAttributes = function _sanitizeAttributes(currentNode) {
1062
+ /* Execute a hook if present */
1063
+ _executeHooks(hooks.beforeSanitizeAttributes, currentNode, null);
1064
+ const {
1065
+ attributes
1066
+ } = currentNode;
1067
+ /* Check if we have attributes; if not we might have a text node */
1068
+ if (!attributes || _isClobbered(currentNode)) {
1069
+ return;
1070
+ }
1071
+ const hookEvent = {
1072
+ attrName: '',
1073
+ attrValue: '',
1074
+ keepAttr: true,
1075
+ allowedAttributes: ALLOWED_ATTR,
1076
+ forceKeepAttr: undefined
1077
+ };
1078
+ let l = attributes.length;
1079
+ /* Go backwards over all attributes; safely remove bad ones */
1080
+ while (l--) {
1081
+ const attr = attributes[l];
1082
+ const {
1083
+ name,
1084
+ namespaceURI,
1085
+ value: attrValue
1086
+ } = attr;
1087
+ const lcName = transformCaseFunc(name);
1088
+ const initValue = attrValue;
1089
+ let value = name === 'value' ? initValue : stringTrim(initValue);
1090
+ /* Execute a hook if present */
1091
+ hookEvent.attrName = lcName;
1092
+ hookEvent.attrValue = value;
1093
+ hookEvent.keepAttr = true;
1094
+ hookEvent.forceKeepAttr = undefined; // Allows developers to see this is a property they can set
1095
+ _executeHooks(hooks.uponSanitizeAttribute, currentNode, hookEvent);
1096
+ value = hookEvent.attrValue;
1097
+ /* Full DOM Clobbering protection via namespace isolation,
1098
+ * Prefix id and name attributes with `user-content-`
1099
+ */
1100
+ if (SANITIZE_NAMED_PROPS && (lcName === 'id' || lcName === 'name')) {
1101
+ // Remove the attribute with this value
1102
+ _removeAttribute(name, currentNode);
1103
+ // Prefix the value and later re-create the attribute with the sanitized value
1104
+ value = SANITIZE_NAMED_PROPS_PREFIX + value;
1105
+ }
1106
+ /* Work around a security issue with comments inside attributes */
1107
+ if (SAFE_FOR_XML && regExpTest(/((--!?|])>)|<\/(style|title|textarea)/i, value)) {
1108
+ _removeAttribute(name, currentNode);
1109
+ continue;
1110
+ }
1111
+ /* Make sure we cannot easily use animated hrefs, even if animations are allowed */
1112
+ if (lcName === 'attributename' && stringMatch(value, 'href')) {
1113
+ _removeAttribute(name, currentNode);
1114
+ continue;
1115
+ }
1116
+ /* Did the hooks approve of the attribute? */
1117
+ if (hookEvent.forceKeepAttr) {
1118
+ continue;
1119
+ }
1120
+ /* Did the hooks approve of the attribute? */
1121
+ if (!hookEvent.keepAttr) {
1122
+ _removeAttribute(name, currentNode);
1123
+ continue;
1124
+ }
1125
+ /* Work around a security issue in jQuery 3.0 */
1126
+ if (!ALLOW_SELF_CLOSE_IN_ATTR && regExpTest(/\/>/i, value)) {
1127
+ _removeAttribute(name, currentNode);
1128
+ continue;
1129
+ }
1130
+ /* Sanitize attribute content to be template-safe */
1131
+ if (SAFE_FOR_TEMPLATES) {
1132
+ arrayForEach([MUSTACHE_EXPR, ERB_EXPR, TMPLIT_EXPR], expr => {
1133
+ value = stringReplace(value, expr, ' ');
1134
+ });
1135
+ }
1136
+ /* Is `value` valid for this attribute? */
1137
+ const lcTag = transformCaseFunc(currentNode.nodeName);
1138
+ if (!_isValidAttribute(lcTag, lcName, value)) {
1139
+ _removeAttribute(name, currentNode);
1140
+ continue;
1141
+ }
1142
+ /* Handle attributes that require Trusted Types */
1143
+ if (trustedTypesPolicy && typeof trustedTypes === 'object' && typeof trustedTypes.getAttributeType === 'function') {
1144
+ if (namespaceURI) ; else {
1145
+ switch (trustedTypes.getAttributeType(lcTag, lcName)) {
1146
+ case 'TrustedHTML':
1147
+ {
1148
+ value = trustedTypesPolicy.createHTML(value);
1149
+ break;
1150
+ }
1151
+ case 'TrustedScriptURL':
1152
+ {
1153
+ value = trustedTypesPolicy.createScriptURL(value);
1154
+ break;
1155
+ }
1156
+ }
1157
+ }
1158
+ }
1159
+ /* Handle invalid data-* attribute set by try-catching it */
1160
+ if (value !== initValue) {
1161
+ try {
1162
+ if (namespaceURI) {
1163
+ currentNode.setAttributeNS(namespaceURI, name, value);
1164
+ } else {
1165
+ /* Fallback to setAttribute() for browser-unrecognized namespaces e.g. "x-schema". */
1166
+ currentNode.setAttribute(name, value);
1167
+ }
1168
+ if (_isClobbered(currentNode)) {
1169
+ _forceRemove(currentNode);
1170
+ } else {
1171
+ arrayPop(DOMPurify.removed);
1172
+ }
1173
+ } catch (_) {
1174
+ _removeAttribute(name, currentNode);
1175
+ }
1176
+ }
1177
+ }
1178
+ /* Execute a hook if present */
1179
+ _executeHooks(hooks.afterSanitizeAttributes, currentNode, null);
1180
+ };
1181
+ /**
1182
+ * _sanitizeShadowDOM
1183
+ *
1184
+ * @param fragment to iterate over recursively
1185
+ */
1186
+ const _sanitizeShadowDOM = function _sanitizeShadowDOM(fragment) {
1187
+ let shadowNode = null;
1188
+ const shadowIterator = _createNodeIterator(fragment);
1189
+ /* Execute a hook if present */
1190
+ _executeHooks(hooks.beforeSanitizeShadowDOM, fragment, null);
1191
+ while (shadowNode = shadowIterator.nextNode()) {
1192
+ /* Execute a hook if present */
1193
+ _executeHooks(hooks.uponSanitizeShadowNode, shadowNode, null);
1194
+ /* Sanitize tags and elements */
1195
+ _sanitizeElements(shadowNode);
1196
+ /* Check attributes next */
1197
+ _sanitizeAttributes(shadowNode);
1198
+ /* Deep shadow DOM detected */
1199
+ if (shadowNode.content instanceof DocumentFragment) {
1200
+ _sanitizeShadowDOM(shadowNode.content);
1201
+ }
1202
+ }
1203
+ /* Execute a hook if present */
1204
+ _executeHooks(hooks.afterSanitizeShadowDOM, fragment, null);
1205
+ };
1206
+ // eslint-disable-next-line complexity
1207
+ DOMPurify.sanitize = function (dirty) {
1208
+ let cfg = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
1209
+ let body = null;
1210
+ let importedNode = null;
1211
+ let currentNode = null;
1212
+ let returnNode = null;
1213
+ /* Make sure we have a string to sanitize.
1214
+ DO NOT return early, as this will return the wrong type if
1215
+ the user has requested a DOM object rather than a string */
1216
+ IS_EMPTY_INPUT = !dirty;
1217
+ if (IS_EMPTY_INPUT) {
1218
+ dirty = '<!-->';
1219
+ }
1220
+ /* Stringify, in case dirty is an object */
1221
+ if (typeof dirty !== 'string' && !_isNode(dirty)) {
1222
+ if (typeof dirty.toString === 'function') {
1223
+ dirty = dirty.toString();
1224
+ if (typeof dirty !== 'string') {
1225
+ throw typeErrorCreate('dirty is not a string, aborting');
1226
+ }
1227
+ } else {
1228
+ throw typeErrorCreate('toString is not a function');
1229
+ }
1230
+ }
1231
+ /* Return dirty HTML if DOMPurify cannot run */
1232
+ if (!DOMPurify.isSupported) {
1233
+ return dirty;
1234
+ }
1235
+ /* Assign config vars */
1236
+ if (!SET_CONFIG) {
1237
+ _parseConfig(cfg);
1238
+ }
1239
+ /* Clean up removed elements */
1240
+ DOMPurify.removed = [];
1241
+ /* Check if dirty is correctly typed for IN_PLACE */
1242
+ if (typeof dirty === 'string') {
1243
+ IN_PLACE = false;
1244
+ }
1245
+ if (IN_PLACE) {
1246
+ /* Do some early pre-sanitization to avoid unsafe root nodes */
1247
+ if (dirty.nodeName) {
1248
+ const tagName = transformCaseFunc(dirty.nodeName);
1249
+ if (!ALLOWED_TAGS[tagName] || FORBID_TAGS[tagName]) {
1250
+ throw typeErrorCreate('root node is forbidden and cannot be sanitized in-place');
1251
+ }
1252
+ }
1253
+ } else if (dirty instanceof Node) {
1254
+ /* If dirty is a DOM element, append to an empty document to avoid
1255
+ elements being stripped by the parser */
1256
+ body = _initDocument('<!---->');
1257
+ importedNode = body.ownerDocument.importNode(dirty, true);
1258
+ if (importedNode.nodeType === NODE_TYPE.element && importedNode.nodeName === 'BODY') {
1259
+ /* Node is already a body, use as is */
1260
+ body = importedNode;
1261
+ } else if (importedNode.nodeName === 'HTML') {
1262
+ body = importedNode;
1263
+ } else {
1264
+ // eslint-disable-next-line unicorn/prefer-dom-node-append
1265
+ body.appendChild(importedNode);
1266
+ }
1267
+ } else {
1268
+ /* Exit directly if we have nothing to do */
1269
+ if (!RETURN_DOM && !SAFE_FOR_TEMPLATES && !WHOLE_DOCUMENT &&
1270
+ // eslint-disable-next-line unicorn/prefer-includes
1271
+ dirty.indexOf('<') === -1) {
1272
+ return trustedTypesPolicy && RETURN_TRUSTED_TYPE ? trustedTypesPolicy.createHTML(dirty) : dirty;
1273
+ }
1274
+ /* Initialize the document to work on */
1275
+ body = _initDocument(dirty);
1276
+ /* Check we have a DOM node from the data */
1277
+ if (!body) {
1278
+ return RETURN_DOM ? null : RETURN_TRUSTED_TYPE ? emptyHTML : '';
1279
+ }
1280
+ }
1281
+ /* Remove first element node (ours) if FORCE_BODY is set */
1282
+ if (body && FORCE_BODY) {
1283
+ _forceRemove(body.firstChild);
1284
+ }
1285
+ /* Get node iterator */
1286
+ const nodeIterator = _createNodeIterator(IN_PLACE ? dirty : body);
1287
+ /* Now start iterating over the created document */
1288
+ while (currentNode = nodeIterator.nextNode()) {
1289
+ /* Sanitize tags and elements */
1290
+ _sanitizeElements(currentNode);
1291
+ /* Check attributes next */
1292
+ _sanitizeAttributes(currentNode);
1293
+ /* Shadow DOM detected, sanitize it */
1294
+ if (currentNode.content instanceof DocumentFragment) {
1295
+ _sanitizeShadowDOM(currentNode.content);
1296
+ }
1297
+ }
1298
+ /* If we sanitized `dirty` in-place, return it. */
1299
+ if (IN_PLACE) {
1300
+ return dirty;
1301
+ }
1302
+ /* Return sanitized string or DOM */
1303
+ if (RETURN_DOM) {
1304
+ if (RETURN_DOM_FRAGMENT) {
1305
+ returnNode = createDocumentFragment.call(body.ownerDocument);
1306
+ while (body.firstChild) {
1307
+ // eslint-disable-next-line unicorn/prefer-dom-node-append
1308
+ returnNode.appendChild(body.firstChild);
1309
+ }
1310
+ } else {
1311
+ returnNode = body;
1312
+ }
1313
+ if (ALLOWED_ATTR.shadowroot || ALLOWED_ATTR.shadowrootmode) {
1314
+ /*
1315
+ AdoptNode() is not used because internal state is not reset
1316
+ (e.g. the past names map of a HTMLFormElement), this is safe
1317
+ in theory but we would rather not risk another attack vector.
1318
+ The state that is cloned by importNode() is explicitly defined
1319
+ by the specs.
1320
+ */
1321
+ returnNode = importNode.call(originalDocument, returnNode, true);
1322
+ }
1323
+ return returnNode;
1324
+ }
1325
+ let serializedHTML = WHOLE_DOCUMENT ? body.outerHTML : body.innerHTML;
1326
+ /* Serialize doctype if allowed */
1327
+ if (WHOLE_DOCUMENT && ALLOWED_TAGS['!doctype'] && body.ownerDocument && body.ownerDocument.doctype && body.ownerDocument.doctype.name && regExpTest(DOCTYPE_NAME, body.ownerDocument.doctype.name)) {
1328
+ serializedHTML = '<!DOCTYPE ' + body.ownerDocument.doctype.name + '>\n' + serializedHTML;
1329
+ }
1330
+ /* Sanitize final string template-safe */
1331
+ if (SAFE_FOR_TEMPLATES) {
1332
+ arrayForEach([MUSTACHE_EXPR, ERB_EXPR, TMPLIT_EXPR], expr => {
1333
+ serializedHTML = stringReplace(serializedHTML, expr, ' ');
1334
+ });
1335
+ }
1336
+ return trustedTypesPolicy && RETURN_TRUSTED_TYPE ? trustedTypesPolicy.createHTML(serializedHTML) : serializedHTML;
1337
+ };
1338
+ DOMPurify.setConfig = function () {
1339
+ let cfg = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
1340
+ _parseConfig(cfg);
1341
+ SET_CONFIG = true;
1342
+ };
1343
+ DOMPurify.clearConfig = function () {
1344
+ CONFIG = null;
1345
+ SET_CONFIG = false;
1346
+ };
1347
+ DOMPurify.isValidAttribute = function (tag, attr, value) {
1348
+ /* Initialize shared config vars if necessary. */
1349
+ if (!CONFIG) {
1350
+ _parseConfig({});
1351
+ }
1352
+ const lcTag = transformCaseFunc(tag);
1353
+ const lcName = transformCaseFunc(attr);
1354
+ return _isValidAttribute(lcTag, lcName, value);
1355
+ };
1356
+ DOMPurify.addHook = function (entryPoint, hookFunction) {
1357
+ if (typeof hookFunction !== 'function') {
1358
+ return;
1359
+ }
1360
+ arrayPush(hooks[entryPoint], hookFunction);
1361
+ };
1362
+ DOMPurify.removeHook = function (entryPoint, hookFunction) {
1363
+ if (hookFunction !== undefined) {
1364
+ const index = arrayLastIndexOf(hooks[entryPoint], hookFunction);
1365
+ return index === -1 ? undefined : arraySplice(hooks[entryPoint], index, 1)[0];
1366
+ }
1367
+ return arrayPop(hooks[entryPoint]);
1368
+ };
1369
+ DOMPurify.removeHooks = function (entryPoint) {
1370
+ hooks[entryPoint] = [];
1371
+ };
1372
+ DOMPurify.removeAllHooks = function () {
1373
+ hooks = _createHooksMap();
1374
+ };
1375
+ return DOMPurify;
1376
+ }
1377
+ var purify = createDOMPurify();
1378
+
1379
+ export { purify as default };
1380
+ //# sourceMappingURL=purify.es.mjs.map