@luzmo/analytics-components-kit 1.0.9-beta.11 → 1.0.9-beta.13

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 (1217) hide show
  1. package/README.md +5 -1
  2. package/components/ad-hoc-slot-content-B-qsBK5Y.cjs +20 -0
  3. package/components/ad-hoc-slot-content-BJ2TwuZ_.js +29 -0
  4. package/components/add-to-dashboard/index.cjs +1 -1
  5. package/components/add-to-dashboard/index.js +1 -1
  6. package/components/add-to-dashboard-B702runr.cjs +166 -0
  7. package/components/add-to-dashboard-O9tn5g_w.js +805 -0
  8. package/components/ai-chat/ai-chat-events.d.ts +5 -1
  9. package/components/ai-chat/ai-chat.d.ts +36 -1
  10. package/components/ai-chat/helpers/assistant-message-feedback.d.ts +26 -0
  11. package/components/ai-chat/index.cjs +1 -1
  12. package/components/ai-chat/index.d.ts +1 -1
  13. package/components/ai-chat/index.js +2 -2
  14. package/components/ai-chat/session/ai-chat-session.d.ts +8 -1
  15. package/components/ai-chat/stream/chunk-extractors.d.ts +8 -0
  16. package/components/ai-chat/stream/index.d.ts +1 -1
  17. package/components/ai-chat/stream/types.d.ts +6 -0
  18. package/components/ai-chat-BBUKgMVk.js +4464 -0
  19. package/components/ai-chat-DxpHdNnM.cjs +393 -0
  20. package/components/ai-interaction-textarea/index.cjs +1 -1
  21. package/components/ai-interaction-textarea/index.js +1 -1
  22. package/components/ai-interaction-textarea-BCa1PnPL.js +823 -0
  23. package/components/ai-interaction-textarea-DSk1A1a5.cjs +101 -0
  24. package/components/area-chart-options.config-CPHMgC3Z.cjs +20 -0
  25. package/components/area-chart-options.config-_vAFPSCl.js +219 -0
  26. package/components/area-chart-options.de-D5Wto0ja.cjs +20 -0
  27. package/components/area-chart-options.de-DQgBZ85Q.js +95 -0
  28. package/components/area-chart-options.en-C_8QeDtL.js +95 -0
  29. package/components/area-chart-options.en-CrffNamW.cjs +20 -0
  30. package/components/area-chart-options.es-BPpe9WGc.cjs +20 -0
  31. package/components/area-chart-options.es-qtqhkLAN.js +95 -0
  32. package/components/area-chart-options.fr-CdlaMfpz.cjs +20 -0
  33. package/components/area-chart-options.fr-Dj1ppAEP.js +95 -0
  34. package/components/area-chart-options.nl-C7RTsytw.cjs +20 -0
  35. package/components/area-chart-options.nl-zW_03PWa.js +95 -0
  36. package/components/area-chart-positioning.config-DDMlv_1g.js +55 -0
  37. package/components/area-chart-positioning.config-DgIFeUfD.cjs +20 -0
  38. package/components/axis-options.config-Dg9pczlQ.cjs +20 -0
  39. package/components/axis-options.config-Dv2BIt_L.js +270 -0
  40. package/components/axis-options.i18n-B4Oq86I1.cjs +20 -0
  41. package/components/axis-options.i18n-b4sAT2xv.js +486 -0
  42. package/components/bar-chart-options.config-CIoiRY3c.cjs +20 -0
  43. package/components/bar-chart-options.config-DTg8EtZB.js +266 -0
  44. package/components/bar-chart-options.de-Cx7sIY-k.js +111 -0
  45. package/components/bar-chart-options.de-D7Aam6Mv.cjs +20 -0
  46. package/components/bar-chart-options.en-CkdOHM9S.cjs +20 -0
  47. package/components/bar-chart-options.en-TmptkrCq.js +111 -0
  48. package/components/bar-chart-options.es-BOKqltQs.js +111 -0
  49. package/components/bar-chart-options.es-C3SZOSiN.cjs +20 -0
  50. package/components/bar-chart-options.fr-_QYj4ma-.js +111 -0
  51. package/components/bar-chart-options.fr-aVs2K5Qh.cjs +20 -0
  52. package/components/bar-chart-options.nl-BoGYJH70.cjs +20 -0
  53. package/components/bar-chart-options.nl-zBlLF4Am.js +111 -0
  54. package/components/bar-chart-positioning.config-CfIg055Z.js +59 -0
  55. package/components/bar-chart-positioning.config-D6pFsRHW.cjs +20 -0
  56. package/components/base-ClbyBq3g.js +248 -0
  57. package/components/base-DOqHO4T0.cjs +20 -0
  58. package/components/box-plot-options.config-rGZR7gQB.js +352 -0
  59. package/components/box-plot-options.config-zD7Csp-M.cjs +20 -0
  60. package/components/box-plot-options.de-CJ5uTyj4.cjs +20 -0
  61. package/components/box-plot-options.de-DkOqW1qm.js +108 -0
  62. package/components/box-plot-options.en-BwkPF9ow.js +108 -0
  63. package/components/box-plot-options.en-D91y5Yn2.cjs +20 -0
  64. package/components/box-plot-options.es-BE_gbUfY.cjs +20 -0
  65. package/components/box-plot-options.es-Bem6QOwX.js +108 -0
  66. package/components/box-plot-options.fr-D6uGRFn8.js +108 -0
  67. package/components/box-plot-options.fr-w8w9Ulrk.cjs +20 -0
  68. package/components/box-plot-options.nl-Dl6tln-c.cjs +20 -0
  69. package/components/box-plot-options.nl-KTVKF4-A.js +108 -0
  70. package/components/box-plot-positioning.config-55vAfMWq.cjs +20 -0
  71. package/components/box-plot-positioning.config-B4w3qGMD.js +48 -0
  72. package/components/bubble-chart-positioning.config-R9U2QcYb.cjs +20 -0
  73. package/components/bubble-chart-positioning.config-sPR3ptvR.js +55 -0
  74. package/components/bullet-chart-options.config-BHw1SMf2.cjs +20 -0
  75. package/components/bullet-chart-options.config-BMWFhdUY.js +95 -0
  76. package/components/bullet-chart-options.de-C6HTRMYV.cjs +20 -0
  77. package/components/bullet-chart-options.de-DeGc5a3k.js +47 -0
  78. package/components/bullet-chart-options.en-BCzDF69d.js +47 -0
  79. package/components/bullet-chart-options.en-C2MDX5A3.cjs +20 -0
  80. package/components/bullet-chart-options.es-CGqpJxSU.cjs +20 -0
  81. package/components/bullet-chart-options.es-D6acIGZV.js +47 -0
  82. package/components/bullet-chart-options.fr-BFtQlQrs.cjs +20 -0
  83. package/components/bullet-chart-options.fr-Bb6iNEnb.js +47 -0
  84. package/components/bullet-chart-options.nl-BSRoEom3.js +47 -0
  85. package/components/bullet-chart-options.nl-BaZDLnDS.cjs +20 -0
  86. package/components/bullet-chart-positioning.config-2TaqHX1E.cjs +20 -0
  87. package/components/bullet-chart-positioning.config-CIMnOzrw.js +56 -0
  88. package/components/choropleth-map-positioning.config-C5yUI4Kf.js +55 -0
  89. package/components/choropleth-map-positioning.config-DzRWowUN.cjs +20 -0
  90. package/components/circle-pack-chart-positioning.config-Bi8XmRUJ.js +48 -0
  91. package/components/circle-pack-chart-positioning.config-DriGXH0O.cjs +20 -0
  92. package/components/circular-gauge-positioning.config--SgX1JzM.cjs +20 -0
  93. package/components/circular-gauge-positioning.config-BcJ0YoWv.js +48 -0
  94. package/components/column-chart-options.config-TQf4dANz.cjs +20 -0
  95. package/components/column-chart-options.config-YW0LC1-g.js +265 -0
  96. package/components/column-chart-options.de-B3M7bxIf.js +111 -0
  97. package/components/column-chart-options.de-BOp0fmxj.cjs +20 -0
  98. package/components/column-chart-options.en-BBFX9b4K.js +111 -0
  99. package/components/column-chart-options.en-CkdOHM9S.cjs +20 -0
  100. package/components/column-chart-options.es-BEfuaiCj.js +111 -0
  101. package/components/column-chart-options.es-BiPP9jKx.cjs +20 -0
  102. package/components/column-chart-options.fr-DVqNXI8g.js +111 -0
  103. package/components/column-chart-options.fr-aVs2K5Qh.cjs +20 -0
  104. package/components/column-chart-options.nl-BoGYJH70.cjs +20 -0
  105. package/components/column-chart-options.nl-CinPRAJ5.js +111 -0
  106. package/components/column-chart-positioning.config-CZ0_ElCf.js +55 -0
  107. package/components/column-chart-positioning.config-Dts3D63x.cjs +20 -0
  108. package/components/combination-chart-options.config-C8SPwDDG.cjs +20 -0
  109. package/components/combination-chart-options.config-DeWB-bAh.js +157 -0
  110. package/components/combination-chart-options.de-COVn8bgM.js +74 -0
  111. package/components/combination-chart-options.de-DycthBF_.cjs +20 -0
  112. package/components/combination-chart-options.en-3zjVUwIY.js +74 -0
  113. package/components/combination-chart-options.en-BIosKCWf.cjs +20 -0
  114. package/components/combination-chart-options.es-CZ6uoD-U.cjs +20 -0
  115. package/components/combination-chart-options.es-Cl5Z-GI5.js +74 -0
  116. package/components/combination-chart-options.fr-B2NH27P6.cjs +20 -0
  117. package/components/combination-chart-options.fr-CBaz1Lhf.js +74 -0
  118. package/components/combination-chart-options.nl-B-vNeGxb.cjs +20 -0
  119. package/components/combination-chart-options.nl-D32yA2uX.js +74 -0
  120. package/components/combination-chart-positioning.config-BTNl8Q0Y.js +48 -0
  121. package/components/combination-chart-positioning.config-CM0o3yFT.cjs +20 -0
  122. package/components/conditional-number-positioning.config-C80ePFmt.js +48 -0
  123. package/components/conditional-number-positioning.config-Ce8Deg6R.cjs +20 -0
  124. package/components/data-field/index.cjs +1 -1
  125. package/components/data-field/index.js +1 -1
  126. package/components/data-field-BLgof095.cjs +54 -0
  127. package/components/data-field-DtiBQ3ec.js +119 -0
  128. package/components/data-field-level/index.cjs +1 -1
  129. package/components/data-field-level/index.js +1 -1
  130. package/components/data-field-level-8Sm39bRZ.js +245 -0
  131. package/components/data-field-level-vBzXLqit.cjs +55 -0
  132. package/components/data-field-panel/index.cjs +1 -1
  133. package/components/data-field-panel/index.js +1 -1
  134. package/components/data-field-panel-DOvbsj7k.cjs +87 -0
  135. package/components/data-field-panel-YL5pqk0y.js +383 -0
  136. package/components/data-fields-select/data-fields-select.d.ts +2 -0
  137. package/components/data-fields-select/index.cjs +1 -1
  138. package/components/data-fields-select/index.js +1 -1
  139. package/components/data-fields-select-SKpx1U5b.cjs +43 -0
  140. package/components/data-fields-select-lx0hau0V.js +293 -0
  141. package/components/dataset-selector-list/index.cjs +1 -1
  142. package/components/dataset-selector-list/index.js +1 -1
  143. package/components/dataset-selector-list-DVv3OLwc.cjs +75 -0
  144. package/components/dataset-selector-list-Dw8SseBg.js +321 -0
  145. package/components/dataset-selector-row/index.cjs +1 -1
  146. package/components/dataset-selector-row/index.js +1 -1
  147. package/components/dataset-selector-row-Dfk5cP49.cjs +104 -0
  148. package/components/dataset-selector-row-q3JwXkc7.js +448 -0
  149. package/components/date-comparison-filter-slots.config-BNgZHORP.cjs +20 -0
  150. package/components/date-comparison-filter-slots.config-CO_C1qq2.js +37 -0
  151. package/components/de-DfxglHXp.js +599 -0
  152. package/components/de-k95wCo8e.cjs +20 -0
  153. package/components/display-settings/index.cjs +1 -1
  154. package/components/display-settings/index.js +1 -1
  155. package/components/display-settings-BGU97VQm.cjs +143 -0
  156. package/components/display-settings-CW-aM6Tg.js +317 -0
  157. package/components/display-settings-binning/index.cjs +1 -1
  158. package/components/display-settings-binning/index.js +1 -1
  159. package/components/display-settings-binning-C18iQPBR.js +111 -0
  160. package/components/display-settings-binning-ChgYSZVd.cjs +56 -0
  161. package/components/display-settings-datetime/index.cjs +1 -1
  162. package/components/display-settings-datetime/index.js +1 -1
  163. package/components/display-settings-datetime-DssZrTKW.cjs +217 -0
  164. package/components/display-settings-datetime-NhrNS7pq.js +414 -0
  165. package/components/display-settings-grand-totals/index.cjs +1 -1
  166. package/components/display-settings-grand-totals/index.js +1 -1
  167. package/components/display-settings-grand-totals-CPTypeXs.cjs +44 -0
  168. package/components/display-settings-grand-totals-D0UduzQs.js +90 -0
  169. package/components/display-settings-numeric/index.cjs +1 -1
  170. package/components/display-settings-numeric/index.js +1 -1
  171. package/components/display-settings-numeric-B2AuI2qg.js +480 -0
  172. package/components/display-settings-numeric-BzWEYoHj.cjs +190 -0
  173. package/components/display-settings-period-over-period/index.cjs +1 -1
  174. package/components/display-settings-period-over-period/index.js +1 -1
  175. package/components/display-settings-period-over-period-DfXdZPP9.js +443 -0
  176. package/components/display-settings-period-over-period-Yy1voN9g.cjs +227 -0
  177. package/components/donut-chart-options.config-DAetuaMj.cjs +20 -0
  178. package/components/donut-chart-options.config-DoX09FLQ.js +226 -0
  179. package/components/donut-chart-options.de-AXRfsiXW.cjs +20 -0
  180. package/components/donut-chart-options.de-CSSodjBg.js +86 -0
  181. package/components/donut-chart-options.en-Du6sBhqy.js +86 -0
  182. package/components/donut-chart-options.en-aZqu2oEV.cjs +20 -0
  183. package/components/donut-chart-options.es-7WgxuaDe.cjs +20 -0
  184. package/components/donut-chart-options.es-BWI72OH_.js +86 -0
  185. package/components/donut-chart-options.fr-C0Z8xEyF.cjs +20 -0
  186. package/components/donut-chart-options.fr-DeUbrL1Y.js +86 -0
  187. package/components/donut-chart-options.nl-aKVLbRJY.cjs +20 -0
  188. package/components/donut-chart-options.nl-bixP46Bs.js +86 -0
  189. package/components/donut-chart-positioning.config-0z7hLOs9.js +48 -0
  190. package/components/donut-chart-positioning.config-jWQOJfuv.cjs +20 -0
  191. package/components/es-B4X3tN70.js +599 -0
  192. package/components/es-BvDMibMQ.cjs +20 -0
  193. package/components/evolution-number-options.config-B6iEr_Bp.cjs +20 -0
  194. package/components/evolution-number-options.config-BGvfrpHI.js +230 -0
  195. package/components/evolution-number-options.de-DcLx_BOR.js +76 -0
  196. package/components/evolution-number-options.de-va_ypOy6.cjs +20 -0
  197. package/components/evolution-number-options.en-Afr-jy0u.js +76 -0
  198. package/components/evolution-number-options.en-CtAX9A-5.cjs +20 -0
  199. package/components/evolution-number-options.es-BQKSc22r.js +76 -0
  200. package/components/evolution-number-options.es-CCkbdLdF.cjs +20 -0
  201. package/components/evolution-number-options.fr-97NjkE_T.js +76 -0
  202. package/components/evolution-number-options.fr-QIK5EXQs.cjs +20 -0
  203. package/components/evolution-number-options.nl-BxQ9H4Ml.js +76 -0
  204. package/components/evolution-number-options.nl-CwUSSlVi.cjs +20 -0
  205. package/components/evolution-number-positioning.config-CNwQK1ho.cjs +20 -0
  206. package/components/evolution-number-positioning.config-Ccn4319Q.js +48 -0
  207. package/components/filter-expression-picker/index.cjs +1 -1
  208. package/components/filter-expression-picker/index.js +1 -1
  209. package/components/filter-expression-picker-C5s82Kj8.cjs +40 -0
  210. package/components/filter-expression-picker-ChPk7AhZ.js +434 -0
  211. package/components/filter-item/index.cjs +1 -1
  212. package/components/filter-item/index.js +1 -1
  213. package/components/filter-item-BsUxTNwl.cjs +111 -0
  214. package/components/filter-item-CEIBzW6Y.js +793 -0
  215. package/components/filter-parameter-picker/index.cjs +1 -1
  216. package/components/filter-parameter-picker/index.js +1 -1
  217. package/components/filter-parameter-picker-CBQlNMvr.cjs +124 -0
  218. package/components/filter-parameter-picker-CMQpNcck.js +372 -0
  219. package/components/filter-value-picker/index.cjs +1 -1
  220. package/components/filter-value-picker/index.js +1 -1
  221. package/components/filter-value-picker-6UbVX8EX.cjs +69 -0
  222. package/components/filter-value-picker-CD9AfCEx.js +170 -0
  223. package/components/filter-value-picker-datetime/index.cjs +1 -1
  224. package/components/filter-value-picker-datetime/index.js +1 -1
  225. package/components/filter-value-picker-datetime-BkaNyKM5.cjs +51 -0
  226. package/components/filter-value-picker-datetime-C80_9zmR.js +160 -0
  227. package/components/filter-value-picker-hierarchy/index.cjs +1 -1
  228. package/components/filter-value-picker-hierarchy/index.js +1 -1
  229. package/components/filter-value-picker-hierarchy-Dcuq6QyL.cjs +54 -0
  230. package/components/filter-value-picker-hierarchy-DkoquwOp.js +316 -0
  231. package/components/filter-value-picker-numeric/index.cjs +1 -1
  232. package/components/filter-value-picker-numeric/index.js +1 -1
  233. package/components/filter-value-picker-numeric-BD9OX_qJ.cjs +54 -0
  234. package/components/filter-value-picker-numeric-C5FI37KY.js +237 -0
  235. package/components/filters/filters.d.ts +11 -0
  236. package/components/filters/index.cjs +1 -1
  237. package/components/filters/index.js +1 -1
  238. package/components/filters-BnH330me.js +942 -0
  239. package/components/filters-CBFB5tNm.cjs +187 -0
  240. package/components/formula/index.cjs +1 -1
  241. package/components/formula/index.js +1 -1
  242. package/components/formula--9ohJwgp.js +136 -0
  243. package/components/formula-PROK1Bg8.cjs +45 -0
  244. package/components/formula-codemirror-CF4MDQHE.js +12008 -0
  245. package/components/formula-codemirror-Q1mjfL4P.cjs +215 -0
  246. package/components/formula-display-store-B1rP7Z1I.js +1087 -0
  247. package/components/formula-display-store-kVLhQbcs.cjs +20 -0
  248. package/components/formula-editor/index.cjs +1 -1
  249. package/components/formula-editor/index.js +3 -3
  250. package/components/formula-editor-DQgpmzJD.js +685 -0
  251. package/components/formula-editor-DihYwWUJ.cjs +224 -0
  252. package/components/formula-field/index.cjs +1 -1
  253. package/components/formula-field/index.js +1 -1
  254. package/components/formula-field-3w3LUoPv.js +38 -0
  255. package/components/formula-field-D2pgnvqx.cjs +20 -0
  256. package/components/formula-input-base-BlqLDV8C.js +236 -0
  257. package/components/formula-input-base-YLUm2p_4.cjs +49 -0
  258. package/components/fr-DdBfGHSA.js +599 -0
  259. package/components/fr-RTKQS7AJ.cjs +20 -0
  260. package/components/funnel-chart-options.config-BjAeGQO1.js +220 -0
  261. package/components/funnel-chart-options.config-D2zw9c3U.cjs +20 -0
  262. package/components/funnel-chart-options.de-B2f_xxvV.cjs +20 -0
  263. package/components/funnel-chart-options.de-D677e-vT.js +77 -0
  264. package/components/funnel-chart-options.en-B7fjBNs8.js +77 -0
  265. package/components/funnel-chart-options.en-Cdvkged9.cjs +20 -0
  266. package/components/funnel-chart-options.es-CrAp7hOK.cjs +20 -0
  267. package/components/funnel-chart-options.es-CyfC7rHm.js +77 -0
  268. package/components/funnel-chart-options.fr-0RxiqeZg.cjs +20 -0
  269. package/components/funnel-chart-options.fr-BnAHH5Tc.js +77 -0
  270. package/components/funnel-chart-options.nl-DeidG7iM.js +77 -0
  271. package/components/funnel-chart-options.nl-r_wRg5qR.cjs +20 -0
  272. package/components/funnel-chart-positioning.config-CGQlxp-N.js +48 -0
  273. package/components/funnel-chart-positioning.config-CuPbQwNk.cjs +20 -0
  274. package/components/get-dataset-name-BYvHNJQ6.js +32 -0
  275. package/components/get-dataset-name-Di7POfCE.cjs +20 -0
  276. package/components/groupings-C9y28uVF.js +52 -0
  277. package/components/groupings-Djt4x-m8.cjs +20 -0
  278. package/components/heat-map-positioning.config-B4Mt-5Z-.js +48 -0
  279. package/components/heat-map-positioning.config-DhBaQp_z.cjs +20 -0
  280. package/components/heat-table-options.config-CcG12s1p.cjs +20 -0
  281. package/components/heat-table-options.config-CiAQfvyb.js +277 -0
  282. package/components/heat-table-options.de-Br9DbeCp.cjs +20 -0
  283. package/components/heat-table-options.de-CuJLYAKD.js +114 -0
  284. package/components/heat-table-options.en-BxaSIKKl.js +114 -0
  285. package/components/heat-table-options.en-Cdn-xUSD.cjs +20 -0
  286. package/components/heat-table-options.es-Dkv8Q0Gi.cjs +20 -0
  287. package/components/heat-table-options.es-IS8jBtX3.js +114 -0
  288. package/components/heat-table-options.fr-Rnhqij20.js +114 -0
  289. package/components/heat-table-options.fr-uLTRU2oE.cjs +20 -0
  290. package/components/heat-table-options.nl-Blzg45N9.js +114 -0
  291. package/components/heat-table-options.nl-DaYIbnqr.cjs +20 -0
  292. package/components/heat-table-positioning.config-CY8sBOrD.js +55 -0
  293. package/components/heat-table-positioning.config-nEY0dbDM.cjs +20 -0
  294. package/components/hexbin-map-positioning.config--wq1zdhz.js +48 -0
  295. package/components/hexbin-map-positioning.config-DdWya10E.cjs +20 -0
  296. package/components/index.cjs +1 -1
  297. package/components/index.js +55 -55
  298. package/components/interactive-viz-item/index.cjs +1 -1
  299. package/components/interactive-viz-item/index.js +1 -1
  300. package/components/interactive-viz-item-CMpwMtM-.cjs +261 -0
  301. package/components/interactive-viz-item-DBxAlfyo.js +528 -0
  302. package/components/item-grid/index.cjs +1 -1
  303. package/components/item-grid/index.js +2 -2
  304. package/components/item-grid-DMCkHIh_.cjs +41 -0
  305. package/components/item-grid-NWnUnlNW.js +245 -0
  306. package/components/item-grid-item-actions-menu/index.cjs +1 -1
  307. package/components/item-grid-item-actions-menu/index.js +1 -1
  308. package/components/item-grid-item-actions-menu-CnC_fFq4.cjs +52 -0
  309. package/components/item-grid-item-actions-menu-DfA4PKM9.js +199 -0
  310. package/components/item-option/index.cjs +1 -1
  311. package/components/item-option/index.js +1 -1
  312. package/components/item-option-CFSZXwLt.cjs +269 -0
  313. package/components/item-option-YpwMa7la.js +959 -0
  314. package/components/item-option-action-button-group/index.cjs +1 -1
  315. package/components/item-option-action-button-group/index.js +1 -1
  316. package/components/item-option-action-button-group-BLoh0dmU.js +117 -0
  317. package/components/item-option-action-button-group-Dg87SFd8.cjs +53 -0
  318. package/components/item-option-base-5PYKLoC7.js +120 -0
  319. package/components/item-option-base-CY2pOzjk.cjs +56 -0
  320. package/components/item-option-color-palette-picker/index.cjs +1 -1
  321. package/components/item-option-color-palette-picker/index.js +1 -1
  322. package/components/item-option-color-palette-picker-B0vPoYn4.js +2040 -0
  323. package/components/item-option-color-palette-picker-DfWOwc6s.cjs +40 -0
  324. package/components/item-option-color-picker/index.cjs +1 -1
  325. package/components/item-option-color-picker/index.js +1 -1
  326. package/components/item-option-color-picker-BQ1Kichc.cjs +34 -0
  327. package/components/item-option-color-picker-BgLqlgMF.js +86 -0
  328. package/components/item-option-color-range/index.cjs +1 -1
  329. package/components/item-option-color-range/index.js +1 -1
  330. package/components/item-option-color-range-AadyK2zm.cjs +98 -0
  331. package/components/item-option-color-range-r7Psy6yt.js +219 -0
  332. package/components/item-option-guidelines/index.cjs +1 -1
  333. package/components/item-option-guidelines/index.js +1 -1
  334. package/components/item-option-guidelines-Dj5vjMOy.cjs +135 -0
  335. package/components/item-option-guidelines-WfKKowZh.js +420 -0
  336. package/components/item-option-multi-language-field/index.cjs +1 -1
  337. package/components/item-option-multi-language-field/index.js +1 -1
  338. package/components/item-option-multi-language-field-Cbj5QUsQ.cjs +33 -0
  339. package/components/item-option-multi-language-field-p26WS8e2.js +81 -0
  340. package/components/item-option-number-field/index.cjs +1 -1
  341. package/components/item-option-number-field/index.js +1 -1
  342. package/components/item-option-number-field-CnZQfLko.js +101 -0
  343. package/components/item-option-number-field-DokKaZNJ.cjs +38 -0
  344. package/components/item-option-panel/index.cjs +1 -1
  345. package/components/item-option-panel/index.js +1 -1
  346. package/components/item-option-panel-Cs9BGllC.js +181 -0
  347. package/components/item-option-panel-IeqCr-0M.cjs +67 -0
  348. package/components/item-option-picker/index.cjs +1 -1
  349. package/components/item-option-picker/index.js +1 -1
  350. package/components/item-option-picker-BwZAq7t8.js +76 -0
  351. package/components/item-option-picker-DV-k1tkm.cjs +37 -0
  352. package/components/item-option-position-picker/index.cjs +1 -1
  353. package/components/item-option-position-picker/index.js +1 -1
  354. package/components/item-option-position-picker-CCikjVLj.cjs +32 -0
  355. package/components/item-option-position-picker-D5a_gcn6.js +116 -0
  356. package/components/item-option-positions-number-field/index.cjs +1 -1
  357. package/components/item-option-positions-number-field/index.js +1 -1
  358. package/components/item-option-positions-number-field-Bn8Dwath.js +165 -0
  359. package/components/item-option-positions-number-field-wcQHJTZW.cjs +49 -0
  360. package/components/item-option-radio-button-group/index.cjs +1 -1
  361. package/components/item-option-radio-button-group/index.js +1 -1
  362. package/components/item-option-radio-button-group-DiElJAIW.cjs +37 -0
  363. package/components/item-option-radio-button-group-sZ5dW5N0.js +73 -0
  364. package/components/item-option-slider/index.cjs +1 -1
  365. package/components/item-option-slider/index.js +1 -1
  366. package/components/item-option-slider-CzL6OVqv.cjs +33 -0
  367. package/components/item-option-slider-DH5Q2WZt.js +97 -0
  368. package/components/item-option-switch/index.cjs +1 -1
  369. package/components/item-option-switch/index.js +1 -1
  370. package/components/item-option-switch-DkMh3RqG.cjs +30 -0
  371. package/components/item-option-switch-p552By7W.js +68 -0
  372. package/components/item-option-text-field/index.cjs +1 -1
  373. package/components/item-option-text-field/index.js +1 -1
  374. package/components/item-option-text-field-CDFWXxCi.cjs +33 -0
  375. package/components/item-option-text-field-DXwWeQLc.js +79 -0
  376. package/components/item-options-configs.cjs +1 -1
  377. package/components/item-options-configs.js +16 -16
  378. package/components/item-slot-drop/index.cjs +1 -1
  379. package/components/item-slot-drop/index.js +1 -1
  380. package/components/item-slot-drop-B7xHip7W.js +329 -0
  381. package/components/item-slot-drop-D0aDeRzk.cjs +91 -0
  382. package/components/item-slot-drop-panel/index.cjs +1 -1
  383. package/components/item-slot-drop-panel/index.js +1 -1
  384. package/components/item-slot-drop-panel-CN14Fhl_.js +354 -0
  385. package/components/item-slot-drop-panel-PpoHWxpZ.cjs +57 -0
  386. package/components/item-slot-picker/index.cjs +1 -1
  387. package/components/item-slot-picker/index.js +1 -1
  388. package/components/item-slot-picker/item-slot-picker.d.ts +30 -2
  389. package/components/item-slot-picker-BGQn6mCM.cjs +158 -0
  390. package/components/item-slot-picker-DSliJni4.js +556 -0
  391. package/components/item-slot-picker-panel/index.cjs +1 -1
  392. package/components/item-slot-picker-panel/index.js +1 -1
  393. package/components/item-slot-picker-panel/item-slot-picker-panel.d.ts +7 -1
  394. package/components/item-slot-picker-panel-BV3WnS9j.js +451 -0
  395. package/components/item-slot-picker-panel-CZHlazfn.cjs +82 -0
  396. package/components/item-slots-configs.cjs +1 -1
  397. package/components/item-slots-configs.js +1 -1
  398. package/components/kpi-options.config-CNBlWUeE.js +334 -0
  399. package/components/kpi-options.config-DJW44vTd.cjs +20 -0
  400. package/components/kpi-options.de-BNSyszd2.cjs +20 -0
  401. package/components/kpi-options.de-DTuT_w_B.js +109 -0
  402. package/components/kpi-options.en-Bnf64PJC.js +109 -0
  403. package/components/kpi-options.en-DZkxgBCc.cjs +20 -0
  404. package/components/kpi-options.es-DQFRSRwE.cjs +20 -0
  405. package/components/kpi-options.es-a0gSVDp5.js +109 -0
  406. package/components/kpi-options.fr-BRlaWkQ_.js +109 -0
  407. package/components/kpi-options.fr-Cpm8BfZ9.cjs +20 -0
  408. package/components/kpi-options.nl-01k2djoO.js +109 -0
  409. package/components/kpi-options.nl-W4ujxuOd.cjs +20 -0
  410. package/components/kpi-positioning.config-Bo0-gfhW.cjs +20 -0
  411. package/components/kpi-positioning.config-Cg8-gz35.js +48 -0
  412. package/components/kpi-slots.config-BvTgcJ9e.cjs +20 -0
  413. package/components/kpi-slots.config-tk6nFpOZ.js +36 -0
  414. package/components/line-chart-options.config-Bmru689o.cjs +20 -0
  415. package/components/line-chart-options.config-fYL7fjSK.js +255 -0
  416. package/components/line-chart-options.de-CB8mHJhD.cjs +20 -0
  417. package/components/line-chart-options.de-CFcXltXH.js +89 -0
  418. package/components/line-chart-options.en-B2gp-KSj.js +89 -0
  419. package/components/line-chart-options.en-BrKt9W7U.cjs +20 -0
  420. package/components/line-chart-options.es-BgnNvocl.cjs +20 -0
  421. package/components/line-chart-options.es-OxOYh4jd.js +89 -0
  422. package/components/line-chart-options.fr-CHk40Imh.js +89 -0
  423. package/components/line-chart-options.fr-Jl6XdyHr.cjs +20 -0
  424. package/components/line-chart-options.nl-C6ncBb5a.js +89 -0
  425. package/components/line-chart-options.nl-esSfBoBW.cjs +20 -0
  426. package/components/line-chart-positioning.config-Bb87MKxZ.cjs +20 -0
  427. package/components/line-chart-positioning.config-UEksxjo2.js +55 -0
  428. package/components/localized-mixin-DdMOQmkW.cjs +20 -0
  429. package/components/localized-mixin-Dv4dT_Qo.js +45 -0
  430. package/components/marker-map-positioning.config-3Vbat2pI.js +48 -0
  431. package/components/marker-map-positioning.config-CFmqWXOL.cjs +20 -0
  432. package/components/nl-CA2Q5zqK.cjs +20 -0
  433. package/components/nl-Dvklxh6k.js +599 -0
  434. package/components/ohlc-chart-options.config-C2Ki7XH3.cjs +20 -0
  435. package/components/ohlc-chart-options.config-DpYG3lZD.js +94 -0
  436. package/components/ohlc-chart-positioning.config-CPXmE2C6.js +78 -0
  437. package/components/ohlc-chart-positioning.config-DPG62QFZ.cjs +20 -0
  438. package/components/parallel-coordinates-plot-positioning.config-CiHl_5PC.js +48 -0
  439. package/components/parallel-coordinates-plot-positioning.config-GLUY-_3r.cjs +20 -0
  440. package/components/pivot-table-positioning.config-CBckdPF6.cjs +20 -0
  441. package/components/pivot-table-positioning.config-DlaxbJDe.js +55 -0
  442. package/components/pyramid-chart-options.config-BCBDjb4p.js +222 -0
  443. package/components/pyramid-chart-options.config-CCts-5RK.cjs +20 -0
  444. package/components/pyramid-chart-options.de-DF-c80dq.js +103 -0
  445. package/components/pyramid-chart-options.de-DuOpsLs5.cjs +20 -0
  446. package/components/pyramid-chart-options.en-C3DkPcBH.cjs +20 -0
  447. package/components/pyramid-chart-options.en-CUA9TibF.js +103 -0
  448. package/components/pyramid-chart-options.es-DOU8E08a.js +103 -0
  449. package/components/pyramid-chart-options.es-DWJdStho.cjs +20 -0
  450. package/components/pyramid-chart-options.fr-DqUZ4U9J.js +103 -0
  451. package/components/pyramid-chart-options.fr-Wb5tFvLC.cjs +20 -0
  452. package/components/pyramid-chart-options.nl-8nKaQ7cp.js +103 -0
  453. package/components/pyramid-chart-options.nl-Csec8VMp.cjs +20 -0
  454. package/components/pyramid-chart-positioning.config-B_hdKwE-.cjs +20 -0
  455. package/components/pyramid-chart-positioning.config-DIttV8Bd.js +55 -0
  456. package/components/radar-chart-options.config-BR1P1bC2.cjs +20 -0
  457. package/components/radar-chart-options.config-Cso1juLq.js +173 -0
  458. package/components/radar-chart-options.de-Er7fpAGV.cjs +20 -0
  459. package/components/radar-chart-options.de-vQACT9qo.js +54 -0
  460. package/components/radar-chart-options.en-BEJDfdE6.cjs +20 -0
  461. package/components/radar-chart-options.en-DPzqlJP6.js +54 -0
  462. package/components/radar-chart-options.es-CYh8qQtu.js +54 -0
  463. package/components/radar-chart-options.es-L88u7bqn.cjs +20 -0
  464. package/components/radar-chart-options.fr-CslMsBcG.cjs +20 -0
  465. package/components/radar-chart-options.fr-xpzxqPGa.js +54 -0
  466. package/components/radar-chart-options.nl-03B6BgO1.js +54 -0
  467. package/components/radar-chart-options.nl-CIvGrz_A.cjs +20 -0
  468. package/components/radar-chart-positioning.config-BCmKaEU3.cjs +20 -0
  469. package/components/radar-chart-positioning.config-SuMx33Rb.js +55 -0
  470. package/components/route-map-positioning.config-BHgJfD2W.cjs +20 -0
  471. package/components/route-map-positioning.config-os7LBECw.js +66 -0
  472. package/components/sankey-diagram-positioning.config-BkZ-z93h.cjs +20 -0
  473. package/components/sankey-diagram-positioning.config-CefPXYny.js +66 -0
  474. package/components/scatter-plot-options.config-BjkL6NKA.js +165 -0
  475. package/components/scatter-plot-options.config-iJwa8WRA.cjs +20 -0
  476. package/components/scatter-plot-options.de-CUPe1USU.cjs +20 -0
  477. package/components/scatter-plot-options.de-DiT6Dfgy.js +115 -0
  478. package/components/scatter-plot-options.en-DaPAnBDH.js +115 -0
  479. package/components/scatter-plot-options.en-aCHwE_2o.cjs +20 -0
  480. package/components/scatter-plot-options.es-B2sIEexr.cjs +20 -0
  481. package/components/scatter-plot-options.es-DKVASEN4.js +115 -0
  482. package/components/scatter-plot-options.fr-B-7GyEXc.cjs +20 -0
  483. package/components/scatter-plot-options.fr-DPt3Ffoy.js +115 -0
  484. package/components/scatter-plot-options.nl-B5ytQ1Si.js +115 -0
  485. package/components/scatter-plot-options.nl-Cz-6m7sg.cjs +20 -0
  486. package/components/scatter-plot-positioning.config-Cj97qUBu.cjs +20 -0
  487. package/components/scatter-plot-positioning.config-tPnsj0Bi.js +77 -0
  488. package/components/set-locale-4ytzZDhn.cjs +20 -0
  489. package/components/set-locale-w6Y3RUvf.js +43 -0
  490. package/components/slicer-filter-positioning.config-Bh_p1GYx.js +48 -0
  491. package/components/slicer-filter-positioning.config-CS51YpGW.cjs +20 -0
  492. package/components/slot-content-C9m-z0Ux.js +23 -0
  493. package/components/slot-content-DYiwtIBX.cjs +20 -0
  494. package/components/slot-menu/index.cjs +1 -1
  495. package/components/slot-menu/index.js +1 -1
  496. package/components/slot-menu/slot-menu.d.ts +5 -0
  497. package/components/slot-menu-B7q15GwU.js +436 -0
  498. package/components/slot-menu-H-hVDVNW.cjs +71 -0
  499. package/components/slot-menu-list/index.cjs +1 -1
  500. package/components/slot-menu-list/index.js +1 -1
  501. package/components/slot-menu-list-C1rVkQEG.cjs +44 -0
  502. package/components/slot-menu-list-CMaf2WZ9.js +348 -0
  503. package/components/slot-role-classification-BtYLRqq0.cjs +20 -0
  504. package/components/slot-role-classification-DKClEpT3.js +133 -0
  505. package/components/slots-config-ChJNgCJz.js +77 -0
  506. package/components/slots-config-Cy9pA0wm.cjs +20 -0
  507. package/components/speedometer-chart-positioning.config-CA4mIQVz.cjs +20 -0
  508. package/components/speedometer-chart-positioning.config-DxmmNwvU.js +48 -0
  509. package/components/spike-map-positioning.config-BMnS3qbm.js +55 -0
  510. package/components/spike-map-positioning.config-Drj2qKMJ.cjs +20 -0
  511. package/components/strip-plot-positioning.config-CiGPeVyq.cjs +20 -0
  512. package/components/strip-plot-positioning.config-DOPNhBEE.js +48 -0
  513. package/components/sunburst-chart-options.config-C5ChdoMM.js +190 -0
  514. package/components/sunburst-chart-options.config-CtT-pBM0.cjs +20 -0
  515. package/components/sunburst-chart-options.de-DO65RQI_.cjs +20 -0
  516. package/components/sunburst-chart-options.de-DPRW5IB9.js +61 -0
  517. package/components/sunburst-chart-options.en-BU4abvh8.js +61 -0
  518. package/components/sunburst-chart-options.en-C3IkkUBW.cjs +20 -0
  519. package/components/sunburst-chart-options.es-BV_4fN10.cjs +20 -0
  520. package/components/sunburst-chart-options.es-Bo65ZQ0Y.js +61 -0
  521. package/components/sunburst-chart-options.fr-5_0gm7hs.js +61 -0
  522. package/components/sunburst-chart-options.fr-DO7-oeNe.cjs +20 -0
  523. package/components/sunburst-chart-options.nl-Bcqm8ykQ.js +61 -0
  524. package/components/sunburst-chart-options.nl-DsecjcfE.cjs +20 -0
  525. package/components/sunburst-chart-positioning.config-CveUDnv_.cjs +20 -0
  526. package/components/sunburst-chart-positioning.config-cwQaxuYH.js +48 -0
  527. package/components/symbol-map-positioning.config-CUaCGtpk.cjs +20 -0
  528. package/components/symbol-map-positioning.config-W6EMKyLL.js +55 -0
  529. package/components/treemap-chart-positioning.config-CynNsRhu.cjs +20 -0
  530. package/components/treemap-chart-positioning.config-bQdU3kX_.js +55 -0
  531. package/components/utils/base.cjs +1 -1
  532. package/components/utils/base.js +2 -2
  533. package/components/utils/store.cjs +1 -1
  534. package/components/utils/store.js +1 -1
  535. package/components/utils-1zaS4yM5.js +240 -0
  536. package/components/utils-B_KSNNkR.cjs +20 -0
  537. package/components/utils.cjs +1 -1
  538. package/components/utils.js +2 -2
  539. package/components/venn-diagram-positioning.config-Bv5zft18.js +55 -0
  540. package/components/venn-diagram-positioning.config-CZv8APyM.cjs +20 -0
  541. package/components/wordcloud-chart-positioning.config-BrbvVug5.cjs +20 -0
  542. package/components/wordcloud-chart-positioning.config-C0lpiEgP.js +55 -0
  543. package/custom-elements.json +272 -5
  544. package/package.json +2 -2
  545. package/react/components/ai-chat.component.ts +5 -2
  546. package/react/esm/components/ai-chat.component.d.ts +3 -1
  547. package/react/esm/components/ai-chat.component.js +3 -1
  548. package/react/luzmo-stub.d.ts +1 -0
  549. package/react/package.json +2 -2
  550. package/standalone/chunks/add-to-dashboard-BlrZ08qE.js +148 -0
  551. package/standalone/chunks/area-chart-options.config-BMvUma_d.js +2 -0
  552. package/standalone/chunks/area-chart-options.de-CiUYKjuF.js +2 -0
  553. package/standalone/chunks/area-chart-options.en-ClANS4ox.js +2 -0
  554. package/standalone/chunks/area-chart-options.es-CJ9G7w-d.js +2 -0
  555. package/standalone/chunks/area-chart-options.fr-HT5lv1Xa.js +2 -0
  556. package/standalone/chunks/area-chart-options.nl-BLkEkEtR.js +2 -0
  557. package/standalone/chunks/axis-options.config-DOE0YdaK.js +2 -0
  558. package/standalone/chunks/axis-options.i18n-WUQx3mVm.js +2 -0
  559. package/standalone/chunks/bar-chart-options.config-BpHqXBFq.js +2 -0
  560. package/standalone/chunks/bar-chart-options.de-BFaQAeSt.js +2 -0
  561. package/standalone/chunks/bar-chart-options.en-uZbbpK84.js +2 -0
  562. package/standalone/chunks/bar-chart-options.es-twNx5B2m.js +2 -0
  563. package/standalone/chunks/bar-chart-options.fr-DRaaaSSH.js +2 -0
  564. package/standalone/chunks/bar-chart-options.nl-CJiMjH5v.js +2 -0
  565. package/standalone/chunks/base-Bo6Un1Yu.js +2 -0
  566. package/standalone/chunks/box-plot-options.config-DDWb_KmV.js +2 -0
  567. package/standalone/chunks/box-plot-options.de-CI5qJAF7.js +2 -0
  568. package/standalone/chunks/box-plot-options.en-BQtMNcl5.js +2 -0
  569. package/standalone/chunks/box-plot-options.es-CHjivUoY.js +2 -0
  570. package/standalone/chunks/box-plot-options.fr-FkvAk1kX.js +2 -0
  571. package/standalone/chunks/box-plot-options.nl-BRnSzvbY.js +2 -0
  572. package/standalone/chunks/bullet-chart-options.config-BhYe0N0o.js +2 -0
  573. package/standalone/chunks/bullet-chart-options.de-kCP9VTDJ.js +2 -0
  574. package/standalone/chunks/bullet-chart-options.en-CQ7u24xM.js +2 -0
  575. package/standalone/chunks/bullet-chart-options.es-CMRwpRyH.js +2 -0
  576. package/standalone/chunks/bullet-chart-options.fr-NLzgxbaB.js +2 -0
  577. package/standalone/chunks/bullet-chart-options.nl-BxNIes0u.js +2 -0
  578. package/standalone/chunks/column-chart-options.config-YIe6cMV5.js +2 -0
  579. package/standalone/chunks/column-chart-options.de-CpCK5x2F.js +2 -0
  580. package/standalone/chunks/column-chart-options.en-uZbbpK84.js +2 -0
  581. package/standalone/chunks/column-chart-options.es-CNgSUKXK.js +2 -0
  582. package/standalone/chunks/column-chart-options.fr-DRaaaSSH.js +2 -0
  583. package/standalone/chunks/column-chart-options.nl-CJiMjH5v.js +2 -0
  584. package/standalone/chunks/combination-chart-options.config-Bf7cNmpc.js +2 -0
  585. package/standalone/chunks/combination-chart-options.de-BarapFn7.js +2 -0
  586. package/standalone/chunks/combination-chart-options.en-Dip8nNUE.js +2 -0
  587. package/standalone/chunks/combination-chart-options.es-3xQbg-Up.js +2 -0
  588. package/standalone/chunks/combination-chart-options.fr-BsXLtxB_.js +2 -0
  589. package/standalone/chunks/combination-chart-options.nl-8LA_bn9G.js +2 -0
  590. package/standalone/chunks/date-comparison-filter-slots.config-GxZF3vb3.js +2 -0
  591. package/standalone/chunks/de-DNm8GJah.js +2 -0
  592. package/standalone/chunks/display-settings-binning-BcAygd33.js +38 -0
  593. package/standalone/chunks/display-settings-datetime-C-c7VS62.js +199 -0
  594. package/standalone/chunks/display-settings-grand-totals-CHUPJMiO.js +26 -0
  595. package/standalone/chunks/display-settings-numeric-CwIsAjlA.js +172 -0
  596. package/standalone/chunks/display-settings-period-over-period-Dgr8fANF.js +209 -0
  597. package/standalone/chunks/donut-chart-options.config-DWpePR5V.js +2 -0
  598. package/standalone/chunks/donut-chart-options.de-IKGJRoDL.js +2 -0
  599. package/standalone/chunks/donut-chart-options.en-O2IK3YiS.js +2 -0
  600. package/standalone/chunks/donut-chart-options.es-gKAHuFAU.js +2 -0
  601. package/standalone/chunks/donut-chart-options.fr-Q-uMrtQG.js +2 -0
  602. package/standalone/chunks/donut-chart-options.nl-B6v6jK4l.js +2 -0
  603. package/standalone/chunks/embed-NStEUFPE.js +228 -0
  604. package/standalone/chunks/es-BKlgDDOM.js +2 -0
  605. package/standalone/chunks/evolution-number-options.config-Brbyq_TD.js +2 -0
  606. package/standalone/chunks/evolution-number-options.de-NPOdl5mB.js +2 -0
  607. package/standalone/chunks/evolution-number-options.en-Eq53ZOMK.js +2 -0
  608. package/standalone/chunks/evolution-number-options.es-WS8nAzvW.js +2 -0
  609. package/standalone/chunks/evolution-number-options.fr-DmcY0jGH.js +2 -0
  610. package/standalone/chunks/evolution-number-options.nl-CvjB2qil.js +2 -0
  611. package/standalone/chunks/filters-BqUlasEq.js +532 -0
  612. package/standalone/chunks/formula-codemirror-CJ8OazqM.js +197 -0
  613. package/standalone/chunks/fr-CYhAyq_i.js +2 -0
  614. package/standalone/chunks/funnel-chart-options.config-S1yxc6IG.js +2 -0
  615. package/standalone/chunks/funnel-chart-options.de-u5OrFyng.js +2 -0
  616. package/standalone/chunks/funnel-chart-options.en-BEGSBn35.js +2 -0
  617. package/standalone/chunks/funnel-chart-options.es-CxWkEgMs.js +2 -0
  618. package/standalone/chunks/funnel-chart-options.fr-DZmmgK2t.js +2 -0
  619. package/standalone/chunks/funnel-chart-options.nl-C6BitaEJ.js +2 -0
  620. package/standalone/chunks/heat-table-options.config-BmtIS2zc.js +2 -0
  621. package/standalone/chunks/heat-table-options.de-B4y9dcra.js +2 -0
  622. package/standalone/chunks/heat-table-options.en-Bouip0NE.js +2 -0
  623. package/standalone/chunks/heat-table-options.es-BRAQP8GK.js +2 -0
  624. package/standalone/chunks/heat-table-options.fr-CTzciHeO.js +2 -0
  625. package/standalone/chunks/heat-table-options.nl-DzmWrTeQ.js +2 -0
  626. package/standalone/chunks/item-option-action-button-group-Z_QOXgGF.js +35 -0
  627. package/standalone/chunks/item-option-base-CwSzaefN.js +38 -0
  628. package/standalone/chunks/item-option-color-palette-picker-ClPI-5Hn.js +22 -0
  629. package/standalone/chunks/item-option-color-picker-1q1JlJS_.js +16 -0
  630. package/standalone/chunks/item-option-color-range-Chg6l7xN.js +80 -0
  631. package/standalone/chunks/item-option-guidelines-LNRztY8Q.js +117 -0
  632. package/standalone/chunks/item-option-multi-language-field-BaN_uPvS.js +15 -0
  633. package/standalone/chunks/item-option-number-field-DOuUp77S.js +20 -0
  634. package/standalone/chunks/item-option-panel-B1Qr4UIW.js +298 -0
  635. package/standalone/chunks/item-option-picker-Zrazb--P.js +19 -0
  636. package/standalone/chunks/item-option-position-picker-CSBgzh-h.js +14 -0
  637. package/standalone/chunks/item-option-positions-number-field-UTA1MQSS.js +31 -0
  638. package/standalone/chunks/item-option-radio-button-group-ClOt6Z30.js +19 -0
  639. package/standalone/chunks/item-option-slider-BLM_vGgf.js +15 -0
  640. package/standalone/chunks/item-option-switch-B-HFT1q3.js +12 -0
  641. package/standalone/chunks/item-option-text-field-CNQhKUVn.js +15 -0
  642. package/standalone/chunks/item-slot-picker-panel-BdW4zXxN.js +425 -0
  643. package/standalone/chunks/kpi-options.config-Brq70MGS.js +2 -0
  644. package/standalone/chunks/kpi-options.de-CJMQBEs7.js +2 -0
  645. package/standalone/chunks/kpi-options.en-BzKmi3Bd.js +2 -0
  646. package/standalone/chunks/kpi-options.es-BTmFYV0w.js +2 -0
  647. package/standalone/chunks/kpi-options.fr-mlazGpRq.js +2 -0
  648. package/standalone/chunks/kpi-options.nl-BV1eFo_U.js +2 -0
  649. package/standalone/chunks/kpi-slots.config-DAjLHdEj.js +2 -0
  650. package/standalone/chunks/line-chart-options.config--_LXaPbB.js +2 -0
  651. package/standalone/chunks/line-chart-options.de-CCCH4dI_.js +2 -0
  652. package/standalone/chunks/line-chart-options.en-BwtEj00F.js +2 -0
  653. package/standalone/chunks/line-chart-options.es-BWWaIDbd.js +2 -0
  654. package/standalone/chunks/line-chart-options.fr-Rp7fs4Id.js +2 -0
  655. package/standalone/chunks/line-chart-options.nl-DcgJ9CUw.js +2 -0
  656. package/standalone/chunks/load-data-fields-for-datasets-CH-5tbXr.js +25 -0
  657. package/standalone/chunks/load-formula-codemirror-CgSaMENO.js +6 -0
  658. package/standalone/chunks/localized-mixin-BAHP4Cln.js +2 -0
  659. package/standalone/chunks/nl-zkCduSpz.js +2 -0
  660. package/standalone/chunks/ohlc-chart-options.config-kyYOgBtR.js +2 -0
  661. package/standalone/chunks/pyramid-chart-options.config-xYIVE_ib.js +2 -0
  662. package/standalone/chunks/pyramid-chart-options.de-CaxalCcg.js +2 -0
  663. package/standalone/chunks/pyramid-chart-options.en-B-weoYGh.js +2 -0
  664. package/standalone/chunks/pyramid-chart-options.es-BahFoH3_.js +2 -0
  665. package/standalone/chunks/pyramid-chart-options.fr-DcTxsNGH.js +2 -0
  666. package/standalone/chunks/pyramid-chart-options.nl-ChImCr8r.js +2 -0
  667. package/standalone/chunks/radar-chart-options.config-CoGFqCqy.js +2 -0
  668. package/standalone/chunks/radar-chart-options.de-vruPXtB4.js +2 -0
  669. package/standalone/chunks/radar-chart-options.en-D8rstMVn.js +2 -0
  670. package/standalone/chunks/radar-chart-options.es-By21lK8S.js +2 -0
  671. package/standalone/chunks/radar-chart-options.fr-C4b5cJxg.js +2 -0
  672. package/standalone/chunks/radar-chart-options.nl-CzEi0MTf.js +2 -0
  673. package/standalone/chunks/scatter-plot-options.config-DG9Ki-mt.js +2 -0
  674. package/standalone/chunks/scatter-plot-options.de-eebqIJA1.js +2 -0
  675. package/standalone/chunks/scatter-plot-options.en-5i08biJm.js +2 -0
  676. package/standalone/chunks/scatter-plot-options.es-Bx8kHesL.js +2 -0
  677. package/standalone/chunks/scatter-plot-options.fr-DK6rPCT_.js +2 -0
  678. package/standalone/chunks/scatter-plot-options.nl-9mS62LyK.js +2 -0
  679. package/standalone/chunks/slot-content-BZhmLTG1.js +2 -0
  680. package/standalone/chunks/sunburst-chart-options.config-DOBSe3i5.js +2 -0
  681. package/standalone/chunks/sunburst-chart-options.de-D3iq4Q-m.js +2 -0
  682. package/standalone/chunks/sunburst-chart-options.en-BUJ_Pr9C.js +2 -0
  683. package/standalone/chunks/sunburst-chart-options.es-stKrKGz2.js +2 -0
  684. package/standalone/chunks/sunburst-chart-options.fr-RkBtlMNp.js +2 -0
  685. package/standalone/chunks/sunburst-chart-options.nl-BUeDNot_.js +2 -0
  686. package/standalone/chunks/version-Byoa09L1.js +2 -0
  687. package/standalone/interactive-viz-item.js +1 -1
  688. package/standalone/item-grid.js +1 -1
  689. package/standalone/manifest.json +137 -129
  690. package/types/ai-chat.types.d.ts +39 -2
  691. package/utils/store/index.d.ts +1 -0
  692. package/utils/store/tests/store-base.test.d.ts +1 -0
  693. package/components/ad-hoc-slot-content-BwcFfXCV.cjs +0 -20
  694. package/components/ad-hoc-slot-content-hSlT62VS.js +0 -29
  695. package/components/add-to-dashboard-BY70QBzE.js +0 -805
  696. package/components/add-to-dashboard-nYUaDghN.cjs +0 -166
  697. package/components/ai-chat-DfuJOWao.cjs +0 -338
  698. package/components/ai-chat-DmDtBF47.js +0 -4325
  699. package/components/ai-interaction-textarea-6ECwAdeT.js +0 -823
  700. package/components/ai-interaction-textarea-CRyyTj_B.cjs +0 -101
  701. package/components/area-chart-options.config-Bf5kti7Z.cjs +0 -20
  702. package/components/area-chart-options.config-DJnPr93H.js +0 -201
  703. package/components/area-chart-options.de-_tPBzxvf.cjs +0 -20
  704. package/components/area-chart-options.de-pUCTG-s0.js +0 -87
  705. package/components/area-chart-options.en-AuSHs27k.cjs +0 -20
  706. package/components/area-chart-options.en-YNsUeMwN.js +0 -87
  707. package/components/area-chart-options.es-2styw_Fz.js +0 -87
  708. package/components/area-chart-options.es-BzRHGbo6.cjs +0 -20
  709. package/components/area-chart-options.fr--WzQVf2z.js +0 -87
  710. package/components/area-chart-options.fr-DYxUQE3x.cjs +0 -20
  711. package/components/area-chart-options.nl-BTEIqBtE.js +0 -87
  712. package/components/area-chart-options.nl-M0xQQ_la.cjs +0 -20
  713. package/components/area-chart-positioning.config-CoCdjr2E.cjs +0 -20
  714. package/components/area-chart-positioning.config-o-uJPEr5.js +0 -55
  715. package/components/axis-options.config-BCP0Z8VI.js +0 -270
  716. package/components/axis-options.config-s-Js3ug-.cjs +0 -20
  717. package/components/axis-options.i18n-BOGRmWjp.js +0 -486
  718. package/components/axis-options.i18n-Cw-DmewV.cjs +0 -20
  719. package/components/bar-chart-options.config-CI17HU2I.cjs +0 -20
  720. package/components/bar-chart-options.config-D1x5WPbL.js +0 -261
  721. package/components/bar-chart-options.de-3qSh2TNr.js +0 -110
  722. package/components/bar-chart-options.de-545XMRGl.cjs +0 -20
  723. package/components/bar-chart-options.en-DAee9yHp.cjs +0 -20
  724. package/components/bar-chart-options.en-DrhQe9rV.js +0 -110
  725. package/components/bar-chart-options.es-BZ1yNzUQ.js +0 -110
  726. package/components/bar-chart-options.es-CfoAEZ-0.cjs +0 -20
  727. package/components/bar-chart-options.fr-5i13R8bs.js +0 -110
  728. package/components/bar-chart-options.fr-C2Ic0Dq0.cjs +0 -20
  729. package/components/bar-chart-options.nl-Bb6XiSDH.cjs +0 -20
  730. package/components/bar-chart-options.nl-DLj-qucU.js +0 -110
  731. package/components/bar-chart-positioning.config-CZgrS6lc.js +0 -59
  732. package/components/bar-chart-positioning.config-fsB82756.cjs +0 -20
  733. package/components/base-BmvsQ-s1.cjs +0 -20
  734. package/components/base-CrpOMVeU.js +0 -248
  735. package/components/box-plot-options.config-CooBIc6N.js +0 -334
  736. package/components/box-plot-options.config-Cp6H9fyb.cjs +0 -20
  737. package/components/box-plot-options.de-BkgscmvG.js +0 -100
  738. package/components/box-plot-options.de-alI5_N9d.cjs +0 -20
  739. package/components/box-plot-options.en-5kGlvxx8.js +0 -100
  740. package/components/box-plot-options.en-DUlXF9r9.cjs +0 -20
  741. package/components/box-plot-options.es-CIm06Gpk.cjs +0 -20
  742. package/components/box-plot-options.es-v_B9Xb9H.js +0 -100
  743. package/components/box-plot-options.fr-C5j-Dzj6.cjs +0 -20
  744. package/components/box-plot-options.fr-CRSOCgU5.js +0 -100
  745. package/components/box-plot-options.nl-DtnBbRo5.cjs +0 -20
  746. package/components/box-plot-options.nl-ZQjVZPau.js +0 -100
  747. package/components/box-plot-positioning.config-BMfGGDfe.cjs +0 -20
  748. package/components/box-plot-positioning.config-CDq460FI.js +0 -48
  749. package/components/bubble-chart-positioning.config-C9MmTtTX.cjs +0 -20
  750. package/components/bubble-chart-positioning.config-DWfz4tud.js +0 -55
  751. package/components/bullet-chart-options.config-CBmbmhzI.js +0 -76
  752. package/components/bullet-chart-options.config-Drv0yQ4x.cjs +0 -20
  753. package/components/bullet-chart-options.de-DHqxFlm7.js +0 -39
  754. package/components/bullet-chart-options.de-DQhoZIdV.cjs +0 -20
  755. package/components/bullet-chart-options.en-6vj0tO4B.js +0 -39
  756. package/components/bullet-chart-options.en-CTpxw73t.cjs +0 -20
  757. package/components/bullet-chart-options.es-Cc4GzyJG.cjs +0 -20
  758. package/components/bullet-chart-options.es-DeDFLO8Z.js +0 -39
  759. package/components/bullet-chart-options.fr-750sl4sT.js +0 -39
  760. package/components/bullet-chart-options.fr-D2Z5WBfJ.cjs +0 -20
  761. package/components/bullet-chart-options.nl-B7tw2hO6.cjs +0 -20
  762. package/components/bullet-chart-options.nl-CS-xSSVr.js +0 -39
  763. package/components/bullet-chart-positioning.config-BwHPM5ui.cjs +0 -20
  764. package/components/bullet-chart-positioning.config-DmSlVIjL.js +0 -56
  765. package/components/choropleth-map-positioning.config-C0m6zzD3.cjs +0 -20
  766. package/components/choropleth-map-positioning.config-cjBzi_Db.js +0 -55
  767. package/components/circle-pack-chart-positioning.config-BAFFQSHe.cjs +0 -20
  768. package/components/circle-pack-chart-positioning.config-CY2rLb57.js +0 -48
  769. package/components/circular-gauge-positioning.config-6pZUNxYa.js +0 -48
  770. package/components/circular-gauge-positioning.config-BfWAjAY2.cjs +0 -20
  771. package/components/column-chart-options.config-B2LIl9lL.js +0 -260
  772. package/components/column-chart-options.config-xmSH4NKF.cjs +0 -20
  773. package/components/column-chart-options.de-BX13JkAO.cjs +0 -20
  774. package/components/column-chart-options.de-CIYtauiG.js +0 -110
  775. package/components/column-chart-options.en-BkAsfXYV.js +0 -110
  776. package/components/column-chart-options.en-DAee9yHp.cjs +0 -20
  777. package/components/column-chart-options.es-CClMQLE-.cjs +0 -20
  778. package/components/column-chart-options.es-jWM7TxS7.js +0 -110
  779. package/components/column-chart-options.fr-BB6301nS.js +0 -110
  780. package/components/column-chart-options.fr-C2Ic0Dq0.cjs +0 -20
  781. package/components/column-chart-options.nl-Bb6XiSDH.cjs +0 -20
  782. package/components/column-chart-options.nl-HUMDgKdl.js +0 -110
  783. package/components/column-chart-positioning.config-hrAvNd7T.js +0 -55
  784. package/components/column-chart-positioning.config-xgRuA_l5.cjs +0 -20
  785. package/components/combination-chart-options.config-0ATFph8S.js +0 -139
  786. package/components/combination-chart-options.config-IEamJGCp.cjs +0 -20
  787. package/components/combination-chart-options.de-BiGjuWUS.cjs +0 -20
  788. package/components/combination-chart-options.de-DVJ9sfLC.js +0 -66
  789. package/components/combination-chart-options.en-B5piXq82.js +0 -66
  790. package/components/combination-chart-options.en-e4XMalU0.cjs +0 -20
  791. package/components/combination-chart-options.es-BmuyyP32.js +0 -66
  792. package/components/combination-chart-options.es-OXb8nozF.cjs +0 -20
  793. package/components/combination-chart-options.fr-CIrnpWEu.js +0 -66
  794. package/components/combination-chart-options.fr-CYzANyZs.cjs +0 -20
  795. package/components/combination-chart-options.nl-BDJ7t0BY.js +0 -66
  796. package/components/combination-chart-options.nl-DyAUjvqC.cjs +0 -20
  797. package/components/combination-chart-positioning.config-BI8HroaG.js +0 -48
  798. package/components/combination-chart-positioning.config-D0TU4hge.cjs +0 -20
  799. package/components/conditional-number-positioning.config-B_yISWne.cjs +0 -20
  800. package/components/conditional-number-positioning.config-CWaDhMLA.js +0 -48
  801. package/components/data-field-D4YFqg1H.js +0 -119
  802. package/components/data-field-Hi-ITTzx.cjs +0 -54
  803. package/components/data-field-level-BWQPtFP5.cjs +0 -55
  804. package/components/data-field-level-CB5GtdU5.js +0 -245
  805. package/components/data-field-panel-64HoViNT.js +0 -383
  806. package/components/data-field-panel-DzKwmQi_.cjs +0 -87
  807. package/components/data-fields-select-BOwoWq0j.js +0 -290
  808. package/components/data-fields-select-DXv6PQHG.cjs +0 -43
  809. package/components/dataset-selector-list-DFC2bvn0.js +0 -321
  810. package/components/dataset-selector-list-_AL1-GWw.cjs +0 -75
  811. package/components/dataset-selector-row-By2ko-Rd.cjs +0 -104
  812. package/components/dataset-selector-row-DC6mrVyF.js +0 -448
  813. package/components/date-comparison-filter-slots.config-BKZ13uzB.js +0 -33
  814. package/components/date-comparison-filter-slots.config-oABOLs3D.cjs +0 -20
  815. package/components/de-CjQMTFtl.cjs +0 -20
  816. package/components/de-Yl3kqB03.js +0 -594
  817. package/components/display-settings-B2V_F_CU.cjs +0 -142
  818. package/components/display-settings-BsCKV9ae.js +0 -316
  819. package/components/display-settings-binning-BdtxayZT.cjs +0 -56
  820. package/components/display-settings-binning-CkrbhPVB.js +0 -111
  821. package/components/display-settings-datetime-CpFyrcGk.cjs +0 -217
  822. package/components/display-settings-datetime-mVh5Tjrx.js +0 -414
  823. package/components/display-settings-grand-totals-CwOGoE06.cjs +0 -44
  824. package/components/display-settings-grand-totals-D7unOEKl.js +0 -90
  825. package/components/display-settings-numeric-DDZyFNFF.js +0 -480
  826. package/components/display-settings-numeric-DhiXPU3f.cjs +0 -190
  827. package/components/display-settings-period-over-period-BNFjbgP0.cjs +0 -227
  828. package/components/display-settings-period-over-period-Hd172SzT.js +0 -443
  829. package/components/donut-chart-options.config-C8wpZzyJ.js +0 -217
  830. package/components/donut-chart-options.config-LbmJpNlm.cjs +0 -20
  831. package/components/donut-chart-options.de-MwhxVUQU.cjs +0 -20
  832. package/components/donut-chart-options.de-yLZjyrqC.js +0 -85
  833. package/components/donut-chart-options.en-CtvZekZO.js +0 -85
  834. package/components/donut-chart-options.en-Z9kCIcjz.cjs +0 -20
  835. package/components/donut-chart-options.es-C89OYrl4.js +0 -85
  836. package/components/donut-chart-options.es-Ch83fRxI.cjs +0 -20
  837. package/components/donut-chart-options.fr-B7JWWsro.cjs +0 -20
  838. package/components/donut-chart-options.fr-Cy4UUjdS.js +0 -85
  839. package/components/donut-chart-options.nl-BT6vFbJ5.js +0 -85
  840. package/components/donut-chart-options.nl-Brxyw7wD.cjs +0 -20
  841. package/components/donut-chart-positioning.config-B2CrxOig.js +0 -48
  842. package/components/donut-chart-positioning.config-DQb53kWI.cjs +0 -20
  843. package/components/es-Ctf1SIsp.js +0 -594
  844. package/components/es-DmmTP7D0.cjs +0 -20
  845. package/components/evolution-number-options.config-Ca9ABNVM.js +0 -230
  846. package/components/evolution-number-options.config-CoGBgLLw.cjs +0 -20
  847. package/components/evolution-number-options.de-BrdcqfjF.js +0 -76
  848. package/components/evolution-number-options.de-CjNBpzAw.cjs +0 -20
  849. package/components/evolution-number-options.en-B9BpR4nq.cjs +0 -20
  850. package/components/evolution-number-options.en-Sd6L4_T9.js +0 -76
  851. package/components/evolution-number-options.es-CxbiY9G6.cjs +0 -20
  852. package/components/evolution-number-options.es-RgSav5iQ.js +0 -76
  853. package/components/evolution-number-options.fr-BD73JeDU.js +0 -76
  854. package/components/evolution-number-options.fr-Cae20bgZ.cjs +0 -20
  855. package/components/evolution-number-options.nl-BJ-5M5kB.cjs +0 -20
  856. package/components/evolution-number-options.nl-WHBQ04_S.js +0 -76
  857. package/components/evolution-number-positioning.config-BdH8pv6_.js +0 -48
  858. package/components/evolution-number-positioning.config-BzBsGcD4.cjs +0 -20
  859. package/components/filter-expression-picker-Bn_jAdQX.cjs +0 -40
  860. package/components/filter-expression-picker-Cjr8xWxy.js +0 -434
  861. package/components/filter-item-CHJDVOju.cjs +0 -111
  862. package/components/filter-item-D6y8eCmG.js +0 -793
  863. package/components/filter-parameter-picker-C955tF0T.js +0 -372
  864. package/components/filter-parameter-picker-jyrh3POQ.cjs +0 -124
  865. package/components/filter-value-picker-B8nA8hTV.js +0 -170
  866. package/components/filter-value-picker-DmWiNLZH.cjs +0 -69
  867. package/components/filter-value-picker-datetime-BAhXn1BS.js +0 -160
  868. package/components/filter-value-picker-datetime-U4XWKSFx.cjs +0 -51
  869. package/components/filter-value-picker-hierarchy-1ya1_rS3.cjs +0 -54
  870. package/components/filter-value-picker-hierarchy-CUPz5Ggs.js +0 -316
  871. package/components/filter-value-picker-numeric-D8mLaxzj.js +0 -237
  872. package/components/filter-value-picker-numeric-DrHdHj31.cjs +0 -54
  873. package/components/filters-Byy8HE19.js +0 -927
  874. package/components/filters-C8xz8DV-.cjs +0 -199
  875. package/components/formula-C6dPJyKm.cjs +0 -45
  876. package/components/formula-D_ipR6d1.js +0 -136
  877. package/components/formula-codemirror-C1UFMf6i.cjs +0 -215
  878. package/components/formula-codemirror-CdlIly66.js +0 -12008
  879. package/components/formula-display-store-B0ifmvCi.cjs +0 -20
  880. package/components/formula-display-store-CfObcBCd.js +0 -1087
  881. package/components/formula-editor-B9ikCsLK.cjs +0 -224
  882. package/components/formula-editor-DJ-0AVCl.js +0 -685
  883. package/components/formula-field-Bq-RYt0H.js +0 -38
  884. package/components/formula-field-CNqn6Xbh.cjs +0 -20
  885. package/components/formula-input-base-Dple-9bo.js +0 -236
  886. package/components/formula-input-base-KSmmN1uI.cjs +0 -49
  887. package/components/fr-DKDPLLAZ.cjs +0 -20
  888. package/components/fr-zWhjQv4B.js +0 -594
  889. package/components/funnel-chart-options.config-CygQsQVD.js +0 -211
  890. package/components/funnel-chart-options.config-DgpM8mWb.cjs +0 -20
  891. package/components/funnel-chart-options.de-CW29wkd4.cjs +0 -20
  892. package/components/funnel-chart-options.de-DIoKO3fr.js +0 -76
  893. package/components/funnel-chart-options.en-CGVFwHzU.cjs +0 -20
  894. package/components/funnel-chart-options.en-Doj4mREG.js +0 -76
  895. package/components/funnel-chart-options.es-Bcot5MS3.cjs +0 -20
  896. package/components/funnel-chart-options.es-D-GP_b6C.js +0 -76
  897. package/components/funnel-chart-options.fr-7ZROacsE.cjs +0 -20
  898. package/components/funnel-chart-options.fr-BoQkeuls.js +0 -76
  899. package/components/funnel-chart-options.nl-C0VZ6Ure.cjs +0 -20
  900. package/components/funnel-chart-options.nl-CRq-RjxK.js +0 -76
  901. package/components/funnel-chart-positioning.config-DgRle8n1.js +0 -48
  902. package/components/funnel-chart-positioning.config-DleNZIG-.cjs +0 -20
  903. package/components/get-dataset-name-3UfKdy0m.cjs +0 -20
  904. package/components/get-dataset-name-trrlomzY.js +0 -32
  905. package/components/groupings-B55Oba6e.js +0 -52
  906. package/components/groupings-DEpTt8DV.cjs +0 -20
  907. package/components/heat-map-positioning.config-BTabq_f9.js +0 -48
  908. package/components/heat-map-positioning.config-DCB3Eagz.cjs +0 -20
  909. package/components/heat-table-options.config-AhmEjDAb.cjs +0 -20
  910. package/components/heat-table-options.config-x-KBTZo1.js +0 -269
  911. package/components/heat-table-options.de-D16uyY3b.cjs +0 -20
  912. package/components/heat-table-options.de-PCwpTsHu.js +0 -112
  913. package/components/heat-table-options.en-DCNhZ0Qw.js +0 -112
  914. package/components/heat-table-options.en-Dhd_yZdX.cjs +0 -20
  915. package/components/heat-table-options.es-DPqviw02.cjs +0 -20
  916. package/components/heat-table-options.es-Dhtu0ztS.js +0 -112
  917. package/components/heat-table-options.fr-BVwdrQWA.cjs +0 -20
  918. package/components/heat-table-options.fr-dtKsuwpe.js +0 -112
  919. package/components/heat-table-options.nl-BAiKDY6k.cjs +0 -20
  920. package/components/heat-table-options.nl-Bc0JFpfk.js +0 -112
  921. package/components/heat-table-positioning.config-Dnu133l4.cjs +0 -20
  922. package/components/heat-table-positioning.config-pK8Wn1dw.js +0 -55
  923. package/components/hexbin-map-positioning.config-DjYp-lX8.js +0 -48
  924. package/components/hexbin-map-positioning.config-IqRt8f29.cjs +0 -20
  925. package/components/interactive-viz-item-CM-LoEa5.cjs +0 -261
  926. package/components/interactive-viz-item-D6lWVMHb.js +0 -528
  927. package/components/item-grid-CbXKsQm4.js +0 -245
  928. package/components/item-grid-DTishUCb.cjs +0 -41
  929. package/components/item-grid-item-actions-menu-B7ylgTwO.js +0 -199
  930. package/components/item-grid-item-actions-menu-C3BUxZJc.cjs +0 -52
  931. package/components/item-option-BTSV33ft.cjs +0 -269
  932. package/components/item-option-BUju6ZE1.js +0 -953
  933. package/components/item-option-action-button-group-CuDeyDRi.cjs +0 -53
  934. package/components/item-option-action-button-group-DnTBh3R4.js +0 -117
  935. package/components/item-option-base-BIDIiNfI.js +0 -120
  936. package/components/item-option-base-C6RQH9M8.cjs +0 -56
  937. package/components/item-option-color-palette-picker-DbsqP2zA.js +0 -2040
  938. package/components/item-option-color-palette-picker-DsG-wxGB.cjs +0 -40
  939. package/components/item-option-color-picker-BUN5YK-t.cjs +0 -34
  940. package/components/item-option-color-picker-CKGUj3cW.js +0 -86
  941. package/components/item-option-color-range-BN81ePAI.cjs +0 -98
  942. package/components/item-option-color-range-dMehrwqA.js +0 -219
  943. package/components/item-option-guidelines-Bn1HSCgL.js +0 -420
  944. package/components/item-option-guidelines-CmPaMdqb.cjs +0 -135
  945. package/components/item-option-multi-language-field-BFgbOzMM.js +0 -81
  946. package/components/item-option-multi-language-field-Du609wC_.cjs +0 -33
  947. package/components/item-option-number-field-CDcf6_4D.js +0 -101
  948. package/components/item-option-number-field-CVAtj0UX.cjs +0 -38
  949. package/components/item-option-panel-0iHLl9-q.cjs +0 -67
  950. package/components/item-option-panel-DUlIB6qj.js +0 -181
  951. package/components/item-option-picker-ClKAGpgs.js +0 -76
  952. package/components/item-option-picker-Dkc3nd3x.cjs +0 -37
  953. package/components/item-option-position-picker-O8PpyiRv.js +0 -116
  954. package/components/item-option-position-picker-qCKh0Mfs.cjs +0 -32
  955. package/components/item-option-positions-number-field-CBx4uQ39.js +0 -165
  956. package/components/item-option-positions-number-field-Dfe4ufnF.cjs +0 -49
  957. package/components/item-option-radio-button-group-B5OVbLRg.cjs +0 -37
  958. package/components/item-option-radio-button-group-J_ZusHOP.js +0 -73
  959. package/components/item-option-slider-BDAEs7Fk.cjs +0 -33
  960. package/components/item-option-slider-V9z4qqyE.js +0 -97
  961. package/components/item-option-switch-BA4ifIHK.js +0 -68
  962. package/components/item-option-switch-Bzy2VRLg.cjs +0 -30
  963. package/components/item-option-text-field-C-sTkUre.cjs +0 -33
  964. package/components/item-option-text-field-Cf0khC48.js +0 -79
  965. package/components/item-slot-drop-D2VDgqYS.js +0 -329
  966. package/components/item-slot-drop-DrJRtG7b.cjs +0 -91
  967. package/components/item-slot-drop-panel-CCCOwtYM.js +0 -353
  968. package/components/item-slot-drop-panel-CFerKcdH.cjs +0 -57
  969. package/components/item-slot-picker-BdfYcBKT.js +0 -503
  970. package/components/item-slot-picker-aqePvZ9B.cjs +0 -174
  971. package/components/item-slot-picker-panel-DC3i7XZP.js +0 -446
  972. package/components/item-slot-picker-panel-dU6NywBo.cjs +0 -81
  973. package/components/line-chart-options.config-C3_RnROS.js +0 -237
  974. package/components/line-chart-options.config-RTYFJQSE.cjs +0 -20
  975. package/components/line-chart-options.de-CKbHARjX.cjs +0 -20
  976. package/components/line-chart-options.de-CtxTZ-Nx.js +0 -81
  977. package/components/line-chart-options.en-BgXtU92P.js +0 -81
  978. package/components/line-chart-options.en-DmtT3Hbw.cjs +0 -20
  979. package/components/line-chart-options.es--u7QlrhG.js +0 -81
  980. package/components/line-chart-options.es-BwyQviz-.cjs +0 -20
  981. package/components/line-chart-options.fr-BUwOFGR7.cjs +0 -20
  982. package/components/line-chart-options.fr-BaPc1M70.js +0 -81
  983. package/components/line-chart-options.nl-BkPXShNF.cjs +0 -20
  984. package/components/line-chart-options.nl-C86fSn7a.js +0 -81
  985. package/components/line-chart-positioning.config-BW19v66B.js +0 -55
  986. package/components/line-chart-positioning.config-DX5mLAP7.cjs +0 -20
  987. package/components/localized-mixin-Bt25Frg1.cjs +0 -20
  988. package/components/localized-mixin-CYMFnS-n.js +0 -45
  989. package/components/marker-map-positioning.config-BJGwlWKz.js +0 -48
  990. package/components/marker-map-positioning.config-C0V5LZG-.cjs +0 -20
  991. package/components/nl-BrjaaktE.cjs +0 -20
  992. package/components/nl-TUFktGm6.js +0 -594
  993. package/components/ohlc-chart-options.config-CWRI5bXI.js +0 -94
  994. package/components/ohlc-chart-options.config-Pqd5MFIv.cjs +0 -20
  995. package/components/ohlc-chart-positioning.config-Bu1_IBVK.cjs +0 -20
  996. package/components/ohlc-chart-positioning.config-CFvbZzCR.js +0 -78
  997. package/components/parallel-coordinates-plot-positioning.config-Bc3qCyxq.js +0 -48
  998. package/components/parallel-coordinates-plot-positioning.config-EJz1XA1k.cjs +0 -20
  999. package/components/pivot-table-positioning.config-Bay8gxV-.js +0 -55
  1000. package/components/pivot-table-positioning.config-CMzGb-BR.cjs +0 -20
  1001. package/components/pyramid-chart-options.config-C7btzuZj.js +0 -220
  1002. package/components/pyramid-chart-options.config-ClLsv7PT.cjs +0 -20
  1003. package/components/pyramid-chart-options.de-BYqibA2g.cjs +0 -20
  1004. package/components/pyramid-chart-options.de-C7n_k-tE.js +0 -102
  1005. package/components/pyramid-chart-options.en-Cu93qdAo.js +0 -102
  1006. package/components/pyramid-chart-options.en-HiLgjfbn.cjs +0 -20
  1007. package/components/pyramid-chart-options.es-BQ8qCZ32.cjs +0 -20
  1008. package/components/pyramid-chart-options.es-DCRAv4r_.js +0 -102
  1009. package/components/pyramid-chart-options.fr-BA7xAAsG.cjs +0 -20
  1010. package/components/pyramid-chart-options.fr-CLXgcrPz.js +0 -102
  1011. package/components/pyramid-chart-options.nl-BYiPyjuQ.cjs +0 -20
  1012. package/components/pyramid-chart-options.nl-CylUmHpw.js +0 -102
  1013. package/components/pyramid-chart-positioning.config-BUSeYxYH.js +0 -55
  1014. package/components/pyramid-chart-positioning.config-CrU2vKM-.cjs +0 -20
  1015. package/components/radar-chart-options.config-B5WP2MPc.cjs +0 -20
  1016. package/components/radar-chart-options.config-CtA6MpUp.js +0 -152
  1017. package/components/radar-chart-options.de-BZPerBca.js +0 -46
  1018. package/components/radar-chart-options.de-D9sVJ3e-.cjs +0 -20
  1019. package/components/radar-chart-options.en-Brb_kgjH.cjs +0 -20
  1020. package/components/radar-chart-options.en-tDJgJQVC.js +0 -46
  1021. package/components/radar-chart-options.es-BmpV458O.cjs +0 -20
  1022. package/components/radar-chart-options.es-Dz4wRR-P.js +0 -46
  1023. package/components/radar-chart-options.fr-B-gaDJX4.cjs +0 -20
  1024. package/components/radar-chart-options.fr-D5KXeury.js +0 -46
  1025. package/components/radar-chart-options.nl-D3_CmNB3.js +0 -46
  1026. package/components/radar-chart-options.nl-DH_wKvgI.cjs +0 -20
  1027. package/components/radar-chart-positioning.config-BEzqTXyr.cjs +0 -20
  1028. package/components/radar-chart-positioning.config-DOLpdn-d.js +0 -55
  1029. package/components/route-map-positioning.config-BgjizdWh.cjs +0 -20
  1030. package/components/route-map-positioning.config-Brg6_eCi.js +0 -66
  1031. package/components/sankey-diagram-positioning.config-DJlWiNYL.js +0 -66
  1032. package/components/sankey-diagram-positioning.config-vccTz1pG.cjs +0 -20
  1033. package/components/scatter-plot-options.config-BplrME7w.js +0 -133
  1034. package/components/scatter-plot-options.config-DJW85uFv.cjs +0 -20
  1035. package/components/scatter-plot-options.de-3CPVK7Hi.cjs +0 -20
  1036. package/components/scatter-plot-options.de-CNLrv6j3.js +0 -99
  1037. package/components/scatter-plot-options.en-DigMzpQy.js +0 -99
  1038. package/components/scatter-plot-options.en-Dzvigy8-.cjs +0 -20
  1039. package/components/scatter-plot-options.es-C-IH7GVH.cjs +0 -20
  1040. package/components/scatter-plot-options.es-CQm_VVqJ.js +0 -99
  1041. package/components/scatter-plot-options.fr-Cdp6kPQi.cjs +0 -20
  1042. package/components/scatter-plot-options.fr-s0M39VT4.js +0 -99
  1043. package/components/scatter-plot-options.nl-CqpPIO03.js +0 -99
  1044. package/components/scatter-plot-options.nl-DeINlMqc.cjs +0 -20
  1045. package/components/scatter-plot-positioning.config-BKqPHMrS.js +0 -77
  1046. package/components/scatter-plot-positioning.config-D7uFFBVZ.cjs +0 -20
  1047. package/components/set-locale-Bgz1WNGE.cjs +0 -20
  1048. package/components/set-locale-s-1X7Jce.js +0 -43
  1049. package/components/slicer-filter-positioning.config-D1kR4xly.cjs +0 -20
  1050. package/components/slicer-filter-positioning.config-Gl9jhO_G.js +0 -48
  1051. package/components/slot-menu-CAhxaK5-.cjs +0 -71
  1052. package/components/slot-menu-Dw53Y-iu.js +0 -429
  1053. package/components/slot-menu-list-5NsRo9XD.js +0 -348
  1054. package/components/slot-menu-list-CUsmYkiV.cjs +0 -44
  1055. package/components/slot-role-classification-2wChhpcq.cjs +0 -20
  1056. package/components/slot-role-classification-B8bkGhQ_.js +0 -133
  1057. package/components/slots-config-Cd4xAG4H.cjs +0 -20
  1058. package/components/slots-config-GlSNH7Gr.js +0 -76
  1059. package/components/speedometer-chart-positioning.config-VBLrLNmO.js +0 -48
  1060. package/components/speedometer-chart-positioning.config-fa90zZdb.cjs +0 -20
  1061. package/components/spike-map-positioning.config-DrxdeFsj.cjs +0 -20
  1062. package/components/spike-map-positioning.config-oYjk3n9a.js +0 -55
  1063. package/components/strip-plot-positioning.config-Bx_fqmEj.cjs +0 -20
  1064. package/components/strip-plot-positioning.config-lMn33cM4.js +0 -48
  1065. package/components/sunburst-chart-options.config-Bjue_lQN.js +0 -184
  1066. package/components/sunburst-chart-options.config-DszAtggj.cjs +0 -20
  1067. package/components/sunburst-chart-options.de-Cv5jxNjX.js +0 -60
  1068. package/components/sunburst-chart-options.de-DV_80qR9.cjs +0 -20
  1069. package/components/sunburst-chart-options.en-Zfns8M0i.cjs +0 -20
  1070. package/components/sunburst-chart-options.en-wsOVOyb6.js +0 -60
  1071. package/components/sunburst-chart-options.es-BSKiBxl_.cjs +0 -20
  1072. package/components/sunburst-chart-options.es-Qhu6VcVi.js +0 -60
  1073. package/components/sunburst-chart-options.fr-DOcWgNOZ.cjs +0 -20
  1074. package/components/sunburst-chart-options.fr-GdCEoo8O.js +0 -60
  1075. package/components/sunburst-chart-options.nl-D2JXoYTB.cjs +0 -20
  1076. package/components/sunburst-chart-options.nl-oTUKol5z.js +0 -60
  1077. package/components/sunburst-chart-positioning.config-C-We-zZF.js +0 -48
  1078. package/components/sunburst-chart-positioning.config-D-GRWmyF.cjs +0 -20
  1079. package/components/symbol-map-positioning.config-B0sLlLzK.cjs +0 -20
  1080. package/components/symbol-map-positioning.config-_TJSfpVj.js +0 -55
  1081. package/components/treemap-chart-positioning.config-CO05Gv7X.cjs +0 -20
  1082. package/components/treemap-chart-positioning.config-DAdvoS2I.js +0 -55
  1083. package/components/utils-CGJh0jrq.cjs +0 -20
  1084. package/components/utils-Dk4dM9xv.js +0 -240
  1085. package/components/venn-diagram-positioning.config-DKXWVaUI.cjs +0 -20
  1086. package/components/venn-diagram-positioning.config-DUwmPQ1A.js +0 -55
  1087. package/components/wordcloud-chart-positioning.config-CgbB_SI0.cjs +0 -20
  1088. package/components/wordcloud-chart-positioning.config-qK5_CF7v.js +0 -55
  1089. package/standalone/chunks/add-to-dashboard-BrWieRxp.js +0 -148
  1090. package/standalone/chunks/area-chart-options.config-CXWPLl-0.js +0 -2
  1091. package/standalone/chunks/area-chart-options.de-Dr8RVJtb.js +0 -2
  1092. package/standalone/chunks/area-chart-options.en-DV1AZ274.js +0 -2
  1093. package/standalone/chunks/area-chart-options.es-Cg7uU7OK.js +0 -2
  1094. package/standalone/chunks/area-chart-options.fr-CJjgrAt2.js +0 -2
  1095. package/standalone/chunks/area-chart-options.nl-CTGxVXNo.js +0 -2
  1096. package/standalone/chunks/axis-options.config-DP9f04t6.js +0 -2
  1097. package/standalone/chunks/axis-options.i18n-BwkGC9PX.js +0 -2
  1098. package/standalone/chunks/bar-chart-options.config-w4REKu0t.js +0 -2
  1099. package/standalone/chunks/bar-chart-options.de-DCVBVtFi.js +0 -2
  1100. package/standalone/chunks/bar-chart-options.en-B4xiZxTy.js +0 -2
  1101. package/standalone/chunks/bar-chart-options.es-UqehXB9Z.js +0 -2
  1102. package/standalone/chunks/bar-chart-options.fr-CaUBeZBK.js +0 -2
  1103. package/standalone/chunks/bar-chart-options.nl-C2tFvUE8.js +0 -2
  1104. package/standalone/chunks/base-CLcNr-fQ.js +0 -2
  1105. package/standalone/chunks/box-plot-options.config-BlYMd4FN.js +0 -2
  1106. package/standalone/chunks/box-plot-options.de-RDAv8kHb.js +0 -2
  1107. package/standalone/chunks/box-plot-options.en-kGLfLsv3.js +0 -2
  1108. package/standalone/chunks/box-plot-options.es-Dw3ivv22.js +0 -2
  1109. package/standalone/chunks/box-plot-options.fr-De5nkQNr.js +0 -2
  1110. package/standalone/chunks/box-plot-options.nl-DD1f-Nlt.js +0 -2
  1111. package/standalone/chunks/bullet-chart-options.config-Cc5lKDjs.js +0 -2
  1112. package/standalone/chunks/bullet-chart-options.de-Ci81seQn.js +0 -2
  1113. package/standalone/chunks/bullet-chart-options.en-Dk95moRX.js +0 -2
  1114. package/standalone/chunks/bullet-chart-options.es-eIqahAOr.js +0 -2
  1115. package/standalone/chunks/bullet-chart-options.fr-CEABbpT0.js +0 -2
  1116. package/standalone/chunks/bullet-chart-options.nl-B3gOPn5D.js +0 -2
  1117. package/standalone/chunks/column-chart-options.config-v7fBgXRI.js +0 -2
  1118. package/standalone/chunks/column-chart-options.de-OoMpZc7N.js +0 -2
  1119. package/standalone/chunks/column-chart-options.en-B4xiZxTy.js +0 -2
  1120. package/standalone/chunks/column-chart-options.es-BL-wKXpp.js +0 -2
  1121. package/standalone/chunks/column-chart-options.fr-CaUBeZBK.js +0 -2
  1122. package/standalone/chunks/column-chart-options.nl-C2tFvUE8.js +0 -2
  1123. package/standalone/chunks/combination-chart-options.config-C9hmUPal.js +0 -2
  1124. package/standalone/chunks/combination-chart-options.de-ChlEhT09.js +0 -2
  1125. package/standalone/chunks/combination-chart-options.en-DhCXqnwj.js +0 -2
  1126. package/standalone/chunks/combination-chart-options.es-DESqZp0U.js +0 -2
  1127. package/standalone/chunks/combination-chart-options.fr-v6P2xQCi.js +0 -2
  1128. package/standalone/chunks/combination-chart-options.nl-D8ato2ve.js +0 -2
  1129. package/standalone/chunks/date-comparison-filter-slots.config-DfHq9lB8.js +0 -2
  1130. package/standalone/chunks/de-BtQ1ecN1.js +0 -2
  1131. package/standalone/chunks/display-settings-binning-B_lKObyP.js +0 -38
  1132. package/standalone/chunks/display-settings-datetime-CTmJyEOX.js +0 -199
  1133. package/standalone/chunks/display-settings-grand-totals-IjcbBoyZ.js +0 -26
  1134. package/standalone/chunks/display-settings-numeric-D9hvRtfN.js +0 -172
  1135. package/standalone/chunks/display-settings-period-over-period-Dnstsyqe.js +0 -209
  1136. package/standalone/chunks/donut-chart-options.config-BuZj-QX5.js +0 -2
  1137. package/standalone/chunks/donut-chart-options.de-QusCBL9B.js +0 -2
  1138. package/standalone/chunks/donut-chart-options.en-D0ligFH6.js +0 -2
  1139. package/standalone/chunks/donut-chart-options.es-Bmn34sGt.js +0 -2
  1140. package/standalone/chunks/donut-chart-options.fr-DGBawYKp.js +0 -2
  1141. package/standalone/chunks/donut-chart-options.nl-DzNTu0v4.js +0 -2
  1142. package/standalone/chunks/embed-Dymwil3u.js +0 -228
  1143. package/standalone/chunks/es-CAWreooi.js +0 -2
  1144. package/standalone/chunks/evolution-number-options.config-B5Cj0YAQ.js +0 -2
  1145. package/standalone/chunks/evolution-number-options.de-Ch0LaHwI.js +0 -2
  1146. package/standalone/chunks/evolution-number-options.en-riChGfa6.js +0 -2
  1147. package/standalone/chunks/evolution-number-options.es-BdG3lvVQ.js +0 -2
  1148. package/standalone/chunks/evolution-number-options.fr-_h0kLeRL.js +0 -2
  1149. package/standalone/chunks/evolution-number-options.nl-CqycrLe1.js +0 -2
  1150. package/standalone/chunks/filters-CBmZhipt.js +0 -544
  1151. package/standalone/chunks/formula-codemirror-D2F6Aj2h.js +0 -197
  1152. package/standalone/chunks/fr-BG0nQk8g.js +0 -2
  1153. package/standalone/chunks/funnel-chart-options.config-1SyJ_qYd.js +0 -2
  1154. package/standalone/chunks/funnel-chart-options.de-BTxwd7Pe.js +0 -2
  1155. package/standalone/chunks/funnel-chart-options.en-CmY-uO1P.js +0 -2
  1156. package/standalone/chunks/funnel-chart-options.es-DLqBydsE.js +0 -2
  1157. package/standalone/chunks/funnel-chart-options.fr-ztQ5OMZi.js +0 -2
  1158. package/standalone/chunks/funnel-chart-options.nl-DVysx7tP.js +0 -2
  1159. package/standalone/chunks/heat-table-options.config-ByHwT44G.js +0 -2
  1160. package/standalone/chunks/heat-table-options.de-BMx67hXo.js +0 -2
  1161. package/standalone/chunks/heat-table-options.en-BbobGoXs.js +0 -2
  1162. package/standalone/chunks/heat-table-options.es-zKo-QMBY.js +0 -2
  1163. package/standalone/chunks/heat-table-options.fr-XSTL1CSb.js +0 -2
  1164. package/standalone/chunks/heat-table-options.nl-Cgcccsee.js +0 -2
  1165. package/standalone/chunks/item-option-action-button-group-BZyiRTfe.js +0 -35
  1166. package/standalone/chunks/item-option-base-Bk5qxdcQ.js +0 -38
  1167. package/standalone/chunks/item-option-color-palette-picker-O8kT0i8p.js +0 -22
  1168. package/standalone/chunks/item-option-color-picker-CUTCc_yN.js +0 -16
  1169. package/standalone/chunks/item-option-color-range-DsKPvjLj.js +0 -80
  1170. package/standalone/chunks/item-option-guidelines-CZyvhgtN.js +0 -117
  1171. package/standalone/chunks/item-option-multi-language-field-DlC-cCD7.js +0 -15
  1172. package/standalone/chunks/item-option-number-field-BW9VpN9_.js +0 -20
  1173. package/standalone/chunks/item-option-panel-BXA3sIYG.js +0 -298
  1174. package/standalone/chunks/item-option-picker-B2KmO7a6.js +0 -19
  1175. package/standalone/chunks/item-option-position-picker-C9C9SKDD.js +0 -14
  1176. package/standalone/chunks/item-option-positions-number-field-C2ahVlxe.js +0 -31
  1177. package/standalone/chunks/item-option-radio-button-group-2q3doUXH.js +0 -19
  1178. package/standalone/chunks/item-option-slider-C7TT3CqL.js +0 -15
  1179. package/standalone/chunks/item-option-switch-CZR2_Bs9.js +0 -12
  1180. package/standalone/chunks/item-option-text-field-DBUOD_fv.js +0 -15
  1181. package/standalone/chunks/item-slot-picker-panel-CTePASjI.js +0 -439
  1182. package/standalone/chunks/line-chart-options.config-DyqQLGw8.js +0 -2
  1183. package/standalone/chunks/line-chart-options.de-BScjvJsI.js +0 -2
  1184. package/standalone/chunks/line-chart-options.en-BVWFsre-.js +0 -2
  1185. package/standalone/chunks/line-chart-options.es-CxNJevNs.js +0 -2
  1186. package/standalone/chunks/line-chart-options.fr-LCsLx0Uh.js +0 -2
  1187. package/standalone/chunks/line-chart-options.nl-BOgcjx48.js +0 -2
  1188. package/standalone/chunks/load-data-fields-for-datasets-CPf_Q7p4.js +0 -25
  1189. package/standalone/chunks/load-formula-codemirror-CA7NW4Zq.js +0 -6
  1190. package/standalone/chunks/localized-mixin-DN2aV3CC.js +0 -2
  1191. package/standalone/chunks/nl-BXPduS2Q.js +0 -2
  1192. package/standalone/chunks/ohlc-chart-options.config-Bu2GKlAH.js +0 -2
  1193. package/standalone/chunks/pyramid-chart-options.config-CBd-pgn_.js +0 -2
  1194. package/standalone/chunks/pyramid-chart-options.de-CBL_8UjH.js +0 -2
  1195. package/standalone/chunks/pyramid-chart-options.en-CTozc1Uh.js +0 -2
  1196. package/standalone/chunks/pyramid-chart-options.es-BKciL-nO.js +0 -2
  1197. package/standalone/chunks/pyramid-chart-options.fr-B04m8B_b.js +0 -2
  1198. package/standalone/chunks/pyramid-chart-options.nl-DIhj1NYF.js +0 -2
  1199. package/standalone/chunks/radar-chart-options.config-CnQ8mbs9.js +0 -2
  1200. package/standalone/chunks/radar-chart-options.de-_LSueG69.js +0 -2
  1201. package/standalone/chunks/radar-chart-options.en-DBA8TpKJ.js +0 -2
  1202. package/standalone/chunks/radar-chart-options.es-DjSsFQkP.js +0 -2
  1203. package/standalone/chunks/radar-chart-options.fr-CCh2jYPS.js +0 -2
  1204. package/standalone/chunks/radar-chart-options.nl-tZ0JRjXD.js +0 -2
  1205. package/standalone/chunks/scatter-plot-options.config-BV9Lb6-v.js +0 -2
  1206. package/standalone/chunks/scatter-plot-options.de-Dg3O1b2R.js +0 -2
  1207. package/standalone/chunks/scatter-plot-options.en-CJH2ZlFW.js +0 -2
  1208. package/standalone/chunks/scatter-plot-options.es-7kExRi4J.js +0 -2
  1209. package/standalone/chunks/scatter-plot-options.fr-Bbkf8efT.js +0 -2
  1210. package/standalone/chunks/scatter-plot-options.nl-zrEXoM-k.js +0 -2
  1211. package/standalone/chunks/sunburst-chart-options.config-DRjBFJV0.js +0 -2
  1212. package/standalone/chunks/sunburst-chart-options.de-D6enQCjV.js +0 -2
  1213. package/standalone/chunks/sunburst-chart-options.en-D9DSivE2.js +0 -2
  1214. package/standalone/chunks/sunburst-chart-options.es-Bb7iCI1h.js +0 -2
  1215. package/standalone/chunks/sunburst-chart-options.fr-CCzUgv7r.js +0 -2
  1216. package/standalone/chunks/sunburst-chart-options.nl-bGOCvc4m.js +0 -2
  1217. package/standalone/chunks/version-DJES6maY.js +0 -2
@@ -1,4325 +0,0 @@
1
- /*! * A kit of modern Luzmo Web Components for analytics in your web application.
2
- *
3
- * Copyright © 2026 Luzmo
4
- * All rights reserved.
5
- * Luzmo web components (“Luzmo Web Components”)
6
- * must be used according to the Luzmo Terms of Service.
7
- * This license allows users with a current active Luzmo account
8
- * to use the Luzmo Web Components. This license terminates
9
- * automatically if a user no longer has an active Luzmo account.
10
- * Please view the Luzmo Terms of Service at: https://www.luzmo.com/information-pages/terms-of-use.
11
- *
12
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
13
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
14
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
15
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
16
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
17
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
18
- * SOFTWARE.
19
- * */
20
- import "./tokens-Ov1pCR4Y.js";
21
- import { c as e, d as t, s as n, u as r } from "./ai-interaction-textarea-6ECwAdeT.js";
22
- import { i, n as a } from "./base-CrpOMVeU.js";
23
- import { t as o } from "./decorate-DyMgX_Uh.js";
24
- import { t as s } from "./defineProperty-AldSMFEH.js";
25
- import { msg as c } from "@lit/localize/lit-localize";
26
- import { luzmoEllipsisVertical as l, luzmoIcon as u, luzmoSpin as d } from "@luzmo/icons";
27
- import "@luzmo/lucero/button";
28
- import "@luzmo/lucero/chat-message";
29
- import "@luzmo/lucero/icon";
30
- import "@luzmo/lucero/overlay";
31
- import "@luzmo/lucero/popover";
32
- import "@luzmo/lucero/progress-steps";
33
- import { html as f, nothing as p, unsafeCSS as m } from "lit";
34
- import { property as h, state as g } from "lit/decorators.js";
35
- import { unsafeHTML as ee } from "lit/directives/unsafe-html.js";
36
- import "@luzmo/lucero/action-button";
37
- import "@luzmo/lucero/question-box";
38
- import { guard as te } from "lit/directives/guard.js";
39
- import { keyed as ne } from "lit/directives/keyed.js";
40
- //#region node_modules/dompurify/dist/purify.es.mjs
41
- function _(e, t) {
42
- this.v = e, this.k = t;
43
- }
44
- function re(e, t) {
45
- (t == null || t > e.length) && (t = e.length);
46
- for (var n = 0, r = Array(t); n < t; n++) r[n] = e[n];
47
- return r;
48
- }
49
- function ie(e) {
50
- if (Array.isArray(e)) return e;
51
- }
52
- function ae(e, t) {
53
- var n = e == null ? null : typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
54
- if (n != null) {
55
- var r, i, a, o, s = [], c = !0, l = !1;
56
- try {
57
- if (a = (n = n.call(e)).next, t === 0) {
58
- if (Object(n) !== n) return;
59
- c = !1;
60
- } else for (; !(c = (r = a.call(n)).done) && (s.push(r.value), s.length !== t); c = !0);
61
- } catch (e) {
62
- l = !0, i = e;
63
- } finally {
64
- try {
65
- if (!c && n.return != null && (o = n.return(), Object(o) !== o)) return;
66
- } finally {
67
- if (l) throw i;
68
- }
69
- }
70
- return s;
71
- }
72
- }
73
- function oe() {
74
- throw TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
75
- }
76
- function v(e, t) {
77
- return ie(e) || ae(e, t) || se(e, t) || oe();
78
- }
79
- function se(e, t) {
80
- if (e) {
81
- if (typeof e == "string") return re(e, t);
82
- var n = {}.toString.call(e).slice(8, -1);
83
- return n === "Object" && e.constructor && (n = e.constructor.name), n === "Map" || n === "Set" ? Array.from(e) : n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n) ? re(e, t) : void 0;
84
- }
85
- }
86
- function ce(e) {
87
- var t, n;
88
- function r(t, n) {
89
- try {
90
- var a = e[t](n), o = a.value, s = o instanceof _;
91
- Promise.resolve(s ? o.v : o).then(function(n) {
92
- if (s) {
93
- var c = t === "return" && o.k ? t : "next";
94
- if (!o.k || n.done) return r(c, n);
95
- n = e[c](n).value;
96
- }
97
- i(!!a.done, n);
98
- }, function(e) {
99
- r("throw", e);
100
- });
101
- } catch (e) {
102
- i(2, e);
103
- }
104
- }
105
- function i(e, i) {
106
- e === 2 ? t.reject(i) : t.resolve({
107
- value: i,
108
- done: e
109
- }), (t = t.next) ? r(t.key, t.arg) : n = null;
110
- }
111
- this._invoke = function(e, i) {
112
- return new Promise(function(a, o) {
113
- var s = {
114
- key: e,
115
- arg: i,
116
- resolve: a,
117
- reject: o,
118
- next: null
119
- };
120
- n ? n = n.next = s : (t = n = s, r(e, i));
121
- });
122
- }, typeof e.return != "function" && (this.return = void 0);
123
- }
124
- ce.prototype[typeof Symbol == "function" && Symbol.asyncIterator || "@@asyncIterator"] = function() {
125
- return this;
126
- }, ce.prototype.next = function(e) {
127
- return this._invoke("next", e);
128
- }, ce.prototype.throw = function(e) {
129
- return this._invoke("throw", e);
130
- }, ce.prototype.return = function(e) {
131
- return this._invoke("return", e);
132
- };
133
- var le = Object.entries, ue = Object.setPrototypeOf, de = Object.isFrozen, fe = Object.getPrototypeOf, pe = Object.getOwnPropertyDescriptor, y = Object.freeze, b = Object.seal, me = Object.create, he = typeof Reflect < "u" && Reflect, ge = he.apply, _e = he.construct;
134
- y ||= function(e) {
135
- return e;
136
- }, b ||= function(e) {
137
- return e;
138
- }, ge ||= function(e, t) {
139
- var n = [...arguments].slice(2);
140
- return e.apply(t, n);
141
- }, _e ||= function(e) {
142
- return new e(...[...arguments].slice(1));
143
- };
144
- var ve = C(Array.prototype.forEach);
145
- Array.prototype.indexOf;
146
- var ye = C(Array.prototype.lastIndexOf), be = C(Array.prototype.pop), xe = C(Array.prototype.push);
147
- Array.prototype.slice;
148
- var Se = C(Array.prototype.splice), Ce = Array.isArray, we = C(String.prototype.toLowerCase), Te = C(String.prototype.toString), Ee = C(String.prototype.match), De = C(String.prototype.replace), Oe = C(String.prototype.indexOf), ke = C(String.prototype.trim), Ae = C(Number.prototype.toString), je = C(Boolean.prototype.toString), Me = typeof BigInt > "u" ? null : C(BigInt.prototype.toString), Ne = typeof Symbol > "u" ? null : C(Symbol.prototype.toString), x = C(Object.prototype.hasOwnProperty), Pe = C(Object.prototype.toString), S = C(RegExp.prototype.test), Fe = Ie(TypeError);
149
- function C(e) {
150
- return function(t) {
151
- t instanceof RegExp && (t.lastIndex = 0);
152
- var n = [...arguments].slice(1);
153
- return ge(e, t, n);
154
- };
155
- }
156
- function Ie(e) {
157
- return function() {
158
- return _e(e, [...arguments]);
159
- };
160
- }
161
- function w(e, t) {
162
- let n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : we;
163
- if (ue && ue(e, null), !Ce(t)) return e;
164
- let r = t.length;
165
- for (; r--;) {
166
- let i = t[r];
167
- if (typeof i == "string") {
168
- let e = n(i);
169
- e !== i && (de(t) || (t[r] = e), i = e);
170
- }
171
- e[i] = !0;
172
- }
173
- return e;
174
- }
175
- function Le(e) {
176
- for (let t = 0; t < e.length; t++) x(e, t) || (e[t] = null);
177
- return e;
178
- }
179
- function T(e) {
180
- let t = me(null);
181
- for (let r of le(e)) {
182
- var n = v(r, 2);
183
- let i = n[0], a = n[1];
184
- x(e, i) && (Ce(a) ? t[i] = Le(a) : a && typeof a == "object" && a.constructor === Object ? t[i] = T(a) : t[i] = a);
185
- }
186
- return t;
187
- }
188
- function Re(e) {
189
- switch (typeof e) {
190
- case "string": return e;
191
- case "number": return Ae(e);
192
- case "boolean": return je(e);
193
- case "bigint": return Me ? Me(e) : "0";
194
- case "symbol": return Ne ? Ne(e) : "Symbol()";
195
- case "undefined": return Pe(e);
196
- case "function":
197
- case "object": {
198
- if (e === null) return Pe(e);
199
- let t = e, n = E(t, "toString");
200
- if (typeof n == "function") {
201
- let e = n(t);
202
- return typeof e == "string" ? e : Pe(e);
203
- }
204
- return Pe(e);
205
- }
206
- default: return Pe(e);
207
- }
208
- }
209
- function E(e, t) {
210
- for (; e !== null;) {
211
- let n = pe(e, t);
212
- if (n) {
213
- if (n.get) return C(n.get);
214
- if (typeof n.value == "function") return C(n.value);
215
- }
216
- e = fe(e);
217
- }
218
- function n() {
219
- return null;
220
- }
221
- return n;
222
- }
223
- function ze(e) {
224
- try {
225
- return S(e, ""), !0;
226
- } catch {
227
- return !1;
228
- }
229
- }
230
- var Be = y(/* @__PURE__ */ "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".split(".")), Ve = y(/* @__PURE__ */ "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".split(".")), He = y([
231
- "feBlend",
232
- "feColorMatrix",
233
- "feComponentTransfer",
234
- "feComposite",
235
- "feConvolveMatrix",
236
- "feDiffuseLighting",
237
- "feDisplacementMap",
238
- "feDistantLight",
239
- "feDropShadow",
240
- "feFlood",
241
- "feFuncA",
242
- "feFuncB",
243
- "feFuncG",
244
- "feFuncR",
245
- "feGaussianBlur",
246
- "feImage",
247
- "feMerge",
248
- "feMergeNode",
249
- "feMorphology",
250
- "feOffset",
251
- "fePointLight",
252
- "feSpecularLighting",
253
- "feSpotLight",
254
- "feTile",
255
- "feTurbulence"
256
- ]), Ue = y([
257
- "animate",
258
- "color-profile",
259
- "cursor",
260
- "discard",
261
- "font-face",
262
- "font-face-format",
263
- "font-face-name",
264
- "font-face-src",
265
- "font-face-uri",
266
- "foreignobject",
267
- "hatch",
268
- "hatchpath",
269
- "mesh",
270
- "meshgradient",
271
- "meshpatch",
272
- "meshrow",
273
- "missing-glyph",
274
- "script",
275
- "set",
276
- "solidcolor",
277
- "unknown",
278
- "use"
279
- ]), We = y(/* @__PURE__ */ "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".split(".")), Ge = y([
280
- "maction",
281
- "maligngroup",
282
- "malignmark",
283
- "mlongdiv",
284
- "mscarries",
285
- "mscarry",
286
- "msgroup",
287
- "mstack",
288
- "msline",
289
- "msrow",
290
- "semantics",
291
- "annotation",
292
- "annotation-xml",
293
- "mprescripts",
294
- "none"
295
- ]), Ke = y(["#text"]), qe = y(/* @__PURE__ */ "accept.action.align.alt.autocapitalize.autocomplete.autopictureinpicture.autoplay.background.bgcolor.border.capture.cellpadding.cellspacing.checked.cite.class.clear.color.cols.colspan.command.commandfor.controls.controlslist.coords.crossorigin.datetime.decoding.default.dir.disabled.disablepictureinpicture.disableremoteplayback.download.draggable.enctype.enterkeyhint.exportparts.face.for.headers.height.hidden.high.href.hreflang.id.inert.inputmode.integrity.ismap.kind.label.lang.list.loading.loop.low.max.maxlength.media.method.min.minlength.multiple.muted.name.nonce.noshade.novalidate.nowrap.open.optimum.part.pattern.placeholder.playsinline.popover.popovertarget.popovertargetaction.poster.preload.pubdate.radiogroup.readonly.rel.required.rev.reversed.role.rows.rowspan.spellcheck.scope.selected.shape.size.sizes.slot.span.srclang.start.src.srcset.step.style.summary.tabindex.title.translate.type.usemap.valign.value.width.wrap.xmlns".split(".")), Je = y(/* @__PURE__ */ "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.dominant-baseline.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.pointer-events.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-orientation.text-rendering.textlength.type.u1.u2.unicode.values.vector-effect.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".split(".")), Ye = y(/* @__PURE__ */ "accent.accentunder.align.bevelled.close.columnalign.columnlines.columnspacing.columnspan.denomalign.depth.dir.display.displaystyle.encoding.fence.frame.height.href.id.largeop.length.linethickness.lquote.lspace.mathbackground.mathcolor.mathsize.mathvariant.maxsize.minsize.movablelimits.notation.numalign.open.rowalign.rowlines.rowspacing.rowspan.rspace.rquote.scriptlevel.scriptminsize.scriptsizemultiplier.selection.separator.separators.stretchy.subscriptshift.supscriptshift.symmetric.voffset.width.xmlns".split(".")), Xe = y([
296
- "xlink:href",
297
- "xml:id",
298
- "xlink:title",
299
- "xml:space",
300
- "xmlns:xlink"
301
- ]), Ze = b(/{{[\w\W]*|^[\w\W]*}}/g), Qe = b(/<%[\w\W]*|^[\w\W]*%>/g), $e = b(/\${[\w\W]*/g), et = b(/^data-[\-\w.\u00B7-\uFFFF]+$/), tt = b(/^aria-[\-\w]+$/), nt = b(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i), rt = b(/^(?:\w+script|data):/i), it = b(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g), at = b(/^html$/i), ot = b(/^[a-z][.\w]*(-[.\w]+)+$/i), st = b(/<[/\w!]/g), ct = b(/<[/\w]/g), lt = b(/<\/no(script|embed|frames)/i), ut = b(/\/>/i), D = {
302
- element: 1,
303
- attribute: 2,
304
- text: 3,
305
- cdataSection: 4,
306
- entityReference: 5,
307
- entityNode: 6,
308
- processingInstruction: 7,
309
- comment: 8,
310
- document: 9,
311
- documentType: 10,
312
- documentFragment: 11,
313
- notation: 12
314
- }, dt = [
315
- "style",
316
- "script",
317
- "xmp",
318
- "iframe",
319
- "noembed",
320
- "noframes",
321
- "plaintext",
322
- "noscript"
323
- ], ft = y(w({}, dt)), pt = function() {
324
- let e = {};
325
- return ve(dt, (t) => {
326
- e[t] = b(RegExp("</" + t + "(?=[\\t\\n\\f\\r />])", "i"));
327
- }), y(e);
328
- }(), mt = function() {
329
- return typeof window > "u" ? null : window;
330
- }, ht = function(e, t) {
331
- if (typeof e != "object" || typeof e.createPolicy != "function") return null;
332
- let n = null, r = "data-tt-policy-suffix";
333
- t && t.hasAttribute(r) && (n = t.getAttribute(r));
334
- let i = "dompurify" + (n ? "#" + n : "");
335
- try {
336
- return e.createPolicy(i, {
337
- createHTML(e) {
338
- return e;
339
- },
340
- createScriptURL(e) {
341
- return e;
342
- }
343
- });
344
- } catch {
345
- return console.warn("TrustedTypes policy " + i + " could not be created."), null;
346
- }
347
- }, gt = function() {
348
- return {
349
- afterSanitizeAttributes: [],
350
- afterSanitizeElements: [],
351
- afterSanitizeShadowDOM: [],
352
- beforeSanitizeAttributes: [],
353
- beforeSanitizeElements: [],
354
- beforeSanitizeShadowDOM: [],
355
- uponSanitizeAttribute: [],
356
- uponSanitizeElement: [],
357
- uponSanitizeShadowNode: []
358
- };
359
- }, _t = function(e, t, n, r) {
360
- return x(e, t) && Ce(e[t]) ? w(r.base ? T(r.base) : {}, e[t], r.transform) : n;
361
- }, vt = function(e, t, n) {
362
- let r = x(e, t) ? e[t] : void 0;
363
- return r && typeof r == "object" ? T(r) : n();
364
- };
365
- function yt() {
366
- let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : mt(), t = (e) => yt(e);
367
- if (t.version = "3.4.16", t.removed = [], !e || !e.document || e.document.nodeType !== D.document || !e.Element) return t.isSupported = !1, t;
368
- let n = e.document, r = n, i = r.currentScript;
369
- e.DocumentFragment;
370
- let a = e.HTMLTemplateElement, o = e.Node, s = e.Element, c = e.NodeFilter;
371
- e.NamedNodeMap === void 0 && (e.NamedNodeMap || e.MozNamedAttrMap), e.HTMLFormElement;
372
- let l = e.DOMParser, u = e.trustedTypes, d = s.prototype, f = E(d, "cloneNode"), p = E(d, "remove"), m = E(d, "removeAttributeNode"), h = E(d, "nextSibling"), g = E(d, "childNodes"), ee = E(d, "parentNode"), te = E(d, "shadowRoot"), ne = E(d, "attributes"), _ = o && o.prototype ? E(o.prototype, "nodeType") : null, re = o && o.prototype ? E(o.prototype, "nodeName") : null, ie = o && o.prototype ? E(o.prototype, "ownerDocument") : null, ae = function(e) {
373
- return _ ? _(e) : e.nodeType;
374
- }, oe = function(e) {
375
- return re ? re(e) : e.nodeName;
376
- };
377
- if (typeof a == "function") {
378
- let e = n.createElement("template");
379
- e.content && e.content.ownerDocument && (n = e.content.ownerDocument);
380
- }
381
- let v, se = "", ce, ue = !1, de = 0, fe = function() {
382
- if (de > 0) throw Fe("A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the \"DOMPurify and Trusted Types\" section of the README.");
383
- }, pe = function(e) {
384
- fe(), de++;
385
- try {
386
- return v.createHTML(e);
387
- } finally {
388
- de--;
389
- }
390
- }, he = function(e) {
391
- fe(), de++;
392
- try {
393
- return v.createScriptURL(e);
394
- } finally {
395
- de--;
396
- }
397
- }, ge = function() {
398
- return ue ||= (ce = ht(u, i), !0), ce;
399
- }, _e = n, Ae = _e.implementation, je = _e.createNodeIterator, Me = _e.createDocumentFragment, Ne = _e.getElementsByTagName, Pe = r.importNode, C = gt();
400
- t.isSupported = typeof le == "function" && typeof ee == "function" && Ae && Ae.createHTMLDocument !== void 0;
401
- let Ie = Ze, Le = Qe, dt = $e, bt = et, xt = tt, St = rt, O = it, Ct = ot, k = nt, A = null, j = w({}, [
402
- ...Be,
403
- ...Ve,
404
- ...He,
405
- ...We,
406
- ...Ke
407
- ]), M = null, N = w({}, [
408
- ...qe,
409
- ...Je,
410
- ...Ye,
411
- ...Xe
412
- ]), P = Object.seal(me(null, {
413
- tagNameCheck: {
414
- writable: !0,
415
- configurable: !1,
416
- enumerable: !0,
417
- value: null
418
- },
419
- attributeNameCheck: {
420
- writable: !0,
421
- configurable: !1,
422
- enumerable: !0,
423
- value: null
424
- },
425
- allowCustomizedBuiltInElements: {
426
- writable: !0,
427
- configurable: !1,
428
- enumerable: !0,
429
- value: !1
430
- }
431
- })), wt = null, Tt = null, F = Object.seal(me(null, {
432
- tagCheck: {
433
- writable: !0,
434
- configurable: !1,
435
- enumerable: !0,
436
- value: null
437
- },
438
- attributeCheck: {
439
- writable: !0,
440
- configurable: !1,
441
- enumerable: !0,
442
- value: null
443
- }
444
- })), Et = !0, Dt = !0, Ot = !1, kt = !0, I = !1, L = !0, At = !1, jt = !1, Mt = null, Nt = null, Pt = !1, R = !1, Ft = !1, It = !1, Lt = !0, Rt = !1, zt = "user-content-", Bt = !0, Vt = !1, Ht = {}, Ut = null, Wt = w({}, /* @__PURE__ */ "annotation-xml.audio.colgroup.desc.foreignobject.head.iframe.math.mi.mn.mo.ms.mtext.noembed.noframes.noscript.plaintext.script.selectedcontent.style.svg.template.thead.title.video.xmp".split(".")), Gt = null, Kt = w({}, [
445
- "audio",
446
- "video",
447
- "img",
448
- "source",
449
- "image",
450
- "track"
451
- ]), qt = null, Jt = w({}, [
452
- "alt",
453
- "class",
454
- "for",
455
- "id",
456
- "label",
457
- "name",
458
- "pattern",
459
- "placeholder",
460
- "role",
461
- "summary",
462
- "title",
463
- "value",
464
- "style",
465
- "xmlns"
466
- ]), Yt = "http://www.w3.org/1998/Math/MathML", Xt = "http://www.w3.org/2000/svg", z = "http://www.w3.org/1999/xhtml", Zt = z, Qt = !1, $t = null, en = w({}, [
467
- Yt,
468
- Xt,
469
- z
470
- ], Te), tn = y([
471
- "mi",
472
- "mo",
473
- "mn",
474
- "ms",
475
- "mtext"
476
- ]), nn = w({}, tn), rn = y(["annotation-xml"]), an = w({}, rn), on = w({}, [
477
- "title",
478
- "style",
479
- "font",
480
- "a",
481
- "script"
482
- ]), sn = null, cn = ["application/xhtml+xml", "text/html"], B = null, ln = null, un = n.createElement("form"), dn = function(e) {
483
- return e instanceof RegExp || e instanceof Function;
484
- }, fn = function() {
485
- let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
486
- if (ln && ln === e) return;
487
- (!e || typeof e != "object") && (e = {}), e = T(e), sn = cn.indexOf(e.PARSER_MEDIA_TYPE) === -1 ? "text/html" : e.PARSER_MEDIA_TYPE, B = sn === "application/xhtml+xml" ? Te : we, A = _t(e, "ALLOWED_TAGS", j, { transform: B }), M = _t(e, "ALLOWED_ATTR", N, { transform: B }), $t = _t(e, "ALLOWED_NAMESPACES", en, { transform: Te }), qt = _t(e, "ADD_URI_SAFE_ATTR", Jt, {
488
- transform: B,
489
- base: Jt
490
- }), Gt = _t(e, "ADD_DATA_URI_TAGS", Kt, {
491
- transform: B,
492
- base: Kt
493
- }), Ut = _t(e, "FORBID_CONTENTS", Wt, { transform: B }), wt = _t(e, "FORBID_TAGS", T({}), { transform: B }), Tt = _t(e, "FORBID_ATTR", T({}), { transform: B }), Ht = x(e, "USE_PROFILES") ? e.USE_PROFILES && typeof e.USE_PROFILES == "object" ? T(e.USE_PROFILES) : e.USE_PROFILES : !1, Et = e.ALLOW_ARIA_ATTR !== !1, Dt = e.ALLOW_DATA_ATTR !== !1, Ot = e.ALLOW_UNKNOWN_PROTOCOLS || !1, kt = e.ALLOW_SELF_CLOSE_IN_ATTR !== !1, I = e.SAFE_FOR_TEMPLATES || !1, L = e.SAFE_FOR_XML !== !1, At = e.WHOLE_DOCUMENT || !1, R = e.RETURN_DOM || !1, Ft = e.RETURN_DOM_FRAGMENT || !1, It = e.RETURN_TRUSTED_TYPE || !1, Pt = e.FORCE_BODY || !1, Lt = e.SANITIZE_DOM !== !1, Rt = e.SANITIZE_NAMED_PROPS || !1, Bt = e.KEEP_CONTENT !== !1, Vt = e.IN_PLACE || !1, k = ze(e.ALLOWED_URI_REGEXP) ? e.ALLOWED_URI_REGEXP : nt, Zt = typeof e.NAMESPACE == "string" ? e.NAMESPACE : z, nn = vt(e, "MATHML_TEXT_INTEGRATION_POINTS", () => w({}, tn)), an = vt(e, "HTML_INTEGRATION_POINTS", () => w({}, rn));
494
- let t = vt(e, "CUSTOM_ELEMENT_HANDLING", () => me(null));
495
- if (P = me(null), x(t, "tagNameCheck") && dn(t.tagNameCheck) && (P.tagNameCheck = t.tagNameCheck), x(t, "attributeNameCheck") && dn(t.attributeNameCheck) && (P.attributeNameCheck = t.attributeNameCheck), x(t, "allowCustomizedBuiltInElements") && typeof t.allowCustomizedBuiltInElements == "boolean" && (P.allowCustomizedBuiltInElements = t.allowCustomizedBuiltInElements), b(P), I && (Dt = !1), Ft && (R = !0), Ht && (A = w({}, Ke), M = me(null), Ht.html === !0 && (w(A, Be), w(M, qe)), Ht.svg === !0 && (w(A, Ve), w(M, Je), w(M, Xe)), Ht.svgFilters === !0 && (w(A, He), w(M, Je), w(M, Xe)), Ht.mathMl === !0 && (w(A, We), w(M, Ye), w(M, Xe))), F.tagCheck = null, F.attributeCheck = null, x(e, "ADD_TAGS") && (typeof e.ADD_TAGS == "function" ? F.tagCheck = e.ADD_TAGS : Ce(e.ADD_TAGS) && (A === j && (A = T(A)), w(A, e.ADD_TAGS, B))), x(e, "ADD_ATTR") && (typeof e.ADD_ATTR == "function" ? F.attributeCheck = e.ADD_ATTR : Ce(e.ADD_ATTR) && (M === N && (M = T(M)), w(M, e.ADD_ATTR, B))), x(e, "ADD_FORBID_CONTENTS") && Ce(e.ADD_FORBID_CONTENTS) && (Ut === Wt && (Ut = T(Ut)), w(Ut, e.ADD_FORBID_CONTENTS, B)), Bt && (A["#text"] = !0), At && w(A, [
496
- "html",
497
- "head",
498
- "body"
499
- ]), A.table && (w(A, ["tbody"]), delete wt.tbody), e.TRUSTED_TYPES_POLICY) {
500
- if (typeof e.TRUSTED_TYPES_POLICY.createHTML != "function") throw Fe("TRUSTED_TYPES_POLICY configuration option must provide a \"createHTML\" hook.");
501
- if (typeof e.TRUSTED_TYPES_POLICY.createScriptURL != "function") throw Fe("TRUSTED_TYPES_POLICY configuration option must provide a \"createScriptURL\" hook.");
502
- let t = v;
503
- v = e.TRUSTED_TYPES_POLICY;
504
- try {
505
- se = pe("");
506
- } catch (e) {
507
- throw v = t, e;
508
- }
509
- } else e.TRUSTED_TYPES_POLICY === null ? (v = void 0, se = "") : (v === void 0 && (v = ge()), v && typeof se == "string" && (se = pe("")));
510
- y && y(e), ln = e;
511
- }, pn = w({}, [
512
- ...Ve,
513
- ...He,
514
- ...Ue
515
- ]), mn = w({}, [...We, ...Ge]), hn = function(e, t, n) {
516
- return t.namespaceURI === z ? e === "svg" : t.namespaceURI === Yt ? e === "svg" && (n === "annotation-xml" || nn[n]) : !!pn[e];
517
- }, gn = function(e, t, n) {
518
- return t.namespaceURI === z ? e === "math" : t.namespaceURI === Xt ? e === "math" && an[n] : !!mn[e];
519
- }, _n = function(e, t, n) {
520
- return t.namespaceURI === Xt && !an[n] || t.namespaceURI === Yt && !nn[n] ? !1 : !mn[e] && (on[e] || !pn[e]);
521
- }, vn = function(e) {
522
- let t = ee(e);
523
- (!t || !t.tagName) && (t = {
524
- namespaceURI: Zt,
525
- tagName: "template"
526
- });
527
- let n = we(e.tagName), r = we(t.tagName);
528
- return $t[e.namespaceURI] ? e.namespaceURI === Xt ? hn(n, t, r) : e.namespaceURI === Yt ? gn(n, t, r) : e.namespaceURI === z ? _n(n, t, r) : !!(sn === "application/xhtml+xml" && $t[e.namespaceURI]) : !1;
529
- }, V = function(e) {
530
- xe(t.removed, { element: e });
531
- try {
532
- ee(e).removeChild(e);
533
- } catch {
534
- if (p(e), !ee(e)) throw Fe("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place");
535
- }
536
- }, yn = function(e, t, n) {
537
- try {
538
- m(e, t);
539
- } catch {
540
- try {
541
- e.removeAttribute(n);
542
- } catch {}
543
- }
544
- }, bn = function(e) {
545
- Sn(e);
546
- let t = g(e);
547
- if (t) {
548
- let e = [];
549
- ve(t, (t) => {
550
- xe(e, t);
551
- }), ve(e, (e) => {
552
- try {
553
- p(e);
554
- } catch {}
555
- });
556
- }
557
- let n = ne(e);
558
- if (n) for (let t = n.length - 1; t >= 0; --t) {
559
- let r = n[t], i = r && r.name;
560
- typeof i == "string" && yn(e, r, i);
561
- }
562
- }, H = function(e, n, r) {
563
- if (!r) try {
564
- r = n.getAttributeNode(e);
565
- } catch {
566
- r = null;
567
- }
568
- xe(t.removed, {
569
- attribute: r || null,
570
- from: n
571
- });
572
- try {
573
- r ? m(n, r) : n.removeAttribute(e);
574
- } catch {
575
- try {
576
- n.removeAttribute(e);
577
- } catch {}
578
- }
579
- if (e === "is") if (R || Ft) try {
580
- V(n);
581
- } catch {}
582
- else try {
583
- n.setAttribute(e, "");
584
- } catch {}
585
- }, xn = function(e) {
586
- let t = ne(e);
587
- if (t) for (let n = t.length - 1; n >= 0; --n) {
588
- let r = t[n], i = r && r.name;
589
- typeof i != "string" || M[B(i)] || yn(e, r, i);
590
- }
591
- }, Sn = function(e) {
592
- let t = [e];
593
- for (; t.length > 0;) {
594
- let e = t.pop();
595
- ae(e) === D.element && xn(e);
596
- let n = g(e);
597
- if (n) for (let e = n.length - 1; e >= 0; --e) t.push(n[e]);
598
- }
599
- }, U = function(e, t) {
600
- return L ? e === "patchsrc" || e === "for" && t !== "label" && t !== "output" : !1;
601
- }, Cn = function(e) {
602
- if (!L) return;
603
- let t = [e];
604
- for (; t.length > 0;) {
605
- let e = t.pop(), n = ae(e);
606
- if (n === D.processingInstruction || n === D.comment && S(ct, e.data)) {
607
- try {
608
- p(e);
609
- } catch {}
610
- continue;
611
- }
612
- if (n === D.element) {
613
- let t = e, n = B(oe(e));
614
- try {
615
- t.hasAttribute && t.hasAttribute("patchsrc") && t.removeAttribute("patchsrc"), t.hasAttribute && t.hasAttribute("for") && U("for", n) && t.removeAttribute("for");
616
- } catch {}
617
- }
618
- let r = g(e);
619
- if (r) for (let e = r.length - 1; e >= 0; --e) t.push(r[e]);
620
- }
621
- }, wn = function(e) {
622
- let t = null, r = null;
623
- if (Pt) e = "<remove></remove>" + e;
624
- else {
625
- let t = Ee(e, /^[\r\n\t ]+/);
626
- r = t && t[0];
627
- }
628
- sn === "application/xhtml+xml" && Zt === z && (e = "<html xmlns=\"http://www.w3.org/1999/xhtml\"><head></head><body>" + e + "</body></html>");
629
- let i = v ? pe(e) : e;
630
- if (Zt === z) try {
631
- t = new l().parseFromString(i, sn);
632
- } catch {}
633
- if (!t || !t.documentElement) {
634
- t = Ae.createDocument(Zt, "template", null);
635
- try {
636
- t.documentElement.innerHTML = Qt ? se : i;
637
- } catch {}
638
- }
639
- let a = t.body || t.documentElement;
640
- return e && r && a.insertBefore(n.createTextNode(r), a.childNodes[0] || null), Zt === z ? Ne.call(t, At ? "html" : "body")[0] : At ? t.documentElement : a;
641
- }, W = function(e) {
642
- let t = ie ? ie(e) : e.ownerDocument;
643
- return je.call(t || e, e, c.SHOW_ELEMENT | c.SHOW_COMMENT | c.SHOW_TEXT | c.SHOW_PROCESSING_INSTRUCTION | c.SHOW_CDATA_SECTION, null);
644
- }, Tn = function(e) {
645
- return e = De(e, Ie, " "), e = De(e, Le, " "), e = De(e, dt, " "), e;
646
- }, En = function(e) {
647
- e.normalize();
648
- let t = ie ? ie(e) : e.ownerDocument, n = je.call(t || e, e, c.SHOW_TEXT | c.SHOW_COMMENT | c.SHOW_CDATA_SECTION | c.SHOW_PROCESSING_INSTRUCTION, null), r = n.nextNode();
649
- for (; r;) r.data = Tn(r.data), r = n.nextNode();
650
- let i = e.querySelectorAll?.call(e, "template");
651
- i && ve(i, (e) => {
652
- On(e.content) && En(e.content);
653
- });
654
- }, Dn = function(e) {
655
- let t = re ? re(e) : null;
656
- return typeof t != "string" || B(t) !== "form" ? !1 : typeof e.nodeName != "string" || typeof e.textContent != "string" || typeof e.removeChild != "function" || e.attributes !== ne(e) || typeof e.removeAttribute != "function" || typeof e.removeAttributeNode != "function" || typeof e.getAttributeNode != "function" || typeof e.setAttribute != "function" || typeof e.namespaceURI != "string" || typeof e.insertBefore != "function" || typeof e.hasChildNodes != "function" || e.nodeType !== _(e) || e.childNodes !== g(e);
657
- }, On = function(e) {
658
- if (!_ || typeof e != "object" || !e) return !1;
659
- try {
660
- return _(e) === D.documentFragment;
661
- } catch {
662
- return !1;
663
- }
664
- }, kn = function(e) {
665
- if (!_ || typeof e != "object" || !e) return !1;
666
- try {
667
- return typeof _(e) == "number";
668
- } catch {
669
- return !1;
670
- }
671
- };
672
- function G(e, n, r) {
673
- e.length !== 0 && ve(e, (e) => {
674
- e.call(t, n, r, ln);
675
- });
676
- }
677
- let K = function(e, t) {
678
- return !!(L && e.hasChildNodes() && !kn(e.firstElementChild) && S(st, e.textContent) && S(st, e.innerHTML) || L && e.namespaceURI === z && ft[t] && (kn(e.firstElementChild) || typeof e.textContent == "string" && S(pt[t], e.textContent)) || e.nodeType === D.processingInstruction || L && e.nodeType === D.comment && S(ct, e.data));
679
- }, An = function(e, t) {
680
- return e instanceof RegExp ? S(e, t) : e instanceof Function && !!e(t, ...[...arguments].slice(2));
681
- }, jn = function(e, t, n) {
682
- if (!wt[t] && Nn(t) && An(P.tagNameCheck, t)) return !1;
683
- if (Bt && !Ut[t]) {
684
- let t = ee(e), r = g(e);
685
- if (r && t) {
686
- let i = r.length;
687
- for (let a = i - 1; a >= 0; --a) {
688
- let i = e === n ? f(r[a], !0) : r[a];
689
- t.insertBefore(i, h(e));
690
- }
691
- }
692
- }
693
- return V(e), !0;
694
- }, q = function(e, t, n, r) {
695
- return e.length === 0 ? t : t === n || t === r ? T(t) : t;
696
- }, J = function(e, t) {
697
- return e === t || ee(e) !== null ? !1 : (Vt && Sn(e), !0);
698
- }, Y = function(e, n) {
699
- if (G(C.beforeSanitizeElements, e, null), J(e, n)) return !0;
700
- if (Dn(e)) return V(e), !0;
701
- let r = B(oe(e));
702
- if (A = q(C.uponSanitizeElement, A, j, Mt), G(C.uponSanitizeElement, e, {
703
- tagName: r,
704
- allowedTags: A
705
- }), J(e, n)) return !0;
706
- if (K(e, r)) return V(e), !0;
707
- if (wt[r] || !(F.tagCheck instanceof Function && F.tagCheck(r)) && !A[r]) {
708
- let t = jn(e, r, n);
709
- return t === !1 && (G(C.afterSanitizeElements, e, null), J(e, n)) ? !0 : t;
710
- }
711
- if (ae(e) === D.element && !vn(e) || (r === "noscript" || r === "noembed" || r === "noframes") && S(lt, e.innerHTML)) return V(e), !0;
712
- if (I && e.nodeType === D.text) {
713
- let n = Tn(e.textContent);
714
- e.textContent !== n && (xe(t.removed, { element: e.cloneNode() }), e.textContent = n);
715
- }
716
- return G(C.afterSanitizeElements, e, null), J(e, n);
717
- }, X = function(e, t, r) {
718
- if (Tt[t] || U(t, e) || Lt && (t === "id" || t === "name") && (r in n || r in un)) return !1;
719
- let i = M[t] || F.attributeCheck instanceof Function && F.attributeCheck(t, e);
720
- return Dt && S(bt, t) || Et && S(xt, t) ? !0 : i ? qt[t] || S(k, De(r, O, "")) || (t === "src" || t === "xlink:href" || t === "href") && e !== "script" && Oe(r, "data:") === 0 && Gt[e] || Ot && !S(St, De(r, O, "")) ? !0 : !r : Nn(e) && An(P.tagNameCheck, e) && An(P.attributeNameCheck, t, e) || t === "is" && P.allowCustomizedBuiltInElements && An(P.tagNameCheck, r);
721
- }, Mn = w({}, [
722
- "annotation-xml",
723
- "color-profile",
724
- "font-face",
725
- "font-face-format",
726
- "font-face-name",
727
- "font-face-src",
728
- "font-face-uri",
729
- "missing-glyph"
730
- ]), Nn = function(e) {
731
- return !Mn[we(e)] && S(Ct, e);
732
- }, Pn = function(e, t, n, r) {
733
- if (v && typeof u == "object" && typeof u.getAttributeType == "function" && !n) switch (u.getAttributeType(e, t)) {
734
- case "TrustedHTML": return pe(r);
735
- case "TrustedScriptURL": return he(r);
736
- }
737
- return r;
738
- }, Fn = function(e, t, n, r) {
739
- try {
740
- return n ? e.setAttributeNS(n, t, r) : e.setAttribute(t, r), Dn(e) ? (V(e), !1) : !0;
741
- } catch {
742
- return H(t, e), !1;
743
- }
744
- }, In = function(e, n) {
745
- if (G(C.beforeSanitizeAttributes, e, null), J(e, n)) return;
746
- let r = e.attributes;
747
- if (!r || Dn(e)) return;
748
- M = q(C.uponSanitizeAttribute, M, N, Nt);
749
- let i = {
750
- attrName: "",
751
- attrValue: "",
752
- keepAttr: !0,
753
- allowedAttributes: M,
754
- forceKeepAttr: void 0
755
- }, a = r.length, o = B(e.nodeName);
756
- for (; a--;) {
757
- let n = r[a], s = n.name, c = n.namespaceURI, l = n.value, u = B(s), d = l, f = s === "value" ? d : ke(d), p = !1;
758
- if (i.attrName = u, i.attrValue = f, i.keepAttr = !0, i.forceKeepAttr = void 0, G(C.uponSanitizeAttribute, e, i), f = i.attrValue, Rt && (u === "id" || u === "name") && Oe(f, zt) !== 0 && (H(s, e, n), f = zt + f, p = !0), L && S(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i, f)) {
759
- H(s, e, n);
760
- continue;
761
- }
762
- if (u === "attributename" && Ee(f, "href")) {
763
- H(s, e, n);
764
- continue;
765
- }
766
- if (!i.forceKeepAttr) {
767
- if (!i.keepAttr) {
768
- H(s, e, n);
769
- continue;
770
- }
771
- if (!kt && S(ut, f)) {
772
- H(s, e, n);
773
- continue;
774
- }
775
- if (I && (f = Tn(f)), !X(o, u, f)) {
776
- H(s, e, n);
777
- continue;
778
- }
779
- f = Pn(o, u, c, f), f !== d && Fn(e, s, c, f) && p && be(t.removed);
780
- }
781
- }
782
- G(C.afterSanitizeAttributes, e, null), J(e, n);
783
- }, Z = function(e) {
784
- let t = null, n = W(e);
785
- for (G(C.beforeSanitizeShadowDOM, e, null); t = n.nextNode();) if (G(C.uponSanitizeShadowNode, t, null), Y(t, e), In(t, e), On(t.content) && Z(t.content), ae(t) === D.element) {
786
- let e = te(t);
787
- On(e) && (Ln(e), Z(e));
788
- }
789
- G(C.afterSanitizeShadowDOM, e, null);
790
- }, Ln = function(e) {
791
- let t = [{
792
- node: e,
793
- shadow: null
794
- }];
795
- for (; t.length > 0;) {
796
- let e = t.pop();
797
- if (e.shadow) {
798
- Z(e.shadow);
799
- continue;
800
- }
801
- let n = e.node, r = ae(n) === D.element, i = g(n);
802
- if (i) for (let e = i.length - 1; e >= 0; --e) t.push({
803
- node: i[e],
804
- shadow: null
805
- });
806
- if (r) {
807
- let e = re ? re(n) : null;
808
- if (typeof e == "string" && B(e) === "template") {
809
- let e = n.content;
810
- On(e) && t.push({
811
- node: e,
812
- shadow: null
813
- });
814
- }
815
- }
816
- if (r) {
817
- let e = te(n);
818
- On(e) && t.push({
819
- node: null,
820
- shadow: e
821
- }, {
822
- node: e,
823
- shadow: null
824
- });
825
- }
826
- }
827
- };
828
- return t.sanitize = function(e) {
829
- let n = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, i = null, a = null, o = null, s = null;
830
- if (Qt = !e, Qt && (e = "<!-->"), typeof e != "string" && !kn(e) && (e = Re(e), typeof e != "string")) throw Fe("dirty is not a string, aborting");
831
- if (!t.isSupported) return e;
832
- jt ? (A = Mt, M = Nt) : fn(n), (C.uponSanitizeElement.length > 0 || C.uponSanitizeAttribute.length > 0) && (A = T(A)), C.uponSanitizeAttribute.length > 0 && (M = T(M)), t.removed = [];
833
- let c = Vt && typeof e != "string" && kn(e);
834
- if (c) {
835
- Cn(e);
836
- let t = oe(e);
837
- if (typeof t == "string") {
838
- let n = B(t);
839
- if (!A[n] || wt[n]) throw bn(e), Fe("root node is forbidden and cannot be sanitized in-place");
840
- }
841
- if (Dn(e)) throw bn(e), Fe("root node is clobbered and cannot be sanitized in-place");
842
- try {
843
- Ln(e);
844
- } catch (t) {
845
- throw bn(e), t;
846
- }
847
- } else if (kn(e)) i = wn("<!---->"), a = i.ownerDocument.importNode(e, !0), a.nodeType === D.element && a.nodeName === "BODY" || a.nodeName === "HTML" ? i = a : i.appendChild(a), Ln(i);
848
- else {
849
- if (!R && !I && !At && e.indexOf("<") === -1) return v && It ? pe(e) : e;
850
- if (i = wn(e), !i) return R ? null : It ? se : "";
851
- }
852
- i && Pt && V(i.firstChild);
853
- let l = c ? e : i;
854
- try {
855
- let e = W(l);
856
- for (; o = e.nextNode();) Y(o, l), In(o, l), On(o.content) && Z(o.content);
857
- } catch (n) {
858
- throw c && (bn(e), ve(t.removed, (e) => {
859
- e.element && Sn(e.element);
860
- })), n;
861
- }
862
- if (c) {
863
- let n = !1;
864
- if (ve(t.removed, (t) => {
865
- t.element && (t.element === e && (n = !0), Sn(t.element));
866
- }), n) throw Fe("a node selected for removal could not be safely returned; refusing to sanitize in place");
867
- return I && En(e), e;
868
- }
869
- if (R) {
870
- if (I && En(i), Ft) for (s = Me.call(i.ownerDocument); i.firstChild;) s.appendChild(i.firstChild);
871
- else s = i;
872
- return (M.shadowroot || M.shadowrootmode) && (s = Pe.call(r, s, !0)), s;
873
- }
874
- let u = At ? i.outerHTML : i.innerHTML;
875
- return At && A["!doctype"] && i.ownerDocument && i.ownerDocument.doctype && i.ownerDocument.doctype.name && S(at, i.ownerDocument.doctype.name) && (u = "<!DOCTYPE " + i.ownerDocument.doctype.name + ">\n" + u), I && (u = Tn(u)), v && It ? pe(u) : u;
876
- }, t.setConfig = function() {
877
- let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
878
- fn(e), jt = !0, Mt = A, Nt = M;
879
- }, t.clearConfig = function() {
880
- ln = null, jt = !1, Mt = null, Nt = null, v = ce, se = "";
881
- }, t.isValidAttribute = function(e, t, n) {
882
- ln || fn({});
883
- let r = B(e), i = B(t);
884
- return X(r, i, n);
885
- }, t.addHook = function(e, t) {
886
- typeof t == "function" && x(C, e) && xe(C[e], t);
887
- }, t.removeHook = function(e, t) {
888
- if (x(C, e)) {
889
- if (t !== void 0) {
890
- let n = ye(C[e], t);
891
- return n === -1 ? void 0 : Se(C[e], n, 1)[0];
892
- }
893
- return be(C[e]);
894
- }
895
- }, t.removeHooks = function(e) {
896
- x(C, e) && (C[e] = []);
897
- }, t.removeAllHooks = function() {
898
- C = gt();
899
- }, t;
900
- }
901
- var bt = yt(), xt;
902
- function St() {
903
- return {
904
- async: !1,
905
- breaks: !1,
906
- extensions: null,
907
- gfm: !0,
908
- hooks: null,
909
- pedantic: !1,
910
- renderer: null,
911
- silent: !1,
912
- tokenizer: null,
913
- walkTokens: null
914
- };
915
- }
916
- var O = St();
917
- function Ct(e) {
918
- O = e;
919
- }
920
- var k = { exec: () => null };
921
- function A(e) {
922
- let t = [];
923
- return (n) => {
924
- let r = Math.max(0, Math.min(3, n - 1)), i = t[r];
925
- return i || (i = e(r), t[r] = i), i;
926
- };
927
- }
928
- function j(e, t = "") {
929
- let n = typeof e == "string" ? e : e.source, r = {
930
- replace: (e, t) => {
931
- let i = typeof t == "string" ? t : t.source;
932
- return i = i.replace(N.caret, "$1"), n = n.replace(e, i), r;
933
- },
934
- getRegex: () => new RegExp(n, t)
935
- };
936
- return r;
937
- }
938
- var M = ((e = "") => {
939
- try {
940
- return !!RegExp("(?<=1)(?<!1)" + e);
941
- } catch {
942
- return !1;
943
- }
944
- })(), N = {
945
- codeRemoveIndent: /^(?: {1,4}| {0,3}\t)/gm,
946
- outputLinkReplace: /\\([\[\]])/g,
947
- indentCodeCompensation: /^(\s+)(?:```)/,
948
- beginningSpace: /^\s+/,
949
- endingHash: /#$/,
950
- startingSpaceChar: /^ /,
951
- endingSpaceChar: / $/,
952
- nonSpaceChar: /[^ ]/,
953
- newLineCharGlobal: /\n/g,
954
- tabCharGlobal: /\t/g,
955
- multipleSpaceGlobal: /\s+/g,
956
- blankLine: /^[ \t]*$/,
957
- doubleBlankLine: /\n[ \t]*\n[ \t]*$/,
958
- blockquoteStart: /^ {0,3}>/,
959
- blockquoteSetextReplace: /\n {0,3}((?:=+|-+) *)(?=\n|$)/g,
960
- blockquoteSetextReplace2: /^ {0,3}>[ \t]?/gm,
961
- listReplaceNesting: /^ {1,4}(?=( {4})*[^ ])/g,
962
- listIsTask: /^\[[ xX]\] +\S/,
963
- listReplaceTask: /^\[[ xX]\] +/,
964
- listTaskCheckbox: /\[[ xX]\]/,
965
- anyLine: /\n.*\n/,
966
- hrefBrackets: /^<(.*)>$/,
967
- tableDelimiter: /[:|]/,
968
- tableAlignChars: /^\||\| *$/g,
969
- tableRowBlankLine: /\n[ \t]*$/,
970
- tableAlignRight: /^ *-+: *$/,
971
- tableAlignCenter: /^ *:-+: *$/,
972
- tableAlignLeft: /^ *:-+ *$/,
973
- startATag: /^<a /i,
974
- endATag: /^<\/a>/i,
975
- startPreScriptTag: /^<(pre|code|kbd|script)(\s|>)/i,
976
- endPreScriptTag: /^<\/(pre|code|kbd|script)(\s|>)/i,
977
- startAngleBracket: /^</,
978
- endAngleBracket: />$/,
979
- pedanticHrefTitle: /^([^'"]*[^\s])\s+(['"])(.*)\2/,
980
- unicodeAlphaNumeric: /[\p{L}\p{N}]/u,
981
- escapeTest: /[&<>"']/,
982
- escapeReplace: /[&<>"']/g,
983
- escapeTestNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,
984
- escapeReplaceNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,
985
- caret: /(^|[^\[])\^/g,
986
- percentDecode: /%25/g,
987
- findPipe: /\|/g,
988
- splitPipe: / \|/,
989
- slashPipe: /\\\|/g,
990
- carriageReturn: /\r\n|\r/g,
991
- spaceLine: /^ +$/gm,
992
- notSpaceStart: /^\S*/,
993
- endingNewline: /\n$/,
994
- listItemRegex: (e) => RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),
995
- nextBulletRegex: A((e) => RegExp(`^ {0,${e}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`)),
996
- hrRegex: A((e) => RegExp(`^ {0,${e}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`)),
997
- fencesBeginRegex: A((e) => RegExp(`^ {0,${e}}(?:\`\`\`|~~~)`)),
998
- headingBeginRegex: A((e) => RegExp(`^ {0,${e}}#`)),
999
- htmlBeginRegex: A((e) => RegExp(`^ {0,${e}}<(?:[a-z].*>|!--)`, "i")),
1000
- blockquoteBeginRegex: A((e) => RegExp(`^ {0,${e}}>`))
1001
- }, P = /^(?:[ \t]*(?:\n|$))+/, wt = /^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/, Tt = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/, F = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/, Et = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/, Dt = / {0,3}(?:[*+-]|\d{1,9}[.)])/, Ot = /^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/, kt = j(Ot).replace(/bull/g, Dt).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/\|table/g, "").getRegex(), I = j(Ot).replace(/bull/g, Dt).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/table/g, / {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(), L = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/, At = /^[^\n]+/, jt = /(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/, Mt = j(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label", jt).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(), Nt = j(/^(bull)([ \t][^\n]*?)?(?:\n|$)/).replace(/bull/g, Dt).getRegex(), Pt = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul", R = /<!--(?:-?>|[\s\S]*?(?:-->|$))/, Ft = j("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))", "i").replace("comment", R).replace("tag", Pt).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(), It = j(L).replace("hr", F).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)])[ \\t]+[^ \\t\\n]").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", Pt).getRegex(), Lt = {
1002
- blockquote: j(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", It).getRegex(),
1003
- code: wt,
1004
- def: Mt,
1005
- fences: Tt,
1006
- heading: Et,
1007
- hr: F,
1008
- html: Ft,
1009
- lheading: kt,
1010
- list: Nt,
1011
- newline: P,
1012
- paragraph: It,
1013
- table: k,
1014
- text: At
1015
- }, Rt = j("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", F).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("blockquote", " {0,3}>").replace("code", "(?: {4}| {0,3} )[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", Pt).getRegex(), zt = {
1016
- ...Lt,
1017
- lheading: I,
1018
- table: Rt,
1019
- paragraph: j(L).replace("hr", F).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table", Rt).replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)])[ \\t]+[^ \\t\\n]").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", Pt).getRegex()
1020
- }, Bt = {
1021
- ...Lt,
1022
- html: j("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:\"[^\"]*\"|'[^']*'|\\s[^'\"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment", R).replace(/tag/g, "(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),
1023
- def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,
1024
- heading: /^(#{1,6})(.*)(?:\n+|$)/,
1025
- fences: k,
1026
- lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,
1027
- paragraph: j(L).replace("hr", F).replace("heading", " *#{1,6} *[^\n]").replace("lheading", kt).replace("|table", "").replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").replace("|tag", "").getRegex()
1028
- }, Vt = /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/, Ht = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/, Ut = /^( {2,}|\\)\n(?!\s*$)/, Wt = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/, Gt = /[\p{P}\p{S}]/u, Kt = /[\s\p{P}\p{S}]/u, qt = /[^\s\p{P}\p{S}]/u, Jt = j(/^((?![*_])punctSpace)/, "u").replace(/punctSpace/g, Kt).getRegex(), Yt = /(?!~)[\p{P}\p{S}]/u, Xt = /(?!~)[\s\p{P}\p{S}]/u, z = /(?:[^\s\p{P}\p{S}]|~)/u, Zt = j(/link|precode-code|html/, "g").replace("link", /\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-", M ? "(?<!`)()" : "(^^|[^`])").replace("code", /(?<b>`+)[^`]+\k<b>(?!`)/).replace("html", /<(?! )[^<>]*?>/).getRegex(), Qt = /^(?:\*+(?:((?!\*)punct)|([^\s*]))?)|^_+(?:((?!_)punct)|([^\s_]))?/, $t = j(Qt, "u").replace(/punct/g, Gt).getRegex(), en = j(Qt, "u").replace(/punct/g, Yt).getRegex(), tn = "^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)", nn = j(tn, "gu").replace(/notPunctSpace/g, qt).replace(/punctSpace/g, Kt).replace(/punct/g, Gt).getRegex(), rn = j(tn, "gu").replace(/notPunctSpace/g, z).replace(/punctSpace/g, Xt).replace(/punct/g, Yt).getRegex(), an = j("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)", "gu").replace(/notPunctSpace/g, qt).replace(/punctSpace/g, Kt).replace(/punct/g, Gt).getRegex(), on = j(/^~~?(?:((?!~)punct)|[^\s~])/, "u").replace(/punct/g, Gt).getRegex(), sn = j("^[^~]+(?=[^~])|(?!~)punct(~~?)(?=[\\s]|$)|notPunctSpace(~~?)(?!~)(?=punctSpace|$)|(?!~)punctSpace(~~?)(?=notPunctSpace)|[\\s](~~?)(?!~)(?=punct)|(?!~)punct(~~?)(?!~)(?=punct)|notPunctSpace(~~?)(?=notPunctSpace)", "gu").replace(/notPunctSpace/g, qt).replace(/punctSpace/g, Kt).replace(/punct/g, Gt).getRegex(), cn = j(/\\(punct)/, "gu").replace(/punct/g, Gt).getRegex(), B = j(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme", /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email", /[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(), ln = j(R).replace("(?:-->|$)", "-->").getRegex(), un = j("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment", ln).replace("attribute", /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(), dn = /(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+(?!`)[^`]*?`+(?!`)|``+(?=\])|[^\[\]\\`])*?/, fn = j(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]+(?:\n[ \t]*)?|\n[ \t]*)(title))?\s*\)/).replace("label", dn).replace("href", /<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title", /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(), pn = j(/^!?\[(label)\]\[(ref)\]/).replace("label", dn).replace("ref", jt).getRegex(), mn = j(/^!?\[(ref)\](?:\[\])?/).replace("ref", jt).getRegex(), hn = j("reflink|nolink(?!\\()", "g").replace("reflink", pn).replace("nolink", mn).getRegex(), gn = /[hH][tT][tT][pP][sS]?|[fF][tT][pP]/, _n = {
1029
- _backpedal: k,
1030
- anyPunctuation: cn,
1031
- autolink: B,
1032
- blockSkip: Zt,
1033
- br: Ut,
1034
- code: Ht,
1035
- del: k,
1036
- delLDelim: k,
1037
- delRDelim: k,
1038
- emStrongLDelim: $t,
1039
- emStrongRDelimAst: nn,
1040
- emStrongRDelimUnd: an,
1041
- escape: Vt,
1042
- link: fn,
1043
- nolink: mn,
1044
- punctuation: Jt,
1045
- reflink: pn,
1046
- reflinkSearch: hn,
1047
- tag: un,
1048
- text: Wt,
1049
- url: k
1050
- }, vn = {
1051
- ..._n,
1052
- link: j(/^!?\[(label)\]\((.*?)\)/).replace("label", dn).getRegex(),
1053
- reflink: j(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", dn).getRegex()
1054
- }, V = {
1055
- ..._n,
1056
- emStrongRDelimAst: rn,
1057
- emStrongLDelim: en,
1058
- delLDelim: on,
1059
- delRDelim: sn,
1060
- url: j(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol", gn).replace("email", /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),
1061
- _backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,
1062
- del: /^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,
1063
- text: j(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol", gn).getRegex()
1064
- }, yn = {
1065
- ...V,
1066
- br: j(Ut).replace("{2,}", "*").getRegex(),
1067
- text: j(V.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex()
1068
- }, bn = {
1069
- normal: Lt,
1070
- gfm: zt,
1071
- pedantic: Bt
1072
- }, H = {
1073
- normal: _n,
1074
- gfm: V,
1075
- breaks: yn,
1076
- pedantic: vn
1077
- }, xn = {
1078
- "&": "&amp;",
1079
- "<": "&lt;",
1080
- ">": "&gt;",
1081
- "\"": "&quot;",
1082
- "'": "&#39;"
1083
- }, Sn = (e) => xn[e];
1084
- function U(e, t) {
1085
- if (t) {
1086
- if (N.escapeTest.test(e)) return e.replace(N.escapeReplace, Sn);
1087
- } else if (N.escapeTestNoEncode.test(e)) return e.replace(N.escapeReplaceNoEncode, Sn);
1088
- return e;
1089
- }
1090
- function Cn(e) {
1091
- try {
1092
- e = encodeURI(e).replace(N.percentDecode, "%");
1093
- } catch {
1094
- return null;
1095
- }
1096
- return e;
1097
- }
1098
- function wn(e, t) {
1099
- let n = e.replace(N.findPipe, (e, t, n) => {
1100
- let r = !1, i = t;
1101
- for (; --i >= 0 && n[i] === "\\";) r = !r;
1102
- return r ? "|" : " |";
1103
- }).split(N.splitPipe), r = 0;
1104
- if (n[0].trim() || n.shift(), n.length > 0 && !n.at(-1)?.trim() && n.pop(), t) if (n.length > t) n.splice(t);
1105
- else for (; n.length < t;) n.push("");
1106
- for (; r < n.length; r++) n[r] = n[r].trim().replace(N.slashPipe, "|");
1107
- return n;
1108
- }
1109
- function W(e, t, n) {
1110
- let r = e.length;
1111
- if (r === 0) return "";
1112
- let i = 0;
1113
- for (; i < r;) {
1114
- let a = e.charAt(r - i - 1);
1115
- if (a === t && !n) i++;
1116
- else if (a !== t && n) i++;
1117
- else break;
1118
- }
1119
- return e.slice(0, r - i);
1120
- }
1121
- function Tn(e) {
1122
- let t = e.split("\n"), n = t.length - 1;
1123
- for (; n >= 0 && N.blankLine.test(t[n]);) n--;
1124
- return t.length - n <= 2 ? e : t.slice(0, n + 1).join("\n");
1125
- }
1126
- function En(e, t) {
1127
- if (e.indexOf(t[1]) === -1) return -1;
1128
- let n = 0;
1129
- for (let r = 0; r < e.length; r++) if (e[r] === "\\") r++;
1130
- else if (e[r] === t[0]) n++;
1131
- else if (e[r] === t[1] && (n--, n < 0)) return r;
1132
- return n > 0 ? -2 : -1;
1133
- }
1134
- function Dn(e, t = 0) {
1135
- let n = t, r = "";
1136
- for (let t of e) if (t === " ") {
1137
- let e = 4 - n % 4;
1138
- r += " ".repeat(e), n += e;
1139
- } else r += t, n++;
1140
- return r;
1141
- }
1142
- function On(e, t, n, r, i) {
1143
- let a = t.href, o = t.title || null, s = e[1].replace(i.other.outputLinkReplace, "$1");
1144
- r.state.inLink = !0;
1145
- let c = {
1146
- type: e[0].charAt(0) === "!" ? "image" : "link",
1147
- raw: n,
1148
- href: a,
1149
- title: o,
1150
- text: s,
1151
- tokens: r.inlineTokens(s)
1152
- };
1153
- return r.state.inLink = !1, c;
1154
- }
1155
- function kn(e, t, n) {
1156
- let r = e.match(n.other.indentCodeCompensation);
1157
- if (r === null) return t;
1158
- let i = r[1];
1159
- return t.split("\n").map((e) => {
1160
- let t = e.match(n.other.beginningSpace);
1161
- if (t === null) return e;
1162
- let [r] = t;
1163
- return r.length >= i.length ? e.slice(i.length) : e;
1164
- }).join("\n");
1165
- }
1166
- var G = class {
1167
- constructor(e) {
1168
- s(this, "options", void 0), s(this, "rules", void 0), s(this, "lexer", void 0), this.options = e || O;
1169
- }
1170
- space(e) {
1171
- let t = this.rules.block.newline.exec(e);
1172
- if (t && t[0].length > 0) return {
1173
- type: "space",
1174
- raw: t[0]
1175
- };
1176
- }
1177
- code(e) {
1178
- let t = this.rules.block.code.exec(e);
1179
- if (t) {
1180
- let e = this.options.pedantic ? t[0] : Tn(t[0]);
1181
- return {
1182
- type: "code",
1183
- raw: e,
1184
- codeBlockStyle: "indented",
1185
- text: e.replace(this.rules.other.codeRemoveIndent, "")
1186
- };
1187
- }
1188
- }
1189
- fences(e) {
1190
- let t = this.rules.block.fences.exec(e);
1191
- if (t) {
1192
- let e = t[0], n = kn(e, t[3] || "", this.rules);
1193
- return {
1194
- type: "code",
1195
- raw: e,
1196
- lang: t[2] ? t[2].trim().replace(this.rules.inline.anyPunctuation, "$1") : t[2],
1197
- text: n
1198
- };
1199
- }
1200
- }
1201
- heading(e) {
1202
- let t = this.rules.block.heading.exec(e);
1203
- if (t) {
1204
- let e = t[2].trim();
1205
- if (this.rules.other.endingHash.test(e)) {
1206
- let t = W(e, "#");
1207
- (this.options.pedantic || !t || this.rules.other.endingSpaceChar.test(t)) && (e = t.trim());
1208
- }
1209
- return {
1210
- type: "heading",
1211
- raw: W(t[0], "\n"),
1212
- depth: t[1].length,
1213
- text: e,
1214
- tokens: this.lexer.inline(e)
1215
- };
1216
- }
1217
- }
1218
- hr(e) {
1219
- let t = this.rules.block.hr.exec(e);
1220
- if (t) return {
1221
- type: "hr",
1222
- raw: W(t[0], "\n")
1223
- };
1224
- }
1225
- blockquote(e) {
1226
- let t = this.rules.block.blockquote.exec(e);
1227
- if (t) {
1228
- let e = W(t[0], "\n").split("\n"), n = "", r = "", i = [];
1229
- for (; e.length > 0;) {
1230
- let t = !1, a = [], o;
1231
- for (o = 0; o < e.length; o++) if (this.rules.other.blockquoteStart.test(e[o])) a.push(e[o]), t = !0;
1232
- else if (!t) a.push(e[o]);
1233
- else break;
1234
- e = e.slice(o);
1235
- let s = a.join("\n"), c = s.replace(this.rules.other.blockquoteSetextReplace, "\n $1").replace(this.rules.other.blockquoteSetextReplace2, "");
1236
- n = n ? `${n}
1237
- ${s}` : s, r = r ? `${r}
1238
- ${c}` : c;
1239
- let l = this.lexer.state.top;
1240
- if (this.lexer.state.top = !0, this.lexer.blockTokens(c, i, !0), this.lexer.state.top = l, e.length === 0) break;
1241
- let u = i.at(-1);
1242
- if (u?.type === "code") break;
1243
- if (u?.type === "blockquote") {
1244
- let t = u, a = t.raw + "\n" + e.join("\n"), o = this.blockquote(a);
1245
- i[i.length - 1] = o, n = n.substring(0, n.length - t.raw.length) + o.raw, r = r.substring(0, r.length - t.text.length) + o.text;
1246
- break;
1247
- } else if (u?.type === "list") {
1248
- let t = u, a = t.raw + "\n" + e.join("\n"), o = this.list(a);
1249
- i[i.length - 1] = o, n = n.substring(0, n.length - u.raw.length) + o.raw, r = r.substring(0, r.length - t.raw.length) + o.raw, e = a.substring(i.at(-1).raw.length).split("\n");
1250
- continue;
1251
- }
1252
- }
1253
- return {
1254
- type: "blockquote",
1255
- raw: n,
1256
- tokens: i,
1257
- text: r
1258
- };
1259
- }
1260
- }
1261
- list(e) {
1262
- let t = this.rules.block.list.exec(e);
1263
- if (t) {
1264
- let n = t[1].trim(), r = n.length > 1, i = {
1265
- type: "list",
1266
- raw: "",
1267
- ordered: r,
1268
- start: r ? +n.slice(0, -1) : "",
1269
- loose: !1,
1270
- items: []
1271
- };
1272
- n = r ? `\\d{1,9}\\${n.slice(-1)}` : `\\${n}`, this.options.pedantic && (n = r ? n : "[*+-]");
1273
- let a = this.rules.other.listItemRegex(n), o = !1;
1274
- for (; e;) {
1275
- let n = !1, r = "", s = "";
1276
- if (!(t = a.exec(e)) || this.rules.block.hr.test(e)) break;
1277
- r = t[0], e = e.substring(r.length);
1278
- let c = Dn(t[2].split("\n", 1)[0], t[1].length), l = e.split("\n", 1)[0], u = !c.trim(), d = 0;
1279
- if (this.options.pedantic ? (d = 2, s = c.trimStart()) : u ? d = t[1].length + 1 : (d = c.search(this.rules.other.nonSpaceChar), d = d > 4 ? 1 : d, s = c.slice(d), d += t[1].length), u && this.rules.other.blankLine.test(l) && (r += l + "\n", e = e.substring(l.length + 1), n = !0), !n) {
1280
- let t = this.rules.other.nextBulletRegex(d), n = this.rules.other.hrRegex(d), i = this.rules.other.fencesBeginRegex(d), a = this.rules.other.headingBeginRegex(d), o = this.rules.other.htmlBeginRegex(d), f = this.rules.other.blockquoteBeginRegex(d);
1281
- for (; e;) {
1282
- let p = e.split("\n", 1)[0], m;
1283
- if (l = p, this.options.pedantic ? (l = l.replace(this.rules.other.listReplaceNesting, " "), m = l) : m = l.replace(this.rules.other.tabCharGlobal, " "), i.test(l) || a.test(l) || o.test(l) || f.test(l) || t.test(l) || n.test(l)) break;
1284
- if (m.search(this.rules.other.nonSpaceChar) >= d || !l.trim()) s += "\n" + m.slice(d);
1285
- else {
1286
- if (u || c.replace(this.rules.other.tabCharGlobal, " ").search(this.rules.other.nonSpaceChar) >= 4 || i.test(c) || a.test(c) || n.test(c)) break;
1287
- s += "\n" + l;
1288
- }
1289
- u = !l.trim(), r += p + "\n", e = e.substring(p.length + 1), c = m.slice(d);
1290
- }
1291
- }
1292
- i.loose || (o ? i.loose = !0 : this.rules.other.doubleBlankLine.test(r) && (o = !0)), i.items.push({
1293
- type: "list_item",
1294
- raw: r,
1295
- task: !!this.options.gfm && this.rules.other.listIsTask.test(s),
1296
- loose: !1,
1297
- text: s,
1298
- tokens: []
1299
- }), i.raw += r;
1300
- }
1301
- let s = i.items.at(-1);
1302
- if (s) s.raw = s.raw.trimEnd(), s.text = s.text.trimEnd();
1303
- else return;
1304
- i.raw = i.raw.trimEnd();
1305
- for (let e of i.items) {
1306
- this.lexer.state.top = !1, e.tokens = this.lexer.blockTokens(e.text, []);
1307
- let t = e.tokens[0];
1308
- if (e.task && (t?.type === "text" || t?.type === "paragraph")) {
1309
- e.text = e.text.replace(this.rules.other.listReplaceTask, ""), t.raw = t.raw.replace(this.rules.other.listReplaceTask, ""), t.text = t.text.replace(this.rules.other.listReplaceTask, "");
1310
- for (let e = this.lexer.inlineQueue.length - 1; e >= 0; e--) if (this.rules.other.listIsTask.test(this.lexer.inlineQueue[e].src)) {
1311
- this.lexer.inlineQueue[e].src = this.lexer.inlineQueue[e].src.replace(this.rules.other.listReplaceTask, "");
1312
- break;
1313
- }
1314
- let n = this.rules.other.listTaskCheckbox.exec(e.raw);
1315
- if (n) {
1316
- let t = {
1317
- type: "checkbox",
1318
- raw: n[0] + " ",
1319
- checked: n[0] !== "[ ]"
1320
- };
1321
- e.checked = t.checked, i.loose ? e.tokens[0] && ["paragraph", "text"].includes(e.tokens[0].type) && "tokens" in e.tokens[0] && e.tokens[0].tokens ? (e.tokens[0].raw = t.raw + e.tokens[0].raw, e.tokens[0].text = t.raw + e.tokens[0].text, e.tokens[0].tokens.unshift(t)) : e.tokens.unshift({
1322
- type: "paragraph",
1323
- raw: t.raw,
1324
- text: t.raw,
1325
- tokens: [t]
1326
- }) : e.tokens.unshift(t);
1327
- }
1328
- } else e.task &&= !1;
1329
- if (!i.loose) {
1330
- let t = e.tokens.filter((e) => e.type === "space");
1331
- i.loose = t.length > 0 && t.some((e) => this.rules.other.anyLine.test(e.raw));
1332
- }
1333
- }
1334
- if (i.loose) for (let e of i.items) {
1335
- e.loose = !0;
1336
- for (let t of e.tokens) t.type === "text" && (t.type = "paragraph");
1337
- }
1338
- return i;
1339
- }
1340
- }
1341
- html(e) {
1342
- let t = this.rules.block.html.exec(e);
1343
- if (t) {
1344
- let e = Tn(t[0]);
1345
- return {
1346
- type: "html",
1347
- block: !0,
1348
- raw: e,
1349
- pre: t[1] === "pre" || t[1] === "script" || t[1] === "style",
1350
- text: e
1351
- };
1352
- }
1353
- }
1354
- def(e) {
1355
- let t = this.rules.block.def.exec(e);
1356
- if (t) {
1357
- let e = t[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal, " "), n = t[2] ? t[2].replace(this.rules.other.hrefBrackets, "$1").replace(this.rules.inline.anyPunctuation, "$1") : "", r = t[3] ? t[3].substring(1, t[3].length - 1).replace(this.rules.inline.anyPunctuation, "$1") : t[3];
1358
- return {
1359
- type: "def",
1360
- tag: e,
1361
- raw: W(t[0], "\n"),
1362
- href: n,
1363
- title: r
1364
- };
1365
- }
1366
- }
1367
- table(e) {
1368
- let t = this.rules.block.table.exec(e);
1369
- if (!t || !this.rules.other.tableDelimiter.test(t[2])) return;
1370
- let n = wn(t[1]), r = t[2].replace(this.rules.other.tableAlignChars, "").split("|"), i = t[3]?.trim() ? t[3].replace(this.rules.other.tableRowBlankLine, "").split("\n") : [], a = {
1371
- type: "table",
1372
- raw: W(t[0], "\n"),
1373
- header: [],
1374
- align: [],
1375
- rows: []
1376
- };
1377
- if (n.length === r.length) {
1378
- for (let e of r) this.rules.other.tableAlignRight.test(e) ? a.align.push("right") : this.rules.other.tableAlignCenter.test(e) ? a.align.push("center") : this.rules.other.tableAlignLeft.test(e) ? a.align.push("left") : a.align.push(null);
1379
- for (let e = 0; e < n.length; e++) a.header.push({
1380
- text: n[e],
1381
- tokens: this.lexer.inline(n[e]),
1382
- header: !0,
1383
- align: a.align[e]
1384
- });
1385
- for (let e of i) a.rows.push(wn(e, a.header.length).map((e, t) => ({
1386
- text: e,
1387
- tokens: this.lexer.inline(e),
1388
- header: !1,
1389
- align: a.align[t]
1390
- })));
1391
- return a;
1392
- }
1393
- }
1394
- lheading(e) {
1395
- let t = this.rules.block.lheading.exec(e);
1396
- if (t) {
1397
- let e = t[1].trim();
1398
- return {
1399
- type: "heading",
1400
- raw: W(t[0], "\n"),
1401
- depth: t[2].charAt(0) === "=" ? 1 : 2,
1402
- text: e,
1403
- tokens: this.lexer.inline(e)
1404
- };
1405
- }
1406
- }
1407
- paragraph(e) {
1408
- let t = this.rules.block.paragraph.exec(e);
1409
- if (t) {
1410
- let e = t[1].charAt(t[1].length - 1) === "\n" ? t[1].slice(0, -1) : t[1];
1411
- return {
1412
- type: "paragraph",
1413
- raw: t[0],
1414
- text: e,
1415
- tokens: this.lexer.inline(e)
1416
- };
1417
- }
1418
- }
1419
- text(e) {
1420
- let t = this.rules.block.text.exec(e);
1421
- if (t) return {
1422
- type: "text",
1423
- raw: t[0],
1424
- text: t[0],
1425
- tokens: this.lexer.inline(t[0])
1426
- };
1427
- }
1428
- escape(e) {
1429
- let t = this.rules.inline.escape.exec(e);
1430
- if (t) return {
1431
- type: "escape",
1432
- raw: t[0],
1433
- text: t[1]
1434
- };
1435
- }
1436
- tag(e) {
1437
- let t = this.rules.inline.tag.exec(e);
1438
- if (t) return !this.lexer.state.inLink && this.rules.other.startATag.test(t[0]) ? this.lexer.state.inLink = !0 : this.lexer.state.inLink && this.rules.other.endATag.test(t[0]) && (this.lexer.state.inLink = !1), !this.lexer.state.inRawBlock && this.rules.other.startPreScriptTag.test(t[0]) ? this.lexer.state.inRawBlock = !0 : this.lexer.state.inRawBlock && this.rules.other.endPreScriptTag.test(t[0]) && (this.lexer.state.inRawBlock = !1), {
1439
- type: "html",
1440
- raw: t[0],
1441
- inLink: this.lexer.state.inLink,
1442
- inRawBlock: this.lexer.state.inRawBlock,
1443
- block: !1,
1444
- text: t[0]
1445
- };
1446
- }
1447
- link(e) {
1448
- let t = this.rules.inline.link.exec(e);
1449
- if (t) {
1450
- let e = t[2].trim();
1451
- if (!this.options.pedantic && this.rules.other.startAngleBracket.test(e)) {
1452
- if (!this.rules.other.endAngleBracket.test(e)) return;
1453
- let t = W(e.slice(0, -1), "\\");
1454
- if ((e.length - t.length) % 2 == 0) return;
1455
- } else {
1456
- let e = En(t[2], "()");
1457
- if (e === -2) return;
1458
- if (e > -1) {
1459
- let n = (t[0].indexOf("!") === 0 ? 5 : 4) + t[1].length + e;
1460
- t[2] = t[2].substring(0, e), t[0] = t[0].substring(0, n).trim(), t[3] = "";
1461
- }
1462
- }
1463
- let n = t[2], r = "";
1464
- if (this.options.pedantic) {
1465
- let e = this.rules.other.pedanticHrefTitle.exec(n);
1466
- e && (n = e[1], r = e[3]);
1467
- } else r = t[3] ? t[3].slice(1, -1) : "";
1468
- return n = n.trim(), this.rules.other.startAngleBracket.test(n) && (n = this.options.pedantic && !this.rules.other.endAngleBracket.test(e) ? n.slice(1) : n.slice(1, -1)), On(t, {
1469
- href: n && n.replace(this.rules.inline.anyPunctuation, "$1"),
1470
- title: r && r.replace(this.rules.inline.anyPunctuation, "$1")
1471
- }, t[0], this.lexer, this.rules);
1472
- }
1473
- }
1474
- reflink(e, t) {
1475
- let n;
1476
- if ((n = this.rules.inline.reflink.exec(e)) || (n = this.rules.inline.nolink.exec(e))) {
1477
- let e = t[(n[2] || n[1]).replace(this.rules.other.multipleSpaceGlobal, " ").toLowerCase()];
1478
- if (!e) {
1479
- let e = n[0].charAt(0);
1480
- return {
1481
- type: "text",
1482
- raw: e,
1483
- text: e
1484
- };
1485
- }
1486
- return On(n, e, n[0], this.lexer, this.rules);
1487
- }
1488
- }
1489
- emStrong(e, t, n = "") {
1490
- let r = this.rules.inline.emStrongLDelim.exec(e);
1491
- if (!(!r || !r[1] && !r[2] && !r[3] && !r[4] || r[4] && n.match(this.rules.other.unicodeAlphaNumeric)) && (!(r[1] || r[3]) || !n || this.rules.inline.punctuation.exec(n))) {
1492
- let n = [...r[0]].length - 1, i, a, o = n, s = 0, c = r[0][0] === "*" ? this.rules.inline.emStrongRDelimAst : this.rules.inline.emStrongRDelimUnd;
1493
- for (c.lastIndex = 0, t = t.slice(-1 * e.length + n); (r = c.exec(t)) !== null;) {
1494
- if (i = r[1] || r[2] || r[3] || r[4] || r[5] || r[6], !i) continue;
1495
- if (a = [...i].length, r[3] || r[4]) {
1496
- o += a;
1497
- continue;
1498
- } else if ((r[5] || r[6]) && n % 3 && !((n + a) % 3)) {
1499
- s += a;
1500
- continue;
1501
- }
1502
- if (o -= a, o > 0) continue;
1503
- a = Math.min(a, a + o + s);
1504
- let t = [...r[0]][0].length, c = e.slice(0, n + r.index + t + a);
1505
- if (Math.min(n, a) % 2) {
1506
- let e = c.slice(1, -1);
1507
- return {
1508
- type: "em",
1509
- raw: c,
1510
- text: e,
1511
- tokens: this.lexer.inlineTokens(e)
1512
- };
1513
- }
1514
- let l = c.slice(2, -2);
1515
- return {
1516
- type: "strong",
1517
- raw: c,
1518
- text: l,
1519
- tokens: this.lexer.inlineTokens(l)
1520
- };
1521
- }
1522
- }
1523
- }
1524
- codespan(e) {
1525
- let t = this.rules.inline.code.exec(e);
1526
- if (t) {
1527
- let e = t[2].replace(this.rules.other.newLineCharGlobal, " "), n = this.rules.other.nonSpaceChar.test(e), r = this.rules.other.startingSpaceChar.test(e) && this.rules.other.endingSpaceChar.test(e);
1528
- return n && r && (e = e.substring(1, e.length - 1)), {
1529
- type: "codespan",
1530
- raw: t[0],
1531
- text: e
1532
- };
1533
- }
1534
- }
1535
- br(e) {
1536
- let t = this.rules.inline.br.exec(e);
1537
- if (t) return {
1538
- type: "br",
1539
- raw: t[0]
1540
- };
1541
- }
1542
- del(e, t, n = "") {
1543
- let r = this.rules.inline.delLDelim.exec(e);
1544
- if (r && (!r[1] || !n || this.rules.inline.punctuation.exec(n))) {
1545
- let n = [...r[0]].length - 1, i, a, o = n, s = this.rules.inline.delRDelim;
1546
- for (s.lastIndex = 0, t = t.slice(-1 * e.length + n); (r = s.exec(t)) !== null;) {
1547
- if (i = r[1] || r[2] || r[3] || r[4] || r[5] || r[6], !i || (a = [...i].length, a !== n)) continue;
1548
- if (r[3] || r[4]) {
1549
- o += a;
1550
- continue;
1551
- }
1552
- if (o -= a, o > 0) continue;
1553
- a = Math.min(a, a + o);
1554
- let t = [...r[0]][0].length, s = e.slice(0, n + r.index + t + a), c = s.slice(n, -n);
1555
- return {
1556
- type: "del",
1557
- raw: s,
1558
- text: c,
1559
- tokens: this.lexer.inlineTokens(c)
1560
- };
1561
- }
1562
- }
1563
- }
1564
- autolink(e) {
1565
- let t = this.rules.inline.autolink.exec(e);
1566
- if (t) {
1567
- let e, n;
1568
- return t[2] === "@" ? (e = t[1], n = "mailto:" + e) : (e = t[1], n = e), {
1569
- type: "link",
1570
- raw: t[0],
1571
- text: e,
1572
- href: n,
1573
- tokens: [{
1574
- type: "text",
1575
- raw: e,
1576
- text: e
1577
- }]
1578
- };
1579
- }
1580
- }
1581
- url(e) {
1582
- let t;
1583
- if (t = this.rules.inline.url.exec(e)) {
1584
- let e, n;
1585
- if (t[2] === "@") e = t[0], n = "mailto:" + e;
1586
- else {
1587
- let r;
1588
- do
1589
- r = t[0], t[0] = this.rules.inline._backpedal.exec(t[0])?.[0] ?? "";
1590
- while (r !== t[0]);
1591
- e = t[0], n = t[1] === "www." ? "http://" + t[0] : t[0];
1592
- }
1593
- return {
1594
- type: "link",
1595
- raw: t[0],
1596
- text: e,
1597
- href: n,
1598
- tokens: [{
1599
- type: "text",
1600
- raw: e,
1601
- text: e
1602
- }]
1603
- };
1604
- }
1605
- }
1606
- inlineText(e) {
1607
- let t = this.rules.inline.text.exec(e);
1608
- if (t) {
1609
- let e = this.lexer.state.inRawBlock;
1610
- return {
1611
- type: "text",
1612
- raw: t[0],
1613
- text: t[0],
1614
- escaped: e
1615
- };
1616
- }
1617
- }
1618
- }, K = class e {
1619
- constructor(e) {
1620
- s(this, "tokens", void 0), s(this, "options", void 0), s(this, "state", void 0), s(this, "inlineQueue", void 0), s(this, "tokenizer", void 0), this.tokens = [], this.tokens.links = Object.create(null), this.options = e || O, this.options.tokenizer = this.options.tokenizer || new G(), this.tokenizer = this.options.tokenizer, this.tokenizer.options = this.options, this.tokenizer.lexer = this, this.inlineQueue = [], this.state = {
1621
- inLink: !1,
1622
- inRawBlock: !1,
1623
- top: !0
1624
- };
1625
- let t = {
1626
- other: N,
1627
- block: bn.normal,
1628
- inline: H.normal
1629
- };
1630
- this.options.pedantic ? (t.block = bn.pedantic, t.inline = H.pedantic) : this.options.gfm && (t.block = bn.gfm, this.options.breaks ? t.inline = H.breaks : t.inline = H.gfm), this.tokenizer.rules = t;
1631
- }
1632
- static get rules() {
1633
- return {
1634
- block: bn,
1635
- inline: H
1636
- };
1637
- }
1638
- static lex(t, n) {
1639
- return new e(n).lex(t);
1640
- }
1641
- static lexInline(t, n) {
1642
- return new e(n).inlineTokens(t);
1643
- }
1644
- lex(e) {
1645
- e = e.replace(N.carriageReturn, "\n"), this.blockTokens(e, this.tokens);
1646
- for (let e = 0; e < this.inlineQueue.length; e++) {
1647
- let t = this.inlineQueue[e];
1648
- this.inlineTokens(t.src, t.tokens);
1649
- }
1650
- return this.inlineQueue = [], this.tokens;
1651
- }
1652
- blockTokens(e, t = [], n = !1) {
1653
- this.tokenizer.lexer = this, this.options.pedantic && (e = e.replace(N.tabCharGlobal, " ").replace(N.spaceLine, ""));
1654
- let r = Infinity;
1655
- for (; e;) {
1656
- if (e.length < r) r = e.length;
1657
- else {
1658
- this.infiniteLoopError(e.charCodeAt(0));
1659
- break;
1660
- }
1661
- let i;
1662
- if (this.options.extensions?.block?.some((n) => (i = n.call({ lexer: this }, e, t)) ? (e = e.substring(i.raw.length), t.push(i), !0) : !1)) continue;
1663
- if (i = this.tokenizer.space(e)) {
1664
- e = e.substring(i.raw.length);
1665
- let n = t.at(-1);
1666
- i.raw.length === 1 && n !== void 0 ? n.raw += "\n" : t.push(i);
1667
- continue;
1668
- }
1669
- if (i = this.tokenizer.code(e)) {
1670
- e = e.substring(i.raw.length);
1671
- let n = t.at(-1);
1672
- n?.type === "paragraph" || n?.type === "text" ? (n.raw += (n.raw.endsWith("\n") ? "" : "\n") + i.raw, n.text += "\n" + i.text, this.inlineQueue.at(-1).src = n.text) : t.push(i);
1673
- continue;
1674
- }
1675
- if (i = this.tokenizer.fences(e)) {
1676
- e = e.substring(i.raw.length), t.push(i);
1677
- continue;
1678
- }
1679
- if (i = this.tokenizer.heading(e)) {
1680
- e = e.substring(i.raw.length), t.push(i);
1681
- continue;
1682
- }
1683
- if (i = this.tokenizer.hr(e)) {
1684
- e = e.substring(i.raw.length), t.push(i);
1685
- continue;
1686
- }
1687
- if (i = this.tokenizer.blockquote(e)) {
1688
- e = e.substring(i.raw.length), t.push(i);
1689
- continue;
1690
- }
1691
- if (i = this.tokenizer.list(e)) {
1692
- e = e.substring(i.raw.length), t.push(i);
1693
- continue;
1694
- }
1695
- if (i = this.tokenizer.html(e)) {
1696
- e = e.substring(i.raw.length), t.push(i);
1697
- continue;
1698
- }
1699
- if (i = this.tokenizer.def(e)) {
1700
- e = e.substring(i.raw.length);
1701
- let n = t.at(-1);
1702
- n?.type === "paragraph" || n?.type === "text" ? (n.raw += (n.raw.endsWith("\n") ? "" : "\n") + i.raw, n.text += "\n" + i.raw, this.inlineQueue.at(-1).src = n.text) : this.tokens.links[i.tag] || (this.tokens.links[i.tag] = {
1703
- href: i.href,
1704
- title: i.title
1705
- }, t.push(i));
1706
- continue;
1707
- }
1708
- if (i = this.tokenizer.table(e)) {
1709
- e = e.substring(i.raw.length), t.push(i);
1710
- continue;
1711
- }
1712
- if (i = this.tokenizer.lheading(e)) {
1713
- e = e.substring(i.raw.length), t.push(i);
1714
- continue;
1715
- }
1716
- let a = e;
1717
- if (this.options.extensions?.startBlock) {
1718
- let t = Infinity, n = e.slice(1), r;
1719
- this.options.extensions.startBlock.forEach((e) => {
1720
- r = e.call({ lexer: this }, n), typeof r == "number" && r >= 0 && (t = Math.min(t, r));
1721
- }), t < Infinity && t >= 0 && (a = e.substring(0, t + 1));
1722
- }
1723
- if (this.state.top && (i = this.tokenizer.paragraph(a))) {
1724
- let r = t.at(-1);
1725
- n && r?.type === "paragraph" ? (r.raw += (r.raw.endsWith("\n") ? "" : "\n") + i.raw, r.text += "\n" + i.text, this.inlineQueue.pop(), this.inlineQueue.at(-1).src = r.text) : t.push(i), n = a.length !== e.length, e = e.substring(i.raw.length);
1726
- continue;
1727
- }
1728
- if (i = this.tokenizer.text(e)) {
1729
- e = e.substring(i.raw.length);
1730
- let n = t.at(-1);
1731
- n?.type === "text" ? (n.raw += (n.raw.endsWith("\n") ? "" : "\n") + i.raw, n.text += "\n" + i.text, this.inlineQueue.pop(), this.inlineQueue.at(-1).src = n.text) : t.push(i);
1732
- continue;
1733
- }
1734
- if (e) {
1735
- this.infiniteLoopError(e.charCodeAt(0));
1736
- break;
1737
- }
1738
- }
1739
- return this.state.top = !0, t;
1740
- }
1741
- inline(e, t = []) {
1742
- return this.inlineQueue.push({
1743
- src: e,
1744
- tokens: t
1745
- }), t;
1746
- }
1747
- inlineTokens(e, t = []) {
1748
- this.tokenizer.lexer = this;
1749
- let n = e, r = null;
1750
- if (this.tokens.links) {
1751
- let e = Object.keys(this.tokens.links);
1752
- if (e.length > 0) for (; (r = this.tokenizer.rules.inline.reflinkSearch.exec(n)) !== null;) e.includes(r[0].slice(r[0].lastIndexOf("[") + 1, -1)) && (n = n.slice(0, r.index) + "[" + "a".repeat(r[0].length - 2) + "]" + n.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex));
1753
- }
1754
- for (; (r = this.tokenizer.rules.inline.anyPunctuation.exec(n)) !== null;) n = n.slice(0, r.index) + "++" + n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);
1755
- let i;
1756
- for (; (r = this.tokenizer.rules.inline.blockSkip.exec(n)) !== null;) i = r[2] ? r[2].length : 0, n = n.slice(0, r.index + i) + "[" + "a".repeat(r[0].length - i - 2) + "]" + n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);
1757
- n = this.options.hooks?.emStrongMask?.call({ lexer: this }, n) ?? n;
1758
- let a = !1, o = "", s = Infinity;
1759
- for (; e;) {
1760
- if (e.length < s) s = e.length;
1761
- else {
1762
- this.infiniteLoopError(e.charCodeAt(0));
1763
- break;
1764
- }
1765
- a || (o = ""), a = !1;
1766
- let r;
1767
- if (this.options.extensions?.inline?.some((n) => (r = n.call({ lexer: this }, e, t)) ? (e = e.substring(r.raw.length), t.push(r), !0) : !1)) continue;
1768
- if (r = this.tokenizer.escape(e)) {
1769
- e = e.substring(r.raw.length), t.push(r);
1770
- continue;
1771
- }
1772
- if (r = this.tokenizer.tag(e)) {
1773
- e = e.substring(r.raw.length), t.push(r);
1774
- continue;
1775
- }
1776
- if (r = this.tokenizer.link(e)) {
1777
- e = e.substring(r.raw.length), t.push(r);
1778
- continue;
1779
- }
1780
- if (r = this.tokenizer.reflink(e, this.tokens.links)) {
1781
- e = e.substring(r.raw.length);
1782
- let n = t.at(-1);
1783
- r.type === "text" && n?.type === "text" ? (n.raw += r.raw, n.text += r.text) : t.push(r);
1784
- continue;
1785
- }
1786
- if (r = this.tokenizer.emStrong(e, n, o)) {
1787
- e = e.substring(r.raw.length), t.push(r);
1788
- continue;
1789
- }
1790
- if (r = this.tokenizer.codespan(e)) {
1791
- e = e.substring(r.raw.length), t.push(r);
1792
- continue;
1793
- }
1794
- if (r = this.tokenizer.br(e)) {
1795
- e = e.substring(r.raw.length), t.push(r);
1796
- continue;
1797
- }
1798
- if (r = this.tokenizer.del(e, n, o)) {
1799
- e = e.substring(r.raw.length), t.push(r);
1800
- continue;
1801
- }
1802
- if (r = this.tokenizer.autolink(e)) {
1803
- e = e.substring(r.raw.length), t.push(r);
1804
- continue;
1805
- }
1806
- if (!this.state.inLink && (r = this.tokenizer.url(e))) {
1807
- e = e.substring(r.raw.length), t.push(r);
1808
- continue;
1809
- }
1810
- let i = e;
1811
- if (this.options.extensions?.startInline) {
1812
- let t = Infinity, n = e.slice(1), r;
1813
- this.options.extensions.startInline.forEach((e) => {
1814
- r = e.call({ lexer: this }, n), typeof r == "number" && r >= 0 && (t = Math.min(t, r));
1815
- }), t < Infinity && t >= 0 && (i = e.substring(0, t + 1));
1816
- }
1817
- if (r = this.tokenizer.inlineText(i)) {
1818
- e = e.substring(r.raw.length), r.raw.slice(-1) !== "_" && (o = r.raw.slice(-1)), a = !0;
1819
- let n = t.at(-1);
1820
- n?.type === "text" ? (n.raw += r.raw, n.text += r.text) : t.push(r);
1821
- continue;
1822
- }
1823
- if (e) {
1824
- this.infiniteLoopError(e.charCodeAt(0));
1825
- break;
1826
- }
1827
- }
1828
- return t;
1829
- }
1830
- infiniteLoopError(e) {
1831
- let t = "Infinite loop on byte: " + e;
1832
- if (this.options.silent) console.error(t);
1833
- else throw Error(t);
1834
- }
1835
- }, An = class {
1836
- constructor(e) {
1837
- s(this, "options", void 0), s(this, "parser", void 0), this.options = e || O;
1838
- }
1839
- space(e) {
1840
- return "";
1841
- }
1842
- code({ text: e, lang: t, escaped: n }) {
1843
- let r = (t || "").match(N.notSpaceStart)?.[0], i = e.replace(N.endingNewline, "") + "\n";
1844
- return r ? "<pre><code class=\"language-" + U(r) + "\">" + (n ? i : U(i, !0)) + "</code></pre>\n" : "<pre><code>" + (n ? i : U(i, !0)) + "</code></pre>\n";
1845
- }
1846
- blockquote({ tokens: e }) {
1847
- return `<blockquote>
1848
- ${this.parser.parse(e)}</blockquote>
1849
- `;
1850
- }
1851
- html({ text: e }) {
1852
- return e;
1853
- }
1854
- def(e) {
1855
- return "";
1856
- }
1857
- heading({ tokens: e, depth: t }) {
1858
- return `<h${t}>${this.parser.parseInline(e)}</h${t}>
1859
- `;
1860
- }
1861
- hr(e) {
1862
- return "<hr>\n";
1863
- }
1864
- list(e) {
1865
- let t = e.ordered, n = e.start, r = "";
1866
- for (let t = 0; t < e.items.length; t++) {
1867
- let n = e.items[t];
1868
- r += this.listitem(n);
1869
- }
1870
- let i = t ? "ol" : "ul", a = t && n !== 1 ? " start=\"" + n + "\"" : "";
1871
- return "<" + i + a + ">\n" + r + "</" + i + ">\n";
1872
- }
1873
- listitem(e) {
1874
- return `<li>${this.parser.parse(e.tokens)}</li>
1875
- `;
1876
- }
1877
- checkbox({ checked: e }) {
1878
- return "<input " + (e ? "checked=\"\" " : "") + "disabled=\"\" type=\"checkbox\"> ";
1879
- }
1880
- paragraph({ tokens: e }) {
1881
- return `<p>${this.parser.parseInline(e)}</p>
1882
- `;
1883
- }
1884
- table(e) {
1885
- let t = "", n = "";
1886
- for (let t = 0; t < e.header.length; t++) n += this.tablecell(e.header[t]);
1887
- t += this.tablerow({ text: n });
1888
- let r = "";
1889
- for (let t = 0; t < e.rows.length; t++) {
1890
- let i = e.rows[t];
1891
- n = "";
1892
- for (let e = 0; e < i.length; e++) n += this.tablecell(i[e]);
1893
- r += this.tablerow({ text: n });
1894
- }
1895
- return r &&= `<tbody>${r}</tbody>`, "<table>\n<thead>\n" + t + "</thead>\n" + r + "</table>\n";
1896
- }
1897
- tablerow({ text: e }) {
1898
- return `<tr>
1899
- ${e}</tr>
1900
- `;
1901
- }
1902
- tablecell(e) {
1903
- let t = this.parser.parseInline(e.tokens), n = e.header ? "th" : "td";
1904
- return (e.align ? `<${n} align="${e.align}">` : `<${n}>`) + t + `</${n}>
1905
- `;
1906
- }
1907
- strong({ tokens: e }) {
1908
- return `<strong>${this.parser.parseInline(e)}</strong>`;
1909
- }
1910
- em({ tokens: e }) {
1911
- return `<em>${this.parser.parseInline(e)}</em>`;
1912
- }
1913
- codespan({ text: e }) {
1914
- return `<code>${U(e, !0)}</code>`;
1915
- }
1916
- br(e) {
1917
- return "<br>";
1918
- }
1919
- del({ tokens: e }) {
1920
- return `<del>${this.parser.parseInline(e)}</del>`;
1921
- }
1922
- link({ href: e, title: t, tokens: n }) {
1923
- let r = this.parser.parseInline(n), i = Cn(e);
1924
- if (i === null) return r;
1925
- e = i;
1926
- let a = "<a href=\"" + e + "\"";
1927
- return t && (a += " title=\"" + U(t) + "\""), a += ">" + r + "</a>", a;
1928
- }
1929
- image({ href: e, title: t, text: n, tokens: r }) {
1930
- r && (n = this.parser.parseInline(r, this.parser.textRenderer));
1931
- let i = Cn(e);
1932
- if (i === null) return U(n);
1933
- e = i;
1934
- let a = `<img src="${e}" alt="${U(n)}"`;
1935
- return t && (a += ` title="${U(t)}"`), a += ">", a;
1936
- }
1937
- text(e) {
1938
- return "tokens" in e && e.tokens ? this.parser.parseInline(e.tokens) : "escaped" in e && e.escaped ? e.text : U(e.text);
1939
- }
1940
- }, jn = class {
1941
- strong({ text: e }) {
1942
- return e;
1943
- }
1944
- em({ text: e }) {
1945
- return e;
1946
- }
1947
- codespan({ text: e }) {
1948
- return e;
1949
- }
1950
- del({ text: e }) {
1951
- return e;
1952
- }
1953
- html({ text: e }) {
1954
- return e;
1955
- }
1956
- text({ text: e }) {
1957
- return e;
1958
- }
1959
- link({ text: e }) {
1960
- return "" + e;
1961
- }
1962
- image({ text: e }) {
1963
- return "" + e;
1964
- }
1965
- br() {
1966
- return "";
1967
- }
1968
- checkbox({ raw: e }) {
1969
- return e;
1970
- }
1971
- }, q = class e {
1972
- constructor(e) {
1973
- s(this, "options", void 0), s(this, "renderer", void 0), s(this, "textRenderer", void 0), this.options = e || O, this.options.renderer = this.options.renderer || new An(), this.renderer = this.options.renderer, this.renderer.options = this.options, this.renderer.parser = this, this.textRenderer = new jn();
1974
- }
1975
- static parse(t, n) {
1976
- return new e(n).parse(t);
1977
- }
1978
- static parseInline(t, n) {
1979
- return new e(n).parseInline(t);
1980
- }
1981
- parse(e) {
1982
- this.renderer.parser = this;
1983
- let t = "";
1984
- for (let n = 0; n < e.length; n++) {
1985
- let r = e[n];
1986
- if (this.options.extensions?.renderers?.[r.type]) {
1987
- let e = r, n = this.options.extensions.renderers[e.type].call({ parser: this }, e);
1988
- if (n !== !1 || ![
1989
- "space",
1990
- "hr",
1991
- "heading",
1992
- "code",
1993
- "table",
1994
- "blockquote",
1995
- "list",
1996
- "html",
1997
- "def",
1998
- "paragraph",
1999
- "text"
2000
- ].includes(e.type)) {
2001
- t += n || "";
2002
- continue;
2003
- }
2004
- }
2005
- let i = r;
2006
- switch (i.type) {
2007
- case "space":
2008
- t += this.renderer.space(i);
2009
- break;
2010
- case "hr":
2011
- t += this.renderer.hr(i);
2012
- break;
2013
- case "heading":
2014
- t += this.renderer.heading(i);
2015
- break;
2016
- case "code":
2017
- t += this.renderer.code(i);
2018
- break;
2019
- case "table":
2020
- t += this.renderer.table(i);
2021
- break;
2022
- case "blockquote":
2023
- t += this.renderer.blockquote(i);
2024
- break;
2025
- case "list":
2026
- t += this.renderer.list(i);
2027
- break;
2028
- case "checkbox":
2029
- t += this.renderer.checkbox(i);
2030
- break;
2031
- case "html":
2032
- t += this.renderer.html(i);
2033
- break;
2034
- case "def":
2035
- t += this.renderer.def(i);
2036
- break;
2037
- case "paragraph":
2038
- t += this.renderer.paragraph(i);
2039
- break;
2040
- case "text":
2041
- t += this.renderer.text(i);
2042
- break;
2043
- default: {
2044
- let e = "Token with \"" + i.type + "\" type was not found.";
2045
- if (this.options.silent) return console.error(e), "";
2046
- throw Error(e);
2047
- }
2048
- }
2049
- }
2050
- return t;
2051
- }
2052
- parseInline(e, t = this.renderer) {
2053
- this.renderer.parser = this;
2054
- let n = "";
2055
- for (let r = 0; r < e.length; r++) {
2056
- let i = e[r];
2057
- if (this.options.extensions?.renderers?.[i.type]) {
2058
- let e = this.options.extensions.renderers[i.type].call({ parser: this }, i);
2059
- if (e !== !1 || ![
2060
- "escape",
2061
- "html",
2062
- "link",
2063
- "image",
2064
- "strong",
2065
- "em",
2066
- "codespan",
2067
- "br",
2068
- "del",
2069
- "text"
2070
- ].includes(i.type)) {
2071
- n += e || "";
2072
- continue;
2073
- }
2074
- }
2075
- let a = i;
2076
- switch (a.type) {
2077
- case "escape":
2078
- n += t.text(a);
2079
- break;
2080
- case "html":
2081
- n += t.html(a);
2082
- break;
2083
- case "link":
2084
- n += t.link(a);
2085
- break;
2086
- case "image":
2087
- n += t.image(a);
2088
- break;
2089
- case "checkbox":
2090
- n += t.checkbox(a);
2091
- break;
2092
- case "strong":
2093
- n += t.strong(a);
2094
- break;
2095
- case "em":
2096
- n += t.em(a);
2097
- break;
2098
- case "codespan":
2099
- n += t.codespan(a);
2100
- break;
2101
- case "br":
2102
- n += t.br(a);
2103
- break;
2104
- case "del":
2105
- n += t.del(a);
2106
- break;
2107
- case "text":
2108
- n += t.text(a);
2109
- break;
2110
- default: {
2111
- let e = "Token with \"" + a.type + "\" type was not found.";
2112
- if (this.options.silent) return console.error(e), "";
2113
- throw Error(e);
2114
- }
2115
- }
2116
- }
2117
- return n;
2118
- }
2119
- }, J = (xt = class {
2120
- constructor(e) {
2121
- s(this, "options", void 0), s(this, "block", void 0), this.options = e || O;
2122
- }
2123
- preprocess(e) {
2124
- return e;
2125
- }
2126
- postprocess(e) {
2127
- return e;
2128
- }
2129
- processAllTokens(e) {
2130
- return e;
2131
- }
2132
- emStrongMask(e) {
2133
- return e;
2134
- }
2135
- provideLexer(e = this.block) {
2136
- return e ? K.lex : K.lexInline;
2137
- }
2138
- provideParser(e = this.block) {
2139
- return e ? q.parse : q.parseInline;
2140
- }
2141
- }, s(xt, "passThroughHooks", /* @__PURE__ */ new Set([
2142
- "preprocess",
2143
- "postprocess",
2144
- "processAllTokens",
2145
- "emStrongMask"
2146
- ])), s(xt, "passThroughHooksRespectAsync", /* @__PURE__ */ new Set([
2147
- "preprocess",
2148
- "postprocess",
2149
- "processAllTokens"
2150
- ])), xt), Y = new class {
2151
- constructor(...e) {
2152
- s(this, "defaults", St()), s(this, "options", this.setOptions), s(this, "parse", this.parseMarkdown(!0)), s(this, "parseInline", this.parseMarkdown(!1)), s(this, "Parser", q), s(this, "Renderer", An), s(this, "TextRenderer", jn), s(this, "Lexer", K), s(this, "Tokenizer", G), s(this, "Hooks", J), this.use(...e);
2153
- }
2154
- walkTokens(e, t) {
2155
- let n = [];
2156
- for (let r of e) switch (n = n.concat(t.call(this, r)), r.type) {
2157
- case "table": {
2158
- let e = r;
2159
- for (let r of e.header) n = n.concat(this.walkTokens(r.tokens, t));
2160
- for (let r of e.rows) for (let e of r) n = n.concat(this.walkTokens(e.tokens, t));
2161
- break;
2162
- }
2163
- case "list": {
2164
- let e = r;
2165
- n = n.concat(this.walkTokens(e.items, t));
2166
- break;
2167
- }
2168
- default: {
2169
- let e = r;
2170
- this.defaults.extensions?.childTokens?.[e.type] ? this.defaults.extensions.childTokens[e.type].forEach((r) => {
2171
- let i = e[r].flat(Infinity);
2172
- n = n.concat(this.walkTokens(i, t));
2173
- }) : e.tokens && (n = n.concat(this.walkTokens(e.tokens, t)));
2174
- }
2175
- }
2176
- return n;
2177
- }
2178
- use(...e) {
2179
- let t = this.defaults.extensions || {
2180
- renderers: {},
2181
- childTokens: {}
2182
- };
2183
- return e.forEach((e) => {
2184
- let n = { ...e };
2185
- if (n.async = this.defaults.async || n.async || !1, e.extensions && (e.extensions.forEach((e) => {
2186
- if (!e.name) throw Error("extension name required");
2187
- if ("renderer" in e) {
2188
- let n = t.renderers[e.name];
2189
- n ? t.renderers[e.name] = function(...t) {
2190
- let r = e.renderer.apply(this, t);
2191
- return r === !1 && (r = n.apply(this, t)), r;
2192
- } : t.renderers[e.name] = e.renderer;
2193
- }
2194
- if ("tokenizer" in e) {
2195
- if (!e.level || e.level !== "block" && e.level !== "inline") throw Error("extension level must be 'block' or 'inline'");
2196
- let n = t[e.level];
2197
- n ? n.unshift(e.tokenizer) : t[e.level] = [e.tokenizer], e.start && (e.level === "block" ? t.startBlock ? t.startBlock.push(e.start) : t.startBlock = [e.start] : e.level === "inline" && (t.startInline ? t.startInline.push(e.start) : t.startInline = [e.start]));
2198
- }
2199
- "childTokens" in e && e.childTokens && (t.childTokens[e.name] = e.childTokens);
2200
- }), n.extensions = t), e.renderer) {
2201
- let t = this.defaults.renderer || new An(this.defaults);
2202
- for (let n in e.renderer) {
2203
- if (!(n in t)) throw Error(`renderer '${n}' does not exist`);
2204
- if (["options", "parser"].includes(n)) continue;
2205
- let r = n, i = e.renderer[r], a = t[r];
2206
- t[r] = (...e) => {
2207
- let n = i.apply(t, e);
2208
- return n === !1 && (n = a.apply(t, e)), n || "";
2209
- };
2210
- }
2211
- n.renderer = t;
2212
- }
2213
- if (e.tokenizer) {
2214
- let t = this.defaults.tokenizer || new G(this.defaults);
2215
- for (let n in e.tokenizer) {
2216
- if (!(n in t)) throw Error(`tokenizer '${n}' does not exist`);
2217
- if ([
2218
- "options",
2219
- "rules",
2220
- "lexer"
2221
- ].includes(n)) continue;
2222
- let r = n, i = e.tokenizer[r], a = t[r];
2223
- t[r] = (...e) => {
2224
- let n = i.apply(t, e);
2225
- return n === !1 && (n = a.apply(t, e)), n;
2226
- };
2227
- }
2228
- n.tokenizer = t;
2229
- }
2230
- if (e.hooks) {
2231
- let t = this.defaults.hooks || new J();
2232
- for (let n in e.hooks) {
2233
- if (!(n in t)) throw Error(`hook '${n}' does not exist`);
2234
- if (["options", "block"].includes(n)) continue;
2235
- let r = n, i = e.hooks[r], a = t[r];
2236
- J.passThroughHooks.has(n) ? t[r] = (e) => {
2237
- if (this.defaults.async && J.passThroughHooksRespectAsync.has(n)) return (async () => {
2238
- let n = await i.call(t, e);
2239
- return a.call(t, n);
2240
- })();
2241
- let r = i.call(t, e);
2242
- return a.call(t, r);
2243
- } : t[r] = (...e) => {
2244
- if (this.defaults.async) return (async () => {
2245
- let n = await i.apply(t, e);
2246
- return n === !1 && (n = await a.apply(t, e)), n;
2247
- })();
2248
- let n = i.apply(t, e);
2249
- return n === !1 && (n = a.apply(t, e)), n;
2250
- };
2251
- }
2252
- n.hooks = t;
2253
- }
2254
- if (e.walkTokens) {
2255
- let t = this.defaults.walkTokens, r = e.walkTokens;
2256
- n.walkTokens = function(e) {
2257
- let n = [];
2258
- return n.push(r.call(this, e)), t && (n = n.concat(t.call(this, e))), n;
2259
- };
2260
- }
2261
- this.defaults = {
2262
- ...this.defaults,
2263
- ...n
2264
- };
2265
- }), this;
2266
- }
2267
- setOptions(e) {
2268
- return this.defaults = {
2269
- ...this.defaults,
2270
- ...e
2271
- }, this;
2272
- }
2273
- lexer(e, t) {
2274
- return K.lex(e, t ?? this.defaults);
2275
- }
2276
- parser(e, t) {
2277
- return q.parse(e, t ?? this.defaults);
2278
- }
2279
- parseMarkdown(e) {
2280
- return (t, n) => {
2281
- let r = { ...n }, i = {
2282
- ...this.defaults,
2283
- ...r
2284
- }, a = this.onError(!!i.silent, !!i.async);
2285
- if (this.defaults.async === !0 && r.async === !1) return a(/* @__PURE__ */ Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));
2286
- if (typeof t > "u" || t === null) return a(/* @__PURE__ */ Error("marked(): input parameter is undefined or null"));
2287
- if (typeof t != "string") return a(/* @__PURE__ */ Error("marked(): input parameter is of type " + Object.prototype.toString.call(t) + ", string expected"));
2288
- if (i.hooks && (i.hooks.options = i, i.hooks.block = e), i.async) return (async () => {
2289
- let n = i.hooks ? await i.hooks.preprocess(t) : t, r = await (i.hooks ? await i.hooks.provideLexer(e) : e ? K.lex : K.lexInline)(n, i), a = i.hooks ? await i.hooks.processAllTokens(r) : r;
2290
- i.walkTokens && await Promise.all(this.walkTokens(a, i.walkTokens));
2291
- let o = await (i.hooks ? await i.hooks.provideParser(e) : e ? q.parse : q.parseInline)(a, i);
2292
- return i.hooks ? await i.hooks.postprocess(o) : o;
2293
- })().catch(a);
2294
- try {
2295
- i.hooks && (t = i.hooks.preprocess(t));
2296
- let n = (i.hooks ? i.hooks.provideLexer(e) : e ? K.lex : K.lexInline)(t, i);
2297
- i.hooks && (n = i.hooks.processAllTokens(n)), i.walkTokens && this.walkTokens(n, i.walkTokens);
2298
- let r = (i.hooks ? i.hooks.provideParser(e) : e ? q.parse : q.parseInline)(n, i);
2299
- return i.hooks && (r = i.hooks.postprocess(r)), r;
2300
- } catch (e) {
2301
- return a(e);
2302
- }
2303
- };
2304
- }
2305
- onError(e, t) {
2306
- return (n) => {
2307
- if (n.message += "\nPlease report this to https://github.com/markedjs/marked.", e) {
2308
- let e = "<p>An error occurred:</p><pre>" + U(n.message + "", !0) + "</pre>";
2309
- return t ? Promise.resolve(e) : e;
2310
- }
2311
- if (t) return Promise.reject(n);
2312
- throw n;
2313
- };
2314
- }
2315
- }();
2316
- function X(e, t) {
2317
- return Y.parse(e, t);
2318
- }
2319
- X.options = X.setOptions = function(e) {
2320
- return Y.setOptions(e), X.defaults = Y.defaults, Ct(X.defaults), X;
2321
- }, X.getDefaults = St, X.defaults = O, X.use = function(...e) {
2322
- return Y.use(...e), X.defaults = Y.defaults, Ct(X.defaults), X;
2323
- }, X.walkTokens = function(e, t) {
2324
- return Y.walkTokens(e, t);
2325
- }, X.parseInline = Y.parseInline, X.Parser = q, X.parser = q.parse, X.Renderer = An, X.TextRenderer = jn, X.Lexer = K, X.lexer = K.lex, X.Tokenizer = G, X.Hooks = J, X.parse = X, X.options, X.setOptions, X.use, X.walkTokens, X.parseInline, q.parse, K.lex;
2326
- //#endregion
2327
- //#region src/components/ai-chat/ai-chat.module.scss?inline
2328
- var Mn = ":host{box-sizing:border-box;flex-direction:column;width:100%;height:100%;display:flex}:host .chat-container{background:var(--luzmo-ai-chat-background,var(--ai-chat-background));border-radius:var(--luzmo-ai-chat-border-radius,var(--ai-chat-border-radius));width:100%;height:100%;min-height:0;padding:var(--luzmo-ai-chat-padding,var(--ai-chat-padding));gap:var(--luzmo-ai-chat-gap,var(--ai-chat-gap));border:var(--luzmo-ai-chat-border,var(--ai-chat-border));box-shadow:var(--luzmo-ai-chat-box-shadow,var(--ai-chat-box-shadow));box-sizing:border-box;flex-direction:column;flex:1;display:flex;overflow:hidden}:host .chat-messages-container{gap:var(--luzmo-ai-chat-gap,var(--ai-chat-gap));flex-direction:column;flex:1;min-height:0;display:flex;overflow:auto}:host .chat-messages-container luzmo-ai-chat-empty-state{flex:1;min-height:0}:host .chat-messages-container::-webkit-scrollbar{width:var(--luzmo-ai-chat-scrollbar-width,var(--ai-chat-scrollbar-width))}:host .chat-messages-container::-webkit-scrollbar-track{background:var(--luzmo-ai-chat-scrollbar-track-background,var(--ai-chat-scrollbar-track-background));border-radius:var(--luzmo-ai-chat-scrollbar-track-border-radius,var(--ai-chat-scrollbar-track-border-radius))}:host .chat-messages-container::-webkit-scrollbar-thumb{background:var(--luzmo-ai-chat-scrollbar-thumb-background,var(--ai-chat-scrollbar-thumb-background));border-radius:var(--luzmo-ai-chat-scrollbar-thumb-border-radius,var(--ai-chat-scrollbar-thumb-border-radius))}:host .chat-messages-container::-webkit-scrollbar-thumb:hover{background:var(--luzmo-ai-chat-scrollbar-thumb-hover-background,var(--ai-chat-scrollbar-thumb-hover-background))}:host .chat-messages-container{scrollbar-width:var(--luzmo-scrollbar-width,thin);scrollbar-color:var(--luzmo-ai-chat-scrollbar-thumb-background,var(--ai-chat-scrollbar-thumb-background)) var(--luzmo-ai-chat-scrollbar-track-background,var(--ai-chat-scrollbar-track-background))}:host luzmo-chat-message{--luzmo-primary:rgba(var(--luzmo-primary-rgb), .08);--chat-message-primary-text-color:var(--luzmo-font-color);--chat-message-primary-border-color:transparent}:host luzmo-chat-message.error{color:var(--luzmo-ai-chat-error-message-color,var(--ai-chat-error-message-color))}:host luzmo-chat-message.cancelled{color:var(--luzmo-ai-chat-cancelled-message-color,var(--ai-chat-cancelled-message-color));font-style:italic}:host .user-message-content{gap:var(--luzmo-spacing-3,8px);flex-direction:column;display:flex}:host .user-message-attachments{gap:var(--luzmo-spacing-2,4px);flex-wrap:wrap;display:flex}:host .user-message-attachment{width:var(--luzmo-ai-chat-user-message-attachment-size,var(--ai-chat-user-message-attachment-size));height:var(--luzmo-ai-chat-user-message-attachment-size,var(--ai-chat-user-message-attachment-size));object-fit:cover;object-position:center;border-radius:var(--luzmo-border-radius-s,4px);pointer-events:none;display:block}:host .user-message-text{white-space:pre-wrap;overflow-wrap:anywhere}:host .markdown-content{line-height:var(--luzmo-ai-chat-markdown-line-height,var(--ai-chat-markdown-line-height))}:host .markdown-content>:first-child{margin-top:0}:host .markdown-content>:last-child{margin-bottom:0}:host .markdown-content p,:host .markdown-content ul,:host .markdown-content ol,:host .markdown-content blockquote,:host .markdown-content pre,:host .markdown-content table{margin:0 0 var(--luzmo-ai-chat-markdown-spacing,var(--ai-chat-markdown-spacing))}:host .markdown-content h1,:host .markdown-content h2,:host .markdown-content h3,:host .markdown-content h4,:host .markdown-content h5,:host .markdown-content h6{margin:var(--luzmo-ai-chat-markdown-heading-spacing,var(--ai-chat-markdown-heading-spacing)) 0 var(--luzmo-ai-chat-markdown-spacing,var(--ai-chat-markdown-spacing));font-weight:var(--luzmo-ai-chat-markdown-heading-font-weight,var(--ai-chat-markdown-heading-font-weight))}:host .markdown-content ul,:host .markdown-content ol{padding-inline-start:var(--luzmo-ai-chat-markdown-list-indent,var(--ai-chat-markdown-list-indent))}:host .markdown-content a{color:var(--luzmo-ai-chat-markdown-link-color,var(--ai-chat-markdown-link-color))}:host .markdown-content code{font-family:var(--luzmo-ai-chat-markdown-code-font-family,var(--ai-chat-markdown-code-font-family));font-size:var(--luzmo-ai-chat-markdown-code-font-size,var(--ai-chat-markdown-code-font-size));background:var(--luzmo-ai-chat-markdown-code-background,var(--ai-chat-markdown-code-background));border-radius:var(--luzmo-ai-chat-markdown-code-border-radius,var(--ai-chat-markdown-code-border-radius));padding:.1em .3em}:host .markdown-content pre{background:var(--luzmo-ai-chat-markdown-code-background,var(--ai-chat-markdown-code-background));border-radius:var(--luzmo-ai-chat-markdown-code-border-radius,var(--ai-chat-markdown-code-border-radius));padding:.75em 1em;overflow-x:auto}:host .markdown-content pre code{background:0 0;padding:0}:host .markdown-content blockquote{border-inline-start:.1875rem solid var(--luzmo-ai-chat-markdown-border-color,var(--ai-chat-markdown-border-color));padding-inline-start:.75rem}:host .markdown-content hr{border:0;border-top:.0625rem solid var(--luzmo-ai-chat-markdown-border-color,var(--ai-chat-markdown-border-color));margin:var(--luzmo-ai-chat-markdown-heading-spacing,var(--ai-chat-markdown-heading-spacing)) 0}:host .markdown-content table{border-collapse:collapse;width:100%}:host .markdown-content th,:host .markdown-content td{border:.0625rem solid var(--luzmo-ai-chat-markdown-border-color,var(--ai-chat-markdown-border-color));text-align:start;padding:.375rem .625rem}:host .markdown-content th{background:var(--luzmo-ai-chat-markdown-table-header-background,var(--ai-chat-markdown-table-header-background));font-weight:600}:host .assistant-message-wrapper{gap:var(--luzmo-ai-chat-assistant-message-actions-margin-top,var(--ai-chat-assistant-message-actions-margin-top));font-family:var(--luzmo-ai-chat-assistant-message-font-family,var(--ai-chat-assistant-message-font-family));font-size:var(--luzmo-ai-chat-assistant-message-font-size,var(--ai-chat-assistant-message-font-size));line-height:var(--luzmo-ai-chat-assistant-message-line-height,var(--ai-chat-assistant-message-line-height));flex-direction:column;display:flex}:host luzmo-chat-message[position=left]{--luzmo-chat-message-font-family:var(--luzmo-ai-chat-assistant-message-font-family,var(--ai-chat-assistant-message-font-family));--luzmo-chat-message-font-size:var(--luzmo-ai-chat-assistant-message-font-size,var(--ai-chat-assistant-message-font-size));--luzmo-chat-message-line-height:var(--luzmo-ai-chat-assistant-message-line-height,var(--ai-chat-assistant-message-line-height))}:host .assistant-message-body{justify-content:space-between;align-items:flex-start;gap:1rem;display:flex}:host .assistant-message-actions{align-items:center;gap:var(--luzmo-ai-chat-assistant-message-actions-gap,var(--ai-chat-assistant-message-actions-gap));flex-wrap:wrap;display:none}:host .assistant-message-actions.assistant-message-actions--has-content{display:flex}:host .assistant-message-actions.assistant-message-actions--confirming{flex-direction:column;align-items:flex-start}:host .assistant-message-actions .assistant-message-action-confirm-message{font-style:var(--luzmo-ai-chat-assistant-message-actions-font-style,var(--ai-chat-assistant-message-actions-font-style));color:var(--luzmo-ai-chat-assistant-message-actions-color,var(--ai-chat-assistant-message-actions-color));white-space:pre-line}:host .assistant-message-actions .assistant-message-action-confirm-controls{align-items:center;gap:var(--luzmo-ai-chat-assistant-message-actions-gap,var(--ai-chat-assistant-message-actions-gap));flex-wrap:wrap;display:flex}:host .assistant-message-actions luzmo-button.assistant-message-action,:host .assistant-message-actions slot::slotted(luzmo-button),:host .assistant-message-actions slot::slotted(button),:host .assistant-message-actions slot::slotted(a),:host .assistant-message-actions slot::slotted(input),:host .assistant-message-actions slot::slotted(select),:host .assistant-message-actions slot::slotted(textarea){font-style:normal}:host .assistant-message-actions slot::slotted(:not(luzmo-button):not(button):not(a):not(input):not(select):not(textarea)){font-style:var(--luzmo-ai-chat-assistant-message-actions-font-style,var(--ai-chat-assistant-message-actions-font-style));color:var(--luzmo-ai-chat-assistant-message-actions-color,var(--ai-chat-assistant-message-actions-color))}:host .assistant-context-menu-trigger{width:var(--luzmo-ai-chat-context-menu-trigger-size,var(--ai-chat-context-menu-trigger-size));height:var(--luzmo-ai-chat-context-menu-trigger-size,var(--ai-chat-context-menu-trigger-size));border:.0625rem solid var(--luzmo-ai-chat-context-menu-trigger-border-color,var(--ai-chat-context-menu-trigger-border-color));border-radius:var(--luzmo-ai-chat-context-menu-trigger-border-radius,var(--ai-chat-context-menu-trigger-border-radius));background:var(--luzmo-ai-chat-context-menu-trigger-background,var(--ai-chat-context-menu-trigger-background));color:var(--luzmo-ai-chat-context-menu-trigger-color,var(--ai-chat-context-menu-trigger-color));cursor:pointer;font-size:var(--ai-chat-context-menu-trigger-icon-size);justify-content:center;align-items:center;padding:0;line-height:1;transition:all .15s;display:inline-flex}:host .assistant-context-menu-trigger:hover{background:var(--luzmo-ai-chat-context-menu-trigger-hover-background,var(--ai-chat-context-menu-trigger-hover-background));border-color:var(--luzmo-ai-chat-context-menu-trigger-hover-border-color,var(--ai-chat-context-menu-trigger-hover-border-color));color:var(--luzmo-ai-chat-context-menu-trigger-hover-color,var(--ai-chat-context-menu-trigger-hover-color))}:host .assistant-context-menu-trigger:disabled{cursor:not-allowed;opacity:.6}:host .assistant-context-menu-trigger:disabled:hover{background:var(--luzmo-ai-chat-context-menu-trigger-background,var(--ai-chat-context-menu-trigger-background));border-color:var(--luzmo-ai-chat-context-menu-trigger-border-color,var(--ai-chat-context-menu-trigger-border-color));color:var(--luzmo-ai-chat-context-menu-trigger-color,var(--ai-chat-context-menu-trigger-color))}:host .assistant-context-menu-item{width:100%;color:var(--luzmo-font-color);text-align:start;cursor:pointer;font-family:var(--luzmo-ai-chat-context-menu-item-font-family,var(--ai-chat-context-menu-item-font-family));background:0 0;border:0;padding:.5rem .75rem}:host .assistant-context-menu-item:hover{background:var(--luzmo-ai-chat-context-menu-item-hover-background,var(--ai-chat-context-menu-item-hover-background))}:host .assistant-context-menu-item:disabled{opacity:.4;cursor:not-allowed}:host .assistant-context-menu-item:disabled:hover{background:0 0}:host luzmo-ai-interaction-textarea{flex-grow:0;flex-shrink:0}:host .loading-message{color:var(--luzmo-font-color);align-items:center;gap:.5rem;display:flex}:host .loading-message svg{color:var(--luzmo-ai-chat-loading-message-color,var(--ai-chat-loading-message-color));font-size:var(--luzmo-ai-chat-loading-message-icon-font-size,var(--ai-chat-loading-message-icon-font-size));justify-content:center;align-items:center;display:flex}:host .loading-message svg.spin{animation:1s linear infinite spin}@keyframes spin{to{transform:rotate(360deg)}}@media (prefers-reduced-motion:reduce){:host .assistant-context-menu-trigger{transition:none}:host .loading-message svg.spin{animation:none}}:host{--ai-chat-background:var(--luzmo-background-color);--ai-chat-border-radius:0;--ai-chat-padding:0;--ai-chat-gap:var(--luzmo-spacing-5);--ai-chat-border:none;--ai-chat-box-shadow:none;--ai-chat-loading-message-color:var(--luzmo-primary);--ai-chat-loading-message-icon-font-size:var(--luzmo-icon-size-m);--ai-chat-error-message-color:var(--luzmo-danger,#dc3545);--ai-chat-cancelled-message-color:var(--luzmo-font-color-dimmed,var(--luzmo-font-color-extra-dimmed));--ai-chat-scrollbar-width:var(--luzmo-scrollbar-size);--ai-chat-scrollbar-track-background:var(--luzmo-scrollbar-track-background);--ai-chat-scrollbar-track-border-radius:var(--luzmo-scrollbar-track-border-radius);--ai-chat-scrollbar-thumb-background:var(--luzmo-scrollbar-thumb-background);--ai-chat-scrollbar-thumb-border-radius:var(--luzmo-scrollbar-thumb-border-radius);--ai-chat-scrollbar-thumb-hover-background:var(--luzmo-scrollbar-thumb-hover-background);--ai-chat-context-menu-trigger-size:var(--luzmo-component-height-xs);--ai-chat-context-menu-trigger-icon-size:var(--luzmo-icon-size-s);--ai-chat-context-menu-trigger-border-color:var(--luzmo-border-color);--ai-chat-context-menu-trigger-border-radius:.375rem;--ai-chat-context-menu-trigger-background:var(--luzmo-background-color,transparent);--ai-chat-context-menu-trigger-color:var(--luzmo-font-color,#5a5a5a);--ai-chat-context-menu-trigger-hover-background:var(--luzmo-background-color-hover,#4434ff14);--ai-chat-context-menu-trigger-hover-border-color:var(--luzmo-border-color-hover,var(--luzmo-border-color));--ai-chat-context-menu-trigger-hover-color:var(--luzmo-font-color,#5a5a5a);--ai-chat-context-menu-item-hover-background:var(--luzmo-background-color-hover,#4434ff14);--ai-chat-context-menu-item-font-family:var(--luzmo-font-family);--ai-chat-markdown-line-height:1.5;--ai-chat-markdown-spacing:var(--luzmo-spacing-3);--ai-chat-markdown-heading-spacing:var(--luzmo-spacing-4);--ai-chat-markdown-heading-font-weight:var(--luzmo-font-weight-bold);--ai-chat-markdown-list-indent:calc(var(--luzmo-spacing-5) + var(--luzmo-spacing-3));--ai-chat-markdown-link-color:var(--luzmo-primary);--ai-chat-markdown-code-font-family:var(--luzmo-font-family-mono,ui-monospace, monospace);--ai-chat-markdown-code-font-size:.875em;--ai-chat-markdown-code-background:var(--luzmo-background-color-highlight);--ai-chat-markdown-code-border-radius:var(--luzmo-border-radius-s);--ai-chat-markdown-border-color:var(--luzmo-border-color);--ai-chat-markdown-table-header-background:var(--luzmo-background-color-highlight);--ai-chat-assistant-message-actions-gap:var(--luzmo-spacing-2);--ai-chat-assistant-message-actions-margin-top:var(--luzmo-spacing-3);--ai-chat-assistant-message-actions-color:var(--luzmo-font-color-extra-dimmed);--ai-chat-assistant-message-actions-font-style:italic;--ai-chat-assistant-message-font-family:var(--luzmo-font-family);--ai-chat-assistant-message-font-size:var(--luzmo-font-size-m);--ai-chat-assistant-message-line-height:var(--ai-chat-markdown-line-height);--ai-chat-user-message-attachment-size:64px}:host([size=s]){--ai-chat-gap:var(--luzmo-spacing-4);--ai-chat-loading-message-icon-font-size:var(--luzmo-icon-size-s);--ai-chat-context-menu-trigger-icon-size:var(--luzmo-icon-size-xs);--ai-chat-assistant-message-font-size:var(--luzmo-font-size-s)}:host([size=l]){--ai-chat-gap:calc(var(--luzmo-spacing-5) + var(--luzmo-spacing-2));--ai-chat-loading-message-icon-font-size:var(--luzmo-icon-size-l);--ai-chat-context-menu-trigger-size:var(--luzmo-component-height-s);--ai-chat-context-menu-trigger-icon-size:var(--luzmo-icon-size-m);--ai-chat-assistant-message-font-size:var(--luzmo-font-size-l)}:host([size=xl]){--ai-chat-gap:calc(var(--luzmo-spacing-5) + var(--luzmo-spacing-3));--ai-chat-loading-message-icon-font-size:var(--luzmo-icon-size-xl);--ai-chat-context-menu-trigger-size:var(--luzmo-component-height);--ai-chat-context-menu-trigger-icon-size:var(--luzmo-icon-size-l);--ai-chat-assistant-message-font-size:var(--luzmo-font-size-xl)}";
2329
- //#endregion
2330
- //#region src/components/ai-chat/helpers/agent-config.ts
2331
- function Nn(e, t) {
2332
- if (e.agentConfig) {
2333
- let n = e.agentConfig, r = t ?? Nn({
2334
- ...e,
2335
- agentConfig: void 0
2336
- });
2337
- return n.context === void 0 && n.type === r.type ? {
2338
- ...r,
2339
- ...n,
2340
- context: r.context
2341
- } : n.context === void 0 ? {
2342
- ...n,
2343
- context: null
2344
- } : n;
2345
- }
2346
- switch (e.agent ?? "item") {
2347
- case "item":
2348
- default: return {
2349
- type: "item",
2350
- context: {
2351
- chart: e.chart,
2352
- task: e.task
2353
- }
2354
- };
2355
- case "dashboard": return {
2356
- type: "dashboard",
2357
- context: {
2358
- dashboard: e.dashboard,
2359
- currentScreenMode: e.currentScreenMode
2360
- }
2361
- };
2362
- case "custom-item": return {
2363
- type: "custom-item",
2364
- context: { customItem: e.customItem }
2365
- };
2366
- case "analyst": return { type: "analyst" };
2367
- }
2368
- }
2369
- function Pn(e) {
2370
- return {
2371
- chart: null,
2372
- dashboard: null,
2373
- customItem: null,
2374
- currentScreenMode: void 0,
2375
- task: void 0,
2376
- ...e.context
2377
- };
2378
- }
2379
- //#endregion
2380
- //#region src/components/ai-chat/empty-state/ai-chat-empty-state.module.scss?inline
2381
- var Fn = ":host{box-sizing:border-box;width:100%;min-height:0;padding-block:var(--luzmo-ai-chat-empty-state-padding-block,var(--ai-chat-empty-state-padding-block));padding-inline:var(--luzmo-ai-chat-empty-state-padding-inline,var(--ai-chat-empty-state-padding-inline));flex:1;justify-content:center;align-items:center;display:flex}.empty-state{justify-content:center;align-items:center;gap:var(--luzmo-ai-chat-empty-state-header-actions-gap,var(--ai-chat-empty-state-header-actions-gap));width:100%;max-width:var(--luzmo-ai-chat-empty-state-max-width,var(--ai-chat-empty-state-max-width));text-align:center;flex-direction:column;display:flex}.header{flex-direction:column;align-items:center;width:100%;display:flex}.actions{align-items:center;gap:var(--luzmo-ai-chat-empty-state-actions-gap,var(--ai-chat-empty-state-actions-gap));flex-direction:column;width:100%;display:flex}.title{font-family:var(--luzmo-font-family);font-size:var(--luzmo-ai-chat-empty-state-title-font-size,var(--ai-chat-empty-state-title-font-size));font-weight:var(--luzmo-ai-chat-empty-state-title-font-weight,var(--ai-chat-empty-state-title-font-weight));line-height:var(--luzmo-ai-chat-empty-state-title-line-height,var(--ai-chat-empty-state-title-line-height));color:var(--luzmo-ai-chat-empty-state-title-color,var(--ai-chat-empty-state-title-color));text-wrap:balance;margin:0}.subtitle{font-family:var(--luzmo-font-family);font-size:var(--luzmo-ai-chat-empty-state-subtitle-font-size,var(--ai-chat-empty-state-subtitle-font-size));font-weight:var(--luzmo-ai-chat-empty-state-subtitle-font-weight,var(--ai-chat-empty-state-subtitle-font-weight));line-height:var(--luzmo-ai-chat-empty-state-subtitle-line-height,var(--ai-chat-empty-state-subtitle-line-height));color:var(--luzmo-ai-chat-empty-state-subtitle-color,var(--ai-chat-empty-state-subtitle-color));margin:0}.suggestions{justify-content:center;align-items:center;gap:var(--luzmo-ai-chat-empty-state-suggestions-gap,var(--ai-chat-empty-state-suggestions-gap));flex-wrap:wrap;width:100%;display:flex}luzmo-action-button{max-width:100%}:host{--ai-chat-empty-state-header-actions-gap:1.5rem;--ai-chat-empty-state-actions-gap:var(--luzmo-spacing-4);--ai-chat-empty-state-suggestions-gap:var(--luzmo-spacing-3);--ai-chat-empty-state-max-width:22.5rem;--ai-chat-empty-state-padding-block:2rem;--ai-chat-empty-state-padding-inline:var(--luzmo-spacing-5);--ai-chat-empty-state-title-font-size:var(--luzmo-font-size-l);--ai-chat-empty-state-title-font-weight:var(--luzmo-font-weight);--ai-chat-empty-state-title-line-height:1.4;--ai-chat-empty-state-title-color:var(--luzmo-font-color-hard);--ai-chat-empty-state-subtitle-font-size:var(--luzmo-font-size-s);--ai-chat-empty-state-subtitle-font-weight:var(--luzmo-font-weight);--ai-chat-empty-state-subtitle-line-height:var(--luzmo-line-height);--ai-chat-empty-state-subtitle-color:var(--luzmo-font-color-dimmed,var(--luzmo-font-color-extra-dimmed))}:host([size=s]){--ai-chat-empty-state-title-font-size:var(--luzmo-font-size-m)}:host([size=l]){--ai-chat-empty-state-title-font-size:var(--luzmo-font-size-xl);--ai-chat-empty-state-subtitle-font-size:var(--luzmo-font-size-m)}:host([size=xl]){--ai-chat-empty-state-title-font-size:var(--luzmo-font-size-xxl);--ai-chat-empty-state-subtitle-font-size:var(--luzmo-font-size-l)}", In, Z = class extends a(i, { validSizes: [
2382
- "s",
2383
- "m",
2384
- "l",
2385
- "xl"
2386
- ] }) {
2387
- constructor(...e) {
2388
- super(...e), this.title = c("What can I help you with?", { desc: "Title for the AI chat empty state" }), this.subtitle = "", this.suggestions = [], this.disabled = !1;
2389
- }
2390
- _handleSuggestionActivate(e) {
2391
- if (this.disabled) return;
2392
- let t = e.prompt ?? e.label;
2393
- this.dispatchEvent(new CustomEvent("luzmo-suggestion-selected", {
2394
- detail: {
2395
- label: e.label,
2396
- prompt: t,
2397
- selectedDatasets: e.selectedDatasets
2398
- },
2399
- bubbles: !0,
2400
- composed: !0
2401
- }));
2402
- }
2403
- render() {
2404
- let e = this.suggestions.length > 0;
2405
- return f`
2406
- <section class="empty-state" aria-labelledby="ai-chat-empty-state-title">
2407
- <header class="header">
2408
- <h2 id="ai-chat-empty-state-title" class="title">${this.title}</h2>
2409
- </header>
2410
-
2411
- ${e ? f`
2412
- <div class="actions">
2413
- ${this.subtitle ? f`<p class="subtitle">${this.subtitle}</p>` : p}
2414
- <div
2415
- class="suggestions"
2416
- role="group"
2417
- aria-label=${c("Prompt suggestions", { desc: "Accessible label for the AI chat empty state suggestion list" })}
2418
- >
2419
- ${this.suggestions.map((e) => f`
2420
- <luzmo-action-button
2421
- variant="accent"
2422
- .size=${this.size}
2423
- ?disabled=${this.disabled}
2424
- @click=${() => this._handleSuggestionActivate(e)}
2425
- >
2426
- ${e.label}
2427
- </luzmo-action-button>
2428
- `)}
2429
- </div>
2430
- </div>
2431
- ` : p}
2432
- </section>
2433
- `;
2434
- }
2435
- };
2436
- //#endregion
2437
- //#region src/components/ai-chat/empty-state/index.ts
2438
- In = Z, In.styles = m(Fn), In.tagName = "luzmo-ai-chat-empty-state", o([h({ type: String })], Z.prototype, "title", void 0), o([h({ type: String })], Z.prototype, "subtitle", void 0), o([h({ type: Array })], Z.prototype, "suggestions", void 0), o([h({
2439
- type: Boolean,
2440
- reflect: !0
2441
- })], Z.prototype, "disabled", void 0), customElements.get("luzmo-ai-chat-empty-state") || customElements.define("luzmo-ai-chat-empty-state", Z);
2442
- //#endregion
2443
- //#region src/components/ai-chat/helpers/elicitation-template.ts
2444
- var Ln = "answer", Rn = (e) => e.stopPropagation();
2445
- function zn(e) {
2446
- let t = e.content?.[Ln];
2447
- return typeof t == "string" ? t : void 0;
2448
- }
2449
- async function Bn(e) {
2450
- e.stopPropagation();
2451
- let t = e.currentTarget;
2452
- await t.updateComplete, t.submit();
2453
- }
2454
- function Vn({ message: e, state: t, size: n, onSubmit: r }) {
2455
- let i = e.elicitation;
2456
- if (!i) return p;
2457
- let a = [{
2458
- id: Ln,
2459
- type: "single",
2460
- title: i.question,
2461
- required: !0,
2462
- options: i.options.map((e) => ({
2463
- value: e,
2464
- label: e
2465
- }))
2466
- }];
2467
- return ne(`${e.id}:${t}`, f`
2468
- <luzmo-question-box
2469
- .size=${n}
2470
- .questions=${a}
2471
- .value=${te([i.answer], () => i.answer ? { [Ln]: i.answer } : {})}
2472
- .labels=${{
2473
- submit: c("Submit", { desc: "Button that sends the chosen answer to an AI agent question" }),
2474
- answerTitle: c("Answer", { desc: "Heading above the answer chosen for an AI agent question" }),
2475
- change: c("Change", { desc: "Button that goes back to pick another answer for an AI agent question" })
2476
- }}
2477
- ?readonly=${t === "answered"}
2478
- ?disabled=${t === "closed"}
2479
- hide-close
2480
- hide-skip
2481
- @luzmo-submit=${r}
2482
- @input=${Rn}
2483
- @change=${Bn}
2484
- @luzmo-cancel=${Rn}
2485
- ></luzmo-question-box>
2486
- `);
2487
- }
2488
- //#endregion
2489
- //#region src/components/ai-chat/ai-chat-request.ts
2490
- function Hn(e, t) {
2491
- return `${e.replace(/\/+$/, "")}/${t.replace(/^\/+|\/+$/g, "")}/aiprompt`;
2492
- }
2493
- function Un(e) {
2494
- return e.type === "placeholder" ? null : {
2495
- ...e,
2496
- version: e.version || "",
2497
- title: e.title || e.options?.title,
2498
- filters: e.filterGroups || [],
2499
- aichartId: e.aichartId || ""
2500
- };
2501
- }
2502
- function Wn(e, t, n = []) {
2503
- return [
2504
- {
2505
- type: "text",
2506
- text: e
2507
- },
2508
- ...t.map((e) => ({
2509
- type: "dataset",
2510
- id: e
2511
- })),
2512
- ...n.map((e) => ({
2513
- type: "image",
2514
- url: e
2515
- }))
2516
- ];
2517
- }
2518
- function Gn(e) {
2519
- return {
2520
- stream: e.stream ?? !0,
2521
- response_mode: "mixed",
2522
- ...e.conversationId ? { conversation_id: e.conversationId } : {},
2523
- ...e.localeId ? { locale_id: e.localeId } : {}
2524
- };
2525
- }
2526
- function Kn(e, t, n) {
2527
- return {
2528
- agent: e,
2529
- task: t,
2530
- ...Gn(n)
2531
- };
2532
- }
2533
- function qn(e) {
2534
- let t = Wn(e.prompt, e.datasetIds, e.attachmentUrls), n = e.chart ? Un(e.chart) : null;
2535
- return n && t.push({
2536
- type: "item",
2537
- value: n
2538
- }), {
2539
- ...Kn("item", e.task ?? "generate", e),
2540
- input: t
2541
- };
2542
- }
2543
- function Jn(e) {
2544
- let t = Wn(e.prompt, e.datasetIds, e.attachmentUrls);
2545
- return e.dashboard && t.push({
2546
- type: "dashboard",
2547
- value: e.dashboard,
2548
- ...e.currentScreenMode ? { current_screen_mode: e.currentScreenMode } : {}
2549
- }), {
2550
- ...Kn("dashboard", "generate", e),
2551
- timezone_id: e.timezoneId ?? "UTC",
2552
- input: t
2553
- };
2554
- }
2555
- function Yn(e) {
2556
- return {
2557
- ...Kn("analyst", "generate", e),
2558
- input: Wn(e.prompt, e.datasetIds, e.attachmentUrls)
2559
- };
2560
- }
2561
- function Xn(e) {
2562
- let t = Wn(e.prompt, [], e.attachmentUrls);
2563
- return e.customItem && t.push({
2564
- type: "custom-item",
2565
- value: e.customItem
2566
- }), {
2567
- ...Kn("custom-item", "generate", e),
2568
- text_format: "markdown",
2569
- ...e.internal ? { internal: !0 } : {},
2570
- input: t
2571
- };
2572
- }
2573
- function Zn(e, t) {
2574
- let n = Wn(t.prompt, t.datasetIds, t.attachmentUrls), r = t.chart ? Un(t.chart) : null;
2575
- return r && n.push({
2576
- type: "item",
2577
- value: r
2578
- }), t.dashboard && n.push({
2579
- type: "dashboard",
2580
- value: t.dashboard,
2581
- ...t.currentScreenMode ? { current_screen_mode: t.currentScreenMode } : {}
2582
- }), {
2583
- agent_id: e,
2584
- ...Gn(t),
2585
- input: n
2586
- };
2587
- }
2588
- function Qn(e, t) {
2589
- if (t.agentId) return Zn(t.agentId, t);
2590
- switch (e) {
2591
- case "dashboard": return Jn(t);
2592
- case "analyst": return Yn(t);
2593
- case "custom-item": return Xn(t);
2594
- default: return qn(t);
2595
- }
2596
- }
2597
- function $n(e, n) {
2598
- let { authKey: r, authToken: i, apiVersion: a = "0.1.0" } = n;
2599
- return n.attachmentUrls?.length && t(n.attachmentUrls), {
2600
- key: r,
2601
- token: i,
2602
- action: "create",
2603
- version: a,
2604
- properties: Qn(e, n)
2605
- };
2606
- }
2607
- function er(e, t, n, r = "0.1.0", i = null) {
2608
- return {
2609
- key: t,
2610
- token: n,
2611
- action: "delete",
2612
- version: r,
2613
- properties: {
2614
- agent: "item",
2615
- restore_to_message_id: e,
2616
- ...i ? { conversation_id: i } : {}
2617
- }
2618
- };
2619
- }
2620
- //#endregion
2621
- //#region src/components/ai-chat/stream/transport.ts
2622
- async function tr(e) {
2623
- let t = await fetch(e.url, {
2624
- method: "POST",
2625
- headers: { "Content-Type": "application/json" },
2626
- mode: "cors",
2627
- body: JSON.stringify(e.body),
2628
- signal: e.signal
2629
- });
2630
- if (!t.ok) {
2631
- let e = await t.json().catch(() => null);
2632
- throw Error(e?.message || `API request failed with status ${t.status}`);
2633
- }
2634
- if (!t.body) throw Error("Response body is not readable");
2635
- return {
2636
- body: t.body,
2637
- conversationId: t.headers.get("x-conversation-id")
2638
- };
2639
- }
2640
- function nr(e) {
2641
- let t = e.trim();
2642
- if (!t || t.startsWith(":") || t.startsWith("event:") || t.startsWith("id:")) return null;
2643
- let n = t;
2644
- return n.startsWith("data:") && (n = n.slice(5).trimStart()), !n || n === "[DONE]" ? null : JSON.parse(n);
2645
- }
2646
- function rr(e, t) {
2647
- try {
2648
- let n = nr(e);
2649
- n && t(n);
2650
- } catch {
2651
- console.error("Failed to parse stream line");
2652
- }
2653
- }
2654
- async function ir(e, t) {
2655
- let n = e.getReader(), r = new TextDecoder(), i = "";
2656
- try {
2657
- for (;;) {
2658
- let { done: e, value: a } = await n.read();
2659
- if (e) break;
2660
- i += r.decode(a, { stream: !0 });
2661
- let o = i.split(/\r?\n/);
2662
- i = o.pop() ?? "";
2663
- for (let e of o) rr(e, t);
2664
- }
2665
- i += r.decode();
2666
- let e = i.trim();
2667
- e && rr(e, t);
2668
- } finally {
2669
- n.releaseLock();
2670
- }
2671
- }
2672
- //#endregion
2673
- //#region src/components/ai-chat/stream/progress.ts
2674
- function ar() {
2675
- return {
2676
- id: "root",
2677
- step: "root",
2678
- status: "pending",
2679
- children: [{
2680
- id: "client-init",
2681
- step: "iqInit",
2682
- status: "inProgress",
2683
- description: c("Thinking", { desc: "Label shown in the AI chat progress tree while the assistant starts processing a prompt" })
2684
- }]
2685
- };
2686
- }
2687
- function or(e) {
2688
- let t = e.progress;
2689
- return typeof t != "object" || !t ? !1 : "id" in t && "step" in t && "status" in t;
2690
- }
2691
- //#endregion
2692
- //#region src/components/ai-chat/stream/chunk-extractors.ts
2693
- function sr(e) {
2694
- if (!e || typeof e != "object") return "";
2695
- let t = e.assistant_message;
2696
- if (!t || typeof t != "object") return "";
2697
- if (typeof t.message == "string") return t.message;
2698
- if (typeof t.text == "string") return t.text;
2699
- if (typeof t.summary == "string") return t.summary;
2700
- let n = t.content;
2701
- return typeof n == "string" ? n : n && typeof n == "object" && typeof n.text == "string" ? n.text : "";
2702
- }
2703
- function cr(e) {
2704
- return e.type === "text_delta" && typeof e.delta == "string" ? e.delta : typeof e.text_delta == "string" ? e.text_delta : typeof e.chunk == "string" ? e.chunk : typeof e.message == "string" ? e.message : typeof e.summary == "string" ? e.summary : "";
2705
- }
2706
- function lr(e) {
2707
- return sr(e.result);
2708
- }
2709
- function ur(e) {
2710
- return !!e.done || e.type === "finish" || e.type === "done" || "question" in e;
2711
- }
2712
- function dr(e, t) {
2713
- let n = typeof e.conversation_id == "string" && e.conversation_id || typeof e.conversationId == "string" && e.conversationId;
2714
- n && t.callbacks.onConversationIdChange(n);
2715
- }
2716
- function fr(e) {
2717
- for (let t of e) if (t && typeof t == "object" && t.type === "item") {
2718
- let e = t.value;
2719
- if (e && typeof e == "object") return e;
2720
- }
2721
- return null;
2722
- }
2723
- function pr(e) {
2724
- let t = e.chart ?? e.generatedChart;
2725
- if (t && typeof t == "object") return t;
2726
- let n = e.aiMessageAssets ?? e.ai_message_assets;
2727
- if (Array.isArray(n)) {
2728
- let e = fr(n);
2729
- if (e) return e;
2730
- }
2731
- let r = e.result;
2732
- if (r && typeof r == "object") {
2733
- let e = r.assistant_message, t = e?.aiMessageAssets ?? e?.ai_message_assets;
2734
- if (Array.isArray(t)) return fr(t);
2735
- }
2736
- return null;
2737
- }
2738
- function mr(e) {
2739
- for (let t of e) if (t && typeof t == "object" && t.type === "dashboard") {
2740
- let e = t.value;
2741
- if (e && typeof e == "object" && Array.isArray(e.views)) return e;
2742
- }
2743
- return null;
2744
- }
2745
- function hr(e) {
2746
- for (let t of e) if (t && typeof t == "object" && t.type === "dashboard") {
2747
- let e = t.name;
2748
- if (e && typeof e == "object") return e;
2749
- }
2750
- }
2751
- function gr(...e) {
2752
- return e.find(Array.isArray);
2753
- }
2754
- function _r(e) {
2755
- if (e.views && Array.isArray(e.views)) return e;
2756
- let t = e.aiMessageAssets ?? e.ai_message_assets;
2757
- if (Array.isArray(t)) return mr(t);
2758
- let n = e.result;
2759
- if (n && typeof n == "object") {
2760
- let e = n.assistant_message, t = e?.aiMessageAssets ?? e?.ai_message_assets;
2761
- if (Array.isArray(t)) return mr(t);
2762
- }
2763
- return null;
2764
- }
2765
- function vr(e) {
2766
- let t = e.aiMessageAssets ?? e.ai_message_assets, n = e.result?.assistant_message, r = gr(t, n?.aiMessageAssets ?? n?.ai_message_assets);
2767
- return r ? hr(r) : void 0;
2768
- }
2769
- function yr(e) {
2770
- let t = e.result?.assistant_message;
2771
- for (let n of [e.aiMessageAssets ?? e.ai_message_assets, t?.aiMessageAssets ?? t?.ai_message_assets]) if (Array.isArray(n)) {
2772
- for (let e of n) if (e && typeof e == "object" && e.type === "custom-item" && e.value && typeof e.value == "object" && !Array.isArray(e.value)) return e.value;
2773
- }
2774
- return null;
2775
- }
2776
- //#endregion
2777
- //#region src/components/ai-chat/stream/stream-processor.ts
2778
- var br = /* @__PURE__ */ new Set([
2779
- "conversation-id",
2780
- "conversation_id",
2781
- "keepalive",
2782
- "ping",
2783
- "finish",
2784
- "done"
2785
- ]);
2786
- function xr(e, t, n) {
2787
- return {
2788
- agent: n.agent,
2789
- conversationId: t.callbacks.getConversationId(),
2790
- ...typeof e.messageId == "string" ? { messageId: e.messageId } : {},
2791
- raw: e
2792
- };
2793
- }
2794
- function Q(e, t, n, r, i) {
2795
- let a = {
2796
- ...xr(n, e, t),
2797
- recognized: !0,
2798
- type: r,
2799
- data: i
2800
- };
2801
- e.callbacks.onStep(a);
2802
- }
2803
- function Sr(e, t, n, r, i) {
2804
- let a = {
2805
- ...xr(n, e, t),
2806
- recognized: !1,
2807
- type: r,
2808
- data: i
2809
- };
2810
- e.callbacks.onStep(a);
2811
- }
2812
- function Cr(e) {
2813
- e.state.progressCollapsed || (e.state.progressCollapsed = !0, e.callbacks.onProgressCollapsed(!0));
2814
- }
2815
- function wr(e, t) {
2816
- Cr(e), e.aiMessage.message = (e.aiMessage.message || "") + t, e.callbacks.onMessageUpdate(e.aiMessage);
2817
- }
2818
- function Tr(e) {
2819
- if (!e) return null;
2820
- let t = e.descriptionMetadata?.decision;
2821
- if (t === "create" || t === "edit" || t === "question") return t;
2822
- for (let t of e.children ?? []) {
2823
- let e = Tr(t);
2824
- if (e) return e;
2825
- }
2826
- return null;
2827
- }
2828
- function Er(e, t, n) {
2829
- if (!or(e)) return !1;
2830
- let r = e.progress;
2831
- if (t.callbacks.onProgress(r), Q(t, n, e, "progress", r), t.state.decision === null) {
2832
- let i = Tr(r);
2833
- i && (t.state.decision = i, Q(t, n, e, "decision", { decision: i }));
2834
- }
2835
- return !0;
2836
- }
2837
- function Dr(e) {
2838
- return !!e.error || e.type === "error" || typeof e.error_text == "string";
2839
- }
2840
- function Or(e) {
2841
- return typeof e.error_text == "string" && e.error_text ? e.error_text : typeof e.error == "string" && e.error ? e.error : c("Something went wrong. Please try again.", { desc: "Generic error message shown in ai chat when the API request fails" });
2842
- }
2843
- function kr(e, t, n) {
2844
- if (!Dr(e)) return !1;
2845
- let r = Or(e);
2846
- return t.aiMessage.message = r, t.aiMessage.isError = !0, delete t.aiMessage.elicitation, t.callbacks.onMessageUpdate(t.aiMessage), $r(e, t, n, e.error ?? r), !0;
2847
- }
2848
- function Ar(e) {
2849
- return typeof e.question == "string" && e.question ? e.question : typeof e.text == "string" && e.text ? e.text : "";
2850
- }
2851
- function jr(e, t, n) {
2852
- if (e.type !== "interrupt") return !1;
2853
- let r = Ar(e);
2854
- return r && (t.state.interruptQuestion = r, wr(t, r), Q(t, n, e, "interrupt", { question: r })), $r(e, t, n), !0;
2855
- }
2856
- function Mr(e) {
2857
- let t = e.elicitation;
2858
- if (!t || typeof t != "object") return null;
2859
- let { question: n, options: r } = t, i = typeof n == "string" ? n.trim() : "", a = Array.isArray(r) ? [...new Set(r.filter((e) => typeof e == "string").map((e) => e.trim()))].filter(Boolean) : [];
2860
- return i && a.length >= 2 ? {
2861
- question: i,
2862
- options: a
2863
- } : null;
2864
- }
2865
- function Nr(e, t, n) {
2866
- if (e.type !== "elicitation") return !1;
2867
- let r = Mr(e);
2868
- return r ? (Cr(t), t.aiMessage.elicitation = r, t.callbacks.onMessageUpdate(t.aiMessage), Q(t, n, e, "elicitation", {
2869
- question: r.question,
2870
- options: r.options
2871
- }), !0) : (Sr(t, n, e, "elicitation", e), !0);
2872
- }
2873
- function Pr(e) {
2874
- return typeof e.asset_id == "string" ? e.asset_id : typeof e.asset_type == "string" ? e.asset_type : "default";
2875
- }
2876
- function Fr(e) {
2877
- return typeof e.asset_type == "string" ? e.asset_type : "";
2878
- }
2879
- function Ir(e) {
2880
- return {
2881
- assetType: Fr(e),
2882
- snapshot: {}
2883
- };
2884
- }
2885
- function Lr(e, t) {
2886
- return {
2887
- ...e,
2888
- ...t
2889
- };
2890
- }
2891
- function Rr(e) {
2892
- let t = e.asset_delta ?? e.delta;
2893
- return t && typeof t == "object" ? t : null;
2894
- }
2895
- function zr(e, t) {
2896
- t.state.assets[Pr(e)] = Ir(e);
2897
- }
2898
- function Br(e, t) {
2899
- let n = Pr(e), r = t.state.assets[n] ?? Ir(e), i = Rr(e);
2900
- i && (r.snapshot = Lr(r.snapshot, i)), t.state.assets[n] = r;
2901
- }
2902
- function Vr(e, t) {
2903
- let n = e.asset ?? e.value ?? e.asset_delta ?? e.delta;
2904
- return n && typeof n == "object" ? Lr(t?.snapshot ?? {}, n) : t?.snapshot ?? {};
2905
- }
2906
- function Hr(e, t, n) {
2907
- let r = Pr(e), i = t.state.assets[r], a = i?.assetType || Fr(e), o = Vr(e, i);
2908
- delete t.state.assets[r], Kr(a, o, e, t, n);
2909
- }
2910
- function Ur(e, t, n) {
2911
- switch (e.type) {
2912
- case "asset_start": return zr(e, t), !0;
2913
- case "asset_delta": return Br(e, t), !0;
2914
- case "asset_end": return Hr(e, t, n), !0;
2915
- default: return !1;
2916
- }
2917
- }
2918
- function Wr(e, t, n, r) {
2919
- n.state.chartSnapshot = e, n.aiMessage.hasChart = !0, typeof t.messageId == "string" && (n.aiMessage.apiMessageId = t.messageId), n.callbacks.onMessageUpdate(n.aiMessage), Q(n, r, t, "chart", e);
2920
- }
2921
- function Gr(e, t, n, r) {
2922
- n.state.customItemSnapshot = e, Q(n, r, t, "custom-item", e);
2923
- }
2924
- function Kr(e, t, n, r, i) {
2925
- switch (e) {
2926
- case "dashboard-title": {
2927
- let e = t.name;
2928
- e && typeof e == "object" && (r.state.dashboardName = e, Q(r, i, n, "dashboard-title", { name: e }));
2929
- return;
2930
- }
2931
- case "dashboard-layout":
2932
- Q(r, i, n, "dashboard-layout", t);
2933
- return;
2934
- case "dashboard-item":
2935
- Q(r, i, n, "dashboard-item", {
2936
- slot: Number(t.slot),
2937
- chart: t.chart ?? t
2938
- });
2939
- return;
2940
- case "dashboard":
2941
- r.state.dashboardSnapshot = t;
2942
- return;
2943
- default: qr(e, t, n, r, i);
2944
- }
2945
- }
2946
- function qr(e, t, n, r, i) {
2947
- if (i.chartAssetType && e === i.chartAssetType) {
2948
- Wr(t, n, r, i);
2949
- return;
2950
- }
2951
- if (i.dashboardAssetType && e === i.dashboardAssetType) {
2952
- r.state.dashboardSnapshot = t;
2953
- return;
2954
- }
2955
- if (i.customItemAssetType && e === i.customItemAssetType) {
2956
- Gr(t, n, r, i);
2957
- return;
2958
- }
2959
- Sr(r, i, n, e || "asset", t);
2960
- }
2961
- function Jr(e, t, n) {
2962
- let r = !1;
2963
- if (n.dashboardAssetType) {
2964
- let n = _r(e);
2965
- if (n) {
2966
- t.state.dashboardSnapshot = n;
2967
- let i = vr(e);
2968
- i && (t.state.dashboardName = i), r = !0;
2969
- }
2970
- }
2971
- if (n.chartAssetType && !t.state.chartSnapshot) {
2972
- let i = pr(e);
2973
- i && (Wr(i, e, t, n), r = !0);
2974
- }
2975
- if (n.customItemAssetType && !t.state.customItemSnapshot) {
2976
- let i = yr(e);
2977
- i && (Gr(i, e, t, n), r = !0);
2978
- }
2979
- return r;
2980
- }
2981
- function Yr(e, t, n) {
2982
- return {
2983
- ...e,
2984
- generatedChart: t,
2985
- conversationId: n.callbacks.getConversationId()
2986
- };
2987
- }
2988
- function Xr(e, t, n) {
2989
- for (let r of Object.keys(t.state.assets)) {
2990
- let i = t.state.assets[r];
2991
- delete t.state.assets[r], !(n.chartAssetType && i.assetType === n.chartAssetType && t.state.chartSnapshot || n.dashboardAssetType && i.assetType === n.dashboardAssetType && t.state.dashboardSnapshot || n.customItemAssetType && i.assetType === n.customItemAssetType && t.state.customItemSnapshot) && Kr(i.assetType, i.snapshot, e, t, n);
2992
- }
2993
- }
2994
- function Zr(e, t) {
2995
- let n = lr(e);
2996
- !n || t.aiMessage.message === n || (t.aiMessage.message = n, t.callbacks.onMessageUpdate(t.aiMessage));
2997
- }
2998
- function Qr(e, t, n) {
2999
- let r = t.state.dashboardSnapshot ?? (n.dashboardAssetType ? _r(e) : null), i = t.state.chartSnapshot ?? (n.chartAssetType ? pr(e) : null);
3000
- return {
3001
- agent: n.agent,
3002
- conversationId: t.callbacks.getConversationId(),
3003
- message: t.aiMessage,
3004
- ...r ? { dashboard: r } : {},
3005
- ...i ? { chart: Yr(e, i, t) } : {},
3006
- ...t.state.customItemSnapshot ? { customItem: t.state.customItemSnapshot } : {},
3007
- ...t.state.dashboardName ? { name: t.state.dashboardName } : {},
3008
- raw: e
3009
- };
3010
- }
3011
- function $r(e, t, n, r) {
3012
- if (!t.state.completed) {
3013
- if (t.state.completed = !0, Xr(e, t, n), Cr(t), r !== void 0) {
3014
- t.callbacks.onComplete({
3015
- agent: n.agent,
3016
- conversationId: t.callbacks.getConversationId(),
3017
- message: t.aiMessage,
3018
- error: r,
3019
- raw: e
3020
- });
3021
- return;
3022
- }
3023
- Zr(e, t), t.callbacks.onComplete(Qr(e, t, n));
3024
- }
3025
- }
3026
- function ei(e) {
3027
- return typeof e.type == "string" && e.type ? e.type : typeof e.asset_type == "string" && e.asset_type ? e.asset_type : "";
3028
- }
3029
- function ti(e, t, n) {
3030
- let r = cr(e);
3031
- return r ? (t.state.accumulatedText += r, wr(t, r), Q(t, n, e, "text", {
3032
- delta: r,
3033
- text: t.state.accumulatedText
3034
- }), !0) : !1;
3035
- }
3036
- function ni(e, t, n, r, i) {
3037
- if (r || i) return;
3038
- let a = ei(e);
3039
- a && !br.has(a) && Sr(t, n, e, a, e);
3040
- }
3041
- function ri(e, t, n) {
3042
- if (dr(e, t), Er(e, t, n) || kr(e, t, n) || jr(e, t, n) || Nr(e, t, n) || Ur(e, t, n)) return;
3043
- let r = ti(e, t, n), i = Jr(e, t, n), a = r || i, o = ur(e);
3044
- ni(e, t, n, a, o), o && $r(e, t, n);
3045
- }
3046
- //#endregion
3047
- //#region src/components/ai-chat/stream/registry.ts
3048
- function ii(e) {
3049
- switch (e) {
3050
- case "dashboard": return {
3051
- agent: e,
3052
- dashboardAssetType: "dashboard"
3053
- };
3054
- case "item": return {
3055
- agent: e,
3056
- chartAssetType: "item"
3057
- };
3058
- case "custom-item": return {
3059
- agent: e,
3060
- customItemAssetType: "custom-item"
3061
- };
3062
- default: return { agent: e };
3063
- }
3064
- }
3065
- function ai(e) {
3066
- let t = ii(e);
3067
- return (e, n) => ri(e, n, t);
3068
- }
3069
- function oi() {
3070
- return {
3071
- progressCollapsed: !1,
3072
- accumulatedText: "",
3073
- decision: null,
3074
- assets: {},
3075
- dashboardSnapshot: null,
3076
- dashboardName: void 0,
3077
- chartSnapshot: null,
3078
- customItemSnapshot: null,
3079
- interruptQuestion: null,
3080
- completed: !1
3081
- };
3082
- }
3083
- //#endregion
3084
- //#region src/components/ai-chat/session/ai-chat-session.ts
3085
- function si() {
3086
- return `msg-${Date.now()}-${Math.random().toString(36).slice(2, 9)}`;
3087
- }
3088
- var ci = class {
3089
- constructor(e, t = {}) {
3090
- this._uiBridgeCallbacks = {}, this._subscribers = /* @__PURE__ */ new Set(), this._state = {
3091
- messages: [],
3092
- selectedDatasets: [],
3093
- isGenerating: !1,
3094
- progress: null,
3095
- progressCollapsed: !1,
3096
- conversationId: null,
3097
- inflightMessage: null
3098
- }, this._abortController = null, this._inflightMessage = null, this._receivedProgress = !1, this._config = {
3099
- apiUrl: "https://api.luzmo.com",
3100
- apiVersion: "0.1.0",
3101
- stream: !0,
3102
- ...e
3103
- }, e.agentConfig && (this._config.agentConfig = Nn(e)), this._hostCallbacks = t, this._state = {
3104
- ...this._state,
3105
- messages: e.messages ? [...e.messages] : [],
3106
- selectedDatasets: e.selectedDatasets ? [...e.selectedDatasets] : [],
3107
- conversationId: e.conversationId ?? null,
3108
- isGenerating: e.isGenerating ?? !1,
3109
- progress: e.progress ?? null,
3110
- progressCollapsed: e.progressCollapsed ?? !1
3111
- };
3112
- }
3113
- get state() {
3114
- return this._state;
3115
- }
3116
- get isGenerating() {
3117
- return this._state.isGenerating;
3118
- }
3119
- get agentConfig() {
3120
- return Nn(this._config);
3121
- }
3122
- subscribe(e) {
3123
- return this._subscribers.add(e), e(this._state), () => {
3124
- this._subscribers.delete(e);
3125
- };
3126
- }
3127
- setUiBridge(e) {
3128
- this._uiBridgeCallbacks = e;
3129
- }
3130
- updateConfig(e) {
3131
- let t = this.agentConfig, n = this._config.agentConfig !== void 0;
3132
- this._config = {
3133
- ...this._config,
3134
- ...e
3135
- }, e.agentConfig && (this._config.agentConfig = Nn(this._config, t));
3136
- let r = {};
3137
- if ("conversationId" in e) {
3138
- let t = e.conversationId ?? null;
3139
- t !== this._state.conversationId && (r.conversationId = t);
3140
- }
3141
- if ("selectedDatasets" in e && e.selectedDatasets) {
3142
- let t = [...e.selectedDatasets];
3143
- this._areSelectedDatasetsEqual(t, this._state.selectedDatasets) || (r.selectedDatasets = t);
3144
- }
3145
- if ("messages" in e && e.messages) {
3146
- let t = [...e.messages];
3147
- this._areChatMessagesEqual(t, this._state.messages) || (r.messages = t);
3148
- }
3149
- if ("isGenerating" in e && e.isGenerating !== this._state.isGenerating && (r.isGenerating = e.isGenerating), "progress" in e && (r.progress = e.progress ?? null), "progressCollapsed" in e && e.progressCollapsed !== this._state.progressCollapsed && (r.progressCollapsed = e.progressCollapsed), Object.keys(r).length > 0) this._patchState(r);
3150
- else if ("agentConfig" in e && (n || this._config.agentConfig !== void 0)) {
3151
- let e = this.agentConfig;
3152
- (e.type !== t.type || e.context !== t.context) && this._notifySubscribers();
3153
- }
3154
- }
3155
- setSelectedDatasets(e) {
3156
- this._patchState({ selectedDatasets: [...e] }), this._emit("onDatasetsChanged", this._state.selectedDatasets);
3157
- }
3158
- addDataset(e) {
3159
- this._state.selectedDatasets.some((t) => t.id === e.id) || (this._patchState({ selectedDatasets: [...this._state.selectedDatasets, e] }), this._emit("onDatasetsChanged", this._state.selectedDatasets));
3160
- }
3161
- removeDataset(e) {
3162
- let t = this._state.selectedDatasets.filter((t) => t.id !== e);
3163
- t.length !== this._state.selectedDatasets.length && (this._patchState({ selectedDatasets: t }), this._emit("onDatasetsChanged", this._state.selectedDatasets));
3164
- }
3165
- isDatasetRequirementMet(e) {
3166
- return !this._config.requireDataset || this._state.selectedDatasets.length > 0 || !!e;
3167
- }
3168
- getAiPromptUrl() {
3169
- return Hn(this._config.apiUrl ?? "https://api.luzmo.com", this._config.apiVersion ?? "0.1.0");
3170
- }
3171
- buildRequestBody(e, t, n = [], r = this._config.agentId, i = {}) {
3172
- return $n(this.agentConfig.type, {
3173
- prompt: e,
3174
- datasetIds: t,
3175
- authKey: this._config.authKey,
3176
- authToken: this._config.authToken,
3177
- conversationId: this._state.conversationId,
3178
- agentId: r,
3179
- chart: this._config.chart ?? null,
3180
- dashboard: this._config.dashboard ?? null,
3181
- customItem: this._config.customItem ?? null,
3182
- currentScreenMode: this._config.currentScreenMode,
3183
- localeId: this._config.localeId,
3184
- timezoneId: this._config.timezoneId,
3185
- task: this._config.task,
3186
- ...this._config.agentConfig ? Pn(this.agentConfig) : {},
3187
- modelPreference: this._config.modelPreference,
3188
- apiVersion: this._config.apiVersion,
3189
- stream: this._config.stream,
3190
- attachmentUrls: n,
3191
- internal: i.internal
3192
- });
3193
- }
3194
- buildPromptSubmittedDetail(e) {
3195
- let t = e.attachmentUrls ?? [];
3196
- return {
3197
- prompt: e.prompt,
3198
- selectedDatasets: e.selectedDatasets,
3199
- datasetIds: e.datasetIds,
3200
- agent: this.agentConfig.type,
3201
- request: this.buildRequestBody(e.prompt, e.datasetIds, t, e.agentId, { internal: e.internal }),
3202
- url: this.getAiPromptUrl(),
3203
- ...e.signal ? { signal: e.signal } : {},
3204
- ...e.attachments?.length ? { attachments: e.attachments } : {},
3205
- ...t.length ? { attachmentUrls: t } : {}
3206
- };
3207
- }
3208
- async _resolveAttachmentUrls(e, i) {
3209
- if (e.attachmentUrls?.length) return t(e.attachmentUrls), [...e.attachmentUrls];
3210
- let a = (e.attachments ?? []).map((e) => e.file).filter((e) => !!e);
3211
- if (a.length === 0) return [];
3212
- r(a);
3213
- let o = this._hostCallbacks.uploadAttachments ?? this._uiBridgeCallbacks.uploadAttachments;
3214
- if (typeof o == "function") return this._normalizeUploadedUrls(await o(a, { signal: i }), a.length);
3215
- let { authKey: s, authToken: c, apiUrl: l = "https://api.luzmo.com", apiVersion: u = "0.1.0" } = this._config;
3216
- if (!s || !c) {
3217
- if (this._hasCallback("onPromptSubmitted")) return [];
3218
- throw Error("Image attachments require authKey/authToken for built-in upload, or provide uploadAttachments / attachmentUrls.");
3219
- }
3220
- return this._normalizeUploadedUrls(await n({
3221
- files: a,
3222
- authKey: s,
3223
- authToken: c,
3224
- apiUrl: l,
3225
- apiVersion: u,
3226
- signal: i
3227
- }), a.length);
3228
- }
3229
- _normalizeUploadedUrls(e, n) {
3230
- let r = Array.isArray(e) ? e.filter((e) => typeof e == "string" && e.trim().length > 0) : [];
3231
- if (r.length !== n) throw Error(`Image upload returned ${r.length} URL(s) for ${n} file(s). Return one non-empty signed URL per file, in the same order.`);
3232
- return t(r), r;
3233
- }
3234
- async submit(e) {
3235
- await this._submit(e);
3236
- }
3237
- async _submit(e) {
3238
- let t = e.datasetIds ?? this._state.selectedDatasets.map((e) => e.id);
3239
- if (!this.isDatasetRequirementMet(e.agentId)) return !1;
3240
- this._abortInflight();
3241
- let n = new AbortController();
3242
- this._abortController = n;
3243
- let r;
3244
- try {
3245
- r = await this._resolveAttachmentUrls(e, n.signal);
3246
- } catch (e) {
3247
- if (this._abortController === n && (this._abortController = null), n.signal.aborted || e.name === "AbortError") return !1;
3248
- throw e;
3249
- }
3250
- if (n.signal.aborted || this._abortController !== n) return !1;
3251
- let i = {
3252
- id: e.aiMessageId ?? si(),
3253
- type: "ai",
3254
- message: ""
3255
- }, a = [...this._state.messages];
3256
- if (!e.skipUserMessage) {
3257
- let t = {
3258
- id: si(),
3259
- type: "user",
3260
- message: e.prompt,
3261
- ...r.length ? { attachmentUrls: r } : {}
3262
- };
3263
- a = [...a, t], this._emit("onMessageSent", t, [...this._state.selectedDatasets]);
3264
- }
3265
- a = [...a, i], this._inflightMessage = i, this._receivedProgress = !1, this._patchState({
3266
- messages: a,
3267
- isGenerating: !0,
3268
- progress: ar(),
3269
- progressCollapsed: !1,
3270
- inflightMessage: i
3271
- });
3272
- let o = t, s = [...this._state.selectedDatasets];
3273
- if (this._hasCallback("onPromptSubmitted")) {
3274
- let t = this.buildPromptSubmittedDetail({
3275
- prompt: e.prompt,
3276
- selectedDatasets: s,
3277
- datasetIds: o,
3278
- signal: n.signal,
3279
- attachments: e.attachments,
3280
- attachmentUrls: r,
3281
- agentId: e.agentId,
3282
- internal: e.internal
3283
- });
3284
- try {
3285
- await this._invokeCallback("onPromptSubmitted", t);
3286
- } catch (e) {
3287
- e.name === "AbortError" ? this.abort() : (this._handleSubmitError(e, i, t.agent), this._finalizeInflightMessage()), this._patchState({ isGenerating: !1 });
3288
- }
3289
- return !0;
3290
- }
3291
- let c = this.buildRequestBody(e.prompt, t, r, e.agentId, { internal: e.internal }), l = this.agentConfig.type, u = ai(l), d = {
3292
- aiMessage: i,
3293
- callbacks: this._createStreamCallbacks(),
3294
- state: oi()
3295
- }, f = this._config.fetchStreaming ?? tr, p = !1;
3296
- try {
3297
- let { body: e, conversationId: t } = await f({
3298
- url: this.getAiPromptUrl(),
3299
- body: c,
3300
- signal: n.signal
3301
- });
3302
- t && this._setConversationId(t), await ir(e, (e) => u(e, d)), p = !0;
3303
- } catch (e) {
3304
- e.name !== "AbortError" && (this._handleSubmitError(e, i, l), p = !0);
3305
- } finally {
3306
- this._abortController === n && (p ? this._finalizeInflightMessage() : this._discardInflightMessage(), this._patchState({ isGenerating: !1 }), this._abortController = null);
3307
- }
3308
- return !0;
3309
- }
3310
- async answerElicitation(e, t, n = {}) {
3311
- let r = this._state.messages.at(-1), i = r?.id === e ? r.elicitation : void 0;
3312
- if (this._state.isGenerating || !i || i.answer || !i.options.includes(t) || !this.isDatasetRequirementMet(n.agentId)) return !1;
3313
- let a = (t) => {
3314
- this._patchState({ messages: this._state.messages.map((n) => n.id === e ? {
3315
- ...n,
3316
- elicitation: {
3317
- ...i,
3318
- answer: t
3319
- }
3320
- } : n) });
3321
- };
3322
- a(t);
3323
- let o = !1;
3324
- try {
3325
- o = await this._submit({
3326
- ...n,
3327
- prompt: t
3328
- });
3329
- } finally {
3330
- o || a(void 0);
3331
- }
3332
- return o;
3333
- }
3334
- async restore(e) {
3335
- let t = this.agentConfig.type;
3336
- if (t !== "item") return {};
3337
- let n = er(e.restoreToMessageId, this._config.authKey, this._config.authToken, this._config.apiVersion, this._state.conversationId);
3338
- if (this._patchState({
3339
- isGenerating: !0,
3340
- progress: null,
3341
- progressCollapsed: !1
3342
- }), this._hasCallback("onRestoreRequested")) {
3343
- let t = {
3344
- apiMessageId: e.restoreToMessageId,
3345
- messageIndex: e.messageIndex,
3346
- request: n,
3347
- url: this.getAiPromptUrl()
3348
- };
3349
- try {
3350
- await this._invokeCallback("onRestoreRequested", t);
3351
- } finally {
3352
- this._patchState({ isGenerating: !1 });
3353
- }
3354
- return {};
3355
- }
3356
- try {
3357
- let r = await fetch(this.getAiPromptUrl(), {
3358
- method: "POST",
3359
- headers: { "Content-Type": "application/json" },
3360
- mode: "cors",
3361
- body: JSON.stringify(n)
3362
- });
3363
- if (!r.ok) {
3364
- let e = await r.json().catch(() => null);
3365
- throw Error(e?.message || `API request failed with status ${r.status}`);
3366
- }
3367
- let i = await r.json().catch(() => null), a = i?.generatedChart ?? (i ? pr(i) : null), o = {
3368
- ...typeof i?.message == "string" ? { message: i.message } : {},
3369
- ...a ? { chart: {
3370
- ...i,
3371
- generatedChart: a
3372
- } } : {}
3373
- }, s = e.messageIndex >= 0 && e.messageIndex < this._state.messages.length ? this._state.messages.slice(0, e.messageIndex + 1) : this._state.messages;
3374
- if (o.message && s[e.messageIndex]?.type === "ai" && (s[e.messageIndex] = {
3375
- ...s[e.messageIndex],
3376
- message: o.message
3377
- }), this._patchState({ messages: [...s] }), o.chart || o.message) {
3378
- let n = s[e.messageIndex], r = n?.type === "ai" ? n : {
3379
- id: si(),
3380
- type: "ai",
3381
- message: o.message ?? ""
3382
- };
3383
- this._emit("onComplete", {
3384
- agent: t,
3385
- conversationId: this._state.conversationId,
3386
- message: r,
3387
- ...o.chart ? { chart: o.chart } : {},
3388
- ...i ? { raw: i } : {}
3389
- });
3390
- }
3391
- return o;
3392
- } finally {
3393
- this._patchState({ isGenerating: !1 });
3394
- }
3395
- }
3396
- buildRestoreRequest(e) {
3397
- return er(e, this._config.authKey, this._config.authToken, this._config.apiVersion, this._state.conversationId);
3398
- }
3399
- abort(e = {}) {
3400
- this._abortController?.abort(), this._abortController = null, e.notify && this._inflightMessage ? this._markInflightCancelled(e.cancelledMessage) : this._discardInflightMessage(), this._patchState({
3401
- isGenerating: !1,
3402
- progress: null,
3403
- progressCollapsed: !1
3404
- }), e.notify && this._emit("onPromptStopped");
3405
- }
3406
- _abortInflight() {
3407
- this._abortController?.abort(), this._abortController = null, this._discardInflightMessage();
3408
- }
3409
- _createStreamCallbacks() {
3410
- return {
3411
- onConversationIdChange: (e) => this._setConversationId(e),
3412
- onProgress: (e) => {
3413
- this._receivedProgress = !0, this._patchState({ progress: e });
3414
- },
3415
- onProgressCollapsed: (e) => {
3416
- this._patchState({ progressCollapsed: e });
3417
- },
3418
- onMessageUpdate: (e) => {
3419
- this._inflightMessage = e, this._upsertMessage(e), this._patchState({ inflightMessage: { ...e } });
3420
- },
3421
- getConversationId: () => this._state.conversationId,
3422
- onStep: (e) => {
3423
- this._emit("onStep", e);
3424
- },
3425
- onComplete: (e) => {
3426
- this._emit("onComplete", e);
3427
- }
3428
- };
3429
- }
3430
- _setConversationId(e) {
3431
- this._config = {
3432
- ...this._config,
3433
- conversationId: e
3434
- }, this._patchState({ conversationId: e }), this._emit("onConversationIdChange", e);
3435
- }
3436
- _upsertMessage(e) {
3437
- let t = this._state.messages.findIndex((t) => t.id === e.id);
3438
- if (t === -1) {
3439
- this._patchState({ messages: [...this._state.messages, { ...e }] });
3440
- return;
3441
- }
3442
- let n = this._state.messages.map((n, r) => r === t ? { ...e } : n);
3443
- this._patchState({ messages: n });
3444
- }
3445
- _finalizeInflightMessage() {
3446
- this._inflightMessage && (this._state.progress && this._receivedProgress && (this._inflightMessage.progress = structuredClone(this._state.progress), this._upsertMessage(this._inflightMessage)), this._inflightMessage = null, this._receivedProgress = !1, this._patchState({
3447
- progress: null,
3448
- progressCollapsed: !1,
3449
- inflightMessage: null
3450
- }));
3451
- }
3452
- _removeInflightFromMessages() {
3453
- this._inflightMessage && this._patchState({ messages: this._state.messages.filter((e) => e.id !== this._inflightMessage.id) });
3454
- }
3455
- _markInflightCancelled(e) {
3456
- this._inflightMessage && (this._inflightMessage.message = e ?? c("Response cancelled.", { desc: "Placeholder shown in ai chat where the assistant reply would appear when the user stops an in-flight response" }), this._inflightMessage.isCancelled = !0, this._inflightMessage.hasChart = !1, delete this._inflightMessage.progress, delete this._inflightMessage.elicitation, this._upsertMessage(this._inflightMessage), this._inflightMessage = null, this._receivedProgress = !1, this._patchState({ inflightMessage: null }));
3457
- }
3458
- _discardInflightMessage() {
3459
- let e = !!(this._inflightMessage || this._state.inflightMessage);
3460
- this._removeInflightFromMessages(), this._inflightMessage = null, this._receivedProgress = !1, e && this._patchState({ inflightMessage: null });
3461
- }
3462
- _handleSubmitError(e, t, n) {
3463
- t.message = c("Something went wrong. Please try again.", { desc: "Generic error message shown in ai chat when the API request fails" }), t.isError = !0, delete t.progress, delete t.elicitation, this._inflightMessage = t, this._upsertMessage(t), this._patchState({
3464
- inflightMessage: { ...t },
3465
- progress: null,
3466
- progressCollapsed: !1
3467
- }), this._emit("onComplete", {
3468
- agent: n,
3469
- conversationId: this._state.conversationId,
3470
- message: t,
3471
- error: e
3472
- });
3473
- }
3474
- _hasCallback(e) {
3475
- return typeof this._hostCallbacks[e] == "function" || typeof this._uiBridgeCallbacks[e] == "function";
3476
- }
3477
- _emit(e, ...t) {
3478
- this._invokeCallback(e, ...t);
3479
- }
3480
- async _invokeCallback(e, ...t) {
3481
- let n = this._hostCallbacks[e], r = this._uiBridgeCallbacks[e];
3482
- typeof n == "function" && await n(...t), typeof r == "function" && await r(...t);
3483
- }
3484
- _patchState(e) {
3485
- this._state = {
3486
- ...this._state,
3487
- ...e
3488
- }, this._emit("onStateChange", this._state), this._notifySubscribers();
3489
- }
3490
- _notifySubscribers() {
3491
- for (let e of this._subscribers) e(this._state);
3492
- }
3493
- _areSelectedDatasetsEqual(e, t) {
3494
- return e.length === t.length && e.every((e, n) => e.id === t[n]?.id);
3495
- }
3496
- _areChatMessagesEqual(e, t) {
3497
- return e.length === t.length && e.every((e, n) => {
3498
- let r = t[n];
3499
- return e.id === r?.id && e.apiMessageId === r?.apiMessageId && e.type === r?.type && e.message === r?.message && e.isError === r?.isError && e.isCancelled === r?.isCancelled && e.hasChart === r?.hasChart && JSON.stringify(e.progress ?? null) === JSON.stringify(r?.progress ?? null) && JSON.stringify(e.actions ?? null) === JSON.stringify(r?.actions ?? null) && JSON.stringify(e.attachmentUrls ?? null) === JSON.stringify(r?.attachmentUrls ?? null) && JSON.stringify(e.elicitation ?? null) === JSON.stringify(r?.elicitation ?? null);
3500
- });
3501
- }
3502
- };
3503
- function li(e, t) {
3504
- return new ci(e, t);
3505
- }
3506
- //#endregion
3507
- //#region src/components/ai-chat/session/ai-chat-session-controller.ts
3508
- var ui = class {
3509
- constructor(e) {
3510
- this.options = e, this._session = null, this._ownsSession = !1, this._customItemFromProps = !1, this._seededFromProps = !1, this._unsubscribe = null;
3511
- }
3512
- get current() {
3513
- return this._session;
3514
- }
3515
- get state() {
3516
- if (this._session) return this._session.state;
3517
- let e = this.options.getSeed();
3518
- return {
3519
- messages: e.messages,
3520
- selectedDatasets: e.selectedDatasets,
3521
- isGenerating: !1,
3522
- progress: null,
3523
- progressCollapsed: !1,
3524
- conversationId: e.conversationId,
3525
- inflightMessage: null
3526
- };
3527
- }
3528
- get ownsCurrentSession() {
3529
- return this._ownsSession;
3530
- }
3531
- setSession(e) {
3532
- if (!e) {
3533
- this._clearSession();
3534
- return;
3535
- }
3536
- this._ownsSession && this._session !== e && this._session?.abort(), this._ownsSession = !1, this._session = e, this._mergeHostElementConfig(e), this._wire(e);
3537
- }
3538
- syncProperties(e) {
3539
- if (!e.has("chatSession")) {
3540
- if (this._createSessionIfMissing(), this._session) {
3541
- let t = this.options.getConfig();
3542
- if (Object.keys(t).some((t) => e.has(t)) && (this._ownsSession ? this._session.updateConfig(t) : this._mergeHostElementConfig(this._session)), e.has("selectedDatasets") && this._ownsSession) {
3543
- let e = this.options.getSeed().selectedDatasets, t = this._session.state.selectedDatasets;
3544
- (e.length !== t.length || e.some((e, n) => e.id !== t[n]?.id)) && this._session.updateConfig({ selectedDatasets: e });
3545
- }
3546
- }
3547
- (e.has("messages") || e.has("selectedDatasets")) && this._seedFromPropsOnce();
3548
- }
3549
- }
3550
- requireSession() {
3551
- return this._createSessionIfMissing(), this._ownsSession ? this._session.updateConfig(this.options.getConfig()) : this._session && this._mergeHostElementConfig(this._session), this._session;
3552
- }
3553
- _mergeHostElementConfig(e) {
3554
- let t = this.options.getConfig(), n = {
3555
- authKey: t.authKey,
3556
- authToken: t.authToken,
3557
- apiUrl: t.apiUrl,
3558
- apiVersion: t.apiVersion,
3559
- stream: t.stream,
3560
- localeId: t.localeId,
3561
- timezoneId: t.timezoneId,
3562
- modelPreference: t.modelPreference,
3563
- requireDataset: t.requireDataset,
3564
- agent: t.agent
3565
- };
3566
- t.agentConfig !== void 0 && (n.agentConfig = t.agentConfig), t.task !== void 0 && (n.task = t.task), t.chart != null && (n.chart = t.chart), t.dashboard != null && (n.dashboard = t.dashboard), t.customItem != null && (this._customItemFromProps = !0), this._customItemFromProps && (n.customItem = t.customItem ?? null), t.currentScreenMode != null && (n.currentScreenMode = t.currentScreenMode), t.conversationId != null && (n.conversationId = t.conversationId), e.updateConfig(n);
3567
- }
3568
- connect() {
3569
- this._session && this._wire(this._session);
3570
- }
3571
- teardown() {
3572
- this._unwire(), this._ownsSession &&= (this._session?.abort(), this._session = null, !1), this._seededFromProps = !1;
3573
- }
3574
- _createSessionIfMissing() {
3575
- if (this._session) return;
3576
- let e = this.options.getSeed();
3577
- this._session = li({
3578
- ...this.options.getConfig(),
3579
- messages: e.messages.length > 0 ? [...e.messages] : void 0,
3580
- selectedDatasets: e.selectedDatasets.length > 0 ? [...e.selectedDatasets] : void 0
3581
- }), this._ownsSession = !0, this._seededFromProps = e.messages.length > 0 || e.selectedDatasets.length > 0, this._wire(this._session);
3582
- }
3583
- _clearSession() {
3584
- this._unwire(), this._ownsSession && this._session?.abort(), this._session = null, this._ownsSession = !1;
3585
- }
3586
- _seedFromPropsOnce() {
3587
- if (!this._ownsSession || this._seededFromProps) return;
3588
- let e = this.requireSession(), t = this.options.getSeed(), n = {};
3589
- e.state.messages.length === 0 && t.messages.length > 0 && (n.messages = [...t.messages]), e.state.selectedDatasets.length === 0 && t.selectedDatasets.length > 0 && (n.selectedDatasets = [...t.selectedDatasets]), Object.keys(n).length > 0 && (e.updateConfig(n), this._seededFromProps = !0);
3590
- }
3591
- _wire(e) {
3592
- this._unwire(), e.setUiBridge(this.options.createDomBridge()), this._unsubscribe = e.subscribe(() => {
3593
- this.options.onRenderNeeded();
3594
- });
3595
- }
3596
- _unwire() {
3597
- this._unsubscribe?.(), this._unsubscribe = null;
3598
- }
3599
- }, di, $ = class t extends a(i, { validSizes: [
3600
- "s",
3601
- "m",
3602
- "l",
3603
- "xl"
3604
- ] }) {
3605
- constructor(...e) {
3606
- super(...e), this.messages = [], this.selectedDatasets = [], this.placeholder = "Describe your change", this.disabled = !1, this.stoppable = !1, this.showAssistantContextMenu = !1, this.authKey = "", this.authToken = "", this.apiUrl = "https://api.luzmo.com", this.appServer = "https://app.luzmo.com", this.includePublicDatasets = !1, this.hideDatasetButton = !1, this.hideDatasetIcons = !1, this.disableDatasetModification = !1, this.hideSelectedDatasets = !1, this.hideAgents = !1, this.disableColumnMentions = !1, this.requireDataset = !1, this.allowImages = !1, this.allowVoiceInput = !1, this.acceptedFileTypes = [], this.agent = "item", this.task = "generate", this.modelPreference = "performance", this.chatSession = null, this.conversationId = null, this.chart = null, this.dashboard = null, this.customItem = null, this.timezoneId = "UTC", this.apiVersion = "0.1.0", this.stream = !0, this.loadingMessage = null, this.cancelledMessage = null, this.initialPrompt = null, this.emptyStateTitle = "", this.emptyStateSubtitle = "", this.emptyStateSuggestions = [], this._textareaValue = "", this._assistantMessageActionsSlotHasContent = !1, this._pendingAssistantMessageAction = null, this._shouldFocusAssistantMessageActionConfirm = !1, this._lastProcessedInitialPrompt = null, this._session = new ui({
3607
- getConfig: () => this._buildSessionConfig(),
3608
- getSeed: () => ({
3609
- messages: this.messages,
3610
- selectedDatasets: Array.isArray(this.selectedDatasets) ? this.selectedDatasets : [],
3611
- conversationId: this.conversationId
3612
- }),
3613
- createDomBridge: () => this._createDomBridgeCallbacks(),
3614
- onRenderNeeded: () => {
3615
- this.requestUpdate(), this.updateComplete.then(() => this._scrollToBottom());
3616
- }
3617
- }), this._handleAssistantMessageActionsSlotChange = (e) => {
3618
- let t = e.target.assignedElements({ flatten: !0 }).length > 0;
3619
- this._setAssistantMessageActionsSlotHasContent(t);
3620
- }, this._handleAssistantMessageActionConfirmKeydown = (e) => {
3621
- e.key !== "Escape" || !this._pendingAssistantMessageAction || (e.preventDefault(), e.stopPropagation(), this._cancelAssistantMessageActionConfirm());
3622
- };
3623
- }
3624
- get flagOpendata() {
3625
- return this.includePublicDatasets;
3626
- }
3627
- set flagOpendata(e) {
3628
- this.includePublicDatasets = e;
3629
- }
3630
- get session() {
3631
- return this._session.current;
3632
- }
3633
- _getRenderState() {
3634
- return this._session.state;
3635
- }
3636
- _createDomBridgeCallbacks() {
3637
- return {
3638
- onMessageSent: (e, t) => {
3639
- this.dispatchEvent(new CustomEvent("luzmo-message-sent", {
3640
- detail: {
3641
- message: e,
3642
- selectedDatasets: t
3643
- },
3644
- bubbles: !0,
3645
- composed: !0
3646
- }));
3647
- },
3648
- onDatasetsChanged: (e) => {
3649
- this.dispatchEvent(new CustomEvent("luzmo-datasets-changed", {
3650
- detail: { selectedDatasets: e },
3651
- bubbles: !0,
3652
- composed: !0
3653
- }));
3654
- },
3655
- onConversationIdChange: (e) => this._emitConversationIdChanged(e),
3656
- onStep: (e) => {
3657
- this.dispatchEvent(new CustomEvent("luzmo-step", {
3658
- detail: e,
3659
- bubbles: !0,
3660
- composed: !0
3661
- }));
3662
- },
3663
- onComplete: (e) => {
3664
- this.dispatchEvent(new CustomEvent("luzmo-complete", {
3665
- detail: e,
3666
- bubbles: !0,
3667
- composed: !0
3668
- }));
3669
- },
3670
- onPromptStopped: () => {
3671
- this.dispatchEvent(new CustomEvent("luzmo-stop", {
3672
- bubbles: !0,
3673
- composed: !0
3674
- }));
3675
- },
3676
- ...typeof this.uploadAttachments == "function" ? { uploadAttachments: (e, t) => this.uploadAttachments(e, t) } : {}
3677
- };
3678
- }
3679
- get _pickedAgentId() {
3680
- if (!this.hideAgents) return this.shadowRoot?.querySelector("luzmo-ai-interaction-textarea")?.selectedAgent?.id;
3681
- }
3682
- get _oneSizeSmaller() {
3683
- return {
3684
- s: "xs",
3685
- m: "s",
3686
- l: "m",
3687
- xl: "l"
3688
- }[this.size] ?? "s";
3689
- }
3690
- get _resolvedAcceptedFileTypes() {
3691
- return this.acceptedFileTypes.length > 0 ? this.acceptedFileTypes : this.allowImages ? [...e] : [];
3692
- }
3693
- _buildSessionConfig() {
3694
- return {
3695
- agent: this.agent,
3696
- agentConfig: this.agentConfig,
3697
- agentId: this.agentId,
3698
- authKey: this.authKey,
3699
- authToken: this.authToken,
3700
- apiUrl: this.apiUrl,
3701
- apiVersion: this.apiVersion,
3702
- stream: this.stream,
3703
- conversationId: this.conversationId,
3704
- chart: this.chart,
3705
- dashboard: this.dashboard,
3706
- customItem: this.customItem,
3707
- currentScreenMode: this.currentScreenMode,
3708
- localeId: this.localeId,
3709
- timezoneId: this.timezoneId,
3710
- task: this.task,
3711
- modelPreference: this.modelPreference,
3712
- requireDataset: this.requireDataset
3713
- };
3714
- }
3715
- _getAgentConfig() {
3716
- let e = this._session.current?.agentConfig;
3717
- return this.agentConfig === void 0 && this.chatSession && e ? e : Nn(this._buildSessionConfig(), e);
3718
- }
3719
- _emitConversationIdChanged(e) {
3720
- this.conversationId = e, this.dispatchEvent(new CustomEvent("luzmo-conversation-id-changed", {
3721
- detail: { conversationId: e },
3722
- bubbles: !0,
3723
- composed: !0
3724
- }));
3725
- }
3726
- async _restoreViaSession(e, t) {
3727
- await this._session.requireSession().restore({
3728
- restoreToMessageId: e,
3729
- messageIndex: t
3730
- });
3731
- }
3732
- async _handleRestoreState(e, t) {
3733
- if (e.apiMessageId && this._getAgentConfig().type === "item") try {
3734
- await this._restoreViaSession(e.apiMessageId, t);
3735
- } catch (e) {
3736
- console.error("AI restore error:", e);
3737
- }
3738
- }
3739
- _handleDatasetSelected(e) {
3740
- this._session.requireSession().addDataset(e.detail);
3741
- }
3742
- _handleDatasetRemoved(e) {
3743
- this._session.requireSession().removeDataset(e.detail.id);
3744
- }
3745
- _handleAgentSelected() {
3746
- this._processInitialPrompt();
3747
- }
3748
- async _submitViaSession(e, t = {}) {
3749
- let n = this._session.requireSession();
3750
- if (!n.isDatasetRequirementMet(t.agentId)) return !1;
3751
- this._textareaValue = "";
3752
- try {
3753
- return await n.submit({
3754
- prompt: e,
3755
- ...t
3756
- }), !0;
3757
- } catch (e) {
3758
- return e.name !== "AbortError" && console.error("AI prompt session error:", e), !1;
3759
- }
3760
- }
3761
- async _handlePromptSubmitted(e) {
3762
- let t = e.detail.prompt;
3763
- await this._submitViaSession(t, {
3764
- ...e.detail.attachments?.length ? { attachments: e.detail.attachments } : {},
3765
- ...e.detail.attachmentUrls?.length ? { attachmentUrls: e.detail.attachmentUrls } : {},
3766
- ...e.detail.selectedAgent ? { agentId: e.detail.selectedAgent.id } : {}
3767
- }) || (this._textareaValue = t);
3768
- }
3769
- _handlePromptStopped() {
3770
- let e = this._session.current;
3771
- if (this._textareaValue = "", e) {
3772
- e.abort({
3773
- notify: !0,
3774
- cancelledMessage: this.cancelledMessage ?? void 0
3775
- });
3776
- return;
3777
- }
3778
- this.dispatchEvent(new CustomEvent("luzmo-stop", {
3779
- bubbles: !0,
3780
- composed: !0
3781
- }));
3782
- }
3783
- async _handleEmptyStateSuggestionSelected(e) {
3784
- let { prompt: t, selectedDatasets: n } = e.detail, r = this._session.requireSession();
3785
- n?.length && r.setSelectedDatasets(n), await this._submitViaSession(t, { agentId: this._pickedAgentId });
3786
- }
3787
- async _processInitialPrompt() {
3788
- if (!this.initialPrompt || this.initialPrompt === this._lastProcessedInitialPrompt) return;
3789
- let e = this._pickedAgentId;
3790
- this._session.requireSession().isDatasetRequirementMet(e) && (this._lastProcessedInitialPrompt = this.initialPrompt, await this._submitViaSession(this.initialPrompt, {
3791
- skipUserMessage: !0,
3792
- agentId: e
3793
- }));
3794
- }
3795
- connectedCallback() {
3796
- super.connectedCallback(), this._session.connect();
3797
- }
3798
- disconnectedCallback() {
3799
- super.disconnectedCallback(), this._session.teardown();
3800
- }
3801
- _scrollToBottom() {
3802
- let e = this.shadowRoot?.querySelector(".chat-messages-container");
3803
- e && requestAnimationFrame(() => {
3804
- requestAnimationFrame(() => {
3805
- e.scrollTop = e.scrollHeight;
3806
- });
3807
- });
3808
- }
3809
- willUpdate(e) {
3810
- super.willUpdate?.(e), this._syncPendingAssistantMessageAction();
3811
- }
3812
- updated(e) {
3813
- super.updated?.(e), this._syncSession(e), this._handleInitialPromptChange(), e.has("uploadAttachments") && this._session.current?.setUiBridge(this._createDomBridgeCallbacks()), this.updateComplete.then(() => {
3814
- this._syncAssistantMessageActionsVisibility(), this._focusPendingAssistantMessageActionConfirm();
3815
- });
3816
- }
3817
- _syncSession(e) {
3818
- if (e.has("chatSession")) {
3819
- this._session.setSession(this.chatSession);
3820
- return;
3821
- }
3822
- this._session.syncProperties(e);
3823
- }
3824
- _handleInitialPromptChange() {
3825
- this.initialPrompt && this.initialPrompt !== this._lastProcessedInitialPrompt ? this._processInitialPrompt() : this.initialPrompt || (this._lastProcessedInitialPrompt = null);
3826
- }
3827
- _renderMarkdown(e) {
3828
- let t = String(X.parse(e, { async: !1 }));
3829
- return bt.sanitize(t, {
3830
- ALLOWED_TAGS: /* @__PURE__ */ "p.br.strong.em.b.i.u.s.code.pre.blockquote.hr.ul.ol.li.h1.h2.h3.h4.h5.h6.table.thead.tbody.tr.th.td.a".split("."),
3831
- ALLOWED_ATTR: [
3832
- "href",
3833
- "title",
3834
- "target",
3835
- "rel"
3836
- ],
3837
- ALLOW_DATA_ATTR: !1,
3838
- FORBID_TAGS: [
3839
- "script",
3840
- "style",
3841
- "iframe",
3842
- "object",
3843
- "embed",
3844
- "link",
3845
- "form",
3846
- "input",
3847
- "button"
3848
- ],
3849
- FORBID_ATTR: [
3850
- "onerror",
3851
- "onload",
3852
- "onclick",
3853
- "onmouseover",
3854
- "onfocus",
3855
- "onblur"
3856
- ]
3857
- });
3858
- }
3859
- _renderProgress() {
3860
- let { progress: e, progressCollapsed: t } = this._getRenderState();
3861
- return e?.children?.length ? f`
3862
- <luzmo-progress-steps
3863
- .progress=${e}
3864
- ?collapsed=${t}
3865
- .size=${this.size}
3866
- ></luzmo-progress-steps>
3867
- ` : p;
3868
- }
3869
- _syncAssistantMessageActionsVisibility() {
3870
- let e = ((this.shadowRoot?.querySelector(`slot[name="${t.assistantMessageActionsSlot}"]`) ?? null)?.assignedElements({ flatten: !0 }).length ?? 0) > 0;
3871
- this._setAssistantMessageActionsSlotHasContent(e);
3872
- }
3873
- _setAssistantMessageActionsSlotHasContent(e) {
3874
- e !== this._assistantMessageActionsSlotHasContent && (this._assistantMessageActionsSlotHasContent = e);
3875
- }
3876
- _isLatestAssistantMessage(e, t) {
3877
- return !!(t && e === t);
3878
- }
3879
- _hasBuiltInAssistantMessageActions(e) {
3880
- return (e.actions?.length ?? 0) > 0;
3881
- }
3882
- _assistantMessageActionsFooterHasContent(e, t) {
3883
- return this._hasBuiltInAssistantMessageActions(e) || t && this._assistantMessageActionsSlotHasContent;
3884
- }
3885
- _syncPendingAssistantMessageAction() {
3886
- let e = this._pendingAssistantMessageAction;
3887
- if (!e) return;
3888
- let { messages: t } = this._getRenderState(), n = t.find((t) => t.id === e.messageId), r = n?.actions?.find((t) => t.id === e.actionId);
3889
- (!n || !r?.confirm) && (this._pendingAssistantMessageAction = null, this._shouldFocusAssistantMessageActionConfirm = !1);
3890
- }
3891
- _getDefaultAssistantMessageActionConfirmMessage() {
3892
- return c("Are you sure?", { desc: "Default assistant message action confirmation prompt" });
3893
- }
3894
- _isAssistantMessageActionConfirming(e) {
3895
- let t = this._pendingAssistantMessageAction, n = e.id;
3896
- return !!(t && n && t.messageId === n);
3897
- }
3898
- _getPendingAssistantMessageAction(e) {
3899
- let t = this._pendingAssistantMessageAction, n = e.id;
3900
- if (!(!t || !n || t.messageId !== n)) return e.actions?.find((e) => e.id === t.actionId);
3901
- }
3902
- _handleAssistantMessageAction(e, t) {
3903
- let n = e.id;
3904
- n && this.dispatchEvent(new CustomEvent("luzmo-assistant-message-action", {
3905
- detail: {
3906
- messageId: n,
3907
- actionId: t.id,
3908
- message: e
3909
- },
3910
- bubbles: !0,
3911
- composed: !0
3912
- }));
3913
- }
3914
- _handleAssistantMessageActionClick(e, t) {
3915
- let n = e.id;
3916
- if (n) {
3917
- if (t.confirm) {
3918
- this._pendingAssistantMessageAction = {
3919
- messageId: n,
3920
- actionId: t.id
3921
- }, this._shouldFocusAssistantMessageActionConfirm = !0;
3922
- return;
3923
- }
3924
- this._handleAssistantMessageAction(e, t);
3925
- }
3926
- }
3927
- _cancelAssistantMessageActionConfirm() {
3928
- this._pendingAssistantMessageAction = null, this._shouldFocusAssistantMessageActionConfirm = !1;
3929
- }
3930
- _confirmAssistantMessageAction(e, t) {
3931
- this._pendingAssistantMessageAction = null, this._shouldFocusAssistantMessageActionConfirm = !1, this._handleAssistantMessageAction(e, t);
3932
- }
3933
- _focusPendingAssistantMessageActionConfirm() {
3934
- !this._shouldFocusAssistantMessageActionConfirm || !this._pendingAssistantMessageAction || (this._shouldFocusAssistantMessageActionConfirm = !1, (this.shadowRoot?.querySelector("luzmo-button.assistant-message-action-confirm-cancel"))?.focus?.());
3935
- }
3936
- _renderBuiltInAssistantMessageAction(e, t) {
3937
- let n = this.disabled || t.disabled || !e.id;
3938
- return f`
3939
- <luzmo-button
3940
- class="assistant-message-action"
3941
- .size=${this._oneSizeSmaller}
3942
- variant="neutral"
3943
- treatment="outline"
3944
- ?disabled=${n}
3945
- @click=${() => this._handleAssistantMessageActionClick(e, t)}
3946
- >
3947
- ${t.icon ? f`<luzmo-icon slot="icon" .icon=${t.icon} .size=${this._oneSizeSmaller}></luzmo-icon>` : p}
3948
- ${t.label}
3949
- </luzmo-button>
3950
- `;
3951
- }
3952
- _renderAssistantMessageActionConfirm(e) {
3953
- let t = this._getPendingAssistantMessageAction(e);
3954
- if (!t) return p;
3955
- let n = t.confirmMessage ?? this._getDefaultAssistantMessageActionConfirmMessage(), r = this.disabled || t.disabled || !e.id;
3956
- return f`
3957
- <span class="assistant-message-action-confirm-message" role="status" aria-live="polite">${n}</span>
3958
- <div class="assistant-message-action-confirm-controls">
3959
- <luzmo-button
3960
- class="assistant-message-action-confirm-cancel"
3961
- .size=${this._oneSizeSmaller}
3962
- variant="neutral"
3963
- treatment="outline"
3964
- ?disabled=${this.disabled}
3965
- @click=${this._cancelAssistantMessageActionConfirm}
3966
- >
3967
- ${c("Cancel", { desc: "Cancel assistant message action confirmation" })}
3968
- </luzmo-button>
3969
- <luzmo-button
3970
- class="assistant-message-action-confirm-confirm"
3971
- .size=${this._oneSizeSmaller}
3972
- variant=${t.confirmVariant ?? "negative"}
3973
- ?disabled=${r}
3974
- @click=${() => this._confirmAssistantMessageAction(e, t)}
3975
- >
3976
- ${t.label}
3977
- </luzmo-button>
3978
- </div>
3979
- `;
3980
- }
3981
- _renderAssistantMessageActions(e, n) {
3982
- let r = e.actions ?? [], i = r.length > 0, a = this._isLatestAssistantMessage(e, n), o = this._isAssistantMessageActionConfirming(e);
3983
- return !i && !a ? p : f`
3984
- <div
3985
- class="assistant-message-actions ${this._assistantMessageActionsFooterHasContent(e, a) ? "assistant-message-actions--has-content" : ""} ${o ? "assistant-message-actions--confirming" : ""}"
3986
- @keydown=${o ? this._handleAssistantMessageActionConfirmKeydown : p}
3987
- >
3988
- ${o ? this._renderAssistantMessageActionConfirm(e) : f`
3989
- ${r.map((t) => this._renderBuiltInAssistantMessageAction(e, t))}
3990
- ${a ? f`
3991
- <slot
3992
- name=${t.assistantMessageActionsSlot}
3993
- @slotchange=${this._handleAssistantMessageActionsSlotChange}
3994
- ></slot>
3995
- ` : p}
3996
- `}
3997
- </div>
3998
- `;
3999
- }
4000
- _renderRestoreMenu(e, t, n, r = !1) {
4001
- if (!(this._getAgentConfig().type === "item" && this.showAssistantContextMenu && e.hasChart && e.apiMessageId && !e.isError && e.id !== n)) return p;
4002
- let i = `context-menu-trigger-${e.apiMessageId}`;
4003
- return f`
4004
- <div class="assistant-context-menu">
4005
- <button
4006
- id=${i}
4007
- class="assistant-context-menu-trigger"
4008
- type="button"
4009
- aria-label=${c("Open restore menu", { desc: "Accessible label for the ai chat restore menu trigger" })}
4010
- aria-haspopup="menu"
4011
- ?disabled=${r}
4012
- >
4013
- ${u(l)}
4014
- </button>
4015
- <luzmo-overlay
4016
- trigger="${i}@click"
4017
- placement="bottom-end"
4018
- >
4019
- <luzmo-popover>
4020
- <button
4021
- class="assistant-context-menu-item"
4022
- type="button"
4023
- ?disabled=${r}
4024
- @click=${() => this._handleRestoreState(e, t)}
4025
- >
4026
- ${c("Restore state", { desc: "Context menu action that restores the chart to this message state" })}
4027
- </button>
4028
- </luzmo-popover>
4029
- </luzmo-overlay>
4030
- </div>
4031
- `;
4032
- }
4033
- _renderMessages() {
4034
- let { messages: e, inflightMessage: t, isGenerating: n } = this._getRenderState(), r = t !== null, i = e.filter((e) => !t || e.id !== t.id), a = [...i].reverse().find((e) => e.type === "ai"), o = a?.id;
4035
- return i.map((t) => {
4036
- let s = t.progress?.children?.length ? f`
4037
- <luzmo-progress-steps
4038
- .progress=${t.progress}
4039
- collapsed
4040
- no-animate
4041
- .size=${this.size}
4042
- ></luzmo-progress-steps>
4043
- ` : p;
4044
- if (t.type === "user") {
4045
- let e = t.attachmentUrls ?? [];
4046
- return f`
4047
- <luzmo-chat-message
4048
- avatar-placement="bottom"
4049
- position="right"
4050
- variant="primary"
4051
- .size=${this.size}
4052
- >
4053
- <div class="user-message-content">
4054
- ${e.length > 0 ? f`
4055
- <div class="user-message-attachments">
4056
- ${e.map((e) => f`
4057
- <img
4058
- class="user-message-attachment"
4059
- src=${e}
4060
- alt=${c("Attached image", { desc: "Accessible label for an image attached to a user chat message" })}
4061
- width="64"
4062
- height="64"
4063
- />
4064
- `)}
4065
- </div>
4066
- ` : p}
4067
- <div class="user-message-text">${t.message}</div>
4068
- </div>
4069
- </luzmo-chat-message>
4070
- `;
4071
- }
4072
- let l = e.indexOf(t), u = t.isError ? "error" : t.isCancelled ? "cancelled" : "", d = !!t.elicitation && (!t.message.trim() || t.message.trim() === t.elicitation?.question), m = t.isCancelled ? t.message : d ? p : f`<div class="markdown-content">${ee(this._renderMarkdown(t.message))}</div>`;
4073
- return f`
4074
- ${s}
4075
- <div class="assistant-message-wrapper">
4076
- <div class="assistant-message-body">
4077
- <luzmo-chat-message
4078
- class=${u}
4079
- role=${t.isError ? "alert" : p}
4080
- avatar-placement="bottom"
4081
- position="left"
4082
- quiet
4083
- .size=${this.size}
4084
- >
4085
- ${m}
4086
- ${Vn({
4087
- message: t,
4088
- size: this.size,
4089
- state: t.elicitation?.answer ? "answered" : t.id && t === i.at(-1) && !n && !this.disabled ? "open" : "closed",
4090
- onSubmit: (e) => this._handleElicitationSubmit(t, e)
4091
- })}
4092
- </luzmo-chat-message>
4093
-
4094
- ${this._renderRestoreMenu(t, l, o, r)}
4095
- </div>
4096
-
4097
- ${this._renderAssistantMessageActions(t, a)}
4098
- </div>
4099
- `;
4100
- });
4101
- }
4102
- async _handleElicitationSubmit(e, t) {
4103
- t.stopPropagation();
4104
- let n = t.currentTarget, r = n.parentElement, i = zn(t.detail), a = !1;
4105
- if (e.id && i) try {
4106
- let t = this._session.requireSession().answerElicitation(e.id, i, { agentId: this._pickedAgentId });
4107
- await this.updateComplete;
4108
- let n = r?.querySelector("luzmo-question-box[readonly]");
4109
- await n?.updateComplete, n?.focus(), a = await t;
4110
- } catch (e) {
4111
- e.name !== "AbortError" && console.error("AI prompt session error:", e);
4112
- }
4113
- a || (n.reset(), await n.updateComplete, n.focus());
4114
- }
4115
- _renderStreamingResponse() {
4116
- let { inflightMessage: e } = this._getRenderState();
4117
- return e?.message ? f`
4118
- <luzmo-chat-message
4119
- avatar-placement="bottom"
4120
- position="left"
4121
- quiet
4122
- .size=${this.size}
4123
- >
4124
- <div class="markdown-content">${ee(this._renderMarkdown(e.message))}</div>
4125
- </luzmo-chat-message>
4126
- ` : p;
4127
- }
4128
- _renderLoadingMessage() {
4129
- let { isGenerating: e, progress: t, inflightMessage: n } = this._getRenderState();
4130
- if (!e || t?.children?.length || n?.message) return p;
4131
- let r = this._getAgentConfig(), i = Pn(r), a = r.type === "dashboard" ? !i.dashboard : i.chart?.type === "placeholder", o = r.type === "dashboard" ? a ? c("Creating dashboard...", { desc: "Label for ai chat creating dashboard message" }) : c("Updating dashboard...", { desc: "Label for ai chat updating dashboard message" }) : a ? c("Creating item...", { desc: "Label for ai chat creating item message" }) : c("Updating item...", { desc: "Label for ai chat updating item message" });
4132
- return f`
4133
- <luzmo-chat-message
4134
- avatar-placement="bottom"
4135
- position="left"
4136
- quiet
4137
- .size=${this.size}
4138
- >
4139
- <div class="loading-message" role="status" aria-live="polite">
4140
- <span class="icon-lg">${u(d, { className: "spin" })}</span>
4141
- <span class="loading-message-text">${this.loadingMessage || o}</span>
4142
- </div>
4143
- </luzmo-chat-message>
4144
- `;
4145
- }
4146
- _renderEmptyState() {
4147
- if (this._getRenderState().messages.length > 0) return p;
4148
- let e = c("What can I help you with?", { desc: "Title for the AI chat empty state" }), t = this.emptyStateSuggestions.length > 0;
4149
- return f`
4150
- <luzmo-ai-chat-empty-state
4151
- .title=${this.emptyStateTitle || e}
4152
- .subtitle=${t ? this.emptyStateSubtitle : ""}
4153
- .suggestions=${this.emptyStateSuggestions}
4154
- .size=${this.size}
4155
- ?disabled=${this.disabled || this._getRenderState().isGenerating}
4156
- @luzmo-suggestion-selected=${this._handleEmptyStateSuggestionSelected}
4157
- ></luzmo-ai-chat-empty-state>
4158
- `;
4159
- }
4160
- render() {
4161
- let { selectedDatasets: e, isGenerating: t } = this._getRenderState();
4162
- return f`
4163
- <div class="chat-container" role="region" aria-label=${c("AI Chat", { desc: "Accessible label for AI chat region" })}>
4164
- <div class="chat-messages-container" role="log" aria-live="polite">
4165
- ${this._renderEmptyState()}
4166
- ${this._renderMessages()}
4167
- ${this._renderProgress()}
4168
- ${this._renderStreamingResponse()}
4169
- ${this._renderLoadingMessage()}
4170
- </div>
4171
-
4172
- <luzmo-ai-interaction-textarea
4173
- role="group"
4174
- aria-label=${c("AI prompt input", { desc: "Accessible label for the ai chat prompt input area" })}
4175
- .size=${this.size}
4176
- .value=${this._textareaValue}
4177
- .selectedDatasets=${e}
4178
- .placeholder=${this.placeholder}
4179
- ?disabled=${this.disabled}
4180
- ?is-generating=${t}
4181
- ?stoppable=${this.stoppable}
4182
- ?hide-dataset-button=${this.hideDatasetButton}
4183
- ?hide-dataset-icons=${this.hideDatasetIcons}
4184
- ?disable-dataset-modification=${this.disableDatasetModification}
4185
- ?hide-selected-datasets=${this.hideSelectedDatasets}
4186
- ?hide-agents=${this.hideAgents}
4187
- ?disable-column-mentions=${this.disableColumnMentions}
4188
- ?require-dataset=${this.requireDataset}
4189
- ?allow-images=${this.allowImages}
4190
- ?allow-voice-input=${this.allowVoiceInput}
4191
- .acceptedFileTypes=${this._resolvedAcceptedFileTypes}
4192
- .uploadAttachments=${this.uploadAttachments}
4193
- auth-key=${this.authKey}
4194
- auth-token=${this.authToken}
4195
- api-url=${this.apiUrl}
4196
- api-version=${this.apiVersion}
4197
- app-server=${this.appServer}
4198
- ?include-public-datasets=${this.includePublicDatasets}
4199
- @prompt-submitted=${this._handlePromptSubmitted}
4200
- @prompt-stopped=${this._handlePromptStopped}
4201
- @dataset-selected=${this._handleDatasetSelected}
4202
- @dataset-removed=${this._handleDatasetRemoved}
4203
- @luzmo-agent-selected=${this._handleAgentSelected}
4204
- ></luzmo-ai-interaction-textarea>
4205
- </div>
4206
- `;
4207
- }
4208
- };
4209
- di = $, di.styles = m(Mn), di.tagName = "luzmo-ai-chat", di.assistantMessageActionsSlot = "assistant-message-actions", o([h({ type: Array })], $.prototype, "messages", void 0), o([h({
4210
- type: Array,
4211
- attribute: "selected-datasets"
4212
- })], $.prototype, "selectedDatasets", void 0), o([h({ type: String })], $.prototype, "placeholder", void 0), o([h({
4213
- type: Boolean,
4214
- reflect: !0
4215
- })], $.prototype, "disabled", void 0), o([h({
4216
- type: Boolean,
4217
- reflect: !0
4218
- })], $.prototype, "stoppable", void 0), o([h({
4219
- type: Boolean,
4220
- attribute: "show-assistant-context-menu"
4221
- })], $.prototype, "showAssistantContextMenu", void 0), o([h({
4222
- type: String,
4223
- attribute: "auth-key"
4224
- })], $.prototype, "authKey", void 0), o([h({
4225
- type: String,
4226
- attribute: "auth-token"
4227
- })], $.prototype, "authToken", void 0), o([h({
4228
- type: String,
4229
- attribute: "api-url"
4230
- })], $.prototype, "apiUrl", void 0), o([h({
4231
- type: String,
4232
- attribute: "app-server"
4233
- })], $.prototype, "appServer", void 0), o([h({
4234
- type: Boolean,
4235
- reflect: !0,
4236
- attribute: "include-public-datasets"
4237
- })], $.prototype, "includePublicDatasets", void 0), o([h({
4238
- type: Boolean,
4239
- attribute: "flag-opendata"
4240
- })], $.prototype, "flagOpendata", null), o([h({
4241
- type: Boolean,
4242
- attribute: "hide-dataset-button"
4243
- })], $.prototype, "hideDatasetButton", void 0), o([h({
4244
- type: Boolean,
4245
- attribute: "hide-dataset-icons"
4246
- })], $.prototype, "hideDatasetIcons", void 0), o([h({
4247
- type: Boolean,
4248
- attribute: "disable-dataset-modification"
4249
- })], $.prototype, "disableDatasetModification", void 0), o([h({
4250
- type: Boolean,
4251
- attribute: "hide-selected-datasets"
4252
- })], $.prototype, "hideSelectedDatasets", void 0), o([h({
4253
- type: Boolean,
4254
- reflect: !0,
4255
- attribute: "hide-agents"
4256
- })], $.prototype, "hideAgents", void 0), o([h({
4257
- type: Boolean,
4258
- attribute: "disable-column-mentions"
4259
- })], $.prototype, "disableColumnMentions", void 0), o([h({
4260
- type: Boolean,
4261
- attribute: "require-dataset"
4262
- })], $.prototype, "requireDataset", void 0), o([h({
4263
- type: Boolean,
4264
- reflect: !0,
4265
- attribute: "allow-images"
4266
- })], $.prototype, "allowImages", void 0), o([h({
4267
- type: Boolean,
4268
- reflect: !0,
4269
- attribute: "allow-voice-input"
4270
- })], $.prototype, "allowVoiceInput", void 0), o([h({
4271
- type: Array,
4272
- attribute: "accepted-file-types"
4273
- })], $.prototype, "acceptedFileTypes", void 0), o([h({ attribute: !1 })], $.prototype, "uploadAttachments", void 0), o([h({ type: String })], $.prototype, "agent", void 0), o([h({ attribute: !1 })], $.prototype, "agentConfig", void 0), o([h({
4274
- type: String,
4275
- attribute: "agent-id"
4276
- })], $.prototype, "agentId", void 0), o([h({ type: String })], $.prototype, "task", void 0), o([h({
4277
- type: String,
4278
- attribute: "model-preference"
4279
- })], $.prototype, "modelPreference", void 0), o([h({ attribute: !1 })], $.prototype, "chatSession", void 0), o([h({
4280
- type: String,
4281
- attribute: "conversation-id"
4282
- })], $.prototype, "conversationId", void 0), o([h({
4283
- type: Object,
4284
- attribute: "chart"
4285
- })], $.prototype, "chart", void 0), o([h({ type: Object })], $.prototype, "dashboard", void 0), o([h({ attribute: !1 })], $.prototype, "customItem", void 0), o([h({
4286
- type: String,
4287
- attribute: "current-screen-mode"
4288
- })], $.prototype, "currentScreenMode", void 0), o([h({
4289
- type: String,
4290
- attribute: "locale-id"
4291
- })], $.prototype, "localeId", void 0), o([h({
4292
- type: String,
4293
- attribute: "timezone-id"
4294
- })], $.prototype, "timezoneId", void 0), o([h({
4295
- type: String,
4296
- attribute: "api-version"
4297
- })], $.prototype, "apiVersion", void 0), o([h({ converter: { fromAttribute: (e) => e !== "false" && e !== null } })], $.prototype, "stream", void 0), o([h({
4298
- type: String,
4299
- attribute: "loading-message"
4300
- })], $.prototype, "loadingMessage", void 0), o([h({
4301
- type: String,
4302
- attribute: "cancelled-message"
4303
- })], $.prototype, "cancelledMessage", void 0), o([h({
4304
- type: String,
4305
- attribute: "initial-prompt"
4306
- })], $.prototype, "initialPrompt", void 0), o([h({
4307
- type: String,
4308
- attribute: "empty-state-title"
4309
- })], $.prototype, "emptyStateTitle", void 0), o([h({
4310
- type: String,
4311
- attribute: "empty-state-subtitle"
4312
- })], $.prototype, "emptyStateSubtitle", void 0), o([h({
4313
- type: Array,
4314
- attribute: !1
4315
- })], $.prototype, "emptyStateSuggestions", void 0), o([g()], $.prototype, "_textareaValue", void 0), o([g()], $.prototype, "_assistantMessageActionsSlotHasContent", void 0), o([g()], $.prototype, "_pendingAssistantMessageAction", void 0);
4316
- //#endregion
4317
- //#region src/components/ai-chat/ai-chat-events.ts
4318
- function fi(e) {
4319
- return e.recognized === !0;
4320
- }
4321
- //#endregion
4322
- //#region src/components/ai-chat/index.ts
4323
- customElements.get("luzmo-ai-chat") || customElements.define("luzmo-ai-chat", $);
4324
- //#endregion
4325
- export { qn as C, Z as D, Hn as E, Jn as S, Un as T, er as _, li as a, Yn as b, ii as c, _r as d, ar as f, ir as g, nr as h, ci as i, ri as l, tr as m, $ as n, oi as o, or as p, ui as r, ai as s, fi as t, pr as u, Qn as v, Zn as w, Xn as x, $n as y };