@luzmo/analytics-components-kit 1.0.5-beta.1 → 1.0.5-beta.2

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 (1221) hide show
  1. package/components/ad-hoc-slot-content-BwcFfXCV.cjs +20 -0
  2. package/components/ad-hoc-slot-content-hSlT62VS.js +29 -0
  3. package/components/ai-chat/ai-chat-request.d.ts +2 -1
  4. package/components/ai-chat/ai-chat.d.ts +11 -0
  5. package/components/ai-chat/ai-prompt-types.d.ts +9 -1
  6. package/components/ai-chat/index.cjs +1 -1
  7. package/components/ai-chat/index.d.ts +3 -0
  8. package/components/ai-chat/index.js +3 -2
  9. package/components/ai-chat/session/ai-chat-session-controller.d.ts +6 -0
  10. package/components/ai-chat/session/ai-chat-session-types.d.ts +12 -0
  11. package/components/ai-chat/session/ai-chat-session.d.ts +13 -2
  12. package/components/ai-chat-D9tYu1q6.cjs +320 -0
  13. package/components/ai-chat-DstJ__Jz.js +3973 -0
  14. package/components/ai-interaction-textarea/ai-interaction-textarea.d.ts +77 -0
  15. package/components/ai-interaction-textarea/index.cjs +1 -1
  16. package/components/ai-interaction-textarea/index.d.ts +1 -1
  17. package/components/ai-interaction-textarea/index.js +1 -1
  18. package/components/ai-interaction-textarea/types.d.ts +5 -0
  19. package/components/ai-interaction-textarea-BR72djHD.cjs +93 -0
  20. package/components/ai-interaction-textarea-C-feG2HA.js +785 -0
  21. package/components/area-chart-options.config-Cf1VrUNv.cjs +20 -0
  22. package/components/area-chart-options.config-DdYBA1_Q.js +146 -0
  23. package/components/area-chart-positioning.config-BFW46XhO.cjs +20 -0
  24. package/components/area-chart-positioning.config-BfieFxgx.js +55 -0
  25. package/components/area-chart-slots.config-BOhwdLnr.cjs +20 -0
  26. package/components/area-chart-slots.config-Cmdkui4v.js +55 -0
  27. package/components/bar-chart-options.config-BF7Q15FL.cjs +20 -0
  28. package/components/bar-chart-options.config-Cx3n0tCr.js +220 -0
  29. package/components/bar-chart-positioning.config-DURuF-Nr.cjs +20 -0
  30. package/components/bar-chart-positioning.config-DzKDbJHr.js +59 -0
  31. package/components/bar-chart-slots.config-BWvrLYv5.js +50 -0
  32. package/components/bar-chart-slots.config-DMWjAd5a.cjs +20 -0
  33. package/components/base-BRVXqI7u.cjs +20 -0
  34. package/components/base-CUexK-Bc.js +249 -0
  35. package/components/base-store-DHC2m2Os.cjs +20 -0
  36. package/components/base-store-DmDe0dTU.js +160 -0
  37. package/components/box-plot-options.config-BkD5CYGz.cjs +20 -0
  38. package/components/box-plot-options.config-DB9iCCZg.js +296 -0
  39. package/components/box-plot-positioning.config-CYmxOZMk.cjs +20 -0
  40. package/components/box-plot-positioning.config-DmFvqCcg.js +48 -0
  41. package/components/box-plot-slots.config-5B_pTjPJ.cjs +20 -0
  42. package/components/box-plot-slots.config-BknEys-m.js +40 -0
  43. package/components/bubble-chart-options.config-4f9FUNhc.cjs +20 -0
  44. package/components/bubble-chart-options.config-D8o_9z0b.js +115 -0
  45. package/components/bubble-chart-positioning.config-BpJ24lBj.cjs +20 -0
  46. package/components/bubble-chart-positioning.config-YgwDIuAp.js +55 -0
  47. package/components/bubble-chart-slots.config-Djb-py0h.js +47 -0
  48. package/components/bubble-chart-slots.config-VHKuntJk.cjs +20 -0
  49. package/components/bullet-chart-options.config-CmC75LQ8.js +75 -0
  50. package/components/bullet-chart-options.config-DDygYBiy.cjs +20 -0
  51. package/components/bullet-chart-positioning.config-6yUejABM.cjs +20 -0
  52. package/components/bullet-chart-positioning.config-CffspACw.js +56 -0
  53. package/components/bullet-chart-slots.config-BECcf-yZ.js +46 -0
  54. package/components/bullet-chart-slots.config-CZfTgKZ4.cjs +20 -0
  55. package/components/choropleth-map-options.config-5W6nNlL7.cjs +20 -0
  56. package/components/choropleth-map-options.config-Bt-vXkKW.js +348 -0
  57. package/components/choropleth-map-positioning.config-Bl5HERTz.js +55 -0
  58. package/components/choropleth-map-positioning.config-nlky_swe.cjs +20 -0
  59. package/components/choropleth-map-slots.config-CZKWF1qV.cjs +20 -0
  60. package/components/choropleth-map-slots.config-DVrgJYSA.js +53 -0
  61. package/components/circle-pack-chart-options.config-CD8MWMTw.cjs +20 -0
  62. package/components/circle-pack-chart-options.config-CLA-ur8J.js +54 -0
  63. package/components/circle-pack-chart-positioning.config-_y9nL_PY.cjs +20 -0
  64. package/components/circle-pack-chart-positioning.config-cBxfJDgf.js +48 -0
  65. package/components/circle-pack-chart-slots.config-BG6Gh03S.js +38 -0
  66. package/components/circle-pack-chart-slots.config-GL7T5_o4.cjs +20 -0
  67. package/components/circular-gauge-options.config-BFBmfsPn.js +188 -0
  68. package/components/circular-gauge-options.config-D9gcbX57.cjs +20 -0
  69. package/components/circular-gauge-positioning.config-BtFTmQVx.cjs +20 -0
  70. package/components/circular-gauge-positioning.config-HG_MhCL2.js +48 -0
  71. package/components/circular-gauge-slots.config-BSzOAb8B.js +39 -0
  72. package/components/circular-gauge-slots.config-DUHabt3G.cjs +20 -0
  73. package/components/color-BWnYpOu7.js +3812 -0
  74. package/components/color-range-utils-CwwtLDX_.js +63 -0
  75. package/components/column-chart-options.config-CiIw23Yo.cjs +20 -0
  76. package/components/column-chart-options.config-V7v9PtQA.js +219 -0
  77. package/components/column-chart-positioning.config-DQtY7_jS.js +55 -0
  78. package/components/column-chart-positioning.config-sAg6OdcO.cjs +20 -0
  79. package/components/column-chart-slots.config-5BjkTrbt.js +50 -0
  80. package/components/column-chart-slots.config-CM5aytbj.cjs +20 -0
  81. package/components/combination-chart-options.config-CgSqqLLE.js +87 -0
  82. package/components/combination-chart-options.config-DaTYSfnr.cjs +20 -0
  83. package/components/combination-chart-positioning.config-CUC44b4w.cjs +20 -0
  84. package/components/combination-chart-positioning.config-xdJ5PeeE.js +48 -0
  85. package/components/combination-chart-slots.config-BwUOXFCR.cjs +20 -0
  86. package/components/combination-chart-slots.config-DgM_T-9r.js +43 -0
  87. package/components/conditional-number-options.config-3_vXSC0j.js +205 -0
  88. package/components/conditional-number-options.config-BPzCxo2q.cjs +20 -0
  89. package/components/conditional-number-positioning.config-BpggYmeg.cjs +20 -0
  90. package/components/conditional-number-positioning.config-Cu3E21yK.js +48 -0
  91. package/components/conditional-number-slots.config-B7maHIaG.cjs +20 -0
  92. package/components/conditional-number-slots.config-CzVPP4me.js +39 -0
  93. package/components/convert-data-field-to-slot-content-DLzkk6dT.cjs +20 -0
  94. package/components/data-broker-Bdv5V8Yp.js +1680 -0
  95. package/components/data-broker-DWEXs6-2.cjs +20 -0
  96. package/components/data-field/index.cjs +1 -1
  97. package/components/data-field/index.js +1 -1
  98. package/components/data-field-CX74S6vV.cjs +54 -0
  99. package/components/data-field-D_EnR1Yt.js +121 -0
  100. package/components/data-field-level/index.cjs +1 -1
  101. package/components/data-field-level/index.js +1 -1
  102. package/components/data-field-level-CFLMDP3a.js +247 -0
  103. package/components/data-field-level-DaDY2_HH.cjs +55 -0
  104. package/components/data-field-panel/index.cjs +1 -1
  105. package/components/data-field-panel/index.js +1 -1
  106. package/components/data-field-panel-BhYP77ZO.js +385 -0
  107. package/components/data-field-panel-BxEVeR6H.cjs +87 -0
  108. package/components/data-fields-select/index.cjs +1 -1
  109. package/components/data-fields-select/index.js +1 -1
  110. package/components/data-fields-select-FlSG0h_V.js +262 -0
  111. package/components/data-fields-select-p53mdgQy.cjs +41 -0
  112. package/components/dataset-icon/index.js +1 -1
  113. package/components/dataset-icon-CWT5Ju8w.js +125 -0
  114. package/components/dataset-selector-list/index.cjs +1 -1
  115. package/components/dataset-selector-list/index.js +1 -1
  116. package/components/dataset-selector-list-ByFAG-kf.cjs +75 -0
  117. package/components/dataset-selector-list-CWIbaMga.js +313 -0
  118. package/components/dataset-selector-row/index.cjs +1 -1
  119. package/components/dataset-selector-row/index.js +1 -1
  120. package/components/dataset-selector-row--W1e0KF2.cjs +79 -0
  121. package/components/dataset-selector-row-CaNvh0Zr.js +273 -0
  122. package/components/date-comparison-filter-options.config-4yHPEJSU.cjs +20 -0
  123. package/components/date-comparison-filter-options.config-CsDlmT6L.js +126 -0
  124. package/components/date-comparison-filter-slots.config-EEgNP09x.js +33 -0
  125. package/components/date-comparison-filter-slots.config-oABOLs3D.cjs +20 -0
  126. package/components/date-filter-options.config-AFAngO_i.cjs +20 -0
  127. package/components/date-filter-options.config-b8EHOjR1.js +118 -0
  128. package/components/date-filter-slots.config-Cuzz0RjE.cjs +20 -0
  129. package/components/date-filter-slots.config-PJ_h3Aj7.js +37 -0
  130. package/components/de-DZ5SDLoC.cjs +20 -0
  131. package/components/de-D_05k7cJ.js +486 -0
  132. package/components/decorate-DyMgX_Uh.js +28 -0
  133. package/components/display-settings/index.cjs +1 -1
  134. package/components/display-settings/index.js +1 -1
  135. package/components/display-settings-BLVdnS2P.cjs +140 -0
  136. package/components/display-settings-BaUca4WC.js +313 -0
  137. package/components/display-settings-binning/index.cjs +1 -1
  138. package/components/display-settings-binning/index.js +1 -1
  139. package/components/display-settings-binning-BNwdn9lC.cjs +56 -0
  140. package/components/display-settings-binning-DlgU4lX4.js +110 -0
  141. package/components/display-settings-datetime/index.cjs +1 -1
  142. package/components/display-settings-datetime/index.js +1 -1
  143. package/components/display-settings-datetime-BF9hOp8K.cjs +217 -0
  144. package/components/display-settings-datetime-DXcE_L84.js +413 -0
  145. package/components/display-settings-grand-totals/index.cjs +1 -1
  146. package/components/display-settings-grand-totals/index.js +1 -1
  147. package/components/display-settings-grand-totals-CqBebvyl.cjs +44 -0
  148. package/components/display-settings-grand-totals-D3duaMBq.js +89 -0
  149. package/components/display-settings-numeric/index.cjs +1 -1
  150. package/components/display-settings-numeric/index.js +1 -1
  151. package/components/display-settings-numeric-Bpph7Z0c.cjs +190 -0
  152. package/components/display-settings-numeric-C7-eiHxR.js +479 -0
  153. package/components/display-settings-period-over-period/index.cjs +1 -1
  154. package/components/display-settings-period-over-period/index.js +1 -1
  155. package/components/display-settings-period-over-period-Bt_7yg70.js +433 -0
  156. package/components/display-settings-period-over-period-Ce-yNJvu.cjs +229 -0
  157. package/components/donut-chart-options.config-D8Bvo6Cc.cjs +20 -0
  158. package/components/donut-chart-options.config-N0MWtn-o.js +207 -0
  159. package/components/donut-chart-positioning.config-BOuKJIMR.cjs +20 -0
  160. package/components/donut-chart-positioning.config-VOymRD6M.js +48 -0
  161. package/components/donut-chart-slots.config-Bi08z-XB.cjs +20 -0
  162. package/components/donut-chart-slots.config-dQrT0g_x.js +39 -0
  163. package/components/dropdown-filter-options.config-BRzYD0KE.cjs +20 -0
  164. package/components/dropdown-filter-options.config-CziqJFPz.js +153 -0
  165. package/components/dropdown-filter-slots.config-CQo3-kIo.js +38 -0
  166. package/components/dropdown-filter-slots.config-CR-Ko6q_.cjs +20 -0
  167. package/components/en-GB-uxY5qmIM.cjs +20 -0
  168. package/components/en-US-q_Ruzags.cjs +20 -0
  169. package/components/en-q_Ruzags.cjs +20 -0
  170. package/components/es-D2WbSDXb.js +486 -0
  171. package/components/es-DbsozUJM.cjs +20 -0
  172. package/components/evolution-number-options.config-BfYN1Qgk.js +228 -0
  173. package/components/evolution-number-options.config-CkqNYgWn.cjs +20 -0
  174. package/components/evolution-number-positioning.config-BO5omIBO.js +48 -0
  175. package/components/evolution-number-positioning.config-D2uRKbgg.cjs +20 -0
  176. package/components/evolution-number-slots.config-CBS0b0Yk.js +37 -0
  177. package/components/evolution-number-slots.config-CikuQYgm.cjs +20 -0
  178. package/components/filter-expression-picker/index.cjs +1 -1
  179. package/components/filter-expression-picker/index.js +1 -1
  180. package/components/filter-expression-picker-BciiMtpZ.js +425 -0
  181. package/components/filter-expression-picker-CoK9Eyfu.cjs +38 -0
  182. package/components/filter-item/index.cjs +1 -1
  183. package/components/filter-item/index.js +1 -1
  184. package/components/filter-item-BmXuGhiV.js +242 -0
  185. package/components/filter-item-Du_13KmX.cjs +58 -0
  186. package/components/filter-parameter-picker/index.js +1 -1
  187. package/components/filter-value-picker/index.cjs +1 -1
  188. package/components/filter-value-picker/index.js +1 -1
  189. package/components/filter-value-picker-CcJP9HyG.cjs +60 -0
  190. package/components/filter-value-picker-DVgv3jjr.js +151 -0
  191. package/components/filter-value-picker-datetime/index.cjs +1 -1
  192. package/components/filter-value-picker-datetime/index.js +1 -1
  193. package/components/filter-value-picker-datetime-C8TlvexC.js +139 -0
  194. package/components/filter-value-picker-datetime-DcJQwICl.cjs +42 -0
  195. package/components/filter-value-picker-hierarchy/index.cjs +1 -1
  196. package/components/filter-value-picker-hierarchy/index.js +1 -1
  197. package/components/filter-value-picker-hierarchy-DuCIK_cQ.cjs +47 -0
  198. package/components/filter-value-picker-hierarchy-p7KmAEfD.js +232 -0
  199. package/components/filter-value-picker-numeric/index.cjs +1 -1
  200. package/components/filter-value-picker-numeric/index.js +1 -1
  201. package/components/filter-value-picker-numeric-CEQteSXv.js +219 -0
  202. package/components/filter-value-picker-numeric-CkuF9VUR.cjs +48 -0
  203. package/components/filters/index.cjs +1 -1
  204. package/components/filters/index.js +1 -1
  205. package/components/filters-CFYjlJk9.cjs +150 -0
  206. package/components/filters-YOx1cv6z.js +400 -0
  207. package/components/formatter-BeXmurVe.cjs +20 -0
  208. package/components/formula/index.cjs +1 -1
  209. package/components/formula/index.js +1 -1
  210. package/components/formula-D5Q_PS-K.js +138 -0
  211. package/components/formula-HGRB-nzB.cjs +45 -0
  212. package/components/formula-codemirror-DimorTw-.js +12018 -0
  213. package/components/formula-codemirror-F9csVYEQ.cjs +215 -0
  214. package/components/formula-display-store-Bhx14M2X.cjs +20 -0
  215. package/components/formula-display-store-dkkdggcj.js +1090 -0
  216. package/components/formula-editor/index.cjs +1 -1
  217. package/components/formula-editor/index.js +3 -3
  218. package/components/formula-editor-B2HvrGdp.js +666 -0
  219. package/components/formula-editor-Cfan0Njf.cjs +218 -0
  220. package/components/formula-field/index.cjs +1 -1
  221. package/components/formula-field/index.js +1 -1
  222. package/components/formula-field-B-471pmk.cjs +20 -0
  223. package/components/formula-field-DVUuiFVC.js +40 -0
  224. package/components/formula-input-base-CHF-NVew.cjs +49 -0
  225. package/components/formula-input-base-XQo00D8V.js +236 -0
  226. package/components/fr-D0jP-0QP.js +486 -0
  227. package/components/fr-E4npvQVn.cjs +20 -0
  228. package/components/funnel-chart-options.config-BVmrhzna.cjs +20 -0
  229. package/components/funnel-chart-options.config-D8fqrJvi.js +187 -0
  230. package/components/funnel-chart-positioning.config-D61EoLfa.cjs +20 -0
  231. package/components/funnel-chart-positioning.config-DTlmceYZ.js +48 -0
  232. package/components/funnel-chart-slots.config-B8zC6Q6_.cjs +20 -0
  233. package/components/funnel-chart-slots.config-CeGu8stc.js +43 -0
  234. package/components/get-css-variable-B8sJUuig.cjs +20 -0
  235. package/components/get-css-variable-r1spgqX0.js +63 -0
  236. package/components/get-dataset-name-B24ms5Si.js +27 -0
  237. package/components/get-dataset-name-DHSjl0Xg.cjs +20 -0
  238. package/components/groupings-BJ89rBBj.cjs +20 -0
  239. package/components/groupings-BQl_7M6c.js +52 -0
  240. package/components/heat-map-options.config-5zjlVaa0.js +224 -0
  241. package/components/heat-map-options.config-xPdOcXDk.cjs +20 -0
  242. package/components/heat-map-positioning.config-Bm4O1kO-.cjs +20 -0
  243. package/components/heat-map-positioning.config-BtPM-mdL.js +48 -0
  244. package/components/heat-map-slots.config-DBkkcvMN.js +37 -0
  245. package/components/heat-map-slots.config-Wp_oS8JQ.cjs +20 -0
  246. package/components/heat-table-options.config-Blcs4JjF.js +372 -0
  247. package/components/heat-table-options.config-DPbTFoRn.cjs +20 -0
  248. package/components/heat-table-positioning.config-BGs7-swK.cjs +20 -0
  249. package/components/heat-table-positioning.config-BSmgGTV-.js +55 -0
  250. package/components/heat-table-slots.config-BN7rtHZG.cjs +20 -0
  251. package/components/heat-table-slots.config-CJOXI-Sf.js +49 -0
  252. package/components/hexbin-map-options.config-CSFSqpMU.cjs +20 -0
  253. package/components/hexbin-map-options.config-D5o0k890.js +276 -0
  254. package/components/hexbin-map-positioning.config-6tI7Fsx6.cjs +20 -0
  255. package/components/hexbin-map-positioning.config-DN6UPACN.js +48 -0
  256. package/components/hexbin-map-slots.config-CpJIfl6o.js +37 -0
  257. package/components/hexbin-map-slots.config-mx5zUTrA.cjs +20 -0
  258. package/components/image-options.config-C46UQpMq.js +153 -0
  259. package/components/image-options.config-DZ5q1D63.cjs +20 -0
  260. package/components/image-slots.config-DjaT4mUk.js +24 -0
  261. package/components/image-slots.config-ODQBVz5H.cjs +20 -0
  262. package/components/index.cjs +1 -1
  263. package/components/index.js +64 -64
  264. package/components/interactive-viz-item/index.cjs +1 -1
  265. package/components/interactive-viz-item/index.js +1 -1
  266. package/components/interactive-viz-item-COsyvG-7.cjs +247 -0
  267. package/components/interactive-viz-item-xwBNcoFX.js +693 -0
  268. package/components/item-grid/index.cjs +1 -1
  269. package/components/item-grid/index.js +1 -1
  270. package/components/item-grid-1AHf6uNh.js +4559 -0
  271. package/components/item-grid-BTWZLR9l.cjs +113 -0
  272. package/components/item-option/index.cjs +1 -1
  273. package/components/item-option/index.js +1 -1
  274. package/components/item-option-D6mIG3C2.cjs +252 -0
  275. package/components/item-option-DiKf1I-V.js +919 -0
  276. package/components/item-option-action-button-group/index.cjs +1 -1
  277. package/components/item-option-action-button-group/index.js +1 -1
  278. package/components/item-option-action-button-group-DZVGBwVB.cjs +53 -0
  279. package/components/item-option-action-button-group-_MTf9Kyg.js +118 -0
  280. package/components/item-option-base-72_Lz4oa.js +123 -0
  281. package/components/item-option-base-D4uG83bv.cjs +56 -0
  282. package/components/item-option-color-palette-picker/index.cjs +1 -1
  283. package/components/item-option-color-palette-picker/index.js +1 -1
  284. package/components/item-option-color-palette-picker-9LzOFRqA.cjs +40 -0
  285. package/components/item-option-color-palette-picker-D6ZtQuby.js +2041 -0
  286. package/components/item-option-color-picker/index.cjs +1 -1
  287. package/components/item-option-color-picker/index.js +1 -1
  288. package/components/item-option-color-picker-Bzfx2m97.cjs +34 -0
  289. package/components/item-option-color-picker-CJ8QNFEa.js +87 -0
  290. package/components/item-option-color-range/index.cjs +1 -1
  291. package/components/item-option-color-range/index.js +1 -1
  292. package/components/item-option-color-range-DDwD_l1L.js +220 -0
  293. package/components/item-option-color-range-DbjFNFga.cjs +98 -0
  294. package/components/item-option-multi-language-field/index.cjs +1 -1
  295. package/components/item-option-multi-language-field/index.js +1 -1
  296. package/components/item-option-multi-language-field-CLUOInEz.cjs +33 -0
  297. package/components/item-option-multi-language-field-DqGIz3c2.js +82 -0
  298. package/components/item-option-number-field/index.cjs +1 -1
  299. package/components/item-option-number-field/index.js +1 -1
  300. package/components/item-option-number-field-CALHe4NE.js +102 -0
  301. package/components/item-option-number-field-rOKqFeZL.cjs +38 -0
  302. package/components/item-option-panel/index.cjs +1 -1
  303. package/components/item-option-panel/index.js +1 -1
  304. package/components/item-option-panel-BETP4EXN.cjs +67 -0
  305. package/components/item-option-panel-VqBQ4vCD.js +183 -0
  306. package/components/item-option-picker/index.cjs +1 -1
  307. package/components/item-option-picker/index.js +1 -1
  308. package/components/item-option-picker-B1c4lBTC.js +77 -0
  309. package/components/item-option-picker-D8m-VrSA.cjs +37 -0
  310. package/components/item-option-position-picker/index.cjs +1 -1
  311. package/components/item-option-position-picker/index.js +1 -1
  312. package/components/item-option-position-picker-3saFBaim.cjs +32 -0
  313. package/components/item-option-position-picker-suuQsaHa.js +117 -0
  314. package/components/item-option-positions-number-field/index.cjs +1 -1
  315. package/components/item-option-positions-number-field/index.js +1 -1
  316. package/components/item-option-positions-number-field-C8Fdb51M.js +164 -0
  317. package/components/item-option-positions-number-field-DWEE8FIS.cjs +49 -0
  318. package/components/item-option-radio-button-group/index.cjs +1 -1
  319. package/components/item-option-radio-button-group/index.js +1 -1
  320. package/components/item-option-radio-button-group-CIZlII80.cjs +37 -0
  321. package/components/item-option-radio-button-group-CsqrAsWc.js +74 -0
  322. package/components/item-option-slider/index.cjs +1 -1
  323. package/components/item-option-slider/index.js +1 -1
  324. package/components/item-option-slider-C0PwAy27.cjs +33 -0
  325. package/components/item-option-slider-DeHoSEtb.js +81 -0
  326. package/components/item-option-switch/index.cjs +1 -1
  327. package/components/item-option-switch/index.js +1 -1
  328. package/components/item-option-switch-BByrv8oZ.cjs +30 -0
  329. package/components/item-option-switch-D7YzsVwc.js +69 -0
  330. package/components/item-option-text-field/index.cjs +1 -1
  331. package/components/item-option-text-field/index.js +1 -1
  332. package/components/item-option-text-field-C9y2J3bZ.js +80 -0
  333. package/components/item-option-text-field-edIJYLwK.cjs +33 -0
  334. package/components/item-options-configs.cjs +1 -1
  335. package/components/item-options-configs.js +45 -45
  336. package/components/item-slot-drop/index.cjs +1 -1
  337. package/components/item-slot-drop/index.js +1 -1
  338. package/components/item-slot-drop-BioBKinp.cjs +91 -0
  339. package/components/item-slot-drop-BpdhUeHr.js +331 -0
  340. package/components/item-slot-drop-panel/index.cjs +1 -1
  341. package/components/item-slot-drop-panel/index.js +1 -1
  342. package/components/item-slot-drop-panel-Cfak8X0X.js +355 -0
  343. package/components/item-slot-drop-panel-DsWaCS45.cjs +57 -0
  344. package/components/item-slot-picker/index.cjs +1 -1
  345. package/components/item-slot-picker/index.js +1 -1
  346. package/components/item-slot-picker-BKZzESjJ.cjs +174 -0
  347. package/components/item-slot-picker-Dsktaddk.js +505 -0
  348. package/components/item-slot-picker-panel/index.cjs +1 -1
  349. package/components/item-slot-picker-panel/index.js +1 -1
  350. package/components/item-slot-picker-panel-DHRq0Fdl.js +448 -0
  351. package/components/item-slot-picker-panel-DupK23lZ.cjs +81 -0
  352. package/components/item-slots-configs.cjs +1 -1
  353. package/components/item-slots-configs.js +45 -45
  354. package/components/line-chart-options.config-BkK829A2.cjs +20 -0
  355. package/components/line-chart-options.config-KFAaQqB_.js +168 -0
  356. package/components/line-chart-positioning.config-C0RfTCDE.cjs +20 -0
  357. package/components/line-chart-positioning.config-Djwg-IFN.js +55 -0
  358. package/components/line-chart-slots.config-D0jaC82U.js +55 -0
  359. package/components/line-chart-slots.config-vv66fcoE.cjs +20 -0
  360. package/components/load-data-fields-for-datasets-BNnr8x3m.js +42 -0
  361. package/components/load-data-fields-for-datasets-CW4Voiex.cjs +20 -0
  362. package/components/localized-mixin-BsdiWv93.js +45 -0
  363. package/components/localized-mixin-CICfOIAL.cjs +20 -0
  364. package/components/marker-map-options.config-BfPFVxpD.cjs +20 -0
  365. package/components/marker-map-options.config-D0RmFKKM.js +117 -0
  366. package/components/marker-map-positioning.config-C_iKxInT.js +48 -0
  367. package/components/marker-map-positioning.config-D3z2_PYt.cjs +20 -0
  368. package/components/marker-map-slots.config-DigZk7lN.cjs +20 -0
  369. package/components/marker-map-slots.config-DsMklO0v.js +37 -0
  370. package/components/nl-8nHhvKVN.js +486 -0
  371. package/components/nl-Ct89Nnbs.cjs +20 -0
  372. package/components/ohlc-chart-options.config-BBdUKmJ9.js +65 -0
  373. package/components/ohlc-chart-options.config-BsBVP-Io.cjs +20 -0
  374. package/components/ohlc-chart-positioning.config-B6cmVTir.js +78 -0
  375. package/components/ohlc-chart-positioning.config-Bb4fYPeO.cjs +20 -0
  376. package/components/ohlc-chart-slots.config-BiQn5Kdg.js +68 -0
  377. package/components/ohlc-chart-slots.config-D3fzoQJH.cjs +20 -0
  378. package/components/parallel-coordinates-plot-options.config--6iJkURT.cjs +20 -0
  379. package/components/parallel-coordinates-plot-options.config-KJrOL0Sr.js +42 -0
  380. package/components/parallel-coordinates-plot-positioning.config-BsJW1FP-.js +48 -0
  381. package/components/parallel-coordinates-plot-positioning.config-cFfEWBCQ.cjs +20 -0
  382. package/components/parallel-coordinates-plot-slots.config-B7QY714-.js +46 -0
  383. package/components/parallel-coordinates-plot-slots.config-s_tLqGA-.cjs +20 -0
  384. package/components/pivot-table-options.config-CKGnnXa_.cjs +20 -0
  385. package/components/pivot-table-options.config-DEmZ_EQi.js +245 -0
  386. package/components/pivot-table-positioning.config-CMAsxlCi.cjs +20 -0
  387. package/components/pivot-table-positioning.config-D1L_TBUC.js +55 -0
  388. package/components/pivot-table-slots.config-DpDaXLdw.js +55 -0
  389. package/components/pivot-table-slots.config-KlYXL90k.cjs +20 -0
  390. package/components/pragmatic-element-adapter-C_7HSvGV.js +1252 -0
  391. package/components/pragmatic-element-adapter-DPWYJiW9.cjs +24 -0
  392. package/components/pyramid-chart-options.config-8QtjhcJC.cjs +20 -0
  393. package/components/pyramid-chart-options.config-DiD3QFps.js +240 -0
  394. package/components/pyramid-chart-positioning.config-BF_YUB98.js +55 -0
  395. package/components/pyramid-chart-positioning.config-BPlmVwKw.cjs +20 -0
  396. package/components/pyramid-chart-slots.config-BrKgartT.js +50 -0
  397. package/components/pyramid-chart-slots.config-CreUpxI2.cjs +20 -0
  398. package/components/radar-chart-options.config-COBM2L3R.js +130 -0
  399. package/components/radar-chart-options.config-DvW36_zk.cjs +20 -0
  400. package/components/radar-chart-positioning.config-Be3DzcOK.js +55 -0
  401. package/components/radar-chart-positioning.config-OcJlRx0R.cjs +20 -0
  402. package/components/radar-chart-slots.config-B3oIp-8w.cjs +20 -0
  403. package/components/radar-chart-slots.config-SivEBhuj.js +53 -0
  404. package/components/regular-table-options.config-B0WNqEjR.cjs +20 -0
  405. package/components/regular-table-options.config-B0zRcsWM.js +148 -0
  406. package/components/regular-table-slots.config-M2axBXl4.js +35 -0
  407. package/components/regular-table-slots.config-UwzWj6gg.cjs +20 -0
  408. package/components/route-map-options.config-CYNKz_Xm.cjs +20 -0
  409. package/components/route-map-options.config-CrMrDQ_l.js +326 -0
  410. package/components/route-map-positioning.config-Bh57uCEW.js +66 -0
  411. package/components/route-map-positioning.config-DRK2m99b.cjs +20 -0
  412. package/components/route-map-slots.config-COCoP99E.js +59 -0
  413. package/components/route-map-slots.config-DfYT65BF.cjs +20 -0
  414. package/components/sankey-diagram-options.config-BYLiy1UX.js +126 -0
  415. package/components/sankey-diagram-options.config-D49IZ1y3.cjs +20 -0
  416. package/components/sankey-diagram-positioning.config-D7Jtuhko.cjs +20 -0
  417. package/components/sankey-diagram-positioning.config-iIPclYoY.js +66 -0
  418. package/components/sankey-diagram-slots.config-C-sqtrS-.js +61 -0
  419. package/components/sankey-diagram-slots.config-D-_u4w36.cjs +20 -0
  420. package/components/scatter-plot-options.config-BETVLevv.cjs +20 -0
  421. package/components/scatter-plot-options.config-BpUYcLt-.js +302 -0
  422. package/components/scatter-plot-positioning.config-1QiXjsOV.cjs +20 -0
  423. package/components/scatter-plot-positioning.config-CanuubeV.js +77 -0
  424. package/components/scatter-plot-slots.config-CrG6wQtV.cjs +20 -0
  425. package/components/scatter-plot-slots.config-Dg78lS25.js +74 -0
  426. package/components/search-filter-options.config-B-dGVPhS.cjs +20 -0
  427. package/components/search-filter-options.config-lGQ-biU5.js +103 -0
  428. package/components/search-filter-slots.config-BhDSDpNd.js +39 -0
  429. package/components/search-filter-slots.config-DP06ulJA.cjs +20 -0
  430. package/components/set-locale-CDdUWJUq.cjs +20 -0
  431. package/components/set-locale-D4CaVip4.js +43 -0
  432. package/components/slicer-filter-options.config-7OXpRWtw.cjs +20 -0
  433. package/components/slicer-filter-options.config-B6rxZYcl.js +226 -0
  434. package/components/slicer-filter-positioning.config-B7HlZizi.cjs +20 -0
  435. package/components/slicer-filter-positioning.config-BLkIaQQJ.js +48 -0
  436. package/components/slicer-filter-slots.config-CHKpdJvF.cjs +20 -0
  437. package/components/slicer-filter-slots.config-XtuZoiId.js +44 -0
  438. package/components/slider-filter-options.config-C7-5aoaC.js +72 -0
  439. package/components/slider-filter-options.config-CRdbX1IJ.cjs +20 -0
  440. package/components/slider-filter-slots.config-9R298H0t.cjs +20 -0
  441. package/components/slider-filter-slots.config-BYkIGVvh.js +43 -0
  442. package/components/slot-menu/index.cjs +1 -1
  443. package/components/slot-menu/index.js +1 -1
  444. package/components/slot-menu-B0TdqTeU.js +426 -0
  445. package/components/slot-menu-Cl3x8mjj.cjs +71 -0
  446. package/components/slot-menu-list/index.cjs +1 -1
  447. package/components/slot-menu-list/index.js +1 -1
  448. package/components/slot-menu-list-B9TBCRxe.cjs +44 -0
  449. package/components/slot-menu-list-DlZoh014.js +347 -0
  450. package/components/slot-role-classification-2wChhpcq.cjs +20 -0
  451. package/components/slot-role-classification-B8bkGhQ_.js +133 -0
  452. package/components/slots-config-DMC15sjT.js +77 -0
  453. package/components/slots-config-DVH0lz6t.cjs +20 -0
  454. package/components/speedometer-chart-options.config-Bd3-G7S7.js +246 -0
  455. package/components/speedometer-chart-options.config-BsIu28S3.cjs +20 -0
  456. package/components/speedometer-chart-positioning.config-ChZlrktw.js +48 -0
  457. package/components/speedometer-chart-positioning.config-DLyYBstR.cjs +20 -0
  458. package/components/speedometer-chart-slots.config-CkeiXSCy.js +39 -0
  459. package/components/speedometer-chart-slots.config-S_hQm2MV.cjs +20 -0
  460. package/components/spike-map-options.config-B_2BXI_9.js +413 -0
  461. package/components/spike-map-options.config-aaiZyME6.cjs +20 -0
  462. package/components/spike-map-positioning.config--1BDkwc2.cjs +20 -0
  463. package/components/spike-map-positioning.config-Bd85irgl.js +55 -0
  464. package/components/spike-map-slots.config-C44Vxsit.js +47 -0
  465. package/components/spike-map-slots.config-cKfaD6dQ.cjs +20 -0
  466. package/components/strip-plot-options.config-By62J2Jj.js +53 -0
  467. package/components/strip-plot-options.config-TB3rkoj2.cjs +20 -0
  468. package/components/strip-plot-positioning.config-C6QwpxOm.js +48 -0
  469. package/components/strip-plot-positioning.config-dBrlDJ1t.cjs +20 -0
  470. package/components/strip-plot-slots.config-DNYlrK_c.cjs +20 -0
  471. package/components/strip-plot-slots.config-xsNFXerT.js +38 -0
  472. package/components/sunburst-chart-options.config-Ckk_kY_s.cjs +20 -0
  473. package/components/sunburst-chart-options.config-DwQwkQxR.js +160 -0
  474. package/components/sunburst-chart-positioning.config-BCByMy4k.js +48 -0
  475. package/components/sunburst-chart-positioning.config-DdrE80fO.cjs +20 -0
  476. package/components/sunburst-chart-slots.config-D6Z2_Kh_.js +38 -0
  477. package/components/sunburst-chart-slots.config-DkUUt5RF.cjs +20 -0
  478. package/components/symbol-map-options.config-56eoWz4w.cjs +20 -0
  479. package/components/symbol-map-options.config-uXEbOHWD.js +157 -0
  480. package/components/symbol-map-positioning.config-GruDumfg.cjs +20 -0
  481. package/components/symbol-map-positioning.config-sg4xS30s.js +55 -0
  482. package/components/symbol-map-slots.config-CHTIkMw4.js +53 -0
  483. package/components/symbol-map-slots.config-DwNf547A.cjs +20 -0
  484. package/components/text-options.config-B5y7YAqT.js +67 -0
  485. package/components/text-options.config-BwBCG2yo.cjs +20 -0
  486. package/components/text-slots.config-CPghLc8b.cjs +20 -0
  487. package/components/text-slots.config-sFoowMc6.js +24 -0
  488. package/components/treemap-chart-options.config-BouAbrk0.js +184 -0
  489. package/components/treemap-chart-options.config-r6biULUj.cjs +20 -0
  490. package/components/treemap-chart-positioning.config-B4HptgcF.cjs +20 -0
  491. package/components/treemap-chart-positioning.config-DPf011uh.js +55 -0
  492. package/components/treemap-chart-slots.config-BjHBRWDJ.js +47 -0
  493. package/components/treemap-chart-slots.config-CS3ot6ZJ.cjs +20 -0
  494. package/components/utils/base.cjs +1 -1
  495. package/components/utils/base.js +2 -2
  496. package/components/utils/store.cjs +1 -1
  497. package/components/utils/store.js +2 -2
  498. package/components/utils-ApDFkgMX.js +240 -0
  499. package/components/utils-BXPde8Tt.cjs +20 -0
  500. package/components/utils.cjs +1 -1
  501. package/components/utils.js +3 -3
  502. package/components/v4-DIjJgmR0.js +49 -0
  503. package/components/venn-diagram-options.config-BZWBYEhB.js +24 -0
  504. package/components/venn-diagram-options.config-BamlR1qo.cjs +20 -0
  505. package/components/venn-diagram-positioning.config-CqO3fp68.cjs +20 -0
  506. package/components/venn-diagram-positioning.config-DwhJGj84.js +55 -0
  507. package/components/venn-diagram-slots.config-CM0HPIPD.js +47 -0
  508. package/components/venn-diagram-slots.config-DYTmU8v2.cjs +20 -0
  509. package/components/video-options.config-BhBpkaLJ.cjs +20 -0
  510. package/components/video-options.config-DWuy1OHa.js +127 -0
  511. package/components/video-slots.config-B_aDlTp6.js +24 -0
  512. package/components/video-slots.config-DMut7o7r.cjs +20 -0
  513. package/components/viz-item-menu/index.cjs +1 -1
  514. package/components/viz-item-menu/index.js +1 -1
  515. package/components/viz-item-menu-6lBtiv3Y.js +170 -0
  516. package/components/viz-item-menu-DpL4Pgjm.cjs +55 -0
  517. package/components/wordcloud-chart-options.config-D041tFDG.js +90 -0
  518. package/components/wordcloud-chart-options.config-DgH4JgN2.cjs +20 -0
  519. package/components/wordcloud-chart-positioning.config-Bp4XE85G.js +55 -0
  520. package/components/wordcloud-chart-positioning.config-ByTxkJHo.cjs +20 -0
  521. package/components/wordcloud-chart-slots.config-Cy-Jgcaq.js +45 -0
  522. package/components/wordcloud-chart-slots.config-V29v2Fhr.cjs +20 -0
  523. package/custom-elements.json +387 -22
  524. package/deprecated-react/components/ai-chat.component.cjs +1 -0
  525. package/deprecated-react/components/ai-interaction-textarea.component.cjs +1 -0
  526. package/deprecated-react/components/data-field-level.component.cjs +1 -0
  527. package/deprecated-react/components/data-field-panel.component.cjs +1 -0
  528. package/deprecated-react/components/data-field.component.cjs +1 -0
  529. package/deprecated-react/components/data-fields-select.component.cjs +1 -0
  530. package/deprecated-react/components/dataset-icon.component.cjs +1 -0
  531. package/deprecated-react/components/dataset-selector-list.component.cjs +1 -0
  532. package/deprecated-react/components/dataset-selector-row.component.cjs +1 -0
  533. package/deprecated-react/components/display-settings-binning.component.cjs +1 -0
  534. package/deprecated-react/components/display-settings-datetime.component.cjs +1 -0
  535. package/deprecated-react/components/display-settings-grand-totals.component.cjs +1 -0
  536. package/deprecated-react/components/display-settings-numeric.component.cjs +1 -0
  537. package/deprecated-react/components/display-settings-period-over-period.component.cjs +1 -0
  538. package/deprecated-react/components/display-settings.component.cjs +1 -0
  539. package/deprecated-react/components/filter-expression-picker.component.cjs +1 -0
  540. package/deprecated-react/components/filter-item.component.cjs +1 -0
  541. package/deprecated-react/components/filter-parameter-picker.component.cjs +1 -0
  542. package/deprecated-react/components/filter-value-picker-datetime.component.cjs +1 -0
  543. package/deprecated-react/components/filter-value-picker-hierarchy.component.cjs +1 -0
  544. package/deprecated-react/components/filter-value-picker-numeric.component.cjs +1 -0
  545. package/deprecated-react/components/filter-value-picker.component.cjs +1 -0
  546. package/deprecated-react/components/filters.component.cjs +1 -0
  547. package/deprecated-react/components/formula-editor.component.cjs +1 -0
  548. package/deprecated-react/components/formula-field.component.cjs +1 -0
  549. package/deprecated-react/components/formula.component.cjs +1 -0
  550. package/deprecated-react/components/interactive-viz-item.component.cjs +1 -0
  551. package/deprecated-react/components/item-grid.component.cjs +1 -0
  552. package/deprecated-react/components/item-option-action-button-group.component.cjs +1 -0
  553. package/deprecated-react/components/item-option-color-palette-picker.component.cjs +1 -0
  554. package/deprecated-react/components/item-option-color-picker.component.cjs +1 -0
  555. package/deprecated-react/components/item-option-color-range.component.cjs +1 -0
  556. package/deprecated-react/components/item-option-multi-language-field.component.cjs +1 -0
  557. package/deprecated-react/components/item-option-number-field.component.cjs +1 -0
  558. package/deprecated-react/components/item-option-panel.component.cjs +1 -0
  559. package/deprecated-react/components/item-option-picker.component.cjs +1 -0
  560. package/deprecated-react/components/item-option-position-picker.component.cjs +1 -0
  561. package/deprecated-react/components/item-option-positions-number-field.component.cjs +1 -0
  562. package/deprecated-react/components/item-option-radio-button-group.component.cjs +1 -0
  563. package/deprecated-react/components/item-option-slider.component.cjs +1 -0
  564. package/deprecated-react/components/item-option-switch.component.cjs +1 -0
  565. package/deprecated-react/components/item-option-text-field.component.cjs +1 -0
  566. package/deprecated-react/components/item-option.component.cjs +1 -0
  567. package/deprecated-react/components/item-slot-drop-panel.component.cjs +1 -0
  568. package/deprecated-react/components/item-slot-drop.component.cjs +1 -0
  569. package/deprecated-react/components/item-slot-picker-panel.component.cjs +1 -0
  570. package/deprecated-react/components/item-slot-picker.component.cjs +1 -0
  571. package/deprecated-react/components/slot-menu-list.component.cjs +1 -0
  572. package/deprecated-react/components/slot-menu.component.cjs +1 -0
  573. package/deprecated-react/components/viz-item-menu.component.cjs +1 -0
  574. package/deprecated-react/index.cjs +2 -0
  575. package/deprecated-react/index.d.ts +2 -0
  576. package/deprecated-react/index.js +2 -0
  577. package/package.json +9 -17
  578. package/react/README.md +29 -72
  579. package/react/components/formula-editor.component.ts +3 -3
  580. package/react/esm/components/formula-editor.component.d.ts +2 -2
  581. package/react/luzmo-stub.d.ts +1 -51
  582. package/react/package.json +35 -0
  583. package/react/tsconfig.json +3 -5
  584. package/types/ai-chat.types.d.ts +5 -0
  585. package/utils/ai-prompt/attachments.d.ts +10 -0
  586. package/utils/ai-prompt/dictation.d.ts +50 -0
  587. package/utils/ai-prompt/image-upload.d.ts +12 -0
  588. package/utils/ai-prompt/index.d.ts +6 -0
  589. package/utils/store/index.d.ts +5 -5
  590. package/utils/store/store-registry.d.ts +1 -1
  591. package/components/ad-hoc-slot-content-BxpvfmjT.js +0 -29
  592. package/components/ad-hoc-slot-content-DJUmB7pS.cjs +0 -20
  593. package/components/ai-chat-BBc330Jm.js +0 -3832
  594. package/components/ai-chat-DLDSaC7W.cjs +0 -300
  595. package/components/ai-interaction-textarea-BCH5_GBO.cjs +0 -68
  596. package/components/ai-interaction-textarea-DzHetSBZ.js +0 -299
  597. package/components/area-chart-options.config-CJYI-zcZ.cjs +0 -20
  598. package/components/area-chart-options.config-CxJWxcD9.js +0 -146
  599. package/components/area-chart-positioning.config-CjeYLy6C.js +0 -55
  600. package/components/area-chart-positioning.config-DVrykBho.cjs +0 -20
  601. package/components/area-chart-slots.config-B56LJaky.cjs +0 -20
  602. package/components/area-chart-slots.config-C22ZF9l0.js +0 -55
  603. package/components/bar-chart-options.config-BAatAyhW.js +0 -220
  604. package/components/bar-chart-options.config-D2a-U6kG.cjs +0 -20
  605. package/components/bar-chart-positioning.config-DpF15KcV.cjs +0 -20
  606. package/components/bar-chart-positioning.config-e-SAdpBe.js +0 -59
  607. package/components/bar-chart-slots.config-BbgFihbK.js +0 -50
  608. package/components/bar-chart-slots.config-CkOVmYcA.cjs +0 -20
  609. package/components/base-DSXeP3BL.cjs +0 -20
  610. package/components/base-a89RuUMb.js +0 -249
  611. package/components/base-store-D0jbv0bE.js +0 -160
  612. package/components/base-store-ab2wBsBE.cjs +0 -20
  613. package/components/box-plot-options.config-BuX2wNhp.js +0 -296
  614. package/components/box-plot-options.config-Di28EvZb.cjs +0 -20
  615. package/components/box-plot-positioning.config-Bq2INEtG.js +0 -48
  616. package/components/box-plot-positioning.config-DbwtHJ4q.cjs +0 -20
  617. package/components/box-plot-slots.config-DL-tTTn9.cjs +0 -20
  618. package/components/box-plot-slots.config-OeublT6p.js +0 -40
  619. package/components/bubble-chart-options.config-C_XQOHgH.js +0 -115
  620. package/components/bubble-chart-options.config-CnpBrIo6.cjs +0 -20
  621. package/components/bubble-chart-positioning.config--EBfDgdN.cjs +0 -20
  622. package/components/bubble-chart-positioning.config-DFnW4mJ9.js +0 -55
  623. package/components/bubble-chart-slots.config-Bdy20Xqs.js +0 -47
  624. package/components/bubble-chart-slots.config-smlOOwcK.cjs +0 -20
  625. package/components/bullet-chart-options.config-6nATAuC3.cjs +0 -20
  626. package/components/bullet-chart-options.config-h5BFyszP.js +0 -75
  627. package/components/bullet-chart-positioning.config-CZ46z07k.cjs +0 -20
  628. package/components/bullet-chart-positioning.config-DS2OmjBY.js +0 -56
  629. package/components/bullet-chart-slots.config-BaTbWYvU.cjs +0 -20
  630. package/components/bullet-chart-slots.config-Cqj3i1qo.js +0 -46
  631. package/components/choropleth-map-options.config-CmtZtBAC.cjs +0 -20
  632. package/components/choropleth-map-options.config-YCo77O3q.js +0 -348
  633. package/components/choropleth-map-positioning.config-Clm5IUT6.cjs +0 -20
  634. package/components/choropleth-map-positioning.config-DgANsGq1.js +0 -55
  635. package/components/choropleth-map-slots.config-ClMcW8wV.cjs +0 -20
  636. package/components/choropleth-map-slots.config-D4vxtdtH.js +0 -53
  637. package/components/circle-pack-chart-options.config-BA_G1sQ8.cjs +0 -20
  638. package/components/circle-pack-chart-options.config-C0cEtjgC.js +0 -54
  639. package/components/circle-pack-chart-positioning.config-2H1CrfH_.js +0 -48
  640. package/components/circle-pack-chart-positioning.config-qF0qGcEO.cjs +0 -20
  641. package/components/circle-pack-chart-slots.config-Dks8K3uQ.js +0 -38
  642. package/components/circle-pack-chart-slots.config-IH2KV7z1.cjs +0 -20
  643. package/components/circular-gauge-options.config-BtP-YDIr.cjs +0 -20
  644. package/components/circular-gauge-options.config-Cdnk-Sp0.js +0 -188
  645. package/components/circular-gauge-positioning.config-CMttD_BW.cjs +0 -20
  646. package/components/circular-gauge-positioning.config-CusKP9Tq.js +0 -48
  647. package/components/circular-gauge-slots.config-B6ajddW-.cjs +0 -20
  648. package/components/circular-gauge-slots.config-Wf4sHmk6.js +0 -39
  649. package/components/color-CXw2IfjN.js +0 -3812
  650. package/components/color-range-utils-u4ziqRRA.js +0 -63
  651. package/components/column-chart-options.config-DoZLlIRM.js +0 -219
  652. package/components/column-chart-options.config-eJ1Cexxe.cjs +0 -20
  653. package/components/column-chart-positioning.config-ColoutIT.cjs +0 -20
  654. package/components/column-chart-positioning.config-rRwPVTbj.js +0 -55
  655. package/components/column-chart-slots.config-BY6y_rvE.cjs +0 -20
  656. package/components/column-chart-slots.config-BhVqSbKw.js +0 -50
  657. package/components/combination-chart-options.config-C3kZ2fpK.cjs +0 -20
  658. package/components/combination-chart-options.config-D7ZXfn61.js +0 -87
  659. package/components/combination-chart-positioning.config-DAVrKW-6.cjs +0 -20
  660. package/components/combination-chart-positioning.config-uLf1RJQr.js +0 -48
  661. package/components/combination-chart-slots.config-CK8YBgUl.js +0 -43
  662. package/components/combination-chart-slots.config-Ciza_y3a.cjs +0 -20
  663. package/components/conditional-number-options.config-BwSMI5Ax.js +0 -205
  664. package/components/conditional-number-options.config-CadHLi0m.cjs +0 -20
  665. package/components/conditional-number-positioning.config-DZjwZfsH.js +0 -48
  666. package/components/conditional-number-positioning.config-Nwsh-WyG.cjs +0 -20
  667. package/components/conditional-number-slots.config-CWX6OuUa.cjs +0 -20
  668. package/components/conditional-number-slots.config-xSNaYD4u.js +0 -39
  669. package/components/convert-data-field-to-slot-content-BQkSy_8B.cjs +0 -20
  670. package/components/data-broker-BH5WDG0j.cjs +0 -20
  671. package/components/data-broker-CVDImE1j.js +0 -1674
  672. package/components/data-field-CFX9bhKN.js +0 -121
  673. package/components/data-field-bRmOqmAe.cjs +0 -54
  674. package/components/data-field-level-Cc6yEETi.js +0 -246
  675. package/components/data-field-level-Dnl27sxs.cjs +0 -55
  676. package/components/data-field-panel-BDExLalA.cjs +0 -87
  677. package/components/data-field-panel-DcqVOzMO.js +0 -385
  678. package/components/data-fields-select-B5aGtDYe.cjs +0 -41
  679. package/components/data-fields-select-CfAfiV-K.js +0 -262
  680. package/components/dataset-icon-BXEgg_8O.js +0 -125
  681. package/components/dataset-selector-list-WT2ZHjQ4.cjs +0 -75
  682. package/components/dataset-selector-list-bAFTW1Hr.js +0 -313
  683. package/components/dataset-selector-row-CXrEKQrA.js +0 -273
  684. package/components/dataset-selector-row-CwkXH93E.cjs +0 -79
  685. package/components/date-comparison-filter-options.config--clPxHFt.cjs +0 -20
  686. package/components/date-comparison-filter-options.config-DCCm5Adt.js +0 -126
  687. package/components/date-comparison-filter-slots.config-KO9B0lfS.cjs +0 -20
  688. package/components/date-comparison-filter-slots.config-s7FcuKia.js +0 -33
  689. package/components/date-filter-options.config-BdNFe-Ds.cjs +0 -20
  690. package/components/date-filter-options.config-DBwcMXzp.js +0 -118
  691. package/components/date-filter-slots.config-BrQoD-EF.cjs +0 -20
  692. package/components/date-filter-slots.config-pbd3rG9z.js +0 -37
  693. package/components/de-DqwsqE-U.js +0 -478
  694. package/components/de-tUSOg_BJ.cjs +0 -20
  695. package/components/decorate-CaYbmmmm.js +0 -28
  696. package/components/display-settings-DrcpHnKo.cjs +0 -140
  697. package/components/display-settings-Ec_smyRC.js +0 -313
  698. package/components/display-settings-binning-COpQPUin.js +0 -110
  699. package/components/display-settings-binning-XXJdJeGU.cjs +0 -56
  700. package/components/display-settings-datetime-DhSW10ln.cjs +0 -217
  701. package/components/display-settings-datetime-qj86dnHh.js +0 -413
  702. package/components/display-settings-grand-totals-D6IDs0U1.js +0 -89
  703. package/components/display-settings-grand-totals-DTF0sqA1.cjs +0 -44
  704. package/components/display-settings-numeric-Dt34JHyR.cjs +0 -190
  705. package/components/display-settings-numeric-Dy2EMcKa.js +0 -479
  706. package/components/display-settings-period-over-period-B-ULI6yW.cjs +0 -229
  707. package/components/display-settings-period-over-period-BMzBnywY.js +0 -433
  708. package/components/donut-chart-options.config-Buas8fzJ.js +0 -207
  709. package/components/donut-chart-options.config-K-HkE7sL.cjs +0 -20
  710. package/components/donut-chart-positioning.config-BnmePhBH.cjs +0 -20
  711. package/components/donut-chart-positioning.config-CnZRc3e8.js +0 -48
  712. package/components/donut-chart-slots.config-CZWRHxZe.js +0 -39
  713. package/components/donut-chart-slots.config-RxPnpO6M.cjs +0 -20
  714. package/components/dropdown-filter-options.config-B-Vvy0Nq.cjs +0 -20
  715. package/components/dropdown-filter-options.config-gv1y1OkC.js +0 -153
  716. package/components/dropdown-filter-slots.config-BBZChIHC.cjs +0 -20
  717. package/components/dropdown-filter-slots.config-aP5hvp2K.js +0 -38
  718. package/components/en-B34alchz.cjs +0 -20
  719. package/components/en-GB-B3xz84vF.cjs +0 -20
  720. package/components/en-US-B34alchz.cjs +0 -20
  721. package/components/es-C-5Yqnck.js +0 -478
  722. package/components/es-Czecz2xB.cjs +0 -20
  723. package/components/evolution-number-options.config-B1IomzV1.js +0 -228
  724. package/components/evolution-number-options.config-Bt1FZqqQ.cjs +0 -20
  725. package/components/evolution-number-positioning.config-CKgGLWTm.cjs +0 -20
  726. package/components/evolution-number-positioning.config-DiKxJqRO.js +0 -48
  727. package/components/evolution-number-slots.config-CYxdcD-x.cjs +0 -20
  728. package/components/evolution-number-slots.config-eOQDWZyb.js +0 -37
  729. package/components/filter-expression-picker-DMZ4sgJ6.js +0 -425
  730. package/components/filter-expression-picker-Dq0X2lo3.cjs +0 -38
  731. package/components/filter-item-BEe-Y6l0.js +0 -242
  732. package/components/filter-item-BnxKP0Zg.cjs +0 -58
  733. package/components/filter-value-picker-BxaX9BML.cjs +0 -60
  734. package/components/filter-value-picker-datetime-BryAsOYH.cjs +0 -42
  735. package/components/filter-value-picker-datetime-DtZDr9fY.js +0 -139
  736. package/components/filter-value-picker-hierarchy-BSKoZJ0F.cjs +0 -47
  737. package/components/filter-value-picker-hierarchy-D9BcuttQ.js +0 -232
  738. package/components/filter-value-picker-numeric-B2EcfNUR.cjs +0 -48
  739. package/components/filter-value-picker-numeric-CoU9l9wS.js +0 -219
  740. package/components/filter-value-picker-r1zs2IHx.js +0 -151
  741. package/components/filters-C9DVFS6T.cjs +0 -150
  742. package/components/filters-DVTYmlI1.js +0 -400
  743. package/components/formatter-8m-wrIM-.cjs +0 -20
  744. package/components/formula--lwYaW2w.cjs +0 -45
  745. package/components/formula-Ekyv6mpo.js +0 -138
  746. package/components/formula-codemirror-BZuBN5sE.cjs +0 -215
  747. package/components/formula-codemirror-DgTmL2Id.js +0 -11973
  748. package/components/formula-display-store-BunPLkc0.cjs +0 -20
  749. package/components/formula-display-store-ezef6EvF.js +0 -1090
  750. package/components/formula-editor-CjVohoJB.cjs +0 -218
  751. package/components/formula-editor-DRpm9ej7.js +0 -666
  752. package/components/formula-field-DcgWLGBD.cjs +0 -20
  753. package/components/formula-field-TwMnyN0t.js +0 -40
  754. package/components/formula-input-base-D6QdnUOa.cjs +0 -49
  755. package/components/formula-input-base-Dxk5euNb.js +0 -236
  756. package/components/fr-BvgQLvx5.js +0 -478
  757. package/components/fr-CQyhQN6j.cjs +0 -20
  758. package/components/funnel-chart-options.config-BAIgb6x9.cjs +0 -20
  759. package/components/funnel-chart-options.config-DAv3185m.js +0 -187
  760. package/components/funnel-chart-positioning.config-DaHDyj7V.cjs +0 -20
  761. package/components/funnel-chart-positioning.config-DysRV01G.js +0 -48
  762. package/components/funnel-chart-slots.config-BsNj6Mbb.js +0 -43
  763. package/components/funnel-chart-slots.config-CSI5mdma.cjs +0 -20
  764. package/components/get-css-variable-B1BZoBcs.cjs +0 -20
  765. package/components/get-css-variable-COcan5CX.js +0 -63
  766. package/components/get-dataset-name-D4smY8ms.cjs +0 -20
  767. package/components/get-dataset-name-D_ZiWu64.js +0 -27
  768. package/components/groupings-Bzp2EA65.js +0 -52
  769. package/components/groupings-Wfp8piEu.cjs +0 -20
  770. package/components/heat-map-options.config-Ckw8voNV.js +0 -224
  771. package/components/heat-map-options.config-Ct-93RVQ.cjs +0 -20
  772. package/components/heat-map-positioning.config-C6CqosaH.js +0 -48
  773. package/components/heat-map-positioning.config-hFwq08ML.cjs +0 -20
  774. package/components/heat-map-slots.config-BFK5TF9k.js +0 -37
  775. package/components/heat-map-slots.config-D0mwjImu.cjs +0 -20
  776. package/components/heat-table-options.config-7IS5wa9l.cjs +0 -20
  777. package/components/heat-table-options.config-PpOf4o94.js +0 -372
  778. package/components/heat-table-positioning.config-B2RuWLH5.js +0 -55
  779. package/components/heat-table-positioning.config-MJ_ox9iT.cjs +0 -20
  780. package/components/heat-table-slots.config-3q2hG4nF.js +0 -49
  781. package/components/heat-table-slots.config-CH6Q9203.cjs +0 -20
  782. package/components/hexbin-map-options.config-CUAv6zuD.cjs +0 -20
  783. package/components/hexbin-map-options.config-D88DHYrl.js +0 -276
  784. package/components/hexbin-map-positioning.config-Dua5Z8M2.cjs +0 -20
  785. package/components/hexbin-map-positioning.config-IiGTpp68.js +0 -48
  786. package/components/hexbin-map-slots.config-BdkQVzI7.cjs +0 -20
  787. package/components/hexbin-map-slots.config-BfbHCCUe.js +0 -37
  788. package/components/image-options.config-ByIPpr29.js +0 -153
  789. package/components/image-options.config-DXqA7sAa.cjs +0 -20
  790. package/components/image-slots.config-B4MFjNWt.js +0 -24
  791. package/components/image-slots.config-DprzKxj3.cjs +0 -20
  792. package/components/interactive-viz-item-O2zj8Ix3.cjs +0 -247
  793. package/components/interactive-viz-item-lBrlvX4F.js +0 -693
  794. package/components/item-grid-CmuMl0eC.cjs +0 -113
  795. package/components/item-grid-Cqi995vx.js +0 -4559
  796. package/components/item-option-CQw6Xsi2.cjs +0 -252
  797. package/components/item-option-Cg3zRKlU.js +0 -969
  798. package/components/item-option-action-button-group-C1TU-ng7.js +0 -118
  799. package/components/item-option-action-button-group-DBdpU9Ac.cjs +0 -53
  800. package/components/item-option-base-4mpxvTpE.js +0 -123
  801. package/components/item-option-base-BtYcXg-E.cjs +0 -56
  802. package/components/item-option-color-palette-picker-4so22U-2.cjs +0 -40
  803. package/components/item-option-color-palette-picker-BBnhEOQj.js +0 -2041
  804. package/components/item-option-color-picker-CTTEHFVR.js +0 -87
  805. package/components/item-option-color-picker-CUBaIdL-.cjs +0 -34
  806. package/components/item-option-color-range-BuLEgB7a.js +0 -220
  807. package/components/item-option-color-range-H4nV-HoV.cjs +0 -98
  808. package/components/item-option-multi-language-field-CXQj3kSW.js +0 -82
  809. package/components/item-option-multi-language-field-d25tETIC.cjs +0 -33
  810. package/components/item-option-number-field-CEQEjnu8.js +0 -102
  811. package/components/item-option-number-field-waG1zcr8.cjs +0 -38
  812. package/components/item-option-panel-Bh4d0Ueb.cjs +0 -67
  813. package/components/item-option-panel-CVjT-rr8.js +0 -183
  814. package/components/item-option-picker-CiEMwzho.js +0 -77
  815. package/components/item-option-picker-YTJ6noOW.cjs +0 -37
  816. package/components/item-option-position-picker-DExAtVBF.cjs +0 -32
  817. package/components/item-option-position-picker-DVsG8inN.js +0 -117
  818. package/components/item-option-positions-number-field-7F1_3pxp.js +0 -164
  819. package/components/item-option-positions-number-field-Ju4e_B6g.cjs +0 -49
  820. package/components/item-option-radio-button-group-6w11UJC-.cjs +0 -37
  821. package/components/item-option-radio-button-group-CHZKF_oZ.js +0 -74
  822. package/components/item-option-slider-CQCvF7wI.js +0 -81
  823. package/components/item-option-slider-DdkgydGa.cjs +0 -33
  824. package/components/item-option-switch-68EoGXKU.js +0 -69
  825. package/components/item-option-switch-IP4wvB7i.cjs +0 -30
  826. package/components/item-option-text-field-0CCtgD5i.js +0 -80
  827. package/components/item-option-text-field-Be4frWhI.cjs +0 -33
  828. package/components/item-slot-drop-C7BJJcZz.cjs +0 -91
  829. package/components/item-slot-drop-PlCmap_s.js +0 -331
  830. package/components/item-slot-drop-panel-BevGCcMh.js +0 -355
  831. package/components/item-slot-drop-panel-hs0gFwb-.cjs +0 -57
  832. package/components/item-slot-picker-BzXlX-Zd.js +0 -505
  833. package/components/item-slot-picker-dmoR1ZyZ.cjs +0 -174
  834. package/components/item-slot-picker-panel-B2TtJUIs.cjs +0 -81
  835. package/components/item-slot-picker-panel-DnvwcLGy.js +0 -448
  836. package/components/line-chart-options.config-DKQ1k4lg.cjs +0 -20
  837. package/components/line-chart-options.config-DMjvCs-4.js +0 -168
  838. package/components/line-chart-positioning.config-CYqzjNzS.cjs +0 -20
  839. package/components/line-chart-positioning.config-DAs0y-O6.js +0 -55
  840. package/components/line-chart-slots.config-Cjp4btvG.cjs +0 -20
  841. package/components/line-chart-slots.config-CrQEwa4W.js +0 -55
  842. package/components/load-data-fields-for-datasets-BVGaku2J.cjs +0 -20
  843. package/components/load-data-fields-for-datasets-DeXLqWt4.js +0 -42
  844. package/components/localized-mixin-BNAt_iYb.cjs +0 -20
  845. package/components/localized-mixin-GXZQgVAD.js +0 -45
  846. package/components/marker-map-options.config-C52a3boH.js +0 -117
  847. package/components/marker-map-options.config-DBPPcGN4.cjs +0 -20
  848. package/components/marker-map-positioning.config-BQ-kNUJI.js +0 -48
  849. package/components/marker-map-positioning.config-C5h5ydGa.cjs +0 -20
  850. package/components/marker-map-slots.config-BOQ8AwRv.cjs +0 -20
  851. package/components/marker-map-slots.config-eJAxjIaQ.js +0 -37
  852. package/components/nl-BwK5iXtO.cjs +0 -20
  853. package/components/nl-D-Wa6DnD.js +0 -478
  854. package/components/ohlc-chart-options.config-38qB2VKc.js +0 -65
  855. package/components/ohlc-chart-options.config-D9h-VLdq.cjs +0 -20
  856. package/components/ohlc-chart-positioning.config-BQyRY4rj.js +0 -78
  857. package/components/ohlc-chart-positioning.config-fqniDSHf.cjs +0 -20
  858. package/components/ohlc-chart-slots.config-CUBUexI-.cjs +0 -20
  859. package/components/ohlc-chart-slots.config-SOs4oD-Q.js +0 -68
  860. package/components/parallel-coordinates-plot-options.config-DfZ80jLX.js +0 -42
  861. package/components/parallel-coordinates-plot-options.config-ovgY0A7j.cjs +0 -20
  862. package/components/parallel-coordinates-plot-positioning.config-Bhyk-q40.cjs +0 -20
  863. package/components/parallel-coordinates-plot-positioning.config-DMUrvTKC.js +0 -48
  864. package/components/parallel-coordinates-plot-slots.config-BXZ-NmbH.cjs +0 -20
  865. package/components/parallel-coordinates-plot-slots.config-DgsHiCqT.js +0 -46
  866. package/components/pivot-table-options.config-5udtucDD.js +0 -245
  867. package/components/pivot-table-options.config-BxKo1DCU.cjs +0 -20
  868. package/components/pivot-table-positioning.config-CRPJ6cp9.cjs +0 -20
  869. package/components/pivot-table-positioning.config-kgOD7qg4.js +0 -55
  870. package/components/pivot-table-slots.config-CRL6EW5R.js +0 -55
  871. package/components/pivot-table-slots.config-VxbOGtmB.cjs +0 -20
  872. package/components/pragmatic-element-adapter-U3ppsQDe.cjs +0 -24
  873. package/components/pragmatic-element-adapter-e5LbH_lv.js +0 -1252
  874. package/components/pyramid-chart-options.config-iP2MzTeb.js +0 -240
  875. package/components/pyramid-chart-options.config-lioHQSoq.cjs +0 -20
  876. package/components/pyramid-chart-positioning.config-B3g4J0Fc.cjs +0 -20
  877. package/components/pyramid-chart-positioning.config-DzmnUNOa.js +0 -55
  878. package/components/pyramid-chart-slots.config-CN_Q2YsP.cjs +0 -20
  879. package/components/pyramid-chart-slots.config-DM3lYlDg.js +0 -50
  880. package/components/radar-chart-options.config-DhnoFEzo.cjs +0 -20
  881. package/components/radar-chart-options.config-aR5sQal-.js +0 -130
  882. package/components/radar-chart-positioning.config-DeMZx8WU.cjs +0 -20
  883. package/components/radar-chart-positioning.config-DtCHigcZ.js +0 -55
  884. package/components/radar-chart-slots.config-BISYnTom.cjs +0 -20
  885. package/components/radar-chart-slots.config-msW05r4n.js +0 -53
  886. package/components/regular-table-options.config-Bk6CBPgj.cjs +0 -20
  887. package/components/regular-table-options.config-kbARlJ1E.js +0 -148
  888. package/components/regular-table-slots.config-BU6Ff96U.cjs +0 -20
  889. package/components/regular-table-slots.config-DAwLOM5T.js +0 -35
  890. package/components/route-map-options.config-CAi93e7I.cjs +0 -20
  891. package/components/route-map-options.config-DCBAfq09.js +0 -326
  892. package/components/route-map-positioning.config-CNNkOriH.js +0 -66
  893. package/components/route-map-positioning.config-GRnTnxOT.cjs +0 -20
  894. package/components/route-map-slots.config-DNiRtoRC.js +0 -59
  895. package/components/route-map-slots.config-Dznp0DT3.cjs +0 -20
  896. package/components/sankey-diagram-options.config-CKjVnYnF.js +0 -126
  897. package/components/sankey-diagram-options.config-D7ZrZV0g.cjs +0 -20
  898. package/components/sankey-diagram-positioning.config-B4dTAI_t.cjs +0 -20
  899. package/components/sankey-diagram-positioning.config-DZzxWrlG.js +0 -66
  900. package/components/sankey-diagram-slots.config-CVD2P6RJ.js +0 -61
  901. package/components/sankey-diagram-slots.config-TKCUvHOD.cjs +0 -20
  902. package/components/scatter-plot-options.config--AfAxaGf.js +0 -302
  903. package/components/scatter-plot-options.config-DXqKb34r.cjs +0 -20
  904. package/components/scatter-plot-positioning.config-7DccAqx9.js +0 -77
  905. package/components/scatter-plot-positioning.config-CUxiLfKj.cjs +0 -20
  906. package/components/scatter-plot-slots.config-CPsk9FUg.cjs +0 -20
  907. package/components/scatter-plot-slots.config-D57rd66g.js +0 -74
  908. package/components/search-filter-options.config-DQwMOiXm.js +0 -103
  909. package/components/search-filter-options.config-DojMfRR_.cjs +0 -20
  910. package/components/search-filter-slots.config-AhwsTdYC.cjs +0 -20
  911. package/components/search-filter-slots.config-DQybwP4H.js +0 -39
  912. package/components/set-locale-BCnD4yp_.cjs +0 -20
  913. package/components/set-locale-CamOWu7o.js +0 -43
  914. package/components/slicer-filter-options.config-BhLn4U1W.cjs +0 -20
  915. package/components/slicer-filter-options.config-DVE33GEz.js +0 -226
  916. package/components/slicer-filter-positioning.config-DUivNE2P.cjs +0 -20
  917. package/components/slicer-filter-positioning.config-aOkoNRyY.js +0 -48
  918. package/components/slicer-filter-slots.config-Bcz9RsdR.js +0 -44
  919. package/components/slicer-filter-slots.config-zV15NWWS.cjs +0 -20
  920. package/components/slider-filter-options.config-B8am9mmE.cjs +0 -20
  921. package/components/slider-filter-options.config-BwaAvOvt.js +0 -72
  922. package/components/slider-filter-slots.config-Bc8Qk7fb.js +0 -43
  923. package/components/slider-filter-slots.config-D9Hra0zE.cjs +0 -20
  924. package/components/slot-menu-Bgoo0gWv.cjs +0 -71
  925. package/components/slot-menu-Cb8piPji.js +0 -422
  926. package/components/slot-menu-list-Cy6tegSf.cjs +0 -44
  927. package/components/slot-menu-list-VuVIRNtr.js +0 -346
  928. package/components/slot-role-classification-Bvt3bI01.cjs +0 -20
  929. package/components/slot-role-classification-CCzj4WgN.js +0 -133
  930. package/components/slots-config-P_GXW0tl.js +0 -77
  931. package/components/slots-config-YdyClHLc.cjs +0 -20
  932. package/components/speedometer-chart-options.config-D4-8n5pn.js +0 -246
  933. package/components/speedometer-chart-options.config-DEW_D9w1.cjs +0 -20
  934. package/components/speedometer-chart-positioning.config-Dj6XK0gq.js +0 -48
  935. package/components/speedometer-chart-positioning.config-DzCh70X-.cjs +0 -20
  936. package/components/speedometer-chart-slots.config-1BqQZ2vP.cjs +0 -20
  937. package/components/speedometer-chart-slots.config-B4zqf0f_.js +0 -39
  938. package/components/spike-map-options.config-CM46vw7B.js +0 -413
  939. package/components/spike-map-options.config-LPAyKMHe.cjs +0 -20
  940. package/components/spike-map-positioning.config-BG2pKkf7.js +0 -55
  941. package/components/spike-map-positioning.config-BQIg4Z0U.cjs +0 -20
  942. package/components/spike-map-slots.config-B7OehIoc.cjs +0 -20
  943. package/components/spike-map-slots.config-BeXzuzh0.js +0 -47
  944. package/components/strip-plot-options.config-BlneYJOy.js +0 -53
  945. package/components/strip-plot-options.config-vBd38UQs.cjs +0 -20
  946. package/components/strip-plot-positioning.config-D3ZNgtC4.cjs +0 -20
  947. package/components/strip-plot-positioning.config-HZCVc6kX.js +0 -48
  948. package/components/strip-plot-slots.config-BGQIQtMK.js +0 -38
  949. package/components/strip-plot-slots.config-CAU0z3q4.cjs +0 -20
  950. package/components/sunburst-chart-options.config-8xopRyBB.js +0 -160
  951. package/components/sunburst-chart-options.config-CUFOuT2J.cjs +0 -20
  952. package/components/sunburst-chart-positioning.config-0O9eMweg.js +0 -48
  953. package/components/sunburst-chart-positioning.config-B-hCz3bI.cjs +0 -20
  954. package/components/sunburst-chart-slots.config-BCNUNkd9.cjs +0 -20
  955. package/components/sunburst-chart-slots.config-BhKeTqTo.js +0 -38
  956. package/components/symbol-map-options.config-CR07hvK0.cjs +0 -20
  957. package/components/symbol-map-options.config-nJAvVQIh.js +0 -157
  958. package/components/symbol-map-positioning.config-Dod98HkQ.js +0 -55
  959. package/components/symbol-map-positioning.config-aHnkaWU6.cjs +0 -20
  960. package/components/symbol-map-slots.config-D9E-oBE4.js +0 -53
  961. package/components/symbol-map-slots.config-Dz_tor5P.cjs +0 -20
  962. package/components/text-options.config-DCF3IVzO.js +0 -67
  963. package/components/text-options.config-JI2D64hs.cjs +0 -20
  964. package/components/text-slots.config-0A6csMfd.cjs +0 -20
  965. package/components/text-slots.config-C60nJ0OX.js +0 -24
  966. package/components/treemap-chart-options.config-RFQTphEG.js +0 -184
  967. package/components/treemap-chart-options.config-p21eSXKG.cjs +0 -20
  968. package/components/treemap-chart-positioning.config-XB1_FmX-.js +0 -55
  969. package/components/treemap-chart-positioning.config-qhPL49um.cjs +0 -20
  970. package/components/treemap-chart-slots.config-BJqqnUEF.cjs +0 -20
  971. package/components/treemap-chart-slots.config-CZRP7PZH.js +0 -47
  972. package/components/utils-B1BzV2xl.cjs +0 -20
  973. package/components/utils-BMOxXnnX.js +0 -240
  974. package/components/v4-BK7K-jy_.js +0 -49
  975. package/components/validate-CJkVJaL1.cjs +0 -20
  976. package/components/validate-J3P0rm_n.js +0 -28
  977. package/components/venn-diagram-options.config-EmRhf40r.cjs +0 -20
  978. package/components/venn-diagram-options.config-uCJ5dei5.js +0 -24
  979. package/components/venn-diagram-positioning.config-Bh1ypVKP.js +0 -55
  980. package/components/venn-diagram-positioning.config-CimHfhlV.cjs +0 -20
  981. package/components/venn-diagram-slots.config-DOljH_uI.js +0 -47
  982. package/components/venn-diagram-slots.config-MpkJTf5q.cjs +0 -20
  983. package/components/video-options.config-Dh_lU4c1.cjs +0 -20
  984. package/components/video-options.config-DkLrX1gP.js +0 -127
  985. package/components/video-slots.config-Bmh6mcUv.cjs +0 -20
  986. package/components/video-slots.config-CqMIkttE.js +0 -24
  987. package/components/viz-item-menu-CTPd7QMx.cjs +0 -55
  988. package/components/viz-item-menu-sOvrO3Ku.js +0 -170
  989. package/components/wordcloud-chart-options.config-C2ZILp7a.js +0 -90
  990. package/components/wordcloud-chart-options.config-mx2CbmrI.cjs +0 -20
  991. package/components/wordcloud-chart-positioning.config-BR_g8Now.cjs +0 -20
  992. package/components/wordcloud-chart-positioning.config-CmakCQG0.js +0 -55
  993. package/components/wordcloud-chart-slots.config-B8s8B47F.js +0 -45
  994. package/components/wordcloud-chart-slots.config-C303nwAz.cjs +0 -20
  995. package/react/components/ai-chat/empty-state/index.ts +0 -1
  996. package/react/components/ai-chat/empty-state/types.ts +0 -16
  997. package/react/components/ai-chat/stream/index.ts +0 -1
  998. package/react/components/ai-chat/stream/types.ts +0 -60
  999. package/react/components/ai-interaction-textarea/index.ts +0 -1
  1000. package/react/components/ai-interaction-textarea/types.ts +0 -6
  1001. package/react/components/data-field/index.ts +0 -1
  1002. package/react/components/data-field/types.ts +0 -5
  1003. package/react/components/data-field-panel/index.ts +0 -1
  1004. package/react/components/data-field-panel/types.ts +0 -27
  1005. package/react/components/data-fields-select/index.ts +0 -1
  1006. package/react/components/data-fields-select/types.ts +0 -5
  1007. package/react/components/dataset-icon/index.ts +0 -1
  1008. package/react/components/dataset-icon/types.ts +0 -8
  1009. package/react/components/display-settings/index.ts +0 -1
  1010. package/react/components/display-settings/types.ts +0 -12
  1011. package/react/components/filters/index.ts +0 -1
  1012. package/react/components/filters/types.ts +0 -15
  1013. package/react/components/formula-draggable-field/index.ts +0 -1
  1014. package/react/components/formula-draggable-field/types.ts +0 -26
  1015. package/react/components/interactive-viz-item/index.ts +0 -1
  1016. package/react/components/interactive-viz-item/types.ts +0 -122
  1017. package/react/components/item-grid/index.ts +0 -1
  1018. package/react/components/item-grid/types.ts +0 -64
  1019. package/react/components/item-option/index.ts +0 -1
  1020. package/react/components/item-option/types.ts +0 -10
  1021. package/react/components/item-slot-drop/index.ts +0 -1
  1022. package/react/components/item-slot-drop/types.ts +0 -6
  1023. package/react/components/slot-menu/index.ts +0 -1
  1024. package/react/components/slot-menu/types.ts +0 -29
  1025. package/react/components/viz-item-menu/index.ts +0 -1
  1026. package/react/components/viz-item-menu/types.ts +0 -11
  1027. package/react/esm/components/ai-chat/empty-state/index.d.ts +0 -1
  1028. package/react/esm/components/ai-chat/empty-state/index.js +0 -1
  1029. package/react/esm/components/ai-chat/empty-state/types.d.ts +0 -14
  1030. package/react/esm/components/ai-chat/stream/index.d.ts +0 -1
  1031. package/react/esm/components/ai-chat/stream/index.js +0 -1
  1032. package/react/esm/components/ai-chat/stream/types.d.ts +0 -55
  1033. package/react/esm/components/ai-interaction-textarea/index.d.ts +0 -1
  1034. package/react/esm/components/ai-interaction-textarea/index.js +0 -1
  1035. package/react/esm/components/ai-interaction-textarea/types.d.ts +0 -5
  1036. package/react/esm/components/data-field/index.d.ts +0 -1
  1037. package/react/esm/components/data-field/index.js +0 -1
  1038. package/react/esm/components/data-field/types.d.ts +0 -4
  1039. package/react/esm/components/data-field/types.js +0 -1
  1040. package/react/esm/components/data-field-panel/index.d.ts +0 -1
  1041. package/react/esm/components/data-field-panel/index.js +0 -1
  1042. package/react/esm/components/data-field-panel/types.d.ts +0 -27
  1043. package/react/esm/components/data-field-panel/types.js +0 -1
  1044. package/react/esm/components/data-fields-select/index.d.ts +0 -1
  1045. package/react/esm/components/data-fields-select/index.js +0 -1
  1046. package/react/esm/components/data-fields-select/types.d.ts +0 -4
  1047. package/react/esm/components/data-fields-select/types.js +0 -1
  1048. package/react/esm/components/dataset-icon/index.d.ts +0 -1
  1049. package/react/esm/components/dataset-icon/index.js +0 -1
  1050. package/react/esm/components/dataset-icon/types.d.ts +0 -11
  1051. package/react/esm/components/dataset-icon/types.js +0 -1
  1052. package/react/esm/components/display-settings/index.d.ts +0 -1
  1053. package/react/esm/components/display-settings/index.js +0 -1
  1054. package/react/esm/components/display-settings/types.d.ts +0 -9
  1055. package/react/esm/components/display-settings/types.js +0 -1
  1056. package/react/esm/components/filters/index.d.ts +0 -1
  1057. package/react/esm/components/filters/index.js +0 -1
  1058. package/react/esm/components/filters/types.d.ts +0 -12
  1059. package/react/esm/components/filters/types.js +0 -1
  1060. package/react/esm/components/formula-draggable-field/index.d.ts +0 -1
  1061. package/react/esm/components/formula-draggable-field/index.js +0 -1
  1062. package/react/esm/components/formula-draggable-field/types.d.ts +0 -24
  1063. package/react/esm/components/formula-draggable-field/types.js +0 -1
  1064. package/react/esm/components/interactive-viz-item/index.d.ts +0 -1
  1065. package/react/esm/components/interactive-viz-item/index.js +0 -1
  1066. package/react/esm/components/interactive-viz-item/types.d.ts +0 -117
  1067. package/react/esm/components/interactive-viz-item/types.js +0 -16
  1068. package/react/esm/components/item-grid/index.d.ts +0 -1
  1069. package/react/esm/components/item-grid/index.js +0 -1
  1070. package/react/esm/components/item-grid/types.d.ts +0 -57
  1071. package/react/esm/components/item-grid/types.js +0 -1
  1072. package/react/esm/components/item-option/index.d.ts +0 -1
  1073. package/react/esm/components/item-option/index.js +0 -1
  1074. package/react/esm/components/item-option/types.d.ts +0 -8
  1075. package/react/esm/components/item-option/types.js +0 -1
  1076. package/react/esm/components/item-slot-drop/index.d.ts +0 -1
  1077. package/react/esm/components/item-slot-drop/index.js +0 -1
  1078. package/react/esm/components/item-slot-drop/types.d.ts +0 -5
  1079. package/react/esm/components/item-slot-drop/types.js +0 -1
  1080. package/react/esm/components/slot-menu/index.d.ts +0 -1
  1081. package/react/esm/components/slot-menu/index.js +0 -1
  1082. package/react/esm/components/slot-menu/types.d.ts +0 -24
  1083. package/react/esm/components/slot-menu/types.js +0 -1
  1084. package/react/esm/components/viz-item-menu/index.d.ts +0 -1
  1085. package/react/esm/components/viz-item-menu/index.js +0 -1
  1086. package/react/esm/components/viz-item-menu/types.d.ts +0 -9
  1087. package/react/esm/components/viz-item-menu/types.js +0 -1
  1088. package/react/esm/types.d.ts +0 -30
  1089. package/react/esm/types.js +0 -8
  1090. package/react/types.ts +0 -55
  1091. package/react/utils/base/base.d.ts +0 -16
  1092. package/react/utils/base/focus-visible.d.ts +0 -29
  1093. package/react/utils/base/focusable.d.ts +0 -58
  1094. package/react/utils/base/index.d.ts +0 -5
  1095. package/react/utils/base/localized-mixin.d.ts +0 -22
  1096. package/react/utils/base/sized-mixin.d.ts +0 -17
  1097. package/react/utils/color/color-palettes.d.ts +0 -17
  1098. package/react/utils/color/extrapolate-color.d.ts +0 -1
  1099. package/react/utils/data/load-data-fields-for-datasets.d.ts +0 -22
  1100. package/react/utils/data-broker/index.d.ts +0 -257
  1101. package/react/utils/data-field-types/calculate-data-field-icon.d.ts +0 -12
  1102. package/react/utils/data-field-types/default-acceptable-data-field-types.d.ts +0 -1
  1103. package/react/utils/data-field-types/tests/calculate-data-field-icon.test.d.ts +0 -1
  1104. package/react/utils/drag/draggable.d.ts +0 -13
  1105. package/react/utils/drag/pragmatic-element-adapter.d.ts +0 -2
  1106. package/react/utils/drag/tests/pragmatic-element-adapter.first-import.test.d.ts +0 -1
  1107. package/react/utils/drag/tests/pragmatic-element-adapter.test.d.ts +0 -1
  1108. package/react/utils/filters/expressions.d.ts +0 -15
  1109. package/react/utils/filters/index.d.ts +0 -1
  1110. package/react/utils/formatter/calculate-duration.d.ts +0 -2
  1111. package/react/utils/formatter/decompose-numeric-format.d.ts +0 -11
  1112. package/react/utils/formatter/default-local-formats.d.ts +0 -20
  1113. package/react/utils/formatter/formats/cs.d.ts +0 -20
  1114. package/react/utils/formatter/formats/da.d.ts +0 -20
  1115. package/react/utils/formatter/formats/de.d.ts +0 -21
  1116. package/react/utils/formatter/formats/en-GB.d.ts +0 -21
  1117. package/react/utils/formatter/formats/en-US.d.ts +0 -1
  1118. package/react/utils/formatter/formats/en.d.ts +0 -1
  1119. package/react/utils/formatter/formats/es.d.ts +0 -54
  1120. package/react/utils/formatter/formats/fi.d.ts +0 -20
  1121. package/react/utils/formatter/formats/fr.d.ts +0 -54
  1122. package/react/utils/formatter/formats/he.d.ts +0 -20
  1123. package/react/utils/formatter/formats/hu.d.ts +0 -20
  1124. package/react/utils/formatter/formats/it.d.ts +0 -54
  1125. package/react/utils/formatter/formats/ja.d.ts +0 -20
  1126. package/react/utils/formatter/formats/ko.d.ts +0 -20
  1127. package/react/utils/formatter/formats/mk.d.ts +0 -20
  1128. package/react/utils/formatter/formats/nl.d.ts +0 -21
  1129. package/react/utils/formatter/formats/no.d.ts +0 -21
  1130. package/react/utils/formatter/formats/pl.d.ts +0 -20
  1131. package/react/utils/formatter/formats/pt.d.ts +0 -20
  1132. package/react/utils/formatter/formats/ru.d.ts +0 -20
  1133. package/react/utils/formatter/formats/sv.d.ts +0 -20
  1134. package/react/utils/formatter/formats/tr.d.ts +0 -21
  1135. package/react/utils/formatter/formats/zh-CN.d.ts +0 -20
  1136. package/react/utils/formatter/formats/zh-TW.d.ts +0 -20
  1137. package/react/utils/formatter/formatter.d.ts +0 -9
  1138. package/react/utils/formatter/get-dataset-name.d.ts +0 -2
  1139. package/react/utils/formatter/localize.d.ts +0 -3
  1140. package/react/utils/formatter/smart-datetime-formats.const.d.ts +0 -36
  1141. package/react/utils/formatter/tests/calculate-duration.test.d.ts +0 -1
  1142. package/react/utils/formatter/tests/decompose-numeric-format.test.d.ts +0 -1
  1143. package/react/utils/formatter/tests/default-local-formats.test.d.ts +0 -1
  1144. package/react/utils/formatter/tests/formatter.test.d.ts +0 -1
  1145. package/react/utils/formatter/tests/localize.test.d.ts +0 -1
  1146. package/react/utils/formula/base/formula-base.d.ts +0 -117
  1147. package/react/utils/formula/base/formula-input-base.d.ts +0 -62
  1148. package/react/utils/formula/codemirror/actions.d.ts +0 -47
  1149. package/react/utils/formula/codemirror/drop-cursor.d.ts +0 -15
  1150. package/react/utils/formula/codemirror/icon-element.d.ts +0 -7
  1151. package/react/utils/formula/codemirror/parser.d.ts +0 -16
  1152. package/react/utils/formula/codemirror/tests/actions.test.d.ts +0 -1
  1153. package/react/utils/formula/codemirror/theme.d.ts +0 -20
  1154. package/react/utils/formula/codemirror/widget.d.ts +0 -18
  1155. package/react/utils/formula/config/aggregations.d.ts +0 -9
  1156. package/react/utils/formula/config/build-datasets.d.ts +0 -10
  1157. package/react/utils/formula/config/expression-helpers.d.ts +0 -42
  1158. package/react/utils/formula/config/functions.d.ts +0 -3
  1159. package/react/utils/formula/config/groupings.d.ts +0 -9
  1160. package/react/utils/formula/config/regex.d.ts +0 -39
  1161. package/react/utils/formula/config/resolve-column-presentation.d.ts +0 -19
  1162. package/react/utils/formula/config/tests/build-datasets.test.d.ts +0 -1
  1163. package/react/utils/formula/config/validate-expression.d.ts +0 -19
  1164. package/react/utils/formula/load-formula-codemirror.d.ts +0 -4
  1165. package/react/utils/formula/render-explanation-tooltip.d.ts +0 -7
  1166. package/react/utils/formula/store/formula-display-store.d.ts +0 -87
  1167. package/react/utils/formula/store/formula-editor-context.d.ts +0 -8
  1168. package/react/utils/formula/store/formula-editor-store.d.ts +0 -46
  1169. package/react/utils/formula/store/tests/formula-editor-store.test.d.ts +0 -1
  1170. package/react/utils/formula/tests/validate-expression.test.d.ts +0 -1
  1171. package/react/utils/get-css-variable.d.ts +0 -1
  1172. package/react/utils/index.d.ts +0 -10
  1173. package/react/utils/localize/set-locale.d.ts +0 -7
  1174. package/react/utils/map-tile-providers/index.d.ts +0 -93
  1175. package/react/utils/slot-content/ad-hoc-slot-content.d.ts +0 -7
  1176. package/react/utils/slot-content/render-calculation-label.d.ts +0 -7
  1177. package/react/utils/slot-content/tests/ad-hoc-slot-content.test.d.ts +0 -1
  1178. package/react/utils/slot-state/slot-context.d.ts +0 -4
  1179. package/react/utils/slot-state/slot-store.d.ts +0 -39
  1180. package/react/utils/store/base-store.d.ts +0 -162
  1181. package/react/utils/store/dashboard-store.d.ts +0 -49
  1182. package/react/utils/store/index.d.ts +0 -135
  1183. package/react/utils/store/item-store.d.ts +0 -33
  1184. package/react/utils/store/store-registry.d.ts +0 -170
  1185. package/react/utils/store/tests/dashboard-store.test.d.ts +0 -1
  1186. package/react/utils/store/tests/item-store.test.d.ts +0 -1
  1187. package/react/utils/store/tests/store-registry.test.d.ts +0 -1
  1188. package/react/utils/store/types.d.ts +0 -270
  1189. package/react/utils/switch-item/index.d.ts +0 -34
  1190. package/react/utils/switch-item/slot-role-classification.d.ts +0 -31
  1191. package/react/utils/switch-item/stories/switch-item.stories.d.ts +0 -17
  1192. package/react/utils/switch-item/tests/slot-role-classification.test.d.ts +0 -1
  1193. package/react/utils/switch-item/tests/switch-item.test.d.ts +0 -1
  1194. package/react/utils/themes/bliss.d.ts +0 -2
  1195. package/react/utils/themes/classic-dark.d.ts +0 -2
  1196. package/react/utils/themes/classic.d.ts +0 -2
  1197. package/react/utils/themes/default-dark.d.ts +0 -2
  1198. package/react/utils/themes/default.d.ts +0 -2
  1199. package/react/utils/themes/index.d.ts +0 -4
  1200. package/react/utils/themes/orion.d.ts +0 -2
  1201. package/react/utils/themes/pinky.d.ts +0 -2
  1202. package/react/utils/themes/radiant.d.ts +0 -2
  1203. package/react/utils/themes/royale.d.ts +0 -2
  1204. package/react/utils/themes/seasonal.d.ts +0 -2
  1205. package/react/utils/themes/urban.d.ts +0 -2
  1206. package/react/utils/themes/vivid.d.ts +0 -2
  1207. package/react/utils/time/formats.const.d.ts +0 -4
  1208. package/react/utils/time/period-over-period-condition.const.d.ts +0 -8
  1209. package/react/utils/time/periods.const.d.ts +0 -15
  1210. package/react/utils/timezone/datetime-timezone.d.ts +0 -25
  1211. package/react/utils/timezone/tests/datetime-timezone.test.d.ts +0 -1
  1212. package/react/utils/transformations/convert-data-field-to-slot-content.d.ts +0 -9
  1213. package/react/utils/transformations/convert-datasets-to-data-fields.d.ts +0 -30
  1214. package/react/utils/transformations/tests/convert-data-field-to-slot-content.test.d.ts +0 -1
  1215. package/react/utils/transformations/tests/convert-datasets-to-data-fields.test.d.ts +0 -1
  1216. package/react/utils/types/tests/type-check.test.d.ts +0 -1
  1217. package/react/utils/types/type-check.d.ts +0 -28
  1218. /package/components/{chunk-mLOUI7ql.cjs → rolldown-runtime-mLOUI7ql.cjs} +0 -0
  1219. /package/{react/esm/components/ai-chat/empty-state/types.js → utils/ai-prompt/tests/attachments.test.d.ts} +0 -0
  1220. /package/{react/esm/components/ai-chat/stream/types.js → utils/ai-prompt/tests/dictation.test.d.ts} +0 -0
  1221. /package/{react/esm/components/ai-interaction-textarea/types.js → utils/ai-prompt/tests/image-upload.test.d.ts} +0 -0
@@ -0,0 +1,3973 @@
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 { i as e } from "./base-CUexK-Bc.js";
21
+ import { t } from "./decorate-DyMgX_Uh.js";
22
+ import { c as n, d as r, s as i, u as a } from "./ai-interaction-textarea-C-feG2HA.js";
23
+ import { msg as o } from "@lit/localize/lit-localize";
24
+ import { luzmoEllipsisVertical as s, luzmoIcon as c, luzmoSpin as l } from "@luzmo/icons";
25
+ import "@luzmo/lucero/button";
26
+ import "@luzmo/lucero/chat-message";
27
+ import "@luzmo/lucero/icon";
28
+ import "@luzmo/lucero/overlay";
29
+ import "@luzmo/lucero/popover";
30
+ import "@luzmo/lucero/progress-steps";
31
+ import { html as u, nothing as d, unsafeCSS as ee } from "lit";
32
+ import { property as f, state as p } from "lit/decorators.js";
33
+ import { unsafeHTML as te } from "lit/directives/unsafe-html.js";
34
+ import "@luzmo/lucero/action-button";
35
+ //#region node_modules/dompurify/dist/purify.es.mjs
36
+ function m(e, t) {
37
+ (t == null || t > e.length) && (t = e.length);
38
+ for (var n = 0, r = Array(t); n < t; n++) r[n] = e[n];
39
+ return r;
40
+ }
41
+ function ne(e) {
42
+ if (Array.isArray(e)) return e;
43
+ }
44
+ function re(e, t) {
45
+ var n = e == null ? null : typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
46
+ if (n != null) {
47
+ var r, i, a, o, s = [], c = !0, l = !1;
48
+ try {
49
+ if (a = (n = n.call(e)).next, t !== 0) for (; !(c = (r = a.call(n)).done) && (s.push(r.value), s.length !== t); c = !0);
50
+ } catch (e) {
51
+ l = !0, i = e;
52
+ } finally {
53
+ try {
54
+ if (!c && n.return != null && (o = n.return(), Object(o) !== o)) return;
55
+ } finally {
56
+ if (l) throw i;
57
+ }
58
+ }
59
+ return s;
60
+ }
61
+ }
62
+ function h() {
63
+ throw TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
64
+ }
65
+ function g(e, t) {
66
+ return ne(e) || re(e, t) || _(e, t) || h();
67
+ }
68
+ function _(e, t) {
69
+ if (e) {
70
+ if (typeof e == "string") return m(e, t);
71
+ var n = {}.toString.call(e).slice(8, -1);
72
+ 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) ? m(e, t) : void 0;
73
+ }
74
+ }
75
+ var ie = Object.entries, v = Object.setPrototypeOf, ae = Object.isFrozen, oe = Object.getPrototypeOf, se = Object.getOwnPropertyDescriptor, y = Object.freeze, b = Object.seal, ce = Object.create, le = typeof Reflect < "u" && Reflect, ue = le.apply, de = le.construct;
76
+ y ||= function(e) {
77
+ return e;
78
+ }, b ||= function(e) {
79
+ return e;
80
+ }, ue ||= function(e, t) {
81
+ var n = [...arguments].slice(2);
82
+ return e.apply(t, n);
83
+ }, de ||= function(e) {
84
+ return new e(...[...arguments].slice(1));
85
+ };
86
+ var fe = C(Array.prototype.forEach), pe = C(Array.prototype.lastIndexOf), me = C(Array.prototype.pop), he = C(Array.prototype.push), ge = C(Array.prototype.splice), _e = Array.isArray, ve = C(String.prototype.toLowerCase), ye = C(String.prototype.toString), be = C(String.prototype.match), xe = C(String.prototype.replace), Se = C(String.prototype.indexOf), Ce = C(String.prototype.trim), we = C(Number.prototype.toString), Te = C(Boolean.prototype.toString), Ee = typeof BigInt > "u" ? null : C(BigInt.prototype.toString), De = typeof Symbol > "u" ? null : C(Symbol.prototype.toString), x = C(Object.prototype.hasOwnProperty), Oe = C(Object.prototype.toString), S = C(RegExp.prototype.test), ke = Ae(TypeError);
87
+ function C(e) {
88
+ return function(t) {
89
+ t instanceof RegExp && (t.lastIndex = 0);
90
+ var n = [...arguments].slice(1);
91
+ return ue(e, t, n);
92
+ };
93
+ }
94
+ function Ae(e) {
95
+ return function() {
96
+ return de(e, [...arguments]);
97
+ };
98
+ }
99
+ function w(e, t) {
100
+ let n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : ve;
101
+ if (v && v(e, null), !_e(t)) return e;
102
+ let r = t.length;
103
+ for (; r--;) {
104
+ let i = t[r];
105
+ if (typeof i == "string") {
106
+ let e = n(i);
107
+ e !== i && (ae(t) || (t[r] = e), i = e);
108
+ }
109
+ e[i] = !0;
110
+ }
111
+ return e;
112
+ }
113
+ function T(e) {
114
+ for (let t = 0; t < e.length; t++) x(e, t) || (e[t] = null);
115
+ return e;
116
+ }
117
+ function E(e) {
118
+ let t = ce(null);
119
+ for (let r of ie(e)) {
120
+ var n = g(r, 2);
121
+ let i = n[0], a = n[1];
122
+ x(e, i) && (_e(a) ? t[i] = T(a) : a && typeof a == "object" && a.constructor === Object ? t[i] = E(a) : t[i] = a);
123
+ }
124
+ return t;
125
+ }
126
+ function je(e) {
127
+ switch (typeof e) {
128
+ case "string": return e;
129
+ case "number": return we(e);
130
+ case "boolean": return Te(e);
131
+ case "bigint": return Ee ? Ee(e) : "0";
132
+ case "symbol": return De ? De(e) : "Symbol()";
133
+ case "undefined": return Oe(e);
134
+ case "function":
135
+ case "object": {
136
+ if (e === null) return Oe(e);
137
+ let t = e, n = D(t, "toString");
138
+ if (typeof n == "function") {
139
+ let e = n(t);
140
+ return typeof e == "string" ? e : Oe(e);
141
+ }
142
+ return Oe(e);
143
+ }
144
+ default: return Oe(e);
145
+ }
146
+ }
147
+ function D(e, t) {
148
+ for (; e !== null;) {
149
+ let n = se(e, t);
150
+ if (n) {
151
+ if (n.get) return C(n.get);
152
+ if (typeof n.value == "function") return C(n.value);
153
+ }
154
+ e = oe(e);
155
+ }
156
+ function n() {
157
+ return null;
158
+ }
159
+ return n;
160
+ }
161
+ function Me(e) {
162
+ try {
163
+ return S(e, ""), !0;
164
+ } catch {
165
+ return !1;
166
+ }
167
+ }
168
+ var Ne = 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(".")), Pe = 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(".")), Fe = y([
169
+ "feBlend",
170
+ "feColorMatrix",
171
+ "feComponentTransfer",
172
+ "feComposite",
173
+ "feConvolveMatrix",
174
+ "feDiffuseLighting",
175
+ "feDisplacementMap",
176
+ "feDistantLight",
177
+ "feDropShadow",
178
+ "feFlood",
179
+ "feFuncA",
180
+ "feFuncB",
181
+ "feFuncG",
182
+ "feFuncR",
183
+ "feGaussianBlur",
184
+ "feImage",
185
+ "feMerge",
186
+ "feMergeNode",
187
+ "feMorphology",
188
+ "feOffset",
189
+ "fePointLight",
190
+ "feSpecularLighting",
191
+ "feSpotLight",
192
+ "feTile",
193
+ "feTurbulence"
194
+ ]), Ie = y([
195
+ "animate",
196
+ "color-profile",
197
+ "cursor",
198
+ "discard",
199
+ "font-face",
200
+ "font-face-format",
201
+ "font-face-name",
202
+ "font-face-src",
203
+ "font-face-uri",
204
+ "foreignobject",
205
+ "hatch",
206
+ "hatchpath",
207
+ "mesh",
208
+ "meshgradient",
209
+ "meshpatch",
210
+ "meshrow",
211
+ "missing-glyph",
212
+ "script",
213
+ "set",
214
+ "solidcolor",
215
+ "unknown",
216
+ "use"
217
+ ]), Le = 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(".")), Re = y([
218
+ "maction",
219
+ "maligngroup",
220
+ "malignmark",
221
+ "mlongdiv",
222
+ "mscarries",
223
+ "mscarry",
224
+ "msgroup",
225
+ "mstack",
226
+ "msline",
227
+ "msrow",
228
+ "semantics",
229
+ "annotation",
230
+ "annotation-xml",
231
+ "mprescripts",
232
+ "none"
233
+ ]), ze = y(["#text"]), Be = 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(".")), Ve = 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.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.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(".")), He = 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(".")), Ue = y([
234
+ "xlink:href",
235
+ "xml:id",
236
+ "xlink:title",
237
+ "xml:space",
238
+ "xmlns:xlink"
239
+ ]), We = b(/{{[\w\W]*|^[\w\W]*}}/g), Ge = b(/<%[\w\W]*|^[\w\W]*%>/g), Ke = b(/\${[\w\W]*/g), qe = b(/^data-[\-\w.\u00B7-\uFFFF]+$/), Je = b(/^aria-[\-\w]+$/), Ye = b(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i), Xe = b(/^(?:\w+script|data):/i), Ze = b(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g), Qe = b(/^html$/i), $e = b(/^[a-z][.\w]*(-[.\w]+)+$/i), et = b(/<[/\w!]/g), tt = b(/<[/\w]/g), nt = b(/<\/no(script|embed|frames)/i), rt = b(/\/>/i), O = {
240
+ element: 1,
241
+ attribute: 2,
242
+ text: 3,
243
+ cdataSection: 4,
244
+ entityReference: 5,
245
+ entityNode: 6,
246
+ processingInstruction: 7,
247
+ comment: 8,
248
+ document: 9,
249
+ documentType: 10,
250
+ documentFragment: 11,
251
+ notation: 12
252
+ }, it = function() {
253
+ return typeof window > "u" ? null : window;
254
+ }, at = function(e, t) {
255
+ if (typeof e != "object" || typeof e.createPolicy != "function") return null;
256
+ let n = null, r = "data-tt-policy-suffix";
257
+ t && t.hasAttribute(r) && (n = t.getAttribute(r));
258
+ let i = "dompurify" + (n ? "#" + n : "");
259
+ try {
260
+ return e.createPolicy(i, {
261
+ createHTML(e) {
262
+ return e;
263
+ },
264
+ createScriptURL(e) {
265
+ return e;
266
+ }
267
+ });
268
+ } catch {
269
+ return console.warn("TrustedTypes policy " + i + " could not be created."), null;
270
+ }
271
+ }, ot = function() {
272
+ return {
273
+ afterSanitizeAttributes: [],
274
+ afterSanitizeElements: [],
275
+ afterSanitizeShadowDOM: [],
276
+ beforeSanitizeAttributes: [],
277
+ beforeSanitizeElements: [],
278
+ beforeSanitizeShadowDOM: [],
279
+ uponSanitizeAttribute: [],
280
+ uponSanitizeElement: [],
281
+ uponSanitizeShadowNode: []
282
+ };
283
+ }, st = function(e, t, n, r) {
284
+ return x(e, t) && _e(e[t]) ? w(r.base ? E(r.base) : {}, e[t], r.transform) : n;
285
+ };
286
+ function ct() {
287
+ let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : it(), t = (e) => ct(e);
288
+ if (t.version = "3.4.12", t.removed = [], !e || !e.document || e.document.nodeType !== O.document || !e.Element) return t.isSupported = !1, t;
289
+ let n = e.document, r = n, i = r.currentScript;
290
+ e.DocumentFragment;
291
+ let a = e.HTMLTemplateElement, o = e.Node, s = e.Element, c = e.NodeFilter;
292
+ e.NamedNodeMap === void 0 && (e.NamedNodeMap || e.MozNamedAttrMap), e.HTMLFormElement;
293
+ let l = e.DOMParser, u = e.trustedTypes, d = s.prototype, ee = D(d, "cloneNode"), f = D(d, "remove"), p = D(d, "nextSibling"), te = D(d, "childNodes"), m = D(d, "parentNode"), ne = D(d, "shadowRoot"), re = D(d, "attributes"), h = o && o.prototype ? D(o.prototype, "nodeType") : null, g = o && o.prototype ? D(o.prototype, "nodeName") : null;
294
+ if (typeof a == "function") {
295
+ let e = n.createElement("template");
296
+ e.content && e.content.ownerDocument && (n = e.content.ownerDocument);
297
+ }
298
+ let _, v = "", ae, oe = !1, se = 0, le = function() {
299
+ if (se > 0) throw ke("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.");
300
+ }, ue = function(e) {
301
+ le(), se++;
302
+ try {
303
+ return _.createHTML(e);
304
+ } finally {
305
+ se--;
306
+ }
307
+ }, de = function(e) {
308
+ le(), se++;
309
+ try {
310
+ return _.createScriptURL(e);
311
+ } finally {
312
+ se--;
313
+ }
314
+ }, we = function() {
315
+ return oe ||= (ae = at(u, i), !0), ae;
316
+ }, Te = n, Ee = Te.implementation, De = Te.createNodeIterator, Oe = Te.createDocumentFragment, C = Te.getElementsByTagName, Ae = r.importNode, T = ot();
317
+ t.isSupported = typeof ie == "function" && typeof m == "function" && Ee && Ee.createHTMLDocument !== void 0;
318
+ let lt = We, ut = Ge, dt = Ke, ft = qe, pt = Je, mt = Xe, k = Ze, ht = $e, A = Ye, j = null, gt = w({}, [
319
+ ...Ne,
320
+ ...Pe,
321
+ ...Fe,
322
+ ...Le,
323
+ ...ze
324
+ ]), M = null, _t = w({}, [
325
+ ...Be,
326
+ ...Ve,
327
+ ...He,
328
+ ...Ue
329
+ ]), N = Object.seal(ce(null, {
330
+ tagNameCheck: {
331
+ writable: !0,
332
+ configurable: !1,
333
+ enumerable: !0,
334
+ value: null
335
+ },
336
+ attributeNameCheck: {
337
+ writable: !0,
338
+ configurable: !1,
339
+ enumerable: !0,
340
+ value: null
341
+ },
342
+ allowCustomizedBuiltInElements: {
343
+ writable: !0,
344
+ configurable: !1,
345
+ enumerable: !0,
346
+ value: !1
347
+ }
348
+ })), P = null, vt = null, F = Object.seal(ce(null, {
349
+ tagCheck: {
350
+ writable: !0,
351
+ configurable: !1,
352
+ enumerable: !0,
353
+ value: null
354
+ },
355
+ attributeCheck: {
356
+ writable: !0,
357
+ configurable: !1,
358
+ enumerable: !0,
359
+ value: null
360
+ }
361
+ })), yt = !0, bt = !0, xt = !1, St = !0, I = !1, L = !0, R = !1, Ct = !1, wt = null, Tt = null, Et = !1, Dt = !1, Ot = !1, kt = !1, At = !0, jt = !1, Mt = "user-content-", Nt = !0, z = !1, B = {}, V = null, Pt = 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(".")), Ft = null, It = w({}, [
362
+ "audio",
363
+ "video",
364
+ "img",
365
+ "source",
366
+ "image",
367
+ "track"
368
+ ]), Lt = null, Rt = w({}, [
369
+ "alt",
370
+ "class",
371
+ "for",
372
+ "id",
373
+ "label",
374
+ "name",
375
+ "pattern",
376
+ "placeholder",
377
+ "role",
378
+ "summary",
379
+ "title",
380
+ "value",
381
+ "style",
382
+ "xmlns"
383
+ ]), zt = "http://www.w3.org/1998/Math/MathML", Bt = "http://www.w3.org/2000/svg", H = "http://www.w3.org/1999/xhtml", Vt = H, Ht = !1, Ut = null, Wt = w({}, [
384
+ zt,
385
+ Bt,
386
+ H
387
+ ], ye), Gt = y([
388
+ "mi",
389
+ "mo",
390
+ "mn",
391
+ "ms",
392
+ "mtext"
393
+ ]), Kt = w({}, Gt), qt = y(["annotation-xml"]), Jt = w({}, qt), Yt = w({}, [
394
+ "title",
395
+ "style",
396
+ "font",
397
+ "a",
398
+ "script"
399
+ ]), Xt = null, Zt = ["application/xhtml+xml", "text/html"], U = null, Qt = null, $t = n.createElement("form"), en = function(e) {
400
+ return e instanceof RegExp || e instanceof Function;
401
+ }, tn = function() {
402
+ let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
403
+ if (Qt && Qt === e) return;
404
+ (!e || typeof e != "object") && (e = {}), e = E(e), Xt = Zt.indexOf(e.PARSER_MEDIA_TYPE) === -1 ? "text/html" : e.PARSER_MEDIA_TYPE, U = Xt === "application/xhtml+xml" ? ye : ve, j = st(e, "ALLOWED_TAGS", gt, { transform: U }), M = st(e, "ALLOWED_ATTR", _t, { transform: U }), Ut = st(e, "ALLOWED_NAMESPACES", Wt, { transform: ye }), Lt = st(e, "ADD_URI_SAFE_ATTR", Rt, {
405
+ transform: U,
406
+ base: Rt
407
+ }), Ft = st(e, "ADD_DATA_URI_TAGS", It, {
408
+ transform: U,
409
+ base: It
410
+ }), V = st(e, "FORBID_CONTENTS", Pt, { transform: U }), P = st(e, "FORBID_TAGS", E({}), { transform: U }), vt = st(e, "FORBID_ATTR", E({}), { transform: U }), B = x(e, "USE_PROFILES") ? e.USE_PROFILES && typeof e.USE_PROFILES == "object" ? E(e.USE_PROFILES) : e.USE_PROFILES : !1, yt = e.ALLOW_ARIA_ATTR !== !1, bt = e.ALLOW_DATA_ATTR !== !1, xt = e.ALLOW_UNKNOWN_PROTOCOLS || !1, St = e.ALLOW_SELF_CLOSE_IN_ATTR !== !1, I = e.SAFE_FOR_TEMPLATES || !1, L = e.SAFE_FOR_XML !== !1, R = e.WHOLE_DOCUMENT || !1, Dt = e.RETURN_DOM || !1, Ot = e.RETURN_DOM_FRAGMENT || !1, kt = e.RETURN_TRUSTED_TYPE || !1, Et = e.FORCE_BODY || !1, At = e.SANITIZE_DOM !== !1, jt = e.SANITIZE_NAMED_PROPS || !1, Nt = e.KEEP_CONTENT !== !1, z = e.IN_PLACE || !1, A = Me(e.ALLOWED_URI_REGEXP) ? e.ALLOWED_URI_REGEXP : Ye, Vt = typeof e.NAMESPACE == "string" ? e.NAMESPACE : H, Kt = x(e, "MATHML_TEXT_INTEGRATION_POINTS") && e.MATHML_TEXT_INTEGRATION_POINTS && typeof e.MATHML_TEXT_INTEGRATION_POINTS == "object" ? E(e.MATHML_TEXT_INTEGRATION_POINTS) : w({}, Gt), Jt = x(e, "HTML_INTEGRATION_POINTS") && e.HTML_INTEGRATION_POINTS && typeof e.HTML_INTEGRATION_POINTS == "object" ? E(e.HTML_INTEGRATION_POINTS) : w({}, qt);
411
+ let t = x(e, "CUSTOM_ELEMENT_HANDLING") && e.CUSTOM_ELEMENT_HANDLING && typeof e.CUSTOM_ELEMENT_HANDLING == "object" ? E(e.CUSTOM_ELEMENT_HANDLING) : ce(null);
412
+ if (N = ce(null), x(t, "tagNameCheck") && en(t.tagNameCheck) && (N.tagNameCheck = t.tagNameCheck), x(t, "attributeNameCheck") && en(t.attributeNameCheck) && (N.attributeNameCheck = t.attributeNameCheck), x(t, "allowCustomizedBuiltInElements") && typeof t.allowCustomizedBuiltInElements == "boolean" && (N.allowCustomizedBuiltInElements = t.allowCustomizedBuiltInElements), b(N), I && (bt = !1), Ot && (Dt = !0), B && (j = w({}, ze), M = ce(null), B.html === !0 && (w(j, Ne), w(M, Be)), B.svg === !0 && (w(j, Pe), w(M, Ve), w(M, Ue)), B.svgFilters === !0 && (w(j, Fe), w(M, Ve), w(M, Ue)), B.mathMl === !0 && (w(j, Le), w(M, He), w(M, Ue))), F.tagCheck = null, F.attributeCheck = null, x(e, "ADD_TAGS") && (typeof e.ADD_TAGS == "function" ? F.tagCheck = e.ADD_TAGS : _e(e.ADD_TAGS) && (j === gt && (j = E(j)), w(j, e.ADD_TAGS, U))), x(e, "ADD_ATTR") && (typeof e.ADD_ATTR == "function" ? F.attributeCheck = e.ADD_ATTR : _e(e.ADD_ATTR) && (M === _t && (M = E(M)), w(M, e.ADD_ATTR, U))), x(e, "ADD_URI_SAFE_ATTR") && _e(e.ADD_URI_SAFE_ATTR) && w(Lt, e.ADD_URI_SAFE_ATTR, U), x(e, "FORBID_CONTENTS") && _e(e.FORBID_CONTENTS) && (V === Pt && (V = E(V)), w(V, e.FORBID_CONTENTS, U)), x(e, "ADD_FORBID_CONTENTS") && _e(e.ADD_FORBID_CONTENTS) && (V === Pt && (V = E(V)), w(V, e.ADD_FORBID_CONTENTS, U)), Nt && (j["#text"] = !0), R && w(j, [
413
+ "html",
414
+ "head",
415
+ "body"
416
+ ]), j.table && (w(j, ["tbody"]), delete P.tbody), e.TRUSTED_TYPES_POLICY) {
417
+ if (typeof e.TRUSTED_TYPES_POLICY.createHTML != "function") throw ke("TRUSTED_TYPES_POLICY configuration option must provide a \"createHTML\" hook.");
418
+ if (typeof e.TRUSTED_TYPES_POLICY.createScriptURL != "function") throw ke("TRUSTED_TYPES_POLICY configuration option must provide a \"createScriptURL\" hook.");
419
+ let t = _;
420
+ _ = e.TRUSTED_TYPES_POLICY;
421
+ try {
422
+ v = ue("");
423
+ } catch (e) {
424
+ throw _ = t, e;
425
+ }
426
+ } else e.TRUSTED_TYPES_POLICY === null ? (_ = void 0, v = "") : (_ === void 0 && (_ = we()), _ && typeof v == "string" && (v = ue("")));
427
+ y && y(e), Qt = e;
428
+ }, nn = w({}, [
429
+ ...Pe,
430
+ ...Fe,
431
+ ...Ie
432
+ ]), rn = w({}, [...Le, ...Re]), an = function(e, t, n) {
433
+ return t.namespaceURI === H ? e === "svg" : t.namespaceURI === zt ? e === "svg" && (n === "annotation-xml" || Kt[n]) : !!nn[e];
434
+ }, on = function(e, t, n) {
435
+ return t.namespaceURI === H ? e === "math" : t.namespaceURI === Bt ? e === "math" && Jt[n] : !!rn[e];
436
+ }, sn = function(e, t, n) {
437
+ return t.namespaceURI === Bt && !Jt[n] || t.namespaceURI === zt && !Kt[n] ? !1 : !rn[e] && (Yt[e] || !nn[e]);
438
+ }, cn = function(e) {
439
+ let t = m(e);
440
+ (!t || !t.tagName) && (t = {
441
+ namespaceURI: Vt,
442
+ tagName: "template"
443
+ });
444
+ let n = ve(e.tagName), r = ve(t.tagName);
445
+ return Ut[e.namespaceURI] ? e.namespaceURI === Bt ? an(n, t, r) : e.namespaceURI === zt ? on(n, t, r) : e.namespaceURI === H ? sn(n, t, r) : !!(Xt === "application/xhtml+xml" && Ut[e.namespaceURI]) : !1;
446
+ }, ln = function(e) {
447
+ he(t.removed, { element: e });
448
+ try {
449
+ m(e).removeChild(e);
450
+ } catch {
451
+ if (f(e), !m(e)) throw ke("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place");
452
+ }
453
+ }, un = function(e) {
454
+ fn(e);
455
+ let t = te(e);
456
+ if (t) {
457
+ let e = [];
458
+ fe(t, (t) => {
459
+ he(e, t);
460
+ }), fe(e, (e) => {
461
+ try {
462
+ f(e);
463
+ } catch {}
464
+ });
465
+ }
466
+ let n = re(e);
467
+ if (n) for (let t = n.length - 1; t >= 0; --t) {
468
+ let r = n[t], i = r && r.name;
469
+ if (typeof i == "string") try {
470
+ e.removeAttribute(i);
471
+ } catch {}
472
+ }
473
+ }, W = function(e, n) {
474
+ try {
475
+ he(t.removed, {
476
+ attribute: n.getAttributeNode(e),
477
+ from: n
478
+ });
479
+ } catch {
480
+ he(t.removed, {
481
+ attribute: null,
482
+ from: n
483
+ });
484
+ }
485
+ if (n.removeAttribute(e), e === "is") if (Dt || Ot) try {
486
+ ln(n);
487
+ } catch {}
488
+ else try {
489
+ n.setAttribute(e, "");
490
+ } catch {}
491
+ }, dn = function(e) {
492
+ let t = re(e);
493
+ if (t) for (let n = t.length - 1; n >= 0; --n) {
494
+ let r = t[n], i = r && r.name;
495
+ if (!(typeof i != "string" || M[U(i)])) try {
496
+ e.removeAttribute(i);
497
+ } catch {}
498
+ }
499
+ }, fn = function(e) {
500
+ let t = [e];
501
+ for (; t.length > 0;) {
502
+ let e = t.pop();
503
+ (h ? h(e) : e.nodeType) === O.element && dn(e);
504
+ let n = te(e);
505
+ if (n) for (let e = n.length - 1; e >= 0; --e) t.push(n[e]);
506
+ }
507
+ }, G = function(e) {
508
+ if (!L) return;
509
+ let t = [e];
510
+ for (; t.length > 0;) {
511
+ let e = t.pop(), n = h ? h(e) : e.nodeType;
512
+ if (n === O.processingInstruction || n === O.comment && S(tt, e.data)) {
513
+ try {
514
+ f(e);
515
+ } catch {}
516
+ continue;
517
+ }
518
+ if (n === O.element) {
519
+ let t = e, n = U(g ? g(e) : e.nodeName);
520
+ try {
521
+ t.hasAttribute && t.hasAttribute("patchsrc") && t.removeAttribute("patchsrc"), t.hasAttribute && t.hasAttribute("for") && n !== "label" && n !== "output" && t.removeAttribute("for");
522
+ } catch {}
523
+ }
524
+ let r = te(e);
525
+ if (r) for (let e = r.length - 1; e >= 0; --e) t.push(r[e]);
526
+ }
527
+ }, pn = function(e) {
528
+ let t = null, r = null;
529
+ if (Et) e = "<remove></remove>" + e;
530
+ else {
531
+ let t = be(e, /^[\r\n\t ]+/);
532
+ r = t && t[0];
533
+ }
534
+ Xt === "application/xhtml+xml" && Vt === H && (e = "<html xmlns=\"http://www.w3.org/1999/xhtml\"><head></head><body>" + e + "</body></html>");
535
+ let i = _ ? ue(e) : e;
536
+ if (Vt === H) try {
537
+ t = new l().parseFromString(i, Xt);
538
+ } catch {}
539
+ if (!t || !t.documentElement) {
540
+ t = Ee.createDocument(Vt, "template", null);
541
+ try {
542
+ t.documentElement.innerHTML = Ht ? v : i;
543
+ } catch {}
544
+ }
545
+ let a = t.body || t.documentElement;
546
+ return e && r && a.insertBefore(n.createTextNode(r), a.childNodes[0] || null), Vt === H ? C.call(t, R ? "html" : "body")[0] : R ? t.documentElement : a;
547
+ }, mn = function(e) {
548
+ return De.call(e.ownerDocument || e, e, c.SHOW_ELEMENT | c.SHOW_COMMENT | c.SHOW_TEXT | c.SHOW_PROCESSING_INSTRUCTION | c.SHOW_CDATA_SECTION, null);
549
+ }, hn = function(e) {
550
+ return e = xe(e, lt, " "), e = xe(e, ut, " "), e = xe(e, dt, " "), e;
551
+ }, gn = function(e) {
552
+ e.normalize();
553
+ let t = De.call(e.ownerDocument || e, e, c.SHOW_TEXT | c.SHOW_COMMENT | c.SHOW_CDATA_SECTION | c.SHOW_PROCESSING_INSTRUCTION, null), n = t.nextNode();
554
+ for (; n;) n.data = hn(n.data), n = t.nextNode();
555
+ let r = e.querySelectorAll?.call(e, "template");
556
+ r && fe(r, (e) => {
557
+ K(e.content) && gn(e.content);
558
+ });
559
+ }, _n = function(e) {
560
+ let t = g ? g(e) : null;
561
+ return typeof t != "string" || U(t) !== "form" ? !1 : typeof e.nodeName != "string" || typeof e.textContent != "string" || typeof e.removeChild != "function" || e.attributes !== re(e) || typeof e.removeAttribute != "function" || typeof e.setAttribute != "function" || typeof e.namespaceURI != "string" || typeof e.insertBefore != "function" || typeof e.hasChildNodes != "function" || e.nodeType !== h(e) || e.childNodes !== te(e);
562
+ }, K = function(e) {
563
+ if (!h || typeof e != "object" || !e) return !1;
564
+ try {
565
+ return h(e) === O.documentFragment;
566
+ } catch {
567
+ return !1;
568
+ }
569
+ }, q = function(e) {
570
+ if (!h || typeof e != "object" || !e) return !1;
571
+ try {
572
+ return typeof h(e) == "number";
573
+ } catch {
574
+ return !1;
575
+ }
576
+ };
577
+ function J(e, n, r) {
578
+ e.length !== 0 && fe(e, (e) => {
579
+ e.call(t, n, r, Qt);
580
+ });
581
+ }
582
+ let vn = function(e, t) {
583
+ return !!(L && e.hasChildNodes() && !q(e.firstElementChild) && S(et, e.textContent) && S(et, e.innerHTML) || L && e.namespaceURI === H && t === "style" && q(e.firstElementChild) || e.nodeType === O.processingInstruction || L && e.nodeType === O.comment && S(tt, e.data));
584
+ }, Y = function(e, t) {
585
+ if (!P[t] && bn(t) && (N.tagNameCheck instanceof RegExp && S(N.tagNameCheck, t) || N.tagNameCheck instanceof Function && N.tagNameCheck(t))) return !1;
586
+ if (Nt && !V[t]) {
587
+ let t = m(e), n = te(e);
588
+ if (n && t) {
589
+ let r = n.length;
590
+ for (let i = r - 1; i >= 0; --i) {
591
+ let r = z ? n[i] : ee(n[i], !0);
592
+ t.insertBefore(r, p(e));
593
+ }
594
+ }
595
+ }
596
+ return ln(e), !0;
597
+ }, yn = function(e, n) {
598
+ if (J(T.beforeSanitizeElements, e, null), e !== n && m(e) === null) return !0;
599
+ if (_n(e)) return ln(e), !0;
600
+ let r = U(g ? g(e) : e.nodeName);
601
+ if (J(T.uponSanitizeElement, e, {
602
+ tagName: r,
603
+ allowedTags: j
604
+ }), e !== n && m(e) === null) return !0;
605
+ if (vn(e, r)) return ln(e), !0;
606
+ if (P[r] || !(F.tagCheck instanceof Function && F.tagCheck(r)) && !j[r]) {
607
+ let t = Y(e, r);
608
+ return t === !1 && J(T.afterSanitizeElements, e, null), t;
609
+ }
610
+ if ((h ? h(e) : e.nodeType) === O.element && !cn(e) || (r === "noscript" || r === "noembed" || r === "noframes") && S(nt, e.innerHTML)) return ln(e), !0;
611
+ if (I && e.nodeType === O.text) {
612
+ let n = hn(e.textContent);
613
+ e.textContent !== n && (he(t.removed, { element: e.cloneNode() }), e.textContent = n);
614
+ }
615
+ return J(T.afterSanitizeElements, e, null), !1;
616
+ }, X = function(e, t, r) {
617
+ if (vt[t] || L && t === "patchsrc" || L && t === "for" && e !== "label" && e !== "output" || At && (t === "id" || t === "name") && (r in n || r in $t)) return !1;
618
+ let i = M[t] || F.attributeCheck instanceof Function && F.attributeCheck(t, e);
619
+ if (!(bt && S(ft, t)) && !(yt && S(pt, t))) {
620
+ if (!i) {
621
+ if (!(bn(e) && (N.tagNameCheck instanceof RegExp && S(N.tagNameCheck, e) || N.tagNameCheck instanceof Function && N.tagNameCheck(e)) && (N.attributeNameCheck instanceof RegExp && S(N.attributeNameCheck, t) || N.attributeNameCheck instanceof Function && N.attributeNameCheck(t, e)) || t === "is" && N.allowCustomizedBuiltInElements && (N.tagNameCheck instanceof RegExp && S(N.tagNameCheck, r) || N.tagNameCheck instanceof Function && N.tagNameCheck(r)))) return !1;
622
+ } else if (!Lt[t] && !S(A, xe(r, k, "")) && !((t === "src" || t === "xlink:href" || t === "href") && e !== "script" && Se(r, "data:") === 0 && Ft[e]) && !(xt && !S(mt, xe(r, k, ""))) && r) return !1;
623
+ }
624
+ return !0;
625
+ }, Z = w({}, [
626
+ "annotation-xml",
627
+ "color-profile",
628
+ "font-face",
629
+ "font-face-format",
630
+ "font-face-name",
631
+ "font-face-src",
632
+ "font-face-uri",
633
+ "missing-glyph"
634
+ ]), bn = function(e) {
635
+ return !Z[ve(e)] && S(ht, e);
636
+ }, xn = function(e, t, n, r) {
637
+ if (_ && typeof u == "object" && typeof u.getAttributeType == "function" && !n) switch (u.getAttributeType(e, t)) {
638
+ case "TrustedHTML": return ue(r);
639
+ case "TrustedScriptURL": return de(r);
640
+ }
641
+ return r;
642
+ }, Sn = function(e, n, r, i) {
643
+ try {
644
+ r ? e.setAttributeNS(r, n, i) : e.setAttribute(n, i), _n(e) ? ln(e) : me(t.removed);
645
+ } catch {
646
+ W(n, e);
647
+ }
648
+ }, Cn = function(e) {
649
+ J(T.beforeSanitizeAttributes, e, null);
650
+ let t = e.attributes;
651
+ if (!t || _n(e)) return;
652
+ let n = {
653
+ attrName: "",
654
+ attrValue: "",
655
+ keepAttr: !0,
656
+ allowedAttributes: M,
657
+ forceKeepAttr: void 0
658
+ }, r = t.length, i = U(e.nodeName);
659
+ for (; r--;) {
660
+ let a = t[r], o = a.name, s = a.namespaceURI, c = a.value, l = U(o), u = c, d = o === "value" ? u : Ce(u);
661
+ if (n.attrName = l, n.attrValue = d, n.keepAttr = !0, n.forceKeepAttr = void 0, J(T.uponSanitizeAttribute, e, n), d = n.attrValue, jt && (l === "id" || l === "name") && Se(d, Mt) !== 0 && (W(o, e), d = Mt + d), L && S(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i, d)) {
662
+ W(o, e);
663
+ continue;
664
+ }
665
+ if (l === "attributename" && be(d, "href")) {
666
+ W(o, e);
667
+ continue;
668
+ }
669
+ if (!n.forceKeepAttr) {
670
+ if (!n.keepAttr) {
671
+ W(o, e);
672
+ continue;
673
+ }
674
+ if (!St && S(rt, d)) {
675
+ W(o, e);
676
+ continue;
677
+ }
678
+ if (I && (d = hn(d)), !X(i, l, d)) {
679
+ W(o, e);
680
+ continue;
681
+ }
682
+ d = xn(i, l, s, d), d !== u && Sn(e, o, s, d);
683
+ }
684
+ }
685
+ J(T.afterSanitizeAttributes, e, null);
686
+ }, wn = function(e) {
687
+ let t = null, n = mn(e);
688
+ for (J(T.beforeSanitizeShadowDOM, e, null); t = n.nextNode();) if (J(T.uponSanitizeShadowNode, t, null), yn(t, e), Cn(t), K(t.content) && wn(t.content), (h ? h(t) : t.nodeType) === O.element) {
689
+ let e = ne(t);
690
+ K(e) && (Tn(e), wn(e));
691
+ }
692
+ J(T.afterSanitizeShadowDOM, e, null);
693
+ }, Tn = function(e) {
694
+ let t = [{
695
+ node: e,
696
+ shadow: null
697
+ }];
698
+ for (; t.length > 0;) {
699
+ let e = t.pop();
700
+ if (e.shadow) {
701
+ wn(e.shadow);
702
+ continue;
703
+ }
704
+ let n = e.node, r = (h ? h(n) : n.nodeType) === O.element, i = te(n);
705
+ if (i) for (let e = i.length - 1; e >= 0; --e) t.push({
706
+ node: i[e],
707
+ shadow: null
708
+ });
709
+ if (r) {
710
+ let e = g ? g(n) : null;
711
+ if (typeof e == "string" && U(e) === "template") {
712
+ let e = n.content;
713
+ K(e) && t.push({
714
+ node: e,
715
+ shadow: null
716
+ });
717
+ }
718
+ }
719
+ if (r) {
720
+ let e = ne(n);
721
+ K(e) && t.push({
722
+ node: null,
723
+ shadow: e
724
+ }, {
725
+ node: e,
726
+ shadow: null
727
+ });
728
+ }
729
+ }
730
+ };
731
+ return t.sanitize = function(e) {
732
+ let n = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, i = null, a = null, o = null, s = null;
733
+ if (Ht = !e, Ht && (e = "<!-->"), typeof e != "string" && !q(e) && (e = je(e), typeof e != "string")) throw ke("dirty is not a string, aborting");
734
+ if (!t.isSupported) return e;
735
+ Ct ? (j = wt, M = Tt) : tn(n), (T.uponSanitizeElement.length > 0 || T.uponSanitizeAttribute.length > 0) && (j = E(j)), T.uponSanitizeAttribute.length > 0 && (M = E(M)), t.removed = [];
736
+ let c = z && typeof e != "string" && q(e);
737
+ if (c) {
738
+ G(e);
739
+ let t = g ? g(e) : e.nodeName;
740
+ if (typeof t == "string") {
741
+ let n = U(t);
742
+ if (!j[n] || P[n]) throw un(e), ke("root node is forbidden and cannot be sanitized in-place");
743
+ }
744
+ if (_n(e)) throw un(e), ke("root node is clobbered and cannot be sanitized in-place");
745
+ try {
746
+ Tn(e);
747
+ } catch (t) {
748
+ throw un(e), t;
749
+ }
750
+ } else if (q(e)) i = pn("<!---->"), a = i.ownerDocument.importNode(e, !0), a.nodeType === O.element && a.nodeName === "BODY" || a.nodeName === "HTML" ? i = a : i.appendChild(a), Tn(a);
751
+ else {
752
+ if (!Dt && !I && !R && e.indexOf("<") === -1) return _ && kt ? ue(e) : e;
753
+ if (i = pn(e), !i) return Dt ? null : kt ? v : "";
754
+ }
755
+ i && Et && ln(i.firstChild);
756
+ let l = c ? e : i, u = mn(l);
757
+ try {
758
+ for (; o = u.nextNode();) yn(o, l), Cn(o), K(o.content) && wn(o.content);
759
+ } catch (n) {
760
+ throw c && (un(e), fe(t.removed, (e) => {
761
+ e.element && fn(e.element);
762
+ })), n;
763
+ }
764
+ if (c) return fe(t.removed, (e) => {
765
+ e.element && fn(e.element);
766
+ }), I && gn(e), e;
767
+ if (Dt) {
768
+ if (I && gn(i), Ot) for (s = Oe.call(i.ownerDocument); i.firstChild;) s.appendChild(i.firstChild);
769
+ else s = i;
770
+ return (M.shadowroot || M.shadowrootmode) && (s = Ae.call(r, s, !0)), s;
771
+ }
772
+ let d = R ? i.outerHTML : i.innerHTML;
773
+ return R && j["!doctype"] && i.ownerDocument && i.ownerDocument.doctype && i.ownerDocument.doctype.name && S(Qe, i.ownerDocument.doctype.name) && (d = "<!DOCTYPE " + i.ownerDocument.doctype.name + ">\n" + d), I && (d = hn(d)), _ && kt ? ue(d) : d;
774
+ }, t.setConfig = function() {
775
+ let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
776
+ tn(e), Ct = !0, wt = j, Tt = M;
777
+ }, t.clearConfig = function() {
778
+ Qt = null, Ct = !1, wt = null, Tt = null, _ = ae, v = "";
779
+ }, t.isValidAttribute = function(e, t, n) {
780
+ Qt || tn({});
781
+ let r = U(e), i = U(t);
782
+ return X(r, i, n);
783
+ }, t.addHook = function(e, t) {
784
+ typeof t == "function" && x(T, e) && he(T[e], t);
785
+ }, t.removeHook = function(e, t) {
786
+ if (x(T, e)) {
787
+ if (t !== void 0) {
788
+ let n = pe(T[e], t);
789
+ return n === -1 ? void 0 : ge(T[e], n, 1)[0];
790
+ }
791
+ return me(T[e]);
792
+ }
793
+ }, t.removeHooks = function(e) {
794
+ x(T, e) && (T[e] = []);
795
+ }, t.removeAllHooks = function() {
796
+ T = ot();
797
+ }, t;
798
+ }
799
+ var lt = ct();
800
+ //#endregion
801
+ //#region node_modules/marked/lib/marked.esm.js
802
+ function ut() {
803
+ return {
804
+ async: !1,
805
+ breaks: !1,
806
+ extensions: null,
807
+ gfm: !0,
808
+ hooks: null,
809
+ pedantic: !1,
810
+ renderer: null,
811
+ silent: !1,
812
+ tokenizer: null,
813
+ walkTokens: null
814
+ };
815
+ }
816
+ var dt = ut();
817
+ function ft(e) {
818
+ dt = e;
819
+ }
820
+ var pt = { exec: () => null };
821
+ function mt(e) {
822
+ let t = [];
823
+ return (n) => {
824
+ let r = Math.max(0, Math.min(3, n - 1)), i = t[r];
825
+ return i || (i = e(r), t[r] = i), i;
826
+ };
827
+ }
828
+ function k(e, t = "") {
829
+ let n = typeof e == "string" ? e : e.source, r = {
830
+ replace: (e, t) => {
831
+ let i = typeof t == "string" ? t : t.source;
832
+ return i = i.replace(A.caret, "$1"), n = n.replace(e, i), r;
833
+ },
834
+ getRegex: () => new RegExp(n, t)
835
+ };
836
+ return r;
837
+ }
838
+ var ht = ((e = "") => {
839
+ try {
840
+ return !!RegExp("(?<=1)(?<!1)" + e);
841
+ } catch {
842
+ return !1;
843
+ }
844
+ })(), A = {
845
+ codeRemoveIndent: /^(?: {1,4}| {0,3}\t)/gm,
846
+ outputLinkReplace: /\\([\[\]])/g,
847
+ indentCodeCompensation: /^(\s+)(?:```)/,
848
+ beginningSpace: /^\s+/,
849
+ endingHash: /#$/,
850
+ startingSpaceChar: /^ /,
851
+ endingSpaceChar: / $/,
852
+ nonSpaceChar: /[^ ]/,
853
+ newLineCharGlobal: /\n/g,
854
+ tabCharGlobal: /\t/g,
855
+ multipleSpaceGlobal: /\s+/g,
856
+ blankLine: /^[ \t]*$/,
857
+ doubleBlankLine: /\n[ \t]*\n[ \t]*$/,
858
+ blockquoteStart: /^ {0,3}>/,
859
+ blockquoteSetextReplace: /\n {0,3}((?:=+|-+) *)(?=\n|$)/g,
860
+ blockquoteSetextReplace2: /^ {0,3}>[ \t]?/gm,
861
+ listReplaceNesting: /^ {1,4}(?=( {4})*[^ ])/g,
862
+ listIsTask: /^\[[ xX]\] +\S/,
863
+ listReplaceTask: /^\[[ xX]\] +/,
864
+ listTaskCheckbox: /\[[ xX]\]/,
865
+ anyLine: /\n.*\n/,
866
+ hrefBrackets: /^<(.*)>$/,
867
+ tableDelimiter: /[:|]/,
868
+ tableAlignChars: /^\||\| *$/g,
869
+ tableRowBlankLine: /\n[ \t]*$/,
870
+ tableAlignRight: /^ *-+: *$/,
871
+ tableAlignCenter: /^ *:-+: *$/,
872
+ tableAlignLeft: /^ *:-+ *$/,
873
+ startATag: /^<a /i,
874
+ endATag: /^<\/a>/i,
875
+ startPreScriptTag: /^<(pre|code|kbd|script)(\s|>)/i,
876
+ endPreScriptTag: /^<\/(pre|code|kbd|script)(\s|>)/i,
877
+ startAngleBracket: /^</,
878
+ endAngleBracket: />$/,
879
+ pedanticHrefTitle: /^([^'"]*[^\s])\s+(['"])(.*)\2/,
880
+ unicodeAlphaNumeric: /[\p{L}\p{N}]/u,
881
+ escapeTest: /[&<>"']/,
882
+ escapeReplace: /[&<>"']/g,
883
+ escapeTestNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,
884
+ escapeReplaceNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,
885
+ caret: /(^|[^\[])\^/g,
886
+ percentDecode: /%25/g,
887
+ findPipe: /\|/g,
888
+ splitPipe: / \|/,
889
+ slashPipe: /\\\|/g,
890
+ carriageReturn: /\r\n|\r/g,
891
+ spaceLine: /^ +$/gm,
892
+ notSpaceStart: /^\S*/,
893
+ endingNewline: /\n$/,
894
+ listItemRegex: (e) => RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),
895
+ nextBulletRegex: mt((e) => RegExp(`^ {0,${e}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`)),
896
+ hrRegex: mt((e) => RegExp(`^ {0,${e}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`)),
897
+ fencesBeginRegex: mt((e) => RegExp(`^ {0,${e}}(?:\`\`\`|~~~)`)),
898
+ headingBeginRegex: mt((e) => RegExp(`^ {0,${e}}#`)),
899
+ htmlBeginRegex: mt((e) => RegExp(`^ {0,${e}}<(?:[a-z].*>|!--)`, "i")),
900
+ blockquoteBeginRegex: mt((e) => RegExp(`^ {0,${e}}>`))
901
+ }, j = /^(?:[ \t]*(?:\n|$))+/, gt = /^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/, M = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/, _t = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/, N = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/, P = / {0,3}(?:[*+-]|\d{1,9}[.)])/, vt = /^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/, F = k(vt).replace(/bull/g, P).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(), yt = k(vt).replace(/bull/g, P).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(), bt = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/, xt = /^[^\n]+/, St = /(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/, I = k(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label", St).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(), L = k(/^(bull)([ \t][^\n]*?)?(?:\n|$)/).replace(/bull/g, P).getRegex(), R = "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", Ct = /<!--(?:-?>|[\s\S]*?(?:-->|$))/, wt = k("^ {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", Ct).replace("tag", R).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(), Tt = k(bt).replace("hr", _t).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", R).getRegex(), Et = {
902
+ blockquote: k(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", Tt).getRegex(),
903
+ code: gt,
904
+ def: I,
905
+ fences: M,
906
+ heading: N,
907
+ hr: _t,
908
+ html: wt,
909
+ lheading: F,
910
+ list: L,
911
+ newline: j,
912
+ paragraph: Tt,
913
+ table: pt,
914
+ text: xt
915
+ }, Dt = k("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", _t).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", R).getRegex(), Ot = {
916
+ ...Et,
917
+ lheading: yt,
918
+ table: Dt,
919
+ paragraph: k(bt).replace("hr", _t).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table", Dt).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", R).getRegex()
920
+ }, kt = {
921
+ ...Et,
922
+ html: k("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:\"[^\"]*\"|'[^']*'|\\s[^'\"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment", Ct).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(),
923
+ def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,
924
+ heading: /^(#{1,6})(.*)(?:\n+|$)/,
925
+ fences: pt,
926
+ lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,
927
+ paragraph: k(bt).replace("hr", _t).replace("heading", " *#{1,6} *[^\n]").replace("lheading", F).replace("|table", "").replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").replace("|tag", "").getRegex()
928
+ }, At = /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/, jt = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/, Mt = /^( {2,}|\\)\n(?!\s*$)/, Nt = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/, z = /[\p{P}\p{S}]/u, B = /[\s\p{P}\p{S}]/u, V = /[^\s\p{P}\p{S}]/u, Pt = k(/^((?![*_])punctSpace)/, "u").replace(/punctSpace/g, B).getRegex(), Ft = /(?!~)[\p{P}\p{S}]/u, It = /(?!~)[\s\p{P}\p{S}]/u, Lt = /(?:[^\s\p{P}\p{S}]|~)/u, Rt = k(/link|precode-code|html/, "g").replace("link", /\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-", ht ? "(?<!`)()" : "(^^|[^`])").replace("code", /(?<b>`+)[^`]+\k<b>(?!`)/).replace("html", /<(?! )[^<>]*?>/).getRegex(), zt = /^(?:\*+(?:((?!\*)punct)|([^\s*]))?)|^_+(?:((?!_)punct)|([^\s_]))?/, Bt = k(zt, "u").replace(/punct/g, z).getRegex(), H = k(zt, "u").replace(/punct/g, Ft).getRegex(), Vt = "^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)", Ht = k(Vt, "gu").replace(/notPunctSpace/g, V).replace(/punctSpace/g, B).replace(/punct/g, z).getRegex(), Ut = k(Vt, "gu").replace(/notPunctSpace/g, Lt).replace(/punctSpace/g, It).replace(/punct/g, Ft).getRegex(), Wt = k("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)", "gu").replace(/notPunctSpace/g, V).replace(/punctSpace/g, B).replace(/punct/g, z).getRegex(), Gt = k(/^~~?(?:((?!~)punct)|[^\s~])/, "u").replace(/punct/g, z).getRegex(), Kt = k("^[^~]+(?=[^~])|(?!~)punct(~~?)(?=[\\s]|$)|notPunctSpace(~~?)(?!~)(?=punctSpace|$)|(?!~)punctSpace(~~?)(?=notPunctSpace)|[\\s](~~?)(?!~)(?=punct)|(?!~)punct(~~?)(?!~)(?=punct)|notPunctSpace(~~?)(?=notPunctSpace)", "gu").replace(/notPunctSpace/g, V).replace(/punctSpace/g, B).replace(/punct/g, z).getRegex(), qt = k(/\\(punct)/, "gu").replace(/punct/g, z).getRegex(), Jt = k(/^<(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(), Yt = k(Ct).replace("(?:-->|$)", "-->").getRegex(), Xt = k("^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", Yt).replace("attribute", /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(), Zt = /(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+(?!`)[^`]*?`+(?!`)|``+(?=\])|[^\[\]\\`])*?/, U = k(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]+(?:\n[ \t]*)?|\n[ \t]*)(title))?\s*\)/).replace("label", Zt).replace("href", /<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title", /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(), Qt = k(/^!?\[(label)\]\[(ref)\]/).replace("label", Zt).replace("ref", St).getRegex(), $t = k(/^!?\[(ref)\](?:\[\])?/).replace("ref", St).getRegex(), en = k("reflink|nolink(?!\\()", "g").replace("reflink", Qt).replace("nolink", $t).getRegex(), tn = /[hH][tT][tT][pP][sS]?|[fF][tT][pP]/, nn = {
929
+ _backpedal: pt,
930
+ anyPunctuation: qt,
931
+ autolink: Jt,
932
+ blockSkip: Rt,
933
+ br: Mt,
934
+ code: jt,
935
+ del: pt,
936
+ delLDelim: pt,
937
+ delRDelim: pt,
938
+ emStrongLDelim: Bt,
939
+ emStrongRDelimAst: Ht,
940
+ emStrongRDelimUnd: Wt,
941
+ escape: At,
942
+ link: U,
943
+ nolink: $t,
944
+ punctuation: Pt,
945
+ reflink: Qt,
946
+ reflinkSearch: en,
947
+ tag: Xt,
948
+ text: Nt,
949
+ url: pt
950
+ }, rn = {
951
+ ...nn,
952
+ link: k(/^!?\[(label)\]\((.*?)\)/).replace("label", Zt).getRegex(),
953
+ reflink: k(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", Zt).getRegex()
954
+ }, an = {
955
+ ...nn,
956
+ emStrongRDelimAst: Ut,
957
+ emStrongLDelim: H,
958
+ delLDelim: Gt,
959
+ delRDelim: Kt,
960
+ url: k(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol", tn).replace("email", /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),
961
+ _backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,
962
+ del: /^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,
963
+ text: k(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol", tn).getRegex()
964
+ }, on = {
965
+ ...an,
966
+ br: k(Mt).replace("{2,}", "*").getRegex(),
967
+ text: k(an.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex()
968
+ }, sn = {
969
+ normal: Et,
970
+ gfm: Ot,
971
+ pedantic: kt
972
+ }, cn = {
973
+ normal: nn,
974
+ gfm: an,
975
+ breaks: on,
976
+ pedantic: rn
977
+ }, ln = {
978
+ "&": "&amp;",
979
+ "<": "&lt;",
980
+ ">": "&gt;",
981
+ "\"": "&quot;",
982
+ "'": "&#39;"
983
+ }, un = (e) => ln[e];
984
+ function W(e, t) {
985
+ if (t) {
986
+ if (A.escapeTest.test(e)) return e.replace(A.escapeReplace, un);
987
+ } else if (A.escapeTestNoEncode.test(e)) return e.replace(A.escapeReplaceNoEncode, un);
988
+ return e;
989
+ }
990
+ function dn(e) {
991
+ try {
992
+ e = encodeURI(e).replace(A.percentDecode, "%");
993
+ } catch {
994
+ return null;
995
+ }
996
+ return e;
997
+ }
998
+ function fn(e, t) {
999
+ let n = e.replace(A.findPipe, (e, t, n) => {
1000
+ let r = !1, i = t;
1001
+ for (; --i >= 0 && n[i] === "\\";) r = !r;
1002
+ return r ? "|" : " |";
1003
+ }).split(A.splitPipe), r = 0;
1004
+ if (n[0].trim() || n.shift(), n.length > 0 && !n.at(-1)?.trim() && n.pop(), t) if (n.length > t) n.splice(t);
1005
+ else for (; n.length < t;) n.push("");
1006
+ for (; r < n.length; r++) n[r] = n[r].trim().replace(A.slashPipe, "|");
1007
+ return n;
1008
+ }
1009
+ function G(e, t, n) {
1010
+ let r = e.length;
1011
+ if (r === 0) return "";
1012
+ let i = 0;
1013
+ for (; i < r;) {
1014
+ let a = e.charAt(r - i - 1);
1015
+ if (a === t && !n) i++;
1016
+ else if (a !== t && n) i++;
1017
+ else break;
1018
+ }
1019
+ return e.slice(0, r - i);
1020
+ }
1021
+ function pn(e) {
1022
+ let t = e.split("\n"), n = t.length - 1;
1023
+ for (; n >= 0 && A.blankLine.test(t[n]);) n--;
1024
+ return t.length - n <= 2 ? e : t.slice(0, n + 1).join("\n");
1025
+ }
1026
+ function mn(e, t) {
1027
+ if (e.indexOf(t[1]) === -1) return -1;
1028
+ let n = 0;
1029
+ for (let r = 0; r < e.length; r++) if (e[r] === "\\") r++;
1030
+ else if (e[r] === t[0]) n++;
1031
+ else if (e[r] === t[1] && (n--, n < 0)) return r;
1032
+ return n > 0 ? -2 : -1;
1033
+ }
1034
+ function hn(e, t = 0) {
1035
+ let n = t, r = "";
1036
+ for (let t of e) if (t === " ") {
1037
+ let e = 4 - n % 4;
1038
+ r += " ".repeat(e), n += e;
1039
+ } else r += t, n++;
1040
+ return r;
1041
+ }
1042
+ function gn(e, t, n, r, i) {
1043
+ let a = t.href, o = t.title || null, s = e[1].replace(i.other.outputLinkReplace, "$1");
1044
+ r.state.inLink = !0;
1045
+ let c = {
1046
+ type: e[0].charAt(0) === "!" ? "image" : "link",
1047
+ raw: n,
1048
+ href: a,
1049
+ title: o,
1050
+ text: s,
1051
+ tokens: r.inlineTokens(s)
1052
+ };
1053
+ return r.state.inLink = !1, c;
1054
+ }
1055
+ function _n(e, t, n) {
1056
+ let r = e.match(n.other.indentCodeCompensation);
1057
+ if (r === null) return t;
1058
+ let i = r[1];
1059
+ return t.split("\n").map((e) => {
1060
+ let t = e.match(n.other.beginningSpace);
1061
+ if (t === null) return e;
1062
+ let [r] = t;
1063
+ return r.length >= i.length ? e.slice(i.length) : e;
1064
+ }).join("\n");
1065
+ }
1066
+ var K = class {
1067
+ options;
1068
+ rules;
1069
+ lexer;
1070
+ constructor(e) {
1071
+ this.options = e || dt;
1072
+ }
1073
+ space(e) {
1074
+ let t = this.rules.block.newline.exec(e);
1075
+ if (t && t[0].length > 0) return {
1076
+ type: "space",
1077
+ raw: t[0]
1078
+ };
1079
+ }
1080
+ code(e) {
1081
+ let t = this.rules.block.code.exec(e);
1082
+ if (t) {
1083
+ let e = this.options.pedantic ? t[0] : pn(t[0]);
1084
+ return {
1085
+ type: "code",
1086
+ raw: e,
1087
+ codeBlockStyle: "indented",
1088
+ text: e.replace(this.rules.other.codeRemoveIndent, "")
1089
+ };
1090
+ }
1091
+ }
1092
+ fences(e) {
1093
+ let t = this.rules.block.fences.exec(e);
1094
+ if (t) {
1095
+ let e = t[0], n = _n(e, t[3] || "", this.rules);
1096
+ return {
1097
+ type: "code",
1098
+ raw: e,
1099
+ lang: t[2] ? t[2].trim().replace(this.rules.inline.anyPunctuation, "$1") : t[2],
1100
+ text: n
1101
+ };
1102
+ }
1103
+ }
1104
+ heading(e) {
1105
+ let t = this.rules.block.heading.exec(e);
1106
+ if (t) {
1107
+ let e = t[2].trim();
1108
+ if (this.rules.other.endingHash.test(e)) {
1109
+ let t = G(e, "#");
1110
+ (this.options.pedantic || !t || this.rules.other.endingSpaceChar.test(t)) && (e = t.trim());
1111
+ }
1112
+ return {
1113
+ type: "heading",
1114
+ raw: G(t[0], "\n"),
1115
+ depth: t[1].length,
1116
+ text: e,
1117
+ tokens: this.lexer.inline(e)
1118
+ };
1119
+ }
1120
+ }
1121
+ hr(e) {
1122
+ let t = this.rules.block.hr.exec(e);
1123
+ if (t) return {
1124
+ type: "hr",
1125
+ raw: G(t[0], "\n")
1126
+ };
1127
+ }
1128
+ blockquote(e) {
1129
+ let t = this.rules.block.blockquote.exec(e);
1130
+ if (t) {
1131
+ let e = G(t[0], "\n").split("\n"), n = "", r = "", i = [];
1132
+ for (; e.length > 0;) {
1133
+ let t = !1, a = [], o;
1134
+ for (o = 0; o < e.length; o++) if (this.rules.other.blockquoteStart.test(e[o])) a.push(e[o]), t = !0;
1135
+ else if (!t) a.push(e[o]);
1136
+ else break;
1137
+ e = e.slice(o);
1138
+ let s = a.join("\n"), c = s.replace(this.rules.other.blockquoteSetextReplace, "\n $1").replace(this.rules.other.blockquoteSetextReplace2, "");
1139
+ n = n ? `${n}
1140
+ ${s}` : s, r = r ? `${r}
1141
+ ${c}` : c;
1142
+ let l = this.lexer.state.top;
1143
+ if (this.lexer.state.top = !0, this.lexer.blockTokens(c, i, !0), this.lexer.state.top = l, e.length === 0) break;
1144
+ let u = i.at(-1);
1145
+ if (u?.type === "code") break;
1146
+ if (u?.type === "blockquote") {
1147
+ let t = u, a = t.raw + "\n" + e.join("\n"), o = this.blockquote(a);
1148
+ 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;
1149
+ break;
1150
+ } else if (u?.type === "list") {
1151
+ let t = u, a = t.raw + "\n" + e.join("\n"), o = this.list(a);
1152
+ 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");
1153
+ continue;
1154
+ }
1155
+ }
1156
+ return {
1157
+ type: "blockquote",
1158
+ raw: n,
1159
+ tokens: i,
1160
+ text: r
1161
+ };
1162
+ }
1163
+ }
1164
+ list(e) {
1165
+ let t = this.rules.block.list.exec(e);
1166
+ if (t) {
1167
+ let n = t[1].trim(), r = n.length > 1, i = {
1168
+ type: "list",
1169
+ raw: "",
1170
+ ordered: r,
1171
+ start: r ? +n.slice(0, -1) : "",
1172
+ loose: !1,
1173
+ items: []
1174
+ };
1175
+ n = r ? `\\d{1,9}\\${n.slice(-1)}` : `\\${n}`, this.options.pedantic && (n = r ? n : "[*+-]");
1176
+ let a = this.rules.other.listItemRegex(n), o = !1;
1177
+ for (; e;) {
1178
+ let n = !1, r = "", s = "";
1179
+ if (!(t = a.exec(e)) || this.rules.block.hr.test(e)) break;
1180
+ r = t[0], e = e.substring(r.length);
1181
+ let c = hn(t[2].split("\n", 1)[0], t[1].length), l = e.split("\n", 1)[0], u = !c.trim(), d = 0;
1182
+ 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) {
1183
+ 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), ee = this.rules.other.blockquoteBeginRegex(d);
1184
+ for (; e;) {
1185
+ let f = e.split("\n", 1)[0], p;
1186
+ if (l = f, this.options.pedantic ? (l = l.replace(this.rules.other.listReplaceNesting, " "), p = l) : p = l.replace(this.rules.other.tabCharGlobal, " "), i.test(l) || a.test(l) || o.test(l) || ee.test(l) || t.test(l) || n.test(l)) break;
1187
+ if (p.search(this.rules.other.nonSpaceChar) >= d || !l.trim()) s += "\n" + p.slice(d);
1188
+ else {
1189
+ if (u || c.replace(this.rules.other.tabCharGlobal, " ").search(this.rules.other.nonSpaceChar) >= 4 || i.test(c) || a.test(c) || n.test(c)) break;
1190
+ s += "\n" + l;
1191
+ }
1192
+ u = !l.trim(), r += f + "\n", e = e.substring(f.length + 1), c = p.slice(d);
1193
+ }
1194
+ }
1195
+ i.loose || (o ? i.loose = !0 : this.rules.other.doubleBlankLine.test(r) && (o = !0)), i.items.push({
1196
+ type: "list_item",
1197
+ raw: r,
1198
+ task: !!this.options.gfm && this.rules.other.listIsTask.test(s),
1199
+ loose: !1,
1200
+ text: s,
1201
+ tokens: []
1202
+ }), i.raw += r;
1203
+ }
1204
+ let s = i.items.at(-1);
1205
+ if (s) s.raw = s.raw.trimEnd(), s.text = s.text.trimEnd();
1206
+ else return;
1207
+ i.raw = i.raw.trimEnd();
1208
+ for (let e of i.items) {
1209
+ this.lexer.state.top = !1, e.tokens = this.lexer.blockTokens(e.text, []);
1210
+ let t = e.tokens[0];
1211
+ if (e.task && (t?.type === "text" || t?.type === "paragraph")) {
1212
+ 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, "");
1213
+ for (let e = this.lexer.inlineQueue.length - 1; e >= 0; e--) if (this.rules.other.listIsTask.test(this.lexer.inlineQueue[e].src)) {
1214
+ this.lexer.inlineQueue[e].src = this.lexer.inlineQueue[e].src.replace(this.rules.other.listReplaceTask, "");
1215
+ break;
1216
+ }
1217
+ let n = this.rules.other.listTaskCheckbox.exec(e.raw);
1218
+ if (n) {
1219
+ let t = {
1220
+ type: "checkbox",
1221
+ raw: n[0] + " ",
1222
+ checked: n[0] !== "[ ]"
1223
+ };
1224
+ 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({
1225
+ type: "paragraph",
1226
+ raw: t.raw,
1227
+ text: t.raw,
1228
+ tokens: [t]
1229
+ }) : e.tokens.unshift(t);
1230
+ }
1231
+ } else e.task &&= !1;
1232
+ if (!i.loose) {
1233
+ let t = e.tokens.filter((e) => e.type === "space");
1234
+ i.loose = t.length > 0 && t.some((e) => this.rules.other.anyLine.test(e.raw));
1235
+ }
1236
+ }
1237
+ if (i.loose) for (let e of i.items) {
1238
+ e.loose = !0;
1239
+ for (let t of e.tokens) t.type === "text" && (t.type = "paragraph");
1240
+ }
1241
+ return i;
1242
+ }
1243
+ }
1244
+ html(e) {
1245
+ let t = this.rules.block.html.exec(e);
1246
+ if (t) {
1247
+ let e = pn(t[0]);
1248
+ return {
1249
+ type: "html",
1250
+ block: !0,
1251
+ raw: e,
1252
+ pre: t[1] === "pre" || t[1] === "script" || t[1] === "style",
1253
+ text: e
1254
+ };
1255
+ }
1256
+ }
1257
+ def(e) {
1258
+ let t = this.rules.block.def.exec(e);
1259
+ if (t) {
1260
+ 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];
1261
+ return {
1262
+ type: "def",
1263
+ tag: e,
1264
+ raw: G(t[0], "\n"),
1265
+ href: n,
1266
+ title: r
1267
+ };
1268
+ }
1269
+ }
1270
+ table(e) {
1271
+ let t = this.rules.block.table.exec(e);
1272
+ if (!t || !this.rules.other.tableDelimiter.test(t[2])) return;
1273
+ let n = fn(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 = {
1274
+ type: "table",
1275
+ raw: G(t[0], "\n"),
1276
+ header: [],
1277
+ align: [],
1278
+ rows: []
1279
+ };
1280
+ if (n.length === r.length) {
1281
+ 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);
1282
+ for (let e = 0; e < n.length; e++) a.header.push({
1283
+ text: n[e],
1284
+ tokens: this.lexer.inline(n[e]),
1285
+ header: !0,
1286
+ align: a.align[e]
1287
+ });
1288
+ for (let e of i) a.rows.push(fn(e, a.header.length).map((e, t) => ({
1289
+ text: e,
1290
+ tokens: this.lexer.inline(e),
1291
+ header: !1,
1292
+ align: a.align[t]
1293
+ })));
1294
+ return a;
1295
+ }
1296
+ }
1297
+ lheading(e) {
1298
+ let t = this.rules.block.lheading.exec(e);
1299
+ if (t) {
1300
+ let e = t[1].trim();
1301
+ return {
1302
+ type: "heading",
1303
+ raw: G(t[0], "\n"),
1304
+ depth: t[2].charAt(0) === "=" ? 1 : 2,
1305
+ text: e,
1306
+ tokens: this.lexer.inline(e)
1307
+ };
1308
+ }
1309
+ }
1310
+ paragraph(e) {
1311
+ let t = this.rules.block.paragraph.exec(e);
1312
+ if (t) {
1313
+ let e = t[1].charAt(t[1].length - 1) === "\n" ? t[1].slice(0, -1) : t[1];
1314
+ return {
1315
+ type: "paragraph",
1316
+ raw: t[0],
1317
+ text: e,
1318
+ tokens: this.lexer.inline(e)
1319
+ };
1320
+ }
1321
+ }
1322
+ text(e) {
1323
+ let t = this.rules.block.text.exec(e);
1324
+ if (t) return {
1325
+ type: "text",
1326
+ raw: t[0],
1327
+ text: t[0],
1328
+ tokens: this.lexer.inline(t[0])
1329
+ };
1330
+ }
1331
+ escape(e) {
1332
+ let t = this.rules.inline.escape.exec(e);
1333
+ if (t) return {
1334
+ type: "escape",
1335
+ raw: t[0],
1336
+ text: t[1]
1337
+ };
1338
+ }
1339
+ tag(e) {
1340
+ let t = this.rules.inline.tag.exec(e);
1341
+ 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), {
1342
+ type: "html",
1343
+ raw: t[0],
1344
+ inLink: this.lexer.state.inLink,
1345
+ inRawBlock: this.lexer.state.inRawBlock,
1346
+ block: !1,
1347
+ text: t[0]
1348
+ };
1349
+ }
1350
+ link(e) {
1351
+ let t = this.rules.inline.link.exec(e);
1352
+ if (t) {
1353
+ let e = t[2].trim();
1354
+ if (!this.options.pedantic && this.rules.other.startAngleBracket.test(e)) {
1355
+ if (!this.rules.other.endAngleBracket.test(e)) return;
1356
+ let t = G(e.slice(0, -1), "\\");
1357
+ if ((e.length - t.length) % 2 == 0) return;
1358
+ } else {
1359
+ let e = mn(t[2], "()");
1360
+ if (e === -2) return;
1361
+ if (e > -1) {
1362
+ let n = (t[0].indexOf("!") === 0 ? 5 : 4) + t[1].length + e;
1363
+ t[2] = t[2].substring(0, e), t[0] = t[0].substring(0, n).trim(), t[3] = "";
1364
+ }
1365
+ }
1366
+ let n = t[2], r = "";
1367
+ if (this.options.pedantic) {
1368
+ let e = this.rules.other.pedanticHrefTitle.exec(n);
1369
+ e && (n = e[1], r = e[3]);
1370
+ } else r = t[3] ? t[3].slice(1, -1) : "";
1371
+ 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)), gn(t, {
1372
+ href: n && n.replace(this.rules.inline.anyPunctuation, "$1"),
1373
+ title: r && r.replace(this.rules.inline.anyPunctuation, "$1")
1374
+ }, t[0], this.lexer, this.rules);
1375
+ }
1376
+ }
1377
+ reflink(e, t) {
1378
+ let n;
1379
+ if ((n = this.rules.inline.reflink.exec(e)) || (n = this.rules.inline.nolink.exec(e))) {
1380
+ let e = t[(n[2] || n[1]).replace(this.rules.other.multipleSpaceGlobal, " ").toLowerCase()];
1381
+ if (!e) {
1382
+ let e = n[0].charAt(0);
1383
+ return {
1384
+ type: "text",
1385
+ raw: e,
1386
+ text: e
1387
+ };
1388
+ }
1389
+ return gn(n, e, n[0], this.lexer, this.rules);
1390
+ }
1391
+ }
1392
+ emStrong(e, t, n = "") {
1393
+ let r = this.rules.inline.emStrongLDelim.exec(e);
1394
+ 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))) {
1395
+ let n = [...r[0]].length - 1, i, a, o = n, s = 0, c = r[0][0] === "*" ? this.rules.inline.emStrongRDelimAst : this.rules.inline.emStrongRDelimUnd;
1396
+ for (c.lastIndex = 0, t = t.slice(-1 * e.length + n); (r = c.exec(t)) !== null;) {
1397
+ if (i = r[1] || r[2] || r[3] || r[4] || r[5] || r[6], !i) continue;
1398
+ if (a = [...i].length, r[3] || r[4]) {
1399
+ o += a;
1400
+ continue;
1401
+ } else if ((r[5] || r[6]) && n % 3 && !((n + a) % 3)) {
1402
+ s += a;
1403
+ continue;
1404
+ }
1405
+ if (o -= a, o > 0) continue;
1406
+ a = Math.min(a, a + o + s);
1407
+ let t = [...r[0]][0].length, c = e.slice(0, n + r.index + t + a);
1408
+ if (Math.min(n, a) % 2) {
1409
+ let e = c.slice(1, -1);
1410
+ return {
1411
+ type: "em",
1412
+ raw: c,
1413
+ text: e,
1414
+ tokens: this.lexer.inlineTokens(e)
1415
+ };
1416
+ }
1417
+ let l = c.slice(2, -2);
1418
+ return {
1419
+ type: "strong",
1420
+ raw: c,
1421
+ text: l,
1422
+ tokens: this.lexer.inlineTokens(l)
1423
+ };
1424
+ }
1425
+ }
1426
+ }
1427
+ codespan(e) {
1428
+ let t = this.rules.inline.code.exec(e);
1429
+ if (t) {
1430
+ 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);
1431
+ return n && r && (e = e.substring(1, e.length - 1)), {
1432
+ type: "codespan",
1433
+ raw: t[0],
1434
+ text: e
1435
+ };
1436
+ }
1437
+ }
1438
+ br(e) {
1439
+ let t = this.rules.inline.br.exec(e);
1440
+ if (t) return {
1441
+ type: "br",
1442
+ raw: t[0]
1443
+ };
1444
+ }
1445
+ del(e, t, n = "") {
1446
+ let r = this.rules.inline.delLDelim.exec(e);
1447
+ if (r && (!r[1] || !n || this.rules.inline.punctuation.exec(n))) {
1448
+ let n = [...r[0]].length - 1, i, a, o = n, s = this.rules.inline.delRDelim;
1449
+ for (s.lastIndex = 0, t = t.slice(-1 * e.length + n); (r = s.exec(t)) !== null;) {
1450
+ if (i = r[1] || r[2] || r[3] || r[4] || r[5] || r[6], !i || (a = [...i].length, a !== n)) continue;
1451
+ if (r[3] || r[4]) {
1452
+ o += a;
1453
+ continue;
1454
+ }
1455
+ if (o -= a, o > 0) continue;
1456
+ a = Math.min(a, a + o);
1457
+ let t = [...r[0]][0].length, s = e.slice(0, n + r.index + t + a), c = s.slice(n, -n);
1458
+ return {
1459
+ type: "del",
1460
+ raw: s,
1461
+ text: c,
1462
+ tokens: this.lexer.inlineTokens(c)
1463
+ };
1464
+ }
1465
+ }
1466
+ }
1467
+ autolink(e) {
1468
+ let t = this.rules.inline.autolink.exec(e);
1469
+ if (t) {
1470
+ let e, n;
1471
+ return t[2] === "@" ? (e = t[1], n = "mailto:" + e) : (e = t[1], n = e), {
1472
+ type: "link",
1473
+ raw: t[0],
1474
+ text: e,
1475
+ href: n,
1476
+ tokens: [{
1477
+ type: "text",
1478
+ raw: e,
1479
+ text: e
1480
+ }]
1481
+ };
1482
+ }
1483
+ }
1484
+ url(e) {
1485
+ let t;
1486
+ if (t = this.rules.inline.url.exec(e)) {
1487
+ let e, n;
1488
+ if (t[2] === "@") e = t[0], n = "mailto:" + e;
1489
+ else {
1490
+ let r;
1491
+ do
1492
+ r = t[0], t[0] = this.rules.inline._backpedal.exec(t[0])?.[0] ?? "";
1493
+ while (r !== t[0]);
1494
+ e = t[0], n = t[1] === "www." ? "http://" + t[0] : t[0];
1495
+ }
1496
+ return {
1497
+ type: "link",
1498
+ raw: t[0],
1499
+ text: e,
1500
+ href: n,
1501
+ tokens: [{
1502
+ type: "text",
1503
+ raw: e,
1504
+ text: e
1505
+ }]
1506
+ };
1507
+ }
1508
+ }
1509
+ inlineText(e) {
1510
+ let t = this.rules.inline.text.exec(e);
1511
+ if (t) {
1512
+ let e = this.lexer.state.inRawBlock;
1513
+ return {
1514
+ type: "text",
1515
+ raw: t[0],
1516
+ text: t[0],
1517
+ escaped: e
1518
+ };
1519
+ }
1520
+ }
1521
+ }, q = class e {
1522
+ tokens;
1523
+ options;
1524
+ state;
1525
+ inlineQueue;
1526
+ tokenizer;
1527
+ constructor(e) {
1528
+ this.tokens = [], this.tokens.links = Object.create(null), this.options = e || dt, this.options.tokenizer = this.options.tokenizer || new K(), this.tokenizer = this.options.tokenizer, this.tokenizer.options = this.options, this.tokenizer.lexer = this, this.inlineQueue = [], this.state = {
1529
+ inLink: !1,
1530
+ inRawBlock: !1,
1531
+ top: !0
1532
+ };
1533
+ let t = {
1534
+ other: A,
1535
+ block: sn.normal,
1536
+ inline: cn.normal
1537
+ };
1538
+ this.options.pedantic ? (t.block = sn.pedantic, t.inline = cn.pedantic) : this.options.gfm && (t.block = sn.gfm, this.options.breaks ? t.inline = cn.breaks : t.inline = cn.gfm), this.tokenizer.rules = t;
1539
+ }
1540
+ static get rules() {
1541
+ return {
1542
+ block: sn,
1543
+ inline: cn
1544
+ };
1545
+ }
1546
+ static lex(t, n) {
1547
+ return new e(n).lex(t);
1548
+ }
1549
+ static lexInline(t, n) {
1550
+ return new e(n).inlineTokens(t);
1551
+ }
1552
+ lex(e) {
1553
+ e = e.replace(A.carriageReturn, "\n"), this.blockTokens(e, this.tokens);
1554
+ for (let e = 0; e < this.inlineQueue.length; e++) {
1555
+ let t = this.inlineQueue[e];
1556
+ this.inlineTokens(t.src, t.tokens);
1557
+ }
1558
+ return this.inlineQueue = [], this.tokens;
1559
+ }
1560
+ blockTokens(e, t = [], n = !1) {
1561
+ this.tokenizer.lexer = this, this.options.pedantic && (e = e.replace(A.tabCharGlobal, " ").replace(A.spaceLine, ""));
1562
+ let r = Infinity;
1563
+ for (; e;) {
1564
+ if (e.length < r) r = e.length;
1565
+ else {
1566
+ this.infiniteLoopError(e.charCodeAt(0));
1567
+ break;
1568
+ }
1569
+ let i;
1570
+ 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;
1571
+ if (i = this.tokenizer.space(e)) {
1572
+ e = e.substring(i.raw.length);
1573
+ let n = t.at(-1);
1574
+ i.raw.length === 1 && n !== void 0 ? n.raw += "\n" : t.push(i);
1575
+ continue;
1576
+ }
1577
+ if (i = this.tokenizer.code(e)) {
1578
+ e = e.substring(i.raw.length);
1579
+ let n = t.at(-1);
1580
+ 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);
1581
+ continue;
1582
+ }
1583
+ if (i = this.tokenizer.fences(e)) {
1584
+ e = e.substring(i.raw.length), t.push(i);
1585
+ continue;
1586
+ }
1587
+ if (i = this.tokenizer.heading(e)) {
1588
+ e = e.substring(i.raw.length), t.push(i);
1589
+ continue;
1590
+ }
1591
+ if (i = this.tokenizer.hr(e)) {
1592
+ e = e.substring(i.raw.length), t.push(i);
1593
+ continue;
1594
+ }
1595
+ if (i = this.tokenizer.blockquote(e)) {
1596
+ e = e.substring(i.raw.length), t.push(i);
1597
+ continue;
1598
+ }
1599
+ if (i = this.tokenizer.list(e)) {
1600
+ e = e.substring(i.raw.length), t.push(i);
1601
+ continue;
1602
+ }
1603
+ if (i = this.tokenizer.html(e)) {
1604
+ e = e.substring(i.raw.length), t.push(i);
1605
+ continue;
1606
+ }
1607
+ if (i = this.tokenizer.def(e)) {
1608
+ e = e.substring(i.raw.length);
1609
+ let n = t.at(-1);
1610
+ 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] = {
1611
+ href: i.href,
1612
+ title: i.title
1613
+ }, t.push(i));
1614
+ continue;
1615
+ }
1616
+ if (i = this.tokenizer.table(e)) {
1617
+ e = e.substring(i.raw.length), t.push(i);
1618
+ continue;
1619
+ }
1620
+ if (i = this.tokenizer.lheading(e)) {
1621
+ e = e.substring(i.raw.length), t.push(i);
1622
+ continue;
1623
+ }
1624
+ let a = e;
1625
+ if (this.options.extensions?.startBlock) {
1626
+ let t = Infinity, n = e.slice(1), r;
1627
+ this.options.extensions.startBlock.forEach((e) => {
1628
+ r = e.call({ lexer: this }, n), typeof r == "number" && r >= 0 && (t = Math.min(t, r));
1629
+ }), t < Infinity && t >= 0 && (a = e.substring(0, t + 1));
1630
+ }
1631
+ if (this.state.top && (i = this.tokenizer.paragraph(a))) {
1632
+ let r = t.at(-1);
1633
+ 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);
1634
+ continue;
1635
+ }
1636
+ if (i = this.tokenizer.text(e)) {
1637
+ e = e.substring(i.raw.length);
1638
+ let n = t.at(-1);
1639
+ 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);
1640
+ continue;
1641
+ }
1642
+ if (e) {
1643
+ this.infiniteLoopError(e.charCodeAt(0));
1644
+ break;
1645
+ }
1646
+ }
1647
+ return this.state.top = !0, t;
1648
+ }
1649
+ inline(e, t = []) {
1650
+ return this.inlineQueue.push({
1651
+ src: e,
1652
+ tokens: t
1653
+ }), t;
1654
+ }
1655
+ inlineTokens(e, t = []) {
1656
+ this.tokenizer.lexer = this;
1657
+ let n = e, r = null;
1658
+ if (this.tokens.links) {
1659
+ let e = Object.keys(this.tokens.links);
1660
+ 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));
1661
+ }
1662
+ for (; (r = this.tokenizer.rules.inline.anyPunctuation.exec(n)) !== null;) n = n.slice(0, r.index) + "++" + n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);
1663
+ let i;
1664
+ 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);
1665
+ n = this.options.hooks?.emStrongMask?.call({ lexer: this }, n) ?? n;
1666
+ let a = !1, o = "", s = Infinity;
1667
+ for (; e;) {
1668
+ if (e.length < s) s = e.length;
1669
+ else {
1670
+ this.infiniteLoopError(e.charCodeAt(0));
1671
+ break;
1672
+ }
1673
+ a || (o = ""), a = !1;
1674
+ let r;
1675
+ 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;
1676
+ if (r = this.tokenizer.escape(e)) {
1677
+ e = e.substring(r.raw.length), t.push(r);
1678
+ continue;
1679
+ }
1680
+ if (r = this.tokenizer.tag(e)) {
1681
+ e = e.substring(r.raw.length), t.push(r);
1682
+ continue;
1683
+ }
1684
+ if (r = this.tokenizer.link(e)) {
1685
+ e = e.substring(r.raw.length), t.push(r);
1686
+ continue;
1687
+ }
1688
+ if (r = this.tokenizer.reflink(e, this.tokens.links)) {
1689
+ e = e.substring(r.raw.length);
1690
+ let n = t.at(-1);
1691
+ r.type === "text" && n?.type === "text" ? (n.raw += r.raw, n.text += r.text) : t.push(r);
1692
+ continue;
1693
+ }
1694
+ if (r = this.tokenizer.emStrong(e, n, o)) {
1695
+ e = e.substring(r.raw.length), t.push(r);
1696
+ continue;
1697
+ }
1698
+ if (r = this.tokenizer.codespan(e)) {
1699
+ e = e.substring(r.raw.length), t.push(r);
1700
+ continue;
1701
+ }
1702
+ if (r = this.tokenizer.br(e)) {
1703
+ e = e.substring(r.raw.length), t.push(r);
1704
+ continue;
1705
+ }
1706
+ if (r = this.tokenizer.del(e, n, o)) {
1707
+ e = e.substring(r.raw.length), t.push(r);
1708
+ continue;
1709
+ }
1710
+ if (r = this.tokenizer.autolink(e)) {
1711
+ e = e.substring(r.raw.length), t.push(r);
1712
+ continue;
1713
+ }
1714
+ if (!this.state.inLink && (r = this.tokenizer.url(e))) {
1715
+ e = e.substring(r.raw.length), t.push(r);
1716
+ continue;
1717
+ }
1718
+ let i = e;
1719
+ if (this.options.extensions?.startInline) {
1720
+ let t = Infinity, n = e.slice(1), r;
1721
+ this.options.extensions.startInline.forEach((e) => {
1722
+ r = e.call({ lexer: this }, n), typeof r == "number" && r >= 0 && (t = Math.min(t, r));
1723
+ }), t < Infinity && t >= 0 && (i = e.substring(0, t + 1));
1724
+ }
1725
+ if (r = this.tokenizer.inlineText(i)) {
1726
+ e = e.substring(r.raw.length), r.raw.slice(-1) !== "_" && (o = r.raw.slice(-1)), a = !0;
1727
+ let n = t.at(-1);
1728
+ n?.type === "text" ? (n.raw += r.raw, n.text += r.text) : t.push(r);
1729
+ continue;
1730
+ }
1731
+ if (e) {
1732
+ this.infiniteLoopError(e.charCodeAt(0));
1733
+ break;
1734
+ }
1735
+ }
1736
+ return t;
1737
+ }
1738
+ infiniteLoopError(e) {
1739
+ let t = "Infinite loop on byte: " + e;
1740
+ if (this.options.silent) console.error(t);
1741
+ else throw Error(t);
1742
+ }
1743
+ }, J = class {
1744
+ options;
1745
+ parser;
1746
+ constructor(e) {
1747
+ this.options = e || dt;
1748
+ }
1749
+ space(e) {
1750
+ return "";
1751
+ }
1752
+ code({ text: e, lang: t, escaped: n }) {
1753
+ let r = (t || "").match(A.notSpaceStart)?.[0], i = e.replace(A.endingNewline, "") + "\n";
1754
+ return r ? "<pre><code class=\"language-" + W(r) + "\">" + (n ? i : W(i, !0)) + "</code></pre>\n" : "<pre><code>" + (n ? i : W(i, !0)) + "</code></pre>\n";
1755
+ }
1756
+ blockquote({ tokens: e }) {
1757
+ return `<blockquote>
1758
+ ${this.parser.parse(e)}</blockquote>
1759
+ `;
1760
+ }
1761
+ html({ text: e }) {
1762
+ return e;
1763
+ }
1764
+ def(e) {
1765
+ return "";
1766
+ }
1767
+ heading({ tokens: e, depth: t }) {
1768
+ return `<h${t}>${this.parser.parseInline(e)}</h${t}>
1769
+ `;
1770
+ }
1771
+ hr(e) {
1772
+ return "<hr>\n";
1773
+ }
1774
+ list(e) {
1775
+ let t = e.ordered, n = e.start, r = "";
1776
+ for (let t = 0; t < e.items.length; t++) {
1777
+ let n = e.items[t];
1778
+ r += this.listitem(n);
1779
+ }
1780
+ let i = t ? "ol" : "ul", a = t && n !== 1 ? " start=\"" + n + "\"" : "";
1781
+ return "<" + i + a + ">\n" + r + "</" + i + ">\n";
1782
+ }
1783
+ listitem(e) {
1784
+ return `<li>${this.parser.parse(e.tokens)}</li>
1785
+ `;
1786
+ }
1787
+ checkbox({ checked: e }) {
1788
+ return "<input " + (e ? "checked=\"\" " : "") + "disabled=\"\" type=\"checkbox\"> ";
1789
+ }
1790
+ paragraph({ tokens: e }) {
1791
+ return `<p>${this.parser.parseInline(e)}</p>
1792
+ `;
1793
+ }
1794
+ table(e) {
1795
+ let t = "", n = "";
1796
+ for (let t = 0; t < e.header.length; t++) n += this.tablecell(e.header[t]);
1797
+ t += this.tablerow({ text: n });
1798
+ let r = "";
1799
+ for (let t = 0; t < e.rows.length; t++) {
1800
+ let i = e.rows[t];
1801
+ n = "";
1802
+ for (let e = 0; e < i.length; e++) n += this.tablecell(i[e]);
1803
+ r += this.tablerow({ text: n });
1804
+ }
1805
+ return r &&= `<tbody>${r}</tbody>`, "<table>\n<thead>\n" + t + "</thead>\n" + r + "</table>\n";
1806
+ }
1807
+ tablerow({ text: e }) {
1808
+ return `<tr>
1809
+ ${e}</tr>
1810
+ `;
1811
+ }
1812
+ tablecell(e) {
1813
+ let t = this.parser.parseInline(e.tokens), n = e.header ? "th" : "td";
1814
+ return (e.align ? `<${n} align="${e.align}">` : `<${n}>`) + t + `</${n}>
1815
+ `;
1816
+ }
1817
+ strong({ tokens: e }) {
1818
+ return `<strong>${this.parser.parseInline(e)}</strong>`;
1819
+ }
1820
+ em({ tokens: e }) {
1821
+ return `<em>${this.parser.parseInline(e)}</em>`;
1822
+ }
1823
+ codespan({ text: e }) {
1824
+ return `<code>${W(e, !0)}</code>`;
1825
+ }
1826
+ br(e) {
1827
+ return "<br>";
1828
+ }
1829
+ del({ tokens: e }) {
1830
+ return `<del>${this.parser.parseInline(e)}</del>`;
1831
+ }
1832
+ link({ href: e, title: t, tokens: n }) {
1833
+ let r = this.parser.parseInline(n), i = dn(e);
1834
+ if (i === null) return r;
1835
+ e = i;
1836
+ let a = "<a href=\"" + e + "\"";
1837
+ return t && (a += " title=\"" + W(t) + "\""), a += ">" + r + "</a>", a;
1838
+ }
1839
+ image({ href: e, title: t, text: n, tokens: r }) {
1840
+ r && (n = this.parser.parseInline(r, this.parser.textRenderer));
1841
+ let i = dn(e);
1842
+ if (i === null) return W(n);
1843
+ e = i;
1844
+ let a = `<img src="${e}" alt="${W(n)}"`;
1845
+ return t && (a += ` title="${W(t)}"`), a += ">", a;
1846
+ }
1847
+ text(e) {
1848
+ return "tokens" in e && e.tokens ? this.parser.parseInline(e.tokens) : "escaped" in e && e.escaped ? e.text : W(e.text);
1849
+ }
1850
+ }, vn = class {
1851
+ strong({ text: e }) {
1852
+ return e;
1853
+ }
1854
+ em({ text: e }) {
1855
+ return e;
1856
+ }
1857
+ codespan({ text: e }) {
1858
+ return e;
1859
+ }
1860
+ del({ text: e }) {
1861
+ return e;
1862
+ }
1863
+ html({ text: e }) {
1864
+ return e;
1865
+ }
1866
+ text({ text: e }) {
1867
+ return e;
1868
+ }
1869
+ link({ text: e }) {
1870
+ return "" + e;
1871
+ }
1872
+ image({ text: e }) {
1873
+ return "" + e;
1874
+ }
1875
+ br() {
1876
+ return "";
1877
+ }
1878
+ checkbox({ raw: e }) {
1879
+ return e;
1880
+ }
1881
+ }, Y = class e {
1882
+ options;
1883
+ renderer;
1884
+ textRenderer;
1885
+ constructor(e) {
1886
+ this.options = e || dt, this.options.renderer = this.options.renderer || new J(), this.renderer = this.options.renderer, this.renderer.options = this.options, this.renderer.parser = this, this.textRenderer = new vn();
1887
+ }
1888
+ static parse(t, n) {
1889
+ return new e(n).parse(t);
1890
+ }
1891
+ static parseInline(t, n) {
1892
+ return new e(n).parseInline(t);
1893
+ }
1894
+ parse(e) {
1895
+ this.renderer.parser = this;
1896
+ let t = "";
1897
+ for (let n = 0; n < e.length; n++) {
1898
+ let r = e[n];
1899
+ if (this.options.extensions?.renderers?.[r.type]) {
1900
+ let e = r, n = this.options.extensions.renderers[e.type].call({ parser: this }, e);
1901
+ if (n !== !1 || ![
1902
+ "space",
1903
+ "hr",
1904
+ "heading",
1905
+ "code",
1906
+ "table",
1907
+ "blockquote",
1908
+ "list",
1909
+ "html",
1910
+ "def",
1911
+ "paragraph",
1912
+ "text"
1913
+ ].includes(e.type)) {
1914
+ t += n || "";
1915
+ continue;
1916
+ }
1917
+ }
1918
+ let i = r;
1919
+ switch (i.type) {
1920
+ case "space":
1921
+ t += this.renderer.space(i);
1922
+ break;
1923
+ case "hr":
1924
+ t += this.renderer.hr(i);
1925
+ break;
1926
+ case "heading":
1927
+ t += this.renderer.heading(i);
1928
+ break;
1929
+ case "code":
1930
+ t += this.renderer.code(i);
1931
+ break;
1932
+ case "table":
1933
+ t += this.renderer.table(i);
1934
+ break;
1935
+ case "blockquote":
1936
+ t += this.renderer.blockquote(i);
1937
+ break;
1938
+ case "list":
1939
+ t += this.renderer.list(i);
1940
+ break;
1941
+ case "checkbox":
1942
+ t += this.renderer.checkbox(i);
1943
+ break;
1944
+ case "html":
1945
+ t += this.renderer.html(i);
1946
+ break;
1947
+ case "def":
1948
+ t += this.renderer.def(i);
1949
+ break;
1950
+ case "paragraph":
1951
+ t += this.renderer.paragraph(i);
1952
+ break;
1953
+ case "text":
1954
+ t += this.renderer.text(i);
1955
+ break;
1956
+ default: {
1957
+ let e = "Token with \"" + i.type + "\" type was not found.";
1958
+ if (this.options.silent) return console.error(e), "";
1959
+ throw Error(e);
1960
+ }
1961
+ }
1962
+ }
1963
+ return t;
1964
+ }
1965
+ parseInline(e, t = this.renderer) {
1966
+ this.renderer.parser = this;
1967
+ let n = "";
1968
+ for (let r = 0; r < e.length; r++) {
1969
+ let i = e[r];
1970
+ if (this.options.extensions?.renderers?.[i.type]) {
1971
+ let e = this.options.extensions.renderers[i.type].call({ parser: this }, i);
1972
+ if (e !== !1 || ![
1973
+ "escape",
1974
+ "html",
1975
+ "link",
1976
+ "image",
1977
+ "strong",
1978
+ "em",
1979
+ "codespan",
1980
+ "br",
1981
+ "del",
1982
+ "text"
1983
+ ].includes(i.type)) {
1984
+ n += e || "";
1985
+ continue;
1986
+ }
1987
+ }
1988
+ let a = i;
1989
+ switch (a.type) {
1990
+ case "escape":
1991
+ n += t.text(a);
1992
+ break;
1993
+ case "html":
1994
+ n += t.html(a);
1995
+ break;
1996
+ case "link":
1997
+ n += t.link(a);
1998
+ break;
1999
+ case "image":
2000
+ n += t.image(a);
2001
+ break;
2002
+ case "checkbox":
2003
+ n += t.checkbox(a);
2004
+ break;
2005
+ case "strong":
2006
+ n += t.strong(a);
2007
+ break;
2008
+ case "em":
2009
+ n += t.em(a);
2010
+ break;
2011
+ case "codespan":
2012
+ n += t.codespan(a);
2013
+ break;
2014
+ case "br":
2015
+ n += t.br(a);
2016
+ break;
2017
+ case "del":
2018
+ n += t.del(a);
2019
+ break;
2020
+ case "text":
2021
+ n += t.text(a);
2022
+ break;
2023
+ default: {
2024
+ let e = "Token with \"" + a.type + "\" type was not found.";
2025
+ if (this.options.silent) return console.error(e), "";
2026
+ throw Error(e);
2027
+ }
2028
+ }
2029
+ }
2030
+ return n;
2031
+ }
2032
+ }, yn = class {
2033
+ options;
2034
+ block;
2035
+ constructor(e) {
2036
+ this.options = e || dt;
2037
+ }
2038
+ static passThroughHooks = /* @__PURE__ */ new Set([
2039
+ "preprocess",
2040
+ "postprocess",
2041
+ "processAllTokens",
2042
+ "emStrongMask"
2043
+ ]);
2044
+ static passThroughHooksRespectAsync = /* @__PURE__ */ new Set([
2045
+ "preprocess",
2046
+ "postprocess",
2047
+ "processAllTokens"
2048
+ ]);
2049
+ preprocess(e) {
2050
+ return e;
2051
+ }
2052
+ postprocess(e) {
2053
+ return e;
2054
+ }
2055
+ processAllTokens(e) {
2056
+ return e;
2057
+ }
2058
+ emStrongMask(e) {
2059
+ return e;
2060
+ }
2061
+ provideLexer(e = this.block) {
2062
+ return e ? q.lex : q.lexInline;
2063
+ }
2064
+ provideParser(e = this.block) {
2065
+ return e ? Y.parse : Y.parseInline;
2066
+ }
2067
+ }, X = new class {
2068
+ defaults = ut();
2069
+ options = this.setOptions;
2070
+ parse = this.parseMarkdown(!0);
2071
+ parseInline = this.parseMarkdown(!1);
2072
+ Parser = Y;
2073
+ Renderer = J;
2074
+ TextRenderer = vn;
2075
+ Lexer = q;
2076
+ Tokenizer = K;
2077
+ Hooks = yn;
2078
+ constructor(...e) {
2079
+ this.use(...e);
2080
+ }
2081
+ walkTokens(e, t) {
2082
+ let n = [];
2083
+ for (let r of e) switch (n = n.concat(t.call(this, r)), r.type) {
2084
+ case "table": {
2085
+ let e = r;
2086
+ for (let r of e.header) n = n.concat(this.walkTokens(r.tokens, t));
2087
+ for (let r of e.rows) for (let e of r) n = n.concat(this.walkTokens(e.tokens, t));
2088
+ break;
2089
+ }
2090
+ case "list": {
2091
+ let e = r;
2092
+ n = n.concat(this.walkTokens(e.items, t));
2093
+ break;
2094
+ }
2095
+ default: {
2096
+ let e = r;
2097
+ this.defaults.extensions?.childTokens?.[e.type] ? this.defaults.extensions.childTokens[e.type].forEach((r) => {
2098
+ let i = e[r].flat(Infinity);
2099
+ n = n.concat(this.walkTokens(i, t));
2100
+ }) : e.tokens && (n = n.concat(this.walkTokens(e.tokens, t)));
2101
+ }
2102
+ }
2103
+ return n;
2104
+ }
2105
+ use(...e) {
2106
+ let t = this.defaults.extensions || {
2107
+ renderers: {},
2108
+ childTokens: {}
2109
+ };
2110
+ return e.forEach((e) => {
2111
+ let n = { ...e };
2112
+ if (n.async = this.defaults.async || n.async || !1, e.extensions && (e.extensions.forEach((e) => {
2113
+ if (!e.name) throw Error("extension name required");
2114
+ if ("renderer" in e) {
2115
+ let n = t.renderers[e.name];
2116
+ n ? t.renderers[e.name] = function(...t) {
2117
+ let r = e.renderer.apply(this, t);
2118
+ return r === !1 && (r = n.apply(this, t)), r;
2119
+ } : t.renderers[e.name] = e.renderer;
2120
+ }
2121
+ if ("tokenizer" in e) {
2122
+ if (!e.level || e.level !== "block" && e.level !== "inline") throw Error("extension level must be 'block' or 'inline'");
2123
+ let n = t[e.level];
2124
+ 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]));
2125
+ }
2126
+ "childTokens" in e && e.childTokens && (t.childTokens[e.name] = e.childTokens);
2127
+ }), n.extensions = t), e.renderer) {
2128
+ let t = this.defaults.renderer || new J(this.defaults);
2129
+ for (let n in e.renderer) {
2130
+ if (!(n in t)) throw Error(`renderer '${n}' does not exist`);
2131
+ if (["options", "parser"].includes(n)) continue;
2132
+ let r = n, i = e.renderer[r], a = t[r];
2133
+ t[r] = (...e) => {
2134
+ let n = i.apply(t, e);
2135
+ return n === !1 && (n = a.apply(t, e)), n || "";
2136
+ };
2137
+ }
2138
+ n.renderer = t;
2139
+ }
2140
+ if (e.tokenizer) {
2141
+ let t = this.defaults.tokenizer || new K(this.defaults);
2142
+ for (let n in e.tokenizer) {
2143
+ if (!(n in t)) throw Error(`tokenizer '${n}' does not exist`);
2144
+ if ([
2145
+ "options",
2146
+ "rules",
2147
+ "lexer"
2148
+ ].includes(n)) continue;
2149
+ let r = n, i = e.tokenizer[r], a = t[r];
2150
+ t[r] = (...e) => {
2151
+ let n = i.apply(t, e);
2152
+ return n === !1 && (n = a.apply(t, e)), n;
2153
+ };
2154
+ }
2155
+ n.tokenizer = t;
2156
+ }
2157
+ if (e.hooks) {
2158
+ let t = this.defaults.hooks || new yn();
2159
+ for (let n in e.hooks) {
2160
+ if (!(n in t)) throw Error(`hook '${n}' does not exist`);
2161
+ if (["options", "block"].includes(n)) continue;
2162
+ let r = n, i = e.hooks[r], a = t[r];
2163
+ yn.passThroughHooks.has(n) ? t[r] = (e) => {
2164
+ if (this.defaults.async && yn.passThroughHooksRespectAsync.has(n)) return (async () => {
2165
+ let n = await i.call(t, e);
2166
+ return a.call(t, n);
2167
+ })();
2168
+ let r = i.call(t, e);
2169
+ return a.call(t, r);
2170
+ } : t[r] = (...e) => {
2171
+ if (this.defaults.async) return (async () => {
2172
+ let n = await i.apply(t, e);
2173
+ return n === !1 && (n = await a.apply(t, e)), n;
2174
+ })();
2175
+ let n = i.apply(t, e);
2176
+ return n === !1 && (n = a.apply(t, e)), n;
2177
+ };
2178
+ }
2179
+ n.hooks = t;
2180
+ }
2181
+ if (e.walkTokens) {
2182
+ let t = this.defaults.walkTokens, r = e.walkTokens;
2183
+ n.walkTokens = function(e) {
2184
+ let n = [];
2185
+ return n.push(r.call(this, e)), t && (n = n.concat(t.call(this, e))), n;
2186
+ };
2187
+ }
2188
+ this.defaults = {
2189
+ ...this.defaults,
2190
+ ...n
2191
+ };
2192
+ }), this;
2193
+ }
2194
+ setOptions(e) {
2195
+ return this.defaults = {
2196
+ ...this.defaults,
2197
+ ...e
2198
+ }, this;
2199
+ }
2200
+ lexer(e, t) {
2201
+ return q.lex(e, t ?? this.defaults);
2202
+ }
2203
+ parser(e, t) {
2204
+ return Y.parse(e, t ?? this.defaults);
2205
+ }
2206
+ parseMarkdown(e) {
2207
+ return (t, n) => {
2208
+ let r = { ...n }, i = {
2209
+ ...this.defaults,
2210
+ ...r
2211
+ }, a = this.onError(!!i.silent, !!i.async);
2212
+ 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."));
2213
+ if (typeof t > "u" || t === null) return a(/* @__PURE__ */ Error("marked(): input parameter is undefined or null"));
2214
+ if (typeof t != "string") return a(/* @__PURE__ */ Error("marked(): input parameter is of type " + Object.prototype.toString.call(t) + ", string expected"));
2215
+ if (i.hooks && (i.hooks.options = i, i.hooks.block = e), i.async) return (async () => {
2216
+ let n = i.hooks ? await i.hooks.preprocess(t) : t, r = await (i.hooks ? await i.hooks.provideLexer(e) : e ? q.lex : q.lexInline)(n, i), a = i.hooks ? await i.hooks.processAllTokens(r) : r;
2217
+ i.walkTokens && await Promise.all(this.walkTokens(a, i.walkTokens));
2218
+ let o = await (i.hooks ? await i.hooks.provideParser(e) : e ? Y.parse : Y.parseInline)(a, i);
2219
+ return i.hooks ? await i.hooks.postprocess(o) : o;
2220
+ })().catch(a);
2221
+ try {
2222
+ i.hooks && (t = i.hooks.preprocess(t));
2223
+ let n = (i.hooks ? i.hooks.provideLexer(e) : e ? q.lex : q.lexInline)(t, i);
2224
+ i.hooks && (n = i.hooks.processAllTokens(n)), i.walkTokens && this.walkTokens(n, i.walkTokens);
2225
+ let r = (i.hooks ? i.hooks.provideParser(e) : e ? Y.parse : Y.parseInline)(n, i);
2226
+ return i.hooks && (r = i.hooks.postprocess(r)), r;
2227
+ } catch (e) {
2228
+ return a(e);
2229
+ }
2230
+ };
2231
+ }
2232
+ onError(e, t) {
2233
+ return (n) => {
2234
+ if (n.message += "\nPlease report this to https://github.com/markedjs/marked.", e) {
2235
+ let e = "<p>An error occurred:</p><pre>" + W(n.message + "", !0) + "</pre>";
2236
+ return t ? Promise.resolve(e) : e;
2237
+ }
2238
+ if (t) return Promise.reject(n);
2239
+ throw n;
2240
+ };
2241
+ }
2242
+ }();
2243
+ function Z(e, t) {
2244
+ return X.parse(e, t);
2245
+ }
2246
+ Z.options = Z.setOptions = function(e) {
2247
+ return X.setOptions(e), Z.defaults = X.defaults, ft(Z.defaults), Z;
2248
+ }, Z.getDefaults = ut, Z.defaults = dt, Z.use = function(...e) {
2249
+ return X.use(...e), Z.defaults = X.defaults, ft(Z.defaults), Z;
2250
+ }, Z.walkTokens = function(e, t) {
2251
+ return X.walkTokens(e, t);
2252
+ }, Z.parseInline = X.parseInline, Z.Parser = Y, Z.parser = Y.parse, Z.Renderer = J, Z.TextRenderer = vn, Z.Lexer = q, Z.lexer = q.lex, Z.Tokenizer = K, Z.Hooks = yn, Z.parse = Z, Z.options, Z.setOptions, Z.use, Z.walkTokens, Z.parseInline, Y.parse, q.lex;
2253
+ //#endregion
2254
+ //#region src/components/ai-chat/ai-chat.module.scss?inline
2255
+ var bn = ":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));--chat-message-font-family:var(--luzmo-ai-chat-assistant-message-font-family,var(--ai-chat-assistant-message-font-family));--luzmo-chat-message-font-family:var(--luzmo-ai-chat-assistant-message-font-family,var(--ai-chat-assistant-message-font-family));--chat-message-font-size:var(--luzmo-ai-chat-assistant-message-font-size,var(--ai-chat-assistant-message-font-size));--luzmo-chat-message-font-size:var(--luzmo-ai-chat-assistant-message-font-size,var(--ai-chat-assistant-message-font-size));--chat-message-line-height:var(--luzmo-ai-chat-assistant-message-line-height,var(--ai-chat-assistant-message-line-height));--luzmo-chat-message-line-height:var(--luzmo-ai-chat-assistant-message-line-height,var(--ai-chat-assistant-message-line-height));flex-direction:column;display:flex}: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;justify-content:center;align-items:center;padding:0;font-size:.875rem;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 luzmo-progress-steps{padding:0 .25rem}: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,1rem));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:1rem;--ai-chat-border:none;--ai-chat-box-shadow:none;--ai-chat-loading-message-color:var(--luzmo-primary);--ai-chat-loading-message-icon-font-size:1rem;--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:1.5rem;--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-s,12px);--ai-chat-assistant-message-line-height:var(--ai-chat-markdown-line-height);--ai-chat-user-message-attachment-size:64px}", xn = ":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-strong,600);--ai-chat-empty-state-title-line-height:1.4;--ai-chat-empty-state-title-color:var(--luzmo-font-color);--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))}", Sn = class extends e {
2256
+ constructor(...e) {
2257
+ super(...e), this.title = o("What can I help you with?", { desc: "Title for the AI chat empty state" }), this.subtitle = "", this.suggestions = [], this.disabled = !1;
2258
+ }
2259
+ static {
2260
+ this.styles = ee(xn);
2261
+ }
2262
+ static {
2263
+ this.tagName = "luzmo-ai-chat-empty-state";
2264
+ }
2265
+ _handleSuggestionActivate(e) {
2266
+ if (this.disabled) return;
2267
+ let t = e.prompt ?? e.label;
2268
+ this.dispatchEvent(new CustomEvent("luzmo-suggestion-selected", {
2269
+ detail: {
2270
+ label: e.label,
2271
+ prompt: t,
2272
+ selectedDatasets: e.selectedDatasets
2273
+ },
2274
+ bubbles: !0,
2275
+ composed: !0
2276
+ }));
2277
+ }
2278
+ render() {
2279
+ let e = this.suggestions.length > 0;
2280
+ return u`
2281
+ <section class="empty-state" aria-labelledby="ai-chat-empty-state-title">
2282
+ <header class="header">
2283
+ <h2 id="ai-chat-empty-state-title" class="title">${this.title}</h2>
2284
+ </header>
2285
+
2286
+ ${e ? u`
2287
+ <div class="actions">
2288
+ ${this.subtitle ? u`<p class="subtitle">${this.subtitle}</p>` : d}
2289
+ <div
2290
+ class="suggestions"
2291
+ role="group"
2292
+ aria-label=${o("Prompt suggestions", { desc: "Accessible label for the AI chat empty state suggestion list" })}
2293
+ >
2294
+ ${this.suggestions.map((e) => u`
2295
+ <luzmo-action-button
2296
+ variant="accent"
2297
+ size="s"
2298
+ ?disabled=${this.disabled}
2299
+ @click=${() => this._handleSuggestionActivate(e)}
2300
+ >
2301
+ ${e.label}
2302
+ </luzmo-action-button>
2303
+ `)}
2304
+ </div>
2305
+ </div>
2306
+ ` : d}
2307
+ </section>
2308
+ `;
2309
+ }
2310
+ };
2311
+ //#endregion
2312
+ //#region src/components/ai-chat/empty-state/index.ts
2313
+ t([f({ type: String })], Sn.prototype, "title", void 0), t([f({ type: String })], Sn.prototype, "subtitle", void 0), t([f({ type: Array })], Sn.prototype, "suggestions", void 0), t([f({
2314
+ type: Boolean,
2315
+ reflect: !0
2316
+ })], Sn.prototype, "disabled", void 0), customElements.get("luzmo-ai-chat-empty-state") || customElements.define("luzmo-ai-chat-empty-state", Sn);
2317
+ //#endregion
2318
+ //#region src/components/ai-chat/ai-chat-request.ts
2319
+ function Cn(e, t) {
2320
+ return `${e.replace(/\/+$/, "")}/${t.replace(/^\/+|\/+$/g, "")}/aiprompt`;
2321
+ }
2322
+ function wn(e) {
2323
+ return e.type === "placeholder" ? null : {
2324
+ ...e,
2325
+ version: e.version || "",
2326
+ title: e.title || e.options?.title,
2327
+ filters: e.filterGroups || [],
2328
+ aichartId: e.aichartId || ""
2329
+ };
2330
+ }
2331
+ function Tn(e, t, n = []) {
2332
+ return [
2333
+ {
2334
+ type: "text",
2335
+ text: e
2336
+ },
2337
+ ...t.map((e) => ({
2338
+ type: "dataset",
2339
+ id: e
2340
+ })),
2341
+ ...n.map((e) => ({
2342
+ type: "image",
2343
+ url: e
2344
+ }))
2345
+ ];
2346
+ }
2347
+ function En(e, t, n) {
2348
+ return {
2349
+ agent: e,
2350
+ task: t,
2351
+ stream: n.stream ?? !0,
2352
+ response_mode: "mixed",
2353
+ ...n.conversationId ? { conversation_id: n.conversationId } : {},
2354
+ ...n.localeId ? { locale_id: n.localeId } : {}
2355
+ };
2356
+ }
2357
+ function Dn(e) {
2358
+ let t = Tn(e.prompt, e.datasetIds, e.attachmentUrls), n = e.chart ? wn(e.chart) : null;
2359
+ return n && t.push({
2360
+ type: "item",
2361
+ value: n
2362
+ }), {
2363
+ ...En("item", e.task ?? "generate", e),
2364
+ input: t
2365
+ };
2366
+ }
2367
+ function On(e) {
2368
+ let t = Tn(e.prompt, e.datasetIds, e.attachmentUrls);
2369
+ return e.dashboard && t.push({
2370
+ type: "dashboard",
2371
+ value: e.dashboard,
2372
+ ...e.currentScreenMode ? { current_screen_mode: e.currentScreenMode } : {}
2373
+ }), {
2374
+ ...En("dashboard", "generate", e),
2375
+ timezone_id: e.timezoneId ?? "UTC",
2376
+ input: t
2377
+ };
2378
+ }
2379
+ function kn(e) {
2380
+ return {
2381
+ ...En("analyst", "generate", e),
2382
+ input: Tn(e.prompt, e.datasetIds, e.attachmentUrls)
2383
+ };
2384
+ }
2385
+ function An(e, t) {
2386
+ switch (e) {
2387
+ case "dashboard": return On(t);
2388
+ case "analyst": return kn(t);
2389
+ default: return Dn(t);
2390
+ }
2391
+ }
2392
+ function jn(e, t) {
2393
+ let { authKey: n, authToken: i, apiVersion: a = "0.1.0" } = t;
2394
+ return t.attachmentUrls?.length && r(t.attachmentUrls), {
2395
+ key: n,
2396
+ token: i,
2397
+ action: "create",
2398
+ version: a,
2399
+ properties: An(e, t)
2400
+ };
2401
+ }
2402
+ function Mn(e, t, n, r = "0.1.0", i = null) {
2403
+ return {
2404
+ key: t,
2405
+ token: n,
2406
+ action: "delete",
2407
+ version: r,
2408
+ properties: {
2409
+ agent: "item",
2410
+ restore_to_message_id: e,
2411
+ ...i ? { conversation_id: i } : {}
2412
+ }
2413
+ };
2414
+ }
2415
+ //#endregion
2416
+ //#region src/components/ai-chat/stream/transport.ts
2417
+ async function Nn(e) {
2418
+ let t = await fetch(e.url, {
2419
+ method: "POST",
2420
+ headers: { "Content-Type": "application/json" },
2421
+ mode: "cors",
2422
+ body: JSON.stringify(e.body),
2423
+ signal: e.signal
2424
+ });
2425
+ if (!t.ok) {
2426
+ let e = await t.json().catch(() => null);
2427
+ throw Error(e?.message || `API request failed with status ${t.status}`);
2428
+ }
2429
+ if (!t.body) throw Error("Response body is not readable");
2430
+ return {
2431
+ body: t.body,
2432
+ conversationId: t.headers.get("x-conversation-id")
2433
+ };
2434
+ }
2435
+ function Pn(e) {
2436
+ let t = e.trim();
2437
+ if (!t || t.startsWith(":") || t.startsWith("event:") || t.startsWith("id:")) return null;
2438
+ let n = t;
2439
+ return n.startsWith("data:") && (n = n.slice(5).trimStart()), !n || n === "[DONE]" ? null : JSON.parse(n);
2440
+ }
2441
+ function Fn(e, t) {
2442
+ try {
2443
+ let n = Pn(e);
2444
+ n && t(n);
2445
+ } catch {
2446
+ console.error("Failed to parse stream line");
2447
+ }
2448
+ }
2449
+ async function In(e, t) {
2450
+ let n = e.getReader(), r = new TextDecoder(), i = "";
2451
+ try {
2452
+ for (;;) {
2453
+ let { done: e, value: a } = await n.read();
2454
+ if (e) break;
2455
+ i += r.decode(a, { stream: !0 });
2456
+ let o = i.split(/\r?\n/);
2457
+ i = o.pop() ?? "";
2458
+ for (let e of o) Fn(e, t);
2459
+ }
2460
+ i += r.decode();
2461
+ let e = i.trim();
2462
+ e && Fn(e, t);
2463
+ } finally {
2464
+ n.releaseLock();
2465
+ }
2466
+ }
2467
+ //#endregion
2468
+ //#region src/components/ai-chat/stream/progress.ts
2469
+ function Ln() {
2470
+ return {
2471
+ id: "root",
2472
+ step: "root",
2473
+ status: "pending",
2474
+ children: [{
2475
+ id: "client-init",
2476
+ step: "iqInit",
2477
+ status: "inProgress",
2478
+ description: o("Thinking", { desc: "Label shown in the AI chat progress tree while the assistant starts processing a prompt" })
2479
+ }]
2480
+ };
2481
+ }
2482
+ function Rn(e) {
2483
+ let t = e.progress;
2484
+ return typeof t != "object" || !t ? !1 : "id" in t && "step" in t && "status" in t;
2485
+ }
2486
+ //#endregion
2487
+ //#region src/components/ai-chat/stream/chunk-extractors.ts
2488
+ function zn(e) {
2489
+ if (!e || typeof e != "object") return "";
2490
+ let t = e.assistant_message;
2491
+ if (!t || typeof t != "object") return "";
2492
+ if (typeof t.message == "string") return t.message;
2493
+ if (typeof t.text == "string") return t.text;
2494
+ if (typeof t.summary == "string") return t.summary;
2495
+ let n = t.content;
2496
+ return typeof n == "string" ? n : n && typeof n == "object" && typeof n.text == "string" ? n.text : "";
2497
+ }
2498
+ function Bn(e) {
2499
+ 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 : "";
2500
+ }
2501
+ function Vn(e) {
2502
+ return zn(e.result);
2503
+ }
2504
+ function Hn(e) {
2505
+ return !!e.done || e.type === "finish" || e.type === "done" || "question" in e;
2506
+ }
2507
+ function Un(e, t) {
2508
+ let n = typeof e.conversation_id == "string" && e.conversation_id || typeof e.conversationId == "string" && e.conversationId;
2509
+ n && t.callbacks.onConversationIdChange(n);
2510
+ }
2511
+ function Wn(e) {
2512
+ for (let t of e) if (t && typeof t == "object" && t.type === "item") {
2513
+ let e = t.value;
2514
+ if (e && typeof e == "object") return e;
2515
+ }
2516
+ return null;
2517
+ }
2518
+ function Gn(e) {
2519
+ let t = e.chart ?? e.generatedChart;
2520
+ if (t && typeof t == "object") return t;
2521
+ let n = e.aiMessageAssets ?? e.ai_message_assets;
2522
+ if (Array.isArray(n)) {
2523
+ let e = Wn(n);
2524
+ if (e) return e;
2525
+ }
2526
+ let r = e.result;
2527
+ if (r && typeof r == "object") {
2528
+ let e = r.assistant_message, t = e?.aiMessageAssets ?? e?.ai_message_assets;
2529
+ if (Array.isArray(t)) return Wn(t);
2530
+ }
2531
+ return null;
2532
+ }
2533
+ function Kn(e) {
2534
+ for (let t of e) if (t && typeof t == "object" && t.type === "dashboard") {
2535
+ let e = t.value;
2536
+ if (e && typeof e == "object" && Array.isArray(e.views)) return e;
2537
+ }
2538
+ return null;
2539
+ }
2540
+ function qn(e) {
2541
+ for (let t of e) if (t && typeof t == "object" && t.type === "dashboard") {
2542
+ let e = t.name;
2543
+ if (e && typeof e == "object") return e;
2544
+ }
2545
+ }
2546
+ function Jn(...e) {
2547
+ return e.find(Array.isArray);
2548
+ }
2549
+ function Yn(e) {
2550
+ if (e.views && Array.isArray(e.views)) return e;
2551
+ let t = e.aiMessageAssets ?? e.ai_message_assets;
2552
+ if (Array.isArray(t)) return Kn(t);
2553
+ let n = e.result;
2554
+ if (n && typeof n == "object") {
2555
+ let e = n.assistant_message, t = e?.aiMessageAssets ?? e?.ai_message_assets;
2556
+ if (Array.isArray(t)) return Kn(t);
2557
+ }
2558
+ return null;
2559
+ }
2560
+ function Xn(e) {
2561
+ let t = e.aiMessageAssets ?? e.ai_message_assets, n = e.result?.assistant_message, r = Jn(t, n?.aiMessageAssets ?? n?.ai_message_assets);
2562
+ return r ? qn(r) : void 0;
2563
+ }
2564
+ //#endregion
2565
+ //#region src/components/ai-chat/stream/stream-processor.ts
2566
+ var Zn = /* @__PURE__ */ new Set([
2567
+ "conversation-id",
2568
+ "conversation_id",
2569
+ "keepalive",
2570
+ "ping",
2571
+ "finish",
2572
+ "done"
2573
+ ]);
2574
+ function Qn(e, t, n) {
2575
+ return {
2576
+ agent: n.agent,
2577
+ conversationId: t.callbacks.getConversationId(),
2578
+ ...typeof e.messageId == "string" ? { messageId: e.messageId } : {},
2579
+ raw: e
2580
+ };
2581
+ }
2582
+ function Q(e, t, n, r, i) {
2583
+ let a = {
2584
+ ...Qn(n, e, t),
2585
+ recognized: !0,
2586
+ type: r,
2587
+ data: i
2588
+ };
2589
+ e.callbacks.onStep(a);
2590
+ }
2591
+ function $n(e, t, n, r, i) {
2592
+ let a = {
2593
+ ...Qn(n, e, t),
2594
+ recognized: !1,
2595
+ type: r,
2596
+ data: i
2597
+ };
2598
+ e.callbacks.onStep(a);
2599
+ }
2600
+ function er(e) {
2601
+ e.state.progressCollapsed || (e.state.progressCollapsed = !0, e.callbacks.onProgressCollapsed(!0));
2602
+ }
2603
+ function tr(e, t) {
2604
+ er(e), e.aiMessage.message = (e.aiMessage.message || "") + t, e.callbacks.onMessageUpdate(e.aiMessage);
2605
+ }
2606
+ function nr(e) {
2607
+ if (!e) return null;
2608
+ let t = e.descriptionMetadata?.decision;
2609
+ if (t === "create" || t === "edit" || t === "question") return t;
2610
+ for (let t of e.children ?? []) {
2611
+ let e = nr(t);
2612
+ if (e) return e;
2613
+ }
2614
+ return null;
2615
+ }
2616
+ function rr(e, t, n) {
2617
+ if (!Rn(e)) return !1;
2618
+ let r = e.progress;
2619
+ if (t.callbacks.onProgress(r), Q(t, n, e, "progress", r), t.state.decision === null) {
2620
+ let i = nr(r);
2621
+ i && (t.state.decision = i, Q(t, n, e, "decision", { decision: i }));
2622
+ }
2623
+ return !0;
2624
+ }
2625
+ function ir(e) {
2626
+ return !!e.error || e.type === "error" || typeof e.error_text == "string";
2627
+ }
2628
+ function ar(e) {
2629
+ return typeof e.error_text == "string" && e.error_text ? e.error_text : typeof e.error == "string" && e.error ? e.error : o("Something went wrong. Please try again.", { desc: "Generic error message shown in ai chat when the API request fails" });
2630
+ }
2631
+ function or(e, t, n) {
2632
+ if (!ir(e)) return !1;
2633
+ let r = ar(e);
2634
+ return t.aiMessage.message = r, t.aiMessage.isError = !0, t.callbacks.onMessageUpdate(t.aiMessage), Dr(e, t, n, e.error ?? r), !0;
2635
+ }
2636
+ function sr(e) {
2637
+ return typeof e.question == "string" && e.question ? e.question : typeof e.text == "string" && e.text ? e.text : "";
2638
+ }
2639
+ function cr(e, t, n) {
2640
+ if (e.type !== "interrupt") return !1;
2641
+ let r = sr(e);
2642
+ return r && (t.state.interruptQuestion = r, tr(t, r), Q(t, n, e, "interrupt", { question: r })), Dr(e, t, n), !0;
2643
+ }
2644
+ function lr(e) {
2645
+ return typeof e.asset_id == "string" ? e.asset_id : typeof e.asset_type == "string" ? e.asset_type : "default";
2646
+ }
2647
+ function ur(e) {
2648
+ return typeof e.asset_type == "string" ? e.asset_type : "";
2649
+ }
2650
+ function dr(e) {
2651
+ return {
2652
+ assetType: ur(e),
2653
+ snapshot: {}
2654
+ };
2655
+ }
2656
+ function fr(e, t) {
2657
+ return {
2658
+ ...e,
2659
+ ...t
2660
+ };
2661
+ }
2662
+ function pr(e) {
2663
+ let t = e.asset_delta ?? e.delta;
2664
+ return t && typeof t == "object" ? t : null;
2665
+ }
2666
+ function mr(e, t) {
2667
+ t.state.assets[lr(e)] = dr(e);
2668
+ }
2669
+ function hr(e, t) {
2670
+ let n = lr(e), r = t.state.assets[n] ?? dr(e), i = pr(e);
2671
+ i && (r.snapshot = fr(r.snapshot, i)), t.state.assets[n] = r;
2672
+ }
2673
+ function gr(e, t) {
2674
+ let n = e.asset ?? e.value ?? e.asset_delta ?? e.delta;
2675
+ return n && typeof n == "object" ? fr(t?.snapshot ?? {}, n) : t?.snapshot ?? {};
2676
+ }
2677
+ function _r(e, t, n) {
2678
+ let r = lr(e), i = t.state.assets[r], a = i?.assetType || ur(e), o = gr(e, i);
2679
+ delete t.state.assets[r], br(a, o, e, t, n);
2680
+ }
2681
+ function vr(e, t, n) {
2682
+ switch (e.type) {
2683
+ case "asset_start": return mr(e, t), !0;
2684
+ case "asset_delta": return hr(e, t), !0;
2685
+ case "asset_end": return _r(e, t, n), !0;
2686
+ default: return !1;
2687
+ }
2688
+ }
2689
+ function yr(e, t, n, r) {
2690
+ 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);
2691
+ }
2692
+ function br(e, t, n, r, i) {
2693
+ switch (e) {
2694
+ case "dashboard-title": {
2695
+ let e = t.name;
2696
+ e && typeof e == "object" && (r.state.dashboardName = e, Q(r, i, n, "dashboard-title", { name: e }));
2697
+ return;
2698
+ }
2699
+ case "dashboard-layout":
2700
+ Q(r, i, n, "dashboard-layout", t);
2701
+ return;
2702
+ case "dashboard-item":
2703
+ Q(r, i, n, "dashboard-item", {
2704
+ slot: Number(t.slot),
2705
+ chart: t.chart ?? t
2706
+ });
2707
+ return;
2708
+ case "dashboard":
2709
+ r.state.dashboardSnapshot = t;
2710
+ return;
2711
+ default: xr(e, t, n, r, i);
2712
+ }
2713
+ }
2714
+ function xr(e, t, n, r, i) {
2715
+ if (i.chartAssetType && e === i.chartAssetType) {
2716
+ yr(t, n, r, i);
2717
+ return;
2718
+ }
2719
+ if (i.dashboardAssetType && e === i.dashboardAssetType) {
2720
+ r.state.dashboardSnapshot = t;
2721
+ return;
2722
+ }
2723
+ $n(r, i, n, e || "asset", t);
2724
+ }
2725
+ function Sr(e, t, n) {
2726
+ let r = !1;
2727
+ if (n.dashboardAssetType) {
2728
+ let n = Yn(e);
2729
+ if (n) {
2730
+ t.state.dashboardSnapshot = n;
2731
+ let i = Xn(e);
2732
+ i && (t.state.dashboardName = i), r = !0;
2733
+ }
2734
+ }
2735
+ if (n.chartAssetType && !t.state.chartSnapshot) {
2736
+ let i = Gn(e);
2737
+ i && (yr(i, e, t, n), r = !0);
2738
+ }
2739
+ return r;
2740
+ }
2741
+ function Cr(e, t, n) {
2742
+ return {
2743
+ ...e,
2744
+ generatedChart: t,
2745
+ conversationId: n.callbacks.getConversationId()
2746
+ };
2747
+ }
2748
+ function wr(e, t, n) {
2749
+ for (let r of Object.keys(t.state.assets)) {
2750
+ let i = t.state.assets[r];
2751
+ delete t.state.assets[r], !(n.chartAssetType && i.assetType === n.chartAssetType && t.state.chartSnapshot || n.dashboardAssetType && i.assetType === n.dashboardAssetType && t.state.dashboardSnapshot) && br(i.assetType, i.snapshot, e, t, n);
2752
+ }
2753
+ }
2754
+ function Tr(e, t) {
2755
+ let n = Vn(e);
2756
+ !n || t.aiMessage.message === n || (t.aiMessage.message = n, t.callbacks.onMessageUpdate(t.aiMessage));
2757
+ }
2758
+ function Er(e, t, n) {
2759
+ let r = t.state.dashboardSnapshot ?? (n.dashboardAssetType ? Yn(e) : null), i = t.state.chartSnapshot ?? (n.chartAssetType ? Gn(e) : null);
2760
+ return {
2761
+ agent: n.agent,
2762
+ conversationId: t.callbacks.getConversationId(),
2763
+ message: t.aiMessage,
2764
+ ...r ? { dashboard: r } : {},
2765
+ ...i ? { chart: Cr(e, i, t) } : {},
2766
+ ...t.state.dashboardName ? { name: t.state.dashboardName } : {},
2767
+ raw: e
2768
+ };
2769
+ }
2770
+ function Dr(e, t, n, r) {
2771
+ if (!t.state.completed) {
2772
+ if (t.state.completed = !0, wr(e, t, n), er(t), r !== void 0) {
2773
+ t.callbacks.onComplete({
2774
+ agent: n.agent,
2775
+ conversationId: t.callbacks.getConversationId(),
2776
+ message: t.aiMessage,
2777
+ error: r,
2778
+ raw: e
2779
+ });
2780
+ return;
2781
+ }
2782
+ Tr(e, t), t.callbacks.onComplete(Er(e, t, n));
2783
+ }
2784
+ }
2785
+ function Or(e) {
2786
+ return typeof e.type == "string" && e.type ? e.type : typeof e.asset_type == "string" && e.asset_type ? e.asset_type : "";
2787
+ }
2788
+ function kr(e, t, n) {
2789
+ let r = Bn(e);
2790
+ return r ? (t.state.accumulatedText += r, tr(t, r), Q(t, n, e, "text", {
2791
+ delta: r,
2792
+ text: t.state.accumulatedText
2793
+ }), !0) : !1;
2794
+ }
2795
+ function Ar(e, t, n, r, i) {
2796
+ if (r || i) return;
2797
+ let a = Or(e);
2798
+ a && !Zn.has(a) && $n(t, n, e, a, e);
2799
+ }
2800
+ function jr(e, t, n) {
2801
+ if (Un(e, t), rr(e, t, n) || or(e, t, n) || cr(e, t, n) || vr(e, t, n)) return;
2802
+ let r = kr(e, t, n), i = Sr(e, t, n), a = r || i, o = Hn(e);
2803
+ Ar(e, t, n, a, o), o && Dr(e, t, n);
2804
+ }
2805
+ //#endregion
2806
+ //#region src/components/ai-chat/stream/registry.ts
2807
+ function Mr(e) {
2808
+ switch (e) {
2809
+ case "dashboard": return {
2810
+ agent: e,
2811
+ dashboardAssetType: "dashboard"
2812
+ };
2813
+ case "item": return {
2814
+ agent: e,
2815
+ chartAssetType: "item"
2816
+ };
2817
+ default: return { agent: e };
2818
+ }
2819
+ }
2820
+ function Nr(e) {
2821
+ let t = Mr(e);
2822
+ return (e, n) => jr(e, n, t);
2823
+ }
2824
+ function Pr() {
2825
+ return {
2826
+ progressCollapsed: !1,
2827
+ accumulatedText: "",
2828
+ decision: null,
2829
+ assets: {},
2830
+ dashboardSnapshot: null,
2831
+ dashboardName: void 0,
2832
+ chartSnapshot: null,
2833
+ interruptQuestion: null,
2834
+ completed: !1
2835
+ };
2836
+ }
2837
+ //#endregion
2838
+ //#region src/components/ai-chat/session/ai-chat-session.ts
2839
+ function Fr() {
2840
+ return `msg-${Date.now()}-${Math.random().toString(36).slice(2, 9)}`;
2841
+ }
2842
+ var Ir = class {
2843
+ constructor(e, t = {}) {
2844
+ this._uiBridgeCallbacks = {}, this._subscribers = /* @__PURE__ */ new Set(), this._state = {
2845
+ messages: [],
2846
+ selectedDatasets: [],
2847
+ isGenerating: !1,
2848
+ progress: null,
2849
+ progressCollapsed: !1,
2850
+ conversationId: null,
2851
+ inflightMessage: null
2852
+ }, this._abortController = null, this._inflightMessage = null, this._receivedProgress = !1, this._config = {
2853
+ apiUrl: "https://api.luzmo.com",
2854
+ apiVersion: "0.1.0",
2855
+ stream: !0,
2856
+ ...e
2857
+ }, this._hostCallbacks = t, this._state = {
2858
+ ...this._state,
2859
+ messages: e.messages ? [...e.messages] : [],
2860
+ selectedDatasets: e.selectedDatasets ? [...e.selectedDatasets] : [],
2861
+ conversationId: e.conversationId ?? null,
2862
+ isGenerating: e.isGenerating ?? !1,
2863
+ progress: e.progress ?? null,
2864
+ progressCollapsed: e.progressCollapsed ?? !1
2865
+ };
2866
+ }
2867
+ get state() {
2868
+ return this._state;
2869
+ }
2870
+ get isGenerating() {
2871
+ return this._state.isGenerating;
2872
+ }
2873
+ subscribe(e) {
2874
+ return this._subscribers.add(e), e(this._state), () => {
2875
+ this._subscribers.delete(e);
2876
+ };
2877
+ }
2878
+ setUiBridge(e) {
2879
+ this._uiBridgeCallbacks = e;
2880
+ }
2881
+ updateConfig(e) {
2882
+ this._config = {
2883
+ ...this._config,
2884
+ ...e
2885
+ };
2886
+ let t = {};
2887
+ if ("conversationId" in e) {
2888
+ let n = e.conversationId ?? null;
2889
+ n !== this._state.conversationId && (t.conversationId = n);
2890
+ }
2891
+ if ("selectedDatasets" in e && e.selectedDatasets) {
2892
+ let n = [...e.selectedDatasets];
2893
+ this._areSelectedDatasetsEqual(n, this._state.selectedDatasets) || (t.selectedDatasets = n);
2894
+ }
2895
+ if ("messages" in e && e.messages) {
2896
+ let n = [...e.messages];
2897
+ this._areChatMessagesEqual(n, this._state.messages) || (t.messages = n);
2898
+ }
2899
+ "isGenerating" in e && e.isGenerating !== this._state.isGenerating && (t.isGenerating = e.isGenerating), "progress" in e && (t.progress = e.progress ?? null), "progressCollapsed" in e && e.progressCollapsed !== this._state.progressCollapsed && (t.progressCollapsed = e.progressCollapsed), Object.keys(t).length > 0 && this._patchState(t);
2900
+ }
2901
+ setSelectedDatasets(e) {
2902
+ this._patchState({ selectedDatasets: [...e] }), this._emit("onDatasetsChanged", this._state.selectedDatasets);
2903
+ }
2904
+ addDataset(e) {
2905
+ this._state.selectedDatasets.some((t) => t.id === e.id) || (this._patchState({ selectedDatasets: [...this._state.selectedDatasets, e] }), this._emit("onDatasetsChanged", this._state.selectedDatasets));
2906
+ }
2907
+ removeDataset(e) {
2908
+ let t = this._state.selectedDatasets.filter((t) => t.id !== e);
2909
+ t.length !== this._state.selectedDatasets.length && (this._patchState({ selectedDatasets: t }), this._emit("onDatasetsChanged", this._state.selectedDatasets));
2910
+ }
2911
+ isDatasetRequirementMet() {
2912
+ return !this._config.requireDataset || this._state.selectedDatasets.length > 0;
2913
+ }
2914
+ getAiPromptUrl() {
2915
+ return Cn(this._config.apiUrl ?? "https://api.luzmo.com", this._config.apiVersion ?? "0.1.0");
2916
+ }
2917
+ buildRequestBody(e, t, n = []) {
2918
+ return jn(this._config.agent, {
2919
+ prompt: e,
2920
+ datasetIds: t,
2921
+ authKey: this._config.authKey,
2922
+ authToken: this._config.authToken,
2923
+ conversationId: this._state.conversationId,
2924
+ chart: this._config.chart ?? null,
2925
+ dashboard: this._config.dashboard ?? null,
2926
+ currentScreenMode: this._config.currentScreenMode,
2927
+ localeId: this._config.localeId,
2928
+ timezoneId: this._config.timezoneId,
2929
+ task: this._config.task,
2930
+ modelPreference: this._config.modelPreference,
2931
+ apiVersion: this._config.apiVersion,
2932
+ stream: this._config.stream,
2933
+ attachmentUrls: n
2934
+ });
2935
+ }
2936
+ buildPromptSubmittedDetail(e) {
2937
+ let t = e.attachmentUrls ?? [];
2938
+ return {
2939
+ prompt: e.prompt,
2940
+ selectedDatasets: e.selectedDatasets,
2941
+ datasetIds: e.datasetIds,
2942
+ agent: this._config.agent,
2943
+ request: this.buildRequestBody(e.prompt, e.datasetIds, t),
2944
+ url: this.getAiPromptUrl(),
2945
+ ...e.signal ? { signal: e.signal } : {},
2946
+ ...e.attachments?.length ? { attachments: e.attachments } : {},
2947
+ ...t.length ? { attachmentUrls: t } : {}
2948
+ };
2949
+ }
2950
+ async _resolveAttachmentUrls(e, t) {
2951
+ if (e.attachmentUrls?.length) return r(e.attachmentUrls), [...e.attachmentUrls];
2952
+ let n = (e.attachments ?? []).map((e) => e.file).filter((e) => !!e);
2953
+ if (n.length === 0) return [];
2954
+ a(n);
2955
+ let o = this._hostCallbacks.uploadAttachments ?? this._uiBridgeCallbacks.uploadAttachments;
2956
+ if (typeof o == "function") return this._normalizeUploadedUrls(await o(n, { signal: t }), n.length);
2957
+ let { authKey: s, authToken: c, apiUrl: l = "https://api.luzmo.com", apiVersion: u = "0.1.0" } = this._config;
2958
+ if (!s || !c) {
2959
+ if (this._hasCallback("onPromptSubmitted")) return [];
2960
+ throw Error("Image attachments require authKey/authToken for built-in upload, or provide uploadAttachments / attachmentUrls.");
2961
+ }
2962
+ return this._normalizeUploadedUrls(await i({
2963
+ files: n,
2964
+ authKey: s,
2965
+ authToken: c,
2966
+ apiUrl: l,
2967
+ apiVersion: u,
2968
+ signal: t
2969
+ }), n.length);
2970
+ }
2971
+ _normalizeUploadedUrls(e, t) {
2972
+ let n = Array.isArray(e) ? e.filter((e) => typeof e == "string" && e.trim().length > 0) : [];
2973
+ if (n.length !== t) throw Error(`Image upload returned ${n.length} URL(s) for ${t} file(s). Return one non-empty signed URL per file, in the same order.`);
2974
+ return r(n), n;
2975
+ }
2976
+ async submit(e) {
2977
+ let t = e.datasetIds ?? this._state.selectedDatasets.map((e) => e.id);
2978
+ if (!this.isDatasetRequirementMet()) return;
2979
+ this._abortInflight();
2980
+ let n = new AbortController();
2981
+ this._abortController = n;
2982
+ let r;
2983
+ try {
2984
+ r = await this._resolveAttachmentUrls(e, n.signal);
2985
+ } catch (e) {
2986
+ if (this._abortController === n && (this._abortController = null), n.signal.aborted || e.name === "AbortError") return;
2987
+ throw e;
2988
+ }
2989
+ if (n.signal.aborted || this._abortController !== n) return;
2990
+ let i = {
2991
+ id: e.aiMessageId ?? Fr(),
2992
+ type: "ai",
2993
+ message: ""
2994
+ }, a = [...this._state.messages];
2995
+ if (!e.skipUserMessage) {
2996
+ let t = {
2997
+ id: Fr(),
2998
+ type: "user",
2999
+ message: e.prompt,
3000
+ ...r.length ? { attachmentUrls: r } : {}
3001
+ };
3002
+ a = [...a, t], this._emit("onMessageSent", t, [...this._state.selectedDatasets]);
3003
+ }
3004
+ a = [...a, i], this._inflightMessage = i, this._receivedProgress = !1, this._patchState({
3005
+ messages: a,
3006
+ isGenerating: !0,
3007
+ progress: Ln(),
3008
+ progressCollapsed: !1,
3009
+ inflightMessage: i
3010
+ });
3011
+ let o = t, s = [...this._state.selectedDatasets];
3012
+ if (this._hasCallback("onPromptSubmitted")) {
3013
+ let t = this.buildPromptSubmittedDetail({
3014
+ prompt: e.prompt,
3015
+ selectedDatasets: s,
3016
+ datasetIds: o,
3017
+ signal: n.signal,
3018
+ attachments: e.attachments,
3019
+ attachmentUrls: r
3020
+ });
3021
+ try {
3022
+ await this._invokeCallback("onPromptSubmitted", t);
3023
+ } catch (e) {
3024
+ e.name === "AbortError" ? this.abort() : (this._handleSubmitError(e, i), this._finalizeInflightMessage()), this._patchState({ isGenerating: !1 });
3025
+ }
3026
+ return;
3027
+ }
3028
+ let c = this.buildRequestBody(e.prompt, t, r), l = Nr(this._config.agent), u = {
3029
+ aiMessage: i,
3030
+ callbacks: this._createStreamCallbacks(),
3031
+ state: Pr()
3032
+ }, d = this._config.fetchStreaming ?? Nn, ee = !1;
3033
+ try {
3034
+ let { body: e, conversationId: t } = await d({
3035
+ url: this.getAiPromptUrl(),
3036
+ body: c,
3037
+ signal: n.signal
3038
+ });
3039
+ t && this._setConversationId(t), await In(e, (e) => l(e, u)), ee = !0;
3040
+ } catch (e) {
3041
+ e.name !== "AbortError" && (this._handleSubmitError(e, i), ee = !0);
3042
+ } finally {
3043
+ this._abortController === n && (ee ? this._finalizeInflightMessage() : this._discardInflightMessage(), this._patchState({ isGenerating: !1 }), this._abortController = null);
3044
+ }
3045
+ }
3046
+ async restore(e) {
3047
+ if (this._config.agent !== "item") return {};
3048
+ let t = Mn(e.restoreToMessageId, this._config.authKey, this._config.authToken, this._config.apiVersion, this._state.conversationId);
3049
+ if (this._patchState({
3050
+ isGenerating: !0,
3051
+ progress: null,
3052
+ progressCollapsed: !1
3053
+ }), this._hasCallback("onRestoreRequested")) {
3054
+ let n = {
3055
+ apiMessageId: e.restoreToMessageId,
3056
+ messageIndex: e.messageIndex,
3057
+ request: t,
3058
+ url: this.getAiPromptUrl()
3059
+ };
3060
+ try {
3061
+ await this._invokeCallback("onRestoreRequested", n);
3062
+ } finally {
3063
+ this._patchState({ isGenerating: !1 });
3064
+ }
3065
+ return {};
3066
+ }
3067
+ try {
3068
+ let n = await fetch(this.getAiPromptUrl(), {
3069
+ method: "POST",
3070
+ headers: { "Content-Type": "application/json" },
3071
+ mode: "cors",
3072
+ body: JSON.stringify(t)
3073
+ });
3074
+ if (!n.ok) {
3075
+ let e = await n.json().catch(() => null);
3076
+ throw Error(e?.message || `API request failed with status ${n.status}`);
3077
+ }
3078
+ let r = await n.json().catch(() => null), i = r?.generatedChart ?? (r ? Gn(r) : null), a = {
3079
+ ...typeof r?.message == "string" ? { message: r.message } : {},
3080
+ ...i ? { chart: {
3081
+ ...r,
3082
+ generatedChart: i
3083
+ } } : {}
3084
+ }, o = e.messageIndex >= 0 && e.messageIndex < this._state.messages.length ? this._state.messages.slice(0, e.messageIndex + 1) : this._state.messages;
3085
+ if (a.message && o[e.messageIndex]?.type === "ai" && (o[e.messageIndex] = {
3086
+ ...o[e.messageIndex],
3087
+ message: a.message
3088
+ }), this._patchState({ messages: [...o] }), a.chart || a.message) {
3089
+ let t = o[e.messageIndex], n = t?.type === "ai" ? t : {
3090
+ id: Fr(),
3091
+ type: "ai",
3092
+ message: a.message ?? ""
3093
+ };
3094
+ this._emit("onComplete", {
3095
+ agent: this._config.agent,
3096
+ conversationId: this._state.conversationId,
3097
+ message: n,
3098
+ ...a.chart ? { chart: a.chart } : {},
3099
+ ...r ? { raw: r } : {}
3100
+ });
3101
+ }
3102
+ return a;
3103
+ } finally {
3104
+ this._patchState({ isGenerating: !1 });
3105
+ }
3106
+ }
3107
+ buildRestoreRequest(e) {
3108
+ return Mn(e, this._config.authKey, this._config.authToken, this._config.apiVersion, this._state.conversationId);
3109
+ }
3110
+ abort(e = {}) {
3111
+ this._abortController?.abort(), this._abortController = null, e.notify && this._inflightMessage ? this._markInflightCancelled(e.cancelledMessage) : this._discardInflightMessage(), this._patchState({
3112
+ isGenerating: !1,
3113
+ progress: null,
3114
+ progressCollapsed: !1
3115
+ }), e.notify && this._emit("onPromptStopped");
3116
+ }
3117
+ _abortInflight() {
3118
+ this._abortController?.abort(), this._abortController = null, this._discardInflightMessage();
3119
+ }
3120
+ _createStreamCallbacks() {
3121
+ return {
3122
+ onConversationIdChange: (e) => this._setConversationId(e),
3123
+ onProgress: (e) => {
3124
+ this._receivedProgress = !0, this._patchState({ progress: e });
3125
+ },
3126
+ onProgressCollapsed: (e) => {
3127
+ this._patchState({ progressCollapsed: e });
3128
+ },
3129
+ onMessageUpdate: (e) => {
3130
+ this._inflightMessage = e, this._upsertMessage(e), this._patchState({ inflightMessage: { ...e } });
3131
+ },
3132
+ getConversationId: () => this._state.conversationId,
3133
+ onStep: (e) => {
3134
+ this._emit("onStep", e);
3135
+ },
3136
+ onComplete: (e) => {
3137
+ this._emit("onComplete", e);
3138
+ }
3139
+ };
3140
+ }
3141
+ _setConversationId(e) {
3142
+ this._config = {
3143
+ ...this._config,
3144
+ conversationId: e
3145
+ }, this._patchState({ conversationId: e }), this._emit("onConversationIdChange", e);
3146
+ }
3147
+ _upsertMessage(e) {
3148
+ let t = this._state.messages.findIndex((t) => t.id === e.id);
3149
+ if (t === -1) {
3150
+ this._patchState({ messages: [...this._state.messages, { ...e }] });
3151
+ return;
3152
+ }
3153
+ let n = this._state.messages.map((n, r) => r === t ? { ...e } : n);
3154
+ this._patchState({ messages: n });
3155
+ }
3156
+ _finalizeInflightMessage() {
3157
+ 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({
3158
+ progress: null,
3159
+ progressCollapsed: !1,
3160
+ inflightMessage: null
3161
+ }));
3162
+ }
3163
+ _removeInflightFromMessages() {
3164
+ this._inflightMessage && this._patchState({ messages: this._state.messages.filter((e) => e.id !== this._inflightMessage.id) });
3165
+ }
3166
+ _markInflightCancelled(e) {
3167
+ this._inflightMessage && (this._inflightMessage.message = e ?? o("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, this._upsertMessage(this._inflightMessage), this._inflightMessage = null, this._receivedProgress = !1, this._patchState({ inflightMessage: null }));
3168
+ }
3169
+ _discardInflightMessage() {
3170
+ let e = !!(this._inflightMessage || this._state.inflightMessage);
3171
+ this._removeInflightFromMessages(), this._inflightMessage = null, this._receivedProgress = !1, e && this._patchState({ inflightMessage: null });
3172
+ }
3173
+ _handleSubmitError(e, t) {
3174
+ t.message = o("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, this._inflightMessage = t, this._upsertMessage(t), this._patchState({
3175
+ inflightMessage: { ...t },
3176
+ progress: null,
3177
+ progressCollapsed: !1
3178
+ }), this._emit("onComplete", {
3179
+ agent: this._config.agent,
3180
+ conversationId: this._state.conversationId,
3181
+ message: t,
3182
+ error: e
3183
+ });
3184
+ }
3185
+ _hasCallback(e) {
3186
+ return typeof this._hostCallbacks[e] == "function" || typeof this._uiBridgeCallbacks[e] == "function";
3187
+ }
3188
+ _emit(e, ...t) {
3189
+ this._invokeCallback(e, ...t);
3190
+ }
3191
+ async _invokeCallback(e, ...t) {
3192
+ let n = this._hostCallbacks[e], r = this._uiBridgeCallbacks[e];
3193
+ typeof n == "function" && await n(...t), typeof r == "function" && await r(...t);
3194
+ }
3195
+ _patchState(e) {
3196
+ this._state = {
3197
+ ...this._state,
3198
+ ...e
3199
+ }, this._emit("onStateChange", this._state);
3200
+ for (let e of this._subscribers) e(this._state);
3201
+ }
3202
+ _areSelectedDatasetsEqual(e, t) {
3203
+ return e.length === t.length && e.every((e, n) => e.id === t[n]?.id);
3204
+ }
3205
+ _areChatMessagesEqual(e, t) {
3206
+ return e.length === t.length && e.every((e, n) => {
3207
+ let r = t[n];
3208
+ 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);
3209
+ });
3210
+ }
3211
+ };
3212
+ function Lr(e, t) {
3213
+ return new Ir(e, t);
3214
+ }
3215
+ //#endregion
3216
+ //#region src/components/ai-chat/session/ai-chat-session-controller.ts
3217
+ var Rr = class {
3218
+ constructor(e) {
3219
+ this.options = e, this._session = null, this._ownsSession = !1, this._seededFromProps = !1, this._unsubscribe = null;
3220
+ }
3221
+ get current() {
3222
+ return this._session;
3223
+ }
3224
+ get state() {
3225
+ if (this._session) return this._session.state;
3226
+ let e = this.options.getSeed();
3227
+ return {
3228
+ messages: e.messages,
3229
+ selectedDatasets: e.selectedDatasets,
3230
+ isGenerating: !1,
3231
+ progress: null,
3232
+ progressCollapsed: !1,
3233
+ conversationId: e.conversationId,
3234
+ inflightMessage: null
3235
+ };
3236
+ }
3237
+ get ownsCurrentSession() {
3238
+ return this._ownsSession;
3239
+ }
3240
+ setSession(e) {
3241
+ if (!e) {
3242
+ this._clearSession();
3243
+ return;
3244
+ }
3245
+ this._ownsSession && this._session !== e && this._session?.abort(), this._ownsSession = !1, this._session = e, this._mergeHostElementConfig(e), this._wire(e);
3246
+ }
3247
+ syncProperties(e) {
3248
+ if (!e.has("chatSession")) {
3249
+ if (this._createSessionIfMissing(), this._session) {
3250
+ let t = this.options.getConfig();
3251
+ Object.keys(t).some((t) => e.has(t)) && (this._ownsSession ? this._session.updateConfig(t) : this._mergeHostElementConfig(this._session));
3252
+ }
3253
+ (e.has("messages") || e.has("selectedDatasets")) && this._seedFromPropsOnce();
3254
+ }
3255
+ }
3256
+ requireSession() {
3257
+ return this._createSessionIfMissing(), this._ownsSession ? this._session.updateConfig(this.options.getConfig()) : this._session && this._mergeHostElementConfig(this._session), this._session;
3258
+ }
3259
+ _mergeHostElementConfig(e) {
3260
+ let t = this.options.getConfig(), n = {
3261
+ authKey: t.authKey,
3262
+ authToken: t.authToken,
3263
+ apiUrl: t.apiUrl,
3264
+ apiVersion: t.apiVersion,
3265
+ stream: t.stream,
3266
+ localeId: t.localeId,
3267
+ timezoneId: t.timezoneId,
3268
+ modelPreference: t.modelPreference,
3269
+ requireDataset: t.requireDataset,
3270
+ agent: t.agent
3271
+ };
3272
+ t.task !== void 0 && (n.task = t.task), t.chart != null && (n.chart = t.chart), t.dashboard != null && (n.dashboard = t.dashboard), t.currentScreenMode != null && (n.currentScreenMode = t.currentScreenMode), t.conversationId != null && (n.conversationId = t.conversationId), e.updateConfig(n);
3273
+ }
3274
+ connect() {
3275
+ this._session && this._wire(this._session);
3276
+ }
3277
+ teardown() {
3278
+ this._unwire(), this._ownsSession &&= (this._session?.abort(), this._session = null, !1), this._seededFromProps = !1;
3279
+ }
3280
+ _createSessionIfMissing() {
3281
+ if (this._session) return;
3282
+ let e = this.options.getSeed();
3283
+ this._session = Lr({
3284
+ ...this.options.getConfig(),
3285
+ messages: e.messages.length > 0 ? [...e.messages] : void 0,
3286
+ selectedDatasets: e.selectedDatasets.length > 0 ? [...e.selectedDatasets] : void 0
3287
+ }), this._ownsSession = !0, this._seededFromProps = e.messages.length > 0 || e.selectedDatasets.length > 0, this._wire(this._session);
3288
+ }
3289
+ _clearSession() {
3290
+ this._unwire(), this._ownsSession && this._session?.abort(), this._session = null, this._ownsSession = !1;
3291
+ }
3292
+ _seedFromPropsOnce() {
3293
+ if (!this._ownsSession || this._seededFromProps) return;
3294
+ let e = this.requireSession(), t = this.options.getSeed(), n = {};
3295
+ 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);
3296
+ }
3297
+ _wire(e) {
3298
+ this._unwire(), e.setUiBridge(this.options.createDomBridge()), this._unsubscribe = e.subscribe(() => {
3299
+ this.options.onRenderNeeded();
3300
+ });
3301
+ }
3302
+ _unwire() {
3303
+ this._unsubscribe?.(), this._unsubscribe = null;
3304
+ }
3305
+ }, $ = class t extends e {
3306
+ constructor(...e) {
3307
+ 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.flagOpendata = !1, this.hideDatasetButton = !1, this.hideDatasetIcons = !1, this.disableDatasetModification = !1, this.hideSelectedDatasets = !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.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 Rr({
3308
+ getConfig: () => this._buildSessionConfig(),
3309
+ getSeed: () => ({
3310
+ messages: this.messages,
3311
+ selectedDatasets: this.selectedDatasets,
3312
+ conversationId: this.conversationId
3313
+ }),
3314
+ createDomBridge: () => this._createDomBridgeCallbacks(),
3315
+ onRenderNeeded: () => {
3316
+ this.requestUpdate(), this.updateComplete.then(() => this._scrollToBottom());
3317
+ }
3318
+ }), this._handleAssistantMessageActionsSlotChange = (e) => {
3319
+ let t = e.target.assignedElements({ flatten: !0 }).length > 0;
3320
+ this._setAssistantMessageActionsSlotHasContent(t);
3321
+ }, this._handleAssistantMessageActionConfirmKeydown = (e) => {
3322
+ e.key !== "Escape" || !this._pendingAssistantMessageAction || (e.preventDefault(), e.stopPropagation(), this._cancelAssistantMessageActionConfirm());
3323
+ };
3324
+ }
3325
+ static {
3326
+ this.styles = ee(bn);
3327
+ }
3328
+ static {
3329
+ this.tagName = "luzmo-ai-chat";
3330
+ }
3331
+ static {
3332
+ this.assistantMessageActionsSlot = "assistant-message-actions";
3333
+ }
3334
+ get session() {
3335
+ return this._session.current;
3336
+ }
3337
+ _getRenderState() {
3338
+ return this._session.state;
3339
+ }
3340
+ _createDomBridgeCallbacks() {
3341
+ return {
3342
+ onMessageSent: (e, t) => {
3343
+ this.dispatchEvent(new CustomEvent("luzmo-message-sent", {
3344
+ detail: {
3345
+ message: e,
3346
+ selectedDatasets: t
3347
+ },
3348
+ bubbles: !0,
3349
+ composed: !0
3350
+ }));
3351
+ },
3352
+ onDatasetsChanged: (e) => {
3353
+ this.dispatchEvent(new CustomEvent("luzmo-datasets-changed", {
3354
+ detail: { selectedDatasets: e },
3355
+ bubbles: !0,
3356
+ composed: !0
3357
+ }));
3358
+ },
3359
+ onConversationIdChange: (e) => this._emitConversationIdChanged(e),
3360
+ onStep: (e) => {
3361
+ this.dispatchEvent(new CustomEvent("luzmo-step", {
3362
+ detail: e,
3363
+ bubbles: !0,
3364
+ composed: !0
3365
+ }));
3366
+ },
3367
+ onComplete: (e) => {
3368
+ this.dispatchEvent(new CustomEvent("luzmo-complete", {
3369
+ detail: e,
3370
+ bubbles: !0,
3371
+ composed: !0
3372
+ }));
3373
+ },
3374
+ onPromptStopped: () => {
3375
+ this.dispatchEvent(new CustomEvent("luzmo-stop", {
3376
+ bubbles: !0,
3377
+ composed: !0
3378
+ }));
3379
+ },
3380
+ ...typeof this.uploadAttachments == "function" ? { uploadAttachments: (e, t) => this.uploadAttachments(e, t) } : {}
3381
+ };
3382
+ }
3383
+ get _resolvedAcceptedFileTypes() {
3384
+ return this.acceptedFileTypes.length > 0 ? this.acceptedFileTypes : this.allowImages ? [...n] : [];
3385
+ }
3386
+ _buildSessionConfig() {
3387
+ return {
3388
+ agent: this.agent,
3389
+ authKey: this.authKey,
3390
+ authToken: this.authToken,
3391
+ apiUrl: this.apiUrl,
3392
+ apiVersion: this.apiVersion,
3393
+ stream: this.stream,
3394
+ conversationId: this.conversationId,
3395
+ chart: this.chart,
3396
+ dashboard: this.dashboard,
3397
+ currentScreenMode: this.currentScreenMode,
3398
+ localeId: this.localeId,
3399
+ timezoneId: this.timezoneId,
3400
+ task: this.task,
3401
+ modelPreference: this.modelPreference,
3402
+ requireDataset: this.requireDataset
3403
+ };
3404
+ }
3405
+ _emitConversationIdChanged(e) {
3406
+ this.conversationId = e, this.dispatchEvent(new CustomEvent("luzmo-conversation-id-changed", {
3407
+ detail: { conversationId: e },
3408
+ bubbles: !0,
3409
+ composed: !0
3410
+ }));
3411
+ }
3412
+ async _restoreViaSession(e, t) {
3413
+ await this._session.requireSession().restore({
3414
+ restoreToMessageId: e,
3415
+ messageIndex: t
3416
+ });
3417
+ }
3418
+ async _handleRestoreState(e, t) {
3419
+ if (e.apiMessageId && this.agent === "item") try {
3420
+ await this._restoreViaSession(e.apiMessageId, t);
3421
+ } catch (e) {
3422
+ console.error("AI restore error:", e);
3423
+ }
3424
+ }
3425
+ _handleDatasetSelected(e) {
3426
+ this._session.requireSession().addDataset(e.detail);
3427
+ }
3428
+ _handleDatasetRemoved(e) {
3429
+ this._session.requireSession().removeDataset(e.detail.id);
3430
+ }
3431
+ async _submitViaSession(e, t = {}) {
3432
+ let n = this._session.requireSession();
3433
+ if (!n.isDatasetRequirementMet()) return !1;
3434
+ this._textareaValue = "";
3435
+ try {
3436
+ return await n.submit({
3437
+ prompt: e,
3438
+ ...t
3439
+ }), !0;
3440
+ } catch (e) {
3441
+ return e.name !== "AbortError" && console.error("AI prompt session error:", e), !1;
3442
+ }
3443
+ }
3444
+ async _handlePromptSubmitted(e) {
3445
+ let t = e.detail.prompt;
3446
+ await this._submitViaSession(t, {
3447
+ ...e.detail.attachments?.length ? { attachments: e.detail.attachments } : {},
3448
+ ...e.detail.attachmentUrls?.length ? { attachmentUrls: e.detail.attachmentUrls } : {}
3449
+ }) || (this._textareaValue = t);
3450
+ }
3451
+ _handlePromptStopped() {
3452
+ let e = this._session.current;
3453
+ if (this._textareaValue = "", e) {
3454
+ e.abort({
3455
+ notify: !0,
3456
+ cancelledMessage: this.cancelledMessage ?? void 0
3457
+ });
3458
+ return;
3459
+ }
3460
+ this.dispatchEvent(new CustomEvent("luzmo-stop", {
3461
+ bubbles: !0,
3462
+ composed: !0
3463
+ }));
3464
+ }
3465
+ async _handleEmptyStateSuggestionSelected(e) {
3466
+ let { prompt: t, selectedDatasets: n } = e.detail, r = this._session.requireSession();
3467
+ n?.length && r.setSelectedDatasets(n), await this._submitViaSession(t);
3468
+ }
3469
+ async _processInitialPrompt() {
3470
+ !this.initialPrompt || this.initialPrompt === this._lastProcessedInitialPrompt || this._session.requireSession().isDatasetRequirementMet() && (this._lastProcessedInitialPrompt = this.initialPrompt, await this._submitViaSession(this.initialPrompt, { skipUserMessage: !0 }));
3471
+ }
3472
+ connectedCallback() {
3473
+ super.connectedCallback(), this._session.connect();
3474
+ }
3475
+ disconnectedCallback() {
3476
+ super.disconnectedCallback(), this._session.teardown();
3477
+ }
3478
+ _scrollToBottom() {
3479
+ let e = this.shadowRoot?.querySelector(".chat-messages-container");
3480
+ e && requestAnimationFrame(() => {
3481
+ requestAnimationFrame(() => {
3482
+ e.scrollTop = e.scrollHeight;
3483
+ });
3484
+ });
3485
+ }
3486
+ willUpdate(e) {
3487
+ super.willUpdate?.(e), this._syncPendingAssistantMessageAction();
3488
+ }
3489
+ updated(e) {
3490
+ super.updated?.(e), this._syncSession(e), this._handleInitialPromptChange(), e.has("uploadAttachments") && this._session.current?.setUiBridge(this._createDomBridgeCallbacks()), this.updateComplete.then(() => {
3491
+ this._syncAssistantMessageActionsVisibility(), this._focusPendingAssistantMessageActionConfirm();
3492
+ });
3493
+ }
3494
+ _syncSession(e) {
3495
+ if (e.has("chatSession")) {
3496
+ this._session.setSession(this.chatSession);
3497
+ return;
3498
+ }
3499
+ this._session.syncProperties(e);
3500
+ }
3501
+ _handleInitialPromptChange() {
3502
+ this.initialPrompt && this.initialPrompt !== this._lastProcessedInitialPrompt ? this._processInitialPrompt() : this.initialPrompt || (this._lastProcessedInitialPrompt = null);
3503
+ }
3504
+ _renderMarkdown(e) {
3505
+ let t = String(Z.parse(e, { async: !1 }));
3506
+ return lt.sanitize(t, {
3507
+ 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("."),
3508
+ ALLOWED_ATTR: [
3509
+ "href",
3510
+ "title",
3511
+ "target",
3512
+ "rel"
3513
+ ],
3514
+ ALLOW_DATA_ATTR: !1,
3515
+ FORBID_TAGS: [
3516
+ "script",
3517
+ "style",
3518
+ "iframe",
3519
+ "object",
3520
+ "embed",
3521
+ "link",
3522
+ "form",
3523
+ "input",
3524
+ "button"
3525
+ ],
3526
+ FORBID_ATTR: [
3527
+ "onerror",
3528
+ "onload",
3529
+ "onclick",
3530
+ "onmouseover",
3531
+ "onfocus",
3532
+ "onblur"
3533
+ ]
3534
+ });
3535
+ }
3536
+ _renderProgress() {
3537
+ let { progress: e, progressCollapsed: t } = this._getRenderState();
3538
+ return e?.children?.length ? u`
3539
+ <luzmo-progress-steps
3540
+ .progress=${e}
3541
+ ?collapsed=${t}
3542
+ size="s"
3543
+ ></luzmo-progress-steps>
3544
+ ` : d;
3545
+ }
3546
+ _isLastAiMessageWithProgress(e, t) {
3547
+ for (let n = t.length - 1; n >= 0; n--) if (t[n].type === "ai" && t[n].progress?.children?.length) return t[n].id === e.id;
3548
+ return !1;
3549
+ }
3550
+ _syncAssistantMessageActionsVisibility() {
3551
+ let e = ((this.shadowRoot?.querySelector(`slot[name="${t.assistantMessageActionsSlot}"]`) ?? null)?.assignedElements({ flatten: !0 }).length ?? 0) > 0;
3552
+ this._setAssistantMessageActionsSlotHasContent(e);
3553
+ }
3554
+ _setAssistantMessageActionsSlotHasContent(e) {
3555
+ e !== this._assistantMessageActionsSlotHasContent && (this._assistantMessageActionsSlotHasContent = e);
3556
+ }
3557
+ _isLatestAssistantMessage(e, t) {
3558
+ return !!(t && e === t);
3559
+ }
3560
+ _hasBuiltInAssistantMessageActions(e) {
3561
+ return (e.actions?.length ?? 0) > 0;
3562
+ }
3563
+ _assistantMessageActionsFooterHasContent(e, t) {
3564
+ return this._hasBuiltInAssistantMessageActions(e) || t && this._assistantMessageActionsSlotHasContent;
3565
+ }
3566
+ _syncPendingAssistantMessageAction() {
3567
+ let e = this._pendingAssistantMessageAction;
3568
+ if (!e) return;
3569
+ let { messages: t } = this._getRenderState(), n = t.find((t) => t.id === e.messageId), r = n?.actions?.find((t) => t.id === e.actionId);
3570
+ (!n || !r?.confirm) && (this._pendingAssistantMessageAction = null, this._shouldFocusAssistantMessageActionConfirm = !1);
3571
+ }
3572
+ _getDefaultAssistantMessageActionConfirmMessage() {
3573
+ return o("Are you sure?", { desc: "Default assistant message action confirmation prompt" });
3574
+ }
3575
+ _isAssistantMessageActionConfirming(e) {
3576
+ let t = this._pendingAssistantMessageAction, n = e.id;
3577
+ return !!(t && n && t.messageId === n);
3578
+ }
3579
+ _getPendingAssistantMessageAction(e) {
3580
+ let t = this._pendingAssistantMessageAction, n = e.id;
3581
+ if (!(!t || !n || t.messageId !== n)) return e.actions?.find((e) => e.id === t.actionId);
3582
+ }
3583
+ _handleAssistantMessageAction(e, t) {
3584
+ let n = e.id;
3585
+ n && this.dispatchEvent(new CustomEvent("luzmo-assistant-message-action", {
3586
+ detail: {
3587
+ messageId: n,
3588
+ actionId: t.id,
3589
+ message: e
3590
+ },
3591
+ bubbles: !0,
3592
+ composed: !0
3593
+ }));
3594
+ }
3595
+ _handleAssistantMessageActionClick(e, t) {
3596
+ let n = e.id;
3597
+ if (n) {
3598
+ if (t.confirm) {
3599
+ this._pendingAssistantMessageAction = {
3600
+ messageId: n,
3601
+ actionId: t.id
3602
+ }, this._shouldFocusAssistantMessageActionConfirm = !0;
3603
+ return;
3604
+ }
3605
+ this._handleAssistantMessageAction(e, t);
3606
+ }
3607
+ }
3608
+ _cancelAssistantMessageActionConfirm() {
3609
+ this._pendingAssistantMessageAction = null, this._shouldFocusAssistantMessageActionConfirm = !1;
3610
+ }
3611
+ _confirmAssistantMessageAction(e, t) {
3612
+ this._pendingAssistantMessageAction = null, this._shouldFocusAssistantMessageActionConfirm = !1, this._handleAssistantMessageAction(e, t);
3613
+ }
3614
+ _focusPendingAssistantMessageActionConfirm() {
3615
+ !this._shouldFocusAssistantMessageActionConfirm || !this._pendingAssistantMessageAction || (this._shouldFocusAssistantMessageActionConfirm = !1, (this.shadowRoot?.querySelector("luzmo-button.assistant-message-action-confirm-cancel"))?.focus?.());
3616
+ }
3617
+ _renderBuiltInAssistantMessageAction(e, t) {
3618
+ return u`
3619
+ <luzmo-button
3620
+ class="assistant-message-action"
3621
+ size="xs"
3622
+ variant="neutral"
3623
+ treatment="outline"
3624
+ ?disabled=${this.disabled || t.disabled || !e.id}
3625
+ @click=${() => this._handleAssistantMessageActionClick(e, t)}
3626
+ >
3627
+ ${t.icon ? u`<luzmo-icon slot="icon" .icon=${t.icon} size="xs"></luzmo-icon>` : d}
3628
+ ${t.label}
3629
+ </luzmo-button>
3630
+ `;
3631
+ }
3632
+ _renderAssistantMessageActionConfirm(e) {
3633
+ let t = this._getPendingAssistantMessageAction(e);
3634
+ if (!t) return d;
3635
+ let n = t.confirmMessage ?? this._getDefaultAssistantMessageActionConfirmMessage(), r = this.disabled || t.disabled || !e.id;
3636
+ return u`
3637
+ <span class="assistant-message-action-confirm-message" role="status" aria-live="polite">${n}</span>
3638
+ <div class="assistant-message-action-confirm-controls">
3639
+ <luzmo-button
3640
+ class="assistant-message-action-confirm-cancel"
3641
+ size="xs"
3642
+ variant="neutral"
3643
+ treatment="outline"
3644
+ quiet
3645
+ ?disabled=${this.disabled}
3646
+ @click=${this._cancelAssistantMessageActionConfirm}
3647
+ >
3648
+ ${o("Cancel", { desc: "Cancel assistant message action confirmation" })}
3649
+ </luzmo-button>
3650
+ <luzmo-button
3651
+ class="assistant-message-action-confirm-confirm"
3652
+ size="xs"
3653
+ variant=${t.confirmVariant ?? "negative"}
3654
+ ?disabled=${r}
3655
+ @click=${() => this._confirmAssistantMessageAction(e, t)}
3656
+ >
3657
+ ${t.label}
3658
+ </luzmo-button>
3659
+ </div>
3660
+ `;
3661
+ }
3662
+ _renderAssistantMessageActions(e, n) {
3663
+ let r = e.actions ?? [], i = r.length > 0, a = this._isLatestAssistantMessage(e, n), o = this._isAssistantMessageActionConfirming(e);
3664
+ return !i && !a ? d : u`
3665
+ <div
3666
+ class="assistant-message-actions ${this._assistantMessageActionsFooterHasContent(e, a) ? "assistant-message-actions--has-content" : ""} ${o ? "assistant-message-actions--confirming" : ""}"
3667
+ @keydown=${o ? this._handleAssistantMessageActionConfirmKeydown : d}
3668
+ >
3669
+ ${o ? this._renderAssistantMessageActionConfirm(e) : u`
3670
+ ${r.map((t) => this._renderBuiltInAssistantMessageAction(e, t))}
3671
+ ${a ? u`
3672
+ <slot
3673
+ name=${t.assistantMessageActionsSlot}
3674
+ @slotchange=${this._handleAssistantMessageActionsSlotChange}
3675
+ ></slot>
3676
+ ` : d}
3677
+ `}
3678
+ </div>
3679
+ `;
3680
+ }
3681
+ _renderRestoreMenu(e, t, n, r = !1) {
3682
+ if (!(this.agent === "item" && this.showAssistantContextMenu && e.hasChart && e.apiMessageId && !e.isError && e.id !== n)) return d;
3683
+ let i = `context-menu-trigger-${e.apiMessageId}`;
3684
+ return u`
3685
+ <div class="assistant-context-menu">
3686
+ <button
3687
+ id=${i}
3688
+ class="assistant-context-menu-trigger"
3689
+ type="button"
3690
+ aria-label=${o("Open restore menu", { desc: "Accessible label for the ai chat restore menu trigger" })}
3691
+ aria-haspopup="menu"
3692
+ ?disabled=${r}
3693
+ >
3694
+ ${c(s)}
3695
+ </button>
3696
+ <luzmo-overlay
3697
+ trigger="${i}@click"
3698
+ placement="bottom-end"
3699
+ >
3700
+ <luzmo-popover>
3701
+ <button
3702
+ class="assistant-context-menu-item"
3703
+ type="button"
3704
+ ?disabled=${r}
3705
+ @click=${() => this._handleRestoreState(e, t)}
3706
+ >
3707
+ ${o("Restore state", { desc: "Context menu action that restores the chart to this message state" })}
3708
+ </button>
3709
+ </luzmo-popover>
3710
+ </luzmo-overlay>
3711
+ </div>
3712
+ `;
3713
+ }
3714
+ _renderMessages() {
3715
+ 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"), s = a?.id;
3716
+ return i.map((t) => {
3717
+ let c = !!t.progress?.children?.length, l = c && this._isLastAiMessageWithProgress(t, i), ee = c && (r || n || !l), f = c ? u`
3718
+ <luzmo-progress-steps
3719
+ .progress=${t.progress}
3720
+ ?condensed=${ee}
3721
+ collapsed
3722
+ no-animate
3723
+ size="s"
3724
+ ></luzmo-progress-steps>
3725
+ ` : d;
3726
+ if (t.type === "user") {
3727
+ let e = t.attachmentUrls ?? [];
3728
+ return u`
3729
+ <luzmo-chat-message
3730
+ avatar-placement="bottom"
3731
+ position="right"
3732
+ variant="primary"
3733
+ size="s"
3734
+ >
3735
+ <div class="user-message-content">
3736
+ ${e.length > 0 ? u`
3737
+ <div class="user-message-attachments">
3738
+ ${e.map((e) => u`
3739
+ <img
3740
+ class="user-message-attachment"
3741
+ src=${e}
3742
+ alt=${o("Attached image", { desc: "Accessible label for an image attached to a user chat message" })}
3743
+ width="64"
3744
+ height="64"
3745
+ />
3746
+ `)}
3747
+ </div>
3748
+ ` : d}
3749
+ <div class="user-message-text">${t.message}</div>
3750
+ </div>
3751
+ </luzmo-chat-message>
3752
+ `;
3753
+ }
3754
+ let p = e.indexOf(t), m = t.isError ? "error" : t.isCancelled ? "cancelled" : "", ne = t.isCancelled ? t.message : u`<div class="markdown-content">${te(this._renderMarkdown(t.message))}</div>`;
3755
+ return u`
3756
+ ${f}
3757
+ <div class="assistant-message-wrapper">
3758
+ <div class="assistant-message-body">
3759
+ <luzmo-chat-message
3760
+ class=${m}
3761
+ role=${t.isError ? "alert" : d}
3762
+ avatar-placement="bottom"
3763
+ position="left"
3764
+ quiet
3765
+ size="s"
3766
+ >
3767
+ ${ne}
3768
+ </luzmo-chat-message>
3769
+
3770
+ ${this._renderRestoreMenu(t, p, s, r)}
3771
+ </div>
3772
+
3773
+ ${this._renderAssistantMessageActions(t, a)}
3774
+ </div>
3775
+ `;
3776
+ });
3777
+ }
3778
+ _renderStreamingResponse() {
3779
+ let { inflightMessage: e } = this._getRenderState();
3780
+ return e?.message ? u`
3781
+ <luzmo-chat-message
3782
+ avatar-placement="bottom"
3783
+ position="left"
3784
+ quiet
3785
+ size="s"
3786
+ >
3787
+ <div class="markdown-content">${te(this._renderMarkdown(e.message))}</div>
3788
+ </luzmo-chat-message>
3789
+ ` : d;
3790
+ }
3791
+ _renderLoadingMessage() {
3792
+ let { isGenerating: e, progress: t, inflightMessage: n } = this._getRenderState();
3793
+ if (!e || t?.children?.length || n?.message) return d;
3794
+ let r = this.agent === "dashboard" ? !this.dashboard : this.chart?.type === "placeholder", i = this.agent === "dashboard" ? r ? o("Creating dashboard...", { desc: "Label for ai chat creating dashboard message" }) : o("Updating dashboard...", { desc: "Label for ai chat updating dashboard message" }) : r ? o("Creating item...", { desc: "Label for ai chat creating item message" }) : o("Updating item...", { desc: "Label for ai chat updating item message" });
3795
+ return u`
3796
+ <luzmo-chat-message
3797
+ avatar-placement="bottom"
3798
+ position="left"
3799
+ quiet
3800
+ size="s"
3801
+ >
3802
+ <div class="loading-message" role="status" aria-live="polite">
3803
+ <span class="icon-lg">${c(l, { className: "spin" })}</span>
3804
+ <span class="loading-message-text">${this.loadingMessage || i}</span>
3805
+ </div>
3806
+ </luzmo-chat-message>
3807
+ `;
3808
+ }
3809
+ _renderEmptyState() {
3810
+ if (this._getRenderState().messages.length > 0) return d;
3811
+ let e = o("What can I help you with?", { desc: "Title for the AI chat empty state" }), t = this.emptyStateSuggestions.length > 0;
3812
+ return u`
3813
+ <luzmo-ai-chat-empty-state
3814
+ .title=${this.emptyStateTitle || e}
3815
+ .subtitle=${t ? this.emptyStateSubtitle : ""}
3816
+ .suggestions=${this.emptyStateSuggestions}
3817
+ ?disabled=${this.disabled || this._getRenderState().isGenerating}
3818
+ @luzmo-suggestion-selected=${this._handleEmptyStateSuggestionSelected}
3819
+ ></luzmo-ai-chat-empty-state>
3820
+ `;
3821
+ }
3822
+ render() {
3823
+ let { selectedDatasets: e, isGenerating: t } = this._getRenderState();
3824
+ return u`
3825
+ <div class="chat-container" role="region" aria-label=${o("AI Chat", { desc: "Accessible label for AI chat region" })}>
3826
+ <div class="chat-messages-container" role="log" aria-live="polite">
3827
+ ${this._renderEmptyState()}
3828
+ ${this._renderMessages()}
3829
+ ${this._renderProgress()}
3830
+ ${this._renderStreamingResponse()}
3831
+ ${this._renderLoadingMessage()}
3832
+ </div>
3833
+
3834
+ <luzmo-ai-interaction-textarea
3835
+ role="group"
3836
+ aria-label=${o("AI prompt input", { desc: "Accessible label for the ai chat prompt input area" })}
3837
+ .value=${this._textareaValue}
3838
+ .selectedDatasets=${e}
3839
+ .placeholder=${this.placeholder}
3840
+ ?disabled=${this.disabled}
3841
+ ?is-generating=${t}
3842
+ ?stoppable=${this.stoppable}
3843
+ ?hide-dataset-button=${this.hideDatasetButton}
3844
+ ?hide-dataset-icons=${this.hideDatasetIcons}
3845
+ ?disable-dataset-modification=${this.disableDatasetModification}
3846
+ ?hide-selected-datasets=${this.hideSelectedDatasets}
3847
+ ?disable-column-mentions=${this.disableColumnMentions}
3848
+ ?require-dataset=${this.requireDataset}
3849
+ ?allow-images=${this.allowImages}
3850
+ ?allow-voice-input=${this.allowVoiceInput}
3851
+ .acceptedFileTypes=${this._resolvedAcceptedFileTypes}
3852
+ .uploadAttachments=${this.uploadAttachments}
3853
+ auth-key=${this.authKey}
3854
+ auth-token=${this.authToken}
3855
+ api-url=${this.apiUrl}
3856
+ api-version=${this.apiVersion}
3857
+ app-server=${this.appServer}
3858
+ ?flag-opendata=${this.flagOpendata}
3859
+ @prompt-submitted=${this._handlePromptSubmitted}
3860
+ @prompt-stopped=${this._handlePromptStopped}
3861
+ @dataset-selected=${this._handleDatasetSelected}
3862
+ @dataset-removed=${this._handleDatasetRemoved}
3863
+ ></luzmo-ai-interaction-textarea>
3864
+ </div>
3865
+ `;
3866
+ }
3867
+ };
3868
+ t([f({ type: Array })], $.prototype, "messages", void 0), t([f({
3869
+ type: Array,
3870
+ attribute: "selected-datasets"
3871
+ })], $.prototype, "selectedDatasets", void 0), t([f({ type: String })], $.prototype, "placeholder", void 0), t([f({
3872
+ type: Boolean,
3873
+ reflect: !0
3874
+ })], $.prototype, "disabled", void 0), t([f({
3875
+ type: Boolean,
3876
+ reflect: !0
3877
+ })], $.prototype, "stoppable", void 0), t([f({
3878
+ type: Boolean,
3879
+ attribute: "show-assistant-context-menu"
3880
+ })], $.prototype, "showAssistantContextMenu", void 0), t([f({
3881
+ type: String,
3882
+ attribute: "auth-key"
3883
+ })], $.prototype, "authKey", void 0), t([f({
3884
+ type: String,
3885
+ attribute: "auth-token"
3886
+ })], $.prototype, "authToken", void 0), t([f({
3887
+ type: String,
3888
+ attribute: "api-url"
3889
+ })], $.prototype, "apiUrl", void 0), t([f({
3890
+ type: String,
3891
+ attribute: "app-server"
3892
+ })], $.prototype, "appServer", void 0), t([f({
3893
+ type: Boolean,
3894
+ attribute: "flag-opendata"
3895
+ })], $.prototype, "flagOpendata", void 0), t([f({
3896
+ type: Boolean,
3897
+ attribute: "hide-dataset-button"
3898
+ })], $.prototype, "hideDatasetButton", void 0), t([f({
3899
+ type: Boolean,
3900
+ attribute: "hide-dataset-icons"
3901
+ })], $.prototype, "hideDatasetIcons", void 0), t([f({
3902
+ type: Boolean,
3903
+ attribute: "disable-dataset-modification"
3904
+ })], $.prototype, "disableDatasetModification", void 0), t([f({
3905
+ type: Boolean,
3906
+ attribute: "hide-selected-datasets"
3907
+ })], $.prototype, "hideSelectedDatasets", void 0), t([f({
3908
+ type: Boolean,
3909
+ attribute: "disable-column-mentions"
3910
+ })], $.prototype, "disableColumnMentions", void 0), t([f({
3911
+ type: Boolean,
3912
+ attribute: "require-dataset"
3913
+ })], $.prototype, "requireDataset", void 0), t([f({
3914
+ type: Boolean,
3915
+ reflect: !0,
3916
+ attribute: "allow-images"
3917
+ })], $.prototype, "allowImages", void 0), t([f({
3918
+ type: Boolean,
3919
+ reflect: !0,
3920
+ attribute: "allow-voice-input"
3921
+ })], $.prototype, "allowVoiceInput", void 0), t([f({
3922
+ type: Array,
3923
+ attribute: "accepted-file-types"
3924
+ })], $.prototype, "acceptedFileTypes", void 0), t([f({ attribute: !1 })], $.prototype, "uploadAttachments", void 0), t([f({ type: String })], $.prototype, "agent", void 0), t([f({ type: String })], $.prototype, "task", void 0), t([f({
3925
+ type: String,
3926
+ attribute: "model-preference"
3927
+ })], $.prototype, "modelPreference", void 0), t([f({ attribute: !1 })], $.prototype, "chatSession", void 0), t([f({
3928
+ type: String,
3929
+ attribute: "conversation-id"
3930
+ })], $.prototype, "conversationId", void 0), t([f({
3931
+ type: Object,
3932
+ attribute: "chart"
3933
+ })], $.prototype, "chart", void 0), t([f({ type: Object })], $.prototype, "dashboard", void 0), t([f({
3934
+ type: String,
3935
+ attribute: "current-screen-mode"
3936
+ })], $.prototype, "currentScreenMode", void 0), t([f({
3937
+ type: String,
3938
+ attribute: "locale-id"
3939
+ })], $.prototype, "localeId", void 0), t([f({
3940
+ type: String,
3941
+ attribute: "timezone-id"
3942
+ })], $.prototype, "timezoneId", void 0), t([f({
3943
+ type: String,
3944
+ attribute: "api-version"
3945
+ })], $.prototype, "apiVersion", void 0), t([f({ converter: { fromAttribute: (e) => e !== "false" && e !== null } })], $.prototype, "stream", void 0), t([f({
3946
+ type: String,
3947
+ attribute: "loading-message"
3948
+ })], $.prototype, "loadingMessage", void 0), t([f({
3949
+ type: String,
3950
+ attribute: "cancelled-message"
3951
+ })], $.prototype, "cancelledMessage", void 0), t([f({
3952
+ type: String,
3953
+ attribute: "initial-prompt"
3954
+ })], $.prototype, "initialPrompt", void 0), t([f({
3955
+ type: String,
3956
+ attribute: "empty-state-title"
3957
+ })], $.prototype, "emptyStateTitle", void 0), t([f({
3958
+ type: String,
3959
+ attribute: "empty-state-subtitle"
3960
+ })], $.prototype, "emptyStateSubtitle", void 0), t([f({
3961
+ type: Array,
3962
+ attribute: !1
3963
+ })], $.prototype, "emptyStateSuggestions", void 0), t([p()], $.prototype, "_textareaValue", void 0), t([p()], $.prototype, "_assistantMessageActionsSlotHasContent", void 0), t([p()], $.prototype, "_pendingAssistantMessageAction", void 0);
3964
+ //#endregion
3965
+ //#region src/components/ai-chat/ai-chat-events.ts
3966
+ function zr(e) {
3967
+ return e.recognized === !0;
3968
+ }
3969
+ //#endregion
3970
+ //#region src/components/ai-chat/index.ts
3971
+ customElements.get("luzmo-ai-chat") || customElements.define("luzmo-ai-chat", $);
3972
+ //#endregion
3973
+ export { wn as C, Dn as S, Sn as T, Mn as _, Lr as a, kn as b, Mr as c, Yn as d, Ln as f, In as g, Pn as h, Ir as i, jr as l, Nn as m, $ as n, Pr as o, Rn as p, Rr as r, Nr as s, zr as t, Gn as u, An as v, Cn as w, On as x, jn as y };