@ckeditor/ckeditor5-ai 47.0.0-alpha.8 → 47.0.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.
- package/build/ai.js +1 -1
- package/dist/index.js +4 -4
- package/dist/translations/af.js +1 -1
- package/dist/translations/af.umd.js +1 -1
- package/dist/translations/ar.js +1 -1
- package/dist/translations/ar.umd.js +1 -1
- package/dist/translations/ast.js +1 -1
- package/dist/translations/ast.umd.js +1 -1
- package/dist/translations/az.js +1 -1
- package/dist/translations/az.umd.js +1 -1
- package/dist/translations/be.js +1 -1
- package/dist/translations/be.umd.js +1 -1
- package/dist/translations/bg.js +1 -1
- package/dist/translations/bg.umd.js +1 -1
- package/dist/translations/bn.js +1 -1
- package/dist/translations/bn.umd.js +1 -1
- package/dist/translations/bs.js +1 -1
- package/dist/translations/bs.umd.js +1 -1
- package/dist/translations/ca.js +1 -1
- package/dist/translations/ca.umd.js +1 -1
- package/dist/translations/cs.js +1 -1
- package/dist/translations/cs.umd.js +1 -1
- package/dist/translations/da.js +1 -1
- package/dist/translations/da.umd.js +1 -1
- package/dist/translations/de-ch.js +1 -1
- package/dist/translations/de-ch.umd.js +1 -1
- package/dist/translations/de.js +1 -1
- package/dist/translations/de.umd.js +1 -1
- package/dist/translations/el.js +1 -1
- package/dist/translations/el.umd.js +1 -1
- package/dist/translations/en-au.js +1 -1
- package/dist/translations/en-au.umd.js +1 -1
- package/dist/translations/en-gb.js +1 -1
- package/dist/translations/en-gb.umd.js +1 -1
- package/dist/translations/en.js +1 -1
- package/dist/translations/en.umd.js +1 -1
- package/dist/translations/eo.js +1 -1
- package/dist/translations/eo.umd.js +1 -1
- package/dist/translations/es-co.js +1 -1
- package/dist/translations/es-co.umd.js +1 -1
- package/dist/translations/es.js +1 -1
- package/dist/translations/es.umd.js +1 -1
- package/dist/translations/et.js +1 -1
- package/dist/translations/et.umd.js +1 -1
- package/dist/translations/eu.js +1 -1
- package/dist/translations/eu.umd.js +1 -1
- package/dist/translations/fa.js +1 -1
- package/dist/translations/fa.umd.js +1 -1
- package/dist/translations/fi.js +1 -1
- package/dist/translations/fi.umd.js +1 -1
- package/dist/translations/fr.js +1 -1
- package/dist/translations/fr.umd.js +1 -1
- package/dist/translations/gl.js +1 -1
- package/dist/translations/gl.umd.js +1 -1
- package/dist/translations/gu.js +1 -1
- package/dist/translations/gu.umd.js +1 -1
- package/dist/translations/he.js +1 -1
- package/dist/translations/he.umd.js +1 -1
- package/dist/translations/hi.js +1 -1
- package/dist/translations/hi.umd.js +1 -1
- package/dist/translations/hr.js +1 -1
- package/dist/translations/hr.umd.js +1 -1
- package/dist/translations/hu.js +1 -1
- package/dist/translations/hu.umd.js +1 -1
- package/dist/translations/hy.js +1 -1
- package/dist/translations/hy.umd.js +1 -1
- package/dist/translations/id.js +1 -1
- package/dist/translations/id.umd.js +1 -1
- package/dist/translations/it.js +1 -1
- package/dist/translations/it.umd.js +1 -1
- package/dist/translations/ja.js +1 -1
- package/dist/translations/ja.umd.js +1 -1
- package/dist/translations/jv.js +1 -1
- package/dist/translations/jv.umd.js +1 -1
- package/dist/translations/kk.js +1 -1
- package/dist/translations/kk.umd.js +1 -1
- package/dist/translations/km.js +1 -1
- package/dist/translations/km.umd.js +1 -1
- package/dist/translations/kn.js +1 -1
- package/dist/translations/kn.umd.js +1 -1
- package/dist/translations/ko.js +1 -1
- package/dist/translations/ko.umd.js +1 -1
- package/dist/translations/ku.js +1 -1
- package/dist/translations/ku.umd.js +1 -1
- package/dist/translations/lt.js +1 -1
- package/dist/translations/lt.umd.js +1 -1
- package/dist/translations/lv.js +1 -1
- package/dist/translations/lv.umd.js +1 -1
- package/dist/translations/ms.js +1 -1
- package/dist/translations/ms.umd.js +1 -1
- package/dist/translations/nb.js +1 -1
- package/dist/translations/nb.umd.js +1 -1
- package/dist/translations/ne.js +1 -1
- package/dist/translations/ne.umd.js +1 -1
- package/dist/translations/nl.js +1 -1
- package/dist/translations/nl.umd.js +1 -1
- package/dist/translations/no.js +1 -1
- package/dist/translations/no.umd.js +1 -1
- package/dist/translations/oc.js +1 -1
- package/dist/translations/oc.umd.js +1 -1
- package/dist/translations/pl.js +1 -1
- package/dist/translations/pl.umd.js +1 -1
- package/dist/translations/pt-br.js +1 -1
- package/dist/translations/pt-br.umd.js +1 -1
- package/dist/translations/pt.js +1 -1
- package/dist/translations/pt.umd.js +1 -1
- package/dist/translations/ro.js +1 -1
- package/dist/translations/ro.umd.js +1 -1
- package/dist/translations/ru.js +1 -1
- package/dist/translations/ru.umd.js +1 -1
- package/dist/translations/si.js +1 -1
- package/dist/translations/si.umd.js +1 -1
- package/dist/translations/sk.js +1 -1
- package/dist/translations/sk.umd.js +1 -1
- package/dist/translations/sl.js +1 -1
- package/dist/translations/sl.umd.js +1 -1
- package/dist/translations/sq.js +1 -1
- package/dist/translations/sq.umd.js +1 -1
- package/dist/translations/sr-latn.js +1 -1
- package/dist/translations/sr-latn.umd.js +1 -1
- package/dist/translations/sr.js +1 -1
- package/dist/translations/sr.umd.js +1 -1
- package/dist/translations/sv.js +1 -1
- package/dist/translations/sv.umd.js +1 -1
- package/dist/translations/th.js +1 -1
- package/dist/translations/th.umd.js +1 -1
- package/dist/translations/ti.js +1 -1
- package/dist/translations/ti.umd.js +1 -1
- package/dist/translations/tk.js +1 -1
- package/dist/translations/tk.umd.js +1 -1
- package/dist/translations/tr.js +1 -1
- package/dist/translations/tr.umd.js +1 -1
- package/dist/translations/tt.js +1 -1
- package/dist/translations/tt.umd.js +1 -1
- package/dist/translations/ug.js +1 -1
- package/dist/translations/ug.umd.js +1 -1
- package/dist/translations/uk.js +1 -1
- package/dist/translations/uk.umd.js +1 -1
- package/dist/translations/ur.js +1 -1
- package/dist/translations/ur.umd.js +1 -1
- package/dist/translations/uz.js +1 -1
- package/dist/translations/uz.umd.js +1 -1
- package/dist/translations/vi.js +1 -1
- package/dist/translations/vi.umd.js +1 -1
- package/dist/translations/zh-cn.js +1 -1
- package/dist/translations/zh-cn.umd.js +1 -1
- package/dist/translations/zh.js +1 -1
- package/dist/translations/zh.umd.js +1 -1
- package/package.json +15 -15
- package/src/aiactions/aiactions.js +1 -1
- package/src/aiactions/model/aiactionsinteraction.js +1 -1
- package/src/aiactions/model/aiactionsreply.js +1 -1
- package/src/aiassistant/adapters/aiadapter.js +1 -1
- package/src/aiassistant/adapters/aitextadapter.js +1 -1
- package/src/aiassistant/adapters/awstextadapter.js +1 -1
- package/src/aiassistant/adapters/openaitextadapter.js +1 -1
- package/src/aiassistant/aiassistant.js +1 -1
- package/src/aiassistant/aiassistantediting.js +1 -1
- package/src/aiassistant/aiassistantui.js +1 -1
- package/src/aiassistant/legacyerrors.js +1 -1
- package/src/aiassistant/ui/aiassistantcontroller.js +2 -2
- package/src/aiassistant/ui/form/aiformcontentarea.js +1 -1
- package/src/aiassistant/ui/form/aiformerrorview.js +1 -1
- package/src/aiassistant/ui/form/aiformpromptview.js +1 -1
- package/src/aiassistant/ui/form/aiformtoolbarview.js +1 -1
- package/src/aiassistant/ui/form/aiformview.js +1 -1
- package/src/aiassistant/ui/form/aihistorylistitemview.js +1 -1
- package/src/aiassistant/ui/form/aihistorylistview.js +1 -1
- package/src/aiassistant/ui/form/prompthistory.js +1 -1
- package/src/aiassistant/ui/showaiassistantcommand.js +1 -1
- package/src/aiassistant/utils/common-translations.js +1 -1
- package/src/aiassistant/utils/normalizecommandsconfig.js +1 -1
- package/src/aiballoon/aiballoon.js +1 -1
- package/src/aiballoon/ui/aiballoondisclaimerview.js +1 -1
- package/src/aiballoon/ui/aiballoontoolbarview.js +1 -1
- package/src/aiballoon/ui/aiballoonview.js +1 -1
- package/src/aichat/aichat.js +1 -1
- package/src/aichat/aichatcontroller.js +1 -1
- package/src/aichat/aichatui.js +1 -1
- package/src/aichat/model/aichatcontext.d.ts +197 -1
- package/src/aichat/model/aichatcontext.js +1 -1
- package/src/aichat/model/aichatconversation.js +1 -1
- package/src/aichat/model/aichatinteraction.js +1 -1
- package/src/aichat/model/aichatmodels.d.ts +30 -0
- package/src/aichat/model/aichatmodels.js +1 -1
- package/src/aichat/ui/aichatcontrolsview.js +1 -1
- package/src/aichat/ui/aichatfeedview.js +1 -1
- package/src/aichat/ui/aichatheaderview.js +1 -1
- package/src/aichat/ui/aichatview.js +1 -1
- package/src/aichat/ui/controls/aichatchipsoverflowmanager.js +1 -1
- package/src/aichat/ui/controls/aichatcontextitembuttonview.js +1 -1
- package/src/aichat/ui/controls/aichatcontextpanelurlinputview.js +1 -1
- package/src/aichat/ui/controls/aichatcontextpanelview.js +1 -1
- package/src/aichat/ui/controls/aichatcontrolsloaderview.js +1 -1
- package/src/aichat/ui/controls/aichatpromptcapabilitiesview.js +1 -1
- package/src/aichat/ui/controls/aichatpromptinputview.js +1 -1
- package/src/aichat/ui/controls/aichatpromptsuggestionslistview.js +1 -1
- package/src/aichat/ui/controls/resources/aichatresourcelistitemview.js +1 -1
- package/src/aichat/ui/controls/resources/aichatresourcesballoonview.js +1 -1
- package/src/aichat/ui/controls/resources/aichatresourceslistview.js +1 -1
- package/src/aichat/ui/controls/resources/aichatresourcessearchinputview.js +1 -1
- package/src/aichat/ui/controls/resources/aichatresourcesview.js +1 -1
- package/src/aichat/ui/feed/aichatfeedcontextchipsview.js +1 -1
- package/src/aichat/ui/feed/aichatfeederroritemview.js +1 -1
- package/src/aichat/ui/feed/aichatfeedinteractionheaderview.js +1 -1
- package/src/aichat/ui/feed/aichatfeeditemview.js +1 -1
- package/src/aichat/ui/feed/aichatfeedreplyitemview.js +1 -1
- package/src/aichat/ui/feed/aichatfeedsuggestionitemactionsview.js +1 -1
- package/src/aichat/ui/feed/aichatfeedsuggestionitemview.js +1 -1
- package/src/aichat/ui/feed/aichatfeedusermessageitem.js +1 -1
- package/src/aichat/utils/eventnames.js +1 -1
- package/src/aichat/utils/promisequeue.js +1 -1
- package/src/aichat/utils/scrollmanager.js +1 -1
- package/src/aichathistory/aichathistory.js +1 -1
- package/src/aichathistory/aichathistorycontroller.js +1 -1
- package/src/aichathistory/aichathistoryui.js +1 -1
- package/src/aichathistory/model/aichathistoryconversations.js +1 -1
- package/src/aichathistory/model/aichathistoryitem.js +1 -1
- package/src/aichathistory/ui/aichathistorylistitemview.js +1 -1
- package/src/aichathistory/ui/aichathistorylistview.js +1 -1
- package/src/aichathistory/ui/aichathistorysectionlistview.js +1 -1
- package/src/aichathistory/ui/aichathistoryview.js +1 -1
- package/src/aicore/aiconnector.js +1 -1
- package/src/aicore/aiediting.js +1 -1
- package/src/aicore/model/aicapabilities.js +1 -1
- package/src/aicore/model/aicontext.js +1 -1
- package/src/aicore/model/aiinteraction.js +1 -1
- package/src/aicore/model/aireply.js +1 -1
- package/src/aicore/pipeline/airesponseapplier.js +2 -2
- package/src/aicore/pipeline/airesponseparser.js +2 -2
- package/src/aicore/ui/aidisclaimerview.js +1 -1
- package/src/aicore/ui/aiskeleton.js +1 -1
- package/src/aicore/ui/aispinner.js +1 -1
- package/src/aicore/ui/suggestioncontainer/aiminitoolbarview.js +1 -1
- package/src/aicore/ui/suggestioncontainer/aisuggestionbodyview.js +1 -1
- package/src/aicore/ui/suggestioncontainer/aisuggestioncontainerview.js +1 -1
- package/src/aicore/ui/suggestioncontainer/aisuggestioncontentpartview.js +1 -1
- package/src/aicore/ui/suggestioncontainer/aisuggestionheaderview.js +1 -1
- package/src/aicore/utils/common-translations.js +1 -1
- package/src/aicore/utils/createresizebutton.js +1 -1
- package/src/aicore/utils/documentposition.js +1 -1
- package/src/aicore/utils/documentrange.js +1 -1
- package/src/aicore/utils/eventnames.js +1 -1
- package/src/aicore/utils/geteditorfromcontext.js +1 -1
- package/src/aicore/utils/getoperationsfromreply.js +1 -1
- package/src/aicore/utils/getsuggestionpartsfromreply.js +1 -1
- package/src/aicore/utils/htmlparser.js +1 -1
- package/src/aicore/utils/htmlstreamer.js +1 -1
- package/src/aieditorintegration/aieditorintegration.js +1 -1
- package/src/aieditorintegration/aitogglebutton/aitogglebuttonui.js +1 -1
- package/src/aieditorintegration/aitogglebutton/toggleaicommand.js +1 -1
- package/src/aiquickactions/aiquickactions.d.ts +1 -0
- package/src/aiquickactions/aiquickactions.js +1 -1
- package/src/aiquickactions/aiquickactionscommand.js +1 -1
- package/src/aiquickactions/aiquickactionsediting.js +1 -1
- package/src/aiquickactions/aiquickactionsui.d.ts +49 -0
- package/src/aiquickactions/aiquickactionsui.js +1 -1
- package/src/aiquickactions/ui/aiquickactionsbuttoncreator.js +1 -1
- package/src/aiquickactions/ui/aiquickactionsdropdowncontentview.js +1 -1
- package/src/aiquickactions/ui/aiquickactionsdropdowncreator.js +1 -1
- package/src/aireviewmode/aireviewcheckdefinitions.js +1 -1
- package/src/aireviewmode/aireviewmode.js +1 -1
- package/src/aireviewmode/aireviewmodecontroller.js +1 -1
- package/src/aireviewmode/aireviewmodeediting.js +1 -1
- package/src/aireviewmode/aireviewmodeui.js +1 -1
- package/src/aireviewmode/model/aireviewcheck.js +1 -1
- package/src/aireviewmode/model/aireviewcheckcustom.js +1 -1
- package/src/aireviewmode/model/aireviewchecklist.js +1 -1
- package/src/aireviewmode/model/aireviewcheckresult.js +1 -1
- package/src/aireviewmode/model/aireviewcheckresultchange.js +1 -1
- package/src/aireviewmode/model/aireviewcheckrun.js +1 -1
- package/src/aireviewmode/model/aireviewcustomcheckrun.js +1 -1
- package/src/aireviewmode/model/aireviewmodels.js +1 -1
- package/src/aireviewmode/model/aireviewsystemcheckrun.js +1 -1
- package/src/aireviewmode/ui/aireviemodepromptinputview.js +1 -1
- package/src/aireviewmode/ui/aireviewmodeballoonsuggestionview.js +1 -1
- package/src/aireviewmode/ui/aireviewmodechecklistitemresultview.js +1 -1
- package/src/aireviewmode/ui/aireviewmodecustomcheckview.js +1 -1
- package/src/aireviewmode/ui/aireviewmodereviewchecklistview.js +1 -1
- package/src/aireviewmode/ui/aireviewmodereviewcheckresultsview.js +1 -1
- package/src/aireviewmode/ui/aireviewmodereviewcommandlistitemview.js +1 -1
- package/src/aireviewmode/ui/aireviewmodereviewcompletedview.js +1 -1
- package/src/aireviewmode/ui/aireviewmodeview.js +1 -1
- package/src/aireviewmode/ui/form/aireviewmodeformamanager.js +1 -1
- package/src/aireviewmode/ui/form/aireviewmodeformdropdown.js +1 -1
- package/src/aireviewmode/ui/form/aireviewmodeformmanager.js +1 -1
- package/src/aitabs/aitabs.d.ts +14 -0
- package/src/aitabs/aitabs.js +1 -1
- package/src/aitabs/aitabsmainview.js +1 -1
- package/src/aitabs/tabs/aitabsview.js +1 -1
- package/src/aitabs/tabs/tabbuttonview.js +1 -1
- package/src/aitabs/tabs/tabpanelview.js +1 -1
- package/src/index.js +1 -1
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const _0x45e5cc=_0x2cf0;(function(_0x29a380,_0x4cd4b2){const _0x4e1b81=_0x2cf0,_0x3bdccf=_0x29a380();while(!![]){try{const _0x20a984=parseInt(_0x4e1b81(0x1bf))/0x1+-parseInt(_0x4e1b81(0x220))/0x2*(-parseInt(_0x4e1b81(0x17e))/0x3)+-parseInt(_0x4e1b81(0x254))/0x4+-parseInt(_0x4e1b81(0x1c5))/0x5+parseInt(_0x4e1b81(0x19f))/0x6*(parseInt(_0x4e1b81(0x1d1))/0x7)+parseInt(_0x4e1b81(0x1dc))/0x8+parseInt(_0x4e1b81(0x216))/0x9;if(_0x20a984===_0x4cd4b2)break;else _0x3bdccf['push'](_0x3bdccf['shift']());}catch(_0x3fc9f6){_0x3bdccf['push'](_0x3bdccf['shift']());}}}(_0x344d,0xac185));import{ContextPlugin as _0x3158cb,Editor as _0x3918b3}from'ckeditor5/src/core.js';import{CKEditorError as _0x16faf9,logError as _0x50a61f,scrollViewportToShowTarget as _0x2339dd,uid as _0x2d2414}from'ckeditor5/src/utils.js';import{AIConnector as _0x234755}from'../aicore/aiconnector.js';import{AITabs as _0x2cb794}from'../aitabs/aitabs.js';import{AIChatConversation as _0x28056c}from'./model/aichatconversation.js';import{getTranslation as _0x3dfaa9}from'../aicore/utils/common-translations.js';import{AI_VISUAL_SELECTION_MARKER_NAME as _0x38ead6}from'../aicore/aiediting.js';import{AIChatModels as _0x47dfa3}from'./model/aichatmodels.js';function _0x2cf0(_0x37b36a,_0x4ac155){const _0x344d49=_0x344d();return _0x2cf0=function(_0x2cf0ab,_0x17a7ec){_0x2cf0ab=_0x2cf0ab-0x177;let _0xb26161=_0x344d49[_0x2cf0ab];return _0xb26161;},_0x2cf0(_0x37b36a,_0x4ac155);}import{getEditorFromContext as _0x3cc6c6}from'../aicore/utils/geteditorfromcontext.js';import{DocumentCompare as _0x151f22,DATA_ID_MODEL_ATTRIBUTE as _0x39eb9b}from'@ckeditor/ckeditor5-collaboration-core';import{getOperationsFromReply as _0x27c536}from'../aicore/utils/getoperationsfromreply.js';import{expandSelectionWithContext as _0x16a2b5,getMinimalSelection as _0x1d20c2,getSuggestionPartsFromReply as _0x1a511c}from'../aicore/utils/getsuggestionpartsfromreply.js';import{ModelRange as _0x503dc3,_DetachOperation as _0x10e379}from'ckeditor5/src/engine.js';import{findOne as _0x2327f3,getAttribute as _0x2777d2,serialize as _0x30a863,Document as _0x284939,findByAttribute as _0x5885d0}from'../aicore/utils/htmlparser.js';import{IconAI as _0xf4914d}from'@ckeditor/ckeditor5-icons';import{AISuggestionContainerView as _0x2c138a}from'../aicore/ui/suggestioncontainer/aisuggestioncontainerview.js';import{AIBalloon as _0x385be5}from'../aiballoon/aiballoon.js';export class AIChatController extends _0x3158cb{[_0x45e5cc(0x204)];[_0x45e5cc(0x2b3)];[_0x45e5cc(0x24f)];[_0x45e5cc(0x1ef)];[_0x45e5cc(0x235)]=new Map();[_0x45e5cc(0x27c)]=null;[_0x45e5cc(0x2ab)]=!0x1;static get[_0x45e5cc(0x1a3)](){return[_0x234755,_0x385be5,_0x151f22];}static get[_0x45e5cc(0x269)](){const _0x4e3a0c=_0x45e5cc;return _0x4e3a0c(0x237);}static get[_0x45e5cc(0x28c)](){return!0x0;}static get[_0x45e5cc(0x1a8)](){return!0x0;}[_0x45e5cc(0x282)](){const _0x153806=_0x45e5cc;this[_0x153806(0x2b3)]=this[_0x153806(0x251)][_0x153806(0x26b)][_0x153806(0x191)](_0x153806(0x2ca)),this[_0x153806(0x24f)]=this[_0x153806(0x251)][_0x153806(0x26b)][_0x153806(0x191)](_0x153806(0x2c9)),this[_0x153806(0x204)]=this[_0x153806(0x251)][_0x153806(0x26b)][_0x153806(0x191)](_0x153806(0x206)),this[_0x153806(0x1ef)]=new _0x47dfa3({'connector':this[_0x153806(0x2b3)]});const _0x23e263=this[_0x153806(0x251)][_0x153806(0x26b)][_0x153806(0x191)](_0x153806(0x1b9));this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x24e),()=>{const _0xe988ec=_0x153806;this[_0xe988ec(0x272)]();}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x22d),(_0x577c6f,_0x200b39)=>{const _0x2eace0=_0x153806;this[_0x2eace0(0x279)]({'userMessage':_0x200b39});}),this[_0x153806(0x262)](_0x23e263,_0x153806(0x2ad),(_0x328681,_0x570167)=>{const _0x50c604=_0x153806;this[_0x50c604(0x209)](_0x570167);}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x1da),()=>{const _0x3aecd8=_0x153806;_0x23e263[_0x3aecd8(0x222)]();}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x1f6),async()=>{const _0x4fc2e0=_0x153806;await this[_0x4fc2e0(0x218)](),await this[_0x4fc2e0(0x21f)]();}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x2bc),()=>{const _0x5aabf5=_0x153806;this[_0x5aabf5(0x1fe)]?.[_0x5aabf5(0x2a5)](_0x3dfaa9(this[_0x5aabf5(0x251)][_0x5aabf5(0x23c)],_0x5aabf5(0x29f)));}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x23e),(_0xd9d066,_0x48c912)=>{const _0x149efa=_0x153806;this[_0x149efa(0x1fe)]?.[_0x149efa(0x1f5)](Array[_0x149efa(0x1e3)](_0x48c912));}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x2a8),(_0x5174d5,_0xc8913)=>{const _0x4d2bc2=_0x153806;this[_0x4d2bc2(0x1fe)]?.[_0x4d2bc2(0x2a8)](_0xc8913);}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x1df),(_0x332678,_0x129e2d)=>{const _0x355777=_0x153806;this[_0x355777(0x1fe)]?.[_0x355777(0x1df)](_0x129e2d[_0x355777(0x184)],_0x129e2d[_0x355777(0x2c7)]);}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x1a7),(_0x1a1301,_0x5503ee)=>{const _0x39ba09=_0x153806;this[_0x39ba09(0x1d9)](_0x5503ee);}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x2be),(_0x247303,_0x772b06)=>{const _0x219a18=_0x153806;this[_0x219a18(0x1fe)]?.[_0x219a18(0x2be)](_0x772b06[_0x219a18(0x2a1)],_0x772b06[_0x219a18(0x270)],_0x772b06[_0x219a18(0x19e)]);}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x247),()=>{const _0x54a8ab=_0x153806;this[_0x54a8ab(0x1ac)]();}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x295),()=>{const _0x29eca4=_0x153806;this[_0x29eca4(0x1e7)]();}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x248),(_0x866eeb,_0x4b448f)=>{const _0x263ddb=_0x153806;this[_0x263ddb(0x1fe)]?.[_0x263ddb(0x2cc)](_0x4b448f);}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x18e),(_0x4a176a,{replyId:_0x5ed2fc})=>{const _0x479f94=_0x153806;console[_0x479f94(0x2b6)](_0x479f94(0x255),_0x5ed2fc);}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x1a6),(_0x1aa0e7,{replyId:_0x226a29})=>{const _0x29905a=_0x153806;console[_0x29905a(0x2b6)](_0x29905a(0x27b),_0x226a29);}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x2a2),(_0x1838a8,_0x398c21)=>{const _0x52b085=_0x153806;this[_0x52b085(0x251)][_0x52b085(0x26b)][_0x52b085(0x191)](_0x385be5)[_0x52b085(0x2b5)](),this[_0x52b085(0x21c)](_0x398c21);}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x224),(_0x3b5f46,{replyId:_0x83ac5b,partIndex:_0x5daf05})=>{const _0x255fa8=_0x153806;this[_0x255fa8(0x2ab)]=this[_0x255fa8(0x24f)][_0x255fa8(0x1b1)],this[_0x255fa8(0x17b)](_0x83ac5b,_0x5daf05);}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x186),(_0x380b7a,{replyId:_0x2df470,partIndex:_0x3f2c0a})=>{const _0x58cd64=_0x153806,_0x4835d9=this[_0x58cd64(0x1cf)](_0x2df470,_0x3f2c0a);_0x4835d9&&_0x58cd64(0x298)!=_0x4835d9[_0x58cd64(0x2b4)][_0x58cd64(0x2b9)][_0x58cd64(0x2ba)]&&this[_0x58cd64(0x204)][_0x58cd64(0x26e)]([_0x4835d9[_0x58cd64(0x2b4)]],_0x58cd64(0x213));}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x252),()=>{const _0x53c388=_0x153806;this[_0x53c388(0x204)][_0x53c388(0x260)](_0x53c388(0x213));}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x27d),(_0x4a4c3c,_0x3b2bdd)=>{const _0x5b0687=_0x153806;this[_0x5b0687(0x251)][_0x5b0687(0x26b)][_0x5b0687(0x191)](_0x385be5)[_0x5b0687(0x2b5)](),this[_0x5b0687(0x296)](_0x3b2bdd);}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x1b7),async(_0x27b229,_0x248dcd)=>{const _0x13f71a=_0x153806,{reply:_0x5366e9}=this[_0x13f71a(0x229)](_0x248dcd[_0x13f71a(0x1ee)]),_0x2f2d3b=_0x3cc6c6(this[_0x13f71a(0x251)]),_0x3b575e=_0x1a511c({'editor':_0x2f2d3b,'changeGroups':_0x5366e9[_0x13f71a(0x1f0)],'documentContextContent':_0x5366e9[_0x13f71a(0x18a)],'showDiff':_0x248dcd[_0x13f71a(0x1b1)]});await this[_0x13f71a(0x24f)][_0x13f71a(0x1b0)]({'id':_0x5366e9['id'],'parts':_0x3b575e,'renderingStrategy':_0x13f71a(0x20f)});}),this[_0x153806(0x262)](this[_0x153806(0x24f)],_0x153806(0x245),(_0x5d7bec,{replyId:_0x2c8095,partIndex:_0x14b468})=>{const _0x55bebd=_0x153806;this[_0x55bebd(0x27c)]?.[_0x55bebd(0x1ee)]==_0x2c8095&&this[_0x55bebd(0x27c)]?.[_0x55bebd(0x2bd)]==_0x14b468&&this[_0x55bebd(0x251)][_0x55bebd(0x26b)][_0x55bebd(0x191)](_0x385be5)[_0x55bebd(0x2b5)]();const {reply:_0x3c2009}=this[_0x55bebd(0x229)](_0x2c8095);_0x3c2009[_0x55bebd(0x1d2)](_0x14b468,_0x55bebd(0x1ae)),this[_0x55bebd(0x204)][_0x55bebd(0x260)](_0x55bebd(0x213));});}async[_0x45e5cc(0x1ab)](){const _0x3b2a44=_0x45e5cc;this[_0x3b2a44(0x251)]instanceof _0x3918b3?this[_0x3b2a44(0x29b)](this[_0x3b2a44(0x251)]):this[_0x3b2a44(0x262)](this[_0x3b2a44(0x251)][_0x3b2a44(0x280)],_0x3b2a44(0x240),(_0x285955,_0x3daca7)=>{const _0x15307f=_0x3b2a44;_0x3daca7['on'](_0x15307f(0x265),()=>{const _0x260eda=_0x15307f;this[_0x260eda(0x29b)](_0x3daca7);});}),await this[_0x3b2a44(0x272)]();}[_0x45e5cc(0x21c)](_0x2aba21){const _0x36cae8=_0x45e5cc,_0x357c6e=_0x3cc6c6(this[_0x36cae8(0x251)]);if(!_0x357c6e[_0x36cae8(0x26b)][_0x36cae8(0x1e0)](_0x36cae8(0x1ba)))return;const _0x5eb2ae=this[_0x36cae8(0x251)][_0x36cae8(0x26b)][_0x36cae8(0x191)](_0x36cae8(0x2b1)),{reply:_0x1fbd23,interaction:_0x2718c}=this[_0x36cae8(0x229)](_0x2aba21[_0x36cae8(0x1ee)]),_0x3a4b4b=this[_0x36cae8(0x1cf)](_0x2aba21[_0x36cae8(0x1ee)],_0x2aba21[_0x36cae8(0x2bd)]),_0x3d4a2f=void 0x0!==_0x2aba21[_0x36cae8(0x2bd)]?[_0x1fbd23[_0x36cae8(0x1f0)][_0x2aba21[_0x36cae8(0x2bd)]]]:_0x1fbd23[_0x36cae8(0x1f0)][_0x36cae8(0x180)](_0x24f729=>_0x36cae8(0x22e)==_0x24f729[_0x36cae8(0x21d)]),_0x6a360f=_0x3d4a2f[_0x36cae8(0x1cc)](_0x26e58c=>_0x1fbd23[_0x36cae8(0x1f0)][_0x36cae8(0x266)](_0x26e58c));_0x6a360f[_0x36cae8(0x211)](_0x45cfad=>_0x1fbd23[_0x36cae8(0x1d2)](_0x45cfad,_0x36cae8(0x1cd)));const _0x10396b=_0x27c536({'editor':_0x357c6e,'reply':_0x1fbd23,'interaction':_0x2718c,'groups':_0x3d4a2f,'transform':!0x0,'documentCompare':_0x5eb2ae,'documentCompareOptions':{'anchor':_0x36cae8(0x196),'markDeletions':!0x0}});let _0x3b2c6b;_0x3a4b4b&&this[_0x36cae8(0x29c)](_0x3a4b4b[_0x36cae8(0x2b4)]),_0x357c6e[_0x36cae8(0x24b)][_0x36cae8(0x287)](_0x33f133=>{const _0x1eca77=_0x36cae8;_0x3b2c6b=_0x33f133[_0x1eca77(0x28f)],_0x357c6e[_0x1eca77(0x26b)][_0x1eca77(0x191)](_0x1eca77(0x1ba))[_0x1eca77(0x217)](_0x10396b),this[_0x1eca77(0x204)][_0x1eca77(0x260)](_0x1eca77(0x213));}),this[_0x36cae8(0x235)][_0x36cae8(0x242)](_0x3b2c6b,{'interactionId':_0x2718c['id'],'replyId':_0x1fbd23['id'],'indexes':_0x6a360f[_0x36cae8(0x257)]()}),this[_0x36cae8(0x2a0)](_0x1fbd23);}[_0x45e5cc(0x296)](_0x404728){const _0x269166=_0x45e5cc,_0x16d349=_0x3cc6c6(this[_0x269166(0x251)]),_0x2019cd=this[_0x269166(0x251)][_0x269166(0x26b)][_0x269166(0x191)](_0x151f22),{reply:_0x4b4c69,interaction:_0x406bf8}=this[_0x269166(0x229)](_0x404728[_0x269166(0x1ee)]),_0x279062=this[_0x269166(0x1cf)](_0x404728[_0x269166(0x1ee)],_0x404728[_0x269166(0x2bd)]),_0x431470=void 0x0!==_0x404728[_0x269166(0x2bd)]?[_0x4b4c69[_0x269166(0x1f0)][_0x404728[_0x269166(0x2bd)]]]:_0x4b4c69[_0x269166(0x1f0)][_0x269166(0x180)](_0x66654e=>_0x269166(0x22e)==_0x66654e[_0x269166(0x21d)]),_0x4abca1=_0x431470[_0x269166(0x1cc)](_0x2a4cf2=>_0x4b4c69[_0x269166(0x1f0)][_0x269166(0x266)](_0x2a4cf2));_0x4abca1[_0x269166(0x211)](_0x3cf057=>_0x4b4c69[_0x269166(0x1d2)](_0x3cf057,_0x269166(0x1cd)));const _0x2e05cd=_0x27c536({'editor':_0x16d349,'reply':_0x4b4c69,'interaction':_0x406bf8,'groups':_0x431470,'transform':!0x0,'documentCompare':_0x2019cd,'documentCompareOptions':{'anchor':_0x269166(0x196),'markDeletions':!0x1}});let _0x589abf;_0x279062&&this[_0x269166(0x29c)](_0x279062[_0x269166(0x2b4)]),_0x16d349[_0x269166(0x24b)][_0x269166(0x287)](_0x4f5118=>{const _0x119970=_0x269166;_0x589abf=_0x4f5118[_0x119970(0x28f)];for(const _0x52fb93 of _0x2e05cd)_0x52fb93[_0x119970(0x2ce)]=_0x16d349[_0x119970(0x24b)][_0x119970(0x29d)][_0x119970(0x24c)],_0x4f5118[_0x119970(0x28f)][_0x119970(0x1ea)](_0x52fb93),_0x16d349[_0x119970(0x24b)][_0x119970(0x1d3)](_0x52fb93);}),this[_0x269166(0x235)][_0x269166(0x242)](_0x589abf,{'interactionId':_0x406bf8['id'],'replyId':_0x4b4c69['id'],'indexes':_0x4abca1[_0x269166(0x257)]()}),this[_0x269166(0x2a0)](_0x4b4c69);}[_0x45e5cc(0x17b)](_0x4b02a2,_0x3437b3){const _0x11ca39=_0x45e5cc,_0x13dc98=_0x3cc6c6(this[_0x11ca39(0x251)]),_0x4eba88=this[_0x11ca39(0x1cf)](_0x4b02a2,_0x3437b3),_0x107b1b=this[_0x11ca39(0x251)][_0x11ca39(0x26b)][_0x11ca39(0x191)](_0x385be5);if(!_0x4eba88)return void _0x107b1b[_0x11ca39(0x2b5)]();const {range:_0x25ba22,currentIndex:_0x48b61a,previousIndex:_0x4fcbc2,nextIndex:_0x110cda}=_0x4eba88;if(this[_0x11ca39(0x27c)]?.[_0x11ca39(0x1ee)]==_0x4b02a2&&this[_0x11ca39(0x27c)]?.[_0x11ca39(0x2bd)]==_0x48b61a)return;this[_0x11ca39(0x27c)]={'replyId':_0x4b02a2,'partIndex':_0x48b61a};const _0x3d72b2=new _0x2c138a(_0x13dc98[_0x11ca39(0x23c)],{'showDiff':this[_0x11ca39(0x2ab)],'areActionsDisabled':!0x1,'miniToolbarConfig':{'showChanges':_0x11ca39(0x17d)},'hideHeader':!0x0}),{reply:_0x4a793c}=this[_0x11ca39(0x229)](_0x4b02a2),_0xedc03=_0x1a511c({'editor':_0x13dc98,'changeGroups':[_0x4a793c[_0x11ca39(0x1f0)][_0x48b61a]],'documentContextContent':_0x4a793c[_0x11ca39(0x18a)],'showDiff':this[_0x11ca39(0x2ab)]});_0x3d72b2[_0x11ca39(0x183)]({'parts':_0xedc03,'renderingStrategy':_0x11ca39(0x20f)});const _0x3c2a0e=_0x48b61a!==_0x4fcbc2;this[_0x11ca39(0x29c)](_0x25ba22,!0x0),_0x107b1b[_0x11ca39(0x2c2)]({'index':_0x48b61a,'title':_0x3dfaa9(this[_0x11ca39(0x251)][_0x11ca39(0x23c)],_0x11ca39(0x1aa),(_0x48b61a+0x1)[_0x11ca39(0x1d4)]()),'icon':_0xf4914d,'mainView':_0x3d72b2,'showRotator':_0x3c2a0e,'showApplyButton':!0x0,'showSuggestButton':!0x0,'ranges':[_0x25ba22]}),this[_0x11ca39(0x24f)][_0x11ca39(0x250)](_0x4b02a2,_0x48b61a),this[_0x11ca39(0x262)](_0x3d72b2,_0x11ca39(0x1b7),(_0x1c038e,{showDiff:_0x473d83})=>{const _0x27110c=_0x11ca39;this[_0x27110c(0x2ab)]=_0x473d83;const {reply:_0x511e4a}=this[_0x27110c(0x229)](_0x4b02a2),_0x20a3e6=_0x1a511c({'editor':_0x13dc98,'changeGroups':[_0x511e4a[_0x27110c(0x1f0)][_0x48b61a]],'documentContextContent':_0x511e4a[_0x27110c(0x18a)],'showDiff':_0x473d83});_0x3d72b2[_0x27110c(0x183)]({'parts':_0x20a3e6,'renderingStrategy':_0x27110c(0x20f)});}),this[_0x11ca39(0x262)](_0x107b1b,_0x11ca39(0x27d),()=>{const _0x57e3ba=_0x11ca39;this[_0x57e3ba(0x296)]({'replyId':_0x4b02a2,'partIndex':_0x48b61a}),_0x3c2a0e?this[_0x57e3ba(0x17b)](_0x4b02a2,_0x110cda):_0x107b1b[_0x57e3ba(0x2b5)]();}),this[_0x11ca39(0x262)](_0x107b1b,_0x11ca39(0x2a2),()=>{const _0x146db3=_0x11ca39;this[_0x146db3(0x21c)]({'replyId':_0x4b02a2,'partIndex':_0x48b61a}),_0x3c2a0e?this[_0x146db3(0x17b)](_0x4b02a2,_0x110cda):_0x107b1b[_0x146db3(0x2b5)]();}),_0x3c2a0e&&(this[_0x11ca39(0x262)](_0x107b1b,_0x11ca39(0x1bd),()=>{const _0x231b9e=_0x11ca39;this[_0x231b9e(0x17b)](_0x4b02a2,_0x110cda);}),this[_0x11ca39(0x262)](_0x107b1b,_0x11ca39(0x239),()=>{const _0x19fe2c=_0x11ca39;this[_0x19fe2c(0x17b)](_0x4b02a2,_0x4fcbc2);})),this[_0x11ca39(0x262)](_0x107b1b,_0x11ca39(0x231),()=>{const _0x4d785e=_0x11ca39;this[_0x4d785e(0x25a)](_0x107b1b),this[_0x4d785e(0x25a)](_0x3d72b2),this[_0x4d785e(0x27c)]=null;});}[_0x45e5cc(0x1cf)](_0x484b98,_0x4e5228){const _0x5f49ab=_0x45e5cc,_0x1cab8e=_0x3cc6c6(this[_0x5f49ab(0x251)]),{reply:_0x5dd20b,interaction:_0x475959}=this[_0x5f49ab(0x229)](_0x484b98),_0x25bb0e=_0x5dd20b[_0x5f49ab(0x1f0)][_0x5f49ab(0x180)](_0x142cad=>_0x5f49ab(0x22e)==_0x142cad[_0x5f49ab(0x21d)]),_0x14389b=_0x25bb0e[_0x5f49ab(0x1cc)](_0x5c1fe8=>_0x5dd20b[_0x5f49ab(0x1f0)][_0x5f49ab(0x266)](_0x5c1fe8));void 0x0===_0x4e5228&&(_0x4e5228=_0x14389b[0x0]);const _0x1e63ac=_0x14389b[_0x5f49ab(0x266)](_0x4e5228);if(-0x1==_0x1e63ac)return null;const _0x3a83c8=0x0==_0x1e63ac?_0x14389b[_0x14389b[_0x5f49ab(0x190)]-0x1]:_0x14389b[_0x1e63ac-0x1],_0x562b87=_0x1e63ac==_0x14389b[_0x5f49ab(0x190)]-0x1?_0x14389b[0x0]:_0x14389b[_0x1e63ac+0x1],_0x3ec794=_0x25bb0e[_0x1e63ac],_0x311da8=new _0x284939([]),_0x478a9d=new _0x284939([]);for(const _0x2b0826 of _0x3ec794[_0x5f49ab(0x26a)])if(_0x5f49ab(0x297)!=_0x2b0826[_0x5f49ab(0x1c9)]&&_0x478a9d[_0x5f49ab(0x26d)][_0x5f49ab(0x21a)](_0x2b0826[_0x5f49ab(0x18c)][_0x5f49ab(0x17c)](!0x0)),_0x5f49ab(0x286)!=_0x2b0826[_0x5f49ab(0x1c9)]){const _0xccb8fb=_0x2327f3(_0x392936=>_0x2777d2(_0x392936,_0x5f49ab(0x2bb))==_0x2b0826['id'],_0x5dd20b[_0x5f49ab(0x18a)],!0x0);_0x311da8[_0x5f49ab(0x26d)][_0x5f49ab(0x21a)](_0xccb8fb[_0x5f49ab(0x17c)](!0x0));}if(0x0==_0x311da8[_0x5f49ab(0x26d)][_0x5f49ab(0x190)]){if(_0x3ec794[_0x5f49ab(0x26a)][0x0][_0x5f49ab(0x1b4)]){const _0x3e3650=_0x5885d0(_0x5f49ab(0x2bb),_0x3ec794[_0x5f49ab(0x26a)][0x0][_0x5f49ab(0x1b4)],_0x5dd20b[_0x5f49ab(0x18a)]);_0x311da8[_0x5f49ab(0x26d)][_0x5f49ab(0x1af)](_0x3e3650[_0x5f49ab(0x17c)](!0x0)),_0x478a9d[_0x5f49ab(0x26d)][_0x5f49ab(0x1af)](_0x3e3650[_0x5f49ab(0x17c)](!0x0)),_0x3e3650[_0x5f49ab(0x228)]&&(_0x311da8[_0x5f49ab(0x26d)][_0x5f49ab(0x21a)](_0x3e3650[_0x5f49ab(0x228)][_0x5f49ab(0x17c)](!0x0)),_0x478a9d[_0x5f49ab(0x26d)][_0x5f49ab(0x21a)](_0x3e3650[_0x5f49ab(0x228)][_0x5f49ab(0x17c)](!0x0)));}else{const _0x4742d1=_0x5dd20b[_0x5f49ab(0x18a)][_0x5f49ab(0x26d)][0x0];if(!_0x4742d1)return null;_0x311da8[_0x5f49ab(0x26d)][_0x5f49ab(0x21a)](_0x4742d1[_0x5f49ab(0x17c)](!0x0)),_0x478a9d[_0x5f49ab(0x26d)][_0x5f49ab(0x21a)](_0x4742d1[_0x5f49ab(0x17c)](!0x0));}}const _0x132388=_0x475959[_0x5f49ab(0x1f9)](),_0x26cca2=_0x1cab8e[_0x5f49ab(0x1f2)][_0x5f49ab(0x1f3)](_0x132388[_0x5f49ab(0x28a)]),_0x1d188c=_0x30a863(_0x311da8),_0x402783=_0x1cab8e[_0x5f49ab(0x1f2)][_0x5f49ab(0x1f3)](_0x1d188c),_0x10c314=_0x1cab8e[_0x5f49ab(0x1f2)][_0x5f49ab(0x1f3)](_0x1d188c),_0x20863a=_0x1cab8e[_0x5f49ab(0x24b)][_0x5f49ab(0x2af)](_0x402783,0x0),_0x12b5ce=_0x30a863(_0x478a9d),_0x4da7b4={'anchor':_0x20863a,'markDeletions':!0x1},_0x35f590=_0x1cab8e[_0x5f49ab(0x26b)][_0x5f49ab(0x191)](_0x151f22)[_0x5f49ab(0x193)](_0x1d188c,_0x12b5ce,_0x4da7b4)[_0x5f49ab(0x22f)]();if(!_0x35f590[_0x5f49ab(0x190)])return null;_0x1cab8e[_0x5f49ab(0x24b)][_0x5f49ab(0x287)](_0x42ff38=>{const _0x454de4=_0x5f49ab;for(const _0x393465 of _0x35f590)if(_0x454de4(0x194)==_0x393465[_0x454de4(0x1c9)]){const _0x2e2f54=_0x393465[_0x454de4(0x25b)],_0x4ab9a6=_0x393465[_0x454de4(0x1d0)],_0x2bb8d6=new _0x10e379(_0x2e2f54,_0x4ab9a6);_0x42ff38[_0x454de4(0x28f)][_0x454de4(0x1ea)](_0x2bb8d6),_0x1cab8e[_0x454de4(0x24b)][_0x454de4(0x1d3)](_0x2bb8d6);}else _0x454de4(0x284)!==_0x393465[_0x454de4(0x1c9)]&&(_0x393465[_0x454de4(0x2ce)]=null,_0x393465[_0x454de4(0x215)]=!0x1,_0x42ff38[_0x454de4(0x28f)][_0x454de4(0x1ea)](_0x393465),_0x1cab8e[_0x454de4(0x24b)][_0x454de4(0x1d3)](_0x393465));});const _0x2ace6e=_0x1d20c2(_0x1cab8e,_0x35f590,_0x402783);_0x16a2b5(_0x1cab8e[_0x5f49ab(0x24b)],_0x2ace6e);const _0x2cdd73=_0x2ace6e[_0x5f49ab(0x273)]()[_0x5f49ab(0x275)][_0x5f49ab(0x20a)][_0x5f49ab(0x257)](),_0x44c0ab=_0x2ace6e[_0x5f49ab(0x273)]()[_0x5f49ab(0x263)][_0x5f49ab(0x20a)][_0x5f49ab(0x257)](),_0x3147e9=[];let _0x135aa8=_0x402783,_0x223870=_0x10c314;for(let _0x586169=0x0;_0x586169<_0x44c0ab[_0x5f49ab(0x190)];_0x586169++){const _0x279d86=_0x135aa8[_0x5f49ab(0x1fa)]-_0x44c0ab[_0x586169];_0x3147e9[_0x586169]=_0x223870[_0x5f49ab(0x1fa)]-_0x279d86,_0x135aa8=_0x135aa8[_0x5f49ab(0x26f)](_0x44c0ab[_0x586169]),_0x223870=_0x223870[_0x5f49ab(0x26f)](_0x3147e9[_0x586169]);}const _0x293432=_0x1cab8e[_0x5f49ab(0x24b)][_0x5f49ab(0x24a)](_0x1cab8e[_0x5f49ab(0x24b)][_0x5f49ab(0x28b)](_0x10c314,_0x2cdd73),_0x1cab8e[_0x5f49ab(0x24b)][_0x5f49ab(0x28b)](_0x10c314,_0x3147e9)),_0x1cca13=_0x10c314[_0x5f49ab(0x1c0)](0x0)[_0x5f49ab(0x20c)](_0x39eb9b),_0x1d7c76=Array[_0x5f49ab(0x1e3)](_0x26cca2[_0x5f49ab(0x227)]())[_0x5f49ab(0x21e)](_0x158f1a=>_0x158f1a[_0x5f49ab(0x20c)](_0x39eb9b)==_0x1cca13)[_0x5f49ab(0x179)](),_0x3582cd=_0x293432[_0x5f49ab(0x275)][_0x5f49ab(0x20a)][_0x5f49ab(0x257)](),_0x4ef354=_0x293432[_0x5f49ab(0x263)][_0x5f49ab(0x20a)][_0x5f49ab(0x257)]();_0x3582cd[0x0]=_0x1d7c76[0x0]+_0x3582cd[0x0],_0x4ef354[0x0]=_0x1d7c76[0x0]+_0x4ef354[0x0];let _0x1aff40=_0x1cab8e[_0x5f49ab(0x24b)][_0x5f49ab(0x24a)](_0x1cab8e[_0x5f49ab(0x24b)][_0x5f49ab(0x28b)](_0x1cab8e[_0x5f49ab(0x24b)][_0x5f49ab(0x29d)][_0x5f49ab(0x285)](),_0x3582cd),_0x1cab8e[_0x5f49ab(0x24b)][_0x5f49ab(0x28b)](_0x1cab8e[_0x5f49ab(0x24b)][_0x5f49ab(0x29d)][_0x5f49ab(0x285)](),_0x4ef354));const _0xd4a72f=_0x1cab8e[_0x5f49ab(0x24b)][_0x5f49ab(0x29d)][_0x5f49ab(0x271)][_0x5f49ab(0x22f)](_0x132388[_0x5f49ab(0x24c)]);for(const _0x1c325c of _0xd4a72f)_0x1aff40=_0x503dc3[_0x5f49ab(0x19d)](_0x1aff40[_0x5f49ab(0x19b)](_0x1c325c));return{'range':_0x1aff40,'previousIndex':_0x3a83c8,'nextIndex':_0x562b87,'currentIndex':_0x4e5228};}[_0x45e5cc(0x29b)](_0x27b487){const _0xee507b=_0x45e5cc;if(!_0x27b487[_0xee507b(0x26b)][_0xee507b(0x1e0)](_0xee507b(0x29e)))return;const _0x2645a2=_0x27b487[_0xee507b(0x2ac)][_0xee507b(0x191)](_0xee507b(0x22b)),_0x5ad454=_0x27b487[_0xee507b(0x2ac)][_0xee507b(0x191)](_0xee507b(0x283));this[_0xee507b(0x262)](_0x2645a2,_0xee507b(0x1ad),(_0x536b78,_0x3eadbe,_0x1fb493)=>{const _0x35049b=_0xee507b,_0x3c3867=this[_0x35049b(0x235)][_0x35049b(0x191)](_0x3eadbe);if(!_0x3c3867)return;const _0x42505f=this[_0x35049b(0x1fe)][_0x35049b(0x1e2)](_0x3c3867[_0x35049b(0x2a3)])[_0x35049b(0x18d)](_0x3c3867[_0x35049b(0x1ee)]);_0x3c3867[_0x35049b(0x299)][_0x35049b(0x211)](_0xb7422a=>_0x42505f[_0x35049b(0x1d2)](_0xb7422a,_0x35049b(0x22e))),this[_0x35049b(0x235)][_0x35049b(0x181)](_0x3eadbe),this[_0x35049b(0x235)][_0x35049b(0x242)](_0x1fb493,_0x3c3867);}),this[_0xee507b(0x262)](_0x5ad454,_0xee507b(0x1ad),(_0x4662fc,_0x3d56c3,_0x2595f2)=>{const _0x3f6c1f=_0xee507b,_0x48abdf=this[_0x3f6c1f(0x235)][_0x3f6c1f(0x191)](_0x3d56c3);if(!_0x48abdf)return;const _0x755339=this[_0x3f6c1f(0x1fe)][_0x3f6c1f(0x1e2)](_0x48abdf[_0x3f6c1f(0x2a3)])[_0x3f6c1f(0x18d)](_0x48abdf[_0x3f6c1f(0x1ee)]);_0x48abdf[_0x3f6c1f(0x299)][_0x3f6c1f(0x211)](_0x710b59=>_0x755339[_0x3f6c1f(0x1d2)](_0x710b59,_0x3f6c1f(0x1cd))),this[_0x3f6c1f(0x235)][_0x3f6c1f(0x181)](_0x3d56c3),this[_0x3f6c1f(0x235)][_0x3f6c1f(0x242)](_0x2595f2,_0x48abdf);});}async[_0x45e5cc(0x1ed)](_0x477c2e){const _0x429978=_0x45e5cc;this[_0x429978(0x251)][_0x429978(0x26b)][_0x429978(0x191)](_0x385be5)[_0x429978(0x2b5)](),this[_0x429978(0x24f)][_0x429978(0x187)](_0x429978(0x20f)),this[_0x429978(0x24f)][_0x429978(0x2b7)](!0x0),await this[_0x429978(0x218)]();try{const _0x2ea007=this[_0x429978(0x251)][_0x429978(0x26b)][_0x429978(0x191)](_0x2cb794);this[_0x429978(0x25f)]('\x20'),_0x2ea007[_0x429978(0x2b8)][_0x429978(0x195)](_0x429978(0x2cd)),await this[_0x429978(0x272)](_0x477c2e);const {sessionId:_0x442979}=this[_0x429978(0x204)][_0x429978(0x277)]();await this[_0x429978(0x1fe)][_0x429978(0x1c2)](_0x477c2e,_0x442979),this[_0x429978(0x1fe)][_0x429978(0x2a7)]()&&this[_0x429978(0x1fe)][_0x429978(0x2a5)](_0x3dfaa9(this[_0x429978(0x251)][_0x429978(0x23c)],_0x429978(0x29f)));}catch(_0xd1e228){console[_0x429978(0x1ce)](_0x429978(0x29a),_0xd1e228);}finally{this[_0x429978(0x24f)][_0x429978(0x187)](_0x429978(0x192)),this[_0x429978(0x24f)][_0x429978(0x2b7)](!0x1);}}[_0x45e5cc(0x28e)](_0x3624d0){const _0x3c50b1=_0x45e5cc;this[_0x3c50b1(0x1fe)]['id']===_0x3624d0&&this[_0x3c50b1(0x272)]();}async[_0x45e5cc(0x1b2)](){const _0x2ee722=_0x45e5cc,_0x1fa18b=this[_0x2ee722(0x204)][_0x2ee722(0x268)]();this[_0x2ee722(0x1fe)]?.[_0x2ee722(0x1f1)](_0x1fa18b),this[_0x2ee722(0x1fe)]?.[_0x2ee722(0x2a5)](_0x3dfaa9(this[_0x2ee722(0x251)][_0x2ee722(0x23c)],_0x2ee722(0x29f)));}[_0x45e5cc(0x208)](){const _0x1fb5f2=_0x45e5cc;this[_0x1fb5f2(0x1fe)]?.[_0x1fb5f2(0x2ae)]();}[_0x45e5cc(0x261)](){const _0x1c0438=_0x45e5cc;this[_0x1c0438(0x24f)][_0x1c0438(0x261)]();}async[_0x45e5cc(0x24e)](){const _0x5b8c6d=_0x45e5cc;await this[_0x5b8c6d(0x272)]();}async[_0x45e5cc(0x20b)]({message:_0x43ec18,quickActionData:_0x180f86}){const _0x4dbd48=_0x45e5cc;await this[_0x4dbd48(0x279)]({'userMessage':_0x43ec18,'quickActionData':_0x180f86});}[_0x45e5cc(0x214)](){const _0x53254b=_0x45e5cc,_0x5acb75=this[_0x53254b(0x251)][_0x53254b(0x293)][_0x53254b(0x191)](_0x53254b(0x198));if(!_0x5acb75)throw new _0x16faf9(_0x53254b(0x17a),this);return _0x5acb75;}async[_0x45e5cc(0x272)](_0x928679){const _0x58a981=_0x45e5cc;try{this[_0x58a981(0x24f)][_0x58a981(0x2a9)](),await this[_0x58a981(0x1dd)](_0x928679);}catch(_0x20a9c0){_0x50a61f(_0x58a981(0x1a5),_0x20a9c0),this[_0x58a981(0x1fe)]=void 0x0,this[_0x58a981(0x24f)][_0x58a981(0x1e1)]();}}async[_0x45e5cc(0x1dd)](_0x1d9c04){const _0x139c2a=_0x45e5cc,_0x2ad8bd=this[_0x139c2a(0x251)][_0x139c2a(0x26b)][_0x139c2a(0x191)](_0x385be5);let _0x5c75b4;_0x2ad8bd[_0x139c2a(0x292)]&&_0x2ad8bd[_0x139c2a(0x2b5)](),_0x5c75b4=_0x1d9c04||!this[_0x139c2a(0x1fe)]?this[_0x139c2a(0x251)][_0x139c2a(0x293)][_0x139c2a(0x191)](_0x139c2a(0x2a6)):this[_0x139c2a(0x1fe)][_0x139c2a(0x207)]['id'],await this[_0x139c2a(0x218)]();const _0x31c609=this[_0x139c2a(0x214)](),_0x271752=_0x1d9c04||_0x2d2414();this[_0x139c2a(0x1fe)]=new _0x28056c({'connector':this[_0x139c2a(0x2b3)],'chatModels':this[_0x139c2a(0x1ef)],'defaultModelId':_0x5c75b4,'conversationId':_0x271752,'group':_0x31c609,'getEditor':()=>_0x3cc6c6(this[_0x139c2a(0x251)])}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x210),(_0x495a9e,_0x3eb520)=>{const _0x1fad67=_0x139c2a;_0x3eb520[_0x1fad67(0x1a2)]=this[_0x1fad67(0x234)](_0x3eb520[_0x1fad67(0x1a2)],this[_0x1fad67(0x251)][_0x1fad67(0x293)][_0x1fad67(0x191)](_0x1fad67(0x1cb))),this[_0x1fad67(0x24f)][_0x1fad67(0x21b)](_0x3eb520),this[_0x1fad67(0x24f)][_0x1fad67(0x1a4)](),this[_0x1fad67(0x24f)][_0x1fad67(0x219)](),this[_0x1fad67(0x24f)][_0x1fad67(0x22c)](),_0x1d9c04||(this[_0x1fad67(0x24f)][_0x1fad67(0x256)](),this[_0x1fad67(0x1fe)]?.[_0x1fad67(0x2a5)](_0x3dfaa9(this[_0x1fad67(0x251)][_0x1fad67(0x23c)],_0x1fad67(0x29f))));}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x205),(_0x14514f,_0x2ac49e)=>{const _0x144b06=_0x139c2a;this[_0x144b06(0x24f)][_0x144b06(0x1f4)](_0x2ac49e[_0x144b06(0x289)]);}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x2cb),(_0x231c50,_0x16eb05)=>{const _0x2b68a4=_0x139c2a;this[_0x2b68a4(0x24f)][_0x2b68a4(0x202)](_0x16eb05);}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x28d),()=>{const _0x2842b1=_0x139c2a;this[_0x2842b1(0x24f)][_0x2842b1(0x1b3)]({'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x2c0),()=>{const _0xa89a6b=_0x139c2a;this[_0xa89a6b(0x24f)][_0xa89a6b(0x1b3)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x25c),(_0x5af0cd,_0x43bc3f)=>{const _0x2c8321=_0x139c2a;this[_0x2c8321(0x24f)][_0x2c8321(0x1d6)](_0x43bc3f,{'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x291),(_0xee4183,_0x402002)=>{const _0x5d4419=_0x139c2a;this[_0x5d4419(0x24f)][_0x5d4419(0x1d6)](_0x402002,{'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x2cf),()=>{const _0x46e120=_0x139c2a;this[_0x46e120(0x24f)][_0x46e120(0x27e)]();}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x1a0),async()=>{const _0x4cd462=_0x139c2a;await this[_0x4cd462(0x24f)][_0x4cd462(0x221)]();}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x225),(_0x2c0657,_0x2a1a52)=>{const _0x5b727c=_0x139c2a;this[_0x5b727c(0x24f)][_0x5b727c(0x243)](_0x2a1a52['id']);}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x1bc),(_0x4ed305,_0x25d785,_0x27fa35)=>{const _0x33b0da=_0x139c2a;this[_0x33b0da(0x25f)](_0x25d785,_0x27fa35);}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x223),(_0x27e5fd,_0xb298ed)=>{const _0x5aa101=_0x139c2a;_0x5aa101(0x259)===_0xb298ed[_0x5aa101(0x1c9)]?this[_0x5aa101(0x24f)][_0x5aa101(0x23a)](_0xb298ed):this[_0x5aa101(0x24f)][_0x5aa101(0x200)](_0xb298ed);}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x182),async(_0x2aea7d,_0x3f6a41,_0x351cbd)=>{const _0x32c6ac=_0x139c2a;await this[_0x32c6ac(0x1e8)]({'reply':_0x3f6a41,'changeGroups':_0x351cbd});}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x2b2),(_0x4424fb,{reply:_0x5efe25,index:_0x176c32,state:_0x2c767c})=>{const _0x5d92a1=_0x139c2a;this[_0x5d92a1(0x24f)][_0x5d92a1(0x294)]({'id':_0x5efe25['id'],'index':_0x176c32,'state':_0x2c767c});}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x2c5),(_0x52d171,_0x4a9368)=>{const _0x56c1fd=_0x139c2a;if(this[_0x56c1fd(0x24f)][_0x56c1fd(0x1ff)](_0x4a9368[_0x56c1fd(0x203)],_0x4a9368[_0x56c1fd(0x23f)]),_0x56c1fd(0x1b5)===_0x4a9368[_0x56c1fd(0x203)][_0x56c1fd(0x1c9)]){const _0xa6185c=[..._0x3cc6c6(this[_0x56c1fd(0x251)])[_0x56c1fd(0x24b)][_0x56c1fd(0x29d)][_0x56c1fd(0x1b5)][_0x56c1fd(0x27f)]()];this[_0x56c1fd(0x204)][_0x56c1fd(0x26e)](_0xa6185c,_0x56c1fd(0x233)+this[_0x56c1fd(0x1fe)]?.['id']);}}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x177),(_0x31acd7,_0x2e3152)=>{const _0x3fefa0=_0x139c2a;this[_0x3fefa0(0x24f)][_0x3fefa0(0x1a7)](_0x2e3152[_0x3fefa0(0x1fc)]),_0x3fefa0(0x1e4)==_0x2e3152[_0x3fefa0(0x1fc)]&&this[_0x3fefa0(0x208)](),_0x3fefa0(0x1b5)===_0x2e3152[_0x3fefa0(0x1c9)]&&this[_0x3fefa0(0x204)][_0x3fefa0(0x260)](_0x3fefa0(0x233)+this[_0x3fefa0(0x1fe)]?.['id']);}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x17f),(_0x66f75a,_0x30621c)=>{const _0xbcce4=_0x139c2a;this[_0xbcce4(0x24f)][_0xbcce4(0x264)](_0x30621c[_0xbcce4(0x203)][_0xbcce4(0x1fc)],_0x30621c[_0xbcce4(0x23f)]);}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x1b6),(_0x31b958,_0x7ddbab)=>{const _0x40f854=_0x139c2a;this[_0x40f854(0x24f)][_0x40f854(0x2c6)](_0x7ddbab[_0x40f854(0x249)]);}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x20e),(_0xc85c7,_0xe573c9)=>{const _0x4ee86c=_0x139c2a;this[_0x4ee86c(0x24f)][_0x4ee86c(0x1b8)](_0xe573c9[_0x4ee86c(0x267)]);}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x230),(_0x5824d3,_0x3abcb0)=>{const _0x5b015a=_0x139c2a;this[_0x5b015a(0x24f)][_0x5b015a(0x1fb)](_0x3abcb0[_0x5b015a(0x2a1)],_0x3abcb0[_0x5b015a(0x184)],_0x3abcb0[_0x5b015a(0x1c1)],_0x3abcb0[_0x5b015a(0x19e)]);}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x274),(_0x34e8b0,_0x5af76b)=>{const _0xc15e45=_0x139c2a;this[_0xc15e45(0x24f)][_0xc15e45(0x1eb)](_0x5af76b[_0xc15e45(0x2a1)],_0x5af76b[_0xc15e45(0x253)],_0x5af76b[_0xc15e45(0x290)]);}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x1d8),(_0x33d22f,_0x5f4847)=>{const _0x3fa006=_0x139c2a;this[_0x3fa006(0x24f)][_0x3fa006(0x288)](_0x5f4847);}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x1bb),(_0x46f589,_0x635b3b)=>{const _0x1d4921=_0x139c2a;this[_0x1d4921(0x24f)][_0x1d4921(0x281)](_0x635b3b[_0x1d4921(0x207)],_0x635b3b[_0x1d4921(0x27a)]);}),this[_0x139c2a(0x1fe)]['on'](_0x139c2a(0x1ce),(_0x302208,{error:_0x58fd8d,interactionId:_0x588da6,fileName:_0x2715fa,url:_0x139a24,sourceId:_0x8254b8,sourceLabel:_0xdfc5ca})=>{const _0x111b0a=_0x139c2a,_0x56a629=_0x588da6?_0x588da6+':'+_0x2d2414():_0x2d2414();_0x58fd8d[_0x111b0a(0x189)][_0x111b0a(0x2bf)](_0x111b0a(0x25e))?this[_0x111b0a(0x24f)][_0x111b0a(0x26c)]({'staticMessage':_0x3dfaa9(this[_0x111b0a(0x251)][_0x111b0a(0x23c)],_0x111b0a(0x236)),'id':_0x56a629}):_0x58fd8d[_0x111b0a(0x189)][_0x111b0a(0x2bf)](_0x111b0a(0x1ec))||_0x58fd8d[_0x111b0a(0x189)][_0x111b0a(0x2bf)](_0x111b0a(0x1a5))?(this[_0x111b0a(0x24f)][_0x111b0a(0x25d)]({'errorMessage':_0x3dfaa9(this[_0x111b0a(0x251)][_0x111b0a(0x23c)],_0x111b0a(0x178)),'id':_0x56a629}),this[_0x111b0a(0x1d5)](_0x58fd8d)):_0x58fd8d[_0x111b0a(0x189)][_0x111b0a(0x2bf)](_0x111b0a(0x1f7))?this[_0x111b0a(0x24f)][_0x111b0a(0x25d)]({'errorMessage':_0x3dfaa9(this[_0x111b0a(0x251)][_0x111b0a(0x23c)],_0x111b0a(0x2b0),_0x2715fa),'id':_0x56a629}):_0x58fd8d[_0x111b0a(0x189)][_0x111b0a(0x2bf)](_0x111b0a(0x1d7))?this[_0x111b0a(0x24f)][_0x111b0a(0x25d)]({'errorMessage':_0x3dfaa9(this[_0x111b0a(0x251)][_0x111b0a(0x23c)],_0x111b0a(0x19c),_0x139a24),'id':_0x56a629}):_0x58fd8d[_0x111b0a(0x189)][_0x111b0a(0x2bf)](_0x111b0a(0x2c8))?this[_0x111b0a(0x24f)][_0x111b0a(0x25d)]({'errorMessage':_0x3dfaa9(this[_0x111b0a(0x251)][_0x111b0a(0x23c)],_0x111b0a(0x1fd)),'id':_0x56a629}):_0x58fd8d[_0x111b0a(0x189)][_0x111b0a(0x2bf)](_0x111b0a(0x20d))?this[_0x111b0a(0x24f)][_0x111b0a(0x25d)]({'errorMessage':_0x3dfaa9(this[_0x111b0a(0x251)][_0x111b0a(0x23c)],_0x111b0a(0x1c3)),'id':_0x56a629}):_0x58fd8d[_0x111b0a(0x189)][_0x111b0a(0x2bf)](_0x111b0a(0x23d))?(_0x8254b8&&this[_0x111b0a(0x24f)][_0x111b0a(0x1c8)](_0x8254b8),this[_0x111b0a(0x24f)][_0x111b0a(0x25d)]({'errorMessage':_0x3dfaa9(this[_0x111b0a(0x251)][_0x111b0a(0x23c)],_0x111b0a(0x188),_0xdfc5ca||_0x111b0a(0x184)),'id':_0x56a629}),this[_0x111b0a(0x1d5)](_0x58fd8d)):_0x58fd8d[_0x111b0a(0x189)][_0x111b0a(0x2bf)](_0x111b0a(0x232))?(this[_0x111b0a(0x24f)][_0x111b0a(0x25d)]({'errorMessage':_0x3dfaa9(this[_0x111b0a(0x251)][_0x111b0a(0x23c)],_0x111b0a(0x2c1)),'id':_0x56a629}),this[_0x111b0a(0x1d5)](_0x58fd8d)):(this[_0x111b0a(0x24f)][_0x111b0a(0x25d)]({'errorMessage':_0x3dfaa9(this[_0x111b0a(0x251)][_0x111b0a(0x23c)],_0x111b0a(0x201)),'id':_0x56a629}),this[_0x111b0a(0x1d5)](_0x58fd8d));}),await this[_0x139c2a(0x1fe)][_0x139c2a(0x282)](this[_0x139c2a(0x251)][_0x139c2a(0x293)][_0x139c2a(0x191)](_0x139c2a(0x1be))),_0x1d9c04||await this[_0x139c2a(0x1fe)][_0x139c2a(0x275)]();}async[_0x45e5cc(0x279)]({userMessage:_0x4dd081,quickActionData:_0x3d425d}){const _0x493238=_0x45e5cc;if(!this[_0x493238(0x1fe)])throw new _0x16faf9(_0x493238(0x238));this[_0x493238(0x1fe)][_0x493238(0x185)]()&&await this[_0x493238(0x1fe)][_0x493238(0x1c4)](this[_0x493238(0x204)][_0x493238(0x277)]()),this[_0x493238(0x1fe)]['id']&&this[_0x493238(0x1fe)][_0x493238(0x197)]&&await this[_0x493238(0x1fe)][_0x493238(0x2d0)]({'userMessage':_0x4dd081,'quickActionData':_0x3d425d}),this[_0x493238(0x1e5)]();}[_0x45e5cc(0x1e5)](){const _0x385360=_0x45e5cc,_0x24d1ca=_0x3cc6c6(this[_0x385360(0x251)])[_0x385360(0x24b)],_0x831f7e=Array[_0x385360(0x1e3)](_0x24d1ca[_0x385360(0x1a1)][_0x385360(0x1ca)](_0x38ead6));_0x24d1ca[_0x385360(0x287)](_0x5de4a6=>{const _0x2a1899=_0x385360;_0x831f7e[_0x2a1899(0x211)](_0x154c81=>_0x5de4a6[_0x2a1899(0x24d)](_0x154c81));});}[_0x45e5cc(0x18b)](){const _0x28942e=_0x45e5cc;console[_0x28942e(0x2b6)](_0x28942e(0x18f));}[_0x45e5cc(0x209)](_0x5e9321){const _0x16d385=_0x45e5cc;this[_0x16d385(0x24f)][_0x16d385(0x1e9)](_0x5e9321);}[_0x45e5cc(0x1d5)](_0x109714){const _0x3444c9=_0x45e5cc;_0x50a61f(_0x109714[_0x3444c9(0x189)]);}[_0x45e5cc(0x1d9)](_0x30c5d8){const _0x270c0b=_0x45e5cc;this[_0x270c0b(0x1fe)]?.[_0x270c0b(0x2c4)](_0x30c5d8);}[_0x45e5cc(0x1ac)](){const _0x33ab6f=_0x45e5cc;this[_0x33ab6f(0x1fe)]?.[_0x33ab6f(0x247)]();}[_0x45e5cc(0x1e7)](){const _0xd4d44f=_0x45e5cc;this[_0xd4d44f(0x1fe)]?.[_0xd4d44f(0x295)]();}[_0x45e5cc(0x229)](_0x47023e){const _0x451e4c=_0x45e5cc,[_0x392c7a,_0x486bfd]=_0x47023e[_0x451e4c(0x1f8)](':'),_0x38cb6a=this[_0x451e4c(0x1fe)][_0x451e4c(0x1e2)](_0x392c7a),_0x30d756=_0x38cb6a[_0x451e4c(0x18d)](_0x486bfd);return{'interaction':_0x38cb6a,'reply':_0x30d756};}[_0x45e5cc(0x29c)](_0x26b2e1,_0x1bc453=!0x1){const _0x31a0b6=_0x45e5cc,_0x31fa02=_0x3cc6c6(this[_0x31a0b6(0x251)]),_0x357f44={'target':_0x31fa02[_0x31a0b6(0x258)][_0x31a0b6(0x2b8)][_0x31a0b6(0x2aa)][_0x31a0b6(0x1c6)](_0x31fa02[_0x31a0b6(0x258)][_0x31a0b6(0x246)][_0x31a0b6(0x1c7)](_0x26b2e1)),'viewportOffset':{'top':0x96,'left':0x0,'bottom':0x32,'right':0x0},'ancestorOffset':0x14,'alignToTop':_0x1bc453};_0x1bc453&&(_0x357f44[_0x31a0b6(0x226)]=!0x0),_0x2339dd(_0x357f44);}[_0x45e5cc(0x25f)](_0x789f93,_0x3696b8=!0x1){const _0x28816e=_0x45e5cc;this[_0x28816e(0x24f)][_0x28816e(0x1bc)](_0x789f93||_0x3dfaa9(this[_0x28816e(0x251)][_0x28816e(0x23c)],_0x28816e(0x23b)),_0x3696b8);}[_0x45e5cc(0x234)](_0x46ea30,_0x81f92f){const _0x210630=_0x45e5cc;let _0xd9ab61;if(_0x81f92f){_0xd9ab61=[];const _0x3456b0=_0x210630(0x199)==typeof _0x81f92f?[_0x81f92f[_0x210630(0x1de)]()]:_0x81f92f[_0x210630(0x1cc)](_0x1002ad=>_0x1002ad[_0x210630(0x1de)]());for(const _0x18fa78 of _0x3456b0)for(const _0x49cc4b of _0x46ea30)(_0x49cc4b['id'][_0x210630(0x1de)]()===_0x18fa78||_0x49cc4b[_0x210630(0x1db)][_0x210630(0x1de)]()===_0x18fa78||_0x49cc4b[_0x210630(0x1e6)][_0x210630(0x1de)]()===_0x18fa78||_0x49cc4b['id'][_0x210630(0x1de)]()[_0x210630(0x2bf)](_0x18fa78))&&_0xd9ab61[_0x210630(0x21a)](_0x49cc4b);}else _0xd9ab61=_0x46ea30;return _0xd9ab61;}async[_0x45e5cc(0x1e8)]({reply:_0x5601ef,changeGroups:_0x570ec4,renderingStrategy:_0x311f77}){const _0x27d549=_0x45e5cc,{id:_0x43b641,isDone:_0x4d67d6,type:_0x1662ad,parsedContent:_0x5cca3b}=_0x5601ef;if(_0x27d549(0x278)===_0x1662ad){const _0x4329db=_0x3cc6c6(this[_0x27d549(0x251)]),_0x51229a=_0x1a511c({'editor':_0x4329db,'showDiff':this[_0x27d549(0x24f)][_0x27d549(0x1b1)],'changeGroups':_0x570ec4,'documentContextContent':_0x5601ef[_0x27d549(0x18a)]});await this[_0x27d549(0x24f)][_0x27d549(0x1b0)]({'id':_0x43b641,'parts':_0x51229a,'renderingStrategy':_0x311f77,'isDone':_0x4d67d6});}else _0x27d549(0x259)===_0x1662ad&&await this[_0x27d549(0x24f)][_0x27d549(0x276)]({'id':_0x43b641,'parsedContent':_0x5cca3b,'renderingStrategy':_0x311f77,'isDone':_0x4d67d6});_0x4d67d6&&_0x5601ef[_0x27d549(0x1a9)][_0x27d549(0x190)]>0x0&&this[_0x27d549(0x24f)][_0x27d549(0x244)](_0x43b641,_0x5601ef[_0x27d549(0x1a9)]);}async[_0x45e5cc(0x218)](){const _0x4a14fd=_0x45e5cc,_0x15ff42=this[_0x4a14fd(0x1fe)]?.[_0x4a14fd(0x241)];_0x15ff42&&(_0x15ff42[_0x4a14fd(0x2a4)](),this[_0x4a14fd(0x24f)][_0x4a14fd(0x212)](_0x15ff42));}async[_0x45e5cc(0x21f)](){const _0x49967d=_0x45e5cc,_0x425ad8=this[_0x49967d(0x1fe)]?.[_0x49967d(0x241)];if(_0x425ad8){for await(const _0x1162ac of _0x425ad8[_0x49967d(0x22a)])await this[_0x49967d(0x1e8)]({'reply':_0x1162ac,'changeGroups':_0x1162ac[_0x49967d(0x1f0)],'renderingStrategy':_0x49967d(0x20f)});}}[_0x45e5cc(0x2a0)](_0x3702f3){const _0x284f5b=_0x45e5cc,_0x15acd9={'positiveCount':_0x3702f3[_0x284f5b(0x1f0)][_0x284f5b(0x180)](_0x265013=>_0x284f5b(0x1cd)===_0x265013[_0x284f5b(0x21d)])[_0x284f5b(0x190)],'totalCount':_0x3702f3[_0x284f5b(0x1f0)][_0x284f5b(0x190)]},_0x3e8cf5=this[_0x284f5b(0x1fe)][_0x284f5b(0x1e2)](_0x3702f3[_0x284f5b(0x2a3)])[_0x284f5b(0x19a)];this[_0x284f5b(0x2b3)][_0x284f5b(0x2c3)](this[_0x284f5b(0x1fe)]['id'],_0x3e8cf5,_0x15acd9);}}function _0x344d(){const _0x56b3d7=['revert','rejected','unshift','updateFeedItemAIReplySuggestionContent','showDiff','addSelectionToChatContext','setLoadingMessage','anchorId','selection','contextSent','toggleSuggestionDisplayMode','setAddContextOptions','AITabs','TrackChangesEditing','modelSelected','setConversationTitle','showNext','ai.chat.context','705185qINtpG','getChild','resources','load','AI_CHAT_CONTEXT_UNSUPPORTED_TYPE','updateCurrentDocumentInContext','6086830ScpyLU','viewRangeToDom','toViewRange','closeSourceResourceBalloon','type','getMarkersGroup','ai.chat.models.displayedModels','map','accepted','error','_getDocumentRangeForReplyChanges','howMany','14zfkUrr','setChangeGroupState','applyOperation','toString','_logError','addFeedInteractionHeader','ai-chat-url-upload-failed','capabilitiesUpdated','_removeFromContext','resizeTabs','name','4515080cMYofq','_handleStartConversation','toLocaleLowerCase','addResourceToContext','has','disableControls','getInteraction','from','current-document','_removeAISelectionMarkers','provider','_toggleReasoning','_updateReplyContent','setIsMaximized','addOperation','updateResourceState','ai-chat-conversation-init-failed','loadConversation','replyId','_aiChatModels','changeGroups','addSelectionToContext','data','parse','setIsUploadInProgress','addFilesToContext','abortPromptStream','ai-chat-file-upload-failed','split','getDocumentContext','maxOffset','populateSourceResourceBalloon','uiId','AI_CHAT_CONTEXT_INVALID_DATA','activeConversation','addContextItem','addFeedItemAISuggestion','AI_CHAT_GENERIC_ERROR','addFeedItemUserMessage','contextItem','_aiEditing','uploadProgressChanged','AIEditing','selectedModel','removeSelectionFromChatContext','_setIsMaximized','path','sendMessage','getAttribute','ai-chat-context-unsupported-type','addContextOptionsChanged','static','conversationInitialized','forEach','stopInteraction','ai-chat-controller-mouse-over','getGroupId','isDocumentOperation','7268319SwPxBW','_applyOperationsAsSuggestions','_stopLastInteraction','clearPendingContextUI','push','createConversation','_insertSuggestion','state','find','_flushLastInteractionUI','2GTMDLg','finishInteraction','resize','replyCreated','showChangeInText','interactionDestroyed','alignToTop','getChildren','nextSibling','getInteractionAndReplyById','replies','undo','clearConversationContextUI','sendUserMessage','pending','getOperations','sourceResourcesLoaded','dialogClosed','ai-chat-resource-load-failed','ai-conversation-','_filterModels','_batchToChanges','AI_CHAT_ABORTED_MESSAGE','AIChatController','ai-chat-controller-no-active-conversation','showPrevious','addFeedItemAIReply','AI_CHAT_UNTITLED_CONVERSATION','locale','ai-chat-source-resources-load-failed','addFileToContext','isLoading','add','lastInteraction','set','removeFeedInteraction','updateFeedItemAIReplySources','rejectSuggestion','mapper','toggleWebSearch','selectModel','contextItems','createRange','model','version','removeMarker','startConversation','_aiChatUi','scrollFeedToSuggestion','context','mouseLeaveSuggestion','resourceId','4922260tfQjNR','Liked\x20response','resetConversationTitle','slice','editing','text-delta','stopListening','sourcePosition','webSearchFinished','addFeedItemError','ai-request-aborted','updateConversationTitle','hideFakeVisualSelection','focusPromptInput','listenTo','end','setContextItemLoading','ready','indexOf','options','getSelectionText','pluginName','changes','plugins','addFeedItemStaticMessage','children','showFakeVisualSelection','getChildAtOffset','query','history','_startConversationSafely','getFirstRange','resourceStateChanged','start','updateFeedItemAIReplyContent','getDocumentData','modification-delta','_handleUIUserMessage','isDisabled','Disliked\x20response','_previewedChangeGroup','applySuggestion','startInteraction','getRanges','editors','setSelectedModel','init','redo','marker','getRoot','new','change','updateCapabilities','isUploadInProgress','content','createPositionFromPath','isOfficialPlugin','webSearchStarted','handleRemovedConversation','batch','isInContext','reasoningFinished','isOpen','config','updateFeedItemAIReplySuggestionPartState','toggleReasoning','_applySuggestion','removed','$graveyard','indexes','Failed\x20to\x20load\x20conversation','_integrateEditor','_scrollToSuggestionRange','document','Undo','AI_CHAT_CONTEXT_CURRENT_DOCUMENT','_updateRatings','sourceId','insertSuggestion','interactionId','stop','addCurrentDocumentToContext','ai.chat.models.defaultModelId','isCurrentDocumentInConversation','addUrlToContext','enableControls','domConverter','_balloonShowDiff','commands','resizedTabs','removeSelectionFromContext','createPositionAt','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_FILE','DocumentCompare','replyChangeGroupStateUpdated','_aiConnector','range','close','log','toggleLoadingSkeleton','view','root','rootName','data-id','addDocumentToContext','partIndex','loadSourceResources','startsWith','reasoningStarted','AI_CHAT_RESOURCE_LOAD_FAILED','open','upsertAIChatRating','removeFromContext','contextItemAdded','setConversationContext','resource','ai-chat-context-invalid-data','AIChatUI','AIConnector','interactionCreated','setModel','chat','baseVersion','interactionStarted','handleUserInteraction','contextItemRemoved','AI_CHAT_UNABLE_TO_START_CONVERSATION','getPath','ai-chat-missing-channel-id','_openBalloonFor','cloneNode','full','2264523XUAYDv','contextItemLoadingEnded','filter','delete','replyContentUpdated','updateContent','source','isCurrentDocumentInContext','mouseOverSuggestion','setFeedItemRenderingStrategy','AI_CHAT_CONTEXT_UNABLE_TO_LOAD_RESOURCES','message','documentContextContent','_showConversationHistory','node','getReply','like','Showing\x20conversation\x20history...','length','get','streaming','getDiff','remove','activateTab','main','isStarted','collaboration.channelId','string','messageId','getTransformedByOperation','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_URL','_createFromRanges','uid','962490eJMCgU','interactionFinished','markers','availableModels','requires','resetMessageInput','ai-chat-conversation-start-failed','dislike','removeContextItem','isPremiumPlugin','sources','AI_BALLOON_HEADER_TITLE','afterInit','_toggleWebSearch'];_0x344d=function(){return _0x56b3d7;};return _0x344d();}
|
|
23
|
+
const _0x19ee94=_0x2a06;(function(_0x32653c,_0x3fc022){const _0x528cb1=_0x2a06,_0x12c789=_0x32653c();while(!![]){try{const _0xa5faa6=-parseInt(_0x528cb1(0xb7))/0x1+-parseInt(_0x528cb1(0x1c0))/0x2*(-parseInt(_0x528cb1(0x150))/0x3)+-parseInt(_0x528cb1(0x1de))/0x4+-parseInt(_0x528cb1(0x19d))/0x5+parseInt(_0x528cb1(0xb1))/0x6*(-parseInt(_0x528cb1(0xd2))/0x7)+-parseInt(_0x528cb1(0x175))/0x8+parseInt(_0x528cb1(0xfb))/0x9;if(_0xa5faa6===_0x3fc022)break;else _0x12c789['push'](_0x12c789['shift']());}catch(_0x322606){_0x12c789['push'](_0x12c789['shift']());}}}(_0x2f6c,0xa2cd1));import{ContextPlugin as _0x23175c,Editor as _0x5a2f64}from'ckeditor5/src/core.js';function _0x2a06(_0x511a84,_0xef870d){const _0x2f6c13=_0x2f6c();return _0x2a06=function(_0x2a065e,_0x575a1d){_0x2a065e=_0x2a065e-0xac;let _0x5e2e73=_0x2f6c13[_0x2a065e];return _0x5e2e73;},_0x2a06(_0x511a84,_0xef870d);}import{CKEditorError as _0x555cfc,logError as _0x322e37,scrollViewportToShowTarget as _0x360cfb,uid as _0x1dc6c9}from'ckeditor5/src/utils.js';import{AIConnector as _0x23f487}from'../aicore/aiconnector.js';import{AITabs as _0x351dd5}from'../aitabs/aitabs.js';import{AIChatConversation as _0x3aaab2}from'./model/aichatconversation.js';function _0x2f6c(){const _0x59db4c=['viewRangeToDom','_applySuggestion','replyCreated','ai-conversation-','_filterModels','applyOperation','contextItemRemoved','view','parse','clearConversationContextUI','removeFromContext','createPositionAt','sendUserMessage','pending','AIEditing','sourcePosition','type','stop','toggleLoadingSkeleton','setChangeGroupState','get','ai-chat-context-unsupported-type','replyId','_getDocumentRangeForReplyChanges','range','mouseLeaveSuggestion','getOperations','path','interactionDestroyed','removeSelectionFromChatContext','resource','add','setFeedItemRenderingStrategy','AI_CHAT_CONTEXT_UNSUPPORTED_TYPE','listenTo','startInteraction','ai-chat-context-invalid-data','history','loadSourceResources','Liked\x20response','changeGroups','markers','startsWith','selectModel','modification-delta','undo','_toggleReasoning','resize','isOpen','maxOffset','nextSibling','filter','query','isCurrentDocumentInConversation','alignToTop','removeMarker','indexes','toViewRange','baseVersion','_toggleWebSearch','isDisabled','updateCapabilities','mapper','ai-request-aborted','start','webSearchStarted','revert','setIsUploadInProgress','getPath','getReply','Failed\x20to\x20load\x20conversation','setIsMaximized','ai.chat.models.displayedModels','abortPromptStream','addUrlToContext','children','_handleUIUserMessage','_scrollToSuggestionRange','ready','capabilitiesUpdated','1933770LmyzPG','ai.chat.context','messageId','addOperation','getInteractionAndReplyById','_aiEditing','push','contextItems','contextItemLoadingEnded','activeConversation','addFileToContext','_createFromRanges','AI_BALLOON_HEADER_TITLE','Showing\x20conversation\x20history...','addDocumentToContext','getInteraction','ai-chat-controller-no-active-conversation','isPremiumPlugin','root','disableControls','setConversationContext','_balloonShowDiff','getChild','cloneNode','ai-chat-source-resources-load-failed','getRoot','data-id','howMany','conversationInitialized','editing','_updateRatings','main','insertSuggestion','from','stopInteraction','removeContextItem','applySuggestion','9043096bKOyBs','_applyOperationsAsSuggestions','AI_CHAT_CONTEXT_INVALID_DATA','ai-chat-missing-channel-id','replies','mouseOverSuggestion','addFeedItemError','replyChangeGroupStateUpdated','slice','setConversationTitle','getSelectionText','getRanges','resetMessageInput','sendMessage','locale','end','node','ai-chat-controller-mouse-over','createConversation','ai.chat.models.defaultModelId','Disliked\x20response','unshift','_integrateEditor','AI_CHAT_ABORTED_MESSAGE','ai-chat-file-upload-failed','state','getDiff','stopListening','_stopLastInteraction','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_FILE','finishInteraction','_flushLastInteractionUI','_openBalloonFor','collaboration.channelId','load','resources','resourceId','addSelectionToContext','new','showFakeVisualSelection','141315IjgZVR','Undo','_showConversationHistory','rejectSuggestion','uid','AI_CHAT_CONTEXT_UNABLE_TO_LOAD_RESOURCES','log','showDiff','anchorId','config','availableModels','contextSent','getAttribute','delete','addContextItem','handleRemovedConversation','lastInteraction','AIConnector','has','addFeedItemUserMessage','contextItem','content','_handleStartConversation','selectedModel','updateConversationTitle','_aiChatModels','_startConversationSafely','length','provider','enableControls','getGroupId','isDocumentOperation','data','interactionId','AITabs','2TpEBTL','marker','domConverter','createRange','updateFeedItemAIReplySources','AI_CHAT_RESOURCE_LOAD_FAILED','message','updateFeedItemAIReplyContent','sourceResourcesLoaded','removeSelectionFromContext','contextItemAdded','showPrevious','getMarkersGroup','addSelectionToChatContext','createPositionFromPath','ai-chat-url-upload-failed','addFeedItemAIReply','getChildAtOffset','partIndex','commands','interactionFinished','updateContent','upsertAIChatRating','init','selection','toLocaleLowerCase','current-document','addCurrentDocumentToContext','find','isInContext','4287344RcRqye','startConversation','populateSourceResourceBalloon','dislike','remove','addResourceToContext','batch','close','resizedTabs','activateTab','ai-chat-conversation-start-failed','getChildren','chat','_aiConnector','toggleReasoning','isLoading','AIChatUI','setAddContextOptions','sources','isUploadInProgress','updateFeedItemAIReplySuggestionPartState','uploadProgressChanged','modelSelected','reasoningStarted','showChangeInText','webSearchFinished','string','open','dialogClosed','loadConversation','version','AI_CHAT_UNTITLED_CONVERSATION','_setIsMaximized','forEach','getTransformedByOperation','sourceId','AI_CHAT_GENERIC_ERROR','DocumentCompare','rejected','resizeTabs','change','text-delta','addFilesToContext','addFeedInteractionHeader','resourceStateChanged','48PQFHmE','changes','AIChatController','AI_CHAT_CONTEXT_CURRENT_DOCUMENT','uiId','full','313547OIqwyg','updateResourceState','requires','handleUserInteraction','setModel','setLoadingMessage','_logError','split','_insertSuggestion','_batchToChanges','showNext','scrollFeedToSuggestion','editors','$graveyard','accepted','updateFeedItemAIReplySuggestionContent','addContextOptionsChanged','isCurrentDocumentInContext','interactionCreated','toggleSuggestionDisplayMode','resetConversationTitle','getFirstRange','addFeedItemStaticMessage','error','_previewedChangeGroup','plugins','afterInit','522277CwojlY','setContextItemLoading','ai-chat-resource-load-failed','toggleWebSearch','clearPendingContextUI','addFeedItemAISuggestion','removeFeedInteraction','static','model','replyContentUpdated','reasoningFinished','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_URL','streaming','TrackChangesEditing','map','getDocumentData','pluginName','setSelectedModel','isStarted','set','updateCurrentDocumentInContext','removed','source','getDocumentContext','focusPromptInput','closeSourceResourceBalloon','_removeAISelectionMarkers','_removeFromContext','name','document','hideFakeVisualSelection','interactionStarted','documentContextContent','_aiChatUi','context','redo','like','indexOf','rootName','ai-chat-conversation-init-failed','AI_CHAT_UNABLE_TO_START_CONVERSATION','28468476DatNil','_updateReplyContent','options','isOfficialPlugin','toString'];_0x2f6c=function(){return _0x59db4c;};return _0x2f6c();}import{getTranslation as _0x410147}from'../aicore/utils/common-translations.js';import{AI_VISUAL_SELECTION_MARKER_NAME as _0x2d0105}from'../aicore/aiediting.js';import{AIChatModels as _0x1cd0b4}from'./model/aichatmodels.js';import{getEditorFromContext as _0xe358}from'../aicore/utils/geteditorfromcontext.js';import{DocumentCompare as _0x2c7119,DATA_ID_MODEL_ATTRIBUTE as _0x2adcc9}from'@ckeditor/ckeditor5-collaboration-core';import{getOperationsFromReply as _0x2857f1}from'../aicore/utils/getoperationsfromreply.js';import{expandSelectionWithContext as _0x58915b,getMinimalSelection as _0x2f69f3,getSuggestionPartsFromReply as _0x121a6f}from'../aicore/utils/getsuggestionpartsfromreply.js';import{ModelRange as _0x2e571f,_DetachOperation as _0xcc7966}from'ckeditor5/src/engine.js';import{findOne as _0x17576e,getAttribute as _0x21da1a,serialize as _0x5571d8,Document as _0x5e6c42,findByAttribute as _0x420881}from'../aicore/utils/htmlparser.js';import{IconAI as _0x124f51}from'@ckeditor/ckeditor5-icons';import{AISuggestionContainerView as _0x4a6bc9}from'../aicore/ui/suggestioncontainer/aisuggestioncontainerview.js';import{AIBalloon as _0xc519a1}from'../aiballoon/aiballoon.js';export class AIChatController extends _0x23175c{[_0x19ee94(0x155)];[_0x19ee94(0x1eb)];[_0x19ee94(0xf3)];[_0x19ee94(0x1b6)];[_0x19ee94(0xc0)]=new Map();[_0x19ee94(0xcf)]=null;[_0x19ee94(0x165)]=!0x1;static get[_0x19ee94(0xb9)](){return[_0x23f487,_0xc519a1,_0x2c7119];}static get[_0x19ee94(0xe2)](){const _0x160822=_0x19ee94;return _0x160822(0xb3);}static get[_0x19ee94(0xfe)](){return!0x0;}static get[_0x19ee94(0x161)](){return!0x0;}[_0x19ee94(0x1d7)](){const _0x1d354c=_0x19ee94;this[_0x1d354c(0x1eb)]=this[_0x1d354c(0xf4)][_0x1d354c(0xd0)][_0x1d354c(0x114)](_0x1d354c(0x1ae)),this[_0x1d354c(0xf3)]=this[_0x1d354c(0xf4)][_0x1d354c(0xd0)][_0x1d354c(0x114)](_0x1d354c(0x1ee)),this[_0x1d354c(0x155)]=this[_0x1d354c(0xf4)][_0x1d354c(0xd0)][_0x1d354c(0x114)](_0x1d354c(0x10e)),this[_0x1d354c(0x1b6)]=new _0x1cd0b4({'connector':this[_0x1d354c(0x1eb)]});const _0x3b4157=this[_0x1d354c(0xf4)][_0x1d354c(0xd0)][_0x1d354c(0x114)](_0x1d354c(0x1bf));this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x1df),()=>{const _0xa8704e=_0x1d354c;this[_0xa8704e(0x1b7)]();}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x10c),(_0x5df798,_0x355d90)=>{const _0x47d0b0=_0x1d354c;this[_0x47d0b0(0x14c)]({'userMessage':_0x355d90});}),this[_0x1d354c(0x122)](_0x3b4157,_0x1d354c(0x1e6),(_0x5d4a8f,_0x4464f1)=>{const _0x3507a6=_0x1d354c;this[_0x3507a6(0x1fe)](_0x4464f1);}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x205),()=>{const _0x1c0c66=_0x1d354c;_0x3b4157[_0x1c0c66(0x12f)]();}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x149),async()=>{const _0x481135=_0x1d354c;await this[_0x481135(0x191)](),await this[_0x481135(0x194)]();}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x15e),()=>{const _0x52b7bb=_0x1d354c;this[_0x52b7bb(0x159)]?.[_0x52b7bb(0x1db)](_0x410147(this[_0x52b7bb(0xf4)][_0x52b7bb(0x183)],_0x52b7bb(0xb4)));}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x15a),(_0x5b3fba,_0x19c68c)=>{const _0x4135da=_0x1d354c;this[_0x4135da(0x159)]?.[_0x4135da(0xae)](Array[_0x4135da(0x171)](_0x19c68c));}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x14a),(_0x321e39,_0x31882e)=>{const _0x4e24b2=_0x1d354c;this[_0x4e24b2(0x159)]?.[_0x4e24b2(0x14a)](_0x31882e);}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x1e3),(_0x330f6f,_0x2c733e)=>{const _0x18182b=_0x1d354c;this[_0x18182b(0x159)]?.[_0x18182b(0x1e3)](_0x2c733e[_0x18182b(0xe8)],_0x2c733e[_0x18182b(0x11e)]);}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x173),(_0x5f0fb0,_0x4bc153)=>{const _0x7e1d7=_0x1d354c;this[_0x7e1d7(0xed)](_0x4bc153);}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x126),(_0xf3baa8,_0x25afdf)=>{const _0x382362=_0x1d354c;this[_0x382362(0x159)]?.[_0x382362(0x126)](_0x25afdf[_0x382362(0x201)],_0x25afdf[_0x382362(0x134)],_0x25afdf[_0x382362(0x1a1)]);}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0xd5),()=>{const _0x337d3c=_0x1d354c;this[_0x337d3c(0x13b)]();}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x1ec),()=>{const _0x43d7ef=_0x1d354c;this[_0x43d7ef(0x12e)]();}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x12b),(_0x5eb600,_0x120a1d)=>{const _0x2782e8=_0x1d354c;this[_0x2782e8(0x159)]?.[_0x2782e8(0xbb)](_0x120a1d);}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0xf6),(_0x86be21,{replyId:_0x31c67d})=>{const _0x40443b=_0x1d354c;console[_0x40443b(0x1a3)](_0x40443b(0x127),_0x31c67d);}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x1e1),(_0x11bf1c,{replyId:_0x3c8489})=>{const _0x4f810e=_0x1d354c;console[_0x4f810e(0x1a3)](_0x4f810e(0x189),_0x3c8489);}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x170),(_0xe14a60,_0x2a278a)=>{const _0xf1b089=_0x1d354c;this[_0xf1b089(0xf4)][_0xf1b089(0xd0)][_0xf1b089(0x114)](_0xc519a1)[_0xf1b089(0x1e5)](),this[_0xf1b089(0xbf)](_0x2a278a);}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x1f6),(_0x292c3e,{replyId:_0x22459b,partIndex:_0x51ff43})=>{const _0x29a9d1=_0x1d354c;this[_0x29a9d1(0x165)]=this[_0x29a9d1(0xf3)][_0x29a9d1(0x1a4)],this[_0x29a9d1(0x195)](_0x22459b,_0x51ff43);}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x17a),(_0x464361,{replyId:_0x497299,partIndex:_0x12da43})=>{const _0x5984af=_0x1d354c,_0x4ec9b1=this[_0x5984af(0x117)](_0x497299,_0x12da43);_0x4ec9b1&&_0x5984af(0xc4)!=_0x4ec9b1[_0x5984af(0x118)][_0x5984af(0x162)][_0x5984af(0xf8)]&&this[_0x5984af(0x155)][_0x5984af(0x19c)]([_0x4ec9b1[_0x5984af(0x118)]],_0x5984af(0x186));}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x119),()=>{const _0x193dbc=_0x1d354c;this[_0x193dbc(0x155)][_0x193dbc(0xf0)](_0x193dbc(0x186));}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x174),(_0x1e41e8,_0x2957fe)=>{const _0x3af4f2=_0x1d354c;this[_0x3af4f2(0xf4)][_0x3af4f2(0xd0)][_0x3af4f2(0x114)](_0xc519a1)[_0x3af4f2(0x1e5)](),this[_0x3af4f2(0x101)](_0x2957fe);}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0xca),async(_0x351cf9,_0x218f3b)=>{const _0x185ee5=_0x1d354c,{reply:_0x38cfd3}=this[_0x185ee5(0x154)](_0x218f3b[_0x185ee5(0x116)]),_0x19fb03=_0xe358(this[_0x185ee5(0xf4)]),_0x3f41d2=_0x121a6f({'editor':_0x19fb03,'changeGroups':_0x38cfd3[_0x185ee5(0x128)],'documentContextContent':_0x38cfd3[_0x185ee5(0xf2)],'showDiff':_0x218f3b[_0x185ee5(0x1a4)]});await this[_0x185ee5(0xf3)][_0x185ee5(0xc6)]({'id':_0x38cfd3['id'],'parts':_0x3f41d2,'renderingStrategy':_0x185ee5(0xd9)});}),this[_0x1d354c(0x122)](this[_0x1d354c(0xf3)],_0x1d354c(0x1a0),(_0x2fe401,{replyId:_0x2da844,partIndex:_0x2dfe35})=>{const _0x10597d=_0x1d354c;this[_0x10597d(0xcf)]?.[_0x10597d(0x116)]==_0x2da844&&this[_0x10597d(0xcf)]?.[_0x10597d(0x1d2)]==_0x2dfe35&&this[_0x10597d(0xf4)][_0x10597d(0xd0)][_0x10597d(0x114)](_0xc519a1)[_0x10597d(0x1e5)]();const {reply:_0x58406b}=this[_0x10597d(0x154)](_0x2da844);_0x58406b[_0x10597d(0x113)](_0x2dfe35,_0x10597d(0x204)),this[_0x10597d(0x155)][_0x10597d(0xf0)](_0x10597d(0x186));});}async[_0x19ee94(0xd1)](){const _0x10ff8a=_0x19ee94;this[_0x10ff8a(0xf4)]instanceof _0x5a2f64?this[_0x10ff8a(0x18b)](this[_0x10ff8a(0xf4)]):this[_0x10ff8a(0x122)](this[_0x10ff8a(0xf4)][_0x10ff8a(0xc3)],_0x10ff8a(0x11f),(_0x5a0488,_0x450693)=>{const _0x186ec1=_0x10ff8a;_0x450693['on'](_0x186ec1(0x14e),()=>{const _0x4add90=_0x186ec1;this[_0x4add90(0x18b)](_0x450693);});}),await this[_0x10ff8a(0x1b7)]();}[_0x19ee94(0xbf)](_0x189e9b){const _0x4e6b78=_0x19ee94,_0x3cd00e=_0xe358(this[_0x4e6b78(0xf4)]);if(!_0x3cd00e[_0x4e6b78(0xd0)][_0x4e6b78(0x1af)](_0x4e6b78(0xdf)))return;const _0x778601=this[_0x4e6b78(0xf4)][_0x4e6b78(0xd0)][_0x4e6b78(0x114)](_0x4e6b78(0x203)),{reply:_0xb04427,interaction:_0x1b2a57}=this[_0x4e6b78(0x154)](_0x189e9b[_0x4e6b78(0x116)]),_0x5b6a4c=this[_0x4e6b78(0x117)](_0x189e9b[_0x4e6b78(0x116)],_0x189e9b[_0x4e6b78(0x1d2)]),_0xbde51d=void 0x0!==_0x189e9b[_0x4e6b78(0x1d2)]?[_0xb04427[_0x4e6b78(0x128)][_0x189e9b[_0x4e6b78(0x1d2)]]]:_0xb04427[_0x4e6b78(0x128)][_0x4e6b78(0x133)](_0x240b49=>_0x4e6b78(0x10d)==_0x240b49[_0x4e6b78(0x18e)]),_0x510bce=_0xbde51d[_0x4e6b78(0xe0)](_0x392ad2=>_0xb04427[_0x4e6b78(0x128)][_0x4e6b78(0xf7)](_0x392ad2));_0x510bce[_0x4e6b78(0x1ff)](_0x537706=>_0xb04427[_0x4e6b78(0x113)](_0x537706,_0x4e6b78(0xc5)));const _0x2a1919=_0x2857f1({'editor':_0x3cd00e,'reply':_0xb04427,'interaction':_0x1b2a57,'groups':_0xbde51d,'transform':!0x0,'documentCompare':_0x778601,'documentCompareOptions':{'anchor':_0x4e6b78(0x16f),'markDeletions':!0x0}});let _0x25f559;_0x5b6a4c&&this[_0x4e6b78(0x14d)](_0x5b6a4c[_0x4e6b78(0x118)]),_0x3cd00e[_0x4e6b78(0xda)][_0x4e6b78(0xac)](_0x44db90=>{const _0x747bde=_0x4e6b78;_0x25f559=_0x44db90[_0x747bde(0x1e4)],_0x3cd00e[_0x747bde(0xd0)][_0x747bde(0x114)](_0x747bde(0xdf))[_0x747bde(0x176)](_0x2a1919),this[_0x747bde(0x155)][_0x747bde(0xf0)](_0x747bde(0x186));}),this[_0x4e6b78(0xc0)][_0x4e6b78(0xe5)](_0x25f559,{'interactionId':_0x1b2a57['id'],'replyId':_0xb04427['id'],'indexes':_0x510bce[_0x4e6b78(0x17d)]()}),this[_0x4e6b78(0x16e)](_0xb04427);}[_0x19ee94(0x101)](_0x562c64){const _0x565bf2=_0x19ee94,_0x53cfb6=_0xe358(this[_0x565bf2(0xf4)]),_0x59cf1e=this[_0x565bf2(0xf4)][_0x565bf2(0xd0)][_0x565bf2(0x114)](_0x2c7119),{reply:_0x323b49,interaction:_0x3cd19c}=this[_0x565bf2(0x154)](_0x562c64[_0x565bf2(0x116)]),_0x258ac4=this[_0x565bf2(0x117)](_0x562c64[_0x565bf2(0x116)],_0x562c64[_0x565bf2(0x1d2)]),_0x1b5820=void 0x0!==_0x562c64[_0x565bf2(0x1d2)]?[_0x323b49[_0x565bf2(0x128)][_0x562c64[_0x565bf2(0x1d2)]]]:_0x323b49[_0x565bf2(0x128)][_0x565bf2(0x133)](_0x5ec0d0=>_0x565bf2(0x10d)==_0x5ec0d0[_0x565bf2(0x18e)]),_0x48b923=_0x1b5820[_0x565bf2(0xe0)](_0x10de26=>_0x323b49[_0x565bf2(0x128)][_0x565bf2(0xf7)](_0x10de26));_0x48b923[_0x565bf2(0x1ff)](_0x416268=>_0x323b49[_0x565bf2(0x113)](_0x416268,_0x565bf2(0xc5)));const _0x39f871=_0x2857f1({'editor':_0x53cfb6,'reply':_0x323b49,'interaction':_0x3cd19c,'groups':_0x1b5820,'transform':!0x0,'documentCompare':_0x59cf1e,'documentCompareOptions':{'anchor':_0x565bf2(0x16f),'markDeletions':!0x1}});let _0x4d36b7;_0x258ac4&&this[_0x565bf2(0x14d)](_0x258ac4[_0x565bf2(0x118)]),_0x53cfb6[_0x565bf2(0xda)][_0x565bf2(0xac)](_0x1b9739=>{const _0x39f8b5=_0x565bf2;_0x4d36b7=_0x1b9739[_0x39f8b5(0x1e4)];for(const _0xcbc0ef of _0x39f871)_0xcbc0ef[_0x39f8b5(0x13a)]=_0x53cfb6[_0x39f8b5(0xda)][_0x39f8b5(0xef)][_0x39f8b5(0x1fc)],_0x1b9739[_0x39f8b5(0x1e4)][_0x39f8b5(0x153)](_0xcbc0ef),_0x53cfb6[_0x39f8b5(0xda)][_0x39f8b5(0x105)](_0xcbc0ef);}),this[_0x565bf2(0xc0)][_0x565bf2(0xe5)](_0x4d36b7,{'interactionId':_0x3cd19c['id'],'replyId':_0x323b49['id'],'indexes':_0x48b923[_0x565bf2(0x17d)]()}),this[_0x565bf2(0x16e)](_0x323b49);}[_0x19ee94(0x195)](_0x3deac4,_0x5c9e5d){const _0x2109ae=_0x19ee94,_0x50653b=_0xe358(this[_0x2109ae(0xf4)]),_0x1534a6=this[_0x2109ae(0x117)](_0x3deac4,_0x5c9e5d),_0x57d8c9=this[_0x2109ae(0xf4)][_0x2109ae(0xd0)][_0x2109ae(0x114)](_0xc519a1);if(!_0x1534a6)return void _0x57d8c9[_0x2109ae(0x1e5)]();const {range:_0x11f0d3,currentIndex:_0x1e012a,previousIndex:_0x273c05,nextIndex:_0x176315}=_0x1534a6;if(this[_0x2109ae(0xcf)]?.[_0x2109ae(0x116)]==_0x3deac4&&this[_0x2109ae(0xcf)]?.[_0x2109ae(0x1d2)]==_0x1e012a)return;this[_0x2109ae(0xcf)]={'replyId':_0x3deac4,'partIndex':_0x1e012a};const _0x229c2a=new _0x4a6bc9(_0x50653b[_0x2109ae(0x183)],{'showDiff':this[_0x2109ae(0x165)],'areActionsDisabled':!0x1,'miniToolbarConfig':{'showChanges':_0x2109ae(0xb6)},'hideHeader':!0x0}),{reply:_0x2dadf1}=this[_0x2109ae(0x154)](_0x3deac4),_0x19d11b=_0x121a6f({'editor':_0x50653b,'changeGroups':[_0x2dadf1[_0x2109ae(0x128)][_0x1e012a]],'documentContextContent':_0x2dadf1[_0x2109ae(0xf2)],'showDiff':this[_0x2109ae(0x165)]});_0x229c2a[_0x2109ae(0x1d5)]({'parts':_0x19d11b,'renderingStrategy':_0x2109ae(0xd9)});const _0x2ce6a6=_0x1e012a!==_0x273c05;this[_0x2109ae(0x14d)](_0x11f0d3,!0x0),_0x57d8c9[_0x2109ae(0x1f9)]({'index':_0x1e012a,'title':_0x410147(this[_0x2109ae(0xf4)][_0x2109ae(0x183)],_0x2109ae(0x15c),(_0x1e012a+0x1)[_0x2109ae(0xff)]()),'icon':_0x124f51,'mainView':_0x229c2a,'showRotator':_0x2ce6a6,'showApplyButton':!0x0,'showSuggestButton':!0x0,'ranges':[_0x11f0d3]}),this[_0x2109ae(0xf3)][_0x2109ae(0xc2)](_0x3deac4,_0x1e012a),this[_0x2109ae(0x122)](_0x229c2a,_0x2109ae(0xca),(_0x7d066f,{showDiff:_0x48ff9a})=>{const _0x17bc43=_0x2109ae;this[_0x17bc43(0x165)]=_0x48ff9a;const {reply:_0x4d656d}=this[_0x17bc43(0x154)](_0x3deac4),_0x4d3478=_0x121a6f({'editor':_0x50653b,'changeGroups':[_0x4d656d[_0x17bc43(0x128)][_0x1e012a]],'documentContextContent':_0x4d656d[_0x17bc43(0xf2)],'showDiff':_0x48ff9a});_0x229c2a[_0x17bc43(0x1d5)]({'parts':_0x4d3478,'renderingStrategy':_0x17bc43(0xd9)});}),this[_0x2109ae(0x122)](_0x57d8c9,_0x2109ae(0x174),()=>{const _0xede9ba=_0x2109ae;this[_0xede9ba(0x101)]({'replyId':_0x3deac4,'partIndex':_0x1e012a}),_0x2ce6a6?this[_0xede9ba(0x195)](_0x3deac4,_0x176315):_0x57d8c9[_0xede9ba(0x1e5)]();}),this[_0x2109ae(0x122)](_0x57d8c9,_0x2109ae(0x170),()=>{const _0x1daab7=_0x2109ae;this[_0x1daab7(0xbf)]({'replyId':_0x3deac4,'partIndex':_0x1e012a}),_0x2ce6a6?this[_0x1daab7(0x195)](_0x3deac4,_0x176315):_0x57d8c9[_0x1daab7(0x1e5)]();}),_0x2ce6a6&&(this[_0x2109ae(0x122)](_0x57d8c9,_0x2109ae(0xc1),()=>{const _0x45ab28=_0x2109ae;this[_0x45ab28(0x195)](_0x3deac4,_0x176315);}),this[_0x2109ae(0x122)](_0x57d8c9,_0x2109ae(0x1cb),()=>{const _0x2113a8=_0x2109ae;this[_0x2113a8(0x195)](_0x3deac4,_0x273c05);})),this[_0x2109ae(0x122)](_0x57d8c9,_0x2109ae(0x1fa),()=>{const _0x70aea0=_0x2109ae;this[_0x70aea0(0x190)](_0x57d8c9),this[_0x70aea0(0x190)](_0x229c2a),this[_0x70aea0(0xcf)]=null;});}[_0x19ee94(0x117)](_0x3094d1,_0x4de0c6){const _0x546cb7=_0x19ee94,_0x5b4f68=_0xe358(this[_0x546cb7(0xf4)]),{reply:_0xee9a37,interaction:_0x13d0eb}=this[_0x546cb7(0x154)](_0x3094d1),_0x4d7b63=_0xee9a37[_0x546cb7(0x128)][_0x546cb7(0x133)](_0x4ca146=>_0x546cb7(0x10d)==_0x4ca146[_0x546cb7(0x18e)]),_0x2aab94=_0x4d7b63[_0x546cb7(0xe0)](_0xf8e41a=>_0xee9a37[_0x546cb7(0x128)][_0x546cb7(0xf7)](_0xf8e41a));void 0x0===_0x4de0c6&&(_0x4de0c6=_0x2aab94[0x0]);const _0x2acaeb=_0x2aab94[_0x546cb7(0xf7)](_0x4de0c6);if(-0x1==_0x2acaeb)return null;const _0x1759c0=0x0==_0x2acaeb?_0x2aab94[_0x2aab94[_0x546cb7(0x1b8)]-0x1]:_0x2aab94[_0x2acaeb-0x1],_0x4e13e2=_0x2acaeb==_0x2aab94[_0x546cb7(0x1b8)]-0x1?_0x2aab94[0x0]:_0x2aab94[_0x2acaeb+0x1],_0x109543=_0x4d7b63[_0x2acaeb],_0xe3e6ad=new _0x5e6c42([]),_0x8822ed=new _0x5e6c42([]);for(const _0x39715e of _0x109543[_0x546cb7(0xb2)])if(_0x546cb7(0xe7)!=_0x39715e[_0x546cb7(0x110)]&&_0x8822ed[_0x546cb7(0x14b)][_0x546cb7(0x156)](_0x39715e[_0x546cb7(0x185)][_0x546cb7(0x167)](!0x0)),_0x546cb7(0x19b)!=_0x39715e[_0x546cb7(0x110)]){const _0x44713a=_0x17576e(_0x4fad0d=>_0x21da1a(_0x4fad0d,_0x546cb7(0x16a))==_0x39715e['id'],_0xee9a37[_0x546cb7(0xf2)],!0x0);_0xe3e6ad[_0x546cb7(0x14b)][_0x546cb7(0x156)](_0x44713a[_0x546cb7(0x167)](!0x0));}if(0x0==_0xe3e6ad[_0x546cb7(0x14b)][_0x546cb7(0x1b8)]){if(_0x109543[_0x546cb7(0xb2)][0x0][_0x546cb7(0x1a5)]){const _0x2ea1e7=_0x420881(_0x546cb7(0x16a),_0x109543[_0x546cb7(0xb2)][0x0][_0x546cb7(0x1a5)],_0xee9a37[_0x546cb7(0xf2)]);_0xe3e6ad[_0x546cb7(0x14b)][_0x546cb7(0x18a)](_0x2ea1e7[_0x546cb7(0x167)](!0x0)),_0x8822ed[_0x546cb7(0x14b)][_0x546cb7(0x18a)](_0x2ea1e7[_0x546cb7(0x167)](!0x0)),_0x2ea1e7[_0x546cb7(0x132)]&&(_0xe3e6ad[_0x546cb7(0x14b)][_0x546cb7(0x156)](_0x2ea1e7[_0x546cb7(0x132)][_0x546cb7(0x167)](!0x0)),_0x8822ed[_0x546cb7(0x14b)][_0x546cb7(0x156)](_0x2ea1e7[_0x546cb7(0x132)][_0x546cb7(0x167)](!0x0)));}else{const _0x43e7d5=_0xee9a37[_0x546cb7(0xf2)][_0x546cb7(0x14b)][0x0];if(!_0x43e7d5)return null;_0xe3e6ad[_0x546cb7(0x14b)][_0x546cb7(0x156)](_0x43e7d5[_0x546cb7(0x167)](!0x0)),_0x8822ed[_0x546cb7(0x14b)][_0x546cb7(0x156)](_0x43e7d5[_0x546cb7(0x167)](!0x0));}}const _0x44ea63=_0x13d0eb[_0x546cb7(0xe9)](),_0x188140=_0x5b4f68[_0x546cb7(0x1bd)][_0x546cb7(0x108)](_0x44ea63[_0x546cb7(0x1b2)]),_0x41cd1=_0x5571d8(_0xe3e6ad),_0x5cd4b0=_0x5b4f68[_0x546cb7(0x1bd)][_0x546cb7(0x108)](_0x41cd1),_0x42893e=_0x5b4f68[_0x546cb7(0x1bd)][_0x546cb7(0x108)](_0x41cd1),_0x4e90ec=_0x5b4f68[_0x546cb7(0xda)][_0x546cb7(0x10b)](_0x5cd4b0,0x0),_0x248ea8=_0x5571d8(_0x8822ed),_0x202d28={'anchor':_0x4e90ec,'markDeletions':!0x1},_0x593bac=_0x5b4f68[_0x546cb7(0xd0)][_0x546cb7(0x114)](_0x2c7119)[_0x546cb7(0x18f)](_0x41cd1,_0x248ea8,_0x202d28)[_0x546cb7(0x11a)]();if(!_0x593bac[_0x546cb7(0x1b8)])return null;_0x5b4f68[_0x546cb7(0xda)][_0x546cb7(0xac)](_0x53709a=>{const _0xed24df=_0x546cb7;for(const _0x37c5dc of _0x593bac)if(_0xed24df(0x1e2)==_0x37c5dc[_0xed24df(0x110)]){const _0xc0f881=_0x37c5dc[_0xed24df(0x10f)],_0x5dfbb7=_0x37c5dc[_0xed24df(0x16b)],_0x992e01=new _0xcc7966(_0xc0f881,_0x5dfbb7);_0x53709a[_0xed24df(0x1e4)][_0xed24df(0x153)](_0x992e01),_0x5b4f68[_0xed24df(0xda)][_0xed24df(0x105)](_0x992e01);}else _0xed24df(0x1c1)!==_0x37c5dc[_0xed24df(0x110)]&&(_0x37c5dc[_0xed24df(0x13a)]=null,_0x37c5dc[_0xed24df(0x1bc)]=!0x1,_0x53709a[_0xed24df(0x1e4)][_0xed24df(0x153)](_0x37c5dc),_0x5b4f68[_0xed24df(0xda)][_0xed24df(0x105)](_0x37c5dc));});const _0x316aa9=_0x2f69f3(_0x5b4f68,_0x593bac,_0x5cd4b0);_0x58915b(_0x5b4f68[_0x546cb7(0xda)],_0x316aa9);const _0x295897=_0x316aa9[_0x546cb7(0xcc)]()[_0x546cb7(0x140)][_0x546cb7(0x11b)][_0x546cb7(0x17d)](),_0x1753da=_0x316aa9[_0x546cb7(0xcc)]()[_0x546cb7(0x184)][_0x546cb7(0x11b)][_0x546cb7(0x17d)](),_0x295641=[];let _0xca84c0=_0x5cd4b0,_0x4b4f83=_0x42893e;for(let _0x173915=0x0;_0x173915<_0x1753da[_0x546cb7(0x1b8)];_0x173915++){const _0x3b9a01=_0xca84c0[_0x546cb7(0x131)]-_0x1753da[_0x173915];_0x295641[_0x173915]=_0x4b4f83[_0x546cb7(0x131)]-_0x3b9a01,_0xca84c0=_0xca84c0[_0x546cb7(0x1d1)](_0x1753da[_0x173915]),_0x4b4f83=_0x4b4f83[_0x546cb7(0x1d1)](_0x295641[_0x173915]);}const _0x144b9f=_0x5b4f68[_0x546cb7(0xda)][_0x546cb7(0x1c3)](_0x5b4f68[_0x546cb7(0xda)][_0x546cb7(0x1ce)](_0x42893e,_0x295897),_0x5b4f68[_0x546cb7(0xda)][_0x546cb7(0x1ce)](_0x42893e,_0x295641)),_0x5976a6=_0x42893e[_0x546cb7(0x166)](0x0)[_0x546cb7(0x1a9)](_0x2adcc9),_0x41c8ac=Array[_0x546cb7(0x171)](_0x188140[_0x546cb7(0x1e9)]())[_0x546cb7(0x1dc)](_0x3dc477=>_0x3dc477[_0x546cb7(0x1a9)](_0x2adcc9)==_0x5976a6)[_0x546cb7(0x144)](),_0x1efd47=_0x144b9f[_0x546cb7(0x140)][_0x546cb7(0x11b)][_0x546cb7(0x17d)](),_0x1d8489=_0x144b9f[_0x546cb7(0x184)][_0x546cb7(0x11b)][_0x546cb7(0x17d)]();_0x1efd47[0x0]=_0x41c8ac[0x0]+_0x1efd47[0x0],_0x1d8489[0x0]=_0x41c8ac[0x0]+_0x1d8489[0x0];let _0x5d6306=_0x5b4f68[_0x546cb7(0xda)][_0x546cb7(0x1c3)](_0x5b4f68[_0x546cb7(0xda)][_0x546cb7(0x1ce)](_0x5b4f68[_0x546cb7(0xda)][_0x546cb7(0xef)][_0x546cb7(0x169)](),_0x1efd47),_0x5b4f68[_0x546cb7(0xda)][_0x546cb7(0x1ce)](_0x5b4f68[_0x546cb7(0xda)][_0x546cb7(0xef)][_0x546cb7(0x169)](),_0x1d8489));const _0x303e02=_0x5b4f68[_0x546cb7(0xda)][_0x546cb7(0xef)][_0x546cb7(0x125)][_0x546cb7(0x11a)](_0x44ea63[_0x546cb7(0x1fc)]);for(const _0xdfdc56 of _0x303e02)_0x5d6306=_0x2e571f[_0x546cb7(0x15b)](_0x5d6306[_0x546cb7(0x200)](_0xdfdc56));return{'range':_0x5d6306,'previousIndex':_0x1759c0,'nextIndex':_0x4e13e2,'currentIndex':_0x4de0c6};}[_0x19ee94(0x18b)](_0xe936ed){const _0xc7656=_0x19ee94;if(!_0xe936ed[_0xc7656(0xd0)][_0xc7656(0x1af)](_0xc7656(0x19e)))return;const _0x4e57f9=_0xe936ed[_0xc7656(0x1d3)][_0xc7656(0x114)](_0xc7656(0x12d)),_0x2117ea=_0xe936ed[_0xc7656(0x1d3)][_0xc7656(0x114)](_0xc7656(0xf5));this[_0xc7656(0x122)](_0x4e57f9,_0xc7656(0x142),(_0x5d2583,_0x830021,_0x3f0dc3)=>{const _0x6d8cba=_0xc7656,_0x3103b3=this[_0x6d8cba(0xc0)][_0x6d8cba(0x114)](_0x830021);if(!_0x3103b3)return;const _0x50ae7a=this[_0x6d8cba(0x159)][_0x6d8cba(0x15f)](_0x3103b3[_0x6d8cba(0x1be)])[_0x6d8cba(0x145)](_0x3103b3[_0x6d8cba(0x116)]);_0x3103b3[_0x6d8cba(0x138)][_0x6d8cba(0x1ff)](_0xe14b4=>_0x50ae7a[_0x6d8cba(0x113)](_0xe14b4,_0x6d8cba(0x10d))),this[_0x6d8cba(0xc0)][_0x6d8cba(0x1aa)](_0x830021),this[_0x6d8cba(0xc0)][_0x6d8cba(0xe5)](_0x3f0dc3,_0x3103b3);}),this[_0xc7656(0x122)](_0x2117ea,_0xc7656(0x142),(_0xe2036c,_0xb6c1f,_0x25dbd5)=>{const _0xd85094=_0xc7656,_0x208a72=this[_0xd85094(0xc0)][_0xd85094(0x114)](_0xb6c1f);if(!_0x208a72)return;const _0x38dc8b=this[_0xd85094(0x159)][_0xd85094(0x15f)](_0x208a72[_0xd85094(0x1be)])[_0xd85094(0x145)](_0x208a72[_0xd85094(0x116)]);_0x208a72[_0xd85094(0x138)][_0xd85094(0x1ff)](_0x269230=>_0x38dc8b[_0xd85094(0x113)](_0x269230,_0xd85094(0xc5))),this[_0xd85094(0xc0)][_0xd85094(0x1aa)](_0xb6c1f),this[_0xd85094(0xc0)][_0xd85094(0xe5)](_0x25dbd5,_0x208a72);});}async[_0x19ee94(0x1fb)](_0xdd5a12){const _0x214101=_0x19ee94;this[_0x214101(0xf4)][_0x214101(0xd0)][_0x214101(0x114)](_0xc519a1)[_0x214101(0x1e5)](),this[_0x214101(0xf3)][_0x214101(0x120)](_0x214101(0xd9)),this[_0x214101(0xf3)][_0x214101(0x112)](!0x0),await this[_0x214101(0x191)]();try{const _0x4cb14c=this[_0x214101(0xf4)][_0x214101(0xd0)][_0x214101(0x114)](_0x351dd5);this[_0x214101(0x1b5)]('\x20'),_0x4cb14c[_0x214101(0x107)][_0x214101(0x1e7)](_0x214101(0x1ea)),await this[_0x214101(0x1b7)](_0xdd5a12);const {sessionId:_0x3f341e}=this[_0x214101(0x155)][_0x214101(0xe1)]();await this[_0x214101(0x159)][_0x214101(0x197)](_0xdd5a12,_0x3f341e),this[_0x214101(0x159)][_0x214101(0x135)]()&&this[_0x214101(0x159)][_0x214101(0x1db)](_0x410147(this[_0x214101(0xf4)][_0x214101(0x183)],_0x214101(0xb4)));}catch(_0x324021){console[_0x214101(0xce)](_0x214101(0x146),_0x324021);}finally{this[_0x214101(0xf3)][_0x214101(0x120)](_0x214101(0xde)),this[_0x214101(0xf3)][_0x214101(0x112)](!0x1);}}[_0x19ee94(0x1ac)](_0x204472){const _0x227533=_0x19ee94;this[_0x227533(0x159)]['id']===_0x204472&&this[_0x227533(0x1b7)]();}async[_0x19ee94(0x1cd)](){const _0x1762c8=_0x19ee94,_0xba676a=this[_0x1762c8(0x155)][_0x1762c8(0x17f)]();this[_0x1762c8(0x159)]?.[_0x1762c8(0x19a)](_0xba676a),this[_0x1762c8(0x159)]?.[_0x1762c8(0x1db)](_0x410147(this[_0x1762c8(0xf4)][_0x1762c8(0x183)],_0x1762c8(0xb4)));}[_0x19ee94(0x11d)](){const _0x10ccc6=_0x19ee94;this[_0x10ccc6(0x159)]?.[_0x10ccc6(0x1c9)]();}[_0x19ee94(0xea)](){const _0xbcc32=_0x19ee94;this[_0xbcc32(0xf3)][_0xbcc32(0xea)]();}async[_0x19ee94(0x1df)](){const _0xc3ccb3=_0x19ee94;await this[_0xc3ccb3(0x1b7)]();}async[_0x19ee94(0x182)]({message:_0x87bf75,quickActionData:_0x3932b1}){const _0x299586=_0x19ee94;await this[_0x299586(0x14c)]({'userMessage':_0x87bf75,'quickActionData':_0x3932b1});}[_0x19ee94(0x1bb)](){const _0x540bd6=_0x19ee94,_0x13ecf8=this[_0x540bd6(0xf4)][_0x540bd6(0x1a6)][_0x540bd6(0x114)](_0x540bd6(0x196));if(!_0x13ecf8)throw new _0x555cfc(_0x540bd6(0x178),this);return _0x13ecf8;}async[_0x19ee94(0x1b7)](_0x98e2e1){const _0x495fdb=_0x19ee94;try{this[_0x495fdb(0xf3)][_0x495fdb(0x1ba)](),await this[_0x495fdb(0x1b3)](_0x98e2e1);}catch(_0x4ef654){_0x322e37(_0x495fdb(0x1e8),_0x4ef654),this[_0x495fdb(0x159)]=void 0x0,this[_0x495fdb(0xf3)][_0x495fdb(0x163)]();}}async[_0x19ee94(0x1b3)](_0x3f8efe){const _0x1c5d79=_0x19ee94,_0x31f967=this[_0x1c5d79(0xf4)][_0x1c5d79(0xd0)][_0x1c5d79(0x114)](_0xc519a1);let _0x95ba5;_0x31f967[_0x1c5d79(0x130)]&&_0x31f967[_0x1c5d79(0x1e5)](),_0x95ba5=_0x3f8efe||!this[_0x1c5d79(0x159)]?this[_0x1c5d79(0xf4)][_0x1c5d79(0x1a6)][_0x1c5d79(0x114)](_0x1c5d79(0x188)):this[_0x1c5d79(0x159)][_0x1c5d79(0x1b4)]['id'],await this[_0x1c5d79(0x191)]();const _0x14e99f=this[_0x1c5d79(0x1bb)](),_0x4cb184=_0x3f8efe||_0x1dc6c9();this[_0x1c5d79(0x159)]=new _0x3aaab2({'connector':this[_0x1c5d79(0x1eb)],'chatModels':this[_0x1c5d79(0x1b6)],'defaultModelId':_0x95ba5,'conversationId':_0x4cb184,'group':_0x14e99f,'getEditor':()=>_0xe358(this[_0x1c5d79(0xf4)])}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0x16c),(_0x5edc99,_0x15bc18)=>{const _0x2bd622=_0x1c5d79;_0x15bc18[_0x2bd622(0x1a7)]=this[_0x2bd622(0x104)](_0x15bc18[_0x2bd622(0x1a7)],this[_0x2bd622(0xf4)][_0x2bd622(0x1a6)][_0x2bd622(0x114)](_0x2bd622(0x148))),this[_0x2bd622(0xf3)][_0x2bd622(0x187)](_0x15bc18),this[_0x2bd622(0xf3)][_0x2bd622(0x181)](),this[_0x2bd622(0xf3)][_0x2bd622(0xd6)](),this[_0x2bd622(0xf3)][_0x2bd622(0x109)](),_0x3f8efe||(this[_0x2bd622(0xf3)][_0x2bd622(0xcb)](),this[_0x2bd622(0x159)]?.[_0x2bd622(0x1db)](_0x410147(this[_0x2bd622(0xf4)][_0x2bd622(0x183)],_0x2bd622(0xb4))));}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0x1f3),(_0x5c179b,_0x5107fe)=>{const _0x376850=_0x1c5d79;this[_0x376850(0xf3)][_0x376850(0x143)](_0x5107fe[_0x376850(0x1f1)]);}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0xc9),(_0x1c7d06,_0xb1c7f3)=>{const _0x201e90=_0x1c5d79;this[_0x201e90(0xf3)][_0x201e90(0x1b0)](_0xb1c7f3);}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0x141),()=>{const _0x4a3db6=_0x1c5d79;this[_0x4a3db6(0xf3)][_0x4a3db6(0xbc)]({'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0x1f5),()=>{const _0x1cad05=_0x1c5d79;this[_0x1cad05(0xf3)][_0x1cad05(0xbc)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0x1f7),(_0x171174,_0x5c55bc)=>{const _0x388f9d=_0x1c5d79;this[_0x388f9d(0xf3)][_0x388f9d(0xaf)](_0x5c55bc,{'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0xdc),(_0x18ac3c,_0x25947b)=>{const _0x322a96=_0x1c5d79;this[_0x322a96(0xf3)][_0x322a96(0xaf)](_0x25947b,{'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0xf1),()=>{const _0x2d3dea=_0x1c5d79;this[_0x2d3dea(0xf3)][_0x2d3dea(0x123)]();}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0x1d4),async()=>{const _0xc53017=_0x1c5d79;await this[_0xc53017(0xf3)][_0xc53017(0x193)]();}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0x11c),(_0x3d049b,_0x18e419)=>{const _0x35c28d=_0x1c5d79;this[_0x35c28d(0xf3)][_0x35c28d(0xd8)](_0x18e419['id']);}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0x17e),(_0x1b53f8,_0x1ab49e,_0x343d54)=>{const _0x2cc842=_0x1c5d79;this[_0x2cc842(0x1b5)](_0x1ab49e,_0x343d54);}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0x102),(_0x1629bc,_0x2d94b6)=>{const _0xb7bd75=_0x1c5d79;_0xb7bd75(0xad)===_0x2d94b6[_0xb7bd75(0x110)]?this[_0xb7bd75(0xf3)][_0xb7bd75(0x1d0)](_0x2d94b6):this[_0xb7bd75(0xf3)][_0xb7bd75(0xd7)](_0x2d94b6);}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0xdb),async(_0x1f8ecd,_0x2dd1dc,_0x34ecc0)=>{const _0x5af4f3=_0x1c5d79;await this[_0x5af4f3(0xfc)]({'reply':_0x2dd1dc,'changeGroups':_0x34ecc0});}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0x17c),(_0x244b1b,{reply:_0x183280,index:_0xcacf84,state:_0x8d9950})=>{const _0x2a95bc=_0x1c5d79;this[_0x2a95bc(0xf3)][_0x2a95bc(0x1f2)]({'id':_0x183280['id'],'index':_0xcacf84,'state':_0x8d9950});}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0x1ca),(_0x28864e,_0x1ba5de)=>{const _0x5398c5=_0x1c5d79;if(this[_0x5398c5(0xf3)][_0x5398c5(0x1ab)](_0x1ba5de[_0x5398c5(0x1b1)],_0x1ba5de[_0x5398c5(0x1ed)]),_0x5398c5(0x1d8)===_0x1ba5de[_0x5398c5(0x1b1)][_0x5398c5(0x110)]){const _0x51ebe0=[..._0xe358(this[_0x5398c5(0xf4)])[_0x5398c5(0xda)][_0x5398c5(0xef)][_0x5398c5(0x1d8)][_0x5398c5(0x180)]()];this[_0x5398c5(0x155)][_0x5398c5(0x19c)](_0x51ebe0,_0x5398c5(0x103)+this[_0x5398c5(0x159)]?.['id']);}}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0x106),(_0x377fed,_0x2595e2)=>{const _0x4aa88e=_0x1c5d79;this[_0x4aa88e(0xf3)][_0x4aa88e(0x173)](_0x2595e2[_0x4aa88e(0xb5)]),_0x4aa88e(0x1da)==_0x2595e2[_0x4aa88e(0xb5)]&&this[_0x4aa88e(0x11d)](),_0x4aa88e(0x1d8)===_0x2595e2[_0x4aa88e(0x110)]&&this[_0x4aa88e(0x155)][_0x4aa88e(0xf0)](_0x4aa88e(0x103)+this[_0x4aa88e(0x159)]?.['id']);}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0x158),(_0x19b9c9,_0xd3a4f)=>{const _0xa56bfb=_0x1c5d79;this[_0xa56bfb(0xf3)][_0xa56bfb(0xd3)](_0xd3a4f[_0xa56bfb(0x1b1)][_0xa56bfb(0xb5)],_0xd3a4f[_0xa56bfb(0x1ed)]);}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0x1a8),(_0x21f0d6,_0x28743a)=>{const _0x5b627c=_0x1c5d79;this[_0x5b627c(0xf3)][_0x5b627c(0x164)](_0x28743a[_0x5b627c(0x157)]);}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0xc7),(_0x461f0d,_0x113ecf)=>{const _0x44db50=_0x1c5d79;this[_0x44db50(0xf3)][_0x44db50(0x1ef)](_0x113ecf[_0x44db50(0xfd)]);}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0x1c8),(_0x341f85,_0x2b876e)=>{const _0x44d0da=_0x1c5d79;this[_0x44d0da(0xf3)][_0x44d0da(0x1e0)](_0x2b876e[_0x44d0da(0x201)],_0x2b876e[_0x44d0da(0xe8)],_0x2b876e[_0x44d0da(0x198)],_0x2b876e[_0x44d0da(0x1a1)]);}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0xb0),(_0x4f7f4e,_0x45667d)=>{const _0x49fcd0=_0x1c5d79;this[_0x49fcd0(0xf3)][_0x49fcd0(0xb8)](_0x45667d[_0x49fcd0(0x201)],_0x45667d[_0x49fcd0(0x199)],_0x45667d[_0x49fcd0(0x1dd)]);}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0x14f),(_0x30ba25,_0x480f0f)=>{const _0x12c6df=_0x1c5d79;this[_0x12c6df(0xf3)][_0x12c6df(0x13d)](_0x480f0f);}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0x1f4),(_0x8b05a6,_0x3a42f7)=>{const _0x3e7cf3=_0x1c5d79;this[_0x3e7cf3(0xf3)][_0x3e7cf3(0xe3)](_0x3a42f7[_0x3e7cf3(0x1b4)],_0x3a42f7[_0x3e7cf3(0x13c)]);}),this[_0x1c5d79(0x159)]['on'](_0x1c5d79(0xce),(_0x31b6e3,{error:_0x1615a7,interactionId:_0x34f759,fileName:_0x58302a,url:_0x457069,sourceId:_0x12e647,sourceLabel:_0x1e09c6})=>{const _0x56ee44=_0x1c5d79,_0x2f692e=_0x34f759?_0x34f759+':'+_0x1dc6c9():_0x1dc6c9();_0x1615a7[_0x56ee44(0x1c6)][_0x56ee44(0x12a)](_0x56ee44(0x13f))?this[_0x56ee44(0xf3)][_0x56ee44(0xcd)]({'staticMessage':_0x410147(this[_0x56ee44(0xf4)][_0x56ee44(0x183)],_0x56ee44(0x18c)),'id':_0x2f692e}):_0x1615a7[_0x56ee44(0x1c6)][_0x56ee44(0x12a)](_0x56ee44(0xf9))||_0x1615a7[_0x56ee44(0x1c6)][_0x56ee44(0x12a)](_0x56ee44(0x1e8))?(this[_0x56ee44(0xf3)][_0x56ee44(0x17b)]({'errorMessage':_0x410147(this[_0x56ee44(0xf4)][_0x56ee44(0x183)],_0x56ee44(0xfa)),'id':_0x2f692e}),this[_0x56ee44(0xbd)](_0x1615a7)):_0x1615a7[_0x56ee44(0x1c6)][_0x56ee44(0x12a)](_0x56ee44(0x18d))?this[_0x56ee44(0xf3)][_0x56ee44(0x17b)]({'errorMessage':_0x410147(this[_0x56ee44(0xf4)][_0x56ee44(0x183)],_0x56ee44(0x192),_0x58302a),'id':_0x2f692e}):_0x1615a7[_0x56ee44(0x1c6)][_0x56ee44(0x12a)](_0x56ee44(0x1cf))?this[_0x56ee44(0xf3)][_0x56ee44(0x17b)]({'errorMessage':_0x410147(this[_0x56ee44(0xf4)][_0x56ee44(0x183)],_0x56ee44(0xdd),_0x457069),'id':_0x2f692e}):_0x1615a7[_0x56ee44(0x1c6)][_0x56ee44(0x12a)](_0x56ee44(0x124))?this[_0x56ee44(0xf3)][_0x56ee44(0x17b)]({'errorMessage':_0x410147(this[_0x56ee44(0xf4)][_0x56ee44(0x183)],_0x56ee44(0x177)),'id':_0x2f692e}):_0x1615a7[_0x56ee44(0x1c6)][_0x56ee44(0x12a)](_0x56ee44(0x115))?this[_0x56ee44(0xf3)][_0x56ee44(0x17b)]({'errorMessage':_0x410147(this[_0x56ee44(0xf4)][_0x56ee44(0x183)],_0x56ee44(0x121)),'id':_0x2f692e}):_0x1615a7[_0x56ee44(0x1c6)][_0x56ee44(0x12a)](_0x56ee44(0x168))?(_0x12e647&&this[_0x56ee44(0xf3)][_0x56ee44(0xeb)](_0x12e647),this[_0x56ee44(0xf3)][_0x56ee44(0x17b)]({'errorMessage':_0x410147(this[_0x56ee44(0xf4)][_0x56ee44(0x183)],_0x56ee44(0x1a2),_0x1e09c6||_0x56ee44(0xe8)),'id':_0x2f692e}),this[_0x56ee44(0xbd)](_0x1615a7)):_0x1615a7[_0x56ee44(0x1c6)][_0x56ee44(0x12a)](_0x56ee44(0xd4))?(this[_0x56ee44(0xf3)][_0x56ee44(0x17b)]({'errorMessage':_0x410147(this[_0x56ee44(0xf4)][_0x56ee44(0x183)],_0x56ee44(0x1c5)),'id':_0x2f692e}),this[_0x56ee44(0xbd)](_0x1615a7)):(this[_0x56ee44(0xf3)][_0x56ee44(0x17b)]({'errorMessage':_0x410147(this[_0x56ee44(0xf4)][_0x56ee44(0x183)],_0x56ee44(0x202)),'id':_0x2f692e}),this[_0x56ee44(0xbd)](_0x1615a7));}),await this[_0x1c5d79(0x159)][_0x1c5d79(0x1d7)](this[_0x1c5d79(0xf4)][_0x1c5d79(0x1a6)][_0x1c5d79(0x114)](_0x1c5d79(0x151))),_0x3f8efe||await this[_0x1c5d79(0x159)][_0x1c5d79(0x140)]();}async[_0x19ee94(0x14c)]({userMessage:_0xabc6a9,quickActionData:_0x5f57d3}){const _0x3ef7a9=_0x19ee94;if(!this[_0x3ef7a9(0x159)])throw new _0x555cfc(_0x3ef7a9(0x160));this[_0x3ef7a9(0x159)][_0x3ef7a9(0xc8)]()&&await this[_0x3ef7a9(0x159)][_0x3ef7a9(0xe6)](this[_0x3ef7a9(0x155)][_0x3ef7a9(0xe1)]()),this[_0x3ef7a9(0x159)]['id']&&this[_0x3ef7a9(0x159)][_0x3ef7a9(0xe4)]&&await this[_0x3ef7a9(0x159)][_0x3ef7a9(0xba)]({'userMessage':_0xabc6a9,'quickActionData':_0x5f57d3}),this[_0x3ef7a9(0xec)]();}[_0x19ee94(0xec)](){const _0x52d23a=_0x19ee94,_0x3fe8a8=_0xe358(this[_0x52d23a(0xf4)])[_0x52d23a(0xda)],_0x1abc0a=Array[_0x52d23a(0x171)](_0x3fe8a8[_0x52d23a(0x129)][_0x52d23a(0x1cc)](_0x2d0105));_0x3fe8a8[_0x52d23a(0xac)](_0x2abfd8=>{const _0xe36fc0=_0x52d23a;_0x1abc0a[_0xe36fc0(0x1ff)](_0x2dd824=>_0x2abfd8[_0xe36fc0(0x137)](_0x2dd824));});}[_0x19ee94(0x19f)](){const _0x4f6cc0=_0x19ee94;console[_0x4f6cc0(0x1a3)](_0x4f6cc0(0x15d));}[_0x19ee94(0x1fe)](_0x56892c){const _0x10982e=_0x19ee94;this[_0x10982e(0xf3)][_0x10982e(0x147)](_0x56892c);}[_0x19ee94(0xbd)](_0x452e88){const _0x2556d7=_0x19ee94;_0x322e37(_0x452e88[_0x2556d7(0x1c6)]);}[_0x19ee94(0xed)](_0x48afc0){const _0x16bea1=_0x19ee94;this[_0x16bea1(0x159)]?.[_0x16bea1(0x10a)](_0x48afc0);}[_0x19ee94(0x13b)](){const _0x18c3bd=_0x19ee94;this[_0x18c3bd(0x159)]?.[_0x18c3bd(0xd5)]();}[_0x19ee94(0x12e)](){const _0x4319b6=_0x19ee94;this[_0x4319b6(0x159)]?.[_0x4319b6(0x1ec)]();}[_0x19ee94(0x154)](_0x4c1cbd){const _0x574b36=_0x19ee94,[_0x132851,_0x18af95]=_0x4c1cbd[_0x574b36(0xbe)](':'),_0x23dd87=this[_0x574b36(0x159)][_0x574b36(0x15f)](_0x132851),_0x221888=_0x23dd87[_0x574b36(0x145)](_0x18af95);return{'interaction':_0x23dd87,'reply':_0x221888};}[_0x19ee94(0x14d)](_0x428864,_0x1f31d0=!0x1){const _0x3aa614=_0x19ee94,_0x55fe0b=_0xe358(this[_0x3aa614(0xf4)]),_0x33e8b2={'target':_0x55fe0b[_0x3aa614(0x16d)][_0x3aa614(0x107)][_0x3aa614(0x1c2)][_0x3aa614(0x100)](_0x55fe0b[_0x3aa614(0x16d)][_0x3aa614(0x13e)][_0x3aa614(0x139)](_0x428864)),'viewportOffset':{'top':0x96,'left':0x0,'bottom':0x32,'right':0x0},'ancestorOffset':0x14,'alignToTop':_0x1f31d0};_0x1f31d0&&(_0x33e8b2[_0x3aa614(0x136)]=!0x0),_0x360cfb(_0x33e8b2);}[_0x19ee94(0x1b5)](_0x41da20,_0x795a4b=!0x1){const _0x3afe3b=_0x19ee94;this[_0x3afe3b(0xf3)][_0x3afe3b(0x17e)](_0x41da20||_0x410147(this[_0x3afe3b(0xf4)][_0x3afe3b(0x183)],_0x3afe3b(0x1fd)),_0x795a4b);}[_0x19ee94(0x104)](_0x3b7817,_0x56f45b){const _0x3ce1a7=_0x19ee94;let _0x2fe763;if(_0x56f45b){_0x2fe763=[];const _0x212a8a=_0x3ce1a7(0x1f8)==typeof _0x56f45b?[_0x56f45b[_0x3ce1a7(0x1d9)]()]:_0x56f45b[_0x3ce1a7(0xe0)](_0x4e1fa2=>_0x4e1fa2[_0x3ce1a7(0x1d9)]());for(const _0x222010 of _0x212a8a)for(const _0xc5541f of _0x3b7817)(_0xc5541f['id'][_0x3ce1a7(0x1d9)]()===_0x222010||_0xc5541f[_0x3ce1a7(0xee)][_0x3ce1a7(0x1d9)]()===_0x222010||_0xc5541f[_0x3ce1a7(0x1b9)][_0x3ce1a7(0x1d9)]()===_0x222010||_0xc5541f['id'][_0x3ce1a7(0x1d9)]()[_0x3ce1a7(0x12a)](_0x222010))&&_0x2fe763[_0x3ce1a7(0x156)](_0xc5541f);}else _0x2fe763=_0x3b7817;return _0x2fe763;}async[_0x19ee94(0xfc)]({reply:_0x52d04d,changeGroups:_0x4e2f80,renderingStrategy:_0x384d3c}){const _0x5b6e6c=_0x19ee94,{id:_0xded5f,isDone:_0x1e6c1a,type:_0xa2ce48,parsedContent:_0x174c07}=_0x52d04d;if(_0x5b6e6c(0x12c)===_0xa2ce48){const _0x386c09=_0xe358(this[_0x5b6e6c(0xf4)]),_0x51c92f=_0x121a6f({'editor':_0x386c09,'showDiff':this[_0x5b6e6c(0xf3)][_0x5b6e6c(0x1a4)],'changeGroups':_0x4e2f80,'documentContextContent':_0x52d04d[_0x5b6e6c(0xf2)]});await this[_0x5b6e6c(0xf3)][_0x5b6e6c(0xc6)]({'id':_0xded5f,'parts':_0x51c92f,'renderingStrategy':_0x384d3c,'isDone':_0x1e6c1a});}else _0x5b6e6c(0xad)===_0xa2ce48&&await this[_0x5b6e6c(0xf3)][_0x5b6e6c(0x1c7)]({'id':_0xded5f,'parsedContent':_0x174c07,'renderingStrategy':_0x384d3c,'isDone':_0x1e6c1a});_0x1e6c1a&&_0x52d04d[_0x5b6e6c(0x1f0)][_0x5b6e6c(0x1b8)]>0x0&&this[_0x5b6e6c(0xf3)][_0x5b6e6c(0x1c4)](_0xded5f,_0x52d04d[_0x5b6e6c(0x1f0)]);}async[_0x19ee94(0x191)](){const _0x25618c=_0x19ee94,_0x34aa38=this[_0x25618c(0x159)]?.[_0x25618c(0x1ad)];_0x34aa38&&(_0x34aa38[_0x25618c(0x111)](),this[_0x25618c(0xf3)][_0x25618c(0x172)](_0x34aa38));}async[_0x19ee94(0x194)](){const _0xd279e3=_0x19ee94,_0x2355a7=this[_0xd279e3(0x159)]?.[_0xd279e3(0x1ad)];if(_0x2355a7){for await(const _0x23e0ea of _0x2355a7[_0xd279e3(0x179)])await this[_0xd279e3(0xfc)]({'reply':_0x23e0ea,'changeGroups':_0x23e0ea[_0xd279e3(0x128)],'renderingStrategy':_0xd279e3(0xd9)});}}[_0x19ee94(0x16e)](_0x57afcb){const _0x4a7fee=_0x19ee94,_0x1385c9={'positiveCount':_0x57afcb[_0x4a7fee(0x128)][_0x4a7fee(0x133)](_0x4e5497=>_0x4a7fee(0xc5)===_0x4e5497[_0x4a7fee(0x18e)])[_0x4a7fee(0x1b8)],'totalCount':_0x57afcb[_0x4a7fee(0x128)][_0x4a7fee(0x1b8)]},_0x2e4a32=this[_0x4a7fee(0x159)][_0x4a7fee(0x15f)](_0x57afcb[_0x4a7fee(0x1be)])[_0x4a7fee(0x152)];this[_0x4a7fee(0x1eb)][_0x4a7fee(0x1d6)](this[_0x4a7fee(0x159)]['id'],_0x2e4a32,_0x1385c9);}}
|
package/src/aichat/aichatui.js
CHANGED
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const _0x2f9983=_0x572b;function _0x572b(_0x5739a9,_0x348283){const _0x2ee647=_0x2ee6();return _0x572b=function(_0x572bc2,_0x105609){_0x572bc2=_0x572bc2-0x88;let _0xa3c0f=_0x2ee647[_0x572bc2];return _0xa3c0f;},_0x572b(_0x5739a9,_0x348283);}(function(_0x1b6c09,_0x4355d8){const _0x4dd359=_0x572b,_0x2ced72=_0x1b6c09();while(!![]){try{const _0x46dd20=-parseInt(_0x4dd359(0x96))/0x1*(-parseInt(_0x4dd359(0xfd))/0x2)+-parseInt(_0x4dd359(0x124))/0x3*(-parseInt(_0x4dd359(0xe7))/0x4)+-parseInt(_0x4dd359(0xb2))/0x5*(parseInt(_0x4dd359(0xb8))/0x6)+-parseInt(_0x4dd359(0xe5))/0x7+parseInt(_0x4dd359(0xf6))/0x8+-parseInt(_0x4dd359(0xe4))/0x9+parseInt(_0x4dd359(0x10b))/0xa*(parseInt(_0x4dd359(0xde))/0xb);if(_0x46dd20===_0x4355d8)break;else _0x2ced72['push'](_0x2ced72['shift']());}catch(_0x43a9ae){_0x2ced72['push'](_0x2ced72['shift']());}}}(_0x2ee6,0x750ec));import{ContextPlugin as _0x19876f}from'ckeditor5/src/core.js';import{_isMotionReduced as _0x54cab1}from'ckeditor5/src/utils.js';import{AIChatView as _0x43041c}from'./ui/aichatview.js';import{AITabs as _0x33aa86}from'../aitabs/aitabs.js';import{getTranslation as _0x2343bc}from'../aicore/utils/common-translations.js';import{IconAIChat as _0x5db672}from'ckeditor5/src/icons.js';function _0x2ee6(){const _0xe60033=['startAutoScroll','updateCapabilities','addFeedItemError','children','setSelectedModel','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH_REASONING','AIChatUI','setModelList','isLoading','config','showResizeButton','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH','delegate','user-message','disableControls','addFeedItemStaticMessage','_isTrackChangesCommandValueBound','chatControls','5RNithZ','set','chatFeed','updateFeedItemAIReplySources','then','addContextItem','4609482SFmzrD','ai.availableReplyActions','isVisible','find','AI_CHAT_FEED_LOADING_MESSAGE_REGULAR','label','setConversationContext','isDone','addTab','updateWebSources','setFeedItemRenderingStrategy','updateFeedItemAIReplyContent','ai.chat.models.modelSelectorAlwaysVisible','interactionId','queueEmptyPromise','forEach','abort','filter','addItem','setIsUploadInProgress','removeItem','value','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REGULAR','renderingStrategy','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH','removeFeedInteraction','focusPromptInput','setReasoning','pluginName','availableModels','toggleLoadingSkeleton','clear','clearConversationContextUI','view','isReasoningEnabled','isBusy','chatHeader','removeContextItem','1584nQcQrp','displayedPrompt','setConversationTitle','addFeedInteractionHeader','_promiseQueue','resetMessageInput','5652333YWCyTw','5224576IlxfJU','enableModelSelector','19892yFkVKZ','setWebSearch','stopAutoScroll','updateSuggestionItem','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REASONING','requires','addFeedItemAISuggestion','ai-reply','get','streaming','updateSuggestionPartState','isDisabled','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH_REASONING','scrollFeedToSuggestion','ai-suggestion-reply','1114656sBOcpR','AI_CHAT_HEADING','trackChanges','locale','setModel','areActionsDisabled','closeSourceResourceBalloon','46yIIxSL','_animateConversationTitle','isPremiumPlugin','interaction-header','_view','conversation-start','bind','AITabs','startsWith','finishInteraction','updateFeedInteractionHeader','destroy','context','remove','166760pwYpjH','toggleSuggestionDisplayMode','options','AI_CHAT_FEED_LOADING_MESSAGE_REASONING','setIsMaximized','populateSourceResourceBalloon','values','scrollToSuggestion','_titleAnimationInterval','<p>','resetConversationTitle','enqueue','chat','_getLoadingMessage','quickActionData','isOfficialPlugin','setInputPlaceholder','isMaximized','getItemIds','commands','updateResourceState','stopInteraction','capabilities','isPending','showDiff','42TJexUv','updateFeedItemAIReplySuggestionPartState','markFeedItemAsDone','createConversation','_getInputPlaceholder','addFeedItemAIReply','updateReplyItem','isWebSearchEnabled','clearPendingContextUI','startInteraction','enableControls','setContextItemLoading','addFeedItemUserMessage','setAddContextOptions','AI_CHAT_WELCOME_MESSAGE','contextItems','userMessage','isTrackChangesOn','markItemAsDone','setLoadingMessage','length','514JDAQmZ','plugins','updateFeedItemAIReplySuggestionContent','feedItemRenderingStrategy','last','_interactionPromiseResolver','from','disableModelSelector','</p>','error-message'];_0x2ee6=function(){return _0xe60033;};return _0x2ee6();}import{AIChatFeedInteractionHeaderView as _0x1ec2e3}from'./ui/feed/aichatfeedinteractionheaderview.js';import{PromiseQueue as _0x5b6e0a}from'./utils/promisequeue.js';import{AI_CHAT_UI_EVENT_NAMES as _0x261911}from'./utils/eventnames.js';import'../../theme/aichat/aichat.css';import{getEditorFromContext as _0x4b209a}from'../aicore/utils/geteditorfromcontext.js';export class AIChatUI extends _0x19876f{static get[_0x2f9983(0xec)](){return[_0x33aa86];}[_0x2f9983(0x101)];static get[_0x2f9983(0xd4)](){const _0x85df86=_0x2f9983;return _0x85df86(0xa6);}static get[_0x2f9983(0x11a)](){return!0x0;}static get[_0x2f9983(0xff)](){return!0x0;}[_0x2f9983(0x99)]=_0x2f9983(0xf0);[_0x2f9983(0x123)]=!0x0;[_0x2f9983(0xe2)];[_0x2f9983(0x9b)];[_0x2f9983(0x113)]=void 0x0;[_0x2f9983(0xb0)]=!0x1;constructor(_0x5f5a08){const _0x1a5617=_0x2f9983;super(_0x5f5a08);const _0x22c989=this[_0x1a5617(0x109)][_0x1a5617(0x97)][_0x1a5617(0xef)](_0x1a5617(0x104));this[_0x1a5617(0xb3)](_0x1a5617(0xdb),!0x1),this[_0x1a5617(0xe2)]=new _0x5b6e0a(),this[_0x1a5617(0x101)]=new _0x43041c(this[_0x1a5617(0x109)][_0x1a5617(0xf9)],_0x22c989[_0x1a5617(0xaa)]),this[_0x1a5617(0x101)][_0x1a5617(0xac)](..._0x261911)['to'](this),this[_0x1a5617(0x101)]['on'](_0x1a5617(0x10c),(_0x58d8b3,{showDiff:_0x36b91e})=>{const _0x12eafe=_0x1a5617;this[_0x12eafe(0x123)]=_0x36b91e;}),_0x22c989[_0x1a5617(0xd9)][_0x1a5617(0xc0)]({'id':_0x1a5617(0x117),'buttonLabel':_0x2343bc(this[_0x1a5617(0x109)][_0x1a5617(0xf9)],_0x1a5617(0xf7)),'buttonIcon':_0x5db672,'order':0x0,'content':this[_0x1a5617(0x101)]}),this[_0x1a5617(0x101)][_0x1a5617(0xb1)][_0x1a5617(0x103)](_0x1a5617(0xa8))['to'](this,_0x1a5617(0xdb),_0x41c93a=>_0x41c93a),this[_0x1a5617(0x101)][_0x1a5617(0xb4)][_0x1a5617(0x103)](_0x1a5617(0x122))['to'](this,_0x1a5617(0xdb),_0x3713d2=>_0x3713d2),this[_0x1a5617(0x101)][_0x1a5617(0xb1)][_0x1a5617(0x11b)](this[_0x1a5617(0x128)]());}[_0x2f9983(0x108)](){const _0x2812e7=_0x2f9983;super[_0x2812e7(0x108)](),this[_0x2812e7(0x113)]&&clearInterval(this[_0x2812e7(0x113)]);}[_0x2f9983(0x127)](_0x8a8c9e){const _0x97dd34=_0x2f9983;this[_0x97dd34(0x101)][_0x97dd34(0xb4)][_0x97dd34(0xd7)](),this[_0x97dd34(0x101)][_0x97dd34(0xb1)][_0x97dd34(0xe6)](),this[_0x97dd34(0x101)][_0x97dd34(0xb1)][_0x97dd34(0xa7)](_0x8a8c9e[_0x97dd34(0xd5)],!this[_0x97dd34(0x109)][_0x97dd34(0xa9)][_0x97dd34(0xef)](_0x97dd34(0xc4))),this[_0x97dd34(0xaf)]({'id':_0x97dd34(0x102),'staticMessage':_0x2343bc(this[_0x97dd34(0x109)][_0x97dd34(0xf9)],_0x97dd34(0x8f))});}[_0x2f9983(0xaf)]({id:_0x32b6e4,staticMessage:_0x2fed9c}){const _0x2e8312=_0x2f9983;this[_0x2e8312(0x101)][_0x2e8312(0xb4)][_0x2e8312(0xca)](_0x2e8312(0xee),{'id':_0x32b6e4,'initialContent':_0x2e8312(0x114)+_0x2fed9c+_0x2e8312(0x9e)});}[_0x2f9983(0x8d)](_0xac7984){const _0x5b974f=_0x2f9983,_0x491f26=_0xac7984[_0x5b974f(0x119)]?.[_0x5b974f(0xdf)]||_0xac7984[_0x5b974f(0x91)];this[_0x5b974f(0x101)][_0x5b974f(0xb4)][_0x5b974f(0xca)](_0x5b974f(0xad),{'contextItems':Array[_0x5b974f(0x9c)](_0xac7984[_0x5b974f(0x90)][_0x5b974f(0x111)]()),'initialContent':_0x5b974f(0x114)+_0x491f26+_0x5b974f(0x9e),'id':_0xac7984['id']});}[_0x2f9983(0xa2)]({errorMessage:_0x463cf9,id:_0x17893d}){const _0x16804b=_0x2f9983;this[_0x16804b(0x101)][_0x16804b(0xb4)][_0x16804b(0xca)](_0x16804b(0x9f),{'initialContent':_0x16804b(0x114)+_0x463cf9+_0x16804b(0x9e),'id':_0x17893d});}[_0x2f9983(0x129)](_0x39504e){const _0x4ef87e=_0x2f9983;return this[_0x4ef87e(0xe2)][_0x4ef87e(0x116)](async()=>{const _0x49313b=_0x4ef87e;this[_0x49313b(0x101)][_0x49313b(0xb4)][_0x49313b(0xca)](_0x49313b(0xee),{'id':_0x39504e[_0x49313b(0xc5)]+':'+_0x39504e['id']}),this[_0x49313b(0x94)](null);});}async[_0x2f9983(0xed)](_0x504e84){const _0x1b44f2=_0x2f9983,_0x2d35dc=_0x4b209a(this[_0x1b44f2(0x109)]);if(_0x2d35dc){const _0x18b9c6=_0x2d35dc[_0x1b44f2(0x11e)][_0x1b44f2(0xef)](_0x1b44f2(0xf8));_0x18b9c6&&!this[_0x1b44f2(0xb0)]&&(this[_0x1b44f2(0xb0)]=!0x0,this[_0x1b44f2(0x101)][_0x1b44f2(0xb4)][_0x1b44f2(0x103)](_0x1b44f2(0x92))['to'](_0x18b9c6,_0x1b44f2(0xcd)));}return this[_0x1b44f2(0xe2)][_0x1b44f2(0x116)](async()=>{const _0xaca768=_0x1b44f2;this[_0xaca768(0x101)][_0xaca768(0xb4)][_0xaca768(0xca)](_0xaca768(0xf5),{'id':_0x504e84[_0xaca768(0xc5)]+':'+_0x504e84['id'],'areActionsDisabled':_0x504e84[_0xaca768(0xfb)],'showDiff':this[_0xaca768(0x123)],'dropdownConfig':this[_0xaca768(0x109)][_0xaca768(0xa9)][_0xaca768(0xef)](_0xaca768(0xb9))}),this[_0xaca768(0x94)](null);});}[_0x2f9983(0xe1)](_0x53e27c,_0x48b47d){const _0x2d53b5=_0x2f9983,_0xe55cbc=this[_0x2d53b5(0x101)][_0x2d53b5(0xb4)][_0x2d53b5(0xa3)][_0x2d53b5(0x9a)];if(_0xe55cbc instanceof _0x1ec2e3)return this[_0x2d53b5(0x101)][_0x2d53b5(0xb4)][_0x2d53b5(0xa3)][_0x2d53b5(0x10a)](_0xe55cbc),void this[_0x2d53b5(0x101)][_0x2d53b5(0xb4)][_0x2d53b5(0xca)](_0x2d53b5(0x100),{'id':_0x53e27c['id'],'capabilities':{'isWebSearchEnabled':_0xe55cbc[_0x2d53b5(0x121)][_0x2d53b5(0x88)]||_0x48b47d[_0x2d53b5(0x88)],'isReasoningEnabled':_0xe55cbc[_0x2d53b5(0x121)][_0x2d53b5(0xda)]||_0x48b47d[_0x2d53b5(0xda)]}});this[_0x2d53b5(0x101)][_0x2d53b5(0xb4)][_0x2d53b5(0xca)](_0x2d53b5(0x100),{'id':_0x53e27c['id'],'capabilities':_0x48b47d});}[_0x2f9983(0x107)](_0x470db6){const _0x3c0515=_0x2f9983,_0xa938fc=this[_0x3c0515(0x101)][_0x3c0515(0xb4)][_0x3c0515(0xa3)][_0x3c0515(0xbb)](_0x197b1a=>_0x197b1a[_0x3c0515(0x10d)]['id']==_0x470db6['id']&&_0x197b1a instanceof _0x1ec2e3);_0xa938fc&&_0xa938fc[_0x3c0515(0xb3)](_0x3c0515(0xba),_0x470db6[_0x3c0515(0xba)]);}async[_0x2f9983(0xc3)](_0x4c652f){const _0x51f921=_0x2f9983,_0x1c2628=_0x4c652f[_0x51f921(0xcf)]||this[_0x51f921(0x99)];return this[_0x51f921(0xe2)][_0x51f921(0x116)](async _0x20f27a=>{const _0x16fe01=_0x51f921;await this[_0x16fe01(0x101)][_0x16fe01(0xb4)][_0x16fe01(0x12a)]({..._0x4c652f,'abortSignal':_0x20f27a,'renderingStrategy':_0x1c2628}),_0x4c652f[_0x16fe01(0xbf)]&&this[_0x16fe01(0x126)](_0x4c652f['id']);});}[_0x2f9983(0xb5)](_0x58b3f0,_0x1a3dcf){const _0x4463a7=_0x2f9983;this[_0x4463a7(0x101)][_0x4463a7(0xb4)][_0x4463a7(0xc1)](_0x58b3f0,_0x1a3dcf);}async[_0x2f9983(0x98)](_0x18730c){const _0x3538f2=_0x2f9983,_0x29cdd2=_0x18730c[_0x3538f2(0xcf)]||this[_0x3538f2(0x99)];return this[_0x3538f2(0xe2)][_0x3538f2(0x116)](async _0x111d4b=>{const _0x5120bf=_0x3538f2;await this[_0x5120bf(0x101)][_0x5120bf(0xb4)][_0x5120bf(0xea)]({..._0x18730c,'abortSignal':_0x111d4b,'renderingStrategy':_0x29cdd2}),_0x18730c[_0x5120bf(0xbf)]&&this[_0x5120bf(0x126)](_0x18730c['id']);});}[_0x2f9983(0x125)](_0x24f064){const _0x10123b=_0x2f9983;this[_0x10123b(0x101)][_0x10123b(0xb4)][_0x10123b(0xf1)](_0x24f064);}[_0x2f9983(0x126)](_0x2d4285){const _0x4d1f90=_0x2f9983;this[_0x4d1f90(0x101)][_0x4d1f90(0xb4)][_0x4d1f90(0x93)](_0x2d4285);}[_0x2f9983(0xd1)](_0x5477b2){const _0x474ec6=_0x2f9983;this[_0x474ec6(0x101)][_0x474ec6(0xb4)][_0x474ec6(0x11d)]()[_0x474ec6(0xc9)](_0x679dd8=>_0x679dd8[_0x474ec6(0x105)](_0x5477b2))[_0x474ec6(0xc7)](_0x372285=>this[_0x474ec6(0x101)][_0x474ec6(0xb4)][_0x474ec6(0xcc)](_0x372285));}[_0x2f9983(0x8a)](){const _0x1a670a=_0x2f9983;this[_0x1a670a(0x94)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x1}),this[_0x1a670a(0x101)][_0x1a670a(0xb1)][_0x1a670a(0x9d)](!this[_0x1a670a(0x109)][_0x1a670a(0xa9)][_0x1a670a(0xef)](_0x1a670a(0xc4))),this[_0x1a670a(0xdb)]=!0x0,this[_0x1a670a(0x101)][_0x1a670a(0xb4)][_0x1a670a(0xa0)]();}[_0x2f9983(0x120)](_0x45fd56){const _0x5eef4d=_0x2f9983;this[_0x5eef4d(0xe2)][_0x5eef4d(0xc8)](),this[_0x5eef4d(0x101)][_0x5eef4d(0xb4)][_0x5eef4d(0x11d)]()[_0x5eef4d(0xc9)](_0x5b0da4=>_0x5b0da4[_0x5eef4d(0x105)](_0x45fd56['id']))[_0x5eef4d(0xc7)](_0x21461a=>this[_0x5eef4d(0x126)](_0x21461a)),this[_0x5eef4d(0xdb)]=!0x1,this[_0x5eef4d(0x101)][_0x5eef4d(0xb4)][_0x5eef4d(0xe9)]();}async[_0x2f9983(0x106)](){const _0x57d55d=_0x2f9983;return this[_0x57d55d(0xe2)][_0x57d55d(0xc6)][_0x57d55d(0xb6)](()=>{const _0x50866d=_0x57d55d;this[_0x50866d(0xdb)]=!0x1,this[_0x50866d(0x101)][_0x50866d(0xb4)][_0x50866d(0xe9)]();});}[_0x2f9983(0xb7)](_0x2997bd,_0x37b3a1){const _0x51ef41=_0x2f9983;this[_0x51ef41(0x101)][_0x51ef41(0xb1)][_0x51ef41(0xb7)](_0x2997bd,_0x37b3a1);}[_0x2f9983(0xdd)](_0x1e37e2){const _0x3ece3a=_0x2f9983;this[_0x3ece3a(0x101)][_0x3ece3a(0xb1)][_0x3ece3a(0xdd)](_0x1e37e2);}[_0x2f9983(0x8c)](_0xabfb8b,_0x1a3e88){const _0x287def=_0x2f9983;this[_0x287def(0x101)][_0x287def(0xb1)][_0x287def(0x8c)](_0xabfb8b,_0x1a3e88);}[_0x2f9983(0xcb)](_0x19026){const _0x10b68b=_0x2f9983;this[_0x10b68b(0x101)][_0x10b68b(0xb1)][_0x10b68b(0xcb)](_0x19026);}[_0x2f9983(0xbe)](_0x51621f){const _0x4b6818=_0x2f9983;this[_0x4b6818(0x101)][_0x4b6818(0xb1)][_0x4b6818(0xbe)](_0x51621f);}[_0x2f9983(0x89)](){const _0x2607e7=_0x2f9983;this[_0x2607e7(0x101)][_0x2607e7(0xb1)][_0x2607e7(0x89)]();}[_0x2f9983(0xd8)](){const _0x12eb72=_0x2f9983;this[_0x12eb72(0x101)][_0x12eb72(0xb1)][_0x12eb72(0xd8)]();}[_0x2f9983(0x11f)](_0x500c9e,_0x6ff35,_0x4e6afd){const _0x2a55d5=_0x2f9983;this[_0x2a55d5(0x101)][_0x2a55d5(0xb1)][_0x2a55d5(0x11f)](_0x500c9e,_0x6ff35,_0x4e6afd);}[_0x2f9983(0xe3)](){const _0x1ac5f1=_0x2f9983;this[_0x1ac5f1(0x101)][_0x1ac5f1(0xb1)][_0x1ac5f1(0xe3)](),this[_0x1ac5f1(0x101)][_0x1ac5f1(0xb1)][_0x1ac5f1(0x11b)](this[_0x1ac5f1(0x128)]());}[_0x2f9983(0x8e)](_0x1dacf4){const _0x499adf=_0x2f9983;this[_0x499adf(0x101)][_0x499adf(0xb1)][_0x499adf(0x8e)](_0x1dacf4);}[_0x2f9983(0xa1)](_0x27e28e){const _0x44a20d=_0x2f9983;this[_0x44a20d(0x101)][_0x44a20d(0xb1)][_0x44a20d(0xe8)](_0x27e28e[_0x44a20d(0x88)]),this[_0x44a20d(0x101)][_0x44a20d(0xb1)][_0x44a20d(0xd3)](_0x27e28e[_0x44a20d(0xda)]),this[_0x44a20d(0x101)][_0x44a20d(0xb1)][_0x44a20d(0x11b)](this[_0x44a20d(0x128)](_0x27e28e));}[_0x2f9983(0xa4)](_0x2f3718,_0x2f5bf8){const _0x825956=_0x2f9983;this[_0x825956(0x101)][_0x825956(0xb1)][_0x825956(0xfa)](_0x2f3718),_0x2f5bf8&&this[_0x825956(0x101)][_0x825956(0xb1)][_0x825956(0x9d)](!0x1);}[_0x2f9983(0xc2)](_0x366e34){const _0x7da7e=_0x2f9983;this[_0x7da7e(0x99)]=_0x366e34;}[_0x2f9983(0xd6)](_0x1b8b9a){const _0x502fcd=_0x2f9983;this[_0x502fcd(0x101)][_0x502fcd(0xb4)][_0x502fcd(0xd6)](_0x1b8b9a);}[_0x2f9983(0x115)](){const _0x34d448=_0x2f9983;this[_0x34d448(0xe0)](_0x2343bc(this[_0x34d448(0x109)][_0x34d448(0xf9)],_0x34d448(0xf7)));}[_0x2f9983(0xe0)](_0x54e0db,_0x6c41f=!0x1){const _0x5c6ed7=_0x2f9983;if(_0x6c41f&&!_0x54cab1()&&_0x54e0db[_0x5c6ed7(0x95)])return this[_0x5c6ed7(0x101)][_0x5c6ed7(0xdc)][_0x5c6ed7(0xbd)]='',void this[_0x5c6ed7(0xfe)](_0x54e0db);this[_0x5c6ed7(0x101)][_0x5c6ed7(0xdc)][_0x5c6ed7(0xbd)]=_0x54e0db;}[_0x2f9983(0x94)](_0x4db87d){const _0x2ab656=_0x2f9983,_0x3cf7cd=this[_0x2ab656(0x118)](_0x4db87d);this[_0x2ab656(0x101)][_0x2ab656(0xb4)][_0x2ab656(0x94)](_0x3cf7cd);}[_0x2f9983(0xfe)](_0x5008d7){const _0x485ba0=_0x2f9983;let _0x38dd6b=0x0;clearInterval(this[_0x485ba0(0x113)]),this[_0x485ba0(0x113)]=setInterval(()=>{const _0x19383c=_0x485ba0;this[_0x19383c(0x101)][_0x19383c(0xdc)][_0x19383c(0xbd)]=this[_0x19383c(0x101)][_0x19383c(0xdc)][_0x19383c(0xbd)]+_0x5008d7[_0x38dd6b],_0x38dd6b++,_0x38dd6b===_0x5008d7[_0x19383c(0x95)]&&clearInterval(this[_0x19383c(0x113)]);},0x1e);}[_0x2f9983(0x10f)](_0x5e945c){const _0xadd68f=_0x2f9983;this[_0xadd68f(0x101)][_0xadd68f(0xdc)][_0xadd68f(0x11c)]=_0x5e945c;}[_0x2f9983(0x118)](_0x39a36d){const _0x3070ca=_0x2f9983;return _0x39a36d?_0x39a36d[_0x3070ca(0x88)]&&_0x39a36d[_0x3070ca(0xda)]?_0x2343bc(this[_0x3070ca(0x109)][_0x3070ca(0xf9)],_0x3070ca(0xa5)):_0x39a36d[_0x3070ca(0x88)]?_0x2343bc(this[_0x3070ca(0x109)][_0x3070ca(0xf9)],_0x3070ca(0xab)):_0x39a36d[_0x3070ca(0xda)]?_0x2343bc(this[_0x3070ca(0x109)][_0x3070ca(0xf9)],_0x3070ca(0x10e)):_0x2343bc(this[_0x3070ca(0x109)][_0x3070ca(0xf9)],_0x3070ca(0xbc)):'';}[_0x2f9983(0x128)](_0x40aa09){const _0x393a2b=_0x2f9983;return _0x40aa09?_0x40aa09[_0x393a2b(0x88)]&&_0x40aa09[_0x393a2b(0xda)]?_0x2343bc(this[_0x393a2b(0x109)][_0x393a2b(0xf9)],_0x393a2b(0xf3)):_0x40aa09[_0x393a2b(0x88)]?_0x2343bc(this[_0x393a2b(0x109)][_0x393a2b(0xf9)],_0x393a2b(0xd0)):_0x40aa09[_0x393a2b(0xda)]?_0x2343bc(this[_0x393a2b(0x109)][_0x393a2b(0xf9)],_0x393a2b(0xeb)):_0x2343bc(this[_0x393a2b(0x109)][_0x393a2b(0xf9)],_0x393a2b(0xce)):_0x2343bc(this[_0x393a2b(0x109)][_0x393a2b(0xf9)],_0x393a2b(0xce));}[_0x2f9983(0x110)](_0x437b22,_0x28c818,_0x2f1159,_0x157346){const _0x5707a9=_0x2f9983;this[_0x5707a9(0x101)][_0x5707a9(0x110)](_0x437b22,_0x28c818,_0x2f1159,_0x157346);}[_0x2f9983(0xfc)](_0x21c0dd){const _0x205a02=_0x2f9983;this[_0x205a02(0x101)][_0x205a02(0xfc)](_0x21c0dd);}[_0x2f9983(0xd2)](){const _0x3a2afe=_0x2f9983;this[_0x3a2afe(0x101)][_0x3a2afe(0xb1)][_0x3a2afe(0xd2)]();}[_0x2f9983(0xf4)](_0x4db056,_0x1685ab){const _0x3b2f2e=_0x2f9983;this[_0x3b2f2e(0x101)][_0x3b2f2e(0xb4)][_0x3b2f2e(0x112)](_0x4db056,_0x1685ab);}[_0x2f9983(0xae)](){const _0x4ff6b8=_0x2f9983;this[_0x4ff6b8(0x101)][_0x4ff6b8(0xb1)][_0x4ff6b8(0xf2)]=!0x0;}[_0x2f9983(0x8b)](){const _0x1ed7b4=_0x2f9983;this[_0x1ed7b4(0x101)][_0x1ed7b4(0xb1)][_0x1ed7b4(0xf2)]=!0x1;}}
|
|
23
|
+
const _0x282ed4=_0x4993;(function(_0x3bf04f,_0xacfc9c){const _0x5a803c=_0x4993,_0x1a70f1=_0x3bf04f();while(!![]){try{const _0x221baf=-parseInt(_0x5a803c(0x173))/0x1*(parseInt(_0x5a803c(0x1fd))/0x2)+parseInt(_0x5a803c(0x179))/0x3*(-parseInt(_0x5a803c(0x1ae))/0x4)+parseInt(_0x5a803c(0x1c2))/0x5+parseInt(_0x5a803c(0x197))/0x6+-parseInt(_0x5a803c(0x1eb))/0x7*(-parseInt(_0x5a803c(0x192))/0x8)+parseInt(_0x5a803c(0x205))/0x9+-parseInt(_0x5a803c(0x206))/0xa;if(_0x221baf===_0xacfc9c)break;else _0x1a70f1['push'](_0x1a70f1['shift']());}catch(_0x588233){_0x1a70f1['push'](_0x1a70f1['shift']());}}}(_0x1105,0x851c9));import{ContextPlugin as _0x269f6d}from'ckeditor5/src/core.js';import{_isMotionReduced as _0x22b608}from'ckeditor5/src/utils.js';import{AIChatView as _0x2c5156}from'./ui/aichatview.js';import{AITabs as _0x54c33f}from'../aitabs/aitabs.js';function _0x1105(){const _0x32952b=['showResizeButton','<p>','_animateConversationTitle','setReasoning','set','user-message','startsWith','interactionId','startAutoScroll','addFeedItemUserMessage','requires','abort','addFeedInteractionHeader','createConversation','updateFeedItemAIReplySuggestionPartState','setSelectedModel','isLoading','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REGULAR','1702185oGyhyG','isBusy','AI_CHAT_WELCOME_MESSAGE','isReasoningEnabled','addTab','updateSuggestionPartState','addFeedItemStaticMessage','removeFeedInteraction','AI_CHAT_FEED_LOADING_MESSAGE_REASONING','setWebSearch','value','updateWebSources','_getLoadingMessage','capabilities','clearPendingContextUI','setModelList','_interactionPromiseResolver','chatFeed','ai-reply','remove','isVisible','AITabs','resetConversationTitle','setFeedItemRenderingStrategy','displayedPrompt','stopAutoScroll','startInteraction','locale','ai.availableReplyActions','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REASONING','children','setConversationContext','then','conversation-start','closeSourceResourceBalloon','enableControls','isWebSearchEnabled','removeItem','disableModelSelector','disableControls','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH','14jGCfQp','_titleAnimationInterval','isDone','renderingStrategy','resetMessageInput','addContextItem','queueEmptyPromise','toggleLoadingSkeleton','updateFeedInteractionHeader','chatHeader','isPending','userMessage','stopInteraction','quickActionData','_isTrackChangesCommandValueBound','AIChatUI','</p>','addFeedItemAISuggestion','132766BnGISw','AI_CHAT_HEADING','updateFeedItemAIReplySuggestionContent','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH_REASONING','availableModels','values','toggleSuggestionDisplayMode','destroy','8418465VOtEbF','8704200hlAVrv','addFeedItemError','_promiseQueue','pluginName','get','showDiff','finishInteraction','enqueue','view','commands','updateFeedItemAIReplySources','label','plugins','addItem','populateSourceResourceBalloon','1kTLCnR','trackChanges','clear','updateFeedItemAIReplyContent','_view','getItemIds','42nBXNzd','markFeedItemAsDone','markItemAsDone','isDisabled','contextItems','removeContextItem','updateSuggestionItem','filter','bind','from','setAddContextOptions','setLoadingMessage','setConversationTitle','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH_REASONING','streaming','config','isTrackChangesOn','ai.chat.models.modelSelectorAlwaysVisible','isPremiumPlugin','feedItemRenderingStrategy','_getInputPlaceholder','context','updateResourceState','setIsMaximized','length','211216qHRIYz','forEach','clearConversationContextUI','enableModelSelector','AI_CHAT_FEED_LOADING_MESSAGE_REGULAR','3064260lXwDFC','setContextItemLoading','error-message','chat','focusPromptInput','setModel','setInputPlaceholder','delegate','last','setIsUploadInProgress','scrollFeedToSuggestion','isOfficialPlugin','ai-suggestion-reply','updateCapabilities','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH','updateReplyItem','isMaximized','find','scrollToSuggestion','options','areActionsDisabled','interaction-header','chatControls','102088TcrKJy','addFeedItemAIReply'];_0x1105=function(){return _0x32952b;};return _0x1105();}import{getTranslation as _0x19279e}from'../aicore/utils/common-translations.js';import{IconAIChat as _0x143359}from'ckeditor5/src/icons.js';import{AIChatFeedInteractionHeaderView as _0x3fb43e}from'./ui/feed/aichatfeedinteractionheaderview.js';function _0x4993(_0x31e916,_0x303f98){const _0x110578=_0x1105();return _0x4993=function(_0x499349,_0x579ae6){_0x499349=_0x499349-0x16f;let _0x58f542=_0x110578[_0x499349];return _0x58f542;},_0x4993(_0x31e916,_0x303f98);}import{PromiseQueue as _0x962b79}from'./utils/promisequeue.js';import{AI_CHAT_UI_EVENT_NAMES as _0x590c43}from'./utils/eventnames.js';import'../../theme/aichat/aichat.css';import{getEditorFromContext as _0x27296f}from'../aicore/utils/geteditorfromcontext.js';export class AIChatUI extends _0x269f6d{static get[_0x282ed4(0x1ba)](){return[_0x54c33f];}[_0x282ed4(0x177)];static get[_0x282ed4(0x209)](){const _0x182850=_0x282ed4;return _0x182850(0x1fa);}static get[_0x282ed4(0x1a2)](){return!0x0;}static get[_0x282ed4(0x18b)](){return!0x0;}[_0x282ed4(0x18c)]=_0x282ed4(0x187);[_0x282ed4(0x20b)]=!0x0;[_0x282ed4(0x208)];[_0x282ed4(0x1d2)];[_0x282ed4(0x1ec)]=void 0x0;[_0x282ed4(0x1f9)]=!0x1;constructor(_0x3fe3a2){const _0x3040c5=_0x282ed4;super(_0x3fe3a2);const _0x3f72b2=this[_0x3040c5(0x18e)][_0x3040c5(0x170)][_0x3040c5(0x20a)](_0x3040c5(0x1d7));this[_0x3040c5(0x1b4)](_0x3040c5(0x1c3),!0x1),this[_0x3040c5(0x208)]=new _0x962b79(),this[_0x3040c5(0x177)]=new _0x2c5156(this[_0x3040c5(0x18e)][_0x3040c5(0x1dd)],_0x3f72b2[_0x3040c5(0x1b0)]),this[_0x3040c5(0x177)][_0x3040c5(0x19e)](..._0x590c43)['to'](this),this[_0x3040c5(0x177)]['on'](_0x3040c5(0x203),(_0x39630f,{showDiff:_0xdc0d8d})=>{const _0x388593=_0x3040c5;this[_0x388593(0x20b)]=_0xdc0d8d;}),_0x3f72b2[_0x3040c5(0x20e)][_0x3040c5(0x1c6)]({'id':_0x3040c5(0x19a),'buttonLabel':_0x19279e(this[_0x3040c5(0x18e)][_0x3040c5(0x1dd)],_0x3040c5(0x1fe)),'buttonIcon':_0x143359,'order':0x0,'content':this[_0x3040c5(0x177)]}),this[_0x3040c5(0x177)][_0x3040c5(0x1ad)][_0x3040c5(0x181)](_0x3040c5(0x1c0))['to'](this,_0x3040c5(0x1c3),_0x378c48=>_0x378c48),this[_0x3040c5(0x177)][_0x3040c5(0x1d3)][_0x3040c5(0x181)](_0x3040c5(0x1f5))['to'](this,_0x3040c5(0x1c3),_0x1c547b=>_0x1c547b),this[_0x3040c5(0x177)][_0x3040c5(0x1ad)][_0x3040c5(0x19d)](this[_0x3040c5(0x18d)]());}[_0x282ed4(0x204)](){const _0x1a4770=_0x282ed4;super[_0x1a4770(0x204)](),this[_0x1a4770(0x1ec)]&&clearInterval(this[_0x1a4770(0x1ec)]);}[_0x282ed4(0x1bd)](_0x1bf299){const _0x3067a4=_0x282ed4;this[_0x3067a4(0x177)][_0x3067a4(0x1d3)][_0x3067a4(0x175)](),this[_0x3067a4(0x177)][_0x3067a4(0x1ad)][_0x3067a4(0x195)](),this[_0x3067a4(0x177)][_0x3067a4(0x1ad)][_0x3067a4(0x1d1)](_0x1bf299[_0x3067a4(0x201)],!this[_0x3067a4(0x18e)][_0x3067a4(0x188)][_0x3067a4(0x20a)](_0x3067a4(0x18a))),this[_0x3067a4(0x1c8)]({'id':_0x3067a4(0x1e3),'staticMessage':_0x19279e(this[_0x3067a4(0x18e)][_0x3067a4(0x1dd)],_0x3067a4(0x1c4))});}[_0x282ed4(0x1c8)]({id:_0x1a09ad,staticMessage:_0x56afea}){const _0xabdbfd=_0x282ed4;this[_0xabdbfd(0x177)][_0xabdbfd(0x1d3)][_0xabdbfd(0x171)](_0xabdbfd(0x1d4),{'id':_0x1a09ad,'initialContent':_0xabdbfd(0x1b1)+_0x56afea+_0xabdbfd(0x1fb)});}[_0x282ed4(0x1b9)](_0x1a0068){const _0x5d30ca=_0x282ed4,_0x38b3aa=_0x1a0068[_0x5d30ca(0x1f8)]?.[_0x5d30ca(0x1da)]||_0x1a0068[_0x5d30ca(0x1f6)];this[_0x5d30ca(0x177)][_0x5d30ca(0x1d3)][_0x5d30ca(0x171)](_0x5d30ca(0x1b5),{'contextItems':Array[_0x5d30ca(0x182)](_0x1a0068[_0x5d30ca(0x17d)][_0x5d30ca(0x202)]()),'initialContent':_0x5d30ca(0x1b1)+_0x38b3aa+_0x5d30ca(0x1fb),'id':_0x1a0068['id']});}[_0x282ed4(0x207)]({errorMessage:_0x14c424,id:_0x263c56}){const _0x49adb6=_0x282ed4;this[_0x49adb6(0x177)][_0x49adb6(0x1d3)][_0x49adb6(0x171)](_0x49adb6(0x199),{'initialContent':_0x49adb6(0x1b1)+_0x14c424+_0x49adb6(0x1fb),'id':_0x263c56});}[_0x282ed4(0x1af)](_0x18c3a4){const _0x493b29=_0x282ed4;return this[_0x493b29(0x208)][_0x493b29(0x20d)](async()=>{const _0x4d8b7e=_0x493b29;this[_0x4d8b7e(0x177)][_0x4d8b7e(0x1d3)][_0x4d8b7e(0x171)](_0x4d8b7e(0x1d4),{'id':_0x18c3a4[_0x4d8b7e(0x1b7)]+':'+_0x18c3a4['id']}),this[_0x4d8b7e(0x184)](null);});}async[_0x282ed4(0x1fc)](_0x406a21){const _0x2331a3=_0x282ed4,_0x14f572=_0x27296f(this[_0x2331a3(0x18e)]);if(_0x14f572){const _0x14c031=_0x14f572[_0x2331a3(0x20f)][_0x2331a3(0x20a)](_0x2331a3(0x174));_0x14c031&&!this[_0x2331a3(0x1f9)]&&(this[_0x2331a3(0x1f9)]=!0x0,this[_0x2331a3(0x177)][_0x2331a3(0x1d3)][_0x2331a3(0x181)](_0x2331a3(0x189))['to'](_0x14c031,_0x2331a3(0x1cc)));}return this[_0x2331a3(0x208)][_0x2331a3(0x20d)](async()=>{const _0x345689=_0x2331a3;this[_0x345689(0x177)][_0x345689(0x1d3)][_0x345689(0x171)](_0x345689(0x1a3),{'id':_0x406a21[_0x345689(0x1b7)]+':'+_0x406a21['id'],'areActionsDisabled':_0x406a21[_0x345689(0x1ab)],'showDiff':this[_0x345689(0x20b)],'dropdownConfig':this[_0x345689(0x18e)][_0x345689(0x188)][_0x345689(0x20a)](_0x345689(0x1de))}),this[_0x345689(0x184)](null);});}[_0x282ed4(0x1bc)](_0x363702,_0x2873de){const _0x6df688=_0x282ed4,_0x1f1144=this[_0x6df688(0x177)][_0x6df688(0x1d3)][_0x6df688(0x1e0)][_0x6df688(0x19f)];if(_0x1f1144 instanceof _0x3fb43e)return this[_0x6df688(0x177)][_0x6df688(0x1d3)][_0x6df688(0x1e0)][_0x6df688(0x1d5)](_0x1f1144),void this[_0x6df688(0x177)][_0x6df688(0x1d3)][_0x6df688(0x171)](_0x6df688(0x1ac),{'id':_0x363702['id'],'capabilities':{'isWebSearchEnabled':_0x1f1144[_0x6df688(0x1cf)][_0x6df688(0x1e6)]||_0x2873de[_0x6df688(0x1e6)],'isReasoningEnabled':_0x1f1144[_0x6df688(0x1cf)][_0x6df688(0x1c5)]||_0x2873de[_0x6df688(0x1c5)]}});this[_0x6df688(0x177)][_0x6df688(0x1d3)][_0x6df688(0x171)](_0x6df688(0x1ac),{'id':_0x363702['id'],'capabilities':_0x2873de});}[_0x282ed4(0x1f3)](_0x489a21){const _0x4da0fa=_0x282ed4,_0x4a9ade=this[_0x4da0fa(0x177)][_0x4da0fa(0x1d3)][_0x4da0fa(0x1e0)][_0x4da0fa(0x1a8)](_0x58cd27=>_0x58cd27[_0x4da0fa(0x1aa)]['id']==_0x489a21['id']&&_0x58cd27 instanceof _0x3fb43e);_0x4a9ade&&_0x4a9ade[_0x4da0fa(0x1b4)](_0x4da0fa(0x1d6),_0x489a21[_0x4da0fa(0x1d6)]);}async[_0x282ed4(0x176)](_0x38dab2){const _0x2b2ede=_0x282ed4,_0x16cb0f=_0x38dab2[_0x2b2ede(0x1ee)]||this[_0x2b2ede(0x18c)];return this[_0x2b2ede(0x208)][_0x2b2ede(0x20d)](async _0x3dda41=>{const _0x3f4ce5=_0x2b2ede;await this[_0x3f4ce5(0x177)][_0x3f4ce5(0x1d3)][_0x3f4ce5(0x1a6)]({..._0x38dab2,'abortSignal':_0x3dda41,'renderingStrategy':_0x16cb0f}),_0x38dab2[_0x3f4ce5(0x1ed)]&&this[_0x3f4ce5(0x17a)](_0x38dab2['id']);});}[_0x282ed4(0x210)](_0x480222,_0x4766b9){const _0x2fd841=_0x282ed4;this[_0x2fd841(0x177)][_0x2fd841(0x1d3)][_0x2fd841(0x1cd)](_0x480222,_0x4766b9);}async[_0x282ed4(0x1ff)](_0x385ec1){const _0x2d76d6=_0x282ed4,_0x224bae=_0x385ec1[_0x2d76d6(0x1ee)]||this[_0x2d76d6(0x18c)];return this[_0x2d76d6(0x208)][_0x2d76d6(0x20d)](async _0x9ec25d=>{const _0x3ddee4=_0x2d76d6;await this[_0x3ddee4(0x177)][_0x3ddee4(0x1d3)][_0x3ddee4(0x17f)]({..._0x385ec1,'abortSignal':_0x9ec25d,'renderingStrategy':_0x224bae}),_0x385ec1[_0x3ddee4(0x1ed)]&&this[_0x3ddee4(0x17a)](_0x385ec1['id']);});}[_0x282ed4(0x1be)](_0x451133){const _0x503b92=_0x282ed4;this[_0x503b92(0x177)][_0x503b92(0x1d3)][_0x503b92(0x1c7)](_0x451133);}[_0x282ed4(0x17a)](_0xf7a0f3){const _0x340627=_0x282ed4;this[_0x340627(0x177)][_0x340627(0x1d3)][_0x340627(0x17b)](_0xf7a0f3);}[_0x282ed4(0x1c9)](_0x26a3be){const _0x595a12=_0x282ed4;this[_0x595a12(0x177)][_0x595a12(0x1d3)][_0x595a12(0x178)]()[_0x595a12(0x180)](_0x45ae70=>_0x45ae70[_0x595a12(0x1b6)](_0x26a3be))[_0x595a12(0x193)](_0x4a9f94=>this[_0x595a12(0x177)][_0x595a12(0x1d3)][_0x595a12(0x1e7)](_0x4a9f94));}[_0x282ed4(0x1dc)](){const _0x31497b=_0x282ed4;this[_0x31497b(0x184)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x1}),this[_0x31497b(0x177)][_0x31497b(0x1ad)][_0x31497b(0x1e8)](!this[_0x31497b(0x18e)][_0x31497b(0x188)][_0x31497b(0x20a)](_0x31497b(0x18a))),this[_0x31497b(0x1c3)]=!0x0,this[_0x31497b(0x177)][_0x31497b(0x1d3)][_0x31497b(0x1b8)]();}[_0x282ed4(0x1f7)](_0x4130ad){const _0xe3452d=_0x282ed4;this[_0xe3452d(0x208)][_0xe3452d(0x1bb)](),this[_0xe3452d(0x177)][_0xe3452d(0x1d3)][_0xe3452d(0x178)]()[_0xe3452d(0x180)](_0x57e485=>_0x57e485[_0xe3452d(0x1b6)](_0x4130ad['id']))[_0xe3452d(0x193)](_0x74c8fd=>this[_0xe3452d(0x17a)](_0x74c8fd)),this[_0xe3452d(0x1c3)]=!0x1,this[_0xe3452d(0x177)][_0xe3452d(0x1d3)][_0xe3452d(0x1db)]();}async[_0x282ed4(0x20c)](){const _0x135e91=_0x282ed4;return this[_0x135e91(0x208)][_0x135e91(0x1f1)][_0x135e91(0x1e2)](()=>{const _0x386a01=_0x135e91;this[_0x386a01(0x1c3)]=!0x1,this[_0x386a01(0x177)][_0x386a01(0x1d3)][_0x386a01(0x1db)]();});}[_0x282ed4(0x1f0)](_0x22e809,_0xb5a2ab){const _0x717e8c=_0x282ed4;this[_0x717e8c(0x177)][_0x717e8c(0x1ad)][_0x717e8c(0x1f0)](_0x22e809,_0xb5a2ab);}[_0x282ed4(0x17e)](_0x3a520b){const _0x1c30fe=_0x282ed4;this[_0x1c30fe(0x177)][_0x1c30fe(0x1ad)][_0x1c30fe(0x17e)](_0x3a520b);}[_0x282ed4(0x198)](_0xb48ad,_0x58fe86){const _0x21c0b9=_0x282ed4;this[_0x21c0b9(0x177)][_0x21c0b9(0x1ad)][_0x21c0b9(0x198)](_0xb48ad,_0x58fe86);}[_0x282ed4(0x1a0)](_0x4832fc){const _0x2735b3=_0x282ed4;this[_0x2735b3(0x177)][_0x2735b3(0x1ad)][_0x2735b3(0x1a0)](_0x4832fc);}[_0x282ed4(0x1e1)](_0x45e4df){const _0x490db9=_0x282ed4;this[_0x490db9(0x177)][_0x490db9(0x1ad)][_0x490db9(0x1e1)](_0x45e4df);}[_0x282ed4(0x1d0)](){const _0x4c05cd=_0x282ed4;this[_0x4c05cd(0x177)][_0x4c05cd(0x1ad)][_0x4c05cd(0x1d0)]();}[_0x282ed4(0x194)](){const _0x2b029c=_0x282ed4;this[_0x2b029c(0x177)][_0x2b029c(0x1ad)][_0x2b029c(0x194)]();}[_0x282ed4(0x18f)](_0x4dd00b,_0x277a5b,_0x54406f){const _0x10806c=_0x282ed4;this[_0x10806c(0x177)][_0x10806c(0x1ad)][_0x10806c(0x18f)](_0x4dd00b,_0x277a5b,_0x54406f);}[_0x282ed4(0x1ef)](){const _0x81f4db=_0x282ed4;this[_0x81f4db(0x177)][_0x81f4db(0x1ad)][_0x81f4db(0x1ef)](),this[_0x81f4db(0x177)][_0x81f4db(0x1ad)][_0x81f4db(0x19d)](this[_0x81f4db(0x18d)]());}[_0x282ed4(0x183)](_0x586c7f){const _0x4a155c=_0x282ed4;this[_0x4a155c(0x177)][_0x4a155c(0x1ad)][_0x4a155c(0x183)](_0x586c7f);}[_0x282ed4(0x1a4)](_0x32870b){const _0x5a7c04=_0x282ed4;this[_0x5a7c04(0x177)][_0x5a7c04(0x1ad)][_0x5a7c04(0x1cb)](_0x32870b[_0x5a7c04(0x1e6)]),this[_0x5a7c04(0x177)][_0x5a7c04(0x1ad)][_0x5a7c04(0x1b3)](_0x32870b[_0x5a7c04(0x1c5)]),this[_0x5a7c04(0x177)][_0x5a7c04(0x1ad)][_0x5a7c04(0x19d)](this[_0x5a7c04(0x18d)](_0x32870b));}[_0x282ed4(0x1bf)](_0x38066e,_0x17a58b){const _0xfa38d6=_0x282ed4;this[_0xfa38d6(0x177)][_0xfa38d6(0x1ad)][_0xfa38d6(0x19c)](_0x38066e),_0x17a58b&&this[_0xfa38d6(0x177)][_0xfa38d6(0x1ad)][_0xfa38d6(0x1e8)](!0x1);}[_0x282ed4(0x1d9)](_0x33fd59){const _0x5abe5d=_0x282ed4;this[_0x5abe5d(0x18c)]=_0x33fd59;}[_0x282ed4(0x1f2)](_0x133507){const _0x6cef39=_0x282ed4;this[_0x6cef39(0x177)][_0x6cef39(0x1d3)][_0x6cef39(0x1f2)](_0x133507);}[_0x282ed4(0x1d8)](){const _0x43efa1=_0x282ed4;this[_0x43efa1(0x185)](_0x19279e(this[_0x43efa1(0x18e)][_0x43efa1(0x1dd)],_0x43efa1(0x1fe)));}[_0x282ed4(0x185)](_0x2b852b,_0x5992a1=!0x1){const _0x487288=_0x282ed4;if(_0x5992a1&&!_0x22b608()&&_0x2b852b[_0x487288(0x191)])return this[_0x487288(0x177)][_0x487288(0x1f4)][_0x487288(0x16f)]='',void this[_0x487288(0x1b2)](_0x2b852b);this[_0x487288(0x177)][_0x487288(0x1f4)][_0x487288(0x16f)]=_0x2b852b;}[_0x282ed4(0x184)](_0x1f6195){const _0x530d87=_0x282ed4,_0x7b9253=this[_0x530d87(0x1ce)](_0x1f6195);this[_0x530d87(0x177)][_0x530d87(0x1d3)][_0x530d87(0x184)](_0x7b9253);}[_0x282ed4(0x1b2)](_0x5a8f34){const _0x348ed2=_0x282ed4;let _0x379d30=0x0;clearInterval(this[_0x348ed2(0x1ec)]),this[_0x348ed2(0x1ec)]=setInterval(()=>{const _0x5dcca4=_0x348ed2;this[_0x5dcca4(0x177)][_0x5dcca4(0x1f4)][_0x5dcca4(0x16f)]=this[_0x5dcca4(0x177)][_0x5dcca4(0x1f4)][_0x5dcca4(0x16f)]+_0x5a8f34[_0x379d30],_0x379d30++,_0x379d30===_0x5a8f34[_0x5dcca4(0x191)]&&clearInterval(this[_0x5dcca4(0x1ec)]);},0x1e);}[_0x282ed4(0x190)](_0xd94442){const _0x434c37=_0x282ed4;this[_0x434c37(0x177)][_0x434c37(0x1f4)][_0x434c37(0x1a7)]=_0xd94442;}[_0x282ed4(0x1ce)](_0x2114c9){const _0x48d86f=_0x282ed4;return _0x2114c9?_0x2114c9[_0x48d86f(0x1e6)]&&_0x2114c9[_0x48d86f(0x1c5)]?_0x19279e(this[_0x48d86f(0x18e)][_0x48d86f(0x1dd)],_0x48d86f(0x200)):_0x2114c9[_0x48d86f(0x1e6)]?_0x19279e(this[_0x48d86f(0x18e)][_0x48d86f(0x1dd)],_0x48d86f(0x1a5)):_0x2114c9[_0x48d86f(0x1c5)]?_0x19279e(this[_0x48d86f(0x18e)][_0x48d86f(0x1dd)],_0x48d86f(0x1ca)):_0x19279e(this[_0x48d86f(0x18e)][_0x48d86f(0x1dd)],_0x48d86f(0x196)):'';}[_0x282ed4(0x18d)](_0x4d671a){const _0x40c550=_0x282ed4;return _0x4d671a?_0x4d671a[_0x40c550(0x1e6)]&&_0x4d671a[_0x40c550(0x1c5)]?_0x19279e(this[_0x40c550(0x18e)][_0x40c550(0x1dd)],_0x40c550(0x186)):_0x4d671a[_0x40c550(0x1e6)]?_0x19279e(this[_0x40c550(0x18e)][_0x40c550(0x1dd)],_0x40c550(0x1ea)):_0x4d671a[_0x40c550(0x1c5)]?_0x19279e(this[_0x40c550(0x18e)][_0x40c550(0x1dd)],_0x40c550(0x1df)):_0x19279e(this[_0x40c550(0x18e)][_0x40c550(0x1dd)],_0x40c550(0x1c1)):_0x19279e(this[_0x40c550(0x18e)][_0x40c550(0x1dd)],_0x40c550(0x1c1));}[_0x282ed4(0x172)](_0x45b7c4,_0x2817de,_0x53c5c9,_0x1b4f95){const _0x3465e3=_0x282ed4;this[_0x3465e3(0x177)][_0x3465e3(0x172)](_0x45b7c4,_0x2817de,_0x53c5c9,_0x1b4f95);}[_0x282ed4(0x1e4)](_0x13a001){const _0x384c87=_0x282ed4;this[_0x384c87(0x177)][_0x384c87(0x1e4)](_0x13a001);}[_0x282ed4(0x19b)](){const _0x20762b=_0x282ed4;this[_0x20762b(0x177)][_0x20762b(0x1ad)][_0x20762b(0x19b)]();}[_0x282ed4(0x1a1)](_0x5b9318,_0x5c8f7c){const _0x1b4c69=_0x282ed4;this[_0x1b4c69(0x177)][_0x1b4c69(0x1d3)][_0x1b4c69(0x1a9)](_0x5b9318,_0x5c8f7c);}[_0x282ed4(0x1e9)](){const _0x128fd2=_0x282ed4;this[_0x128fd2(0x177)][_0x128fd2(0x1ad)][_0x128fd2(0x17c)]=!0x0;}[_0x282ed4(0x1e5)](){const _0xdb66e3=_0x282ed4;this[_0xdb66e3(0x177)][_0xdb66e3(0x1ad)][_0xdb66e3(0x17c)]=!0x1;}}
|
|
@@ -2,8 +2,203 @@
|
|
|
2
2
|
* @license Copyright (c) 2003-2025, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
3
|
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
4
4
|
*/
|
|
5
|
-
import {
|
|
5
|
+
import { type AIConnector, type AIUserMessage } from '../../aicore/aiconnector.js';
|
|
6
|
+
import { AIContextItemType, AIContextTextResourceType, type AIContextItem, type AIContextItemRequestData } from '../../aicore/model/aicontext.js';
|
|
6
7
|
export declare const AI_CONTEXT_MODEL_EVENT_NAMES: readonly ["contextItemAdded", "contextItemRemoved", "contextItemLoadingEnded", "contextSent", "error", "addContextOptionsChanged", "sourceResourcesLoaded", "resourceStateChanged", "uploadProgressChanged"];
|
|
8
|
+
declare const AIChatContext_base: {
|
|
9
|
+
new (): import("ckeditor5/src/utils.js").Observable;
|
|
10
|
+
prototype: import("ckeditor5/src/utils.js").Observable;
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* Manages the context of the current conversation.
|
|
14
|
+
*/
|
|
15
|
+
export declare class AIChatContext extends /* #__PURE__ */ AIChatContext_base {
|
|
16
|
+
constructor({ connector, config, ownerId }: {
|
|
17
|
+
connector: AIConnector;
|
|
18
|
+
config?: AIChatContextConfig;
|
|
19
|
+
ownerId: string;
|
|
20
|
+
});
|
|
21
|
+
/**
|
|
22
|
+
* Initializes the context.
|
|
23
|
+
*/
|
|
24
|
+
init(): void;
|
|
25
|
+
/**
|
|
26
|
+
* Returns the pending context items that will be sent to the AI endpoint in the next interaction.
|
|
27
|
+
*
|
|
28
|
+
* @returns Map of pending context items keyed by their uiId
|
|
29
|
+
*/
|
|
30
|
+
getPendingContextItems(): Map<string, AIContextItem>;
|
|
31
|
+
/**
|
|
32
|
+
* Populates context items from message data.
|
|
33
|
+
* This method converts user message content to context items and adds them to the conversation context.
|
|
34
|
+
*/
|
|
35
|
+
populateFromMessage(content: AIUserMessage['content'][0]): Promise<AIContextItem>;
|
|
36
|
+
/**
|
|
37
|
+
* Creates a context item from conversation content.
|
|
38
|
+
*/
|
|
39
|
+
private _createContextItemFromContent;
|
|
40
|
+
/**
|
|
41
|
+
* Returns all context items that have been sent to the AI endpoint in the current conversation.
|
|
42
|
+
*
|
|
43
|
+
* @returns Map of sent context items keyed by their uiId
|
|
44
|
+
*/
|
|
45
|
+
getSentContextItems(): Map<string, AIContextItem>;
|
|
46
|
+
/**
|
|
47
|
+
* Removes a context item from the pending context.
|
|
48
|
+
* Read-only items cannot be removed and the method returns early.
|
|
49
|
+
*
|
|
50
|
+
* @param uiId The unique identifier of the context item to remove
|
|
51
|
+
*/
|
|
52
|
+
removeFromContext(uiId: string): void;
|
|
53
|
+
/**
|
|
54
|
+
* Clears all pending context items and adds the current document to the conversation context if it exists.
|
|
55
|
+
*/
|
|
56
|
+
clearPendingContextItems(): void;
|
|
57
|
+
/**
|
|
58
|
+
* Adds context items to the conversation context and clears the pending context items.
|
|
59
|
+
*/
|
|
60
|
+
addToConversationContext(contextItems: Map<string, AIContextItem>): void;
|
|
61
|
+
/**
|
|
62
|
+
* Checks if the current document is in the pending context.
|
|
63
|
+
*
|
|
64
|
+
* @returns True if the current document is in pending context, false otherwise
|
|
65
|
+
*/
|
|
66
|
+
isCurrentDocumentInContext(): boolean;
|
|
67
|
+
isSelectionInContext(): boolean;
|
|
68
|
+
/**
|
|
69
|
+
* Checks if the current document is in the conversation context.
|
|
70
|
+
*
|
|
71
|
+
* @returns True if the current document is in conversation context, false otherwise
|
|
72
|
+
*/
|
|
73
|
+
isCurrentDocumentInConversation(): boolean;
|
|
74
|
+
/**
|
|
75
|
+
* Converts context items to request data format for API endpoint.
|
|
76
|
+
* This static method transforms the internal context item format to the format expected by the AI connector.
|
|
77
|
+
*
|
|
78
|
+
* @param contextItems Map of context items to convert
|
|
79
|
+
* @returns Array of context items in API request format
|
|
80
|
+
*/
|
|
81
|
+
static mapContextItemsToRequestData(contextItems: Map<string, AIContextItem>): Array<AIContextItemRequestData>;
|
|
82
|
+
/**
|
|
83
|
+
* Adds files to the context by uploading them and creating context items.
|
|
84
|
+
* This method handles multiple files concurrently and tracks upload progress.
|
|
85
|
+
*
|
|
86
|
+
* @param files Array of File objects to upload and add to context
|
|
87
|
+
* @param [attributes] Optional attributes object containing resourceId and label for tracking purposes and context chips
|
|
88
|
+
* @param [type] Context item type, defaults to AIContextItemType.FILE to indicate that the file is being added as a file or text
|
|
89
|
+
* @returns Promise that resolves when all files are processed
|
|
90
|
+
*/
|
|
91
|
+
addFilesToContext(files: Array<File>, attributes?: {
|
|
92
|
+
resourceId: string;
|
|
93
|
+
label: string;
|
|
94
|
+
}, type?: AIContextItemType.FILE | AIContextItemType.TEXT): Promise<void>;
|
|
95
|
+
/**
|
|
96
|
+
* Adds the current document to the pending context.
|
|
97
|
+
* If the document is already in context, this method returns early without changes.
|
|
98
|
+
*
|
|
99
|
+
* @param label Display label for the current document
|
|
100
|
+
*/
|
|
101
|
+
addCurrentDocumentToContext(label: string): void;
|
|
102
|
+
/**
|
|
103
|
+
* Updates the current document in the pending context with new content and version.
|
|
104
|
+
* This method uploads the document content and updates the context item accordingly.
|
|
105
|
+
*
|
|
106
|
+
* @param content The document content to upload, or undefined to skip
|
|
107
|
+
* @param version Version number of the document for change tracking
|
|
108
|
+
* @returns Promise that resolves when the document is updated
|
|
109
|
+
*/
|
|
110
|
+
updateCurrentDocument(content: string | undefined, version: number, sessionId: string | null, selections: Array<{
|
|
111
|
+
start: number;
|
|
112
|
+
end: number;
|
|
113
|
+
htmlFragment: string;
|
|
114
|
+
}>): Promise<void>;
|
|
115
|
+
addSelectionToContext(selection: string): void;
|
|
116
|
+
removeSelectionFromContext(): void;
|
|
117
|
+
/**
|
|
118
|
+
* Adds a URL to the context by uploading it and creating a context item.
|
|
119
|
+
* This method handles URL upload with proper error handling and progress tracking.
|
|
120
|
+
*
|
|
121
|
+
* @param url The URL to upload and add to context
|
|
122
|
+
* @param [attributes] Optional attributes object containing resourceId and label for tracking purposes and context chips
|
|
123
|
+
* @returns Promise that resolves when the URL is processed
|
|
124
|
+
*/
|
|
125
|
+
addUrlToContext(url: string, attributes?: {
|
|
126
|
+
resourceId: string;
|
|
127
|
+
label: string;
|
|
128
|
+
}): Promise<void>;
|
|
129
|
+
/**
|
|
130
|
+
* Loads resources for a given source provider with the specified query.
|
|
131
|
+
* This method calls the source's getResources callback and updates resource states.
|
|
132
|
+
*
|
|
133
|
+
* @param sourceId The unique identifier of the source provider
|
|
134
|
+
* @param query Search query to filter resources
|
|
135
|
+
* @param uid Unique identifier for the request to prevent race conditions
|
|
136
|
+
* @returns Promise resolving to array of resources with context state
|
|
137
|
+
*/
|
|
138
|
+
loadSourceResources(sourceId: string, query: string, uid: string): Promise<Array<AIContextResourceState>>;
|
|
139
|
+
addResourceToContext(source: AIContextProvider, resource: AIContextResource): Promise<void>;
|
|
140
|
+
}
|
|
141
|
+
export type AIChatContextItemAddedEvent = {
|
|
142
|
+
name: 'contextItemAdded';
|
|
143
|
+
args: [
|
|
144
|
+
{
|
|
145
|
+
contextItem: AIContextItem;
|
|
146
|
+
isLoading: boolean;
|
|
147
|
+
}
|
|
148
|
+
];
|
|
149
|
+
};
|
|
150
|
+
export type AIChatContextItemRemovedEvent = {
|
|
151
|
+
name: 'contextItemRemoved';
|
|
152
|
+
args: [
|
|
153
|
+
{
|
|
154
|
+
uiId: string;
|
|
155
|
+
type?: AIContextItemType;
|
|
156
|
+
}
|
|
157
|
+
];
|
|
158
|
+
};
|
|
159
|
+
export type AIChatContextSentEvent = {
|
|
160
|
+
name: 'contextSent';
|
|
161
|
+
args: [
|
|
162
|
+
{
|
|
163
|
+
contextItems: Array<AIContextItem>;
|
|
164
|
+
}
|
|
165
|
+
];
|
|
166
|
+
};
|
|
167
|
+
export type AIChatContextAddContextOptionsChangedEvent = {
|
|
168
|
+
name: 'addContextOptionsChanged';
|
|
169
|
+
args: [
|
|
170
|
+
{
|
|
171
|
+
options: AIAddContextOptionsState;
|
|
172
|
+
}
|
|
173
|
+
];
|
|
174
|
+
};
|
|
175
|
+
export type AIChatContextUploadProgressChangedEvent = {
|
|
176
|
+
name: 'uploadProgressChanged';
|
|
177
|
+
args: [
|
|
178
|
+
{
|
|
179
|
+
isUploadInProgress: boolean;
|
|
180
|
+
}
|
|
181
|
+
];
|
|
182
|
+
};
|
|
183
|
+
export type AIAddContextOptionsState = {
|
|
184
|
+
document: {
|
|
185
|
+
enabled: boolean;
|
|
186
|
+
isHidden: boolean;
|
|
187
|
+
};
|
|
188
|
+
urls: {
|
|
189
|
+
enabled: boolean;
|
|
190
|
+
};
|
|
191
|
+
files: {
|
|
192
|
+
enabled: boolean;
|
|
193
|
+
};
|
|
194
|
+
sources: Array<AIContextProviderState>;
|
|
195
|
+
};
|
|
196
|
+
export type AIContextProviderState = AIContextProvider & {
|
|
197
|
+
resources: Array<AIContextResourceState>;
|
|
198
|
+
};
|
|
199
|
+
export type AIContextResourceState = AIContextResource & {
|
|
200
|
+
isInContext?: boolean;
|
|
201
|
+
};
|
|
7
202
|
/**
|
|
8
203
|
* The configuration of the AI Chat menu for adding resources to the prompt context.
|
|
9
204
|
*
|
|
@@ -132,3 +327,4 @@ export type AIContextTextResource = {
|
|
|
132
327
|
content: string;
|
|
133
328
|
type: AIContextTextResourceType;
|
|
134
329
|
};
|
|
330
|
+
export {};
|