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

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (318) hide show
  1. package/build/ai.js +1 -1
  2. package/dist/index.js +5 -5
  3. package/dist/translations/af.js +1 -1
  4. package/dist/translations/af.umd.js +1 -1
  5. package/dist/translations/ar.js +1 -1
  6. package/dist/translations/ar.umd.js +1 -1
  7. package/dist/translations/ast.js +1 -1
  8. package/dist/translations/ast.umd.js +1 -1
  9. package/dist/translations/az.js +1 -1
  10. package/dist/translations/az.umd.js +1 -1
  11. package/dist/translations/be.js +1 -1
  12. package/dist/translations/be.umd.js +1 -1
  13. package/dist/translations/bg.js +1 -1
  14. package/dist/translations/bg.umd.js +1 -1
  15. package/dist/translations/bn.js +1 -1
  16. package/dist/translations/bn.umd.js +1 -1
  17. package/dist/translations/bs.js +1 -1
  18. package/dist/translations/bs.umd.js +1 -1
  19. package/dist/translations/ca.js +1 -1
  20. package/dist/translations/ca.umd.js +1 -1
  21. package/dist/translations/cs.js +1 -1
  22. package/dist/translations/cs.umd.js +1 -1
  23. package/dist/translations/da.js +1 -1
  24. package/dist/translations/da.umd.js +1 -1
  25. package/dist/translations/de-ch.js +1 -1
  26. package/dist/translations/de-ch.umd.js +1 -1
  27. package/dist/translations/de.js +1 -1
  28. package/dist/translations/de.umd.js +1 -1
  29. package/dist/translations/el.js +1 -1
  30. package/dist/translations/el.umd.js +1 -1
  31. package/dist/translations/en-au.js +1 -1
  32. package/dist/translations/en-au.umd.js +1 -1
  33. package/dist/translations/en-gb.js +1 -1
  34. package/dist/translations/en-gb.umd.js +1 -1
  35. package/dist/translations/en.js +1 -1
  36. package/dist/translations/en.umd.js +1 -1
  37. package/dist/translations/eo.js +1 -1
  38. package/dist/translations/eo.umd.js +1 -1
  39. package/dist/translations/es-co.js +1 -1
  40. package/dist/translations/es-co.umd.js +1 -1
  41. package/dist/translations/es.js +1 -1
  42. package/dist/translations/es.umd.js +1 -1
  43. package/dist/translations/et.js +1 -1
  44. package/dist/translations/et.umd.js +1 -1
  45. package/dist/translations/eu.js +1 -1
  46. package/dist/translations/eu.umd.js +1 -1
  47. package/dist/translations/fa.js +1 -1
  48. package/dist/translations/fa.umd.js +1 -1
  49. package/dist/translations/fi.js +1 -1
  50. package/dist/translations/fi.umd.js +1 -1
  51. package/dist/translations/fr.js +1 -1
  52. package/dist/translations/fr.umd.js +1 -1
  53. package/dist/translations/gl.js +1 -1
  54. package/dist/translations/gl.umd.js +1 -1
  55. package/dist/translations/gu.js +1 -1
  56. package/dist/translations/gu.umd.js +1 -1
  57. package/dist/translations/he.js +1 -1
  58. package/dist/translations/he.umd.js +1 -1
  59. package/dist/translations/hi.js +1 -1
  60. package/dist/translations/hi.umd.js +1 -1
  61. package/dist/translations/hr.js +1 -1
  62. package/dist/translations/hr.umd.js +1 -1
  63. package/dist/translations/hu.js +1 -1
  64. package/dist/translations/hu.umd.js +1 -1
  65. package/dist/translations/hy.js +1 -1
  66. package/dist/translations/hy.umd.js +1 -1
  67. package/dist/translations/id.js +1 -1
  68. package/dist/translations/id.umd.js +1 -1
  69. package/dist/translations/it.js +1 -1
  70. package/dist/translations/it.umd.js +1 -1
  71. package/dist/translations/ja.js +1 -1
  72. package/dist/translations/ja.umd.js +1 -1
  73. package/dist/translations/jv.js +1 -1
  74. package/dist/translations/jv.umd.js +1 -1
  75. package/dist/translations/kk.js +1 -1
  76. package/dist/translations/kk.umd.js +1 -1
  77. package/dist/translations/km.js +1 -1
  78. package/dist/translations/km.umd.js +1 -1
  79. package/dist/translations/kn.js +1 -1
  80. package/dist/translations/kn.umd.js +1 -1
  81. package/dist/translations/ko.js +1 -1
  82. package/dist/translations/ko.umd.js +1 -1
  83. package/dist/translations/ku.js +1 -1
  84. package/dist/translations/ku.umd.js +1 -1
  85. package/dist/translations/lt.js +1 -1
  86. package/dist/translations/lt.umd.js +1 -1
  87. package/dist/translations/lv.js +1 -1
  88. package/dist/translations/lv.umd.js +1 -1
  89. package/dist/translations/ms.js +1 -1
  90. package/dist/translations/ms.umd.js +1 -1
  91. package/dist/translations/nb.js +1 -1
  92. package/dist/translations/nb.umd.js +1 -1
  93. package/dist/translations/ne.js +1 -1
  94. package/dist/translations/ne.umd.js +1 -1
  95. package/dist/translations/nl.js +1 -1
  96. package/dist/translations/nl.umd.js +1 -1
  97. package/dist/translations/no.js +1 -1
  98. package/dist/translations/no.umd.js +1 -1
  99. package/dist/translations/oc.js +1 -1
  100. package/dist/translations/oc.umd.js +1 -1
  101. package/dist/translations/pl.js +1 -1
  102. package/dist/translations/pl.umd.js +1 -1
  103. package/dist/translations/pt-br.js +1 -1
  104. package/dist/translations/pt-br.umd.js +1 -1
  105. package/dist/translations/pt.js +1 -1
  106. package/dist/translations/pt.umd.js +1 -1
  107. package/dist/translations/ro.js +1 -1
  108. package/dist/translations/ro.umd.js +1 -1
  109. package/dist/translations/ru.js +1 -1
  110. package/dist/translations/ru.umd.js +1 -1
  111. package/dist/translations/si.js +1 -1
  112. package/dist/translations/si.umd.js +1 -1
  113. package/dist/translations/sk.js +1 -1
  114. package/dist/translations/sk.umd.js +1 -1
  115. package/dist/translations/sl.js +1 -1
  116. package/dist/translations/sl.umd.js +1 -1
  117. package/dist/translations/sq.js +1 -1
  118. package/dist/translations/sq.umd.js +1 -1
  119. package/dist/translations/sr-latn.js +1 -1
  120. package/dist/translations/sr-latn.umd.js +1 -1
  121. package/dist/translations/sr.js +1 -1
  122. package/dist/translations/sr.umd.js +1 -1
  123. package/dist/translations/sv.js +1 -1
  124. package/dist/translations/sv.umd.js +1 -1
  125. package/dist/translations/th.js +1 -1
  126. package/dist/translations/th.umd.js +1 -1
  127. package/dist/translations/ti.js +1 -1
  128. package/dist/translations/ti.umd.js +1 -1
  129. package/dist/translations/tk.js +1 -1
  130. package/dist/translations/tk.umd.js +1 -1
  131. package/dist/translations/tr.js +1 -1
  132. package/dist/translations/tr.umd.js +1 -1
  133. package/dist/translations/tt.js +1 -1
  134. package/dist/translations/tt.umd.js +1 -1
  135. package/dist/translations/ug.js +1 -1
  136. package/dist/translations/ug.umd.js +1 -1
  137. package/dist/translations/uk.js +1 -1
  138. package/dist/translations/uk.umd.js +1 -1
  139. package/dist/translations/ur.js +1 -1
  140. package/dist/translations/ur.umd.js +1 -1
  141. package/dist/translations/uz.js +1 -1
  142. package/dist/translations/uz.umd.js +1 -1
  143. package/dist/translations/vi.js +1 -1
  144. package/dist/translations/vi.umd.js +1 -1
  145. package/dist/translations/zh-cn.js +1 -1
  146. package/dist/translations/zh-cn.umd.js +1 -1
  147. package/dist/translations/zh.js +1 -1
  148. package/dist/translations/zh.umd.js +1 -1
  149. package/package.json +15 -15
  150. package/src/aiactions/aiactions.js +1 -1
  151. package/src/aiactions/model/aiactionsinteraction.js +1 -1
  152. package/src/aiactions/model/aiactionsreply.js +1 -1
  153. package/src/aiassistant/adapters/aiadapter.js +1 -1
  154. package/src/aiassistant/adapters/aitextadapter.js +1 -1
  155. package/src/aiassistant/adapters/awstextadapter.js +1 -1
  156. package/src/aiassistant/adapters/openaitextadapter.js +1 -1
  157. package/src/aiassistant/aiassistant.js +1 -1
  158. package/src/aiassistant/aiassistantediting.js +1 -1
  159. package/src/aiassistant/aiassistantui.js +1 -1
  160. package/src/aiassistant/legacyerrors.js +1 -1
  161. package/src/aiassistant/ui/aiassistantcontroller.js +2 -2
  162. package/src/aiassistant/ui/form/aiformcontentarea.js +1 -1
  163. package/src/aiassistant/ui/form/aiformerrorview.js +1 -1
  164. package/src/aiassistant/ui/form/aiformpromptview.js +1 -1
  165. package/src/aiassistant/ui/form/aiformtoolbarview.js +1 -1
  166. package/src/aiassistant/ui/form/aiformview.js +1 -1
  167. package/src/aiassistant/ui/form/aihistorylistitemview.js +1 -1
  168. package/src/aiassistant/ui/form/aihistorylistview.js +1 -1
  169. package/src/aiassistant/ui/form/prompthistory.js +1 -1
  170. package/src/aiassistant/ui/showaiassistantcommand.js +1 -1
  171. package/src/aiassistant/utils/common-translations.js +1 -1
  172. package/src/aiassistant/utils/normalizecommandsconfig.js +1 -1
  173. package/src/aiballoon/aiballoon.js +1 -1
  174. package/src/aiballoon/ui/aiballoonview.js +1 -1
  175. package/src/aichat/aichat.js +1 -1
  176. package/src/aichat/aichatballoon.js +1 -1
  177. package/src/aichat/aichatcontroller.js +1 -1
  178. package/src/aichat/aichatui.js +1 -1
  179. package/src/aichat/model/aichatcontext.js +1 -1
  180. package/src/aichat/model/aichatconversation.js +1 -1
  181. package/src/aichat/model/aichatinteraction.js +1 -1
  182. package/src/aichat/ui/aichatballoonview.js +1 -1
  183. package/src/aichat/ui/aichatcontrolsview.js +1 -1
  184. package/src/aichat/ui/aichatfeedview.js +1 -1
  185. package/src/aichat/ui/aichatheaderview.js +1 -1
  186. package/src/aichat/ui/aichatview.js +1 -1
  187. package/src/aichat/ui/controls/aichatchipsoverflowmanager.js +1 -1
  188. package/src/aichat/ui/controls/aichatcontextitembuttonview.js +1 -1
  189. package/src/aichat/ui/controls/aichatcontextpanelurlinputview.js +1 -1
  190. package/src/aichat/ui/controls/aichatcontextpanelview.js +1 -1
  191. package/src/aichat/ui/controls/aichatcontrolsloaderview.js +1 -1
  192. package/src/aichat/ui/controls/aichatpromptcapabilitiesview.js +1 -1
  193. package/src/aichat/ui/controls/aichatpromptinputview.js +1 -1
  194. package/src/aichat/ui/controls/aichatpromptsuggestionslistview.js +1 -1
  195. package/src/aichat/ui/controls/resources/aichatcontextresourceslistview.js +1 -1
  196. package/src/aichat/ui/controls/resources/aichatcontextresourcesview.js +1 -1
  197. package/src/aichat/ui/controls/resources/aichatresourcelistitemview.js +1 -1
  198. package/src/aichat/ui/controls/resources/aichatresourcesballoonview.js +1 -1
  199. package/src/aichat/ui/controls/resources/aichatresourcessearchinputview.js +1 -1
  200. package/src/aichat/ui/feed/aichatfeedcontextchipsview.js +1 -1
  201. package/src/aichat/ui/feed/aichatfeedcustomelementview.js +1 -1
  202. package/src/aichat/ui/feed/aichatfeederroritemview.js +1 -1
  203. package/src/aichat/ui/feed/aichatfeedinteractionheaderview.js +1 -1
  204. package/src/aichat/ui/feed/aichatfeeditemview.js +1 -1
  205. package/src/aichat/ui/feed/aichatfeedreplyitemview.js +1 -1
  206. package/src/aichat/ui/feed/aichatfeedsuggestionitemactionsview.js +1 -1
  207. package/src/aichat/ui/feed/aichatfeedsuggestionitemview.js +1 -1
  208. package/src/aichat/ui/feed/aichatfeedusermessageitem.js +1 -1
  209. package/src/aichat/utils/eventnames.js +1 -1
  210. package/src/aichat/utils/promisequeue.js +1 -1
  211. package/src/aichathistory/aichathistory.js +1 -1
  212. package/src/aichathistory/aichathistorycontroller.js +1 -1
  213. package/src/aichathistory/aichathistoryui.js +1 -1
  214. package/src/aichathistory/model/aichathistoryconversations.js +1 -1
  215. package/src/aichathistory/model/aichathistoryitem.js +1 -1
  216. package/src/aichathistory/ui/aichathistorylistitemview.js +2 -2
  217. package/src/aichathistory/ui/aichathistorylistview.js +1 -1
  218. package/src/aichathistory/ui/aichathistorysectionlistview.js +1 -1
  219. package/src/aichathistory/ui/aichathistoryview.js +1 -1
  220. package/src/aichatshortcuts/aichatshortcuts.js +1 -1
  221. package/src/aichatshortcuts/ui/aichatshortcutsview.js +1 -1
  222. package/src/aichatshortcuts/ui/aichatshortcutview.js +1 -1
  223. package/src/aicore/aiconnector.js +1 -1
  224. package/src/aicore/aiediting.js +1 -1
  225. package/src/aicore/model/aicapabilities.js +1 -1
  226. package/src/aicore/model/aicontext.js +1 -1
  227. package/src/aicore/model/aiinteraction.js +1 -1
  228. package/src/aicore/model/aimodels.js +1 -1
  229. package/src/aicore/model/aireply.js +1 -1
  230. package/src/aicore/pipeline/airesponseapplier.js +2 -2
  231. package/src/aicore/pipeline/airesponseparser.js +2 -2
  232. package/src/aicore/ui/aidisclaimerview.js +1 -1
  233. package/src/aicore/ui/aiskeleton.js +1 -1
  234. package/src/aicore/ui/aispinner.js +1 -1
  235. package/src/aicore/ui/suggestioncontainer/aiminitoolbarview.js +1 -1
  236. package/src/aicore/ui/suggestioncontainer/aisuggestionbodyview.js +1 -1
  237. package/src/aicore/ui/suggestioncontainer/aisuggestioncontainerview.js +1 -1
  238. package/src/aicore/ui/suggestioncontainer/aisuggestioncontentpartheaderview.js +1 -1
  239. package/src/aicore/ui/suggestioncontainer/aisuggestioncontentpartstateview.js +1 -1
  240. package/src/aicore/ui/suggestioncontainer/aisuggestioncontentparttoolbarview.js +1 -1
  241. package/src/aicore/ui/suggestioncontainer/aisuggestioncontentpartview.js +1 -1
  242. package/src/aicore/ui/suggestioncontainer/aisuggestionheaderview.js +1 -1
  243. package/src/aicore/ui/suggestioncontainer/aisuggestionloaderview.js +1 -1
  244. package/src/aicore/ui/suggestioncontainer/aisuggestionstreamablecontentview.js +1 -1
  245. package/src/aicore/ui/suggestioncontainer/aiwebsourcesview.js +1 -1
  246. package/src/aicore/utils/common-translations.js +1 -1
  247. package/src/aicore/utils/createresizebutton.js +1 -1
  248. package/src/aicore/utils/documentposition.js +1 -1
  249. package/src/aicore/utils/documentrange.js +1 -1
  250. package/src/aicore/utils/eventnames.js +1 -1
  251. package/src/aicore/utils/geteditorfromcontext.js +1 -1
  252. package/src/aicore/utils/getoperationsfromreply.js +1 -1
  253. package/src/aicore/utils/getsuggestionpartsfromreply.js +1 -1
  254. package/src/aicore/utils/htmlparser.js +1 -1
  255. package/src/aicore/utils/htmlstreamer.js +1 -1
  256. package/src/aicore/utils/scrollmanager.js +1 -1
  257. package/src/aieditorintegration/aieditorintegration.js +1 -1
  258. package/src/aieditorintegration/aitogglebutton/aitogglebuttonui.js +1 -1
  259. package/src/aieditorintegration/aitogglebutton/toggleaicommand.js +1 -1
  260. package/src/aiquickactions/aiquickactions.js +1 -1
  261. package/src/aiquickactions/aiquickactionscommand.js +1 -1
  262. package/src/aiquickactions/aiquickactionsediting.js +1 -1
  263. package/src/aiquickactions/aiquickactionsui.js +1 -1
  264. package/src/aiquickactions/ui/aiquickactionsbuttoncreator.js +1 -1
  265. package/src/aiquickactions/ui/aiquickactionsdropdowncontentview.js +1 -1
  266. package/src/aiquickactions/ui/aiquickactionsdropdowncreator.js +1 -1
  267. package/src/aiquickactions/ui/aiquickactionsfilteredlistview.js +1 -1
  268. package/src/aiquickactions/ui/balloon/aiactionsballoondisclaimerview.js +1 -1
  269. package/src/aiquickactions/ui/balloon/aiactionsballoontoolbarview.js +1 -1
  270. package/src/aiquickactions/ui/balloon/aiactionsballoonview.js +1 -1
  271. package/src/aiquickactions/ui/dropdownmenubuttonwithhighlightview.js +1 -1
  272. package/src/aireviewcore/aireviewcorecontroller.js +1 -1
  273. package/src/aireviewcore/aireviewcoreediting.js +1 -1
  274. package/src/aireviewcore/aireviewcoreui.js +1 -1
  275. package/src/aireviewcore/model/aireviewcheck.js +1 -1
  276. package/src/aireviewcore/model/aireviewchecklist.js +1 -1
  277. package/src/aireviewcore/model/aireviewcheckresult.js +1 -1
  278. package/src/aireviewcore/model/aireviewcheckresultchange.js +1 -1
  279. package/src/aireviewcore/model/aireviewcheckrun.js +1 -1
  280. package/src/aireviewcore/model/aireviewsystemcheckrun.js +1 -1
  281. package/src/aireviewcore/ui/aireviewcoreballoonsuggestionview.js +1 -1
  282. package/src/aireviewcore/ui/aireviewcorechecklistitemresultview.js +1 -1
  283. package/src/aireviewcore/ui/aireviewcorecustomcheckview.js +1 -1
  284. package/src/aireviewcore/ui/aireviewcorefinishreviewbuttonview.js +1 -1
  285. package/src/aireviewcore/ui/aireviewcoregeneralerrorview.js +1 -1
  286. package/src/aireviewcore/ui/aireviewcorepromptinputview.js +1 -1
  287. package/src/aireviewcore/ui/aireviewcorereviewchecklistview.js +1 -1
  288. package/src/aireviewcore/ui/aireviewcorereviewcommandlistitemview.js +1 -1
  289. package/src/aireviewcore/ui/aireviewcorereviewcompletedview.js +1 -1
  290. package/src/aireviewcore/ui/aireviewcoreuicheckresultsview.js +1 -1
  291. package/src/aireviewcore/ui/aireviewcoreview.js +1 -1
  292. package/src/aireviewcore/ui/form/aireviewcoreformdropdown.js +1 -1
  293. package/src/aireviewcore/ui/form/aireviewcoreformmanager.js +1 -1
  294. package/src/aireviewmode/aireviewcheckdefinitions.js +1 -1
  295. package/src/aireviewmode/aireviewmode.js +1 -1
  296. package/src/aireviewmode/aireviewmodecontroller.js +1 -1
  297. package/src/aireviewmode/aireviewmodeui.js +1 -1
  298. package/src/aireviewmode/model/aireviewcheckcustom.js +1 -1
  299. package/src/aireviewmode/model/aireviewcheckextra.js +1 -1
  300. package/src/aireviewmode/model/aireviewcustomcheckrun.js +1 -1
  301. package/src/aireviewmode/model/aireviewextracheckrun.js +1 -1
  302. package/src/aireviewmode/model/aireviewmodechecklist.js +1 -1
  303. package/src/aitabs/aitabs.js +1 -1
  304. package/src/aitabs/aitabsmainview.js +1 -1
  305. package/src/aitabs/tabs/aitabsview.js +1 -1
  306. package/src/aitabs/tabs/tabbuttonview.js +1 -1
  307. package/src/aitabs/tabs/tabpanelview.js +1 -1
  308. package/src/aitranslate/aitranslate.js +1 -1
  309. package/src/aitranslate/aitranslatecontroller.js +1 -1
  310. package/src/aitranslate/aitranslateui.js +1 -1
  311. package/src/aitranslate/model/aitranslatecheck.js +1 -1
  312. package/src/aitranslate/model/aitranslatechecklist.js +1 -1
  313. package/src/aitranslate/model/aitranslatecheckrun.js +1 -1
  314. package/src/aitranslate/ui/aitranslatechecklistview.js +1 -1
  315. package/src/aitranslate/ui/aitranslatecheckresultsview.js +1 -1
  316. package/src/errors.js +1 -1
  317. package/src/errorsmap.js +1 -1
  318. package/src/index.js +1 -1
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x34efa7=_0x5d26;(function(_0xf4df7f,_0x4019a0){const _0x4589d1=_0x5d26,_0x252b3f=_0xf4df7f();while(!![]){try{const _0x29a20d=parseInt(_0x4589d1(0x170))/0x1+parseInt(_0x4589d1(0x175))/0x2*(-parseInt(_0x4589d1(0x144))/0x3)+parseInt(_0x4589d1(0x16d))/0x4*(-parseInt(_0x4589d1(0x15b))/0x5)+parseInt(_0x4589d1(0x150))/0x6*(parseInt(_0x4589d1(0x16a))/0x7)+parseInt(_0x4589d1(0x173))/0x8+parseInt(_0x4589d1(0x16f))/0x9*(parseInt(_0x4589d1(0x16c))/0xa)+-parseInt(_0x4589d1(0x167))/0xb*(parseInt(_0x4589d1(0x161))/0xc);if(_0x29a20d===_0x4019a0)break;else _0x252b3f['push'](_0x252b3f['shift']());}catch(_0x2e294d){_0x252b3f['push'](_0x252b3f['shift']());}}}(_0x4c06,0xa41e1));function _0x5d26(_0x1d1f94,_0x27a1f3){const _0x4c06c5=_0x4c06();return _0x5d26=function(_0x5d2698,_0x1ca48c){_0x5d2698=_0x5d2698-0x136;let _0x3799f8=_0x4c06c5[_0x5d2698];return _0x3799f8;},_0x5d26(_0x1d1f94,_0x27a1f3);}import{Plugin as _0x17c9fc}from'ckeditor5/src/core.js';import{AIBalloon as _0x16d011}from'../aiballoon/aiballoon.js';import{AI_REPLY_ACTIONS as _0x3d6215}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';import{AIChatBalloonView as _0x655cb7}from'./ui/aichatballoonview.js';import{AI_SUGGESTION_UI_EVENT_NAMES as _0x239baf}from'../aicore/utils/eventnames.js';import{Dialog as _0x4288b8}from'ckeditor5/src/ui.js';export class AIChatBalloon extends _0x17c9fc{static get[_0x34efa7(0x176)](){return[_0x4288b8,_0x16d011];}static get[_0x34efa7(0x137)](){const _0x3bc785=_0x34efa7;return _0x3bc785(0x160);}static get[_0x34efa7(0x163)](){return!0x0;}static get[_0x34efa7(0x139)](){return!0x0;}[_0x34efa7(0x149)];constructor(_0xf6c07a){const _0x12c38d=_0x34efa7;super(_0xf6c07a),this[_0x12c38d(0x171)](_0x12c38d(0x145),!0x1);}[_0x34efa7(0x143)](_0x719580){const _0x311348=_0x34efa7,_0x2ab3cb=this[_0x311348(0x13d)];this[_0x311348(0x149)]||(this[_0x311348(0x149)]=this[_0x311348(0x15f)]()),_0x2ab3cb[_0x311348(0x151)][_0x311348(0x152)](_0x311348(0x14e))[_0x311348(0x143)]({..._0x719580,'id':_0x311348(0x157),'class':_0x311348(0x140),'mainView':this[_0x311348(0x149)]}),this[_0x311348(0x15e)](_0x719580[_0x311348(0x147)]),this[_0x311348(0x149)][_0x311348(0x16b)](!_0x719580[_0x311348(0x158)]),this[_0x311348(0x153)]();}[_0x34efa7(0x142)](){const _0x3500b4=_0x34efa7;this[_0x3500b4(0x13d)][_0x3500b4(0x151)][_0x3500b4(0x152)](_0x3500b4(0x14e))[_0x3500b4(0x142)]();}[_0x34efa7(0x14d)](_0x1fda80){const _0x154c4d=_0x34efa7;return this[_0x154c4d(0x149)]||(this[_0x154c4d(0x149)]=this[_0x154c4d(0x15f)]()),this[_0x154c4d(0x149)][_0x154c4d(0x14d)](_0x1fda80);}[_0x34efa7(0x168)](_0x34180e){const _0x449f7e=_0x34efa7;this[_0x449f7e(0x149)]&&this[_0x449f7e(0x149)][_0x449f7e(0x168)](_0x34180e);}[_0x34efa7(0x15f)](){const _0xe1e7a6=_0x34efa7,_0x3e961c=this[_0xe1e7a6(0x13d)],_0x4bbf85=_0x3e961c[_0xe1e7a6(0x151)][_0xe1e7a6(0x152)](_0xe1e7a6(0x14e)),_0x4cfc66=_0x3e961c[_0xe1e7a6(0x16e)][_0xe1e7a6(0x152)](_0xe1e7a6(0x14f));let _0x3aad1e=_0x3e961c[_0xe1e7a6(0x146)][_0xe1e7a6(0x152)](_0xe1e7a6(0x15a))||[..._0x3d6215];_0x3e961c[_0xe1e7a6(0x151)][_0xe1e7a6(0x156)](_0xe1e7a6(0x177))||(_0x3aad1e=_0x3aad1e[_0xe1e7a6(0x13e)](_0xad3450=>_0xe1e7a6(0x141)!=_0xad3450));const _0x51fd7a=new _0x655cb7(_0x3e961c[_0xe1e7a6(0x148)],{'availableActions':_0x3aad1e,'showApplyButton':!0x0,'showSuggestButton':!!_0x4cfc66});return _0x51fd7a[_0xe1e7a6(0x165)](_0xe1e7a6(0x145))['to'](this),_0x51fd7a[_0xe1e7a6(0x14b)](..._0x239baf)['to'](this),_0x51fd7a[_0xe1e7a6(0x14b)](_0xe1e7a6(0x13f),_0xe1e7a6(0x178))['to'](this),_0x4bbf85[_0xe1e7a6(0x14b)](_0xe1e7a6(0x136))['to'](this),_0x51fd7a['on'](_0xe1e7a6(0x169),this[_0xe1e7a6(0x153)][_0xe1e7a6(0x165)](this)),_0x51fd7a['on'](_0xe1e7a6(0x141),this[_0xe1e7a6(0x153)][_0xe1e7a6(0x165)](this)),_0x51fd7a['on'](_0xe1e7a6(0x138),this[_0xe1e7a6(0x153)][_0xe1e7a6(0x165)](this)),_0x4cfc66&&_0x51fd7a[_0xe1e7a6(0x165)](_0xe1e7a6(0x166))['to'](_0x4cfc66,_0xe1e7a6(0x164)),_0x51fd7a[_0xe1e7a6(0x14a)](),_0x51fd7a;}[_0x34efa7(0x15e)](_0x39001a){const _0x3cdcfb=_0x34efa7,_0x15c1c6=this[_0x3cdcfb(0x13d)],_0x28ac8a=_0x15c1c6[_0x3cdcfb(0x151)][_0x3cdcfb(0x152)](_0x3cdcfb(0x155))[_0x3cdcfb(0x162)][_0x3cdcfb(0x172)][_0x3cdcfb(0x13c)];this[_0x3cdcfb(0x149)][_0x3cdcfb(0x174)](_0x39001a),_0x28ac8a[_0x3cdcfb(0x156)](this[_0x3cdcfb(0x149)][_0x3cdcfb(0x13b)])||(_0x28ac8a[_0x3cdcfb(0x15c)]([this[_0x3cdcfb(0x149)][_0x3cdcfb(0x13b)],this[_0x3cdcfb(0x149)][_0x3cdcfb(0x15d)]],0x0),_0x15c1c6[_0x3cdcfb(0x151)][_0x3cdcfb(0x152)](_0x3cdcfb(0x14e))[_0x3cdcfb(0x14c)](_0x3cdcfb(0x159),()=>{const _0x3ef508=_0x3cdcfb;_0x28ac8a[_0x3ef508(0x154)](this[_0x3ef508(0x149)][_0x3ef508(0x13b)]),_0x28ac8a[_0x3ef508(0x154)](this[_0x3ef508(0x149)][_0x3ef508(0x15d)]);}));}[_0x34efa7(0x153)](){const _0x3d3b4f=_0x34efa7;this[_0x3d3b4f(0x149)][_0x3d3b4f(0x13a)]();}}function _0x4c06(){const _0x2ab455=['144444RZnDip','plugins','get','_restoreDefaultViewFocus','remove','Dialog','has','aiChatBalloon','areActionsDisabled','beforeDialogClosed','ai.availableReplyActions','5OYosHM','addMany','nextButtonView','_toggleRotatorButtonsInDialogHeader','_createChatBalloonView','AIChatBalloon','1032BHhDrE','view','isOfficialPlugin','value','bind','isTrackChangesOn','221716GudEAm','setState','applySuggestion','287WSmeav','togglePartToolbarEnabled','5876960nYURzn','3152748OPQaBI','commands','18sBtbyA','897659AoVLiP','set','headerView','9495680MwUdzG','toggleRotatorButtonsVisibility','2tuFFeR','requires','TrackChanges','showNext','dialogClosed','pluginName','rejectSuggestion','isPremiumPlugin','focus','previousButtonView','children','editor','filter','showPrevious','ck-ai-chat-balloon','insertSuggestion','close','open','3159651tpmqtk','showDiff','config','showRotator','locale','_chatBalloonView','render','delegate','once','updateContent','AIBalloon','trackChanges'];_0x4c06=function(){return _0x2ab455;};return _0x4c06();}
23
+ const _0x36c7e9=_0x414a;(function(_0x2a57fe,_0x2c7232){const _0x9f8b8=_0x414a,_0x21cc21=_0x2a57fe();while(!![]){try{const _0x10feb7=-parseInt(_0x9f8b8(0xcf))/0x1*(parseInt(_0x9f8b8(0xe6))/0x2)+parseInt(_0x9f8b8(0xdc))/0x3+parseInt(_0x9f8b8(0xf5))/0x4*(parseInt(_0x9f8b8(0xe8))/0x5)+parseInt(_0x9f8b8(0xd3))/0x6+-parseInt(_0x9f8b8(0xfb))/0x7*(parseInt(_0x9f8b8(0xe5))/0x8)+parseInt(_0x9f8b8(0xff))/0x9+parseInt(_0x9f8b8(0xcb))/0xa*(-parseInt(_0x9f8b8(0xd6))/0xb);if(_0x10feb7===_0x2c7232)break;else _0x21cc21['push'](_0x21cc21['shift']());}catch(_0x4c6665){_0x21cc21['push'](_0x21cc21['shift']());}}}(_0x52b5,0xb2a1e));import{Plugin as _0x18fe8c}from'ckeditor5/src/core.js';import{AIBalloon as _0x24ff05}from'../aiballoon/aiballoon.js';import{AI_REPLY_ACTIONS as _0x1f0a62}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';import{AIChatBalloonView as _0x1f0b92}from'./ui/aichatballoonview.js';import{AI_SUGGESTION_UI_EVENT_NAMES as _0x4d1f51}from'../aicore/utils/eventnames.js';import{Dialog as _0x127a1a}from'ckeditor5/src/ui.js';function _0x414a(_0xf7c221,_0x1ce93e){const _0x52b50c=_0x52b5();return _0x414a=function(_0x414ac8,_0x40475b){_0x414ac8=_0x414ac8-0xc4;let _0x95c486=_0x52b50c[_0x414ac8];return _0x95c486;},_0x414a(_0xf7c221,_0x1ce93e);}export class AIChatBalloon extends _0x18fe8c{static get[_0x36c7e9(0xfa)](){return[_0x127a1a,_0x24ff05];}static get[_0x36c7e9(0xe9)](){const _0x43e578=_0x36c7e9;return _0x43e578(0xf4);}static get[_0x36c7e9(0xd5)](){return!0x0;}static get[_0x36c7e9(0xda)](){return!0x0;}[_0x36c7e9(0xd2)];constructor(_0x5d81ba){const _0x523380=_0x36c7e9;super(_0x5d81ba),this[_0x523380(0x100)](_0x523380(0xc6),!0x1);}[_0x36c7e9(0x103)](_0x2d5d4a){const _0x3f8ef5=_0x36c7e9,_0x4a30cb=this[_0x3f8ef5(0xcc)];this[_0x3f8ef5(0xd2)]||(this[_0x3f8ef5(0xd2)]=this[_0x3f8ef5(0xde)]()),_0x4a30cb[_0x3f8ef5(0xef)][_0x3f8ef5(0xdd)](_0x3f8ef5(0xed))[_0x3f8ef5(0x103)]({..._0x2d5d4a,'id':_0x3f8ef5(0xf7),'class':_0x3f8ef5(0xc9),'mainView':this[_0x3f8ef5(0xd2)]}),this[_0x3f8ef5(0xd4)](_0x2d5d4a[_0x3f8ef5(0xe0)]),this[_0x3f8ef5(0xd2)][_0x3f8ef5(0xcd)](!_0x2d5d4a[_0x3f8ef5(0xce)]),this[_0x3f8ef5(0xd9)]();}[_0x36c7e9(0xec)](){const _0x5924d3=_0x36c7e9;this[_0x5924d3(0xcc)][_0x5924d3(0xef)][_0x5924d3(0xdd)](_0x5924d3(0xed))[_0x5924d3(0xec)]();}[_0x36c7e9(0x101)](_0x82a43){const _0x5856b3=_0x36c7e9;return this[_0x5856b3(0xd2)]||(this[_0x5856b3(0xd2)]=this[_0x5856b3(0xde)]()),this[_0x5856b3(0xd2)][_0x5856b3(0x101)](_0x82a43);}[_0x36c7e9(0x104)](_0x3ab07f){const _0x461e64=_0x36c7e9;this[_0x461e64(0xd2)]&&this[_0x461e64(0xd2)][_0x461e64(0x104)](_0x3ab07f);}[_0x36c7e9(0xde)](){const _0x2acf1c=_0x36c7e9,_0x414d32=this[_0x2acf1c(0xcc)],_0xcc536e=_0x414d32[_0x2acf1c(0xef)][_0x2acf1c(0xdd)](_0x2acf1c(0xed)),_0x10fd8b=_0x414d32[_0x2acf1c(0x102)][_0x2acf1c(0xdd)](_0x2acf1c(0x105));let _0x324e7b=_0x414d32[_0x2acf1c(0xea)][_0x2acf1c(0xdd)](_0x2acf1c(0xf3))||[..._0x1f0a62];_0x414d32[_0x2acf1c(0xef)][_0x2acf1c(0xe3)](_0x2acf1c(0xca))||(_0x324e7b=_0x324e7b[_0x2acf1c(0xf1)](_0xf2afbf=>_0x2acf1c(0xe7)!=_0xf2afbf));const _0x949d5e=new _0x1f0b92(_0x414d32[_0x2acf1c(0xdb)],{'availableActions':_0x324e7b,'showApplyButton':!0x0,'showSuggestButton':!!_0x10fd8b});return _0x949d5e[_0x2acf1c(0xe1)](_0x2acf1c(0xc6))['to'](this),_0x949d5e[_0x2acf1c(0xd8)](..._0x4d1f51)['to'](this),_0x949d5e[_0x2acf1c(0xd8)](_0x2acf1c(0xf6),_0x2acf1c(0xd0))['to'](this),_0xcc536e[_0x2acf1c(0xd8)](_0x2acf1c(0xd7))['to'](this),_0x949d5e['on'](_0x2acf1c(0xeb),this[_0x2acf1c(0xd9)][_0x2acf1c(0xe1)](this)),_0x949d5e['on'](_0x2acf1c(0xe7),this[_0x2acf1c(0xd9)][_0x2acf1c(0xe1)](this)),_0x949d5e['on'](_0x2acf1c(0xf8),this[_0x2acf1c(0xd9)][_0x2acf1c(0xe1)](this)),_0x10fd8b&&_0x949d5e[_0x2acf1c(0xe1)](_0x2acf1c(0xc8))['to'](_0x10fd8b,_0x2acf1c(0xe2)),_0x949d5e[_0x2acf1c(0xc4)](),_0x949d5e;}[_0x36c7e9(0xd4)](_0x3974ea){const _0x1c5de0=_0x36c7e9,_0x1904c1=this[_0x1c5de0(0xcc)],_0x151f9e=_0x1904c1[_0x1c5de0(0xef)][_0x1c5de0(0xdd)](_0x1c5de0(0xc5))[_0x1c5de0(0xee)][_0x1c5de0(0xc7)][_0x1c5de0(0xfc)];this[_0x1c5de0(0xd2)][_0x1c5de0(0xe4)](_0x3974ea),_0x151f9e[_0x1c5de0(0xe3)](this[_0x1c5de0(0xd2)][_0x1c5de0(0xf0)])||(_0x151f9e[_0x1c5de0(0xdf)]([this[_0x1c5de0(0xd2)][_0x1c5de0(0xf0)],this[_0x1c5de0(0xd2)][_0x1c5de0(0xd1)]],0x0),_0x1904c1[_0x1c5de0(0xef)][_0x1c5de0(0xdd)](_0x1c5de0(0xed))[_0x1c5de0(0xfd)](_0x1c5de0(0xf2),()=>{const _0x342baf=_0x1c5de0;_0x151f9e[_0x342baf(0xfe)](this[_0x342baf(0xd2)][_0x342baf(0xf0)]),_0x151f9e[_0x342baf(0xfe)](this[_0x342baf(0xd2)][_0x342baf(0xd1)]);}));}[_0x36c7e9(0xd9)](){const _0x49ce30=_0x36c7e9;this[_0x49ce30(0xd2)][_0x49ce30(0xf9)]();}}function _0x52b5(){const _0x42282b=['trackChanges','render','Dialog','showDiff','headerView','isTrackChangesOn','ck-ai-chat-balloon','TrackChanges','468320knghXN','editor','togglePartToolbarEnabled','areActionsDisabled','3NXcjOJ','showNext','nextButtonView','_chatBalloonView','6768276HzlwwI','_toggleRotatorButtonsInDialogHeader','isOfficialPlugin','55PGVqzr','dialogClosed','delegate','_restoreDefaultViewFocus','isPremiumPlugin','locale','1957668JKYXas','get','_createChatBalloonView','addMany','showRotator','bind','value','has','toggleRotatorButtonsVisibility','8uWSRcL','427560mHWnbr','insertSuggestion','300535CgBBqn','pluginName','config','applySuggestion','close','AIBalloon','view','plugins','previousButtonView','filter','beforeDialogClosed','ai.availableReplyActions','AIChatBalloon','16XUlnUk','showPrevious','aiChatBalloon','rejectSuggestion','focus','requires','9169167BmHtuP','children','once','remove','8064261cwTTaD','set','updateContent','commands','open','setState'];_0x52b5=function(){return _0x42282b;};return _0x52b5();}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x12f486=_0x3a9b;function _0x5ea4(){const _0x6daf08=['ai-chat-context-file-too-large','like','setIsMaximized','getConversation','showNext','executeCustomItemCallback','_bodyCollection','getDocumentContext','AIChatController','selection','get','sourceId','toggleReasoning','outdated','AI_CHAT_CONTEXT_FORM_DATA_SIZE_LIMITS_EXCEEDED','node','activeConversation','ai.models.defaultModelId','changeGroups','closeSourceResourceBalloon','alignToTop','AI_CHAT_CONTEXT_INVALID_DATA','resize','stop','undo','addSelectionToChatContext','toViewRange','startInteraction','addFeedItemAIReply','toggleLoadingSkeleton','slice','finishInteraction','ai-request-aborted','AI_CHAT_GENERIC_ERROR','focusPromptInput','resizedTabs','addFileToContext','ai-chat-resource-load-failed','_aiChatBalloonShowDiff','getInteractionAndReplyById','1546761eRHUTC','unshift','contextItemLoadingEnded','createPositionAt','scrollFeedToSuggestion','removeFeedInteraction','removeSelectionFromContext','ready','replyCreated','AITabs','sendMessage','applySuggestion','_aiChatBalloon','_logError','viewRangeToDom','showDiff','_updateReplyContent','current-document','ai-conversation-','nextSibling','reasoningStarted','end','change','load','isInContext','previous','partIndex','Showing\x20conversation\x20history...','detachFromDom','sendUserMessage','loadConversation','createReply','getPath','getDiff','_registerToolDataCallback','Liked\x20response','addResourceToContext','AI_CHAT_RESOURCE_LOAD_FAILED','attachToDom','enableControls','split','setConversationTitle','getAttribute','isOfficialPlugin','source','removeSelectionFromChatContext','_flushLastInteractionUI','startConversation','_openBalloonFor','addFeedItemAISuggestion','delegate','messageId','activateTab','AI_CHAT_CONTEXT_FILE_TOO_LARGE','getChild','_applyOperationsAsSuggestions','getSelectionText','addFilesToContext','dialogClosed','addFeedItemError','lastInteraction','_aiConnector','findIndex','isModelAvailable','isCurrentDocumentInContext','updateFeedItemAIReplyContent','startAutoScroll','updateFeedItemAIReplySources','_createFromRanges','AI_CHAT_UNABLE_TO_LOAD_CONVERSATION','webSearchFinished','AIChatUI','toolDataReceived','hasChanges','ai.chat.initialConversation','mouseLeaveSuggestion','createPositionFromPath','setFeedItemRenderingStrategy','find','sources','rootName','ai-chat-url-upload-failed','toggleSuggestionDisplayMode','new','maxOffset','close','query','_applySuggestion','main','_setIsMaximized','lastCreated','cloneNode','TrackChangesEditing','delete','reasoningFinished','streaming','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_FILE','isUploadInProgress','model','setIsUploadInProgress','root','Undo','24bXLKoC','resourceId','open','ai-chat-invalid-request','_aiChatModels','pluginName','ai-chat-source-resources-load-failed','clearConversationContextUI','_getDocumentRangeForReplyChanges','removeFromContext','addUrlToContext','redo','$graveyard','index','context','ai-chat-controller-mouse-over','listenTo','getChildAtOffset','documentContextContent','dislike','accepted','set','getFirstRange','getReply','ai-chat-conversation-init-failed','ai-chat-context-invalid-data','AIConnector','includes','callback','594750ugEPbv','ai-chat-context-form-data-size-limits-exceeded','content','type','AI_CHAT_UNABLE_TO_START_CONVERSATION','Disliked\x20response','data-id','clearLoadingMessage','webSearchStarted','version','replyChangeGroupStateUpdated','data','resource','ai-chat-missing-channel-id','capabilitiesUpdated','isLoading','ai-chat-context-unsupported-type','createdAt','updateConversationTitle','isStarted','AIChatBalloon','setSelectedModel','map','destroy','addOperation','replyContentUpdated','updateFeedItemAIReplySuggestionContent','AI_CHAT_CONTEXT_UNSUPPORTED_FILE_TYPE','populateSourceResourceBalloon','getConversations','isDocumentOperation','_scrollToSuggestionRange','addContextOptionsChanged','toString','handleRemovedConversation','revert','message','interactionId','addFeedItemUserMessage','path','ai-chat-context-unsupported-file-type','getTransformedByOperation','requires','getChildren','7zkYjmX','afterInit','parse','clearPendingContextUI','batch','addCurrentDocumentToChatContext','showFakeVisualSelection','howMany','updateResourceState','resetMessageInput','_toggleReasoning','error','_stopLastInteraction','setLoadingMessage','_removeFromContext','updateContent','next','setContextItemLoading','resetConversationTitle','state','log','loadSourceResources','addCurrentDocumentToContext','_getPresentableSiblingContentPartIndex','history','showPrevious','getAll','indexOf','AIEditing','_getAIChatInteractionAPI','interactionCreated','replyId','collaboration.channelId','document','getInteraction','ai.chat.context','_integrateEditor','done','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_URL','resourceStateChanged','commands','modelSelected','length','setFeedItemAIReplySuggestionPartActive','range','sessionId','addSelectionToContext','text','resetReasoningState','_updateRatings','remove','marker','239zMJRgb','plugins','ai-no-track-changes','upsertAIChatRating','uploadProgressChanged','AI_CHAT_ABORTED_MESSAGE','setModel','add','mapper','setAddContextOptions','aiChatBalloon','resources','start','_startConversationSafely','AI_CHAT_CONTEXT_UNABLE_TO_LOAD_RESOURCES','ai-chat-conversation-start-failed','has','uiId','hideFakeVisualSelection','selectedModel','disableControls','stopInteraction','showChangeInText','areActionsDisabled','2156EDxrwQ','contextItemAdded','prepareLoadingMessage','applyOperation','_getLastCreatedConversationId','interactionFinished','addFeedItemCustomElement','currentReply','toggleWebSearch','ai-chat-context-file-too-many-pages','insertSuggestion','mouseOverSuggestion','3402905qzeBes','domConverter','init','4jllmFr','DocumentCompare','isPremiumPlugin','AI_CHAT_CONTEXT_FILE_TOO_MANY_PAGES','ai-chat-file-upload-failed','indexes','_batchToChanges','sourceResourcesLoaded','updateFeedItemAIReplySuggestionPartState','forEach','locale','editing','TrackChanges','bind','children','modification','1074681YrzfKH','getContentParts','selectModel','addFeedItemStaticMessage','config','addFeedInteractionHeader','1406226BmNIih','addDocumentToContext','setChangeGroupState','createConversation','ai.models','abortPromptStream','getDocumentData','isDisabled','AI_CHAT_CONTEXT_CURRENT_DOCUMENT','AI_CHAT_INVALID_REQUEST','isCurrentDocumentInConversation','updateCapabilities','_getUserPresentableContentPartDocumentRange','anchorId','_currentPreviewedChangeGroup','from','_rejectSuggestion','fetchConversation','push','contextSent','AI_BALLOON_HEADER_TITLE','resetWebSearchState','getOperations','conversationInitialized','rejectSuggestion','getGroupId','_insertSuggestion','_toggleWebSearch','chat','_handleStartConversation','createRange','changes','startsWith','addContextItem','AI_CHAT_CONTEXT_UNSUPPORTED_TYPE','options','_aiChatUi','_aiEditing','updateCurrentDocumentInContext','2654290xvabfY','AI_CHAT_UNTITLED_CONVERSATION','editors','contextItem','handleUserInteraction','replies','ai-chat-controller-no-active-conversation','setState','uid','fetchConversations','baseVersion','contextItems','getRoot','view','_showConversationHistory','resizeTabs','pending','ai-chat-conversation-not-found','setConversationContext','interactionStarted','_handleUIUserMessage','removed','rejected','removeContextItem','filter','sourcePosition','interactionDestroyed','contextItemRemoved','static','getRanges'];_0x5ea4=function(){return _0x6daf08;};return _0x5ea4();}(function(_0x1cd78a,_0x3df4ce){const _0x443f11=_0x3a9b,_0x1dd61c=_0x1cd78a();while(!![]){try{const _0x49b2f8=-parseInt(_0x443f11(0x8e))/0x1*(-parseInt(_0x443f11(0xa6))/0x2)+-parseInt(_0x443f11(0x138))/0x3*(parseInt(_0x443f11(0xb5))/0x4)+-parseInt(_0x443f11(0x1bb))/0x5+parseInt(_0x443f11(0xcb))/0x6*(parseInt(_0x443f11(0x1e7))/0x7)+-parseInt(_0x443f11(0x19e))/0x8*(-parseInt(_0x443f11(0xc5))/0x9)+-parseInt(_0x443f11(0xf2))/0xa+parseInt(_0x443f11(0xb2))/0xb;if(_0x49b2f8===_0x3df4ce)break;else _0x1dd61c['push'](_0x1dd61c['shift']());}catch(_0x291744){_0x1dd61c['push'](_0x1dd61c['shift']());}}}(_0x5ea4,0x3f62d));import{ContextPlugin as _0x1bba01,Editor as _0x1ab0f4}from'ckeditor5/src/core.js';import{BodyCollection as _0x438b43}from'ckeditor5/src/ui.js';function _0x3a9b(_0x3e25e9,_0x13cffa){const _0x5ea4d7=_0x5ea4();return _0x3a9b=function(_0x3a9be2,_0x2df47a){_0x3a9be2=_0x3a9be2-0x6b;let _0x19568e=_0x5ea4d7[_0x3a9be2];return _0x19568e;},_0x3a9b(_0x3e25e9,_0x13cffa);}import{CKEditorError as _0x4b2b76,logError as _0x5319e8,scrollViewportToShowTarget as _0x343c18,uid as _0x14d190}from'ckeditor5/src/utils.js';import{AIConnector as _0x4a9833}from'../aicore/aiconnector.js';import{AITabs as _0x575159}from'../aitabs/aitabs.js';import{AIChatConversation as _0x2fc456}from'./model/aichatconversation.js';import{getTranslation as _0x541ff7}from'../aicore/utils/common-translations.js';import{AIModels as _0x1bdab5}from'../aicore/model/aimodels.js';import{getEditorFromContext as _0x4b9b70}from'../aicore/utils/geteditorfromcontext.js';import{DocumentCompare as _0x41a947,DATA_ID_MODEL_ATTRIBUTE as _0xdc6d4f}from'ckeditor5-collaboration/src/collaboration-core.js';import{fixMarkerOperationOldRange as _0x366e90,getOperationsFromReply as _0x58de2c}from'../aicore/utils/getoperationsfromreply.js';import{expandSelectionWithContext as _0x52bea3,getMinimalSelection as _0x572c78}from'../aicore/utils/getsuggestionpartsfromreply.js';import{ModelRange as _0x1ca952,_DetachOperation as _0x1604bc}from'ckeditor5/src/engine.js';import{findOne as _0xd10b12,getAttribute as _0xa01188,serialize as _0x52f5de,Document as _0x8e65d3,findByAttribute as _0x2b1db6}from'../aicore/utils/htmlparser.js';export class AIChatController extends _0x1bba01{[_0x12f486(0xf0)];[_0x12f486(0x175)];[_0x12f486(0xef)];[_0x12f486(0x1a2)];[_0x12f486(0x144)];[_0x12f486(0xbb)]=new Map();[_0x12f486(0xd9)]=null;[_0x12f486(0x116)];static get[_0x12f486(0x1e5)](){return[_0x4a9833,_0x41a947];}static get[_0x12f486(0x1a3)](){const _0x460de2=_0x12f486;return _0x460de2(0x118);}static get[_0x12f486(0x163)](){return!0x0;}static get[_0x12f486(0xb7)](){return!0x0;}[_0x12f486(0xb4)](){const _0x1dc127=_0x12f486;this[_0x1dc127(0x116)]=new _0x438b43(this[_0x1dc127(0x1ac)][_0x1dc127(0xbf)]),this[_0x1dc127(0x116)][_0x1dc127(0x15e)](),this[_0x1dc127(0x175)]=this[_0x1dc127(0x1ac)][_0x1dc127(0x8f)][_0x1dc127(0x11a)](_0x1dc127(0x1b8)),this[_0x1dc127(0xef)]=this[_0x1dc127(0x1ac)][_0x1dc127(0x8f)][_0x1dc127(0x11a)](_0x1dc127(0x17f)),this[_0x1dc127(0xf0)]=this[_0x1dc127(0x1ac)][_0x1dc127(0x8f)][_0x1dc127(0x11a)](_0x1dc127(0x76)),this[_0x1dc127(0x1a2)]=new _0x1bdab5({'connector':this[_0x1dc127(0x175)],'config':this[_0x1dc127(0x1ac)][_0x1dc127(0xc9)][_0x1dc127(0x11a)](_0x1dc127(0xcf)),'locale':this[_0x1dc127(0x1ac)][_0x1dc127(0xbf)]});const _0xd54ed3=this[_0x1dc127(0x1ac)][_0x1dc127(0x8f)][_0x1dc127(0x11a)](_0x1dc127(0x141));this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x167),()=>{const _0x25692d=_0x1dc127;this[_0x25692d(0x9b)]();}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x155),(_0x87ccbc,_0x41cf6a)=>{const _0xdffe61=_0x1dc127;this[_0xdffe61(0x106)]({'userMessage':_0x41cf6a});}),this[_0x1dc127(0x1ae)](_0xd54ed3,_0x1dc127(0x133),(_0x3ea742,_0x45432b)=>{const _0x39f165=_0x1dc127;this[_0x39f165(0x191)](_0x45432b);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x101),()=>{const _0x48b26c=_0x1dc127;_0xd54ed3[_0x48b26c(0x126)]();}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0xd0),async()=>{const _0x3b7fde=_0x1dc127;await this[_0x3b7fde(0x1f3)](),await this[_0x3b7fde(0x166)](),this[_0x3b7fde(0x165)]();}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0xcc),()=>{const _0x4f47ed=_0x1dc127;this[_0x4f47ed(0x1ec)]();}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x134),(_0x3aa7d9,_0x1b7d3d)=>{const _0x3f6410=_0x1dc127;this[_0x3f6410(0x120)]?.[_0x3f6410(0x171)](Array[_0x3f6410(0xda)](_0x1b7d3d));}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x1a8),(_0x1b93e9,_0x51ecd9)=>{const _0xcad80=_0x1dc127;this[_0xcad80(0x120)]?.[_0xcad80(0x1a8)](_0x51ecd9);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x115),(_0xe50526,_0x9a4076)=>{const _0x4c4d2e=_0x1dc127;_0x9a4076[_0x4c4d2e(0x1ba)](this[_0x4c4d2e(0x1ac)]);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x15c),(_0x37750d,_0x2ebabc)=>{const _0x1ad393=_0x1dc127;this[_0x1ad393(0x120)]?.[_0x1ad393(0x15c)](_0x2ebabc[_0x1ad393(0x164)],_0x2ebabc[_0x1ad393(0x1c7)]);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x109),(_0x42274a,_0x1a86f2)=>{const _0x4d5d83=_0x1dc127;this[_0x4d5d83(0x1f5)](_0x1a86f2);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x6f),(_0x4bf45b,_0x1e01b8)=>{const _0x28d97b=_0x1dc127;this[_0x28d97b(0x120)]?.[_0x28d97b(0x6f)](_0x1e01b8[_0x28d97b(0x11b)],_0x1e01b8[_0x28d97b(0x18e)],_0x1e01b8[_0x28d97b(0xfa)]);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0xae),()=>{const _0x499db6=_0x1dc127;this[_0x499db6(0xe6)]();}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x11c),()=>{const _0x55d1fd=_0x1dc127;this[_0x55d1fd(0x1f1)]();}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0xc7),(_0x2a7ddc,_0x1fe8c6)=>{const _0x222e01=_0x1dc127;this[_0x222e01(0x120)]?.[_0x222e01(0x94)](_0x1fe8c6);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x111),(_0x2b5f2b,{replyId:_0x427502})=>{const _0x24be12=_0x1dc127;console[_0x24be12(0x6e)](_0x24be12(0x15b),_0x427502);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x1b1),(_0xaa3829,{replyId:_0x348651})=>{const _0x3a4e1d=_0x1dc127;console[_0x3a4e1d(0x6e)](_0x3a4e1d(0x1c0),_0x348651);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0xb0),(_0x339033,_0x52d437)=>{const _0x2f85e0=_0x1dc127;this[_0x2f85e0(0xe5)](_0x52d437);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0xa4),(_0x253786,{replyId:_0x2dd668,partIndex:_0x5617ba})=>{const _0xf58846=_0x1dc127;this[_0xf58846(0x136)]=this[_0xf58846(0xef)][_0xf58846(0x147)],this[_0xf58846(0x168)](_0x2dd668,_0x5617ba);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0xb1),(_0x2a5047,{replyId:_0x301d47,partIndex:_0x9d8eb0})=>{const _0x21d917=_0x1dc127,_0x3130a7=this[_0x21d917(0x1a6)](_0x301d47,_0x9d8eb0);_0x3130a7&&_0x21d917(0x1aa)!=_0x3130a7[_0x21d917(0x86)][_0x21d917(0x19c)][_0x21d917(0x188)]&&this[_0x21d917(0xf0)][_0x21d917(0x1ed)]([_0x3130a7[_0x21d917(0x86)]],_0x21d917(0x1ad));}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x183),()=>{const _0x4aa01c=_0x1dc127;this[_0x4aa01c(0xf0)][_0x4aa01c(0xa0)](_0x4aa01c(0x1ad));}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x143),(_0x5a3a3d,_0x3cf295)=>{const _0x5a199a=_0x1dc127;this[_0x5a199a(0xf0)][_0x5a199a(0xa0)](_0x5a199a(0x1ad)),this[_0x5a199a(0x18f)](_0x3cf295);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0x18a),async(_0x1b4c4f,{replyId:_0xc0cef0,showDiff:_0x1d7d37})=>{const _0xfd97ce=_0x1dc127,{reply:_0x579cc7}=this[_0xfd97ce(0x137)](_0xc0cef0),_0x289790=_0x579cc7[_0xfd97ce(0xc6)]({'showDiff':_0x1d7d37});await this[_0xfd97ce(0xef)][_0xfd97ce(0x1d5)]({'id':_0x579cc7['id'],'parts':_0x289790,'renderingStrategy':_0xfd97ce(0x10e)});}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0xef)],_0x1dc127(0xe3),(_0x20d6a8,{replyId:_0x579eb9,partIndex:_0x350b6f})=>{const _0x5180a5=_0x1dc127;this[_0x5180a5(0xdb)]({'replyId':_0x579eb9,'partIndex':_0x350b6f}),this[_0x5180a5(0xf0)][_0x5180a5(0xa0)](_0x5180a5(0x1ad));}),this[_0x1dc127(0x1ac)][_0x1dc127(0x8f)][_0x1dc127(0x9e)](_0x1dc127(0x1cf))&&(this[_0x1dc127(0x144)]=this[_0x1dc127(0x1ac)][_0x1dc127(0x8f)][_0x1dc127(0x11a)](_0x1dc127(0x1cf)),this[_0x1dc127(0x1b3)](_0x1dc127(0x136),!0x1),this[_0x1dc127(0x144)][_0x1dc127(0xc2)](_0x1dc127(0x147))['to'](this,_0x1dc127(0x136)),this[_0x1dc127(0x1ae)](this[_0x1dc127(0x144)],_0x1dc127(0x18a),()=>{const _0x4dffca=_0x1dc127,{replyId:_0x1e6d45,partIndex:_0x9f1efe}=this[_0x4dffca(0xd9)];this[_0x4dffca(0x136)]=!this[_0x4dffca(0x136)];const {reply:_0x5bb99b}=this[_0x4dffca(0x137)](_0x1e6d45),_0x3b8a36=_0x5bb99b[_0x4dffca(0xc6)]({'showDiff':this[_0x4dffca(0x136)],'groupIndex':_0x9f1efe});this[_0x4dffca(0x144)][_0x4dffca(0x1f6)]({'part':_0x3b8a36[0x0],'renderingStrategy':_0x4dffca(0x10e),'keepErrors':!0x0});}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0x144)],_0x1dc127(0x143),()=>{const _0x1a40db=_0x1dc127,{replyId:_0x478680,partIndex:_0x30e0f6}=this[_0x1a40db(0xd9)];this[_0x1a40db(0x18f)]({'replyId':_0x478680,'partIndex':_0x30e0f6}),this[_0x1a40db(0x144)][_0x1a40db(0xf9)](_0x1a40db(0x1b2));}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0x144)],_0x1dc127(0xb0),()=>{const _0x2edd63=_0x1dc127,{replyId:_0x787d15,partIndex:_0x5239ac}=this[_0x2edd63(0xd9)];this[_0x2edd63(0xe5)]({'replyId':_0x787d15,'partIndex':_0x5239ac}),this[_0x2edd63(0x144)][_0x2edd63(0xf9)](_0x2edd63(0x1b2));}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0x144)],_0x1dc127(0xe3),()=>{const _0x2fa1c2=_0x1dc127,{replyId:_0x304648,partIndex:_0x5e5d5f}=this[_0x2fa1c2(0xd9)];this[_0x2fa1c2(0xdb)]({'replyId':_0x304648,'partIndex':_0x5e5d5f}),this[_0x2fa1c2(0x144)][_0x2fa1c2(0xf9)](_0x2fa1c2(0x108));}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0x144)],_0x1dc127(0x114),()=>{const _0x3712e0=_0x1dc127,{replyId:_0x1a3d70,partIndex:_0x4807b0}=this[_0x3712e0(0xd9)],_0x656dc2=this[_0x3712e0(0x71)](_0x1a3d70,_0x4807b0,_0x3712e0(0x1f7));null!==_0x656dc2&&this[_0x3712e0(0x168)](_0x1a3d70,_0x656dc2);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0x144)],_0x1dc127(0x73),()=>{const _0xf290dc=_0x1dc127,{replyId:_0x37e3ec,partIndex:_0x19ce16}=this[_0xf290dc(0xd9)],_0xee9586=this[_0xf290dc(0x71)](_0x37e3ec,_0x19ce16,_0xf290dc(0x151));null!==_0xee9586&&this[_0xf290dc(0x168)](_0x37e3ec,_0xee9586);}),this[_0x1dc127(0x1ae)](this[_0x1dc127(0x144)],_0x1dc127(0x172),(_0x3306de,{id:_0x160b25})=>{const _0x168123=_0x1dc127;if(_0x168123(0x98)!==_0x160b25)return;const {replyId:_0x371ecb,partIndex:_0x277464}=this[_0x168123(0xd9)];this[_0x168123(0xd9)]=null,this[_0x168123(0xef)][_0x168123(0x85)]({'id':_0x371ecb,'index':_0x277464,'isActive':!0x1});}));}async[_0x12f486(0x1e8)](){const _0xff9820=_0x12f486;this[_0xff9820(0x1ac)]instanceof _0x1ab0f4?this[_0xff9820(0x7e)](this[_0xff9820(0x1ac)]):this[_0xff9820(0x1ae)](this[_0xff9820(0x1ac)][_0xff9820(0xf4)],_0xff9820(0x95),(_0x2402c7,_0x3dc412)=>{const _0x2da804=_0xff9820;_0x3dc412['on'](_0x2da804(0x13f),()=>{const _0x5206b6=_0x2da804;this[_0x5206b6(0x7e)](_0x3dc412);});});const _0x373747=this[_0xff9820(0x1ac)][_0xff9820(0xc9)][_0xff9820(0x11a)](_0xff9820(0x182));let _0x4b53eb=_0x373747;if(_0xff9820(0x192)!=_0x373747||(_0x4b53eb=await this[_0xff9820(0xaa)](),_0x4b53eb))return _0xff9820(0x18b)==_0x4b53eb?this[_0xff9820(0x9b)]():this[_0xff9820(0x156)](_0x4b53eb);}async[_0x12f486(0x1d2)](){const _0x128c93=_0x12f486;return await this[_0x128c93(0x1f3)](),this[_0x128c93(0x116)][_0x128c93(0x154)](),super[_0x128c93(0x1d2)]();}[_0x12f486(0xe5)](_0x33292e){const _0xfd4326=_0x12f486,_0x4dc5af=_0x4b9b70(this[_0xfd4326(0x1ac)]);if(!_0x4dc5af[_0xfd4326(0x8f)][_0xfd4326(0x9e)](_0xfd4326(0xc1)))throw new _0x4b2b76(_0xfd4326(0x90),null);const _0x33d3ee=this[_0xfd4326(0x1ac)][_0xfd4326(0x8f)][_0xfd4326(0x11a)](_0xfd4326(0xb6)),{reply:_0xa65adf,interaction:_0x312d0c}=this[_0xfd4326(0x137)](_0x33292e[_0xfd4326(0x79)]),_0x36cad7=this[_0xfd4326(0x1a6)](_0x33292e[_0xfd4326(0x79)],_0x33292e[_0xfd4326(0x152)]),_0x45eb0d=void 0x0!==_0x33292e[_0xfd4326(0x152)]?[_0xa65adf[_0xfd4326(0x122)][_0x33292e[_0xfd4326(0x152)]]]:_0xa65adf[_0xfd4326(0x122)][_0xfd4326(0x10a)](_0x15cf14=>_0xfd4326(0x102)==_0x15cf14[_0xfd4326(0x6d)]),_0x211458=_0x45eb0d[_0xfd4326(0x1d1)](_0x2e0fe6=>_0xa65adf[_0xfd4326(0x122)][_0xfd4326(0x75)](_0x2e0fe6));if(!_0x36cad7||_0xfd4326(0x1aa)==_0x36cad7[_0xfd4326(0x86)][_0xfd4326(0x19c)][_0xfd4326(0x188)])return void _0x211458[_0xfd4326(0xbe)](_0x5f1038=>_0xa65adf[_0xfd4326(0xcd)](_0x5f1038,_0xfd4326(0x11d)));_0x211458[_0xfd4326(0xbe)](_0x21fa3c=>_0xa65adf[_0xfd4326(0xcd)](_0x21fa3c,_0xfd4326(0x1b2)));const _0x23ec33=_0x58de2c({'editor':_0x4dc5af,'reply':_0xa65adf,'interaction':_0x312d0c,'groups':_0x45eb0d,'transform':!0x0,'documentCompare':_0x33d3ee,'documentCompareOptions':{'anchor':_0xfd4326(0x190),'markDeletions':!0x0}});let _0x43b986;_0x36cad7&&this[_0xfd4326(0x1da)](_0x36cad7[_0xfd4326(0x86)]),_0x4dc5af[_0xfd4326(0x19a)][_0xfd4326(0x14e)](_0x290941=>{const _0x17ea79=_0xfd4326;_0x43b986=_0x290941[_0x17ea79(0x1eb)],_0x4dc5af[_0x17ea79(0x8f)][_0x17ea79(0x11a)](_0x17ea79(0x194))[_0x17ea79(0x16f)](_0x23ec33),this[_0x17ea79(0xf0)][_0x17ea79(0xa0)](_0x17ea79(0x1ad));}),this[_0xfd4326(0xbb)][_0xfd4326(0x1b3)](_0x43b986,{'interactionId':_0x312d0c['id'],'replyId':_0xa65adf['id'],'indexes':_0x211458[_0xfd4326(0x12e)]()}),this[_0xfd4326(0x8b)](_0xa65adf);}[_0x12f486(0x18f)](_0x22f3ae){const _0x1a54bd=_0x12f486,_0x2b4987=_0x4b9b70(this[_0x1a54bd(0x1ac)]),_0x5b34a9=this[_0x1a54bd(0x1ac)][_0x1a54bd(0x8f)][_0x1a54bd(0x11a)](_0x41a947),{reply:_0x1edfe4,interaction:_0x58ec33}=this[_0x1a54bd(0x137)](_0x22f3ae[_0x1a54bd(0x79)]),_0x4f5cee=this[_0x1a54bd(0x1a6)](_0x22f3ae[_0x1a54bd(0x79)],_0x22f3ae[_0x1a54bd(0x152)]),_0x435d12=void 0x0!==_0x22f3ae[_0x1a54bd(0x152)]?[_0x1edfe4[_0x1a54bd(0x122)][_0x22f3ae[_0x1a54bd(0x152)]]]:_0x1edfe4[_0x1a54bd(0x122)][_0x1a54bd(0x10a)](_0x918551=>_0x1a54bd(0x102)==_0x918551[_0x1a54bd(0x6d)]),_0x5efc18=_0x435d12[_0x1a54bd(0x1d1)](_0x47d412=>_0x1edfe4[_0x1a54bd(0x122)][_0x1a54bd(0x75)](_0x47d412));if(!_0x4f5cee||_0x1a54bd(0x1aa)==_0x4f5cee[_0x1a54bd(0x86)][_0x1a54bd(0x19c)][_0x1a54bd(0x188)])return void _0x5efc18[_0x1a54bd(0xbe)](_0x3e802d=>_0x1edfe4[_0x1a54bd(0xcd)](_0x3e802d,_0x1a54bd(0x11d)));_0x5efc18[_0x1a54bd(0xbe)](_0x1d2cdc=>_0x1edfe4[_0x1a54bd(0xcd)](_0x1d2cdc,_0x1a54bd(0x1b2)));const _0xeb5e3b=_0x58de2c({'editor':_0x2b4987,'reply':_0x1edfe4,'interaction':_0x58ec33,'groups':_0x435d12,'transform':!0x0,'documentCompare':_0x5b34a9,'documentCompareOptions':{'anchor':_0x1a54bd(0x190),'markDeletions':!0x1}});let _0x6cb429;_0x4f5cee&&this[_0x1a54bd(0x1da)](_0x4f5cee[_0x1a54bd(0x86)]),_0x2b4987[_0x1a54bd(0x19a)][_0x1a54bd(0x14e)](_0x32685f=>{const _0xe06463=_0x1a54bd;_0x6cb429=_0x32685f[_0xe06463(0x1eb)];for(const _0x57c3cd of _0xeb5e3b)_0x57c3cd[_0xe06463(0xfc)]=_0x2b4987[_0xe06463(0x19a)][_0xe06463(0x7b)][_0xe06463(0x1c4)],_0x366e90(_0x2b4987,_0x57c3cd),_0x32685f[_0xe06463(0x1eb)][_0xe06463(0x1d3)](_0x57c3cd),_0x2b4987[_0xe06463(0x19a)][_0xe06463(0xa9)](_0x57c3cd);}),this[_0x1a54bd(0xbb)][_0x1a54bd(0x1b3)](_0x6cb429,{'interactionId':_0x58ec33['id'],'replyId':_0x1edfe4['id'],'indexes':_0x5efc18[_0x1a54bd(0x12e)]()}),this[_0x1a54bd(0x8b)](_0x1edfe4);}[_0x12f486(0xdb)](_0x184437){const _0x23c35f=_0x12f486,{reply:_0x467f13}=this[_0x23c35f(0x137)](_0x184437[_0x23c35f(0x79)]);_0x467f13[_0x23c35f(0xcd)](_0x184437[_0x23c35f(0x152)],_0x23c35f(0x108));}[_0x12f486(0x168)](_0x1cb438,_0x356f63){const _0xd0de7=_0x12f486;if(!this[_0xd0de7(0x144)])return;const {reply:_0x2bb636}=this[_0xd0de7(0x137)](_0x1cb438),_0x340a0f=_0x2bb636[_0xd0de7(0xc6)]({'showDiff':this[_0xd0de7(0x136)]});let _0x54a150,_0x45e06c;if(void 0x0!==_0x356f63?(_0x45e06c=_0x340a0f[_0xd0de7(0x186)](_0x12b688=>_0x12b688[_0xd0de7(0x1ab)]==_0x356f63),_0x54a150=_0x45e06c?.[_0xd0de7(0x1ab)]):(_0x45e06c=_0x340a0f[0x0],_0x54a150=_0x45e06c[_0xd0de7(0x1ab)]),this[_0xd0de7(0xd9)]?.[_0xd0de7(0x79)]==_0x1cb438&&this[_0xd0de7(0xd9)]?.[_0xd0de7(0x152)]==_0x54a150)return;const _0x2d37c0=this[_0xd0de7(0xd7)](_0x1cb438,_0x2bb636,_0x45e06c);if(!_0x2d37c0)return void this[_0xd0de7(0x144)][_0xd0de7(0x18d)]();this[_0xd0de7(0xd9)]={'replyId':_0x1cb438,'partIndex':_0x54a150},this[_0xd0de7(0x1da)](_0x2d37c0,!0x0);const _0xc41e9b=this[_0xd0de7(0x71)](_0x1cb438,_0x54a150,_0xd0de7(0x1f7));this[_0xd0de7(0x144)][_0xd0de7(0x1f6)]({'part':_0x45e06c,'renderingStrategy':_0xd0de7(0x10e)}),this[_0xd0de7(0x144)][_0xd0de7(0x1a0)]({'index':_0x54a150,'title':_0x541ff7(this[_0xd0de7(0x1ac)][_0xd0de7(0xbf)],_0xd0de7(0xdf),(_0x54a150+0x1)[_0xd0de7(0x1dc)]()),'showRotator':null!==_0xc41e9b,'ranges':[_0x2d37c0],'areActionsDisabled':_0x2bb636[_0xd0de7(0xa5)]}),this[_0xd0de7(0x144)][_0xd0de7(0xf9)](_0xd0de7(0x102)),this[_0xd0de7(0xef)][_0xd0de7(0x13c)](_0x1cb438,_0x54a150),this[_0xd0de7(0xef)][_0xd0de7(0x85)]({'id':_0x1cb438,'index':_0x54a150,'isActive':!0x0});}[_0x12f486(0x71)](_0x11654d,_0x32bcb8,_0xe115c6){const _0x48c3d0=_0x12f486,{reply:_0x99aff1}=this[_0x48c3d0(0x137)](_0x11654d),_0x3b2501=_0x99aff1[_0x48c3d0(0xc6)]({'showDiff':this[_0x48c3d0(0x136)]});if(0x1==_0x3b2501[_0x48c3d0(0x84)])return null;const _0x1dbb90=_0x3b2501[_0x48c3d0(0x176)](_0x50c627=>_0x50c627[_0x48c3d0(0x1ab)]==_0x32bcb8),_0x21a045=_0x48c3d0(0x1f7)==_0xe115c6?0x1:-0x1;let _0x2d61d1=_0x3b2501['at']((_0x1dbb90+_0x21a045)%_0x3b2501[_0x48c3d0(0x84)])[_0x48c3d0(0x1ab)],_0x40012f=_0x3b2501[_0x2d61d1];for(;!this[_0x48c3d0(0xd7)](_0x11654d,_0x99aff1,_0x40012f);){if(_0x2d61d1=_0x3b2501['at']((_0x2d61d1+_0x21a045)%_0x3b2501[_0x48c3d0(0x84)])[_0x48c3d0(0x1ab)],_0x2d61d1===_0x1dbb90)return null;_0x40012f=_0x3b2501[_0x2d61d1];}return _0x2d61d1;}[_0x12f486(0xd7)](_0x15014a,_0x1a29ef,_0x19b613){const _0x123598=_0x12f486,_0x1395b4=_0x1a29ef[_0x123598(0x122)];if(!_0x19b613[_0x123598(0x181)])return null;const _0x1180df=_0x1395b4[_0x123598(0x186)](_0x37020e=>_0x37020e[_0x123598(0x1ab)]==_0x19b613[_0x123598(0x1ab)]);if(_0x123598(0x102)!==_0x1180df?.[_0x123598(0x6d)])return null;const _0x30dd03=this[_0x123598(0x1a6)](_0x15014a,_0x19b613[_0x123598(0x1ab)]);if(!_0x30dd03)return null;const {range:_0x33c880,currentIndex:_0x210f55}=_0x30dd03;return _0x123598(0x1aa)==_0x33c880[_0x123598(0x19c)][_0x123598(0x188)]?(_0x1a29ef[_0x123598(0xcd)](_0x210f55,_0x123598(0x11d)),null):_0x30dd03[_0x123598(0x86)];}[_0x12f486(0x1a6)](_0x3b3573,_0x10173e){const _0x255021=_0x12f486,_0x439c5f=_0x4b9b70(this[_0x255021(0x1ac)]),{reply:_0x401849,interaction:_0x48e03d}=this[_0x255021(0x137)](_0x3b3573),_0x1327cc=_0x401849[_0x255021(0x122)][_0x255021(0x10a)](_0x4820ef=>_0x255021(0x102)==_0x4820ef[_0x255021(0x6d)]),_0x5456e2=_0x1327cc[_0x255021(0x1d1)](_0x4872e7=>_0x401849[_0x255021(0x122)][_0x255021(0x75)](_0x4872e7));void 0x0===_0x10173e&&(_0x10173e=_0x5456e2[0x0]);const _0x2c5a6a=_0x5456e2[_0x255021(0x75)](_0x10173e);if(-0x1==_0x2c5a6a)return null;const _0x4d7819=_0x1327cc[_0x2c5a6a],_0x319692=new _0x8e65d3([]),_0x55b9ae=new _0x8e65d3([]);for(const _0x2a7b16 of _0x4d7819[_0x255021(0xea)])if(_0x255021(0x107)!=_0x2a7b16[_0x255021(0x1be)]&&_0x55b9ae[_0x255021(0xc3)][_0x255021(0xdd)](_0x2a7b16[_0x255021(0x11f)][_0x255021(0x193)](!0x0)),_0x255021(0x18b)!=_0x2a7b16[_0x255021(0x1be)]){const _0x3e06a0=_0xd10b12(_0x5e682a=>_0xa01188(_0x5e682a,_0x255021(0x1c1))==_0x2a7b16['id'],_0x401849[_0x255021(0x1b0)],!0x0);_0x319692[_0x255021(0xc3)][_0x255021(0xdd)](_0x3e06a0[_0x255021(0x193)](!0x0));}if(0x0==_0x319692[_0x255021(0xc3)][_0x255021(0x84)]){if(_0x4d7819[_0x255021(0xea)][0x0][_0x255021(0xd8)]){const _0x2de812=_0x2b1db6(_0x255021(0x1c1),_0x4d7819[_0x255021(0xea)][0x0][_0x255021(0xd8)],_0x401849[_0x255021(0x1b0)]);_0x319692[_0x255021(0xc3)][_0x255021(0x139)](_0x2de812[_0x255021(0x193)](!0x0)),_0x55b9ae[_0x255021(0xc3)][_0x255021(0x139)](_0x2de812[_0x255021(0x193)](!0x0)),_0x2de812[_0x255021(0x14b)]&&(_0x319692[_0x255021(0xc3)][_0x255021(0xdd)](_0x2de812[_0x255021(0x14b)][_0x255021(0x193)](!0x0)),_0x55b9ae[_0x255021(0xc3)][_0x255021(0xdd)](_0x2de812[_0x255021(0x14b)][_0x255021(0x193)](!0x0)));}else{const _0x1531cb=_0x401849[_0x255021(0x1b0)][_0x255021(0xc3)][0x0];if(!_0x1531cb)return null;_0x319692[_0x255021(0xc3)][_0x255021(0xdd)](_0x1531cb[_0x255021(0x193)](!0x0)),_0x55b9ae[_0x255021(0xc3)][_0x255021(0xdd)](_0x1531cb[_0x255021(0x193)](!0x0));}}const _0x420e24=_0x48e03d[_0x255021(0x117)](),_0x53a6f5=_0x439c5f[_0x255021(0x1c6)][_0x255021(0x1e9)](_0x420e24[_0x255021(0x1bd)]),_0x419a89=_0x52f5de(_0x319692),_0x16c708=_0x439c5f[_0x255021(0x1c6)][_0x255021(0x1e9)](_0x419a89),_0x414649=_0x439c5f[_0x255021(0x1c6)][_0x255021(0x1e9)](_0x419a89),_0x527068=_0x439c5f[_0x255021(0x19a)][_0x255021(0x13b)](_0x16c708,0x0),_0x53009d=_0x52f5de(_0x55b9ae),_0x1042e5={'anchor':_0x527068,'markDeletions':!0x1},_0x4cecbd=_0x439c5f[_0x255021(0x8f)][_0x255021(0x11a)](_0x41a947)[_0x255021(0x159)](_0x419a89,_0x53009d,_0x1042e5)[_0x255021(0xe1)]();if(!_0x4cecbd[_0x255021(0x84)])return null;_0x439c5f[_0x255021(0x19a)][_0x255021(0x14e)](_0x4402d5=>{const _0xbbca87=_0x255021;for(const _0x45ce03 of _0x4cecbd)if(_0xbbca87(0x8c)==_0x45ce03[_0xbbca87(0x1be)]){const _0x29dded=_0x45ce03[_0xbbca87(0x10b)],_0xefe669=_0x45ce03[_0xbbca87(0x1ee)],_0x2adf78=new _0x1604bc(_0x29dded,_0xefe669);_0x4402d5[_0xbbca87(0x1eb)][_0xbbca87(0x1d3)](_0x2adf78),_0x439c5f[_0xbbca87(0x19a)][_0xbbca87(0xa9)](_0x2adf78);}else _0xbbca87(0x8d)!==_0x45ce03[_0xbbca87(0x1be)]&&(_0x45ce03[_0xbbca87(0xfc)]=null,_0x45ce03[_0xbbca87(0x1d9)]=!0x1,_0x4402d5[_0xbbca87(0x1eb)][_0xbbca87(0x1d3)](_0x45ce03),_0x439c5f[_0xbbca87(0x19a)][_0xbbca87(0xa9)](_0x45ce03));});const _0x47af60=_0x572c78(_0x439c5f,_0x4cecbd,_0x16c708);_0x52bea3(_0x439c5f[_0x255021(0x19a)],_0x47af60);const _0x2dfeb4=_0x47af60[_0x255021(0x1b4)]()[_0x255021(0x9a)][_0x255021(0x1e2)][_0x255021(0x12e)](),_0x2fc32c=_0x47af60[_0x255021(0x1b4)]()[_0x255021(0x14d)][_0x255021(0x1e2)][_0x255021(0x12e)](),_0x6f1d01=[];let _0x3bab61=_0x16c708,_0x562844=_0x414649;for(let _0x57a858=0x0;_0x57a858<_0x2fc32c[_0x255021(0x84)];_0x57a858++){const _0x3ba85=_0x3bab61[_0x255021(0x18c)]-_0x2fc32c[_0x57a858];_0x6f1d01[_0x57a858]=_0x562844[_0x255021(0x18c)]-_0x3ba85,_0x3bab61=_0x3bab61[_0x255021(0x1af)](_0x2fc32c[_0x57a858]),_0x562844=_0x562844[_0x255021(0x1af)](_0x6f1d01[_0x57a858]);}const _0x7e705f=_0x439c5f[_0x255021(0x19a)][_0x255021(0xe9)](_0x439c5f[_0x255021(0x19a)][_0x255021(0x184)](_0x414649,_0x2dfeb4),_0x439c5f[_0x255021(0x19a)][_0x255021(0x184)](_0x414649,_0x6f1d01)),_0x3d7af3=_0x414649[_0x255021(0x16e)](0x0)[_0x255021(0x162)](_0xdc6d4f),_0x5215e5=Array[_0x255021(0xda)](_0x53a6f5[_0x255021(0x1e6)]())[_0x255021(0x186)](_0x1b4e2e=>_0x1b4e2e[_0x255021(0x162)](_0xdc6d4f)==_0x3d7af3)[_0x255021(0x158)](),_0x579dfc=_0x7e705f[_0x255021(0x9a)][_0x255021(0x1e2)][_0x255021(0x12e)](),_0x127d6e=_0x7e705f[_0x255021(0x14d)][_0x255021(0x1e2)][_0x255021(0x12e)]();_0x579dfc[0x0]=_0x5215e5[0x0]+_0x579dfc[0x0],_0x127d6e[0x0]=_0x5215e5[0x0]+_0x127d6e[0x0];let _0x298940=_0x439c5f[_0x255021(0x19a)][_0x255021(0xe9)](_0x439c5f[_0x255021(0x19a)][_0x255021(0x184)](_0x439c5f[_0x255021(0x19a)][_0x255021(0x7b)][_0x255021(0xfe)](),_0x579dfc),_0x439c5f[_0x255021(0x19a)][_0x255021(0x184)](_0x439c5f[_0x255021(0x19a)][_0x255021(0x7b)][_0x255021(0xfe)](),_0x127d6e));const _0xd5d8de=_0x439c5f[_0x255021(0x19a)][_0x255021(0x7b)][_0x255021(0x72)][_0x255021(0xe1)](_0x420e24[_0x255021(0x1c4)]);for(const _0x1aad67 of _0xd5d8de)_0x298940=_0x1ca952[_0x255021(0x17c)](_0x298940[_0x255021(0x1e4)](_0x1aad67));return{'range':_0x298940,'currentIndex':_0x10173e};}[_0x12f486(0x7e)](_0x2a2496){const _0x34d6e2=_0x12f486;if(!_0x2a2496[_0x34d6e2(0x8f)][_0x34d6e2(0x9e)](_0x34d6e2(0x19d)))return;const _0xa7923a=_0x2a2496[_0x34d6e2(0x82)][_0x34d6e2(0x11a)](_0x34d6e2(0x128)),_0x439b46=_0x2a2496[_0x34d6e2(0x82)][_0x34d6e2(0x11a)](_0x34d6e2(0x1a9));this[_0x34d6e2(0x1ae)](_0xa7923a,_0x34d6e2(0x1de),(_0x154fae,_0x30a94e,_0x452b90)=>{const _0x785b1d=_0x34d6e2,_0x1ff3c3=this[_0x785b1d(0xbb)][_0x785b1d(0x11a)](_0x30a94e);if(!_0x1ff3c3)return;const _0x1b2866=this[_0x785b1d(0x120)][_0x785b1d(0x7c)](_0x1ff3c3[_0x785b1d(0x1e0)])[_0x785b1d(0x1b5)](_0x1ff3c3[_0x785b1d(0x79)]);_0x1ff3c3[_0x785b1d(0xba)][_0x785b1d(0xbe)](_0x32eb98=>_0x1b2866[_0x785b1d(0xcd)](_0x32eb98,_0x785b1d(0x102))),this[_0x785b1d(0xbb)][_0x785b1d(0x195)](_0x30a94e),this[_0x785b1d(0xbb)][_0x785b1d(0x1b3)](_0x452b90,_0x1ff3c3);}),this[_0x34d6e2(0x1ae)](_0x439b46,_0x34d6e2(0x1de),(_0x41fa79,_0x445968,_0xfd1f94)=>{const _0x85955f=_0x34d6e2,_0x48157f=this[_0x85955f(0xbb)][_0x85955f(0x11a)](_0x445968);if(!_0x48157f)return;const _0x3c32dd=this[_0x85955f(0x120)][_0x85955f(0x7c)](_0x48157f[_0x85955f(0x1e0)])[_0x85955f(0x1b5)](_0x48157f[_0x85955f(0x79)]);_0x48157f[_0x85955f(0xba)][_0x85955f(0xbe)](_0x47ec15=>_0x3c32dd[_0x85955f(0xcd)](_0x47ec15,_0x85955f(0x1b2))),this[_0x85955f(0xbb)][_0x85955f(0x195)](_0x445968),this[_0x85955f(0xbb)][_0x85955f(0x1b3)](_0xfd1f94,_0x48157f);});}async[_0x12f486(0x156)](_0x2c3a65){const _0x24969d=_0x12f486;this[_0x24969d(0x1ac)][_0x24969d(0x8f)][_0x24969d(0x9e)](_0x24969d(0x1cf))&&this[_0x24969d(0x1ac)][_0x24969d(0x8f)][_0x24969d(0x11a)](_0x24969d(0x1cf))[_0x24969d(0x18d)](),(this[_0x24969d(0x1ac)][_0x24969d(0x8f)][_0x24969d(0x11a)](_0x575159)[_0x24969d(0xff)][_0x24969d(0x16c)](_0x24969d(0xe7)),this[_0x24969d(0xef)][_0x24969d(0x185)](_0x24969d(0x10e)),this[_0x24969d(0xef)][_0x24969d(0x12d)](!0x0),await this[_0x24969d(0x1f3)]());try{await this[_0x24969d(0x175)][_0x24969d(0xdc)](_0x2c3a65)[_0x24969d(0x113)](),await this[_0x24969d(0x9b)](_0x2c3a65),this[_0x24969d(0x1cd)]('\x20'),await this[_0x24969d(0x120)][_0x24969d(0x14f)](_0x2c3a65,this[_0x24969d(0xf0)][_0x24969d(0x87)]),this[_0x24969d(0x120)][_0x24969d(0xd5)]()&&this[_0x24969d(0x1ec)]();}catch(_0x236fa9){this[_0x24969d(0xef)][_0x24969d(0x173)]({'errorMessage':_0x541ff7(this[_0x24969d(0x1ac)][_0x24969d(0xbf)],_0x24969d(0x17d)),'id':_0x2c3a65}),this[_0x24969d(0x145)](new _0x4b2b76(_0x24969d(0x103),this,{'error':_0x236fa9}));}finally{this[_0x24969d(0xef)][_0x24969d(0x17a)](),this[_0x24969d(0xef)][_0x24969d(0x185)](_0x24969d(0x197)),this[_0x24969d(0xef)][_0x24969d(0x12d)](!0x1);}}async[_0x12f486(0xaa)](){const _0x476a3d=_0x12f486,_0x519c79=this[_0x476a3d(0x175)][_0x476a3d(0xfb)](this[_0x476a3d(0xe4)](),{'limit':0x1,'sortBy':_0x476a3d(0x1cc)});try{const _0x35ba80=await _0x519c79[_0x476a3d(0x1d8)]();return _0x35ba80[_0x476a3d(0x84)]?_0x35ba80[0x0]['id']:_0x476a3d(0x18b);}catch(_0x2a4274){return this[_0x476a3d(0xef)][_0x476a3d(0x173)]({'errorMessage':_0x541ff7(this[_0x476a3d(0x1ac)][_0x476a3d(0xbf)],_0x476a3d(0x17d)),'id':_0x14d190()}),this[_0x476a3d(0x145)](new _0x4b2b76(_0x476a3d(0x1b6),this,{'error':_0x2a4274})),this[_0x476a3d(0xef)][_0x476a3d(0x12d)](!0x1),this[_0x476a3d(0xef)][_0x476a3d(0xa2)](),null;}}[_0x12f486(0x1dd)](_0xdbff9b){const _0x4aa16e=_0x12f486;this[_0x4aa16e(0x120)]['id']===_0xdbff9b&&this[_0x4aa16e(0x9b)]();}[_0x12f486(0x1ec)](){const _0x4bc248=_0x12f486;this[_0x4bc248(0x120)]?.[_0x4bc248(0x70)](_0x541ff7(this[_0x4bc248(0x1ac)][_0x4bc248(0xbf)],_0x4bc248(0xd3)));}async[_0x12f486(0x129)](){const _0x1c0804=_0x12f486,_0xdf1bb2=this[_0x1c0804(0xf0)][_0x1c0804(0x170)]();this[_0x1c0804(0x120)]?.[_0x1c0804(0x88)](_0xdf1bb2),this[_0x1c0804(0x1ec)]();}[_0x12f486(0x165)](){const _0x4d45b7=_0x12f486;this[_0x4d45b7(0x120)]?.[_0x4d45b7(0x13e)]();}[_0x12f486(0x132)](){const _0x170816=_0x12f486;this[_0x170816(0xef)][_0x170816(0x132)]();}async[_0x12f486(0x167)](){const _0x28afb5=_0x12f486;await this[_0x28afb5(0x9b)]();}async[_0x12f486(0x142)]({message:_0x199b34,attributes:_0x52e314}){const _0x5580c6=_0x12f486;await this[_0x5580c6(0x106)]({'userMessage':_0x199b34,'attributes':_0x52e314});}[_0x12f486(0xe4)](){const _0x5d49dc=_0x12f486,_0x4d3556=this[_0x5d49dc(0x1ac)][_0x5d49dc(0xc9)][_0x5d49dc(0x11a)](_0x5d49dc(0x7a));if(!_0x4d3556)throw new _0x4b2b76(_0x5d49dc(0x1c8),this);return _0x4d3556;}async[_0x12f486(0x9b)](_0x7c8731){const _0x5b7549=_0x12f486;try{this[_0x5b7549(0xef)][_0x5b7549(0x15f)](),await this[_0x5b7549(0xe8)](_0x7c8731);}catch(_0xc78bdf){this[_0x5b7549(0xef)][_0x5b7549(0x173)]({'errorMessage':_0x541ff7(this[_0x5b7549(0x1ac)][_0x5b7549(0xbf)],_0x5b7549(0x1bf)),'id':_0x7c8731||_0x14d190()}),console[_0x5b7549(0x1f2)](_0xc78bdf),this[_0x5b7549(0x120)]=void 0x0,this[_0x5b7549(0xef)][_0x5b7549(0xa2)]();}}async[_0x12f486(0xe8)](_0x2d8c44){const _0x1d59e0=_0x12f486;let _0x2ce41e;this[_0x1d59e0(0x1ac)][_0x1d59e0(0x8f)][_0x1d59e0(0x9e)](_0x1d59e0(0x1cf))&&this[_0x1d59e0(0x1ac)][_0x1d59e0(0x8f)][_0x1d59e0(0x11a)](_0x1d59e0(0x1cf))[_0x1d59e0(0x18d)](),_0x2d8c44||!this[_0x1d59e0(0x120)]?_0x2ce41e=this[_0x1d59e0(0x1ac)][_0x1d59e0(0xc9)][_0x1d59e0(0x11a)](_0x1d59e0(0x121)):this[_0x1d59e0(0xef)][_0x1d59e0(0x177)]&&(_0x2ce41e=this[_0x1d59e0(0x120)][_0x1d59e0(0xa1)]['id']),await this[_0x1d59e0(0x1f3)]();const _0x115d26=this[_0x1d59e0(0xe4)](),_0x2ab835=_0x2d8c44||_0x14d190();this[_0x1d59e0(0x120)]=new _0x2fc456({'connector':this[_0x1d59e0(0x175)],'chatModels':this[_0x1d59e0(0x1a2)],'selectedModelId':_0x2ce41e,'conversationId':_0x2ab835,'group':_0x115d26,'getEditor':()=>_0x4b9b70(this[_0x1d59e0(0x1ac)]),'isFromHistory':!!_0x2d8c44}),this[_0x1d59e0(0x120)][_0x1d59e0(0x16a)](_0x1d59e0(0x180),_0x1d59e0(0x105))['to'](this),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0xe2),(_0x207f60,_0x3c932a)=>{const _0xcb238b=_0x1d59e0;this[_0xcb238b(0xef)][_0xcb238b(0xce)](_0x3c932a),this[_0xcb238b(0xef)][_0xcb238b(0x1f0)](),this[_0xcb238b(0xef)][_0xcb238b(0x1ea)](),this[_0xcb238b(0xef)][_0xcb238b(0x1a5)](),_0x2d8c44||(this[_0xcb238b(0xef)][_0xcb238b(0x6c)](),this[_0xcb238b(0x1ec)]());}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x92),(_0x4921c2,_0x14b799)=>{const _0x4444a3=_0x1d59e0;this[_0x4444a3(0xef)][_0x4444a3(0x19b)](_0x14b799[_0x4444a3(0x199)]);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x78),(_0x5ee57d,_0x2fa841)=>{const _0x1dcfd4=_0x1d59e0;this[_0x1dcfd4(0xef)][_0x1dcfd4(0x1e1)](_0x2fa841);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x1c3),()=>{const _0xa93082=_0x1d59e0,_0x54114c=this[_0xa93082(0xef)][_0xa93082(0xa8)]({'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});this[_0xa93082(0xef)][_0xa93082(0x1f4)](_0x54114c);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x14c),()=>{const _0x26ed79=_0x1d59e0,_0x15739a=this[_0x26ed79(0xef)][_0x26ed79(0xa8)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});this[_0x26ed79(0xef)][_0x26ed79(0x1f4)](_0x15739a);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x17e),(_0x27a643,_0x36d3ba)=>{const _0x4296d0=_0x1d59e0;this[_0x4296d0(0xef)][_0x4296d0(0xca)](_0x36d3ba,{'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x196),(_0x420333,_0xe81147)=>{const _0x290a5e=_0x1d59e0;this[_0x290a5e(0xef)][_0x290a5e(0xca)](_0xe81147,{'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x105),()=>{const _0x32af26=_0x1d59e0;this[_0x32af26(0xef)][_0x32af26(0x12b)]();}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0xab),async()=>{const _0x23b089=_0x1d59e0;await this[_0x23b089(0xef)][_0x23b089(0x12f)]();}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x10c),(_0x48d4a0,_0x8fcf5a)=>{const _0x26f276=_0x1d59e0;this[_0x26f276(0xef)][_0x26f276(0x13d)](_0x8fcf5a['id']);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x161),(_0x52ce72,_0x24bed9,_0x51af18)=>{const _0x17cb2a=_0x1d59e0;this[_0x17cb2a(0x1cd)](_0x24bed9,_0x51af18);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x140),(_0x34e583,_0x225350)=>{const _0x5e950f=_0x1d59e0;_0x5e950f(0x89)===_0x225350[_0x5e950f(0x1be)]?this[_0x5e950f(0xef)][_0x5e950f(0x12c)](_0x225350):this[_0x5e950f(0xef)][_0x5e950f(0x169)](_0x225350);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x1d4),async(_0x4efdbe,_0x1281e4)=>{const _0x384841=_0x1d59e0;await this[_0x384841(0x148)]({'reply':_0x1281e4});}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x1c5),(_0x3d0826,{reply:_0x15a3b0,index:_0x365d6a,state:_0xc1736e})=>{const _0x40a092=_0x1d59e0;this[_0x40a092(0xef)][_0x40a092(0xbd)]({'id':_0x15a3b0['id'],'index':_0x365d6a,'state':_0xc1736e}),this[_0x40a092(0xd9)]?.[_0x40a092(0x79)][_0x40a092(0x1b9)](_0x15a3b0['id'])&&this[_0x40a092(0xd9)]?.[_0x40a092(0x152)]==_0x365d6a&&this[_0x40a092(0x144)]?.[_0x40a092(0xf9)](_0xc1736e);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0xa7),(_0x14c886,_0x21abac)=>{const _0x42c4e6=_0x1d59e0;if(this[_0x42c4e6(0xef)][_0x42c4e6(0xec)](_0x21abac[_0x42c4e6(0xf5)],_0x21abac[_0x42c4e6(0x1ca)]),_0x42c4e6(0x119)===_0x21abac[_0x42c4e6(0xf5)][_0x42c4e6(0x1be)]){const _0x1f6824=[..._0x4b9b70(this[_0x42c4e6(0x1ac)])[_0x42c4e6(0x19a)][_0x42c4e6(0x7b)][_0x42c4e6(0x119)][_0x42c4e6(0x10f)]()];this[_0x42c4e6(0xf0)][_0x42c4e6(0x1ed)](_0x1f6824,_0x42c4e6(0x14a)+this[_0x42c4e6(0x120)]?.['id']);}}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x10d),(_0x3cf9dc,_0x4f0aeb)=>{const _0xd2094a=_0x1d59e0;this[_0xd2094a(0xef)][_0xd2094a(0x109)](_0x4f0aeb[_0xd2094a(0x9f)]),_0xd2094a(0x149)==_0x4f0aeb[_0xd2094a(0x9f)]&&this[_0xd2094a(0x165)](),_0xd2094a(0x119)===_0x4f0aeb[_0xd2094a(0x1be)]&&this[_0xd2094a(0xf0)][_0xd2094a(0xa0)](_0xd2094a(0x14a)+this[_0xd2094a(0x120)]?.['id']);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x13a),(_0x54fc61,_0x5c4dd)=>{const _0x127022=_0x1d59e0;this[_0x127022(0xef)][_0x127022(0x6b)](_0x5c4dd[_0x127022(0xf5)][_0x127022(0x9f)],_0x5c4dd[_0x127022(0x1ca)]);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0xde),(_0x5a11e3,_0x4a66ca)=>{const _0x48f590=_0x1d59e0;this[_0x48f590(0xef)][_0x48f590(0x104)](_0x4a66ca[_0x48f590(0xfd)]);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x1db),(_0x520ecf,_0x19c8bc)=>{const _0x1297a8=_0x1d59e0;this[_0x1297a8(0xef)][_0x1297a8(0x97)](_0x19c8bc[_0x1297a8(0xee)]);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0xbc),(_0x25b6d6,_0x30b088)=>{const _0x4f6365=_0x1d59e0;this[_0x4f6365(0xef)][_0x4f6365(0x1d7)](_0x30b088[_0x4f6365(0x11b)],_0x30b088[_0x4f6365(0x164)],_0x30b088[_0x4f6365(0x99)],_0x30b088[_0x4f6365(0xfa)]);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x81),(_0x441e89,_0x552cf7)=>{const _0x1e07d2=_0x1d59e0;this[_0x1e07d2(0xef)][_0x1e07d2(0x1ef)](_0x552cf7[_0x1e07d2(0x11b)],_0x552cf7[_0x1e07d2(0x19f)],_0x552cf7[_0x1e07d2(0x150)]);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x1c9),(_0xfb5aa5,_0x378fd4)=>{const _0x2433bf=_0x1d59e0;this[_0x2433bf(0xef)][_0x2433bf(0xd6)](_0x378fd4);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x83),async(_0x4028f1,_0x16b1aa)=>{const _0x3b54c6=_0x1d59e0,_0x5e279d=(await this[_0x3b54c6(0x1a2)][_0x3b54c6(0x74)]())[_0x3b54c6(0x186)](_0x15af02=>_0x15af02['id']===_0x16b1aa[_0x3b54c6(0xa1)]?.['id'])||null;this[_0x3b54c6(0xef)][_0x3b54c6(0x1d0)](_0x5e279d,_0x16b1aa[_0x3b54c6(0xd2)]);}),this[_0x1d59e0(0x120)]['on'](_0x1d59e0(0x1f2),(_0x2e2053,{error:_0x342019,interactionId:_0x233989,fileName:_0x23b837,url:_0x4f2192,sourceId:_0x10b14a,sourceLabel:_0x90e268})=>{const _0x547729=_0x1d59e0,_0x2ee824=_0x233989?_0x233989+':'+_0x14d190():_0x14d190();_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x130))?this[_0x547729(0xef)][_0x547729(0xc8)]({'staticMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x93)),'id':_0x2ee824}):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x1b6))||_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x9d))?(this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x1bf)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019)):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0xb9))?this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x198),_0x23b837),'id':_0x2ee824}):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x189))?this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x80),_0x4f2192),'id':_0x2ee824}):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x1b7))?this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x125)),'id':_0x2ee824}):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x1cb))?this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0xed)),'id':_0x2ee824}):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x1a4))?(_0x10b14a&&this[_0x547729(0xef)][_0x547729(0x123)](_0x10b14a),this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x9c),_0x90e268||_0x547729(0x164)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019)):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x135))?(this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x15d)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019)):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x1a1))?(this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0xd4)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019)):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x1e3))?(this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x1d6)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019)):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x110))?(this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x16d)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019)):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0xaf))?(this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0xb8)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019)):_0x342019[_0x547729(0x1df)][_0x547729(0xeb)](_0x547729(0x1bc))?(this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x11e)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019)):(this[_0x547729(0xef)][_0x547729(0x173)]({'errorMessage':_0x541ff7(this[_0x547729(0x1ac)][_0x547729(0xbf)],_0x547729(0x131)),'id':_0x2ee824}),this[_0x547729(0x145)](_0x342019));}),await this[_0x1d59e0(0x120)][_0x1d59e0(0xb4)](this[_0x1d59e0(0x1ac)][_0x1d59e0(0xc9)][_0x1d59e0(0x11a)](_0x1d59e0(0x7d))),_0x2d8c44||await this[_0x1d59e0(0x120)][_0x1d59e0(0x9a)]();}async[_0x12f486(0x106)]({userMessage:_0x474d71,attributes:_0x5a0dc9}){const _0x15fb2f=_0x12f486;if(!this[_0x15fb2f(0x120)])throw new _0x4b2b76(_0x15fb2f(0xf8));if(this[_0x15fb2f(0x120)][_0x15fb2f(0x178)]()){const _0x3b9b61=await this[_0x15fb2f(0xf0)][_0x15fb2f(0xd1)]();await this[_0x15fb2f(0x120)][_0x15fb2f(0xf1)](_0x3b9b61);}this[_0x15fb2f(0x120)]['id']&&this[_0x15fb2f(0x120)][_0x15fb2f(0x1ce)]&&await this[_0x15fb2f(0x120)][_0x15fb2f(0xf6)]({'userMessage':_0x474d71,'attributes':_0x5a0dc9});}[_0x12f486(0x100)](){const _0x1aa1db=_0x12f486;console[_0x1aa1db(0x6e)](_0x1aa1db(0x153));}[_0x12f486(0x191)](_0xd722fc){const _0x201daf=_0x12f486;this[_0x201daf(0xef)][_0x201daf(0x112)](_0xd722fc);}[_0x12f486(0x145)](_0x18ca84){const _0x1c2f54=_0x12f486;_0x5319e8(_0x18ca84[_0x1c2f54(0x1df)]);}[_0x12f486(0x1f5)](_0x317741){const _0x431bca=_0x12f486;this[_0x431bca(0x120)]?.[_0x431bca(0x1a7)](_0x317741);}[_0x12f486(0xe6)](){const _0x55ad82=_0x12f486;this[_0x55ad82(0x120)]?.[_0x55ad82(0xae)]();}[_0x12f486(0x1f1)](){const _0x1106b2=_0x12f486;this[_0x1106b2(0x120)]?.[_0x1106b2(0x11c)]();}[_0x12f486(0x137)](_0x409d5e){const _0x344c26=_0x12f486,[_0x34df75,_0x5ede4e]=_0x409d5e[_0x344c26(0x160)](':'),_0x50a5d7=this[_0x344c26(0x120)][_0x344c26(0x7c)](_0x34df75),_0x3bfbdc=_0x50a5d7[_0x344c26(0x1b5)](_0x5ede4e);return{'interaction':_0x50a5d7,'reply':_0x3bfbdc};}[_0x12f486(0x1da)](_0xb0d721,_0x1fd5df=!0x1){const _0x55f66=_0x12f486,_0x3cd8e9=_0x4b9b70(this[_0x55f66(0x1ac)]),_0x27dbd9={'target':_0x3cd8e9[_0x55f66(0xc0)][_0x55f66(0xff)][_0x55f66(0xb3)][_0x55f66(0x146)](_0x3cd8e9[_0x55f66(0xc0)][_0x55f66(0x96)][_0x55f66(0x12a)](_0xb0d721)),'viewportOffset':{'top':0x96,'left':0x0,'bottom':0x32,'right':0x0},'ancestorOffset':0x14,'alignToTop':_0x1fd5df};_0x1fd5df&&(_0x27dbd9[_0x55f66(0x124)]=!0x0),_0x343c18(_0x27dbd9);}[_0x12f486(0x1cd)](_0x22c40a,_0xbdc0a4=!0x1){const _0x395e57=_0x12f486;this[_0x395e57(0xef)][_0x395e57(0x161)](_0x22c40a||_0x541ff7(this[_0x395e57(0x1ac)][_0x395e57(0xbf)],_0x395e57(0xf3)),_0xbdc0a4);}async[_0x12f486(0x148)]({reply:_0x21a2e3,renderingStrategy:_0x2036a7}){const _0x584d26=_0x12f486,{id:_0x55df35,interactionId:_0x37a6ec,isDone:_0x4d4c45,type:_0x23ef66,parsedContent:_0x50aef2}=_0x21a2e3,_0x3ff1fb=_0x37a6ec+':'+_0x55df35;if(_0x584d26(0xc4)===_0x23ef66){const _0x3edc53=_0x21a2e3[_0x584d26(0xc6)]({'showDiff':this[_0x584d26(0xef)][_0x584d26(0x147)]});await this[_0x584d26(0xef)][_0x584d26(0x1d5)]({'id':_0x3ff1fb,'parts':_0x3edc53,'renderingStrategy':_0x2036a7,'isDone':_0x4d4c45});}else _0x584d26(0x89)===_0x23ef66&&await this[_0x584d26(0xef)][_0x584d26(0x179)]({'id':_0x3ff1fb,'parsedContent':_0x50aef2,'renderingStrategy':_0x2036a7,'isDone':_0x4d4c45});_0x4d4c45&&_0x21a2e3[_0x584d26(0x187)][_0x584d26(0x84)]>0x0&&this[_0x584d26(0xef)][_0x584d26(0x17b)](_0x3ff1fb,_0x21a2e3[_0x584d26(0x187)]);}async[_0x12f486(0x1f3)](){const _0x5df7f9=_0x12f486,_0x2dc52c=this[_0x5df7f9(0x120)]?.[_0x5df7f9(0x174)];_0x2dc52c&&(_0x2dc52c[_0x5df7f9(0x127)](),this[_0x5df7f9(0xef)][_0x5df7f9(0xa3)](_0x2dc52c));}async[_0x12f486(0x166)](){const _0xe9beb7=_0x12f486,_0x44e665=this[_0xe9beb7(0x120)]?.[_0xe9beb7(0x174)];if(_0x44e665){for await(const _0x54d972 of _0x44e665[_0xe9beb7(0xf7)])await this[_0xe9beb7(0x148)]({'reply':_0x54d972,'renderingStrategy':_0xe9beb7(0x10e)});}}[_0x12f486(0x8b)](_0x183ae3){const _0x30f580=_0x12f486,_0x45e7f7={'positiveCount':_0x183ae3[_0x30f580(0x122)][_0x30f580(0x10a)](_0x812fa5=>_0x30f580(0x1b2)===_0x812fa5[_0x30f580(0x6d)])[_0x30f580(0x84)],'totalCount':_0x183ae3[_0x30f580(0x122)][_0x30f580(0x84)],'modificationId':_0x183ae3['id']},_0x5f147a=this[_0x30f580(0x120)][_0x30f580(0x7c)](_0x183ae3[_0x30f580(0x1e0)])[_0x30f580(0x16b)];_0x5f147a&&this[_0x30f580(0x175)][_0x30f580(0x91)](this[_0x30f580(0x120)]['id'],_0x5f147a,_0x45e7f7);}[_0x12f486(0x15a)](_0x306397){const _0x14f56f=_0x12f486;let _0x191942=null,_0x251572=null;this['on'](_0x14f56f(0x180),(_0x3322b3,_0x4b4634,_0x3255a8)=>{const _0x140d65=_0x14f56f;_0x3255a8['id']!==_0x191942&&(_0x191942=_0x3255a8['id'],_0x251572=this[_0x140d65(0x77)](_0x3255a8)),_0x306397(_0x4b4634,_0x251572);});}[_0x12f486(0x77)](_0x263f89){const _0x2d75a2=_0x12f486,_0x5d4c2d=this[_0x2d75a2(0xef)],_0x1a3f16=()=>{const _0x5392d1=_0x2d75a2;_0x263f89[_0x5392d1(0xe0)](),_0x263f89[_0x5392d1(0x8a)](),_0x5d4c2d[_0x5392d1(0x1c2)]();},_0x479083=()=>{const _0x432136=_0x2d75a2;_0x263f89[_0x432136(0xad)]&&(_0x263f89[_0x432136(0xad)][_0x432136(0x7f)](),_0x263f89[_0x432136(0xad)]=void 0x0);};return{'insertTextReply':(_0x59683a,_0x1e7ee8)=>{const _0x4ee509=_0x2d75a2;_0x479083(),_0x1a3f16();const _0xbdcb5f=_0x263f89[_0x4ee509(0xad)]=_0x263f89[_0x4ee509(0x157)]({'type':_0x4ee509(0x89),'interactionId':_0x263f89['id'],'content':_0x59683a,'id':_0x1e7ee8||_0x14d190()});return _0x479083(),_0xbdcb5f;},'insertCustomElement':async(_0x4dcc3d,_0x1ddf33)=>(_0x479083(),_0x1a3f16(),_0x5d4c2d[_0x2d75a2(0xac)](_0x4dcc3d,_0x1ddf33||_0x14d190())),'setLoadingMessage':_0x5d2abf=>{const _0x165c9e=_0x2d75a2;_0x5d4c2d[_0x165c9e(0x1f4)](_0x5d2abf);},'clearLoadingMessage':()=>{const _0x500a9b=_0x2d75a2;_0x5d4c2d[_0x500a9b(0x1c2)]();}};}}
23
+ const _0x549e58=_0x2831;(function(_0x1b3890,_0x384e77){const _0x14e4d6=_0x2831,_0x5b9f03=_0x1b3890();while(!![]){try{const _0x118a91=parseInt(_0x14e4d6(0x248))/0x1*(parseInt(_0x14e4d6(0x23e))/0x2)+-parseInt(_0x14e4d6(0x2dc))/0x3+parseInt(_0x14e4d6(0x19e))/0x4+-parseInt(_0x14e4d6(0x2a4))/0x5*(parseInt(_0x14e4d6(0x1de))/0x6)+parseInt(_0x14e4d6(0x1ca))/0x7*(-parseInt(_0x14e4d6(0x1ec))/0x8)+-parseInt(_0x14e4d6(0x1fc))/0x9+parseInt(_0x14e4d6(0x2c5))/0xa;if(_0x118a91===_0x384e77)break;else _0x5b9f03['push'](_0x5b9f03['shift']());}catch(_0x4977dd){_0x5b9f03['push'](_0x5b9f03['shift']());}}}(_0x34e4,0x4eb0b));import{ContextPlugin as _0x532a15,Editor as _0x49cd1c}from'ckeditor5/src/core.js';import{BodyCollection as _0x304253}from'ckeditor5/src/ui.js';import{CKEditorError as _0x4463ae,logError as _0x5d0d75,scrollViewportToShowTarget as _0x2f1661,uid as _0x327016}from'ckeditor5/src/utils.js';import{AIConnector as _0x5d5837}from'../aicore/aiconnector.js';import{AITabs as _0xf3132e}from'../aitabs/aitabs.js';import{AIChatConversation as _0x3c92d0}from'./model/aichatconversation.js';import{getTranslation as _0x4b3662}from'../aicore/utils/common-translations.js';function _0x34e4(){const _0x31f4e9=['_getUserPresentableContentPartDocumentRange','isInContext','chat','root','_bodyCollection','resource','editors','addFileToContext','ai-conversation-','clearConversationContextUI','getDocumentContext','updateFeedItemAIReplySuggestionContent','listenTo','ai-no-track-changes','interactionFinished','change','3551580DkXvxd','baseVersion','delegate','accepted','contextItemRemoved','getChild','replyCreated','cloneNode','resources','ai-chat-url-upload-failed','AI_CHAT_UNTITLED_CONVERSATION','updateConversationTitle','removeFeedInteraction','source','dialogClosed','streaming','selectModel','partIndex','state','new','mouseOverSuggestion','revert','_scrollToSuggestionRange','30210WByBPk','setModel','AITabs','AIConnector','getSelectionText','detachFromDom','createRange','isUploadInProgress','ai-chat-conversation-start-failed','contextItems','updateCapabilities','updateFeedItemAIReplySources','ai-chat-controller-mouse-over','getChildren','_setIsMaximized','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_URL','config','stop','domConverter','updateFeedItemAIReplySuggestionPartState','push','addFilesToContext','handleUserInteraction','selection','ai-chat-controller-no-active-conversation','getOperations','ai-chat-context-invalid-data','_applySuggestion','nextSibling','removeSelectionFromChatContext','setAddContextOptions','ai.models','getConversation','alignToTop','static','history','activateTab','_stopLastInteraction','content','addFeedItemError','getRoot','removed','getContentParts','AI_CHAT_GENERIC_ERROR','abortPromptStream','updateResourceState','interactionId','find','createPositionAt','setIsUploadInProgress','messageId','clearLoadingMessage','ai-chat-context-unsupported-type','scrollFeedToSuggestion','replies','isDocumentOperation','ai-chat-context-form-data-size-limits-exceeded','resourceStateChanged','context','populateSourceResourceBalloon','setFeedItemAIReplySuggestionPartActive','focusPromptInput','_aiChatBalloonShowDiff','fetchConversations','callback','batch','getAttribute','AI_CHAT_CONTEXT_UNSUPPORTED_FILE_TYPE','insertSuggestion','type','changes','locale','current-document','ai.models.defaultModelId','_createFromRanges','ai-chat-source-resources-load-failed','findIndex','addSelectionToChatContext','1818696YJyYks','split','unshift','mapper','version','activeConversation','isPremiumPlugin','getRanges','done','sourceResourcesLoaded','getDiff','$graveyard','Undo','ai-chat-conversation-init-failed','applyOperation','aiChatBalloon','ai-chat-context-unsupported-file-type','setContextItemLoading','open','addContextOptionsChanged','fetchConversation','interactionStarted','addSelectionToContext','toString','closeSourceResourceBalloon','selectedModel','AIChatController','startInteraction','getAll','addFeedItemAIReply','updateContent','message','Disliked\x20response','reasoningStarted','_toggleReasoning','_getLastCreatedConversationId','contextItemLoadingEnded','maxOffset','_openBalloonFor','AI_CHAT_ABORTED_MESSAGE','replyId','getChildAtOffset','addFeedItemCustomElement','resetMessageInput','171794CDhmrF','DocumentCompare','_integrateEditor','setLoadingMessage','addFeedItemAISuggestion','showFakeVisualSelection','addResourceToContext','redo','sendMessage','interactionCreated','addContextItem','disableControls','resize','undo','previous','AI_CHAT_INVALID_REQUEST','updateCurrentDocumentInContext','ai-request-aborted','showDiff','loadSourceResources','6mzIaqQ','uiId','resetConversationTitle','startsWith','set','Liked\x20response','ai.chat.initialConversation','addCurrentDocumentToChatContext','_showConversationHistory','applySuggestion','interactionDestroyed','isStarted','contextItem','options','112PScoTW','_registerToolDataCallback','_updateReplyContent','modification','getInteraction','sourceId','stopInteraction','editing','showNext','plugins','pending','_currentPreviewedChangeGroup','changeGroups','toViewRange','setIsMaximized','ai-chat-file-upload-failed','4395627bCtABF','getConversations','uploadProgressChanged','from','toolDataReceived','load','anchorId','start','range','_aiEditing','clearPendingContextUI','_applyOperationsAsSuggestions','createPositionFromPath','webSearchStarted','contextItemAdded','ai-chat-resource-load-failed','addCurrentDocumentToContext','resizedTabs','resizeTabs','ai-chat-conversation-not-found','AI_CHAT_UNABLE_TO_LOAD_CONVERSATION','startAutoScroll','TrackChangesEditing','ai-chat-invalid-request','has','isModelAvailable','main','rejectSuggestion','data-id','document','handleRemovedConversation','delete','children','ai.chat.context','addFeedItemStaticMessage','mouseLeaveSuggestion','resetReasoningState','lastCreated','map','sourcePosition','createReply','finishInteraction','parse','_toggleWebSearch','_flushLastInteractionUI','toggleWebSearch','AI_CHAT_RESOURCE_LOAD_FAILED','addFeedInteractionHeader','capabilitiesUpdated','ai-chat-context-file-too-many-pages','_getDocumentRangeForReplyChanges','init','dislike','getDocumentData','bind','enableControls','AIEditing','removeSelectionFromContext','_getPresentableSiblingContentPartIndex','replyContentUpdated','close','_insertSuggestion','viewRangeToDom','setFeedItemRenderingStrategy','model','getTransformedByOperation','1204342QVhlTF','isDisabled','toggleLoadingSkeleton','_handleStartConversation','modelSelected','currentReply','AI_CHAT_CONTEXT_UNSUPPORTED_TYPE','AI_CHAT_CONTEXT_CURRENT_DOCUMENT','howMany','loadConversation','1gaOofr','_startConversationSafely','getFirstRange','startConversation','addOperation','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_FILE','getPath','_removeFromContext','_getAIChatInteractionAPI','length','_handleUIUserMessage','resourceId','replyChangeGroupStateUpdated','like','_aiChatUi','AI_CHAT_CONTEXT_FILE_TOO_MANY_PAGES','executeCustomItemCallback','commands','conversationInitialized','setState','resetWebSearchState','showPrevious','getReply','attachToDom','collaboration.channelId','requires','isCurrentDocumentInContext','webSearchFinished','Showing\x20conversation\x20history...','hideFakeVisualSelection','marker','sendUserMessage','log','hasChanges','_batchToChanges','createConversation','setConversationTitle','ready','getGroupId','isCurrentDocumentInConversation','showChangeInText','slice','ai-chat-missing-channel-id','data','rootName','filter','outdated','addFeedItemUserMessage','sessionId','sources','query','end','remove','AI_CHAT_CONTEXT_INVALID_DATA','areActionsDisabled','view','AIChatUI','TrackChanges','getInteractionAndReplyById','_aiConnector','lastInteraction','isLoading','createdAt','upsertAIChatRating','error','uid','node','rejected','prepareLoadingMessage','toggleReasoning','add','setChangeGroupState','AI_CHAT_CONTEXT_FORM_DATA_SIZE_LIMITS_EXCEEDED','forEach','afterInit','path','AI_CHAT_UNABLE_TO_START_CONVERSATION','_rejectSuggestion','addUrlToContext','index','removeContextItem','includes','_updateRatings','AI_CHAT_CONTEXT_FILE_TOO_LARGE','text','get','AI_BALLOON_HEADER_TITLE','contextSent','AIChatBalloon','destroy','addDocumentToContext','_logError','1238135oXhaeg','indexes','reasoningFinished','indexOf','removeFromContext','updateFeedItemAIReplyContent','setSelectedModel','setConversationContext','documentContextContent','isOfficialPlugin','_aiChatModels','next','toggleSuggestionDisplayMode','pluginName','AI_CHAT_CONTEXT_UNABLE_TO_LOAD_RESOURCES','_aiChatBalloon','ai-chat-context-file-too-large'];_0x34e4=function(){return _0x31f4e9;};return _0x34e4();}import{AIModels as _0x1574f3}from'../aicore/model/aimodels.js';import{getEditorFromContext as _0x4ee1ac}from'../aicore/utils/geteditorfromcontext.js';import{DocumentCompare as _0x181444,DATA_ID_MODEL_ATTRIBUTE as _0x5a92da}from'ckeditor5-collaboration/src/collaboration-core.js';import{fixMarkerOperationOldRange as _0x595e85,getOperationsFromReply as _0x1f974c}from'../aicore/utils/getoperationsfromreply.js';import{expandSelectionWithContext as _0x3cc810,getMinimalSelection as _0x515b44}from'../aicore/utils/getsuggestionpartsfromreply.js';import{ModelRange as _0x4a1aab,_DetachOperation as _0x467c1c}from'ckeditor5/src/engine.js';function _0x2831(_0x403949,_0x57b4ca){const _0x34e4a8=_0x34e4();return _0x2831=function(_0x283108,_0x2d5fd0){_0x283108=_0x283108-0x190;let _0x12bbee=_0x34e4a8[_0x283108];return _0x12bbee;},_0x2831(_0x403949,_0x57b4ca);}import{findOne as _0x2a7a53,getAttribute as _0x51229b,serialize as _0x45c6b5,Document as _0x5b8bb4,findByAttribute as _0x1d2477}from'../aicore/utils/htmlparser.js';export class AIChatController extends _0x532a15{[_0x549e58(0x205)];[_0x549e58(0x283)];[_0x549e58(0x256)];[_0x549e58(0x2ae)];[_0x549e58(0x2b3)];[_0x549e58(0x26a)]=new Map();[_0x549e58(0x1f7)]=null;[_0x549e58(0x2b9)];static get[_0x549e58(0x261)](){return[_0x5d5837,_0x181444];}static get[_0x549e58(0x2b1)](){const _0x2721f7=_0x549e58;return _0x2721f7(0x1b8);}static get[_0x549e58(0x2ad)](){return!0x0;}static get[_0x549e58(0x1a4)](){return!0x0;}[_0x549e58(0x22f)](){const _0x5134f8=_0x549e58;this[_0x5134f8(0x2b9)]=new _0x304253(this[_0x5134f8(0x316)][_0x5134f8(0x197)]),this[_0x5134f8(0x2b9)][_0x5134f8(0x25f)](),this[_0x5134f8(0x283)]=this[_0x5134f8(0x316)][_0x5134f8(0x1f5)][_0x5134f8(0x29d)](_0x5134f8(0x2df)),this[_0x5134f8(0x256)]=this[_0x5134f8(0x316)][_0x5134f8(0x1f5)][_0x5134f8(0x29d)](_0x5134f8(0x280)),this[_0x5134f8(0x205)]=this[_0x5134f8(0x316)][_0x5134f8(0x1f5)][_0x5134f8(0x29d)](_0x5134f8(0x234)),this[_0x5134f8(0x2ae)]=new _0x1574f3({'connector':this[_0x5134f8(0x283)],'config':this[_0x5134f8(0x316)][_0x5134f8(0x2ec)][_0x5134f8(0x29d)](_0x5134f8(0x2fb)),'locale':this[_0x5134f8(0x316)][_0x5134f8(0x197)]});const _0x9c68be=this[_0x5134f8(0x316)][_0x5134f8(0x1f5)][_0x5134f8(0x29d)](_0x5134f8(0x2de));this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x24b),()=>{const _0x13da72=_0x5134f8;this[_0x13da72(0x249)]();}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x267),(_0x1fbf28,_0x1ec1e7)=>{const _0x38d695=_0x5134f8;this[_0x38d695(0x252)]({'userMessage':_0x1ec1e7});}),this[_0x5134f8(0x2c1)](_0x9c68be,_0x5134f8(0x20d),(_0x45fa38,_0x129fde)=>{const _0x153927=_0x5134f8;this[_0x153927(0x2ea)](_0x129fde);}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x20e),()=>{const _0x4675f2=_0x5134f8;_0x9c68be[_0x4675f2(0x1d6)]();}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x308),async()=>{const _0x502f42=_0x5134f8;await this[_0x502f42(0x301)](),await this[_0x502f42(0x228)](),this[_0x502f42(0x2f9)]();}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x2a2),()=>{const _0x19929d=_0x5134f8;this[_0x19929d(0x1e5)]();}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x2bc),(_0x2b97da,_0x2ee259)=>{const _0x55dc9e=_0x5134f8;this[_0x55dc9e(0x1a3)]?.[_0x55dc9e(0x2f1)](Array[_0x55dc9e(0x1ff)](_0x2ee259));}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x296),(_0x410f06,_0x246e62)=>{const _0x208f74=_0x5134f8;this[_0x208f74(0x1a3)]?.[_0x208f74(0x296)](_0x246e62);}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x258),(_0x221b26,_0x810224)=>{const _0x5c0de7=_0x5134f8;_0x810224[_0x5c0de7(0x190)](this[_0x5c0de7(0x316)]);}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x1d0),(_0x4a6d0e,_0x572a46)=>{const _0x56ab12=_0x5134f8;this[_0x56ab12(0x1a3)]?.[_0x56ab12(0x1d0)](_0x572a46[_0x56ab12(0x2d2)],_0x572a46[_0x56ab12(0x2ba)]);}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x298),(_0xb7b871,_0x53cb4b)=>{const _0x1a47bc=_0x5134f8;this[_0x1a47bc(0x24f)](_0x53cb4b);}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x1dd),(_0x5b01ce,_0x2662a1)=>{const _0x598a36=_0x5134f8;this[_0x598a36(0x1a3)]?.[_0x598a36(0x1dd)](_0x2662a1[_0x598a36(0x1f1)],_0x2662a1[_0x598a36(0x27a)],_0x2662a1[_0x598a36(0x289)]);}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x229),()=>{const _0x54f136=_0x5134f8;this[_0x54f136(0x227)]();}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x28d),()=>{const _0x5ceb3e=_0x5134f8;this[_0x5ceb3e(0x1c0)]();}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x2d5),(_0x448e75,_0x38c366)=>{const _0x30c59b=_0x5134f8;this[_0x30c59b(0x1a3)]?.[_0x30c59b(0x2dd)](_0x38c366);}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x255),(_0x3c6551,{replyId:_0x2aa711})=>{const _0x4cbd04=_0x5134f8;console[_0x4cbd04(0x268)](_0x4cbd04(0x1e3),_0x2aa711);}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x230),(_0x4d4ee0,{replyId:_0x46f7a3})=>{const _0x265caf=_0x5134f8;console[_0x265caf(0x268)](_0x265caf(0x1be),_0x46f7a3);}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x194),(_0x46da20,_0x4c9e4f)=>{const _0x44bb03=_0x5134f8;this[_0x44bb03(0x239)](_0x4c9e4f);}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x270),(_0x2b1e1e,{replyId:_0x16654c,partIndex:_0x2780f8})=>{const _0x59e50f=_0x5134f8;this[_0x59e50f(0x31a)]=this[_0x59e50f(0x256)][_0x59e50f(0x1dc)],this[_0x59e50f(0x1c4)](_0x16654c,_0x2780f8);}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x2d9),(_0x3b5b00,{replyId:_0x4da5b4,partIndex:_0x421490})=>{const _0x42b29a=_0x5134f8,_0x3f572e=this[_0x42b29a(0x22e)](_0x4da5b4,_0x421490);_0x3f572e&&_0x42b29a(0x1a9)!=_0x3f572e[_0x42b29a(0x204)][_0x42b29a(0x2b8)][_0x42b29a(0x274)]&&this[_0x42b29a(0x205)][_0x42b29a(0x1cf)]([_0x3f572e[_0x42b29a(0x204)]],_0x42b29a(0x2e8));}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x21f),()=>{const _0xaee70f=_0x5134f8;this[_0xaee70f(0x205)][_0xaee70f(0x265)](_0xaee70f(0x2e8));}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x1e7),(_0x3a7e2c,_0x2e113f)=>{const _0x2e6cb5=_0x5134f8;this[_0x2e6cb5(0x205)][_0x2e6cb5(0x265)](_0x2e6cb5(0x2e8)),this[_0x2e6cb5(0x2f7)](_0x2e113f);}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x2b0),async(_0xce90f6,{replyId:_0x30c15b,showDiff:_0x4a81c9})=>{const _0x5e2ad0=_0x5134f8,{reply:_0x50ceb4}=this[_0x5e2ad0(0x282)](_0x30c15b),_0x219d10=_0x50ceb4[_0x5e2ad0(0x306)]({'showDiff':_0x4a81c9});await this[_0x5e2ad0(0x256)][_0x5e2ad0(0x2c0)]({'id':_0x50ceb4['id'],'parts':_0x219d10,'renderingStrategy':_0x5e2ad0(0x2fe)});}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x256)],_0x5134f8(0x217),(_0x2e7c33,{replyId:_0x3f8b77,partIndex:_0x228ad4})=>{const _0x4037a4=_0x5134f8;this[_0x4037a4(0x295)]({'replyId':_0x3f8b77,'partIndex':_0x228ad4}),this[_0x4037a4(0x205)][_0x4037a4(0x265)](_0x4037a4(0x2e8));}),this[_0x5134f8(0x316)][_0x5134f8(0x1f5)][_0x5134f8(0x214)](_0x5134f8(0x2a0))&&(this[_0x5134f8(0x2b3)]=this[_0x5134f8(0x316)][_0x5134f8(0x1f5)][_0x5134f8(0x29d)](_0x5134f8(0x2a0)),this[_0x5134f8(0x1e2)](_0x5134f8(0x31a),!0x1),this[_0x5134f8(0x2b3)][_0x5134f8(0x232)](_0x5134f8(0x1dc))['to'](this,_0x5134f8(0x31a)),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x2b3)],_0x5134f8(0x2b0),()=>{const _0x11d0a7=_0x5134f8,{replyId:_0x205007,partIndex:_0x154c70}=this[_0x11d0a7(0x1f7)];this[_0x11d0a7(0x31a)]=!this[_0x11d0a7(0x31a)];const {reply:_0x3c362d}=this[_0x11d0a7(0x282)](_0x205007),_0x122c6d=_0x3c362d[_0x11d0a7(0x306)]({'showDiff':this[_0x11d0a7(0x31a)],'groupIndex':_0x154c70});this[_0x11d0a7(0x2b3)][_0x11d0a7(0x1bc)]({'part':_0x122c6d[0x0],'renderingStrategy':_0x11d0a7(0x2fe),'keepErrors':!0x0});}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x2b3)],_0x5134f8(0x1e7),()=>{const _0x562a68=_0x5134f8,{replyId:_0x3d72e6,partIndex:_0x33eb9e}=this[_0x562a68(0x1f7)];this[_0x562a68(0x2f7)]({'replyId':_0x3d72e6,'partIndex':_0x33eb9e}),this[_0x562a68(0x2b3)][_0x562a68(0x25b)](_0x562a68(0x2c8));}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x2b3)],_0x5134f8(0x194),()=>{const _0x2c9b9c=_0x5134f8,{replyId:_0x5a0299,partIndex:_0x1104eb}=this[_0x2c9b9c(0x1f7)];this[_0x2c9b9c(0x239)]({'replyId':_0x5a0299,'partIndex':_0x1104eb}),this[_0x2c9b9c(0x2b3)][_0x2c9b9c(0x25b)](_0x2c9b9c(0x2c8));}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x2b3)],_0x5134f8(0x217),()=>{const _0x3d7c54=_0x5134f8,{replyId:_0x4c80ad,partIndex:_0x3f2de8}=this[_0x3d7c54(0x1f7)];this[_0x3d7c54(0x295)]({'replyId':_0x4c80ad,'partIndex':_0x3f2de8}),this[_0x3d7c54(0x2b3)][_0x3d7c54(0x25b)](_0x3d7c54(0x28b));}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x2b3)],_0x5134f8(0x1f4),()=>{const _0x17bd62=_0x5134f8,{replyId:_0x3c044b,partIndex:_0x59970b}=this[_0x17bd62(0x1f7)],_0x5275f0=this[_0x17bd62(0x236)](_0x3c044b,_0x59970b,_0x17bd62(0x2af));null!==_0x5275f0&&this[_0x17bd62(0x1c4)](_0x3c044b,_0x5275f0);}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x2b3)],_0x5134f8(0x25d),()=>{const _0x7ba9f=_0x5134f8,{replyId:_0x34dfae,partIndex:_0x342356}=this[_0x7ba9f(0x1f7)],_0x635678=this[_0x7ba9f(0x236)](_0x34dfae,_0x342356,_0x7ba9f(0x1d8));null!==_0x635678&&this[_0x7ba9f(0x1c4)](_0x34dfae,_0x635678);}),this[_0x5134f8(0x2c1)](this[_0x5134f8(0x2b3)],_0x5134f8(0x2d3),(_0x1a8370,{id:_0x5bae2a})=>{const _0x533204=_0x5134f8;if(_0x533204(0x1ad)!==_0x5bae2a)return;const {replyId:_0x99be5b,partIndex:_0x2e5aef}=this[_0x533204(0x1f7)];this[_0x533204(0x1f7)]=null,this[_0x533204(0x256)][_0x533204(0x318)]({'id':_0x99be5b,'index':_0x2e5aef,'isActive':!0x1});}));}async[_0x549e58(0x292)](){const _0x263c23=_0x549e58;this[_0x263c23(0x316)]instanceof _0x49cd1c?this[_0x263c23(0x1cc)](this[_0x263c23(0x316)]):this[_0x263c23(0x2c1)](this[_0x263c23(0x316)][_0x263c23(0x2bb)],_0x263c23(0x28e),(_0x4ff037,_0x3b9ba4)=>{const _0x1a5651=_0x263c23;_0x3b9ba4['on'](_0x1a5651(0x26d),()=>{const _0x4e3fa9=_0x1a5651;this[_0x4e3fa9(0x1cc)](_0x3b9ba4);});});const _0x21c16c=this[_0x263c23(0x316)][_0x263c23(0x2ec)][_0x263c23(0x29d)](_0x263c23(0x1e4));let _0x36216d=_0x21c16c;if(_0x263c23(0x221)!=_0x21c16c||(_0x36216d=await this[_0x263c23(0x1c1)](),_0x36216d))return _0x263c23(0x2d8)==_0x36216d?this[_0x263c23(0x249)]():this[_0x263c23(0x247)](_0x36216d);}async[_0x549e58(0x2a1)](){const _0x218160=_0x549e58;return await this[_0x218160(0x301)](),this[_0x218160(0x2b9)][_0x218160(0x2e1)](),super[_0x218160(0x2a1)]();}[_0x549e58(0x239)](_0x2b8829){const _0x590b58=_0x549e58,_0x482193=_0x4ee1ac(this[_0x590b58(0x316)]);if(!_0x482193[_0x590b58(0x1f5)][_0x590b58(0x214)](_0x590b58(0x281)))throw new _0x4463ae(_0x590b58(0x2c2),null);const _0x4c8d19=this[_0x590b58(0x316)][_0x590b58(0x1f5)][_0x590b58(0x29d)](_0x590b58(0x1cb)),{reply:_0x1b0e67,interaction:_0x41f93e}=this[_0x590b58(0x282)](_0x2b8829[_0x590b58(0x1c6)]),_0x3143c5=this[_0x590b58(0x22e)](_0x2b8829[_0x590b58(0x1c6)],_0x2b8829[_0x590b58(0x2d6)]),_0xe42fbf=void 0x0!==_0x2b8829[_0x590b58(0x2d6)]?[_0x1b0e67[_0x590b58(0x1f8)][_0x2b8829[_0x590b58(0x2d6)]]]:_0x1b0e67[_0x590b58(0x1f8)][_0x590b58(0x275)](_0x5dce58=>_0x590b58(0x1f6)==_0x5dce58[_0x590b58(0x2d7)]),_0x58a113=_0xe42fbf[_0x590b58(0x222)](_0x1042f6=>_0x1b0e67[_0x590b58(0x1f8)][_0x590b58(0x2a7)](_0x1042f6));if(!_0x3143c5||_0x590b58(0x1a9)==_0x3143c5[_0x590b58(0x204)][_0x590b58(0x2b8)][_0x590b58(0x274)])return void _0x58a113[_0x590b58(0x291)](_0x3b9891=>_0x1b0e67[_0x590b58(0x28f)](_0x3b9891,_0x590b58(0x276)));_0x58a113[_0x590b58(0x291)](_0x34872c=>_0x1b0e67[_0x590b58(0x28f)](_0x34872c,_0x590b58(0x2c8)));const _0x1f6b0a=_0x1f974c({'editor':_0x482193,'reply':_0x1b0e67,'interaction':_0x41f93e,'groups':_0xe42fbf,'transform':!0x0,'documentCompare':_0x4c8d19,'documentCompareOptions':{'anchor':_0x590b58(0x216),'markDeletions':!0x0}});let _0x55b8bd;_0x3143c5&&this[_0x590b58(0x2db)](_0x3143c5[_0x590b58(0x204)]),_0x482193[_0x590b58(0x23c)][_0x590b58(0x2c4)](_0x30fcfd=>{const _0xd96f31=_0x590b58;_0x55b8bd=_0x30fcfd[_0xd96f31(0x191)],_0x482193[_0xd96f31(0x1f5)][_0xd96f31(0x29d)](_0xd96f31(0x212))[_0xd96f31(0x207)](_0x1f6b0a),this[_0xd96f31(0x205)][_0xd96f31(0x265)](_0xd96f31(0x2e8));}),this[_0x590b58(0x26a)][_0x590b58(0x1e2)](_0x55b8bd,{'interactionId':_0x41f93e['id'],'replyId':_0x1b0e67['id'],'indexes':_0x58a113[_0x590b58(0x271)]()}),this[_0x590b58(0x29a)](_0x1b0e67);}[_0x549e58(0x2f7)](_0x8d5d4b){const _0x12acd8=_0x549e58,_0x503fcc=_0x4ee1ac(this[_0x12acd8(0x316)]),_0x2e4365=this[_0x12acd8(0x316)][_0x12acd8(0x1f5)][_0x12acd8(0x29d)](_0x181444),{reply:_0x5d16cd,interaction:_0x362640}=this[_0x12acd8(0x282)](_0x8d5d4b[_0x12acd8(0x1c6)]),_0x5ade61=this[_0x12acd8(0x22e)](_0x8d5d4b[_0x12acd8(0x1c6)],_0x8d5d4b[_0x12acd8(0x2d6)]),_0x2500d2=void 0x0!==_0x8d5d4b[_0x12acd8(0x2d6)]?[_0x5d16cd[_0x12acd8(0x1f8)][_0x8d5d4b[_0x12acd8(0x2d6)]]]:_0x5d16cd[_0x12acd8(0x1f8)][_0x12acd8(0x275)](_0x53ca91=>_0x12acd8(0x1f6)==_0x53ca91[_0x12acd8(0x2d7)]),_0x3e416d=_0x2500d2[_0x12acd8(0x222)](_0x523923=>_0x5d16cd[_0x12acd8(0x1f8)][_0x12acd8(0x2a7)](_0x523923));if(!_0x5ade61||_0x12acd8(0x1a9)==_0x5ade61[_0x12acd8(0x204)][_0x12acd8(0x2b8)][_0x12acd8(0x274)])return void _0x3e416d[_0x12acd8(0x291)](_0x356011=>_0x5d16cd[_0x12acd8(0x28f)](_0x356011,_0x12acd8(0x276)));_0x3e416d[_0x12acd8(0x291)](_0x3d7eb5=>_0x5d16cd[_0x12acd8(0x28f)](_0x3d7eb5,_0x12acd8(0x2c8)));const _0x22f46c=_0x1f974c({'editor':_0x503fcc,'reply':_0x5d16cd,'interaction':_0x362640,'groups':_0x2500d2,'transform':!0x0,'documentCompare':_0x2e4365,'documentCompareOptions':{'anchor':_0x12acd8(0x216),'markDeletions':!0x1}});let _0x51028c;_0x5ade61&&this[_0x12acd8(0x2db)](_0x5ade61[_0x12acd8(0x204)]),_0x503fcc[_0x12acd8(0x23c)][_0x12acd8(0x2c4)](_0x2d395f=>{const _0x40810e=_0x12acd8;_0x51028c=_0x2d395f[_0x40810e(0x191)];for(const _0x3d095f of _0x22f46c)_0x3d095f[_0x40810e(0x2c6)]=_0x503fcc[_0x40810e(0x23c)][_0x40810e(0x219)][_0x40810e(0x1a2)],_0x595e85(_0x503fcc,_0x3d095f),_0x2d395f[_0x40810e(0x191)][_0x40810e(0x24c)](_0x3d095f),_0x503fcc[_0x40810e(0x23c)][_0x40810e(0x1ac)](_0x3d095f);}),this[_0x12acd8(0x26a)][_0x12acd8(0x1e2)](_0x51028c,{'interactionId':_0x362640['id'],'replyId':_0x5d16cd['id'],'indexes':_0x3e416d[_0x12acd8(0x271)]()}),this[_0x12acd8(0x29a)](_0x5d16cd);}[_0x549e58(0x295)](_0x3111cf){const _0x310318=_0x549e58,{reply:_0x4bc04e}=this[_0x310318(0x282)](_0x3111cf[_0x310318(0x1c6)]);_0x4bc04e[_0x310318(0x28f)](_0x3111cf[_0x310318(0x2d6)],_0x310318(0x28b));}[_0x549e58(0x1c4)](_0x195cb9,_0x1bf2cc){const _0x567e19=_0x549e58;if(!this[_0x567e19(0x2b3)])return;const {reply:_0x549369}=this[_0x567e19(0x282)](_0x195cb9),_0x31f506=_0x549369[_0x567e19(0x306)]({'showDiff':this[_0x567e19(0x31a)]});let _0x23f16,_0x399427;if(void 0x0!==_0x1bf2cc?(_0x399427=_0x31f506[_0x567e19(0x30b)](_0x171965=>_0x171965[_0x567e19(0x297)]==_0x1bf2cc),_0x23f16=_0x399427?.[_0x567e19(0x297)]):(_0x399427=_0x31f506[0x0],_0x23f16=_0x399427[_0x567e19(0x297)]),this[_0x567e19(0x1f7)]?.[_0x567e19(0x1c6)]==_0x195cb9&&this[_0x567e19(0x1f7)]?.[_0x567e19(0x2d6)]==_0x23f16)return;const _0x27df77=this[_0x567e19(0x2b5)](_0x195cb9,_0x549369,_0x399427);if(!_0x27df77)return void this[_0x567e19(0x2b3)][_0x567e19(0x238)]();this[_0x567e19(0x1f7)]={'replyId':_0x195cb9,'partIndex':_0x23f16},this[_0x567e19(0x2db)](_0x27df77,!0x0);const _0x36e4e5=this[_0x567e19(0x236)](_0x195cb9,_0x23f16,_0x567e19(0x2af));this[_0x567e19(0x2b3)][_0x567e19(0x1bc)]({'part':_0x399427,'renderingStrategy':_0x567e19(0x2fe)}),this[_0x567e19(0x2b3)][_0x567e19(0x1b0)]({'index':_0x23f16,'title':_0x4b3662(this[_0x567e19(0x316)][_0x567e19(0x197)],_0x567e19(0x29e),(_0x23f16+0x1)[_0x567e19(0x1b5)]()),'showRotator':null!==_0x36e4e5,'ranges':[_0x27df77],'areActionsDisabled':_0x549369[_0x567e19(0x27e)]}),this[_0x567e19(0x2b3)][_0x567e19(0x25b)](_0x567e19(0x1f6)),this[_0x567e19(0x256)][_0x567e19(0x311)](_0x195cb9,_0x23f16),this[_0x567e19(0x256)][_0x567e19(0x318)]({'id':_0x195cb9,'index':_0x23f16,'isActive':!0x0});}[_0x549e58(0x236)](_0x5a7af1,_0x9b722b,_0x43b5e1){const _0x32f5db=_0x549e58,{reply:_0x1c906f}=this[_0x32f5db(0x282)](_0x5a7af1),_0x55baa4=_0x1c906f[_0x32f5db(0x306)]({'showDiff':this[_0x32f5db(0x31a)]});if(0x1==_0x55baa4[_0x32f5db(0x251)])return null;const _0x11c0fb=_0x55baa4[_0x32f5db(0x19c)](_0x4790a9=>_0x4790a9[_0x32f5db(0x297)]==_0x9b722b),_0x44b1e0=_0x32f5db(0x2af)==_0x43b5e1?0x1:-0x1;let _0x522e08=_0x55baa4['at']((_0x11c0fb+_0x44b1e0)%_0x55baa4[_0x32f5db(0x251)])[_0x32f5db(0x297)],_0x5b60a3=_0x55baa4[_0x522e08];for(;!this[_0x32f5db(0x2b5)](_0x5a7af1,_0x1c906f,_0x5b60a3);){if(_0x522e08=_0x55baa4['at']((_0x522e08+_0x44b1e0)%_0x55baa4[_0x32f5db(0x251)])[_0x32f5db(0x297)],_0x522e08===_0x11c0fb)return null;_0x5b60a3=_0x55baa4[_0x522e08];}return _0x522e08;}[_0x549e58(0x2b5)](_0x37a016,_0x792f23,_0xd6a4a0){const _0x29a2e6=_0x549e58,_0x294d3b=_0x792f23[_0x29a2e6(0x1f8)];if(!_0xd6a4a0[_0x29a2e6(0x269)])return null;const _0x5aec53=_0x294d3b[_0x29a2e6(0x30b)](_0x564782=>_0x564782[_0x29a2e6(0x297)]==_0xd6a4a0[_0x29a2e6(0x297)]);if(_0x29a2e6(0x1f6)!==_0x5aec53?.[_0x29a2e6(0x2d7)])return null;const _0x151c82=this[_0x29a2e6(0x22e)](_0x37a016,_0xd6a4a0[_0x29a2e6(0x297)]);if(!_0x151c82)return null;const {range:_0x4b3ebe,currentIndex:_0x387838}=_0x151c82;return _0x29a2e6(0x1a9)==_0x4b3ebe[_0x29a2e6(0x2b8)][_0x29a2e6(0x274)]?(_0x792f23[_0x29a2e6(0x28f)](_0x387838,_0x29a2e6(0x276)),null):_0x151c82[_0x29a2e6(0x204)];}[_0x549e58(0x22e)](_0x5a65b8,_0x59c8d7){const _0x3efdaf=_0x549e58,_0x28531e=_0x4ee1ac(this[_0x3efdaf(0x316)]),{reply:_0x323c7e,interaction:_0x3788cb}=this[_0x3efdaf(0x282)](_0x5a65b8),_0x4106bb=_0x323c7e[_0x3efdaf(0x1f8)][_0x3efdaf(0x275)](_0x5ece1a=>_0x3efdaf(0x1f6)==_0x5ece1a[_0x3efdaf(0x2d7)]),_0x572d9=_0x4106bb[_0x3efdaf(0x222)](_0x4908f6=>_0x323c7e[_0x3efdaf(0x1f8)][_0x3efdaf(0x2a7)](_0x4908f6));void 0x0===_0x59c8d7&&(_0x59c8d7=_0x572d9[0x0]);const _0x11cf25=_0x572d9[_0x3efdaf(0x2a7)](_0x59c8d7);if(-0x1==_0x11cf25)return null;const _0x3bb4d2=_0x4106bb[_0x11cf25],_0x49701e=new _0x5b8bb4([]),_0x4f3731=new _0x5b8bb4([]);for(const _0x2ca06f of _0x3bb4d2[_0x3efdaf(0x196)])if(_0x3efdaf(0x305)!=_0x2ca06f[_0x3efdaf(0x195)]&&_0x4f3731[_0x3efdaf(0x21c)][_0x3efdaf(0x2f0)](_0x2ca06f[_0x3efdaf(0x28a)][_0x3efdaf(0x2cc)](!0x0)),_0x3efdaf(0x2d8)!=_0x2ca06f[_0x3efdaf(0x195)]){const _0x3cf0bc=_0x2a7a53(_0x5cc7fe=>_0x51229b(_0x5cc7fe,_0x3efdaf(0x218))==_0x2ca06f['id'],_0x323c7e[_0x3efdaf(0x2ac)],!0x0);_0x49701e[_0x3efdaf(0x21c)][_0x3efdaf(0x2f0)](_0x3cf0bc[_0x3efdaf(0x2cc)](!0x0));}if(0x0==_0x49701e[_0x3efdaf(0x21c)][_0x3efdaf(0x251)]){if(_0x3bb4d2[_0x3efdaf(0x196)][0x0][_0x3efdaf(0x202)]){const _0x29c15a=_0x1d2477(_0x3efdaf(0x218),_0x3bb4d2[_0x3efdaf(0x196)][0x0][_0x3efdaf(0x202)],_0x323c7e[_0x3efdaf(0x2ac)]);_0x49701e[_0x3efdaf(0x21c)][_0x3efdaf(0x1a0)](_0x29c15a[_0x3efdaf(0x2cc)](!0x0)),_0x4f3731[_0x3efdaf(0x21c)][_0x3efdaf(0x1a0)](_0x29c15a[_0x3efdaf(0x2cc)](!0x0)),_0x29c15a[_0x3efdaf(0x2f8)]&&(_0x49701e[_0x3efdaf(0x21c)][_0x3efdaf(0x2f0)](_0x29c15a[_0x3efdaf(0x2f8)][_0x3efdaf(0x2cc)](!0x0)),_0x4f3731[_0x3efdaf(0x21c)][_0x3efdaf(0x2f0)](_0x29c15a[_0x3efdaf(0x2f8)][_0x3efdaf(0x2cc)](!0x0)));}else{const _0x2513e2=_0x323c7e[_0x3efdaf(0x2ac)][_0x3efdaf(0x21c)][0x0];if(!_0x2513e2)return null;_0x49701e[_0x3efdaf(0x21c)][_0x3efdaf(0x2f0)](_0x2513e2[_0x3efdaf(0x2cc)](!0x0)),_0x4f3731[_0x3efdaf(0x21c)][_0x3efdaf(0x2f0)](_0x2513e2[_0x3efdaf(0x2cc)](!0x0));}}const _0x30d4e5=_0x3788cb[_0x3efdaf(0x2bf)](),_0x537a7e=_0x28531e[_0x3efdaf(0x273)][_0x3efdaf(0x226)](_0x30d4e5[_0x3efdaf(0x302)]),_0x1295fa=_0x45c6b5(_0x49701e),_0x5e2312=_0x28531e[_0x3efdaf(0x273)][_0x3efdaf(0x226)](_0x1295fa),_0x21b297=_0x28531e[_0x3efdaf(0x273)][_0x3efdaf(0x226)](_0x1295fa),_0x33a1e6=_0x28531e[_0x3efdaf(0x23c)][_0x3efdaf(0x30c)](_0x5e2312,0x0),_0x49285c=_0x45c6b5(_0x4f3731),_0x228b8b={'anchor':_0x33a1e6,'markDeletions':!0x1},_0x5de7f6=_0x28531e[_0x3efdaf(0x1f5)][_0x3efdaf(0x29d)](_0x181444)[_0x3efdaf(0x1a8)](_0x1295fa,_0x49285c,_0x228b8b)[_0x3efdaf(0x2f5)]();if(!_0x5de7f6[_0x3efdaf(0x251)])return null;_0x28531e[_0x3efdaf(0x23c)][_0x3efdaf(0x2c4)](_0xf4c8c6=>{const _0x17f887=_0x3efdaf;for(const _0xb99f8a of _0x5de7f6)if(_0x17f887(0x27c)==_0xb99f8a[_0x17f887(0x195)]){const _0x2ca690=_0xb99f8a[_0x17f887(0x223)],_0x462ca6=_0xb99f8a[_0x17f887(0x246)],_0x2dc69d=new _0x467c1c(_0x2ca690,_0x462ca6);_0xf4c8c6[_0x17f887(0x191)][_0x17f887(0x24c)](_0x2dc69d),_0x28531e[_0x17f887(0x23c)][_0x17f887(0x1ac)](_0x2dc69d);}else _0x17f887(0x266)!==_0xb99f8a[_0x17f887(0x195)]&&(_0xb99f8a[_0x17f887(0x2c6)]=null,_0xb99f8a[_0x17f887(0x313)]=!0x1,_0xf4c8c6[_0x17f887(0x191)][_0x17f887(0x24c)](_0xb99f8a),_0x28531e[_0x17f887(0x23c)][_0x17f887(0x1ac)](_0xb99f8a));});const _0x4a2b63=_0x515b44(_0x28531e,_0x5de7f6,_0x5e2312);_0x3cc810(_0x28531e[_0x3efdaf(0x23c)],_0x4a2b63);const _0x3b55ef=_0x4a2b63[_0x3efdaf(0x24a)]()[_0x3efdaf(0x203)][_0x3efdaf(0x293)][_0x3efdaf(0x271)](),_0x5d6150=_0x4a2b63[_0x3efdaf(0x24a)]()[_0x3efdaf(0x27b)][_0x3efdaf(0x293)][_0x3efdaf(0x271)](),_0x3306c4=[];let _0x8e6236=_0x5e2312,_0xb05d9a=_0x21b297;for(let _0x298933=0x0;_0x298933<_0x5d6150[_0x3efdaf(0x251)];_0x298933++){const _0x3f68f1=_0x8e6236[_0x3efdaf(0x1c3)]-_0x5d6150[_0x298933];_0x3306c4[_0x298933]=_0xb05d9a[_0x3efdaf(0x1c3)]-_0x3f68f1,_0x8e6236=_0x8e6236[_0x3efdaf(0x1c7)](_0x5d6150[_0x298933]),_0xb05d9a=_0xb05d9a[_0x3efdaf(0x1c7)](_0x3306c4[_0x298933]);}const _0x5d3a53=_0x28531e[_0x3efdaf(0x23c)][_0x3efdaf(0x2e2)](_0x28531e[_0x3efdaf(0x23c)][_0x3efdaf(0x208)](_0x21b297,_0x3b55ef),_0x28531e[_0x3efdaf(0x23c)][_0x3efdaf(0x208)](_0x21b297,_0x3306c4)),_0x434555=_0x21b297[_0x3efdaf(0x2ca)](0x0)[_0x3efdaf(0x192)](_0x5a92da),_0x952069=Array[_0x3efdaf(0x1ff)](_0x537a7e[_0x3efdaf(0x2e9)]())[_0x3efdaf(0x30b)](_0x1f9dca=>_0x1f9dca[_0x3efdaf(0x192)](_0x5a92da)==_0x434555)[_0x3efdaf(0x24e)](),_0x25d3a1=_0x5d3a53[_0x3efdaf(0x203)][_0x3efdaf(0x293)][_0x3efdaf(0x271)](),_0x7b6fe0=_0x5d3a53[_0x3efdaf(0x27b)][_0x3efdaf(0x293)][_0x3efdaf(0x271)]();_0x25d3a1[0x0]=_0x952069[0x0]+_0x25d3a1[0x0],_0x7b6fe0[0x0]=_0x952069[0x0]+_0x7b6fe0[0x0];let _0x32182d=_0x28531e[_0x3efdaf(0x23c)][_0x3efdaf(0x2e2)](_0x28531e[_0x3efdaf(0x23c)][_0x3efdaf(0x208)](_0x28531e[_0x3efdaf(0x23c)][_0x3efdaf(0x219)][_0x3efdaf(0x304)](),_0x25d3a1),_0x28531e[_0x3efdaf(0x23c)][_0x3efdaf(0x208)](_0x28531e[_0x3efdaf(0x23c)][_0x3efdaf(0x219)][_0x3efdaf(0x304)](),_0x7b6fe0));const _0xcf1977=_0x28531e[_0x3efdaf(0x23c)][_0x3efdaf(0x219)][_0x3efdaf(0x2ff)][_0x3efdaf(0x2f5)](_0x30d4e5[_0x3efdaf(0x1a2)]);for(const _0x219e67 of _0xcf1977)_0x32182d=_0x4a1aab[_0x3efdaf(0x19a)](_0x32182d[_0x3efdaf(0x23d)](_0x219e67));return{'range':_0x32182d,'currentIndex':_0x59c8d7};}[_0x549e58(0x1cc)](_0x5f23f1){const _0x2b90cf=_0x549e58;if(!_0x5f23f1[_0x2b90cf(0x1f5)][_0x2b90cf(0x214)](_0x2b90cf(0x1aa)))return;const _0x44ed83=_0x5f23f1[_0x2b90cf(0x259)][_0x2b90cf(0x29d)](_0x2b90cf(0x1d7)),_0x597e8a=_0x5f23f1[_0x2b90cf(0x259)][_0x2b90cf(0x29d)](_0x2b90cf(0x1d1));this[_0x2b90cf(0x2c1)](_0x44ed83,_0x2b90cf(0x2da),(_0x2df795,_0x17614b,_0x7954d3)=>{const _0x4e19a2=_0x2b90cf,_0x47141c=this[_0x4e19a2(0x26a)][_0x4e19a2(0x29d)](_0x17614b);if(!_0x47141c)return;const _0x5a3c88=this[_0x4e19a2(0x1a3)][_0x4e19a2(0x1f0)](_0x47141c[_0x4e19a2(0x30a)])[_0x4e19a2(0x25e)](_0x47141c[_0x4e19a2(0x1c6)]);_0x47141c[_0x4e19a2(0x2a5)][_0x4e19a2(0x291)](_0x374649=>_0x5a3c88[_0x4e19a2(0x28f)](_0x374649,_0x4e19a2(0x1f6))),this[_0x4e19a2(0x26a)][_0x4e19a2(0x21b)](_0x17614b),this[_0x4e19a2(0x26a)][_0x4e19a2(0x1e2)](_0x7954d3,_0x47141c);}),this[_0x2b90cf(0x2c1)](_0x597e8a,_0x2b90cf(0x2da),(_0x11b710,_0x45971b,_0x2f652f)=>{const _0x1664b1=_0x2b90cf,_0x2b17f8=this[_0x1664b1(0x26a)][_0x1664b1(0x29d)](_0x45971b);if(!_0x2b17f8)return;const _0x55ef1d=this[_0x1664b1(0x1a3)][_0x1664b1(0x1f0)](_0x2b17f8[_0x1664b1(0x30a)])[_0x1664b1(0x25e)](_0x2b17f8[_0x1664b1(0x1c6)]);_0x2b17f8[_0x1664b1(0x2a5)][_0x1664b1(0x291)](_0x41c697=>_0x55ef1d[_0x1664b1(0x28f)](_0x41c697,_0x1664b1(0x2c8))),this[_0x1664b1(0x26a)][_0x1664b1(0x21b)](_0x45971b),this[_0x1664b1(0x26a)][_0x1664b1(0x1e2)](_0x2f652f,_0x2b17f8);});}async[_0x549e58(0x247)](_0xba540b){const _0x39f4da=_0x549e58;this[_0x39f4da(0x316)][_0x39f4da(0x1f5)][_0x39f4da(0x214)](_0x39f4da(0x2a0))&&this[_0x39f4da(0x316)][_0x39f4da(0x1f5)][_0x39f4da(0x29d)](_0x39f4da(0x2a0))[_0x39f4da(0x238)](),(this[_0x39f4da(0x316)][_0x39f4da(0x1f5)][_0x39f4da(0x29d)](_0xf3132e)[_0x39f4da(0x27f)][_0x39f4da(0x300)](_0x39f4da(0x2b7)),this[_0x39f4da(0x256)][_0x39f4da(0x23b)](_0x39f4da(0x2fe)),this[_0x39f4da(0x256)][_0x39f4da(0x240)](!0x0),await this[_0x39f4da(0x301)]());try{await this[_0x39f4da(0x283)][_0x39f4da(0x1b2)](_0xba540b)[_0x39f4da(0x2fc)](),await this[_0x39f4da(0x249)](_0xba540b),this[_0x39f4da(0x2d0)]('\x20'),await this[_0x39f4da(0x1a3)][_0x39f4da(0x201)](_0xba540b,this[_0x39f4da(0x205)][_0x39f4da(0x278)]),this[_0x39f4da(0x1a3)][_0x39f4da(0x26f)]()&&this[_0x39f4da(0x1e5)]();}catch(_0x1edf7f){this[_0x39f4da(0x256)][_0x39f4da(0x303)]({'errorMessage':_0x4b3662(this[_0x39f4da(0x316)][_0x39f4da(0x197)],_0x39f4da(0x210)),'id':_0xba540b}),this[_0x39f4da(0x2a3)](new _0x4463ae(_0x39f4da(0x20f),this,{'error':_0x1edf7f}));}finally{this[_0x39f4da(0x256)][_0x39f4da(0x211)](),this[_0x39f4da(0x256)][_0x39f4da(0x23b)](_0x39f4da(0x2d4)),this[_0x39f4da(0x256)][_0x39f4da(0x240)](!0x1);}}async[_0x549e58(0x1c1)](){const _0x1def88=_0x549e58,_0x29fdb9=this[_0x1def88(0x283)][_0x1def88(0x31b)](this[_0x1def88(0x26e)](),{'limit':0x1,'sortBy':_0x1def88(0x286)});try{const _0x819eda=await _0x29fdb9[_0x1def88(0x1fd)]();return _0x819eda[_0x1def88(0x251)]?_0x819eda[0x0]['id']:_0x1def88(0x2d8);}catch(_0x547bdb){return this[_0x1def88(0x256)][_0x1def88(0x303)]({'errorMessage':_0x4b3662(this[_0x1def88(0x316)][_0x1def88(0x197)],_0x1def88(0x210)),'id':_0x327016()}),this[_0x1def88(0x2a3)](new _0x4463ae(_0x1def88(0x1ab),this,{'error':_0x547bdb})),this[_0x1def88(0x256)][_0x1def88(0x240)](!0x1),this[_0x1def88(0x256)][_0x1def88(0x1d5)](),null;}}[_0x549e58(0x21a)](_0x171605){const _0x5468f2=_0x549e58;this[_0x5468f2(0x1a3)]['id']===_0x171605&&this[_0x5468f2(0x249)]();}[_0x549e58(0x1e5)](){const _0x4dec69=_0x549e58;this[_0x4dec69(0x1a3)]?.[_0x4dec69(0x20c)](_0x4b3662(this[_0x4dec69(0x316)][_0x4dec69(0x197)],_0x4dec69(0x245)));}async[_0x549e58(0x19d)](){const _0x1b6b38=_0x549e58,_0x52a9eb=this[_0x1b6b38(0x205)][_0x1b6b38(0x2e0)]();this[_0x1b6b38(0x1a3)]?.[_0x1b6b38(0x1b4)](_0x52a9eb),this[_0x1b6b38(0x1e5)]();}[_0x549e58(0x2f9)](){const _0x24e882=_0x549e58;this[_0x24e882(0x1a3)]?.[_0x24e882(0x235)]();}[_0x549e58(0x319)](){const _0x1dc4d9=_0x549e58;this[_0x1dc4d9(0x256)][_0x1dc4d9(0x319)]();}async[_0x549e58(0x24b)](){const _0x271550=_0x549e58;await this[_0x271550(0x249)]();}async[_0x549e58(0x1d2)]({message:_0x2f5c85,attributes:_0x2efcc1}){const _0x2c9b9a=_0x549e58;await this[_0x2c9b9a(0x252)]({'userMessage':_0x2f5c85,'attributes':_0x2efcc1});}[_0x549e58(0x26e)](){const _0x1f8742=_0x549e58,_0x2a0c82=this[_0x1f8742(0x316)][_0x1f8742(0x2ec)][_0x1f8742(0x29d)](_0x1f8742(0x260));if(!_0x2a0c82)throw new _0x4463ae(_0x1f8742(0x272),this);return _0x2a0c82;}async[_0x549e58(0x249)](_0x11751e){const _0x3f293e=_0x549e58;try{this[_0x3f293e(0x256)][_0x3f293e(0x233)](),await this[_0x3f293e(0x241)](_0x11751e);}catch(_0x12213c){this[_0x3f293e(0x256)][_0x3f293e(0x303)]({'errorMessage':_0x4b3662(this[_0x3f293e(0x316)][_0x3f293e(0x197)],_0x3f293e(0x294)),'id':_0x11751e||_0x327016()}),console[_0x3f293e(0x288)](_0x12213c),this[_0x3f293e(0x1a3)]=void 0x0,this[_0x3f293e(0x256)][_0x3f293e(0x1d5)]();}}async[_0x549e58(0x241)](_0x2e21e8){const _0x23468e=_0x549e58;let _0x53e4cc;this[_0x23468e(0x316)][_0x23468e(0x1f5)][_0x23468e(0x214)](_0x23468e(0x2a0))&&this[_0x23468e(0x316)][_0x23468e(0x1f5)][_0x23468e(0x29d)](_0x23468e(0x2a0))[_0x23468e(0x238)](),_0x2e21e8||!this[_0x23468e(0x1a3)]?_0x53e4cc=this[_0x23468e(0x316)][_0x23468e(0x2ec)][_0x23468e(0x29d)](_0x23468e(0x199)):this[_0x23468e(0x256)][_0x23468e(0x215)]&&(_0x53e4cc=this[_0x23468e(0x1a3)][_0x23468e(0x1b7)]['id']),await this[_0x23468e(0x301)]();const _0x1cdb76=this[_0x23468e(0x26e)](),_0x1bf4be=_0x2e21e8||_0x327016();this[_0x23468e(0x1a3)]=new _0x3c92d0({'connector':this[_0x23468e(0x283)],'chatModels':this[_0x23468e(0x2ae)],'selectedModelId':_0x53e4cc,'conversationId':_0x1bf4be,'group':_0x1cdb76,'getEditor':()=>_0x4ee1ac(this[_0x23468e(0x316)]),'isFromHistory':!!_0x2e21e8}),this[_0x23468e(0x1a3)][_0x23468e(0x2c7)](_0x23468e(0x200),_0x23468e(0x1b3))['to'](this),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x25a),(_0x37a61c,_0x37e815)=>{const _0x2001ff=_0x23468e;this[_0x2001ff(0x256)][_0x2001ff(0x26b)](_0x37e815),this[_0x2001ff(0x256)][_0x2001ff(0x1c9)](),this[_0x2001ff(0x256)][_0x2001ff(0x206)](),this[_0x2001ff(0x256)][_0x2001ff(0x2be)](),_0x2e21e8||(this[_0x2001ff(0x256)][_0x2001ff(0x1e0)](),this[_0x2001ff(0x1e5)]());}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x1fe),(_0x4d0709,_0x161ee7)=>{const _0x582e4d=_0x23468e;this[_0x582e4d(0x256)][_0x582e4d(0x30d)](_0x161ee7[_0x582e4d(0x2e3)]);}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x1d3),(_0x4419b2,_0x12fc01)=>{const _0xa3d7e0=_0x23468e;this[_0xa3d7e0(0x256)][_0xa3d7e0(0x277)](_0x12fc01);}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x209),()=>{const _0xc57575=_0x23468e,_0x54ed27=this[_0xc57575(0x256)][_0xc57575(0x28c)]({'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});this[_0xc57575(0x256)][_0xc57575(0x1cd)](_0x54ed27);}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x1bf),()=>{const _0x23e538=_0x23468e,_0x2f1c09=this[_0x23e538(0x256)][_0x23e538(0x28c)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});this[_0x23e538(0x256)][_0x23e538(0x1cd)](_0x2f1c09);}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x263),(_0x38cdc0,_0x5d646d)=>{const _0x409644=_0x23468e;this[_0x409644(0x256)][_0x409644(0x22b)](_0x5d646d,{'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x2a6),(_0x17d5a5,_0x5c694b)=>{const _0x58aef4=_0x23468e;this[_0x58aef4(0x256)][_0x58aef4(0x22b)](_0x5c694b,{'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x1b3),()=>{const _0x4f0867=_0x23468e;this[_0x4f0867(0x256)][_0x4f0867(0x1b9)]();}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x2c3),async()=>{const _0x3c3d16=_0x23468e;await this[_0x3c3d16(0x256)][_0x3c3d16(0x225)]();}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x1e8),(_0x2d24e7,_0xaa2970)=>{const _0x9dcbd5=_0x23468e;this[_0x9dcbd5(0x256)][_0x9dcbd5(0x2d1)](_0xaa2970['id']);}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x26c),(_0x3da819,_0x39770d,_0xa3b591)=>{const _0x5e6cde=_0x23468e;this[_0x5e6cde(0x2d0)](_0x39770d,_0xa3b591);}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x2cb),(_0xe751d,_0xdf0653)=>{const _0x34aff6=_0x23468e;_0x34aff6(0x29c)===_0xdf0653[_0x34aff6(0x195)]?this[_0x34aff6(0x256)][_0x34aff6(0x1bb)](_0xdf0653):this[_0x34aff6(0x256)][_0x34aff6(0x1ce)](_0xdf0653);}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x237),async(_0x122261,_0x162478)=>{const _0x87b7e7=_0x23468e;await this[_0x87b7e7(0x1ee)]({'reply':_0x162478});}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x254),(_0x1f20e0,{reply:_0x154d3e,index:_0x28ab83,state:_0x4d35c5})=>{const _0x24cde8=_0x23468e;this[_0x24cde8(0x256)][_0x24cde8(0x2ef)]({'id':_0x154d3e['id'],'index':_0x28ab83,'state':_0x4d35c5}),this[_0x24cde8(0x1f7)]?.[_0x24cde8(0x1c6)][_0x24cde8(0x299)](_0x154d3e['id'])&&this[_0x24cde8(0x1f7)]?.[_0x24cde8(0x2d6)]==_0x28ab83&&this[_0x24cde8(0x2b3)]?.[_0x24cde8(0x25b)](_0x4d35c5);}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x20a),(_0x265087,_0x5cb021)=>{const _0x35c2a9=_0x23468e;if(this[_0x35c2a9(0x256)][_0x35c2a9(0x1d4)](_0x5cb021[_0x35c2a9(0x1ea)],_0x5cb021[_0x35c2a9(0x285)]),_0x35c2a9(0x2f3)===_0x5cb021[_0x35c2a9(0x1ea)][_0x35c2a9(0x195)]){const _0x12d95f=[..._0x4ee1ac(this[_0x35c2a9(0x316)])[_0x35c2a9(0x23c)][_0x35c2a9(0x219)][_0x35c2a9(0x2f3)][_0x35c2a9(0x1a5)]()];this[_0x35c2a9(0x205)][_0x35c2a9(0x1cf)](_0x12d95f,_0x35c2a9(0x2bd)+this[_0x35c2a9(0x1a3)]?.['id']);}}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x2c9),(_0x3ba5f8,_0x3da658)=>{const _0x284e4e=_0x23468e;this[_0x284e4e(0x256)][_0x284e4e(0x298)](_0x3da658[_0x284e4e(0x1df)]),_0x284e4e(0x198)==_0x3da658[_0x284e4e(0x1df)]&&this[_0x284e4e(0x2f9)](),_0x284e4e(0x2f3)===_0x3da658[_0x284e4e(0x195)]&&this[_0x284e4e(0x205)][_0x284e4e(0x265)](_0x284e4e(0x2bd)+this[_0x284e4e(0x1a3)]?.['id']);}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x1c2),(_0x17c800,_0x54af4f)=>{const _0x58f94e=_0x23468e;this[_0x58f94e(0x256)][_0x58f94e(0x1af)](_0x54af4f[_0x58f94e(0x1ea)][_0x58f94e(0x1df)],_0x54af4f[_0x58f94e(0x285)]);}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x29f),(_0x4d42c9,_0x10b24b)=>{const _0x76caa2=_0x23468e;this[_0x76caa2(0x256)][_0x76caa2(0x2ab)](_0x10b24b[_0x76caa2(0x2e5)]);}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x1b1),(_0x175ba0,_0x2779fb)=>{const _0x4ff4f6=_0x23468e;this[_0x4ff4f6(0x256)][_0x4ff4f6(0x2fa)](_0x2779fb[_0x4ff4f6(0x1eb)]);}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x1a7),(_0x544fcb,_0x58e969)=>{const _0x2d25f7=_0x23468e;this[_0x2d25f7(0x256)][_0x2d25f7(0x317)](_0x58e969[_0x2d25f7(0x1f1)],_0x58e969[_0x2d25f7(0x2d2)],_0x58e969[_0x2d25f7(0x2cd)],_0x58e969[_0x2d25f7(0x289)]);}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x315),(_0x10bce1,_0x2e36cb)=>{const _0x3f1dcb=_0x23468e;this[_0x3f1dcb(0x256)][_0x3f1dcb(0x309)](_0x2e36cb[_0x3f1dcb(0x1f1)],_0x2e36cb[_0x3f1dcb(0x253)],_0x2e36cb[_0x3f1dcb(0x2b6)]);}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x22c),(_0x182543,_0x1ced36)=>{const _0x19438f=_0x23468e;this[_0x19438f(0x256)][_0x19438f(0x2e6)](_0x1ced36);}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x242),async(_0x5c28a9,_0x2c567e)=>{const _0x5a8bd6=_0x23468e,_0x4e8f28=(await this[_0x5a8bd6(0x2ae)][_0x5a8bd6(0x1ba)]())[_0x5a8bd6(0x30b)](_0x2fc143=>_0x2fc143['id']===_0x2c567e[_0x5a8bd6(0x1b7)]?.['id'])||null;this[_0x5a8bd6(0x256)][_0x5a8bd6(0x2aa)](_0x4e8f28,_0x2c567e[_0x5a8bd6(0x23f)]);}),this[_0x23468e(0x1a3)]['on'](_0x23468e(0x288),(_0x528136,{error:_0x3350dc,interactionId:_0x5af8d9,fileName:_0x21e311,url:_0x3e6167,sourceId:_0x206f11,sourceLabel:_0x414121})=>{const _0x5b103e=_0x23468e,_0x3042da=_0x5af8d9?_0x5af8d9+':'+_0x327016():_0x327016();_0x3350dc[_0x5b103e(0x1bd)][_0x5b103e(0x1e1)](_0x5b103e(0x1db))?this[_0x5b103e(0x256)][_0x5b103e(0x21e)]({'staticMessage':_0x4b3662(this[_0x5b103e(0x316)][_0x5b103e(0x197)],_0x5b103e(0x1c5)),'id':_0x3042da}):_0x3350dc[_0x5b103e(0x1bd)][_0x5b103e(0x1e1)](_0x5b103e(0x1ab))||_0x3350dc[_0x5b103e(0x1bd)][_0x5b103e(0x1e1)](_0x5b103e(0x2e4))?(this[_0x5b103e(0x256)][_0x5b103e(0x303)]({'errorMessage':_0x4b3662(this[_0x5b103e(0x316)][_0x5b103e(0x197)],_0x5b103e(0x294)),'id':_0x3042da}),this[_0x5b103e(0x2a3)](_0x3350dc)):_0x3350dc[_0x5b103e(0x1bd)][_0x5b103e(0x1e1)](_0x5b103e(0x1fb))?this[_0x5b103e(0x256)][_0x5b103e(0x303)]({'errorMessage':_0x4b3662(this[_0x5b103e(0x316)][_0x5b103e(0x197)],_0x5b103e(0x24d),_0x21e311),'id':_0x3042da}):_0x3350dc[_0x5b103e(0x1bd)][_0x5b103e(0x1e1)](_0x5b103e(0x2ce))?this[_0x5b103e(0x256)][_0x5b103e(0x303)]({'errorMessage':_0x4b3662(this[_0x5b103e(0x316)][_0x5b103e(0x197)],_0x5b103e(0x2eb),_0x3e6167),'id':_0x3042da}):_0x3350dc[_0x5b103e(0x1bd)][_0x5b103e(0x1e1)](_0x5b103e(0x2f6))?this[_0x5b103e(0x256)][_0x5b103e(0x303)]({'errorMessage':_0x4b3662(this[_0x5b103e(0x316)][_0x5b103e(0x197)],_0x5b103e(0x27d)),'id':_0x3042da}):_0x3350dc[_0x5b103e(0x1bd)][_0x5b103e(0x1e1)](_0x5b103e(0x310))?this[_0x5b103e(0x256)][_0x5b103e(0x303)]({'errorMessage':_0x4b3662(this[_0x5b103e(0x316)][_0x5b103e(0x197)],_0x5b103e(0x244)),'id':_0x3042da}):_0x3350dc[_0x5b103e(0x1bd)][_0x5b103e(0x1e1)](_0x5b103e(0x19b))?(_0x206f11&&this[_0x5b103e(0x256)][_0x5b103e(0x1b6)](_0x206f11),this[_0x5b103e(0x256)][_0x5b103e(0x303)]({'errorMessage':_0x4b3662(this[_0x5b103e(0x316)][_0x5b103e(0x197)],_0x5b103e(0x2b2),_0x414121||_0x5b103e(0x2d2)),'id':_0x3042da}),this[_0x5b103e(0x2a3)](_0x3350dc)):_0x3350dc[_0x5b103e(0x1bd)][_0x5b103e(0x1e1)](_0x5b103e(0x20b))?(this[_0x5b103e(0x256)][_0x5b103e(0x303)]({'errorMessage':_0x4b3662(this[_0x5b103e(0x316)][_0x5b103e(0x197)],_0x5b103e(0x22a)),'id':_0x3042da}),this[_0x5b103e(0x2a3)](_0x3350dc)):_0x3350dc[_0x5b103e(0x1bd)][_0x5b103e(0x1e1)](_0x5b103e(0x213))?(this[_0x5b103e(0x256)][_0x5b103e(0x303)]({'errorMessage':_0x4b3662(this[_0x5b103e(0x316)][_0x5b103e(0x197)],_0x5b103e(0x1d9)),'id':_0x3042da}),this[_0x5b103e(0x2a3)](_0x3350dc)):_0x3350dc[_0x5b103e(0x1bd)][_0x5b103e(0x1e1)](_0x5b103e(0x1ae))?(this[_0x5b103e(0x256)][_0x5b103e(0x303)]({'errorMessage':_0x4b3662(this[_0x5b103e(0x316)][_0x5b103e(0x197)],_0x5b103e(0x193)),'id':_0x3042da}),this[_0x5b103e(0x2a3)](_0x3350dc)):_0x3350dc[_0x5b103e(0x1bd)][_0x5b103e(0x1e1)](_0x5b103e(0x2b4))?(this[_0x5b103e(0x256)][_0x5b103e(0x303)]({'errorMessage':_0x4b3662(this[_0x5b103e(0x316)][_0x5b103e(0x197)],_0x5b103e(0x29b)),'id':_0x3042da}),this[_0x5b103e(0x2a3)](_0x3350dc)):_0x3350dc[_0x5b103e(0x1bd)][_0x5b103e(0x1e1)](_0x5b103e(0x22d))?(this[_0x5b103e(0x256)][_0x5b103e(0x303)]({'errorMessage':_0x4b3662(this[_0x5b103e(0x316)][_0x5b103e(0x197)],_0x5b103e(0x257)),'id':_0x3042da}),this[_0x5b103e(0x2a3)](_0x3350dc)):_0x3350dc[_0x5b103e(0x1bd)][_0x5b103e(0x1e1)](_0x5b103e(0x314))?(this[_0x5b103e(0x256)][_0x5b103e(0x303)]({'errorMessage':_0x4b3662(this[_0x5b103e(0x316)][_0x5b103e(0x197)],_0x5b103e(0x290)),'id':_0x3042da}),this[_0x5b103e(0x2a3)](_0x3350dc)):(this[_0x5b103e(0x256)][_0x5b103e(0x303)]({'errorMessage':_0x4b3662(this[_0x5b103e(0x316)][_0x5b103e(0x197)],_0x5b103e(0x307)),'id':_0x3042da}),this[_0x5b103e(0x2a3)](_0x3350dc));}),await this[_0x23468e(0x1a3)][_0x23468e(0x22f)](this[_0x23468e(0x316)][_0x23468e(0x2ec)][_0x23468e(0x29d)](_0x23468e(0x21d))),_0x2e21e8||await this[_0x23468e(0x1a3)][_0x23468e(0x203)]();}async[_0x549e58(0x252)]({userMessage:_0x466e6f,attributes:_0x21b2c2}){const _0x186a92=_0x549e58;if(!this[_0x186a92(0x1a3)])throw new _0x4463ae(_0x186a92(0x2f4));if(this[_0x186a92(0x1a3)][_0x186a92(0x262)]()){const _0x4b322e=await this[_0x186a92(0x205)][_0x186a92(0x231)]();await this[_0x186a92(0x1a3)][_0x186a92(0x1da)](_0x4b322e);}this[_0x186a92(0x1a3)]['id']&&this[_0x186a92(0x1a3)][_0x186a92(0x1e9)]&&await this[_0x186a92(0x1a3)][_0x186a92(0x2f2)]({'userMessage':_0x466e6f,'attributes':_0x21b2c2});}[_0x549e58(0x1e6)](){const _0x52b855=_0x549e58;console[_0x52b855(0x268)](_0x52b855(0x264));}[_0x549e58(0x2ea)](_0x46814e){const _0xc652c=_0x549e58;this[_0xc652c(0x256)][_0xc652c(0x1fa)](_0x46814e);}[_0x549e58(0x2a3)](_0x199568){const _0x5b80b9=_0x549e58;_0x5d0d75(_0x199568[_0x5b80b9(0x1bd)]);}[_0x549e58(0x24f)](_0x182cd4){const _0x2d4f67=_0x549e58;this[_0x2d4f67(0x1a3)]?.[_0x2d4f67(0x2a8)](_0x182cd4);}[_0x549e58(0x227)](){const _0x29c436=_0x549e58;this[_0x29c436(0x1a3)]?.[_0x29c436(0x229)]();}[_0x549e58(0x1c0)](){const _0x6cfd80=_0x549e58;this[_0x6cfd80(0x1a3)]?.[_0x6cfd80(0x28d)]();}[_0x549e58(0x282)](_0x4055e1){const _0x210623=_0x549e58,[_0x37c9e0,_0x5729bc]=_0x4055e1[_0x210623(0x19f)](':'),_0x14c550=this[_0x210623(0x1a3)][_0x210623(0x1f0)](_0x37c9e0),_0x4b5f51=_0x14c550[_0x210623(0x25e)](_0x5729bc);return{'interaction':_0x14c550,'reply':_0x4b5f51};}[_0x549e58(0x2db)](_0x4918b7,_0x281cfa=!0x1){const _0x557bb8=_0x549e58,_0x3c7b74=_0x4ee1ac(this[_0x557bb8(0x316)]),_0x44ff6c={'target':_0x3c7b74[_0x557bb8(0x1f3)][_0x557bb8(0x27f)][_0x557bb8(0x2ee)][_0x557bb8(0x23a)](_0x3c7b74[_0x557bb8(0x1f3)][_0x557bb8(0x1a1)][_0x557bb8(0x1f9)](_0x4918b7)),'viewportOffset':{'top':0x96,'left':0x0,'bottom':0x32,'right':0x0},'ancestorOffset':0x14,'alignToTop':_0x281cfa};_0x281cfa&&(_0x44ff6c[_0x557bb8(0x2fd)]=!0x0),_0x2f1661(_0x44ff6c);}[_0x549e58(0x2d0)](_0x45d587,_0x3dee12=!0x1){const _0x40562b=_0x549e58;this[_0x40562b(0x256)][_0x40562b(0x26c)](_0x45d587||_0x4b3662(this[_0x40562b(0x316)][_0x40562b(0x197)],_0x40562b(0x2cf)),_0x3dee12);}async[_0x549e58(0x1ee)]({reply:_0x2a476a,renderingStrategy:_0x48f4bd}){const _0x9bd327=_0x549e58,{id:_0x120f15,interactionId:_0x4ba276,isDone:_0x32c155,type:_0x5629bb,parsedContent:_0x153661}=_0x2a476a,_0x488fb0=_0x4ba276+':'+_0x120f15;if(_0x9bd327(0x1ef)===_0x5629bb){const _0xc5012f=_0x2a476a[_0x9bd327(0x306)]({'showDiff':this[_0x9bd327(0x256)][_0x9bd327(0x1dc)]});await this[_0x9bd327(0x256)][_0x9bd327(0x2c0)]({'id':_0x488fb0,'parts':_0xc5012f,'renderingStrategy':_0x48f4bd,'isDone':_0x32c155});}else _0x9bd327(0x29c)===_0x5629bb&&await this[_0x9bd327(0x256)][_0x9bd327(0x2a9)]({'id':_0x488fb0,'parsedContent':_0x153661,'renderingStrategy':_0x48f4bd,'isDone':_0x32c155});_0x32c155&&_0x2a476a[_0x9bd327(0x279)][_0x9bd327(0x251)]>0x0&&this[_0x9bd327(0x256)][_0x9bd327(0x2e7)](_0x488fb0,_0x2a476a[_0x9bd327(0x279)]);}async[_0x549e58(0x301)](){const _0x55b142=_0x549e58,_0x2b02a0=this[_0x55b142(0x1a3)]?.[_0x55b142(0x284)];_0x2b02a0&&(_0x2b02a0[_0x55b142(0x2ed)](),this[_0x55b142(0x256)][_0x55b142(0x1f2)](_0x2b02a0));}async[_0x549e58(0x228)](){const _0x333cf2=_0x549e58,_0x15e8b5=this[_0x333cf2(0x1a3)]?.[_0x333cf2(0x284)];if(_0x15e8b5){for await(const _0x2722ec of _0x15e8b5[_0x333cf2(0x312)])await this[_0x333cf2(0x1ee)]({'reply':_0x2722ec,'renderingStrategy':_0x333cf2(0x2fe)});}}[_0x549e58(0x29a)](_0x1d2f58){const _0x52bda4=_0x549e58,_0x267ea1={'positiveCount':_0x1d2f58[_0x52bda4(0x1f8)][_0x52bda4(0x275)](_0x5709c7=>_0x52bda4(0x2c8)===_0x5709c7[_0x52bda4(0x2d7)])[_0x52bda4(0x251)],'totalCount':_0x1d2f58[_0x52bda4(0x1f8)][_0x52bda4(0x251)],'modificationId':_0x1d2f58['id']},_0x3198d5=this[_0x52bda4(0x1a3)][_0x52bda4(0x1f0)](_0x1d2f58[_0x52bda4(0x30a)])[_0x52bda4(0x30e)];_0x3198d5&&this[_0x52bda4(0x283)][_0x52bda4(0x287)](this[_0x52bda4(0x1a3)]['id'],_0x3198d5,_0x267ea1);}[_0x549e58(0x1ed)](_0x397437){const _0x1bef6f=_0x549e58;let _0x5a30ee=null,_0x1caacd=null;this['on'](_0x1bef6f(0x200),(_0x358507,_0x511a8f,_0x2081b8)=>{const _0x17ca84=_0x1bef6f;_0x2081b8['id']!==_0x5a30ee&&(_0x5a30ee=_0x2081b8['id'],_0x1caacd=this[_0x17ca84(0x250)](_0x2081b8)),_0x397437(_0x511a8f,_0x1caacd);});}[_0x549e58(0x250)](_0x2324f6){const _0x3cc9f6=_0x549e58,_0x24573f=this[_0x3cc9f6(0x256)],_0xf1c82d=()=>{const _0x49ca50=_0x3cc9f6;_0x2324f6[_0x49ca50(0x25c)](),_0x2324f6[_0x49ca50(0x220)](),_0x24573f[_0x49ca50(0x30f)]();},_0x3ffeaa=()=>{const _0xcd9475=_0x3cc9f6;_0x2324f6[_0xcd9475(0x243)]&&(_0x2324f6[_0xcd9475(0x243)][_0xcd9475(0x1a6)](),_0x2324f6[_0xcd9475(0x243)]=void 0x0);};return{'insertTextReply':(_0x17d826,_0x234a4d)=>{const _0x57c9a5=_0x3cc9f6;_0x3ffeaa(),_0xf1c82d();const _0x316734=_0x2324f6[_0x57c9a5(0x243)]=_0x2324f6[_0x57c9a5(0x224)]({'type':_0x57c9a5(0x29c),'interactionId':_0x2324f6['id'],'content':_0x17d826,'id':_0x234a4d||_0x327016()});return _0x3ffeaa(),_0x316734;},'insertCustomElement':async(_0x5e1ae6,_0x40e29b)=>(_0x3ffeaa(),_0xf1c82d(),_0x24573f[_0x3cc9f6(0x1c8)](_0x5e1ae6,_0x40e29b||_0x327016())),'setLoadingMessage':_0x2bd119=>{const _0x2a2e48=_0x3cc9f6;_0x24573f[_0x2a2e48(0x1cd)](_0x2bd119);},'clearLoadingMessage':()=>{const _0x1f891c=_0x3cc9f6;_0x24573f[_0x1f891c(0x30f)]();}};}}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x5b30e0=_0x208a;(function(_0x3f2555,_0x36db1c){const _0x122913=_0x208a,_0x4fc272=_0x3f2555();while(!![]){try{const _0x360610=parseInt(_0x122913(0x127))/0x1*(-parseInt(_0x122913(0x160))/0x2)+parseInt(_0x122913(0x19c))/0x3*(parseInt(_0x122913(0x153))/0x4)+-parseInt(_0x122913(0x139))/0x5*(-parseInt(_0x122913(0x185))/0x6)+parseInt(_0x122913(0x1bf))/0x7*(parseInt(_0x122913(0x178))/0x8)+-parseInt(_0x122913(0x170))/0x9*(parseInt(_0x122913(0x12c))/0xa)+-parseInt(_0x122913(0x1b6))/0xb+parseInt(_0x122913(0x1ac))/0xc;if(_0x360610===_0x36db1c)break;else _0x4fc272['push'](_0x4fc272['shift']());}catch(_0x571fa7){_0x4fc272['push'](_0x4fc272['shift']());}}}(_0x3c6c,0x62c91));import{ContextPlugin as _0x14576b}from'ckeditor5/src/core.js';import{_isMotionReduced as _0x482524}from'ckeditor5/src/utils.js';import{AIChatView as _0x522b38}from'./ui/aichatview.js';import{AITabs as _0x15c315}from'../aitabs/aitabs.js';import{getTranslation as _0x2b4b9a}from'../aicore/utils/common-translations.js';import{IconAIChat as _0x19435b}from'ckeditor5/src/icons.js';function _0x208a(_0x3a4771,_0x8ec7ad){const _0x3c6c77=_0x3c6c();return _0x208a=function(_0x208a49,_0x28276a){_0x208a49=_0x208a49-0x11c;let _0x605e65=_0x3c6c77[_0x208a49];return _0x605e65;},_0x208a(_0x3a4771,_0x8ec7ad);}import{AIChatFeedInteractionHeaderView as _0x2a22d5}from'./ui/feed/aichatfeedinteractionheaderview.js';import{PromiseQueue as _0x2035af}from'./utils/promisequeue.js';import{AI_CHAT_UI_EVENT_NAMES as _0x3cb218}from'./utils/eventnames.js';import'../../theme/aichat/aichat.css';function _0x3c6c(){const _0x58bf21=['conversationCreated','36417LGehOb','user-message','setIsMaximized','chatControls','from','clearConversationContextUI','isBusy','clearLoadingMessage','isDone','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH','isVisible','updateSuggestionItem','removeFeedItem','updateWebSources','contextItems','setFeedItemAIReplySuggestionPartActive','4895040HzJrAB','removeItem','bind','interaction-header','AI_CHAT_FEED_LOADING_MESSAGE_REASONING','value','updateFeedItemAIReplySuggestionPartState','updateSuggestionPartState','AIChatUI','AITabs','2280201oLpUrH','setModelList','ai.chat.context.searchInputVisibleFrom','setInputPlaceholder','addFeedItemCustomElement','setFeedItemRenderingStrategy','trackChanges','updateResourceState','enableControls','23807gzGeNK','values','startAutoScroll','chatHeader','conversation-start','filter','prepareLoadingMessage','commands','userMessage','isMaximized','addFeedItemAIReply','areActionsDisabled','scrollToSuggestion','get','isTrackChangesOn','addItem','stopAutoScroll','addFeedItemError','startInteraction','capabilities','isDisabled','setReasoning','setContextItemLoading','destroy','AI_CHAT_WELCOME_MESSAGE','length','addFeedInteractionHeader','stopInteraction','queueEmptyPromise','54667QABPYu','requires','createConversation','isModelAvailable','locale','6330bKYzKz','finishInteraction','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REGULAR','_view','markItemAsDone','toggleLoadingSkeleton','_interactionPromiseResolver','resetConversationTitle','addFeedItemAISuggestion','_animateConversationTitle','last','clearPendingContextUI','updateFeedInteractionHeader','10dwMTnz','updateFeedItemAIReplySources','chat','ai-suggestion-reply','setLoadingMessage','setWebSearch','remove','_promiseQueue','updateFeedItemAIReplySuggestionContent','isPremiumPlugin','setModel','markFeedItemAsDone','view','hasItem','AI_CHAT_FEED_LOADING_MESSAGE_REGULAR','removeContextItem','resetMessageInput','displayedPrompt','interactionId','availableModels','plugins','attributes','focusPromptInput','startsWith','chatFeed','isReasoningEnabled','204NctLda','disableControls','forEach','TrackChanges','</p>','children','context','custom-element','updateReplyItem','_titleAnimationInterval','abort','addFeedItemUserMessage','setIsUploadInProgress','22bezCEi','getItemIds','toggleSuggestionDisplayMode','enableModelSelector','addFeedItemStaticMessage','showResizeButton','ai-reply','populateSourceResourceBalloon','ai.chat.welcomeMessage','then','options','isWebSearchEnabled','updateFeedItemAIReplyContent','clear','delegate','closeSourceResourceBalloon','3582SWWpGQ','setConversationTitle','set','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REASONING','addTab','ai.availableReplyActions','hasFeedItem','setPromptInputValue','48qfzeSU','setConversationContext','insertSuggestion','config','isPending','label','showDiff','AI_CHAT_HEADING','scrollFeedToSuggestion','streaming','error-message','has','setAddContextOptions','1253316noYNkB','setSelectedModel','<p>','enqueue','addContextItem','updateCapabilities','ai.models.showModelSelector','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH_REASONING','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH_REASONING','setSuggestionPartActive','disableModelSelector','removeFeedInteraction','renderingStrategy','isOfficialPlugin','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH','pluginName','_getInputPlaceholder','find','_isTrackChangesCommandValueBound','fire','isLoading','feedItemRenderingStrategy'];_0x3c6c=function(){return _0x58bf21;};return _0x3c6c();}import{getEditorFromContext as _0xdcfe5}from'../aicore/utils/geteditorfromcontext.js';import{AI_REPLY_ACTIONS as _0x1b7ec6}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';export class AIChatUI extends _0x14576b{static get[_0x5b30e0(0x128)](){return[_0x15c315];}[_0x5b30e0(0x12f)];static get[_0x5b30e0(0x194)](){const _0x4254a7=_0x5b30e0;return _0x4254a7(0x1b4);}static get[_0x5b30e0(0x192)](){return!0x0;}static get[_0x5b30e0(0x142)](){return!0x0;}[_0x5b30e0(0x19a)]=_0x5b30e0(0x181);[_0x5b30e0(0x17e)]=!0x0;[_0x5b30e0(0x140)];[_0x5b30e0(0x132)];[_0x5b30e0(0x15c)]=void 0x0;[_0x5b30e0(0x197)]=!0x1;constructor(_0x57a970){const _0x308d03=_0x5b30e0;super(_0x57a970);const _0x47fec1=this[_0x308d03(0x159)][_0x308d03(0x14d)][_0x308d03(0x1cc)](_0x308d03(0x1b5));this[_0x308d03(0x172)](_0x308d03(0x1a2),!0x1),this[_0x308d03(0x140)]=new _0x2035af(),this[_0x308d03(0x12f)]=new _0x522b38(this[_0x308d03(0x159)][_0x308d03(0x12b)],{'showResizeButton':_0x47fec1[_0x308d03(0x165)],'contextResourcesSearchInputVisibleFrom':this[_0x308d03(0x159)][_0x308d03(0x17b)][_0x308d03(0x1cc)](_0x308d03(0x1b8))}),this[_0x308d03(0x12f)][_0x308d03(0x16e)](..._0x3cb218)['to'](this),this[_0x308d03(0x12f)]['on'](_0x308d03(0x162),(_0x4b62c3,{showDiff:_0x3b08e3})=>{const _0x401391=_0x308d03;this[_0x401391(0x17e)]=_0x3b08e3;}),_0x47fec1[_0x308d03(0x145)][_0x308d03(0x174)]({'id':_0x308d03(0x13b),'buttonLabel':_0x2b4b9a(this[_0x308d03(0x159)][_0x308d03(0x12b)],_0x308d03(0x17f)),'buttonIcon':_0x19435b,'order':0x0,'content':this[_0x308d03(0x12f)]}),this[_0x308d03(0x12f)][_0x308d03(0x19f)][_0x308d03(0x1ae)](_0x308d03(0x199))['to'](this,_0x308d03(0x1a2),_0x2b4a61=>_0x2b4a61),this[_0x308d03(0x12f)][_0x308d03(0x151)][_0x308d03(0x1ae)](_0x308d03(0x17c))['to'](this,_0x308d03(0x1a2),_0x26fa56=>_0x26fa56),this[_0x308d03(0x12f)][_0x308d03(0x19f)][_0x308d03(0x1b9)](this[_0x308d03(0x195)]()),this[_0x308d03(0x1ae)](_0x308d03(0x12a))['to'](this[_0x308d03(0x12f)][_0x308d03(0x19f)],_0x308d03(0x12a));}[_0x5b30e0(0x121)](){const _0x42136b=_0x5b30e0;super[_0x42136b(0x121)](),this[_0x42136b(0x15c)]&&clearInterval(this[_0x42136b(0x15c)]);}[_0x5b30e0(0x129)](_0x5d3476){const _0x3f7764=_0x5b30e0,_0x55f8da=this[_0x3f7764(0x159)][_0x3f7764(0x17b)][_0x3f7764(0x1cc)](_0x3f7764(0x168))??_0x2b4b9a(this[_0x3f7764(0x159)][_0x3f7764(0x12b)],_0x3f7764(0x122));this[_0x3f7764(0x12f)][_0x3f7764(0x151)][_0x3f7764(0x16d)](),this[_0x3f7764(0x12f)][_0x3f7764(0x19f)][_0x3f7764(0x163)](),this[_0x3f7764(0x12f)][_0x3f7764(0x19f)][_0x3f7764(0x1b7)](_0x5d3476[_0x3f7764(0x14c)],!this[_0x3f7764(0x159)][_0x3f7764(0x17b)][_0x3f7764(0x1cc)](_0x3f7764(0x18b))),this[_0x3f7764(0x164)]({'id':_0x3f7764(0x1c3),'staticMessage':_0x55f8da}),this[_0x3f7764(0x198)](_0x3f7764(0x19b));}[_0x5b30e0(0x164)]({id:_0x318dfd,staticMessage:_0x260f52}){const _0xd3b4a=_0x5b30e0;this[_0xd3b4a(0x12f)][_0xd3b4a(0x151)][_0xd3b4a(0x1ce)](_0xd3b4a(0x166),{'id':_0x318dfd,'initialContent':_0xd3b4a(0x187)+_0x260f52+_0xd3b4a(0x157)});}[_0x5b30e0(0x15e)](_0x34f1be){const _0x5e3f4c=_0x5b30e0,_0x13b511=_0x34f1be[_0x5e3f4c(0x14e)]?.[_0x5e3f4c(0x14a)]||_0x34f1be[_0x5e3f4c(0x1c7)];this[_0x5e3f4c(0x12f)][_0x5e3f4c(0x151)][_0x5e3f4c(0x1ce)](_0x5e3f4c(0x19d),{'contextItems':Array[_0x5e3f4c(0x1a0)](_0x34f1be[_0x5e3f4c(0x1aa)][_0x5e3f4c(0x1c0)]()),'initialContent':_0x5e3f4c(0x187)+_0x13b511+_0x5e3f4c(0x157),'id':_0x34f1be['id']});}[_0x5b30e0(0x1d0)]({errorMessage:_0x3d4ef3,id:_0x3cf878}){const _0x43f0d9=_0x5b30e0;this[_0x43f0d9(0x12f)][_0x43f0d9(0x151)][_0x43f0d9(0x1ce)](_0x43f0d9(0x182),{'initialContent':_0x43f0d9(0x187)+_0x3d4ef3+_0x43f0d9(0x157),'id':_0x3cf878});}[_0x5b30e0(0x1c9)](_0x8fba42){const _0x55b14f=_0x5b30e0;return this[_0x55b14f(0x140)][_0x55b14f(0x188)](async()=>{const _0x1e050d=_0x55b14f;this[_0x1e050d(0x12f)][_0x1e050d(0x151)][_0x1e050d(0x1ce)](_0x1e050d(0x166),{'id':_0x8fba42[_0x1e050d(0x14b)]+':'+_0x8fba42['id']}),this[_0x1e050d(0x1a3)]();});}async[_0x5b30e0(0x134)](_0x1e76fe){const _0x31ba4e=_0x5b30e0,_0x5d0ed3=_0xdcfe5(this[_0x31ba4e(0x159)]);let _0x4587c9=_0x5d0ed3[_0x31ba4e(0x17b)][_0x31ba4e(0x1cc)](_0x31ba4e(0x175))||[..._0x1b7ec6];if(_0x5d0ed3[_0x31ba4e(0x14d)][_0x31ba4e(0x183)](_0x31ba4e(0x156))){if(!this[_0x31ba4e(0x197)]){this[_0x31ba4e(0x197)]=!0x0;const _0x3007a3=_0x5d0ed3[_0x31ba4e(0x1c6)][_0x31ba4e(0x1cc)](_0x31ba4e(0x1bc));this[_0x31ba4e(0x12f)][_0x31ba4e(0x151)][_0x31ba4e(0x1ae)](_0x31ba4e(0x1cd))['to'](_0x3007a3,_0x31ba4e(0x1b1));}}else _0x4587c9=_0x4587c9[_0x31ba4e(0x1c4)](_0x3c5562=>_0x31ba4e(0x17a)!=_0x3c5562);return this[_0x31ba4e(0x140)][_0x31ba4e(0x188)](async()=>{const _0x5e22c0=_0x31ba4e;this[_0x5e22c0(0x12f)][_0x5e22c0(0x151)][_0x5e22c0(0x1ce)](_0x5e22c0(0x13c),{'id':_0x1e76fe[_0x5e22c0(0x14b)]+':'+_0x1e76fe['id'],'areActionsDisabled':_0x1e76fe[_0x5e22c0(0x1ca)],'showDiff':this[_0x5e22c0(0x17e)],'availableActions':_0x4587c9}),this[_0x5e22c0(0x1a3)]();});}[_0x5b30e0(0x124)](_0x102e31,_0x1cca37){const _0x3458aa=_0x5b30e0,_0x28037a=this[_0x3458aa(0x12f)][_0x3458aa(0x151)][_0x3458aa(0x158)][_0x3458aa(0x136)];if(_0x28037a instanceof _0x2a22d5)return this[_0x3458aa(0x12f)][_0x3458aa(0x151)][_0x3458aa(0x158)][_0x3458aa(0x13f)](_0x28037a),void this[_0x3458aa(0x12f)][_0x3458aa(0x151)][_0x3458aa(0x1ce)](_0x3458aa(0x1af),{'id':_0x102e31['id'],'capabilities':{'isWebSearchEnabled':_0x28037a[_0x3458aa(0x11d)][_0x3458aa(0x16b)]||_0x1cca37[_0x3458aa(0x16b)],'isReasoningEnabled':_0x28037a[_0x3458aa(0x11d)][_0x3458aa(0x152)]||_0x1cca37[_0x3458aa(0x152)]}});this[_0x3458aa(0x12f)][_0x3458aa(0x151)][_0x3458aa(0x1ce)](_0x3458aa(0x1af),{'id':_0x102e31['id'],'capabilities':_0x1cca37});}async[_0x5b30e0(0x1ba)](_0x5f76ae,_0x78105c){const _0x8cfa3c=_0x5b30e0;let _0x3a6034;return await this[_0x8cfa3c(0x140)][_0x8cfa3c(0x188)](async()=>{const _0x281e45=_0x8cfa3c;_0x3a6034=this[_0x281e45(0x12f)][_0x281e45(0x151)][_0x281e45(0x1ce)](_0x281e45(0x15a),{'content':_0x5f76ae,'id':_0x78105c});}),_0x3a6034;}[_0x5b30e0(0x1a8)](_0x4f8f1a){const _0x3bc284=_0x5b30e0;this[_0x3bc284(0x12f)][_0x3bc284(0x151)][_0x3bc284(0x1ad)](_0x4f8f1a);}[_0x5b30e0(0x176)](_0x41b23c){const _0x257bd5=_0x5b30e0;return this[_0x257bd5(0x12f)][_0x257bd5(0x151)][_0x257bd5(0x146)](_0x41b23c);}[_0x5b30e0(0x138)](_0x458317){const _0x2799e2=_0x5b30e0,_0x22d187=this[_0x2799e2(0x12f)][_0x2799e2(0x151)][_0x2799e2(0x158)][_0x2799e2(0x196)](_0x471b1e=>_0x471b1e[_0x2799e2(0x16a)]['id']==_0x458317['id']&&_0x471b1e instanceof _0x2a22d5);_0x22d187&&_0x22d187[_0x2799e2(0x172)](_0x2799e2(0x1a6),_0x458317[_0x2799e2(0x1a6)]);}async[_0x5b30e0(0x16c)](_0x4290db){const _0x11c6a2=_0x5b30e0,_0x4b433b=_0x4290db[_0x11c6a2(0x191)]||this[_0x11c6a2(0x19a)];return this[_0x11c6a2(0x140)][_0x11c6a2(0x188)](async _0x4e7c3a=>{const _0x3a0348=_0x11c6a2;await this[_0x3a0348(0x12f)][_0x3a0348(0x151)][_0x3a0348(0x15b)]({..._0x4290db,'abortSignal':_0x4e7c3a,'renderingStrategy':_0x4b433b}),_0x4290db[_0x3a0348(0x1a4)]&&this[_0x3a0348(0x144)](_0x4290db['id']);});}[_0x5b30e0(0x13a)](_0xbf7792,_0x3070d5){const _0x22cdc4=_0x5b30e0;this[_0x22cdc4(0x12f)][_0x22cdc4(0x151)][_0x22cdc4(0x1a9)](_0xbf7792,_0x3070d5);}async[_0x5b30e0(0x141)](_0x3a2c95){const _0x1236df=_0x5b30e0,_0x26039b=_0x3a2c95[_0x1236df(0x191)]||this[_0x1236df(0x19a)];return this[_0x1236df(0x140)][_0x1236df(0x188)](async _0x45c77a=>{const _0x3a6c35=_0x1236df;await this[_0x3a6c35(0x12f)][_0x3a6c35(0x151)][_0x3a6c35(0x1a7)]({..._0x3a2c95,'abortSignal':_0x45c77a,'renderingStrategy':_0x26039b}),_0x3a2c95[_0x3a6c35(0x1a4)]&&this[_0x3a6c35(0x144)](_0x3a2c95['id']);});}[_0x5b30e0(0x1b2)](_0x4d390b){const _0x333323=_0x5b30e0;this[_0x333323(0x12f)][_0x333323(0x151)][_0x333323(0x1b3)](_0x4d390b);}[_0x5b30e0(0x1ab)](_0x425437){const _0x3e7537=_0x5b30e0;this[_0x3e7537(0x12f)][_0x3e7537(0x151)][_0x3e7537(0x18e)](_0x425437);}[_0x5b30e0(0x144)](_0x5f38cd){const _0x307feb=_0x5b30e0;this[_0x307feb(0x12f)][_0x307feb(0x151)][_0x307feb(0x130)](_0x5f38cd);}[_0x5b30e0(0x190)](_0x44cf46){const _0x492cf6=_0x5b30e0;this[_0x492cf6(0x12f)][_0x492cf6(0x151)][_0x492cf6(0x161)]()[_0x492cf6(0x1c4)](_0x251083=>_0x251083[_0x492cf6(0x150)](_0x44cf46))[_0x492cf6(0x155)](_0xb113a0=>this[_0x492cf6(0x12f)][_0x492cf6(0x151)][_0x492cf6(0x1ad)](_0xb113a0));}[_0x5b30e0(0x11c)](){const _0x22a2fc=_0x5b30e0,_0x51d44f=this[_0x22a2fc(0x1c5)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x1});this[_0x22a2fc(0x13d)](_0x51d44f),this[_0x22a2fc(0x12f)][_0x22a2fc(0x19f)][_0x22a2fc(0x18f)](!this[_0x22a2fc(0x159)][_0x22a2fc(0x17b)][_0x22a2fc(0x1cc)](_0x22a2fc(0x18b))),this[_0x22a2fc(0x1a2)]=!0x0,this[_0x22a2fc(0x12f)][_0x22a2fc(0x151)][_0x22a2fc(0x1c1)]();}[_0x5b30e0(0x125)](_0x430127){const _0x3d1f0d=_0x5b30e0;this[_0x3d1f0d(0x140)][_0x3d1f0d(0x15d)](),this[_0x3d1f0d(0x12f)][_0x3d1f0d(0x151)][_0x3d1f0d(0x161)]()[_0x3d1f0d(0x1c4)](_0x1cac3b=>_0x1cac3b[_0x3d1f0d(0x150)](_0x430127['id']))[_0x3d1f0d(0x155)](_0x5e0790=>this[_0x3d1f0d(0x144)](_0x5e0790)),this[_0x3d1f0d(0x1a2)]=!0x1,this[_0x3d1f0d(0x12f)][_0x3d1f0d(0x151)][_0x3d1f0d(0x1cf)]();}async[_0x5b30e0(0x12d)](){const _0x48bdd6=_0x5b30e0;return this[_0x48bdd6(0x140)][_0x48bdd6(0x126)][_0x48bdd6(0x169)](()=>{const _0x1eb5a7=_0x48bdd6;this[_0x1eb5a7(0x1a2)]=!0x1,this[_0x1eb5a7(0x12f)][_0x1eb5a7(0x151)][_0x1eb5a7(0x1cf)]();});}[_0x5b30e0(0x189)](_0x5e679a,_0x557493){const _0x33e6f3=_0x5b30e0;this[_0x33e6f3(0x12f)][_0x33e6f3(0x19f)][_0x33e6f3(0x189)](_0x5e679a,_0x557493);}[_0x5b30e0(0x148)](_0x55ef29){const _0x350dc7=_0x5b30e0;this[_0x350dc7(0x12f)][_0x350dc7(0x19f)][_0x350dc7(0x148)](_0x55ef29);}[_0x5b30e0(0x120)](_0x2f9557,_0x9da9a7){const _0x329dd5=_0x5b30e0;this[_0x329dd5(0x12f)][_0x329dd5(0x19f)][_0x329dd5(0x120)](_0x2f9557,_0x9da9a7);}[_0x5b30e0(0x15f)](_0x41d0aa){const _0x1036b9=_0x5b30e0;this[_0x1036b9(0x12f)][_0x1036b9(0x19f)][_0x1036b9(0x15f)](_0x41d0aa);}[_0x5b30e0(0x179)](_0x3e64a5){const _0x209f11=_0x5b30e0;this[_0x209f11(0x12f)][_0x209f11(0x19f)][_0x209f11(0x179)](_0x3e64a5);}[_0x5b30e0(0x137)](){const _0xff7998=_0x5b30e0;this[_0xff7998(0x12f)][_0xff7998(0x19f)][_0xff7998(0x137)]();}[_0x5b30e0(0x1a1)](){const _0x1d8454=_0x5b30e0;this[_0x1d8454(0x12f)][_0x1d8454(0x19f)][_0x1d8454(0x1a1)]();}[_0x5b30e0(0x1bd)](_0x1fd275,_0x3fea39,_0x4ca928){const _0x4247fd=_0x5b30e0;this[_0x4247fd(0x12f)][_0x4247fd(0x19f)][_0x4247fd(0x1bd)](_0x1fd275,_0x3fea39,_0x4ca928);}[_0x5b30e0(0x149)](){const _0x39831d=_0x5b30e0;this[_0x39831d(0x12f)][_0x39831d(0x19f)][_0x39831d(0x149)](),this[_0x39831d(0x12f)][_0x39831d(0x19f)][_0x39831d(0x1b9)](this[_0x39831d(0x195)]());}[_0x5b30e0(0x184)](_0x3e5525){const _0x18bc23=_0x5b30e0;this[_0x18bc23(0x12f)][_0x18bc23(0x19f)][_0x18bc23(0x184)](_0x3e5525);}[_0x5b30e0(0x18a)](_0x2c6df3){const _0x153e19=_0x5b30e0;this[_0x153e19(0x12f)][_0x153e19(0x19f)][_0x153e19(0x13e)](_0x2c6df3[_0x153e19(0x16b)]),this[_0x153e19(0x12f)][_0x153e19(0x19f)][_0x153e19(0x11f)](_0x2c6df3[_0x153e19(0x152)]),this[_0x153e19(0x12f)][_0x153e19(0x19f)][_0x153e19(0x1b9)](this[_0x153e19(0x195)](_0x2c6df3));}[_0x5b30e0(0x186)](_0x28c88a,_0x1bb7d0){const _0x57fd29=_0x5b30e0;this[_0x57fd29(0x12f)][_0x57fd29(0x19f)][_0x57fd29(0x143)](_0x28c88a),_0x1bb7d0&&this[_0x57fd29(0x12f)][_0x57fd29(0x19f)][_0x57fd29(0x18f)](!0x1);}[_0x5b30e0(0x1bb)](_0x49810e){const _0x20ddec=_0x5b30e0;this[_0x20ddec(0x19a)]=_0x49810e;}[_0x5b30e0(0x131)](_0x48ed37){const _0x5d36c6=_0x5b30e0;this[_0x5d36c6(0x12f)][_0x5d36c6(0x151)][_0x5d36c6(0x131)](_0x48ed37);}[_0x5b30e0(0x133)](){const _0x1fa503=_0x5b30e0;this[_0x1fa503(0x171)](_0x2b4b9a(this[_0x1fa503(0x159)][_0x1fa503(0x12b)],_0x1fa503(0x17f)));}[_0x5b30e0(0x171)](_0x28f682,_0x77ccac=!0x1){const _0x27a691=_0x5b30e0;if(_0x77ccac&&!_0x482524()&&_0x28f682[_0x27a691(0x123)])return this[_0x27a691(0x12f)][_0x27a691(0x1c2)][_0x27a691(0x17d)]='',void this[_0x27a691(0x135)](_0x28f682);this[_0x27a691(0x12f)][_0x27a691(0x1c2)][_0x27a691(0x17d)]=_0x28f682;}[_0x5b30e0(0x13d)](_0x54e7a1){const _0x280158=_0x5b30e0;this[_0x280158(0x12f)][_0x280158(0x151)][_0x280158(0x13d)](_0x54e7a1);}[_0x5b30e0(0x1a3)](){const _0x439e07=_0x5b30e0;this[_0x439e07(0x12f)][_0x439e07(0x151)][_0x439e07(0x13d)]('');}[_0x5b30e0(0x135)](_0x2b273f){const _0x4e730f=_0x5b30e0;let _0x346267=0x0;clearInterval(this[_0x4e730f(0x15c)]),this[_0x4e730f(0x15c)]=setInterval(()=>{const _0x5af928=_0x4e730f;this[_0x5af928(0x12f)][_0x5af928(0x1c2)][_0x5af928(0x17d)]=this[_0x5af928(0x12f)][_0x5af928(0x1c2)][_0x5af928(0x17d)]+_0x2b273f[_0x346267],_0x346267++,_0x346267===_0x2b273f[_0x5af928(0x123)]&&clearInterval(this[_0x5af928(0x15c)]);},0x1e);}[_0x5b30e0(0x19e)](_0x1d290c){const _0x3495fa=_0x5b30e0;this[_0x3495fa(0x12f)][_0x3495fa(0x1c2)][_0x3495fa(0x1c8)]=_0x1d290c;}[_0x5b30e0(0x1c5)](_0x3736cd){const _0x4c334f=_0x5b30e0;return _0x3736cd[_0x4c334f(0x16b)]&&_0x3736cd[_0x4c334f(0x152)]?_0x2b4b9a(this[_0x4c334f(0x159)][_0x4c334f(0x12b)],_0x4c334f(0x18d)):_0x3736cd[_0x4c334f(0x16b)]?_0x2b4b9a(this[_0x4c334f(0x159)][_0x4c334f(0x12b)],_0x4c334f(0x193)):_0x3736cd[_0x4c334f(0x152)]?_0x2b4b9a(this[_0x4c334f(0x159)][_0x4c334f(0x12b)],_0x4c334f(0x1b0)):_0x2b4b9a(this[_0x4c334f(0x159)][_0x4c334f(0x12b)],_0x4c334f(0x147));}[_0x5b30e0(0x195)](_0x300035){const _0x4afb78=_0x5b30e0;return _0x300035?_0x300035[_0x4afb78(0x16b)]&&_0x300035[_0x4afb78(0x152)]?_0x2b4b9a(this[_0x4afb78(0x159)][_0x4afb78(0x12b)],_0x4afb78(0x18c)):_0x300035[_0x4afb78(0x16b)]?_0x2b4b9a(this[_0x4afb78(0x159)][_0x4afb78(0x12b)],_0x4afb78(0x1a5)):_0x300035[_0x4afb78(0x152)]?_0x2b4b9a(this[_0x4afb78(0x159)][_0x4afb78(0x12b)],_0x4afb78(0x173)):_0x2b4b9a(this[_0x4afb78(0x159)][_0x4afb78(0x12b)],_0x4afb78(0x12e)):_0x2b4b9a(this[_0x4afb78(0x159)][_0x4afb78(0x12b)],_0x4afb78(0x12e));}[_0x5b30e0(0x167)](_0x2ae011,_0x5ef07b,_0x2ffda9,_0x1993ae){const _0x18eb84=_0x5b30e0;this[_0x18eb84(0x12f)][_0x18eb84(0x167)](_0x2ae011,_0x5ef07b,_0x2ffda9,_0x1993ae);}[_0x5b30e0(0x16f)](_0x214f76){const _0x2224a7=_0x5b30e0;this[_0x2224a7(0x12f)][_0x2224a7(0x16f)](_0x214f76);}[_0x5b30e0(0x177)](_0x4b626b){const _0x1c9468=_0x5b30e0;this[_0x1c9468(0x12f)][_0x1c9468(0x19f)][_0x1c9468(0x177)](_0x4b626b);}[_0x5b30e0(0x14f)](_0x414a9f=!0x1){const _0x2ba998=_0x5b30e0;this[_0x2ba998(0x12f)][_0x2ba998(0x19f)][_0x2ba998(0x14f)](_0x414a9f);}[_0x5b30e0(0x180)](_0x43cb43,_0x3ce7d5){const _0x8a74a8=_0x5b30e0;this[_0x8a74a8(0x12f)][_0x8a74a8(0x151)][_0x8a74a8(0x1cb)](_0x43cb43,_0x3ce7d5);}[_0x5b30e0(0x1c1)](){const _0x157f0a=_0x5b30e0;this[_0x157f0a(0x12f)][_0x157f0a(0x151)][_0x157f0a(0x1c1)]();}[_0x5b30e0(0x154)](){const _0x3e6d52=_0x5b30e0;this[_0x3e6d52(0x12f)][_0x3e6d52(0x19f)][_0x3e6d52(0x11e)]=!0x0;}[_0x5b30e0(0x1be)](){const _0x4f91ad=_0x5b30e0;this[_0x4f91ad(0x12f)][_0x4f91ad(0x19f)][_0x4f91ad(0x11e)]=!0x1;}}
23
+ const _0x2a0ffa=_0x28db;(function(_0x128897,_0x6af7d8){const _0x2caa68=_0x28db,_0x151681=_0x128897();while(!![]){try{const _0x2620b7=parseInt(_0x2caa68(0x24a))/0x1+parseInt(_0x2caa68(0x1fd))/0x2*(-parseInt(_0x2caa68(0x24c))/0x3)+-parseInt(_0x2caa68(0x278))/0x4*(parseInt(_0x2caa68(0x1e4))/0x5)+-parseInt(_0x2caa68(0x1e3))/0x6*(-parseInt(_0x2caa68(0x231))/0x7)+-parseInt(_0x2caa68(0x1da))/0x8+-parseInt(_0x2caa68(0x20b))/0x9*(parseInt(_0x2caa68(0x25f))/0xa)+parseInt(_0x2caa68(0x269))/0xb;if(_0x2620b7===_0x6af7d8)break;else _0x151681['push'](_0x151681['shift']());}catch(_0xba2268){_0x151681['push'](_0x151681['shift']());}}}(_0xe7ea,0x1c2c2));import{ContextPlugin as _0x4f2910}from'ckeditor5/src/core.js';import{_isMotionReduced as _0x36b33c}from'ckeditor5/src/utils.js';import{AIChatView as _0x5a7760}from'./ui/aichatview.js';import{AITabs as _0x2c7996}from'../aitabs/aitabs.js';import{getTranslation as _0x5ea92d}from'../aicore/utils/common-translations.js';import{IconAIChat as _0x3a8131}from'ckeditor5/src/icons.js';import{AIChatFeedInteractionHeaderView as _0x2a3413}from'./ui/feed/aichatfeedinteractionheaderview.js';import{PromiseQueue as _0x3c63f6}from'./utils/promisequeue.js';import{AI_CHAT_UI_EVENT_NAMES as _0x59a95e}from'./utils/eventnames.js';import'../../theme/aichat/aichat.css';function _0x28db(_0x4d5f3c,_0x18bbfc){const _0xe7eada=_0xe7ea();return _0x28db=function(_0x28db79,_0x206209){_0x28db79=_0x28db79-0x1ca;let _0x21f91d=_0xe7eada[_0x28db79];return _0x21f91d;},_0x28db(_0x4d5f3c,_0x18bbfc);}import{getEditorFromContext as _0x7083ab}from'../aicore/utils/geteditorfromcontext.js';import{AI_REPLY_ACTIONS as _0x505374}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';export class AIChatUI extends _0x4f2910{static get[_0x2a0ffa(0x1d7)](){return[_0x2c7996];}[_0x2a0ffa(0x26e)];static get[_0x2a0ffa(0x23e)](){const _0x6d6165=_0x2a0ffa;return _0x6d6165(0x279);}static get[_0x2a0ffa(0x24d)](){return!0x0;}static get[_0x2a0ffa(0x218)](){return!0x0;}[_0x2a0ffa(0x1df)]=_0x2a0ffa(0x271);[_0x2a0ffa(0x242)]=!0x0;[_0x2a0ffa(0x275)];[_0x2a0ffa(0x214)];[_0x2a0ffa(0x211)]=void 0x0;[_0x2a0ffa(0x230)]=!0x1;constructor(_0x356d7e){const _0x4e593f=_0x2a0ffa;super(_0x356d7e);const _0x1d917a=this[_0x4e593f(0x1f9)][_0x4e593f(0x216)][_0x4e593f(0x1dc)](_0x4e593f(0x1e7));this[_0x4e593f(0x222)](_0x4e593f(0x1fc),!0x1),this[_0x4e593f(0x275)]=new _0x3c63f6(),this[_0x4e593f(0x26e)]=new _0x5a7760(this[_0x4e593f(0x1f9)][_0x4e593f(0x1dd)],{'showResizeButton':_0x1d917a[_0x4e593f(0x20e)],'contextResourcesSearchInputVisibleFrom':this[_0x4e593f(0x1f9)][_0x4e593f(0x207)][_0x4e593f(0x1dc)](_0x4e593f(0x266))}),this[_0x4e593f(0x26e)][_0x4e593f(0x27d)](..._0x59a95e)['to'](this),this[_0x4e593f(0x26e)]['on'](_0x4e593f(0x272),(_0x546b50,{showDiff:_0x263085})=>{const _0x276789=_0x4e593f;this[_0x276789(0x242)]=_0x263085;}),_0x1d917a[_0x4e593f(0x25e)][_0x4e593f(0x22f)]({'id':_0x4e593f(0x243),'buttonLabel':_0x5ea92d(this[_0x4e593f(0x1f9)][_0x4e593f(0x1dd)],_0x4e593f(0x1d5)),'buttonIcon':_0x3a8131,'order':0x0,'content':this[_0x4e593f(0x26e)]}),this[_0x4e593f(0x26e)][_0x4e593f(0x209)][_0x4e593f(0x25a)](_0x4e593f(0x22a))['to'](this,_0x4e593f(0x1fc),_0x4e19a9=>_0x4e19a9),this[_0x4e593f(0x26e)][_0x4e593f(0x265)][_0x4e593f(0x25a)](_0x4e593f(0x1e9))['to'](this,_0x4e593f(0x1fc),_0xa2c83b=>_0xa2c83b),this[_0x4e593f(0x26e)][_0x4e593f(0x209)][_0x4e593f(0x26a)](this[_0x4e593f(0x233)]()),this[_0x4e593f(0x25a)](_0x4e593f(0x1cd))['to'](this[_0x4e593f(0x26e)][_0x4e593f(0x209)],_0x4e593f(0x1cd));}[_0x2a0ffa(0x25d)](){const _0x30f88d=_0x2a0ffa;super[_0x30f88d(0x25d)](),this[_0x30f88d(0x211)]&&clearInterval(this[_0x30f88d(0x211)]);}[_0x2a0ffa(0x1f0)](_0x14bb64){const _0x21b3a6=_0x2a0ffa,_0x30e35e=this[_0x21b3a6(0x1f9)][_0x21b3a6(0x207)][_0x21b3a6(0x1dc)](_0x21b3a6(0x1e5))??_0x5ea92d(this[_0x21b3a6(0x1f9)][_0x21b3a6(0x1dd)],_0x21b3a6(0x229));this[_0x21b3a6(0x26e)][_0x21b3a6(0x265)][_0x21b3a6(0x256)](),this[_0x21b3a6(0x26e)][_0x21b3a6(0x209)][_0x21b3a6(0x27a)](),this[_0x21b3a6(0x26e)][_0x21b3a6(0x209)][_0x21b3a6(0x1de)](_0x14bb64[_0x21b3a6(0x217)],!this[_0x21b3a6(0x1f9)][_0x21b3a6(0x207)][_0x21b3a6(0x1dc)](_0x21b3a6(0x1d4))),this[_0x21b3a6(0x234)]({'id':_0x21b3a6(0x22c),'staticMessage':_0x30e35e}),this[_0x21b3a6(0x220)](_0x21b3a6(0x1ea));}[_0x2a0ffa(0x234)]({id:_0x42e96d,staticMessage:_0x2b83e4}){const _0x24cab0=_0x2a0ffa;this[_0x24cab0(0x26e)][_0x24cab0(0x265)][_0x24cab0(0x276)](_0x24cab0(0x215),{'id':_0x42e96d,'initialContent':_0x24cab0(0x232)+_0x2b83e4+_0x24cab0(0x260)});}[_0x2a0ffa(0x1fe)](_0xefb567){const _0x2184c4=_0x2a0ffa,_0x203ba4=_0xefb567[_0x2184c4(0x20f)]?.[_0x2184c4(0x1f1)]||_0xefb567[_0x2184c4(0x21c)];this[_0x2184c4(0x26e)][_0x2184c4(0x265)][_0x2184c4(0x276)](_0x2184c4(0x1f4),{'contextItems':Array[_0x2184c4(0x258)](_0xefb567[_0x2184c4(0x25c)][_0x2184c4(0x246)]()),'initialContent':_0x2184c4(0x232)+_0x203ba4+_0x2184c4(0x260),'id':_0xefb567['id']});}[_0x2a0ffa(0x206)]({errorMessage:_0x4da9c5,id:_0x1a878b}){const _0xeca186=_0x2a0ffa;this[_0xeca186(0x26e)][_0xeca186(0x265)][_0xeca186(0x276)](_0xeca186(0x235),{'initialContent':_0xeca186(0x232)+_0x4da9c5+_0xeca186(0x260),'id':_0x1a878b});}[_0x2a0ffa(0x21b)](_0x2767e5){const _0x44817f=_0x2a0ffa;return this[_0x44817f(0x275)][_0x44817f(0x237)](async()=>{const _0xe2eb75=_0x44817f;this[_0xe2eb75(0x26e)][_0xe2eb75(0x265)][_0xe2eb75(0x276)](_0xe2eb75(0x215),{'id':_0x2767e5[_0xe2eb75(0x1fb)]+':'+_0x2767e5['id']}),this[_0xe2eb75(0x245)]();});}async[_0x2a0ffa(0x1d8)](_0x5d9bc0){const _0x959fdd=_0x2a0ffa,_0x3fea96=_0x7083ab(this[_0x959fdd(0x1f9)]);let _0x41d0b4=_0x3fea96[_0x959fdd(0x207)][_0x959fdd(0x1dc)](_0x959fdd(0x262))||[..._0x505374];if(_0x3fea96[_0x959fdd(0x216)][_0x959fdd(0x203)](_0x959fdd(0x22d))){if(!this[_0x959fdd(0x230)]){this[_0x959fdd(0x230)]=!0x0;const _0x376458=_0x3fea96[_0x959fdd(0x255)][_0x959fdd(0x1dc)](_0x959fdd(0x1cf));this[_0x959fdd(0x26e)][_0x959fdd(0x265)][_0x959fdd(0x25a)](_0x959fdd(0x267))['to'](_0x376458,_0x959fdd(0x1f8));}}else _0x41d0b4=_0x41d0b4[_0x959fdd(0x273)](_0x29aa6a=>_0x959fdd(0x24f)!=_0x29aa6a);return this[_0x959fdd(0x275)][_0x959fdd(0x237)](async()=>{const _0x4f4e41=_0x959fdd;this[_0x4f4e41(0x26e)][_0x4f4e41(0x265)][_0x4f4e41(0x276)](_0x4f4e41(0x23c),{'id':_0x5d9bc0[_0x4f4e41(0x1fb)]+':'+_0x5d9bc0['id'],'areActionsDisabled':_0x5d9bc0[_0x4f4e41(0x213)],'showDiff':this[_0x4f4e41(0x242)],'availableActions':_0x41d0b4}),this[_0x4f4e41(0x245)]();});}[_0x2a0ffa(0x210)](_0x3b2961,_0x5057e6){const _0xe34e71=_0x2a0ffa,_0x7cb3fd=this[_0xe34e71(0x26e)][_0xe34e71(0x265)][_0xe34e71(0x1f2)][_0xe34e71(0x21f)];if(_0x7cb3fd instanceof _0x2a3413)return this[_0xe34e71(0x26e)][_0xe34e71(0x265)][_0xe34e71(0x1f2)][_0xe34e71(0x1d9)](_0x7cb3fd),void this[_0xe34e71(0x26e)][_0xe34e71(0x265)][_0xe34e71(0x276)](_0xe34e71(0x240),{'id':_0x3b2961['id'],'capabilities':{'isWebSearchEnabled':_0x7cb3fd[_0xe34e71(0x239)][_0xe34e71(0x1ce)]||_0x5057e6[_0xe34e71(0x1ce)],'isReasoningEnabled':_0x7cb3fd[_0xe34e71(0x239)][_0xe34e71(0x223)]||_0x5057e6[_0xe34e71(0x223)]}});this[_0xe34e71(0x26e)][_0xe34e71(0x265)][_0xe34e71(0x276)](_0xe34e71(0x240),{'id':_0x3b2961['id'],'capabilities':_0x5057e6});}async[_0x2a0ffa(0x23b)](_0x41bea7,_0xdf571d){const _0x10baba=_0x2a0ffa;let _0x32ed62;return await this[_0x10baba(0x275)][_0x10baba(0x237)](async()=>{const _0x370822=_0x10baba;_0x32ed62=this[_0x370822(0x26e)][_0x370822(0x265)][_0x370822(0x276)](_0x370822(0x221),{'content':_0x41bea7,'id':_0xdf571d});}),_0x32ed62;}[_0x2a0ffa(0x224)](_0x43325e){const _0xa74f16=_0x2a0ffa;this[_0xa74f16(0x26e)][_0xa74f16(0x265)][_0xa74f16(0x263)](_0x43325e);}[_0x2a0ffa(0x21e)](_0x3c9dce){const _0x22e561=_0x2a0ffa;return this[_0x22e561(0x26e)][_0x22e561(0x265)][_0x22e561(0x1fa)](_0x3c9dce);}[_0x2a0ffa(0x1f5)](_0x3eaf41){const _0x53b9ec=_0x2a0ffa,_0x1b48f2=this[_0x53b9ec(0x26e)][_0x53b9ec(0x265)][_0x53b9ec(0x1f2)][_0x53b9ec(0x1e0)](_0x4ec0ae=>_0x4ec0ae[_0x53b9ec(0x219)]['id']==_0x3eaf41['id']&&_0x4ec0ae instanceof _0x2a3413);_0x1b48f2&&_0x1b48f2[_0x53b9ec(0x222)](_0x53b9ec(0x241),_0x3eaf41[_0x53b9ec(0x241)]);}async[_0x2a0ffa(0x264)](_0x5f4c60){const _0x53cc6e=_0x2a0ffa,_0x3559e2=_0x5f4c60[_0x53cc6e(0x1ec)]||this[_0x53cc6e(0x1df)];return this[_0x53cc6e(0x275)][_0x53cc6e(0x237)](async _0x39b7db=>{const _0x288fdb=_0x53cc6e;await this[_0x288fdb(0x26e)][_0x288fdb(0x265)][_0x288fdb(0x227)]({..._0x5f4c60,'abortSignal':_0x39b7db,'renderingStrategy':_0x3559e2}),_0x5f4c60[_0x288fdb(0x201)]&&this[_0x288fdb(0x22e)](_0x5f4c60['id']);});}[_0x2a0ffa(0x208)](_0x361abe,_0x1902b7){const _0x427518=_0x2a0ffa;this[_0x427518(0x26e)][_0x427518(0x265)][_0x427518(0x257)](_0x361abe,_0x1902b7);}async[_0x2a0ffa(0x1d0)](_0x1e285c){const _0x5b7970=_0x2a0ffa,_0xd91e5e=_0x1e285c[_0x5b7970(0x1ec)]||this[_0x5b7970(0x1df)];return this[_0x5b7970(0x275)][_0x5b7970(0x237)](async _0x308528=>{const _0x1567ec=_0x5b7970;await this[_0x1567ec(0x26e)][_0x1567ec(0x265)][_0x1567ec(0x21d)]({..._0x1e285c,'abortSignal':_0x308528,'renderingStrategy':_0xd91e5e}),_0x1e285c[_0x1567ec(0x201)]&&this[_0x1567ec(0x22e)](_0x1e285c['id']);});}[_0x2a0ffa(0x1d1)](_0x3ea17b){const _0x544720=_0x2a0ffa;this[_0x544720(0x26e)][_0x544720(0x265)][_0x544720(0x27c)](_0x3ea17b);}[_0x2a0ffa(0x226)](_0xefa298){const _0x118067=_0x2a0ffa;this[_0x118067(0x26e)][_0x118067(0x265)][_0x118067(0x1d6)](_0xefa298);}[_0x2a0ffa(0x22e)](_0x475a48){const _0x206b52=_0x2a0ffa;this[_0x206b52(0x26e)][_0x206b52(0x265)][_0x206b52(0x24b)](_0x475a48);}[_0x2a0ffa(0x238)](_0x2bfa87){const _0x5e7ff2=_0x2a0ffa;this[_0x5e7ff2(0x26e)][_0x5e7ff2(0x265)][_0x5e7ff2(0x277)]()[_0x5e7ff2(0x273)](_0x53c054=>_0x53c054[_0x5e7ff2(0x23f)](_0x2bfa87))[_0x5e7ff2(0x248)](_0x3a4cf7=>this[_0x5e7ff2(0x26e)][_0x5e7ff2(0x265)][_0x5e7ff2(0x263)](_0x3a4cf7));}[_0x2a0ffa(0x270)](){const _0x315778=_0x2a0ffa,_0x3dfe7a=this[_0x315778(0x1e2)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x1});this[_0x315778(0x1cc)](_0x3dfe7a),this[_0x315778(0x26e)][_0x315778(0x209)][_0x315778(0x202)](!this[_0x315778(0x1f9)][_0x315778(0x207)][_0x315778(0x1dc)](_0x315778(0x1d4))),this[_0x315778(0x1fc)]=!0x0,this[_0x315778(0x26e)][_0x315778(0x265)][_0x315778(0x200)]();}[_0x2a0ffa(0x228)](_0x1331aa){const _0x3c1b0b=_0x2a0ffa;this[_0x3c1b0b(0x275)][_0x3c1b0b(0x254)](),this[_0x3c1b0b(0x26e)][_0x3c1b0b(0x265)][_0x3c1b0b(0x277)]()[_0x3c1b0b(0x273)](_0x1c05bd=>_0x1c05bd[_0x3c1b0b(0x23f)](_0x1331aa['id']))[_0x3c1b0b(0x248)](_0x3e56d9=>this[_0x3c1b0b(0x22e)](_0x3e56d9)),this[_0x3c1b0b(0x1fc)]=!0x1,this[_0x3c1b0b(0x26e)][_0x3c1b0b(0x265)][_0x3c1b0b(0x20a)]();}async[_0x2a0ffa(0x253)](){const _0x555ba6=_0x2a0ffa;return this[_0x555ba6(0x275)][_0x555ba6(0x1e8)][_0x555ba6(0x1f7)](()=>{const _0x5a1218=_0x555ba6;this[_0x5a1218(0x1fc)]=!0x1,this[_0x5a1218(0x26e)][_0x5a1218(0x265)][_0x5a1218(0x20a)]();});}[_0x2a0ffa(0x1ee)](_0xcb5ee1,_0x4dd5f6){const _0x1937b7=_0x2a0ffa;this[_0x1937b7(0x26e)][_0x1937b7(0x209)][_0x1937b7(0x1ee)](_0xcb5ee1,_0x4dd5f6);}[_0x2a0ffa(0x212)](_0x124caf){const _0x4f372f=_0x2a0ffa;this[_0x4f372f(0x26e)][_0x4f372f(0x209)][_0x4f372f(0x212)](_0x124caf);}[_0x2a0ffa(0x1ed)](_0x148b5f,_0xc70085){const _0x5d3819=_0x2a0ffa;this[_0x5d3819(0x26e)][_0x5d3819(0x209)][_0x5d3819(0x1ed)](_0x148b5f,_0xc70085);}[_0x2a0ffa(0x22b)](_0x430b45){const _0x1d8954=_0x2a0ffa;this[_0x1d8954(0x26e)][_0x1d8954(0x209)][_0x1d8954(0x22b)](_0x430b45);}[_0x2a0ffa(0x20d)](_0x33121c){const _0x3d3f4d=_0x2a0ffa;this[_0x3d3f4d(0x26e)][_0x3d3f4d(0x209)][_0x3d3f4d(0x20d)](_0x33121c);}[_0x2a0ffa(0x251)](){const _0x55ae5d=_0x2a0ffa;this[_0x55ae5d(0x26e)][_0x55ae5d(0x209)][_0x55ae5d(0x251)]();}[_0x2a0ffa(0x26f)](){const _0x840909=_0x2a0ffa;this[_0x840909(0x26e)][_0x840909(0x209)][_0x840909(0x26f)]();}[_0x2a0ffa(0x1db)](_0x466de2,_0x5a33cb,_0x3ec379){const _0x310f9b=_0x2a0ffa;this[_0x310f9b(0x26e)][_0x310f9b(0x209)][_0x310f9b(0x1db)](_0x466de2,_0x5a33cb,_0x3ec379);}[_0x2a0ffa(0x1ff)](){const _0x481de3=_0x2a0ffa;this[_0x481de3(0x26e)][_0x481de3(0x209)][_0x481de3(0x1ff)](),this[_0x481de3(0x26e)][_0x481de3(0x209)][_0x481de3(0x26a)](this[_0x481de3(0x233)]());}[_0x2a0ffa(0x261)](_0x114e29){const _0x5afda9=_0x2a0ffa;this[_0x5afda9(0x26e)][_0x5afda9(0x209)][_0x5afda9(0x261)](_0x114e29);}[_0x2a0ffa(0x26b)](_0x2e5144){const _0x485de=_0x2a0ffa;this[_0x485de(0x26e)][_0x485de(0x209)][_0x485de(0x21a)](_0x2e5144[_0x485de(0x1ce)]),this[_0x485de(0x26e)][_0x485de(0x209)][_0x485de(0x252)](_0x2e5144[_0x485de(0x223)]),this[_0x485de(0x26e)][_0x485de(0x209)][_0x485de(0x26a)](this[_0x485de(0x233)](_0x2e5144));}[_0x2a0ffa(0x23d)](_0xb46e2f,_0x60e86e){const _0x843d44=_0x2a0ffa;this[_0x843d44(0x26e)][_0x843d44(0x209)][_0x843d44(0x20c)](_0xb46e2f),_0x60e86e&&this[_0x843d44(0x26e)][_0x843d44(0x209)][_0x843d44(0x202)](!0x1);}[_0x2a0ffa(0x1e1)](_0x396cd0){const _0x3d1229=_0x2a0ffa;this[_0x3d1229(0x1df)]=_0x396cd0;}[_0x2a0ffa(0x259)](_0x3fb747){const _0x4297f2=_0x2a0ffa;this[_0x4297f2(0x26e)][_0x4297f2(0x265)][_0x4297f2(0x259)](_0x3fb747);}[_0x2a0ffa(0x1d2)](){const _0x43960b=_0x2a0ffa;this[_0x43960b(0x205)](_0x5ea92d(this[_0x43960b(0x1f9)][_0x43960b(0x1dd)],_0x43960b(0x1d5)));}[_0x2a0ffa(0x205)](_0x1c5cc9,_0x17bd89=!0x1){const _0x493d0f=_0x2a0ffa;if(_0x17bd89&&!_0x36b33c()&&_0x1c5cc9[_0x493d0f(0x225)])return this[_0x493d0f(0x26e)][_0x493d0f(0x25b)][_0x493d0f(0x236)]='',void this[_0x493d0f(0x1eb)](_0x1c5cc9);this[_0x493d0f(0x26e)][_0x493d0f(0x25b)][_0x493d0f(0x236)]=_0x1c5cc9;}[_0x2a0ffa(0x1cc)](_0x6ee84b){const _0x451f79=_0x2a0ffa;this[_0x451f79(0x26e)][_0x451f79(0x265)][_0x451f79(0x1cc)](_0x6ee84b);}[_0x2a0ffa(0x245)](){const _0x3ae2e4=_0x2a0ffa;this[_0x3ae2e4(0x26e)][_0x3ae2e4(0x265)][_0x3ae2e4(0x1cc)]('');}[_0x2a0ffa(0x1eb)](_0x550218){const _0x3fa02b=_0x2a0ffa;let _0x325dba=0x0;clearInterval(this[_0x3fa02b(0x211)]),this[_0x3fa02b(0x211)]=setInterval(()=>{const _0xcd1501=_0x3fa02b;this[_0xcd1501(0x26e)][_0xcd1501(0x25b)][_0xcd1501(0x236)]=this[_0xcd1501(0x26e)][_0xcd1501(0x25b)][_0xcd1501(0x236)]+_0x550218[_0x325dba],_0x325dba++,_0x325dba===_0x550218[_0xcd1501(0x225)]&&clearInterval(this[_0xcd1501(0x211)]);},0x1e);}[_0x2a0ffa(0x1f3)](_0x9923f6){const _0x2ae4bd=_0x2a0ffa;this[_0x2ae4bd(0x26e)][_0x2ae4bd(0x25b)][_0x2ae4bd(0x1cb)]=_0x9923f6;}[_0x2a0ffa(0x1e2)](_0x32e1c9){const _0x31d36d=_0x2a0ffa;return _0x32e1c9[_0x31d36d(0x1ce)]&&_0x32e1c9[_0x31d36d(0x223)]?_0x5ea92d(this[_0x31d36d(0x1f9)][_0x31d36d(0x1dd)],_0x31d36d(0x26c)):_0x32e1c9[_0x31d36d(0x1ce)]?_0x5ea92d(this[_0x31d36d(0x1f9)][_0x31d36d(0x1dd)],_0x31d36d(0x268)):_0x32e1c9[_0x31d36d(0x223)]?_0x5ea92d(this[_0x31d36d(0x1f9)][_0x31d36d(0x1dd)],_0x31d36d(0x1e6)):_0x5ea92d(this[_0x31d36d(0x1f9)][_0x31d36d(0x1dd)],_0x31d36d(0x1f6));}[_0x2a0ffa(0x233)](_0x3ec333){const _0x44e892=_0x2a0ffa;return _0x3ec333?_0x3ec333[_0x44e892(0x1ce)]&&_0x3ec333[_0x44e892(0x223)]?_0x5ea92d(this[_0x44e892(0x1f9)][_0x44e892(0x1dd)],_0x44e892(0x249)):_0x3ec333[_0x44e892(0x1ce)]?_0x5ea92d(this[_0x44e892(0x1f9)][_0x44e892(0x1dd)],_0x44e892(0x27b)):_0x3ec333[_0x44e892(0x223)]?_0x5ea92d(this[_0x44e892(0x1f9)][_0x44e892(0x1dd)],_0x44e892(0x204)):_0x5ea92d(this[_0x44e892(0x1f9)][_0x44e892(0x1dd)],_0x44e892(0x1ca)):_0x5ea92d(this[_0x44e892(0x1f9)][_0x44e892(0x1dd)],_0x44e892(0x1ca));}[_0x2a0ffa(0x26d)](_0x253c6b,_0x2dd29c,_0x356b30,_0x1b32ca){const _0x300b67=_0x2a0ffa;this[_0x300b67(0x26e)][_0x300b67(0x26d)](_0x253c6b,_0x2dd29c,_0x356b30,_0x1b32ca);}[_0x2a0ffa(0x23a)](_0x24db8b){const _0x4f85ec=_0x2a0ffa;this[_0x4f85ec(0x26e)][_0x4f85ec(0x23a)](_0x24db8b);}[_0x2a0ffa(0x247)](_0x5a0d99){const _0xa732=_0x2a0ffa;this[_0xa732(0x26e)][_0xa732(0x209)][_0xa732(0x247)](_0x5a0d99);}[_0x2a0ffa(0x274)](_0xdb3dae=!0x1){const _0x33f8d3=_0x2a0ffa;this[_0x33f8d3(0x26e)][_0x33f8d3(0x209)][_0x33f8d3(0x274)](_0xdb3dae);}[_0x2a0ffa(0x1ef)](_0x1606c9,_0x178f9a){const _0x446afc=_0x2a0ffa;this[_0x446afc(0x26e)][_0x446afc(0x265)][_0x446afc(0x250)](_0x1606c9,_0x178f9a);}[_0x2a0ffa(0x200)](){const _0x21964e=_0x2a0ffa;this[_0x21964e(0x26e)][_0x21964e(0x265)][_0x21964e(0x200)]();}[_0x2a0ffa(0x244)](){const _0x1eff6e=_0x2a0ffa;this[_0x1eff6e(0x26e)][_0x1eff6e(0x209)][_0x1eff6e(0x24e)]=!0x0;}[_0x2a0ffa(0x1d3)](){const _0x30aa4f=_0x2a0ffa;this[_0x30aa4f(0x26e)][_0x30aa4f(0x209)][_0x30aa4f(0x24e)]=!0x1;}}function _0xe7ea(){const _0x5e707f=['children','setIsMaximized','user-message','updateFeedInteractionHeader','AI_CHAT_FEED_LOADING_MESSAGE_REGULAR','then','value','context','hasItem','interactionId','isBusy','22alnarw','addFeedItemUserMessage','resetMessageInput','startAutoScroll','isDone','disableModelSelector','has','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REASONING','setConversationTitle','addFeedItemError','config','updateFeedItemAIReplySources','chatControls','stopAutoScroll','667593zrFnbB','setModel','setConversationContext','showResizeButton','attributes','addFeedInteractionHeader','_titleAnimationInterval','removeContextItem','areActionsDisabled','_interactionPromiseResolver','ai-reply','plugins','availableModels','isPremiumPlugin','options','setWebSearch','addFeedItemAIReply','userMessage','updateSuggestionItem','hasFeedItem','last','fire','custom-element','set','isReasoningEnabled','removeFeedItem','length','setFeedItemAIReplySuggestionPartActive','updateReplyItem','stopInteraction','AI_CHAT_WELCOME_MESSAGE','isLoading','setIsUploadInProgress','conversation-start','TrackChanges','markFeedItemAsDone','addTab','_isTrackChangesCommandValueBound','7AzFOdl','<p>','_getInputPlaceholder','addFeedItemStaticMessage','error-message','label','enqueue','removeFeedInteraction','capabilities','closeSourceResourceBalloon','addFeedItemCustomElement','ai-suggestion-reply','setSelectedModel','pluginName','startsWith','interaction-header','isVisible','showDiff','chat','disableControls','clearLoadingMessage','values','setPromptInputValue','forEach','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH_REASONING','178389QLgDTX','markItemAsDone','42243Dceujd','isOfficialPlugin','isDisabled','insertSuggestion','scrollToSuggestion','clearPendingContextUI','setReasoning','finishInteraction','abort','commands','clear','updateWebSources','from','toggleLoadingSkeleton','bind','chatHeader','contextItems','destroy','view','30EpReBe','</p>','setAddContextOptions','ai.availableReplyActions','removeItem','updateFeedItemAIReplyContent','chatFeed','ai.chat.context.searchInputVisibleFrom','isTrackChangesOn','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH','6349486wmAPDO','setInputPlaceholder','updateCapabilities','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH_REASONING','populateSourceResourceBalloon','_view','clearConversationContextUI','startInteraction','streaming','toggleSuggestionDisplayMode','filter','focusPromptInput','_promiseQueue','addItem','getItemIds','4cZUZbn','AIChatUI','enableModelSelector','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH','updateSuggestionPartState','delegate','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REGULAR','isMaximized','setLoadingMessage','isModelAvailable','isWebSearchEnabled','trackChanges','updateFeedItemAIReplySuggestionContent','updateFeedItemAIReplySuggestionPartState','resetConversationTitle','enableControls','ai.models.showModelSelector','AI_CHAT_HEADING','setSuggestionPartActive','requires','addFeedItemAISuggestion','remove','1305376EcTOeN','updateResourceState','get','locale','setModelList','feedItemRenderingStrategy','find','setFeedItemRenderingStrategy','prepareLoadingMessage','704502ivfAkL','1085220NDAqRY','ai.chat.welcomeMessage','AI_CHAT_FEED_LOADING_MESSAGE_REASONING','AITabs','queueEmptyPromise','isPending','conversationCreated','_animateConversationTitle','renderingStrategy','setContextItemLoading','addContextItem','scrollFeedToSuggestion','createConversation','displayedPrompt'];_0xe7ea=function(){return _0x5e707f;};return _0xe7ea();}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x93f129=_0x426d;(function(_0x29db95,_0x4f08be){const _0x3b3c60=_0x426d,_0x1f9660=_0x29db95();while(!![]){try{const _0x58297f=-parseInt(_0x3b3c60(0x161))/0x1+parseInt(_0x3b3c60(0x186))/0x2*(parseInt(_0x3b3c60(0x183))/0x3)+-parseInt(_0x3b3c60(0x154))/0x4*(parseInt(_0x3b3c60(0x19d))/0x5)+-parseInt(_0x3b3c60(0x15a))/0x6*(-parseInt(_0x3b3c60(0x17d))/0x7)+-parseInt(_0x3b3c60(0x1b4))/0x8*(-parseInt(_0x3b3c60(0x142))/0x9)+parseInt(_0x3b3c60(0x164))/0xa*(-parseInt(_0x3b3c60(0x171))/0xb)+-parseInt(_0x3b3c60(0x15b))/0xc*(-parseInt(_0x3b3c60(0x1ae))/0xd);if(_0x58297f===_0x4f08be)break;else _0x1f9660['push'](_0x1f9660['shift']());}catch(_0x3e3595){_0x1f9660['push'](_0x1f9660['shift']());}}}(_0x55eb,0x4cc47));import{CKEditorError as _0x3b1bc7,ObservableMixin as _0x171529,uid as _0x123aea}from'ckeditor5/src/utils.js';function _0x55eb(){const _0x5e8ced=['59753EAbzcy','isHidden','ai-chat-document-upload-failed','918390bVVKDP','addSelectionToContext','contextItemRemoved','TOOL','SELECTION','map','attributes','message','text/markdown','URL','selection','_isResourceInContext','file-','22pNHvxr','ai-chat-url-upload-failed','length','uploadUrl','clearPendingContextItems','abortController','substring','stack','_addContextOptionsState','_ongoingUploadOperations','size','addResourceToContext','35YjYKpN','Current\x20document','_addContextItem','removeSelectionFromContext','getData','addToConversationContext','96051DlfVSb','all','resourceStateChanged','28GVMWKb','object','delete','url-','ai-chat-source-resources-load-failed','_createContextItemFromContent','addUrlToContext','_updateResourceInContextState','isReadOnly','error','toolName','getDocument','_setAddContextOptionsDefaultState','getPendingContextItems','ai-chat-context-invalid-data','document','filter','ai-chat-resource-load-failed','_conversationContextItems','resourceId','contextItemAdded','uploadDocument','find','5YDjBWi','from','urls','abort','label','_addToConversationContextItem','isCurrentDocumentInContext','addCurrentDocumentToContext','enabled','loadSourceResources','_toggleAddCurrentDocumentOptionVisibility','DOCUMENT','data','MARKDOWN','_ownerId','_finishContextItemLoading','type','183716VEepgu','addToolItemToContext','isSelectionInContext','files','_config','customItems','88ClthGE','push','File','FILE','_getCustomSourcesInitialState','string','ai-chat-source-not-found','current-document','mcpServerName','isInContext','get','sources','populateFromMessage','version','mapContextItemsToRequestData','text/plain','getId','name','addContextOptionsChanged','_finishUploadOperation','uploadFile','uploadProgressChanged','updateCurrentDocument','values','fetchDocument','resources','content','sourceResourcesLoaded','_ongoingUploads','HTML','sessionId','startsWith','TEXT','url','set','_pendingContextItems','forEach','_convertTextResourceToFile','97974GgJfdH','_mapContextItemToRequestData','fire','_removeContextItem','removeFromContext','hidden','addFilesToContext','ai-chat-resource-no-data','has','_connector','files-','end','text/html','init','_findSourceIdsByResourceId','uiId','ai-chat-context-unsupported-type','isCurrentDocumentInConversation','307460OkLZvJ','getSentContextItems','_startUploadOperation','code','object\x20with\x20content\x20and\x20type\x20properties','ai-chat-file-upload-failed','29226fMPtBn','36qxcjpY','contextItemLoadingEnded','getResources','start','contextSent','ai-request-aborted'];_0x55eb=function(){return _0x5e8ced;};return _0x55eb();}import{AIContextItemType as _0x14c2d3,AIContextTextResourceType as _0x373519}from'../../aicore/model/aicontext.js';import{escape as _0x524adf}from'es-toolkit/compat';import{errorsMap as _0x59d93c}from'../../errorsmap.js';export const AI_CONTEXT_MODEL_EVENT_NAMES=[_0x93f129(0x19a),_0x93f129(0x166),_0x93f129(0x15c),_0x93f129(0x15f),_0x93f129(0x18f),_0x93f129(0x1c6),_0x93f129(0x137),_0x93f129(0x185),_0x93f129(0x131)];function _0x426d(_0x17d6f8,_0x59412a){const _0x55eb86=_0x55eb();return _0x426d=function(_0x426dcc,_0x105091){_0x426dcc=_0x426dcc-0x131;let _0x39fa0b=_0x55eb86[_0x426dcc];return _0x39fa0b;},_0x426d(_0x17d6f8,_0x59412a);}export class AIChatContext extends _0x171529(){[_0x93f129(0x14b)];[_0x93f129(0x1b2)];[_0x93f129(0x1ab)];constructor({connector:_0x10dd4e,config:_0x2a7203,ownerId:_0x4435d9}){const _0x2a5124=_0x93f129;super(),this[_0x2a5124(0x14b)]=_0x10dd4e,this[_0x2a5124(0x1b2)]=_0x2a7203,this[_0x2a5124(0x1ab)]=_0x4435d9;}[_0x93f129(0x14f)](){const _0x2fdb9e=_0x93f129;this[_0x2fdb9e(0x13f)]=new Map(),this[_0x2fdb9e(0x198)]=new Map(),this[_0x2fdb9e(0x138)]=new Map(),this[_0x2fdb9e(0x17a)]=new Map(),this[_0x2fdb9e(0x192)]();}[_0x93f129(0x193)](){const _0x3b0809=_0x93f129;return this[_0x3b0809(0x13f)];}async[_0x93f129(0x1c0)](_0x2bf1f6){const _0x1a5c24=_0x93f129,_0x2b735f=await this[_0x1a5c24(0x18b)](_0x2bf1f6);return this[_0x1a5c24(0x1a2)](_0x2b735f),_0x1a5c24(0x1bb)===_0x2b735f[_0x1a5c24(0x151)]&&this[_0x1a5c24(0x1a7)](),_0x2b735f;}async[_0x93f129(0x18b)](_0x38212a){const _0x313478=_0x93f129;if(_0x38212a[_0x313478(0x1ad)]===_0x14c2d3[_0x313478(0x1a8)]){const _0x5b0e1b=await this[_0x313478(0x14b)][_0x313478(0x134)](this[_0x313478(0x1ab)],_0x38212a['id'])[_0x313478(0x191)]();return{'id':_0x313478(0x1bb),'uiId':_0x313478(0x1bb),'label':_0x313478(0x17e),'type':_0x38212a[_0x313478(0x1ad)],'content':_0x5b0e1b[_0x313478(0x136)],'hidden':this[_0x313478(0x198)][_0x313478(0x14a)](_0x313478(0x1bb)),'version':_0x5b0e1b[_0x313478(0x16a)]?.[_0x313478(0x1c1)],'sessionId':_0x5b0e1b[_0x313478(0x16a)]?.[_0x313478(0x13a)]};}if(_0x38212a[_0x313478(0x1ad)]===_0x14c2d3[_0x313478(0x167)])return{'id':_0x38212a['id'],'uiId':_0x38212a['id'],'label':_0x38212a[_0x313478(0x1a9)]?.[_0x313478(0x1a1)]||_0x38212a['id'],'type':_0x14c2d3[_0x313478(0x167)],'mcpServerName':_0x38212a[_0x313478(0x1bc)],'toolName':_0x38212a[_0x313478(0x190)],'data':_0x38212a[_0x313478(0x1a9)]||{}};return{'id':_0x38212a['id'],'uiId':_0x38212a['id'],'label':_0x38212a[_0x313478(0x16a)]?.[_0x313478(0x1a1)]||_0x38212a[_0x313478(0x1c5)]||_0x38212a[_0x313478(0x13d)]||_0x38212a['id'],'type':_0x38212a[_0x313478(0x1ad)],..._0x38212a?.[_0x313478(0x16a)]?.[_0x313478(0x199)]?{'resourceId':_0x38212a[_0x313478(0x16a)]?.[_0x313478(0x199)]}:{}};}[_0x93f129(0x155)](){const _0x187b59=_0x93f129;return new Map(this[_0x187b59(0x198)]);}[_0x93f129(0x146)](_0x176290){const _0xc92e49=_0x93f129,_0x8bb269=this[_0xc92e49(0x13f)][_0xc92e49(0x1be)](_0x176290);_0x8bb269?.[_0xc92e49(0x18e)]||this[_0xc92e49(0x145)](_0x176290);}[_0x93f129(0x175)](){const _0x539410=_0x93f129;if(0x0===this[_0x539410(0x13f)][_0x539410(0x17b)])return;for(const _0x5b2496 of this[_0x539410(0x13f)][_0x539410(0x133)]())this[_0x539410(0x145)](_0x5b2496[_0x539410(0x151)]);const _0x5bc520=this[_0x539410(0x198)][_0x539410(0x1be)](_0x539410(0x1bb))||this[_0x539410(0x13f)][_0x539410(0x1be)](_0x539410(0x1bb));_0x5bc520&&this[_0x539410(0x17f)]({..._0x5bc520,'isReadOnly':!0x0,'hidden':!0x0});}[_0x93f129(0x182)](_0x104287){const _0x2ab169=_0x93f129;for(const _0x120989 of _0x104287[_0x2ab169(0x133)]())this[_0x2ab169(0x1a2)](_0x120989);this[_0x2ab169(0x175)](),this[_0x2ab169(0x144)](_0x2ab169(0x15f),{'contextItems':Array[_0x2ab169(0x19e)](this[_0x2ab169(0x155)]()[_0x2ab169(0x133)]())});}[_0x93f129(0x1a3)](){const _0x1cde3e=_0x93f129;return this[_0x1cde3e(0x13f)][_0x1cde3e(0x14a)](_0x1cde3e(0x1bb));}[_0x93f129(0x1b0)](){const _0x3f6d12=_0x93f129;return this[_0x3f6d12(0x13f)][_0x3f6d12(0x14a)](_0x3f6d12(0x16e));}[_0x93f129(0x153)](){const _0x147abb=_0x93f129;return this[_0x147abb(0x198)][_0x147abb(0x14a)](_0x147abb(0x1bb));}static[_0x93f129(0x1c2)](_0xe91a27){const _0x561fcf=_0x93f129;return Array[_0x561fcf(0x19e)](_0xe91a27[_0x561fcf(0x133)]())[_0x561fcf(0x169)](_0x17c99d=>this[_0x561fcf(0x143)](_0x17c99d))[_0x561fcf(0x196)](_0x1896aa=>null!==_0x1896aa);}async[_0x93f129(0x148)](_0x504e23,_0x1d9aa7,_0xae810a=_0x14c2d3[_0x93f129(0x1b7)]){const _0x42a5bd=_0x93f129,_0x21024f=_0x42a5bd(0x14c)+_0x123aea();this[_0x42a5bd(0x156)](_0x21024f);try{await Promise[_0x42a5bd(0x184)](_0x504e23[_0x42a5bd(0x169)](async _0x1df579=>{const _0x3dc140=_0x42a5bd,_0x32ba89=_0x3dc140(0x170)+_0x123aea(),_0x27eacb=_0x524adf(_0x1df579[_0x3dc140(0x1c5)]);try{this[_0x3dc140(0x17f)]({'type':_0xae810a,'label':_0x1d9aa7?.[_0x3dc140(0x1a1)]||_0x27eacb,'uiId':_0x32ba89,'resourceId':_0x1d9aa7?.[_0x3dc140(0x199)]},!0x0);const _0x1733cc=this[_0x3dc140(0x14b)][_0x3dc140(0x1c8)](this[_0x3dc140(0x1ab)],_0x1df579,_0x1d9aa7);this[_0x3dc140(0x138)][_0x3dc140(0x13e)](_0x32ba89,_0x1733cc[_0x3dc140(0x176)]);const {id:_0x4559}=await _0x1733cc[_0x3dc140(0x1c4)]();this[_0x3dc140(0x138)][_0x3dc140(0x188)](_0x32ba89),this[_0x3dc140(0x1ac)]({'type':_0xae810a,'id':_0x4559,'label':_0x1d9aa7?.[_0x3dc140(0x1a1)]||_0x27eacb,'uiId':_0x32ba89,'resourceId':_0x1d9aa7?.[_0x3dc140(0x199)]},!0x1);}catch(_0x4a1a28){this[_0x3dc140(0x138)][_0x3dc140(0x188)](_0x32ba89);if(!(_0x4a1a28 instanceof _0x3b1bc7&&_0x4a1a28[_0x3dc140(0x16b)][_0x3dc140(0x13b)](_0x3dc140(0x160)))){const _0x3d293d=_0x59d93c[_0x3dc140(0x1be)](_0x4a1a28[_0x3dc140(0x157)])||_0x3dc140(0x159),_0x554262=new _0x3b1bc7(_0x3d293d,null,{'fileName':_0x27eacb,..._0x4a1a28});_0x554262[_0x3dc140(0x178)]=_0x4a1a28[_0x3dc140(0x178)],this[_0x3dc140(0x144)](_0x3dc140(0x18f),{'error':_0x554262});}this[_0x3dc140(0x145)](_0x32ba89);}}));}finally{this[_0x42a5bd(0x1c7)](_0x21024f);}}[_0x93f129(0x1a4)](_0x4f2d19){const _0x443657=_0x93f129;if(this[_0x443657(0x1a3)]()||!this[_0x443657(0x179)][_0x443657(0x195)][_0x443657(0x1a5)])return;const _0x5654bf={'type':_0x14c2d3[_0x443657(0x1a8)],'uiId':_0x443657(0x1bb),'label':_0x4f2d19,'isReadOnly':this[_0x443657(0x198)][_0x443657(0x14a)](_0x443657(0x1bb)),'hidden':this[_0x443657(0x198)][_0x443657(0x14a)](_0x443657(0x1bb))};this[_0x443657(0x17f)](_0x5654bf);}async[_0x93f129(0x132)](_0x2f8652,_0x34fab9,_0x3584f1,_0x2c56d0){const _0x39c6a8=_0x93f129,_0x4a4473=this[_0x39c6a8(0x13f)][_0x39c6a8(0x1be)](_0x39c6a8(0x1bb));if(_0x4a4473&&_0x2f8652){_0x4a4473[_0x39c6a8(0x16e)]=_0x2c56d0?_0x2c56d0[_0x39c6a8(0x169)](_0x2d3828=>({'start':_0x2d3828[_0x39c6a8(0x15e)],'end':_0x2d3828[_0x39c6a8(0x14d)]})):[];try{if(_0x4a4473[_0x39c6a8(0x1c1)]===_0x34fab9)return;const {id:_0x10da25}=await this[_0x39c6a8(0x14b)][_0x39c6a8(0x19b)](this[_0x39c6a8(0x1ab)],_0x2f8652,{'version':_0x34fab9,'sessionId':_0x3584f1})[_0x39c6a8(0x1c4)]();_0x4a4473['id']=_0x10da25,_0x4a4473[_0x39c6a8(0x136)]=_0x2f8652,_0x4a4473[_0x39c6a8(0x1c1)]=_0x34fab9,_0x4a4473[_0x39c6a8(0x13a)]=_0x3584f1;}catch(_0x5aeac3){const _0x4584d9=new _0x3b1bc7(_0x39c6a8(0x163),null);_0x4584d9[_0x39c6a8(0x178)]=_0x5aeac3[_0x39c6a8(0x178)],this[_0x39c6a8(0x144)](_0x39c6a8(0x18f),{'error':_0x4584d9});}}}[_0x93f129(0x165)](_0xe7e271){const _0x5ee0b6=_0x93f129;this[_0x5ee0b6(0x17f)]({'type':_0x14c2d3[_0x5ee0b6(0x168)],'label':_0xe7e271,'uiId':_0x5ee0b6(0x16e),'content':_0xe7e271});}[_0x93f129(0x180)](){const _0x5b3a75=_0x93f129;this[_0x5b3a75(0x145)](_0x5b3a75(0x16e));}async[_0x93f129(0x18c)](_0x37ff5f,_0x246c05){const _0x257470=_0x93f129,_0x83716d=_0x257470(0x189)+_0x123aea();this[_0x257470(0x156)](_0x83716d);const _0x389931=_0x257470(0x189)+_0x123aea();try{this[_0x257470(0x17f)]({'type':_0x14c2d3[_0x257470(0x16d)],'label':_0x246c05?.[_0x257470(0x1a1)]||_0x37ff5f,'uiId':_0x389931,'resourceId':_0x246c05?.[_0x257470(0x199)]},!0x0);const _0x52ab28=this[_0x257470(0x14b)][_0x257470(0x174)](this[_0x257470(0x1ab)],_0x37ff5f,_0x246c05);this[_0x257470(0x138)][_0x257470(0x13e)](_0x389931,_0x52ab28[_0x257470(0x176)]);const {id:_0x3542f1}=await _0x52ab28[_0x257470(0x1c4)]();this[_0x257470(0x138)][_0x257470(0x188)](_0x389931),this[_0x257470(0x1ac)]({'type':_0x14c2d3[_0x257470(0x16d)],'id':_0x3542f1,'label':_0x246c05?.[_0x257470(0x1a1)]||_0x37ff5f,'uiId':_0x389931,'resourceId':_0x246c05?.[_0x257470(0x199)]},!0x1);}catch(_0x2250eb){this[_0x257470(0x138)][_0x257470(0x188)](_0x389931),(_0x2250eb[_0x257470(0x16b)][_0x257470(0x13b)](_0x257470(0x160))||this[_0x257470(0x144)](_0x257470(0x18f),{'error':new _0x3b1bc7(_0x257470(0x172),this,{'url':_0x37ff5f,'originalError':_0x2250eb}),'url':_0x37ff5f}),this[_0x257470(0x145)](_0x389931));}finally{this[_0x257470(0x1c7)](_0x83716d);}}[_0x93f129(0x1af)](_0x3e290c){const _0x308066=_0x93f129;_0x3e290c['id']=_0x3e290c['id']??_0x123aea()[_0x308066(0x177)](0x0,0x15),this[_0x308066(0x13f)][_0x308066(0x13e)](_0x3e290c[_0x308066(0x151)],_0x3e290c),this[_0x308066(0x144)](_0x308066(0x19a),{'contextItem':_0x3e290c,'isLoading':!0x1});}async[_0x93f129(0x1a6)](_0x1e116f,_0x2b33c8,_0x22f38f){const _0x2e5a51=_0x93f129,_0x5c05e8=this[_0x2e5a51(0x179)][_0x2e5a51(0x1bf)][_0x2e5a51(0x19c)](_0x3cfd13=>_0x3cfd13['id']===_0x1e116f);if(!_0x5c05e8)return this[_0x2e5a51(0x144)](_0x2e5a51(0x18f),{'error':new _0x3b1bc7(_0x2e5a51(0x1ba),this,{'sourceId':_0x1e116f}),'sourceId':_0x1e116f}),[];try{const _0x4e50d5=(await _0x5c05e8[_0x2e5a51(0x15d)](_0x2b33c8))[_0x2e5a51(0x169)](_0x3c14bc=>{const _0x577c9a=_0x2e5a51,_0x2582f0=this[_0x577c9a(0x16f)](_0x3c14bc['id']);return{..._0x3c14bc,'isInContext':_0x2582f0};});return _0x5c05e8[_0x2e5a51(0x135)]=_0x4e50d5,this[_0x2e5a51(0x144)](_0x2e5a51(0x137),{'sourceId':_0x1e116f,'source':_0x5c05e8,'resources':_0x4e50d5,'uid':_0x22f38f}),_0x4e50d5;}catch(_0x114e29){return this[_0x2e5a51(0x144)](_0x2e5a51(0x18f),{'error':new _0x3b1bc7(_0x2e5a51(0x18a),this,{'sourceId':_0x1e116f,'originalError':_0x114e29}),'sourceId':_0x1e116f,'sourceLabel':_0x5c05e8[_0x2e5a51(0x1a1)]}),[];}}async[_0x93f129(0x17c)](_0x2047ee,_0xc8d2e1){const _0x509c02=_0x93f129;if(this[_0x509c02(0x16f)](_0xc8d2e1['id']))return;let _0x56fdde=_0xc8d2e1[_0x509c02(0x1a9)];if(!_0x56fdde&&_0x2047ee[_0x509c02(0x181)])try{_0x56fdde=await _0x2047ee[_0x509c02(0x181)](_0xc8d2e1['id']);}catch(_0x1171c0){return void this[_0x509c02(0x144)](_0x509c02(0x18f),{'error':new _0x3b1bc7(_0x509c02(0x197),this,{'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id'],'originalError':_0x1171c0}),'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id']});}if(_0x56fdde)switch(_0xc8d2e1[_0x509c02(0x1ad)]){case _0x14c2d3[_0x509c02(0x16d)]:if(_0x509c02(0x1b9)!=typeof _0x56fdde)return void this[_0x509c02(0x144)](_0x509c02(0x18f),{'error':new _0x3b1bc7(_0x509c02(0x194),this,{'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id'],'expectedType':_0x509c02(0x1b9),'actualType':typeof _0x56fdde}),'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id']});await this[_0x509c02(0x18c)](_0x56fdde,{'label':_0xc8d2e1[_0x509c02(0x1a1)],'resourceId':_0xc8d2e1['id']});break;case _0x14c2d3[_0x509c02(0x1b7)]:if(!(_0x56fdde instanceof File))return void this[_0x509c02(0x144)](_0x509c02(0x18f),{'error':new _0x3b1bc7(_0x509c02(0x194),this,{'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id'],'expectedType':_0x509c02(0x1b6),'actualType':typeof _0x56fdde}),'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id']});await this[_0x509c02(0x148)]([_0x56fdde],{'label':_0xc8d2e1[_0x509c02(0x1a1)],'resourceId':_0xc8d2e1['id']});break;case _0x14c2d3[_0x509c02(0x13c)]:if(_0x509c02(0x187)!=typeof _0x56fdde||!(_0x509c02(0x136)in _0x56fdde)||!(_0x509c02(0x1ad)in _0x56fdde))return void this[_0x509c02(0x144)](_0x509c02(0x18f),{'error':new _0x3b1bc7(_0x509c02(0x194),this,{'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id'],'expectedType':_0x509c02(0x158),'actualType':typeof _0x56fdde}),'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id']});_0x56fdde=AIChatContext[_0x509c02(0x141)](_0x56fdde,_0xc8d2e1[_0x509c02(0x1a1)]),await this[_0x509c02(0x148)]([_0x56fdde],{'label':_0xc8d2e1[_0x509c02(0x1a1)],'resourceId':_0xc8d2e1['id']},_0x14c2d3[_0x509c02(0x13c)]);break;case _0x14c2d3[_0x509c02(0x167)]:break;default:this[_0x509c02(0x144)](_0x509c02(0x18f),{'error':new _0x3b1bc7(_0x509c02(0x152),this,{'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id'],'resourceType':_0xc8d2e1[_0x509c02(0x1ad)]}),'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id']});}else this[_0x509c02(0x144)](_0x509c02(0x18f),{'error':new _0x3b1bc7(_0x509c02(0x149),this,{'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id']}),'resourceId':_0xc8d2e1['id'],'sourceId':_0x2047ee['id']});}static[_0x93f129(0x141)](_0x117620,_0x8006fc){const _0x15dca8=_0x93f129;switch(_0x117620[_0x15dca8(0x1ad)]){case _0x373519[_0x15dca8(0x1aa)]:return new File([_0x117620[_0x15dca8(0x136)]],_0x8006fc,{'type':_0x15dca8(0x16c)});case _0x373519[_0x15dca8(0x139)]:return new File([_0x117620[_0x15dca8(0x136)]],_0x8006fc,{'type':_0x15dca8(0x14e)});default:return new File([_0x117620[_0x15dca8(0x136)]],_0x8006fc,{'type':_0x15dca8(0x1c3)});}}static[_0x93f129(0x143)](_0x15cb6c){const _0x3aecf8=_0x93f129;switch(_0x15cb6c[_0x3aecf8(0x1ad)]){case _0x14c2d3[_0x3aecf8(0x1b7)]:return{'type':_0x14c2d3[_0x3aecf8(0x1b7)],'id':_0x15cb6c['id']};case _0x14c2d3[_0x3aecf8(0x16d)]:return{'type':_0x14c2d3[_0x3aecf8(0x16d)],'id':_0x15cb6c['id']};case _0x14c2d3[_0x3aecf8(0x1a8)]:return{'type':_0x14c2d3[_0x3aecf8(0x1a8)],'id':_0x15cb6c['id'],..._0x15cb6c[_0x3aecf8(0x16e)]?.[_0x3aecf8(0x173)]&&{'selection':_0x15cb6c[_0x3aecf8(0x16e)]}};case _0x14c2d3[_0x3aecf8(0x13c)]:return{'type':_0x14c2d3[_0x3aecf8(0x1b7)],'id':_0x15cb6c['id']};case _0x14c2d3[_0x3aecf8(0x167)]:{const _0x507a26=_0x15cb6c;return{'type':_0x14c2d3[_0x3aecf8(0x167)],'mcpServerName':_0x507a26[_0x3aecf8(0x1bc)],'toolName':_0x507a26[_0x3aecf8(0x190)],'data':_0x507a26[_0x3aecf8(0x1a9)],'id':_0x507a26['id']};}default:return null;}}[_0x93f129(0x17f)](_0x5529f8,_0x46c139=!0x1){const _0x5c54c7=_0x93f129;if(this[_0x5c54c7(0x13f)][_0x5c54c7(0x13e)](_0x5529f8[_0x5c54c7(0x151)],_0x5529f8),_0x5529f8[_0x5c54c7(0x147)]||this[_0x5c54c7(0x144)](_0x5c54c7(0x19a),{'contextItem':_0x5529f8,'isLoading':_0x46c139}),_0x5c54c7(0x1bb)===_0x5529f8[_0x5c54c7(0x151)]&&this[_0x5c54c7(0x1a7)](),_0x5529f8[_0x5c54c7(0x199)]){const _0xeefa35=this[_0x5c54c7(0x150)](_0x5529f8[_0x5c54c7(0x199)]);_0xeefa35&&_0xeefa35[_0x5c54c7(0x140)](_0x57b59f=>{const _0x51d31b=_0x5c54c7;this[_0x51d31b(0x18d)](_0x57b59f,_0x5529f8[_0x51d31b(0x199)],!0x0);});}}[_0x93f129(0x145)](_0x1271da){const _0x2e3e5d=_0x93f129,_0x2606ab=this[_0x2e3e5d(0x13f)][_0x2e3e5d(0x1be)](_0x1271da),_0x2af3c9=this[_0x2e3e5d(0x138)][_0x2e3e5d(0x1be)](_0x1271da);if(_0x2af3c9&&(_0x2af3c9[_0x2e3e5d(0x1a0)](),this[_0x2e3e5d(0x138)][_0x2e3e5d(0x188)](_0x1271da)),_0x2606ab?.[_0x2e3e5d(0x199)]){const _0x89c0b0=this[_0x2e3e5d(0x150)](_0x2606ab[_0x2e3e5d(0x199)]);_0x89c0b0&&_0x89c0b0[_0x2e3e5d(0x140)](_0x2affc6=>{const _0x3c8771=_0x2e3e5d;this[_0x3c8771(0x18d)](_0x2affc6,_0x2606ab[_0x3c8771(0x199)],!0x1);});}this[_0x2e3e5d(0x13f)][_0x2e3e5d(0x188)](_0x1271da),this[_0x2e3e5d(0x144)](_0x2e3e5d(0x166),{'uiId':_0x1271da,'type':_0x2606ab?.[_0x2e3e5d(0x1ad)]}),_0x2e3e5d(0x1bb)===_0x1271da&&this[_0x2e3e5d(0x1a7)]();}[_0x93f129(0x1ac)](_0x4ef6f7,_0x25632f){const _0x5c98c6=_0x93f129;if(this[_0x5c98c6(0x13f)][_0x5c98c6(0x14a)](_0x4ef6f7[_0x5c98c6(0x151)])&&(this[_0x5c98c6(0x13f)][_0x5c98c6(0x13e)](_0x4ef6f7[_0x5c98c6(0x151)],_0x4ef6f7),this[_0x5c98c6(0x144)](_0x5c98c6(0x15c),{'contextItem':_0x4ef6f7,'isLoading':_0x25632f}),_0x4ef6f7[_0x5c98c6(0x199)])){const _0xeae4ba=this[_0x5c98c6(0x150)](_0x4ef6f7[_0x5c98c6(0x199)]);_0xeae4ba&&_0xeae4ba[_0x5c98c6(0x140)](_0xf73ca2=>{const _0x3b4e52=_0x5c98c6;this[_0x3b4e52(0x18d)](_0xf73ca2,_0x4ef6f7[_0x3b4e52(0x199)],!0x0);});}}[_0x93f129(0x1a2)](_0x4179ea){const _0x49f67a=_0x93f129;this[_0x49f67a(0x198)][_0x49f67a(0x13e)](_0x4179ea[_0x49f67a(0x151)],_0x4179ea);}[_0x93f129(0x192)](){const _0x342cbf=_0x93f129;this[_0x342cbf(0x179)]={'document':{'enabled':!0x1!==this[_0x342cbf(0x1b2)]?.[_0x342cbf(0x195)]?.[_0x342cbf(0x1a5)],'isHidden':!0x1},'urls':{'enabled':!0x1!==this[_0x342cbf(0x1b2)]?.[_0x342cbf(0x19f)]?.[_0x342cbf(0x1a5)]},'files':{'enabled':!0x1!==this[_0x342cbf(0x1b2)]?.[_0x342cbf(0x1b1)]?.[_0x342cbf(0x1a5)]},'sources':this[_0x342cbf(0x1b8)](),'customItems':this[_0x342cbf(0x1b2)]?.[_0x342cbf(0x1b3)]?.[_0x342cbf(0x169)](_0x26c6ad=>({..._0x26c6ad,'enabled':!0x0}))??[]},this[_0x342cbf(0x144)](_0x342cbf(0x1c6),{'options':this[_0x342cbf(0x179)]});}[_0x93f129(0x1b8)](){const _0x1785ac=_0x93f129;return this[_0x1785ac(0x1b2)]?.[_0x1785ac(0x1bf)]?.[_0x1785ac(0x169)](_0x5957f1=>({..._0x5957f1,'resources':[]}))??[];}[_0x93f129(0x1a7)](){const _0x4123d1=_0x93f129,_0x3f8e05=this[_0x4123d1(0x1a3)]()||this[_0x4123d1(0x153)]();this[_0x4123d1(0x179)][_0x4123d1(0x195)][_0x4123d1(0x162)]=_0x3f8e05,this[_0x4123d1(0x144)](_0x4123d1(0x1c6),{'options':this[_0x4123d1(0x179)]});}[_0x93f129(0x16f)](_0x250a38){const _0x5f30f6=_0x93f129;for(const _0x34a21a of this[_0x5f30f6(0x13f)][_0x5f30f6(0x133)]())if(_0x34a21a[_0x5f30f6(0x199)]===_0x250a38)return!0x0;for(const _0x462ee3 of this[_0x5f30f6(0x198)][_0x5f30f6(0x133)]())if(_0x462ee3[_0x5f30f6(0x199)]===_0x250a38)return!0x0;return!0x1;}[_0x93f129(0x150)](_0xa01923){const _0x5554e8=_0x93f129,_0x239a7d=[];for(const _0x380454 of this[_0x5554e8(0x179)][_0x5554e8(0x1bf)]){_0x380454[_0x5554e8(0x135)][_0x5554e8(0x19c)](_0x128f53=>_0x128f53['id']===_0xa01923)&&_0x239a7d[_0x5554e8(0x1b5)](_0x380454['id']);}return 0x0===_0x239a7d[_0x5554e8(0x173)]?null:_0x239a7d;}[_0x93f129(0x18d)](_0x1fbeea,_0x302edd,_0x1e37b3){const _0x3b9297=_0x93f129,_0x493b3e=this[_0x3b9297(0x179)][_0x3b9297(0x1bf)][_0x3b9297(0x19c)](_0x3dbc6f=>_0x3dbc6f['id']===_0x1fbeea);if(!_0x493b3e)return;const _0x97e0f7=_0x493b3e[_0x3b9297(0x135)][_0x3b9297(0x19c)](_0x1bf4ac=>_0x1bf4ac['id']===_0x302edd);_0x97e0f7&&(_0x97e0f7[_0x3b9297(0x1bd)]=_0x1e37b3,this[_0x3b9297(0x144)](_0x3b9297(0x185),{'sourceId':_0x1fbeea,'resourceId':_0x302edd,'isInContext':_0x1e37b3}));}[_0x93f129(0x156)](_0x584a41){const _0x5a334a=_0x93f129;this[_0x5a334a(0x17a)][_0x5a334a(0x13e)](_0x584a41,!0x0),this[_0x5a334a(0x17a)][_0x5a334a(0x17b)]&&this[_0x5a334a(0x144)](_0x5a334a(0x131),{'isUploadInProgress':!0x0});}[_0x93f129(0x1c7)](_0x16499b){const _0x520b00=_0x93f129;this[_0x520b00(0x17a)][_0x520b00(0x188)](_0x16499b),0x0===this[_0x520b00(0x17a)][_0x520b00(0x17b)]&&this[_0x520b00(0x144)](_0x520b00(0x131),{'isUploadInProgress':!0x1});}}
23
+ const _0x27a96b=_0x9508;(function(_0x11bcbb,_0x41a815){const _0x20396b=_0x9508,_0x1c3fef=_0x11bcbb();while(!![]){try{const _0x489aa2=-parseInt(_0x20396b(0x197))/0x1+parseInt(_0x20396b(0x16e))/0x2*(parseInt(_0x20396b(0x187))/0x3)+-parseInt(_0x20396b(0x152))/0x4+-parseInt(_0x20396b(0x1a0))/0x5+parseInt(_0x20396b(0x198))/0x6+parseInt(_0x20396b(0x159))/0x7*(parseInt(_0x20396b(0x1ce))/0x8)+-parseInt(_0x20396b(0x156))/0x9;if(_0x489aa2===_0x41a815)break;else _0x1c3fef['push'](_0x1c3fef['shift']());}catch(_0xbc73a2){_0x1c3fef['push'](_0x1c3fef['shift']());}}}(_0x5ecb,0xa6511));import{CKEditorError as _0x96d3b4,ObservableMixin as _0xe85e33,uid as _0x32b7ae}from'ckeditor5/src/utils.js';import{AIContextItemType as _0x4c0c19,AIContextTextResourceType as _0x203c83}from'../../aicore/model/aicontext.js';import{escape as _0x1533d3}from'es-toolkit/compat';import{errorsMap as _0x8de527}from'../../errorsmap.js';function _0x9508(_0x1cf429,_0x1fb513){const _0x5ecb0a=_0x5ecb();return _0x9508=function(_0x95081b,_0x1c9873){_0x95081b=_0x95081b-0x145;let _0x39f5c0=_0x5ecb0a[_0x95081b];return _0x39f5c0;},_0x9508(_0x1cf429,_0x1fb513);}export const AI_CONTEXT_MODEL_EVENT_NAMES=[_0x27a96b(0x1cd),_0x27a96b(0x168),_0x27a96b(0x1b3),_0x27a96b(0x1c7),_0x27a96b(0x151),_0x27a96b(0x169),_0x27a96b(0x1c5),_0x27a96b(0x14d),_0x27a96b(0x1b5)];function _0x5ecb(){const _0x57a565=['isCurrentDocumentInConversation','hidden','name','all','contextItemRemoved','addContextOptionsChanged','getSentContextItems','text/html','sources','_findSourceIdsByResourceId','1588BLsVAQ','isCurrentDocumentInContext','_pendingContextItems','ai-chat-url-upload-failed','clearPendingContextItems','attributes','DOCUMENT','_ongoingUploads','_addContextItem','removeFromContext','enabled','addToolItemToContext','delete','uploadUrl','URL','init','text/plain','updateCurrentDocument','file-','addCurrentDocumentToContext','uiId','ai-chat-context-unsupported-type','isInContext','end','toolName','3369lzQeOI','resources','getId','length','urls','_ownerId','addUrlToContext','HTML','label','files','values','substring','uploadDocument','MARKDOWN','start','ai-chat-file-upload-failed','40928IiJaTT','5241138CSIfmV','_convertTextResourceToFile','Current\x20document','message','url','string','find','addToConversationContext','145690uFmqyT','SELECTION','isSelectionInContext','abort','fetchDocument','ai-chat-source-not-found','isReadOnly','_startUploadOperation','getDocument','forEach','addSelectionToContext','ai-chat-resource-no-data','url-','from','startsWith','set','push','size','addFilesToContext','contextItemLoadingEnded','FILE','uploadProgressChanged','_getCustomSourcesInitialState','has','resourceId','document','content','populateFromMessage','fire','customItems','_toggleAddCurrentDocumentOptionVisibility','code','getResources','ai-chat-context-invalid-data','_setAddContextOptionsDefaultState','loadSourceResources','getData','sourceResourcesLoaded','current-document','contextSent','_removeContextItem','_addToConversationContextItem','_finishContextItemLoading','mapContextItemsToRequestData','sessionId','contextItemAdded','25880hOBGoC','files-','object','_conversationContextItems','object\x20with\x20content\x20and\x20type\x20properties','filter','mcpServerName','_finishUploadOperation','stack','uploadFile','TEXT','_config','text/markdown','TOOL','ai-chat-document-upload-failed','_createContextItemFromContent','ai-request-aborted','abortController','isHidden','resourceStateChanged','_connector','get','selection','error','4569576kqgcko','getPendingContextItems','_ongoingUploadOperations','version','2832183EvEcPq','_mapContextItemToRequestData','type','959umaJBs','File','_isResourceInContext','data','addResourceToContext','_updateResourceInContextState','ai-chat-source-resources-load-failed','_addContextOptionsState','ai-chat-resource-load-failed','map','removeSelectionFromContext'];_0x5ecb=function(){return _0x57a565;};return _0x5ecb();}export class AIChatContext extends _0xe85e33(){[_0x27a96b(0x14e)];[_0x27a96b(0x145)];[_0x27a96b(0x18c)];constructor({connector:_0x3f63e7,config:_0xb091c4,ownerId:_0xc89aba}){const _0x403382=_0x27a96b;super(),this[_0x403382(0x14e)]=_0x3f63e7,this[_0x403382(0x145)]=_0xb091c4,this[_0x403382(0x18c)]=_0xc89aba;}[_0x27a96b(0x17d)](){const _0x12377e=_0x27a96b;this[_0x12377e(0x170)]=new Map(),this[_0x12377e(0x1d1)]=new Map(),this[_0x12377e(0x175)]=new Map(),this[_0x12377e(0x154)]=new Map(),this[_0x12377e(0x1c2)]();}[_0x27a96b(0x153)](){const _0x22cfd7=_0x27a96b;return this[_0x22cfd7(0x170)];}async[_0x27a96b(0x1bb)](_0x4861c3){const _0x575366=_0x27a96b,_0x5a43a4=await this[_0x575366(0x149)](_0x4861c3);return this[_0x575366(0x1c9)](_0x5a43a4),_0x575366(0x1c6)===_0x5a43a4[_0x575366(0x182)]&&this[_0x575366(0x1be)](),_0x5a43a4;}async[_0x27a96b(0x149)](_0x4dd932){const _0x272367=_0x27a96b;if(_0x4dd932[_0x272367(0x158)]===_0x4c0c19[_0x272367(0x174)]){const _0x354e22=await this[_0x272367(0x14e)][_0x272367(0x1a4)](this[_0x272367(0x18c)],_0x4dd932['id'])[_0x272367(0x1a8)]();return{'id':_0x272367(0x1c6),'uiId':_0x272367(0x1c6),'label':_0x272367(0x19a),'type':_0x4dd932[_0x272367(0x158)],'content':_0x354e22[_0x272367(0x1ba)],'hidden':this[_0x272367(0x1d1)][_0x272367(0x1b7)](_0x272367(0x1c6)),'version':_0x354e22[_0x272367(0x173)]?.[_0x272367(0x155)],'sessionId':_0x354e22[_0x272367(0x173)]?.[_0x272367(0x1cc)]};}if(_0x4dd932[_0x272367(0x158)]===_0x4c0c19[_0x272367(0x147)])return{'id':_0x4dd932['id'],'uiId':_0x4dd932['id'],'label':_0x4dd932[_0x272367(0x15c)]?.[_0x272367(0x18f)]||_0x4dd932['id'],'type':_0x4c0c19[_0x272367(0x147)],'mcpServerName':_0x4dd932[_0x272367(0x1d4)],'toolName':_0x4dd932[_0x272367(0x186)],'data':_0x4dd932[_0x272367(0x15c)]||{}};return{'id':_0x4dd932['id'],'uiId':_0x4dd932['id'],'label':_0x4dd932[_0x272367(0x173)]?.[_0x272367(0x18f)]||_0x4dd932[_0x272367(0x166)]||_0x4dd932[_0x272367(0x19c)]||_0x4dd932['id'],'type':_0x4dd932[_0x272367(0x158)],..._0x4dd932?.[_0x272367(0x173)]?.[_0x272367(0x1b8)]?{'resourceId':_0x4dd932[_0x272367(0x173)]?.[_0x272367(0x1b8)]}:{}};}[_0x27a96b(0x16a)](){const _0x49a3ff=_0x27a96b;return new Map(this[_0x49a3ff(0x1d1)]);}[_0x27a96b(0x177)](_0xb0c652){const _0x3321ed=_0x27a96b,_0x467348=this[_0x3321ed(0x170)][_0x3321ed(0x14f)](_0xb0c652);_0x467348?.[_0x3321ed(0x1a6)]||this[_0x3321ed(0x1c8)](_0xb0c652);}[_0x27a96b(0x172)](){const _0x20b63c=_0x27a96b;if(0x0===this[_0x20b63c(0x170)][_0x20b63c(0x1b1)])return;for(const _0x2722ab of this[_0x20b63c(0x170)][_0x20b63c(0x191)]())this[_0x20b63c(0x1c8)](_0x2722ab[_0x20b63c(0x182)]);const _0x1683c6=this[_0x20b63c(0x1d1)][_0x20b63c(0x14f)](_0x20b63c(0x1c6))||this[_0x20b63c(0x170)][_0x20b63c(0x14f)](_0x20b63c(0x1c6));_0x1683c6&&this[_0x20b63c(0x176)]({..._0x1683c6,'isReadOnly':!0x0,'hidden':!0x0});}[_0x27a96b(0x19f)](_0x2888ef){const _0x407a52=_0x27a96b;for(const _0x11d08e of _0x2888ef[_0x407a52(0x191)]())this[_0x407a52(0x1c9)](_0x11d08e);this[_0x407a52(0x172)](),this[_0x407a52(0x1bc)](_0x407a52(0x1c7),{'contextItems':Array[_0x407a52(0x1ad)](this[_0x407a52(0x16a)]()[_0x407a52(0x191)]())});}[_0x27a96b(0x16f)](){const _0x24adad=_0x27a96b;return this[_0x24adad(0x170)][_0x24adad(0x1b7)](_0x24adad(0x1c6));}[_0x27a96b(0x1a2)](){const _0x201bcf=_0x27a96b;return this[_0x201bcf(0x170)][_0x201bcf(0x1b7)](_0x201bcf(0x150));}[_0x27a96b(0x164)](){const _0x1d541d=_0x27a96b;return this[_0x1d541d(0x1d1)][_0x1d541d(0x1b7)](_0x1d541d(0x1c6));}static[_0x27a96b(0x1cb)](_0x10504e){const _0x2965cb=_0x27a96b;return Array[_0x2965cb(0x1ad)](_0x10504e[_0x2965cb(0x191)]())[_0x2965cb(0x162)](_0x15c94c=>this[_0x2965cb(0x157)](_0x15c94c))[_0x2965cb(0x1d3)](_0x2e3847=>null!==_0x2e3847);}async[_0x27a96b(0x1b2)](_0x3fcf86,_0x1b970b,_0xae4f3c=_0x4c0c19[_0x27a96b(0x1b4)]){const _0x281cb4=_0x27a96b,_0x2f7aea=_0x281cb4(0x1cf)+_0x32b7ae();this[_0x281cb4(0x1a7)](_0x2f7aea);try{await Promise[_0x281cb4(0x167)](_0x3fcf86[_0x281cb4(0x162)](async _0xaf60fb=>{const _0x18e90f=_0x281cb4,_0x18f8e3=_0x18e90f(0x180)+_0x32b7ae(),_0x31176c=_0x1533d3(_0xaf60fb[_0x18e90f(0x166)]);try{this[_0x18e90f(0x176)]({'type':_0xae4f3c,'label':_0x1b970b?.[_0x18e90f(0x18f)]||_0x31176c,'uiId':_0x18f8e3,'resourceId':_0x1b970b?.[_0x18e90f(0x1b8)]},!0x0);const _0x2b21bb=this[_0x18e90f(0x14e)][_0x18e90f(0x1d7)](this[_0x18e90f(0x18c)],_0xaf60fb,_0x1b970b);this[_0x18e90f(0x175)][_0x18e90f(0x1af)](_0x18f8e3,_0x2b21bb[_0x18e90f(0x14b)]);const {id:_0x1effdb}=await _0x2b21bb[_0x18e90f(0x189)]();this[_0x18e90f(0x175)][_0x18e90f(0x17a)](_0x18f8e3),this[_0x18e90f(0x1ca)]({'type':_0xae4f3c,'id':_0x1effdb,'label':_0x1b970b?.[_0x18e90f(0x18f)]||_0x31176c,'uiId':_0x18f8e3,'resourceId':_0x1b970b?.[_0x18e90f(0x1b8)]},!0x1);}catch(_0x2d24e3){this[_0x18e90f(0x175)][_0x18e90f(0x17a)](_0x18f8e3);if(!(_0x2d24e3 instanceof _0x96d3b4&&_0x2d24e3[_0x18e90f(0x19b)][_0x18e90f(0x1ae)](_0x18e90f(0x14a)))){const _0x57cf10=_0x8de527[_0x18e90f(0x14f)](_0x2d24e3[_0x18e90f(0x1bf)])||_0x18e90f(0x196),_0x37eaa6=new _0x96d3b4(_0x57cf10,null,{'fileName':_0x31176c,..._0x2d24e3});_0x37eaa6[_0x18e90f(0x1d6)]=_0x2d24e3[_0x18e90f(0x1d6)],this[_0x18e90f(0x1bc)](_0x18e90f(0x151),{'error':_0x37eaa6});}this[_0x18e90f(0x1c8)](_0x18f8e3);}}));}finally{this[_0x281cb4(0x1d5)](_0x2f7aea);}}[_0x27a96b(0x181)](_0x2f3056){const _0x260c64=_0x27a96b;if(this[_0x260c64(0x16f)]()||!this[_0x260c64(0x160)][_0x260c64(0x1b9)][_0x260c64(0x178)])return;const _0x23ce93={'type':_0x4c0c19[_0x260c64(0x174)],'uiId':_0x260c64(0x1c6),'label':_0x2f3056,'isReadOnly':this[_0x260c64(0x1d1)][_0x260c64(0x1b7)](_0x260c64(0x1c6)),'hidden':this[_0x260c64(0x1d1)][_0x260c64(0x1b7)](_0x260c64(0x1c6))};this[_0x260c64(0x176)](_0x23ce93);}async[_0x27a96b(0x17f)](_0x41690c,_0x5407ed,_0x2aa1fb,_0x1ae26b){const _0xa31356=_0x27a96b,_0x11b69e=this[_0xa31356(0x170)][_0xa31356(0x14f)](_0xa31356(0x1c6));if(_0x11b69e&&_0x41690c){_0x11b69e[_0xa31356(0x150)]=_0x1ae26b?_0x1ae26b[_0xa31356(0x162)](_0x4d4b09=>({'start':_0x4d4b09[_0xa31356(0x195)],'end':_0x4d4b09[_0xa31356(0x185)]})):[];try{if(_0x11b69e[_0xa31356(0x155)]===_0x5407ed)return;const {id:_0x54832a}=await this[_0xa31356(0x14e)][_0xa31356(0x193)](this[_0xa31356(0x18c)],_0x41690c,{'version':_0x5407ed,'sessionId':_0x2aa1fb})[_0xa31356(0x189)]();_0x11b69e['id']=_0x54832a,_0x11b69e[_0xa31356(0x1ba)]=_0x41690c,_0x11b69e[_0xa31356(0x155)]=_0x5407ed,_0x11b69e[_0xa31356(0x1cc)]=_0x2aa1fb;}catch(_0x5a39f0){const _0x6ffdf9=new _0x96d3b4(_0xa31356(0x148),null);_0x6ffdf9[_0xa31356(0x1d6)]=_0x5a39f0[_0xa31356(0x1d6)],this[_0xa31356(0x1bc)](_0xa31356(0x151),{'error':_0x6ffdf9});}}}[_0x27a96b(0x1aa)](_0x74fe7c){const _0x45d62c=_0x27a96b;this[_0x45d62c(0x176)]({'type':_0x4c0c19[_0x45d62c(0x1a1)],'label':_0x74fe7c,'uiId':_0x45d62c(0x150),'content':_0x74fe7c});}[_0x27a96b(0x163)](){const _0x222751=_0x27a96b;this[_0x222751(0x1c8)](_0x222751(0x150));}async[_0x27a96b(0x18d)](_0x2b805d,_0xdd4d36){const _0x17bcdf=_0x27a96b,_0x29761c=_0x17bcdf(0x1ac)+_0x32b7ae();this[_0x17bcdf(0x1a7)](_0x29761c);const _0x13df04=_0x17bcdf(0x1ac)+_0x32b7ae();try{this[_0x17bcdf(0x176)]({'type':_0x4c0c19[_0x17bcdf(0x17c)],'label':_0xdd4d36?.[_0x17bcdf(0x18f)]||_0x2b805d,'uiId':_0x13df04,'resourceId':_0xdd4d36?.[_0x17bcdf(0x1b8)]},!0x0);const _0x577438=this[_0x17bcdf(0x14e)][_0x17bcdf(0x17b)](this[_0x17bcdf(0x18c)],_0x2b805d,_0xdd4d36);this[_0x17bcdf(0x175)][_0x17bcdf(0x1af)](_0x13df04,_0x577438[_0x17bcdf(0x14b)]);const {id:_0x38fed8}=await _0x577438[_0x17bcdf(0x189)]();this[_0x17bcdf(0x175)][_0x17bcdf(0x17a)](_0x13df04),this[_0x17bcdf(0x1ca)]({'type':_0x4c0c19[_0x17bcdf(0x17c)],'id':_0x38fed8,'label':_0xdd4d36?.[_0x17bcdf(0x18f)]||_0x2b805d,'uiId':_0x13df04,'resourceId':_0xdd4d36?.[_0x17bcdf(0x1b8)]},!0x1);}catch(_0x4e5c93){this[_0x17bcdf(0x175)][_0x17bcdf(0x17a)](_0x13df04),(_0x4e5c93[_0x17bcdf(0x19b)][_0x17bcdf(0x1ae)](_0x17bcdf(0x14a))||this[_0x17bcdf(0x1bc)](_0x17bcdf(0x151),{'error':new _0x96d3b4(_0x17bcdf(0x171),this,{'url':_0x2b805d,'originalError':_0x4e5c93}),'url':_0x2b805d}),this[_0x17bcdf(0x1c8)](_0x13df04));}finally{this[_0x17bcdf(0x1d5)](_0x29761c);}}[_0x27a96b(0x179)](_0x3c97cd){const _0x461aef=_0x27a96b;_0x3c97cd['id']=_0x3c97cd['id']??_0x32b7ae()[_0x461aef(0x192)](0x0,0x15),this[_0x461aef(0x170)][_0x461aef(0x1af)](_0x3c97cd[_0x461aef(0x182)],_0x3c97cd),this[_0x461aef(0x1bc)](_0x461aef(0x1cd),{'contextItem':_0x3c97cd,'isLoading':!0x1});}async[_0x27a96b(0x1c3)](_0xf10e93,_0x8ac118,_0x25b05d){const _0x3c5b7d=_0x27a96b,_0x4022c0=this[_0x3c5b7d(0x160)][_0x3c5b7d(0x16c)][_0x3c5b7d(0x19e)](_0x373b9b=>_0x373b9b['id']===_0xf10e93);if(!_0x4022c0)return this[_0x3c5b7d(0x1bc)](_0x3c5b7d(0x151),{'error':new _0x96d3b4(_0x3c5b7d(0x1a5),this,{'sourceId':_0xf10e93}),'sourceId':_0xf10e93}),[];try{const _0x3db0ce=(await _0x4022c0[_0x3c5b7d(0x1c0)](_0x8ac118))[_0x3c5b7d(0x162)](_0x3173f1=>{const _0x3fbc84=_0x3c5b7d,_0x412171=this[_0x3fbc84(0x15b)](_0x3173f1['id']);return{..._0x3173f1,'isInContext':_0x412171};});return _0x4022c0[_0x3c5b7d(0x188)]=_0x3db0ce,this[_0x3c5b7d(0x1bc)](_0x3c5b7d(0x1c5),{'sourceId':_0xf10e93,'source':_0x4022c0,'resources':_0x3db0ce,'uid':_0x25b05d}),_0x3db0ce;}catch(_0x265ded){return this[_0x3c5b7d(0x1bc)](_0x3c5b7d(0x151),{'error':new _0x96d3b4(_0x3c5b7d(0x15f),this,{'sourceId':_0xf10e93,'originalError':_0x265ded}),'sourceId':_0xf10e93,'sourceLabel':_0x4022c0[_0x3c5b7d(0x18f)]}),[];}}async[_0x27a96b(0x15d)](_0x2fb7a8,_0x382939){const _0x36c95e=_0x27a96b;if(this[_0x36c95e(0x15b)](_0x382939['id']))return;let _0x1c953b=_0x382939[_0x36c95e(0x15c)];if(!_0x1c953b&&_0x2fb7a8[_0x36c95e(0x1c4)])try{_0x1c953b=await _0x2fb7a8[_0x36c95e(0x1c4)](_0x382939['id']);}catch(_0x9f66e1){return void this[_0x36c95e(0x1bc)](_0x36c95e(0x151),{'error':new _0x96d3b4(_0x36c95e(0x161),this,{'resourceId':_0x382939['id'],'sourceId':_0x2fb7a8['id'],'originalError':_0x9f66e1}),'resourceId':_0x382939['id'],'sourceId':_0x2fb7a8['id']});}if(_0x1c953b)switch(_0x382939[_0x36c95e(0x158)]){case _0x4c0c19[_0x36c95e(0x17c)]:if(_0x36c95e(0x19d)!=typeof _0x1c953b)return void this[_0x36c95e(0x1bc)](_0x36c95e(0x151),{'error':new _0x96d3b4(_0x36c95e(0x1c1),this,{'resourceId':_0x382939['id'],'sourceId':_0x2fb7a8['id'],'expectedType':_0x36c95e(0x19d),'actualType':typeof _0x1c953b}),'resourceId':_0x382939['id'],'sourceId':_0x2fb7a8['id']});await this[_0x36c95e(0x18d)](_0x1c953b,{'label':_0x382939[_0x36c95e(0x18f)],'resourceId':_0x382939['id']});break;case _0x4c0c19[_0x36c95e(0x1b4)]:if(!(_0x1c953b instanceof File))return void this[_0x36c95e(0x1bc)](_0x36c95e(0x151),{'error':new _0x96d3b4(_0x36c95e(0x1c1),this,{'resourceId':_0x382939['id'],'sourceId':_0x2fb7a8['id'],'expectedType':_0x36c95e(0x15a),'actualType':typeof _0x1c953b}),'resourceId':_0x382939['id'],'sourceId':_0x2fb7a8['id']});await this[_0x36c95e(0x1b2)]([_0x1c953b],{'label':_0x382939[_0x36c95e(0x18f)],'resourceId':_0x382939['id']});break;case _0x4c0c19[_0x36c95e(0x1d8)]:if(_0x36c95e(0x1d0)!=typeof _0x1c953b||!(_0x36c95e(0x1ba)in _0x1c953b)||!(_0x36c95e(0x158)in _0x1c953b))return void this[_0x36c95e(0x1bc)](_0x36c95e(0x151),{'error':new _0x96d3b4(_0x36c95e(0x1c1),this,{'resourceId':_0x382939['id'],'sourceId':_0x2fb7a8['id'],'expectedType':_0x36c95e(0x1d2),'actualType':typeof _0x1c953b}),'resourceId':_0x382939['id'],'sourceId':_0x2fb7a8['id']});_0x1c953b=AIChatContext[_0x36c95e(0x199)](_0x1c953b,_0x382939[_0x36c95e(0x18f)]),await this[_0x36c95e(0x1b2)]([_0x1c953b],{'label':_0x382939[_0x36c95e(0x18f)],'resourceId':_0x382939['id']},_0x4c0c19[_0x36c95e(0x1d8)]);break;case _0x4c0c19[_0x36c95e(0x147)]:break;default:this[_0x36c95e(0x1bc)](_0x36c95e(0x151),{'error':new _0x96d3b4(_0x36c95e(0x183),this,{'resourceId':_0x382939['id'],'sourceId':_0x2fb7a8['id'],'resourceType':_0x382939[_0x36c95e(0x158)]}),'resourceId':_0x382939['id'],'sourceId':_0x2fb7a8['id']});}else this[_0x36c95e(0x1bc)](_0x36c95e(0x151),{'error':new _0x96d3b4(_0x36c95e(0x1ab),this,{'resourceId':_0x382939['id'],'sourceId':_0x2fb7a8['id']}),'resourceId':_0x382939['id'],'sourceId':_0x2fb7a8['id']});}static[_0x27a96b(0x199)](_0x42803f,_0x6369fa){const _0x1ba4b5=_0x27a96b;switch(_0x42803f[_0x1ba4b5(0x158)]){case _0x203c83[_0x1ba4b5(0x194)]:return new File([_0x42803f[_0x1ba4b5(0x1ba)]],_0x6369fa,{'type':_0x1ba4b5(0x146)});case _0x203c83[_0x1ba4b5(0x18e)]:return new File([_0x42803f[_0x1ba4b5(0x1ba)]],_0x6369fa,{'type':_0x1ba4b5(0x16b)});default:return new File([_0x42803f[_0x1ba4b5(0x1ba)]],_0x6369fa,{'type':_0x1ba4b5(0x17e)});}}static[_0x27a96b(0x157)](_0x115e53){const _0x193871=_0x27a96b;switch(_0x115e53[_0x193871(0x158)]){case _0x4c0c19[_0x193871(0x1b4)]:return{'type':_0x4c0c19[_0x193871(0x1b4)],'id':_0x115e53['id']};case _0x4c0c19[_0x193871(0x17c)]:return{'type':_0x4c0c19[_0x193871(0x17c)],'id':_0x115e53['id']};case _0x4c0c19[_0x193871(0x174)]:return{'type':_0x4c0c19[_0x193871(0x174)],'id':_0x115e53['id'],..._0x115e53[_0x193871(0x150)]?.[_0x193871(0x18a)]&&{'selection':_0x115e53[_0x193871(0x150)]}};case _0x4c0c19[_0x193871(0x1d8)]:return{'type':_0x4c0c19[_0x193871(0x1b4)],'id':_0x115e53['id']};case _0x4c0c19[_0x193871(0x147)]:{const _0x3a2ec7=_0x115e53;return{'type':_0x4c0c19[_0x193871(0x147)],'mcpServerName':_0x3a2ec7[_0x193871(0x1d4)],'toolName':_0x3a2ec7[_0x193871(0x186)],'data':_0x3a2ec7[_0x193871(0x15c)],'id':_0x3a2ec7['id']};}default:return null;}}[_0x27a96b(0x176)](_0x1c8e48,_0x22f3f2=!0x1){const _0x134f94=_0x27a96b;if(this[_0x134f94(0x170)][_0x134f94(0x1af)](_0x1c8e48[_0x134f94(0x182)],_0x1c8e48),_0x1c8e48[_0x134f94(0x165)]||this[_0x134f94(0x1bc)](_0x134f94(0x1cd),{'contextItem':_0x1c8e48,'isLoading':_0x22f3f2}),_0x134f94(0x1c6)===_0x1c8e48[_0x134f94(0x182)]&&this[_0x134f94(0x1be)](),_0x1c8e48[_0x134f94(0x1b8)]){const _0xe7b072=this[_0x134f94(0x16d)](_0x1c8e48[_0x134f94(0x1b8)]);_0xe7b072&&_0xe7b072[_0x134f94(0x1a9)](_0x5d9541=>{const _0x5646dc=_0x134f94;this[_0x5646dc(0x15e)](_0x5d9541,_0x1c8e48[_0x5646dc(0x1b8)],!0x0);});}}[_0x27a96b(0x1c8)](_0x26687f){const _0x268e47=_0x27a96b,_0x4963aa=this[_0x268e47(0x170)][_0x268e47(0x14f)](_0x26687f),_0x559340=this[_0x268e47(0x175)][_0x268e47(0x14f)](_0x26687f);if(_0x559340&&(_0x559340[_0x268e47(0x1a3)](),this[_0x268e47(0x175)][_0x268e47(0x17a)](_0x26687f)),_0x4963aa?.[_0x268e47(0x1b8)]){const _0x40294a=this[_0x268e47(0x16d)](_0x4963aa[_0x268e47(0x1b8)]);_0x40294a&&_0x40294a[_0x268e47(0x1a9)](_0x13811d=>{const _0x5130f3=_0x268e47;this[_0x5130f3(0x15e)](_0x13811d,_0x4963aa[_0x5130f3(0x1b8)],!0x1);});}this[_0x268e47(0x170)][_0x268e47(0x17a)](_0x26687f),this[_0x268e47(0x1bc)](_0x268e47(0x168),{'uiId':_0x26687f,'type':_0x4963aa?.[_0x268e47(0x158)]}),_0x268e47(0x1c6)===_0x26687f&&this[_0x268e47(0x1be)]();}[_0x27a96b(0x1ca)](_0x1c2790,_0x33b368){const _0x3123fc=_0x27a96b;if(this[_0x3123fc(0x170)][_0x3123fc(0x1b7)](_0x1c2790[_0x3123fc(0x182)])&&(this[_0x3123fc(0x170)][_0x3123fc(0x1af)](_0x1c2790[_0x3123fc(0x182)],_0x1c2790),this[_0x3123fc(0x1bc)](_0x3123fc(0x1b3),{'contextItem':_0x1c2790,'isLoading':_0x33b368}),_0x1c2790[_0x3123fc(0x1b8)])){const _0xfd800f=this[_0x3123fc(0x16d)](_0x1c2790[_0x3123fc(0x1b8)]);_0xfd800f&&_0xfd800f[_0x3123fc(0x1a9)](_0x5f3f78=>{const _0x15b375=_0x3123fc;this[_0x15b375(0x15e)](_0x5f3f78,_0x1c2790[_0x15b375(0x1b8)],!0x0);});}}[_0x27a96b(0x1c9)](_0xc29fef){const _0x45b84b=_0x27a96b;this[_0x45b84b(0x1d1)][_0x45b84b(0x1af)](_0xc29fef[_0x45b84b(0x182)],_0xc29fef);}[_0x27a96b(0x1c2)](){const _0x485986=_0x27a96b;this[_0x485986(0x160)]={'document':{'enabled':!0x1!==this[_0x485986(0x145)]?.[_0x485986(0x1b9)]?.[_0x485986(0x178)],'isHidden':!0x1},'urls':{'enabled':!0x1!==this[_0x485986(0x145)]?.[_0x485986(0x18b)]?.[_0x485986(0x178)]},'files':{'enabled':!0x1!==this[_0x485986(0x145)]?.[_0x485986(0x190)]?.[_0x485986(0x178)]},'sources':this[_0x485986(0x1b6)](),'customItems':this[_0x485986(0x145)]?.[_0x485986(0x1bd)]?.[_0x485986(0x162)](_0x28fc17=>({..._0x28fc17,'enabled':!0x0}))??[]},this[_0x485986(0x1bc)](_0x485986(0x169),{'options':this[_0x485986(0x160)]});}[_0x27a96b(0x1b6)](){const _0x4ce1b0=_0x27a96b;return this[_0x4ce1b0(0x145)]?.[_0x4ce1b0(0x16c)]?.[_0x4ce1b0(0x162)](_0x317708=>({..._0x317708,'resources':[]}))??[];}[_0x27a96b(0x1be)](){const _0x5d892f=_0x27a96b,_0x4f2626=this[_0x5d892f(0x16f)]()||this[_0x5d892f(0x164)]();this[_0x5d892f(0x160)][_0x5d892f(0x1b9)][_0x5d892f(0x14c)]=_0x4f2626,this[_0x5d892f(0x1bc)](_0x5d892f(0x169),{'options':this[_0x5d892f(0x160)]});}[_0x27a96b(0x15b)](_0x3dfa2a){const _0x2cada9=_0x27a96b;for(const _0x1e3c76 of this[_0x2cada9(0x170)][_0x2cada9(0x191)]())if(_0x1e3c76[_0x2cada9(0x1b8)]===_0x3dfa2a)return!0x0;for(const _0xec7e6b of this[_0x2cada9(0x1d1)][_0x2cada9(0x191)]())if(_0xec7e6b[_0x2cada9(0x1b8)]===_0x3dfa2a)return!0x0;return!0x1;}[_0x27a96b(0x16d)](_0x8e736a){const _0x1b201c=_0x27a96b,_0x54958f=[];for(const _0x350631 of this[_0x1b201c(0x160)][_0x1b201c(0x16c)]){_0x350631[_0x1b201c(0x188)][_0x1b201c(0x19e)](_0x522b85=>_0x522b85['id']===_0x8e736a)&&_0x54958f[_0x1b201c(0x1b0)](_0x350631['id']);}return 0x0===_0x54958f[_0x1b201c(0x18a)]?null:_0x54958f;}[_0x27a96b(0x15e)](_0x918438,_0x14aa37,_0x2ad1d2){const _0xf7a949=_0x27a96b,_0x62c76b=this[_0xf7a949(0x160)][_0xf7a949(0x16c)][_0xf7a949(0x19e)](_0x3f1ae3=>_0x3f1ae3['id']===_0x918438);if(!_0x62c76b)return;const _0x84f3a7=_0x62c76b[_0xf7a949(0x188)][_0xf7a949(0x19e)](_0x50f353=>_0x50f353['id']===_0x14aa37);_0x84f3a7&&(_0x84f3a7[_0xf7a949(0x184)]=_0x2ad1d2,this[_0xf7a949(0x1bc)](_0xf7a949(0x14d),{'sourceId':_0x918438,'resourceId':_0x14aa37,'isInContext':_0x2ad1d2}));}[_0x27a96b(0x1a7)](_0x12e176){const _0x4e85ed=_0x27a96b;this[_0x4e85ed(0x154)][_0x4e85ed(0x1af)](_0x12e176,!0x0),this[_0x4e85ed(0x154)][_0x4e85ed(0x1b1)]&&this[_0x4e85ed(0x1bc)](_0x4e85ed(0x1b5),{'isUploadInProgress':!0x0});}[_0x27a96b(0x1d5)](_0x4eb162){const _0x244b71=_0x27a96b;this[_0x244b71(0x154)][_0x244b71(0x17a)](_0x4eb162),0x0===this[_0x244b71(0x154)][_0x244b71(0x1b1)]&&this[_0x244b71(0x1bc)](_0x244b71(0x1b5),{'isUploadInProgress':!0x1});}}