@ckeditor/ckeditor5-ai 47.7.0-alpha.1 → 47.7.0-alpha.3

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 _0x3a83b2=_0xe6bb;(function(_0xbe659d,_0xe05e4f){const _0x5161e9=_0xe6bb,_0x5d703d=_0xbe659d();while(!![]){try{const _0x1d5133=-parseInt(_0x5161e9(0xba))/0x1+parseInt(_0x5161e9(0xc8))/0x2*(parseInt(_0x5161e9(0xd9))/0x3)+parseInt(_0x5161e9(0xbe))/0x4+-parseInt(_0x5161e9(0xd1))/0x5+-parseInt(_0x5161e9(0xaf))/0x6*(-parseInt(_0x5161e9(0xd4))/0x7)+parseInt(_0x5161e9(0xea))/0x8+-parseInt(_0x5161e9(0xb5))/0x9;if(_0x1d5133===_0xe05e4f)break;else _0x5d703d['push'](_0x5d703d['shift']());}catch(_0x500e3b){_0x5d703d['push'](_0x5d703d['shift']());}}}(_0x1a5a,0x524e3));import{Plugin as _0x2e123d}from'ckeditor5/src/core.js';import{AIBalloon as _0x235938}from'../aiballoon/aiballoon.js';import{AI_REPLY_ACTIONS as _0x42d5ff}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';import{AIChatBalloonView as _0x3c57d0}from'./ui/aichatballoonview.js';import{AI_SUGGESTION_UI_EVENT_NAMES as _0x3b6c5a}from'../aicore/utils/eventnames.js';function _0xe6bb(_0x5fe5a5,_0x41602c){const _0x1a5a7d=_0x1a5a();return _0xe6bb=function(_0xe6bbde,_0xc4098c){_0xe6bbde=_0xe6bbde-0xae;let _0x6bddf7=_0x1a5a7d[_0xe6bbde];return _0x6bddf7;},_0xe6bb(_0x5fe5a5,_0x41602c);}import{Dialog as _0xcc4fc0}from'ckeditor5/src/ui.js';function _0x1a5a(){const _0x56df5a=['showDiff','areActionsDisabled','requires','updateContent','children','plugins','bind','previousButtonView','dialogClosed','2tZKoTG','config','rejectSuggestion','focus','showRotator','_createChatBalloonView','open','_restoreDefaultViewFocus','delegate','322915fshEBF','showNext','get','84wizoOS','_toggleRotatorButtonsInDialogHeader','AIChatBalloon','AIBalloon','close','1044486cjpGkg','addMany','toggleRotatorButtonsVisibility','locale','commands','nextButtonView','beforeDialogClosed','showPrevious','trackChanges','setState','ai.availableReplyActions','set','isPremiumPlugin','applySuggestion','value','has','ck-ai-chat-balloon','3073000nEeXfx','editor','headerView','Dialog','pluginName','327960DPLlCN','isOfficialPlugin','view','remove','filter','_chatBalloonView','6334983rMFGZo','aiChatBalloon','render','once','insertSuggestion','580594TFasny','isTrackChangesOn','TrackChanges','togglePartToolbarEnabled','1191920KLRofs'];_0x1a5a=function(){return _0x56df5a;};return _0x1a5a();}export class AIChatBalloon extends _0x2e123d{static get[_0x3a83b2(0xc1)](){return[_0xcc4fc0,_0x235938];}static get[_0x3a83b2(0xae)](){const _0x4c01a3=_0x3a83b2;return _0x4c01a3(0xd6);}static get[_0x3a83b2(0xb0)](){return!0x0;}static get[_0x3a83b2(0xe5)](){return!0x0;}[_0x3a83b2(0xb4)];constructor(_0x5a5a4c){const _0x5b177b=_0x3a83b2;super(_0x5a5a4c),this[_0x5b177b(0xe4)](_0x5b177b(0xbf),!0x1);}[_0x3a83b2(0xce)](_0x2a4b03){const _0x5e3669=_0x3a83b2,_0x12acf2=this[_0x5e3669(0xeb)];this[_0x5e3669(0xb4)]||(this[_0x5e3669(0xb4)]=this[_0x5e3669(0xcd)]()),_0x12acf2[_0x5e3669(0xc4)][_0x5e3669(0xd3)](_0x5e3669(0xd7))[_0x5e3669(0xce)]({..._0x2a4b03,'id':_0x5e3669(0xb6),'class':_0x5e3669(0xe9),'mainView':this[_0x5e3669(0xb4)]}),this[_0x5e3669(0xd5)](_0x2a4b03[_0x5e3669(0xcc)]),this[_0x5e3669(0xb4)][_0x5e3669(0xbd)](!_0x2a4b03[_0x5e3669(0xc0)]),this[_0x5e3669(0xcf)]();}[_0x3a83b2(0xd8)](){const _0x37014c=_0x3a83b2;this[_0x37014c(0xeb)][_0x37014c(0xc4)][_0x37014c(0xd3)](_0x37014c(0xd7))[_0x37014c(0xd8)]();}[_0x3a83b2(0xc2)](_0x2cdbb1){const _0x485e24=_0x3a83b2;return this[_0x485e24(0xb4)]||(this[_0x485e24(0xb4)]=this[_0x485e24(0xcd)]()),this[_0x485e24(0xb4)][_0x485e24(0xc2)](_0x2cdbb1);}[_0x3a83b2(0xe2)](_0x2b3880){const _0x1726fa=_0x3a83b2;this[_0x1726fa(0xb4)]&&this[_0x1726fa(0xb4)][_0x1726fa(0xe2)](_0x2b3880);}[_0x3a83b2(0xcd)](){const _0x23c09b=_0x3a83b2,_0x22c910=this[_0x23c09b(0xeb)],_0x242b57=_0x22c910[_0x23c09b(0xc4)][_0x23c09b(0xd3)](_0x23c09b(0xd7)),_0xb989fe=_0x22c910[_0x23c09b(0xdd)][_0x23c09b(0xd3)](_0x23c09b(0xe1));let _0x21a870=_0x22c910[_0x23c09b(0xc9)][_0x23c09b(0xd3)](_0x23c09b(0xe3))||[..._0x42d5ff];_0x22c910[_0x23c09b(0xc4)][_0x23c09b(0xe8)](_0x23c09b(0xbc))||(_0x21a870=_0x21a870[_0x23c09b(0xb3)](_0x29702c=>_0x23c09b(0xb9)!=_0x29702c));const _0x3b11f6=new _0x3c57d0(_0x22c910[_0x23c09b(0xdc)],{'availableActions':_0x21a870,'showApplyButton':!0x0,'showSuggestButton':!!_0xb989fe});return _0x3b11f6[_0x23c09b(0xc5)](_0x23c09b(0xbf))['to'](this),_0x3b11f6[_0x23c09b(0xd0)](..._0x3b6c5a)['to'](this),_0x3b11f6[_0x23c09b(0xd0)](_0x23c09b(0xe0),_0x23c09b(0xd2))['to'](this),_0x242b57[_0x23c09b(0xd0)](_0x23c09b(0xc7))['to'](this),_0x3b11f6['on'](_0x23c09b(0xe6),this[_0x23c09b(0xcf)][_0x23c09b(0xc5)](this)),_0x3b11f6['on'](_0x23c09b(0xb9),this[_0x23c09b(0xcf)][_0x23c09b(0xc5)](this)),_0x3b11f6['on'](_0x23c09b(0xca),this[_0x23c09b(0xcf)][_0x23c09b(0xc5)](this)),_0xb989fe&&_0x3b11f6[_0x23c09b(0xc5)](_0x23c09b(0xbb))['to'](_0xb989fe,_0x23c09b(0xe7)),_0x3b11f6[_0x23c09b(0xb7)](),_0x3b11f6;}[_0x3a83b2(0xd5)](_0x50fd41){const _0x2b93cd=_0x3a83b2,_0x596743=this[_0x2b93cd(0xeb)],_0x323523=_0x596743[_0x2b93cd(0xc4)][_0x2b93cd(0xd3)](_0x2b93cd(0xed))[_0x2b93cd(0xb1)][_0x2b93cd(0xec)][_0x2b93cd(0xc3)];this[_0x2b93cd(0xb4)][_0x2b93cd(0xdb)](_0x50fd41),_0x323523[_0x2b93cd(0xe8)](this[_0x2b93cd(0xb4)][_0x2b93cd(0xc6)])||(_0x323523[_0x2b93cd(0xda)]([this[_0x2b93cd(0xb4)][_0x2b93cd(0xc6)],this[_0x2b93cd(0xb4)][_0x2b93cd(0xde)]],0x0),_0x596743[_0x2b93cd(0xc4)][_0x2b93cd(0xd3)](_0x2b93cd(0xd7))[_0x2b93cd(0xb8)](_0x2b93cd(0xdf),()=>{const _0x3bed92=_0x2b93cd;_0x323523[_0x3bed92(0xb2)](this[_0x3bed92(0xb4)][_0x3bed92(0xc6)]),_0x323523[_0x3bed92(0xb2)](this[_0x3bed92(0xb4)][_0x3bed92(0xde)]);}));}[_0x3a83b2(0xcf)](){const _0x5e2ab4=_0x3a83b2;this[_0x5e2ab4(0xb4)][_0x5e2ab4(0xcb)]();}}
23
+ function _0x5eff(){const _0x38512c=['nextButtonView','get','4205536QCCQJH','updateContent','4442560dRKSKK','_createChatBalloonView','previousButtonView','ai.availableReplyActions','ck-ai-chat-balloon','bind','applySuggestion','pluginName','showRotator','close','showDiff','has','set','_chatBalloonView','locale','setState','5ShcDqk','isOfficialPlugin','plugins','isPremiumPlugin','AIChatBalloon','render','TrackChanges','toggleRotatorButtonsVisibility','aiChatBalloon','filter','once','1179615FUISsN','_restoreDefaultViewFocus','togglePartToolbarEnabled','2614913kNmdVR','rejectSuggestion','remove','AIBalloon','open','areActionsDisabled','view','focus','trackChanges','8643690zyQXnp','addMany','_toggleRotatorButtonsInDialogHeader','config','editor','dialogClosed','showNext','delegate','4915160VuysKb','requires','value','insertSuggestion','headerView','children','showPrevious','459764ioRYgF','Dialog','isTrackChangesOn','commands','beforeDialogClosed'];_0x5eff=function(){return _0x38512c;};return _0x5eff();}const _0x4ca625=_0x5f0f;(function(_0x5db650,_0x14f9bd){const _0x32affc=_0x5f0f,_0x2d1a39=_0x5db650();while(!![]){try{const _0x51a409=-parseInt(_0x32affc(0x153))/0x1*(parseInt(_0x32affc(0x13a))/0x2)+-parseInt(_0x32affc(0x15e))/0x3+-parseInt(_0x32affc(0x141))/0x4+parseInt(_0x32affc(0x172))/0x5+parseInt(_0x32affc(0x16a))/0x6+parseInt(_0x32affc(0x161))/0x7+parseInt(_0x32affc(0x143))/0x8;if(_0x51a409===_0x14f9bd)break;else _0x2d1a39['push'](_0x2d1a39['shift']());}catch(_0x4a62eb){_0x2d1a39['push'](_0x2d1a39['shift']());}}}(_0x5eff,0xb92ff));import{Plugin as _0x5e7b60}from'ckeditor5/src/core.js';import{AIBalloon as _0x3d013d}from'../aiballoon/aiballoon.js';import{AI_REPLY_ACTIONS as _0xbe219c}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';import{AIChatBalloonView as _0x474b40}from'./ui/aichatballoonview.js';import{AI_SUGGESTION_UI_EVENT_NAMES as _0x1cdd27}from'../aicore/utils/eventnames.js';function _0x5f0f(_0x53f11b,_0x3260e6){const _0x5eff9f=_0x5eff();return _0x5f0f=function(_0x5f0fd4,_0x5f282f){_0x5f0fd4=_0x5f0fd4-0x137;let _0x2e5895=_0x5eff9f[_0x5f0fd4];return _0x2e5895;},_0x5f0f(_0x53f11b,_0x3260e6);}import{Dialog as _0x55dc1e}from'ckeditor5/src/ui.js';export class AIChatBalloon extends _0x5e7b60{static get[_0x4ca625(0x173)](){return[_0x55dc1e,_0x3d013d];}static get[_0x4ca625(0x14a)](){const _0x4023c4=_0x4ca625;return _0x4023c4(0x157);}static get[_0x4ca625(0x154)](){return!0x0;}static get[_0x4ca625(0x156)](){return!0x0;}[_0x4ca625(0x150)];constructor(_0x2fa0f5){const _0x50d218=_0x4ca625;super(_0x2fa0f5),this[_0x50d218(0x14f)](_0x50d218(0x14d),!0x1);}[_0x4ca625(0x165)](_0x2ebd1d){const _0x37253e=_0x4ca625,_0x1d1cf8=this[_0x37253e(0x16e)];this[_0x37253e(0x150)]||(this[_0x37253e(0x150)]=this[_0x37253e(0x144)]()),_0x1d1cf8[_0x37253e(0x155)][_0x37253e(0x140)](_0x37253e(0x164))[_0x37253e(0x165)]({..._0x2ebd1d,'id':_0x37253e(0x15b),'class':_0x37253e(0x147),'mainView':this[_0x37253e(0x150)]}),this[_0x37253e(0x16c)](_0x2ebd1d[_0x37253e(0x14b)]),this[_0x37253e(0x150)][_0x37253e(0x160)](!_0x2ebd1d[_0x37253e(0x166)]),this[_0x37253e(0x15f)]();}[_0x4ca625(0x14c)](){const _0xfa85bf=_0x4ca625;this[_0xfa85bf(0x16e)][_0xfa85bf(0x155)][_0xfa85bf(0x140)](_0xfa85bf(0x164))[_0xfa85bf(0x14c)]();}[_0x4ca625(0x142)](_0x1c2488){const _0x1c1f20=_0x4ca625;return this[_0x1c1f20(0x150)]||(this[_0x1c1f20(0x150)]=this[_0x1c1f20(0x144)]()),this[_0x1c1f20(0x150)][_0x1c1f20(0x142)](_0x1c2488);}[_0x4ca625(0x152)](_0x494005){const _0x58f8f7=_0x4ca625;this[_0x58f8f7(0x150)]&&this[_0x58f8f7(0x150)][_0x58f8f7(0x152)](_0x494005);}[_0x4ca625(0x144)](){const _0xa2eb8f=_0x4ca625,_0x3326a0=this[_0xa2eb8f(0x16e)],_0x4c2d=_0x3326a0[_0xa2eb8f(0x155)][_0xa2eb8f(0x140)](_0xa2eb8f(0x164)),_0x361353=_0x3326a0[_0xa2eb8f(0x13d)][_0xa2eb8f(0x140)](_0xa2eb8f(0x169));let _0x431433=_0x3326a0[_0xa2eb8f(0x16d)][_0xa2eb8f(0x140)](_0xa2eb8f(0x146))||[..._0xbe219c];_0x3326a0[_0xa2eb8f(0x155)][_0xa2eb8f(0x14e)](_0xa2eb8f(0x159))||(_0x431433=_0x431433[_0xa2eb8f(0x15c)](_0x5176fe=>_0xa2eb8f(0x175)!=_0x5176fe));const _0x580fff=new _0x474b40(_0x3326a0[_0xa2eb8f(0x151)],{'availableActions':_0x431433,'showApplyButton':!0x0,'showSuggestButton':!!_0x361353});return _0x580fff[_0xa2eb8f(0x148)](_0xa2eb8f(0x14d))['to'](this),_0x580fff[_0xa2eb8f(0x171)](..._0x1cdd27)['to'](this),_0x580fff[_0xa2eb8f(0x171)](_0xa2eb8f(0x139),_0xa2eb8f(0x170))['to'](this),_0x4c2d[_0xa2eb8f(0x171)](_0xa2eb8f(0x16f))['to'](this),_0x580fff['on'](_0xa2eb8f(0x149),this[_0xa2eb8f(0x15f)][_0xa2eb8f(0x148)](this)),_0x580fff['on'](_0xa2eb8f(0x175),this[_0xa2eb8f(0x15f)][_0xa2eb8f(0x148)](this)),_0x580fff['on'](_0xa2eb8f(0x162),this[_0xa2eb8f(0x15f)][_0xa2eb8f(0x148)](this)),_0x361353&&_0x580fff[_0xa2eb8f(0x148)](_0xa2eb8f(0x13c))['to'](_0x361353,_0xa2eb8f(0x174)),_0x580fff[_0xa2eb8f(0x158)](),_0x580fff;}[_0x4ca625(0x16c)](_0xa0a287){const _0x24470f=_0x4ca625,_0xd77ee6=this[_0x24470f(0x16e)],_0x2fe9b0=_0xd77ee6[_0x24470f(0x155)][_0x24470f(0x140)](_0x24470f(0x13b))[_0x24470f(0x167)][_0x24470f(0x137)][_0x24470f(0x138)];this[_0x24470f(0x150)][_0x24470f(0x15a)](_0xa0a287),_0x2fe9b0[_0x24470f(0x14e)](this[_0x24470f(0x150)][_0x24470f(0x145)])||(_0x2fe9b0[_0x24470f(0x16b)]([this[_0x24470f(0x150)][_0x24470f(0x145)],this[_0x24470f(0x150)][_0x24470f(0x13f)]],0x0),_0xd77ee6[_0x24470f(0x155)][_0x24470f(0x140)](_0x24470f(0x164))[_0x24470f(0x15d)](_0x24470f(0x13e),()=>{const _0x517de3=_0x24470f;_0x2fe9b0[_0x517de3(0x163)](this[_0x517de3(0x150)][_0x517de3(0x145)]),_0x2fe9b0[_0x517de3(0x163)](this[_0x517de3(0x150)][_0x517de3(0x13f)]);}));}[_0x4ca625(0x15f)](){const _0x81f633=_0x4ca625;this[_0x81f633(0x150)][_0x81f633(0x168)]();}}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x5027f0=_0x1799;(function(_0x526011,_0x3c6c16){const _0x317aaf=_0x1799,_0x14b5a1=_0x526011();while(!![]){try{const _0x349421=parseInt(_0x317aaf(0x29b))/0x1+parseInt(_0x317aaf(0x259))/0x2+parseInt(_0x317aaf(0x30b))/0x3+-parseInt(_0x317aaf(0x2d3))/0x4+-parseInt(_0x317aaf(0x241))/0x5+-parseInt(_0x317aaf(0x2f8))/0x6+-parseInt(_0x317aaf(0x2ab))/0x7*(parseInt(_0x317aaf(0x27b))/0x8);if(_0x349421===_0x3c6c16)break;else _0x14b5a1['push'](_0x14b5a1['shift']());}catch(_0x487909){_0x14b5a1['push'](_0x14b5a1['shift']());}}}(_0x38d9,0x84de5));import{ContextPlugin as _0x236b46,Editor as _0x1e36b8}from'ckeditor5/src/core.js';import{BodyCollection as _0x3f7636}from'ckeditor5/src/ui.js';function _0x38d9(){const _0x5178d3=['mouseLeaveSuggestion','filter','fetchConversation','areActionsDisabled','setFeedItemAIReplySuggestionPartActive','done','callback','changeGroups','ai-chat-invalid-request','_currentPreviewedChangeGroup','text','setIsMaximized','replyContentUpdated','interactionCreated','6272jrfyoO','getAttribute','conversationInitialized','replyCreated','modification','webSearchFinished','contextItemRemoved','resetMessageInput','ai-chat-controller-no-active-conversation','mapper','log','_registerToolDataCallback','replyChangeGroupStateUpdated','uploadProgressChanged','resize','ai.chat.initialConversation','ai-chat-context-unsupported-file-type','prepareLoadingMessage','_aiChatBalloon','replies','_scrollToSuggestionRange','detachFromDom','_aiChatUi','locale','sendMessage','ai-conversation-','marker','lastCreated','maxOffset','isOfficialPlugin','_getDocumentRangeForReplyChanges','loadSourceResources','source','contextItemAdded','populateSourceResourceBalloon','addFeedItemAIReply','uid','interactionId','document','_updateRatings','1873592reAeMd','ai.models.defaultModelId','_toggleWebSearch','index','_toggleReasoning','howMany','_startConversationSafely','updateFeedItemAIReplySources','reasoningFinished','_getUserPresentableContentPartDocumentRange','AI_CHAT_CONTEXT_FILE_TOO_LARGE','createReply','showDiff','ai.models','removeSelectionFromContext','createdAt','parse','ai-chat-context-file-too-many-pages','sources','isUploadInProgress','getChildAtOffset','has','message','addDocumentToContext','unshift','closeSourceResourceBalloon','addUrlToContext','toViewRange','setConversationTitle','updateFeedItemAIReplyContent','setIsUploadInProgress','upsertAIChatRating','map','clearConversationContextUI','options','setAddContextOptions','Disliked\x20response','6211416LcjiPC','AIEditing','ai-chat-file-upload-failed','children','toString','_aiEditing','resetWebSearchState','isPremiumPlugin','open','_applySuggestion','afterInit','AI_CHAT_CONTEXT_UNSUPPORTED_TYPE','getGroupId','messageId','updateResourceState','AI_CHAT_CONTEXT_CURRENT_DOCUMENT','commands','_applyOperationsAsSuggestions','change','1789539djsRbr','error','toggleLoadingSkeleton','rejectSuggestion','ai-chat-source-resources-load-failed','AI_CHAT_CONTEXT_FILE_TOO_MANY_PAGES','config','close','interactionFinished','updateFeedItemAIReplySuggestionContent','nextSibling','version','attachToDom','removeFeedInteraction','Showing\x20conversation\x20history...','getTransformedByOperation','stop','from','ai-chat-context-invalid-data','AIChatController','collaboration.channelId','replyId','ai.chat.context','_openBalloonFor','reasoningStarted','query','_getPresentableSiblingContentPartIndex','rejected','interactionDestroyed','ai-chat-resource-load-failed','contextItem','push','resources','getDocumentContext','like','AI_CHAT_UNABLE_TO_START_CONVERSATION','revert','changes','includes','sourcePosition','activeConversation','getInteractionAndReplyById','streaming','getContentParts','add','pluginName','AI_CHAT_CONTEXT_FORM_DATA_SIZE_LIMITS_EXCEEDED','insertSuggestion','getRanges','createPositionAt','mouseOverSuggestion','_batchToChanges','toggleReasoning','getPath','next','updateCapabilities','disableControls','AIChatBalloon','node','_handleStartConversation','handleUserInteraction','AI_CHAT_RESOURCE_LOAD_FAILED','startAutoScroll','getInteraction','set','data','fetchConversations','startsWith','clearLoadingMessage','selectedModel','getOperations','selectModel','resizedTabs','outdated','addCurrentDocumentToChatContext','applyOperation','ai-chat-context-form-data-size-limits-exceeded','isStarted','applySuggestion','end','addFeedInteractionHeader','Liked\x20response','updateFeedItemAIReplySuggestionPartState','chat','requires','batch','focusPromptInput','_getAIChatInteractionAPI','load','AI_CHAT_UNABLE_TO_LOAD_CONVERSATION','ai-chat-context-unsupported-type','getRoot','resourceStateChanged','removed','delete','model','currentReply','isCurrentDocumentInContext','AI_CHAT_CONTEXT_INVALID_DATA','loadConversation','slice','_removeFromContext','_updateReplyContent','resourceId','toggleWebSearch','setModel','content','getFirstRange','updateCurrentDocumentInContext','AI_CHAT_UNTITLED_CONVERSATION','sourceId','removeSelectionFromChatContext','addFeedItemAISuggestion','hasChanges','abortPromptStream','forEach','modelSelected','bind','addFileToContext','capabilitiesUpdated','_bodyCollection','dialogClosed','_aiConnector','addFeedItemUserMessage','_handleUIUserMessage','documentContextContent','_showConversationHistory','_aiChatBalloonShowDiff','ai-chat-missing-channel-id','delegate','updateContent','_getLastCreatedConversationId','isDisabled','getDiff','DocumentCompare','root','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_FILE','editing','cloneNode','selection','ai-chat-context-file-too-large','Undo','isLoading','getReply','ai-chat-controller-mouse-over','alignToTop','updateConversationTitle','context','AI_CHAT_CONTEXT_UNSUPPORTED_FILE_TYPE','setConversationContext','showNext','_stopLastInteraction','length','aiChatBalloon','createRange','ai-no-track-changes','previous','getConversation','addOperation','start','findIndex','AI_CHAT_INVALID_REQUEST','range','resizeTabs','handleRemovedConversation','setLoadingMessage','viewRangeToDom','anchorId','setSelectedModel','getChild','createConversation','undo','addContextOptionsChanged','main','type','_aiChatModels','getSelectionText','get','removeContextItem','init','ai-chat-conversation-init-failed','uiId','activateTab','setState','AIConnector','TrackChanges','$graveyard','isCurrentDocumentInConversation','addResourceToContext','AI_CHAT_CONTEXT_UNABLE_TO_LOAD_RESOURCES','indexOf','editors','2310160FvHeyl','AITabs','pending','toolDataReceived','new','accepted','showFakeVisualSelection','startInteraction','AIChatUI','plugins','setFeedItemRenderingStrategy','resetReasoningState','clearPendingContextUI','contextSent','static','rootName','AI_BALLOON_HEADER_TITLE','enableControls','getDocumentData','scrollFeedToSuggestion','resource','addSelectionToChatContext','redo','view','2107342aDIGQx','isInContext','path','_logError','ai-chat-conversation-not-found','sourceResourcesLoaded','split','ai-chat-conversation-start-failed','_flushLastInteractionUI','sendUserMessage','lastInteraction','data-id','addFilesToContext','_rejectSuggestion','partIndex','_setIsMaximized','setContextItemLoading','contextItems','toggleSuggestionDisplayMode','setChangeGroupState','showChangeInText','addFeedItemCustomElement','TrackChangesEditing','destroy','getChildren','_insertSuggestion','resetConversationTitle','AI_CHAT_GENERIC_ERROR','dislike','find','_createFromRanges','domConverter','isModelAvailable','addContextItem','344ivtTbd','_integrateEditor','addFeedItemStaticMessage','ai-request-aborted','current-document','listenTo','addSelectionToContext','stopInteraction','indexes','ai-chat-url-upload-failed','AI_CHAT_ABORTED_MESSAGE','removeFromContext','webSearchStarted','baseVersion','contextItemLoadingEnded','hideFakeVisualSelection','createPositionFromPath','history','startConversation','isDocumentOperation','addCurrentDocumentToContext','remove','executeCustomItemCallback','finishInteraction','showPrevious','ready','getAll','addFeedItemError','interactionStarted','getConversations','state','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_URL','898239BUozSv','sessionId'];_0x38d9=function(){return _0x5178d3;};return _0x38d9();}import{CKEditorError as _0x1cac1d,logError as _0x5d39d3,scrollViewportToShowTarget as _0x2d5201,uid as _0xc400fc}from'ckeditor5/src/utils.js';function _0x1799(_0x12adca,_0x1e1d81){const _0x38d9be=_0x38d9();return _0x1799=function(_0x17991e,_0x5d25cf){_0x17991e=_0x17991e-0x1a5;let _0x4be4be=_0x38d9be[_0x17991e];return _0x4be4be;},_0x1799(_0x12adca,_0x1e1d81);}import{AIConnector as _0x344017}from'../aicore/aiconnector.js';import{AITabs as _0x620505}from'../aitabs/aitabs.js';import{AIChatConversation as _0x126b86}from'./model/aichatconversation.js';import{getTranslation as _0x4e370c}from'../aicore/utils/common-translations.js';import{AIModels as _0x3404d3}from'../aicore/model/aimodels.js';import{getEditorFromContext as _0x22d5bb}from'../aicore/utils/geteditorfromcontext.js';import{DocumentCompare as _0x1b0eca,DATA_ID_MODEL_ATTRIBUTE as _0x213e06}from'ckeditor5-collaboration/src/collaboration-core.js';import{fixMarkerOperationOldRange as _0x4e9a85,getOperationsFromReply as _0x4c9494}from'../aicore/utils/getoperationsfromreply.js';import{expandSelectionWithContext as _0x22d854,getMinimalSelection as _0x2b3d24}from'../aicore/utils/getsuggestionpartsfromreply.js';import{ModelRange as _0x29ade5,_DetachOperation as _0x568343}from'ckeditor5/src/engine.js';import{findOne as _0x323a6d,getAttribute as _0x68ecf9,serialize as _0x417201,Document as _0x128a28,findByAttribute as _0x25ed47}from'../aicore/utils/htmlparser.js';export class AIChatController extends _0x236b46{[_0x5027f0(0x2fd)];[_0x5027f0(0x1fb)];[_0x5027f0(0x2c1)];[_0x5027f0(0x230)];[_0x5027f0(0x2bd)];[_0x5027f0(0x1b4)]=new Map();[_0x5027f0(0x2a6)]=null;[_0x5027f0(0x1f9)];static get[_0x5027f0(0x1d5)](){return[_0x344017,_0x1b0eca];}static get[_0x5027f0(0x1ae)](){const _0x42d8c4=_0x5027f0;return _0x42d8c4(0x31e);}static get[_0x5027f0(0x2c8)](){return!0x0;}static get[_0x5027f0(0x2ff)](){return!0x0;}[_0x5027f0(0x234)](){const _0x19d41e=_0x5027f0;this[_0x19d41e(0x1f9)]=new _0x3f7636(this[_0x19d41e(0x214)][_0x19d41e(0x2c2)]),this[_0x19d41e(0x1f9)][_0x19d41e(0x317)](),this[_0x19d41e(0x1fb)]=this[_0x19d41e(0x214)][_0x19d41e(0x24a)][_0x19d41e(0x232)](_0x19d41e(0x239)),this[_0x19d41e(0x2c1)]=this[_0x19d41e(0x214)][_0x19d41e(0x24a)][_0x19d41e(0x232)](_0x19d41e(0x249)),this[_0x19d41e(0x2fd)]=this[_0x19d41e(0x214)][_0x19d41e(0x24a)][_0x19d41e(0x232)](_0x19d41e(0x2f9)),this[_0x19d41e(0x230)]=new _0x3404d3({'connector':this[_0x19d41e(0x1fb)],'config':this[_0x19d41e(0x214)][_0x19d41e(0x311)][_0x19d41e(0x232)](_0x19d41e(0x2e0)),'locale':this[_0x19d41e(0x214)][_0x19d41e(0x2c2)]});const _0x196ad0=this[_0x19d41e(0x214)][_0x19d41e(0x24a)][_0x19d41e(0x232)](_0x19d41e(0x242));this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x28d),()=>{const _0x2dbabe=_0x19d41e;this[_0x2dbabe(0x2d9)]();}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x262),(_0x52f359,_0x4125e0)=>{const _0x6a6648=_0x19d41e;this[_0x6a6648(0x1fd)]({'userMessage':_0x4125e0});}),this[_0x19d41e(0x280)](_0x196ad0,_0x19d41e(0x1c9),(_0x157569,_0x21d333)=>{const _0x52d66c=_0x19d41e;this[_0x52d66c(0x268)](_0x21d333);}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x224),()=>{const _0x514c06=_0x19d41e;_0x196ad0[_0x514c06(0x2b9)]();}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x1f3),async()=>{const _0x42a140=_0x19d41e;await this[_0x42a140(0x218)](),await this[_0x42a140(0x261)](),this[_0x42a140(0x1f0)]();}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x2ea),()=>{const _0x2ca215=_0x19d41e;this[_0x2ca215(0x1cb)]();}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x1f7),(_0x125251,_0x3217ce)=>{const _0x2a3182=_0x19d41e;this[_0x2a3182(0x1a9)]?.[_0x2a3182(0x265)](Array[_0x2a3182(0x31c)](_0x3217ce));}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x2ed),(_0x4f71c5,_0x2c9b19)=>{const _0x292185=_0x19d41e;this[_0x292185(0x1a9)]?.[_0x292185(0x2ed)](_0x2c9b19);}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x291),(_0x5a3934,_0x559bfc)=>{const _0x80656a=_0x19d41e;_0x559bfc[_0x80656a(0x2a3)](this[_0x80656a(0x214)]);}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x23d),(_0x4a8c8a,_0x5df2c4)=>{const _0x24c724=_0x19d41e;this[_0x24c724(0x1a9)]?.[_0x24c724(0x23d)](_0x5df2c4[_0x24c724(0x2cb)],_0x5df2c4[_0x24c724(0x255)]);}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x233),(_0x58d49b,_0x3f3c4f)=>{const _0x405422=_0x19d41e;this[_0x405422(0x1e6)](_0x3f3c4f);}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x2ca),(_0x142b80,_0x56caae)=>{const _0x5b08a6=_0x19d41e;this[_0x5b08a6(0x1a9)]?.[_0x5b08a6(0x2ca)](_0x56caae[_0x5b08a6(0x1ef)],_0x56caae[_0x5b08a6(0x324)],_0x56caae[_0x5b08a6(0x2cf)]);}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x1e9),()=>{const _0x3900d0=_0x19d41e;this[_0x3900d0(0x2d5)]();}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x1b5),()=>{const _0x3c905c=_0x19d41e;this[_0x3c905c(0x2d7)]();}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x1c8),(_0x26a362,_0x5243a9)=>{const _0x5984c3=_0x19d41e;this[_0x5984c3(0x1a9)]?.[_0x5984c3(0x1ea)](_0x5243a9);}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x32d),(_0x7c6539,{replyId:_0x2e4950})=>{const _0x127973=_0x19d41e;console[_0x127973(0x2b5)](_0x127973(0x1d2),_0x2e4950);}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x275),(_0x428d62,{replyId:_0x180353})=>{const _0x289a40=_0x19d41e;console[_0x289a40(0x2b5)](_0x289a40(0x2f7),_0x180353);}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x1b0),(_0x169d11,_0x3338e3)=>{const _0x5021e7=_0x19d41e;this[_0x5021e7(0x272)](_0x3338e3);}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x26d),(_0x421f24,{replyId:_0xa31f0f,partIndex:_0x2288a6})=>{const _0x41557b=_0x19d41e;this[_0x41557b(0x200)]=this[_0x41557b(0x2c1)][_0x41557b(0x2df)],this[_0x41557b(0x322)](_0xa31f0f,_0x2288a6);}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x1b3),(_0x1ea6bc,{replyId:_0x41337b,partIndex:_0xaa1bb9})=>{const _0x107008=_0x19d41e,_0x409862=this[_0x107008(0x2c9)](_0x41337b,_0xaa1bb9);_0x409862&&_0x107008(0x23b)!=_0x409862[_0x107008(0x223)][_0x107008(0x208)][_0x107008(0x250)]&&this[_0x107008(0x2fd)][_0x107008(0x247)]([_0x409862[_0x107008(0x223)]],_0x107008(0x211));}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x29d),()=>{const _0xb9f25c=_0x19d41e;this[_0xb9f25c(0x2fd)][_0xb9f25c(0x28a)](_0xb9f25c(0x211));}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x1cf),(_0x1450b0,_0x50ba66)=>{const _0x1c0a5e=_0x19d41e;this[_0x1c0a5e(0x2fd)][_0x1c0a5e(0x28a)](_0x1c0a5e(0x211)),this[_0x1c0a5e(0x301)](_0x50ba66);}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x26b),async(_0x2b1d11,{replyId:_0x508def,showDiff:_0xeb9bbc})=>{const _0x555f81=_0x19d41e,{reply:_0x285005}=this[_0x555f81(0x1aa)](_0x508def),_0x26e021=_0x285005[_0x555f81(0x1ac)]({'showDiff':_0xeb9bbc});await this[_0x555f81(0x2c1)][_0x555f81(0x314)]({'id':_0x285005['id'],'parts':_0x26e021,'renderingStrategy':_0x555f81(0x24f)});}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2c1)],_0x19d41e(0x30e),(_0x5deae4,{replyId:_0x123926,partIndex:_0x523ea8})=>{const _0x15170b=_0x19d41e;this[_0x15170b(0x266)]({'replyId':_0x123926,'partIndex':_0x523ea8}),this[_0x15170b(0x2fd)][_0x15170b(0x28a)](_0x15170b(0x211));}),this[_0x19d41e(0x214)][_0x19d41e(0x24a)][_0x19d41e(0x2e8)](_0x19d41e(0x1ba))&&(this[_0x19d41e(0x2bd)]=this[_0x19d41e(0x214)][_0x19d41e(0x24a)][_0x19d41e(0x232)](_0x19d41e(0x1ba)),this[_0x19d41e(0x1c1)](_0x19d41e(0x200),!0x1),this[_0x19d41e(0x2bd)][_0x19d41e(0x1f6)](_0x19d41e(0x2df))['to'](this,_0x19d41e(0x200)),this[_0x19d41e(0x280)](this[_0x19d41e(0x2bd)],_0x19d41e(0x26b),()=>{const _0x49751b=_0x19d41e,{replyId:_0x537209,partIndex:_0x2bcb74}=this[_0x49751b(0x2a6)];this[_0x49751b(0x200)]=!this[_0x49751b(0x200)];const {reply:_0xebfd5f}=this[_0x49751b(0x1aa)](_0x537209),_0x1f64ad=_0xebfd5f[_0x49751b(0x1ac)]({'showDiff':this[_0x49751b(0x200)],'groupIndex':_0x2bcb74});this[_0x49751b(0x2bd)][_0x49751b(0x203)]({'part':_0x1f64ad[0x0],'renderingStrategy':_0x49751b(0x24f),'keepErrors':!0x0});}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2bd)],_0x19d41e(0x1cf),()=>{const _0x38ea59=_0x19d41e,{replyId:_0x29f3a2,partIndex:_0x3f562f}=this[_0x38ea59(0x2a6)];this[_0x38ea59(0x301)]({'replyId':_0x29f3a2,'partIndex':_0x3f562f}),this[_0x38ea59(0x2bd)][_0x38ea59(0x238)](_0x38ea59(0x246));}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2bd)],_0x19d41e(0x1b0),()=>{const _0x28a5fc=_0x19d41e,{replyId:_0x230550,partIndex:_0x3c2892}=this[_0x28a5fc(0x2a6)];this[_0x28a5fc(0x272)]({'replyId':_0x230550,'partIndex':_0x3c2892}),this[_0x28a5fc(0x2bd)][_0x28a5fc(0x238)](_0x28a5fc(0x246));}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2bd)],_0x19d41e(0x30e),()=>{const _0x1bab2a=_0x19d41e,{replyId:_0x280b91,partIndex:_0x37190a}=this[_0x1bab2a(0x2a6)];this[_0x1bab2a(0x266)]({'replyId':_0x280b91,'partIndex':_0x37190a}),this[_0x1bab2a(0x2bd)][_0x1bab2a(0x238)](_0x1bab2a(0x326));}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2bd)],_0x19d41e(0x217),()=>{const _0xa527fc=_0x19d41e,{replyId:_0x252f62,partIndex:_0x636846}=this[_0xa527fc(0x2a6)],_0x101221=this[_0xa527fc(0x325)](_0x252f62,_0x636846,_0xa527fc(0x1b7));null!==_0x101221&&this[_0xa527fc(0x322)](_0x252f62,_0x101221);}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2bd)],_0x19d41e(0x293),()=>{const _0x534d4c=_0x19d41e,{replyId:_0x261b2c,partIndex:_0x3ccb46}=this[_0x534d4c(0x2a6)],_0x3c6caf=this[_0x534d4c(0x325)](_0x261b2c,_0x3ccb46,_0x534d4c(0x21d));null!==_0x3c6caf&&this[_0x534d4c(0x322)](_0x261b2c,_0x3c6caf);}),this[_0x19d41e(0x280)](this[_0x19d41e(0x2bd)],_0x19d41e(0x1fa),(_0x408265,{id:_0x597848})=>{const _0x5a583a=_0x19d41e;if(_0x5a583a(0x21a)!==_0x597848)return;const {replyId:_0x4e627c,partIndex:_0x3449a0}=this[_0x5a583a(0x2a6)];this[_0x5a583a(0x2a6)]=null,this[_0x5a583a(0x2c1)][_0x5a583a(0x2a1)]({'id':_0x4e627c,'index':_0x3449a0,'isActive':!0x1});}));}async[_0x5027f0(0x302)](){const _0x17be73=_0x5027f0;this[_0x17be73(0x214)]instanceof _0x1e36b8?this[_0x17be73(0x27c)](this[_0x17be73(0x214)]):this[_0x17be73(0x280)](this[_0x17be73(0x214)][_0x17be73(0x240)],_0x17be73(0x1ad),(_0x1453a2,_0x1e5d09)=>{const _0x31fd63=_0x17be73;_0x1e5d09['on'](_0x31fd63(0x294),()=>{const _0xeebca3=_0x31fd63;this[_0xeebca3(0x27c)](_0x1e5d09);});});const _0x322ba3=this[_0x17be73(0x214)][_0x17be73(0x311)][_0x17be73(0x232)](_0x17be73(0x2ba));let _0x52c9f3=_0x322ba3;if(_0x17be73(0x2c6)!=_0x322ba3||(_0x52c9f3=await this[_0x17be73(0x204)](),_0x52c9f3))return _0x17be73(0x245)==_0x52c9f3?this[_0x17be73(0x2d9)]():this[_0x17be73(0x1e4)](_0x52c9f3);}async[_0x5027f0(0x270)](){const _0x19ca13=_0x5027f0;return await this[_0x19ca13(0x218)](),this[_0x19ca13(0x1f9)][_0x19ca13(0x2c0)](),super[_0x19ca13(0x270)]();}[_0x5027f0(0x272)](_0x20dccd){const _0x237776=_0x5027f0,_0x52d5c1=_0x22d5bb(this[_0x237776(0x214)]);if(!_0x52d5c1[_0x237776(0x24a)][_0x237776(0x2e8)](_0x237776(0x23a)))throw new _0x1cac1d(_0x237776(0x21c),null);const _0x530adb=this[_0x237776(0x214)][_0x237776(0x24a)][_0x237776(0x232)](_0x237776(0x207)),{reply:_0x3bf25b,interaction:_0x35b404}=this[_0x237776(0x1aa)](_0x20dccd[_0x237776(0x320)]),_0x3d1ab6=this[_0x237776(0x2c9)](_0x20dccd[_0x237776(0x320)],_0x20dccd[_0x237776(0x267)]),_0x3e5af7=void 0x0!==_0x20dccd[_0x237776(0x267)]?[_0x3bf25b[_0x237776(0x2a4)][_0x20dccd[_0x237776(0x267)]]]:_0x3bf25b[_0x237776(0x2a4)][_0x237776(0x29e)](_0x1aa9f0=>_0x237776(0x243)==_0x1aa9f0[_0x237776(0x299)]),_0x55a270=_0x3e5af7[_0x237776(0x2f3)](_0xaa15d9=>_0x3bf25b[_0x237776(0x2a4)][_0x237776(0x23f)](_0xaa15d9));if(!_0x3d1ab6||_0x237776(0x23b)==_0x3d1ab6[_0x237776(0x223)][_0x237776(0x208)][_0x237776(0x250)])return void _0x55a270[_0x237776(0x1f4)](_0x418b31=>_0x3bf25b[_0x237776(0x26c)](_0x418b31,_0x237776(0x1ca)));_0x55a270[_0x237776(0x1f4)](_0x57e663=>_0x3bf25b[_0x237776(0x26c)](_0x57e663,_0x237776(0x246)));const _0x1a92a4=_0x4c9494({'editor':_0x52d5c1,'reply':_0x3bf25b,'interaction':_0x35b404,'groups':_0x3e5af7,'transform':!0x0,'documentCompare':_0x530adb,'documentCompareOptions':{'anchor':_0x237776(0x22e),'markDeletions':!0x0}});let _0x40006a;_0x3d1ab6&&this[_0x237776(0x2bf)](_0x3d1ab6[_0x237776(0x223)]),_0x52d5c1[_0x237776(0x1e0)][_0x237776(0x30a)](_0x3a59b4=>{const _0x551577=_0x237776;_0x40006a=_0x3a59b4[_0x551577(0x1d6)],_0x52d5c1[_0x551577(0x24a)][_0x551577(0x232)](_0x551577(0x26f))[_0x551577(0x309)](_0x1a92a4),this[_0x551577(0x2fd)][_0x551577(0x28a)](_0x551577(0x211));}),this[_0x237776(0x1b4)][_0x237776(0x1c1)](_0x40006a,{'interactionId':_0x35b404['id'],'replyId':_0x3bf25b['id'],'indexes':_0x55a270[_0x237776(0x1e5)]()}),this[_0x237776(0x2d2)](_0x3bf25b);}[_0x5027f0(0x301)](_0x348229){const _0x2c4f48=_0x5027f0,_0x5756a1=_0x22d5bb(this[_0x2c4f48(0x214)]),_0x390a14=this[_0x2c4f48(0x214)][_0x2c4f48(0x24a)][_0x2c4f48(0x232)](_0x1b0eca),{reply:_0x30eb92,interaction:_0x3e2d2e}=this[_0x2c4f48(0x1aa)](_0x348229[_0x2c4f48(0x320)]),_0x5456bd=this[_0x2c4f48(0x2c9)](_0x348229[_0x2c4f48(0x320)],_0x348229[_0x2c4f48(0x267)]),_0x4d4edc=void 0x0!==_0x348229[_0x2c4f48(0x267)]?[_0x30eb92[_0x2c4f48(0x2a4)][_0x348229[_0x2c4f48(0x267)]]]:_0x30eb92[_0x2c4f48(0x2a4)][_0x2c4f48(0x29e)](_0x40bd60=>_0x2c4f48(0x243)==_0x40bd60[_0x2c4f48(0x299)]),_0x192537=_0x4d4edc[_0x2c4f48(0x2f3)](_0x2b6f34=>_0x30eb92[_0x2c4f48(0x2a4)][_0x2c4f48(0x23f)](_0x2b6f34));if(!_0x5456bd||_0x2c4f48(0x23b)==_0x5456bd[_0x2c4f48(0x223)][_0x2c4f48(0x208)][_0x2c4f48(0x250)])return void _0x192537[_0x2c4f48(0x1f4)](_0x118251=>_0x30eb92[_0x2c4f48(0x26c)](_0x118251,_0x2c4f48(0x1ca)));_0x192537[_0x2c4f48(0x1f4)](_0x558941=>_0x30eb92[_0x2c4f48(0x26c)](_0x558941,_0x2c4f48(0x246)));const _0x452c4=_0x4c9494({'editor':_0x5756a1,'reply':_0x30eb92,'interaction':_0x3e2d2e,'groups':_0x4d4edc,'transform':!0x0,'documentCompare':_0x390a14,'documentCompareOptions':{'anchor':_0x2c4f48(0x22e),'markDeletions':!0x1}});let _0x2ce87e;_0x5456bd&&this[_0x2c4f48(0x2bf)](_0x5456bd[_0x2c4f48(0x223)]),_0x5756a1[_0x2c4f48(0x1e0)][_0x2c4f48(0x30a)](_0x152561=>{const _0x5ee0c7=_0x2c4f48;_0x2ce87e=_0x152561[_0x5ee0c7(0x1d6)];for(const _0x4d04e8 of _0x452c4)_0x4d04e8[_0x5ee0c7(0x288)]=_0x5756a1[_0x5ee0c7(0x1e0)][_0x5ee0c7(0x2d1)][_0x5ee0c7(0x316)],_0x4e9a85(_0x5756a1,_0x4d04e8),_0x152561[_0x5ee0c7(0x1d6)][_0x5ee0c7(0x21f)](_0x4d04e8),_0x5756a1[_0x5ee0c7(0x1e0)][_0x5ee0c7(0x1cc)](_0x4d04e8);}),this[_0x2c4f48(0x1b4)][_0x2c4f48(0x1c1)](_0x2ce87e,{'interactionId':_0x3e2d2e['id'],'replyId':_0x30eb92['id'],'indexes':_0x192537[_0x2c4f48(0x1e5)]()}),this[_0x2c4f48(0x2d2)](_0x30eb92);}[_0x5027f0(0x266)](_0x5a7d5f){const _0xa3cfd9=_0x5027f0,{reply:_0x52db6e}=this[_0xa3cfd9(0x1aa)](_0x5a7d5f[_0xa3cfd9(0x320)]);_0x52db6e[_0xa3cfd9(0x26c)](_0x5a7d5f[_0xa3cfd9(0x267)],_0xa3cfd9(0x326));}[_0x5027f0(0x322)](_0x5d16b8,_0x199d36){const _0x466928=_0x5027f0;if(!this[_0x466928(0x2bd)])return;const {reply:_0x1ca728}=this[_0x466928(0x1aa)](_0x5d16b8),_0x216e8f=_0x1ca728[_0x466928(0x1ac)]({'showDiff':this[_0x466928(0x200)]});let _0x53ed6d,_0x345268;if(void 0x0!==_0x199d36?(_0x345268=_0x216e8f[_0x466928(0x276)](_0x1e2c7d=>_0x1e2c7d[_0x466928(0x2d6)]==_0x199d36),_0x53ed6d=_0x345268?.[_0x466928(0x2d6)]):(_0x345268=_0x216e8f[0x0],_0x53ed6d=_0x345268[_0x466928(0x2d6)]),this[_0x466928(0x2a6)]?.[_0x466928(0x320)]==_0x5d16b8&&this[_0x466928(0x2a6)]?.[_0x466928(0x267)]==_0x53ed6d)return;const _0x3c7410=this[_0x466928(0x2dc)](_0x5d16b8,_0x1ca728,_0x345268);if(!_0x3c7410)return void this[_0x466928(0x2bd)][_0x466928(0x312)]();this[_0x466928(0x2a6)]={'replyId':_0x5d16b8,'partIndex':_0x53ed6d},this[_0x466928(0x2bf)](_0x3c7410,!0x0);const _0x29fb91=this[_0x466928(0x325)](_0x5d16b8,_0x53ed6d,_0x466928(0x1b7));this[_0x466928(0x2bd)][_0x466928(0x203)]({'part':_0x345268,'renderingStrategy':_0x466928(0x24f)}),this[_0x466928(0x2bd)][_0x466928(0x300)]({'index':_0x53ed6d,'title':_0x4e370c(this[_0x466928(0x214)][_0x466928(0x2c2)],_0x466928(0x251),(_0x53ed6d+0x1)[_0x466928(0x2fc)]()),'showRotator':null!==_0x29fb91,'ranges':[_0x3c7410],'areActionsDisabled':_0x1ca728[_0x466928(0x2a0)]}),this[_0x466928(0x2bd)][_0x466928(0x238)](_0x466928(0x243)),this[_0x466928(0x2c1)][_0x466928(0x254)](_0x5d16b8,_0x53ed6d),this[_0x466928(0x2c1)][_0x466928(0x2a1)]({'id':_0x5d16b8,'index':_0x53ed6d,'isActive':!0x0});}[_0x5027f0(0x325)](_0x3645ad,_0x41b7a9,_0x1404ce){const _0xa8c104=_0x5027f0,{reply:_0x1b9832}=this[_0xa8c104(0x1aa)](_0x3645ad),_0x5a42e0=_0x1b9832[_0xa8c104(0x1ac)]({'showDiff':this[_0xa8c104(0x200)]});if(0x1==_0x5a42e0[_0xa8c104(0x219)])return null;const _0x4bdad1=_0x5a42e0[_0xa8c104(0x221)](_0x1ba417=>_0x1ba417[_0xa8c104(0x2d6)]==_0x41b7a9),_0xa5a99f=_0xa8c104(0x1b7)==_0x1404ce?0x1:-0x1;let _0x242ba9=_0x5a42e0['at']((_0x4bdad1+_0xa5a99f)%_0x5a42e0[_0xa8c104(0x219)])[_0xa8c104(0x2d6)],_0x45a6b8=_0x5a42e0[_0x242ba9];for(;!this[_0xa8c104(0x2dc)](_0x3645ad,_0x1b9832,_0x45a6b8);){if(_0x242ba9=_0x5a42e0['at']((_0x242ba9+_0xa5a99f)%_0x5a42e0[_0xa8c104(0x219)])[_0xa8c104(0x2d6)],_0x242ba9===_0x4bdad1)return null;_0x45a6b8=_0x5a42e0[_0x242ba9];}return _0x242ba9;}[_0x5027f0(0x2dc)](_0x57988f,_0x2057c7,_0xb967d1){const _0x4c53bb=_0x5027f0,_0x440797=_0x2057c7[_0x4c53bb(0x2a4)];if(!_0xb967d1[_0x4c53bb(0x1f2)])return null;const _0x39f2ed=_0x440797[_0x4c53bb(0x276)](_0x380056=>_0x380056[_0x4c53bb(0x2d6)]==_0xb967d1[_0x4c53bb(0x2d6)]);if(_0x4c53bb(0x243)!==_0x39f2ed?.[_0x4c53bb(0x299)])return null;const _0x4b7123=this[_0x4c53bb(0x2c9)](_0x57988f,_0xb967d1[_0x4c53bb(0x2d6)]);if(!_0x4b7123)return null;const {range:_0x52f971,currentIndex:_0x23f244}=_0x4b7123;return _0x4c53bb(0x23b)==_0x52f971[_0x4c53bb(0x208)][_0x4c53bb(0x250)]?(_0x2057c7[_0x4c53bb(0x26c)](_0x23f244,_0x4c53bb(0x1ca)),null):_0x4b7123[_0x4c53bb(0x223)];}[_0x5027f0(0x2c9)](_0x393371,_0x1517ab){const _0x315e3f=_0x5027f0,_0x5e8e44=_0x22d5bb(this[_0x315e3f(0x214)]),{reply:_0x57acb8,interaction:_0x58cdc5}=this[_0x315e3f(0x1aa)](_0x393371),_0x81f660=_0x57acb8[_0x315e3f(0x2a4)][_0x315e3f(0x29e)](_0x5aaca9=>_0x315e3f(0x243)==_0x5aaca9[_0x315e3f(0x299)]),_0x2d58b3=_0x81f660[_0x315e3f(0x2f3)](_0x3ff419=>_0x57acb8[_0x315e3f(0x2a4)][_0x315e3f(0x23f)](_0x3ff419));void 0x0===_0x1517ab&&(_0x1517ab=_0x2d58b3[0x0]);const _0x121ae7=_0x2d58b3[_0x315e3f(0x23f)](_0x1517ab);if(-0x1==_0x121ae7)return null;const _0x793827=_0x81f660[_0x121ae7],_0x390dbb=new _0x128a28([]),_0x31a6cf=new _0x128a28([]);for(const _0x1923d5 of _0x793827[_0x315e3f(0x1a6)])if(_0x315e3f(0x1de)!=_0x1923d5[_0x315e3f(0x22f)]&&_0x31a6cf[_0x315e3f(0x2fb)][_0x315e3f(0x32a)](_0x1923d5[_0x315e3f(0x1bb)][_0x315e3f(0x20b)](!0x0)),_0x315e3f(0x245)!=_0x1923d5[_0x315e3f(0x22f)]){const _0xa2cfa0=_0x323a6d(_0x5bb4d=>_0x68ecf9(_0x5bb4d,_0x315e3f(0x264))==_0x1923d5['id'],_0x57acb8[_0x315e3f(0x1fe)],!0x0);_0x390dbb[_0x315e3f(0x2fb)][_0x315e3f(0x32a)](_0xa2cfa0[_0x315e3f(0x20b)](!0x0));}if(0x0==_0x390dbb[_0x315e3f(0x2fb)][_0x315e3f(0x219)]){if(_0x793827[_0x315e3f(0x1a6)][0x0][_0x315e3f(0x228)]){const _0x4fde13=_0x25ed47(_0x315e3f(0x264),_0x793827[_0x315e3f(0x1a6)][0x0][_0x315e3f(0x228)],_0x57acb8[_0x315e3f(0x1fe)]);_0x390dbb[_0x315e3f(0x2fb)][_0x315e3f(0x2eb)](_0x4fde13[_0x315e3f(0x20b)](!0x0)),_0x31a6cf[_0x315e3f(0x2fb)][_0x315e3f(0x2eb)](_0x4fde13[_0x315e3f(0x20b)](!0x0)),_0x4fde13[_0x315e3f(0x315)]&&(_0x390dbb[_0x315e3f(0x2fb)][_0x315e3f(0x32a)](_0x4fde13[_0x315e3f(0x315)][_0x315e3f(0x20b)](!0x0)),_0x31a6cf[_0x315e3f(0x2fb)][_0x315e3f(0x32a)](_0x4fde13[_0x315e3f(0x315)][_0x315e3f(0x20b)](!0x0)));}else{const _0x24188c=_0x57acb8[_0x315e3f(0x1fe)][_0x315e3f(0x2fb)][0x0];if(!_0x24188c)return null;_0x390dbb[_0x315e3f(0x2fb)][_0x315e3f(0x32a)](_0x24188c[_0x315e3f(0x20b)](!0x0)),_0x31a6cf[_0x315e3f(0x2fb)][_0x315e3f(0x32a)](_0x24188c[_0x315e3f(0x20b)](!0x0));}}const _0x10fc85=_0x58cdc5[_0x315e3f(0x32c)](),_0x28a3fe=_0x5e8e44[_0x315e3f(0x1c2)][_0x315e3f(0x2e3)](_0x10fc85[_0x315e3f(0x1eb)]),_0x3763d1=_0x417201(_0x390dbb),_0x107dd2=_0x5e8e44[_0x315e3f(0x1c2)][_0x315e3f(0x2e3)](_0x3763d1),_0x4a3c37=_0x5e8e44[_0x315e3f(0x1c2)][_0x315e3f(0x2e3)](_0x3763d1),_0x2b29ee=_0x5e8e44[_0x315e3f(0x1e0)][_0x315e3f(0x1b2)](_0x107dd2,0x0),_0x5b5752=_0x417201(_0x31a6cf),_0x4cf678={'anchor':_0x2b29ee,'markDeletions':!0x1},_0x37c793=_0x5e8e44[_0x315e3f(0x24a)][_0x315e3f(0x232)](_0x1b0eca)[_0x315e3f(0x206)](_0x3763d1,_0x5b5752,_0x4cf678)[_0x315e3f(0x1c7)]();if(!_0x37c793[_0x315e3f(0x219)])return null;_0x5e8e44[_0x315e3f(0x1e0)][_0x315e3f(0x30a)](_0x906524=>{const _0x3a9c00=_0x315e3f;for(const _0xc75d36 of _0x37c793)if(_0x3a9c00(0x290)==_0xc75d36[_0x3a9c00(0x22f)]){const _0x254970=_0xc75d36[_0x3a9c00(0x1a8)],_0x4be89e=_0xc75d36[_0x3a9c00(0x2d8)],_0x83e501=new _0x568343(_0x254970,_0x4be89e);_0x906524[_0x3a9c00(0x1d6)][_0x3a9c00(0x21f)](_0x83e501),_0x5e8e44[_0x3a9c00(0x1e0)][_0x3a9c00(0x1cc)](_0x83e501);}else _0x3a9c00(0x2c5)!==_0xc75d36[_0x3a9c00(0x22f)]&&(_0xc75d36[_0x3a9c00(0x288)]=null,_0xc75d36[_0x3a9c00(0x28e)]=!0x1,_0x906524[_0x3a9c00(0x1d6)][_0x3a9c00(0x21f)](_0xc75d36),_0x5e8e44[_0x3a9c00(0x1e0)][_0x3a9c00(0x1cc)](_0xc75d36));});const _0x58fb6b=_0x2b3d24(_0x5e8e44,_0x37c793,_0x107dd2);_0x22d854(_0x5e8e44[_0x315e3f(0x1e0)],_0x58fb6b);const _0x573a49=_0x58fb6b[_0x315e3f(0x1ec)]()[_0x315e3f(0x220)][_0x315e3f(0x25b)][_0x315e3f(0x1e5)](),_0x22d568=_0x58fb6b[_0x315e3f(0x1ec)]()[_0x315e3f(0x1d0)][_0x315e3f(0x25b)][_0x315e3f(0x1e5)](),_0x5bc0f9=[];let _0x2e7470=_0x107dd2,_0x32002b=_0x4a3c37;for(let _0x1d95aa=0x0;_0x1d95aa<_0x22d568[_0x315e3f(0x219)];_0x1d95aa++){const _0x378e1b=_0x2e7470[_0x315e3f(0x2c7)]-_0x22d568[_0x1d95aa];_0x5bc0f9[_0x1d95aa]=_0x32002b[_0x315e3f(0x2c7)]-_0x378e1b,_0x2e7470=_0x2e7470[_0x315e3f(0x2e7)](_0x22d568[_0x1d95aa]),_0x32002b=_0x32002b[_0x315e3f(0x2e7)](_0x5bc0f9[_0x1d95aa]);}const _0x135d7d=_0x5e8e44[_0x315e3f(0x1e0)][_0x315e3f(0x21b)](_0x5e8e44[_0x315e3f(0x1e0)][_0x315e3f(0x28b)](_0x4a3c37,_0x573a49),_0x5e8e44[_0x315e3f(0x1e0)][_0x315e3f(0x28b)](_0x4a3c37,_0x5bc0f9)),_0x313ea9=_0x4a3c37[_0x315e3f(0x22a)](0x0)[_0x315e3f(0x2ac)](_0x213e06),_0x599206=Array[_0x315e3f(0x31c)](_0x28a3fe[_0x315e3f(0x271)]())[_0x315e3f(0x276)](_0x1aba9e=>_0x1aba9e[_0x315e3f(0x2ac)](_0x213e06)==_0x313ea9)[_0x315e3f(0x1b6)](),_0xbf1f94=_0x135d7d[_0x315e3f(0x220)][_0x315e3f(0x25b)][_0x315e3f(0x1e5)](),_0x526a6e=_0x135d7d[_0x315e3f(0x1d0)][_0x315e3f(0x25b)][_0x315e3f(0x1e5)]();_0xbf1f94[0x0]=_0x599206[0x0]+_0xbf1f94[0x0],_0x526a6e[0x0]=_0x599206[0x0]+_0x526a6e[0x0];let _0x20c0bc=_0x5e8e44[_0x315e3f(0x1e0)][_0x315e3f(0x21b)](_0x5e8e44[_0x315e3f(0x1e0)][_0x315e3f(0x28b)](_0x5e8e44[_0x315e3f(0x1e0)][_0x315e3f(0x2d1)][_0x315e3f(0x1dc)](),_0xbf1f94),_0x5e8e44[_0x315e3f(0x1e0)][_0x315e3f(0x28b)](_0x5e8e44[_0x315e3f(0x1e0)][_0x315e3f(0x2d1)][_0x315e3f(0x1dc)](),_0x526a6e));const _0x156389=_0x5e8e44[_0x315e3f(0x1e0)][_0x315e3f(0x2d1)][_0x315e3f(0x28c)][_0x315e3f(0x1c7)](_0x10fc85[_0x315e3f(0x316)]);for(const _0x1f5839 of _0x156389)_0x20c0bc=_0x29ade5[_0x315e3f(0x277)](_0x20c0bc[_0x315e3f(0x31a)](_0x1f5839));return{'range':_0x20c0bc,'currentIndex':_0x1517ab};}[_0x5027f0(0x27c)](_0x4a1f4d){const _0x3eedb0=_0x5027f0;if(!_0x4a1f4d[_0x3eedb0(0x24a)][_0x3eedb0(0x2e8)](_0x3eedb0(0x20e)))return;const _0x19a493=_0x4a1f4d[_0x3eedb0(0x308)][_0x3eedb0(0x232)](_0x3eedb0(0x22c)),_0x375845=_0x4a1f4d[_0x3eedb0(0x308)][_0x3eedb0(0x232)](_0x3eedb0(0x257));this[_0x3eedb0(0x280)](_0x19a493,_0x3eedb0(0x1a5),(_0x4bdeff,_0x37a3e7,_0x537a00)=>{const _0x262485=_0x3eedb0,_0x43c4c4=this[_0x262485(0x1b4)][_0x262485(0x232)](_0x37a3e7);if(!_0x43c4c4)return;const _0x5eac72=this[_0x262485(0x1a9)][_0x262485(0x1c0)](_0x43c4c4[_0x262485(0x2d0)])[_0x262485(0x210)](_0x43c4c4[_0x262485(0x320)]);_0x43c4c4[_0x262485(0x283)][_0x262485(0x1f4)](_0x1c1357=>_0x5eac72[_0x262485(0x26c)](_0x1c1357,_0x262485(0x243))),this[_0x262485(0x1b4)][_0x262485(0x1df)](_0x37a3e7),this[_0x262485(0x1b4)][_0x262485(0x1c1)](_0x537a00,_0x43c4c4);}),this[_0x3eedb0(0x280)](_0x375845,_0x3eedb0(0x1a5),(_0x2aa665,_0xe23d22,_0x6e143c)=>{const _0x231fb8=_0x3eedb0,_0x9df0be=this[_0x231fb8(0x1b4)][_0x231fb8(0x232)](_0xe23d22);if(!_0x9df0be)return;const _0x2ef81b=this[_0x231fb8(0x1a9)][_0x231fb8(0x1c0)](_0x9df0be[_0x231fb8(0x2d0)])[_0x231fb8(0x210)](_0x9df0be[_0x231fb8(0x320)]);_0x9df0be[_0x231fb8(0x283)][_0x231fb8(0x1f4)](_0xa85068=>_0x2ef81b[_0x231fb8(0x26c)](_0xa85068,_0x231fb8(0x246))),this[_0x231fb8(0x1b4)][_0x231fb8(0x1df)](_0xe23d22),this[_0x231fb8(0x1b4)][_0x231fb8(0x1c1)](_0x6e143c,_0x9df0be);});}async[_0x5027f0(0x1e4)](_0x521d2c){const _0x1d8095=_0x5027f0;this[_0x1d8095(0x214)][_0x1d8095(0x24a)][_0x1d8095(0x2e8)](_0x1d8095(0x1ba))&&this[_0x1d8095(0x214)][_0x1d8095(0x24a)][_0x1d8095(0x232)](_0x1d8095(0x1ba))[_0x1d8095(0x312)](),(this[_0x1d8095(0x214)][_0x1d8095(0x24a)][_0x1d8095(0x232)](_0x620505)[_0x1d8095(0x258)][_0x1d8095(0x237)](_0x1d8095(0x1d4)),this[_0x1d8095(0x2c1)][_0x1d8095(0x24b)](_0x1d8095(0x24f)),this[_0x1d8095(0x2c1)][_0x1d8095(0x30d)](!0x0),await this[_0x1d8095(0x218)]());try{await this[_0x1d8095(0x1fb)][_0x1d8095(0x29f)](_0x521d2c)[_0x1d8095(0x21e)](),await this[_0x1d8095(0x2d9)](_0x521d2c),this[_0x1d8095(0x213)]('\x20'),await this[_0x1d8095(0x1a9)][_0x1d8095(0x1d9)](_0x521d2c,this[_0x1d8095(0x2fd)][_0x1d8095(0x29c)]),this[_0x1d8095(0x1a9)][_0x1d8095(0x23c)]()&&this[_0x1d8095(0x1cb)]();}catch(_0x2189fb){this[_0x1d8095(0x2c1)][_0x1d8095(0x296)]({'errorMessage':_0x4e370c(this[_0x1d8095(0x214)][_0x1d8095(0x2c2)],_0x1d8095(0x1da)),'id':_0x521d2c}),this[_0x1d8095(0x25c)](new _0x1cac1d(_0x1d8095(0x25d),this,{'error':_0x2189fb}));}finally{this[_0x1d8095(0x2c1)][_0x1d8095(0x1bf)](),this[_0x1d8095(0x2c1)][_0x1d8095(0x24b)](_0x1d8095(0x1ab)),this[_0x1d8095(0x2c1)][_0x1d8095(0x30d)](!0x1);}}async[_0x5027f0(0x204)](){const _0x5a7605=_0x5027f0,_0x4f2857=this[_0x5a7605(0x1fb)][_0x5a7605(0x1c3)](this[_0x5a7605(0x304)](),{'limit':0x1,'sortBy':_0x5a7605(0x2e2)});try{const _0x7453bf=await _0x4f2857[_0x5a7605(0x298)]();return _0x7453bf[_0x5a7605(0x219)]?_0x7453bf[0x0]['id']:_0x5a7605(0x245);}catch(_0x4c85c2){return this[_0x5a7605(0x2c1)][_0x5a7605(0x296)]({'errorMessage':_0x4e370c(this[_0x5a7605(0x214)][_0x5a7605(0x2c2)],_0x5a7605(0x1da)),'id':_0xc400fc()}),this[_0x5a7605(0x25c)](new _0x1cac1d(_0x5a7605(0x235),this,{'error':_0x4c85c2})),this[_0x5a7605(0x2c1)][_0x5a7605(0x30d)](!0x1),this[_0x5a7605(0x2c1)][_0x5a7605(0x1b9)](),null;}}[_0x5027f0(0x225)](_0xe3605d){const _0x4ffbc4=_0x5027f0;this[_0x4ffbc4(0x1a9)]['id']===_0xe3605d&&this[_0x4ffbc4(0x2d9)]();}[_0x5027f0(0x1cb)](){const _0x17cae5=_0x5027f0;this[_0x17cae5(0x1a9)]?.[_0x17cae5(0x28f)](_0x4e370c(this[_0x17cae5(0x214)][_0x17cae5(0x2c2)],_0x17cae5(0x307)));}async[_0x5027f0(0x256)](){const _0x334cf8=_0x5027f0,_0x2452a6=this[_0x334cf8(0x2fd)][_0x334cf8(0x231)]();this[_0x334cf8(0x1a9)]?.[_0x334cf8(0x281)](_0x2452a6),this[_0x334cf8(0x1cb)]();}[_0x5027f0(0x1f0)](){const _0x1da89e=_0x5027f0;this[_0x1da89e(0x1a9)]?.[_0x1da89e(0x2e1)]();}[_0x5027f0(0x1d7)](){const _0x26a183=_0x5027f0;this[_0x26a183(0x2c1)][_0x26a183(0x1d7)]();}async[_0x5027f0(0x28d)](){const _0x116e01=_0x5027f0;await this[_0x116e01(0x2d9)]();}async[_0x5027f0(0x2c3)]({message:_0x12dde6,attributes:_0x202bb5}){const _0x18cb1d=_0x5027f0;await this[_0x18cb1d(0x1fd)]({'userMessage':_0x12dde6,'attributes':_0x202bb5});}[_0x5027f0(0x304)](){const _0xc23f48=_0x5027f0,_0x5a2833=this[_0xc23f48(0x214)][_0xc23f48(0x311)][_0xc23f48(0x232)](_0xc23f48(0x31f));if(!_0x5a2833)throw new _0x1cac1d(_0xc23f48(0x201),this);return _0x5a2833;}async[_0x5027f0(0x2d9)](_0xa8c65c){const _0x39a383=_0x5027f0;try{this[_0x39a383(0x2c1)][_0x39a383(0x252)](),await this[_0x39a383(0x1bc)](_0xa8c65c);}catch(_0x120e05){this[_0x39a383(0x2c1)][_0x39a383(0x296)]({'errorMessage':_0x4e370c(this[_0x39a383(0x214)][_0x39a383(0x2c2)],_0x39a383(0x32e)),'id':_0xa8c65c||_0xc400fc()}),console[_0x39a383(0x30c)](_0x120e05),this[_0x39a383(0x1a9)]=void 0x0,this[_0x39a383(0x2c1)][_0x39a383(0x1b9)]();}}async[_0x5027f0(0x1bc)](_0x161138){const _0x50ffe7=_0x5027f0;let _0x1b2d7e;this[_0x50ffe7(0x214)][_0x50ffe7(0x24a)][_0x50ffe7(0x2e8)](_0x50ffe7(0x1ba))&&this[_0x50ffe7(0x214)][_0x50ffe7(0x24a)][_0x50ffe7(0x232)](_0x50ffe7(0x1ba))[_0x50ffe7(0x312)](),_0x161138||!this[_0x50ffe7(0x1a9)]?_0x1b2d7e=this[_0x50ffe7(0x214)][_0x50ffe7(0x311)][_0x50ffe7(0x232)](_0x50ffe7(0x2d4)):this[_0x50ffe7(0x2c1)][_0x50ffe7(0x279)]&&(_0x1b2d7e=this[_0x50ffe7(0x1a9)][_0x50ffe7(0x1c6)]['id']),await this[_0x50ffe7(0x218)]();const _0x1ea9cd=this[_0x50ffe7(0x304)](),_0x35428a=_0x161138||_0xc400fc();this[_0x50ffe7(0x1a9)]=new _0x126b86({'connector':this[_0x50ffe7(0x1fb)],'chatModels':this[_0x50ffe7(0x230)],'selectedModelId':_0x1b2d7e,'conversationId':_0x35428a,'group':_0x1ea9cd,'getEditor':()=>_0x22d5bb(this[_0x50ffe7(0x214)]),'isFromHistory':!!_0x161138}),this[_0x50ffe7(0x1a9)][_0x50ffe7(0x202)](_0x50ffe7(0x244),_0x50ffe7(0x297))['to'](this),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x2ad),(_0x4e462a,_0x118de5)=>{const _0x2ad52a=_0x50ffe7;this[_0x2ad52a(0x2c1)][_0x2ad52a(0x22b)](_0x118de5),this[_0x2ad52a(0x2c1)][_0x2ad52a(0x2b2)](),this[_0x2ad52a(0x2c1)][_0x2ad52a(0x24d)](),this[_0x2ad52a(0x2c1)][_0x2ad52a(0x2f4)](),_0x161138||(this[_0x2ad52a(0x2c1)][_0x2ad52a(0x273)](),this[_0x2ad52a(0x1cb)]());}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x2b8),(_0x1838c0,_0x32feb4)=>{const _0x316e0e=_0x50ffe7;this[_0x316e0e(0x2c1)][_0x316e0e(0x2f1)](_0x32feb4[_0x316e0e(0x2e6)]);}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x2aa),(_0x314ab4,_0x4a60bf)=>{const _0x5f310b=_0x50ffe7;this[_0x5f310b(0x2c1)][_0x5f310b(0x1fc)](_0x4a60bf);}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x287),()=>{const _0x422dfb=_0x50ffe7,_0xb45227=this[_0x422dfb(0x2c1)][_0x422dfb(0x2bc)]({'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});this[_0x422dfb(0x2c1)][_0x422dfb(0x226)](_0xb45227);}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x323),()=>{const _0x46be7b=_0x50ffe7,_0x23c5fd=this[_0x46be7b(0x2c1)][_0x46be7b(0x2bc)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});this[_0x46be7b(0x2c1)][_0x46be7b(0x226)](_0x23c5fd);}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x2b0),(_0x19f9c9,_0x277199)=>{const _0x5ce8dc=_0x50ffe7;this[_0x5ce8dc(0x2c1)][_0x5ce8dc(0x1d1)](_0x277199,{'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x2db),(_0x5af0fe,_0x24b545)=>{const _0x53ab03=_0x50ffe7;this[_0x53ab03(0x2c1)][_0x53ab03(0x1d1)](_0x24b545,{'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x297),()=>{const _0x15d6d4=_0x50ffe7;this[_0x15d6d4(0x2c1)][_0x15d6d4(0x248)]();}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x313),async()=>{const _0x3c33f2=_0x50ffe7;await this[_0x3c33f2(0x2c1)][_0x3c33f2(0x292)]();}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x327),(_0x1c58a2,_0x154d1b)=>{const _0x3c49e0=_0x50ffe7;this[_0x3c49e0(0x2c1)][_0x3c49e0(0x318)](_0x154d1b['id']);}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x2ef),(_0x26b9ec,_0x46748c,_0x55dd8c)=>{const _0x495039=_0x50ffe7;this[_0x495039(0x213)](_0x46748c,_0x55dd8c);}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x2ae),(_0x119354,_0x48d092)=>{const _0x2c3a92=_0x50ffe7;_0x2c3a92(0x2a7)===_0x48d092[_0x2c3a92(0x22f)]?this[_0x2c3a92(0x2c1)][_0x2c3a92(0x2ce)](_0x48d092):this[_0x2c3a92(0x2c1)][_0x2c3a92(0x1f1)](_0x48d092);}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x2a9),async(_0x2d03e3,_0x48e912)=>{const _0xd5cd0c=_0x50ffe7;await this[_0xd5cd0c(0x1e7)]({'reply':_0x48e912});}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x2b7),(_0x55cd02,{reply:_0x8851db,index:_0x2dcbab,state:_0x35c5bf})=>{const _0x2701a4=_0x50ffe7;this[_0x2701a4(0x2c1)][_0x2701a4(0x1d3)]({'id':_0x8851db['id'],'index':_0x2dcbab,'state':_0x35c5bf}),this[_0x2701a4(0x2a6)]?.[_0x2701a4(0x320)][_0x2701a4(0x1a7)](_0x8851db['id'])&&this[_0x2701a4(0x2a6)]?.[_0x2701a4(0x267)]==_0x2dcbab&&this[_0x2701a4(0x2bd)]?.[_0x2701a4(0x238)](_0x35c5bf);}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x2cc),(_0x3f903b,_0x47771e)=>{const _0x21e40a=_0x50ffe7;if(this[_0x21e40a(0x2c1)][_0x21e40a(0x27a)](_0x47771e[_0x21e40a(0x329)],_0x47771e[_0x21e40a(0x20f)]),_0x21e40a(0x20c)===_0x47771e[_0x21e40a(0x329)][_0x21e40a(0x22f)]){const _0x17ed2f=[..._0x22d5bb(this[_0x21e40a(0x214)])[_0x21e40a(0x1e0)][_0x21e40a(0x2d1)][_0x21e40a(0x20c)][_0x21e40a(0x1b1)]()];this[_0x21e40a(0x2fd)][_0x21e40a(0x247)](_0x17ed2f,_0x21e40a(0x2c4)+this[_0x21e40a(0x1a9)]?.['id']);}}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x2b1),(_0x58b39c,_0x422d01)=>{const _0x3a21bc=_0x50ffe7;this[_0x3a21bc(0x2c1)][_0x3a21bc(0x233)](_0x422d01[_0x3a21bc(0x236)]),_0x3a21bc(0x27f)==_0x422d01[_0x3a21bc(0x236)]&&this[_0x3a21bc(0x1f0)](),_0x3a21bc(0x20c)===_0x422d01[_0x3a21bc(0x22f)]&&this[_0x3a21bc(0x2fd)][_0x3a21bc(0x28a)](_0x3a21bc(0x2c4)+this[_0x3a21bc(0x1a9)]?.['id']);}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x289),(_0x82092b,_0x239909)=>{const _0x2e1570=_0x50ffe7;this[_0x2e1570(0x2c1)][_0x2e1570(0x269)](_0x239909[_0x2e1570(0x329)][_0x2e1570(0x236)],_0x239909[_0x2e1570(0x20f)]);}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x24e),(_0x1490e6,_0x1d3798)=>{const _0x3f02e4=_0x50ffe7;this[_0x3f02e4(0x2c1)][_0x3f02e4(0x216)](_0x1d3798[_0x3f02e4(0x26a)]);}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x22d),(_0x500f53,_0x391dbc)=>{const _0x40b19c=_0x50ffe7;this[_0x40b19c(0x2c1)][_0x40b19c(0x2f6)](_0x391dbc[_0x40b19c(0x2f5)]);}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x25e),(_0x4dab87,_0x40a04c)=>{const _0x15d708=_0x50ffe7;this[_0x15d708(0x2c1)][_0x15d708(0x2cd)](_0x40a04c[_0x15d708(0x1ef)],_0x40a04c[_0x15d708(0x2cb)],_0x40a04c[_0x15d708(0x32b)],_0x40a04c[_0x15d708(0x2cf)]);}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x1dd),(_0x2be9bd,_0xf66d9a)=>{const _0x17d499=_0x50ffe7;this[_0x17d499(0x2c1)][_0x17d499(0x306)](_0xf66d9a[_0x17d499(0x1ef)],_0xf66d9a[_0x17d499(0x1e8)],_0xf66d9a[_0x17d499(0x25a)]);}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x1f8),(_0x38485f,_0x327e4d)=>{const _0x3456a9=_0x50ffe7;this[_0x3456a9(0x2c1)][_0x3456a9(0x1b8)](_0x327e4d);}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x1f5),async(_0x5b85bd,_0x16b18c)=>{const _0x1c1e39=_0x50ffe7,_0x230a27=(await this[_0x1c1e39(0x230)][_0x1c1e39(0x295)]())[_0x1c1e39(0x276)](_0x13ee6d=>_0x13ee6d['id']===_0x16b18c[_0x1c1e39(0x1c6)]?.['id'])||null;this[_0x1c1e39(0x2c1)][_0x1c1e39(0x229)](_0x230a27,_0x16b18c[_0x1c1e39(0x205)]);}),this[_0x50ffe7(0x1a9)]['on'](_0x50ffe7(0x30c),(_0x56b90b,{error:_0xf38d8c,interactionId:_0x1ca3de,fileName:_0x11d636,url:_0x51e044,sourceId:_0x59cb85,sourceLabel:_0x2f63f8})=>{const _0x5031a0=_0x50ffe7,_0x1abee9=_0x1ca3de?_0x1ca3de+':'+_0xc400fc():_0xc400fc();_0xf38d8c[_0x5031a0(0x2e9)][_0x5031a0(0x1c4)](_0x5031a0(0x27e))?this[_0x5031a0(0x2c1)][_0x5031a0(0x27d)]({'staticMessage':_0x4e370c(this[_0x5031a0(0x214)][_0x5031a0(0x2c2)],_0x5031a0(0x285)),'id':_0x1abee9}):_0xf38d8c[_0x5031a0(0x2e9)][_0x5031a0(0x1c4)](_0x5031a0(0x235))||_0xf38d8c[_0x5031a0(0x2e9)][_0x5031a0(0x1c4)](_0x5031a0(0x260))?(this[_0x5031a0(0x2c1)][_0x5031a0(0x296)]({'errorMessage':_0x4e370c(this[_0x5031a0(0x214)][_0x5031a0(0x2c2)],_0x5031a0(0x32e)),'id':_0x1abee9}),this[_0x5031a0(0x25c)](_0xf38d8c)):_0xf38d8c[_0x5031a0(0x2e9)][_0x5031a0(0x1c4)](_0x5031a0(0x2fa))?this[_0x5031a0(0x2c1)][_0x5031a0(0x296)]({'errorMessage':_0x4e370c(this[_0x5031a0(0x214)][_0x5031a0(0x2c2)],_0x5031a0(0x209),_0x11d636),'id':_0x1abee9}):_0xf38d8c[_0x5031a0(0x2e9)][_0x5031a0(0x1c4)](_0x5031a0(0x284))?this[_0x5031a0(0x2c1)][_0x5031a0(0x296)]({'errorMessage':_0x4e370c(this[_0x5031a0(0x214)][_0x5031a0(0x2c2)],_0x5031a0(0x29a),_0x51e044),'id':_0x1abee9}):_0xf38d8c[_0x5031a0(0x2e9)][_0x5031a0(0x1c4)](_0x5031a0(0x31d))?this[_0x5031a0(0x2c1)][_0x5031a0(0x296)]({'errorMessage':_0x4e370c(this[_0x5031a0(0x214)][_0x5031a0(0x2c2)],_0x5031a0(0x1e3)),'id':_0x1abee9}):_0xf38d8c[_0x5031a0(0x2e9)][_0x5031a0(0x1c4)](_0x5031a0(0x1db))?this[_0x5031a0(0x2c1)][_0x5031a0(0x296)]({'errorMessage':_0x4e370c(this[_0x5031a0(0x214)][_0x5031a0(0x2c2)],_0x5031a0(0x303)),'id':_0x1abee9}):_0xf38d8c[_0x5031a0(0x2e9)][_0x5031a0(0x1c4)](_0x5031a0(0x30f))?(_0x59cb85&&this[_0x5031a0(0x2c1)][_0x5031a0(0x2ec)](_0x59cb85),this[_0x5031a0(0x2c1)][_0x5031a0(0x296)]({'errorMessage':_0x4e370c(this[_0x5031a0(0x214)][_0x5031a0(0x2c2)],_0x5031a0(0x23e),_0x2f63f8||_0x5031a0(0x2cb)),'id':_0x1abee9}),this[_0x5031a0(0x25c)](_0xf38d8c)):_0xf38d8c[_0x5031a0(0x2e9)][_0x5031a0(0x1c4)](_0x5031a0(0x328))?(this[_0x5031a0(0x2c1)][_0x5031a0(0x296)]({'errorMessage':_0x4e370c(this[_0x5031a0(0x214)][_0x5031a0(0x2c2)],_0x5031a0(0x1be)),'id':_0x1abee9}),this[_0x5031a0(0x25c)](_0xf38d8c)):_0xf38d8c[_0x5031a0(0x2e9)][_0x5031a0(0x1c4)](_0x5031a0(0x2a5))?(this[_0x5031a0(0x2c1)][_0x5031a0(0x296)]({'errorMessage':_0x4e370c(this[_0x5031a0(0x214)][_0x5031a0(0x2c2)],_0x5031a0(0x222)),'id':_0x1abee9}),this[_0x5031a0(0x25c)](_0xf38d8c)):_0xf38d8c[_0x5031a0(0x2e9)][_0x5031a0(0x1c4)](_0x5031a0(0x2bb))?(this[_0x5031a0(0x2c1)][_0x5031a0(0x296)]({'errorMessage':_0x4e370c(this[_0x5031a0(0x214)][_0x5031a0(0x2c2)],_0x5031a0(0x215)),'id':_0x1abee9}),this[_0x5031a0(0x25c)](_0xf38d8c)):_0xf38d8c[_0x5031a0(0x2e9)][_0x5031a0(0x1c4)](_0x5031a0(0x20d))?(this[_0x5031a0(0x2c1)][_0x5031a0(0x296)]({'errorMessage':_0x4e370c(this[_0x5031a0(0x214)][_0x5031a0(0x2c2)],_0x5031a0(0x2dd)),'id':_0x1abee9}),this[_0x5031a0(0x25c)](_0xf38d8c)):_0xf38d8c[_0x5031a0(0x2e9)][_0x5031a0(0x1c4)](_0x5031a0(0x2e4))?(this[_0x5031a0(0x2c1)][_0x5031a0(0x296)]({'errorMessage':_0x4e370c(this[_0x5031a0(0x214)][_0x5031a0(0x2c2)],_0x5031a0(0x310)),'id':_0x1abee9}),this[_0x5031a0(0x25c)](_0xf38d8c)):_0xf38d8c[_0x5031a0(0x2e9)][_0x5031a0(0x1c4)](_0x5031a0(0x1cd))?(this[_0x5031a0(0x2c1)][_0x5031a0(0x296)]({'errorMessage':_0x4e370c(this[_0x5031a0(0x214)][_0x5031a0(0x2c2)],_0x5031a0(0x1af)),'id':_0x1abee9}),this[_0x5031a0(0x25c)](_0xf38d8c)):(this[_0x5031a0(0x2c1)][_0x5031a0(0x296)]({'errorMessage':_0x4e370c(this[_0x5031a0(0x214)][_0x5031a0(0x2c2)],_0x5031a0(0x274)),'id':_0x1abee9}),this[_0x5031a0(0x25c)](_0xf38d8c));}),await this[_0x50ffe7(0x1a9)][_0x50ffe7(0x234)](this[_0x50ffe7(0x214)][_0x50ffe7(0x311)][_0x50ffe7(0x232)](_0x50ffe7(0x321))),_0x161138||await this[_0x50ffe7(0x1a9)][_0x50ffe7(0x220)]();}async[_0x5027f0(0x1fd)]({userMessage:_0x4c13f6,attributes:_0x39503b}){const _0x49ec95=_0x5027f0;if(!this[_0x49ec95(0x1a9)])throw new _0x1cac1d(_0x49ec95(0x2b3));if(this[_0x49ec95(0x1a9)][_0x49ec95(0x1e2)]()){const _0xce98f8=await this[_0x49ec95(0x2fd)][_0x49ec95(0x253)]();await this[_0x49ec95(0x1a9)][_0x49ec95(0x1ed)](_0xce98f8);}this[_0x49ec95(0x1a9)]['id']&&this[_0x49ec95(0x1a9)][_0x49ec95(0x1ce)]&&await this[_0x49ec95(0x1a9)][_0x49ec95(0x1bd)]({'userMessage':_0x4c13f6,'attributes':_0x39503b});}[_0x5027f0(0x1ff)](){const _0x4fad0d=_0x5027f0;console[_0x4fad0d(0x2b5)](_0x4fad0d(0x319));}[_0x5027f0(0x268)](_0x19f736){const _0x3ed95d=_0x5027f0;this[_0x3ed95d(0x2c1)][_0x3ed95d(0x2a8)](_0x19f736);}[_0x5027f0(0x25c)](_0x27d80d){const _0x5ee159=_0x5027f0;_0x5d39d3(_0x27d80d[_0x5ee159(0x2e9)]);}[_0x5027f0(0x1e6)](_0x4be07a){const _0x3b6c02=_0x5027f0;this[_0x3b6c02(0x1a9)]?.[_0x3b6c02(0x286)](_0x4be07a);}[_0x5027f0(0x2d5)](){const _0x555cbb=_0x5027f0;this[_0x555cbb(0x1a9)]?.[_0x555cbb(0x1e9)]();}[_0x5027f0(0x2d7)](){const _0x3b0955=_0x5027f0;this[_0x3b0955(0x1a9)]?.[_0x3b0955(0x1b5)]();}[_0x5027f0(0x1aa)](_0x1fbd43){const _0x35f1a6=_0x5027f0,[_0x189731,_0xf5ee14]=_0x1fbd43[_0x35f1a6(0x25f)](':'),_0x501d12=this[_0x35f1a6(0x1a9)][_0x35f1a6(0x1c0)](_0x189731),_0x44656f=_0x501d12[_0x35f1a6(0x210)](_0xf5ee14);return{'interaction':_0x501d12,'reply':_0x44656f};}[_0x5027f0(0x2bf)](_0x43cbf5,_0x31d935=!0x1){const _0x514d09=_0x5027f0,_0x481c77=_0x22d5bb(this[_0x514d09(0x214)]),_0x1ba5f1={'target':_0x481c77[_0x514d09(0x20a)][_0x514d09(0x258)][_0x514d09(0x278)][_0x514d09(0x227)](_0x481c77[_0x514d09(0x20a)][_0x514d09(0x2b4)][_0x514d09(0x2ee)](_0x43cbf5)),'viewportOffset':{'top':0x96,'left':0x0,'bottom':0x32,'right':0x0},'ancestorOffset':0x14,'alignToTop':_0x31d935};_0x31d935&&(_0x1ba5f1[_0x514d09(0x212)]=!0x0),_0x2d5201(_0x1ba5f1);}[_0x5027f0(0x213)](_0x410831,_0x2b702c=!0x1){const _0x1690fb=_0x5027f0;this[_0x1690fb(0x2c1)][_0x1690fb(0x2ef)](_0x410831||_0x4e370c(this[_0x1690fb(0x214)][_0x1690fb(0x2c2)],_0x1690fb(0x1ee)),_0x2b702c);}async[_0x5027f0(0x1e7)]({reply:_0x49d3e7,renderingStrategy:_0xa62801}){const _0x51f90e=_0x5027f0,{id:_0x345af0,interactionId:_0x238ce8,isDone:_0x373d9d,type:_0x11016e,parsedContent:_0x6cc0be}=_0x49d3e7,_0xf965a7=_0x238ce8+':'+_0x345af0;if(_0x51f90e(0x2af)===_0x11016e){const _0x2ec9fd=_0x49d3e7[_0x51f90e(0x1ac)]({'showDiff':this[_0x51f90e(0x2c1)][_0x51f90e(0x2df)]});await this[_0x51f90e(0x2c1)][_0x51f90e(0x314)]({'id':_0xf965a7,'parts':_0x2ec9fd,'renderingStrategy':_0xa62801,'isDone':_0x373d9d});}else _0x51f90e(0x2a7)===_0x11016e&&await this[_0x51f90e(0x2c1)][_0x51f90e(0x2f0)]({'id':_0xf965a7,'parsedContent':_0x6cc0be,'renderingStrategy':_0xa62801,'isDone':_0x373d9d});_0x373d9d&&_0x49d3e7[_0x51f90e(0x2e5)][_0x51f90e(0x219)]>0x0&&this[_0x51f90e(0x2c1)][_0x51f90e(0x2da)](_0xf965a7,_0x49d3e7[_0x51f90e(0x2e5)]);}async[_0x5027f0(0x218)](){const _0x1913c6=_0x5027f0,_0x2b52a5=this[_0x1913c6(0x1a9)]?.[_0x1913c6(0x263)];_0x2b52a5&&(_0x2b52a5[_0x1913c6(0x31b)](),this[_0x1913c6(0x2c1)][_0x1913c6(0x282)](_0x2b52a5));}async[_0x5027f0(0x261)](){const _0x13bef6=_0x5027f0,_0x590fe2=this[_0x13bef6(0x1a9)]?.[_0x13bef6(0x263)];if(_0x590fe2){for await(const _0x5af297 of _0x590fe2[_0x13bef6(0x2be)])await this[_0x13bef6(0x1e7)]({'reply':_0x5af297,'renderingStrategy':_0x13bef6(0x24f)});}}[_0x5027f0(0x2d2)](_0x31a737){const _0x365923=_0x5027f0,_0x2a2c45={'positiveCount':_0x31a737[_0x365923(0x2a4)][_0x365923(0x29e)](_0x5b0194=>_0x365923(0x246)===_0x5b0194[_0x365923(0x299)])[_0x365923(0x219)],'totalCount':_0x31a737[_0x365923(0x2a4)][_0x365923(0x219)],'modificationId':_0x31a737['id']},_0xdd06ef=this[_0x365923(0x1a9)][_0x365923(0x1c0)](_0x31a737[_0x365923(0x2d0)])[_0x365923(0x305)];_0xdd06ef&&this[_0x365923(0x1fb)][_0x365923(0x2f2)](this[_0x365923(0x1a9)]['id'],_0xdd06ef,_0x2a2c45);}[_0x5027f0(0x2b6)](_0x36d585){const _0x2d398d=_0x5027f0;let _0x4bc403=null,_0x463a40=null;this['on'](_0x2d398d(0x244),(_0x18eb2f,_0x383f35,_0xfa60b)=>{const _0x5b80a2=_0x2d398d;_0xfa60b['id']!==_0x4bc403&&(_0x4bc403=_0xfa60b['id'],_0x463a40=this[_0x5b80a2(0x1d8)](_0xfa60b)),_0x36d585(_0x383f35,_0x463a40);});}[_0x5027f0(0x1d8)](_0x4e4638){const _0x344f20=_0x5027f0,_0x4296ef=this[_0x344f20(0x2c1)],_0x1a4110=()=>{const _0x4c55b1=_0x344f20;_0x4e4638[_0x4c55b1(0x2fe)](),_0x4e4638[_0x4c55b1(0x24c)](),_0x4296ef[_0x4c55b1(0x1c5)]();},_0x3ac5f2=()=>{const _0x172671=_0x344f20;_0x4e4638[_0x172671(0x1e1)]&&(_0x4e4638[_0x172671(0x1e1)][_0x172671(0x2a2)](),_0x4e4638[_0x172671(0x1e1)]=void 0x0);};return{'insertTextReply':(_0x4f1a1a,_0x1066ab)=>{const _0x107bc6=_0x344f20;_0x3ac5f2(),_0x1a4110();const _0x47cebb=_0x4e4638[_0x107bc6(0x1e1)]=_0x4e4638[_0x107bc6(0x2de)]({'type':_0x107bc6(0x2a7),'interactionId':_0x4e4638['id'],'content':_0x4f1a1a,'id':_0x1066ab||_0xc400fc()});return _0x3ac5f2(),_0x47cebb;},'insertCustomElement':async(_0x314e34,_0x596ec9)=>(_0x3ac5f2(),_0x1a4110(),_0x4296ef[_0x344f20(0x26e)](_0x314e34,_0x596ec9||_0xc400fc())),'setLoadingMessage':_0x180ecc=>{const _0x5b2186=_0x344f20;_0x4296ef[_0x5b2186(0x226)](_0x180ecc);},'clearLoadingMessage':()=>{const _0xdaf9d3=_0x344f20;_0x4296ef[_0xdaf9d3(0x1c5)]();}};}}
23
+ const _0x2747dd=_0x34fc;(function(_0x235cef,_0x1ff040){const _0x44197f=_0x34fc,_0x1fb211=_0x235cef();while(!![]){try{const _0x2c35cd=parseInt(_0x44197f(0x2cb))/0x1+-parseInt(_0x44197f(0x293))/0x2+parseInt(_0x44197f(0x35e))/0x3*(-parseInt(_0x44197f(0x2a0))/0x4)+parseInt(_0x44197f(0x1fe))/0x5*(-parseInt(_0x44197f(0x33e))/0x6)+parseInt(_0x44197f(0x23c))/0x7*(-parseInt(_0x44197f(0x368))/0x8)+parseInt(_0x44197f(0x2bd))/0x9+parseInt(_0x44197f(0x214))/0xa;if(_0x2c35cd===_0x1ff040)break;else _0x1fb211['push'](_0x1fb211['shift']());}catch(_0x518e9a){_0x1fb211['push'](_0x1fb211['shift']());}}}(_0x3048,0xabf23));import{ContextPlugin as _0x2d315c,Editor as _0x2e07c5}from'ckeditor5/src/core.js';function _0x34fc(_0x2976cd,_0xfcc963){const _0x30482b=_0x3048();return _0x34fc=function(_0x34fced,_0x3ad431){_0x34fced=_0x34fced-0x1e4;let _0x69b37c=_0x30482b[_0x34fced];return _0x69b37c;},_0x34fc(_0x2976cd,_0xfcc963);}import{BodyCollection as _0x11d605}from'ckeditor5/src/ui.js';import{CKEditorError as _0x2f9ac0,logError as _0x4adf39,scrollViewportToShowTarget as _0x26977c,uid as _0x441c86}from'ckeditor5/src/utils.js';import{AIConnector as _0x4fc309}from'../aicore/aiconnector.js';import{AITabs as _0x2e48c5}from'../aitabs/aitabs.js';import{AIChatConversation as _0x13f3a3}from'./model/aichatconversation.js';import{getTranslation as _0x3bbccd}from'../aicore/utils/common-translations.js';import{AIModels as _0x2b8021}from'../aicore/model/aimodels.js';import{getEditorFromContext as _0x1edd1c}from'../aicore/utils/geteditorfromcontext.js';import{DocumentCompare as _0x159832,DATA_ID_MODEL_ATTRIBUTE as _0x192377}from'ckeditor5-collaboration/src/collaboration-core.js';import{fixMarkerOperationOldRange as _0x424953,getOperationsFromReply as _0x357892}from'../aicore/utils/getoperationsfromreply.js';import{expandSelectionWithContext as _0x25c4d2,getMinimalSelection as _0x41899c}from'../aicore/utils/getsuggestionpartsfromreply.js';function _0x3048(){const _0x2ebb8e=['ai-chat-context-invalid-data','_removeFromContext','addFileToContext','removeFeedInteraction','message','toggleWebSearch','AI_CHAT_ABORTED_MESSAGE','_aiEditing','ready','_setIsMaximized','filter','uid','domConverter','_openBalloonFor','setAddContextOptions','getDocumentContext','interactionStarted','loadConversation','updateResourceState','clearConversationContextUI','AI_CHAT_CONTEXT_FILE_TOO_MANY_PAGES','resizeTabs','bind','AIEditing','addSelectionToChatContext','_toggleReasoning','sourceId','addCurrentDocumentToChatContext','webSearchFinished','_showConversationHistory','locale','attachToDom','getChild','contextItems','toggleLoadingSkeleton','ai-no-track-changes','toString','updateConversationTitle','reasoningStarted','range','_handleUIUserMessage','addFeedItemStaticMessage','slice','modelSelected','Liked\x20response','_updateRatings','_rejectSuggestion','activeConversation','has','findIndex','commands','getOperations','type','data-id','open','end','documentContextContent','selection','closeSourceResourceBalloon','children','2486164PQZOkq','addCurrentDocumentToContext','conversationInitialized','interactionId','fetchConversations','_scrollToSuggestionRange','content','ai-chat-invalid-request','ai-chat-context-unsupported-type','_insertSuggestion','load','showFakeVisualSelection','batch','2468rVrDCT','indexes','map','interactionFinished','getTransformedByOperation','accepted','hideFakeVisualSelection','executeCustomItemCallback','maxOffset','clearLoadingMessage','updateCurrentDocumentInContext','setFeedItemAIReplySuggestionPartActive','removeSelectionFromContext','showNext','start','Disliked\x20response','text','sendUserMessage','_aiChatModels','messageId','isCurrentDocumentInContext','addDocumentToContext','state','contextItemAdded','startConversation','delegate','capabilitiesUpdated','isModelAvailable','getConversations','12293523NNXSWF','get','resource','uploadProgressChanged','add','scrollFeedToSuggestion','stopInteraction','focusPromptInput','rejectSuggestion','ai-chat-conversation-init-failed','_applyOperationsAsSuggestions','dialogClosed','removed','reasoningFinished','1214407yblTKg','static','addFeedInteractionHeader','resourceId','replyContentUpdated','mapper','alignToTop','abortPromptStream','ai-conversation-','revert','getConversation','ai-chat-controller-no-active-conversation','AI_CHAT_RESOURCE_LOAD_FAILED','contextItemLoadingEnded','setChangeGroupState','editors','populateSourceResourceBalloon','addFeedItemUserMessage','getGroupId','AIChatBalloon','showPrevious','TrackChangesEditing','getPath','plugins','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_FILE','replyId','_batchToChanges','replyChangeGroupStateUpdated','listenTo','sourcePosition','ai-chat-resource-load-failed','view','ai.chat.context','previous','AI_CHAT_UNTITLED_CONVERSATION','addContextItem','getDocumentData','_currentPreviewedChangeGroup','clearPendingContextUI','AI_CHAT_CONTEXT_FILE_TOO_LARGE','_registerToolDataCallback','hasChanges','showDiff','isLoading','resourceStateChanged','AI_CHAT_CONTEXT_CURRENT_DOCUMENT','getDiff','ai-chat-context-unsupported-file-type','applyOperation','fetchConversation','context','changeGroups','resizedTabs','$graveyard','toggleSuggestionDisplayMode','lastInteraction','close','AI_CHAT_CONTEXT_UNABLE_TO_LOAD_RESOURCES','TrackChanges','setIsUploadInProgress','_getPresentableSiblingContentPartIndex','webSearchStarted','from','contextItem','ai-chat-controller-mouse-over','ai-chat-conversation-start-failed','ai-chat-context-form-data-size-limits-exceeded','addFeedItemError','source','_aiChatUi','handleUserInteraction','addFeedItemAISuggestion','finishInteraction','toolDataReceived','_getDocumentRangeForReplyChanges','ai.models.defaultModelId','resize','resources','getInteractionAndReplyById','resetWebSearchState','root','createReply','enableControls','getAttribute','toggleReasoning','removeFromContext','_createFromRanges','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_URL','rejected','marker','removeSelectionFromChatContext','AI_BALLOON_HEADER_TITLE','remove','rootName','addFilesToContext','_getLastCreatedConversationId','indexOf','replies','streaming','sources','AI_CHAT_CONTEXT_UNSUPPORTED_TYPE','config','resetReasoningState','options','aiChatBalloon','detachFromDom','change','_startConversationSafely','getReply','createPositionAt','addResourceToContext','mouseLeaveSuggestion','data','getChildren','_bodyCollection','14286kteqQl','setContextItemLoading','_getAIChatInteractionAPI','AITabs','ai-chat-source-resources-load-failed','setState','insertSuggestion','AI_CHAT_CONTEXT_FORM_DATA_SIZE_LIMITS_EXCEEDED','activateTab','isDocumentOperation','done','_updateReplyContent','includes','replyCreated','baseVersion','collaboration.channelId','ai-request-aborted','updateCapabilities','like','version','editing','createRange','ai.models','getRanges','ai-chat-context-file-too-large','_logError','stop','setModel','AI_CHAT_GENERIC_ERROR','_flushLastInteractionUI','isInContext','history','4359nRZFqC','uiId','model','interactionDestroyed','handleRemovedConversation','addFeedItemCustomElement','_aiChatBalloonShowDiff','removeContextItem','AIConnector','forEach','8tjrifW','isOfficialPlugin','destroy','chat','find','sendMessage','dislike','log','AI_CHAT_UNABLE_TO_LOAD_CONVERSATION','AI_CHAT_UNABLE_TO_START_CONVERSATION','ai-chat-missing-channel-id','partIndex','length','error','isCurrentDocumentInConversation','contextItemRemoved','DocumentCompare','viewRangeToDom','_integrateEditor','startAutoScroll','createConversation','unshift','showChangeInText','startsWith','getRoot','getSelectionText','modification','afterInit','pluginName','pending','anchorId','ai-chat-context-file-too-many-pages','createPositionFromPath','_stopLastInteraction','2060bkZZcL','getInteraction','Undo','resetConversationTitle','getChildAtOffset','getContentParts','isDisabled','addContextOptionsChanged','_toggleWebSearch','addUrlToContext','push','howMany','AIChatController','sourceResourcesLoaded','AI_CHAT_INVALID_REQUEST','init','query','lastCreated','undo','setSelectedModel','addOperation','node','20723020DNDqML','updateFeedItemAIReplyContent','disableControls','resetMessageInput','setLoadingMessage','document','ai-chat-conversation-not-found','ai.chat.initialConversation','getFirstRange','updateFeedItemAIReplySources','isPremiumPlugin','nextSibling','setIsMaximized','areActionsDisabled','loadSourceResources','updateContent','index','applySuggestion','redo','split','toViewRange','next','cloneNode','addFeedItemAIReply','setConversationTitle','AI_CHAT_CONTEXT_UNSUPPORTED_FILE_TYPE','_handleStartConversation','delete','updateFeedItemAIReplySuggestionContent','interactionCreated','Showing\x20conversation\x20history...','main','set','_aiChatBalloon','requires','ai-chat-file-upload-failed','new','_applySuggestion','updateFeedItemAIReplySuggestionPartState','getAll','5794670VJlMlc','outdated','callback','path','upsertAIChatRating','_aiConnector','createdAt','selectedModel','addSelectionToContext','parse','ai-chat-url-upload-failed','mouseOverSuggestion','current-document','contextSent','changes','isUploadInProgress','currentReply','prepareLoadingMessage','startInteraction','sessionId','selectModel','setConversationContext','_getUserPresentableContentPartDocumentRange','isStarted','AIChatUI','setFeedItemRenderingStrategy','AI_CHAT_CONTEXT_INVALID_DATA'];_0x3048=function(){return _0x2ebb8e;};return _0x3048();}import{ModelRange as _0x4e6981,_DetachOperation as _0x577bc1}from'ckeditor5/src/engine.js';import{findOne as _0x598a20,getAttribute as _0xc47dbe,serialize as _0x37aaa3,Document as _0x16ddd7,findByAttribute as _0x55da11}from'../aicore/utils/htmlparser.js';export class AIChatController extends _0x2d315c{[_0x2747dd(0x25e)];[_0x2747dd(0x241)];[_0x2747dd(0x310)];[_0x2747dd(0x2b2)];[_0x2747dd(0x235)];[_0x2747dd(0x2e5)]=new Map();[_0x2747dd(0x2f0)]=null;[_0x2747dd(0x33d)];static get[_0x2747dd(0x236)](){return[_0x4fc309,_0x159832];}static get[_0x2747dd(0x1f8)](){const _0xbc9cfc=_0x2747dd;return _0xbc9cfc(0x20a);}static get[_0x2747dd(0x369)](){return!0x0;}static get[_0x2747dd(0x21e)](){return!0x0;}[_0x2747dd(0x20d)](){const _0x448b52=_0x2747dd;this[_0x448b52(0x33d)]=new _0x11d605(this[_0x448b52(0x2fd)][_0x448b52(0x275)]),this[_0x448b52(0x33d)][_0x448b52(0x276)](),this[_0x448b52(0x241)]=this[_0x448b52(0x2fd)][_0x448b52(0x2e2)][_0x448b52(0x2be)](_0x448b52(0x366)),this[_0x448b52(0x310)]=this[_0x448b52(0x2fd)][_0x448b52(0x2e2)][_0x448b52(0x2be)](_0x448b52(0x254)),this[_0x448b52(0x25e)]=this[_0x448b52(0x2fd)][_0x448b52(0x2e2)][_0x448b52(0x2be)](_0x448b52(0x26e)),this[_0x448b52(0x2b2)]=new _0x2b8021({'connector':this[_0x448b52(0x241)],'config':this[_0x448b52(0x2fd)][_0x448b52(0x330)][_0x448b52(0x2be)](_0x448b52(0x354)),'locale':this[_0x448b52(0x2fd)][_0x448b52(0x275)]});const _0x2e9490=this[_0x448b52(0x2fd)][_0x448b52(0x2e2)][_0x448b52(0x2be)](_0x448b52(0x341));this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x2b8),()=>{const _0x2fd856=_0x448b52;this[_0x2fd856(0x336)]();}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x2b1),(_0x170991,_0x5e0174)=>{const _0xa0a49e=_0x448b52;this[_0xa0a49e(0x27f)]({'userMessage':_0x5e0174});}),this[_0x448b52(0x2e7)](_0x2e9490,_0x448b52(0x2ff),(_0x3c7cf0,_0x345325)=>{const _0x4b6a58=_0x448b52;this[_0x4b6a58(0x260)](_0x345325);}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x26c),()=>{const _0x2b3370=_0x448b52;_0x2e9490[_0x2b3370(0x317)]();}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x2d2),async()=>{const _0x2e1057=_0x448b52;await this[_0x2e1057(0x1fd)](),await this[_0x2e1057(0x35b)](),this[_0x2e1057(0x325)]();}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x2b5),()=>{const _0x4dc1ac=_0x448b52;this[_0x4dc1ac(0x272)]();}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x259),(_0x310bfd,_0x43ca36)=>{const _0x38e912=_0x448b52;this[_0x38e912(0x286)]?.[_0x38e912(0x329)](Array[_0x38e912(0x309)](_0x43ca36));}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x207),(_0x21a7be,_0x3dc9d4)=>{const _0xea74ac=_0x448b52;this[_0xea74ac(0x286)]?.[_0xea74ac(0x207)](_0x3dc9d4);}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x2a7),(_0x5919f8,_0x477922)=>{const _0x30ce77=_0x448b52;_0x477922[_0x30ce77(0x23e)](this[_0x30ce77(0x2fd)]);}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x339),(_0x11efcc,_0x672eb6)=>{const _0x3ed8a5=_0x448b52;this[_0x3ed8a5(0x286)]?.[_0x3ed8a5(0x339)](_0x672eb6[_0x3ed8a5(0x30f)],_0x672eb6[_0x3ed8a5(0x2bf)]);}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x365),(_0x40dfd6,_0x33aabd)=>{const _0x532816=_0x448b52;this[_0x532816(0x258)](_0x33aabd);}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x222),(_0x5c8595,_0x4f931a)=>{const _0x29d367=_0x448b52;this[_0x29d367(0x286)]?.[_0x29d367(0x222)](_0x4f931a[_0x29d367(0x271)],_0x4f931a[_0x29d367(0x20e)],_0x4f931a[_0x29d367(0x262)]);}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x25c),()=>{const _0xaae761=_0x448b52;this[_0xaae761(0x206)]();}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x31f),()=>{const _0x4a9b43=_0x448b52;this[_0x4a9b43(0x270)]();}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x250),(_0x521684,_0x496525)=>{const _0x588c4d=_0x448b52;this[_0x588c4d(0x286)]?.[_0x588c4d(0x359)](_0x496525);}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x350),(_0xbb1218,{replyId:_0x5dd1de})=>{const _0x1a25d8=_0x448b52;console[_0x1a25d8(0x36f)](_0x1a25d8(0x283),_0x5dd1de);}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x36e),(_0x11bf57,{replyId:_0x360312})=>{const _0x49ab26=_0x448b52;console[_0x49ab26(0x36f)](_0x49ab26(0x2af),_0x360312);}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x344),(_0x4e431c,_0x2f8659)=>{const _0x31cfcd=_0x448b52;this[_0x31cfcd(0x29c)](_0x2f8659);}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x1f2),(_0x35b1b4,{replyId:_0x20a20b,partIndex:_0x4c67e6})=>{const _0x41009a=_0x448b52;this[_0x41009a(0x364)]=this[_0x41009a(0x310)][_0x41009a(0x2f5)],this[_0x41009a(0x264)](_0x20a20b,_0x4c67e6);}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x247),(_0x51c732,{replyId:_0xa7a010,partIndex:_0x44d1e1})=>{const _0x3b23a6=_0x448b52,_0x29b8ba=this[_0x3b23a6(0x315)](_0xa7a010,_0x44d1e1);_0x29b8ba&&_0x3b23a6(0x300)!=_0x29b8ba[_0x3b23a6(0x27e)][_0x3b23a6(0x31b)][_0x3b23a6(0x328)]&&this[_0x3b23a6(0x25e)][_0x3b23a6(0x29e)]([_0x29b8ba[_0x3b23a6(0x27e)]],_0x3b23a6(0x30b));}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x33a),()=>{const _0x43dcd6=_0x448b52;this[_0x43dcd6(0x25e)][_0x43dcd6(0x2a6)](_0x43dcd6(0x30b));}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x225),(_0x2a98a7,_0x1b4436)=>{const _0x1aff2c=_0x448b52;this[_0x1aff2c(0x25e)][_0x1aff2c(0x2a6)](_0x1aff2c(0x30b)),this[_0x1aff2c(0x239)](_0x1b4436);}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x301),async(_0x38c532,{replyId:_0x150bb9,showDiff:_0xddce25})=>{const _0x22f826=_0x448b52,{reply:_0x56fec4}=this[_0x22f826(0x319)](_0x150bb9),_0x23972e=_0x56fec4[_0x22f826(0x203)]({'showDiff':_0xddce25});await this[_0x22f826(0x310)][_0x22f826(0x230)]({'id':_0x56fec4['id'],'parts':_0x23972e,'renderingStrategy':_0x22f826(0x2cc)});}),this[_0x448b52(0x2e7)](this[_0x448b52(0x310)],_0x448b52(0x2c5),(_0x3e29d4,{replyId:_0x97c0d,partIndex:_0x2e26f6})=>{const _0xb75fa2=_0x448b52;this[_0xb75fa2(0x285)]({'replyId':_0x97c0d,'partIndex':_0x2e26f6}),this[_0xb75fa2(0x25e)][_0xb75fa2(0x2a6)](_0xb75fa2(0x30b));}),this[_0x448b52(0x2fd)][_0x448b52(0x2e2)][_0x448b52(0x287)](_0x448b52(0x2de))&&(this[_0x448b52(0x235)]=this[_0x448b52(0x2fd)][_0x448b52(0x2e2)][_0x448b52(0x2be)](_0x448b52(0x2de)),this[_0x448b52(0x234)](_0x448b52(0x364),!0x1),this[_0x448b52(0x235)][_0x448b52(0x26d)](_0x448b52(0x2f5))['to'](this,_0x448b52(0x364)),this[_0x448b52(0x2e7)](this[_0x448b52(0x235)],_0x448b52(0x301),()=>{const _0x581f87=_0x448b52,{replyId:_0x34b7a6,partIndex:_0x4c08b8}=this[_0x581f87(0x2f0)];this[_0x581f87(0x364)]=!this[_0x581f87(0x364)];const {reply:_0x31098d}=this[_0x581f87(0x319)](_0x34b7a6),_0x34f953=_0x31098d[_0x581f87(0x203)]({'showDiff':this[_0x581f87(0x364)],'groupIndex':_0x4c08b8});this[_0x581f87(0x235)][_0x581f87(0x223)]({'part':_0x34f953[0x0],'renderingStrategy':_0x581f87(0x2cc),'keepErrors':!0x0});}),this[_0x448b52(0x2e7)](this[_0x448b52(0x235)],_0x448b52(0x225),()=>{const _0x21243=_0x448b52,{replyId:_0x2f54fe,partIndex:_0x2e30d1}=this[_0x21243(0x2f0)];this[_0x21243(0x239)]({'replyId':_0x2f54fe,'partIndex':_0x2e30d1}),this[_0x21243(0x235)][_0x21243(0x343)](_0x21243(0x2a5));}),this[_0x448b52(0x2e7)](this[_0x448b52(0x235)],_0x448b52(0x344),()=>{const _0x43c7cd=_0x448b52,{replyId:_0x49ebb6,partIndex:_0x4128ac}=this[_0x43c7cd(0x2f0)];this[_0x43c7cd(0x29c)]({'replyId':_0x49ebb6,'partIndex':_0x4128ac}),this[_0x43c7cd(0x235)][_0x43c7cd(0x343)](_0x43c7cd(0x2a5));}),this[_0x448b52(0x2e7)](this[_0x448b52(0x235)],_0x448b52(0x2c5),()=>{const _0x19fe49=_0x448b52,{replyId:_0x26cd04,partIndex:_0x56b6d2}=this[_0x19fe49(0x2f0)];this[_0x19fe49(0x285)]({'replyId':_0x26cd04,'partIndex':_0x56b6d2}),this[_0x19fe49(0x235)][_0x19fe49(0x343)](_0x19fe49(0x323));}),this[_0x448b52(0x2e7)](this[_0x448b52(0x235)],_0x448b52(0x2ad),()=>{const _0x10a422=_0x448b52,{replyId:_0x113490,partIndex:_0x72daeb}=this[_0x10a422(0x2f0)],_0x5d67ba=this[_0x10a422(0x307)](_0x113490,_0x72daeb,_0x10a422(0x229));null!==_0x5d67ba&&this[_0x10a422(0x264)](_0x113490,_0x5d67ba);}),this[_0x448b52(0x2e7)](this[_0x448b52(0x235)],_0x448b52(0x2df),()=>{const _0x101680=_0x448b52,{replyId:_0x5e569f,partIndex:_0x22152d}=this[_0x101680(0x2f0)],_0xf74d85=this[_0x101680(0x307)](_0x5e569f,_0x22152d,_0x101680(0x2ec));null!==_0xf74d85&&this[_0x101680(0x264)](_0x5e569f,_0xf74d85);}),this[_0x448b52(0x2e7)](this[_0x448b52(0x235)],_0x448b52(0x2c8),(_0x4c4748,{id:_0x2f5437})=>{const _0x4450a2=_0x448b52;if(_0x4450a2(0x333)!==_0x2f5437)return;const {replyId:_0x4798ff,partIndex:_0x3d43c5}=this[_0x4450a2(0x2f0)];this[_0x4450a2(0x2f0)]=null,this[_0x4450a2(0x310)][_0x4450a2(0x2ab)]({'id':_0x4798ff,'index':_0x3d43c5,'isActive':!0x1});}));}async[_0x2747dd(0x1f7)](){const _0x3a1bb6=_0x2747dd;this[_0x3a1bb6(0x2fd)]instanceof _0x2e07c5?this[_0x3a1bb6(0x1ee)](this[_0x3a1bb6(0x2fd)]):this[_0x3a1bb6(0x2e7)](this[_0x3a1bb6(0x2fd)][_0x3a1bb6(0x2da)],_0x3a1bb6(0x2c1),(_0x572fa2,_0x4a73a6)=>{const _0x17fd9a=_0x3a1bb6;_0x4a73a6['on'](_0x17fd9a(0x25f),()=>{const _0x51aa23=_0x17fd9a;this[_0x51aa23(0x1ee)](_0x4a73a6);});});const _0x21f259=this[_0x3a1bb6(0x2fd)][_0x3a1bb6(0x330)][_0x3a1bb6(0x2be)](_0x3a1bb6(0x21b));let _0x1b6fa6=_0x21f259;if(_0x3a1bb6(0x20f)!=_0x21f259||(_0x1b6fa6=await this[_0x3a1bb6(0x32a)](),_0x1b6fa6))return _0x3a1bb6(0x238)==_0x1b6fa6?this[_0x3a1bb6(0x336)]():this[_0x3a1bb6(0x268)](_0x1b6fa6);}async[_0x2747dd(0x36a)](){const _0x11e11b=_0x2747dd;return await this[_0x11e11b(0x1fd)](),this[_0x11e11b(0x33d)][_0x11e11b(0x334)](),super[_0x11e11b(0x36a)]();}[_0x2747dd(0x29c)](_0x4827ab){const _0x3783d3=_0x2747dd,_0x4e3305=_0x1edd1c(this[_0x3783d3(0x2fd)]);if(!_0x4e3305[_0x3783d3(0x2e2)][_0x3783d3(0x287)](_0x3783d3(0x305)))throw new _0x2f9ac0(_0x3783d3(0x27a),null);const _0x10562a=this[_0x3783d3(0x2fd)][_0x3783d3(0x2e2)][_0x3783d3(0x2be)](_0x3783d3(0x1ec)),{reply:_0x4ce2dc,interaction:_0x334803}=this[_0x3783d3(0x319)](_0x4827ab[_0x3783d3(0x2e4)]),_0x232e1c=this[_0x3783d3(0x315)](_0x4827ab[_0x3783d3(0x2e4)],_0x4827ab[_0x3783d3(0x1e7)]),_0x598eb8=void 0x0!==_0x4827ab[_0x3783d3(0x1e7)]?[_0x4ce2dc[_0x3783d3(0x2fe)][_0x4827ab[_0x3783d3(0x1e7)]]]:_0x4ce2dc[_0x3783d3(0x2fe)][_0x3783d3(0x261)](_0x16add2=>_0x3783d3(0x1f9)==_0x16add2[_0x3783d3(0x2b6)]),_0x34fe3c=_0x598eb8[_0x3783d3(0x2a2)](_0x1fe36e=>_0x4ce2dc[_0x3783d3(0x2fe)][_0x3783d3(0x32b)](_0x1fe36e));if(!_0x232e1c||_0x3783d3(0x300)==_0x232e1c[_0x3783d3(0x27e)][_0x3783d3(0x31b)][_0x3783d3(0x328)])return void _0x34fe3c[_0x3783d3(0x367)](_0x5a7866=>_0x4ce2dc[_0x3783d3(0x2d9)](_0x5a7866,_0x3783d3(0x23d)));_0x34fe3c[_0x3783d3(0x367)](_0x1f6c57=>_0x4ce2dc[_0x3783d3(0x2d9)](_0x1f6c57,_0x3783d3(0x2a5)));const _0x3dffd5=_0x357892({'editor':_0x4e3305,'reply':_0x4ce2dc,'interaction':_0x334803,'groups':_0x598eb8,'transform':!0x0,'documentCompare':_0x10562a,'documentCompareOptions':{'anchor':_0x3783d3(0x233),'markDeletions':!0x0}});let _0x3c132b;_0x232e1c&&this[_0x3783d3(0x298)](_0x232e1c[_0x3783d3(0x27e)]),_0x4e3305[_0x3783d3(0x360)][_0x3783d3(0x335)](_0x4c970c=>{const _0x43db88=_0x3783d3;_0x3c132b=_0x4c970c[_0x43db88(0x29f)],_0x4e3305[_0x43db88(0x2e2)][_0x43db88(0x2be)](_0x43db88(0x2e0))[_0x43db88(0x2c7)](_0x3dffd5),this[_0x43db88(0x25e)][_0x43db88(0x2a6)](_0x43db88(0x30b));}),this[_0x3783d3(0x2e5)][_0x3783d3(0x234)](_0x3c132b,{'interactionId':_0x334803['id'],'replyId':_0x4ce2dc['id'],'indexes':_0x34fe3c[_0x3783d3(0x281)]()}),this[_0x3783d3(0x284)](_0x4ce2dc);}[_0x2747dd(0x239)](_0x2d84ae){const _0x5d0cb5=_0x2747dd,_0x158730=_0x1edd1c(this[_0x5d0cb5(0x2fd)]),_0x291ce1=this[_0x5d0cb5(0x2fd)][_0x5d0cb5(0x2e2)][_0x5d0cb5(0x2be)](_0x159832),{reply:_0x504571,interaction:_0x3e3dd8}=this[_0x5d0cb5(0x319)](_0x2d84ae[_0x5d0cb5(0x2e4)]),_0x8cce37=this[_0x5d0cb5(0x315)](_0x2d84ae[_0x5d0cb5(0x2e4)],_0x2d84ae[_0x5d0cb5(0x1e7)]),_0x3cf27e=void 0x0!==_0x2d84ae[_0x5d0cb5(0x1e7)]?[_0x504571[_0x5d0cb5(0x2fe)][_0x2d84ae[_0x5d0cb5(0x1e7)]]]:_0x504571[_0x5d0cb5(0x2fe)][_0x5d0cb5(0x261)](_0x17e38a=>_0x5d0cb5(0x1f9)==_0x17e38a[_0x5d0cb5(0x2b6)]),_0x84f373=_0x3cf27e[_0x5d0cb5(0x2a2)](_0x43c47d=>_0x504571[_0x5d0cb5(0x2fe)][_0x5d0cb5(0x32b)](_0x43c47d));if(!_0x8cce37||_0x5d0cb5(0x300)==_0x8cce37[_0x5d0cb5(0x27e)][_0x5d0cb5(0x31b)][_0x5d0cb5(0x328)])return void _0x84f373[_0x5d0cb5(0x367)](_0x329f9e=>_0x504571[_0x5d0cb5(0x2d9)](_0x329f9e,_0x5d0cb5(0x23d)));_0x84f373[_0x5d0cb5(0x367)](_0x3cde84=>_0x504571[_0x5d0cb5(0x2d9)](_0x3cde84,_0x5d0cb5(0x2a5)));const _0x30f8c0=_0x357892({'editor':_0x158730,'reply':_0x504571,'interaction':_0x3e3dd8,'groups':_0x3cf27e,'transform':!0x0,'documentCompare':_0x291ce1,'documentCompareOptions':{'anchor':_0x5d0cb5(0x233),'markDeletions':!0x1}});let _0x124a24;_0x8cce37&&this[_0x5d0cb5(0x298)](_0x8cce37[_0x5d0cb5(0x27e)]),_0x158730[_0x5d0cb5(0x360)][_0x5d0cb5(0x335)](_0x55ca25=>{const _0x4d9610=_0x5d0cb5;_0x124a24=_0x55ca25[_0x4d9610(0x29f)];for(const _0x48de86 of _0x30f8c0)_0x48de86[_0x4d9610(0x34c)]=_0x158730[_0x4d9610(0x360)][_0x4d9610(0x219)][_0x4d9610(0x351)],_0x424953(_0x158730,_0x48de86),_0x55ca25[_0x4d9610(0x29f)][_0x4d9610(0x212)](_0x48de86),_0x158730[_0x4d9610(0x360)][_0x4d9610(0x2fb)](_0x48de86);}),this[_0x5d0cb5(0x2e5)][_0x5d0cb5(0x234)](_0x124a24,{'interactionId':_0x3e3dd8['id'],'replyId':_0x504571['id'],'indexes':_0x84f373[_0x5d0cb5(0x281)]()}),this[_0x5d0cb5(0x284)](_0x504571);}[_0x2747dd(0x285)](_0xc69623){const _0x1e6294=_0x2747dd,{reply:_0x1b8a71}=this[_0x1e6294(0x319)](_0xc69623[_0x1e6294(0x2e4)]);_0x1b8a71[_0x1e6294(0x2d9)](_0xc69623[_0x1e6294(0x1e7)],_0x1e6294(0x323));}[_0x2747dd(0x264)](_0x2a9d1f,_0x20ca88){const _0x59ee8f=_0x2747dd;if(!this[_0x59ee8f(0x235)])return;const {reply:_0x208adf}=this[_0x59ee8f(0x319)](_0x2a9d1f),_0x11d56a=_0x208adf[_0x59ee8f(0x203)]({'showDiff':this[_0x59ee8f(0x364)]});let _0x3127ed,_0x374e8b;if(void 0x0!==_0x20ca88?(_0x374e8b=_0x11d56a[_0x59ee8f(0x36c)](_0x1128b3=>_0x1128b3[_0x59ee8f(0x224)]==_0x20ca88),_0x3127ed=_0x374e8b?.[_0x59ee8f(0x224)]):(_0x374e8b=_0x11d56a[0x0],_0x3127ed=_0x374e8b[_0x59ee8f(0x224)]),this[_0x59ee8f(0x2f0)]?.[_0x59ee8f(0x2e4)]==_0x2a9d1f&&this[_0x59ee8f(0x2f0)]?.[_0x59ee8f(0x1e7)]==_0x3127ed)return;const _0x2ad523=this[_0x59ee8f(0x252)](_0x2a9d1f,_0x208adf,_0x374e8b);if(!_0x2ad523)return void this[_0x59ee8f(0x235)][_0x59ee8f(0x303)]();this[_0x59ee8f(0x2f0)]={'replyId':_0x2a9d1f,'partIndex':_0x3127ed},this[_0x59ee8f(0x298)](_0x2ad523,!0x0);const _0x1c6a6e=this[_0x59ee8f(0x307)](_0x2a9d1f,_0x3127ed,_0x59ee8f(0x229));this[_0x59ee8f(0x235)][_0x59ee8f(0x223)]({'part':_0x374e8b,'renderingStrategy':_0x59ee8f(0x2cc)}),this[_0x59ee8f(0x235)][_0x59ee8f(0x28d)]({'index':_0x3127ed,'title':_0x3bbccd(this[_0x59ee8f(0x2fd)][_0x59ee8f(0x275)],_0x59ee8f(0x326),(_0x3127ed+0x1)[_0x59ee8f(0x27b)]()),'showRotator':null!==_0x1c6a6e,'ranges':[_0x2ad523],'areActionsDisabled':_0x208adf[_0x59ee8f(0x221)]}),this[_0x59ee8f(0x235)][_0x59ee8f(0x343)](_0x59ee8f(0x1f9)),this[_0x59ee8f(0x310)][_0x59ee8f(0x2c2)](_0x2a9d1f,_0x3127ed),this[_0x59ee8f(0x310)][_0x59ee8f(0x2ab)]({'id':_0x2a9d1f,'index':_0x3127ed,'isActive':!0x0});}[_0x2747dd(0x307)](_0x470425,_0x208b1c,_0x203113){const _0x32029c=_0x2747dd,{reply:_0x2e0206}=this[_0x32029c(0x319)](_0x470425),_0x29c586=_0x2e0206[_0x32029c(0x203)]({'showDiff':this[_0x32029c(0x364)]});if(0x1==_0x29c586[_0x32029c(0x1e8)])return null;const _0x25d8d0=_0x29c586[_0x32029c(0x288)](_0x42090f=>_0x42090f[_0x32029c(0x224)]==_0x208b1c),_0x4ede93=_0x32029c(0x229)==_0x203113?0x1:-0x1;let _0x318d13=_0x29c586['at']((_0x25d8d0+_0x4ede93)%_0x29c586[_0x32029c(0x1e8)])[_0x32029c(0x224)],_0x378bad=_0x29c586[_0x318d13];for(;!this[_0x32029c(0x252)](_0x470425,_0x2e0206,_0x378bad);){if(_0x318d13=_0x29c586['at']((_0x318d13+_0x4ede93)%_0x29c586[_0x32029c(0x1e8)])[_0x32029c(0x224)],_0x318d13===_0x25d8d0)return null;_0x378bad=_0x29c586[_0x318d13];}return _0x318d13;}[_0x2747dd(0x252)](_0x34b65e,_0x2d92b6,_0x82c0ed){const _0x5aea6c=_0x2747dd,_0x18270f=_0x2d92b6[_0x5aea6c(0x2fe)];if(!_0x82c0ed[_0x5aea6c(0x2f4)])return null;const _0x3a791a=_0x18270f[_0x5aea6c(0x36c)](_0x508d9a=>_0x508d9a[_0x5aea6c(0x224)]==_0x82c0ed[_0x5aea6c(0x224)]);if(_0x5aea6c(0x1f9)!==_0x3a791a?.[_0x5aea6c(0x2b6)])return null;const _0x2e90c5=this[_0x5aea6c(0x315)](_0x34b65e,_0x82c0ed[_0x5aea6c(0x224)]);if(!_0x2e90c5)return null;const {range:_0x17497a,currentIndex:_0x1e7324}=_0x2e90c5;return _0x5aea6c(0x300)==_0x17497a[_0x5aea6c(0x31b)][_0x5aea6c(0x328)]?(_0x2d92b6[_0x5aea6c(0x2d9)](_0x1e7324,_0x5aea6c(0x23d)),null):_0x2e90c5[_0x5aea6c(0x27e)];}[_0x2747dd(0x315)](_0x364e9f,_0x531c54){const _0xde3e2b=_0x2747dd,_0x35cd4a=_0x1edd1c(this[_0xde3e2b(0x2fd)]),{reply:_0x1cdf07,interaction:_0x92c078}=this[_0xde3e2b(0x319)](_0x364e9f),_0x2ba0ac=_0x1cdf07[_0xde3e2b(0x2fe)][_0xde3e2b(0x261)](_0x5cc6ed=>_0xde3e2b(0x1f9)==_0x5cc6ed[_0xde3e2b(0x2b6)]),_0x4f44a2=_0x2ba0ac[_0xde3e2b(0x2a2)](_0x74941d=>_0x1cdf07[_0xde3e2b(0x2fe)][_0xde3e2b(0x32b)](_0x74941d));void 0x0===_0x531c54&&(_0x531c54=_0x4f44a2[0x0]);const _0xa234f3=_0x4f44a2[_0xde3e2b(0x32b)](_0x531c54);if(-0x1==_0xa234f3)return null;const _0x5c3104=_0x2ba0ac[_0xa234f3],_0x32fd5c=new _0x16ddd7([]),_0x24576d=new _0x16ddd7([]);for(const _0x4685e1 of _0x5c3104[_0xde3e2b(0x24a)])if(_0xde3e2b(0x2c9)!=_0x4685e1[_0xde3e2b(0x28b)]&&_0x24576d[_0xde3e2b(0x292)][_0xde3e2b(0x208)](_0x4685e1[_0xde3e2b(0x213)][_0xde3e2b(0x22a)](!0x0)),_0xde3e2b(0x238)!=_0x4685e1[_0xde3e2b(0x28b)]){const _0x1448ee=_0x598a20(_0x4c36fd=>_0xc47dbe(_0x4c36fd,_0xde3e2b(0x28c))==_0x4685e1['id'],_0x1cdf07[_0xde3e2b(0x28f)],!0x0);_0x32fd5c[_0xde3e2b(0x292)][_0xde3e2b(0x208)](_0x1448ee[_0xde3e2b(0x22a)](!0x0));}if(0x0==_0x32fd5c[_0xde3e2b(0x292)][_0xde3e2b(0x1e8)]){if(_0x5c3104[_0xde3e2b(0x24a)][0x0][_0xde3e2b(0x1fa)]){const _0x13f031=_0x55da11(_0xde3e2b(0x28c),_0x5c3104[_0xde3e2b(0x24a)][0x0][_0xde3e2b(0x1fa)],_0x1cdf07[_0xde3e2b(0x28f)]);_0x32fd5c[_0xde3e2b(0x292)][_0xde3e2b(0x1f1)](_0x13f031[_0xde3e2b(0x22a)](!0x0)),_0x24576d[_0xde3e2b(0x292)][_0xde3e2b(0x1f1)](_0x13f031[_0xde3e2b(0x22a)](!0x0)),_0x13f031[_0xde3e2b(0x21f)]&&(_0x32fd5c[_0xde3e2b(0x292)][_0xde3e2b(0x208)](_0x13f031[_0xde3e2b(0x21f)][_0xde3e2b(0x22a)](!0x0)),_0x24576d[_0xde3e2b(0x292)][_0xde3e2b(0x208)](_0x13f031[_0xde3e2b(0x21f)][_0xde3e2b(0x22a)](!0x0)));}else{const _0x2a9f00=_0x1cdf07[_0xde3e2b(0x28f)][_0xde3e2b(0x292)][0x0];if(!_0x2a9f00)return null;_0x32fd5c[_0xde3e2b(0x292)][_0xde3e2b(0x208)](_0x2a9f00[_0xde3e2b(0x22a)](!0x0)),_0x24576d[_0xde3e2b(0x292)][_0xde3e2b(0x208)](_0x2a9f00[_0xde3e2b(0x22a)](!0x0));}}const _0x311d0c=_0x92c078[_0xde3e2b(0x266)](),_0x484838=_0x35cd4a[_0xde3e2b(0x33b)][_0xde3e2b(0x245)](_0x311d0c[_0xde3e2b(0x299)]),_0x29f9ed=_0x37aaa3(_0x32fd5c),_0x14cf04=_0x35cd4a[_0xde3e2b(0x33b)][_0xde3e2b(0x245)](_0x29f9ed),_0x155a6e=_0x35cd4a[_0xde3e2b(0x33b)][_0xde3e2b(0x245)](_0x29f9ed),_0x302a3=_0x35cd4a[_0xde3e2b(0x360)][_0xde3e2b(0x338)](_0x14cf04,0x0),_0xa90a88=_0x37aaa3(_0x24576d),_0x35cced={'anchor':_0x302a3,'markDeletions':!0x1},_0x2b65eb=_0x35cd4a[_0xde3e2b(0x2e2)][_0xde3e2b(0x2be)](_0x159832)[_0xde3e2b(0x2f9)](_0x29f9ed,_0xa90a88,_0x35cced)[_0xde3e2b(0x28a)]();if(!_0x2b65eb[_0xde3e2b(0x1e8)])return null;_0x35cd4a[_0xde3e2b(0x360)][_0xde3e2b(0x335)](_0x54a3d7=>{const _0x416688=_0xde3e2b;for(const _0x26656c of _0x2b65eb)if(_0x416688(0x327)==_0x26656c[_0x416688(0x28b)]){const _0x4a4e19=_0x26656c[_0x416688(0x2e8)],_0x58684a=_0x26656c[_0x416688(0x209)],_0xfe6e0d=new _0x577bc1(_0x4a4e19,_0x58684a);_0x54a3d7[_0x416688(0x29f)][_0x416688(0x212)](_0xfe6e0d),_0x35cd4a[_0x416688(0x360)][_0x416688(0x2fb)](_0xfe6e0d);}else _0x416688(0x324)!==_0x26656c[_0x416688(0x28b)]&&(_0x26656c[_0x416688(0x34c)]=null,_0x26656c[_0x416688(0x347)]=!0x1,_0x54a3d7[_0x416688(0x29f)][_0x416688(0x212)](_0x26656c),_0x35cd4a[_0x416688(0x360)][_0x416688(0x2fb)](_0x26656c));});const _0x2db9da=_0x41899c(_0x35cd4a,_0x2b65eb,_0x14cf04);_0x25c4d2(_0x35cd4a[_0xde3e2b(0x360)],_0x2db9da);const _0x1e208d=_0x2db9da[_0xde3e2b(0x21c)]()[_0xde3e2b(0x2ae)][_0xde3e2b(0x23f)][_0xde3e2b(0x281)](),_0x59e730=_0x2db9da[_0xde3e2b(0x21c)]()[_0xde3e2b(0x28e)][_0xde3e2b(0x23f)][_0xde3e2b(0x281)](),_0x221638=[];let _0x3c3b3f=_0x14cf04,_0x28c699=_0x155a6e;for(let _0x589d41=0x0;_0x589d41<_0x59e730[_0xde3e2b(0x1e8)];_0x589d41++){const _0x347812=_0x3c3b3f[_0xde3e2b(0x2a8)]-_0x59e730[_0x589d41];_0x221638[_0x589d41]=_0x28c699[_0xde3e2b(0x2a8)]-_0x347812,_0x3c3b3f=_0x3c3b3f[_0xde3e2b(0x202)](_0x59e730[_0x589d41]),_0x28c699=_0x28c699[_0xde3e2b(0x202)](_0x221638[_0x589d41]);}const _0x3bc5f3=_0x35cd4a[_0xde3e2b(0x360)][_0xde3e2b(0x353)](_0x35cd4a[_0xde3e2b(0x360)][_0xde3e2b(0x1fc)](_0x155a6e,_0x1e208d),_0x35cd4a[_0xde3e2b(0x360)][_0xde3e2b(0x1fc)](_0x155a6e,_0x221638)),_0xd9d99e=_0x155a6e[_0xde3e2b(0x277)](0x0)[_0xde3e2b(0x31e)](_0x192377),_0x446010=Array[_0xde3e2b(0x309)](_0x484838[_0xde3e2b(0x33c)]())[_0xde3e2b(0x36c)](_0x44d33e=>_0x44d33e[_0xde3e2b(0x31e)](_0x192377)==_0xd9d99e)[_0xde3e2b(0x2e1)](),_0x33a86e=_0x3bc5f3[_0xde3e2b(0x2ae)][_0xde3e2b(0x23f)][_0xde3e2b(0x281)](),_0x59e9ed=_0x3bc5f3[_0xde3e2b(0x28e)][_0xde3e2b(0x23f)][_0xde3e2b(0x281)]();_0x33a86e[0x0]=_0x446010[0x0]+_0x33a86e[0x0],_0x59e9ed[0x0]=_0x446010[0x0]+_0x59e9ed[0x0];let _0x3b9f57=_0x35cd4a[_0xde3e2b(0x360)][_0xde3e2b(0x353)](_0x35cd4a[_0xde3e2b(0x360)][_0xde3e2b(0x1fc)](_0x35cd4a[_0xde3e2b(0x360)][_0xde3e2b(0x219)][_0xde3e2b(0x1f4)](),_0x33a86e),_0x35cd4a[_0xde3e2b(0x360)][_0xde3e2b(0x1fc)](_0x35cd4a[_0xde3e2b(0x360)][_0xde3e2b(0x219)][_0xde3e2b(0x1f4)](),_0x59e9ed));const _0x216bed=_0x35cd4a[_0xde3e2b(0x360)][_0xde3e2b(0x219)][_0xde3e2b(0x35d)][_0xde3e2b(0x28a)](_0x311d0c[_0xde3e2b(0x351)]);for(const _0x4af460 of _0x216bed)_0x3b9f57=_0x4e6981[_0xde3e2b(0x321)](_0x3b9f57[_0xde3e2b(0x2a4)](_0x4af460));return{'range':_0x3b9f57,'currentIndex':_0x531c54};}[_0x2747dd(0x1ee)](_0x4370e1){const _0x29f134=_0x2747dd;if(!_0x4370e1[_0x29f134(0x2e2)][_0x29f134(0x287)](_0x29f134(0x200)))return;const _0x4bd8ec=_0x4370e1[_0x29f134(0x289)][_0x29f134(0x2be)](_0x29f134(0x210)),_0x261273=_0x4370e1[_0x29f134(0x289)][_0x29f134(0x2be)](_0x29f134(0x226));this[_0x29f134(0x2e7)](_0x4bd8ec,_0x29f134(0x2d4),(_0x41af21,_0x58a66e,_0x59a148)=>{const _0x2f31c9=_0x29f134,_0x28f69d=this[_0x2f31c9(0x2e5)][_0x2f31c9(0x2be)](_0x58a66e);if(!_0x28f69d)return;const _0x1feb4c=this[_0x2f31c9(0x286)][_0x2f31c9(0x1ff)](_0x28f69d[_0x2f31c9(0x296)])[_0x2f31c9(0x337)](_0x28f69d[_0x2f31c9(0x2e4)]);_0x28f69d[_0x2f31c9(0x2a1)][_0x2f31c9(0x367)](_0x491f22=>_0x1feb4c[_0x2f31c9(0x2d9)](_0x491f22,_0x2f31c9(0x1f9))),this[_0x2f31c9(0x2e5)][_0x2f31c9(0x22f)](_0x58a66e),this[_0x2f31c9(0x2e5)][_0x2f31c9(0x234)](_0x59a148,_0x28f69d);}),this[_0x29f134(0x2e7)](_0x261273,_0x29f134(0x2d4),(_0x1b80ea,_0x292d4b,_0x26a048)=>{const _0x26210b=_0x29f134,_0x22ab53=this[_0x26210b(0x2e5)][_0x26210b(0x2be)](_0x292d4b);if(!_0x22ab53)return;const _0xe1c766=this[_0x26210b(0x286)][_0x26210b(0x1ff)](_0x22ab53[_0x26210b(0x296)])[_0x26210b(0x337)](_0x22ab53[_0x26210b(0x2e4)]);_0x22ab53[_0x26210b(0x2a1)][_0x26210b(0x367)](_0x402ae1=>_0xe1c766[_0x26210b(0x2d9)](_0x402ae1,_0x26210b(0x2a5))),this[_0x26210b(0x2e5)][_0x26210b(0x22f)](_0x292d4b),this[_0x26210b(0x2e5)][_0x26210b(0x234)](_0x26a048,_0x22ab53);});}async[_0x2747dd(0x268)](_0xf22291){const _0x48748c=_0x2747dd;this[_0x48748c(0x2fd)][_0x48748c(0x2e2)][_0x48748c(0x287)](_0x48748c(0x2de))&&this[_0x48748c(0x2fd)][_0x48748c(0x2e2)][_0x48748c(0x2be)](_0x48748c(0x2de))[_0x48748c(0x303)](),(this[_0x48748c(0x2fd)][_0x48748c(0x2e2)][_0x48748c(0x2be)](_0x2e48c5)[_0x48748c(0x2ea)][_0x48748c(0x346)](_0x48748c(0x36b)),this[_0x48748c(0x310)][_0x48748c(0x255)](_0x48748c(0x2cc)),this[_0x48748c(0x310)][_0x48748c(0x279)](!0x0),await this[_0x48748c(0x1fd)]());try{await this[_0x48748c(0x241)][_0x48748c(0x2fc)](_0xf22291)[_0x48748c(0x2d5)](),await this[_0x48748c(0x336)](_0xf22291),this[_0x48748c(0x27c)]('\x20'),await this[_0x48748c(0x286)][_0x48748c(0x29d)](_0xf22291,this[_0x48748c(0x25e)][_0x48748c(0x24f)]),this[_0x48748c(0x286)][_0x48748c(0x1ea)]()&&this[_0x48748c(0x272)]();}catch(_0x3d59e0){this[_0x48748c(0x310)][_0x48748c(0x30e)]({'errorMessage':_0x3bbccd(this[_0x48748c(0x2fd)][_0x48748c(0x275)],_0x48748c(0x1e4)),'id':_0xf22291}),this[_0x48748c(0x357)](new _0x2f9ac0(_0x48748c(0x21a),this,{'error':_0x3d59e0}));}finally{this[_0x48748c(0x310)][_0x48748c(0x1ef)](),this[_0x48748c(0x310)][_0x48748c(0x255)](_0x48748c(0x32d)),this[_0x48748c(0x310)][_0x48748c(0x279)](!0x1);}}async[_0x2747dd(0x32a)](){const _0x2ca8b1=_0x2747dd,_0x4b28f8=this[_0x2ca8b1(0x241)][_0x2ca8b1(0x297)](this[_0x2ca8b1(0x2dd)](),{'limit':0x1,'sortBy':_0x2ca8b1(0x242)});try{const _0x5ce96c=await _0x4b28f8[_0x2ca8b1(0x2bc)]();return _0x5ce96c[_0x2ca8b1(0x1e8)]?_0x5ce96c[0x0]['id']:_0x2ca8b1(0x238);}catch(_0x966bce){return this[_0x2ca8b1(0x310)][_0x2ca8b1(0x30e)]({'errorMessage':_0x3bbccd(this[_0x2ca8b1(0x2fd)][_0x2ca8b1(0x275)],_0x2ca8b1(0x1e4)),'id':_0x441c86()}),this[_0x2ca8b1(0x357)](new _0x2f9ac0(_0x2ca8b1(0x2c6),this,{'error':_0x966bce})),this[_0x2ca8b1(0x310)][_0x2ca8b1(0x279)](!0x1),this[_0x2ca8b1(0x310)][_0x2ca8b1(0x216)](),null;}}[_0x2747dd(0x362)](_0x4be48b){const _0x1ba129=_0x2747dd;this[_0x1ba129(0x286)]['id']===_0x4be48b&&this[_0x1ba129(0x336)]();}[_0x2747dd(0x272)](){const _0x56bfe7=_0x2747dd;this[_0x56bfe7(0x286)]?.[_0x56bfe7(0x294)](_0x3bbccd(this[_0x56bfe7(0x2fd)][_0x56bfe7(0x275)],_0x56bfe7(0x2f8)));}async[_0x2747dd(0x26f)](){const _0x559ecc=_0x2747dd,_0x1b4841=this[_0x559ecc(0x25e)][_0x559ecc(0x1f5)]();this[_0x559ecc(0x286)]?.[_0x559ecc(0x244)](_0x1b4841),this[_0x559ecc(0x272)]();}[_0x2747dd(0x325)](){const _0x2a6cae=_0x2747dd;this[_0x2a6cae(0x286)]?.[_0x2a6cae(0x2ac)]();}[_0x2747dd(0x2c4)](){const _0x28bd9f=_0x2747dd;this[_0x28bd9f(0x310)][_0x28bd9f(0x2c4)]();}async[_0x2747dd(0x2b8)](){const _0x134892=_0x2747dd;await this[_0x134892(0x336)]();}async[_0x2747dd(0x36d)]({message:_0x55f310,attributes:_0x31f248}){const _0xe6b8ec=_0x2747dd;await this[_0xe6b8ec(0x27f)]({'userMessage':_0x55f310,'attributes':_0x31f248});}[_0x2747dd(0x2dd)](){const _0x2b2854=_0x2747dd,_0x381388=this[_0x2b2854(0x2fd)][_0x2b2854(0x330)][_0x2b2854(0x2be)](_0x2b2854(0x34d));if(!_0x381388)throw new _0x2f9ac0(_0x2b2854(0x1e6),this);return _0x381388;}async[_0x2747dd(0x336)](_0xd25225){const _0x3c90b9=_0x2747dd;try{this[_0x3c90b9(0x310)][_0x3c90b9(0x31d)](),await this[_0x3c90b9(0x22e)](_0xd25225);}catch(_0xa8bc9f){this[_0x3c90b9(0x310)][_0x3c90b9(0x30e)]({'errorMessage':_0x3bbccd(this[_0x3c90b9(0x2fd)][_0x3c90b9(0x275)],_0x3c90b9(0x1e5)),'id':_0xd25225||_0x441c86()}),console[_0x3c90b9(0x1e9)](_0xa8bc9f),this[_0x3c90b9(0x286)]=void 0x0,this[_0x3c90b9(0x310)][_0x3c90b9(0x216)]();}}async[_0x2747dd(0x22e)](_0x51d76d){const _0x14054f=_0x2747dd;let _0x298bc0;this[_0x14054f(0x2fd)][_0x14054f(0x2e2)][_0x14054f(0x287)](_0x14054f(0x2de))&&this[_0x14054f(0x2fd)][_0x14054f(0x2e2)][_0x14054f(0x2be)](_0x14054f(0x2de))[_0x14054f(0x303)](),_0x51d76d||!this[_0x14054f(0x286)]?_0x298bc0=this[_0x14054f(0x2fd)][_0x14054f(0x330)][_0x14054f(0x2be)](_0x14054f(0x316)):this[_0x14054f(0x310)][_0x14054f(0x2bb)]&&(_0x298bc0=this[_0x14054f(0x286)][_0x14054f(0x243)]['id']),await this[_0x14054f(0x1fd)]();const _0x3dbb86=this[_0x14054f(0x2dd)](),_0x37ec35=_0x51d76d||_0x441c86();this[_0x14054f(0x286)]=new _0x13f3a3({'connector':this[_0x14054f(0x241)],'chatModels':this[_0x14054f(0x2b2)],'selectedModelId':_0x298bc0,'conversationId':_0x37ec35,'group':_0x3dbb86,'getEditor':()=>_0x1edd1c(this[_0x14054f(0x2fd)]),'isFromHistory':!!_0x51d76d}),this[_0x14054f(0x286)][_0x14054f(0x2b9)](_0x14054f(0x314),_0x14054f(0x267))['to'](this),this[_0x14054f(0x286)]['on'](_0x14054f(0x295),(_0x4666f8,_0x1b7f58)=>{const _0x534093=_0x14054f;this[_0x534093(0x310)][_0x534093(0x1f0)](_0x1b7f58),this[_0x534093(0x310)][_0x534093(0x217)](),this[_0x534093(0x310)][_0x534093(0x2f1)](),this[_0x534093(0x310)][_0x534093(0x26a)](),_0x51d76d||(this[_0x534093(0x310)][_0x534093(0x201)](),this[_0x534093(0x272)]());}),this[_0x14054f(0x286)]['on'](_0x14054f(0x2c0),(_0x5ae2be,_0x5a0b49)=>{const _0x271ccb=_0x14054f;this[_0x271ccb(0x310)][_0x271ccb(0x306)](_0x5a0b49[_0x271ccb(0x24b)]);}),this[_0x14054f(0x286)]['on'](_0x14054f(0x231),(_0x74c564,_0x387826)=>{const _0x18fb8b=_0x14054f;this[_0x18fb8b(0x310)][_0x18fb8b(0x2dc)](_0x387826);}),this[_0x14054f(0x286)]['on'](_0x14054f(0x308),()=>{const _0x308562=_0x14054f,_0x2d46ba=this[_0x308562(0x310)][_0x308562(0x24d)]({'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});this[_0x308562(0x310)][_0x308562(0x218)](_0x2d46ba);}),this[_0x14054f(0x286)]['on'](_0x14054f(0x27d),()=>{const _0x531e55=_0x14054f,_0x22ba2e=this[_0x531e55(0x310)][_0x531e55(0x24d)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});this[_0x531e55(0x310)][_0x531e55(0x218)](_0x22ba2e);}),this[_0x14054f(0x286)]['on'](_0x14054f(0x273),(_0x36d802,_0x45f917)=>{const _0x48214f=_0x14054f;this[_0x48214f(0x310)][_0x48214f(0x2cd)](_0x45f917,{'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x14054f(0x286)]['on'](_0x14054f(0x2ca),(_0x37b5d7,_0x38c3d6)=>{const _0x17807e=_0x14054f;this[_0x17807e(0x310)][_0x17807e(0x2cd)](_0x38c3d6,{'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x14054f(0x286)]['on'](_0x14054f(0x267),()=>{const _0x2a3633=_0x14054f;this[_0x2a3633(0x310)][_0x2a3633(0x24e)]();}),this[_0x14054f(0x286)]['on'](_0x14054f(0x2a3),async()=>{const _0x3a1264=_0x14054f;await this[_0x3a1264(0x310)][_0x3a1264(0x313)]();}),this[_0x14054f(0x286)]['on'](_0x14054f(0x361),(_0x5a3fc2,_0x9e5520)=>{const _0x431469=_0x14054f;this[_0x431469(0x310)][_0x431469(0x25a)](_0x9e5520['id']);}),this[_0x14054f(0x286)]['on'](_0x14054f(0x22c),(_0x2544ce,_0x3dda49,_0x344113)=>{const _0x4d4e15=_0x14054f;this[_0x4d4e15(0x27c)](_0x3dda49,_0x344113);}),this[_0x14054f(0x286)]['on'](_0x14054f(0x34b),(_0x33db73,_0x4051a8)=>{const _0x3e0237=_0x14054f;_0x3e0237(0x2b0)===_0x4051a8[_0x3e0237(0x28b)]?this[_0x3e0237(0x310)][_0x3e0237(0x22b)](_0x4051a8):this[_0x3e0237(0x310)][_0x3e0237(0x312)](_0x4051a8);}),this[_0x14054f(0x286)]['on'](_0x14054f(0x2cf),async(_0x46d308,_0x57729e)=>{const _0x32e6bb=_0x14054f;await this[_0x32e6bb(0x349)]({'reply':_0x57729e});}),this[_0x14054f(0x286)]['on'](_0x14054f(0x2e6),(_0x2def7b,{reply:_0x1c657f,index:_0xb14275,state:_0x26ff40})=>{const _0x2df477=_0x14054f;this[_0x2df477(0x310)][_0x2df477(0x23a)]({'id':_0x1c657f['id'],'index':_0xb14275,'state':_0x26ff40}),this[_0x2df477(0x2f0)]?.[_0x2df477(0x2e4)][_0x2df477(0x34a)](_0x1c657f['id'])&&this[_0x2df477(0x2f0)]?.[_0x2df477(0x1e7)]==_0xb14275&&this[_0x2df477(0x235)]?.[_0x2df477(0x343)](_0x26ff40);}),this[_0x14054f(0x286)]['on'](_0x14054f(0x2b7),(_0x55e935,_0x6bde9)=>{const _0x475051=_0x14054f;if(this[_0x475051(0x310)][_0x475051(0x2ee)](_0x6bde9[_0x475051(0x30a)],_0x6bde9[_0x475051(0x2f6)]),_0x475051(0x290)===_0x6bde9[_0x475051(0x30a)][_0x475051(0x28b)]){const _0x46d164=[..._0x1edd1c(this[_0x475051(0x2fd)])[_0x475051(0x360)][_0x475051(0x219)][_0x475051(0x290)][_0x475051(0x355)]()];this[_0x475051(0x25e)][_0x475051(0x29e)](_0x46d164,_0x475051(0x2d3)+this[_0x475051(0x286)]?.['id']);}}),this[_0x14054f(0x286)]['on'](_0x14054f(0x1eb),(_0x31e7cb,_0x52a9eb)=>{const _0x11c01=_0x14054f;this[_0x11c01(0x310)][_0x11c01(0x365)](_0x52a9eb[_0x11c01(0x35f)]),_0x11c01(0x248)==_0x52a9eb[_0x11c01(0x35f)]&&this[_0x11c01(0x325)](),_0x11c01(0x290)===_0x52a9eb[_0x11c01(0x28b)]&&this[_0x11c01(0x25e)][_0x11c01(0x2a6)](_0x11c01(0x2d3)+this[_0x11c01(0x286)]?.['id']);}),this[_0x14054f(0x286)]['on'](_0x14054f(0x2d8),(_0x516da2,_0x27ca92)=>{const _0x67da16=_0x14054f;this[_0x67da16(0x310)][_0x67da16(0x33f)](_0x27ca92[_0x67da16(0x30a)][_0x67da16(0x35f)],_0x27ca92[_0x67da16(0x2f6)]);}),this[_0x14054f(0x286)]['on'](_0x14054f(0x249),(_0x3dacd9,_0x2dea76)=>{const _0xb7b43d=_0x14054f;this[_0xb7b43d(0x310)][_0xb7b43d(0x251)](_0x2dea76[_0xb7b43d(0x278)]);}),this[_0x14054f(0x286)]['on'](_0x14054f(0x205),(_0x2091de,_0x410a23)=>{const _0x4d59a9=_0x14054f;this[_0x4d59a9(0x310)][_0x4d59a9(0x265)](_0x410a23[_0x4d59a9(0x332)]);}),this[_0x14054f(0x286)]['on'](_0x14054f(0x20b),(_0x46e6d0,_0x369660)=>{const _0x5cced1=_0x14054f;this[_0x5cced1(0x310)][_0x5cced1(0x2db)](_0x369660[_0x5cced1(0x271)],_0x369660[_0x5cced1(0x30f)],_0x369660[_0x5cced1(0x318)],_0x369660[_0x5cced1(0x262)]);}),this[_0x14054f(0x286)]['on'](_0x14054f(0x2f7),(_0x3574fa,_0x235415)=>{const _0x2b343f=_0x14054f;this[_0x2b343f(0x310)][_0x2b343f(0x269)](_0x235415[_0x2b343f(0x271)],_0x235415[_0x2b343f(0x2ce)],_0x235415[_0x2b343f(0x35c)]);}),this[_0x14054f(0x286)]['on'](_0x14054f(0x2ba),(_0x500d72,_0x5bd06d)=>{const _0x4d39e9=_0x14054f;this[_0x4d39e9(0x310)][_0x4d39e9(0x34f)](_0x5bd06d);}),this[_0x14054f(0x286)]['on'](_0x14054f(0x282),async(_0xa07b7c,_0x122137)=>{const _0xe53a56=_0x14054f,_0x36d362=(await this[_0xe53a56(0x2b2)][_0xe53a56(0x23b)]())[_0xe53a56(0x36c)](_0x1c554e=>_0x1c554e['id']===_0x122137[_0xe53a56(0x243)]?.['id'])||null;this[_0xe53a56(0x310)][_0xe53a56(0x211)](_0x36d362,_0x122137[_0xe53a56(0x204)]);}),this[_0x14054f(0x286)]['on'](_0x14054f(0x1e9),(_0x2085bd,{error:_0x36b43b,interactionId:_0x54bc4e,fileName:_0x4a332b,url:_0xc1a559,sourceId:_0x408979,sourceLabel:_0x33497e})=>{const _0x290d68=_0x14054f,_0x265e00=_0x54bc4e?_0x54bc4e+':'+_0x441c86():_0x441c86();_0x36b43b[_0x290d68(0x25b)][_0x290d68(0x1f3)](_0x290d68(0x34e))?this[_0x290d68(0x310)][_0x290d68(0x280)]({'staticMessage':_0x3bbccd(this[_0x290d68(0x2fd)][_0x290d68(0x275)],_0x290d68(0x25d)),'id':_0x265e00}):_0x36b43b[_0x290d68(0x25b)][_0x290d68(0x1f3)](_0x290d68(0x2c6))||_0x36b43b[_0x290d68(0x25b)][_0x290d68(0x1f3)](_0x290d68(0x30c))?(this[_0x290d68(0x310)][_0x290d68(0x30e)]({'errorMessage':_0x3bbccd(this[_0x290d68(0x2fd)][_0x290d68(0x275)],_0x290d68(0x1e5)),'id':_0x265e00}),this[_0x290d68(0x357)](_0x36b43b)):_0x36b43b[_0x290d68(0x25b)][_0x290d68(0x1f3)](_0x290d68(0x237))?this[_0x290d68(0x310)][_0x290d68(0x30e)]({'errorMessage':_0x3bbccd(this[_0x290d68(0x2fd)][_0x290d68(0x275)],_0x290d68(0x2e3),_0x4a332b),'id':_0x265e00}):_0x36b43b[_0x290d68(0x25b)][_0x290d68(0x1f3)](_0x290d68(0x246))?this[_0x290d68(0x310)][_0x290d68(0x30e)]({'errorMessage':_0x3bbccd(this[_0x290d68(0x2fd)][_0x290d68(0x275)],_0x290d68(0x322),_0xc1a559),'id':_0x265e00}):_0x36b43b[_0x290d68(0x25b)][_0x290d68(0x1f3)](_0x290d68(0x257))?this[_0x290d68(0x310)][_0x290d68(0x30e)]({'errorMessage':_0x3bbccd(this[_0x290d68(0x2fd)][_0x290d68(0x275)],_0x290d68(0x256)),'id':_0x265e00}):_0x36b43b[_0x290d68(0x25b)][_0x290d68(0x1f3)](_0x290d68(0x29b))?this[_0x290d68(0x310)][_0x290d68(0x30e)]({'errorMessage':_0x3bbccd(this[_0x290d68(0x2fd)][_0x290d68(0x275)],_0x290d68(0x32f)),'id':_0x265e00}):_0x36b43b[_0x290d68(0x25b)][_0x290d68(0x1f3)](_0x290d68(0x342))?(_0x408979&&this[_0x290d68(0x310)][_0x290d68(0x291)](_0x408979),this[_0x290d68(0x310)][_0x290d68(0x30e)]({'errorMessage':_0x3bbccd(this[_0x290d68(0x2fd)][_0x290d68(0x275)],_0x290d68(0x304),_0x33497e||_0x290d68(0x30f)),'id':_0x265e00}),this[_0x290d68(0x357)](_0x36b43b)):_0x36b43b[_0x290d68(0x25b)][_0x290d68(0x1f3)](_0x290d68(0x2e9))?(this[_0x290d68(0x310)][_0x290d68(0x30e)]({'errorMessage':_0x3bbccd(this[_0x290d68(0x2fd)][_0x290d68(0x275)],_0x290d68(0x2d7)),'id':_0x265e00}),this[_0x290d68(0x357)](_0x36b43b)):_0x36b43b[_0x290d68(0x25b)][_0x290d68(0x1f3)](_0x290d68(0x29a))?(this[_0x290d68(0x310)][_0x290d68(0x30e)]({'errorMessage':_0x3bbccd(this[_0x290d68(0x2fd)][_0x290d68(0x275)],_0x290d68(0x20c)),'id':_0x265e00}),this[_0x290d68(0x357)](_0x36b43b)):_0x36b43b[_0x290d68(0x25b)][_0x290d68(0x1f3)](_0x290d68(0x2fa))?(this[_0x290d68(0x310)][_0x290d68(0x30e)]({'errorMessage':_0x3bbccd(this[_0x290d68(0x2fd)][_0x290d68(0x275)],_0x290d68(0x22d)),'id':_0x265e00}),this[_0x290d68(0x357)](_0x36b43b)):_0x36b43b[_0x290d68(0x25b)][_0x290d68(0x1f3)](_0x290d68(0x356))?(this[_0x290d68(0x310)][_0x290d68(0x30e)]({'errorMessage':_0x3bbccd(this[_0x290d68(0x2fd)][_0x290d68(0x275)],_0x290d68(0x2f2)),'id':_0x265e00}),this[_0x290d68(0x357)](_0x36b43b)):_0x36b43b[_0x290d68(0x25b)][_0x290d68(0x1f3)](_0x290d68(0x1fb))?(this[_0x290d68(0x310)][_0x290d68(0x30e)]({'errorMessage':_0x3bbccd(this[_0x290d68(0x2fd)][_0x290d68(0x275)],_0x290d68(0x26b)),'id':_0x265e00}),this[_0x290d68(0x357)](_0x36b43b)):_0x36b43b[_0x290d68(0x25b)][_0x290d68(0x1f3)](_0x290d68(0x30d))?(this[_0x290d68(0x310)][_0x290d68(0x30e)]({'errorMessage':_0x3bbccd(this[_0x290d68(0x2fd)][_0x290d68(0x275)],_0x290d68(0x345)),'id':_0x265e00}),this[_0x290d68(0x357)](_0x36b43b)):(this[_0x290d68(0x310)][_0x290d68(0x30e)]({'errorMessage':_0x3bbccd(this[_0x290d68(0x2fd)][_0x290d68(0x275)],_0x290d68(0x35a)),'id':_0x265e00}),this[_0x290d68(0x357)](_0x36b43b));}),await this[_0x14054f(0x286)][_0x14054f(0x20d)](this[_0x14054f(0x2fd)][_0x14054f(0x330)][_0x14054f(0x2be)](_0x14054f(0x2eb))),_0x51d76d||await this[_0x14054f(0x286)][_0x14054f(0x2ae)]();}async[_0x2747dd(0x27f)]({userMessage:_0x4d09ee,attributes:_0x1053ac}){const _0x47d9dc=_0x2747dd;if(!this[_0x47d9dc(0x286)])throw new _0x2f9ac0(_0x47d9dc(0x2d6));if(this[_0x47d9dc(0x286)][_0x47d9dc(0x2b4)]()){const _0x1b4187=await this[_0x47d9dc(0x25e)][_0x47d9dc(0x2ef)]();await this[_0x47d9dc(0x286)][_0x47d9dc(0x2aa)](_0x1b4187);}this[_0x47d9dc(0x286)]['id']&&this[_0x47d9dc(0x286)][_0x47d9dc(0x253)]&&await this[_0x47d9dc(0x286)][_0x47d9dc(0x311)]({'userMessage':_0x4d09ee,'attributes':_0x1053ac});}[_0x2747dd(0x274)](){const _0x1e1e1e=_0x2747dd;console[_0x1e1e1e(0x36f)](_0x1e1e1e(0x232));}[_0x2747dd(0x260)](_0x51b3b2){const _0x309683=_0x2747dd;this[_0x309683(0x310)][_0x309683(0x220)](_0x51b3b2);}[_0x2747dd(0x357)](_0x34103c){const _0x84fe6=_0x2747dd;_0x4adf39(_0x34103c[_0x84fe6(0x25b)]);}[_0x2747dd(0x258)](_0x5e873e){const _0x1554d9=_0x2747dd;this[_0x1554d9(0x286)]?.[_0x1554d9(0x320)](_0x5e873e);}[_0x2747dd(0x206)](){const _0x4f4be5=_0x2747dd;this[_0x4f4be5(0x286)]?.[_0x4f4be5(0x25c)]();}[_0x2747dd(0x270)](){const _0x57c279=_0x2747dd;this[_0x57c279(0x286)]?.[_0x57c279(0x31f)]();}[_0x2747dd(0x319)](_0x5958a3){const _0x1ded7c=_0x2747dd,[_0xc7962e,_0x4c3a56]=_0x5958a3[_0x1ded7c(0x227)](':'),_0x1f4149=this[_0x1ded7c(0x286)][_0x1ded7c(0x1ff)](_0xc7962e),_0x5541e5=_0x1f4149[_0x1ded7c(0x337)](_0x4c3a56);return{'interaction':_0x1f4149,'reply':_0x5541e5};}[_0x2747dd(0x298)](_0x54161d,_0xc94e9=!0x1){const _0x314ff5=_0x2747dd,_0x3c2473=_0x1edd1c(this[_0x314ff5(0x2fd)]),_0x458d6e={'target':_0x3c2473[_0x314ff5(0x352)][_0x314ff5(0x2ea)][_0x314ff5(0x263)][_0x314ff5(0x1ed)](_0x3c2473[_0x314ff5(0x352)][_0x314ff5(0x2d0)][_0x314ff5(0x228)](_0x54161d)),'viewportOffset':{'top':0x96,'left':0x0,'bottom':0x32,'right':0x0},'ancestorOffset':0x14,'alignToTop':_0xc94e9};_0xc94e9&&(_0x458d6e[_0x314ff5(0x2d1)]=!0x0),_0x26977c(_0x458d6e);}[_0x2747dd(0x27c)](_0x55eac9,_0x56baec=!0x1){const _0x15be4c=_0x2747dd;this[_0x15be4c(0x310)][_0x15be4c(0x22c)](_0x55eac9||_0x3bbccd(this[_0x15be4c(0x2fd)][_0x15be4c(0x275)],_0x15be4c(0x2ed)),_0x56baec);}async[_0x2747dd(0x349)]({reply:_0x4bc9cb,renderingStrategy:_0x247da1}){const _0x25b4e7=_0x2747dd,{id:_0x5a476d,interactionId:_0x5b4ed5,isDone:_0x45ed13,type:_0x231797,parsedContent:_0x1e1d93}=_0x4bc9cb,_0x5333c2=_0x5b4ed5+':'+_0x5a476d;if(_0x25b4e7(0x1f6)===_0x231797){const _0x4b2816=_0x4bc9cb[_0x25b4e7(0x203)]({'showDiff':this[_0x25b4e7(0x310)][_0x25b4e7(0x2f5)]});await this[_0x25b4e7(0x310)][_0x25b4e7(0x230)]({'id':_0x5333c2,'parts':_0x4b2816,'renderingStrategy':_0x247da1,'isDone':_0x45ed13});}else _0x25b4e7(0x2b0)===_0x231797&&await this[_0x25b4e7(0x310)][_0x25b4e7(0x215)]({'id':_0x5333c2,'parsedContent':_0x1e1d93,'renderingStrategy':_0x247da1,'isDone':_0x45ed13});_0x45ed13&&_0x4bc9cb[_0x25b4e7(0x32e)][_0x25b4e7(0x1e8)]>0x0&&this[_0x25b4e7(0x310)][_0x25b4e7(0x21d)](_0x5333c2,_0x4bc9cb[_0x25b4e7(0x32e)]);}async[_0x2747dd(0x1fd)](){const _0x32c10f=_0x2747dd,_0xcbc6a9=this[_0x32c10f(0x286)]?.[_0x32c10f(0x302)];_0xcbc6a9&&(_0xcbc6a9[_0x32c10f(0x358)](),this[_0x32c10f(0x310)][_0x32c10f(0x2c3)](_0xcbc6a9));}async[_0x2747dd(0x35b)](){const _0x4d6957=_0x2747dd,_0x4594bf=this[_0x4d6957(0x286)]?.[_0x4d6957(0x302)];if(_0x4594bf){for await(const _0x5c47d7 of _0x4594bf[_0x4d6957(0x32c)])await this[_0x4d6957(0x349)]({'reply':_0x5c47d7,'renderingStrategy':_0x4d6957(0x2cc)});}}[_0x2747dd(0x284)](_0x180eeb){const _0x514440=_0x2747dd,_0x50d871={'positiveCount':_0x180eeb[_0x514440(0x2fe)][_0x514440(0x261)](_0x2b3424=>_0x514440(0x2a5)===_0x2b3424[_0x514440(0x2b6)])[_0x514440(0x1e8)],'totalCount':_0x180eeb[_0x514440(0x2fe)][_0x514440(0x1e8)],'modificationId':_0x180eeb['id']},_0x2b47d1=this[_0x514440(0x286)][_0x514440(0x1ff)](_0x180eeb[_0x514440(0x296)])[_0x514440(0x2b3)];_0x2b47d1&&this[_0x514440(0x241)][_0x514440(0x240)](this[_0x514440(0x286)]['id'],_0x2b47d1,_0x50d871);}[_0x2747dd(0x2f3)](_0x501474){const _0x4ae38b=_0x2747dd;let _0x15b4d1=null,_0x5ce051=null;this['on'](_0x4ae38b(0x314),(_0x31cd8b,_0x2dbb4b,_0x5d99df)=>{const _0x24095a=_0x4ae38b;_0x5d99df['id']!==_0x15b4d1&&(_0x15b4d1=_0x5d99df['id'],_0x5ce051=this[_0x24095a(0x340)](_0x5d99df)),_0x501474(_0x2dbb4b,_0x5ce051);});}[_0x2747dd(0x340)](_0x3ea4a5){const _0x59ff9f=_0x2747dd,_0x47c7ac=this[_0x59ff9f(0x310)],_0x1964b7=()=>{const _0x439da6=_0x59ff9f;_0x3ea4a5[_0x439da6(0x31a)](),_0x3ea4a5[_0x439da6(0x331)](),_0x47c7ac[_0x439da6(0x2a9)]();},_0x423d63=()=>{const _0x42b49c=_0x59ff9f;_0x3ea4a5[_0x42b49c(0x24c)]&&(_0x3ea4a5[_0x42b49c(0x24c)][_0x42b49c(0x348)](),_0x3ea4a5[_0x42b49c(0x24c)]=void 0x0);};return{'insertTextReply':(_0x501c28,_0x4ff7e8)=>{const _0x23d18d=_0x59ff9f;_0x423d63(),_0x1964b7();const _0x20e463=_0x3ea4a5[_0x23d18d(0x24c)]=_0x3ea4a5[_0x23d18d(0x31c)]({'type':_0x23d18d(0x2b0),'interactionId':_0x3ea4a5['id'],'content':_0x501c28,'id':_0x4ff7e8||_0x441c86()});return _0x423d63(),_0x20e463;},'insertCustomElement':async(_0xf1815f,_0x343ffd)=>(_0x423d63(),_0x1964b7(),_0x47c7ac[_0x59ff9f(0x363)](_0xf1815f,_0x343ffd||_0x441c86())),'setLoadingMessage':_0x54786e=>{const _0xf10a36=_0x59ff9f;_0x47c7ac[_0xf10a36(0x218)](_0x54786e);},'clearLoadingMessage':()=>{const _0x44d873=_0x59ff9f;_0x47c7ac[_0x44d873(0x2a9)]();}};}}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x6176ee=_0x3372;(function(_0x330b34,_0x3f6a03){const _0x4e8583=_0x3372,_0x1daa2d=_0x330b34();while(!![]){try{const _0x5ab1b3=parseInt(_0x4e8583(0x134))/0x1*(parseInt(_0x4e8583(0x1a7))/0x2)+-parseInt(_0x4e8583(0x14b))/0x3*(parseInt(_0x4e8583(0x1c8))/0x4)+parseInt(_0x4e8583(0x1d2))/0x5+parseInt(_0x4e8583(0x1a6))/0x6*(-parseInt(_0x4e8583(0x1e4))/0x7)+-parseInt(_0x4e8583(0x1d7))/0x8+-parseInt(_0x4e8583(0x17e))/0x9*(parseInt(_0x4e8583(0x163))/0xa)+parseInt(_0x4e8583(0x1a9))/0xb;if(_0x5ab1b3===_0x3f6a03)break;else _0x1daa2d['push'](_0x1daa2d['shift']());}catch(_0x2b52ff){_0x1daa2d['push'](_0x1daa2d['shift']());}}}(_0x2c6e,0xe8ada));function _0x3372(_0x146efa,_0x4c2446){const _0x2c6e2a=_0x2c6e();return _0x3372=function(_0x3372dc,_0x413e4b){_0x3372dc=_0x3372dc-0x133;let _0x52d912=_0x2c6e2a[_0x3372dc];return _0x52d912;},_0x3372(_0x146efa,_0x4c2446);}import{ContextPlugin as _0x1569d2}from'ckeditor5/src/core.js';import{_isMotionReduced as _0x528ce3}from'ckeditor5/src/utils.js';import{AIChatView as _0x5e1a78}from'./ui/aichatview.js';function _0x2c6e(){const _0x2f0755=['isReasoningEnabled','updateFeedInteractionHeader','setFeedItemRenderingStrategy','locale','_getInputPlaceholder','interaction-header','config','renderingStrategy','populateSourceResourceBalloon','ai.availableReplyActions','isPending','<p>','88lcodXs','updateReplyItem','setPromptInputValue','isPremiumPlugin','from','TrackChanges','AI_CHAT_WELCOME_MESSAGE','updateCapabilities','enqueue','updateFeedItemAIReplyContent','3640075vcryXs','value','remove','focusPromptInput','markFeedItemAsDone','13083760ToOQSF','isLoading','AIChatUI','chatControls','setModel','addFeedItemAISuggestion','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH_REASONING','destroy','_animateConversationTitle','displayedPrompt','isModelAvailable','toggleSuggestionDisplayMode','view','70826EXHwgI','isOfficialPlugin','interactionId','conversation-start','404945YGgLpa','enableModelSelector','last','chatHeader','requires','updateSuggestionItem','set','toggleLoadingSkeleton','user-message','resetMessageInput','AI_CHAT_FEED_LOADING_MESSAGE_REASONING','AITabs','get','custom-element','abort','startInteraction','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REASONING','streaming','plugins','contextItems','areActionsDisabled','options','showResizeButton','247404DpYbKP','AI_CHAT_FEED_LOADING_MESSAGE_REGULAR','removeContextItem','disableControls','length','setIsUploadInProgress','updateSuggestionPartState','setSelectedModel','_isTrackChangesCommandValueBound','filter','updateFeedItemAIReplySources','setReasoning','ai.chat.context.searchInputVisibleFrom','updateResourceState','AI_CHAT_HEADING','conversationCreated','finishInteraction','feedItemRenderingStrategy','isMaximized','setFeedItemAIReplySuggestionPartActive','isDisabled','_titleAnimationInterval','has','queueEmptyPromise','5903990oeDSUG','context','trackChanges','createConversation','find','addFeedItemStaticMessage','forEach','hasFeedItem','addItem','clearLoadingMessage','stopInteraction','addFeedItemUserMessage','capabilities','setInputPlaceholder','addFeedItemAIReply','isDone','attributes','</p>','isWebSearchEnabled','startsWith','removeFeedItem','ai.models.showModelSelector','pluginName','setConversationTitle','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH','clearConversationContextUI','setWebSearch','9NoHUEQ','clear','enableControls','setConversationContext','updateFeedItemAIReplySuggestionContent','insertSuggestion','isTrackChangesOn','then','setLoadingMessage','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH','setSuggestionPartActive','addFeedItemCustomElement','startAutoScroll','stopAutoScroll','ai-reply','scrollFeedToSuggestion','commands','error-message','setContextItemLoading','fire','chatFeed','bind','userMessage','showDiff','setIsMaximized','getItemIds','addFeedInteractionHeader','chat','hasItem','updateWebSources','setAddContextOptions','_interactionPromiseResolver','children','closeSourceResourceBalloon','addContextItem','_view','addFeedItemError','isBusy','prepareLoadingMessage','delegate','516gtofWR','2EhHMLX','removeItem','52034433GcAfRj','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH_REASONING','clearPendingContextUI','ai.chat.welcomeMessage','removeFeedInteraction','scrollToSuggestion','markItemAsDone','label','disableModelSelector','ai-suggestion-reply','addTab','availableModels','updateFeedItemAIReplySuggestionPartState','resetConversationTitle','isVisible','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REGULAR','setModelList','values','_promiseQueue'];_0x2c6e=function(){return _0x2f0755;};return _0x2c6e();}import{AITabs as _0x1b72fe}from'../aitabs/aitabs.js';import{getTranslation as _0x14725c}from'../aicore/utils/common-translations.js';import{IconAIChat as _0x306729}from'ckeditor5/src/icons.js';import{AIChatFeedInteractionHeaderView as _0x1be2dc}from'./ui/feed/aichatfeedinteractionheaderview.js';import{PromiseQueue as _0x232a0b}from'./utils/promisequeue.js';import{AI_CHAT_UI_EVENT_NAMES as _0x3ddcd3}from'./utils/eventnames.js';import'../../theme/aichat/aichat.css';import{getEditorFromContext as _0xb3b154}from'../aicore/utils/geteditorfromcontext.js';import{AI_REPLY_ACTIONS as _0x5b5cb1}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';export class AIChatUI extends _0x1569d2{static get[_0x6176ee(0x138)](){return[_0x1b72fe];}[_0x6176ee(0x1a1)];static get[_0x6176ee(0x179)](){const _0x513d3c=_0x6176ee;return _0x513d3c(0x1d9);}static get[_0x6176ee(0x1e5)](){return!0x0;}static get[_0x6176ee(0x1cb)](){return!0x0;}[_0x6176ee(0x15c)]=_0x6176ee(0x145);[_0x6176ee(0x195)]=!0x0;[_0x6176ee(0x1bb)];[_0x6176ee(0x19d)];[_0x6176ee(0x160)]=void 0x0;[_0x6176ee(0x153)]=!0x1;constructor(_0xf3cb99){const _0x423615=_0x6176ee;super(_0xf3cb99);const _0x30d50d=this[_0x423615(0x164)][_0x423615(0x146)][_0x423615(0x140)](_0x423615(0x13f));this[_0x423615(0x13a)](_0x423615(0x1a3),!0x1),this[_0x423615(0x1bb)]=new _0x232a0b(),this[_0x423615(0x1a1)]=new _0x5e1a78(this[_0x423615(0x164)][_0x423615(0x1bf)],{'showResizeButton':_0x30d50d[_0x423615(0x14a)],'contextResourcesSearchInputVisibleFrom':this[_0x423615(0x164)][_0x423615(0x1c2)][_0x423615(0x140)](_0x423615(0x157))}),this[_0x423615(0x1a1)][_0x423615(0x1a5)](..._0x3ddcd3)['to'](this),this[_0x423615(0x1a1)]['on'](_0x423615(0x1e2),(_0x4917f1,{showDiff:_0x8b5343})=>{const _0x2a7857=_0x423615;this[_0x2a7857(0x195)]=_0x8b5343;}),_0x30d50d[_0x423615(0x1e3)][_0x423615(0x1b3)]({'id':_0x423615(0x199),'buttonLabel':_0x14725c(this[_0x423615(0x164)][_0x423615(0x1bf)],_0x423615(0x159)),'buttonIcon':_0x306729,'order':0x0,'content':this[_0x423615(0x1a1)]}),this[_0x423615(0x1a1)][_0x423615(0x1da)][_0x423615(0x193)](_0x423615(0x1d8))['to'](this,_0x423615(0x1a3),_0x96e94e=>_0x96e94e),this[_0x423615(0x1a1)][_0x423615(0x192)][_0x423615(0x193)](_0x423615(0x1c6))['to'](this,_0x423615(0x1a3),_0x51fdc1=>_0x51fdc1),this[_0x423615(0x1a1)][_0x423615(0x1da)][_0x423615(0x170)](this[_0x423615(0x1c0)]()),this[_0x423615(0x193)](_0x423615(0x1e1))['to'](this[_0x423615(0x1a1)][_0x423615(0x1da)],_0x423615(0x1e1));}[_0x6176ee(0x1de)](){const _0x2878cc=_0x6176ee;super[_0x2878cc(0x1de)](),this[_0x2878cc(0x160)]&&clearInterval(this[_0x2878cc(0x160)]);}[_0x6176ee(0x166)](_0x430fd6){const _0x459b2b=_0x6176ee,_0x56f416=this[_0x459b2b(0x164)][_0x459b2b(0x1c2)][_0x459b2b(0x140)](_0x459b2b(0x1ac))??_0x14725c(this[_0x459b2b(0x164)][_0x459b2b(0x1bf)],_0x459b2b(0x1ce));this[_0x459b2b(0x1a1)][_0x459b2b(0x192)][_0x459b2b(0x17f)](),this[_0x459b2b(0x1a1)][_0x459b2b(0x1da)][_0x459b2b(0x135)](),this[_0x459b2b(0x1a1)][_0x459b2b(0x1da)][_0x459b2b(0x1b9)](_0x430fd6[_0x459b2b(0x1b4)],!this[_0x459b2b(0x164)][_0x459b2b(0x1c2)][_0x459b2b(0x140)](_0x459b2b(0x178))),this[_0x459b2b(0x168)]({'id':_0x459b2b(0x133),'staticMessage':_0x56f416}),this[_0x459b2b(0x191)](_0x459b2b(0x15a));}[_0x6176ee(0x168)]({id:_0x5c399d,staticMessage:_0x1b581e}){const _0xa0dada=_0x6176ee;this[_0xa0dada(0x1a1)][_0xa0dada(0x192)][_0xa0dada(0x16b)](_0xa0dada(0x18c),{'id':_0x5c399d,'initialContent':_0xa0dada(0x1c7)+_0x1b581e+_0xa0dada(0x174)});}[_0x6176ee(0x16e)](_0xcfceeb){const _0xfbe76a=_0x6176ee,_0x83cc8a=_0xcfceeb[_0xfbe76a(0x173)]?.[_0xfbe76a(0x1e0)]||_0xcfceeb[_0xfbe76a(0x194)];this[_0xfbe76a(0x1a1)][_0xfbe76a(0x192)][_0xfbe76a(0x16b)](_0xfbe76a(0x13c),{'contextItems':Array[_0xfbe76a(0x1cc)](_0xcfceeb[_0xfbe76a(0x147)][_0xfbe76a(0x1ba)]()),'initialContent':_0xfbe76a(0x1c7)+_0x83cc8a+_0xfbe76a(0x174),'id':_0xcfceeb['id']});}[_0x6176ee(0x1a2)]({errorMessage:_0x333121,id:_0x1efd07}){const _0x448de7=_0x6176ee;this[_0x448de7(0x1a1)][_0x448de7(0x192)][_0x448de7(0x16b)](_0x448de7(0x18f),{'initialContent':_0x448de7(0x1c7)+_0x333121+_0x448de7(0x174),'id':_0x1efd07});}[_0x6176ee(0x171)](_0x3e0c18){const _0x445668=_0x6176ee;return this[_0x445668(0x1bb)][_0x445668(0x1d0)](async()=>{const _0x33437c=_0x445668;this[_0x33437c(0x1a1)][_0x33437c(0x192)][_0x33437c(0x16b)](_0x33437c(0x18c),{'id':_0x3e0c18[_0x33437c(0x1e6)]+':'+_0x3e0c18['id']}),this[_0x33437c(0x16c)]();});}async[_0x6176ee(0x1dc)](_0x416653){const _0x3c8f4b=_0x6176ee,_0x326c72=_0xb3b154(this[_0x3c8f4b(0x164)]);let _0x5f49f0=_0x326c72[_0x3c8f4b(0x1c2)][_0x3c8f4b(0x140)](_0x3c8f4b(0x1c5))||[..._0x5b5cb1];if(_0x326c72[_0x3c8f4b(0x146)][_0x3c8f4b(0x161)](_0x3c8f4b(0x1cd))){if(!this[_0x3c8f4b(0x153)]){this[_0x3c8f4b(0x153)]=!0x0;const _0x9e09f1=_0x326c72[_0x3c8f4b(0x18e)][_0x3c8f4b(0x140)](_0x3c8f4b(0x165));this[_0x3c8f4b(0x1a1)][_0x3c8f4b(0x192)][_0x3c8f4b(0x193)](_0x3c8f4b(0x184))['to'](_0x9e09f1,_0x3c8f4b(0x1d3));}}else _0x5f49f0=_0x5f49f0[_0x3c8f4b(0x154)](_0x12f09b=>_0x3c8f4b(0x183)!=_0x12f09b);return this[_0x3c8f4b(0x1bb)][_0x3c8f4b(0x1d0)](async()=>{const _0x36b366=_0x3c8f4b;this[_0x36b366(0x1a1)][_0x36b366(0x192)][_0x36b366(0x16b)](_0x36b366(0x1b2),{'id':_0x416653[_0x36b366(0x1e6)]+':'+_0x416653['id'],'areActionsDisabled':_0x416653[_0x36b366(0x148)],'showDiff':this[_0x36b366(0x195)],'availableActions':_0x5f49f0}),this[_0x36b366(0x16c)]();});}[_0x6176ee(0x198)](_0x3b0493,_0x5ba4b8){const _0x1f17a5=_0x6176ee,_0x508704=this[_0x1f17a5(0x1a1)][_0x1f17a5(0x192)][_0x1f17a5(0x19e)][_0x1f17a5(0x136)];if(_0x508704 instanceof _0x1be2dc)return this[_0x1f17a5(0x1a1)][_0x1f17a5(0x192)][_0x1f17a5(0x19e)][_0x1f17a5(0x1d4)](_0x508704),void this[_0x1f17a5(0x1a1)][_0x1f17a5(0x192)][_0x1f17a5(0x16b)](_0x1f17a5(0x1c1),{'id':_0x3b0493['id'],'capabilities':{'isWebSearchEnabled':_0x508704[_0x1f17a5(0x16f)][_0x1f17a5(0x175)]||_0x5ba4b8[_0x1f17a5(0x175)],'isReasoningEnabled':_0x508704[_0x1f17a5(0x16f)][_0x1f17a5(0x1bc)]||_0x5ba4b8[_0x1f17a5(0x1bc)]}});this[_0x1f17a5(0x1a1)][_0x1f17a5(0x192)][_0x1f17a5(0x16b)](_0x1f17a5(0x1c1),{'id':_0x3b0493['id'],'capabilities':_0x5ba4b8});}async[_0x6176ee(0x189)](_0x330de9,_0x40fb13){const _0x589265=_0x6176ee;let _0xbafbad;return await this[_0x589265(0x1bb)][_0x589265(0x1d0)](async()=>{const _0x3705ca=_0x589265;_0xbafbad=this[_0x3705ca(0x1a1)][_0x3705ca(0x192)][_0x3705ca(0x16b)](_0x3705ca(0x141),{'content':_0x330de9,'id':_0x40fb13});}),_0xbafbad;}[_0x6176ee(0x177)](_0x5aae1b){const _0x38f87a=_0x6176ee;this[_0x38f87a(0x1a1)][_0x38f87a(0x192)][_0x38f87a(0x1a8)](_0x5aae1b);}[_0x6176ee(0x16a)](_0x367ad4){const _0x3c6438=_0x6176ee;return this[_0x3c6438(0x1a1)][_0x3c6438(0x192)][_0x3c6438(0x19a)](_0x367ad4);}[_0x6176ee(0x1bd)](_0x57cd34){const _0x167208=_0x6176ee,_0xf7b64c=this[_0x167208(0x1a1)][_0x167208(0x192)][_0x167208(0x19e)][_0x167208(0x167)](_0x3ddb3b=>_0x3ddb3b[_0x167208(0x149)]['id']==_0x57cd34['id']&&_0x3ddb3b instanceof _0x1be2dc);_0xf7b64c&&_0xf7b64c[_0x167208(0x13a)](_0x167208(0x1b7),_0x57cd34[_0x167208(0x1b7)]);}async[_0x6176ee(0x1d1)](_0x382487){const _0x456289=_0x6176ee,_0x3ef3e6=_0x382487[_0x456289(0x1c3)]||this[_0x456289(0x15c)];return this[_0x456289(0x1bb)][_0x456289(0x1d0)](async _0x14e4b4=>{const _0x42a398=_0x456289;await this[_0x42a398(0x1a1)][_0x42a398(0x192)][_0x42a398(0x1c9)]({..._0x382487,'abortSignal':_0x14e4b4,'renderingStrategy':_0x3ef3e6}),_0x382487[_0x42a398(0x172)]&&this[_0x42a398(0x1d6)](_0x382487['id']);});}[_0x6176ee(0x155)](_0x1a13d2,_0x3d66e6){const _0x1894b9=_0x6176ee;this[_0x1894b9(0x1a1)][_0x1894b9(0x192)][_0x1894b9(0x19b)](_0x1a13d2,_0x3d66e6);}async[_0x6176ee(0x182)](_0x4110a7){const _0x15561b=_0x6176ee,_0x50e8c8=_0x4110a7[_0x15561b(0x1c3)]||this[_0x15561b(0x15c)];return this[_0x15561b(0x1bb)][_0x15561b(0x1d0)](async _0x246d1e=>{const _0x25c137=_0x15561b;await this[_0x25c137(0x1a1)][_0x25c137(0x192)][_0x25c137(0x139)]({..._0x4110a7,'abortSignal':_0x246d1e,'renderingStrategy':_0x50e8c8}),_0x4110a7[_0x25c137(0x172)]&&this[_0x25c137(0x1d6)](_0x4110a7['id']);});}[_0x6176ee(0x1b5)](_0x3607ab){const _0x1991fb=_0x6176ee;this[_0x1991fb(0x1a1)][_0x1991fb(0x192)][_0x1991fb(0x151)](_0x3607ab);}[_0x6176ee(0x15e)](_0xb88e58){const _0x10f148=_0x6176ee;this[_0x10f148(0x1a1)][_0x10f148(0x192)][_0x10f148(0x188)](_0xb88e58);}[_0x6176ee(0x1d6)](_0x9b3874){const _0x36f9bf=_0x6176ee;this[_0x36f9bf(0x1a1)][_0x36f9bf(0x192)][_0x36f9bf(0x1af)](_0x9b3874);}[_0x6176ee(0x1ad)](_0x4a1fea){const _0x18869e=_0x6176ee;this[_0x18869e(0x1a1)][_0x18869e(0x192)][_0x18869e(0x197)]()[_0x18869e(0x154)](_0x52ad8b=>_0x52ad8b[_0x18869e(0x176)](_0x4a1fea))[_0x18869e(0x169)](_0x2cef57=>this[_0x18869e(0x1a1)][_0x18869e(0x192)][_0x18869e(0x1a8)](_0x2cef57));}[_0x6176ee(0x143)](){const _0x3a6123=_0x6176ee,_0x349840=this[_0x3a6123(0x1a4)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x1});this[_0x3a6123(0x186)](_0x349840),this[_0x3a6123(0x1a1)][_0x3a6123(0x1da)][_0x3a6123(0x1b1)](!this[_0x3a6123(0x164)][_0x3a6123(0x1c2)][_0x3a6123(0x140)](_0x3a6123(0x178))),this[_0x3a6123(0x1a3)]=!0x0,this[_0x3a6123(0x1a1)][_0x3a6123(0x192)][_0x3a6123(0x18a)]();}[_0x6176ee(0x16d)](_0x28e7ec){const _0x1da42b=_0x6176ee;this[_0x1da42b(0x1bb)][_0x1da42b(0x142)](),this[_0x1da42b(0x1a1)][_0x1da42b(0x192)][_0x1da42b(0x197)]()[_0x1da42b(0x154)](_0x5d3d65=>_0x5d3d65[_0x1da42b(0x176)](_0x28e7ec['id']))[_0x1da42b(0x169)](_0x2b4387=>this[_0x1da42b(0x1d6)](_0x2b4387)),this[_0x1da42b(0x1a3)]=!0x1,this[_0x1da42b(0x1a1)][_0x1da42b(0x192)][_0x1da42b(0x18b)]();}async[_0x6176ee(0x15b)](){const _0x2be500=_0x6176ee;return this[_0x2be500(0x1bb)][_0x2be500(0x162)][_0x2be500(0x185)](()=>{const _0x11a149=_0x2be500;this[_0x11a149(0x1a3)]=!0x1,this[_0x11a149(0x1a1)][_0x11a149(0x192)][_0x11a149(0x18b)]();});}[_0x6176ee(0x1a0)](_0x3f1cbb,_0x3b2736){const _0xa29896=_0x6176ee;this[_0xa29896(0x1a1)][_0xa29896(0x1da)][_0xa29896(0x1a0)](_0x3f1cbb,_0x3b2736);}[_0x6176ee(0x14d)](_0x1ab714){const _0x469bb8=_0x6176ee;this[_0x469bb8(0x1a1)][_0x469bb8(0x1da)][_0x469bb8(0x14d)](_0x1ab714);}[_0x6176ee(0x190)](_0x139771,_0x3bcaa5){const _0x192d83=_0x6176ee;this[_0x192d83(0x1a1)][_0x192d83(0x1da)][_0x192d83(0x190)](_0x139771,_0x3bcaa5);}[_0x6176ee(0x150)](_0x302fec){const _0x80c778=_0x6176ee;this[_0x80c778(0x1a1)][_0x80c778(0x1da)][_0x80c778(0x150)](_0x302fec);}[_0x6176ee(0x181)](_0x2f8d56){const _0x31e5cd=_0x6176ee;this[_0x31e5cd(0x1a1)][_0x31e5cd(0x1da)][_0x31e5cd(0x181)](_0x2f8d56);}[_0x6176ee(0x1ab)](){const _0x459309=_0x6176ee;this[_0x459309(0x1a1)][_0x459309(0x1da)][_0x459309(0x1ab)]();}[_0x6176ee(0x17c)](){const _0x44849a=_0x6176ee;this[_0x44849a(0x1a1)][_0x44849a(0x1da)][_0x44849a(0x17c)]();}[_0x6176ee(0x158)](_0xd983b8,_0x10c61f,_0x5204ee){const _0x466d1f=_0x6176ee;this[_0x466d1f(0x1a1)][_0x466d1f(0x1da)][_0x466d1f(0x158)](_0xd983b8,_0x10c61f,_0x5204ee);}[_0x6176ee(0x13d)](){const _0x19bfa8=_0x6176ee;this[_0x19bfa8(0x1a1)][_0x19bfa8(0x1da)][_0x19bfa8(0x13d)](),this[_0x19bfa8(0x1a1)][_0x19bfa8(0x1da)][_0x19bfa8(0x170)](this[_0x19bfa8(0x1c0)]());}[_0x6176ee(0x19c)](_0x8f028d){const _0x3ea6d0=_0x6176ee;this[_0x3ea6d0(0x1a1)][_0x3ea6d0(0x1da)][_0x3ea6d0(0x19c)](_0x8f028d);}[_0x6176ee(0x1cf)](_0x850559){const _0x548a1c=_0x6176ee;this[_0x548a1c(0x1a1)][_0x548a1c(0x1da)][_0x548a1c(0x17d)](_0x850559[_0x548a1c(0x175)]),this[_0x548a1c(0x1a1)][_0x548a1c(0x1da)][_0x548a1c(0x156)](_0x850559[_0x548a1c(0x1bc)]),this[_0x548a1c(0x1a1)][_0x548a1c(0x1da)][_0x548a1c(0x170)](this[_0x548a1c(0x1c0)](_0x850559));}[_0x6176ee(0x152)](_0x531099,_0x279a9b){const _0xf7a342=_0x6176ee;this[_0xf7a342(0x1a1)][_0xf7a342(0x1da)][_0xf7a342(0x1db)](_0x531099),_0x279a9b&&this[_0xf7a342(0x1a1)][_0xf7a342(0x1da)][_0xf7a342(0x1b1)](!0x1);}[_0x6176ee(0x1be)](_0x5aa570){const _0x128f59=_0x6176ee;this[_0x128f59(0x15c)]=_0x5aa570;}[_0x6176ee(0x13b)](_0x544f4a){const _0x51ef6d=_0x6176ee;this[_0x51ef6d(0x1a1)][_0x51ef6d(0x192)][_0x51ef6d(0x13b)](_0x544f4a);}[_0x6176ee(0x1b6)](){const _0x4849cd=_0x6176ee;this[_0x4849cd(0x17a)](_0x14725c(this[_0x4849cd(0x164)][_0x4849cd(0x1bf)],_0x4849cd(0x159)));}[_0x6176ee(0x17a)](_0x38c819,_0x52914e=!0x1){const _0x300b5b=_0x6176ee;if(_0x52914e&&!_0x528ce3()&&_0x38c819[_0x300b5b(0x14f)])return this[_0x300b5b(0x1a1)][_0x300b5b(0x137)][_0x300b5b(0x1b0)]='',void this[_0x300b5b(0x1df)](_0x38c819);this[_0x300b5b(0x1a1)][_0x300b5b(0x137)][_0x300b5b(0x1b0)]=_0x38c819;}[_0x6176ee(0x186)](_0x36f530){const _0x3bddbe=_0x6176ee;this[_0x3bddbe(0x1a1)][_0x3bddbe(0x192)][_0x3bddbe(0x186)](_0x36f530);}[_0x6176ee(0x16c)](){const _0x5507da=_0x6176ee;this[_0x5507da(0x1a1)][_0x5507da(0x192)][_0x5507da(0x186)]('');}[_0x6176ee(0x1df)](_0x5c23df){const _0x72b48a=_0x6176ee;let _0x18754a=0x0;clearInterval(this[_0x72b48a(0x160)]),this[_0x72b48a(0x160)]=setInterval(()=>{const _0x1fc0d7=_0x72b48a;this[_0x1fc0d7(0x1a1)][_0x1fc0d7(0x137)][_0x1fc0d7(0x1b0)]=this[_0x1fc0d7(0x1a1)][_0x1fc0d7(0x137)][_0x1fc0d7(0x1b0)]+_0x5c23df[_0x18754a],_0x18754a++,_0x18754a===_0x5c23df[_0x1fc0d7(0x14f)]&&clearInterval(this[_0x1fc0d7(0x160)]);},0x1e);}[_0x6176ee(0x196)](_0x33c2e0){const _0xe54f81=_0x6176ee;this[_0xe54f81(0x1a1)][_0xe54f81(0x137)][_0xe54f81(0x15d)]=_0x33c2e0;}[_0x6176ee(0x1a4)](_0x10bc35){const _0x5c12cf=_0x6176ee;return _0x10bc35[_0x5c12cf(0x175)]&&_0x10bc35[_0x5c12cf(0x1bc)]?_0x14725c(this[_0x5c12cf(0x164)][_0x5c12cf(0x1bf)],_0x5c12cf(0x1dd)):_0x10bc35[_0x5c12cf(0x175)]?_0x14725c(this[_0x5c12cf(0x164)][_0x5c12cf(0x1bf)],_0x5c12cf(0x187)):_0x10bc35[_0x5c12cf(0x1bc)]?_0x14725c(this[_0x5c12cf(0x164)][_0x5c12cf(0x1bf)],_0x5c12cf(0x13e)):_0x14725c(this[_0x5c12cf(0x164)][_0x5c12cf(0x1bf)],_0x5c12cf(0x14c));}[_0x6176ee(0x1c0)](_0x3f8d15){const _0x1e6551=_0x6176ee;return _0x3f8d15?_0x3f8d15[_0x1e6551(0x175)]&&_0x3f8d15[_0x1e6551(0x1bc)]?_0x14725c(this[_0x1e6551(0x164)][_0x1e6551(0x1bf)],_0x1e6551(0x1aa)):_0x3f8d15[_0x1e6551(0x175)]?_0x14725c(this[_0x1e6551(0x164)][_0x1e6551(0x1bf)],_0x1e6551(0x17b)):_0x3f8d15[_0x1e6551(0x1bc)]?_0x14725c(this[_0x1e6551(0x164)][_0x1e6551(0x1bf)],_0x1e6551(0x144)):_0x14725c(this[_0x1e6551(0x164)][_0x1e6551(0x1bf)],_0x1e6551(0x1b8)):_0x14725c(this[_0x1e6551(0x164)][_0x1e6551(0x1bf)],_0x1e6551(0x1b8));}[_0x6176ee(0x1c4)](_0xa3dd50,_0x1125c6,_0x5e04d7,_0x4474ba){const _0x213f1e=_0x6176ee;this[_0x213f1e(0x1a1)][_0x213f1e(0x1c4)](_0xa3dd50,_0x1125c6,_0x5e04d7,_0x4474ba);}[_0x6176ee(0x19f)](_0x2d2d35){const _0x2377e0=_0x6176ee;this[_0x2377e0(0x1a1)][_0x2377e0(0x19f)](_0x2d2d35);}[_0x6176ee(0x1ca)](_0x52fb2f){const _0x4968ef=_0x6176ee;this[_0x4968ef(0x1a1)][_0x4968ef(0x1da)][_0x4968ef(0x1ca)](_0x52fb2f);}[_0x6176ee(0x1d5)](_0x596dbd=!0x1){const _0x341069=_0x6176ee;this[_0x341069(0x1a1)][_0x341069(0x1da)][_0x341069(0x1d5)](_0x596dbd);}[_0x6176ee(0x18d)](_0x3f2ae5,_0x10fbd2){const _0x1ad9ac=_0x6176ee;this[_0x1ad9ac(0x1a1)][_0x1ad9ac(0x192)][_0x1ad9ac(0x1ae)](_0x3f2ae5,_0x10fbd2);}[_0x6176ee(0x18a)](){const _0xdded36=_0x6176ee;this[_0xdded36(0x1a1)][_0xdded36(0x192)][_0xdded36(0x18a)]();}[_0x6176ee(0x14e)](){const _0x3e0fd2=_0x6176ee;this[_0x3e0fd2(0x1a1)][_0x3e0fd2(0x1da)][_0x3e0fd2(0x15f)]=!0x0;}[_0x6176ee(0x180)](){const _0x5ca518=_0x6176ee;this[_0x5ca518(0x1a1)][_0x5ca518(0x1da)][_0x5ca518(0x15f)]=!0x1;}}
23
+ const _0x3317c0=_0x5f43;(function(_0xc46bad,_0x4999c2){const _0x424329=_0x5f43,_0x4b7692=_0xc46bad();while(!![]){try{const _0xe5c372=-parseInt(_0x424329(0xeb))/0x1+-parseInt(_0x424329(0xfe))/0x2*(parseInt(_0x424329(0xc5))/0x3)+parseInt(_0x424329(0x94))/0x4+-parseInt(_0x424329(0xc2))/0x5+-parseInt(_0x424329(0x92))/0x6*(parseInt(_0x424329(0x7b))/0x7)+parseInt(_0x424329(0xa1))/0x8*(-parseInt(_0x424329(0x10c))/0x9)+-parseInt(_0x424329(0x108))/0xa*(-parseInt(_0x424329(0x78))/0xb);if(_0xe5c372===_0x4999c2)break;else _0x4b7692['push'](_0x4b7692['shift']());}catch(_0x1f1d32){_0x4b7692['push'](_0x4b7692['shift']());}}}(_0x1c90,0xadd31));function _0x5f43(_0x3d1c2c,_0x3a36c7){const _0x1c905b=_0x1c90();return _0x5f43=function(_0x5f4318,_0x5636a5){_0x5f4318=_0x5f4318-0x6d;let _0x3ee36e=_0x1c905b[_0x5f4318];return _0x3ee36e;},_0x5f43(_0x3d1c2c,_0x3a36c7);}import{ContextPlugin as _0x56cc2b}from'ckeditor5/src/core.js';import{_isMotionReduced as _0x1dabd6}from'ckeditor5/src/utils.js';import{AIChatView as _0x18a52c}from'./ui/aichatview.js';import{AITabs as _0x201db7}from'../aitabs/aitabs.js';import{getTranslation as _0x53b576}from'../aicore/utils/common-translations.js';function _0x1c90(){const _0x55391c=['chatControls','clear','updateSuggestionItem','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REGULAR','hasFeedItem','removeFeedInteraction','<p>','hasItem','addFeedItemAISuggestion','resetConversationTitle','conversationCreated','scrollToSuggestion','requires','plugins','ai-suggestion-reply','toggleSuggestionDisplayMode','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH_REASONING','contextItems','setFeedItemRenderingStrategy','updateFeedItemAIReplySuggestionPartState','setSelectedModel','enableControls','1014938TtBxBi','markItemAsDone','ai.chat.context.searchInputVisibleFrom','enableModelSelector','last','ai.models.showModelSelector','user-message','showDiff','getItemIds','trackChanges','addFeedItemCustomElement','updateCapabilities','config','isModelAvailable','toggleLoadingSkeleton','startInteraction','AI_CHAT_FEED_LOADING_MESSAGE_REGULAR','AI_CHAT_WELCOME_MESSAGE','addContextItem','2Jwxblt','set','_titleAnimationInterval','label','showResizeButton','isPremiumPlugin','context','setReasoning','options','areActionsDisabled','41906810JXgvwk','startsWith','view','isWebSearchEnabled','11943NJrnii','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH','setContextItemLoading','AIChatUI','resetMessageInput','setIsUploadInProgress','capabilities','updateFeedItemAIReplyContent','fire','clearPendingContextUI','attributes','updateSuggestionPartState','filter','updateFeedItemAIReplySources','updateFeedInteractionHeader','setConversationTitle','ai-reply','destroy','isTrackChangesOn','feedItemRenderingStrategy','userMessage','remove','setFeedItemAIReplySuggestionPartActive','updateReplyItem','_isTrackChangesCommandValueBound','chat','custom-element','AI_CHAT_FEED_LOADING_MESSAGE_REASONING','values','isMaximized','clearConversationContextUI','get','11hlqtmG','addFeedItemUserMessage','children','7AKLyVL','stopInteraction','populateSourceResourceBalloon','updateResourceState','_getInputPlaceholder','addFeedInteractionHeader','isDone','setModel','locale','availableModels','setPromptInputValue','isDisabled','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH_REASONING','interactionId','addFeedItemError','stopAutoScroll','from','has','updateWebSources','AITabs','</p>','_animateConversationTitle','error-message','1366782WVAZRv','updateFeedItemAIReplySuggestionContent','1564836ZRluWE','renderingStrategy','ai.availableReplyActions','isBusy','TrackChanges','removeFeedItem','markFeedItemAsDone','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REASONING','queueEmptyPromise','conversation-start','ai.chat.welcomeMessage','isLoading','length','2936iRQGkY','isPending','interaction-header','isVisible','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH','setSuggestionPartActive','bind','addFeedItemAIReply','addTab','setInputPlaceholder','createConversation','chatFeed','pluginName','setModelList','chatHeader','value','clearLoadingMessage','startAutoScroll','AI_CHAT_HEADING','setConversationContext','scrollFeedToSuggestion','insertSuggestion','setLoadingMessage','forEach','displayedPrompt','_view','commands','_promiseQueue','finishInteraction','focusPromptInput','setIsMaximized','closeSourceResourceBalloon','disableControls','6792120JRcRHQ','isOfficialPlugin','disableModelSelector','2345211fyntWB','delegate','prepareLoadingMessage','then','_interactionPromiseResolver','streaming','setAddContextOptions','addFeedItemStaticMessage','removeContextItem','setWebSearch','enqueue','addItem','abort','removeItem','find','isReasoningEnabled'];_0x1c90=function(){return _0x55391c;};return _0x1c90();}import{IconAIChat as _0x4d2411}from'ckeditor5/src/icons.js';import{AIChatFeedInteractionHeaderView as _0x17f7be}from'./ui/feed/aichatfeedinteractionheaderview.js';import{PromiseQueue as _0x32bbeb}from'./utils/promisequeue.js';import{AI_CHAT_UI_EVENT_NAMES as _0x1e2ced}from'./utils/eventnames.js';import'../../theme/aichat/aichat.css';import{getEditorFromContext as _0x225a88}from'../aicore/utils/geteditorfromcontext.js';import{AI_REPLY_ACTIONS as _0x538a24}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';export class AIChatUI extends _0x56cc2b{static get[_0x3317c0(0xe1)](){return[_0x201db7];}[_0x3317c0(0xba)];static get[_0x3317c0(0xad)](){const _0x1c2544=_0x3317c0;return _0x1c2544(0x10f);}static get[_0x3317c0(0xc3)](){return!0x0;}static get[_0x3317c0(0x103)](){return!0x0;}[_0x3317c0(0x11f)]=_0x3317c0(0xca);[_0x3317c0(0xf2)]=!0x0;[_0x3317c0(0xbc)];[_0x3317c0(0xc9)];[_0x3317c0(0x100)]=void 0x0;[_0x3317c0(0x70)]=!0x1;constructor(_0x4d2df){const _0x5f0350=_0x3317c0;super(_0x4d2df);const _0x1576ba=this[_0x5f0350(0x104)][_0x5f0350(0xe2)][_0x5f0350(0x77)](_0x5f0350(0x8e));this[_0x5f0350(0xff)](_0x5f0350(0x97),!0x1),this[_0x5f0350(0xbc)]=new _0x32bbeb(),this[_0x5f0350(0xba)]=new _0x18a52c(this[_0x5f0350(0x104)][_0x5f0350(0x83)],{'showResizeButton':_0x1576ba[_0x5f0350(0x102)],'contextResourcesSearchInputVisibleFrom':this[_0x5f0350(0x104)][_0x5f0350(0xf7)][_0x5f0350(0x77)](_0x5f0350(0xed))}),this[_0x5f0350(0xba)][_0x5f0350(0xc6)](..._0x1e2ced)['to'](this),this[_0x5f0350(0xba)]['on'](_0x5f0350(0xe4),(_0x2559bb,{showDiff:_0x269d67})=>{const _0x7e97d3=_0x5f0350;this[_0x7e97d3(0xf2)]=_0x269d67;}),_0x1576ba[_0x5f0350(0x10a)][_0x5f0350(0xa9)]({'id':_0x5f0350(0x71),'buttonLabel':_0x53b576(this[_0x5f0350(0x104)][_0x5f0350(0x83)],_0x5f0350(0xb3)),'buttonIcon':_0x4d2411,'order':0x0,'content':this[_0x5f0350(0xba)]}),this[_0x5f0350(0xba)][_0x5f0350(0xd5)][_0x5f0350(0xa7)](_0x5f0350(0x9f))['to'](this,_0x5f0350(0x97),_0x3971f8=>_0x3971f8),this[_0x5f0350(0xba)][_0x5f0350(0xac)][_0x5f0350(0xa7)](_0x5f0350(0xa2))['to'](this,_0x5f0350(0x97),_0x5721e8=>_0x5721e8),this[_0x5f0350(0xba)][_0x5f0350(0xd5)][_0x5f0350(0xaa)](this[_0x5f0350(0x7f)]()),this[_0x5f0350(0xa7)](_0x5f0350(0xf8))['to'](this[_0x5f0350(0xba)][_0x5f0350(0xd5)],_0x5f0350(0xf8));}[_0x3317c0(0x11d)](){const _0x375abf=_0x3317c0;super[_0x375abf(0x11d)](),this[_0x375abf(0x100)]&&clearInterval(this[_0x375abf(0x100)]);}[_0x3317c0(0xab)](_0x538d6e){const _0x159d00=_0x3317c0,_0x516e9f=this[_0x159d00(0x104)][_0x159d00(0xf7)][_0x159d00(0x77)](_0x159d00(0x9e))??_0x53b576(this[_0x159d00(0x104)][_0x159d00(0x83)],_0x159d00(0xfc));this[_0x159d00(0xba)][_0x159d00(0xac)][_0x159d00(0xd6)](),this[_0x159d00(0xba)][_0x159d00(0xd5)][_0x159d00(0xee)](),this[_0x159d00(0xba)][_0x159d00(0xd5)][_0x159d00(0xae)](_0x538d6e[_0x159d00(0x84)],!this[_0x159d00(0x104)][_0x159d00(0xf7)][_0x159d00(0x77)](_0x159d00(0xf0))),this[_0x159d00(0xcc)]({'id':_0x159d00(0x9d),'staticMessage':_0x516e9f}),this[_0x159d00(0x114)](_0x159d00(0xdf));}[_0x3317c0(0xcc)]({id:_0x36395d,staticMessage:_0x4e3b49}){const _0x1801b9=_0x3317c0;this[_0x1801b9(0xba)][_0x1801b9(0xac)][_0x1801b9(0xd0)](_0x1801b9(0x11c),{'id':_0x36395d,'initialContent':_0x1801b9(0xdb)+_0x4e3b49+_0x1801b9(0x8f)});}[_0x3317c0(0x79)](_0x51ae5e){const _0x350135=_0x3317c0,_0x30dbc5=_0x51ae5e[_0x350135(0x116)]?.[_0x350135(0xb9)]||_0x51ae5e[_0x350135(0x120)];this[_0x350135(0xba)][_0x350135(0xac)][_0x350135(0xd0)](_0x350135(0xf1),{'contextItems':Array[_0x350135(0x8b)](_0x51ae5e[_0x350135(0xe6)][_0x350135(0x74)]()),'initialContent':_0x350135(0xdb)+_0x30dbc5+_0x350135(0x8f),'id':_0x51ae5e['id']});}[_0x3317c0(0x89)]({errorMessage:_0x12af9c,id:_0x1d5993}){const _0x53bfd8=_0x3317c0;this[_0x53bfd8(0xba)][_0x53bfd8(0xac)][_0x53bfd8(0xd0)](_0x53bfd8(0x91),{'initialContent':_0x53bfd8(0xdb)+_0x12af9c+_0x53bfd8(0x8f),'id':_0x1d5993});}[_0x3317c0(0xa8)](_0x3416a4){const _0x1adeff=_0x3317c0;return this[_0x1adeff(0xbc)][_0x1adeff(0xcf)](async()=>{const _0x5f216b=_0x1adeff;this[_0x5f216b(0xba)][_0x5f216b(0xac)][_0x5f216b(0xd0)](_0x5f216b(0x11c),{'id':_0x3416a4[_0x5f216b(0x88)]+':'+_0x3416a4['id']}),this[_0x5f216b(0xb1)]();});}async[_0x3317c0(0xdd)](_0x3d292e){const _0x4603ba=_0x3317c0,_0xc5a3b7=_0x225a88(this[_0x4603ba(0x104)]);let _0x97f162=_0xc5a3b7[_0x4603ba(0xf7)][_0x4603ba(0x77)](_0x4603ba(0x96))||[..._0x538a24];if(_0xc5a3b7[_0x4603ba(0xe2)][_0x4603ba(0x8c)](_0x4603ba(0x98))){if(!this[_0x4603ba(0x70)]){this[_0x4603ba(0x70)]=!0x0;const _0x139d92=_0xc5a3b7[_0x4603ba(0xbb)][_0x4603ba(0x77)](_0x4603ba(0xf4));this[_0x4603ba(0xba)][_0x4603ba(0xac)][_0x4603ba(0xa7)](_0x4603ba(0x11e))['to'](_0x139d92,_0x4603ba(0xb0));}}else _0x97f162=_0x97f162[_0x4603ba(0x118)](_0x20ea26=>_0x4603ba(0xb6)!=_0x20ea26);return this[_0x4603ba(0xbc)][_0x4603ba(0xcf)](async()=>{const _0x463253=_0x4603ba;this[_0x463253(0xba)][_0x463253(0xac)][_0x463253(0xd0)](_0x463253(0xe3),{'id':_0x3d292e[_0x463253(0x88)]+':'+_0x3d292e['id'],'areActionsDisabled':_0x3d292e[_0x463253(0x107)],'showDiff':this[_0x463253(0xf2)],'availableActions':_0x97f162}),this[_0x463253(0xb1)]();});}[_0x3317c0(0x80)](_0x56a7cb,_0x12f4dd){const _0x5cc841=_0x3317c0,_0x48b952=this[_0x5cc841(0xba)][_0x5cc841(0xac)][_0x5cc841(0x7a)][_0x5cc841(0xef)];if(_0x48b952 instanceof _0x17f7be)return this[_0x5cc841(0xba)][_0x5cc841(0xac)][_0x5cc841(0x7a)][_0x5cc841(0x6d)](_0x48b952),void this[_0x5cc841(0xba)][_0x5cc841(0xac)][_0x5cc841(0xd0)](_0x5cc841(0xa3),{'id':_0x56a7cb['id'],'capabilities':{'isWebSearchEnabled':_0x48b952[_0x5cc841(0x112)][_0x5cc841(0x10b)]||_0x12f4dd[_0x5cc841(0x10b)],'isReasoningEnabled':_0x48b952[_0x5cc841(0x112)][_0x5cc841(0xd4)]||_0x12f4dd[_0x5cc841(0xd4)]}});this[_0x5cc841(0xba)][_0x5cc841(0xac)][_0x5cc841(0xd0)](_0x5cc841(0xa3),{'id':_0x56a7cb['id'],'capabilities':_0x12f4dd});}async[_0x3317c0(0xf5)](_0x31ef5c,_0x4a5504){const _0x403989=_0x3317c0;let _0x2b0919;return await this[_0x403989(0xbc)][_0x403989(0xcf)](async()=>{const _0x102207=_0x403989;_0x2b0919=this[_0x102207(0xba)][_0x102207(0xac)][_0x102207(0xd0)](_0x102207(0x72),{'content':_0x31ef5c,'id':_0x4a5504});}),_0x2b0919;}[_0x3317c0(0x99)](_0x4f780a){const _0x541c0c=_0x3317c0;this[_0x541c0c(0xba)][_0x541c0c(0xac)][_0x541c0c(0xd2)](_0x4f780a);}[_0x3317c0(0xd9)](_0x2a1eca){const _0x585196=_0x3317c0;return this[_0x585196(0xba)][_0x585196(0xac)][_0x585196(0xdc)](_0x2a1eca);}[_0x3317c0(0x11a)](_0x5e7604){const _0x284240=_0x3317c0,_0x20c26e=this[_0x284240(0xba)][_0x284240(0xac)][_0x284240(0x7a)][_0x284240(0xd3)](_0x41dbb4=>_0x41dbb4[_0x284240(0x106)]['id']==_0x5e7604['id']&&_0x41dbb4 instanceof _0x17f7be);_0x20c26e&&_0x20c26e[_0x284240(0xff)](_0x284240(0xa4),_0x5e7604[_0x284240(0xa4)]);}async[_0x3317c0(0x113)](_0x13c9ee){const _0x41265f=_0x3317c0,_0x49e657=_0x13c9ee[_0x41265f(0x95)]||this[_0x41265f(0x11f)];return this[_0x41265f(0xbc)][_0x41265f(0xcf)](async _0x447bd7=>{const _0x111927=_0x41265f;await this[_0x111927(0xba)][_0x111927(0xac)][_0x111927(0x6f)]({..._0x13c9ee,'abortSignal':_0x447bd7,'renderingStrategy':_0x49e657}),_0x13c9ee[_0x111927(0x81)]&&this[_0x111927(0x9a)](_0x13c9ee['id']);});}[_0x3317c0(0x119)](_0x4c596b,_0x4ef59b){const _0x194468=_0x3317c0;this[_0x194468(0xba)][_0x194468(0xac)][_0x194468(0x8d)](_0x4c596b,_0x4ef59b);}async[_0x3317c0(0x93)](_0x407dbf){const _0x4b738c=_0x3317c0,_0x22aeb1=_0x407dbf[_0x4b738c(0x95)]||this[_0x4b738c(0x11f)];return this[_0x4b738c(0xbc)][_0x4b738c(0xcf)](async _0x25960c=>{const _0x1875b2=_0x4b738c;await this[_0x1875b2(0xba)][_0x1875b2(0xac)][_0x1875b2(0xd7)]({..._0x407dbf,'abortSignal':_0x25960c,'renderingStrategy':_0x22aeb1}),_0x407dbf[_0x1875b2(0x81)]&&this[_0x1875b2(0x9a)](_0x407dbf['id']);});}[_0x3317c0(0xe8)](_0x459685){const _0x47c591=_0x3317c0;this[_0x47c591(0xba)][_0x47c591(0xac)][_0x47c591(0x117)](_0x459685);}[_0x3317c0(0x6e)](_0x20ebeb){const _0x2fdd81=_0x3317c0;this[_0x2fdd81(0xba)][_0x2fdd81(0xac)][_0x2fdd81(0xa6)](_0x20ebeb);}[_0x3317c0(0x9a)](_0x50e396){const _0x459f3d=_0x3317c0;this[_0x459f3d(0xba)][_0x459f3d(0xac)][_0x459f3d(0xec)](_0x50e396);}[_0x3317c0(0xda)](_0x5a5cb9){const _0xda74e=_0x3317c0;this[_0xda74e(0xba)][_0xda74e(0xac)][_0xda74e(0xf3)]()[_0xda74e(0x118)](_0x98270b=>_0x98270b[_0xda74e(0x109)](_0x5a5cb9))[_0xda74e(0xb8)](_0x21b78c=>this[_0xda74e(0xba)][_0xda74e(0xac)][_0xda74e(0xd2)](_0x21b78c));}[_0x3317c0(0xfa)](){const _0x101369=_0x3317c0,_0x3118c8=this[_0x101369(0xc7)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x1});this[_0x101369(0xb7)](_0x3118c8),this[_0x101369(0xba)][_0x101369(0xd5)][_0x101369(0xc4)](!this[_0x101369(0x104)][_0x101369(0xf7)][_0x101369(0x77)](_0x101369(0xf0))),this[_0x101369(0x97)]=!0x0,this[_0x101369(0xba)][_0x101369(0xac)][_0x101369(0xb2)]();}[_0x3317c0(0x7c)](_0x4904b){const _0x3fdd6d=_0x3317c0;this[_0x3fdd6d(0xbc)][_0x3fdd6d(0xd1)](),this[_0x3fdd6d(0xba)][_0x3fdd6d(0xac)][_0x3fdd6d(0xf3)]()[_0x3fdd6d(0x118)](_0xd27939=>_0xd27939[_0x3fdd6d(0x109)](_0x4904b['id']))[_0x3fdd6d(0xb8)](_0x3b54ac=>this[_0x3fdd6d(0x9a)](_0x3b54ac)),this[_0x3fdd6d(0x97)]=!0x1,this[_0x3fdd6d(0xba)][_0x3fdd6d(0xac)][_0x3fdd6d(0x8a)]();}async[_0x3317c0(0xbd)](){const _0x6bddeb=_0x3317c0;return this[_0x6bddeb(0xbc)][_0x6bddeb(0x9c)][_0x6bddeb(0xc8)](()=>{const _0x339ef4=_0x6bddeb;this[_0x339ef4(0x97)]=!0x1,this[_0x339ef4(0xba)][_0x339ef4(0xac)][_0x339ef4(0x8a)]();});}[_0x3317c0(0xfd)](_0x3f9c38,_0x1f6611){const _0x4f0630=_0x3317c0;this[_0x4f0630(0xba)][_0x4f0630(0xd5)][_0x4f0630(0xfd)](_0x3f9c38,_0x1f6611);}[_0x3317c0(0xcd)](_0x3fed8f){const _0x2858b2=_0x3317c0;this[_0x2858b2(0xba)][_0x2858b2(0xd5)][_0x2858b2(0xcd)](_0x3fed8f);}[_0x3317c0(0x10e)](_0x5eed51,_0x14e6d9){const _0x575ce9=_0x3317c0;this[_0x575ce9(0xba)][_0x575ce9(0xd5)][_0x575ce9(0x10e)](_0x5eed51,_0x14e6d9);}[_0x3317c0(0x111)](_0x14b98e){const _0x10f5df=_0x3317c0;this[_0x10f5df(0xba)][_0x10f5df(0xd5)][_0x10f5df(0x111)](_0x14b98e);}[_0x3317c0(0xb4)](_0x51f8e1){const _0x10d45a=_0x3317c0;this[_0x10d45a(0xba)][_0x10d45a(0xd5)][_0x10d45a(0xb4)](_0x51f8e1);}[_0x3317c0(0x115)](){const _0x9c6df3=_0x3317c0;this[_0x9c6df3(0xba)][_0x9c6df3(0xd5)][_0x9c6df3(0x115)]();}[_0x3317c0(0x76)](){const _0x4724ea=_0x3317c0;this[_0x4724ea(0xba)][_0x4724ea(0xd5)][_0x4724ea(0x76)]();}[_0x3317c0(0x7e)](_0x5c5b54,_0xe596be,_0x4f3b27){const _0x262ccd=_0x3317c0;this[_0x262ccd(0xba)][_0x262ccd(0xd5)][_0x262ccd(0x7e)](_0x5c5b54,_0xe596be,_0x4f3b27);}[_0x3317c0(0x110)](){const _0x1b2ba2=_0x3317c0;this[_0x1b2ba2(0xba)][_0x1b2ba2(0xd5)][_0x1b2ba2(0x110)](),this[_0x1b2ba2(0xba)][_0x1b2ba2(0xd5)][_0x1b2ba2(0xaa)](this[_0x1b2ba2(0x7f)]());}[_0x3317c0(0xcb)](_0x42fffe){const _0x172e9e=_0x3317c0;this[_0x172e9e(0xba)][_0x172e9e(0xd5)][_0x172e9e(0xcb)](_0x42fffe);}[_0x3317c0(0xf6)](_0x385342){const _0x5323d3=_0x3317c0;this[_0x5323d3(0xba)][_0x5323d3(0xd5)][_0x5323d3(0xce)](_0x385342[_0x5323d3(0x10b)]),this[_0x5323d3(0xba)][_0x5323d3(0xd5)][_0x5323d3(0x105)](_0x385342[_0x5323d3(0xd4)]),this[_0x5323d3(0xba)][_0x5323d3(0xd5)][_0x5323d3(0xaa)](this[_0x5323d3(0x7f)](_0x385342));}[_0x3317c0(0xe9)](_0x7e602e,_0x23d4a6){const _0x3218c5=_0x3317c0;this[_0x3218c5(0xba)][_0x3218c5(0xd5)][_0x3218c5(0x82)](_0x7e602e),_0x23d4a6&&this[_0x3218c5(0xba)][_0x3218c5(0xd5)][_0x3218c5(0xc4)](!0x1);}[_0x3317c0(0xe7)](_0xe7c3d2){const _0xb22aca=_0x3317c0;this[_0xb22aca(0x11f)]=_0xe7c3d2;}[_0x3317c0(0xf9)](_0x6d0fff){const _0x5cd278=_0x3317c0;this[_0x5cd278(0xba)][_0x5cd278(0xac)][_0x5cd278(0xf9)](_0x6d0fff);}[_0x3317c0(0xde)](){const _0xc93e25=_0x3317c0;this[_0xc93e25(0x11b)](_0x53b576(this[_0xc93e25(0x104)][_0xc93e25(0x83)],_0xc93e25(0xb3)));}[_0x3317c0(0x11b)](_0x2c4752,_0x5b8c85=!0x1){const _0x2d8e93=_0x3317c0;if(_0x5b8c85&&!_0x1dabd6()&&_0x2c4752[_0x2d8e93(0xa0)])return this[_0x2d8e93(0xba)][_0x2d8e93(0xaf)][_0x2d8e93(0x101)]='',void this[_0x2d8e93(0x90)](_0x2c4752);this[_0x2d8e93(0xba)][_0x2d8e93(0xaf)][_0x2d8e93(0x101)]=_0x2c4752;}[_0x3317c0(0xb7)](_0x3398c7){const _0x3d1f8b=_0x3317c0;this[_0x3d1f8b(0xba)][_0x3d1f8b(0xac)][_0x3d1f8b(0xb7)](_0x3398c7);}[_0x3317c0(0xb1)](){const _0xcf31d1=_0x3317c0;this[_0xcf31d1(0xba)][_0xcf31d1(0xac)][_0xcf31d1(0xb7)]('');}[_0x3317c0(0x90)](_0x1f316e){const _0x154b40=_0x3317c0;let _0x2e3cce=0x0;clearInterval(this[_0x154b40(0x100)]),this[_0x154b40(0x100)]=setInterval(()=>{const _0x1ab49e=_0x154b40;this[_0x1ab49e(0xba)][_0x1ab49e(0xaf)][_0x1ab49e(0x101)]=this[_0x1ab49e(0xba)][_0x1ab49e(0xaf)][_0x1ab49e(0x101)]+_0x1f316e[_0x2e3cce],_0x2e3cce++,_0x2e3cce===_0x1f316e[_0x1ab49e(0xa0)]&&clearInterval(this[_0x1ab49e(0x100)]);},0x1e);}[_0x3317c0(0xbf)](_0x1a83ef){const _0x537668=_0x3317c0;this[_0x537668(0xba)][_0x537668(0xaf)][_0x537668(0x75)]=_0x1a83ef;}[_0x3317c0(0xc7)](_0x1429e3){const _0x15e5ff=_0x3317c0;return _0x1429e3[_0x15e5ff(0x10b)]&&_0x1429e3[_0x15e5ff(0xd4)]?_0x53b576(this[_0x15e5ff(0x104)][_0x15e5ff(0x83)],_0x15e5ff(0xe5)):_0x1429e3[_0x15e5ff(0x10b)]?_0x53b576(this[_0x15e5ff(0x104)][_0x15e5ff(0x83)],_0x15e5ff(0xa5)):_0x1429e3[_0x15e5ff(0xd4)]?_0x53b576(this[_0x15e5ff(0x104)][_0x15e5ff(0x83)],_0x15e5ff(0x73)):_0x53b576(this[_0x15e5ff(0x104)][_0x15e5ff(0x83)],_0x15e5ff(0xfb));}[_0x3317c0(0x7f)](_0x22baaa){const _0x53e6c5=_0x3317c0;return _0x22baaa?_0x22baaa[_0x53e6c5(0x10b)]&&_0x22baaa[_0x53e6c5(0xd4)]?_0x53b576(this[_0x53e6c5(0x104)][_0x53e6c5(0x83)],_0x53e6c5(0x87)):_0x22baaa[_0x53e6c5(0x10b)]?_0x53b576(this[_0x53e6c5(0x104)][_0x53e6c5(0x83)],_0x53e6c5(0x10d)):_0x22baaa[_0x53e6c5(0xd4)]?_0x53b576(this[_0x53e6c5(0x104)][_0x53e6c5(0x83)],_0x53e6c5(0x9b)):_0x53b576(this[_0x53e6c5(0x104)][_0x53e6c5(0x83)],_0x53e6c5(0xd8)):_0x53b576(this[_0x53e6c5(0x104)][_0x53e6c5(0x83)],_0x53e6c5(0xd8));}[_0x3317c0(0x7d)](_0x46400e,_0x6be1c7,_0x381534,_0xe0a0b3){const _0x2102c9=_0x3317c0;this[_0x2102c9(0xba)][_0x2102c9(0x7d)](_0x46400e,_0x6be1c7,_0x381534,_0xe0a0b3);}[_0x3317c0(0xc0)](_0x59874c){const _0x9fe1f5=_0x3317c0;this[_0x9fe1f5(0xba)][_0x9fe1f5(0xc0)](_0x59874c);}[_0x3317c0(0x85)](_0x303fb8){const _0x67be69=_0x3317c0;this[_0x67be69(0xba)][_0x67be69(0xd5)][_0x67be69(0x85)](_0x303fb8);}[_0x3317c0(0xbe)](_0x26df61=!0x1){const _0x29803f=_0x3317c0;this[_0x29803f(0xba)][_0x29803f(0xd5)][_0x29803f(0xbe)](_0x26df61);}[_0x3317c0(0xb5)](_0x3ef895,_0x5bfd11){const _0x2fe75c=_0x3317c0;this[_0x2fe75c(0xba)][_0x2fe75c(0xac)][_0x2fe75c(0xe0)](_0x3ef895,_0x5bfd11);}[_0x3317c0(0xb2)](){const _0x1467c2=_0x3317c0;this[_0x1467c2(0xba)][_0x1467c2(0xac)][_0x1467c2(0xb2)]();}[_0x3317c0(0xc1)](){const _0xdc82b1=_0x3317c0;this[_0xdc82b1(0xba)][_0xdc82b1(0xd5)][_0xdc82b1(0x86)]=!0x0;}[_0x3317c0(0xea)](){const _0x46d858=_0x3317c0;this[_0x46d858(0xba)][_0x46d858(0xd5)][_0x46d858(0x86)]=!0x1;}}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- function _0x3b94(){const _0x7779f4=['files','isCurrentDocumentInConversation','version','sessionId','DOCUMENT','ai-request-aborted','getSentContextItems','contextItemLoadingEnded','_connector','document','SELECTION','getData','removeFromContext','url-','contextSent','addCurrentDocumentToContext','sources','start','_startUploadOperation','updateCurrentDocument','_ongoingUploadOperations','isReadOnly','_pendingContextItems','get','has','selection','fetchDocument','filter','length','188WQFosN','push','from','uploadDocument','data','_findSourceIdsByResourceId','792RpjxJu','isHidden','startsWith','addToConversationContext','FILE','removeSelectionFromContext','_setAddContextOptionsDefaultState','size','end','ai-chat-url-upload-failed','getResources','text/markdown','ai-chat-file-upload-failed','_addToConversationContextItem','URL','set','message','delete','getDocument','_mapContextItemToRequestData','File','_ownerId','isInContext','object','addUrlToContext','ai-chat-document-upload-failed','find','fire','ai-chat-resource-load-failed','contextItemAdded','_finishContextItemLoading','_getCustomSourcesInitialState','loadSourceResources','_convertTextResourceToFile','sourceResourcesLoaded','attributes','1902027mvOBUY','hidden','error','_toggleAddCurrentDocumentOptionVisibility','_isResourceInContext','ai-chat-context-unsupported-type','152155CcqJov','ai-chat-source-not-found','addToolItemToContext','getPendingContextItems','HTML','text/html','label','forEach','toolName','abortController','_addContextItem','1317162cTVAPc','_updateResourceInContextState','TOOL','file-','text/plain','_removeContextItem','all','2LEMSDG','378850hKpisB','addSelectionToContext','string','urls','resourceStateChanged','addFilesToContext','_conversationContextItems','abort','MARKDOWN','enabled','mcpServerName','contextItemRemoved','object\x20with\x20content\x20and\x20type\x20properties','init','addContextOptionsChanged','populateFromMessage','_config','1206318kEumIL','ai-chat-source-resources-load-failed','values','uiId','current-document','code','_createContextItemFromContent','getId','url','addResourceToContext','content','map','ai-chat-resource-no-data','Current\x20document','_ongoingUploads','customItems','TEXT','mapContextItemsToRequestData','isCurrentDocumentInContext','ai-chat-context-invalid-data','clearPendingContextItems','files-','isSelectionInContext','_addContextOptionsState','resourceId','uploadProgressChanged','_finishUploadOperation','uploadUrl','4246416TJNFEH','name','uploadFile','stack','type','substring','resources','587258WcdWjZ'];_0x3b94=function(){return _0x7779f4;};return _0x3b94();}const _0x4c43d5=_0x33af;(function(_0x1a4cc1,_0x29e313){const _0x12df2c=_0x33af,_0x30759f=_0x1a4cc1();while(!![]){try{const _0x43629a=parseInt(_0x12df2c(0x7d))/0x1*(-parseInt(_0x12df2c(0x10b))/0x2)+-parseInt(_0x12df2c(0xfa))/0x3+-parseInt(_0x12df2c(0xd0))/0x4*(parseInt(_0x12df2c(0x100))/0x5)+parseInt(_0x12df2c(0x8f))/0x6+parseInt(_0x12df2c(0xb2))/0x7+parseInt(_0x12df2c(0xab))/0x8+parseInt(_0x12df2c(0xd6))/0x9*(parseInt(_0x12df2c(0x7e))/0xa);if(_0x43629a===_0x29e313)break;else _0x30759f['push'](_0x30759f['shift']());}catch(_0x569e9b){_0x30759f['push'](_0x30759f['shift']());}}}(_0x3b94,0xbb8c9));import{CKEditorError as _0x2d4364,ObservableMixin as _0x1858a8,uid as _0x218167}from'ckeditor5/src/utils.js';function _0x33af(_0x4de831,_0x19a01c){const _0x3b94bb=_0x3b94();return _0x33af=function(_0x33af3e,_0x503fa7){_0x33af3e=_0x33af3e-0x7d;let _0x541cf7=_0x3b94bb[_0x33af3e];return _0x541cf7;},_0x33af(_0x4de831,_0x19a01c);}import{AIContextItemType as _0x4ce5ec,AIContextTextResourceType as _0x5e2d38}from'../../aicore/model/aicontext.js';import{escape as _0xca7685}from'es-toolkit/compat';import{errorsMap as _0x23da73}from'../../errorsmap.js';export const AI_CONTEXT_MODEL_EVENT_NAMES=[_0x4c43d5(0xf3),_0x4c43d5(0x89),_0x4c43d5(0xba),_0x4c43d5(0xc1),_0x4c43d5(0xfc),_0x4c43d5(0x8c),_0x4c43d5(0xf8),_0x4c43d5(0x82),_0x4c43d5(0xa8)];export class AIChatContext extends _0x1858a8(){[_0x4c43d5(0xbb)];[_0x4c43d5(0x8e)];[_0x4c43d5(0xeb)];constructor({connector:_0x2bc180,config:_0x537409,ownerId:_0x5955fb}){const _0x45d8f1=_0x4c43d5;super(),this[_0x45d8f1(0xbb)]=_0x2bc180,this[_0x45d8f1(0x8e)]=_0x537409,this[_0x45d8f1(0xeb)]=_0x5955fb;}[_0x4c43d5(0x8b)](){const _0x326006=_0x4c43d5;this[_0x326006(0xc9)]=new Map(),this[_0x326006(0x84)]=new Map(),this[_0x326006(0x9d)]=new Map(),this[_0x326006(0xc7)]=new Map(),this[_0x326006(0xdc)]();}[_0x4c43d5(0x103)](){const _0x1b1332=_0x4c43d5;return this[_0x1b1332(0xc9)];}async[_0x4c43d5(0x8d)](_0x110a3c){const _0x1199af=_0x4c43d5,_0x1f6465=await this[_0x1199af(0x95)](_0x110a3c);return this[_0x1199af(0xe3)](_0x1f6465),_0x1199af(0x93)===_0x1f6465[_0x1199af(0x92)]&&this[_0x1199af(0xfd)](),_0x1f6465;}async[_0x4c43d5(0x95)](_0x25d153){const _0x4ba6b9=_0x4c43d5;if(_0x25d153[_0x4ba6b9(0xaf)]===_0x4ce5ec[_0x4ba6b9(0xb7)]){const _0x10cb91=await this[_0x4ba6b9(0xbb)][_0x4ba6b9(0xcd)](this[_0x4ba6b9(0xeb)],_0x25d153['id'])[_0x4ba6b9(0xe8)]();return{'id':_0x4ba6b9(0x93),'uiId':_0x4ba6b9(0x93),'label':_0x4ba6b9(0x9c),'type':_0x25d153[_0x4ba6b9(0xaf)],'content':_0x10cb91[_0x4ba6b9(0x99)],'hidden':this[_0x4ba6b9(0x84)][_0x4ba6b9(0xcb)](_0x4ba6b9(0x93)),'version':_0x10cb91[_0x4ba6b9(0xf9)]?.[_0x4ba6b9(0xb5)],'sessionId':_0x10cb91[_0x4ba6b9(0xf9)]?.[_0x4ba6b9(0xb6)]};}if(_0x25d153[_0x4ba6b9(0xaf)]===_0x4ce5ec[_0x4ba6b9(0x10d)])return{'id':_0x25d153['id'],'uiId':_0x25d153['id'],'label':_0x25d153[_0x4ba6b9(0xd4)]?.[_0x4ba6b9(0x106)]||_0x25d153['id'],'type':_0x4ce5ec[_0x4ba6b9(0x10d)],'mcpServerName':_0x25d153[_0x4ba6b9(0x88)],'toolName':_0x25d153[_0x4ba6b9(0x108)],'data':_0x25d153[_0x4ba6b9(0xd4)]||{}};return{'id':_0x25d153['id'],'uiId':_0x25d153['id'],'label':_0x25d153[_0x4ba6b9(0xf9)]?.[_0x4ba6b9(0x106)]||_0x25d153[_0x4ba6b9(0xac)]||_0x25d153[_0x4ba6b9(0x97)]||_0x25d153['id'],'type':_0x25d153[_0x4ba6b9(0xaf)],..._0x25d153?.[_0x4ba6b9(0xf9)]?.[_0x4ba6b9(0xa7)]?{'resourceId':_0x25d153[_0x4ba6b9(0xf9)]?.[_0x4ba6b9(0xa7)]}:{}};}[_0x4c43d5(0xb9)](){const _0x183124=_0x4c43d5;return new Map(this[_0x183124(0x84)]);}[_0x4c43d5(0xbf)](_0x3ffe78){const _0x417c97=_0x4c43d5,_0x324ddb=this[_0x417c97(0xc9)][_0x417c97(0xca)](_0x3ffe78);_0x324ddb?.[_0x417c97(0xc8)]||this[_0x417c97(0x110)](_0x3ffe78);}[_0x4c43d5(0xa3)](){const _0x469e54=_0x4c43d5;if(0x0===this[_0x469e54(0xc9)][_0x469e54(0xdd)])return;for(const _0x3d11d2 of this[_0x469e54(0xc9)][_0x469e54(0x91)]())this[_0x469e54(0x110)](_0x3d11d2[_0x469e54(0x92)]);const _0x383a32=this[_0x469e54(0x84)][_0x469e54(0xca)](_0x469e54(0x93))||this[_0x469e54(0xc9)][_0x469e54(0xca)](_0x469e54(0x93));_0x383a32&&this[_0x469e54(0x10a)]({..._0x383a32,'isReadOnly':!0x0,'hidden':!0x0});}[_0x4c43d5(0xd9)](_0x12c385){const _0x3ae536=_0x4c43d5;for(const _0x4dd982 of _0x12c385[_0x3ae536(0x91)]())this[_0x3ae536(0xe3)](_0x4dd982);this[_0x3ae536(0xa3)](),this[_0x3ae536(0xf1)](_0x3ae536(0xc1),{'contextItems':Array[_0x3ae536(0xd2)](this[_0x3ae536(0xb9)]()[_0x3ae536(0x91)]())});}[_0x4c43d5(0xa1)](){const _0x435126=_0x4c43d5;return this[_0x435126(0xc9)][_0x435126(0xcb)](_0x435126(0x93));}[_0x4c43d5(0xa5)](){const _0x3eba97=_0x4c43d5;return this[_0x3eba97(0xc9)][_0x3eba97(0xcb)](_0x3eba97(0xcc));}[_0x4c43d5(0xb4)](){const _0x2d554b=_0x4c43d5;return this[_0x2d554b(0x84)][_0x2d554b(0xcb)](_0x2d554b(0x93));}static[_0x4c43d5(0xa0)](_0x276a5b){const _0x3b245b=_0x4c43d5;return Array[_0x3b245b(0xd2)](_0x276a5b[_0x3b245b(0x91)]())[_0x3b245b(0x9a)](_0x1ec22a=>this[_0x3b245b(0xe9)](_0x1ec22a))[_0x3b245b(0xce)](_0x32c20b=>null!==_0x32c20b);}async[_0x4c43d5(0x83)](_0x53edc7,_0x1b2045,_0x5b3169=_0x4ce5ec[_0x4c43d5(0xda)]){const _0x1c4fd9=_0x4c43d5,_0x53f461=_0x1c4fd9(0xa4)+_0x218167();this[_0x1c4fd9(0xc5)](_0x53f461);try{await Promise[_0x1c4fd9(0x111)](_0x53edc7[_0x1c4fd9(0x9a)](async _0x5da161=>{const _0x16f0e2=_0x1c4fd9,_0x4eefaa=_0x16f0e2(0x10e)+_0x218167(),_0x3b1139=_0xca7685(_0x5da161[_0x16f0e2(0xac)]);try{this[_0x16f0e2(0x10a)]({'type':_0x5b3169,'label':_0x1b2045?.[_0x16f0e2(0x106)]||_0x3b1139,'uiId':_0x4eefaa,'resourceId':_0x1b2045?.[_0x16f0e2(0xa7)]},!0x0);const _0x13a9a1=this[_0x16f0e2(0xbb)][_0x16f0e2(0xad)](this[_0x16f0e2(0xeb)],_0x5da161,_0x1b2045);this[_0x16f0e2(0x9d)][_0x16f0e2(0xe5)](_0x4eefaa,_0x13a9a1[_0x16f0e2(0x109)]);const {id:_0xaaafbe}=await _0x13a9a1[_0x16f0e2(0x96)]();this[_0x16f0e2(0x9d)][_0x16f0e2(0xe7)](_0x4eefaa),this[_0x16f0e2(0xf4)]({'type':_0x5b3169,'id':_0xaaafbe,'label':_0x1b2045?.[_0x16f0e2(0x106)]||_0x3b1139,'uiId':_0x4eefaa,'resourceId':_0x1b2045?.[_0x16f0e2(0xa7)]},!0x1);}catch(_0x100517){this[_0x16f0e2(0x9d)][_0x16f0e2(0xe7)](_0x4eefaa);if(!(_0x100517 instanceof _0x2d4364&&_0x100517[_0x16f0e2(0xe6)][_0x16f0e2(0xd8)](_0x16f0e2(0xb8)))){const _0x52e5be=_0x23da73[_0x16f0e2(0xca)](_0x100517[_0x16f0e2(0x94)])||_0x16f0e2(0xe2),_0x5b6058=new _0x2d4364(_0x52e5be,null,{'fileName':_0x3b1139,..._0x100517});_0x5b6058[_0x16f0e2(0xae)]=_0x100517[_0x16f0e2(0xae)],this[_0x16f0e2(0xf1)](_0x16f0e2(0xfc),{'error':_0x5b6058});}this[_0x16f0e2(0x110)](_0x4eefaa);}}));}finally{this[_0x1c4fd9(0xa9)](_0x53f461);}}[_0x4c43d5(0xc2)](_0x4b9e93){const _0x4dfe85=_0x4c43d5;if(this[_0x4dfe85(0xa1)]()||!this[_0x4dfe85(0xa6)][_0x4dfe85(0xbc)][_0x4dfe85(0x87)])return;const _0x229a88={'type':_0x4ce5ec[_0x4dfe85(0xb7)],'uiId':_0x4dfe85(0x93),'label':_0x4b9e93,'isReadOnly':this[_0x4dfe85(0x84)][_0x4dfe85(0xcb)](_0x4dfe85(0x93)),'hidden':this[_0x4dfe85(0x84)][_0x4dfe85(0xcb)](_0x4dfe85(0x93))};this[_0x4dfe85(0x10a)](_0x229a88);}async[_0x4c43d5(0xc6)](_0x4b5691,_0x1e93e7,_0x5590e1,_0xf42897){const _0x389c0b=_0x4c43d5,_0x3a8737=this[_0x389c0b(0xc9)][_0x389c0b(0xca)](_0x389c0b(0x93));if(_0x3a8737&&_0x4b5691){_0x3a8737[_0x389c0b(0xcc)]=_0xf42897?_0xf42897[_0x389c0b(0x9a)](_0x5f3eba=>({'start':_0x5f3eba[_0x389c0b(0xc4)],'end':_0x5f3eba[_0x389c0b(0xde)]})):[];try{if(_0x3a8737[_0x389c0b(0xb5)]===_0x1e93e7)return;const {id:_0x244ea0}=await this[_0x389c0b(0xbb)][_0x389c0b(0xd3)](this[_0x389c0b(0xeb)],_0x4b5691,{'version':_0x1e93e7,'sessionId':_0x5590e1})[_0x389c0b(0x96)]();_0x3a8737['id']=_0x244ea0,_0x3a8737[_0x389c0b(0x99)]=_0x4b5691,_0x3a8737[_0x389c0b(0xb5)]=_0x1e93e7,_0x3a8737[_0x389c0b(0xb6)]=_0x5590e1;}catch(_0x356a42){const _0xdf4eae=new _0x2d4364(_0x389c0b(0xef),null);_0xdf4eae[_0x389c0b(0xae)]=_0x356a42[_0x389c0b(0xae)],this[_0x389c0b(0xf1)](_0x389c0b(0xfc),{'error':_0xdf4eae});}}}[_0x4c43d5(0x7f)](_0x5637b7){const _0x24254a=_0x4c43d5;this[_0x24254a(0x10a)]({'type':_0x4ce5ec[_0x24254a(0xbd)],'label':_0x5637b7,'uiId':_0x24254a(0xcc),'content':_0x5637b7});}[_0x4c43d5(0xdb)](){const _0x8615d9=_0x4c43d5;this[_0x8615d9(0x110)](_0x8615d9(0xcc));}async[_0x4c43d5(0xee)](_0x1bb8b3,_0x490cfb){const _0x52ea71=_0x4c43d5,_0x54a305=_0x52ea71(0xc0)+_0x218167();this[_0x52ea71(0xc5)](_0x54a305);const _0x573dd8=_0x52ea71(0xc0)+_0x218167();try{this[_0x52ea71(0x10a)]({'type':_0x4ce5ec[_0x52ea71(0xe4)],'label':_0x490cfb?.[_0x52ea71(0x106)]||_0x1bb8b3,'uiId':_0x573dd8,'resourceId':_0x490cfb?.[_0x52ea71(0xa7)]},!0x0);const _0x5503ec=this[_0x52ea71(0xbb)][_0x52ea71(0xaa)](this[_0x52ea71(0xeb)],_0x1bb8b3,_0x490cfb);this[_0x52ea71(0x9d)][_0x52ea71(0xe5)](_0x573dd8,_0x5503ec[_0x52ea71(0x109)]);const {id:_0x4677f4}=await _0x5503ec[_0x52ea71(0x96)]();this[_0x52ea71(0x9d)][_0x52ea71(0xe7)](_0x573dd8),this[_0x52ea71(0xf4)]({'type':_0x4ce5ec[_0x52ea71(0xe4)],'id':_0x4677f4,'label':_0x490cfb?.[_0x52ea71(0x106)]||_0x1bb8b3,'uiId':_0x573dd8,'resourceId':_0x490cfb?.[_0x52ea71(0xa7)]},!0x1);}catch(_0x103c44){this[_0x52ea71(0x9d)][_0x52ea71(0xe7)](_0x573dd8),(_0x103c44[_0x52ea71(0xe6)][_0x52ea71(0xd8)](_0x52ea71(0xb8))||this[_0x52ea71(0xf1)](_0x52ea71(0xfc),{'error':new _0x2d4364(_0x52ea71(0xdf),this,{'url':_0x1bb8b3,'originalError':_0x103c44}),'url':_0x1bb8b3}),this[_0x52ea71(0x110)](_0x573dd8));}finally{this[_0x52ea71(0xa9)](_0x54a305);}}[_0x4c43d5(0x102)](_0x437f95){const _0x2c4f85=_0x4c43d5;_0x437f95['id']=_0x437f95['id']??_0x218167()[_0x2c4f85(0xb0)](0x0,0x15),this[_0x2c4f85(0xc9)][_0x2c4f85(0xe5)](_0x437f95[_0x2c4f85(0x92)],_0x437f95),this[_0x2c4f85(0xf1)](_0x2c4f85(0xf3),{'contextItem':_0x437f95,'isLoading':!0x1});}async[_0x4c43d5(0xf6)](_0x45261a,_0xb1d53d,_0x2c3e74){const _0x4f705d=_0x4c43d5,_0x1913e4=this[_0x4f705d(0xa6)][_0x4f705d(0xc3)][_0x4f705d(0xf0)](_0x196bd4=>_0x196bd4['id']===_0x45261a);if(!_0x1913e4)return this[_0x4f705d(0xf1)](_0x4f705d(0xfc),{'error':new _0x2d4364(_0x4f705d(0x101),this,{'sourceId':_0x45261a}),'sourceId':_0x45261a}),[];try{const _0xcfe154=(await _0x1913e4[_0x4f705d(0xe0)](_0xb1d53d))[_0x4f705d(0x9a)](_0x5464e9=>{const _0x4a640e=_0x4f705d,_0x3838d6=this[_0x4a640e(0xfe)](_0x5464e9['id']);return{..._0x5464e9,'isInContext':_0x3838d6};});return _0x1913e4[_0x4f705d(0xb1)]=_0xcfe154,this[_0x4f705d(0xf1)](_0x4f705d(0xf8),{'sourceId':_0x45261a,'source':_0x1913e4,'resources':_0xcfe154,'uid':_0x2c3e74}),_0xcfe154;}catch(_0x3b19b3){return this[_0x4f705d(0xf1)](_0x4f705d(0xfc),{'error':new _0x2d4364(_0x4f705d(0x90),this,{'sourceId':_0x45261a,'originalError':_0x3b19b3}),'sourceId':_0x45261a,'sourceLabel':_0x1913e4[_0x4f705d(0x106)]}),[];}}async[_0x4c43d5(0x98)](_0xa01334,_0x3c89da){const _0x29812b=_0x4c43d5;if(this[_0x29812b(0xfe)](_0x3c89da['id']))return;let _0x113f88=_0x3c89da[_0x29812b(0xd4)];if(!_0x113f88&&_0xa01334[_0x29812b(0xbe)])try{_0x113f88=await _0xa01334[_0x29812b(0xbe)](_0x3c89da['id']);}catch(_0x101558){return void this[_0x29812b(0xf1)](_0x29812b(0xfc),{'error':new _0x2d4364(_0x29812b(0xf2),this,{'resourceId':_0x3c89da['id'],'sourceId':_0xa01334['id'],'originalError':_0x101558}),'resourceId':_0x3c89da['id'],'sourceId':_0xa01334['id']});}if(_0x113f88)switch(_0x3c89da[_0x29812b(0xaf)]){case _0x4ce5ec[_0x29812b(0xe4)]:if(_0x29812b(0x80)!=typeof _0x113f88)return void this[_0x29812b(0xf1)](_0x29812b(0xfc),{'error':new _0x2d4364(_0x29812b(0xa2),this,{'resourceId':_0x3c89da['id'],'sourceId':_0xa01334['id'],'expectedType':_0x29812b(0x80),'actualType':typeof _0x113f88}),'resourceId':_0x3c89da['id'],'sourceId':_0xa01334['id']});await this[_0x29812b(0xee)](_0x113f88,{'label':_0x3c89da[_0x29812b(0x106)],'resourceId':_0x3c89da['id']});break;case _0x4ce5ec[_0x29812b(0xda)]:if(!(_0x113f88 instanceof File))return void this[_0x29812b(0xf1)](_0x29812b(0xfc),{'error':new _0x2d4364(_0x29812b(0xa2),this,{'resourceId':_0x3c89da['id'],'sourceId':_0xa01334['id'],'expectedType':_0x29812b(0xea),'actualType':typeof _0x113f88}),'resourceId':_0x3c89da['id'],'sourceId':_0xa01334['id']});await this[_0x29812b(0x83)]([_0x113f88],{'label':_0x3c89da[_0x29812b(0x106)],'resourceId':_0x3c89da['id']});break;case _0x4ce5ec[_0x29812b(0x9f)]:if(_0x29812b(0xed)!=typeof _0x113f88||!(_0x29812b(0x99)in _0x113f88)||!(_0x29812b(0xaf)in _0x113f88))return void this[_0x29812b(0xf1)](_0x29812b(0xfc),{'error':new _0x2d4364(_0x29812b(0xa2),this,{'resourceId':_0x3c89da['id'],'sourceId':_0xa01334['id'],'expectedType':_0x29812b(0x8a),'actualType':typeof _0x113f88}),'resourceId':_0x3c89da['id'],'sourceId':_0xa01334['id']});_0x113f88=AIChatContext[_0x29812b(0xf7)](_0x113f88,_0x3c89da[_0x29812b(0x106)]),await this[_0x29812b(0x83)]([_0x113f88],{'label':_0x3c89da[_0x29812b(0x106)],'resourceId':_0x3c89da['id']},_0x4ce5ec[_0x29812b(0x9f)]);break;case _0x4ce5ec[_0x29812b(0x10d)]:break;default:this[_0x29812b(0xf1)](_0x29812b(0xfc),{'error':new _0x2d4364(_0x29812b(0xff),this,{'resourceId':_0x3c89da['id'],'sourceId':_0xa01334['id'],'resourceType':_0x3c89da[_0x29812b(0xaf)]}),'resourceId':_0x3c89da['id'],'sourceId':_0xa01334['id']});}else this[_0x29812b(0xf1)](_0x29812b(0xfc),{'error':new _0x2d4364(_0x29812b(0x9b),this,{'resourceId':_0x3c89da['id'],'sourceId':_0xa01334['id']}),'resourceId':_0x3c89da['id'],'sourceId':_0xa01334['id']});}static[_0x4c43d5(0xf7)](_0xfc93ad,_0x423555){const _0x3839f3=_0x4c43d5;switch(_0xfc93ad[_0x3839f3(0xaf)]){case _0x5e2d38[_0x3839f3(0x86)]:return new File([_0xfc93ad[_0x3839f3(0x99)]],_0x423555,{'type':_0x3839f3(0xe1)});case _0x5e2d38[_0x3839f3(0x104)]:return new File([_0xfc93ad[_0x3839f3(0x99)]],_0x423555,{'type':_0x3839f3(0x105)});default:return new File([_0xfc93ad[_0x3839f3(0x99)]],_0x423555,{'type':_0x3839f3(0x10f)});}}static[_0x4c43d5(0xe9)](_0x217439){const _0x5a28eb=_0x4c43d5;switch(_0x217439[_0x5a28eb(0xaf)]){case _0x4ce5ec[_0x5a28eb(0xda)]:return{'type':_0x4ce5ec[_0x5a28eb(0xda)],'id':_0x217439['id']};case _0x4ce5ec[_0x5a28eb(0xe4)]:return{'type':_0x4ce5ec[_0x5a28eb(0xe4)],'id':_0x217439['id']};case _0x4ce5ec[_0x5a28eb(0xb7)]:return{'type':_0x4ce5ec[_0x5a28eb(0xb7)],'id':_0x217439['id'],..._0x217439[_0x5a28eb(0xcc)]?.[_0x5a28eb(0xcf)]&&{'selection':_0x217439[_0x5a28eb(0xcc)]}};case _0x4ce5ec[_0x5a28eb(0x9f)]:return{'type':_0x4ce5ec[_0x5a28eb(0xda)],'id':_0x217439['id']};case _0x4ce5ec[_0x5a28eb(0x10d)]:{const _0x578c97=_0x217439;return{'type':_0x4ce5ec[_0x5a28eb(0x10d)],'mcpServerName':_0x578c97[_0x5a28eb(0x88)],'toolName':_0x578c97[_0x5a28eb(0x108)],'data':_0x578c97[_0x5a28eb(0xd4)],'id':_0x578c97['id']};}default:return null;}}[_0x4c43d5(0x10a)](_0x4cbbbb,_0x19766f=!0x1){const _0x5a8f88=_0x4c43d5;if(this[_0x5a8f88(0xc9)][_0x5a8f88(0xe5)](_0x4cbbbb[_0x5a8f88(0x92)],_0x4cbbbb),_0x4cbbbb[_0x5a8f88(0xfb)]||this[_0x5a8f88(0xf1)](_0x5a8f88(0xf3),{'contextItem':_0x4cbbbb,'isLoading':_0x19766f}),_0x5a8f88(0x93)===_0x4cbbbb[_0x5a8f88(0x92)]&&this[_0x5a8f88(0xfd)](),_0x4cbbbb[_0x5a8f88(0xa7)]){const _0x30f046=this[_0x5a8f88(0xd5)](_0x4cbbbb[_0x5a8f88(0xa7)]);_0x30f046&&_0x30f046[_0x5a8f88(0x107)](_0x22f13f=>{const _0x32d47c=_0x5a8f88;this[_0x32d47c(0x10c)](_0x22f13f,_0x4cbbbb[_0x32d47c(0xa7)],!0x0);});}}[_0x4c43d5(0x110)](_0xe022d5){const _0x31d238=_0x4c43d5,_0x341224=this[_0x31d238(0xc9)][_0x31d238(0xca)](_0xe022d5),_0x12bc86=this[_0x31d238(0x9d)][_0x31d238(0xca)](_0xe022d5);if(_0x12bc86&&(_0x12bc86[_0x31d238(0x85)](),this[_0x31d238(0x9d)][_0x31d238(0xe7)](_0xe022d5)),_0x341224?.[_0x31d238(0xa7)]){const _0x5825c8=this[_0x31d238(0xd5)](_0x341224[_0x31d238(0xa7)]);_0x5825c8&&_0x5825c8[_0x31d238(0x107)](_0x24e11b=>{const _0x5773da=_0x31d238;this[_0x5773da(0x10c)](_0x24e11b,_0x341224[_0x5773da(0xa7)],!0x1);});}this[_0x31d238(0xc9)][_0x31d238(0xe7)](_0xe022d5),this[_0x31d238(0xf1)](_0x31d238(0x89),{'uiId':_0xe022d5,'type':_0x341224?.[_0x31d238(0xaf)]}),_0x31d238(0x93)===_0xe022d5&&this[_0x31d238(0xfd)]();}[_0x4c43d5(0xf4)](_0x11c6a5,_0x5effc9){const _0x14fb43=_0x4c43d5;if(this[_0x14fb43(0xc9)][_0x14fb43(0xcb)](_0x11c6a5[_0x14fb43(0x92)])&&(this[_0x14fb43(0xc9)][_0x14fb43(0xe5)](_0x11c6a5[_0x14fb43(0x92)],_0x11c6a5),this[_0x14fb43(0xf1)](_0x14fb43(0xba),{'contextItem':_0x11c6a5,'isLoading':_0x5effc9}),_0x11c6a5[_0x14fb43(0xa7)])){const _0x3ca417=this[_0x14fb43(0xd5)](_0x11c6a5[_0x14fb43(0xa7)]);_0x3ca417&&_0x3ca417[_0x14fb43(0x107)](_0x1ae8b7=>{const _0x1c2ece=_0x14fb43;this[_0x1c2ece(0x10c)](_0x1ae8b7,_0x11c6a5[_0x1c2ece(0xa7)],!0x0);});}}[_0x4c43d5(0xe3)](_0x3e74b4){const _0x257d0e=_0x4c43d5;this[_0x257d0e(0x84)][_0x257d0e(0xe5)](_0x3e74b4[_0x257d0e(0x92)],_0x3e74b4);}[_0x4c43d5(0xdc)](){const _0x423db5=_0x4c43d5;this[_0x423db5(0xa6)]={'document':{'enabled':!0x1!==this[_0x423db5(0x8e)]?.[_0x423db5(0xbc)]?.[_0x423db5(0x87)],'isHidden':!0x1},'urls':{'enabled':!0x1!==this[_0x423db5(0x8e)]?.[_0x423db5(0x81)]?.[_0x423db5(0x87)]},'files':{'enabled':!0x1!==this[_0x423db5(0x8e)]?.[_0x423db5(0xb3)]?.[_0x423db5(0x87)]},'sources':this[_0x423db5(0xf5)](),'customItems':this[_0x423db5(0x8e)]?.[_0x423db5(0x9e)]?.[_0x423db5(0x9a)](_0x150812=>({..._0x150812,'enabled':!0x0}))??[]},this[_0x423db5(0xf1)](_0x423db5(0x8c),{'options':this[_0x423db5(0xa6)]});}[_0x4c43d5(0xf5)](){const _0x47716a=_0x4c43d5;return this[_0x47716a(0x8e)]?.[_0x47716a(0xc3)]?.[_0x47716a(0x9a)](_0x2b817c=>({..._0x2b817c,'resources':[]}))??[];}[_0x4c43d5(0xfd)](){const _0x57c1b7=_0x4c43d5,_0x5c1116=this[_0x57c1b7(0xa1)]()||this[_0x57c1b7(0xb4)]();this[_0x57c1b7(0xa6)][_0x57c1b7(0xbc)][_0x57c1b7(0xd7)]=_0x5c1116,this[_0x57c1b7(0xf1)](_0x57c1b7(0x8c),{'options':this[_0x57c1b7(0xa6)]});}[_0x4c43d5(0xfe)](_0x371925){const _0x21b9b7=_0x4c43d5;for(const _0x3eea48 of this[_0x21b9b7(0xc9)][_0x21b9b7(0x91)]())if(_0x3eea48[_0x21b9b7(0xa7)]===_0x371925)return!0x0;for(const _0xd60bb7 of this[_0x21b9b7(0x84)][_0x21b9b7(0x91)]())if(_0xd60bb7[_0x21b9b7(0xa7)]===_0x371925)return!0x0;return!0x1;}[_0x4c43d5(0xd5)](_0x5ba5e4){const _0x58e76c=_0x4c43d5,_0x47cc99=[];for(const _0x55bf3c of this[_0x58e76c(0xa6)][_0x58e76c(0xc3)]){_0x55bf3c[_0x58e76c(0xb1)][_0x58e76c(0xf0)](_0x2ffc05=>_0x2ffc05['id']===_0x5ba5e4)&&_0x47cc99[_0x58e76c(0xd1)](_0x55bf3c['id']);}return 0x0===_0x47cc99[_0x58e76c(0xcf)]?null:_0x47cc99;}[_0x4c43d5(0x10c)](_0x330bb4,_0x21e5f7,_0x4c2c2a){const _0x14639d=_0x4c43d5,_0xb06b83=this[_0x14639d(0xa6)][_0x14639d(0xc3)][_0x14639d(0xf0)](_0x4d2803=>_0x4d2803['id']===_0x330bb4);if(!_0xb06b83)return;const _0x22fa9e=_0xb06b83[_0x14639d(0xb1)][_0x14639d(0xf0)](_0x554b5b=>_0x554b5b['id']===_0x21e5f7);_0x22fa9e&&(_0x22fa9e[_0x14639d(0xec)]=_0x4c2c2a,this[_0x14639d(0xf1)](_0x14639d(0x82),{'sourceId':_0x330bb4,'resourceId':_0x21e5f7,'isInContext':_0x4c2c2a}));}[_0x4c43d5(0xc5)](_0x19a851){const _0x506a42=_0x4c43d5;this[_0x506a42(0xc7)][_0x506a42(0xe5)](_0x19a851,!0x0),this[_0x506a42(0xc7)][_0x506a42(0xdd)]&&this[_0x506a42(0xf1)](_0x506a42(0xa8),{'isUploadInProgress':!0x0});}[_0x4c43d5(0xa9)](_0x264bf3){const _0x452c6b=_0x4c43d5;this[_0x452c6b(0xc7)][_0x452c6b(0xe7)](_0x264bf3),0x0===this[_0x452c6b(0xc7)][_0x452c6b(0xdd)]&&this[_0x452c6b(0xf1)](_0x452c6b(0xa8),{'isUploadInProgress':!0x1});}}
23
+ const _0x548e69=_0x456c;(function(_0x574534,_0x9a8fed){const _0x4de43b=_0x456c,_0x50d322=_0x574534();while(!![]){try{const _0x209cf4=parseInt(_0x4de43b(0x11d))/0x1*(parseInt(_0x4de43b(0xe0))/0x2)+parseInt(_0x4de43b(0x129))/0x3*(-parseInt(_0x4de43b(0xf2))/0x4)+parseInt(_0x4de43b(0x105))/0x5*(-parseInt(_0x4de43b(0x132))/0x6)+parseInt(_0x4de43b(0x149))/0x7+parseInt(_0x4de43b(0x135))/0x8+parseInt(_0x4de43b(0x14c))/0x9+parseInt(_0x4de43b(0x150))/0xa*(-parseInt(_0x4de43b(0xfa))/0xb);if(_0x209cf4===_0x9a8fed)break;else _0x50d322['push'](_0x50d322['shift']());}catch(_0x5e408a){_0x50d322['push'](_0x50d322['shift']());}}}(_0x5e6a,0x36127));function _0x5e6a(){const _0x8232c7=['_removeContextItem','FILE','resources','filter','getResources','end','set','44qSWLeW','delete','_isResourceInContext','uploadUrl','contextItemRemoved','isSelectionInContext','code','ai-chat-file-upload-failed','URL','contextItemLoadingEnded','addFilesToContext','45JGtvcv','map','object\x20with\x20content\x20and\x20type\x20properties','object','hidden','_findSourceIdsByResourceId','ai-chat-source-not-found','error','start','clearPendingContextItems','mcpServerName','addContextOptionsChanged','isCurrentDocumentInConversation','mapContextItemsToRequestData','_pendingContextItems','addCurrentDocumentToContext','_ongoingUploadOperations','urls','removeSelectionFromContext','ai-request-aborted','fire','contextSent','uploadDocument','ai-chat-url-upload-failed','2QJrbdF','getData','removeFromContext','addToConversationContext','addToolItemToContext','isInContext','from','files','data','resourceId','_config','addSelectionToContext','3cvtnMm','_toggleAddCurrentDocumentOptionVisibility','_addContextOptionsState','uiId','_connector','getDocument','push','has','toolName','65886woGbJp','_getCustomSourcesInitialState','TOOL','3470152Zrgxlm','size','find','isReadOnly','url-','_updateResourceInContextState','updateCurrentDocument','abort','string','document','TEXT','_convertTextResourceToFile','ai-chat-resource-load-failed','Current\x20document','length','loadSourceResources','resourceStateChanged','selection','ai-chat-resource-no-data','type','68432UwyeSj','stack','MARKDOWN','1519740tAvwou','label','name','sourceResourcesLoaded','1471630CUJGwu','url','ai-chat-document-upload-failed','_mapContextItemToRequestData','text/markdown','_setAddContextOptionsDefaultState','_startUploadOperation','values','_addContextItem','isHidden','substring','content','_ownerId','uploadProgressChanged','enabled','addUrlToContext','_finishUploadOperation','forEach','text/plain','attributes','version','fetchDocument','_finishContextItemLoading','HTML','_ongoingUploads','_addToConversationContextItem','isCurrentDocumentInContext','ai-chat-source-resources-load-failed','uploadFile','File','populateFromMessage','sessionId','init','getPendingContextItems','addResourceToContext','SELECTION','ai-chat-context-unsupported-type','DOCUMENT','425202IeSXGO','message','text/html','getId','abortController','customItems','getSentContextItems','startsWith','_createContextItemFromContent','ai-chat-context-invalid-data','all','_conversationContextItems','contextItemAdded','file-','get','files-','sources','current-document','514588ZchCVD'];_0x5e6a=function(){return _0x8232c7;};return _0x5e6a();}import{CKEditorError as _0xfc3ea9,ObservableMixin as _0x2a0d4f,uid as _0x31d1d9}from'ckeditor5/src/utils.js';import{AIContextItemType as _0x59cd01,AIContextTextResourceType as _0x26f8d7}from'../../aicore/model/aicontext.js';function _0x456c(_0x407709,_0x59912f){const _0x5e6af2=_0x5e6a();return _0x456c=function(_0x456ce7,_0x377cf5){_0x456ce7=_0x456ce7-0xd8;let _0x6d376e=_0x5e6af2[_0x456ce7];return _0x6d376e;},_0x456c(_0x407709,_0x59912f);}import{escape as _0xb6ef75}from'es-toolkit/compat';import{errorsMap as _0x249939}from'../../errorsmap.js';export const AI_CONTEXT_MODEL_EVENT_NAMES=[_0x548e69(0xec),_0x548e69(0xfe),_0x548e69(0x103),_0x548e69(0x11a),_0x548e69(0x10c),_0x548e69(0x110),_0x548e69(0x14f),_0x548e69(0x145),_0x548e69(0x15d)];export class AIChatContext extends _0x2a0d4f(){[_0x548e69(0x12d)];[_0x548e69(0x127)];[_0x548e69(0x15c)];constructor({connector:_0x357a6b,config:_0x5ae51b,ownerId:_0x533615}){const _0xf4a87d=_0x548e69;super(),this[_0xf4a87d(0x12d)]=_0x357a6b,this[_0xf4a87d(0x127)]=_0x5ae51b,this[_0xf4a87d(0x15c)]=_0x533615;}[_0x548e69(0xda)](){const _0x4efb05=_0x548e69;this[_0x4efb05(0x113)]=new Map(),this[_0x4efb05(0xeb)]=new Map(),this[_0x4efb05(0x168)]=new Map(),this[_0x4efb05(0x115)]=new Map(),this[_0x4efb05(0x155)]();}[_0x548e69(0xdb)](){const _0x2e982a=_0x548e69;return this[_0x2e982a(0x113)];}async[_0x548e69(0xd8)](_0x3c3b4a){const _0x52f0b7=_0x548e69,_0x5c6491=await this[_0x52f0b7(0xe8)](_0x3c3b4a);return this[_0x52f0b7(0x169)](_0x5c6491),_0x52f0b7(0xf1)===_0x5c6491[_0x52f0b7(0x12c)]&&this[_0x52f0b7(0x12a)](),_0x5c6491;}async[_0x548e69(0xe8)](_0x55d98a){const _0x3a16ba=_0x548e69;if(_0x55d98a[_0x3a16ba(0x148)]===_0x59cd01[_0x3a16ba(0xdf)]){const _0x161e26=await this[_0x3a16ba(0x12d)][_0x3a16ba(0x165)](this[_0x3a16ba(0x15c)],_0x55d98a['id'])[_0x3a16ba(0x12e)]();return{'id':_0x3a16ba(0xf1),'uiId':_0x3a16ba(0xf1),'label':_0x3a16ba(0x142),'type':_0x55d98a[_0x3a16ba(0x148)],'content':_0x161e26[_0x3a16ba(0x15b)],'hidden':this[_0x3a16ba(0xeb)][_0x3a16ba(0x130)](_0x3a16ba(0xf1)),'version':_0x161e26[_0x3a16ba(0x163)]?.[_0x3a16ba(0x164)],'sessionId':_0x161e26[_0x3a16ba(0x163)]?.[_0x3a16ba(0xd9)]};}if(_0x55d98a[_0x3a16ba(0x148)]===_0x59cd01[_0x3a16ba(0x134)])return{'id':_0x55d98a['id'],'uiId':_0x55d98a['id'],'label':_0x55d98a[_0x3a16ba(0x125)]?.[_0x3a16ba(0x14d)]||_0x55d98a['id'],'type':_0x59cd01[_0x3a16ba(0x134)],'mcpServerName':_0x55d98a[_0x3a16ba(0x10f)],'toolName':_0x55d98a[_0x3a16ba(0x131)],'data':_0x55d98a[_0x3a16ba(0x125)]||{}};return{'id':_0x55d98a['id'],'uiId':_0x55d98a['id'],'label':_0x55d98a[_0x3a16ba(0x163)]?.[_0x3a16ba(0x14d)]||_0x55d98a[_0x3a16ba(0x14e)]||_0x55d98a[_0x3a16ba(0x151)]||_0x55d98a['id'],'type':_0x55d98a[_0x3a16ba(0x148)],..._0x55d98a?.[_0x3a16ba(0x163)]?.[_0x3a16ba(0x126)]?{'resourceId':_0x55d98a[_0x3a16ba(0x163)]?.[_0x3a16ba(0x126)]}:{}};}[_0x548e69(0xe6)](){const _0xcadaaa=_0x548e69;return new Map(this[_0xcadaaa(0xeb)]);}[_0x548e69(0x11f)](_0x53a371){const _0xf47865=_0x548e69,_0x24bea8=this[_0xf47865(0x113)][_0xf47865(0xee)](_0x53a371);_0x24bea8?.[_0xf47865(0x138)]||this[_0xf47865(0xf3)](_0x53a371);}[_0x548e69(0x10e)](){const _0x59780c=_0x548e69;if(0x0===this[_0x59780c(0x113)][_0x59780c(0x136)])return;for(const _0x1337e1 of this[_0x59780c(0x113)][_0x59780c(0x157)]())this[_0x59780c(0xf3)](_0x1337e1[_0x59780c(0x12c)]);const _0x191019=this[_0x59780c(0xeb)][_0x59780c(0xee)](_0x59780c(0xf1))||this[_0x59780c(0x113)][_0x59780c(0xee)](_0x59780c(0xf1));_0x191019&&this[_0x59780c(0x158)]({..._0x191019,'isReadOnly':!0x0,'hidden':!0x0});}[_0x548e69(0x120)](_0x3429bd){const _0x1cf2b8=_0x548e69;for(const _0x4b87e4 of _0x3429bd[_0x1cf2b8(0x157)]())this[_0x1cf2b8(0x169)](_0x4b87e4);this[_0x1cf2b8(0x10e)](),this[_0x1cf2b8(0x119)](_0x1cf2b8(0x11a),{'contextItems':Array[_0x1cf2b8(0x123)](this[_0x1cf2b8(0xe6)]()[_0x1cf2b8(0x157)]())});}[_0x548e69(0x16a)](){const _0x189f33=_0x548e69;return this[_0x189f33(0x113)][_0x189f33(0x130)](_0x189f33(0xf1));}[_0x548e69(0xff)](){const _0xea5d13=_0x548e69;return this[_0xea5d13(0x113)][_0xea5d13(0x130)](_0xea5d13(0x146));}[_0x548e69(0x111)](){const _0x28be05=_0x548e69;return this[_0x28be05(0xeb)][_0x28be05(0x130)](_0x28be05(0xf1));}static[_0x548e69(0x112)](_0x8e2f19){const _0x224340=_0x548e69;return Array[_0x224340(0x123)](_0x8e2f19[_0x224340(0x157)]())[_0x224340(0x106)](_0x765ef1=>this[_0x224340(0x153)](_0x765ef1))[_0x224340(0xf6)](_0x159a7d=>null!==_0x159a7d);}async[_0x548e69(0x104)](_0x2b1a13,_0xfcbf8a,_0x5e6d00=_0x59cd01[_0x548e69(0xf4)]){const _0x363caa=_0x548e69,_0x2fbe51=_0x363caa(0xef)+_0x31d1d9();this[_0x363caa(0x156)](_0x2fbe51);try{await Promise[_0x363caa(0xea)](_0x2b1a13[_0x363caa(0x106)](async _0x526f0c=>{const _0x3ddb46=_0x363caa,_0x13c63d=_0x3ddb46(0xed)+_0x31d1d9(),_0x12602e=_0xb6ef75(_0x526f0c[_0x3ddb46(0x14e)]);try{this[_0x3ddb46(0x158)]({'type':_0x5e6d00,'label':_0xfcbf8a?.[_0x3ddb46(0x14d)]||_0x12602e,'uiId':_0x13c63d,'resourceId':_0xfcbf8a?.[_0x3ddb46(0x126)]},!0x0);const _0xf9c5e7=this[_0x3ddb46(0x12d)][_0x3ddb46(0x16c)](this[_0x3ddb46(0x15c)],_0x526f0c,_0xfcbf8a);this[_0x3ddb46(0x168)][_0x3ddb46(0xf9)](_0x13c63d,_0xf9c5e7[_0x3ddb46(0xe4)]);const {id:_0x10e103}=await _0xf9c5e7[_0x3ddb46(0xe3)]();this[_0x3ddb46(0x168)][_0x3ddb46(0xfb)](_0x13c63d),this[_0x3ddb46(0x166)]({'type':_0x5e6d00,'id':_0x10e103,'label':_0xfcbf8a?.[_0x3ddb46(0x14d)]||_0x12602e,'uiId':_0x13c63d,'resourceId':_0xfcbf8a?.[_0x3ddb46(0x126)]},!0x1);}catch(_0xdd805c){this[_0x3ddb46(0x168)][_0x3ddb46(0xfb)](_0x13c63d);if(!(_0xdd805c instanceof _0xfc3ea9&&_0xdd805c[_0x3ddb46(0xe1)][_0x3ddb46(0xe7)](_0x3ddb46(0x118)))){const _0x2daace=_0x249939[_0x3ddb46(0xee)](_0xdd805c[_0x3ddb46(0x100)])||_0x3ddb46(0x101),_0x38fdab=new _0xfc3ea9(_0x2daace,null,{'fileName':_0x12602e,..._0xdd805c});_0x38fdab[_0x3ddb46(0x14a)]=_0xdd805c[_0x3ddb46(0x14a)],this[_0x3ddb46(0x119)](_0x3ddb46(0x10c),{'error':_0x38fdab});}this[_0x3ddb46(0xf3)](_0x13c63d);}}));}finally{this[_0x363caa(0x160)](_0x2fbe51);}}[_0x548e69(0x114)](_0x5ee54d){const _0x2fcc70=_0x548e69;if(this[_0x2fcc70(0x16a)]()||!this[_0x2fcc70(0x12b)][_0x2fcc70(0x13e)][_0x2fcc70(0x15e)])return;const _0x3db494={'type':_0x59cd01[_0x2fcc70(0xdf)],'uiId':_0x2fcc70(0xf1),'label':_0x5ee54d,'isReadOnly':this[_0x2fcc70(0xeb)][_0x2fcc70(0x130)](_0x2fcc70(0xf1)),'hidden':this[_0x2fcc70(0xeb)][_0x2fcc70(0x130)](_0x2fcc70(0xf1))};this[_0x2fcc70(0x158)](_0x3db494);}async[_0x548e69(0x13b)](_0x36e592,_0x38f680,_0x3d1881,_0xd3ea5c){const _0x30db3d=_0x548e69,_0x24ee13=this[_0x30db3d(0x113)][_0x30db3d(0xee)](_0x30db3d(0xf1));if(_0x24ee13&&_0x36e592){_0x24ee13[_0x30db3d(0x146)]=_0xd3ea5c?_0xd3ea5c[_0x30db3d(0x106)](_0x19823c=>({'start':_0x19823c[_0x30db3d(0x10d)],'end':_0x19823c[_0x30db3d(0xf8)]})):[];try{if(_0x24ee13[_0x30db3d(0x164)]===_0x38f680)return;const {id:_0xfffe32}=await this[_0x30db3d(0x12d)][_0x30db3d(0x11b)](this[_0x30db3d(0x15c)],_0x36e592,{'version':_0x38f680,'sessionId':_0x3d1881})[_0x30db3d(0xe3)]();_0x24ee13['id']=_0xfffe32,_0x24ee13[_0x30db3d(0x15b)]=_0x36e592,_0x24ee13[_0x30db3d(0x164)]=_0x38f680,_0x24ee13[_0x30db3d(0xd9)]=_0x3d1881;}catch(_0x3611e8){const _0x50f6a7=new _0xfc3ea9(_0x30db3d(0x152),null);_0x50f6a7[_0x30db3d(0x14a)]=_0x3611e8[_0x30db3d(0x14a)],this[_0x30db3d(0x119)](_0x30db3d(0x10c),{'error':_0x50f6a7});}}}[_0x548e69(0x128)](_0x10ed0b){const _0x51487c=_0x548e69;this[_0x51487c(0x158)]({'type':_0x59cd01[_0x51487c(0xdd)],'label':_0x10ed0b,'uiId':_0x51487c(0x146),'content':_0x10ed0b});}[_0x548e69(0x117)](){const _0x1ad9e8=_0x548e69;this[_0x1ad9e8(0xf3)](_0x1ad9e8(0x146));}async[_0x548e69(0x15f)](_0x278e3d,_0x427513){const _0x3ac466=_0x548e69,_0x206a93=_0x3ac466(0x139)+_0x31d1d9();this[_0x3ac466(0x156)](_0x206a93);const _0x5e687b=_0x3ac466(0x139)+_0x31d1d9();try{this[_0x3ac466(0x158)]({'type':_0x59cd01[_0x3ac466(0x102)],'label':_0x427513?.[_0x3ac466(0x14d)]||_0x278e3d,'uiId':_0x5e687b,'resourceId':_0x427513?.[_0x3ac466(0x126)]},!0x0);const _0x3be5d6=this[_0x3ac466(0x12d)][_0x3ac466(0xfd)](this[_0x3ac466(0x15c)],_0x278e3d,_0x427513);this[_0x3ac466(0x168)][_0x3ac466(0xf9)](_0x5e687b,_0x3be5d6[_0x3ac466(0xe4)]);const {id:_0x3636fa}=await _0x3be5d6[_0x3ac466(0xe3)]();this[_0x3ac466(0x168)][_0x3ac466(0xfb)](_0x5e687b),this[_0x3ac466(0x166)]({'type':_0x59cd01[_0x3ac466(0x102)],'id':_0x3636fa,'label':_0x427513?.[_0x3ac466(0x14d)]||_0x278e3d,'uiId':_0x5e687b,'resourceId':_0x427513?.[_0x3ac466(0x126)]},!0x1);}catch(_0x4ebfe){this[_0x3ac466(0x168)][_0x3ac466(0xfb)](_0x5e687b),(_0x4ebfe[_0x3ac466(0xe1)][_0x3ac466(0xe7)](_0x3ac466(0x118))||this[_0x3ac466(0x119)](_0x3ac466(0x10c),{'error':new _0xfc3ea9(_0x3ac466(0x11c),this,{'url':_0x278e3d,'originalError':_0x4ebfe}),'url':_0x278e3d}),this[_0x3ac466(0xf3)](_0x5e687b));}finally{this[_0x3ac466(0x160)](_0x206a93);}}[_0x548e69(0x121)](_0x2de14d){const _0x167ded=_0x548e69;_0x2de14d['id']=_0x2de14d['id']??_0x31d1d9()[_0x167ded(0x15a)](0x0,0x15),this[_0x167ded(0x113)][_0x167ded(0xf9)](_0x2de14d[_0x167ded(0x12c)],_0x2de14d),this[_0x167ded(0x119)](_0x167ded(0xec),{'contextItem':_0x2de14d,'isLoading':!0x1});}async[_0x548e69(0x144)](_0x5b14ac,_0x14c1a7,_0x34dda9){const _0x4909e6=_0x548e69,_0x1ab1ba=this[_0x4909e6(0x12b)][_0x4909e6(0xf0)][_0x4909e6(0x137)](_0x22b2a4=>_0x22b2a4['id']===_0x5b14ac);if(!_0x1ab1ba)return this[_0x4909e6(0x119)](_0x4909e6(0x10c),{'error':new _0xfc3ea9(_0x4909e6(0x10b),this,{'sourceId':_0x5b14ac}),'sourceId':_0x5b14ac}),[];try{const _0x4b08ab=(await _0x1ab1ba[_0x4909e6(0xf7)](_0x14c1a7))[_0x4909e6(0x106)](_0x4c008=>{const _0x4199ca=_0x4909e6,_0x342021=this[_0x4199ca(0xfc)](_0x4c008['id']);return{..._0x4c008,'isInContext':_0x342021};});return _0x1ab1ba[_0x4909e6(0xf5)]=_0x4b08ab,this[_0x4909e6(0x119)](_0x4909e6(0x14f),{'sourceId':_0x5b14ac,'source':_0x1ab1ba,'resources':_0x4b08ab,'uid':_0x34dda9}),_0x4b08ab;}catch(_0x45c2e9){return this[_0x4909e6(0x119)](_0x4909e6(0x10c),{'error':new _0xfc3ea9(_0x4909e6(0x16b),this,{'sourceId':_0x5b14ac,'originalError':_0x45c2e9}),'sourceId':_0x5b14ac,'sourceLabel':_0x1ab1ba[_0x4909e6(0x14d)]}),[];}}async[_0x548e69(0xdc)](_0x451f57,_0x476efe){const _0x1df5db=_0x548e69;if(this[_0x1df5db(0xfc)](_0x476efe['id']))return;let _0x40448f=_0x476efe[_0x1df5db(0x125)];if(!_0x40448f&&_0x451f57[_0x1df5db(0x11e)])try{_0x40448f=await _0x451f57[_0x1df5db(0x11e)](_0x476efe['id']);}catch(_0x1c258e){return void this[_0x1df5db(0x119)](_0x1df5db(0x10c),{'error':new _0xfc3ea9(_0x1df5db(0x141),this,{'resourceId':_0x476efe['id'],'sourceId':_0x451f57['id'],'originalError':_0x1c258e}),'resourceId':_0x476efe['id'],'sourceId':_0x451f57['id']});}if(_0x40448f)switch(_0x476efe[_0x1df5db(0x148)]){case _0x59cd01[_0x1df5db(0x102)]:if(_0x1df5db(0x13d)!=typeof _0x40448f)return void this[_0x1df5db(0x119)](_0x1df5db(0x10c),{'error':new _0xfc3ea9(_0x1df5db(0xe9),this,{'resourceId':_0x476efe['id'],'sourceId':_0x451f57['id'],'expectedType':_0x1df5db(0x13d),'actualType':typeof _0x40448f}),'resourceId':_0x476efe['id'],'sourceId':_0x451f57['id']});await this[_0x1df5db(0x15f)](_0x40448f,{'label':_0x476efe[_0x1df5db(0x14d)],'resourceId':_0x476efe['id']});break;case _0x59cd01[_0x1df5db(0xf4)]:if(!(_0x40448f instanceof File))return void this[_0x1df5db(0x119)](_0x1df5db(0x10c),{'error':new _0xfc3ea9(_0x1df5db(0xe9),this,{'resourceId':_0x476efe['id'],'sourceId':_0x451f57['id'],'expectedType':_0x1df5db(0x16d),'actualType':typeof _0x40448f}),'resourceId':_0x476efe['id'],'sourceId':_0x451f57['id']});await this[_0x1df5db(0x104)]([_0x40448f],{'label':_0x476efe[_0x1df5db(0x14d)],'resourceId':_0x476efe['id']});break;case _0x59cd01[_0x1df5db(0x13f)]:if(_0x1df5db(0x108)!=typeof _0x40448f||!(_0x1df5db(0x15b)in _0x40448f)||!(_0x1df5db(0x148)in _0x40448f))return void this[_0x1df5db(0x119)](_0x1df5db(0x10c),{'error':new _0xfc3ea9(_0x1df5db(0xe9),this,{'resourceId':_0x476efe['id'],'sourceId':_0x451f57['id'],'expectedType':_0x1df5db(0x107),'actualType':typeof _0x40448f}),'resourceId':_0x476efe['id'],'sourceId':_0x451f57['id']});_0x40448f=AIChatContext[_0x1df5db(0x140)](_0x40448f,_0x476efe[_0x1df5db(0x14d)]),await this[_0x1df5db(0x104)]([_0x40448f],{'label':_0x476efe[_0x1df5db(0x14d)],'resourceId':_0x476efe['id']},_0x59cd01[_0x1df5db(0x13f)]);break;case _0x59cd01[_0x1df5db(0x134)]:break;default:this[_0x1df5db(0x119)](_0x1df5db(0x10c),{'error':new _0xfc3ea9(_0x1df5db(0xde),this,{'resourceId':_0x476efe['id'],'sourceId':_0x451f57['id'],'resourceType':_0x476efe[_0x1df5db(0x148)]}),'resourceId':_0x476efe['id'],'sourceId':_0x451f57['id']});}else this[_0x1df5db(0x119)](_0x1df5db(0x10c),{'error':new _0xfc3ea9(_0x1df5db(0x147),this,{'resourceId':_0x476efe['id'],'sourceId':_0x451f57['id']}),'resourceId':_0x476efe['id'],'sourceId':_0x451f57['id']});}static[_0x548e69(0x140)](_0x2c2dba,_0x53bd75){const _0x445834=_0x548e69;switch(_0x2c2dba[_0x445834(0x148)]){case _0x26f8d7[_0x445834(0x14b)]:return new File([_0x2c2dba[_0x445834(0x15b)]],_0x53bd75,{'type':_0x445834(0x154)});case _0x26f8d7[_0x445834(0x167)]:return new File([_0x2c2dba[_0x445834(0x15b)]],_0x53bd75,{'type':_0x445834(0xe2)});default:return new File([_0x2c2dba[_0x445834(0x15b)]],_0x53bd75,{'type':_0x445834(0x162)});}}static[_0x548e69(0x153)](_0x23e5c2){const _0x334c32=_0x548e69;switch(_0x23e5c2[_0x334c32(0x148)]){case _0x59cd01[_0x334c32(0xf4)]:return{'type':_0x59cd01[_0x334c32(0xf4)],'id':_0x23e5c2['id']};case _0x59cd01[_0x334c32(0x102)]:return{'type':_0x59cd01[_0x334c32(0x102)],'id':_0x23e5c2['id']};case _0x59cd01[_0x334c32(0xdf)]:return{'type':_0x59cd01[_0x334c32(0xdf)],'id':_0x23e5c2['id'],..._0x23e5c2[_0x334c32(0x146)]?.[_0x334c32(0x143)]&&{'selection':_0x23e5c2[_0x334c32(0x146)]}};case _0x59cd01[_0x334c32(0x13f)]:return{'type':_0x59cd01[_0x334c32(0xf4)],'id':_0x23e5c2['id']};case _0x59cd01[_0x334c32(0x134)]:{const _0x1a856c=_0x23e5c2;return{'type':_0x59cd01[_0x334c32(0x134)],'mcpServerName':_0x1a856c[_0x334c32(0x10f)],'toolName':_0x1a856c[_0x334c32(0x131)],'data':_0x1a856c[_0x334c32(0x125)],'id':_0x1a856c['id']};}default:return null;}}[_0x548e69(0x158)](_0xd6c476,_0x275467=!0x1){const _0x2ae040=_0x548e69;if(this[_0x2ae040(0x113)][_0x2ae040(0xf9)](_0xd6c476[_0x2ae040(0x12c)],_0xd6c476),_0xd6c476[_0x2ae040(0x109)]||this[_0x2ae040(0x119)](_0x2ae040(0xec),{'contextItem':_0xd6c476,'isLoading':_0x275467}),_0x2ae040(0xf1)===_0xd6c476[_0x2ae040(0x12c)]&&this[_0x2ae040(0x12a)](),_0xd6c476[_0x2ae040(0x126)]){const _0x537aeb=this[_0x2ae040(0x10a)](_0xd6c476[_0x2ae040(0x126)]);_0x537aeb&&_0x537aeb[_0x2ae040(0x161)](_0x3b5dfd=>{const _0x4ee846=_0x2ae040;this[_0x4ee846(0x13a)](_0x3b5dfd,_0xd6c476[_0x4ee846(0x126)],!0x0);});}}[_0x548e69(0xf3)](_0x40d3de){const _0xfdab40=_0x548e69,_0x5721c3=this[_0xfdab40(0x113)][_0xfdab40(0xee)](_0x40d3de),_0x59e2b6=this[_0xfdab40(0x168)][_0xfdab40(0xee)](_0x40d3de);if(_0x59e2b6&&(_0x59e2b6[_0xfdab40(0x13c)](),this[_0xfdab40(0x168)][_0xfdab40(0xfb)](_0x40d3de)),_0x5721c3?.[_0xfdab40(0x126)]){const _0x56c75d=this[_0xfdab40(0x10a)](_0x5721c3[_0xfdab40(0x126)]);_0x56c75d&&_0x56c75d[_0xfdab40(0x161)](_0x19a4a6=>{const _0x3f1133=_0xfdab40;this[_0x3f1133(0x13a)](_0x19a4a6,_0x5721c3[_0x3f1133(0x126)],!0x1);});}this[_0xfdab40(0x113)][_0xfdab40(0xfb)](_0x40d3de),this[_0xfdab40(0x119)](_0xfdab40(0xfe),{'uiId':_0x40d3de,'type':_0x5721c3?.[_0xfdab40(0x148)]}),_0xfdab40(0xf1)===_0x40d3de&&this[_0xfdab40(0x12a)]();}[_0x548e69(0x166)](_0x392082,_0x4461f7){const _0x7d2a55=_0x548e69;if(this[_0x7d2a55(0x113)][_0x7d2a55(0x130)](_0x392082[_0x7d2a55(0x12c)])&&(this[_0x7d2a55(0x113)][_0x7d2a55(0xf9)](_0x392082[_0x7d2a55(0x12c)],_0x392082),this[_0x7d2a55(0x119)](_0x7d2a55(0x103),{'contextItem':_0x392082,'isLoading':_0x4461f7}),_0x392082[_0x7d2a55(0x126)])){const _0x1f7406=this[_0x7d2a55(0x10a)](_0x392082[_0x7d2a55(0x126)]);_0x1f7406&&_0x1f7406[_0x7d2a55(0x161)](_0x15151a=>{const _0x1dbe8a=_0x7d2a55;this[_0x1dbe8a(0x13a)](_0x15151a,_0x392082[_0x1dbe8a(0x126)],!0x0);});}}[_0x548e69(0x169)](_0x158528){const _0x51c6b1=_0x548e69;this[_0x51c6b1(0xeb)][_0x51c6b1(0xf9)](_0x158528[_0x51c6b1(0x12c)],_0x158528);}[_0x548e69(0x155)](){const _0xf47c06=_0x548e69;this[_0xf47c06(0x12b)]={'document':{'enabled':!0x1!==this[_0xf47c06(0x127)]?.[_0xf47c06(0x13e)]?.[_0xf47c06(0x15e)],'isHidden':!0x1},'urls':{'enabled':!0x1!==this[_0xf47c06(0x127)]?.[_0xf47c06(0x116)]?.[_0xf47c06(0x15e)]},'files':{'enabled':!0x1!==this[_0xf47c06(0x127)]?.[_0xf47c06(0x124)]?.[_0xf47c06(0x15e)]},'sources':this[_0xf47c06(0x133)](),'customItems':this[_0xf47c06(0x127)]?.[_0xf47c06(0xe5)]?.[_0xf47c06(0x106)](_0x59fc00=>({..._0x59fc00,'enabled':!0x0}))??[]},this[_0xf47c06(0x119)](_0xf47c06(0x110),{'options':this[_0xf47c06(0x12b)]});}[_0x548e69(0x133)](){const _0x25f565=_0x548e69;return this[_0x25f565(0x127)]?.[_0x25f565(0xf0)]?.[_0x25f565(0x106)](_0x208836=>({..._0x208836,'resources':[]}))??[];}[_0x548e69(0x12a)](){const _0x24eb7f=_0x548e69,_0x5d6844=this[_0x24eb7f(0x16a)]()||this[_0x24eb7f(0x111)]();this[_0x24eb7f(0x12b)][_0x24eb7f(0x13e)][_0x24eb7f(0x159)]=_0x5d6844,this[_0x24eb7f(0x119)](_0x24eb7f(0x110),{'options':this[_0x24eb7f(0x12b)]});}[_0x548e69(0xfc)](_0x394606){const _0x5009e7=_0x548e69;for(const _0x17a2a7 of this[_0x5009e7(0x113)][_0x5009e7(0x157)]())if(_0x17a2a7[_0x5009e7(0x126)]===_0x394606)return!0x0;for(const _0x463a93 of this[_0x5009e7(0xeb)][_0x5009e7(0x157)]())if(_0x463a93[_0x5009e7(0x126)]===_0x394606)return!0x0;return!0x1;}[_0x548e69(0x10a)](_0x5da460){const _0x56e114=_0x548e69,_0x1d247d=[];for(const _0x4f83df of this[_0x56e114(0x12b)][_0x56e114(0xf0)]){_0x4f83df[_0x56e114(0xf5)][_0x56e114(0x137)](_0x4143c8=>_0x4143c8['id']===_0x5da460)&&_0x1d247d[_0x56e114(0x12f)](_0x4f83df['id']);}return 0x0===_0x1d247d[_0x56e114(0x143)]?null:_0x1d247d;}[_0x548e69(0x13a)](_0xe57caa,_0x1db2bf,_0xa41eca){const _0x521f6d=_0x548e69,_0x1be385=this[_0x521f6d(0x12b)][_0x521f6d(0xf0)][_0x521f6d(0x137)](_0x282ed5=>_0x282ed5['id']===_0xe57caa);if(!_0x1be385)return;const _0xc3aa46=_0x1be385[_0x521f6d(0xf5)][_0x521f6d(0x137)](_0x3b2a60=>_0x3b2a60['id']===_0x1db2bf);_0xc3aa46&&(_0xc3aa46[_0x521f6d(0x122)]=_0xa41eca,this[_0x521f6d(0x119)](_0x521f6d(0x145),{'sourceId':_0xe57caa,'resourceId':_0x1db2bf,'isInContext':_0xa41eca}));}[_0x548e69(0x156)](_0x4d7dd7){const _0x4a5505=_0x548e69;this[_0x4a5505(0x115)][_0x4a5505(0xf9)](_0x4d7dd7,!0x0),this[_0x4a5505(0x115)][_0x4a5505(0x136)]&&this[_0x4a5505(0x119)](_0x4a5505(0x15d),{'isUploadInProgress':!0x0});}[_0x548e69(0x160)](_0x5af813){const _0x41f139=_0x548e69;this[_0x41f139(0x115)][_0x41f139(0xfb)](_0x5af813),0x0===this[_0x41f139(0x115)][_0x41f139(0x136)]&&this[_0x41f139(0x119)](_0x41f139(0x15d),{'isUploadInProgress':!0x1});}}