@ckeditor/ckeditor5-ai 47.7.1-alpha.0 → 47.7.2-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (318) hide show
  1. package/build/ai.js +1 -1
  2. package/dist/index.js +5 -5
  3. package/dist/translations/af.js +1 -1
  4. package/dist/translations/af.umd.js +1 -1
  5. package/dist/translations/ar.js +1 -1
  6. package/dist/translations/ar.umd.js +1 -1
  7. package/dist/translations/ast.js +1 -1
  8. package/dist/translations/ast.umd.js +1 -1
  9. package/dist/translations/az.js +1 -1
  10. package/dist/translations/az.umd.js +1 -1
  11. package/dist/translations/be.js +1 -1
  12. package/dist/translations/be.umd.js +1 -1
  13. package/dist/translations/bg.js +1 -1
  14. package/dist/translations/bg.umd.js +1 -1
  15. package/dist/translations/bn.js +1 -1
  16. package/dist/translations/bn.umd.js +1 -1
  17. package/dist/translations/bs.js +1 -1
  18. package/dist/translations/bs.umd.js +1 -1
  19. package/dist/translations/ca.js +1 -1
  20. package/dist/translations/ca.umd.js +1 -1
  21. package/dist/translations/cs.js +1 -1
  22. package/dist/translations/cs.umd.js +1 -1
  23. package/dist/translations/da.js +1 -1
  24. package/dist/translations/da.umd.js +1 -1
  25. package/dist/translations/de-ch.js +1 -1
  26. package/dist/translations/de-ch.umd.js +1 -1
  27. package/dist/translations/de.js +1 -1
  28. package/dist/translations/de.umd.js +1 -1
  29. package/dist/translations/el.js +1 -1
  30. package/dist/translations/el.umd.js +1 -1
  31. package/dist/translations/en-au.js +1 -1
  32. package/dist/translations/en-au.umd.js +1 -1
  33. package/dist/translations/en-gb.js +1 -1
  34. package/dist/translations/en-gb.umd.js +1 -1
  35. package/dist/translations/en.js +1 -1
  36. package/dist/translations/en.umd.js +1 -1
  37. package/dist/translations/eo.js +1 -1
  38. package/dist/translations/eo.umd.js +1 -1
  39. package/dist/translations/es-co.js +1 -1
  40. package/dist/translations/es-co.umd.js +1 -1
  41. package/dist/translations/es.js +1 -1
  42. package/dist/translations/es.umd.js +1 -1
  43. package/dist/translations/et.js +1 -1
  44. package/dist/translations/et.umd.js +1 -1
  45. package/dist/translations/eu.js +1 -1
  46. package/dist/translations/eu.umd.js +1 -1
  47. package/dist/translations/fa.js +1 -1
  48. package/dist/translations/fa.umd.js +1 -1
  49. package/dist/translations/fi.js +1 -1
  50. package/dist/translations/fi.umd.js +1 -1
  51. package/dist/translations/fr.js +1 -1
  52. package/dist/translations/fr.umd.js +1 -1
  53. package/dist/translations/gl.js +1 -1
  54. package/dist/translations/gl.umd.js +1 -1
  55. package/dist/translations/gu.js +1 -1
  56. package/dist/translations/gu.umd.js +1 -1
  57. package/dist/translations/he.js +1 -1
  58. package/dist/translations/he.umd.js +1 -1
  59. package/dist/translations/hi.js +1 -1
  60. package/dist/translations/hi.umd.js +1 -1
  61. package/dist/translations/hr.js +1 -1
  62. package/dist/translations/hr.umd.js +1 -1
  63. package/dist/translations/hu.js +1 -1
  64. package/dist/translations/hu.umd.js +1 -1
  65. package/dist/translations/hy.js +1 -1
  66. package/dist/translations/hy.umd.js +1 -1
  67. package/dist/translations/id.js +1 -1
  68. package/dist/translations/id.umd.js +1 -1
  69. package/dist/translations/it.js +1 -1
  70. package/dist/translations/it.umd.js +1 -1
  71. package/dist/translations/ja.js +1 -1
  72. package/dist/translations/ja.umd.js +1 -1
  73. package/dist/translations/jv.js +1 -1
  74. package/dist/translations/jv.umd.js +1 -1
  75. package/dist/translations/kk.js +1 -1
  76. package/dist/translations/kk.umd.js +1 -1
  77. package/dist/translations/km.js +1 -1
  78. package/dist/translations/km.umd.js +1 -1
  79. package/dist/translations/kn.js +1 -1
  80. package/dist/translations/kn.umd.js +1 -1
  81. package/dist/translations/ko.js +1 -1
  82. package/dist/translations/ko.umd.js +1 -1
  83. package/dist/translations/ku.js +1 -1
  84. package/dist/translations/ku.umd.js +1 -1
  85. package/dist/translations/lt.js +1 -1
  86. package/dist/translations/lt.umd.js +1 -1
  87. package/dist/translations/lv.js +1 -1
  88. package/dist/translations/lv.umd.js +1 -1
  89. package/dist/translations/ms.js +1 -1
  90. package/dist/translations/ms.umd.js +1 -1
  91. package/dist/translations/nb.js +1 -1
  92. package/dist/translations/nb.umd.js +1 -1
  93. package/dist/translations/ne.js +1 -1
  94. package/dist/translations/ne.umd.js +1 -1
  95. package/dist/translations/nl.js +1 -1
  96. package/dist/translations/nl.umd.js +1 -1
  97. package/dist/translations/no.js +1 -1
  98. package/dist/translations/no.umd.js +1 -1
  99. package/dist/translations/oc.js +1 -1
  100. package/dist/translations/oc.umd.js +1 -1
  101. package/dist/translations/pl.js +1 -1
  102. package/dist/translations/pl.umd.js +1 -1
  103. package/dist/translations/pt-br.js +1 -1
  104. package/dist/translations/pt-br.umd.js +1 -1
  105. package/dist/translations/pt.js +1 -1
  106. package/dist/translations/pt.umd.js +1 -1
  107. package/dist/translations/ro.js +1 -1
  108. package/dist/translations/ro.umd.js +1 -1
  109. package/dist/translations/ru.js +1 -1
  110. package/dist/translations/ru.umd.js +1 -1
  111. package/dist/translations/si.js +1 -1
  112. package/dist/translations/si.umd.js +1 -1
  113. package/dist/translations/sk.js +1 -1
  114. package/dist/translations/sk.umd.js +1 -1
  115. package/dist/translations/sl.js +1 -1
  116. package/dist/translations/sl.umd.js +1 -1
  117. package/dist/translations/sq.js +1 -1
  118. package/dist/translations/sq.umd.js +1 -1
  119. package/dist/translations/sr-latn.js +1 -1
  120. package/dist/translations/sr-latn.umd.js +1 -1
  121. package/dist/translations/sr.js +1 -1
  122. package/dist/translations/sr.umd.js +1 -1
  123. package/dist/translations/sv.js +1 -1
  124. package/dist/translations/sv.umd.js +1 -1
  125. package/dist/translations/th.js +1 -1
  126. package/dist/translations/th.umd.js +1 -1
  127. package/dist/translations/ti.js +1 -1
  128. package/dist/translations/ti.umd.js +1 -1
  129. package/dist/translations/tk.js +1 -1
  130. package/dist/translations/tk.umd.js +1 -1
  131. package/dist/translations/tr.js +1 -1
  132. package/dist/translations/tr.umd.js +1 -1
  133. package/dist/translations/tt.js +1 -1
  134. package/dist/translations/tt.umd.js +1 -1
  135. package/dist/translations/ug.js +1 -1
  136. package/dist/translations/ug.umd.js +1 -1
  137. package/dist/translations/uk.js +1 -1
  138. package/dist/translations/uk.umd.js +1 -1
  139. package/dist/translations/ur.js +1 -1
  140. package/dist/translations/ur.umd.js +1 -1
  141. package/dist/translations/uz.js +1 -1
  142. package/dist/translations/uz.umd.js +1 -1
  143. package/dist/translations/vi.js +1 -1
  144. package/dist/translations/vi.umd.js +1 -1
  145. package/dist/translations/zh-cn.js +1 -1
  146. package/dist/translations/zh-cn.umd.js +1 -1
  147. package/dist/translations/zh.js +1 -1
  148. package/dist/translations/zh.umd.js +1 -1
  149. package/package.json +15 -15
  150. package/src/aiactions/aiactions.js +1 -1
  151. package/src/aiactions/model/aiactionsinteraction.js +1 -1
  152. package/src/aiactions/model/aiactionsreply.js +1 -1
  153. package/src/aiassistant/adapters/aiadapter.js +1 -1
  154. package/src/aiassistant/adapters/aitextadapter.js +1 -1
  155. package/src/aiassistant/adapters/awstextadapter.js +1 -1
  156. package/src/aiassistant/adapters/openaitextadapter.js +1 -1
  157. package/src/aiassistant/aiassistant.js +1 -1
  158. package/src/aiassistant/aiassistantediting.js +1 -1
  159. package/src/aiassistant/aiassistantui.js +1 -1
  160. package/src/aiassistant/legacyerrors.js +1 -1
  161. package/src/aiassistant/ui/aiassistantcontroller.js +2 -2
  162. package/src/aiassistant/ui/form/aiformcontentarea.js +1 -1
  163. package/src/aiassistant/ui/form/aiformerrorview.js +1 -1
  164. package/src/aiassistant/ui/form/aiformpromptview.js +1 -1
  165. package/src/aiassistant/ui/form/aiformtoolbarview.js +1 -1
  166. package/src/aiassistant/ui/form/aiformview.js +1 -1
  167. package/src/aiassistant/ui/form/aihistorylistitemview.js +1 -1
  168. package/src/aiassistant/ui/form/aihistorylistview.js +1 -1
  169. package/src/aiassistant/ui/form/prompthistory.js +1 -1
  170. package/src/aiassistant/ui/showaiassistantcommand.js +1 -1
  171. package/src/aiassistant/utils/common-translations.js +1 -1
  172. package/src/aiassistant/utils/normalizecommandsconfig.js +1 -1
  173. package/src/aiballoon/aiballoon.js +1 -1
  174. package/src/aiballoon/ui/aiballoonview.js +1 -1
  175. package/src/aichat/aichat.js +1 -1
  176. package/src/aichat/aichatballoon.js +1 -1
  177. package/src/aichat/aichatcontroller.js +1 -1
  178. package/src/aichat/aichatui.js +1 -1
  179. package/src/aichat/model/aichatcontext.js +1 -1
  180. package/src/aichat/model/aichatconversation.js +1 -1
  181. package/src/aichat/model/aichatinteraction.js +1 -1
  182. package/src/aichat/ui/aichatballoonview.js +1 -1
  183. package/src/aichat/ui/aichatcontrolsview.js +1 -1
  184. package/src/aichat/ui/aichatfeedview.js +1 -1
  185. package/src/aichat/ui/aichatheaderview.js +1 -1
  186. package/src/aichat/ui/aichatview.js +1 -1
  187. package/src/aichat/ui/controls/aichatchipsoverflowmanager.js +1 -1
  188. package/src/aichat/ui/controls/aichatcontextitembuttonview.js +1 -1
  189. package/src/aichat/ui/controls/aichatcontextpanelurlinputview.js +1 -1
  190. package/src/aichat/ui/controls/aichatcontextpanelview.js +1 -1
  191. package/src/aichat/ui/controls/aichatcontrolsloaderview.js +1 -1
  192. package/src/aichat/ui/controls/aichatpromptcapabilitiesview.js +1 -1
  193. package/src/aichat/ui/controls/aichatpromptinputview.js +1 -1
  194. package/src/aichat/ui/controls/aichatpromptsuggestionslistview.js +1 -1
  195. package/src/aichat/ui/controls/resources/aichatcontextresourceslistview.js +1 -1
  196. package/src/aichat/ui/controls/resources/aichatcontextresourcesview.js +1 -1
  197. package/src/aichat/ui/controls/resources/aichatresourcelistitemview.js +1 -1
  198. package/src/aichat/ui/controls/resources/aichatresourcesballoonview.js +1 -1
  199. package/src/aichat/ui/controls/resources/aichatresourcessearchinputview.js +1 -1
  200. package/src/aichat/ui/feed/aichatfeedcontextchipsview.js +1 -1
  201. package/src/aichat/ui/feed/aichatfeedcustomelementview.js +1 -1
  202. package/src/aichat/ui/feed/aichatfeederroritemview.js +1 -1
  203. package/src/aichat/ui/feed/aichatfeedinteractionheaderview.js +1 -1
  204. package/src/aichat/ui/feed/aichatfeeditemview.js +1 -1
  205. package/src/aichat/ui/feed/aichatfeedreplyitemview.js +1 -1
  206. package/src/aichat/ui/feed/aichatfeedsuggestionitemactionsview.js +1 -1
  207. package/src/aichat/ui/feed/aichatfeedsuggestionitemview.js +1 -1
  208. package/src/aichat/ui/feed/aichatfeedusermessageitem.js +1 -1
  209. package/src/aichat/utils/eventnames.js +1 -1
  210. package/src/aichat/utils/promisequeue.js +1 -1
  211. package/src/aichathistory/aichathistory.js +1 -1
  212. package/src/aichathistory/aichathistorycontroller.js +1 -1
  213. package/src/aichathistory/aichathistoryui.js +1 -1
  214. package/src/aichathistory/model/aichathistoryconversations.js +1 -1
  215. package/src/aichathistory/model/aichathistoryitem.js +1 -1
  216. package/src/aichathistory/ui/aichathistorylistitemview.js +2 -2
  217. package/src/aichathistory/ui/aichathistorylistview.js +1 -1
  218. package/src/aichathistory/ui/aichathistorysectionlistview.js +1 -1
  219. package/src/aichathistory/ui/aichathistoryview.js +1 -1
  220. package/src/aichatshortcuts/aichatshortcuts.js +1 -1
  221. package/src/aichatshortcuts/ui/aichatshortcutsview.js +1 -1
  222. package/src/aichatshortcuts/ui/aichatshortcutview.js +1 -1
  223. package/src/aicore/aiconnector.js +1 -1
  224. package/src/aicore/aiediting.js +1 -1
  225. package/src/aicore/model/aicapabilities.js +1 -1
  226. package/src/aicore/model/aicontext.js +1 -1
  227. package/src/aicore/model/aiinteraction.js +1 -1
  228. package/src/aicore/model/aimodels.js +1 -1
  229. package/src/aicore/model/aireply.js +1 -1
  230. package/src/aicore/pipeline/airesponseapplier.js +2 -2
  231. package/src/aicore/pipeline/airesponseparser.js +2 -2
  232. package/src/aicore/ui/aidisclaimerview.js +1 -1
  233. package/src/aicore/ui/aiskeleton.js +1 -1
  234. package/src/aicore/ui/aispinner.js +1 -1
  235. package/src/aicore/ui/suggestioncontainer/aiminitoolbarview.js +1 -1
  236. package/src/aicore/ui/suggestioncontainer/aisuggestionbodyview.js +1 -1
  237. package/src/aicore/ui/suggestioncontainer/aisuggestioncontainerview.js +1 -1
  238. package/src/aicore/ui/suggestioncontainer/aisuggestioncontentpartheaderview.js +1 -1
  239. package/src/aicore/ui/suggestioncontainer/aisuggestioncontentpartstateview.js +1 -1
  240. package/src/aicore/ui/suggestioncontainer/aisuggestioncontentparttoolbarview.js +1 -1
  241. package/src/aicore/ui/suggestioncontainer/aisuggestioncontentpartview.js +1 -1
  242. package/src/aicore/ui/suggestioncontainer/aisuggestionheaderview.js +1 -1
  243. package/src/aicore/ui/suggestioncontainer/aisuggestionloaderview.js +1 -1
  244. package/src/aicore/ui/suggestioncontainer/aisuggestionstreamablecontentview.js +1 -1
  245. package/src/aicore/ui/suggestioncontainer/aiwebsourcesview.js +1 -1
  246. package/src/aicore/utils/common-translations.js +1 -1
  247. package/src/aicore/utils/createresizebutton.js +1 -1
  248. package/src/aicore/utils/documentposition.js +1 -1
  249. package/src/aicore/utils/documentrange.js +1 -1
  250. package/src/aicore/utils/eventnames.js +1 -1
  251. package/src/aicore/utils/geteditorfromcontext.js +1 -1
  252. package/src/aicore/utils/getoperationsfromreply.js +1 -1
  253. package/src/aicore/utils/getsuggestionpartsfromreply.js +1 -1
  254. package/src/aicore/utils/htmlparser.js +1 -1
  255. package/src/aicore/utils/htmlstreamer.js +1 -1
  256. package/src/aicore/utils/scrollmanager.js +1 -1
  257. package/src/aieditorintegration/aieditorintegration.js +1 -1
  258. package/src/aieditorintegration/aitogglebutton/aitogglebuttonui.js +1 -1
  259. package/src/aieditorintegration/aitogglebutton/toggleaicommand.js +1 -1
  260. package/src/aiquickactions/aiquickactions.js +1 -1
  261. package/src/aiquickactions/aiquickactionscommand.js +1 -1
  262. package/src/aiquickactions/aiquickactionsediting.js +1 -1
  263. package/src/aiquickactions/aiquickactionsui.js +1 -1
  264. package/src/aiquickactions/ui/aiquickactionsbuttoncreator.js +1 -1
  265. package/src/aiquickactions/ui/aiquickactionsdropdowncontentview.js +1 -1
  266. package/src/aiquickactions/ui/aiquickactionsdropdowncreator.js +1 -1
  267. package/src/aiquickactions/ui/aiquickactionsfilteredlistview.js +1 -1
  268. package/src/aiquickactions/ui/balloon/aiactionsballoondisclaimerview.js +1 -1
  269. package/src/aiquickactions/ui/balloon/aiactionsballoontoolbarview.js +1 -1
  270. package/src/aiquickactions/ui/balloon/aiactionsballoonview.js +1 -1
  271. package/src/aiquickactions/ui/dropdownmenubuttonwithhighlightview.js +1 -1
  272. package/src/aireviewcore/aireviewcorecontroller.js +1 -1
  273. package/src/aireviewcore/aireviewcoreediting.js +1 -1
  274. package/src/aireviewcore/aireviewcoreui.js +1 -1
  275. package/src/aireviewcore/model/aireviewcheck.js +1 -1
  276. package/src/aireviewcore/model/aireviewchecklist.js +1 -1
  277. package/src/aireviewcore/model/aireviewcheckresult.js +1 -1
  278. package/src/aireviewcore/model/aireviewcheckresultchange.js +1 -1
  279. package/src/aireviewcore/model/aireviewcheckrun.js +1 -1
  280. package/src/aireviewcore/model/aireviewsystemcheckrun.js +1 -1
  281. package/src/aireviewcore/ui/aireviewcoreballoonsuggestionview.js +1 -1
  282. package/src/aireviewcore/ui/aireviewcorechecklistitemresultview.js +1 -1
  283. package/src/aireviewcore/ui/aireviewcorecustomcheckview.js +1 -1
  284. package/src/aireviewcore/ui/aireviewcorefinishreviewbuttonview.js +1 -1
  285. package/src/aireviewcore/ui/aireviewcoregeneralerrorview.js +1 -1
  286. package/src/aireviewcore/ui/aireviewcorepromptinputview.js +1 -1
  287. package/src/aireviewcore/ui/aireviewcorereviewchecklistview.js +1 -1
  288. package/src/aireviewcore/ui/aireviewcorereviewcommandlistitemview.js +1 -1
  289. package/src/aireviewcore/ui/aireviewcorereviewcompletedview.js +1 -1
  290. package/src/aireviewcore/ui/aireviewcoreuicheckresultsview.js +1 -1
  291. package/src/aireviewcore/ui/aireviewcoreview.js +1 -1
  292. package/src/aireviewcore/ui/form/aireviewcoreformdropdown.js +1 -1
  293. package/src/aireviewcore/ui/form/aireviewcoreformmanager.js +1 -1
  294. package/src/aireviewmode/aireviewcheckdefinitions.js +1 -1
  295. package/src/aireviewmode/aireviewmode.js +1 -1
  296. package/src/aireviewmode/aireviewmodecontroller.js +1 -1
  297. package/src/aireviewmode/aireviewmodeui.js +1 -1
  298. package/src/aireviewmode/model/aireviewcheckcustom.js +1 -1
  299. package/src/aireviewmode/model/aireviewcheckextra.js +1 -1
  300. package/src/aireviewmode/model/aireviewcustomcheckrun.js +1 -1
  301. package/src/aireviewmode/model/aireviewextracheckrun.js +1 -1
  302. package/src/aireviewmode/model/aireviewmodechecklist.js +1 -1
  303. package/src/aitabs/aitabs.js +1 -1
  304. package/src/aitabs/aitabsmainview.js +1 -1
  305. package/src/aitabs/tabs/aitabsview.js +1 -1
  306. package/src/aitabs/tabs/tabbuttonview.js +1 -1
  307. package/src/aitabs/tabs/tabpanelview.js +1 -1
  308. package/src/aitranslate/aitranslate.js +1 -1
  309. package/src/aitranslate/aitranslatecontroller.js +1 -1
  310. package/src/aitranslate/aitranslateui.js +1 -1
  311. package/src/aitranslate/model/aitranslatecheck.js +1 -1
  312. package/src/aitranslate/model/aitranslatechecklist.js +1 -1
  313. package/src/aitranslate/model/aitranslatecheckrun.js +1 -1
  314. package/src/aitranslate/ui/aitranslatechecklistview.js +1 -1
  315. package/src/aitranslate/ui/aitranslatecheckresultsview.js +1 -1
  316. package/src/errors.js +1 -1
  317. package/src/errorsmap.js +1 -1
  318. package/src/index.js +1 -1
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x112432=_0x3506;function _0x3506(_0x4d6de8,_0x552995){const _0x4564d1=_0x4564();return _0x3506=function(_0x350619,_0x318153){_0x350619=_0x350619-0xd3;let _0x2c2232=_0x4564d1[_0x350619];return _0x2c2232;},_0x3506(_0x4d6de8,_0x552995);}(function(_0x4388ff,_0x456f56){const _0x517995=_0x3506,_0x107edf=_0x4388ff();while(!![]){try{const _0x3ef10c=-parseInt(_0x517995(0x109))/0x1+-parseInt(_0x517995(0xf1))/0x2*(-parseInt(_0x517995(0x105))/0x3)+-parseInt(_0x517995(0xdb))/0x4+-parseInt(_0x517995(0xe0))/0x5+parseInt(_0x517995(0xd5))/0x6+-parseInt(_0x517995(0xf4))/0x7*(-parseInt(_0x517995(0xec))/0x8)+parseInt(_0x517995(0xe8))/0x9;if(_0x3ef10c===_0x456f56)break;else _0x107edf['push'](_0x107edf['shift']());}catch(_0x52a3d3){_0x107edf['push'](_0x107edf['shift']());}}}(_0x4564,0x537a5));import{Plugin as _0x5df656}from'ckeditor5/src/core.js';import{AIBalloon as _0x3edd7a}from'../aiballoon/aiballoon.js';import{AI_REPLY_ACTIONS as _0x48d540}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';import{AIChatBalloonView as _0x216dd0}from'./ui/aichatballoonview.js';import{AI_SUGGESTION_UI_EVENT_NAMES as _0x26263c}from'../aicore/utils/eventnames.js';function _0x4564(){const _0x3b3fc8=['once','TrackChanges','open','2803055PlxZqk','toggleRotatorButtonsVisibility','requires','areActionsDisabled','close','locale','get','_restoreDefaultViewFocus','229626pqANJf','showRotator','isOfficialPlugin','view','8IGCCvZ','plugins','_chatBalloonView','focus','headerView','24974edXVgi','showDiff','delegate','1672958iMnZaS','pluginName','ck-ai-chat-balloon','filter','AIChatBalloon','commands','rejectSuggestion','showPrevious','updateContent','bind','_createChatBalloonView','insertSuggestion','isPremiumPlugin','children','remove','dialogClosed','_toggleRotatorButtonsInDialogHeader','141iFeChz','AIBalloon','togglePartToolbarEnabled','isTrackChangesOn','115294NYVGbJ','beforeDialogClosed','set','render','nextButtonView','value','has','addMany','setState','aiChatBalloon','config','trackChanges','2678514AIsFTF','Dialog','previousButtonView','showNext','ai.availableReplyActions','editor','1119944NhEAWP','applySuggestion'];_0x4564=function(){return _0x3b3fc8;};return _0x4564();}import{Dialog as _0x4fa0c3}from'ckeditor5/src/ui.js';export class AIChatBalloon extends _0x5df656{static get[_0x112432(0xe2)](){return[_0x4fa0c3,_0x3edd7a];}static get[_0x112432(0xf5)](){const _0x3482d8=_0x112432;return _0x3482d8(0xf8);}static get[_0x112432(0xea)](){return!0x0;}static get[_0x112432(0x100)](){return!0x0;}[_0x112432(0xee)];constructor(_0x992453){const _0x493fed=_0x112432;super(_0x992453),this[_0x493fed(0x10b)](_0x493fed(0xf2),!0x1);}[_0x112432(0xdf)](_0x15a9c){const _0x41248b=_0x112432,_0xb0aaf1=this[_0x41248b(0xda)];this[_0x41248b(0xee)]||(this[_0x41248b(0xee)]=this[_0x41248b(0xfe)]()),_0xb0aaf1[_0x41248b(0xed)][_0x41248b(0xe6)](_0x41248b(0x106))[_0x41248b(0xdf)]({..._0x15a9c,'id':_0x41248b(0x112),'class':_0x41248b(0xf6),'mainView':this[_0x41248b(0xee)]}),this[_0x41248b(0x104)](_0x15a9c[_0x41248b(0xe9)]),this[_0x41248b(0xee)][_0x41248b(0x107)](!_0x15a9c[_0x41248b(0xe3)]),this[_0x41248b(0xe7)]();}[_0x112432(0xe4)](){const _0xa49998=_0x112432;this[_0xa49998(0xda)][_0xa49998(0xed)][_0xa49998(0xe6)](_0xa49998(0x106))[_0xa49998(0xe4)]();}[_0x112432(0xfc)](_0x1b3332){const _0x5472c1=_0x112432;return this[_0x5472c1(0xee)]||(this[_0x5472c1(0xee)]=this[_0x5472c1(0xfe)]()),this[_0x5472c1(0xee)][_0x5472c1(0xfc)](_0x1b3332);}[_0x112432(0x111)](_0x4ac987){const _0x49ddb4=_0x112432;this[_0x49ddb4(0xee)]&&this[_0x49ddb4(0xee)][_0x49ddb4(0x111)](_0x4ac987);}[_0x112432(0xfe)](){const _0xa10466=_0x112432,_0x10f825=this[_0xa10466(0xda)],_0x2da645=_0x10f825[_0xa10466(0xed)][_0xa10466(0xe6)](_0xa10466(0x106)),_0x549a04=_0x10f825[_0xa10466(0xf9)][_0xa10466(0xe6)](_0xa10466(0xd4));let _0xda0b4=_0x10f825[_0xa10466(0xd3)][_0xa10466(0xe6)](_0xa10466(0xd9))||[..._0x48d540];_0x10f825[_0xa10466(0xed)][_0xa10466(0x10f)](_0xa10466(0xde))||(_0xda0b4=_0xda0b4[_0xa10466(0xf7)](_0xa7b2cc=>_0xa10466(0xff)!=_0xa7b2cc));const _0x64878=new _0x216dd0(_0x10f825[_0xa10466(0xe5)],{'availableActions':_0xda0b4,'showApplyButton':!0x0,'showSuggestButton':!!_0x549a04});return _0x64878[_0xa10466(0xfd)](_0xa10466(0xf2))['to'](this),_0x64878[_0xa10466(0xf3)](..._0x26263c)['to'](this),_0x64878[_0xa10466(0xf3)](_0xa10466(0xfb),_0xa10466(0xd8))['to'](this),_0x2da645[_0xa10466(0xf3)](_0xa10466(0x103))['to'](this),_0x64878['on'](_0xa10466(0xdc),this[_0xa10466(0xe7)][_0xa10466(0xfd)](this)),_0x64878['on'](_0xa10466(0xff),this[_0xa10466(0xe7)][_0xa10466(0xfd)](this)),_0x64878['on'](_0xa10466(0xfa),this[_0xa10466(0xe7)][_0xa10466(0xfd)](this)),_0x549a04&&_0x64878[_0xa10466(0xfd)](_0xa10466(0x108))['to'](_0x549a04,_0xa10466(0x10e)),_0x64878[_0xa10466(0x10c)](),_0x64878;}[_0x112432(0x104)](_0x4ae4b2){const _0x56794c=_0x112432,_0x11530e=this[_0x56794c(0xda)],_0x4f0132=_0x11530e[_0x56794c(0xed)][_0x56794c(0xe6)](_0x56794c(0xd6))[_0x56794c(0xeb)][_0x56794c(0xf0)][_0x56794c(0x101)];this[_0x56794c(0xee)][_0x56794c(0xe1)](_0x4ae4b2),_0x4f0132[_0x56794c(0x10f)](this[_0x56794c(0xee)][_0x56794c(0xd7)])||(_0x4f0132[_0x56794c(0x110)]([this[_0x56794c(0xee)][_0x56794c(0xd7)],this[_0x56794c(0xee)][_0x56794c(0x10d)]],0x0),_0x11530e[_0x56794c(0xed)][_0x56794c(0xe6)](_0x56794c(0x106))[_0x56794c(0xdd)](_0x56794c(0x10a),()=>{const _0x1106e5=_0x56794c;_0x4f0132[_0x1106e5(0x102)](this[_0x1106e5(0xee)][_0x1106e5(0xd7)]),_0x4f0132[_0x1106e5(0x102)](this[_0x1106e5(0xee)][_0x1106e5(0x10d)]);}));}[_0x112432(0xe7)](){const _0x259669=_0x112432;this[_0x259669(0xee)][_0x259669(0xef)]();}}
23
+ const _0x34efa7=_0x5d26;(function(_0xf4df7f,_0x4019a0){const _0x4589d1=_0x5d26,_0x252b3f=_0xf4df7f();while(!![]){try{const _0x29a20d=parseInt(_0x4589d1(0x170))/0x1+parseInt(_0x4589d1(0x175))/0x2*(-parseInt(_0x4589d1(0x144))/0x3)+parseInt(_0x4589d1(0x16d))/0x4*(-parseInt(_0x4589d1(0x15b))/0x5)+parseInt(_0x4589d1(0x150))/0x6*(parseInt(_0x4589d1(0x16a))/0x7)+parseInt(_0x4589d1(0x173))/0x8+parseInt(_0x4589d1(0x16f))/0x9*(parseInt(_0x4589d1(0x16c))/0xa)+-parseInt(_0x4589d1(0x167))/0xb*(parseInt(_0x4589d1(0x161))/0xc);if(_0x29a20d===_0x4019a0)break;else _0x252b3f['push'](_0x252b3f['shift']());}catch(_0x2e294d){_0x252b3f['push'](_0x252b3f['shift']());}}}(_0x4c06,0xa41e1));function _0x5d26(_0x1d1f94,_0x27a1f3){const _0x4c06c5=_0x4c06();return _0x5d26=function(_0x5d2698,_0x1ca48c){_0x5d2698=_0x5d2698-0x136;let _0x3799f8=_0x4c06c5[_0x5d2698];return _0x3799f8;},_0x5d26(_0x1d1f94,_0x27a1f3);}import{Plugin as _0x17c9fc}from'ckeditor5/src/core.js';import{AIBalloon as _0x16d011}from'../aiballoon/aiballoon.js';import{AI_REPLY_ACTIONS as _0x3d6215}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';import{AIChatBalloonView as _0x655cb7}from'./ui/aichatballoonview.js';import{AI_SUGGESTION_UI_EVENT_NAMES as _0x239baf}from'../aicore/utils/eventnames.js';import{Dialog as _0x4288b8}from'ckeditor5/src/ui.js';export class AIChatBalloon extends _0x17c9fc{static get[_0x34efa7(0x176)](){return[_0x4288b8,_0x16d011];}static get[_0x34efa7(0x137)](){const _0x3bc785=_0x34efa7;return _0x3bc785(0x160);}static get[_0x34efa7(0x163)](){return!0x0;}static get[_0x34efa7(0x139)](){return!0x0;}[_0x34efa7(0x149)];constructor(_0xf6c07a){const _0x12c38d=_0x34efa7;super(_0xf6c07a),this[_0x12c38d(0x171)](_0x12c38d(0x145),!0x1);}[_0x34efa7(0x143)](_0x719580){const _0x311348=_0x34efa7,_0x2ab3cb=this[_0x311348(0x13d)];this[_0x311348(0x149)]||(this[_0x311348(0x149)]=this[_0x311348(0x15f)]()),_0x2ab3cb[_0x311348(0x151)][_0x311348(0x152)](_0x311348(0x14e))[_0x311348(0x143)]({..._0x719580,'id':_0x311348(0x157),'class':_0x311348(0x140),'mainView':this[_0x311348(0x149)]}),this[_0x311348(0x15e)](_0x719580[_0x311348(0x147)]),this[_0x311348(0x149)][_0x311348(0x16b)](!_0x719580[_0x311348(0x158)]),this[_0x311348(0x153)]();}[_0x34efa7(0x142)](){const _0x3500b4=_0x34efa7;this[_0x3500b4(0x13d)][_0x3500b4(0x151)][_0x3500b4(0x152)](_0x3500b4(0x14e))[_0x3500b4(0x142)]();}[_0x34efa7(0x14d)](_0x1fda80){const _0x154c4d=_0x34efa7;return this[_0x154c4d(0x149)]||(this[_0x154c4d(0x149)]=this[_0x154c4d(0x15f)]()),this[_0x154c4d(0x149)][_0x154c4d(0x14d)](_0x1fda80);}[_0x34efa7(0x168)](_0x34180e){const _0x449f7e=_0x34efa7;this[_0x449f7e(0x149)]&&this[_0x449f7e(0x149)][_0x449f7e(0x168)](_0x34180e);}[_0x34efa7(0x15f)](){const _0xe1e7a6=_0x34efa7,_0x3e961c=this[_0xe1e7a6(0x13d)],_0x4bbf85=_0x3e961c[_0xe1e7a6(0x151)][_0xe1e7a6(0x152)](_0xe1e7a6(0x14e)),_0x4cfc66=_0x3e961c[_0xe1e7a6(0x16e)][_0xe1e7a6(0x152)](_0xe1e7a6(0x14f));let _0x3aad1e=_0x3e961c[_0xe1e7a6(0x146)][_0xe1e7a6(0x152)](_0xe1e7a6(0x15a))||[..._0x3d6215];_0x3e961c[_0xe1e7a6(0x151)][_0xe1e7a6(0x156)](_0xe1e7a6(0x177))||(_0x3aad1e=_0x3aad1e[_0xe1e7a6(0x13e)](_0xad3450=>_0xe1e7a6(0x141)!=_0xad3450));const _0x51fd7a=new _0x655cb7(_0x3e961c[_0xe1e7a6(0x148)],{'availableActions':_0x3aad1e,'showApplyButton':!0x0,'showSuggestButton':!!_0x4cfc66});return _0x51fd7a[_0xe1e7a6(0x165)](_0xe1e7a6(0x145))['to'](this),_0x51fd7a[_0xe1e7a6(0x14b)](..._0x239baf)['to'](this),_0x51fd7a[_0xe1e7a6(0x14b)](_0xe1e7a6(0x13f),_0xe1e7a6(0x178))['to'](this),_0x4bbf85[_0xe1e7a6(0x14b)](_0xe1e7a6(0x136))['to'](this),_0x51fd7a['on'](_0xe1e7a6(0x169),this[_0xe1e7a6(0x153)][_0xe1e7a6(0x165)](this)),_0x51fd7a['on'](_0xe1e7a6(0x141),this[_0xe1e7a6(0x153)][_0xe1e7a6(0x165)](this)),_0x51fd7a['on'](_0xe1e7a6(0x138),this[_0xe1e7a6(0x153)][_0xe1e7a6(0x165)](this)),_0x4cfc66&&_0x51fd7a[_0xe1e7a6(0x165)](_0xe1e7a6(0x166))['to'](_0x4cfc66,_0xe1e7a6(0x164)),_0x51fd7a[_0xe1e7a6(0x14a)](),_0x51fd7a;}[_0x34efa7(0x15e)](_0x39001a){const _0x3cdcfb=_0x34efa7,_0x15c1c6=this[_0x3cdcfb(0x13d)],_0x28ac8a=_0x15c1c6[_0x3cdcfb(0x151)][_0x3cdcfb(0x152)](_0x3cdcfb(0x155))[_0x3cdcfb(0x162)][_0x3cdcfb(0x172)][_0x3cdcfb(0x13c)];this[_0x3cdcfb(0x149)][_0x3cdcfb(0x174)](_0x39001a),_0x28ac8a[_0x3cdcfb(0x156)](this[_0x3cdcfb(0x149)][_0x3cdcfb(0x13b)])||(_0x28ac8a[_0x3cdcfb(0x15c)]([this[_0x3cdcfb(0x149)][_0x3cdcfb(0x13b)],this[_0x3cdcfb(0x149)][_0x3cdcfb(0x15d)]],0x0),_0x15c1c6[_0x3cdcfb(0x151)][_0x3cdcfb(0x152)](_0x3cdcfb(0x14e))[_0x3cdcfb(0x14c)](_0x3cdcfb(0x159),()=>{const _0x3ef508=_0x3cdcfb;_0x28ac8a[_0x3ef508(0x154)](this[_0x3ef508(0x149)][_0x3ef508(0x13b)]),_0x28ac8a[_0x3ef508(0x154)](this[_0x3ef508(0x149)][_0x3ef508(0x15d)]);}));}[_0x34efa7(0x153)](){const _0x3d3b4f=_0x34efa7;this[_0x3d3b4f(0x149)][_0x3d3b4f(0x13a)]();}}function _0x4c06(){const _0x2ab455=['144444RZnDip','plugins','get','_restoreDefaultViewFocus','remove','Dialog','has','aiChatBalloon','areActionsDisabled','beforeDialogClosed','ai.availableReplyActions','5OYosHM','addMany','nextButtonView','_toggleRotatorButtonsInDialogHeader','_createChatBalloonView','AIChatBalloon','1032BHhDrE','view','isOfficialPlugin','value','bind','isTrackChangesOn','221716GudEAm','setState','applySuggestion','287WSmeav','togglePartToolbarEnabled','5876960nYURzn','3152748OPQaBI','commands','18sBtbyA','897659AoVLiP','set','headerView','9495680MwUdzG','toggleRotatorButtonsVisibility','2tuFFeR','requires','TrackChanges','showNext','dialogClosed','pluginName','rejectSuggestion','isPremiumPlugin','focus','previousButtonView','children','editor','filter','showPrevious','ck-ai-chat-balloon','insertSuggestion','close','open','3159651tpmqtk','showDiff','config','showRotator','locale','_chatBalloonView','render','delegate','once','updateContent','AIBalloon','trackChanges'];_0x4c06=function(){return _0x2ab455;};return _0x4c06();}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x102c9d=_0x77c5;(function(_0x5b62b1,_0x22aa55){const _0x5c419a=_0x77c5,_0x5f02a2=_0x5b62b1();while(!![]){try{const _0x287fed=-parseInt(_0x5c419a(0x23e))/0x1*(-parseInt(_0x5c419a(0x250))/0x2)+parseInt(_0x5c419a(0x2c1))/0x3+parseInt(_0x5c419a(0x2be))/0x4+-parseInt(_0x5c419a(0x1fe))/0x5+-parseInt(_0x5c419a(0x212))/0x6+parseInt(_0x5c419a(0x373))/0x7*(-parseInt(_0x5c419a(0x20d))/0x8)+-parseInt(_0x5c419a(0x348))/0x9*(-parseInt(_0x5c419a(0x210))/0xa);if(_0x287fed===_0x22aa55)break;else _0x5f02a2['push'](_0x5f02a2['shift']());}catch(_0x47b5fa){_0x5f02a2['push'](_0x5f02a2['shift']());}}}(_0x1ed0,0x34737));import{ContextPlugin as _0x31d929,Editor as _0xb49bf1}from'ckeditor5/src/core.js';import{BodyCollection as _0xaa0105}from'ckeditor5/src/ui.js';import{CKEditorError as _0x302247,logError as _0x5bf06e,scrollViewportToShowTarget as _0x5dad21,uid as _0x31ba12}from'ckeditor5/src/utils.js';import{AIConnector as _0x14f9fd}from'../aicore/aiconnector.js';import{AITabs as _0x367c5c}from'../aitabs/aitabs.js';import{AIChatConversation as _0x460b3a}from'./model/aichatconversation.js';import{getTranslation as _0x394fc2}from'../aicore/utils/common-translations.js';function _0x1ed0(){const _0x4a7d63=['collaboration.channelId','removed','_startConversationSafely','AI_CHAT_GENERIC_ERROR','webSearchFinished','from','data','delegate','dialogClosed','getOperations','setFeedItemAIReplySuggestionPartActive','requires','createPositionFromPath','parse','ai-chat-context-unsupported-file-type','insertSuggestion','lastInteraction','1bpjbyd','listenTo','getChildren','_aiEditing','commands','index','_currentPreviewedChangeGroup','resourceId','toggleSuggestionDisplayMode','resource','clearLoadingMessage','rejected','TrackChangesEditing','getInteractionAndReplyById','interactionDestroyed','load','removeFeedInteraction','sendMessage','3914RZLlgL','AI_CHAT_CONTEXT_FILE_TOO_MANY_PAGES','_createFromRanges','plugins','_handleUIUserMessage','howMany','revert','version','message','disableControls','webSearchStarted','AI_CHAT_UNABLE_TO_LOAD_CONVERSATION','locale','undo','isOfficialPlugin','addDocumentToContext','editors','view','getRoot','contextItemLoadingEnded','conversationInitialized','like','loadConversation','populateSourceResourceBalloon','getDocumentData','mouseOverSuggestion','setIsMaximized','AI_CHAT_CONTEXT_FORM_DATA_SIZE_LIMITS_EXCEEDED','detachFromDom','AIChatBalloon','resources','interactionFinished','log','maxOffset','showDiff','updateFeedItemAIReplyContent','setConversationTitle','uiId','lastCreated','startInteraction','_applyOperationsAsSuggestions','addUrlToContext','replyContentUpdated','replyCreated','forEach','ai-conversation-','_stopLastInteraction','addResourceToContext','applySuggestion','error','set','afterInit','sendUserMessage','enableControls','toggleReasoning','_insertSuggestion','_openBalloonFor','rootName','previous','addSelectionToChatContext','_flushLastInteractionUI','AIEditing','messageId','isDisabled','range','ai-chat-context-file-too-many-pages','_getUserPresentableContentPartDocumentRange','addFeedItemError','getChild','_batchToChanges','TrackChanges','getAttribute','ai-chat-conversation-start-failed','destroy','partIndex','push','_showConversationHistory','_aiChatUi','isCurrentDocumentInContext','nextSibling','showNext','ai-chat-controller-mouse-over','end','state','AI_CHAT_RESOURCE_LOAD_FAILED','includes','loadSourceResources','_toggleReasoning','setLoadingMessage','main','model','ai-request-aborted','resizedTabs','selection','_rejectSuggestion','_aiChatModels','AI_BALLOON_HEADER_TITLE','cloneNode','start','getGroupId','contextItem','data-id','createReply','history','AIConnector','contextItemRemoved','upsertAIChatRating','getRanges','baseVersion','ai.models.defaultModelId','397024migPxJ','capabilitiesUpdated','getChildAtOffset','98250hRFVsN','abortPromptStream','attachToDom','replies','ai-no-track-changes','addFilesToContext','AI_CHAT_CONTEXT_FILE_TOO_LARGE','toViewRange','_getLastCreatedConversationId','reasoningStarted','clearPendingContextUI','addSelectionToContext','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_URL','ai-chat-context-file-too-large','getConversation','getConversations','toggleWebSearch','Liked\x20response','mapper','resetMessageInput','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_FILE','_registerToolDataCallback','startConversation','selectModel','map','stopInteraction','updateFeedItemAIReplySuggestionContent','addFeedItemUserMessage','open','currentReply','addFeedItemAIReply','showChangeInText','getPath','_bodyCollection','hasChanges','fetchConversation','batch','slice','ai-chat-file-upload-failed','isStarted','filter','static','AI_CHAT_ABORTED_MESSAGE','alignToTop','Undo','anchorId','_getAIChatInteractionAPI','updateContent','removeSelectionFromContext','_getPresentableSiblingContentPartIndex','accepted','_logError','setState','text','finishInteraction','AI_CHAT_INVALID_REQUEST','updateConversationTitle','getAll','activeConversation','source','removeContextItem','_updateReplyContent','applyOperation','get','showPrevious','ai.models','contextItemAdded','ready','isCurrentDocumentInConversation','$graveyard','next','addFileToContext','_scrollToSuggestionRange','ai-chat-source-resources-load-failed','pluginName','delete','getSelectionText','sourceResourcesLoaded','domConverter','type','remove','setConversationContext','addContextOptionsChanged','new','setContextItemLoading','addFeedItemStaticMessage','find','updateFeedItemAIReplySuggestionPartState','AI_CHAT_CONTEXT_UNABLE_TO_LOAD_RESOURCES','viewRangeToDom','indexes','documentContextContent','add','interactionId','change','marker','handleUserInteraction','getDiff','_removeFromContext','mouseLeaveSuggestion','clearConversationContextUI','findIndex','activateTab','replyId','setAddContextOptions','ai-chat-resource-load-failed','sourcePosition','interactionCreated','ai-chat-url-upload-failed','ai-chat-context-form-data-size-limits-exceeded','indexOf','ai-chat-controller-no-active-conversation','editing','resizeTabs','toolDataReceived','uid','modelSelected','sourceId','AIChatUI','_integrateEditor','isPremiumPlugin','DocumentCompare','modification','addCurrentDocumentToContext','AI_CHAT_UNTITLED_CONVERSATION','document','getContentParts','bind','updateCapabilities','setSelectedModel','AI_CHAT_CONTEXT_INVALID_DATA','addFeedInteractionHeader','removeFromContext','pending','interactionStarted','6567741RXLdPi','AI_CHAT_UNABLE_TO_START_CONVERSATION','ai-chat-invalid-request','AITabs','isLoading','root','_aiChatBalloonShowDiff','redo','aiChatBalloon','startsWith','path','addCurrentDocumentToChatContext','_updateRatings','resize','Disliked\x20response','toggleLoadingSkeleton','getDocumentContext','prepareLoadingMessage','createConversation','current-document','getTransformedByOperation','scrollFeedToSuggestion','removeSelectionFromChatContext','dislike','split','options','_applySuggestion','closeSourceResourceBalloon','isDocumentOperation','resetConversationTitle','focusPromptInput','getReply','rejectSuggestion','getFirstRange','createPositionAt','sessionId','_handleStartConversation','config','executeCustomItemCallback','toString','length','_aiConnector','updateCurrentDocumentInContext','39179LpckDf','_getDocumentRangeForReplyChanges','close','Showing\x20conversation\x20history...','getInteraction','node','hideFakeVisualSelection','chat','addFeedItemAISuggestion','setFeedItemRenderingStrategy','reasoningFinished','fetchConversations','ai-chat-conversation-init-failed','_setIsMaximized','children','_toggleWebSearch','addContextItem','changes','setIsUploadInProgress','addOperation','setChangeGroupState','callback','isUploadInProgress','764675TFNGET','AI_CHAT_CONTEXT_UNSUPPORTED_TYPE','updateFeedItemAIReplySources','stop','AI_CHAT_CONTEXT_UNSUPPORTED_FILE_TYPE','ai-chat-conversation-not-found','unshift','setModel','createdAt','has','ai-chat-context-invalid-data','streaming','updateResourceState','startAutoScroll','handleRemovedConversation','368lQtMse','ai.chat.context','content','10arFwSv','selectedModel','1430856vGaPLx','areActionsDisabled','AI_CHAT_CONTEXT_CURRENT_DOCUMENT','isInContext','ai-chat-missing-channel-id','resourceStateChanged','resetWebSearchState','sources','AIChatController','showFakeVisualSelection','_aiChatBalloon','createRange','replyChangeGroupStateUpdated','contextItems','query','ai-chat-context-unsupported-type','init','uploadProgressChanged','isModelAvailable','addFeedItemCustomElement','outdated','ai.chat.initialConversation','resetReasoningState','context','done','changeGroups','contextSent'];_0x1ed0=function(){return _0x4a7d63;};return _0x1ed0();}import{AIModels as _0x29f6a7}from'../aicore/model/aimodels.js';import{getEditorFromContext as _0x16921b}from'../aicore/utils/geteditorfromcontext.js';function _0x77c5(_0x17ebc6,_0x29d426){const _0x1ed03f=_0x1ed0();return _0x77c5=function(_0x77c569,_0x156738){_0x77c569=_0x77c569-0x1e9;let _0x2b55e8=_0x1ed03f[_0x77c569];return _0x2b55e8;},_0x77c5(_0x17ebc6,_0x29d426);}import{DocumentCompare as _0x15cd3d,DATA_ID_MODEL_ATTRIBUTE as _0x533f4e}from'ckeditor5-collaboration/src/collaboration-core.js';import{fixMarkerOperationOldRange as _0x289b77,getOperationsFromReply as _0x4f62e2}from'../aicore/utils/getoperationsfromreply.js';import{expandSelectionWithContext as _0x527f56,getMinimalSelection as _0x43ab2c}from'../aicore/utils/getsuggestionpartsfromreply.js';import{ModelRange as _0x55b05b,_DetachOperation as _0x151737}from'ckeditor5/src/engine.js';import{findOne as _0x1ac4c7,getAttribute as _0x529fa7,serialize as _0x2bf49a,Document as _0x4f64f6,findByAttribute as _0x564a3e}from'../aicore/utils/htmlparser.js';export class AIChatController extends _0x31d929{[_0x102c9d(0x241)];[_0x102c9d(0x371)];[_0x102c9d(0x29d)];[_0x102c9d(0x2af)];[_0x102c9d(0x21c)];[_0x102c9d(0x295)]=new Map();[_0x102c9d(0x244)]=null;[_0x102c9d(0x2e2)];static get[_0x102c9d(0x238)](){return[_0x14f9fd,_0x15cd3d];}static get[_0x102c9d(0x30b)](){const _0x2670c0=_0x102c9d;return _0x2670c0(0x21a);}static get[_0x102c9d(0x25e)](){return!0x0;}static get[_0x102c9d(0x339)](){return!0x0;}[_0x102c9d(0x222)](){const _0x266443=_0x102c9d;this[_0x266443(0x2e2)]=new _0xaa0105(this[_0x266443(0x229)][_0x266443(0x25c)]),this[_0x266443(0x2e2)][_0x266443(0x2c3)](),this[_0x266443(0x371)]=this[_0x266443(0x229)][_0x266443(0x253)][_0x266443(0x300)](_0x266443(0x2b8)),this[_0x266443(0x29d)]=this[_0x266443(0x229)][_0x266443(0x253)][_0x266443(0x300)](_0x266443(0x337)),this[_0x266443(0x241)]=this[_0x266443(0x229)][_0x266443(0x253)][_0x266443(0x300)](_0x266443(0x28d)),this[_0x266443(0x2af)]=new _0x29f6a7({'connector':this[_0x266443(0x371)],'config':this[_0x266443(0x229)][_0x266443(0x36d)][_0x266443(0x300)](_0x266443(0x302)),'locale':this[_0x266443(0x229)][_0x266443(0x25c)]});const _0xa481b7=this[_0x266443(0x229)][_0x266443(0x253)][_0x266443(0x300)](_0x266443(0x34b));this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x2d7),()=>{const _0x3900f0=_0x266443;this[_0x3900f0(0x22f)]();}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x284),(_0x1d8799,_0x193916)=>{const _0x36d60e=_0x266443;this[_0x36d60e(0x254)]({'userMessage':_0x193916});}),this[_0x266443(0x23f)](_0xa481b7,_0x266443(0x2ac),(_0x3be252,_0x70c09e)=>{const _0x2310ac=_0x266443;this[_0x2310ac(0x1f4)](_0x70c09e);}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x332),()=>{const _0x4f73f6=_0x266443;_0xa481b7[_0x4f73f6(0x355)]();}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x2c2),async()=>{const _0x44fbcb=_0x266443;await this[_0x44fbcb(0x27e)](),await this[_0x44fbcb(0x28c)](),this[_0x44fbcb(0x35e)]();}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x25f),()=>{const _0x4b6757=_0x266443;this[_0x4b6757(0x353)]();}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x308),(_0x39b65b,_0x577531)=>{const _0x671f53=_0x266443;this[_0x671f53(0x2fb)]?.[_0x671f53(0x2c6)](Array[_0x671f53(0x232)](_0x577531));}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x279),(_0x123109,_0x109f46)=>{const _0x5ef306=_0x266443;this[_0x5ef306(0x2fb)]?.[_0x5ef306(0x279)](_0x109f46);}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x36e),(_0x505634,_0x17e818)=>{const _0x3921b6=_0x266443;_0x17e818[_0x3921b6(0x1fc)](this[_0x3921b6(0x229)]);}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x27f),(_0x1f9401,_0x17b779)=>{const _0x5be2c9=_0x266443;this[_0x5be2c9(0x2fb)]?.[_0x5be2c9(0x27f)](_0x17b779[_0x5be2c9(0x2fc)],_0x17b779[_0x5be2c9(0x247)]);}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x2fd),(_0x1ba95a,_0x310859)=>{const _0x5386fe=_0x266443;this[_0x5386fe(0x323)](_0x310859);}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x2a6),(_0x4e7282,_0x115dcd)=>{const _0x590df9=_0x266443;this[_0x590df9(0x2fb)]?.[_0x590df9(0x2a6)](_0x115dcd[_0x590df9(0x336)],_0x115dcd[_0x590df9(0x220)],_0x115dcd[_0x590df9(0x334)]);}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x2d1),()=>{const _0x1c4c0b=_0x266443;this[_0x1c4c0b(0x1f6)]();}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x286),()=>{const _0x530e11=_0x266443;this[_0x530e11(0x2a7)]();}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x2d8),(_0x181d11,_0x2b811c)=>{const _0x547373=_0x266443;this[_0x547373(0x2fb)]?.[_0x547373(0x205)](_0x2b811c);}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x265),(_0xc1e828,{replyId:_0x2af49f})=>{const _0x57c422=_0x266443;console[_0x57c422(0x270)](_0x57c422(0x2d2),_0x2af49f);}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x35f),(_0x5ab0fd,{replyId:_0x54040b})=>{const _0x41163c=_0x266443;console[_0x41163c(0x270)](_0x41163c(0x356),_0x54040b);}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x23c),(_0x4188d4,_0x36376c)=>{const _0xeaaf3c=_0x266443;this[_0xeaaf3c(0x287)](_0x36376c);}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x2e0),(_0x1c89eb,{replyId:_0x3fd2cc,partIndex:_0xddbe9b})=>{const _0x10e16d=_0x266443;this[_0x10e16d(0x34e)]=this[_0x10e16d(0x29d)][_0x10e16d(0x272)],this[_0x10e16d(0x288)](_0x3fd2cc,_0xddbe9b);}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x269),(_0xd27cbe,{replyId:_0x34597f,partIndex:_0x342b6b})=>{const _0x139d05=_0x266443,_0x12aa5d=this[_0x139d05(0x374)](_0x34597f,_0x342b6b);_0x12aa5d&&_0x139d05(0x306)!=_0x12aa5d[_0x139d05(0x290)][_0x139d05(0x34d)][_0x139d05(0x289)]&&this[_0x139d05(0x241)][_0x139d05(0x21b)]([_0x12aa5d[_0x139d05(0x290)]],_0x139d05(0x2a1));}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x324),()=>{const _0x4b407e=_0x266443;this[_0x4b407e(0x241)][_0x4b407e(0x1ed)](_0x4b407e(0x2a1));}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x280),(_0x5c7007,_0x3854db)=>{const _0x59b47b=_0x266443;this[_0x59b47b(0x241)][_0x59b47b(0x1ed)](_0x59b47b(0x2a1)),this[_0x59b47b(0x362)](_0x3854db);}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x246),async(_0x257ca4,{replyId:_0x89546,showDiff:_0x5b5f99})=>{const _0x55234a=_0x266443,{reply:_0x2ac6b3}=this[_0x55234a(0x24b)](_0x89546),_0x20ee1f=_0x2ac6b3[_0x55234a(0x33f)]({'showDiff':_0x5b5f99});await this[_0x55234a(0x29d)][_0x55234a(0x2db)]({'id':_0x2ac6b3['id'],'parts':_0x20ee1f,'renderingStrategy':_0x55234a(0x2ea)});}),this[_0x266443(0x23f)](this[_0x266443(0x29d)],_0x266443(0x368),(_0x17d2bb,{replyId:_0x1acc64,partIndex:_0xd67d05})=>{const _0x205c4a=_0x266443;this[_0x205c4a(0x2ae)]({'replyId':_0x1acc64,'partIndex':_0xd67d05}),this[_0x205c4a(0x241)][_0x205c4a(0x1ed)](_0x205c4a(0x2a1));}),this[_0x266443(0x229)][_0x266443(0x253)][_0x266443(0x207)](_0x266443(0x26d))&&(this[_0x266443(0x21c)]=this[_0x266443(0x229)][_0x266443(0x253)][_0x266443(0x300)](_0x266443(0x26d)),this[_0x266443(0x282)](_0x266443(0x34e),!0x1),this[_0x266443(0x21c)][_0x266443(0x340)](_0x266443(0x272))['to'](this,_0x266443(0x34e)),this[_0x266443(0x23f)](this[_0x266443(0x21c)],_0x266443(0x246),()=>{const _0x443925=_0x266443,{replyId:_0x5019b3,partIndex:_0x2f768a}=this[_0x443925(0x244)];this[_0x443925(0x34e)]=!this[_0x443925(0x34e)];const {reply:_0xfc40f1}=this[_0x443925(0x24b)](_0x5019b3),_0x1b0482=_0xfc40f1[_0x443925(0x33f)]({'showDiff':this[_0x443925(0x34e)],'groupIndex':_0x2f768a});this[_0x443925(0x21c)][_0x443925(0x2f0)]({'part':_0x1b0482[0x0],'renderingStrategy':_0x443925(0x2ea),'keepErrors':!0x0});}),this[_0x266443(0x23f)](this[_0x266443(0x21c)],_0x266443(0x280),()=>{const _0x5b35a7=_0x266443,{replyId:_0x5375bf,partIndex:_0x1f45c3}=this[_0x5b35a7(0x244)];this[_0x5b35a7(0x362)]({'replyId':_0x5375bf,'partIndex':_0x1f45c3}),this[_0x5b35a7(0x21c)][_0x5b35a7(0x2f5)](_0x5b35a7(0x2f3));}),this[_0x266443(0x23f)](this[_0x266443(0x21c)],_0x266443(0x23c),()=>{const _0x12ba62=_0x266443,{replyId:_0x48753e,partIndex:_0x4940ca}=this[_0x12ba62(0x244)];this[_0x12ba62(0x287)]({'replyId':_0x48753e,'partIndex':_0x4940ca}),this[_0x12ba62(0x21c)][_0x12ba62(0x2f5)](_0x12ba62(0x2f3));}),this[_0x266443(0x23f)](this[_0x266443(0x21c)],_0x266443(0x368),()=>{const _0x2148dc=_0x266443,{replyId:_0x37854b,partIndex:_0x1ba292}=this[_0x2148dc(0x244)];this[_0x2148dc(0x2ae)]({'replyId':_0x37854b,'partIndex':_0x1ba292}),this[_0x2148dc(0x21c)][_0x2148dc(0x2f5)](_0x2148dc(0x249));}),this[_0x266443(0x23f)](this[_0x266443(0x21c)],_0x266443(0x2a0),()=>{const _0x40f96c=_0x266443,{replyId:_0x5b9d3d,partIndex:_0x2a157e}=this[_0x40f96c(0x244)],_0x4d0b50=this[_0x40f96c(0x2f2)](_0x5b9d3d,_0x2a157e,_0x40f96c(0x307));null!==_0x4d0b50&&this[_0x40f96c(0x288)](_0x5b9d3d,_0x4d0b50);}),this[_0x266443(0x23f)](this[_0x266443(0x21c)],_0x266443(0x301),()=>{const _0xa8f27c=_0x266443,{replyId:_0x2d8633,partIndex:_0x299c45}=this[_0xa8f27c(0x244)],_0x457d42=this[_0xa8f27c(0x2f2)](_0x2d8633,_0x299c45,_0xa8f27c(0x28a));null!==_0x457d42&&this[_0xa8f27c(0x288)](_0x2d8633,_0x457d42);}),this[_0x266443(0x23f)](this[_0x266443(0x21c)],_0x266443(0x235),(_0x3adf3c,{id:_0x4dc695})=>{const _0x52089d=_0x266443;if(_0x52089d(0x350)!==_0x4dc695)return;const {replyId:_0x2d824c,partIndex:_0x58c491}=this[_0x52089d(0x244)];this[_0x52089d(0x244)]=null,this[_0x52089d(0x29d)][_0x52089d(0x237)]({'id':_0x2d824c,'index':_0x58c491,'isActive':!0x1});}));}async[_0x102c9d(0x283)](){const _0x5eddca=_0x102c9d;this[_0x5eddca(0x229)]instanceof _0xb49bf1?this[_0x5eddca(0x338)](this[_0x5eddca(0x229)]):this[_0x5eddca(0x23f)](this[_0x5eddca(0x229)][_0x5eddca(0x260)],_0x5eddca(0x31d),(_0x21c47d,_0x602ba3)=>{const _0x2048ba=_0x5eddca;_0x602ba3['on'](_0x2048ba(0x304),()=>{const _0x23cf9d=_0x2048ba;this[_0x23cf9d(0x338)](_0x602ba3);});});const _0xb218a=this[_0x5eddca(0x229)][_0x5eddca(0x36d)][_0x5eddca(0x300)](_0x5eddca(0x227));let _0x2832b2=_0xb218a;if(_0x5eddca(0x276)!=_0xb218a||(_0x2832b2=await this[_0x5eddca(0x2c9)](),_0x2832b2))return _0x5eddca(0x314)==_0x2832b2?this[_0x5eddca(0x22f)]():this[_0x5eddca(0x266)](_0x2832b2);}async[_0x102c9d(0x299)](){const _0x1c8e48=_0x102c9d;return await this[_0x1c8e48(0x27e)](),this[_0x1c8e48(0x2e2)][_0x1c8e48(0x26c)](),super[_0x1c8e48(0x299)]();}[_0x102c9d(0x287)](_0x12a340){const _0x2212a4=_0x102c9d,_0x5e924b=_0x16921b(this[_0x2212a4(0x229)]);if(!_0x5e924b[_0x2212a4(0x253)][_0x2212a4(0x207)](_0x2212a4(0x296)))throw new _0x302247(_0x2212a4(0x2c5),null);const _0x37c998=this[_0x2212a4(0x229)][_0x2212a4(0x253)][_0x2212a4(0x300)](_0x2212a4(0x33a)),{reply:_0x207a76,interaction:_0x3799e8}=this[_0x2212a4(0x24b)](_0x12a340[_0x2212a4(0x328)]),_0x1f1eda=this[_0x2212a4(0x374)](_0x12a340[_0x2212a4(0x328)],_0x12a340[_0x2212a4(0x29a)]),_0x1089ff=void 0x0!==_0x12a340[_0x2212a4(0x29a)]?[_0x207a76[_0x2212a4(0x22b)][_0x12a340[_0x2212a4(0x29a)]]]:_0x207a76[_0x2212a4(0x22b)][_0x2212a4(0x2e9)](_0x541eca=>_0x2212a4(0x346)==_0x541eca[_0x2212a4(0x2a3)]),_0x38557d=_0x1089ff[_0x2212a4(0x2d9)](_0x1f3e15=>_0x207a76[_0x2212a4(0x22b)][_0x2212a4(0x32f)](_0x1f3e15));if(!_0x1f1eda||_0x2212a4(0x306)==_0x1f1eda[_0x2212a4(0x290)][_0x2212a4(0x34d)][_0x2212a4(0x289)])return void _0x38557d[_0x2212a4(0x27c)](_0x294b24=>_0x207a76[_0x2212a4(0x1fb)](_0x294b24,_0x2212a4(0x226)));_0x38557d[_0x2212a4(0x27c)](_0x2b5fde=>_0x207a76[_0x2212a4(0x1fb)](_0x2b5fde,_0x2212a4(0x2f3)));const _0x3d76bf=_0x4f62e2({'editor':_0x5e924b,'reply':_0x207a76,'interaction':_0x3799e8,'groups':_0x1089ff,'transform':!0x0,'documentCompare':_0x37c998,'documentCompareOptions':{'anchor':_0x2212a4(0x2a9),'markDeletions':!0x0}});let _0x3d4356;_0x1f1eda&&this[_0x2212a4(0x309)](_0x1f1eda[_0x2212a4(0x290)]),_0x5e924b[_0x2212a4(0x2aa)][_0x2212a4(0x31f)](_0x9784bb=>{const _0xf20a59=_0x2212a4;_0x3d4356=_0x9784bb[_0xf20a59(0x2e5)],_0x5e924b[_0xf20a59(0x253)][_0xf20a59(0x300)](_0xf20a59(0x24a))[_0xf20a59(0x278)](_0x3d76bf),this[_0xf20a59(0x241)][_0xf20a59(0x1ed)](_0xf20a59(0x2a1));}),this[_0x2212a4(0x295)][_0x2212a4(0x282)](_0x3d4356,{'interactionId':_0x3799e8['id'],'replyId':_0x207a76['id'],'indexes':_0x38557d[_0x2212a4(0x2e6)]()}),this[_0x2212a4(0x354)](_0x207a76);}[_0x102c9d(0x362)](_0x45abd6){const _0x32fe27=_0x102c9d,_0x123d57=_0x16921b(this[_0x32fe27(0x229)]),_0x157245=this[_0x32fe27(0x229)][_0x32fe27(0x253)][_0x32fe27(0x300)](_0x15cd3d),{reply:_0x363053,interaction:_0x30c16d}=this[_0x32fe27(0x24b)](_0x45abd6[_0x32fe27(0x328)]),_0x118fd8=this[_0x32fe27(0x374)](_0x45abd6[_0x32fe27(0x328)],_0x45abd6[_0x32fe27(0x29a)]),_0x2c4e55=void 0x0!==_0x45abd6[_0x32fe27(0x29a)]?[_0x363053[_0x32fe27(0x22b)][_0x45abd6[_0x32fe27(0x29a)]]]:_0x363053[_0x32fe27(0x22b)][_0x32fe27(0x2e9)](_0xaa2e94=>_0x32fe27(0x346)==_0xaa2e94[_0x32fe27(0x2a3)]),_0x1128c9=_0x2c4e55[_0x32fe27(0x2d9)](_0x4b7db0=>_0x363053[_0x32fe27(0x22b)][_0x32fe27(0x32f)](_0x4b7db0));if(!_0x118fd8||_0x32fe27(0x306)==_0x118fd8[_0x32fe27(0x290)][_0x32fe27(0x34d)][_0x32fe27(0x289)])return void _0x1128c9[_0x32fe27(0x27c)](_0x398511=>_0x363053[_0x32fe27(0x1fb)](_0x398511,_0x32fe27(0x226)));_0x1128c9[_0x32fe27(0x27c)](_0x54d16c=>_0x363053[_0x32fe27(0x1fb)](_0x54d16c,_0x32fe27(0x2f3)));const _0x54fb69=_0x4f62e2({'editor':_0x123d57,'reply':_0x363053,'interaction':_0x30c16d,'groups':_0x2c4e55,'transform':!0x0,'documentCompare':_0x157245,'documentCompareOptions':{'anchor':_0x32fe27(0x2a9),'markDeletions':!0x1}});let _0x3670fb;_0x118fd8&&this[_0x32fe27(0x309)](_0x118fd8[_0x32fe27(0x290)]),_0x123d57[_0x32fe27(0x2aa)][_0x32fe27(0x31f)](_0x1382d7=>{const _0x21f7bb=_0x32fe27;_0x3670fb=_0x1382d7[_0x21f7bb(0x2e5)];for(const _0x238fc8 of _0x54fb69)_0x238fc8[_0x21f7bb(0x2bc)]=_0x123d57[_0x21f7bb(0x2aa)][_0x21f7bb(0x33e)][_0x21f7bb(0x257)],_0x289b77(_0x123d57,_0x238fc8),_0x1382d7[_0x21f7bb(0x2e5)][_0x21f7bb(0x1fa)](_0x238fc8),_0x123d57[_0x21f7bb(0x2aa)][_0x21f7bb(0x2ff)](_0x238fc8);}),this[_0x32fe27(0x295)][_0x32fe27(0x282)](_0x3670fb,{'interactionId':_0x30c16d['id'],'replyId':_0x363053['id'],'indexes':_0x1128c9[_0x32fe27(0x2e6)]()}),this[_0x32fe27(0x354)](_0x363053);}[_0x102c9d(0x2ae)](_0x578d5b){const _0x598b4c=_0x102c9d,{reply:_0x1fc87d}=this[_0x598b4c(0x24b)](_0x578d5b[_0x598b4c(0x328)]);_0x1fc87d[_0x598b4c(0x1fb)](_0x578d5b[_0x598b4c(0x29a)],_0x598b4c(0x249));}[_0x102c9d(0x288)](_0x32f50c,_0x3db501){const _0x3befbf=_0x102c9d;if(!this[_0x3befbf(0x21c)])return;const {reply:_0x2f1c07}=this[_0x3befbf(0x24b)](_0x32f50c),_0xce11cf=_0x2f1c07[_0x3befbf(0x33f)]({'showDiff':this[_0x3befbf(0x34e)]});let _0x3e3a4b,_0x573451;if(void 0x0!==_0x3db501?(_0x573451=_0xce11cf[_0x3befbf(0x317)](_0x32406c=>_0x32406c[_0x3befbf(0x243)]==_0x3db501),_0x3e3a4b=_0x573451?.[_0x3befbf(0x243)]):(_0x573451=_0xce11cf[0x0],_0x3e3a4b=_0x573451[_0x3befbf(0x243)]),this[_0x3befbf(0x244)]?.[_0x3befbf(0x328)]==_0x32f50c&&this[_0x3befbf(0x244)]?.[_0x3befbf(0x29a)]==_0x3e3a4b)return;const _0x5201c3=this[_0x3befbf(0x292)](_0x32f50c,_0x2f1c07,_0x573451);if(!_0x5201c3)return void this[_0x3befbf(0x21c)][_0x3befbf(0x1e9)]();this[_0x3befbf(0x244)]={'replyId':_0x32f50c,'partIndex':_0x3e3a4b},this[_0x3befbf(0x309)](_0x5201c3,!0x0);const _0x2b381d=this[_0x3befbf(0x2f2)](_0x32f50c,_0x3e3a4b,_0x3befbf(0x307));this[_0x3befbf(0x21c)][_0x3befbf(0x2f0)]({'part':_0x573451,'renderingStrategy':_0x3befbf(0x2ea)}),this[_0x3befbf(0x21c)][_0x3befbf(0x2dd)]({'index':_0x3e3a4b,'title':_0x394fc2(this[_0x3befbf(0x229)][_0x3befbf(0x25c)],_0x3befbf(0x2b0),(_0x3e3a4b+0x1)[_0x3befbf(0x36f)]()),'showRotator':null!==_0x2b381d,'ranges':[_0x5201c3],'areActionsDisabled':_0x2f1c07[_0x3befbf(0x213)]}),this[_0x3befbf(0x21c)][_0x3befbf(0x2f5)](_0x3befbf(0x346)),this[_0x3befbf(0x29d)][_0x3befbf(0x35d)](_0x32f50c,_0x3e3a4b),this[_0x3befbf(0x29d)][_0x3befbf(0x237)]({'id':_0x32f50c,'index':_0x3e3a4b,'isActive':!0x0});}[_0x102c9d(0x2f2)](_0x2c213d,_0x17df30,_0x2e9fa5){const _0x4dc3f7=_0x102c9d,{reply:_0x44af38}=this[_0x4dc3f7(0x24b)](_0x2c213d),_0x33f9f7=_0x44af38[_0x4dc3f7(0x33f)]({'showDiff':this[_0x4dc3f7(0x34e)]});if(0x1==_0x33f9f7[_0x4dc3f7(0x370)])return null;const _0x49d9d2=_0x33f9f7[_0x4dc3f7(0x326)](_0x268c51=>_0x268c51[_0x4dc3f7(0x243)]==_0x17df30),_0x7b4800=_0x4dc3f7(0x307)==_0x2e9fa5?0x1:-0x1;let _0xedfae3=_0x33f9f7['at']((_0x49d9d2+_0x7b4800)%_0x33f9f7[_0x4dc3f7(0x370)])[_0x4dc3f7(0x243)],_0x5eebe5=_0x33f9f7[_0xedfae3];for(;!this[_0x4dc3f7(0x292)](_0x2c213d,_0x44af38,_0x5eebe5);){if(_0xedfae3=_0x33f9f7['at']((_0xedfae3+_0x7b4800)%_0x33f9f7[_0x4dc3f7(0x370)])[_0x4dc3f7(0x243)],_0xedfae3===_0x49d9d2)return null;_0x5eebe5=_0x33f9f7[_0xedfae3];}return _0xedfae3;}[_0x102c9d(0x292)](_0x5c084e,_0x544811,_0x32c8d6){const _0x2aa94c=_0x102c9d,_0x5a420c=_0x544811[_0x2aa94c(0x22b)];if(!_0x32c8d6[_0x2aa94c(0x2e3)])return null;const _0x2165a5=_0x5a420c[_0x2aa94c(0x317)](_0x1583f6=>_0x1583f6[_0x2aa94c(0x243)]==_0x32c8d6[_0x2aa94c(0x243)]);if(_0x2aa94c(0x346)!==_0x2165a5?.[_0x2aa94c(0x2a3)])return null;const _0x2fb53a=this[_0x2aa94c(0x374)](_0x5c084e,_0x32c8d6[_0x2aa94c(0x243)]);if(!_0x2fb53a)return null;const {range:_0x58f85f,currentIndex:_0x1a17fa}=_0x2fb53a;return _0x2aa94c(0x306)==_0x58f85f[_0x2aa94c(0x34d)][_0x2aa94c(0x289)]?(_0x544811[_0x2aa94c(0x1fb)](_0x1a17fa,_0x2aa94c(0x226)),null):_0x2fb53a[_0x2aa94c(0x290)];}[_0x102c9d(0x374)](_0x210b93,_0x4c3f75){const _0x34c68f=_0x102c9d,_0x10d4c6=_0x16921b(this[_0x34c68f(0x229)]),{reply:_0x441411,interaction:_0x8802be}=this[_0x34c68f(0x24b)](_0x210b93),_0x3f4c02=_0x441411[_0x34c68f(0x22b)][_0x34c68f(0x2e9)](_0x3f4d36=>_0x34c68f(0x346)==_0x3f4d36[_0x34c68f(0x2a3)]),_0x5db061=_0x3f4c02[_0x34c68f(0x2d9)](_0x22b1d7=>_0x441411[_0x34c68f(0x22b)][_0x34c68f(0x32f)](_0x22b1d7));void 0x0===_0x4c3f75&&(_0x4c3f75=_0x5db061[0x0]);const _0x516d01=_0x5db061[_0x34c68f(0x32f)](_0x4c3f75);if(-0x1==_0x516d01)return null;const _0x585bd8=_0x3f4c02[_0x516d01],_0x42934e=new _0x4f64f6([]),_0x574831=new _0x4f64f6([]);for(const _0x47ad3b of _0x585bd8[_0x34c68f(0x1f8)])if(_0x34c68f(0x22e)!=_0x47ad3b[_0x34c68f(0x310)]&&_0x574831[_0x34c68f(0x1f5)][_0x34c68f(0x29b)](_0x47ad3b[_0x34c68f(0x1ec)][_0x34c68f(0x2b1)](!0x0)),_0x34c68f(0x314)!=_0x47ad3b[_0x34c68f(0x310)]){const _0x2d7b60=_0x1ac4c7(_0x2a9007=>_0x529fa7(_0x2a9007,_0x34c68f(0x2b5))==_0x47ad3b['id'],_0x441411[_0x34c68f(0x31c)],!0x0);_0x42934e[_0x34c68f(0x1f5)][_0x34c68f(0x29b)](_0x2d7b60[_0x34c68f(0x2b1)](!0x0));}if(0x0==_0x42934e[_0x34c68f(0x1f5)][_0x34c68f(0x370)]){if(_0x585bd8[_0x34c68f(0x1f8)][0x0][_0x34c68f(0x2ee)]){const _0x4038d4=_0x564a3e(_0x34c68f(0x2b5),_0x585bd8[_0x34c68f(0x1f8)][0x0][_0x34c68f(0x2ee)],_0x441411[_0x34c68f(0x31c)]);_0x42934e[_0x34c68f(0x1f5)][_0x34c68f(0x204)](_0x4038d4[_0x34c68f(0x2b1)](!0x0)),_0x574831[_0x34c68f(0x1f5)][_0x34c68f(0x204)](_0x4038d4[_0x34c68f(0x2b1)](!0x0)),_0x4038d4[_0x34c68f(0x29f)]&&(_0x42934e[_0x34c68f(0x1f5)][_0x34c68f(0x29b)](_0x4038d4[_0x34c68f(0x29f)][_0x34c68f(0x2b1)](!0x0)),_0x574831[_0x34c68f(0x1f5)][_0x34c68f(0x29b)](_0x4038d4[_0x34c68f(0x29f)][_0x34c68f(0x2b1)](!0x0)));}else{const _0x179c54=_0x441411[_0x34c68f(0x31c)][_0x34c68f(0x1f5)][0x0];if(!_0x179c54)return null;_0x42934e[_0x34c68f(0x1f5)][_0x34c68f(0x29b)](_0x179c54[_0x34c68f(0x2b1)](!0x0)),_0x574831[_0x34c68f(0x1f5)][_0x34c68f(0x29b)](_0x179c54[_0x34c68f(0x2b1)](!0x0));}}const _0x35ad26=_0x8802be[_0x34c68f(0x358)](),_0x233b67=_0x10d4c6[_0x34c68f(0x233)][_0x34c68f(0x23a)](_0x35ad26[_0x34c68f(0x20f)]),_0x3715a2=_0x2bf49a(_0x42934e),_0x9f69c8=_0x10d4c6[_0x34c68f(0x233)][_0x34c68f(0x23a)](_0x3715a2),_0x1491b1=_0x10d4c6[_0x34c68f(0x233)][_0x34c68f(0x23a)](_0x3715a2),_0x4b700c=_0x10d4c6[_0x34c68f(0x2aa)][_0x34c68f(0x36a)](_0x9f69c8,0x0),_0x33e8f2=_0x2bf49a(_0x574831),_0xe5409d={'anchor':_0x4b700c,'markDeletions':!0x1},_0x104a3b=_0x10d4c6[_0x34c68f(0x253)][_0x34c68f(0x300)](_0x15cd3d)[_0x34c68f(0x322)](_0x3715a2,_0x33e8f2,_0xe5409d)[_0x34c68f(0x236)]();if(!_0x104a3b[_0x34c68f(0x370)])return null;_0x10d4c6[_0x34c68f(0x2aa)][_0x34c68f(0x31f)](_0x5c11c2=>{const _0x950e51=_0x34c68f;for(const _0x2d4b46 of _0x104a3b)if(_0x950e51(0x311)==_0x2d4b46[_0x950e51(0x310)]){const _0x57f395=_0x2d4b46[_0x950e51(0x32b)],_0x4bba9c=_0x2d4b46[_0x950e51(0x255)],_0x187253=new _0x151737(_0x57f395,_0x4bba9c);_0x5c11c2[_0x950e51(0x2e5)][_0x950e51(0x1fa)](_0x187253),_0x10d4c6[_0x950e51(0x2aa)][_0x950e51(0x2ff)](_0x187253);}else _0x950e51(0x320)!==_0x2d4b46[_0x950e51(0x310)]&&(_0x2d4b46[_0x950e51(0x2bc)]=null,_0x2d4b46[_0x950e51(0x364)]=!0x1,_0x5c11c2[_0x950e51(0x2e5)][_0x950e51(0x1fa)](_0x2d4b46),_0x10d4c6[_0x950e51(0x2aa)][_0x950e51(0x2ff)](_0x2d4b46));});const _0x84bb3=_0x43ab2c(_0x10d4c6,_0x104a3b,_0x9f69c8);_0x527f56(_0x10d4c6[_0x34c68f(0x2aa)],_0x84bb3);const _0x2f2be0=_0x84bb3[_0x34c68f(0x369)]()[_0x34c68f(0x2b2)][_0x34c68f(0x352)][_0x34c68f(0x2e6)](),_0x87ce3e=_0x84bb3[_0x34c68f(0x369)]()[_0x34c68f(0x2a2)][_0x34c68f(0x352)][_0x34c68f(0x2e6)](),_0x420df2=[];let _0x1d7023=_0x9f69c8,_0x19c669=_0x1491b1;for(let _0x16baa6=0x0;_0x16baa6<_0x87ce3e[_0x34c68f(0x370)];_0x16baa6++){const _0x40339d=_0x1d7023[_0x34c68f(0x271)]-_0x87ce3e[_0x16baa6];_0x420df2[_0x16baa6]=_0x19c669[_0x34c68f(0x271)]-_0x40339d,_0x1d7023=_0x1d7023[_0x34c68f(0x2c0)](_0x87ce3e[_0x16baa6]),_0x19c669=_0x19c669[_0x34c68f(0x2c0)](_0x420df2[_0x16baa6]);}const _0x31080b=_0x10d4c6[_0x34c68f(0x2aa)][_0x34c68f(0x21d)](_0x10d4c6[_0x34c68f(0x2aa)][_0x34c68f(0x239)](_0x1491b1,_0x2f2be0),_0x10d4c6[_0x34c68f(0x2aa)][_0x34c68f(0x239)](_0x1491b1,_0x420df2)),_0x2fa0a4=_0x1491b1[_0x34c68f(0x294)](0x0)[_0x34c68f(0x297)](_0x533f4e),_0x40b5f4=Array[_0x34c68f(0x232)](_0x233b67[_0x34c68f(0x240)]())[_0x34c68f(0x317)](_0x4a357b=>_0x4a357b[_0x34c68f(0x297)](_0x533f4e)==_0x2fa0a4)[_0x34c68f(0x2e1)](),_0xc8e5a3=_0x31080b[_0x34c68f(0x2b2)][_0x34c68f(0x352)][_0x34c68f(0x2e6)](),_0x39e94=_0x31080b[_0x34c68f(0x2a2)][_0x34c68f(0x352)][_0x34c68f(0x2e6)]();_0xc8e5a3[0x0]=_0x40b5f4[0x0]+_0xc8e5a3[0x0],_0x39e94[0x0]=_0x40b5f4[0x0]+_0x39e94[0x0];let _0x1fee57=_0x10d4c6[_0x34c68f(0x2aa)][_0x34c68f(0x21d)](_0x10d4c6[_0x34c68f(0x2aa)][_0x34c68f(0x239)](_0x10d4c6[_0x34c68f(0x2aa)][_0x34c68f(0x33e)][_0x34c68f(0x262)](),_0xc8e5a3),_0x10d4c6[_0x34c68f(0x2aa)][_0x34c68f(0x239)](_0x10d4c6[_0x34c68f(0x2aa)][_0x34c68f(0x33e)][_0x34c68f(0x262)](),_0x39e94));const _0x1c4fab=_0x10d4c6[_0x34c68f(0x2aa)][_0x34c68f(0x33e)][_0x34c68f(0x2b7)][_0x34c68f(0x236)](_0x35ad26[_0x34c68f(0x257)]);for(const _0x12a85a of _0x1c4fab)_0x1fee57=_0x55b05b[_0x34c68f(0x252)](_0x1fee57[_0x34c68f(0x35c)](_0x12a85a));return{'range':_0x1fee57,'currentIndex':_0x4c3f75};}[_0x102c9d(0x338)](_0x4b0798){const _0x44c9be=_0x102c9d;if(!_0x4b0798[_0x44c9be(0x253)][_0x44c9be(0x207)](_0x44c9be(0x2ed)))return;const _0x25d6bb=_0x4b0798[_0x44c9be(0x242)][_0x44c9be(0x300)](_0x44c9be(0x25d)),_0x46716e=_0x4b0798[_0x44c9be(0x242)][_0x44c9be(0x300)](_0x44c9be(0x34f));this[_0x44c9be(0x23f)](_0x25d6bb,_0x44c9be(0x256),(_0x25771f,_0x12a693,_0x47c597)=>{const _0xa14773=_0x44c9be,_0x2b1c87=this[_0xa14773(0x295)][_0xa14773(0x300)](_0x12a693);if(!_0x2b1c87)return;const _0x3f4007=this[_0xa14773(0x2fb)][_0xa14773(0x1eb)](_0x2b1c87[_0xa14773(0x31e)])[_0xa14773(0x367)](_0x2b1c87[_0xa14773(0x328)]);_0x2b1c87[_0xa14773(0x31b)][_0xa14773(0x27c)](_0x1c7c9b=>_0x3f4007[_0xa14773(0x1fb)](_0x1c7c9b,_0xa14773(0x346))),this[_0xa14773(0x295)][_0xa14773(0x30c)](_0x12a693),this[_0xa14773(0x295)][_0xa14773(0x282)](_0x47c597,_0x2b1c87);}),this[_0x44c9be(0x23f)](_0x46716e,_0x44c9be(0x256),(_0x50dfac,_0x1fdc0c,_0x475ff3)=>{const _0x25cf92=_0x44c9be,_0x15e792=this[_0x25cf92(0x295)][_0x25cf92(0x300)](_0x1fdc0c);if(!_0x15e792)return;const _0x2c62d3=this[_0x25cf92(0x2fb)][_0x25cf92(0x1eb)](_0x15e792[_0x25cf92(0x31e)])[_0x25cf92(0x367)](_0x15e792[_0x25cf92(0x328)]);_0x15e792[_0x25cf92(0x31b)][_0x25cf92(0x27c)](_0x3313f1=>_0x2c62d3[_0x25cf92(0x1fb)](_0x3313f1,_0x25cf92(0x2f3))),this[_0x25cf92(0x295)][_0x25cf92(0x30c)](_0x1fdc0c),this[_0x25cf92(0x295)][_0x25cf92(0x282)](_0x475ff3,_0x15e792);});}async[_0x102c9d(0x266)](_0x228875){const _0x503fbb=_0x102c9d;this[_0x503fbb(0x229)][_0x503fbb(0x253)][_0x503fbb(0x207)](_0x503fbb(0x26d))&&this[_0x503fbb(0x229)][_0x503fbb(0x253)][_0x503fbb(0x300)](_0x503fbb(0x26d))[_0x503fbb(0x1e9)](),(this[_0x503fbb(0x229)][_0x503fbb(0x253)][_0x503fbb(0x300)](_0x367c5c)[_0x503fbb(0x261)][_0x503fbb(0x327)](_0x503fbb(0x1ee)),this[_0x503fbb(0x29d)][_0x503fbb(0x1f0)](_0x503fbb(0x2ea)),this[_0x503fbb(0x29d)][_0x503fbb(0x357)](!0x0),await this[_0x503fbb(0x27e)]());try{await this[_0x503fbb(0x371)][_0x503fbb(0x2e4)](_0x228875)[_0x503fbb(0x2cf)](),await this[_0x503fbb(0x22f)](_0x228875),this[_0x503fbb(0x2f9)]('\x20'),await this[_0x503fbb(0x2fb)][_0x503fbb(0x24d)](_0x228875,this[_0x503fbb(0x241)][_0x503fbb(0x36b)]),this[_0x503fbb(0x2fb)][_0x503fbb(0x305)]()&&this[_0x503fbb(0x353)]();}catch(_0x3453e3){this[_0x503fbb(0x29d)][_0x503fbb(0x293)]({'errorMessage':_0x394fc2(this[_0x503fbb(0x229)][_0x503fbb(0x25c)],_0x503fbb(0x25b)),'id':_0x228875}),this[_0x503fbb(0x2f4)](new _0x302247(_0x503fbb(0x203),this,{'error':_0x3453e3}));}finally{this[_0x503fbb(0x29d)][_0x503fbb(0x20b)](),this[_0x503fbb(0x29d)][_0x503fbb(0x1f0)](_0x503fbb(0x209)),this[_0x503fbb(0x29d)][_0x503fbb(0x357)](!0x1);}}async[_0x102c9d(0x2c9)](){const _0x2550f2=_0x102c9d,_0x3bc019=this[_0x2550f2(0x371)][_0x2550f2(0x1f2)](this[_0x2550f2(0x2b3)](),{'limit':0x1,'sortBy':_0x2550f2(0x206)});try{const _0x1ef9e1=await _0x3bc019[_0x2550f2(0x2d0)]();return _0x1ef9e1[_0x2550f2(0x370)]?_0x1ef9e1[0x0]['id']:_0x2550f2(0x314);}catch(_0x41989b){return this[_0x2550f2(0x29d)][_0x2550f2(0x293)]({'errorMessage':_0x394fc2(this[_0x2550f2(0x229)][_0x2550f2(0x25c)],_0x2550f2(0x25b)),'id':_0x31ba12()}),this[_0x2550f2(0x2f4)](new _0x302247(_0x2550f2(0x1f3),this,{'error':_0x41989b})),this[_0x2550f2(0x29d)][_0x2550f2(0x357)](!0x1),this[_0x2550f2(0x29d)][_0x2550f2(0x259)](),null;}}[_0x102c9d(0x20c)](_0x1c5e14){const _0x3a096a=_0x102c9d;this[_0x3a096a(0x2fb)]['id']===_0x1c5e14&&this[_0x3a096a(0x22f)]();}[_0x102c9d(0x353)](){const _0x1ce072=_0x102c9d;this[_0x1ce072(0x2fb)]?.[_0x1ce072(0x33c)](_0x394fc2(this[_0x1ce072(0x229)][_0x1ce072(0x25c)],_0x1ce072(0x214)));}async[_0x102c9d(0x28b)](){const _0x5a17ce=_0x102c9d,_0x92d97=this[_0x5a17ce(0x241)][_0x5a17ce(0x30d)]();this[_0x5a17ce(0x2fb)]?.[_0x5a17ce(0x2cc)](_0x92d97),this[_0x5a17ce(0x353)]();}[_0x102c9d(0x35e)](){const _0x4feda2=_0x102c9d;this[_0x4feda2(0x2fb)]?.[_0x4feda2(0x2f1)]();}[_0x102c9d(0x366)](){const _0x58a173=_0x102c9d;this[_0x58a173(0x29d)][_0x58a173(0x366)]();}async[_0x102c9d(0x2d7)](){const _0x4d6850=_0x102c9d;await this[_0x4d6850(0x22f)]();}async[_0x102c9d(0x24f)]({message:_0x296e01,attributes:_0x41b4b3}){const _0x59cb12=_0x102c9d;await this[_0x59cb12(0x254)]({'userMessage':_0x296e01,'attributes':_0x41b4b3});}[_0x102c9d(0x2b3)](){const _0x53a5c6=_0x102c9d,_0x2e55a2=this[_0x53a5c6(0x229)][_0x53a5c6(0x36d)][_0x53a5c6(0x300)](_0x53a5c6(0x22d));if(!_0x2e55a2)throw new _0x302247(_0x53a5c6(0x216),this);return _0x2e55a2;}async[_0x102c9d(0x22f)](_0x43706f){const _0x2eef2f=_0x102c9d;try{this[_0x2eef2f(0x29d)][_0x2eef2f(0x285)](),await this[_0x2eef2f(0x36c)](_0x43706f);}catch(_0x2be21e){this[_0x2eef2f(0x29d)][_0x2eef2f(0x293)]({'errorMessage':_0x394fc2(this[_0x2eef2f(0x229)][_0x2eef2f(0x25c)],_0x2eef2f(0x349)),'id':_0x43706f||_0x31ba12()}),console[_0x2eef2f(0x281)](_0x2be21e),this[_0x2eef2f(0x2fb)]=void 0x0,this[_0x2eef2f(0x29d)][_0x2eef2f(0x259)]();}}async[_0x102c9d(0x36c)](_0x480a55){const _0x233588=_0x102c9d;let _0x1199ad;this[_0x233588(0x229)][_0x233588(0x253)][_0x233588(0x207)](_0x233588(0x26d))&&this[_0x233588(0x229)][_0x233588(0x253)][_0x233588(0x300)](_0x233588(0x26d))[_0x233588(0x1e9)](),_0x480a55||!this[_0x233588(0x2fb)]?_0x1199ad=this[_0x233588(0x229)][_0x233588(0x36d)][_0x233588(0x300)](_0x233588(0x2bd)):this[_0x233588(0x29d)][_0x233588(0x224)]&&(_0x1199ad=this[_0x233588(0x2fb)][_0x233588(0x211)]['id']),await this[_0x233588(0x27e)]();const _0x121353=this[_0x233588(0x2b3)](),_0x5c98cf=_0x480a55||_0x31ba12();this[_0x233588(0x2fb)]=new _0x460b3a({'connector':this[_0x233588(0x371)],'chatModels':this[_0x233588(0x2af)],'selectedModelId':_0x1199ad,'conversationId':_0x5c98cf,'group':_0x121353,'getEditor':()=>_0x16921b(this[_0x233588(0x229)]),'isFromHistory':!!_0x480a55}),this[_0x233588(0x2fb)][_0x233588(0x234)](_0x233588(0x333),_0x233588(0x347))['to'](this),this[_0x233588(0x2fb)]['on'](_0x233588(0x264),(_0x51433a,_0x2cbc3f)=>{const _0x360d12=_0x233588;this[_0x360d12(0x29d)][_0x360d12(0x35a)](_0x2cbc3f),this[_0x360d12(0x29d)][_0x360d12(0x2d4)](),this[_0x360d12(0x29d)][_0x360d12(0x2cb)](),this[_0x360d12(0x29d)][_0x360d12(0x325)](),_0x480a55||(this[_0x360d12(0x29d)][_0x360d12(0x365)](),this[_0x360d12(0x353)]());}),this[_0x233588(0x2fb)]['on'](_0x233588(0x223),(_0x45f78c,_0x1f566e)=>{const _0x347879=_0x233588;this[_0x347879(0x29d)][_0x347879(0x1f9)](_0x1f566e[_0x347879(0x1fd)]);}),this[_0x233588(0x2fb)]['on'](_0x233588(0x32c),(_0x540fed,_0x493cbb)=>{const _0x521634=_0x233588;this[_0x521634(0x29d)][_0x521634(0x2dc)](_0x493cbb);}),this[_0x233588(0x2fb)]['on'](_0x233588(0x25a),()=>{const _0x22e626=_0x233588,_0x1dd878=this[_0x22e626(0x29d)][_0x22e626(0x359)]({'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});this[_0x22e626(0x29d)][_0x22e626(0x2a8)](_0x1dd878);}),this[_0x233588(0x2fb)]['on'](_0x233588(0x2ca),()=>{const _0x594912=_0x233588,_0x4f4fc7=this[_0x594912(0x29d)][_0x594912(0x359)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});this[_0x594912(0x29d)][_0x594912(0x2a8)](_0x4f4fc7);}),this[_0x233588(0x2fb)]['on'](_0x233588(0x231),(_0x4879f9,_0x3526f5)=>{const _0x2f8a48=_0x233588;this[_0x2f8a48(0x29d)][_0x2f8a48(0x344)](_0x3526f5,{'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x233588(0x2fb)]['on'](_0x233588(0x1f1),(_0x4157c3,_0x1ce903)=>{const _0x5f5423=_0x233588;this[_0x5f5423(0x29d)][_0x5f5423(0x344)](_0x1ce903,{'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x233588(0x2fb)]['on'](_0x233588(0x347),()=>{const _0x40a000=_0x233588;this[_0x40a000(0x29d)][_0x40a000(0x277)]();}),this[_0x233588(0x2fb)]['on'](_0x233588(0x26f),async()=>{const _0x788f6=_0x233588;await this[_0x788f6(0x29d)][_0x788f6(0x2f7)]();}),this[_0x233588(0x2fb)]['on'](_0x233588(0x24c),(_0x28753d,_0x5e1732)=>{const _0x423645=_0x233588;this[_0x423645(0x29d)][_0x423645(0x24e)](_0x5e1732['id']);}),this[_0x233588(0x2fb)]['on'](_0x233588(0x274),(_0x486ea5,_0x5956f3,_0x4d2760)=>{const _0x4d51cd=_0x233588;this[_0x4d51cd(0x2f9)](_0x5956f3,_0x4d2760);}),this[_0x233588(0x2fb)]['on'](_0x233588(0x27b),(_0x444b9f,_0x561b0c)=>{const _0x35e758=_0x233588;_0x35e758(0x2f6)===_0x561b0c[_0x35e758(0x310)]?this[_0x35e758(0x29d)][_0x35e758(0x2df)](_0x561b0c):this[_0x35e758(0x29d)][_0x35e758(0x1ef)](_0x561b0c);}),this[_0x233588(0x2fb)]['on'](_0x233588(0x27a),async(_0x4e2e3e,_0x3c13c9)=>{const _0x570e9f=_0x233588;await this[_0x570e9f(0x2fe)]({'reply':_0x3c13c9});}),this[_0x233588(0x2fb)]['on'](_0x233588(0x21e),(_0x208598,{reply:_0x5ad359,index:_0x5355fe,state:_0x5e3092})=>{const _0x1b480b=_0x233588;this[_0x1b480b(0x29d)][_0x1b480b(0x318)]({'id':_0x5ad359['id'],'index':_0x5355fe,'state':_0x5e3092}),this[_0x1b480b(0x244)]?.[_0x1b480b(0x328)][_0x1b480b(0x2a5)](_0x5ad359['id'])&&this[_0x1b480b(0x244)]?.[_0x1b480b(0x29a)]==_0x5355fe&&this[_0x1b480b(0x21c)]?.[_0x1b480b(0x2f5)](_0x5e3092);}),this[_0x233588(0x2fb)]['on'](_0x233588(0x303),(_0x142e58,_0x3a0be7)=>{const _0x25aac2=_0x233588;if(this[_0x25aac2(0x29d)][_0x25aac2(0x1f7)](_0x3a0be7[_0x25aac2(0x2b4)],_0x3a0be7[_0x25aac2(0x34c)]),_0x25aac2(0x2ad)===_0x3a0be7[_0x25aac2(0x2b4)][_0x25aac2(0x310)]){const _0x2be3fa=[..._0x16921b(this[_0x25aac2(0x229)])[_0x25aac2(0x2aa)][_0x25aac2(0x33e)][_0x25aac2(0x2ad)][_0x25aac2(0x2bb)]()];this[_0x25aac2(0x241)][_0x25aac2(0x21b)](_0x2be3fa,_0x25aac2(0x27d)+this[_0x25aac2(0x2fb)]?.['id']);}}),this[_0x233588(0x2fb)]['on'](_0x233588(0x2b9),(_0x177024,_0xa587c5)=>{const _0x1ef40e=_0x233588;this[_0x1ef40e(0x29d)][_0x1ef40e(0x2fd)](_0xa587c5[_0x1ef40e(0x275)]),_0x1ef40e(0x35b)==_0xa587c5[_0x1ef40e(0x275)]&&this[_0x1ef40e(0x35e)](),_0x1ef40e(0x2ad)===_0xa587c5[_0x1ef40e(0x310)]&&this[_0x1ef40e(0x241)][_0x1ef40e(0x1ed)](_0x1ef40e(0x27d)+this[_0x1ef40e(0x2fb)]?.['id']);}),this[_0x233588(0x2fb)]['on'](_0x233588(0x263),(_0x586d13,_0x456e0a)=>{const _0x283e6c=_0x233588;this[_0x283e6c(0x29d)][_0x283e6c(0x315)](_0x456e0a[_0x283e6c(0x2b4)][_0x283e6c(0x275)],_0x456e0a[_0x283e6c(0x34c)]);}),this[_0x233588(0x2fb)]['on'](_0x233588(0x22c),(_0x490b02,_0x50f075)=>{const _0x3cdd21=_0x233588;this[_0x3cdd21(0x29d)][_0x3cdd21(0x312)](_0x50f075[_0x3cdd21(0x21f)]);}),this[_0x233588(0x2fb)]['on'](_0x233588(0x313),(_0x128344,_0x3deccd)=>{const _0x55ba8d=_0x233588;this[_0x55ba8d(0x29d)][_0x55ba8d(0x329)](_0x3deccd[_0x55ba8d(0x361)]);}),this[_0x233588(0x2fb)]['on'](_0x233588(0x30e),(_0x21c485,_0x213758)=>{const _0x2fd4eb=_0x233588;this[_0x2fd4eb(0x29d)][_0x2fd4eb(0x267)](_0x213758[_0x2fd4eb(0x336)],_0x213758[_0x2fd4eb(0x2fc)],_0x213758[_0x2fd4eb(0x26e)],_0x213758[_0x2fd4eb(0x334)]);}),this[_0x233588(0x2fb)]['on'](_0x233588(0x217),(_0x48ae34,_0x40eec8)=>{const _0x241e1e=_0x233588;this[_0x241e1e(0x29d)][_0x241e1e(0x20a)](_0x40eec8[_0x241e1e(0x336)],_0x40eec8[_0x241e1e(0x245)],_0x40eec8[_0x241e1e(0x215)]);}),this[_0x233588(0x2fb)]['on'](_0x233588(0x2bf),(_0x3a95eb,_0x51df56)=>{const _0x4fa144=_0x233588;this[_0x4fa144(0x29d)][_0x4fa144(0x341)](_0x51df56);}),this[_0x233588(0x2fb)]['on'](_0x233588(0x335),async(_0x10759c,_0x1e2a4a)=>{const _0xaf9ec6=_0x233588,_0x3c510a=(await this[_0xaf9ec6(0x2af)][_0xaf9ec6(0x2fa)]())[_0xaf9ec6(0x317)](_0x2717e2=>_0x2717e2['id']===_0x1e2a4a[_0xaf9ec6(0x211)]?.['id'])||null;this[_0xaf9ec6(0x29d)][_0xaf9ec6(0x342)](_0x3c510a,_0x1e2a4a[_0xaf9ec6(0x28f)]);}),this[_0x233588(0x2fb)]['on'](_0x233588(0x281),(_0x3aae51,{error:_0x3ad286,interactionId:_0xb149ca,fileName:_0x35e2be,url:_0x4d1cb0,sourceId:_0x142574,sourceLabel:_0x34cb3a})=>{const _0x2049d7=_0x233588,_0x406d41=_0xb149ca?_0xb149ca+':'+_0x31ba12():_0x31ba12();_0x3ad286[_0x2049d7(0x258)][_0x2049d7(0x351)](_0x2049d7(0x2ab))?this[_0x2049d7(0x29d)][_0x2049d7(0x316)]({'staticMessage':_0x394fc2(this[_0x2049d7(0x229)][_0x2049d7(0x25c)],_0x2049d7(0x2eb)),'id':_0x406d41}):_0x3ad286[_0x2049d7(0x258)][_0x2049d7(0x351)](_0x2049d7(0x1f3))||_0x3ad286[_0x2049d7(0x258)][_0x2049d7(0x351)](_0x2049d7(0x298))?(this[_0x2049d7(0x29d)][_0x2049d7(0x293)]({'errorMessage':_0x394fc2(this[_0x2049d7(0x229)][_0x2049d7(0x25c)],_0x2049d7(0x349)),'id':_0x406d41}),this[_0x2049d7(0x2f4)](_0x3ad286)):_0x3ad286[_0x2049d7(0x258)][_0x2049d7(0x351)](_0x2049d7(0x2e7))?this[_0x2049d7(0x29d)][_0x2049d7(0x293)]({'errorMessage':_0x394fc2(this[_0x2049d7(0x229)][_0x2049d7(0x25c)],_0x2049d7(0x2d5),_0x35e2be),'id':_0x406d41}):_0x3ad286[_0x2049d7(0x258)][_0x2049d7(0x351)](_0x2049d7(0x32d))?this[_0x2049d7(0x29d)][_0x2049d7(0x293)]({'errorMessage':_0x394fc2(this[_0x2049d7(0x229)][_0x2049d7(0x25c)],_0x2049d7(0x2cd),_0x4d1cb0),'id':_0x406d41}):_0x3ad286[_0x2049d7(0x258)][_0x2049d7(0x351)](_0x2049d7(0x208))?this[_0x2049d7(0x29d)][_0x2049d7(0x293)]({'errorMessage':_0x394fc2(this[_0x2049d7(0x229)][_0x2049d7(0x25c)],_0x2049d7(0x343)),'id':_0x406d41}):_0x3ad286[_0x2049d7(0x258)][_0x2049d7(0x351)](_0x2049d7(0x221))?this[_0x2049d7(0x29d)][_0x2049d7(0x293)]({'errorMessage':_0x394fc2(this[_0x2049d7(0x229)][_0x2049d7(0x25c)],_0x2049d7(0x1ff)),'id':_0x406d41}):_0x3ad286[_0x2049d7(0x258)][_0x2049d7(0x351)](_0x2049d7(0x30a))?(_0x142574&&this[_0x2049d7(0x29d)][_0x2049d7(0x363)](_0x142574),this[_0x2049d7(0x29d)][_0x2049d7(0x293)]({'errorMessage':_0x394fc2(this[_0x2049d7(0x229)][_0x2049d7(0x25c)],_0x2049d7(0x319),_0x34cb3a||_0x2049d7(0x2fc)),'id':_0x406d41}),this[_0x2049d7(0x2f4)](_0x3ad286)):_0x3ad286[_0x2049d7(0x258)][_0x2049d7(0x351)](_0x2049d7(0x32a))?(this[_0x2049d7(0x29d)][_0x2049d7(0x293)]({'errorMessage':_0x394fc2(this[_0x2049d7(0x229)][_0x2049d7(0x25c)],_0x2049d7(0x2a4)),'id':_0x406d41}),this[_0x2049d7(0x2f4)](_0x3ad286)):_0x3ad286[_0x2049d7(0x258)][_0x2049d7(0x351)](_0x2049d7(0x34a))?(this[_0x2049d7(0x29d)][_0x2049d7(0x293)]({'errorMessage':_0x394fc2(this[_0x2049d7(0x229)][_0x2049d7(0x25c)],_0x2049d7(0x2f8)),'id':_0x406d41}),this[_0x2049d7(0x2f4)](_0x3ad286)):_0x3ad286[_0x2049d7(0x258)][_0x2049d7(0x351)](_0x2049d7(0x23b))?(this[_0x2049d7(0x29d)][_0x2049d7(0x293)]({'errorMessage':_0x394fc2(this[_0x2049d7(0x229)][_0x2049d7(0x25c)],_0x2049d7(0x202)),'id':_0x406d41}),this[_0x2049d7(0x2f4)](_0x3ad286)):_0x3ad286[_0x2049d7(0x258)][_0x2049d7(0x351)](_0x2049d7(0x2ce))?(this[_0x2049d7(0x29d)][_0x2049d7(0x293)]({'errorMessage':_0x394fc2(this[_0x2049d7(0x229)][_0x2049d7(0x25c)],_0x2049d7(0x2c7)),'id':_0x406d41}),this[_0x2049d7(0x2f4)](_0x3ad286)):_0x3ad286[_0x2049d7(0x258)][_0x2049d7(0x351)](_0x2049d7(0x291))?(this[_0x2049d7(0x29d)][_0x2049d7(0x293)]({'errorMessage':_0x394fc2(this[_0x2049d7(0x229)][_0x2049d7(0x25c)],_0x2049d7(0x251)),'id':_0x406d41}),this[_0x2049d7(0x2f4)](_0x3ad286)):_0x3ad286[_0x2049d7(0x258)][_0x2049d7(0x351)](_0x2049d7(0x32e))?(this[_0x2049d7(0x29d)][_0x2049d7(0x293)]({'errorMessage':_0x394fc2(this[_0x2049d7(0x229)][_0x2049d7(0x25c)],_0x2049d7(0x26b)),'id':_0x406d41}),this[_0x2049d7(0x2f4)](_0x3ad286)):(this[_0x2049d7(0x29d)][_0x2049d7(0x293)]({'errorMessage':_0x394fc2(this[_0x2049d7(0x229)][_0x2049d7(0x25c)],_0x2049d7(0x230)),'id':_0x406d41}),this[_0x2049d7(0x2f4)](_0x3ad286));}),await this[_0x233588(0x2fb)][_0x233588(0x222)](this[_0x233588(0x229)][_0x233588(0x36d)][_0x233588(0x300)](_0x233588(0x20e))),_0x480a55||await this[_0x233588(0x2fb)][_0x233588(0x2b2)]();}async[_0x102c9d(0x254)]({userMessage:_0x45c593,attributes:_0x5c77c0}){const _0xeb4ce8=_0x102c9d;if(!this[_0xeb4ce8(0x2fb)])throw new _0x302247(_0xeb4ce8(0x330));if(this[_0xeb4ce8(0x2fb)][_0xeb4ce8(0x29e)]()){const _0x50d1f6=await this[_0xeb4ce8(0x241)][_0xeb4ce8(0x268)]();await this[_0xeb4ce8(0x2fb)][_0xeb4ce8(0x372)](_0x50d1f6);}this[_0xeb4ce8(0x2fb)]['id']&&this[_0xeb4ce8(0x2fb)][_0xeb4ce8(0x2e8)]&&await this[_0xeb4ce8(0x2fb)][_0xeb4ce8(0x321)]({'userMessage':_0x45c593,'attributes':_0x5c77c0});}[_0x102c9d(0x29c)](){const _0x569728=_0x102c9d;console[_0x569728(0x270)](_0x569728(0x1ea));}[_0x102c9d(0x1f4)](_0x33a7f9){const _0x50b489=_0x102c9d;this[_0x50b489(0x29d)][_0x50b489(0x26a)](_0x33a7f9);}[_0x102c9d(0x2f4)](_0x41a4e2){const _0x659b08=_0x102c9d;_0x5bf06e(_0x41a4e2[_0x659b08(0x258)]);}[_0x102c9d(0x323)](_0x5e0332){const _0x3bbb77=_0x102c9d;this[_0x3bbb77(0x2fb)]?.[_0x3bbb77(0x345)](_0x5e0332);}[_0x102c9d(0x1f6)](){const _0x29133b=_0x102c9d;this[_0x29133b(0x2fb)]?.[_0x29133b(0x2d1)]();}[_0x102c9d(0x2a7)](){const _0x5e41e5=_0x102c9d;this[_0x5e41e5(0x2fb)]?.[_0x5e41e5(0x286)]();}[_0x102c9d(0x24b)](_0x12d679){const _0x51adc9=_0x102c9d,[_0x47112b,_0x548769]=_0x12d679[_0x51adc9(0x360)](':'),_0x547edd=this[_0x51adc9(0x2fb)][_0x51adc9(0x1eb)](_0x47112b),_0x2500cd=_0x547edd[_0x51adc9(0x367)](_0x548769);return{'interaction':_0x547edd,'reply':_0x2500cd};}[_0x102c9d(0x309)](_0x446648,_0x5051a1=!0x1){const _0x170bbd=_0x102c9d,_0x24aafb=_0x16921b(this[_0x170bbd(0x229)]),_0x2adb92={'target':_0x24aafb[_0x170bbd(0x331)][_0x170bbd(0x261)][_0x170bbd(0x30f)][_0x170bbd(0x31a)](_0x24aafb[_0x170bbd(0x331)][_0x170bbd(0x2d3)][_0x170bbd(0x2c8)](_0x446648)),'viewportOffset':{'top':0x96,'left':0x0,'bottom':0x32,'right':0x0},'ancestorOffset':0x14,'alignToTop':_0x5051a1};_0x5051a1&&(_0x2adb92[_0x170bbd(0x2ec)]=!0x0),_0x5dad21(_0x2adb92);}[_0x102c9d(0x2f9)](_0x5db940,_0xdef926=!0x1){const _0x565bbb=_0x102c9d;this[_0x565bbb(0x29d)][_0x565bbb(0x274)](_0x5db940||_0x394fc2(this[_0x565bbb(0x229)][_0x565bbb(0x25c)],_0x565bbb(0x33d)),_0xdef926);}async[_0x102c9d(0x2fe)]({reply:_0x251666,renderingStrategy:_0x4fe23e}){const _0x3695df=_0x102c9d,{id:_0x21e5c3,interactionId:_0x3c3450,isDone:_0x5f1d3d,type:_0x4cf923,parsedContent:_0x369ca1}=_0x251666,_0xca74c6=_0x3c3450+':'+_0x21e5c3;if(_0x3695df(0x33b)===_0x4cf923){const _0x2f467a=_0x251666[_0x3695df(0x33f)]({'showDiff':this[_0x3695df(0x29d)][_0x3695df(0x272)]});await this[_0x3695df(0x29d)][_0x3695df(0x2db)]({'id':_0xca74c6,'parts':_0x2f467a,'renderingStrategy':_0x4fe23e,'isDone':_0x5f1d3d});}else _0x3695df(0x2f6)===_0x4cf923&&await this[_0x3695df(0x29d)][_0x3695df(0x273)]({'id':_0xca74c6,'parsedContent':_0x369ca1,'renderingStrategy':_0x4fe23e,'isDone':_0x5f1d3d});_0x5f1d3d&&_0x251666[_0x3695df(0x219)][_0x3695df(0x370)]>0x0&&this[_0x3695df(0x29d)][_0x3695df(0x200)](_0xca74c6,_0x251666[_0x3695df(0x219)]);}async[_0x102c9d(0x27e)](){const _0x504df7=_0x102c9d,_0x19e3fc=this[_0x504df7(0x2fb)]?.[_0x504df7(0x23d)];_0x19e3fc&&(_0x19e3fc[_0x504df7(0x201)](),this[_0x504df7(0x29d)][_0x504df7(0x2da)](_0x19e3fc));}async[_0x102c9d(0x28c)](){const _0x3674cc=_0x102c9d,_0x55aef2=this[_0x3674cc(0x2fb)]?.[_0x3674cc(0x23d)];if(_0x55aef2){for await(const _0x553147 of _0x55aef2[_0x3674cc(0x2c4)])await this[_0x3674cc(0x2fe)]({'reply':_0x553147,'renderingStrategy':_0x3674cc(0x2ea)});}}[_0x102c9d(0x354)](_0x3952f4){const _0x458993=_0x102c9d,_0x5ab835={'positiveCount':_0x3952f4[_0x458993(0x22b)][_0x458993(0x2e9)](_0x115ecf=>_0x458993(0x2f3)===_0x115ecf[_0x458993(0x2a3)])[_0x458993(0x370)],'totalCount':_0x3952f4[_0x458993(0x22b)][_0x458993(0x370)],'modificationId':_0x3952f4['id']},_0x4e7d72=this[_0x458993(0x2fb)][_0x458993(0x1eb)](_0x3952f4[_0x458993(0x31e)])[_0x458993(0x28e)];_0x4e7d72&&this[_0x458993(0x371)][_0x458993(0x2ba)](this[_0x458993(0x2fb)]['id'],_0x4e7d72,_0x5ab835);}[_0x102c9d(0x2d6)](_0x22d48f){const _0x53f8d8=_0x102c9d;let _0x40e726=null,_0x2d5697=null;this['on'](_0x53f8d8(0x333),(_0x52638a,_0x2fede5,_0x1b5848)=>{const _0x2badba=_0x53f8d8;_0x1b5848['id']!==_0x40e726&&(_0x40e726=_0x1b5848['id'],_0x2d5697=this[_0x2badba(0x2ef)](_0x1b5848)),_0x22d48f(_0x2fede5,_0x2d5697);});}[_0x102c9d(0x2ef)](_0x44ab33){const _0x348f02=_0x102c9d,_0x4270f9=this[_0x348f02(0x29d)],_0x137ca3=()=>{const _0x42fbfd=_0x348f02;_0x44ab33[_0x42fbfd(0x218)](),_0x44ab33[_0x42fbfd(0x228)](),_0x4270f9[_0x42fbfd(0x248)]();},_0x5bf415=()=>{const _0x9c1fe9=_0x348f02;_0x44ab33[_0x9c1fe9(0x2de)]&&(_0x44ab33[_0x9c1fe9(0x2de)][_0x9c1fe9(0x22a)](),_0x44ab33[_0x9c1fe9(0x2de)]=void 0x0);};return{'insertTextReply':(_0x51cb79,_0x40de36)=>{const _0x55836a=_0x348f02;_0x5bf415(),_0x137ca3();const _0x13ec93=_0x44ab33[_0x55836a(0x2de)]=_0x44ab33[_0x55836a(0x2b6)]({'type':_0x55836a(0x2f6),'interactionId':_0x44ab33['id'],'content':_0x51cb79,'id':_0x40de36||_0x31ba12()});return _0x5bf415(),_0x13ec93;},'insertCustomElement':async(_0x16d92b,_0x40b1d7)=>(_0x5bf415(),_0x137ca3(),_0x4270f9[_0x348f02(0x225)](_0x16d92b,_0x40b1d7||_0x31ba12())),'setLoadingMessage':_0x275ccd=>{const _0x342322=_0x348f02;_0x4270f9[_0x342322(0x2a8)](_0x275ccd);},'clearLoadingMessage':()=>{const _0x24ccee=_0x348f02;_0x4270f9[_0x24ccee(0x248)]();}};}}
23
+ const _0x12f486=_0x3a9b;function _0x5ea4(){const _0x6daf08=['ai-chat-context-file-too-large','like','setIsMaximized','getConversation','showNext','executeCustomItemCallback','_bodyCollection','getDocumentContext','AIChatController','selection','get','sourceId','toggleReasoning','outdated','AI_CHAT_CONTEXT_FORM_DATA_SIZE_LIMITS_EXCEEDED','node','activeConversation','ai.models.defaultModelId','changeGroups','closeSourceResourceBalloon','alignToTop','AI_CHAT_CONTEXT_INVALID_DATA','resize','stop','undo','addSelectionToChatContext','toViewRange','startInteraction','addFeedItemAIReply','toggleLoadingSkeleton','slice','finishInteraction','ai-request-aborted','AI_CHAT_GENERIC_ERROR','focusPromptInput','resizedTabs','addFileToContext','ai-chat-resource-load-failed','_aiChatBalloonShowDiff','getInteractionAndReplyById','1546761eRHUTC','unshift','contextItemLoadingEnded','createPositionAt','scrollFeedToSuggestion','removeFeedInteraction','removeSelectionFromContext','ready','replyCreated','AITabs','sendMessage','applySuggestion','_aiChatBalloon','_logError','viewRangeToDom','showDiff','_updateReplyContent','current-document','ai-conversation-','nextSibling','reasoningStarted','end','change','load','isInContext','previous','partIndex','Showing\x20conversation\x20history...','detachFromDom','sendUserMessage','loadConversation','createReply','getPath','getDiff','_registerToolDataCallback','Liked\x20response','addResourceToContext','AI_CHAT_RESOURCE_LOAD_FAILED','attachToDom','enableControls','split','setConversationTitle','getAttribute','isOfficialPlugin','source','removeSelectionFromChatContext','_flushLastInteractionUI','startConversation','_openBalloonFor','addFeedItemAISuggestion','delegate','messageId','activateTab','AI_CHAT_CONTEXT_FILE_TOO_LARGE','getChild','_applyOperationsAsSuggestions','getSelectionText','addFilesToContext','dialogClosed','addFeedItemError','lastInteraction','_aiConnector','findIndex','isModelAvailable','isCurrentDocumentInContext','updateFeedItemAIReplyContent','startAutoScroll','updateFeedItemAIReplySources','_createFromRanges','AI_CHAT_UNABLE_TO_LOAD_CONVERSATION','webSearchFinished','AIChatUI','toolDataReceived','hasChanges','ai.chat.initialConversation','mouseLeaveSuggestion','createPositionFromPath','setFeedItemRenderingStrategy','find','sources','rootName','ai-chat-url-upload-failed','toggleSuggestionDisplayMode','new','maxOffset','close','query','_applySuggestion','main','_setIsMaximized','lastCreated','cloneNode','TrackChangesEditing','delete','reasoningFinished','streaming','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_FILE','isUploadInProgress','model','setIsUploadInProgress','root','Undo','24bXLKoC','resourceId','open','ai-chat-invalid-request','_aiChatModels','pluginName','ai-chat-source-resources-load-failed','clearConversationContextUI','_getDocumentRangeForReplyChanges','removeFromContext','addUrlToContext','redo','$graveyard','index','context','ai-chat-controller-mouse-over','listenTo','getChildAtOffset','documentContextContent','dislike','accepted','set','getFirstRange','getReply','ai-chat-conversation-init-failed','ai-chat-context-invalid-data','AIConnector','includes','callback','594750ugEPbv','ai-chat-context-form-data-size-limits-exceeded','content','type','AI_CHAT_UNABLE_TO_START_CONVERSATION','Disliked\x20response','data-id','clearLoadingMessage','webSearchStarted','version','replyChangeGroupStateUpdated','data','resource','ai-chat-missing-channel-id','capabilitiesUpdated','isLoading','ai-chat-context-unsupported-type','createdAt','updateConversationTitle','isStarted','AIChatBalloon','setSelectedModel','map','destroy','addOperation','replyContentUpdated','updateFeedItemAIReplySuggestionContent','AI_CHAT_CONTEXT_UNSUPPORTED_FILE_TYPE','populateSourceResourceBalloon','getConversations','isDocumentOperation','_scrollToSuggestionRange','addContextOptionsChanged','toString','handleRemovedConversation','revert','message','interactionId','addFeedItemUserMessage','path','ai-chat-context-unsupported-file-type','getTransformedByOperation','requires','getChildren','7zkYjmX','afterInit','parse','clearPendingContextUI','batch','addCurrentDocumentToChatContext','showFakeVisualSelection','howMany','updateResourceState','resetMessageInput','_toggleReasoning','error','_stopLastInteraction','setLoadingMessage','_removeFromContext','updateContent','next','setContextItemLoading','resetConversationTitle','state','log','loadSourceResources','addCurrentDocumentToContext','_getPresentableSiblingContentPartIndex','history','showPrevious','getAll','indexOf','AIEditing','_getAIChatInteractionAPI','interactionCreated','replyId','collaboration.channelId','document','getInteraction','ai.chat.context','_integrateEditor','done','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_URL','resourceStateChanged','commands','modelSelected','length','setFeedItemAIReplySuggestionPartActive','range','sessionId','addSelectionToContext','text','resetReasoningState','_updateRatings','remove','marker','239zMJRgb','plugins','ai-no-track-changes','upsertAIChatRating','uploadProgressChanged','AI_CHAT_ABORTED_MESSAGE','setModel','add','mapper','setAddContextOptions','aiChatBalloon','resources','start','_startConversationSafely','AI_CHAT_CONTEXT_UNABLE_TO_LOAD_RESOURCES','ai-chat-conversation-start-failed','has','uiId','hideFakeVisualSelection','selectedModel','disableControls','stopInteraction','showChangeInText','areActionsDisabled','2156EDxrwQ','contextItemAdded','prepareLoadingMessage','applyOperation','_getLastCreatedConversationId','interactionFinished','addFeedItemCustomElement','currentReply','toggleWebSearch','ai-chat-context-file-too-many-pages','insertSuggestion','mouseOverSuggestion','3402905qzeBes','domConverter','init','4jllmFr','DocumentCompare','isPremiumPlugin','AI_CHAT_CONTEXT_FILE_TOO_MANY_PAGES','ai-chat-file-upload-failed','indexes','_batchToChanges','sourceResourcesLoaded','updateFeedItemAIReplySuggestionPartState','forEach','locale','editing','TrackChanges','bind','children','modification','1074681YrzfKH','getContentParts','selectModel','addFeedItemStaticMessage','config','addFeedInteractionHeader','1406226BmNIih','addDocumentToContext','setChangeGroupState','createConversation','ai.models','abortPromptStream','getDocumentData','isDisabled','AI_CHAT_CONTEXT_CURRENT_DOCUMENT','AI_CHAT_INVALID_REQUEST','isCurrentDocumentInConversation','updateCapabilities','_getUserPresentableContentPartDocumentRange','anchorId','_currentPreviewedChangeGroup','from','_rejectSuggestion','fetchConversation','push','contextSent','AI_BALLOON_HEADER_TITLE','resetWebSearchState','getOperations','conversationInitialized','rejectSuggestion','getGroupId','_insertSuggestion','_toggleWebSearch','chat','_handleStartConversation','createRange','changes','startsWith','addContextItem','AI_CHAT_CONTEXT_UNSUPPORTED_TYPE','options','_aiChatUi','_aiEditing','updateCurrentDocumentInContext','2654290xvabfY','AI_CHAT_UNTITLED_CONVERSATION','editors','contextItem','handleUserInteraction','replies','ai-chat-controller-no-active-conversation','setState','uid','fetchConversations','baseVersion','contextItems','getRoot','view','_showConversationHistory','resizeTabs','pending','ai-chat-conversation-not-found','setConversationContext','interactionStarted','_handleUIUserMessage','removed','rejected','removeContextItem','filter','sourcePosition','interactionDestroyed','contextItemRemoved','static','getRanges'];_0x5ea4=function(){return _0x6daf08;};return _0x5ea4();}(function(_0x1cd78a,_0x3df4ce){const _0x443f11=_0x3a9b,_0x1dd61c=_0x1cd78a();while(!![]){try{const _0x49b2f8=-parseInt(_0x443f11(0x8e))/0x1*(-parseInt(_0x443f11(0xa6))/0x2)+-parseInt(_0x443f11(0x138))/0x3*(parseInt(_0x443f11(0xb5))/0x4)+-parseInt(_0x443f11(0x1bb))/0x5+parseInt(_0x443f11(0xcb))/0x6*(parseInt(_0x443f11(0x1e7))/0x7)+-parseInt(_0x443f11(0x19e))/0x8*(-parseInt(_0x443f11(0xc5))/0x9)+-parseInt(_0x443f11(0xf2))/0xa+parseInt(_0x443f11(0xb2))/0xb;if(_0x49b2f8===_0x3df4ce)break;else _0x1dd61c['push'](_0x1dd61c['shift']());}catch(_0x291744){_0x1dd61c['push'](_0x1dd61c['shift']());}}}(_0x5ea4,0x3f62d));import{ContextPlugin as _0x1bba01,Editor as _0x1ab0f4}from'ckeditor5/src/core.js';import{BodyCollection as _0x438b43}from'ckeditor5/src/ui.js';function _0x3a9b(_0x3e25e9,_0x13cffa){const _0x5ea4d7=_0x5ea4();return _0x3a9b=function(_0x3a9be2,_0x2df47a){_0x3a9be2=_0x3a9be2-0x6b;let _0x19568e=_0x5ea4d7[_0x3a9be2];return _0x19568e;},_0x3a9b(_0x3e25e9,_0x13cffa);}import{CKEditorError as _0x4b2b76,logError as _0x5319e8,scrollViewportToShowTarget as _0x343c18,uid as _0x14d190}from'ckeditor5/src/utils.js';import{AIConnector as _0x4a9833}from'../aicore/aiconnector.js';import{AITabs as _0x575159}from'../aitabs/aitabs.js';import{AIChatConversation as _0x2fc456}from'./model/aichatconversation.js';import{getTranslation as _0x541ff7}from'../aicore/utils/common-translations.js';import{AIModels as _0x1bdab5}from'../aicore/model/aimodels.js';import{getEditorFromContext as _0x4b9b70}from'../aicore/utils/geteditorfromcontext.js';import{DocumentCompare as _0x41a947,DATA_ID_MODEL_ATTRIBUTE as _0xdc6d4f}from'ckeditor5-collaboration/src/collaboration-core.js';import{fixMarkerOperationOldRange as _0x366e90,getOperationsFromReply as _0x58de2c}from'../aicore/utils/getoperationsfromreply.js';import{expandSelectionWithContext as _0x52bea3,getMinimalSelection as _0x572c78}from'../aicore/utils/getsuggestionpartsfromreply.js';import{ModelRange as _0x1ca952,_DetachOperation as _0x1604bc}from'ckeditor5/src/engine.js';import{findOne as _0xd10b12,getAttribute as _0xa01188,serialize as _0x52f5de,Document as _0x8e65d3,findByAttribute as _0x2b1db6}from'../aicore/utils/htmlparser.js';export class AIChatController extends _0x1bba01{[_0x12f486(0xf0)];[_0x12f486(0x175)];[_0x12f486(0xef)];[_0x12f486(0x1a2)];[_0x12f486(0x144)];[_0x12f486(0xbb)]=new Map();[_0x12f486(0xd9)]=null;[_0x12f486(0x116)];static get[_0x12f486(0x1e5)](){return[_0x4a9833,_0x41a947];}static get[_0x12f486(0x1a3)](){const _0x460de2=_0x12f486;return _0x460de2(0x118);}static get[_0x12f486(0x163)](){return!0x0;}static get[_0x12f486(0xb7)](){return!0x0;}[_0x12f486(0xb4)](){const _0x1dc127=_0x12f486;this[_0x1dc127(0x116)]=new _0x438b43(this[_0x1dc127(0x1ac)][_0x1dc127(0xbf)]),this[_0x1dc127(0x116)][_0x1dc127(0x15e)](),this[_0x1dc127(0x175)]=this[_0x1dc127(0x1ac)][_0x1dc127(0x8f)][_0x1dc127(0x11a)](_0x1dc127(0x1b8)),this[_0x1dc127(0xef)]=this[_0x1dc127(0x1ac)][_0x1dc127(0x8f)][_0x1dc127(0x11a)](_0x1dc127(0x17f)),this[_0x1dc127(0xf0)]=this[_0x1dc127(0x1ac)][_0x1dc127(0x8f)][_0x1dc127(0x11a)](_0x1dc127(0x76)),this[_0x1dc127(0x1a2)]=new _0x1bdab5({'connector':this[_0x1dc127(0x175)],'config':this[_0x1dc127(0x1ac)][_0x1dc127(0xc9)][_0x1dc127(0x11a)](_0x1dc127(0xcf)),'locale':this[_0x1dc127(0x1ac)][_0x1dc127(0xbf)]});const _0xd54ed3=this[_0x1dc127(0x1ac)][_0x1dc127(0x8f)][_0x1dc127(0x11a)](_0x1dc127(0x141));this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x167),()=>{const _0x25692d=_0x1dc127;this[_0x25692d(0x9b)]();}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x155),(_0x87ccbc,_0x41cf6a)=>{const _0xdffe61=_0x1dc127;this[_0xdffe61(0x106)]({'userMessage':_0x41cf6a});}),this[_0x1dc127(0x1ae)](_0xd54ed3,_0x1dc127(0x133),(_0x3ea742,_0x45432b)=>{const _0x39f165=_0x1dc127;this[_0x39f165(0x191)](_0x45432b);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x101),()=>{const _0x48b26c=_0x1dc127;_0xd54ed3[_0x48b26c(0x126)]();}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0xd0),async()=>{const _0x3b7fde=_0x1dc127;await this[_0x3b7fde(0x1f3)](),await this[_0x3b7fde(0x166)](),this[_0x3b7fde(0x165)]();}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0xcc),()=>{const _0x4f47ed=_0x1dc127;this[_0x4f47ed(0x1ec)]();}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x134),(_0x3aa7d9,_0x1b7d3d)=>{const _0x3f6410=_0x1dc127;this[_0x3f6410(0x120)]?.[_0x3f6410(0x171)](Array[_0x3f6410(0xda)](_0x1b7d3d));}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x1a8),(_0x1b93e9,_0x51ecd9)=>{const _0xcad80=_0x1dc127;this[_0xcad80(0x120)]?.[_0xcad80(0x1a8)](_0x51ecd9);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x115),(_0xe50526,_0x9a4076)=>{const _0x4c4d2e=_0x1dc127;_0x9a4076[_0x4c4d2e(0x1ba)](this[_0x4c4d2e(0x1ac)]);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x15c),(_0x37750d,_0x2ebabc)=>{const _0x1ad393=_0x1dc127;this[_0x1ad393(0x120)]?.[_0x1ad393(0x15c)](_0x2ebabc[_0x1ad393(0x164)],_0x2ebabc[_0x1ad393(0x1c7)]);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x109),(_0x42274a,_0x1a86f2)=>{const _0x4d5d83=_0x1dc127;this[_0x4d5d83(0x1f5)](_0x1a86f2);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x6f),(_0x4bf45b,_0x1e01b8)=>{const _0x28d97b=_0x1dc127;this[_0x28d97b(0x120)]?.[_0x28d97b(0x6f)](_0x1e01b8[_0x28d97b(0x11b)],_0x1e01b8[_0x28d97b(0x18e)],_0x1e01b8[_0x28d97b(0xfa)]);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0xae),()=>{const _0x499db6=_0x1dc127;this[_0x499db6(0xe6)]();}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x11c),()=>{const _0x55d1fd=_0x1dc127;this[_0x55d1fd(0x1f1)]();}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0xc7),(_0x2a7ddc,_0x1fe8c6)=>{const _0x222e01=_0x1dc127;this[_0x222e01(0x120)]?.[_0x222e01(0x94)](_0x1fe8c6);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x111),(_0x2b5f2b,{replyId:_0x427502})=>{const _0x24be12=_0x1dc127;console[_0x24be12(0x6e)](_0x24be12(0x15b),_0x427502);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x1b1),(_0xaa3829,{replyId:_0x348651})=>{const _0x3a4e1d=_0x1dc127;console[_0x3a4e1d(0x6e)](_0x3a4e1d(0x1c0),_0x348651);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0xb0),(_0x339033,_0x52d437)=>{const _0x2f85e0=_0x1dc127;this[_0x2f85e0(0xe5)](_0x52d437);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0xa4),(_0x253786,{replyId:_0x2dd668,partIndex:_0x5617ba})=>{const _0xf58846=_0x1dc127;this[_0xf58846(0x136)]=this[_0xf58846(0xef)][_0xf58846(0x147)],this[_0xf58846(0x168)](_0x2dd668,_0x5617ba);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0xb1),(_0x2a5047,{replyId:_0x301d47,partIndex:_0x9d8eb0})=>{const _0x21d917=_0x1dc127,_0x3130a7=this[_0x21d917(0x1a6)](_0x301d47,_0x9d8eb0);_0x3130a7&&_0x21d917(0x1aa)!=_0x3130a7[_0x21d917(0x86)][_0x21d917(0x19c)][_0x21d917(0x188)]&&this[_0x21d917(0xf0)][_0x21d917(0x1ed)]([_0x3130a7[_0x21d917(0x86)]],_0x21d917(0x1ad));}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x183),()=>{const _0x4aa01c=_0x1dc127;this[_0x4aa01c(0xf0)][_0x4aa01c(0xa0)](_0x4aa01c(0x1ad));}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x143),(_0x5a3a3d,_0x3cf295)=>{const _0x5a199a=_0x1dc127;this[_0x5a199a(0xf0)][_0x5a199a(0xa0)](_0x5a199a(0x1ad)),this[_0x5a199a(0x18f)](_0x3cf295);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x18a),async(_0x1b4c4f,{replyId:_0xc0cef0,showDiff:_0x1d7d37})=>{const _0xfd97ce=_0x1dc127,{reply:_0x579cc7}=this[_0xfd97ce(0x137)](_0xc0cef0),_0x289790=_0x579cc7[_0xfd97ce(0xc6)]({'showDiff':_0x1d7d37});await this[_0xfd97ce(0xef)][_0xfd97ce(0x1d5)]({'id':_0x579cc7['id'],'parts':_0x289790,'renderingStrategy':_0xfd97ce(0x10e)});}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0xe3),(_0x20d6a8,{replyId:_0x579eb9,partIndex:_0x350b6f})=>{const _0x5180a5=_0x1dc127;this[_0x5180a5(0xdb)]({'replyId':_0x579eb9,'partIndex':_0x350b6f}),this[_0x5180a5(0xf0)][_0x5180a5(0xa0)](_0x5180a5(0x1ad));}),this[_0x1dc127(0x1ac)][_0x1dc127(0x8f)][_0x1dc127(0x9e)](_0x1dc127(0x1cf))&&(this[_0x1dc127(0x144)]=this[_0x1dc127(0x1ac)][_0x1dc127(0x8f)][_0x1dc127(0x11a)](_0x1dc127(0x1cf)),this[_0x1dc127(0x1b3)](_0x1dc127(0x136),!0x1),this[_0x1dc127(0x144)][_0x1dc127(0xc2)](_0x1dc127(0x147))['to'](this,_0x1dc127(0x136)),this[_0x1dc127(0x1ae)](this[_0x1dc127(0x144)],_0x1dc127(0x18a),()=>{const _0x4dffca=_0x1dc127,{replyId:_0x1e6d45,partIndex:_0x9f1efe}=this[_0x4dffca(0xd9)];this[_0x4dffca(0x136)]=!this[_0x4dffca(0x136)];const {reply:_0x5bb99b}=this[_0x4dffca(0x137)](_0x1e6d45),_0x3b8a36=_0x5bb99b[_0x4dffca(0xc6)]({'showDiff':this[_0x4dffca(0x136)],'groupIndex':_0x9f1efe});this[_0x4dffca(0x144)][_0x4dffca(0x1f6)]({'part':_0x3b8a36[0x0],'renderingStrategy':_0x4dffca(0x10e),'keepErrors':!0x0});}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0x144)],_0x1dc127(0x143),()=>{const _0x1a40db=_0x1dc127,{replyId:_0x478680,partIndex:_0x30e0f6}=this[_0x1a40db(0xd9)];this[_0x1a40db(0x18f)]({'replyId':_0x478680,'partIndex':_0x30e0f6}),this[_0x1a40db(0x144)][_0x1a40db(0xf9)](_0x1a40db(0x1b2));}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0x144)],_0x1dc127(0xb0),()=>{const _0x2edd63=_0x1dc127,{replyId:_0x787d15,partIndex:_0x5239ac}=this[_0x2edd63(0xd9)];this[_0x2edd63(0xe5)]({'replyId':_0x787d15,'partIndex':_0x5239ac}),this[_0x2edd63(0x144)][_0x2edd63(0xf9)](_0x2edd63(0x1b2));}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0x144)],_0x1dc127(0xe3),()=>{const _0x2fa1c2=_0x1dc127,{replyId:_0x304648,partIndex:_0x5e5d5f}=this[_0x2fa1c2(0xd9)];this[_0x2fa1c2(0xdb)]({'replyId':_0x304648,'partIndex':_0x5e5d5f}),this[_0x2fa1c2(0x144)][_0x2fa1c2(0xf9)](_0x2fa1c2(0x108));}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0x144)],_0x1dc127(0x114),()=>{const _0x3712e0=_0x1dc127,{replyId:_0x1a3d70,partIndex:_0x4807b0}=this[_0x3712e0(0xd9)],_0x656dc2=this[_0x3712e0(0x71)](_0x1a3d70,_0x4807b0,_0x3712e0(0x1f7));null!==_0x656dc2&&this[_0x3712e0(0x168)](_0x1a3d70,_0x656dc2);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0x144)],_0x1dc127(0x73),()=>{const _0xf290dc=_0x1dc127,{replyId:_0x37e3ec,partIndex:_0x19ce16}=this[_0xf290dc(0xd9)],_0xee9586=this[_0xf290dc(0x71)](_0x37e3ec,_0x19ce16,_0xf290dc(0x151));null!==_0xee9586&&this[_0xf290dc(0x168)](_0x37e3ec,_0xee9586);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0x144)],_0x1dc127(0x172),(_0x3306de,{id:_0x160b25})=>{const _0x168123=_0x1dc127;if(_0x168123(0x98)!==_0x160b25)return;const {replyId:_0x371ecb,partIndex:_0x277464}=this[_0x168123(0xd9)];this[_0x168123(0xd9)]=null,this[_0x168123(0xef)][_0x168123(0x85)]({'id':_0x371ecb,'index':_0x277464,'isActive':!0x1});}));}async[_0x12f486(0x1e8)](){const _0xff9820=_0x12f486;this[_0xff9820(0x1ac)]instanceof _0x1ab0f4?this[_0xff9820(0x7e)](this[_0xff9820(0x1ac)]):this[_0xff9820(0x1ae)](this[_0xff9820(0x1ac)][_0xff9820(0xf4)],_0xff9820(0x95),(_0x2402c7,_0x3dc412)=>{const _0x2da804=_0xff9820;_0x3dc412['on'](_0x2da804(0x13f),()=>{const _0x5206b6=_0x2da804;this[_0x5206b6(0x7e)](_0x3dc412);});});const _0x373747=this[_0xff9820(0x1ac)][_0xff9820(0xc9)][_0xff9820(0x11a)](_0xff9820(0x182));let _0x4b53eb=_0x373747;if(_0xff9820(0x192)!=_0x373747||(_0x4b53eb=await this[_0xff9820(0xaa)](),_0x4b53eb))return _0xff9820(0x18b)==_0x4b53eb?this[_0xff9820(0x9b)]():this[_0xff9820(0x156)](_0x4b53eb);}async[_0x12f486(0x1d2)](){const _0x128c93=_0x12f486;return await this[_0x128c93(0x1f3)](),this[_0x128c93(0x116)][_0x128c93(0x154)](),super[_0x128c93(0x1d2)]();}[_0x12f486(0xe5)](_0x33292e){const _0xfd4326=_0x12f486,_0x4dc5af=_0x4b9b70(this[_0xfd4326(0x1ac)]);if(!_0x4dc5af[_0xfd4326(0x8f)][_0xfd4326(0x9e)](_0xfd4326(0xc1)))throw new _0x4b2b76(_0xfd4326(0x90),null);const _0x33d3ee=this[_0xfd4326(0x1ac)][_0xfd4326(0x8f)][_0xfd4326(0x11a)](_0xfd4326(0xb6)),{reply:_0xa65adf,interaction:_0x312d0c}=this[_0xfd4326(0x137)](_0x33292e[_0xfd4326(0x79)]),_0x36cad7=this[_0xfd4326(0x1a6)](_0x33292e[_0xfd4326(0x79)],_0x33292e[_0xfd4326(0x152)]),_0x45eb0d=void 0x0!==_0x33292e[_0xfd4326(0x152)]?[_0xa65adf[_0xfd4326(0x122)][_0x33292e[_0xfd4326(0x152)]]]:_0xa65adf[_0xfd4326(0x122)][_0xfd4326(0x10a)](_0x15cf14=>_0xfd4326(0x102)==_0x15cf14[_0xfd4326(0x6d)]),_0x211458=_0x45eb0d[_0xfd4326(0x1d1)](_0x2e0fe6=>_0xa65adf[_0xfd4326(0x122)][_0xfd4326(0x75)](_0x2e0fe6));if(!_0x36cad7||_0xfd4326(0x1aa)==_0x36cad7[_0xfd4326(0x86)][_0xfd4326(0x19c)][_0xfd4326(0x188)])return void _0x211458[_0xfd4326(0xbe)](_0x5f1038=>_0xa65adf[_0xfd4326(0xcd)](_0x5f1038,_0xfd4326(0x11d)));_0x211458[_0xfd4326(0xbe)](_0x21fa3c=>_0xa65adf[_0xfd4326(0xcd)](_0x21fa3c,_0xfd4326(0x1b2)));const _0x23ec33=_0x58de2c({'editor':_0x4dc5af,'reply':_0xa65adf,'interaction':_0x312d0c,'groups':_0x45eb0d,'transform':!0x0,'documentCompare':_0x33d3ee,'documentCompareOptions':{'anchor':_0xfd4326(0x190),'markDeletions':!0x0}});let _0x43b986;_0x36cad7&&this[_0xfd4326(0x1da)](_0x36cad7[_0xfd4326(0x86)]),_0x4dc5af[_0xfd4326(0x19a)][_0xfd4326(0x14e)](_0x290941=>{const _0x17ea79=_0xfd4326;_0x43b986=_0x290941[_0x17ea79(0x1eb)],_0x4dc5af[_0x17ea79(0x8f)][_0x17ea79(0x11a)](_0x17ea79(0x194))[_0x17ea79(0x16f)](_0x23ec33),this[_0x17ea79(0xf0)][_0x17ea79(0xa0)](_0x17ea79(0x1ad));}),this[_0xfd4326(0xbb)][_0xfd4326(0x1b3)](_0x43b986,{'interactionId':_0x312d0c['id'],'replyId':_0xa65adf['id'],'indexes':_0x211458[_0xfd4326(0x12e)]()}),this[_0xfd4326(0x8b)](_0xa65adf);}[_0x12f486(0x18f)](_0x22f3ae){const _0x1a54bd=_0x12f486,_0x2b4987=_0x4b9b70(this[_0x1a54bd(0x1ac)]),_0x5b34a9=this[_0x1a54bd(0x1ac)][_0x1a54bd(0x8f)][_0x1a54bd(0x11a)](_0x41a947),{reply:_0x1edfe4,interaction:_0x58ec33}=this[_0x1a54bd(0x137)](_0x22f3ae[_0x1a54bd(0x79)]),_0x4f5cee=this[_0x1a54bd(0x1a6)](_0x22f3ae[_0x1a54bd(0x79)],_0x22f3ae[_0x1a54bd(0x152)]),_0x435d12=void 0x0!==_0x22f3ae[_0x1a54bd(0x152)]?[_0x1edfe4[_0x1a54bd(0x122)][_0x22f3ae[_0x1a54bd(0x152)]]]:_0x1edfe4[_0x1a54bd(0x122)][_0x1a54bd(0x10a)](_0x918551=>_0x1a54bd(0x102)==_0x918551[_0x1a54bd(0x6d)]),_0x5efc18=_0x435d12[_0x1a54bd(0x1d1)](_0x47d412=>_0x1edfe4[_0x1a54bd(0x122)][_0x1a54bd(0x75)](_0x47d412));if(!_0x4f5cee||_0x1a54bd(0x1aa)==_0x4f5cee[_0x1a54bd(0x86)][_0x1a54bd(0x19c)][_0x1a54bd(0x188)])return void _0x5efc18[_0x1a54bd(0xbe)](_0x3e802d=>_0x1edfe4[_0x1a54bd(0xcd)](_0x3e802d,_0x1a54bd(0x11d)));_0x5efc18[_0x1a54bd(0xbe)](_0x1d2cdc=>_0x1edfe4[_0x1a54bd(0xcd)](_0x1d2cdc,_0x1a54bd(0x1b2)));const _0xeb5e3b=_0x58de2c({'editor':_0x2b4987,'reply':_0x1edfe4,'interaction':_0x58ec33,'groups':_0x435d12,'transform':!0x0,'documentCompare':_0x5b34a9,'documentCompareOptions':{'anchor':_0x1a54bd(0x190),'markDeletions':!0x1}});let _0x6cb429;_0x4f5cee&&this[_0x1a54bd(0x1da)](_0x4f5cee[_0x1a54bd(0x86)]),_0x2b4987[_0x1a54bd(0x19a)][_0x1a54bd(0x14e)](_0x32685f=>{const _0xe06463=_0x1a54bd;_0x6cb429=_0x32685f[_0xe06463(0x1eb)];for(const _0x57c3cd of _0xeb5e3b)_0x57c3cd[_0xe06463(0xfc)]=_0x2b4987[_0xe06463(0x19a)][_0xe06463(0x7b)][_0xe06463(0x1c4)],_0x366e90(_0x2b4987,_0x57c3cd),_0x32685f[_0xe06463(0x1eb)][_0xe06463(0x1d3)](_0x57c3cd),_0x2b4987[_0xe06463(0x19a)][_0xe06463(0xa9)](_0x57c3cd);}),this[_0x1a54bd(0xbb)][_0x1a54bd(0x1b3)](_0x6cb429,{'interactionId':_0x58ec33['id'],'replyId':_0x1edfe4['id'],'indexes':_0x5efc18[_0x1a54bd(0x12e)]()}),this[_0x1a54bd(0x8b)](_0x1edfe4);}[_0x12f486(0xdb)](_0x184437){const _0x23c35f=_0x12f486,{reply:_0x467f13}=this[_0x23c35f(0x137)](_0x184437[_0x23c35f(0x79)]);_0x467f13[_0x23c35f(0xcd)](_0x184437[_0x23c35f(0x152)],_0x23c35f(0x108));}[_0x12f486(0x168)](_0x1cb438,_0x356f63){const _0xd0de7=_0x12f486;if(!this[_0xd0de7(0x144)])return;const {reply:_0x2bb636}=this[_0xd0de7(0x137)](_0x1cb438),_0x340a0f=_0x2bb636[_0xd0de7(0xc6)]({'showDiff':this[_0xd0de7(0x136)]});let _0x54a150,_0x45e06c;if(void 0x0!==_0x356f63?(_0x45e06c=_0x340a0f[_0xd0de7(0x186)](_0x12b688=>_0x12b688[_0xd0de7(0x1ab)]==_0x356f63),_0x54a150=_0x45e06c?.[_0xd0de7(0x1ab)]):(_0x45e06c=_0x340a0f[0x0],_0x54a150=_0x45e06c[_0xd0de7(0x1ab)]),this[_0xd0de7(0xd9)]?.[_0xd0de7(0x79)]==_0x1cb438&&this[_0xd0de7(0xd9)]?.[_0xd0de7(0x152)]==_0x54a150)return;const _0x2d37c0=this[_0xd0de7(0xd7)](_0x1cb438,_0x2bb636,_0x45e06c);if(!_0x2d37c0)return void this[_0xd0de7(0x144)][_0xd0de7(0x18d)]();this[_0xd0de7(0xd9)]={'replyId':_0x1cb438,'partIndex':_0x54a150},this[_0xd0de7(0x1da)](_0x2d37c0,!0x0);const _0xc41e9b=this[_0xd0de7(0x71)](_0x1cb438,_0x54a150,_0xd0de7(0x1f7));this[_0xd0de7(0x144)][_0xd0de7(0x1f6)]({'part':_0x45e06c,'renderingStrategy':_0xd0de7(0x10e)}),this[_0xd0de7(0x144)][_0xd0de7(0x1a0)]({'index':_0x54a150,'title':_0x541ff7(this[_0xd0de7(0x1ac)][_0xd0de7(0xbf)],_0xd0de7(0xdf),(_0x54a150+0x1)[_0xd0de7(0x1dc)]()),'showRotator':null!==_0xc41e9b,'ranges':[_0x2d37c0],'areActionsDisabled':_0x2bb636[_0xd0de7(0xa5)]}),this[_0xd0de7(0x144)][_0xd0de7(0xf9)](_0xd0de7(0x102)),this[_0xd0de7(0xef)][_0xd0de7(0x13c)](_0x1cb438,_0x54a150),this[_0xd0de7(0xef)][_0xd0de7(0x85)]({'id':_0x1cb438,'index':_0x54a150,'isActive':!0x0});}[_0x12f486(0x71)](_0x11654d,_0x32bcb8,_0xe115c6){const _0x48c3d0=_0x12f486,{reply:_0x99aff1}=this[_0x48c3d0(0x137)](_0x11654d),_0x3b2501=_0x99aff1[_0x48c3d0(0xc6)]({'showDiff':this[_0x48c3d0(0x136)]});if(0x1==_0x3b2501[_0x48c3d0(0x84)])return null;const _0x1dbb90=_0x3b2501[_0x48c3d0(0x176)](_0x50c627=>_0x50c627[_0x48c3d0(0x1ab)]==_0x32bcb8),_0x21a045=_0x48c3d0(0x1f7)==_0xe115c6?0x1:-0x1;let _0x2d61d1=_0x3b2501['at']((_0x1dbb90+_0x21a045)%_0x3b2501[_0x48c3d0(0x84)])[_0x48c3d0(0x1ab)],_0x40012f=_0x3b2501[_0x2d61d1];for(;!this[_0x48c3d0(0xd7)](_0x11654d,_0x99aff1,_0x40012f);){if(_0x2d61d1=_0x3b2501['at']((_0x2d61d1+_0x21a045)%_0x3b2501[_0x48c3d0(0x84)])[_0x48c3d0(0x1ab)],_0x2d61d1===_0x1dbb90)return null;_0x40012f=_0x3b2501[_0x2d61d1];}return _0x2d61d1;}[_0x12f486(0xd7)](_0x15014a,_0x1a29ef,_0x19b613){const _0x123598=_0x12f486,_0x1395b4=_0x1a29ef[_0x123598(0x122)];if(!_0x19b613[_0x123598(0x181)])return null;const _0x1180df=_0x1395b4[_0x123598(0x186)](_0x37020e=>_0x37020e[_0x123598(0x1ab)]==_0x19b613[_0x123598(0x1ab)]);if(_0x123598(0x102)!==_0x1180df?.[_0x123598(0x6d)])return null;const _0x30dd03=this[_0x123598(0x1a6)](_0x15014a,_0x19b613[_0x123598(0x1ab)]);if(!_0x30dd03)return null;const {range:_0x33c880,currentIndex:_0x210f55}=_0x30dd03;return _0x123598(0x1aa)==_0x33c880[_0x123598(0x19c)][_0x123598(0x188)]?(_0x1a29ef[_0x123598(0xcd)](_0x210f55,_0x123598(0x11d)),null):_0x30dd03[_0x123598(0x86)];}[_0x12f486(0x1a6)](_0x3b3573,_0x10173e){const _0x255021=_0x12f486,_0x439c5f=_0x4b9b70(this[_0x255021(0x1ac)]),{reply:_0x401849,interaction:_0x48e03d}=this[_0x255021(0x137)](_0x3b3573),_0x1327cc=_0x401849[_0x255021(0x122)][_0x255021(0x10a)](_0x4820ef=>_0x255021(0x102)==_0x4820ef[_0x255021(0x6d)]),_0x5456e2=_0x1327cc[_0x255021(0x1d1)](_0x4872e7=>_0x401849[_0x255021(0x122)][_0x255021(0x75)](_0x4872e7));void 0x0===_0x10173e&&(_0x10173e=_0x5456e2[0x0]);const _0x2c5a6a=_0x5456e2[_0x255021(0x75)](_0x10173e);if(-0x1==_0x2c5a6a)return null;const _0x4d7819=_0x1327cc[_0x2c5a6a],_0x319692=new _0x8e65d3([]),_0x55b9ae=new _0x8e65d3([]);for(const _0x2a7b16 of _0x4d7819[_0x255021(0xea)])if(_0x255021(0x107)!=_0x2a7b16[_0x255021(0x1be)]&&_0x55b9ae[_0x255021(0xc3)][_0x255021(0xdd)](_0x2a7b16[_0x255021(0x11f)][_0x255021(0x193)](!0x0)),_0x255021(0x18b)!=_0x2a7b16[_0x255021(0x1be)]){const _0x3e06a0=_0xd10b12(_0x5e682a=>_0xa01188(_0x5e682a,_0x255021(0x1c1))==_0x2a7b16['id'],_0x401849[_0x255021(0x1b0)],!0x0);_0x319692[_0x255021(0xc3)][_0x255021(0xdd)](_0x3e06a0[_0x255021(0x193)](!0x0));}if(0x0==_0x319692[_0x255021(0xc3)][_0x255021(0x84)]){if(_0x4d7819[_0x255021(0xea)][0x0][_0x255021(0xd8)]){const _0x2de812=_0x2b1db6(_0x255021(0x1c1),_0x4d7819[_0x255021(0xea)][0x0][_0x255021(0xd8)],_0x401849[_0x255021(0x1b0)]);_0x319692[_0x255021(0xc3)][_0x255021(0x139)](_0x2de812[_0x255021(0x193)](!0x0)),_0x55b9ae[_0x255021(0xc3)][_0x255021(0x139)](_0x2de812[_0x255021(0x193)](!0x0)),_0x2de812[_0x255021(0x14b)]&&(_0x319692[_0x255021(0xc3)][_0x255021(0xdd)](_0x2de812[_0x255021(0x14b)][_0x255021(0x193)](!0x0)),_0x55b9ae[_0x255021(0xc3)][_0x255021(0xdd)](_0x2de812[_0x255021(0x14b)][_0x255021(0x193)](!0x0)));}else{const _0x1531cb=_0x401849[_0x255021(0x1b0)][_0x255021(0xc3)][0x0];if(!_0x1531cb)return null;_0x319692[_0x255021(0xc3)][_0x255021(0xdd)](_0x1531cb[_0x255021(0x193)](!0x0)),_0x55b9ae[_0x255021(0xc3)][_0x255021(0xdd)](_0x1531cb[_0x255021(0x193)](!0x0));}}const _0x420e24=_0x48e03d[_0x255021(0x117)](),_0x53a6f5=_0x439c5f[_0x255021(0x1c6)][_0x255021(0x1e9)](_0x420e24[_0x255021(0x1bd)]),_0x419a89=_0x52f5de(_0x319692),_0x16c708=_0x439c5f[_0x255021(0x1c6)][_0x255021(0x1e9)](_0x419a89),_0x414649=_0x439c5f[_0x255021(0x1c6)][_0x255021(0x1e9)](_0x419a89),_0x527068=_0x439c5f[_0x255021(0x19a)][_0x255021(0x13b)](_0x16c708,0x0),_0x53009d=_0x52f5de(_0x55b9ae),_0x1042e5={'anchor':_0x527068,'markDeletions':!0x1},_0x4cecbd=_0x439c5f[_0x255021(0x8f)][_0x255021(0x11a)](_0x41a947)[_0x255021(0x159)](_0x419a89,_0x53009d,_0x1042e5)[_0x255021(0xe1)]();if(!_0x4cecbd[_0x255021(0x84)])return null;_0x439c5f[_0x255021(0x19a)][_0x255021(0x14e)](_0x4402d5=>{const _0xbbca87=_0x255021;for(const _0x45ce03 of _0x4cecbd)if(_0xbbca87(0x8c)==_0x45ce03[_0xbbca87(0x1be)]){const _0x29dded=_0x45ce03[_0xbbca87(0x10b)],_0xefe669=_0x45ce03[_0xbbca87(0x1ee)],_0x2adf78=new _0x1604bc(_0x29dded,_0xefe669);_0x4402d5[_0xbbca87(0x1eb)][_0xbbca87(0x1d3)](_0x2adf78),_0x439c5f[_0xbbca87(0x19a)][_0xbbca87(0xa9)](_0x2adf78);}else _0xbbca87(0x8d)!==_0x45ce03[_0xbbca87(0x1be)]&&(_0x45ce03[_0xbbca87(0xfc)]=null,_0x45ce03[_0xbbca87(0x1d9)]=!0x1,_0x4402d5[_0xbbca87(0x1eb)][_0xbbca87(0x1d3)](_0x45ce03),_0x439c5f[_0xbbca87(0x19a)][_0xbbca87(0xa9)](_0x45ce03));});const _0x47af60=_0x572c78(_0x439c5f,_0x4cecbd,_0x16c708);_0x52bea3(_0x439c5f[_0x255021(0x19a)],_0x47af60);const _0x2dfeb4=_0x47af60[_0x255021(0x1b4)]()[_0x255021(0x9a)][_0x255021(0x1e2)][_0x255021(0x12e)](),_0x2fc32c=_0x47af60[_0x255021(0x1b4)]()[_0x255021(0x14d)][_0x255021(0x1e2)][_0x255021(0x12e)](),_0x6f1d01=[];let _0x3bab61=_0x16c708,_0x562844=_0x414649;for(let _0x57a858=0x0;_0x57a858<_0x2fc32c[_0x255021(0x84)];_0x57a858++){const _0x3ba85=_0x3bab61[_0x255021(0x18c)]-_0x2fc32c[_0x57a858];_0x6f1d01[_0x57a858]=_0x562844[_0x255021(0x18c)]-_0x3ba85,_0x3bab61=_0x3bab61[_0x255021(0x1af)](_0x2fc32c[_0x57a858]),_0x562844=_0x562844[_0x255021(0x1af)](_0x6f1d01[_0x57a858]);}const _0x7e705f=_0x439c5f[_0x255021(0x19a)][_0x255021(0xe9)](_0x439c5f[_0x255021(0x19a)][_0x255021(0x184)](_0x414649,_0x2dfeb4),_0x439c5f[_0x255021(0x19a)][_0x255021(0x184)](_0x414649,_0x6f1d01)),_0x3d7af3=_0x414649[_0x255021(0x16e)](0x0)[_0x255021(0x162)](_0xdc6d4f),_0x5215e5=Array[_0x255021(0xda)](_0x53a6f5[_0x255021(0x1e6)]())[_0x255021(0x186)](_0x1b4e2e=>_0x1b4e2e[_0x255021(0x162)](_0xdc6d4f)==_0x3d7af3)[_0x255021(0x158)](),_0x579dfc=_0x7e705f[_0x255021(0x9a)][_0x255021(0x1e2)][_0x255021(0x12e)](),_0x127d6e=_0x7e705f[_0x255021(0x14d)][_0x255021(0x1e2)][_0x255021(0x12e)]();_0x579dfc[0x0]=_0x5215e5[0x0]+_0x579dfc[0x0],_0x127d6e[0x0]=_0x5215e5[0x0]+_0x127d6e[0x0];let _0x298940=_0x439c5f[_0x255021(0x19a)][_0x255021(0xe9)](_0x439c5f[_0x255021(0x19a)][_0x255021(0x184)](_0x439c5f[_0x255021(0x19a)][_0x255021(0x7b)][_0x255021(0xfe)](),_0x579dfc),_0x439c5f[_0x255021(0x19a)][_0x255021(0x184)](_0x439c5f[_0x255021(0x19a)][_0x255021(0x7b)][_0x255021(0xfe)](),_0x127d6e));const _0xd5d8de=_0x439c5f[_0x255021(0x19a)][_0x255021(0x7b)][_0x255021(0x72)][_0x255021(0xe1)](_0x420e24[_0x255021(0x1c4)]);for(const _0x1aad67 of _0xd5d8de)_0x298940=_0x1ca952[_0x255021(0x17c)](_0x298940[_0x255021(0x1e4)](_0x1aad67));return{'range':_0x298940,'currentIndex':_0x10173e};}[_0x12f486(0x7e)](_0x2a2496){const _0x34d6e2=_0x12f486;if(!_0x2a2496[_0x34d6e2(0x8f)][_0x34d6e2(0x9e)](_0x34d6e2(0x19d)))return;const _0xa7923a=_0x2a2496[_0x34d6e2(0x82)][_0x34d6e2(0x11a)](_0x34d6e2(0x128)),_0x439b46=_0x2a2496[_0x34d6e2(0x82)][_0x34d6e2(0x11a)](_0x34d6e2(0x1a9));this[_0x34d6e2(0x1ae)](_0xa7923a,_0x34d6e2(0x1de),(_0x154fae,_0x30a94e,_0x452b90)=>{const _0x785b1d=_0x34d6e2,_0x1ff3c3=this[_0x785b1d(0xbb)][_0x785b1d(0x11a)](_0x30a94e);if(!_0x1ff3c3)return;const _0x1b2866=this[_0x785b1d(0x120)][_0x785b1d(0x7c)](_0x1ff3c3[_0x785b1d(0x1e0)])[_0x785b1d(0x1b5)](_0x1ff3c3[_0x785b1d(0x79)]);_0x1ff3c3[_0x785b1d(0xba)][_0x785b1d(0xbe)](_0x32eb98=>_0x1b2866[_0x785b1d(0xcd)](_0x32eb98,_0x785b1d(0x102))),this[_0x785b1d(0xbb)][_0x785b1d(0x195)](_0x30a94e),this[_0x785b1d(0xbb)][_0x785b1d(0x1b3)](_0x452b90,_0x1ff3c3);}),this[_0x34d6e2(0x1ae)](_0x439b46,_0x34d6e2(0x1de),(_0x41fa79,_0x445968,_0xfd1f94)=>{const _0x85955f=_0x34d6e2,_0x48157f=this[_0x85955f(0xbb)][_0x85955f(0x11a)](_0x445968);if(!_0x48157f)return;const _0x3c32dd=this[_0x85955f(0x120)][_0x85955f(0x7c)](_0x48157f[_0x85955f(0x1e0)])[_0x85955f(0x1b5)](_0x48157f[_0x85955f(0x79)]);_0x48157f[_0x85955f(0xba)][_0x85955f(0xbe)](_0x47ec15=>_0x3c32dd[_0x85955f(0xcd)](_0x47ec15,_0x85955f(0x1b2))),this[_0x85955f(0xbb)][_0x85955f(0x195)](_0x445968),this[_0x85955f(0xbb)][_0x85955f(0x1b3)](_0xfd1f94,_0x48157f);});}async[_0x12f486(0x156)](_0x2c3a65){const _0x24969d=_0x12f486;this[_0x24969d(0x1ac)][_0x24969d(0x8f)][_0x24969d(0x9e)](_0x24969d(0x1cf))&&this[_0x24969d(0x1ac)][_0x24969d(0x8f)][_0x24969d(0x11a)](_0x24969d(0x1cf))[_0x24969d(0x18d)](),(this[_0x24969d(0x1ac)][_0x24969d(0x8f)][_0x24969d(0x11a)](_0x575159)[_0x24969d(0xff)][_0x24969d(0x16c)](_0x24969d(0xe7)),this[_0x24969d(0xef)][_0x24969d(0x185)](_0x24969d(0x10e)),this[_0x24969d(0xef)][_0x24969d(0x12d)](!0x0),await this[_0x24969d(0x1f3)]());try{await this[_0x24969d(0x175)][_0x24969d(0xdc)](_0x2c3a65)[_0x24969d(0x113)](),await this[_0x24969d(0x9b)](_0x2c3a65),this[_0x24969d(0x1cd)]('\x20'),await this[_0x24969d(0x120)][_0x24969d(0x14f)](_0x2c3a65,this[_0x24969d(0xf0)][_0x24969d(0x87)]),this[_0x24969d(0x120)][_0x24969d(0xd5)]()&&this[_0x24969d(0x1ec)]();}catch(_0x236fa9){this[_0x24969d(0xef)][_0x24969d(0x173)]({'errorMessage':_0x541ff7(this[_0x24969d(0x1ac)][_0x24969d(0xbf)],_0x24969d(0x17d)),'id':_0x2c3a65}),this[_0x24969d(0x145)](new _0x4b2b76(_0x24969d(0x103),this,{'error':_0x236fa9}));}finally{this[_0x24969d(0xef)][_0x24969d(0x17a)](),this[_0x24969d(0xef)][_0x24969d(0x185)](_0x24969d(0x197)),this[_0x24969d(0xef)][_0x24969d(0x12d)](!0x1);}}async[_0x12f486(0xaa)](){const _0x476a3d=_0x12f486,_0x519c79=this[_0x476a3d(0x175)][_0x476a3d(0xfb)](this[_0x476a3d(0xe4)](),{'limit':0x1,'sortBy':_0x476a3d(0x1cc)});try{const _0x35ba80=await _0x519c79[_0x476a3d(0x1d8)]();return _0x35ba80[_0x476a3d(0x84)]?_0x35ba80[0x0]['id']:_0x476a3d(0x18b);}catch(_0x2a4274){return this[_0x476a3d(0xef)][_0x476a3d(0x173)]({'errorMessage':_0x541ff7(this[_0x476a3d(0x1ac)][_0x476a3d(0xbf)],_0x476a3d(0x17d)),'id':_0x14d190()}),this[_0x476a3d(0x145)](new _0x4b2b76(_0x476a3d(0x1b6),this,{'error':_0x2a4274})),this[_0x476a3d(0xef)][_0x476a3d(0x12d)](!0x1),this[_0x476a3d(0xef)][_0x476a3d(0xa2)](),null;}}[_0x12f486(0x1dd)](_0xdbff9b){const _0x4aa16e=_0x12f486;this[_0x4aa16e(0x120)]['id']===_0xdbff9b&&this[_0x4aa16e(0x9b)]();}[_0x12f486(0x1ec)](){const _0x4bc248=_0x12f486;this[_0x4bc248(0x120)]?.[_0x4bc248(0x70)](_0x541ff7(this[_0x4bc248(0x1ac)][_0x4bc248(0xbf)],_0x4bc248(0xd3)));}async[_0x12f486(0x129)](){const _0x1c0804=_0x12f486,_0xdf1bb2=this[_0x1c0804(0xf0)][_0x1c0804(0x170)]();this[_0x1c0804(0x120)]?.[_0x1c0804(0x88)](_0xdf1bb2),this[_0x1c0804(0x1ec)]();}[_0x12f486(0x165)](){const _0x4d45b7=_0x12f486;this[_0x4d45b7(0x120)]?.[_0x4d45b7(0x13e)]();}[_0x12f486(0x132)](){const _0x170816=_0x12f486;this[_0x170816(0xef)][_0x170816(0x132)]();}async[_0x12f486(0x167)](){const _0x28afb5=_0x12f486;await this[_0x28afb5(0x9b)]();}async[_0x12f486(0x142)]({message:_0x199b34,attributes:_0x52e314}){const _0x5580c6=_0x12f486;await this[_0x5580c6(0x106)]({'userMessage':_0x199b34,'attributes':_0x52e314});}[_0x12f486(0xe4)](){const _0x5d49dc=_0x12f486,_0x4d3556=this[_0x5d49dc(0x1ac)][_0x5d49dc(0xc9)][_0x5d49dc(0x11a)](_0x5d49dc(0x7a));if(!_0x4d3556)throw new _0x4b2b76(_0x5d49dc(0x1c8),this);return _0x4d3556;}async[_0x12f486(0x9b)](_0x7c8731){const _0x5b7549=_0x12f486;try{this[_0x5b7549(0xef)][_0x5b7549(0x15f)](),await this[_0x5b7549(0xe8)](_0x7c8731);}catch(_0xc78bdf){this[_0x5b7549(0xef)][_0x5b7549(0x173)]({'errorMessage':_0x541ff7(this[_0x5b7549(0x1ac)][_0x5b7549(0xbf)],_0x5b7549(0x1bf)),'id':_0x7c8731||_0x14d190()}),console[_0x5b7549(0x1f2)](_0xc78bdf),this[_0x5b7549(0x120)]=void 0x0,this[_0x5b7549(0xef)][_0x5b7549(0xa2)]();}}async[_0x12f486(0xe8)](_0x2d8c44){const _0x1d59e0=_0x12f486;let _0x2ce41e;this[_0x1d59e0(0x1ac)][_0x1d59e0(0x8f)][_0x1d59e0(0x9e)](_0x1d59e0(0x1cf))&&this[_0x1d59e0(0x1ac)][_0x1d59e0(0x8f)][_0x1d59e0(0x11a)](_0x1d59e0(0x1cf))[_0x1d59e0(0x18d)](),_0x2d8c44||!this[_0x1d59e0(0x120)]?_0x2ce41e=this[_0x1d59e0(0x1ac)][_0x1d59e0(0xc9)][_0x1d59e0(0x11a)](_0x1d59e0(0x121)):this[_0x1d59e0(0xef)][_0x1d59e0(0x177)]&&(_0x2ce41e=this[_0x1d59e0(0x120)][_0x1d59e0(0xa1)]['id']),await this[_0x1d59e0(0x1f3)]();const _0x115d26=this[_0x1d59e0(0xe4)](),_0x2ab835=_0x2d8c44||_0x14d190();this[_0x1d59e0(0x120)]=new _0x2fc456({'connector':this[_0x1d59e0(0x175)],'chatModels':this[_0x1d59e0(0x1a2)],'selectedModelId':_0x2ce41e,'conversationId':_0x2ab835,'group':_0x115d26,'getEditor':()=>_0x4b9b70(this[_0x1d59e0(0x1ac)]),'isFromHistory':!!_0x2d8c44}),this[_0x1d59e0(0x120)][_0x1d59e0(0x16a)](_0x1d59e0(0x180),_0x1d59e0(0x105))['to'](this),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0xe2),(_0x207f60,_0x3c932a)=>{const _0xcb238b=_0x1d59e0;this[_0xcb238b(0xef)][_0xcb238b(0xce)](_0x3c932a),this[_0xcb238b(0xef)][_0xcb238b(0x1f0)](),this[_0xcb238b(0xef)][_0xcb238b(0x1ea)](),this[_0xcb238b(0xef)][_0xcb238b(0x1a5)](),_0x2d8c44||(this[_0xcb238b(0xef)][_0xcb238b(0x6c)](),this[_0xcb238b(0x1ec)]());}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x92),(_0x4921c2,_0x14b799)=>{const _0x4444a3=_0x1d59e0;this[_0x4444a3(0xef)][_0x4444a3(0x19b)](_0x14b799[_0x4444a3(0x199)]);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x78),(_0x5ee57d,_0x2fa841)=>{const _0x1dcfd4=_0x1d59e0;this[_0x1dcfd4(0xef)][_0x1dcfd4(0x1e1)](_0x2fa841);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x1c3),()=>{const _0xa93082=_0x1d59e0,_0x54114c=this[_0xa93082(0xef)][_0xa93082(0xa8)]({'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});this[_0xa93082(0xef)][_0xa93082(0x1f4)](_0x54114c);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x14c),()=>{const _0x26ed79=_0x1d59e0,_0x15739a=this[_0x26ed79(0xef)][_0x26ed79(0xa8)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});this[_0x26ed79(0xef)][_0x26ed79(0x1f4)](_0x15739a);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x17e),(_0x27a643,_0x36d3ba)=>{const _0x4296d0=_0x1d59e0;this[_0x4296d0(0xef)][_0x4296d0(0xca)](_0x36d3ba,{'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x196),(_0x420333,_0xe81147)=>{const _0x290a5e=_0x1d59e0;this[_0x290a5e(0xef)][_0x290a5e(0xca)](_0xe81147,{'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x105),()=>{const _0x32af26=_0x1d59e0;this[_0x32af26(0xef)][_0x32af26(0x12b)]();}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0xab),async()=>{const _0x23b089=_0x1d59e0;await this[_0x23b089(0xef)][_0x23b089(0x12f)]();}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x10c),(_0x48d4a0,_0x8fcf5a)=>{const _0x26f276=_0x1d59e0;this[_0x26f276(0xef)][_0x26f276(0x13d)](_0x8fcf5a['id']);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x161),(_0x52ce72,_0x24bed9,_0x51af18)=>{const _0x17cb2a=_0x1d59e0;this[_0x17cb2a(0x1cd)](_0x24bed9,_0x51af18);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x140),(_0x34e583,_0x225350)=>{const _0x5e950f=_0x1d59e0;_0x5e950f(0x89)===_0x225350[_0x5e950f(0x1be)]?this[_0x5e950f(0xef)][_0x5e950f(0x12c)](_0x225350):this[_0x5e950f(0xef)][_0x5e950f(0x169)](_0x225350);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x1d4),async(_0x4efdbe,_0x1281e4)=>{const _0x384841=_0x1d59e0;await this[_0x384841(0x148)]({'reply':_0x1281e4});}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x1c5),(_0x3d0826,{reply:_0x15a3b0,index:_0x365d6a,state:_0xc1736e})=>{const _0x40a092=_0x1d59e0;this[_0x40a092(0xef)][_0x40a092(0xbd)]({'id':_0x15a3b0['id'],'index':_0x365d6a,'state':_0xc1736e}),this[_0x40a092(0xd9)]?.[_0x40a092(0x79)][_0x40a092(0x1b9)](_0x15a3b0['id'])&&this[_0x40a092(0xd9)]?.[_0x40a092(0x152)]==_0x365d6a&&this[_0x40a092(0x144)]?.[_0x40a092(0xf9)](_0xc1736e);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0xa7),(_0x14c886,_0x21abac)=>{const _0x42c4e6=_0x1d59e0;if(this[_0x42c4e6(0xef)][_0x42c4e6(0xec)](_0x21abac[_0x42c4e6(0xf5)],_0x21abac[_0x42c4e6(0x1ca)]),_0x42c4e6(0x119)===_0x21abac[_0x42c4e6(0xf5)][_0x42c4e6(0x1be)]){const _0x1f6824=[..._0x4b9b70(this[_0x42c4e6(0x1ac)])[_0x42c4e6(0x19a)][_0x42c4e6(0x7b)][_0x42c4e6(0x119)][_0x42c4e6(0x10f)]()];this[_0x42c4e6(0xf0)][_0x42c4e6(0x1ed)](_0x1f6824,_0x42c4e6(0x14a)+this[_0x42c4e6(0x120)]?.['id']);}}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x10d),(_0x3cf9dc,_0x4f0aeb)=>{const _0xd2094a=_0x1d59e0;this[_0xd2094a(0xef)][_0xd2094a(0x109)](_0x4f0aeb[_0xd2094a(0x9f)]),_0xd2094a(0x149)==_0x4f0aeb[_0xd2094a(0x9f)]&&this[_0xd2094a(0x165)](),_0xd2094a(0x119)===_0x4f0aeb[_0xd2094a(0x1be)]&&this[_0xd2094a(0xf0)][_0xd2094a(0xa0)](_0xd2094a(0x14a)+this[_0xd2094a(0x120)]?.['id']);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x13a),(_0x54fc61,_0x5c4dd)=>{const _0x127022=_0x1d59e0;this[_0x127022(0xef)][_0x127022(0x6b)](_0x5c4dd[_0x127022(0xf5)][_0x127022(0x9f)],_0x5c4dd[_0x127022(0x1ca)]);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0xde),(_0x5a11e3,_0x4a66ca)=>{const _0x48f590=_0x1d59e0;this[_0x48f590(0xef)][_0x48f590(0x104)](_0x4a66ca[_0x48f590(0xfd)]);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x1db),(_0x520ecf,_0x19c8bc)=>{const _0x1297a8=_0x1d59e0;this[_0x1297a8(0xef)][_0x1297a8(0x97)](_0x19c8bc[_0x1297a8(0xee)]);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0xbc),(_0x25b6d6,_0x30b088)=>{const _0x4f6365=_0x1d59e0;this[_0x4f6365(0xef)][_0x4f6365(0x1d7)](_0x30b088[_0x4f6365(0x11b)],_0x30b088[_0x4f6365(0x164)],_0x30b088[_0x4f6365(0x99)],_0x30b088[_0x4f6365(0xfa)]);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x81),(_0x441e89,_0x552cf7)=>{const _0x1e07d2=_0x1d59e0;this[_0x1e07d2(0xef)][_0x1e07d2(0x1ef)](_0x552cf7[_0x1e07d2(0x11b)],_0x552cf7[_0x1e07d2(0x19f)],_0x552cf7[_0x1e07d2(0x150)]);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x1c9),(_0xfb5aa5,_0x378fd4)=>{const _0x2433bf=_0x1d59e0;this[_0x2433bf(0xef)][_0x2433bf(0xd6)](_0x378fd4);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x83),async(_0x4028f1,_0x16b1aa)=>{const _0x3b54c6=_0x1d59e0,_0x5e279d=(await this[_0x3b54c6(0x1a2)][_0x3b54c6(0x74)]())[_0x3b54c6(0x186)](_0x15af02=>_0x15af02['id']===_0x16b1aa[_0x3b54c6(0xa1)]?.['id'])||null;this[_0x3b54c6(0xef)][_0x3b54c6(0x1d0)](_0x5e279d,_0x16b1aa[_0x3b54c6(0xd2)]);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x1f2),(_0x2e2053,{error:_0x342019,interactionId:_0x233989,fileName:_0x23b837,url:_0x4f2192,sourceId:_0x10b14a,sourceLabel:_0x90e268})=>{const _0x547729=_0x1d59e0,_0x2ee824=_0x233989?_0x233989+':'+_0x14d190():_0x14d190();_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x130))?this[_0x547729(0xef)][_0x547729(0xc8)]({'staticMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x93)),'id':_0x2ee824}):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x1b6))||_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x9d))?(this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x1bf)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019)):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0xb9))?this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x198),_0x23b837),'id':_0x2ee824}):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x189))?this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x80),_0x4f2192),'id':_0x2ee824}):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x1b7))?this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x125)),'id':_0x2ee824}):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x1cb))?this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0xed)),'id':_0x2ee824}):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x1a4))?(_0x10b14a&&this[_0x547729(0xef)][_0x547729(0x123)](_0x10b14a),this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x9c),_0x90e268||_0x547729(0x164)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019)):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x135))?(this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x15d)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019)):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x1a1))?(this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0xd4)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019)):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x1e3))?(this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x1d6)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019)):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x110))?(this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x16d)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019)):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0xaf))?(this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0xb8)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019)):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x1bc))?(this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x11e)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019)):(this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x131)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019));}),await this[_0x1d59e0(0x120)][_0x1d59e0(0xb4)](this[_0x1d59e0(0x1ac)][_0x1d59e0(0xc9)][_0x1d59e0(0x11a)](_0x1d59e0(0x7d))),_0x2d8c44||await this[_0x1d59e0(0x120)][_0x1d59e0(0x9a)]();}async[_0x12f486(0x106)]({userMessage:_0x474d71,attributes:_0x5a0dc9}){const _0x15fb2f=_0x12f486;if(!this[_0x15fb2f(0x120)])throw new _0x4b2b76(_0x15fb2f(0xf8));if(this[_0x15fb2f(0x120)][_0x15fb2f(0x178)]()){const _0x3b9b61=await this[_0x15fb2f(0xf0)][_0x15fb2f(0xd1)]();await this[_0x15fb2f(0x120)][_0x15fb2f(0xf1)](_0x3b9b61);}this[_0x15fb2f(0x120)]['id']&&this[_0x15fb2f(0x120)][_0x15fb2f(0x1ce)]&&await this[_0x15fb2f(0x120)][_0x15fb2f(0xf6)]({'userMessage':_0x474d71,'attributes':_0x5a0dc9});}[_0x12f486(0x100)](){const _0x1aa1db=_0x12f486;console[_0x1aa1db(0x6e)](_0x1aa1db(0x153));}[_0x12f486(0x191)](_0xd722fc){const _0x201daf=_0x12f486;this[_0x201daf(0xef)][_0x201daf(0x112)](_0xd722fc);}[_0x12f486(0x145)](_0x18ca84){const _0x1c2f54=_0x12f486;_0x5319e8(_0x18ca84[_0x1c2f54(0x1df)]);}[_0x12f486(0x1f5)](_0x317741){const _0x431bca=_0x12f486;this[_0x431bca(0x120)]?.[_0x431bca(0x1a7)](_0x317741);}[_0x12f486(0xe6)](){const _0x55ad82=_0x12f486;this[_0x55ad82(0x120)]?.[_0x55ad82(0xae)]();}[_0x12f486(0x1f1)](){const _0x1106b2=_0x12f486;this[_0x1106b2(0x120)]?.[_0x1106b2(0x11c)]();}[_0x12f486(0x137)](_0x409d5e){const _0x344c26=_0x12f486,[_0x34df75,_0x5ede4e]=_0x409d5e[_0x344c26(0x160)](':'),_0x50a5d7=this[_0x344c26(0x120)][_0x344c26(0x7c)](_0x34df75),_0x3bfbdc=_0x50a5d7[_0x344c26(0x1b5)](_0x5ede4e);return{'interaction':_0x50a5d7,'reply':_0x3bfbdc};}[_0x12f486(0x1da)](_0xb0d721,_0x1fd5df=!0x1){const _0x55f66=_0x12f486,_0x3cd8e9=_0x4b9b70(this[_0x55f66(0x1ac)]),_0x27dbd9={'target':_0x3cd8e9[_0x55f66(0xc0)][_0x55f66(0xff)][_0x55f66(0xb3)][_0x55f66(0x146)](_0x3cd8e9[_0x55f66(0xc0)][_0x55f66(0x96)][_0x55f66(0x12a)](_0xb0d721)),'viewportOffset':{'top':0x96,'left':0x0,'bottom':0x32,'right':0x0},'ancestorOffset':0x14,'alignToTop':_0x1fd5df};_0x1fd5df&&(_0x27dbd9[_0x55f66(0x124)]=!0x0),_0x343c18(_0x27dbd9);}[_0x12f486(0x1cd)](_0x22c40a,_0xbdc0a4=!0x1){const _0x395e57=_0x12f486;this[_0x395e57(0xef)][_0x395e57(0x161)](_0x22c40a||_0x541ff7(this[_0x395e57(0x1ac)][_0x395e57(0xbf)],_0x395e57(0xf3)),_0xbdc0a4);}async[_0x12f486(0x148)]({reply:_0x21a2e3,renderingStrategy:_0x2036a7}){const _0x584d26=_0x12f486,{id:_0x55df35,interactionId:_0x37a6ec,isDone:_0x4d4c45,type:_0x23ef66,parsedContent:_0x50aef2}=_0x21a2e3,_0x3ff1fb=_0x37a6ec+':'+_0x55df35;if(_0x584d26(0xc4)===_0x23ef66){const _0x3edc53=_0x21a2e3[_0x584d26(0xc6)]({'showDiff':this[_0x584d26(0xef)][_0x584d26(0x147)]});await this[_0x584d26(0xef)][_0x584d26(0x1d5)]({'id':_0x3ff1fb,'parts':_0x3edc53,'renderingStrategy':_0x2036a7,'isDone':_0x4d4c45});}else _0x584d26(0x89)===_0x23ef66&&await this[_0x584d26(0xef)][_0x584d26(0x179)]({'id':_0x3ff1fb,'parsedContent':_0x50aef2,'renderingStrategy':_0x2036a7,'isDone':_0x4d4c45});_0x4d4c45&&_0x21a2e3[_0x584d26(0x187)][_0x584d26(0x84)]>0x0&&this[_0x584d26(0xef)][_0x584d26(0x17b)](_0x3ff1fb,_0x21a2e3[_0x584d26(0x187)]);}async[_0x12f486(0x1f3)](){const _0x5df7f9=_0x12f486,_0x2dc52c=this[_0x5df7f9(0x120)]?.[_0x5df7f9(0x174)];_0x2dc52c&&(_0x2dc52c[_0x5df7f9(0x127)](),this[_0x5df7f9(0xef)][_0x5df7f9(0xa3)](_0x2dc52c));}async[_0x12f486(0x166)](){const _0xe9beb7=_0x12f486,_0x44e665=this[_0xe9beb7(0x120)]?.[_0xe9beb7(0x174)];if(_0x44e665){for await(const _0x54d972 of _0x44e665[_0xe9beb7(0xf7)])await this[_0xe9beb7(0x148)]({'reply':_0x54d972,'renderingStrategy':_0xe9beb7(0x10e)});}}[_0x12f486(0x8b)](_0x183ae3){const _0x30f580=_0x12f486,_0x45e7f7={'positiveCount':_0x183ae3[_0x30f580(0x122)][_0x30f580(0x10a)](_0x812fa5=>_0x30f580(0x1b2)===_0x812fa5[_0x30f580(0x6d)])[_0x30f580(0x84)],'totalCount':_0x183ae3[_0x30f580(0x122)][_0x30f580(0x84)],'modificationId':_0x183ae3['id']},_0x5f147a=this[_0x30f580(0x120)][_0x30f580(0x7c)](_0x183ae3[_0x30f580(0x1e0)])[_0x30f580(0x16b)];_0x5f147a&&this[_0x30f580(0x175)][_0x30f580(0x91)](this[_0x30f580(0x120)]['id'],_0x5f147a,_0x45e7f7);}[_0x12f486(0x15a)](_0x306397){const _0x14f56f=_0x12f486;let _0x191942=null,_0x251572=null;this['on'](_0x14f56f(0x180),(_0x3322b3,_0x4b4634,_0x3255a8)=>{const _0x140d65=_0x14f56f;_0x3255a8['id']!==_0x191942&&(_0x191942=_0x3255a8['id'],_0x251572=this[_0x140d65(0x77)](_0x3255a8)),_0x306397(_0x4b4634,_0x251572);});}[_0x12f486(0x77)](_0x263f89){const _0x2d75a2=_0x12f486,_0x5d4c2d=this[_0x2d75a2(0xef)],_0x1a3f16=()=>{const _0x5392d1=_0x2d75a2;_0x263f89[_0x5392d1(0xe0)](),_0x263f89[_0x5392d1(0x8a)](),_0x5d4c2d[_0x5392d1(0x1c2)]();},_0x479083=()=>{const _0x432136=_0x2d75a2;_0x263f89[_0x432136(0xad)]&&(_0x263f89[_0x432136(0xad)][_0x432136(0x7f)](),_0x263f89[_0x432136(0xad)]=void 0x0);};return{'insertTextReply':(_0x59683a,_0x1e7ee8)=>{const _0x4ee509=_0x2d75a2;_0x479083(),_0x1a3f16();const _0xbdcb5f=_0x263f89[_0x4ee509(0xad)]=_0x263f89[_0x4ee509(0x157)]({'type':_0x4ee509(0x89),'interactionId':_0x263f89['id'],'content':_0x59683a,'id':_0x1e7ee8||_0x14d190()});return _0x479083(),_0xbdcb5f;},'insertCustomElement':async(_0x4dcc3d,_0x1ddf33)=>(_0x479083(),_0x1a3f16(),_0x5d4c2d[_0x2d75a2(0xac)](_0x4dcc3d,_0x1ddf33||_0x14d190())),'setLoadingMessage':_0x5d2abf=>{const _0x165c9e=_0x2d75a2;_0x5d4c2d[_0x165c9e(0x1f4)](_0x5d2abf);},'clearLoadingMessage':()=>{const _0x500a9b=_0x2d75a2;_0x5d4c2d[_0x500a9b(0x1c2)]();}};}}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x27346e=_0x42fa;(function(_0x5deaaa,_0x4bd1f9){const _0x281b80=_0x42fa,_0x9b407e=_0x5deaaa();while(!![]){try{const _0x1f3b3f=-parseInt(_0x281b80(0x14a))/0x1+parseInt(_0x281b80(0x105))/0x2+parseInt(_0x281b80(0xb9))/0x3*(-parseInt(_0x281b80(0xfd))/0x4)+-parseInt(_0x281b80(0x10e))/0x5+parseInt(_0x281b80(0xb2))/0x6+-parseInt(_0x281b80(0xea))/0x7+parseInt(_0x281b80(0x147))/0x8;if(_0x1f3b3f===_0x4bd1f9)break;else _0x9b407e['push'](_0x9b407e['shift']());}catch(_0x411a6a){_0x9b407e['push'](_0x9b407e['shift']());}}}(_0x1b51,0xc032c));function _0x42fa(_0x3e1df3,_0x3c0443){const _0x1b51e3=_0x1b51();return _0x42fa=function(_0x42fa5a,_0x16609c){_0x42fa5a=_0x42fa5a-0xb2;let _0x3a3920=_0x1b51e3[_0x42fa5a];return _0x3a3920;},_0x42fa(_0x3e1df3,_0x3c0443);}import{ContextPlugin as _0xb484d8}from'ckeditor5/src/core.js';import{_isMotionReduced as _0x1c9dbc}from'ckeditor5/src/utils.js';import{AIChatView as _0x3bfe09}from'./ui/aichatview.js';import{AITabs as _0x4bfb6f}from'../aitabs/aitabs.js';import{getTranslation as _0x472d9f}from'../aicore/utils/common-translations.js';import{IconAIChat as _0x2d93b1}from'ckeditor5/src/icons.js';import{AIChatFeedInteractionHeaderView as _0x471c57}from'./ui/feed/aichatfeedinteractionheaderview.js';import{PromiseQueue as _0x65460}from'./utils/promisequeue.js';function _0x1b51(){const _0x2a4e7e=['_view','setFeedItemAIReplySuggestionPartActive','1074657EDooEQ','fire','isReasoningEnabled','removeContextItem','AI_CHAT_FEED_LOADING_MESSAGE_REASONING','from','attributes','chatHeader','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH','commands','setWebSearch','enableControls','hasItem','user-message','values','interactionId','has','isModelAvailable','queueEmptyPromise','showResizeButton','disableControls','setReasoning','setIsMaximized','isTrackChangesOn','setFeedItemRenderingStrategy','addFeedItemAIReply','AI_CHAT_WELCOME_MESSAGE','setConversationTitle','hasFeedItem','updateSuggestionItem','isMaximized','areActionsDisabled','updateFeedItemAIReplyContent','setSuggestionPartActive','contextItems','capabilities','view','isWebSearchEnabled','setPromptInputValue','bind','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH_REASONING','pluginName','clearConversationContextUI','delegate','prepareLoadingMessage','isOfficialPlugin','removeItem','AI_CHAT_FEED_LOADING_MESSAGE_REGULAR','addFeedItemCustomElement','698362hwefbn','find','insertSuggestion','ai.availableReplyActions','addFeedItemError','populateSourceResourceBalloon','ai-reply','createConversation','disableModelSelector','AITabs','setConversationContext','stopAutoScroll','toggleSuggestionDisplayMode','trackChanges','clearPendingContextUI','custom-element','scrollFeedToSuggestion','renderingStrategy','chatFeed','4NDuykP','ai.models.showModelSelector','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH','ai.chat.welcomeMessage','toggleLoadingSkeleton','availableModels','updateSuggestionPartState','getItemIds','540370UUVcEU','displayedPrompt','setModelList','resetMessageInput','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH_REASONING','_titleAnimationInterval','value','label','filter','3652160pxYeHC','resetConversationTitle','isDone','showDiff','addFeedInteractionHeader','addTab','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REASONING','_animateConversationTitle','updateResourceState','_interactionPromiseResolver','destroy','get','setIsUploadInProgress','abort','isLoading','locale','clear','clearLoadingMessage','length','updateWebSources','last','startInteraction','updateFeedInteractionHeader','isVisible','removeFeedItem','updateFeedItemAIReplySources','markFeedItemAsDone','remove','chatControls','isPending','setModel','conversationCreated','setLoadingMessage','startAutoScroll','ai.chat.context.searchInputVisibleFrom','isBusy','closeSourceResourceBalloon','addContextItem','options','finishInteraction','isPremiumPlugin','feedItemRenderingStrategy','setInputPlaceholder','then','ai-suggestion-reply','scrollToSuggestion','addItem','_getInputPlaceholder','addFeedItemUserMessage','setContextItemLoading','error-message','interaction-header','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REGULAR','enqueue','enableModelSelector','addFeedItemStaticMessage','set','16242936xtjbyF','setAddContextOptions','TrackChanges','1159193MjuBSI','_promiseQueue','</p>','config','AI_CHAT_HEADING','markItemAsDone','<p>','requires','focusPromptInput','streaming','AIChatUI','addFeedItemAISuggestion','userMessage','conversation-start','isDisabled','plugins','chat','_isTrackChangesCommandValueBound','stopInteraction','forEach','updateFeedItemAIReplySuggestionContent','updateFeedItemAIReplySuggestionPartState','removeFeedInteraction','children','setSelectedModel','5005812FUbSNi','context','updateCapabilities','updateReplyItem','startsWith'];_0x1b51=function(){return _0x2a4e7e;};return _0x1b51();}import{AI_CHAT_UI_EVENT_NAMES as _0x442c9a}from'./utils/eventnames.js';import'../../theme/aichat/aichat.css';import{getEditorFromContext as _0x9db47a}from'../aicore/utils/geteditorfromcontext.js';import{AI_REPLY_ACTIONS as _0x12ca3d}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';export class AIChatUI extends _0xb484d8{static get[_0x27346e(0x151)](){return[_0x4bfb6f];}[_0x27346e(0xb7)];static get[_0x27346e(0xe2)](){const _0x4efc9d=_0x27346e;return _0x4efc9d(0x154);}static get[_0x27346e(0xe6)](){return!0x0;}static get[_0x27346e(0x136)](){return!0x0;}[_0x27346e(0x137)]=_0x27346e(0x153);[_0x27346e(0x111)]=!0x0;[_0x27346e(0x14b)];[_0x27346e(0x117)];[_0x27346e(0x10a)]=void 0x0;[_0x27346e(0x15b)]=!0x1;constructor(_0x41c0f9){const _0x4323e4=_0x27346e;super(_0x41c0f9);const _0x50a075=this[_0x4323e4(0xb3)][_0x4323e4(0x159)][_0x4323e4(0x119)](_0x4323e4(0xf3));this[_0x4323e4(0x146)](_0x4323e4(0x131),!0x1),this[_0x4323e4(0x14b)]=new _0x65460(),this[_0x4323e4(0xb7)]=new _0x3bfe09(this[_0x4323e4(0xb3)][_0x4323e4(0x11d)],{'showResizeButton':_0x50a075[_0x4323e4(0xcc)],'contextResourcesSearchInputVisibleFrom':this[_0x4323e4(0xb3)][_0x4323e4(0x14d)][_0x4323e4(0x119)](_0x4323e4(0x130))}),this[_0x4323e4(0xb7)][_0x4323e4(0xe4)](..._0x442c9a)['to'](this),this[_0x4323e4(0xb7)]['on'](_0x4323e4(0xf6),(_0x422f0d,{showDiff:_0x3f4dff})=>{const _0x3ac9dd=_0x4323e4;this[_0x3ac9dd(0x111)]=_0x3f4dff;}),_0x50a075[_0x4323e4(0xdd)][_0x4323e4(0x113)]({'id':_0x4323e4(0x15a),'buttonLabel':_0x472d9f(this[_0x4323e4(0xb3)][_0x4323e4(0x11d)],_0x4323e4(0x14e)),'buttonIcon':_0x2d93b1,'order':0x0,'content':this[_0x4323e4(0xb7)]}),this[_0x4323e4(0xb7)][_0x4323e4(0x12a)][_0x4323e4(0xe0)](_0x4323e4(0x11c))['to'](this,_0x4323e4(0x131),_0x22a332=>_0x22a332),this[_0x4323e4(0xb7)][_0x4323e4(0xfc)][_0x4323e4(0xe0)](_0x4323e4(0x12b))['to'](this,_0x4323e4(0x131),_0x1a045b=>_0x1a045b),this[_0x4323e4(0xb7)][_0x4323e4(0x12a)][_0x4323e4(0x138)](this[_0x4323e4(0x13d)]()),this[_0x4323e4(0xe0)](_0x4323e4(0xca))['to'](this[_0x4323e4(0xb7)][_0x4323e4(0x12a)],_0x4323e4(0xca));}[_0x27346e(0x118)](){const _0x3b37f4=_0x27346e;super[_0x3b37f4(0x118)](),this[_0x3b37f4(0x10a)]&&clearInterval(this[_0x3b37f4(0x10a)]);}[_0x27346e(0xf1)](_0x670c58){const _0x1a8f20=_0x27346e,_0x36d37a=this[_0x1a8f20(0xb3)][_0x1a8f20(0x14d)][_0x1a8f20(0x119)](_0x1a8f20(0x100))??_0x472d9f(this[_0x1a8f20(0xb3)][_0x1a8f20(0x11d)],_0x1a8f20(0xd3));this[_0x1a8f20(0xb7)][_0x1a8f20(0xfc)][_0x1a8f20(0x11e)](),this[_0x1a8f20(0xb7)][_0x1a8f20(0x12a)][_0x1a8f20(0x144)](),this[_0x1a8f20(0xb7)][_0x1a8f20(0x12a)][_0x1a8f20(0x107)](_0x670c58[_0x1a8f20(0x102)],!this[_0x1a8f20(0xb3)][_0x1a8f20(0x14d)][_0x1a8f20(0x119)](_0x1a8f20(0xfe))),this[_0x1a8f20(0x145)]({'id':_0x1a8f20(0x157),'staticMessage':_0x36d37a}),this[_0x1a8f20(0xba)](_0x1a8f20(0x12d));}[_0x27346e(0x145)]({id:_0x51ab49,staticMessage:_0x410bfe}){const _0x378ca2=_0x27346e;this[_0x378ca2(0xb7)][_0x378ca2(0xfc)][_0x378ca2(0x13c)](_0x378ca2(0xf0),{'id':_0x51ab49,'initialContent':_0x378ca2(0x150)+_0x410bfe+_0x378ca2(0x14c)});}[_0x27346e(0x13e)](_0x22e0b6){const _0x30b8f2=_0x27346e,_0x42d61c=_0x22e0b6[_0x30b8f2(0xbf)]?.[_0x30b8f2(0x106)]||_0x22e0b6[_0x30b8f2(0x156)];this[_0x30b8f2(0xb7)][_0x30b8f2(0xfc)][_0x30b8f2(0x13c)](_0x30b8f2(0xc6),{'contextItems':Array[_0x30b8f2(0xbe)](_0x22e0b6[_0x30b8f2(0xdb)][_0x30b8f2(0xc7)]()),'initialContent':_0x30b8f2(0x150)+_0x42d61c+_0x30b8f2(0x14c),'id':_0x22e0b6['id']});}[_0x27346e(0xee)]({errorMessage:_0x2173d9,id:_0x5b1b21}){const _0x235b46=_0x27346e;this[_0x235b46(0xb7)][_0x235b46(0xfc)][_0x235b46(0x13c)](_0x235b46(0x140),{'initialContent':_0x235b46(0x150)+_0x2173d9+_0x235b46(0x14c),'id':_0x5b1b21});}[_0x27346e(0xd2)](_0x425515){const _0x21ab02=_0x27346e;return this[_0x21ab02(0x14b)][_0x21ab02(0x143)](async()=>{const _0x370b84=_0x21ab02;this[_0x370b84(0xb7)][_0x370b84(0xfc)][_0x370b84(0x13c)](_0x370b84(0xf0),{'id':_0x425515[_0x370b84(0xc8)]+':'+_0x425515['id']}),this[_0x370b84(0x11f)]();});}async[_0x27346e(0x155)](_0x2b764a){const _0x58038c=_0x27346e,_0x2c9c0b=_0x9db47a(this[_0x58038c(0xb3)]);let _0x4c1cf4=_0x2c9c0b[_0x58038c(0x14d)][_0x58038c(0x119)](_0x58038c(0xed))||[..._0x12ca3d];if(_0x2c9c0b[_0x58038c(0x159)][_0x58038c(0xc9)](_0x58038c(0x149))){if(!this[_0x58038c(0x15b)]){this[_0x58038c(0x15b)]=!0x0;const _0x2df11b=_0x2c9c0b[_0x58038c(0xc2)][_0x58038c(0x119)](_0x58038c(0xf7));this[_0x58038c(0xb7)][_0x58038c(0xfc)][_0x58038c(0xe0)](_0x58038c(0xd0))['to'](_0x2df11b,_0x58038c(0x10b));}}else _0x4c1cf4=_0x4c1cf4[_0x58038c(0x10d)](_0x2e1c4c=>_0x58038c(0xec)!=_0x2e1c4c);return this[_0x58038c(0x14b)][_0x58038c(0x143)](async()=>{const _0x537556=_0x58038c;this[_0x537556(0xb7)][_0x537556(0xfc)][_0x537556(0x13c)](_0x537556(0x13a),{'id':_0x2b764a[_0x537556(0xc8)]+':'+_0x2b764a['id'],'areActionsDisabled':_0x2b764a[_0x537556(0xd8)],'showDiff':this[_0x537556(0x111)],'availableActions':_0x4c1cf4}),this[_0x537556(0x11f)]();});}[_0x27346e(0x112)](_0x4ac7f7,_0x17a344){const _0x4c31dc=_0x27346e,_0x125a92=this[_0x4c31dc(0xb7)][_0x4c31dc(0xfc)][_0x4c31dc(0x161)][_0x4c31dc(0x122)];if(_0x125a92 instanceof _0x471c57)return this[_0x4c31dc(0xb7)][_0x4c31dc(0xfc)][_0x4c31dc(0x161)][_0x4c31dc(0x129)](_0x125a92),void this[_0x4c31dc(0xb7)][_0x4c31dc(0xfc)][_0x4c31dc(0x13c)](_0x4c31dc(0x141),{'id':_0x4ac7f7['id'],'capabilities':{'isWebSearchEnabled':_0x125a92[_0x4c31dc(0xdc)][_0x4c31dc(0xde)]||_0x17a344[_0x4c31dc(0xde)],'isReasoningEnabled':_0x125a92[_0x4c31dc(0xdc)][_0x4c31dc(0xbb)]||_0x17a344[_0x4c31dc(0xbb)]}});this[_0x4c31dc(0xb7)][_0x4c31dc(0xfc)][_0x4c31dc(0x13c)](_0x4c31dc(0x141),{'id':_0x4ac7f7['id'],'capabilities':_0x17a344});}async[_0x27346e(0xe9)](_0x4c2e64,_0x435b92){const _0x271fae=_0x27346e;let _0x920628;return await this[_0x271fae(0x14b)][_0x271fae(0x143)](async()=>{const _0x2922c0=_0x271fae;_0x920628=this[_0x2922c0(0xb7)][_0x2922c0(0xfc)][_0x2922c0(0x13c)](_0x2922c0(0xf9),{'content':_0x4c2e64,'id':_0x435b92});}),_0x920628;}[_0x27346e(0x126)](_0xe03101){const _0x5538b2=_0x27346e;this[_0x5538b2(0xb7)][_0x5538b2(0xfc)][_0x5538b2(0xe7)](_0xe03101);}[_0x27346e(0xd5)](_0x50cec3){const _0x21ea3b=_0x27346e;return this[_0x21ea3b(0xb7)][_0x21ea3b(0xfc)][_0x21ea3b(0xc5)](_0x50cec3);}[_0x27346e(0x124)](_0x139b00){const _0x394af7=_0x27346e,_0x15f3c7=this[_0x394af7(0xb7)][_0x394af7(0xfc)][_0x394af7(0x161)][_0x394af7(0xeb)](_0x442f78=>_0x442f78[_0x394af7(0x134)]['id']==_0x139b00['id']&&_0x442f78 instanceof _0x471c57);_0x15f3c7&&_0x15f3c7[_0x394af7(0x146)](_0x394af7(0x125),_0x139b00[_0x394af7(0x125)]);}async[_0x27346e(0xd9)](_0x44e961){const _0x57db71=_0x27346e,_0x4d5597=_0x44e961[_0x57db71(0xfb)]||this[_0x57db71(0x137)];return this[_0x57db71(0x14b)][_0x57db71(0x143)](async _0x3e71d3=>{const _0x2286d2=_0x57db71;await this[_0x2286d2(0xb7)][_0x2286d2(0xfc)][_0x2286d2(0xb5)]({..._0x44e961,'abortSignal':_0x3e71d3,'renderingStrategy':_0x4d5597}),_0x44e961[_0x2286d2(0x110)]&&this[_0x2286d2(0x128)](_0x44e961['id']);});}[_0x27346e(0x127)](_0x1784c8,_0x50cd35){const _0x5c16c2=_0x27346e;this[_0x5c16c2(0xb7)][_0x5c16c2(0xfc)][_0x5c16c2(0x121)](_0x1784c8,_0x50cd35);}async[_0x27346e(0x15e)](_0x3469a6){const _0xcbe623=_0x27346e,_0x294f0a=_0x3469a6[_0xcbe623(0xfb)]||this[_0xcbe623(0x137)];return this[_0xcbe623(0x14b)][_0xcbe623(0x143)](async _0x29321a=>{const _0x2af865=_0xcbe623;await this[_0x2af865(0xb7)][_0x2af865(0xfc)][_0x2af865(0xd6)]({..._0x3469a6,'abortSignal':_0x29321a,'renderingStrategy':_0x294f0a}),_0x3469a6[_0x2af865(0x110)]&&this[_0x2af865(0x128)](_0x3469a6['id']);});}[_0x27346e(0x15f)](_0x106760){const _0x73561e=_0x27346e;this[_0x73561e(0xb7)][_0x73561e(0xfc)][_0x73561e(0x103)](_0x106760);}[_0x27346e(0xb8)](_0x555c95){const _0x451626=_0x27346e;this[_0x451626(0xb7)][_0x451626(0xfc)][_0x451626(0xda)](_0x555c95);}[_0x27346e(0x128)](_0x24dbd5){const _0x2a140e=_0x27346e;this[_0x2a140e(0xb7)][_0x2a140e(0xfc)][_0x2a140e(0x14f)](_0x24dbd5);}[_0x27346e(0x160)](_0xcc3f88){const _0x2eb25b=_0x27346e;this[_0x2eb25b(0xb7)][_0x2eb25b(0xfc)][_0x2eb25b(0x104)]()[_0x2eb25b(0x10d)](_0xdabc03=>_0xdabc03[_0x2eb25b(0xb6)](_0xcc3f88))[_0x2eb25b(0x15d)](_0x3adcb7=>this[_0x2eb25b(0xb7)][_0x2eb25b(0xfc)][_0x2eb25b(0xe7)](_0x3adcb7));}[_0x27346e(0x123)](){const _0x118a96=_0x27346e,_0x276347=this[_0x118a96(0xe5)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x1});this[_0x118a96(0x12e)](_0x276347),this[_0x118a96(0xb7)][_0x118a96(0x12a)][_0x118a96(0xf2)](!this[_0x118a96(0xb3)][_0x118a96(0x14d)][_0x118a96(0x119)](_0x118a96(0xfe))),this[_0x118a96(0x131)]=!0x0,this[_0x118a96(0xb7)][_0x118a96(0xfc)][_0x118a96(0x12f)]();}[_0x27346e(0x15c)](_0x59d970){const _0x4013bf=_0x27346e;this[_0x4013bf(0x14b)][_0x4013bf(0x11b)](),this[_0x4013bf(0xb7)][_0x4013bf(0xfc)][_0x4013bf(0x104)]()[_0x4013bf(0x10d)](_0x3913fa=>_0x3913fa[_0x4013bf(0xb6)](_0x59d970['id']))[_0x4013bf(0x15d)](_0xd4848f=>this[_0x4013bf(0x128)](_0xd4848f)),this[_0x4013bf(0x131)]=!0x1,this[_0x4013bf(0xb7)][_0x4013bf(0xfc)][_0x4013bf(0xf5)]();}async[_0x27346e(0x135)](){const _0x535e6f=_0x27346e;return this[_0x535e6f(0x14b)][_0x535e6f(0xcb)][_0x535e6f(0x139)](()=>{const _0x10948b=_0x535e6f;this[_0x10948b(0x131)]=!0x1,this[_0x10948b(0xb7)][_0x10948b(0xfc)][_0x10948b(0xf5)]();});}[_0x27346e(0x133)](_0x55652c,_0x289661){const _0x34c0f0=_0x27346e;this[_0x34c0f0(0xb7)][_0x34c0f0(0x12a)][_0x34c0f0(0x133)](_0x55652c,_0x289661);}[_0x27346e(0xbc)](_0x485c17){const _0x385277=_0x27346e;this[_0x385277(0xb7)][_0x385277(0x12a)][_0x385277(0xbc)](_0x485c17);}[_0x27346e(0x13f)](_0x515475,_0x9753cf){const _0x3dfad7=_0x27346e;this[_0x3dfad7(0xb7)][_0x3dfad7(0x12a)][_0x3dfad7(0x13f)](_0x515475,_0x9753cf);}[_0x27346e(0x11a)](_0x199d73){const _0x15c1a0=_0x27346e;this[_0x15c1a0(0xb7)][_0x15c1a0(0x12a)][_0x15c1a0(0x11a)](_0x199d73);}[_0x27346e(0xf4)](_0x128ac3){const _0x784994=_0x27346e;this[_0x784994(0xb7)][_0x784994(0x12a)][_0x784994(0xf4)](_0x128ac3);}[_0x27346e(0xf8)](){const _0x1aab4f=_0x27346e;this[_0x1aab4f(0xb7)][_0x1aab4f(0x12a)][_0x1aab4f(0xf8)]();}[_0x27346e(0xe3)](){const _0x25f5c7=_0x27346e;this[_0x25f5c7(0xb7)][_0x25f5c7(0x12a)][_0x25f5c7(0xe3)]();}[_0x27346e(0x116)](_0x28f7c0,_0x5e8256,_0x596a28){const _0x489ea8=_0x27346e;this[_0x489ea8(0xb7)][_0x489ea8(0x12a)][_0x489ea8(0x116)](_0x28f7c0,_0x5e8256,_0x596a28);}[_0x27346e(0x108)](){const _0x11ada1=_0x27346e;this[_0x11ada1(0xb7)][_0x11ada1(0x12a)][_0x11ada1(0x108)](),this[_0x11ada1(0xb7)][_0x11ada1(0x12a)][_0x11ada1(0x138)](this[_0x11ada1(0x13d)]());}[_0x27346e(0x148)](_0x33e74f){const _0x42d74f=_0x27346e;this[_0x42d74f(0xb7)][_0x42d74f(0x12a)][_0x42d74f(0x148)](_0x33e74f);}[_0x27346e(0xb4)](_0x5ab5c6){const _0x38b922=_0x27346e;this[_0x38b922(0xb7)][_0x38b922(0x12a)][_0x38b922(0xc3)](_0x5ab5c6[_0x38b922(0xde)]),this[_0x38b922(0xb7)][_0x38b922(0x12a)][_0x38b922(0xce)](_0x5ab5c6[_0x38b922(0xbb)]),this[_0x38b922(0xb7)][_0x38b922(0x12a)][_0x38b922(0x138)](this[_0x38b922(0x13d)](_0x5ab5c6));}[_0x27346e(0x162)](_0x517cf9,_0x45ea1a){const _0xb6afd1=_0x27346e;this[_0xb6afd1(0xb7)][_0xb6afd1(0x12a)][_0xb6afd1(0x12c)](_0x517cf9),_0x45ea1a&&this[_0xb6afd1(0xb7)][_0xb6afd1(0x12a)][_0xb6afd1(0xf2)](!0x1);}[_0x27346e(0xd1)](_0x44a8c7){const _0x271d20=_0x27346e;this[_0x271d20(0x137)]=_0x44a8c7;}[_0x27346e(0x101)](_0x58e01e){const _0x2ca91b=_0x27346e;this[_0x2ca91b(0xb7)][_0x2ca91b(0xfc)][_0x2ca91b(0x101)](_0x58e01e);}[_0x27346e(0x10f)](){const _0x5d73ef=_0x27346e;this[_0x5d73ef(0xd4)](_0x472d9f(this[_0x5d73ef(0xb3)][_0x5d73ef(0x11d)],_0x5d73ef(0x14e)));}[_0x27346e(0xd4)](_0x1afdfa,_0x2d9071=!0x1){const _0x151e76=_0x27346e;if(_0x2d9071&&!_0x1c9dbc()&&_0x1afdfa[_0x151e76(0x120)])return this[_0x151e76(0xb7)][_0x151e76(0xc0)][_0x151e76(0x10c)]='',void this[_0x151e76(0x115)](_0x1afdfa);this[_0x151e76(0xb7)][_0x151e76(0xc0)][_0x151e76(0x10c)]=_0x1afdfa;}[_0x27346e(0x12e)](_0x192862){const _0xc26a97=_0x27346e;this[_0xc26a97(0xb7)][_0xc26a97(0xfc)][_0xc26a97(0x12e)](_0x192862);}[_0x27346e(0x11f)](){const _0x29cc53=_0x27346e;this[_0x29cc53(0xb7)][_0x29cc53(0xfc)][_0x29cc53(0x12e)]('');}[_0x27346e(0x115)](_0x2af4ad){const _0x36975a=_0x27346e;let _0x3daa91=0x0;clearInterval(this[_0x36975a(0x10a)]),this[_0x36975a(0x10a)]=setInterval(()=>{const _0x39adcf=_0x36975a;this[_0x39adcf(0xb7)][_0x39adcf(0xc0)][_0x39adcf(0x10c)]=this[_0x39adcf(0xb7)][_0x39adcf(0xc0)][_0x39adcf(0x10c)]+_0x2af4ad[_0x3daa91],_0x3daa91++,_0x3daa91===_0x2af4ad[_0x39adcf(0x120)]&&clearInterval(this[_0x39adcf(0x10a)]);},0x1e);}[_0x27346e(0xcf)](_0x2d7ae5){const _0x211a13=_0x27346e;this[_0x211a13(0xb7)][_0x211a13(0xc0)][_0x211a13(0xd7)]=_0x2d7ae5;}[_0x27346e(0xe5)](_0x49e531){const _0x43e252=_0x27346e;return _0x49e531[_0x43e252(0xde)]&&_0x49e531[_0x43e252(0xbb)]?_0x472d9f(this[_0x43e252(0xb3)][_0x43e252(0x11d)],_0x43e252(0x109)):_0x49e531[_0x43e252(0xde)]?_0x472d9f(this[_0x43e252(0xb3)][_0x43e252(0x11d)],_0x43e252(0xc1)):_0x49e531[_0x43e252(0xbb)]?_0x472d9f(this[_0x43e252(0xb3)][_0x43e252(0x11d)],_0x43e252(0xbd)):_0x472d9f(this[_0x43e252(0xb3)][_0x43e252(0x11d)],_0x43e252(0xe8));}[_0x27346e(0x13d)](_0x57c405){const _0x3b16e6=_0x27346e;return _0x57c405?_0x57c405[_0x3b16e6(0xde)]&&_0x57c405[_0x3b16e6(0xbb)]?_0x472d9f(this[_0x3b16e6(0xb3)][_0x3b16e6(0x11d)],_0x3b16e6(0xe1)):_0x57c405[_0x3b16e6(0xde)]?_0x472d9f(this[_0x3b16e6(0xb3)][_0x3b16e6(0x11d)],_0x3b16e6(0xff)):_0x57c405[_0x3b16e6(0xbb)]?_0x472d9f(this[_0x3b16e6(0xb3)][_0x3b16e6(0x11d)],_0x3b16e6(0x114)):_0x472d9f(this[_0x3b16e6(0xb3)][_0x3b16e6(0x11d)],_0x3b16e6(0x142)):_0x472d9f(this[_0x3b16e6(0xb3)][_0x3b16e6(0x11d)],_0x3b16e6(0x142));}[_0x27346e(0xef)](_0x3ad1cf,_0x52f7b3,_0xe7311,_0x53ab4f){const _0x41d842=_0x27346e;this[_0x41d842(0xb7)][_0x41d842(0xef)](_0x3ad1cf,_0x52f7b3,_0xe7311,_0x53ab4f);}[_0x27346e(0x132)](_0x3eba7c){const _0x595921=_0x27346e;this[_0x595921(0xb7)][_0x595921(0x132)](_0x3eba7c);}[_0x27346e(0xdf)](_0x380137){const _0x2dc93d=_0x27346e;this[_0x2dc93d(0xb7)][_0x2dc93d(0x12a)][_0x2dc93d(0xdf)](_0x380137);}[_0x27346e(0x152)](_0x398f90=!0x1){const _0x4f73cb=_0x27346e;this[_0x4f73cb(0xb7)][_0x4f73cb(0x12a)][_0x4f73cb(0x152)](_0x398f90);}[_0x27346e(0xfa)](_0x2b1c5b,_0x397899){const _0x169f11=_0x27346e;this[_0x169f11(0xb7)][_0x169f11(0xfc)][_0x169f11(0x13b)](_0x2b1c5b,_0x397899);}[_0x27346e(0x12f)](){const _0x8cf56b=_0x27346e;this[_0x8cf56b(0xb7)][_0x8cf56b(0xfc)][_0x8cf56b(0x12f)]();}[_0x27346e(0xcd)](){const _0x23e44d=_0x27346e;this[_0x23e44d(0xb7)][_0x23e44d(0x12a)][_0x23e44d(0x158)]=!0x0;}[_0x27346e(0xc4)](){const _0x5bbd7=_0x27346e;this[_0x5bbd7(0xb7)][_0x5bbd7(0x12a)][_0x5bbd7(0x158)]=!0x1;}}
23
+ const _0x5b30e0=_0x208a;(function(_0x3f2555,_0x36db1c){const _0x122913=_0x208a,_0x4fc272=_0x3f2555();while(!![]){try{const _0x360610=parseInt(_0x122913(0x127))/0x1*(-parseInt(_0x122913(0x160))/0x2)+parseInt(_0x122913(0x19c))/0x3*(parseInt(_0x122913(0x153))/0x4)+-parseInt(_0x122913(0x139))/0x5*(-parseInt(_0x122913(0x185))/0x6)+parseInt(_0x122913(0x1bf))/0x7*(parseInt(_0x122913(0x178))/0x8)+-parseInt(_0x122913(0x170))/0x9*(parseInt(_0x122913(0x12c))/0xa)+-parseInt(_0x122913(0x1b6))/0xb+parseInt(_0x122913(0x1ac))/0xc;if(_0x360610===_0x36db1c)break;else _0x4fc272['push'](_0x4fc272['shift']());}catch(_0x571fa7){_0x4fc272['push'](_0x4fc272['shift']());}}}(_0x3c6c,0x62c91));import{ContextPlugin as _0x14576b}from'ckeditor5/src/core.js';import{_isMotionReduced as _0x482524}from'ckeditor5/src/utils.js';import{AIChatView as _0x522b38}from'./ui/aichatview.js';import{AITabs as _0x15c315}from'../aitabs/aitabs.js';import{getTranslation as _0x2b4b9a}from'../aicore/utils/common-translations.js';import{IconAIChat as _0x19435b}from'ckeditor5/src/icons.js';function _0x208a(_0x3a4771,_0x8ec7ad){const _0x3c6c77=_0x3c6c();return _0x208a=function(_0x208a49,_0x28276a){_0x208a49=_0x208a49-0x11c;let _0x605e65=_0x3c6c77[_0x208a49];return _0x605e65;},_0x208a(_0x3a4771,_0x8ec7ad);}import{AIChatFeedInteractionHeaderView as _0x2a22d5}from'./ui/feed/aichatfeedinteractionheaderview.js';import{PromiseQueue as _0x2035af}from'./utils/promisequeue.js';import{AI_CHAT_UI_EVENT_NAMES as _0x3cb218}from'./utils/eventnames.js';import'../../theme/aichat/aichat.css';function _0x3c6c(){const _0x58bf21=['conversationCreated','36417LGehOb','user-message','setIsMaximized','chatControls','from','clearConversationContextUI','isBusy','clearLoadingMessage','isDone','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH','isVisible','updateSuggestionItem','removeFeedItem','updateWebSources','contextItems','setFeedItemAIReplySuggestionPartActive','4895040HzJrAB','removeItem','bind','interaction-header','AI_CHAT_FEED_LOADING_MESSAGE_REASONING','value','updateFeedItemAIReplySuggestionPartState','updateSuggestionPartState','AIChatUI','AITabs','2280201oLpUrH','setModelList','ai.chat.context.searchInputVisibleFrom','setInputPlaceholder','addFeedItemCustomElement','setFeedItemRenderingStrategy','trackChanges','updateResourceState','enableControls','23807gzGeNK','values','startAutoScroll','chatHeader','conversation-start','filter','prepareLoadingMessage','commands','userMessage','isMaximized','addFeedItemAIReply','areActionsDisabled','scrollToSuggestion','get','isTrackChangesOn','addItem','stopAutoScroll','addFeedItemError','startInteraction','capabilities','isDisabled','setReasoning','setContextItemLoading','destroy','AI_CHAT_WELCOME_MESSAGE','length','addFeedInteractionHeader','stopInteraction','queueEmptyPromise','54667QABPYu','requires','createConversation','isModelAvailable','locale','6330bKYzKz','finishInteraction','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REGULAR','_view','markItemAsDone','toggleLoadingSkeleton','_interactionPromiseResolver','resetConversationTitle','addFeedItemAISuggestion','_animateConversationTitle','last','clearPendingContextUI','updateFeedInteractionHeader','10dwMTnz','updateFeedItemAIReplySources','chat','ai-suggestion-reply','setLoadingMessage','setWebSearch','remove','_promiseQueue','updateFeedItemAIReplySuggestionContent','isPremiumPlugin','setModel','markFeedItemAsDone','view','hasItem','AI_CHAT_FEED_LOADING_MESSAGE_REGULAR','removeContextItem','resetMessageInput','displayedPrompt','interactionId','availableModels','plugins','attributes','focusPromptInput','startsWith','chatFeed','isReasoningEnabled','204NctLda','disableControls','forEach','TrackChanges','</p>','children','context','custom-element','updateReplyItem','_titleAnimationInterval','abort','addFeedItemUserMessage','setIsUploadInProgress','22bezCEi','getItemIds','toggleSuggestionDisplayMode','enableModelSelector','addFeedItemStaticMessage','showResizeButton','ai-reply','populateSourceResourceBalloon','ai.chat.welcomeMessage','then','options','isWebSearchEnabled','updateFeedItemAIReplyContent','clear','delegate','closeSourceResourceBalloon','3582SWWpGQ','setConversationTitle','set','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REASONING','addTab','ai.availableReplyActions','hasFeedItem','setPromptInputValue','48qfzeSU','setConversationContext','insertSuggestion','config','isPending','label','showDiff','AI_CHAT_HEADING','scrollFeedToSuggestion','streaming','error-message','has','setAddContextOptions','1253316noYNkB','setSelectedModel','<p>','enqueue','addContextItem','updateCapabilities','ai.models.showModelSelector','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH_REASONING','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH_REASONING','setSuggestionPartActive','disableModelSelector','removeFeedInteraction','renderingStrategy','isOfficialPlugin','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH','pluginName','_getInputPlaceholder','find','_isTrackChangesCommandValueBound','fire','isLoading','feedItemRenderingStrategy'];_0x3c6c=function(){return _0x58bf21;};return _0x3c6c();}import{getEditorFromContext as _0xdcfe5}from'../aicore/utils/geteditorfromcontext.js';import{AI_REPLY_ACTIONS as _0x1b7ec6}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';export class AIChatUI extends _0x14576b{static get[_0x5b30e0(0x128)](){return[_0x15c315];}[_0x5b30e0(0x12f)];static get[_0x5b30e0(0x194)](){const _0x4254a7=_0x5b30e0;return _0x4254a7(0x1b4);}static get[_0x5b30e0(0x192)](){return!0x0;}static get[_0x5b30e0(0x142)](){return!0x0;}[_0x5b30e0(0x19a)]=_0x5b30e0(0x181);[_0x5b30e0(0x17e)]=!0x0;[_0x5b30e0(0x140)];[_0x5b30e0(0x132)];[_0x5b30e0(0x15c)]=void 0x0;[_0x5b30e0(0x197)]=!0x1;constructor(_0x57a970){const _0x308d03=_0x5b30e0;super(_0x57a970);const _0x47fec1=this[_0x308d03(0x159)][_0x308d03(0x14d)][_0x308d03(0x1cc)](_0x308d03(0x1b5));this[_0x308d03(0x172)](_0x308d03(0x1a2),!0x1),this[_0x308d03(0x140)]=new _0x2035af(),this[_0x308d03(0x12f)]=new _0x522b38(this[_0x308d03(0x159)][_0x308d03(0x12b)],{'showResizeButton':_0x47fec1[_0x308d03(0x165)],'contextResourcesSearchInputVisibleFrom':this[_0x308d03(0x159)][_0x308d03(0x17b)][_0x308d03(0x1cc)](_0x308d03(0x1b8))}),this[_0x308d03(0x12f)][_0x308d03(0x16e)](..._0x3cb218)['to'](this),this[_0x308d03(0x12f)]['on'](_0x308d03(0x162),(_0x4b62c3,{showDiff:_0x3b08e3})=>{const _0x401391=_0x308d03;this[_0x401391(0x17e)]=_0x3b08e3;}),_0x47fec1[_0x308d03(0x145)][_0x308d03(0x174)]({'id':_0x308d03(0x13b),'buttonLabel':_0x2b4b9a(this[_0x308d03(0x159)][_0x308d03(0x12b)],_0x308d03(0x17f)),'buttonIcon':_0x19435b,'order':0x0,'content':this[_0x308d03(0x12f)]}),this[_0x308d03(0x12f)][_0x308d03(0x19f)][_0x308d03(0x1ae)](_0x308d03(0x199))['to'](this,_0x308d03(0x1a2),_0x2b4a61=>_0x2b4a61),this[_0x308d03(0x12f)][_0x308d03(0x151)][_0x308d03(0x1ae)](_0x308d03(0x17c))['to'](this,_0x308d03(0x1a2),_0x26fa56=>_0x26fa56),this[_0x308d03(0x12f)][_0x308d03(0x19f)][_0x308d03(0x1b9)](this[_0x308d03(0x195)]()),this[_0x308d03(0x1ae)](_0x308d03(0x12a))['to'](this[_0x308d03(0x12f)][_0x308d03(0x19f)],_0x308d03(0x12a));}[_0x5b30e0(0x121)](){const _0x42136b=_0x5b30e0;super[_0x42136b(0x121)](),this[_0x42136b(0x15c)]&&clearInterval(this[_0x42136b(0x15c)]);}[_0x5b30e0(0x129)](_0x5d3476){const _0x3f7764=_0x5b30e0,_0x55f8da=this[_0x3f7764(0x159)][_0x3f7764(0x17b)][_0x3f7764(0x1cc)](_0x3f7764(0x168))??_0x2b4b9a(this[_0x3f7764(0x159)][_0x3f7764(0x12b)],_0x3f7764(0x122));this[_0x3f7764(0x12f)][_0x3f7764(0x151)][_0x3f7764(0x16d)](),this[_0x3f7764(0x12f)][_0x3f7764(0x19f)][_0x3f7764(0x163)](),this[_0x3f7764(0x12f)][_0x3f7764(0x19f)][_0x3f7764(0x1b7)](_0x5d3476[_0x3f7764(0x14c)],!this[_0x3f7764(0x159)][_0x3f7764(0x17b)][_0x3f7764(0x1cc)](_0x3f7764(0x18b))),this[_0x3f7764(0x164)]({'id':_0x3f7764(0x1c3),'staticMessage':_0x55f8da}),this[_0x3f7764(0x198)](_0x3f7764(0x19b));}[_0x5b30e0(0x164)]({id:_0x318dfd,staticMessage:_0x260f52}){const _0xd3b4a=_0x5b30e0;this[_0xd3b4a(0x12f)][_0xd3b4a(0x151)][_0xd3b4a(0x1ce)](_0xd3b4a(0x166),{'id':_0x318dfd,'initialContent':_0xd3b4a(0x187)+_0x260f52+_0xd3b4a(0x157)});}[_0x5b30e0(0x15e)](_0x34f1be){const _0x5e3f4c=_0x5b30e0,_0x13b511=_0x34f1be[_0x5e3f4c(0x14e)]?.[_0x5e3f4c(0x14a)]||_0x34f1be[_0x5e3f4c(0x1c7)];this[_0x5e3f4c(0x12f)][_0x5e3f4c(0x151)][_0x5e3f4c(0x1ce)](_0x5e3f4c(0x19d),{'contextItems':Array[_0x5e3f4c(0x1a0)](_0x34f1be[_0x5e3f4c(0x1aa)][_0x5e3f4c(0x1c0)]()),'initialContent':_0x5e3f4c(0x187)+_0x13b511+_0x5e3f4c(0x157),'id':_0x34f1be['id']});}[_0x5b30e0(0x1d0)]({errorMessage:_0x3d4ef3,id:_0x3cf878}){const _0x43f0d9=_0x5b30e0;this[_0x43f0d9(0x12f)][_0x43f0d9(0x151)][_0x43f0d9(0x1ce)](_0x43f0d9(0x182),{'initialContent':_0x43f0d9(0x187)+_0x3d4ef3+_0x43f0d9(0x157),'id':_0x3cf878});}[_0x5b30e0(0x1c9)](_0x8fba42){const _0x55b14f=_0x5b30e0;return this[_0x55b14f(0x140)][_0x55b14f(0x188)](async()=>{const _0x1e050d=_0x55b14f;this[_0x1e050d(0x12f)][_0x1e050d(0x151)][_0x1e050d(0x1ce)](_0x1e050d(0x166),{'id':_0x8fba42[_0x1e050d(0x14b)]+':'+_0x8fba42['id']}),this[_0x1e050d(0x1a3)]();});}async[_0x5b30e0(0x134)](_0x1e76fe){const _0x31ba4e=_0x5b30e0,_0x5d0ed3=_0xdcfe5(this[_0x31ba4e(0x159)]);let _0x4587c9=_0x5d0ed3[_0x31ba4e(0x17b)][_0x31ba4e(0x1cc)](_0x31ba4e(0x175))||[..._0x1b7ec6];if(_0x5d0ed3[_0x31ba4e(0x14d)][_0x31ba4e(0x183)](_0x31ba4e(0x156))){if(!this[_0x31ba4e(0x197)]){this[_0x31ba4e(0x197)]=!0x0;const _0x3007a3=_0x5d0ed3[_0x31ba4e(0x1c6)][_0x31ba4e(0x1cc)](_0x31ba4e(0x1bc));this[_0x31ba4e(0x12f)][_0x31ba4e(0x151)][_0x31ba4e(0x1ae)](_0x31ba4e(0x1cd))['to'](_0x3007a3,_0x31ba4e(0x1b1));}}else _0x4587c9=_0x4587c9[_0x31ba4e(0x1c4)](_0x3c5562=>_0x31ba4e(0x17a)!=_0x3c5562);return this[_0x31ba4e(0x140)][_0x31ba4e(0x188)](async()=>{const _0x5e22c0=_0x31ba4e;this[_0x5e22c0(0x12f)][_0x5e22c0(0x151)][_0x5e22c0(0x1ce)](_0x5e22c0(0x13c),{'id':_0x1e76fe[_0x5e22c0(0x14b)]+':'+_0x1e76fe['id'],'areActionsDisabled':_0x1e76fe[_0x5e22c0(0x1ca)],'showDiff':this[_0x5e22c0(0x17e)],'availableActions':_0x4587c9}),this[_0x5e22c0(0x1a3)]();});}[_0x5b30e0(0x124)](_0x102e31,_0x1cca37){const _0x3458aa=_0x5b30e0,_0x28037a=this[_0x3458aa(0x12f)][_0x3458aa(0x151)][_0x3458aa(0x158)][_0x3458aa(0x136)];if(_0x28037a instanceof _0x2a22d5)return this[_0x3458aa(0x12f)][_0x3458aa(0x151)][_0x3458aa(0x158)][_0x3458aa(0x13f)](_0x28037a),void this[_0x3458aa(0x12f)][_0x3458aa(0x151)][_0x3458aa(0x1ce)](_0x3458aa(0x1af),{'id':_0x102e31['id'],'capabilities':{'isWebSearchEnabled':_0x28037a[_0x3458aa(0x11d)][_0x3458aa(0x16b)]||_0x1cca37[_0x3458aa(0x16b)],'isReasoningEnabled':_0x28037a[_0x3458aa(0x11d)][_0x3458aa(0x152)]||_0x1cca37[_0x3458aa(0x152)]}});this[_0x3458aa(0x12f)][_0x3458aa(0x151)][_0x3458aa(0x1ce)](_0x3458aa(0x1af),{'id':_0x102e31['id'],'capabilities':_0x1cca37});}async[_0x5b30e0(0x1ba)](_0x5f76ae,_0x78105c){const _0x8cfa3c=_0x5b30e0;let _0x3a6034;return await this[_0x8cfa3c(0x140)][_0x8cfa3c(0x188)](async()=>{const _0x281e45=_0x8cfa3c;_0x3a6034=this[_0x281e45(0x12f)][_0x281e45(0x151)][_0x281e45(0x1ce)](_0x281e45(0x15a),{'content':_0x5f76ae,'id':_0x78105c});}),_0x3a6034;}[_0x5b30e0(0x1a8)](_0x4f8f1a){const _0x3bc284=_0x5b30e0;this[_0x3bc284(0x12f)][_0x3bc284(0x151)][_0x3bc284(0x1ad)](_0x4f8f1a);}[_0x5b30e0(0x176)](_0x41b23c){const _0x257bd5=_0x5b30e0;return this[_0x257bd5(0x12f)][_0x257bd5(0x151)][_0x257bd5(0x146)](_0x41b23c);}[_0x5b30e0(0x138)](_0x458317){const _0x2799e2=_0x5b30e0,_0x22d187=this[_0x2799e2(0x12f)][_0x2799e2(0x151)][_0x2799e2(0x158)][_0x2799e2(0x196)](_0x471b1e=>_0x471b1e[_0x2799e2(0x16a)]['id']==_0x458317['id']&&_0x471b1e instanceof _0x2a22d5);_0x22d187&&_0x22d187[_0x2799e2(0x172)](_0x2799e2(0x1a6),_0x458317[_0x2799e2(0x1a6)]);}async[_0x5b30e0(0x16c)](_0x4290db){const _0x11c6a2=_0x5b30e0,_0x4b433b=_0x4290db[_0x11c6a2(0x191)]||this[_0x11c6a2(0x19a)];return this[_0x11c6a2(0x140)][_0x11c6a2(0x188)](async _0x4e7c3a=>{const _0x3a0348=_0x11c6a2;await this[_0x3a0348(0x12f)][_0x3a0348(0x151)][_0x3a0348(0x15b)]({..._0x4290db,'abortSignal':_0x4e7c3a,'renderingStrategy':_0x4b433b}),_0x4290db[_0x3a0348(0x1a4)]&&this[_0x3a0348(0x144)](_0x4290db['id']);});}[_0x5b30e0(0x13a)](_0xbf7792,_0x3070d5){const _0x22cdc4=_0x5b30e0;this[_0x22cdc4(0x12f)][_0x22cdc4(0x151)][_0x22cdc4(0x1a9)](_0xbf7792,_0x3070d5);}async[_0x5b30e0(0x141)](_0x3a2c95){const _0x1236df=_0x5b30e0,_0x26039b=_0x3a2c95[_0x1236df(0x191)]||this[_0x1236df(0x19a)];return this[_0x1236df(0x140)][_0x1236df(0x188)](async _0x45c77a=>{const _0x3a6c35=_0x1236df;await this[_0x3a6c35(0x12f)][_0x3a6c35(0x151)][_0x3a6c35(0x1a7)]({..._0x3a2c95,'abortSignal':_0x45c77a,'renderingStrategy':_0x26039b}),_0x3a2c95[_0x3a6c35(0x1a4)]&&this[_0x3a6c35(0x144)](_0x3a2c95['id']);});}[_0x5b30e0(0x1b2)](_0x4d390b){const _0x333323=_0x5b30e0;this[_0x333323(0x12f)][_0x333323(0x151)][_0x333323(0x1b3)](_0x4d390b);}[_0x5b30e0(0x1ab)](_0x425437){const _0x3e7537=_0x5b30e0;this[_0x3e7537(0x12f)][_0x3e7537(0x151)][_0x3e7537(0x18e)](_0x425437);}[_0x5b30e0(0x144)](_0x5f38cd){const _0x307feb=_0x5b30e0;this[_0x307feb(0x12f)][_0x307feb(0x151)][_0x307feb(0x130)](_0x5f38cd);}[_0x5b30e0(0x190)](_0x44cf46){const _0x492cf6=_0x5b30e0;this[_0x492cf6(0x12f)][_0x492cf6(0x151)][_0x492cf6(0x161)]()[_0x492cf6(0x1c4)](_0x251083=>_0x251083[_0x492cf6(0x150)](_0x44cf46))[_0x492cf6(0x155)](_0xb113a0=>this[_0x492cf6(0x12f)][_0x492cf6(0x151)][_0x492cf6(0x1ad)](_0xb113a0));}[_0x5b30e0(0x11c)](){const _0x22a2fc=_0x5b30e0,_0x51d44f=this[_0x22a2fc(0x1c5)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x1});this[_0x22a2fc(0x13d)](_0x51d44f),this[_0x22a2fc(0x12f)][_0x22a2fc(0x19f)][_0x22a2fc(0x18f)](!this[_0x22a2fc(0x159)][_0x22a2fc(0x17b)][_0x22a2fc(0x1cc)](_0x22a2fc(0x18b))),this[_0x22a2fc(0x1a2)]=!0x0,this[_0x22a2fc(0x12f)][_0x22a2fc(0x151)][_0x22a2fc(0x1c1)]();}[_0x5b30e0(0x125)](_0x430127){const _0x3d1f0d=_0x5b30e0;this[_0x3d1f0d(0x140)][_0x3d1f0d(0x15d)](),this[_0x3d1f0d(0x12f)][_0x3d1f0d(0x151)][_0x3d1f0d(0x161)]()[_0x3d1f0d(0x1c4)](_0x1cac3b=>_0x1cac3b[_0x3d1f0d(0x150)](_0x430127['id']))[_0x3d1f0d(0x155)](_0x5e0790=>this[_0x3d1f0d(0x144)](_0x5e0790)),this[_0x3d1f0d(0x1a2)]=!0x1,this[_0x3d1f0d(0x12f)][_0x3d1f0d(0x151)][_0x3d1f0d(0x1cf)]();}async[_0x5b30e0(0x12d)](){const _0x48bdd6=_0x5b30e0;return this[_0x48bdd6(0x140)][_0x48bdd6(0x126)][_0x48bdd6(0x169)](()=>{const _0x1eb5a7=_0x48bdd6;this[_0x1eb5a7(0x1a2)]=!0x1,this[_0x1eb5a7(0x12f)][_0x1eb5a7(0x151)][_0x1eb5a7(0x1cf)]();});}[_0x5b30e0(0x189)](_0x5e679a,_0x557493){const _0x33e6f3=_0x5b30e0;this[_0x33e6f3(0x12f)][_0x33e6f3(0x19f)][_0x33e6f3(0x189)](_0x5e679a,_0x557493);}[_0x5b30e0(0x148)](_0x55ef29){const _0x350dc7=_0x5b30e0;this[_0x350dc7(0x12f)][_0x350dc7(0x19f)][_0x350dc7(0x148)](_0x55ef29);}[_0x5b30e0(0x120)](_0x2f9557,_0x9da9a7){const _0x329dd5=_0x5b30e0;this[_0x329dd5(0x12f)][_0x329dd5(0x19f)][_0x329dd5(0x120)](_0x2f9557,_0x9da9a7);}[_0x5b30e0(0x15f)](_0x41d0aa){const _0x1036b9=_0x5b30e0;this[_0x1036b9(0x12f)][_0x1036b9(0x19f)][_0x1036b9(0x15f)](_0x41d0aa);}[_0x5b30e0(0x179)](_0x3e64a5){const _0x209f11=_0x5b30e0;this[_0x209f11(0x12f)][_0x209f11(0x19f)][_0x209f11(0x179)](_0x3e64a5);}[_0x5b30e0(0x137)](){const _0xff7998=_0x5b30e0;this[_0xff7998(0x12f)][_0xff7998(0x19f)][_0xff7998(0x137)]();}[_0x5b30e0(0x1a1)](){const _0x1d8454=_0x5b30e0;this[_0x1d8454(0x12f)][_0x1d8454(0x19f)][_0x1d8454(0x1a1)]();}[_0x5b30e0(0x1bd)](_0x1fd275,_0x3fea39,_0x4ca928){const _0x4247fd=_0x5b30e0;this[_0x4247fd(0x12f)][_0x4247fd(0x19f)][_0x4247fd(0x1bd)](_0x1fd275,_0x3fea39,_0x4ca928);}[_0x5b30e0(0x149)](){const _0x39831d=_0x5b30e0;this[_0x39831d(0x12f)][_0x39831d(0x19f)][_0x39831d(0x149)](),this[_0x39831d(0x12f)][_0x39831d(0x19f)][_0x39831d(0x1b9)](this[_0x39831d(0x195)]());}[_0x5b30e0(0x184)](_0x3e5525){const _0x18bc23=_0x5b30e0;this[_0x18bc23(0x12f)][_0x18bc23(0x19f)][_0x18bc23(0x184)](_0x3e5525);}[_0x5b30e0(0x18a)](_0x2c6df3){const _0x153e19=_0x5b30e0;this[_0x153e19(0x12f)][_0x153e19(0x19f)][_0x153e19(0x13e)](_0x2c6df3[_0x153e19(0x16b)]),this[_0x153e19(0x12f)][_0x153e19(0x19f)][_0x153e19(0x11f)](_0x2c6df3[_0x153e19(0x152)]),this[_0x153e19(0x12f)][_0x153e19(0x19f)][_0x153e19(0x1b9)](this[_0x153e19(0x195)](_0x2c6df3));}[_0x5b30e0(0x186)](_0x28c88a,_0x1bb7d0){const _0x57fd29=_0x5b30e0;this[_0x57fd29(0x12f)][_0x57fd29(0x19f)][_0x57fd29(0x143)](_0x28c88a),_0x1bb7d0&&this[_0x57fd29(0x12f)][_0x57fd29(0x19f)][_0x57fd29(0x18f)](!0x1);}[_0x5b30e0(0x1bb)](_0x49810e){const _0x20ddec=_0x5b30e0;this[_0x20ddec(0x19a)]=_0x49810e;}[_0x5b30e0(0x131)](_0x48ed37){const _0x5d36c6=_0x5b30e0;this[_0x5d36c6(0x12f)][_0x5d36c6(0x151)][_0x5d36c6(0x131)](_0x48ed37);}[_0x5b30e0(0x133)](){const _0x1fa503=_0x5b30e0;this[_0x1fa503(0x171)](_0x2b4b9a(this[_0x1fa503(0x159)][_0x1fa503(0x12b)],_0x1fa503(0x17f)));}[_0x5b30e0(0x171)](_0x28f682,_0x77ccac=!0x1){const _0x27a691=_0x5b30e0;if(_0x77ccac&&!_0x482524()&&_0x28f682[_0x27a691(0x123)])return this[_0x27a691(0x12f)][_0x27a691(0x1c2)][_0x27a691(0x17d)]='',void this[_0x27a691(0x135)](_0x28f682);this[_0x27a691(0x12f)][_0x27a691(0x1c2)][_0x27a691(0x17d)]=_0x28f682;}[_0x5b30e0(0x13d)](_0x54e7a1){const _0x280158=_0x5b30e0;this[_0x280158(0x12f)][_0x280158(0x151)][_0x280158(0x13d)](_0x54e7a1);}[_0x5b30e0(0x1a3)](){const _0x439e07=_0x5b30e0;this[_0x439e07(0x12f)][_0x439e07(0x151)][_0x439e07(0x13d)]('');}[_0x5b30e0(0x135)](_0x2b273f){const _0x4e730f=_0x5b30e0;let _0x346267=0x0;clearInterval(this[_0x4e730f(0x15c)]),this[_0x4e730f(0x15c)]=setInterval(()=>{const _0x5af928=_0x4e730f;this[_0x5af928(0x12f)][_0x5af928(0x1c2)][_0x5af928(0x17d)]=this[_0x5af928(0x12f)][_0x5af928(0x1c2)][_0x5af928(0x17d)]+_0x2b273f[_0x346267],_0x346267++,_0x346267===_0x2b273f[_0x5af928(0x123)]&&clearInterval(this[_0x5af928(0x15c)]);},0x1e);}[_0x5b30e0(0x19e)](_0x1d290c){const _0x3495fa=_0x5b30e0;this[_0x3495fa(0x12f)][_0x3495fa(0x1c2)][_0x3495fa(0x1c8)]=_0x1d290c;}[_0x5b30e0(0x1c5)](_0x3736cd){const _0x4c334f=_0x5b30e0;return _0x3736cd[_0x4c334f(0x16b)]&&_0x3736cd[_0x4c334f(0x152)]?_0x2b4b9a(this[_0x4c334f(0x159)][_0x4c334f(0x12b)],_0x4c334f(0x18d)):_0x3736cd[_0x4c334f(0x16b)]?_0x2b4b9a(this[_0x4c334f(0x159)][_0x4c334f(0x12b)],_0x4c334f(0x193)):_0x3736cd[_0x4c334f(0x152)]?_0x2b4b9a(this[_0x4c334f(0x159)][_0x4c334f(0x12b)],_0x4c334f(0x1b0)):_0x2b4b9a(this[_0x4c334f(0x159)][_0x4c334f(0x12b)],_0x4c334f(0x147));}[_0x5b30e0(0x195)](_0x300035){const _0x4afb78=_0x5b30e0;return _0x300035?_0x300035[_0x4afb78(0x16b)]&&_0x300035[_0x4afb78(0x152)]?_0x2b4b9a(this[_0x4afb78(0x159)][_0x4afb78(0x12b)],_0x4afb78(0x18c)):_0x300035[_0x4afb78(0x16b)]?_0x2b4b9a(this[_0x4afb78(0x159)][_0x4afb78(0x12b)],_0x4afb78(0x1a5)):_0x300035[_0x4afb78(0x152)]?_0x2b4b9a(this[_0x4afb78(0x159)][_0x4afb78(0x12b)],_0x4afb78(0x173)):_0x2b4b9a(this[_0x4afb78(0x159)][_0x4afb78(0x12b)],_0x4afb78(0x12e)):_0x2b4b9a(this[_0x4afb78(0x159)][_0x4afb78(0x12b)],_0x4afb78(0x12e));}[_0x5b30e0(0x167)](_0x2ae011,_0x5ef07b,_0x2ffda9,_0x1993ae){const _0x18eb84=_0x5b30e0;this[_0x18eb84(0x12f)][_0x18eb84(0x167)](_0x2ae011,_0x5ef07b,_0x2ffda9,_0x1993ae);}[_0x5b30e0(0x16f)](_0x214f76){const _0x2224a7=_0x5b30e0;this[_0x2224a7(0x12f)][_0x2224a7(0x16f)](_0x214f76);}[_0x5b30e0(0x177)](_0x4b626b){const _0x1c9468=_0x5b30e0;this[_0x1c9468(0x12f)][_0x1c9468(0x19f)][_0x1c9468(0x177)](_0x4b626b);}[_0x5b30e0(0x14f)](_0x414a9f=!0x1){const _0x2ba998=_0x5b30e0;this[_0x2ba998(0x12f)][_0x2ba998(0x19f)][_0x2ba998(0x14f)](_0x414a9f);}[_0x5b30e0(0x180)](_0x43cb43,_0x3ce7d5){const _0x8a74a8=_0x5b30e0;this[_0x8a74a8(0x12f)][_0x8a74a8(0x151)][_0x8a74a8(0x1cb)](_0x43cb43,_0x3ce7d5);}[_0x5b30e0(0x1c1)](){const _0x157f0a=_0x5b30e0;this[_0x157f0a(0x12f)][_0x157f0a(0x151)][_0x157f0a(0x1c1)]();}[_0x5b30e0(0x154)](){const _0x3e6d52=_0x5b30e0;this[_0x3e6d52(0x12f)][_0x3e6d52(0x19f)][_0x3e6d52(0x11e)]=!0x0;}[_0x5b30e0(0x1be)](){const _0x4f91ad=_0x5b30e0;this[_0x4f91ad(0x12f)][_0x4f91ad(0x19f)][_0x4f91ad(0x11e)]=!0x1;}}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x493bbe=_0xeaed;(function(_0x57dfe2,_0xf75e18){const _0x1adc85=_0xeaed,_0x5b0928=_0x57dfe2();while(!![]){try{const _0x1a5d5f=parseInt(_0x1adc85(0x222))/0x1+parseInt(_0x1adc85(0x21f))/0x2+-parseInt(_0x1adc85(0x21d))/0x3*(-parseInt(_0x1adc85(0x1f6))/0x4)+parseInt(_0x1adc85(0x23f))/0x5+-parseInt(_0x1adc85(0x219))/0x6+-parseInt(_0x1adc85(0x212))/0x7+-parseInt(_0x1adc85(0x23d))/0x8;if(_0x1a5d5f===_0xf75e18)break;else _0x5b0928['push'](_0x5b0928['shift']());}catch(_0x59f623){_0x5b0928['push'](_0x5b0928['shift']());}}}(_0x3078,0x1d6e5));import{CKEditorError as _0x2c910a,ObservableMixin as _0x12fd7c,uid as _0x1be409}from'ckeditor5/src/utils.js';function _0x3078(){const _0x393bb8=['files','filter','_finishContextItemLoading','object\x20with\x20content\x20and\x20type\x20properties','isCurrentDocumentInContext','_finishUploadOperation','_connector','type','_setAddContextOptionsDefaultState','uploadFile','find','contextSent','push','isHidden','ai-chat-url-upload-failed','abortController','init','attributes','fire','_convertTextResourceToFile','length','fetchDocument','addSelectionToContext','abort','startsWith','_mapContextItemToRequestData','text/html','updateCurrentDocument','804clCORq','_config','from','forEach','addToolItemToContext','FILE','ai-chat-resource-no-data','ai-chat-context-unsupported-type','TEXT','_addToConversationContextItem','loadSourceResources','addResourceToContext','_ownerId','isInContext','current-document','code','_updateResourceInContextState','getId','ai-chat-resource-load-failed','values','sources','isCurrentDocumentInConversation','URL','Current\x20document','isSelectionInContext','error','message','_addContextItem','310905akLysw','_createContextItemFromContent','data','document','substring','DOCUMENT','resourceStateChanged','321816NKDKQQ','object','_isResourceInContext','ai-chat-context-invalid-data','186sPuOnC','selection','439328qzrEmA','toolName','clearPendingContextItems','121193yRmYiP','removeFromContext','uploadUrl','uiId','_removeContextItem','version','getData','label','resources','start','mcpServerName','addContextOptionsChanged','resourceId','sourceResourcesLoaded','customItems','name','stack','text/plain','getSentContextItems','addUrlToContext','getPendingContextItems','_pendingContextItems','set','urls','contextItemRemoved','_toggleAddCurrentDocumentOptionVisibility','url','2914016qzUZZV','all','1147665XIvWvB','addCurrentDocumentToContext','text/markdown','HTML','TOOL','sessionId','ai-request-aborted','ai-chat-source-not-found','_findSourceIdsByResourceId','_ongoingUploads','getDocument','delete','ai-chat-document-upload-failed','file-','uploadProgressChanged','removeSelectionFromContext','map','content','get','hidden','SELECTION','_ongoingUploadOperations','_addContextOptionsState','end','contextItemAdded','_getCustomSourcesInitialState','_conversationContextItems','size','contextItemLoadingEnded','populateFromMessage','url-','isReadOnly','addFilesToContext','uploadDocument','MARKDOWN','mapContextItemsToRequestData','has','addToConversationContext','ai-chat-source-resources-load-failed','ai-chat-file-upload-failed','files-','_startUploadOperation','string','File','enabled','getResources'];_0x3078=function(){return _0x393bb8;};return _0x3078();}import{AIContextItemType as _0x35783e,AIContextTextResourceType as _0xde5a2}from'../../aicore/model/aicontext.js';import{escape as _0x5fc93e}from'es-toolkit/compat';import{errorsMap as _0x41d6a6}from'../../errorsmap.js';function _0xeaed(_0x1e6111,_0x11f2f8){const _0x3078bf=_0x3078();return _0xeaed=function(_0xeaedb2,_0x14e910){_0xeaedb2=_0xeaedb2-0x1c0;let _0x125e72=_0x3078bf[_0xeaedb2];return _0x125e72;},_0xeaed(_0x1e6111,_0x11f2f8);}export const AI_CONTEXT_MODEL_EVENT_NAMES=[_0x493bbe(0x1c4),_0x493bbe(0x23a),_0x493bbe(0x1c8),_0x493bbe(0x1e5),_0x493bbe(0x20f),_0x493bbe(0x22d),_0x493bbe(0x22f),_0x493bbe(0x218),_0x493bbe(0x24d)];export class AIChatContext extends _0x12fd7c(){[_0x493bbe(0x1e0)];[_0x493bbe(0x1f7)];[_0x493bbe(0x202)];constructor({connector:_0x268c28,config:_0x534c31,ownerId:_0x2aca78}){const _0xf46996=_0x493bbe;super(),this[_0xf46996(0x1e0)]=_0x268c28,this[_0xf46996(0x1f7)]=_0x534c31,this[_0xf46996(0x202)]=_0x2aca78;}[_0x493bbe(0x1ea)](){const _0x2adea9=_0x493bbe;this[_0x2adea9(0x237)]=new Map(),this[_0x2adea9(0x1c6)]=new Map(),this[_0x2adea9(0x248)]=new Map(),this[_0x2adea9(0x1c1)]=new Map(),this[_0x2adea9(0x1e2)]();}[_0x493bbe(0x236)](){const _0x79f4e6=_0x493bbe;return this[_0x79f4e6(0x237)];}async[_0x493bbe(0x1c9)](_0xd0380a){const _0x2320e5=_0x493bbe,_0x167b3c=await this[_0x2320e5(0x213)](_0xd0380a);return this[_0x2320e5(0x1ff)](_0x167b3c),_0x2320e5(0x204)===_0x167b3c[_0x2320e5(0x225)]&&this[_0x2320e5(0x23b)](),_0x167b3c;}async[_0x493bbe(0x213)](_0xdcd53){const _0x5406fa=_0x493bbe;if(_0xdcd53[_0x5406fa(0x1e1)]===_0x35783e[_0x5406fa(0x217)]){const _0xb29e6=await this[_0x5406fa(0x1e0)][_0x5406fa(0x1ef)](this[_0x5406fa(0x202)],_0xdcd53['id'])[_0x5406fa(0x249)]();return{'id':_0x5406fa(0x204),'uiId':_0x5406fa(0x204),'label':_0x5406fa(0x20d),'type':_0xdcd53[_0x5406fa(0x1e1)],'content':_0xb29e6[_0x5406fa(0x250)],'hidden':this[_0x5406fa(0x1c6)][_0x5406fa(0x1d0)](_0x5406fa(0x204)),'version':_0xb29e6[_0x5406fa(0x1eb)]?.[_0x5406fa(0x227)],'sessionId':_0xb29e6[_0x5406fa(0x1eb)]?.[_0x5406fa(0x244)]};}if(_0xdcd53[_0x5406fa(0x1e1)]===_0x35783e[_0x5406fa(0x243)])return{'id':_0xdcd53['id'],'uiId':_0xdcd53['id'],'label':_0xdcd53[_0x5406fa(0x214)]?.[_0x5406fa(0x229)]||_0xdcd53['id'],'type':_0x35783e[_0x5406fa(0x243)],'mcpServerName':_0xdcd53[_0x5406fa(0x22c)],'toolName':_0xdcd53[_0x5406fa(0x220)],'data':_0xdcd53[_0x5406fa(0x214)]||{}};return{'id':_0xdcd53['id'],'uiId':_0xdcd53['id'],'label':_0xdcd53[_0x5406fa(0x1eb)]?.[_0x5406fa(0x229)]||_0xdcd53[_0x5406fa(0x231)]||_0xdcd53[_0x5406fa(0x23c)]||_0xdcd53['id'],'type':_0xdcd53[_0x5406fa(0x1e1)],..._0xdcd53?.[_0x5406fa(0x1eb)]?.[_0x5406fa(0x22e)]?{'resourceId':_0xdcd53[_0x5406fa(0x1eb)]?.[_0x5406fa(0x22e)]}:{}};}[_0x493bbe(0x234)](){const _0x21df9f=_0x493bbe;return new Map(this[_0x21df9f(0x1c6)]);}[_0x493bbe(0x223)](_0xa1d258){const _0xf5c6b5=_0x493bbe,_0x407af5=this[_0xf5c6b5(0x237)][_0xf5c6b5(0x251)](_0xa1d258);_0x407af5?.[_0xf5c6b5(0x1cb)]||this[_0xf5c6b5(0x226)](_0xa1d258);}[_0x493bbe(0x221)](){const _0x262f47=_0x493bbe;if(0x0===this[_0x262f47(0x237)][_0x262f47(0x1c7)])return;for(const _0x720e4 of this[_0x262f47(0x237)][_0x262f47(0x209)]())this[_0x262f47(0x226)](_0x720e4[_0x262f47(0x225)]);const _0x38febd=this[_0x262f47(0x1c6)][_0x262f47(0x251)](_0x262f47(0x204))||this[_0x262f47(0x237)][_0x262f47(0x251)](_0x262f47(0x204));_0x38febd&&this[_0x262f47(0x211)]({..._0x38febd,'isReadOnly':!0x0,'hidden':!0x0});}[_0x493bbe(0x1d1)](_0x46f6b7){const _0xadaa68=_0x493bbe;for(const _0x2a9cf1 of _0x46f6b7[_0xadaa68(0x209)]())this[_0xadaa68(0x1ff)](_0x2a9cf1);this[_0xadaa68(0x221)](),this[_0xadaa68(0x1ec)](_0xadaa68(0x1e5),{'contextItems':Array[_0xadaa68(0x1f8)](this[_0xadaa68(0x234)]()[_0xadaa68(0x209)]())});}[_0x493bbe(0x1de)](){const _0x18eee6=_0x493bbe;return this[_0x18eee6(0x237)][_0x18eee6(0x1d0)](_0x18eee6(0x204));}[_0x493bbe(0x20e)](){const _0x171904=_0x493bbe;return this[_0x171904(0x237)][_0x171904(0x1d0)](_0x171904(0x21e));}[_0x493bbe(0x20b)](){const _0x260a12=_0x493bbe;return this[_0x260a12(0x1c6)][_0x260a12(0x1d0)](_0x260a12(0x204));}static[_0x493bbe(0x1cf)](_0x374cd7){const _0x55c56a=_0x493bbe;return Array[_0x55c56a(0x1f8)](_0x374cd7[_0x55c56a(0x209)]())[_0x55c56a(0x24f)](_0xb0c833=>this[_0x55c56a(0x1f3)](_0xb0c833))[_0x55c56a(0x1db)](_0x1ad40e=>null!==_0x1ad40e);}async[_0x493bbe(0x1cc)](_0x258f55,_0x5a007c,_0x27997f=_0x35783e[_0x493bbe(0x1fb)]){const _0x6d42e9=_0x493bbe,_0x1e6e3c=_0x6d42e9(0x1d4)+_0x1be409();this[_0x6d42e9(0x1d5)](_0x1e6e3c);try{await Promise[_0x6d42e9(0x23e)](_0x258f55[_0x6d42e9(0x24f)](async _0x197177=>{const _0x4757a6=_0x6d42e9,_0x24d535=_0x4757a6(0x24c)+_0x1be409(),_0x130a50=_0x5fc93e(_0x197177[_0x4757a6(0x231)]);try{this[_0x4757a6(0x211)]({'type':_0x27997f,'label':_0x5a007c?.[_0x4757a6(0x229)]||_0x130a50,'uiId':_0x24d535,'resourceId':_0x5a007c?.[_0x4757a6(0x22e)]},!0x0);const _0x4b2fe6=this[_0x4757a6(0x1e0)][_0x4757a6(0x1e3)](this[_0x4757a6(0x202)],_0x197177,_0x5a007c);this[_0x4757a6(0x248)][_0x4757a6(0x238)](_0x24d535,_0x4b2fe6[_0x4757a6(0x1e9)]);const {id:_0x4a81ab}=await _0x4b2fe6[_0x4757a6(0x207)]();this[_0x4757a6(0x248)][_0x4757a6(0x24a)](_0x24d535),this[_0x4757a6(0x1dc)]({'type':_0x27997f,'id':_0x4a81ab,'label':_0x5a007c?.[_0x4757a6(0x229)]||_0x130a50,'uiId':_0x24d535,'resourceId':_0x5a007c?.[_0x4757a6(0x22e)]},!0x1);}catch(_0x171aa1){this[_0x4757a6(0x248)][_0x4757a6(0x24a)](_0x24d535);if(!(_0x171aa1 instanceof _0x2c910a&&_0x171aa1[_0x4757a6(0x210)][_0x4757a6(0x1f2)](_0x4757a6(0x245)))){const _0x45aae3=_0x41d6a6[_0x4757a6(0x251)](_0x171aa1[_0x4757a6(0x205)])||_0x4757a6(0x1d3),_0x566e87=new _0x2c910a(_0x45aae3,null,{'fileName':_0x130a50,..._0x171aa1});_0x566e87[_0x4757a6(0x232)]=_0x171aa1[_0x4757a6(0x232)],this[_0x4757a6(0x1ec)](_0x4757a6(0x20f),{'error':_0x566e87});}this[_0x4757a6(0x226)](_0x24d535);}}));}finally{this[_0x6d42e9(0x1df)](_0x1e6e3c);}}[_0x493bbe(0x240)](_0x41e677){const _0x18ae15=_0x493bbe;if(this[_0x18ae15(0x1de)]()||!this[_0x18ae15(0x1c2)][_0x18ae15(0x215)][_0x18ae15(0x1d8)])return;const _0x2bc0a2={'type':_0x35783e[_0x18ae15(0x217)],'uiId':_0x18ae15(0x204),'label':_0x41e677,'isReadOnly':this[_0x18ae15(0x1c6)][_0x18ae15(0x1d0)](_0x18ae15(0x204)),'hidden':this[_0x18ae15(0x1c6)][_0x18ae15(0x1d0)](_0x18ae15(0x204))};this[_0x18ae15(0x211)](_0x2bc0a2);}async[_0x493bbe(0x1f5)](_0x246b9b,_0x50834b,_0x30bcde,_0x5b80c9){const _0x516a43=_0x493bbe,_0x78d633=this[_0x516a43(0x237)][_0x516a43(0x251)](_0x516a43(0x204));if(_0x78d633&&_0x246b9b){_0x78d633[_0x516a43(0x21e)]=_0x5b80c9?_0x5b80c9[_0x516a43(0x24f)](_0x4419b5=>({'start':_0x4419b5[_0x516a43(0x22b)],'end':_0x4419b5[_0x516a43(0x1c3)]})):[];try{if(_0x78d633[_0x516a43(0x227)]===_0x50834b)return;const {id:_0x300319}=await this[_0x516a43(0x1e0)][_0x516a43(0x1cd)](this[_0x516a43(0x202)],_0x246b9b,{'version':_0x50834b,'sessionId':_0x30bcde})[_0x516a43(0x207)]();_0x78d633['id']=_0x300319,_0x78d633[_0x516a43(0x250)]=_0x246b9b,_0x78d633[_0x516a43(0x227)]=_0x50834b,_0x78d633[_0x516a43(0x244)]=_0x30bcde;}catch(_0x3b666e){const _0x180960=new _0x2c910a(_0x516a43(0x24b),null);_0x180960[_0x516a43(0x232)]=_0x3b666e[_0x516a43(0x232)],this[_0x516a43(0x1ec)](_0x516a43(0x20f),{'error':_0x180960});}}}[_0x493bbe(0x1f0)](_0x55c87d){const _0x31958c=_0x493bbe;this[_0x31958c(0x211)]({'type':_0x35783e[_0x31958c(0x1c0)],'label':_0x55c87d,'uiId':_0x31958c(0x21e),'content':_0x55c87d});}[_0x493bbe(0x24e)](){const _0x1ae772=_0x493bbe;this[_0x1ae772(0x226)](_0x1ae772(0x21e));}async[_0x493bbe(0x235)](_0x517851,_0x5e833b){const _0x425e3e=_0x493bbe,_0xec71b5=_0x425e3e(0x1ca)+_0x1be409();this[_0x425e3e(0x1d5)](_0xec71b5);const _0x2dac1a=_0x425e3e(0x1ca)+_0x1be409();try{this[_0x425e3e(0x211)]({'type':_0x35783e[_0x425e3e(0x20c)],'label':_0x5e833b?.[_0x425e3e(0x229)]||_0x517851,'uiId':_0x2dac1a,'resourceId':_0x5e833b?.[_0x425e3e(0x22e)]},!0x0);const _0xd490ca=this[_0x425e3e(0x1e0)][_0x425e3e(0x224)](this[_0x425e3e(0x202)],_0x517851,_0x5e833b);this[_0x425e3e(0x248)][_0x425e3e(0x238)](_0x2dac1a,_0xd490ca[_0x425e3e(0x1e9)]);const {id:_0x591db3}=await _0xd490ca[_0x425e3e(0x207)]();this[_0x425e3e(0x248)][_0x425e3e(0x24a)](_0x2dac1a),this[_0x425e3e(0x1dc)]({'type':_0x35783e[_0x425e3e(0x20c)],'id':_0x591db3,'label':_0x5e833b?.[_0x425e3e(0x229)]||_0x517851,'uiId':_0x2dac1a,'resourceId':_0x5e833b?.[_0x425e3e(0x22e)]},!0x1);}catch(_0x680ef1){this[_0x425e3e(0x248)][_0x425e3e(0x24a)](_0x2dac1a),(_0x680ef1[_0x425e3e(0x210)][_0x425e3e(0x1f2)](_0x425e3e(0x245))||this[_0x425e3e(0x1ec)](_0x425e3e(0x20f),{'error':new _0x2c910a(_0x425e3e(0x1e8),this,{'url':_0x517851,'originalError':_0x680ef1}),'url':_0x517851}),this[_0x425e3e(0x226)](_0x2dac1a));}finally{this[_0x425e3e(0x1df)](_0xec71b5);}}[_0x493bbe(0x1fa)](_0x56822d){const _0x465585=_0x493bbe;_0x56822d['id']=_0x56822d['id']??_0x1be409()[_0x465585(0x216)](0x0,0x15),this[_0x465585(0x237)][_0x465585(0x238)](_0x56822d[_0x465585(0x225)],_0x56822d),this[_0x465585(0x1ec)](_0x465585(0x1c4),{'contextItem':_0x56822d,'isLoading':!0x1});}async[_0x493bbe(0x200)](_0x185436,_0x4cd7f1,_0x3a9b12){const _0x5d543e=_0x493bbe,_0x3df85f=this[_0x5d543e(0x1c2)][_0x5d543e(0x20a)][_0x5d543e(0x1e4)](_0x20535a=>_0x20535a['id']===_0x185436);if(!_0x3df85f)return this[_0x5d543e(0x1ec)](_0x5d543e(0x20f),{'error':new _0x2c910a(_0x5d543e(0x246),this,{'sourceId':_0x185436}),'sourceId':_0x185436}),[];try{const _0x38a7ef=(await _0x3df85f[_0x5d543e(0x1d9)](_0x4cd7f1))[_0x5d543e(0x24f)](_0x2cf10f=>{const _0x1331fe=_0x5d543e,_0x2a0784=this[_0x1331fe(0x21b)](_0x2cf10f['id']);return{..._0x2cf10f,'isInContext':_0x2a0784};});return _0x3df85f[_0x5d543e(0x22a)]=_0x38a7ef,this[_0x5d543e(0x1ec)](_0x5d543e(0x22f),{'sourceId':_0x185436,'source':_0x3df85f,'resources':_0x38a7ef,'uid':_0x3a9b12}),_0x38a7ef;}catch(_0x24d4e1){return this[_0x5d543e(0x1ec)](_0x5d543e(0x20f),{'error':new _0x2c910a(_0x5d543e(0x1d2),this,{'sourceId':_0x185436,'originalError':_0x24d4e1}),'sourceId':_0x185436,'sourceLabel':_0x3df85f[_0x5d543e(0x229)]}),[];}}async[_0x493bbe(0x201)](_0x44ec27,_0x2038a7){const _0x591f8e=_0x493bbe;if(this[_0x591f8e(0x21b)](_0x2038a7['id']))return;let _0x54fadd=_0x2038a7[_0x591f8e(0x214)];if(!_0x54fadd&&_0x44ec27[_0x591f8e(0x228)])try{_0x54fadd=await _0x44ec27[_0x591f8e(0x228)](_0x2038a7['id']);}catch(_0x2c03b6){return void this[_0x591f8e(0x1ec)](_0x591f8e(0x20f),{'error':new _0x2c910a(_0x591f8e(0x208),this,{'resourceId':_0x2038a7['id'],'sourceId':_0x44ec27['id'],'originalError':_0x2c03b6}),'resourceId':_0x2038a7['id'],'sourceId':_0x44ec27['id']});}if(_0x54fadd)switch(_0x2038a7[_0x591f8e(0x1e1)]){case _0x35783e[_0x591f8e(0x20c)]:if(_0x591f8e(0x1d6)!=typeof _0x54fadd)return void this[_0x591f8e(0x1ec)](_0x591f8e(0x20f),{'error':new _0x2c910a(_0x591f8e(0x21c),this,{'resourceId':_0x2038a7['id'],'sourceId':_0x44ec27['id'],'expectedType':_0x591f8e(0x1d6),'actualType':typeof _0x54fadd}),'resourceId':_0x2038a7['id'],'sourceId':_0x44ec27['id']});await this[_0x591f8e(0x235)](_0x54fadd,{'label':_0x2038a7[_0x591f8e(0x229)],'resourceId':_0x2038a7['id']});break;case _0x35783e[_0x591f8e(0x1fb)]:if(!(_0x54fadd instanceof File))return void this[_0x591f8e(0x1ec)](_0x591f8e(0x20f),{'error':new _0x2c910a(_0x591f8e(0x21c),this,{'resourceId':_0x2038a7['id'],'sourceId':_0x44ec27['id'],'expectedType':_0x591f8e(0x1d7),'actualType':typeof _0x54fadd}),'resourceId':_0x2038a7['id'],'sourceId':_0x44ec27['id']});await this[_0x591f8e(0x1cc)]([_0x54fadd],{'label':_0x2038a7[_0x591f8e(0x229)],'resourceId':_0x2038a7['id']});break;case _0x35783e[_0x591f8e(0x1fe)]:if(_0x591f8e(0x21a)!=typeof _0x54fadd||!(_0x591f8e(0x250)in _0x54fadd)||!(_0x591f8e(0x1e1)in _0x54fadd))return void this[_0x591f8e(0x1ec)](_0x591f8e(0x20f),{'error':new _0x2c910a(_0x591f8e(0x21c),this,{'resourceId':_0x2038a7['id'],'sourceId':_0x44ec27['id'],'expectedType':_0x591f8e(0x1dd),'actualType':typeof _0x54fadd}),'resourceId':_0x2038a7['id'],'sourceId':_0x44ec27['id']});_0x54fadd=AIChatContext[_0x591f8e(0x1ed)](_0x54fadd,_0x2038a7[_0x591f8e(0x229)]),await this[_0x591f8e(0x1cc)]([_0x54fadd],{'label':_0x2038a7[_0x591f8e(0x229)],'resourceId':_0x2038a7['id']},_0x35783e[_0x591f8e(0x1fe)]);break;case _0x35783e[_0x591f8e(0x243)]:break;default:this[_0x591f8e(0x1ec)](_0x591f8e(0x20f),{'error':new _0x2c910a(_0x591f8e(0x1fd),this,{'resourceId':_0x2038a7['id'],'sourceId':_0x44ec27['id'],'resourceType':_0x2038a7[_0x591f8e(0x1e1)]}),'resourceId':_0x2038a7['id'],'sourceId':_0x44ec27['id']});}else this[_0x591f8e(0x1ec)](_0x591f8e(0x20f),{'error':new _0x2c910a(_0x591f8e(0x1fc),this,{'resourceId':_0x2038a7['id'],'sourceId':_0x44ec27['id']}),'resourceId':_0x2038a7['id'],'sourceId':_0x44ec27['id']});}static[_0x493bbe(0x1ed)](_0x16f088,_0x4c7708){const _0x1d69b9=_0x493bbe;switch(_0x16f088[_0x1d69b9(0x1e1)]){case _0xde5a2[_0x1d69b9(0x1ce)]:return new File([_0x16f088[_0x1d69b9(0x250)]],_0x4c7708,{'type':_0x1d69b9(0x241)});case _0xde5a2[_0x1d69b9(0x242)]:return new File([_0x16f088[_0x1d69b9(0x250)]],_0x4c7708,{'type':_0x1d69b9(0x1f4)});default:return new File([_0x16f088[_0x1d69b9(0x250)]],_0x4c7708,{'type':_0x1d69b9(0x233)});}}static[_0x493bbe(0x1f3)](_0x1c2d9e){const _0x25ad5a=_0x493bbe;switch(_0x1c2d9e[_0x25ad5a(0x1e1)]){case _0x35783e[_0x25ad5a(0x1fb)]:return{'type':_0x35783e[_0x25ad5a(0x1fb)],'id':_0x1c2d9e['id']};case _0x35783e[_0x25ad5a(0x20c)]:return{'type':_0x35783e[_0x25ad5a(0x20c)],'id':_0x1c2d9e['id']};case _0x35783e[_0x25ad5a(0x217)]:return{'type':_0x35783e[_0x25ad5a(0x217)],'id':_0x1c2d9e['id'],..._0x1c2d9e[_0x25ad5a(0x21e)]?.[_0x25ad5a(0x1ee)]&&{'selection':_0x1c2d9e[_0x25ad5a(0x21e)]}};case _0x35783e[_0x25ad5a(0x1fe)]:return{'type':_0x35783e[_0x25ad5a(0x1fb)],'id':_0x1c2d9e['id']};case _0x35783e[_0x25ad5a(0x243)]:{const _0x1ccfe0=_0x1c2d9e;return{'type':_0x35783e[_0x25ad5a(0x243)],'mcpServerName':_0x1ccfe0[_0x25ad5a(0x22c)],'toolName':_0x1ccfe0[_0x25ad5a(0x220)],'data':_0x1ccfe0[_0x25ad5a(0x214)],'id':_0x1ccfe0['id']};}default:return null;}}[_0x493bbe(0x211)](_0x26ebea,_0x4f00a4=!0x1){const _0x193068=_0x493bbe;if(this[_0x193068(0x237)][_0x193068(0x238)](_0x26ebea[_0x193068(0x225)],_0x26ebea),_0x26ebea[_0x193068(0x252)]||this[_0x193068(0x1ec)](_0x193068(0x1c4),{'contextItem':_0x26ebea,'isLoading':_0x4f00a4}),_0x193068(0x204)===_0x26ebea[_0x193068(0x225)]&&this[_0x193068(0x23b)](),_0x26ebea[_0x193068(0x22e)]){const _0x6b0400=this[_0x193068(0x247)](_0x26ebea[_0x193068(0x22e)]);_0x6b0400&&_0x6b0400[_0x193068(0x1f9)](_0x32585c=>{const _0x58e5bb=_0x193068;this[_0x58e5bb(0x206)](_0x32585c,_0x26ebea[_0x58e5bb(0x22e)],!0x0);});}}[_0x493bbe(0x226)](_0x39a985){const _0x2e71fe=_0x493bbe,_0x4efa6a=this[_0x2e71fe(0x237)][_0x2e71fe(0x251)](_0x39a985),_0x323d35=this[_0x2e71fe(0x248)][_0x2e71fe(0x251)](_0x39a985);if(_0x323d35&&(_0x323d35[_0x2e71fe(0x1f1)](),this[_0x2e71fe(0x248)][_0x2e71fe(0x24a)](_0x39a985)),_0x4efa6a?.[_0x2e71fe(0x22e)]){const _0x2458f0=this[_0x2e71fe(0x247)](_0x4efa6a[_0x2e71fe(0x22e)]);_0x2458f0&&_0x2458f0[_0x2e71fe(0x1f9)](_0x27975c=>{const _0x47f031=_0x2e71fe;this[_0x47f031(0x206)](_0x27975c,_0x4efa6a[_0x47f031(0x22e)],!0x1);});}this[_0x2e71fe(0x237)][_0x2e71fe(0x24a)](_0x39a985),this[_0x2e71fe(0x1ec)](_0x2e71fe(0x23a),{'uiId':_0x39a985,'type':_0x4efa6a?.[_0x2e71fe(0x1e1)]}),_0x2e71fe(0x204)===_0x39a985&&this[_0x2e71fe(0x23b)]();}[_0x493bbe(0x1dc)](_0x17ca79,_0x5a4f59){const _0x5a82c1=_0x493bbe;if(this[_0x5a82c1(0x237)][_0x5a82c1(0x1d0)](_0x17ca79[_0x5a82c1(0x225)])&&(this[_0x5a82c1(0x237)][_0x5a82c1(0x238)](_0x17ca79[_0x5a82c1(0x225)],_0x17ca79),this[_0x5a82c1(0x1ec)](_0x5a82c1(0x1c8),{'contextItem':_0x17ca79,'isLoading':_0x5a4f59}),_0x17ca79[_0x5a82c1(0x22e)])){const _0x37c029=this[_0x5a82c1(0x247)](_0x17ca79[_0x5a82c1(0x22e)]);_0x37c029&&_0x37c029[_0x5a82c1(0x1f9)](_0x4b66c6=>{const _0x19d845=_0x5a82c1;this[_0x19d845(0x206)](_0x4b66c6,_0x17ca79[_0x19d845(0x22e)],!0x0);});}}[_0x493bbe(0x1ff)](_0x34ef19){const _0x3d29ec=_0x493bbe;this[_0x3d29ec(0x1c6)][_0x3d29ec(0x238)](_0x34ef19[_0x3d29ec(0x225)],_0x34ef19);}[_0x493bbe(0x1e2)](){const _0x1fa86a=_0x493bbe;this[_0x1fa86a(0x1c2)]={'document':{'enabled':!0x1!==this[_0x1fa86a(0x1f7)]?.[_0x1fa86a(0x215)]?.[_0x1fa86a(0x1d8)],'isHidden':!0x1},'urls':{'enabled':!0x1!==this[_0x1fa86a(0x1f7)]?.[_0x1fa86a(0x239)]?.[_0x1fa86a(0x1d8)]},'files':{'enabled':!0x1!==this[_0x1fa86a(0x1f7)]?.[_0x1fa86a(0x1da)]?.[_0x1fa86a(0x1d8)]},'sources':this[_0x1fa86a(0x1c5)](),'customItems':this[_0x1fa86a(0x1f7)]?.[_0x1fa86a(0x230)]?.[_0x1fa86a(0x24f)](_0x5bce5b=>({..._0x5bce5b,'enabled':!0x0}))??[]},this[_0x1fa86a(0x1ec)](_0x1fa86a(0x22d),{'options':this[_0x1fa86a(0x1c2)]});}[_0x493bbe(0x1c5)](){const _0x26da0a=_0x493bbe;return this[_0x26da0a(0x1f7)]?.[_0x26da0a(0x20a)]?.[_0x26da0a(0x24f)](_0x442944=>({..._0x442944,'resources':[]}))??[];}[_0x493bbe(0x23b)](){const _0x5d390d=_0x493bbe,_0x19325e=this[_0x5d390d(0x1de)]()||this[_0x5d390d(0x20b)]();this[_0x5d390d(0x1c2)][_0x5d390d(0x215)][_0x5d390d(0x1e7)]=_0x19325e,this[_0x5d390d(0x1ec)](_0x5d390d(0x22d),{'options':this[_0x5d390d(0x1c2)]});}[_0x493bbe(0x21b)](_0x5e3801){const _0xd89e57=_0x493bbe;for(const _0x4883c5 of this[_0xd89e57(0x237)][_0xd89e57(0x209)]())if(_0x4883c5[_0xd89e57(0x22e)]===_0x5e3801)return!0x0;for(const _0x204c05 of this[_0xd89e57(0x1c6)][_0xd89e57(0x209)]())if(_0x204c05[_0xd89e57(0x22e)]===_0x5e3801)return!0x0;return!0x1;}[_0x493bbe(0x247)](_0x5efa79){const _0x1806a5=_0x493bbe,_0x26131e=[];for(const _0x206988 of this[_0x1806a5(0x1c2)][_0x1806a5(0x20a)]){_0x206988[_0x1806a5(0x22a)][_0x1806a5(0x1e4)](_0x35c22d=>_0x35c22d['id']===_0x5efa79)&&_0x26131e[_0x1806a5(0x1e6)](_0x206988['id']);}return 0x0===_0x26131e[_0x1806a5(0x1ee)]?null:_0x26131e;}[_0x493bbe(0x206)](_0x4a3f10,_0x4e4678,_0x4dbb0a){const _0x4496e9=_0x493bbe,_0x48cc72=this[_0x4496e9(0x1c2)][_0x4496e9(0x20a)][_0x4496e9(0x1e4)](_0xafb8=>_0xafb8['id']===_0x4a3f10);if(!_0x48cc72)return;const _0x1f7b53=_0x48cc72[_0x4496e9(0x22a)][_0x4496e9(0x1e4)](_0x28c526=>_0x28c526['id']===_0x4e4678);_0x1f7b53&&(_0x1f7b53[_0x4496e9(0x203)]=_0x4dbb0a,this[_0x4496e9(0x1ec)](_0x4496e9(0x218),{'sourceId':_0x4a3f10,'resourceId':_0x4e4678,'isInContext':_0x4dbb0a}));}[_0x493bbe(0x1d5)](_0x33cdef){const _0xf3f5d3=_0x493bbe;this[_0xf3f5d3(0x1c1)][_0xf3f5d3(0x238)](_0x33cdef,!0x0),this[_0xf3f5d3(0x1c1)][_0xf3f5d3(0x1c7)]&&this[_0xf3f5d3(0x1ec)](_0xf3f5d3(0x24d),{'isUploadInProgress':!0x0});}[_0x493bbe(0x1df)](_0xfd11){const _0x40b74d=_0x493bbe;this[_0x40b74d(0x1c1)][_0x40b74d(0x24a)](_0xfd11),0x0===this[_0x40b74d(0x1c1)][_0x40b74d(0x1c7)]&&this[_0x40b74d(0x1ec)](_0x40b74d(0x24d),{'isUploadInProgress':!0x1});}}
23
+ const _0x93f129=_0x426d;(function(_0x29db95,_0x4f08be){const _0x3b3c60=_0x426d,_0x1f9660=_0x29db95();while(!![]){try{const _0x58297f=-parseInt(_0x3b3c60(0x161))/0x1+parseInt(_0x3b3c60(0x186))/0x2*(parseInt(_0x3b3c60(0x183))/0x3)+-parseInt(_0x3b3c60(0x154))/0x4*(parseInt(_0x3b3c60(0x19d))/0x5)+-parseInt(_0x3b3c60(0x15a))/0x6*(-parseInt(_0x3b3c60(0x17d))/0x7)+-parseInt(_0x3b3c60(0x1b4))/0x8*(-parseInt(_0x3b3c60(0x142))/0x9)+parseInt(_0x3b3c60(0x164))/0xa*(-parseInt(_0x3b3c60(0x171))/0xb)+-parseInt(_0x3b3c60(0x15b))/0xc*(-parseInt(_0x3b3c60(0x1ae))/0xd);if(_0x58297f===_0x4f08be)break;else _0x1f9660['push'](_0x1f9660['shift']());}catch(_0x3e3595){_0x1f9660['push'](_0x1f9660['shift']());}}}(_0x55eb,0x4cc47));import{CKEditorError as _0x3b1bc7,ObservableMixin as _0x171529,uid as _0x123aea}from'ckeditor5/src/utils.js';function _0x55eb(){const _0x5e8ced=['59753EAbzcy','isHidden','ai-chat-document-upload-failed','918390bVVKDP','addSelectionToContext','contextItemRemoved','TOOL','SELECTION','map','attributes','message','text/markdown','URL','selection','_isResourceInContext','file-','22pNHvxr','ai-chat-url-upload-failed','length','uploadUrl','clearPendingContextItems','abortController','substring','stack','_addContextOptionsState','_ongoingUploadOperations','size','addResourceToContext','35YjYKpN','Current\x20document','_addContextItem','removeSelectionFromContext','getData','addToConversationContext','96051DlfVSb','all','resourceStateChanged','28GVMWKb','object','delete','url-','ai-chat-source-resources-load-failed','_createContextItemFromContent','addUrlToContext','_updateResourceInContextState','isReadOnly','error','toolName','getDocument','_setAddContextOptionsDefaultState','getPendingContextItems','ai-chat-context-invalid-data','document','filter','ai-chat-resource-load-failed','_conversationContextItems','resourceId','contextItemAdded','uploadDocument','find','5YDjBWi','from','urls','abort','label','_addToConversationContextItem','isCurrentDocumentInContext','addCurrentDocumentToContext','enabled','loadSourceResources','_toggleAddCurrentDocumentOptionVisibility','DOCUMENT','data','MARKDOWN','_ownerId','_finishContextItemLoading','type','183716VEepgu','addToolItemToContext','isSelectionInContext','files','_config','customItems','88ClthGE','push','File','FILE','_getCustomSourcesInitialState','string','ai-chat-source-not-found','current-document','mcpServerName','isInContext','get','sources','populateFromMessage','version','mapContextItemsToRequestData','text/plain','getId','name','addContextOptionsChanged','_finishUploadOperation','uploadFile','uploadProgressChanged','updateCurrentDocument','values','fetchDocument','resources','content','sourceResourcesLoaded','_ongoingUploads','HTML','sessionId','startsWith','TEXT','url','set','_pendingContextItems','forEach','_convertTextResourceToFile','97974GgJfdH','_mapContextItemToRequestData','fire','_removeContextItem','removeFromContext','hidden','addFilesToContext','ai-chat-resource-no-data','has','_connector','files-','end','text/html','init','_findSourceIdsByResourceId','uiId','ai-chat-context-unsupported-type','isCurrentDocumentInConversation','307460OkLZvJ','getSentContextItems','_startUploadOperation','code','object\x20with\x20content\x20and\x20type\x20properties','ai-chat-file-upload-failed','29226fMPtBn','36qxcjpY','contextItemLoadingEnded','getResources','start','contextSent','ai-request-aborted'];_0x55eb=function(){return _0x5e8ced;};return _0x55eb();}import{AIContextItemType as _0x14c2d3,AIContextTextResourceType as _0x373519}from'../../aicore/model/aicontext.js';import{escape as _0x524adf}from'es-toolkit/compat';import{errorsMap as _0x59d93c}from'../../errorsmap.js';export const AI_CONTEXT_MODEL_EVENT_NAMES=[_0x93f129(0x19a),_0x93f129(0x166),_0x93f129(0x15c),_0x93f129(0x15f),_0x93f129(0x18f),_0x93f129(0x1c6),_0x93f129(0x137),_0x93f129(0x185),_0x93f129(0x131)];function _0x426d(_0x17d6f8,_0x59412a){const _0x55eb86=_0x55eb();return _0x426d=function(_0x426dcc,_0x105091){_0x426dcc=_0x426dcc-0x131;let _0x39fa0b=_0x55eb86[_0x426dcc];return _0x39fa0b;},_0x426d(_0x17d6f8,_0x59412a);}export class AIChatContext extends _0x171529(){[_0x93f129(0x14b)];[_0x93f129(0x1b2)];[_0x93f129(0x1ab)];constructor({connector:_0x10dd4e,config:_0x2a7203,ownerId:_0x4435d9}){const _0x2a5124=_0x93f129;super(),this[_0x2a5124(0x14b)]=_0x10dd4e,this[_0x2a5124(0x1b2)]=_0x2a7203,this[_0x2a5124(0x1ab)]=_0x4435d9;}[_0x93f129(0x14f)](){const _0x2fdb9e=_0x93f129;this[_0x2fdb9e(0x13f)]=new Map(),this[_0x2fdb9e(0x198)]=new Map(),this[_0x2fdb9e(0x138)]=new Map(),this[_0x2fdb9e(0x17a)]=new Map(),this[_0x2fdb9e(0x192)]();}[_0x93f129(0x193)](){const _0x3b0809=_0x93f129;return this[_0x3b0809(0x13f)];}async[_0x93f129(0x1c0)](_0x2bf1f6){const _0x1a5c24=_0x93f129,_0x2b735f=await this[_0x1a5c24(0x18b)](_0x2bf1f6);return this[_0x1a5c24(0x1a2)](_0x2b735f),_0x1a5c24(0x1bb)===_0x2b735f[_0x1a5c24(0x151)]&&this[_0x1a5c24(0x1a7)](),_0x2b735f;}async[_0x93f129(0x18b)](_0x38212a){const _0x313478=_0x93f129;if(_0x38212a[_0x313478(0x1ad)]===_0x14c2d3[_0x313478(0x1a8)]){const _0x5b0e1b=await this[_0x313478(0x14b)][_0x313478(0x134)](this[_0x313478(0x1ab)],_0x38212a['id'])[_0x313478(0x191)]();return{'id':_0x313478(0x1bb),'uiId':_0x313478(0x1bb),'label':_0x313478(0x17e),'type':_0x38212a[_0x313478(0x1ad)],'content':_0x5b0e1b[_0x313478(0x136)],'hidden':this[_0x313478(0x198)][_0x313478(0x14a)](_0x313478(0x1bb)),'version':_0x5b0e1b[_0x313478(0x16a)]?.[_0x313478(0x1c1)],'sessionId':_0x5b0e1b[_0x313478(0x16a)]?.[_0x313478(0x13a)]};}if(_0x38212a[_0x313478(0x1ad)]===_0x14c2d3[_0x313478(0x167)])return{'id':_0x38212a['id'],'uiId':_0x38212a['id'],'label':_0x38212a[_0x313478(0x1a9)]?.[_0x313478(0x1a1)]||_0x38212a['id'],'type':_0x14c2d3[_0x313478(0x167)],'mcpServerName':_0x38212a[_0x313478(0x1bc)],'toolName':_0x38212a[_0x313478(0x190)],'data':_0x38212a[_0x313478(0x1a9)]||{}};return{'id':_0x38212a['id'],'uiId':_0x38212a['id'],'label':_0x38212a[_0x313478(0x16a)]?.[_0x313478(0x1a1)]||_0x38212a[_0x313478(0x1c5)]||_0x38212a[_0x313478(0x13d)]||_0x38212a['id'],'type':_0x38212a[_0x313478(0x1ad)],..._0x38212a?.[_0x313478(0x16a)]?.[_0x313478(0x199)]?{'resourceId':_0x38212a[_0x313478(0x16a)]?.[_0x313478(0x199)]}:{}};}[_0x93f129(0x155)](){const _0x187b59=_0x93f129;return new Map(this[_0x187b59(0x198)]);}[_0x93f129(0x146)](_0x176290){const _0xc92e49=_0x93f129,_0x8bb269=this[_0xc92e49(0x13f)][_0xc92e49(0x1be)](_0x176290);_0x8bb269?.[_0xc92e49(0x18e)]||this[_0xc92e49(0x145)](_0x176290);}[_0x93f129(0x175)](){const _0x539410=_0x93f129;if(0x0===this[_0x539410(0x13f)][_0x539410(0x17b)])return;for(const _0x5b2496 of this[_0x539410(0x13f)][_0x539410(0x133)]())this[_0x539410(0x145)](_0x5b2496[_0x539410(0x151)]);const _0x5bc520=this[_0x539410(0x198)][_0x539410(0x1be)](_0x539410(0x1bb))||this[_0x539410(0x13f)][_0x539410(0x1be)](_0x539410(0x1bb));_0x5bc520&&this[_0x539410(0x17f)]({..._0x5bc520,'isReadOnly':!0x0,'hidden':!0x0});}[_0x93f129(0x182)](_0x104287){const _0x2ab169=_0x93f129;for(const _0x120989 of _0x104287[_0x2ab169(0x133)]())this[_0x2ab169(0x1a2)](_0x120989);this[_0x2ab169(0x175)](),this[_0x2ab169(0x144)](_0x2ab169(0x15f),{'contextItems':Array[_0x2ab169(0x19e)](this[_0x2ab169(0x155)]()[_0x2ab169(0x133)]())});}[_0x93f129(0x1a3)](){const _0x1cde3e=_0x93f129;return this[_0x1cde3e(0x13f)][_0x1cde3e(0x14a)](_0x1cde3e(0x1bb));}[_0x93f129(0x1b0)](){const _0x3f6d12=_0x93f129;return this[_0x3f6d12(0x13f)][_0x3f6d12(0x14a)](_0x3f6d12(0x16e));}[_0x93f129(0x153)](){const _0x147abb=_0x93f129;return this[_0x147abb(0x198)][_0x147abb(0x14a)](_0x147abb(0x1bb));}static[_0x93f129(0x1c2)](_0xe91a27){const _0x561fcf=_0x93f129;return Array[_0x561fcf(0x19e)](_0xe91a27[_0x561fcf(0x133)]())[_0x561fcf(0x169)](_0x17c99d=>this[_0x561fcf(0x143)](_0x17c99d))[_0x561fcf(0x196)](_0x1896aa=>null!==_0x1896aa);}async[_0x93f129(0x148)](_0x504e23,_0x1d9aa7,_0xae810a=_0x14c2d3[_0x93f129(0x1b7)]){const _0x42a5bd=_0x93f129,_0x21024f=_0x42a5bd(0x14c)+_0x123aea();this[_0x42a5bd(0x156)](_0x21024f);try{await Promise[_0x42a5bd(0x184)](_0x504e23[_0x42a5bd(0x169)](async _0x1df579=>{const _0x3dc140=_0x42a5bd,_0x32ba89=_0x3dc140(0x170)+_0x123aea(),_0x27eacb=_0x524adf(_0x1df579[_0x3dc140(0x1c5)]);try{this[_0x3dc140(0x17f)]({'type':_0xae810a,'label':_0x1d9aa7?.[_0x3dc140(0x1a1)]||_0x27eacb,'uiId':_0x32ba89,'resourceId':_0x1d9aa7?.[_0x3dc140(0x199)]},!0x0);const _0x1733cc=this[_0x3dc140(0x14b)][_0x3dc140(0x1c8)](this[_0x3dc140(0x1ab)],_0x1df579,_0x1d9aa7);this[_0x3dc140(0x138)][_0x3dc140(0x13e)](_0x32ba89,_0x1733cc[_0x3dc140(0x176)]);const {id:_0x4559}=await _0x1733cc[_0x3dc140(0x1c4)]();this[_0x3dc140(0x138)][_0x3dc140(0x188)](_0x32ba89),this[_0x3dc140(0x1ac)]({'type':_0xae810a,'id':_0x4559,'label':_0x1d9aa7?.[_0x3dc140(0x1a1)]||_0x27eacb,'uiId':_0x32ba89,'resourceId':_0x1d9aa7?.[_0x3dc140(0x199)]},!0x1);}catch(_0x4a1a28){this[_0x3dc140(0x138)][_0x3dc140(0x188)](_0x32ba89);if(!(_0x4a1a28 instanceof _0x3b1bc7&&_0x4a1a28[_0x3dc140(0x16b)][_0x3dc140(0x13b)](_0x3dc140(0x160)))){const _0x3d293d=_0x59d93c[_0x3dc140(0x1be)](_0x4a1a28[_0x3dc140(0x157)])||_0x3dc140(0x159),_0x554262=new _0x3b1bc7(_0x3d293d,null,{'fileName':_0x27eacb,..._0x4a1a28});_0x554262[_0x3dc140(0x178)]=_0x4a1a28[_0x3dc140(0x178)],this[_0x3dc140(0x144)](_0x3dc140(0x18f),{'error':_0x554262});}this[_0x3dc140(0x145)](_0x32ba89);}}));}finally{this[_0x42a5bd(0x1c7)](_0x21024f);}}[_0x93f129(0x1a4)](_0x4f2d19){const _0x443657=_0x93f129;if(this[_0x443657(0x1a3)]()||!this[_0x443657(0x179)][_0x443657(0x195)][_0x443657(0x1a5)])return;const _0x5654bf={'type':_0x14c2d3[_0x443657(0x1a8)],'uiId':_0x443657(0x1bb),'label':_0x4f2d19,'isReadOnly':this[_0x443657(0x198)][_0x443657(0x14a)](_0x443657(0x1bb)),'hidden':this[_0x443657(0x198)][_0x443657(0x14a)](_0x443657(0x1bb))};this[_0x443657(0x17f)](_0x5654bf);}async[_0x93f129(0x132)](_0x2f8652,_0x34fab9,_0x3584f1,_0x2c56d0){const _0x39c6a8=_0x93f129,_0x4a4473=this[_0x39c6a8(0x13f)][_0x39c6a8(0x1be)](_0x39c6a8(0x1bb));if(_0x4a4473&&_0x2f8652){_0x4a4473[_0x39c6a8(0x16e)]=_0x2c56d0?_0x2c56d0[_0x39c6a8(0x169)](_0x2d3828=>({'start':_0x2d3828[_0x39c6a8(0x15e)],'end':_0x2d3828[_0x39c6a8(0x14d)]})):[];try{if(_0x4a4473[_0x39c6a8(0x1c1)]===_0x34fab9)return;const {id:_0x10da25}=await this[_0x39c6a8(0x14b)][_0x39c6a8(0x19b)](this[_0x39c6a8(0x1ab)],_0x2f8652,{'version':_0x34fab9,'sessionId':_0x3584f1})[_0x39c6a8(0x1c4)]();_0x4a4473['id']=_0x10da25,_0x4a4473[_0x39c6a8(0x136)]=_0x2f8652,_0x4a4473[_0x39c6a8(0x1c1)]=_0x34fab9,_0x4a4473[_0x39c6a8(0x13a)]=_0x3584f1;}catch(_0x5aeac3){const _0x4584d9=new _0x3b1bc7(_0x39c6a8(0x163),null);_0x4584d9[_0x39c6a8(0x178)]=_0x5aeac3[_0x39c6a8(0x178)],this[_0x39c6a8(0x144)](_0x39c6a8(0x18f),{'error':_0x4584d9});}}}[_0x93f129(0x165)](_0xe7e271){const _0x5ee0b6=_0x93f129;this[_0x5ee0b6(0x17f)]({'type':_0x14c2d3[_0x5ee0b6(0x168)],'label':_0xe7e271,'uiId':_0x5ee0b6(0x16e),'content':_0xe7e271});}[_0x93f129(0x180)](){const _0x5b3a75=_0x93f129;this[_0x5b3a75(0x145)](_0x5b3a75(0x16e));}async[_0x93f129(0x18c)](_0x37ff5f,_0x246c05){const _0x257470=_0x93f129,_0x83716d=_0x257470(0x189)+_0x123aea();this[_0x257470(0x156)](_0x83716d);const _0x389931=_0x257470(0x189)+_0x123aea();try{this[_0x257470(0x17f)]({'type':_0x14c2d3[_0x257470(0x16d)],'label':_0x246c05?.[_0x257470(0x1a1)]||_0x37ff5f,'uiId':_0x389931,'resourceId':_0x246c05?.[_0x257470(0x199)]},!0x0);const _0x52ab28=this[_0x257470(0x14b)][_0x257470(0x174)](this[_0x257470(0x1ab)],_0x37ff5f,_0x246c05);this[_0x257470(0x138)][_0x257470(0x13e)](_0x389931,_0x52ab28[_0x257470(0x176)]);const {id:_0x3542f1}=await _0x52ab28[_0x257470(0x1c4)]();this[_0x257470(0x138)][_0x257470(0x188)](_0x389931),this[_0x257470(0x1ac)]({'type':_0x14c2d3[_0x257470(0x16d)],'id':_0x3542f1,'label':_0x246c05?.[_0x257470(0x1a1)]||_0x37ff5f,'uiId':_0x389931,'resourceId':_0x246c05?.[_0x257470(0x199)]},!0x1);}catch(_0x2250eb){this[_0x257470(0x138)][_0x257470(0x188)](_0x389931),(_0x2250eb[_0x257470(0x16b)][_0x257470(0x13b)](_0x257470(0x160))||this[_0x257470(0x144)](_0x257470(0x18f),{'error':new _0x3b1bc7(_0x257470(0x172),this,{'url':_0x37ff5f,'originalError':_0x2250eb}),'url':_0x37ff5f}),this[_0x257470(0x145)](_0x389931));}finally{this[_0x257470(0x1c7)](_0x83716d);}}[_0x93f129(0x1af)](_0x3e290c){const _0x308066=_0x93f129;_0x3e290c['id']=_0x3e290c['id']??_0x123aea()[_0x308066(0x177)](0x0,0x15),this[_0x308066(0x13f)][_0x308066(0x13e)](_0x3e290c[_0x308066(0x151)],_0x3e290c),this[_0x308066(0x144)](_0x308066(0x19a),{'contextItem':_0x3e290c,'isLoading':!0x1});}async[_0x93f129(0x1a6)](_0x1e116f,_0x2b33c8,_0x22f38f){const _0x2e5a51=_0x93f129,_0x5c05e8=this[_0x2e5a51(0x179)][_0x2e5a51(0x1bf)][_0x2e5a51(0x19c)](_0x3cfd13=>_0x3cfd13['id']===_0x1e116f);if(!_0x5c05e8)return this[_0x2e5a51(0x144)](_0x2e5a51(0x18f),{'error':new _0x3b1bc7(_0x2e5a51(0x1ba),this,{'sourceId':_0x1e116f}),'sourceId':_0x1e116f}),[];try{const _0x4e50d5=(await _0x5c05e8[_0x2e5a51(0x15d)](_0x2b33c8))[_0x2e5a51(0x169)](_0x3c14bc=>{const _0x577c9a=_0x2e5a51,_0x2582f0=this[_0x577c9a(0x16f)](_0x3c14bc['id']);return{..._0x3c14bc,'isInContext':_0x2582f0};});return _0x5c05e8[_0x2e5a51(0x135)]=_0x4e50d5,this[_0x2e5a51(0x144)](_0x2e5a51(0x137),{'sourceId':_0x1e116f,'source':_0x5c05e8,'resources':_0x4e50d5,'uid':_0x22f38f}),_0x4e50d5;}catch(_0x114e29){return this[_0x2e5a51(0x144)](_0x2e5a51(0x18f),{'error':new _0x3b1bc7(_0x2e5a51(0x18a),this,{'sourceId':_0x1e116f,'originalError':_0x114e29}),'sourceId':_0x1e116f,'sourceLabel':_0x5c05e8[_0x2e5a51(0x1a1)]}),[];}}async[_0x93f129(0x17c)](_0x2047ee,_0xc8d2e1){const _0x509c02=_0x93f129;if(this[_0x509c02(0x16f)](_0xc8d2e1['id']))return;let _0x56fdde=_0xc8d2e1[_0x509c02(0x1a9)];if(!_0x56fdde&&_0x2047ee[_0x509c02(0x181)])try{_0x56fdde=await _0x2047ee[_0x509c02(0x181)](_0xc8d2e1['id']);}catch(_0x1171c0){return void this[_0x509c02(0x144)](_0x509c02(0x18f),{'error':new _0x3b1bc7(_0x509c02(0x197),this,{'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id'],'originalError':_0x1171c0}),'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id']});}if(_0x56fdde)switch(_0xc8d2e1[_0x509c02(0x1ad)]){case _0x14c2d3[_0x509c02(0x16d)]:if(_0x509c02(0x1b9)!=typeof _0x56fdde)return void this[_0x509c02(0x144)](_0x509c02(0x18f),{'error':new _0x3b1bc7(_0x509c02(0x194),this,{'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id'],'expectedType':_0x509c02(0x1b9),'actualType':typeof _0x56fdde}),'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id']});await this[_0x509c02(0x18c)](_0x56fdde,{'label':_0xc8d2e1[_0x509c02(0x1a1)],'resourceId':_0xc8d2e1['id']});break;case _0x14c2d3[_0x509c02(0x1b7)]:if(!(_0x56fdde instanceof File))return void this[_0x509c02(0x144)](_0x509c02(0x18f),{'error':new _0x3b1bc7(_0x509c02(0x194),this,{'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id'],'expectedType':_0x509c02(0x1b6),'actualType':typeof _0x56fdde}),'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id']});await this[_0x509c02(0x148)]([_0x56fdde],{'label':_0xc8d2e1[_0x509c02(0x1a1)],'resourceId':_0xc8d2e1['id']});break;case _0x14c2d3[_0x509c02(0x13c)]:if(_0x509c02(0x187)!=typeof _0x56fdde||!(_0x509c02(0x136)in _0x56fdde)||!(_0x509c02(0x1ad)in _0x56fdde))return void this[_0x509c02(0x144)](_0x509c02(0x18f),{'error':new _0x3b1bc7(_0x509c02(0x194),this,{'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id'],'expectedType':_0x509c02(0x158),'actualType':typeof _0x56fdde}),'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id']});_0x56fdde=AIChatContext[_0x509c02(0x141)](_0x56fdde,_0xc8d2e1[_0x509c02(0x1a1)]),await this[_0x509c02(0x148)]([_0x56fdde],{'label':_0xc8d2e1[_0x509c02(0x1a1)],'resourceId':_0xc8d2e1['id']},_0x14c2d3[_0x509c02(0x13c)]);break;case _0x14c2d3[_0x509c02(0x167)]:break;default:this[_0x509c02(0x144)](_0x509c02(0x18f),{'error':new _0x3b1bc7(_0x509c02(0x152),this,{'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id'],'resourceType':_0xc8d2e1[_0x509c02(0x1ad)]}),'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id']});}else this[_0x509c02(0x144)](_0x509c02(0x18f),{'error':new _0x3b1bc7(_0x509c02(0x149),this,{'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id']}),'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id']});}static[_0x93f129(0x141)](_0x117620,_0x8006fc){const _0x15dca8=_0x93f129;switch(_0x117620[_0x15dca8(0x1ad)]){case _0x373519[_0x15dca8(0x1aa)]:return new File([_0x117620[_0x15dca8(0x136)]],_0x8006fc,{'type':_0x15dca8(0x16c)});case _0x373519[_0x15dca8(0x139)]:return new File([_0x117620[_0x15dca8(0x136)]],_0x8006fc,{'type':_0x15dca8(0x14e)});default:return new File([_0x117620[_0x15dca8(0x136)]],_0x8006fc,{'type':_0x15dca8(0x1c3)});}}static[_0x93f129(0x143)](_0x15cb6c){const _0x3aecf8=_0x93f129;switch(_0x15cb6c[_0x3aecf8(0x1ad)]){case _0x14c2d3[_0x3aecf8(0x1b7)]:return{'type':_0x14c2d3[_0x3aecf8(0x1b7)],'id':_0x15cb6c['id']};case _0x14c2d3[_0x3aecf8(0x16d)]:return{'type':_0x14c2d3[_0x3aecf8(0x16d)],'id':_0x15cb6c['id']};case _0x14c2d3[_0x3aecf8(0x1a8)]:return{'type':_0x14c2d3[_0x3aecf8(0x1a8)],'id':_0x15cb6c['id'],..._0x15cb6c[_0x3aecf8(0x16e)]?.[_0x3aecf8(0x173)]&&{'selection':_0x15cb6c[_0x3aecf8(0x16e)]}};case _0x14c2d3[_0x3aecf8(0x13c)]:return{'type':_0x14c2d3[_0x3aecf8(0x1b7)],'id':_0x15cb6c['id']};case _0x14c2d3[_0x3aecf8(0x167)]:{const _0x507a26=_0x15cb6c;return{'type':_0x14c2d3[_0x3aecf8(0x167)],'mcpServerName':_0x507a26[_0x3aecf8(0x1bc)],'toolName':_0x507a26[_0x3aecf8(0x190)],'data':_0x507a26[_0x3aecf8(0x1a9)],'id':_0x507a26['id']};}default:return null;}}[_0x93f129(0x17f)](_0x5529f8,_0x46c139=!0x1){const _0x5c54c7=_0x93f129;if(this[_0x5c54c7(0x13f)][_0x5c54c7(0x13e)](_0x5529f8[_0x5c54c7(0x151)],_0x5529f8),_0x5529f8[_0x5c54c7(0x147)]||this[_0x5c54c7(0x144)](_0x5c54c7(0x19a),{'contextItem':_0x5529f8,'isLoading':_0x46c139}),_0x5c54c7(0x1bb)===_0x5529f8[_0x5c54c7(0x151)]&&this[_0x5c54c7(0x1a7)](),_0x5529f8[_0x5c54c7(0x199)]){const _0xeefa35=this[_0x5c54c7(0x150)](_0x5529f8[_0x5c54c7(0x199)]);_0xeefa35&&_0xeefa35[_0x5c54c7(0x140)](_0x57b59f=>{const _0x51d31b=_0x5c54c7;this[_0x51d31b(0x18d)](_0x57b59f,_0x5529f8[_0x51d31b(0x199)],!0x0);});}}[_0x93f129(0x145)](_0x1271da){const _0x2e3e5d=_0x93f129,_0x2606ab=this[_0x2e3e5d(0x13f)][_0x2e3e5d(0x1be)](_0x1271da),_0x2af3c9=this[_0x2e3e5d(0x138)][_0x2e3e5d(0x1be)](_0x1271da);if(_0x2af3c9&&(_0x2af3c9[_0x2e3e5d(0x1a0)](),this[_0x2e3e5d(0x138)][_0x2e3e5d(0x188)](_0x1271da)),_0x2606ab?.[_0x2e3e5d(0x199)]){const _0x89c0b0=this[_0x2e3e5d(0x150)](_0x2606ab[_0x2e3e5d(0x199)]);_0x89c0b0&&_0x89c0b0[_0x2e3e5d(0x140)](_0x2affc6=>{const _0x3c8771=_0x2e3e5d;this[_0x3c8771(0x18d)](_0x2affc6,_0x2606ab[_0x3c8771(0x199)],!0x1);});}this[_0x2e3e5d(0x13f)][_0x2e3e5d(0x188)](_0x1271da),this[_0x2e3e5d(0x144)](_0x2e3e5d(0x166),{'uiId':_0x1271da,'type':_0x2606ab?.[_0x2e3e5d(0x1ad)]}),_0x2e3e5d(0x1bb)===_0x1271da&&this[_0x2e3e5d(0x1a7)]();}[_0x93f129(0x1ac)](_0x4ef6f7,_0x25632f){const _0x5c98c6=_0x93f129;if(this[_0x5c98c6(0x13f)][_0x5c98c6(0x14a)](_0x4ef6f7[_0x5c98c6(0x151)])&&(this[_0x5c98c6(0x13f)][_0x5c98c6(0x13e)](_0x4ef6f7[_0x5c98c6(0x151)],_0x4ef6f7),this[_0x5c98c6(0x144)](_0x5c98c6(0x15c),{'contextItem':_0x4ef6f7,'isLoading':_0x25632f}),_0x4ef6f7[_0x5c98c6(0x199)])){const _0xeae4ba=this[_0x5c98c6(0x150)](_0x4ef6f7[_0x5c98c6(0x199)]);_0xeae4ba&&_0xeae4ba[_0x5c98c6(0x140)](_0xf73ca2=>{const _0x3b4e52=_0x5c98c6;this[_0x3b4e52(0x18d)](_0xf73ca2,_0x4ef6f7[_0x3b4e52(0x199)],!0x0);});}}[_0x93f129(0x1a2)](_0x4179ea){const _0x49f67a=_0x93f129;this[_0x49f67a(0x198)][_0x49f67a(0x13e)](_0x4179ea[_0x49f67a(0x151)],_0x4179ea);}[_0x93f129(0x192)](){const _0x342cbf=_0x93f129;this[_0x342cbf(0x179)]={'document':{'enabled':!0x1!==this[_0x342cbf(0x1b2)]?.[_0x342cbf(0x195)]?.[_0x342cbf(0x1a5)],'isHidden':!0x1},'urls':{'enabled':!0x1!==this[_0x342cbf(0x1b2)]?.[_0x342cbf(0x19f)]?.[_0x342cbf(0x1a5)]},'files':{'enabled':!0x1!==this[_0x342cbf(0x1b2)]?.[_0x342cbf(0x1b1)]?.[_0x342cbf(0x1a5)]},'sources':this[_0x342cbf(0x1b8)](),'customItems':this[_0x342cbf(0x1b2)]?.[_0x342cbf(0x1b3)]?.[_0x342cbf(0x169)](_0x26c6ad=>({..._0x26c6ad,'enabled':!0x0}))??[]},this[_0x342cbf(0x144)](_0x342cbf(0x1c6),{'options':this[_0x342cbf(0x179)]});}[_0x93f129(0x1b8)](){const _0x1785ac=_0x93f129;return this[_0x1785ac(0x1b2)]?.[_0x1785ac(0x1bf)]?.[_0x1785ac(0x169)](_0x5957f1=>({..._0x5957f1,'resources':[]}))??[];}[_0x93f129(0x1a7)](){const _0x4123d1=_0x93f129,_0x3f8e05=this[_0x4123d1(0x1a3)]()||this[_0x4123d1(0x153)]();this[_0x4123d1(0x179)][_0x4123d1(0x195)][_0x4123d1(0x162)]=_0x3f8e05,this[_0x4123d1(0x144)](_0x4123d1(0x1c6),{'options':this[_0x4123d1(0x179)]});}[_0x93f129(0x16f)](_0x250a38){const _0x5f30f6=_0x93f129;for(const _0x34a21a of this[_0x5f30f6(0x13f)][_0x5f30f6(0x133)]())if(_0x34a21a[_0x5f30f6(0x199)]===_0x250a38)return!0x0;for(const _0x462ee3 of this[_0x5f30f6(0x198)][_0x5f30f6(0x133)]())if(_0x462ee3[_0x5f30f6(0x199)]===_0x250a38)return!0x0;return!0x1;}[_0x93f129(0x150)](_0xa01923){const _0x5554e8=_0x93f129,_0x239a7d=[];for(const _0x380454 of this[_0x5554e8(0x179)][_0x5554e8(0x1bf)]){_0x380454[_0x5554e8(0x135)][_0x5554e8(0x19c)](_0x128f53=>_0x128f53['id']===_0xa01923)&&_0x239a7d[_0x5554e8(0x1b5)](_0x380454['id']);}return 0x0===_0x239a7d[_0x5554e8(0x173)]?null:_0x239a7d;}[_0x93f129(0x18d)](_0x1fbeea,_0x302edd,_0x1e37b3){const _0x3b9297=_0x93f129,_0x493b3e=this[_0x3b9297(0x179)][_0x3b9297(0x1bf)][_0x3b9297(0x19c)](_0x3dbc6f=>_0x3dbc6f['id']===_0x1fbeea);if(!_0x493b3e)return;const _0x97e0f7=_0x493b3e[_0x3b9297(0x135)][_0x3b9297(0x19c)](_0x1bf4ac=>_0x1bf4ac['id']===_0x302edd);_0x97e0f7&&(_0x97e0f7[_0x3b9297(0x1bd)]=_0x1e37b3,this[_0x3b9297(0x144)](_0x3b9297(0x185),{'sourceId':_0x1fbeea,'resourceId':_0x302edd,'isInContext':_0x1e37b3}));}[_0x93f129(0x156)](_0x584a41){const _0x5a334a=_0x93f129;this[_0x5a334a(0x17a)][_0x5a334a(0x13e)](_0x584a41,!0x0),this[_0x5a334a(0x17a)][_0x5a334a(0x17b)]&&this[_0x5a334a(0x144)](_0x5a334a(0x131),{'isUploadInProgress':!0x0});}[_0x93f129(0x1c7)](_0x16499b){const _0x520b00=_0x93f129;this[_0x520b00(0x17a)][_0x520b00(0x188)](_0x16499b),0x0===this[_0x520b00(0x17a)][_0x520b00(0x17b)]&&this[_0x520b00(0x144)](_0x520b00(0x131),{'isUploadInProgress':!0x1});}}