@ckeditor/ckeditor5-ai 47.3.0-alpha.5 → 47.3.0-alpha.7
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 +5 -5
- 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.js +1 -1
- package/src/aichat/model/aichatconversation.js +1 -1
- package/src/aichat/model/aichatinteraction.js +1 -1
- 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/aichatcontextresourceslistview.js +1 -1
- package/src/aichat/ui/controls/resources/aichatcontextresourcesview.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/aichatresourcessearchinputview.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/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 +2 -2
- 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/aimodels.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/aicore/utils/scrollmanager.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.js +1 -1
- package/src/aiquickactions/aiquickactionscommand.js +1 -1
- package/src/aiquickactions/aiquickactionsediting.js +1 -1
- 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/aiquickactions/ui/aiquickactionsfilteredlistview.js +1 -1
- package/src/aiquickactions/ui/dropdownmenubuttonwithhighlightview.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/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/aireviewmodefinishreviewbuttonview.js +1 -1
- package/src/aireviewmode/ui/aireviewmodegeneralerrorview.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/aireviewmodeformdropdown.js +1 -1
- package/src/aireviewmode/ui/form/aireviewmodeformmanager.js +1 -1
- 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/errors.js +1 -1
- package/src/errorsmap.js +1 -1
- package/src/index.js +1 -1
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const _0x722d79=_0x5d0d;(function(_0x152726,_0x3fa067){const _0x3873ae=_0x5d0d,_0x264994=_0x152726();while(!![]){try{const _0x15ccab=-parseInt(_0x3873ae(0x20f))/0x1*(-parseInt(_0x3873ae(0x195))/0x2)+parseInt(_0x3873ae(0x26c))/0x3*(-parseInt(_0x3873ae(0x2c0))/0x4)+parseInt(_0x3873ae(0x210))/0x5*(-parseInt(_0x3873ae(0x23b))/0x6)+parseInt(_0x3873ae(0x1a9))/0x7+parseInt(_0x3873ae(0x2d3))/0x8*(parseInt(_0x3873ae(0x2a3))/0x9)+-parseInt(_0x3873ae(0x2ce))/0xa*(parseInt(_0x3873ae(0x19f))/0xb)+-parseInt(_0x3873ae(0x20c))/0xc;if(_0x15ccab===_0x3fa067)break;else _0x264994['push'](_0x264994['shift']());}catch(_0x20d857){_0x264994['push'](_0x264994['shift']());}}}(_0x149e,0x35b6b));import{ContextPlugin as _0x2222db,Editor as _0x223500}from'ckeditor5/src/core.js';function _0x149e(){const _0x12217b=['setIsUploadInProgress','setFeedItemRenderingStrategy','_aiChatModels','_aiChatUi','config','getRoot','_aiEditing','getConversation','ai-chat-url-upload-failed','AITabs','AI_BALLOON_HEADER_TITLE','uid','message','filter','populateSourceResourceBalloon','removeSelectionFromChatContext','AIConnector','collaboration.channelId','addContextItem','ai.availableReplyActions','focusPromptInput','addUrlToContext','has','startInteraction','howMany','AI_CHAT_INVALID_REQUEST','sources','current-document','_removeFromContext','type','clearConversationContextUI','anchorId','getOperations','documentContextContent','ai-chat-source-resources-load-failed','removeFeedInteraction','dislike','showChangeInText','clearPendingContextUI','getDocumentData','like','split','interactionStarted','revert','handleUserInteraction','remove','1328AOhJwS','map','getChildren','_logError','_updateRatings','afterInit','editors','ai.chat.models.displayedModels','removeMarker','requires','506GGELqP','ai.chat.models.defaultModelId','_getDocumentRangeForReplyChanges','Liked\x20response','createRange','updateFeedItemAIReplySuggestionContent','getGroupId','applySuggestion','ready','getDiff','2121665QbBvxr','showNext','resizedTabs','isUploadInProgress','setLoadingMessage','ai-chat-context-file-too-many-pages','scrollFeedToSuggestion','sourceResourcesLoaded','addFeedItemAISuggestion','uiId','main','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_URL','pluginName','upsertAIChatRating','stop','isStarted','AIChatController','resource','updateFeedItemAIReplyContent','updateCapabilities','setConversationTitle','createPositionAt','rejected','context','mapper','reasoningFinished','sourceId','addSelectionToChatContext','abortPromptStream','start','_batchToChanges','rootName','stopListening','version','_removeAISelectionMarkers','getReply','addFeedItemUserMessage','nextSibling','ai-request-aborted','_insertSuggestion','contextItems','document','updateContent','reasoningStarted','node','contextItem','contextItemAdded','updateCurrentDocumentInContext','addFeedInteractionHeader','new','_toggleWebSearch','addDocumentToContext','addFeedItemAIReply','ai-chat-context-invalid-data','markers','messageId','_aiConnector','_handleStartConversation','resizeTabs','ai-chat-controller-mouse-over','replyContentUpdated','resetMessageInput','AI_CHAT_CONTEXT_INVALID_DATA','root','ai-chat-conversation-not-found','getAttribute','closeSourceResourceBalloon','isCurrentDocumentInContext','getTransformedByOperation','_previewedChangeGroup','_integrateEditor','isLoading','ai-chat-conversation-init-failed','isOpen','updateFeedItemAIReplySources','ai-chat-resource-load-failed','chat','applyOperation','_balloonShowDiff','getChildAtOffset','AI_CHAT_RESOURCE_LOAD_FAILED','addOperation','interactionDestroyed','isDocumentOperation','dialogClosed','ai-chat-conversation-start-failed','AI_CHAT_UNABLE_TO_LOAD_CONVERSATION','AIChatUI','DocumentCompare','ai-no-track-changes','toString','toggleWebSearch','view','Undo','getSelectionText','end','selectModel','ai-chat-invalid-request','data-id','420648rUtUWD','viewRangeToDom','interactionFinished','371NMUYlA','431155VQfglY','AI_CHAT_CONTEXT_UNSUPPORTED_FILE_TYPE','index','resourceStateChanged','setIsMaximized','alignToTop','setSelectedModel','unshift','startsWith','model','listenTo','disableControls','AI_CHAT_CONTEXT_FILE_TOO_MANY_PAGES','full','isPremiumPlugin','toggleSuggestionDisplayMode','close','push','activateTab','startAutoScroll','contextSent','isModelAvailable','commands','ai-chat-context-unsupported-file-type','isCurrentDocumentInConversation','indexes','sendMessage','marker','ai-chat-missing-channel-id','addContextOptionsChanged','setChangeGroupState','sendUserMessage','AI_CHAT_ABORTED_MESSAGE','indexOf','ai-chat-context-form-data-size-limits-exceeded','Disliked\x20response','delete','_updateReplyContent','AI_CHAT_UNABLE_TO_START_CONVERSATION','_createFromRanges','AI_CHAT_GENERIC_ERROR','interactionCreated','_flushLastInteractionUI','6eJpySK','_showConversationHistory','getRanges','contextItemRemoved','_startConversationSafely','history','options','editing','_handleUIUserMessage','updateResourceState','removeContextItem','mouseOverSuggestion','setContextItemLoading','locale','AI_CHAT_CONTEXT_UNABLE_TO_LOAD_RESOURCES','text-delta','updateConversationTitle','source','change','ai-chat-context-file-too-large','fetchConversation','getInteractionAndReplyById','state','length','add','set','ai-chat-controller-no-active-conversation','insertSuggestion','hideFakeVisualSelection','showFakeVisualSelection','createPositionFromPath','TrackChangesEditing','_setIsMaximized','log','Showing\x20conversation\x20history...','addResourceToContext','static','addSelectionToContext','outdated','baseVersion','setModel','AIEditing','getDocumentContext','$graveyard','forEach','plugins','createConversation','conversationInitialized','webSearchFinished','831507jPTgyQ','range','capabilitiesUpdated','_applyOperationsAsSuggestions','undo','loadConversation','AI_CHAT_UNTITLED_CONVERSATION','ai-chat-file-upload-failed','interactionId','modelSelected','init','removeFromContext','resetConversationTitle','webSearchStarted','getContentParts','error','_scrollToSuggestionRange','ai.chat.context','getChild','open','handleRemovedConversation','maxOffset','toggleLoadingSkeleton','get','replyCreated','loadSourceResources','streaming','enableControls','stopInteraction','isDisabled','content','findIndex','toggleReasoning','finishInteraction','addFeedItemStaticMessage','_openBalloonFor','uploadProgressChanged','redo','removeSelectionFromContext','lastInteraction','showDiff','changes','addFeedItemError','getFirstRange','TrackChanges','ai-conversation-','addFilesToContext','load','_toggleReasoning','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_FILE','toViewRange','getInteraction','accepted','_applySuggestion','query','135cMKuJt','children','changeGroups','data','AI_CHAT_CONTEXT_UNSUPPORTED_TYPE','addCurrentDocumentToContext','removed','sourcePosition','AI_CHAT_CONTEXT_FILE_TOO_LARGE','addFileToContext','cloneNode','getMarkersGroup','rejectSuggestion','setAddContextOptions','parse','partIndex','domConverter','isInContext','resize','hasChanges','setConversationContext','updateFeedItemAIReplySuggestionPartState','modification-delta','mouseLeaveSuggestion','startConversation','path','AI_CHAT_CONTEXT_FORM_DATA_SIZE_LIMITS_EXCEEDED','replies','AI_CHAT_CONTEXT_CURRENT_DOCUMENT','4xTavfX','resourceId','find','selection','contextItemLoadingEnded','replyId','selectedModel','showPrevious','ai-chat-context-unsupported-type','slice','pending','getPath','isOfficialPlugin','resources','55240HSmQui','activeConversation','replyChangeGroupStateUpdated','batch','from','172336VVSKhk','_stopLastInteraction'];_0x149e=function(){return _0x12217b;};return _0x149e();}import{CKEditorError as _0x56bfe4,logError as _0x403c82,scrollViewportToShowTarget as _0x2ac001,uid as _0x567464}from'ckeditor5/src/utils.js';import{AIConnector as _0x371ca2}from'../aicore/aiconnector.js';import{AITabs as _0x15b59e}from'../aitabs/aitabs.js';import{AIChatConversation as _0x5188f9}from'./model/aichatconversation.js';import{getTranslation as _0xc3a8c}from'../aicore/utils/common-translations.js';import{AI_VISUAL_SELECTION_MARKER_NAME as _0x5dc995}from'../aicore/aiediting.js';import{AI_REPLY_ACTIONS as _0xaf499c}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';import{AIChatModels as _0x405bb5}from'./model/aichatmodels.js';import{getEditorFromContext as _0x4dfe45}from'../aicore/utils/geteditorfromcontext.js';import{DocumentCompare as _0x1e0fe3,DATA_ID_MODEL_ATTRIBUTE as _0x47a7f5}from'ckeditor5-collaboration/src/collaboration-core.js';import{fixMarkerOperationOldRange as _0x316879,getOperationsFromReply as _0x3fe6}from'../aicore/utils/getoperationsfromreply.js';import{expandSelectionWithContext as _0x118718,getMinimalSelection as _0x136d73}from'../aicore/utils/getsuggestionpartsfromreply.js';import{ModelRange as _0x419998,_DetachOperation as _0x347c6f}from'ckeditor5/src/engine.js';import{findOne as _0x5c46b8,getAttribute as _0x174d3e,serialize as _0x9af624,Document as _0x301a4d,findByAttribute as _0x244b7e}from'../aicore/utils/htmlparser.js';import{IconAI as _0x5c5b7c}from'@ckeditor/ckeditor5-icons';import{AISuggestionContainerView as _0x72ff3}from'../aicore/ui/suggestioncontainer/aisuggestioncontainerview.js';function _0x5d0d(_0x384c83,_0x4caa46){const _0x149e86=_0x149e();return _0x5d0d=function(_0x5d0d58,_0x1e46bd){_0x5d0d58=_0x5d0d58-0x16e;let _0x4416bf=_0x149e86[_0x5d0d58];return _0x4416bf;},_0x5d0d(_0x384c83,_0x4caa46);}import{AIBalloon as _0x1641f1}from'../aiballoon/aiballoon.js';export class AIChatController extends _0x2222db{[_0x722d79(0x2db)];[_0x722d79(0x1e1)];[_0x722d79(0x2d8)];[_0x722d79(0x2d7)];[_0x722d79(0x1c7)]=new Map();[_0x722d79(0x1ee)]=null;[_0x722d79(0x1f7)]=!0x1;static get[_0x722d79(0x19e)](){return[_0x371ca2,_0x1641f1,_0x1e0fe3];}static get[_0x722d79(0x1b5)](){const _0x2adda9=_0x722d79;return _0x2adda9(0x1b9);}static get[_0x722d79(0x2cc)](){return!0x0;}static get[_0x722d79(0x21e)](){return!0x0;}[_0x722d79(0x276)](){const _0x562a99=_0x722d79;this[_0x562a99(0x1e1)]=this[_0x562a99(0x1c0)][_0x562a99(0x268)][_0x562a99(0x283)](_0x562a99(0x177)),this[_0x562a99(0x2d8)]=this[_0x562a99(0x1c0)][_0x562a99(0x268)][_0x562a99(0x283)](_0x562a99(0x200)),this[_0x562a99(0x2db)]=this[_0x562a99(0x1c0)][_0x562a99(0x268)][_0x562a99(0x283)](_0x562a99(0x264)),this[_0x562a99(0x2d7)]=new _0x405bb5({'connector':this[_0x562a99(0x1e1)],'availableModels':this[_0x562a99(0x1c0)][_0x562a99(0x2d9)][_0x562a99(0x283)](_0x562a99(0x19c)),'defaultModelId':this[_0x562a99(0x1c0)][_0x562a99(0x2d9)][_0x562a99(0x283)](_0x562a99(0x1a0))});const _0x33c077=this[_0x562a99(0x1c0)][_0x562a99(0x268)][_0x562a99(0x283)](_0x562a99(0x170));this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x2bb),()=>{const _0x56ec1a=_0x562a99;this[_0x56ec1a(0x23f)]();}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x22f),(_0x2cce55,_0x3472e1)=>{const _0x51a53c=_0x562a99;this[_0x51a53c(0x243)]({'userMessage':_0x3472e1});}),this[_0x562a99(0x21a)](_0x33c077,_0x562a99(0x1ab),(_0x24fffd,_0x2d6522)=>{const _0x3a5585=_0x562a99;this[_0x3a5585(0x25b)](_0x2d6522);}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x1e3),()=>{const _0x1aa992=_0x562a99;_0x33c077[_0x1aa992(0x2b5)]();}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x1c5),async()=>{const _0xae4ead=_0x562a99;await this[_0xae4ead(0x2d4)](),await this[_0xae4ead(0x23a)](),this[_0xae4ead(0x176)]();}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x1dc),()=>{const _0x299916=_0x562a99;this[_0x299916(0x2cf)]?.[_0x299916(0x2a8)](_0xc3a8c(this[_0x299916(0x1c0)][_0x299916(0x248)],_0x299916(0x2bf)));}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x2ac),(_0xe52146,_0x2bb65c)=>{const _0x42bbe0=_0x562a99;this[_0x42bbe0(0x2cf)]?.[_0x42bbe0(0x29a)](Array[_0x42bbe0(0x2d2)](_0x2bb65c));}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x17c),(_0x196f40,_0x3b03b6)=>{const _0x686761=_0x562a99;this[_0x686761(0x2cf)]?.[_0x686761(0x17c)](_0x3b03b6);}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x25e),(_0xceb38b,_0x3db746)=>{const _0x3bcf25=_0x562a99;this[_0x3bcf25(0x2cf)]?.[_0x3bcf25(0x25e)](_0x3db746[_0x3bcf25(0x24c)],_0x3db746[_0x3bcf25(0x1ba)]);}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x245),(_0x221f5d,_0x1254ed)=>{const _0x216e5d=_0x562a99;this[_0x216e5d(0x183)](_0x1254ed);}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x285),(_0x1e89e8,_0x1f684e)=>{const _0x351a07=_0x562a99;this[_0x351a07(0x2cf)]?.[_0x351a07(0x285)](_0x1f684e[_0x351a07(0x1c3)],_0x1f684e[_0x351a07(0x2a2)],_0x1f684e[_0x351a07(0x172)]);}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x204),()=>{const _0x21efb3=_0x562a99;this[_0x21efb3(0x1db)]();}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x28c),()=>{const _0x2a1190=_0x562a99;this[_0x2a1190(0x29c)]();}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x209),(_0x41de71,_0x1a7e0f)=>{const _0x5ca3ea=_0x562a99;this[_0x5ca3ea(0x2cf)]?.[_0x5ca3ea(0x263)](_0x1a7e0f);}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x18f),(_0x1d6d66,{replyId:_0x3c25b5})=>{const _0x46f076=_0x562a99;console[_0x46f076(0x25c)](_0x46f076(0x1a2),_0x3c25b5);}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x18b),(_0xba9926,{replyId:_0x112551})=>{const _0x1c6633=_0x562a99;console[_0x1c6633(0x25c)](_0x1c6633(0x233),_0x112551);}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x256),(_0xc6f27f,_0x44353e)=>{const _0x49f989=_0x562a99;this[_0x49f989(0x1c0)][_0x49f989(0x268)][_0x49f989(0x283)](_0x1641f1)[_0x49f989(0x220)](),this[_0x49f989(0x1d0)](_0x44353e);}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x18c),(_0x5b56d4,{replyId:_0x20cb07,partIndex:_0x4d3b47})=>{const _0x46bdaf=_0x562a99;this[_0x46bdaf(0x1f7)]=this[_0x46bdaf(0x2d8)][_0x46bdaf(0x294)],this[_0x46bdaf(0x28f)](_0x20cb07,_0x4d3b47);}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x246),(_0x3e8752,{replyId:_0x51346c,partIndex:_0x224542})=>{const _0x96a3d5=_0x562a99,_0x47a7e9=this[_0x96a3d5(0x1a1)](_0x51346c,_0x224542);_0x47a7e9&&_0x96a3d5(0x266)!=_0x47a7e9[_0x96a3d5(0x26d)][_0x96a3d5(0x1e8)][_0x96a3d5(0x1c8)]&&this[_0x96a3d5(0x2db)][_0x96a3d5(0x258)]([_0x47a7e9[_0x96a3d5(0x26d)]],_0x96a3d5(0x1e4));}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x2ba),()=>{const _0x5850d9=_0x562a99;this[_0x5850d9(0x2db)][_0x5850d9(0x257)](_0x5850d9(0x1e4));}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x1a6),(_0x4e2bfe,_0x57c5fd)=>{const _0x1df968=_0x562a99;this[_0x1df968(0x1c0)][_0x1df968(0x268)][_0x1df968(0x283)](_0x1641f1)[_0x1df968(0x220)](),this[_0x1df968(0x2a1)](_0x57c5fd);}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x21f),async(_0x15de9d,{replyId:_0x2a30e9,showDiff:_0x39461f})=>{const _0x3bba4f=_0x562a99,{reply:_0x53e104}=this[_0x3bba4f(0x250)](_0x2a30e9),_0x224e93=_0x53e104[_0x3bba4f(0x27a)]({'showDiff':_0x39461f});await this[_0x3bba4f(0x2d8)][_0x3bba4f(0x1a4)]({'id':_0x53e104['id'],'parts':_0x224e93,'renderingStrategy':_0x3bba4f(0x25f)});}),this[_0x562a99(0x21a)](this[_0x562a99(0x2d8)],_0x562a99(0x2af),(_0x5d8aca,{replyId:_0xfbf834,partIndex:_0x43b77b})=>{const _0x1a9f0a=_0x562a99;this[_0x1a9f0a(0x1ee)]?.[_0x1a9f0a(0x2c5)]==_0xfbf834&&this[_0x1a9f0a(0x1ee)]?.[_0x1a9f0a(0x2b2)]==_0x43b77b&&this[_0x1a9f0a(0x1c0)][_0x1a9f0a(0x268)][_0x1a9f0a(0x283)](_0x1641f1)[_0x1a9f0a(0x220)]();const {reply:_0x4d7847}=this[_0x1a9f0a(0x250)](_0xfbf834);_0x4d7847[_0x1a9f0a(0x22e)](_0x43b77b,_0x1a9f0a(0x1bf)),this[_0x1a9f0a(0x2db)][_0x1a9f0a(0x257)](_0x1a9f0a(0x1e4));});}async[_0x722d79(0x19a)](){const _0x113b5b=_0x722d79;this[_0x113b5b(0x1c0)]instanceof _0x223500?this[_0x113b5b(0x1ef)](this[_0x113b5b(0x1c0)]):this[_0x113b5b(0x21a)](this[_0x113b5b(0x1c0)][_0x113b5b(0x19b)],_0x113b5b(0x253),(_0x257e78,_0x36a987)=>{const _0x154bc5=_0x113b5b;_0x36a987['on'](_0x154bc5(0x1a7),()=>{const _0x350ace=_0x154bc5;this[_0x350ace(0x1ef)](_0x36a987);});}),await this[_0x113b5b(0x23f)]();}[_0x722d79(0x1d0)](_0x120439){const _0x115fdb=_0x722d79,_0x119257=_0x4dfe45(this[_0x115fdb(0x1c0)]);if(!_0x119257[_0x115fdb(0x268)][_0x115fdb(0x17d)](_0x115fdb(0x298)))throw new _0x56bfe4(_0x115fdb(0x202),null);const _0x1d075c=this[_0x115fdb(0x1c0)][_0x115fdb(0x268)][_0x115fdb(0x283)](_0x115fdb(0x201)),{reply:_0x2ab759,interaction:_0x3fd3ae}=this[_0x115fdb(0x250)](_0x120439[_0x115fdb(0x2c5)]),_0x1e94de=this[_0x115fdb(0x1a1)](_0x120439[_0x115fdb(0x2c5)],_0x120439[_0x115fdb(0x2b2)]),_0x4647d5=void 0x0!==_0x120439[_0x115fdb(0x2b2)]?[_0x2ab759[_0x115fdb(0x2a5)][_0x120439[_0x115fdb(0x2b2)]]]:_0x2ab759[_0x115fdb(0x2a5)][_0x115fdb(0x174)](_0x2ddad8=>_0x115fdb(0x2ca)==_0x2ddad8[_0x115fdb(0x251)]),_0x1ca4f4=_0x4647d5[_0x115fdb(0x196)](_0x4e5568=>_0x2ab759[_0x115fdb(0x2a5)][_0x115fdb(0x231)](_0x4e5568));if(!_0x1e94de||_0x115fdb(0x266)==_0x1e94de[_0x115fdb(0x26d)][_0x115fdb(0x1e8)][_0x115fdb(0x1c8)])return void _0x1ca4f4[_0x115fdb(0x267)](_0x13cbed=>_0x2ab759[_0x115fdb(0x22e)](_0x13cbed,_0x115fdb(0x261)));_0x1ca4f4[_0x115fdb(0x267)](_0x98b69d=>_0x2ab759[_0x115fdb(0x22e)](_0x98b69d,_0x115fdb(0x2a0)));const _0x2729ef=_0x3fe6({'editor':_0x119257,'reply':_0x2ab759,'interaction':_0x3fd3ae,'groups':_0x4647d5,'transform':!0x0,'documentCompare':_0x1d075c,'documentCompareOptions':{'anchor':_0x115fdb(0x1b3),'markDeletions':!0x0}});let _0x4b1225;_0x1e94de&&this[_0x115fdb(0x27c)](_0x1e94de[_0x115fdb(0x26d)]),_0x119257[_0x115fdb(0x219)][_0x115fdb(0x24d)](_0x2cbcf9=>{const _0x250b16=_0x115fdb;_0x4b1225=_0x2cbcf9[_0x250b16(0x2d1)],_0x119257[_0x250b16(0x268)][_0x250b16(0x283)](_0x250b16(0x25a))[_0x250b16(0x26f)](_0x2729ef),this[_0x250b16(0x2db)][_0x250b16(0x257)](_0x250b16(0x1e4));}),this[_0x115fdb(0x1c7)][_0x115fdb(0x254)](_0x4b1225,{'interactionId':_0x3fd3ae['id'],'replyId':_0x2ab759['id'],'indexes':_0x1ca4f4[_0x115fdb(0x2c9)]()}),this[_0x115fdb(0x199)](_0x2ab759);}[_0x722d79(0x2a1)](_0x2e02ac){const _0x3cb3c6=_0x722d79,_0x349d4e=_0x4dfe45(this[_0x3cb3c6(0x1c0)]),_0x1a9b89=this[_0x3cb3c6(0x1c0)][_0x3cb3c6(0x268)][_0x3cb3c6(0x283)](_0x1e0fe3),{reply:_0x5888e2,interaction:_0x1f1395}=this[_0x3cb3c6(0x250)](_0x2e02ac[_0x3cb3c6(0x2c5)]),_0x4695b5=this[_0x3cb3c6(0x1a1)](_0x2e02ac[_0x3cb3c6(0x2c5)],_0x2e02ac[_0x3cb3c6(0x2b2)]),_0x1fe6fa=void 0x0!==_0x2e02ac[_0x3cb3c6(0x2b2)]?[_0x5888e2[_0x3cb3c6(0x2a5)][_0x2e02ac[_0x3cb3c6(0x2b2)]]]:_0x5888e2[_0x3cb3c6(0x2a5)][_0x3cb3c6(0x174)](_0x5c678e=>_0x3cb3c6(0x2ca)==_0x5c678e[_0x3cb3c6(0x251)]),_0x58ac68=_0x1fe6fa[_0x3cb3c6(0x196)](_0x58efa6=>_0x5888e2[_0x3cb3c6(0x2a5)][_0x3cb3c6(0x231)](_0x58efa6));if(!_0x4695b5||_0x3cb3c6(0x266)==_0x4695b5[_0x3cb3c6(0x26d)][_0x3cb3c6(0x1e8)][_0x3cb3c6(0x1c8)])return void _0x58ac68[_0x3cb3c6(0x267)](_0x125de6=>_0x5888e2[_0x3cb3c6(0x22e)](_0x125de6,_0x3cb3c6(0x261)));_0x58ac68[_0x3cb3c6(0x267)](_0x1dd959=>_0x5888e2[_0x3cb3c6(0x22e)](_0x1dd959,_0x3cb3c6(0x2a0)));const _0x145ea3=_0x3fe6({'editor':_0x349d4e,'reply':_0x5888e2,'interaction':_0x1f1395,'groups':_0x1fe6fa,'transform':!0x0,'documentCompare':_0x1a9b89,'documentCompareOptions':{'anchor':_0x3cb3c6(0x1b3),'markDeletions':!0x1}});let _0x35a949;_0x4695b5&&this[_0x3cb3c6(0x27c)](_0x4695b5[_0x3cb3c6(0x26d)]),_0x349d4e[_0x3cb3c6(0x219)][_0x3cb3c6(0x24d)](_0x4255db=>{const _0x2dd27a=_0x3cb3c6;_0x35a949=_0x4255db[_0x2dd27a(0x2d1)];for(const _0x4e751b of _0x145ea3)_0x4e751b[_0x2dd27a(0x262)]=_0x349d4e[_0x2dd27a(0x219)][_0x2dd27a(0x1d2)][_0x2dd27a(0x1ca)],_0x316879(_0x349d4e,_0x4e751b),_0x4255db[_0x2dd27a(0x2d1)][_0x2dd27a(0x1fa)](_0x4e751b),_0x349d4e[_0x2dd27a(0x219)][_0x2dd27a(0x1f6)](_0x4e751b);}),this[_0x3cb3c6(0x1c7)][_0x3cb3c6(0x254)](_0x35a949,{'interactionId':_0x1f1395['id'],'replyId':_0x5888e2['id'],'indexes':_0x58ac68[_0x3cb3c6(0x2c9)]()}),this[_0x3cb3c6(0x199)](_0x5888e2);}[_0x722d79(0x28f)](_0x3f88e6,_0x258de5){const _0x282c6e=_0x722d79,_0x384b72=_0x4dfe45(this[_0x282c6e(0x1c0)]),_0x4dc653=this[_0x282c6e(0x1a1)](_0x3f88e6,_0x258de5),_0x1776cf=this[_0x282c6e(0x1c0)][_0x282c6e(0x268)][_0x282c6e(0x283)](_0x1641f1);if(!_0x4dc653)return void _0x1776cf[_0x282c6e(0x220)]();const {range:_0x301433,currentIndex:_0x217593}=_0x4dc653;if(_0x282c6e(0x266)==_0x301433[_0x282c6e(0x1e8)][_0x282c6e(0x1c8)]){const {reply:_0xcf96f0}=this[_0x282c6e(0x250)](_0x3f88e6);return _0xcf96f0[_0x282c6e(0x22e)](_0x217593,_0x282c6e(0x261)),void _0x1776cf[_0x282c6e(0x220)]();}if(this[_0x282c6e(0x1ee)]?.[_0x282c6e(0x2c5)]==_0x3f88e6&&this[_0x282c6e(0x1ee)]?.[_0x282c6e(0x2b2)]==_0x217593)return;this[_0x282c6e(0x1c9)](_0x1776cf),this[_0x282c6e(0x1ee)]={'replyId':_0x3f88e6,'partIndex':_0x217593};let _0x53d856=_0x384b72[_0x282c6e(0x2d9)][_0x282c6e(0x283)](_0x282c6e(0x17a))||[..._0xaf499c];_0x384b72[_0x282c6e(0x268)][_0x282c6e(0x17d)](_0x282c6e(0x298))||(_0x53d856=_0x53d856[_0x282c6e(0x174)](_0x23a86b=>_0x282c6e(0x256)!=_0x23a86b));const _0x45bddf=new _0x72ff3(_0x384b72[_0x282c6e(0x248)],{'showDiff':this[_0x282c6e(0x1f7)],'areActionsDisabled':!0x1,'miniToolbarConfig':{'showChanges':_0x282c6e(0x21d)},'hideHeader':!0x0,'availableActions':_0x53d856});this[_0x282c6e(0x1c9)](_0x45bddf);const {reply:_0x175fa9}=this[_0x282c6e(0x250)](_0x3f88e6),_0x5379b3=_0x175fa9[_0x282c6e(0x27a)]({'showDiff':this[_0x282c6e(0x1f7)]})[_0x282c6e(0x174)](_0x456985=>_0x456985[_0x282c6e(0x2b6)]),_0x39d62f=_0x5379b3[_0x282c6e(0x28b)](_0x55e801=>_0x55e801[_0x282c6e(0x212)]==_0x217593);if(-0x1==_0x39d62f)return;const _0x5d358b=_0x5379b3[_0x39d62f],_0x2c5447=_0x5379b3['at']((_0x39d62f-0x1)%_0x5379b3[_0x282c6e(0x252)])?.[_0x282c6e(0x212)],_0x5231ac=_0x5379b3['at']((_0x39d62f+0x1)%_0x5379b3[_0x282c6e(0x252)])?.[_0x282c6e(0x212)];_0x45bddf[_0x282c6e(0x1d3)]({'parts':[_0x5d358b],'renderingStrategy':_0x282c6e(0x25f)});const _0x27df79=_0x217593!==_0x2c5447;this[_0x282c6e(0x27c)](_0x301433,!0x0),_0x1776cf[_0x282c6e(0x27f)]({'index':_0x217593,'title':_0xc3a8c(this[_0x282c6e(0x1c0)][_0x282c6e(0x248)],_0x282c6e(0x171),(_0x39d62f+0x1)[_0x282c6e(0x203)]()),'icon':_0x5c5b7c,'mainView':_0x45bddf,'showRotator':_0x27df79,'showApplyButton':!0x0,'showSuggestButton':_0x384b72[_0x282c6e(0x268)][_0x282c6e(0x17d)](_0x282c6e(0x298)),'ranges':[_0x301433]}),this[_0x282c6e(0x2d8)][_0x282c6e(0x1af)](_0x3f88e6,_0x217593),this[_0x282c6e(0x21a)](_0x45bddf,_0x282c6e(0x21f),(_0x2c5f82,{showDiff:_0x4237fc})=>{const _0x1db6aa=_0x282c6e;this[_0x1db6aa(0x1f7)]=_0x4237fc;const {reply:_0x5077a4}=this[_0x1db6aa(0x250)](_0x3f88e6),_0x470de3=_0x5077a4[_0x1db6aa(0x27a)]({'showDiff':_0x4237fc,'groupIndex':_0x217593});_0x45bddf[_0x1db6aa(0x1d3)]({'parts':_0x470de3,'renderingStrategy':_0x1db6aa(0x25f)});}),this[_0x282c6e(0x21a)](_0x1776cf,_0x282c6e(0x1a6),()=>{const _0xbf9042=_0x282c6e;this[_0xbf9042(0x2a1)]({'replyId':_0x3f88e6,'partIndex':_0x217593}),_0x27df79?this[_0xbf9042(0x28f)](_0x3f88e6,_0x5231ac):_0x1776cf[_0xbf9042(0x220)]();}),this[_0x282c6e(0x21a)](_0x1776cf,_0x282c6e(0x256),()=>{const _0x4e1213=_0x282c6e;this[_0x4e1213(0x1d0)]({'replyId':_0x3f88e6,'partIndex':_0x217593}),_0x27df79?this[_0x4e1213(0x28f)](_0x3f88e6,_0x5231ac):_0x1776cf[_0x4e1213(0x220)]();}),_0x27df79&&(this[_0x282c6e(0x21a)](_0x1776cf,_0x282c6e(0x1aa),()=>{const _0x3a78fe=_0x282c6e;this[_0x3a78fe(0x28f)](_0x3f88e6,_0x5231ac);}),this[_0x282c6e(0x21a)](_0x1776cf,_0x282c6e(0x2c7),()=>{const _0x2ac325=_0x282c6e;this[_0x2ac325(0x28f)](_0x3f88e6,_0x2c5447);})),this[_0x282c6e(0x21a)](_0x1776cf,_0x282c6e(0x1fd),()=>{const _0x1a8056=_0x282c6e;this[_0x1a8056(0x1c9)](_0x1776cf),this[_0x1a8056(0x1c9)](_0x45bddf),this[_0x1a8056(0x1ee)]=null;});}[_0x722d79(0x1a1)](_0x821076,_0x1cd73e){const _0x48e56f=_0x722d79,_0x4a9e87=_0x4dfe45(this[_0x48e56f(0x1c0)]),{reply:_0x2b5c54,interaction:_0x5b58b3}=this[_0x48e56f(0x250)](_0x821076),_0x3a5e49=_0x2b5c54[_0x48e56f(0x2a5)][_0x48e56f(0x174)](_0x3cf133=>_0x48e56f(0x2ca)==_0x3cf133[_0x48e56f(0x251)]),_0xad91b0=_0x3a5e49[_0x48e56f(0x196)](_0x3b6346=>_0x2b5c54[_0x48e56f(0x2a5)][_0x48e56f(0x231)](_0x3b6346));void 0x0===_0x1cd73e&&(_0x1cd73e=_0xad91b0[0x0]);const _0x3bd09e=_0xad91b0[_0x48e56f(0x231)](_0x1cd73e);if(-0x1==_0x3bd09e)return null;const _0x4ddd15=_0x3a5e49[_0x3bd09e],_0x44ce4d=new _0x301a4d([]),_0xc128dd=new _0x301a4d([]);for(const _0x570550 of _0x4ddd15[_0x48e56f(0x295)])if(_0x48e56f(0x2a9)!=_0x570550[_0x48e56f(0x184)]&&_0xc128dd[_0x48e56f(0x2a4)][_0x48e56f(0x221)](_0x570550[_0x48e56f(0x1d5)][_0x48e56f(0x2ad)](!0x0)),_0x48e56f(0x1da)!=_0x570550[_0x48e56f(0x184)]){const _0x4781c7=_0x5c46b8(_0x2bd938=>_0x174d3e(_0x2bd938,_0x48e56f(0x20b))==_0x570550['id'],_0x2b5c54[_0x48e56f(0x188)],!0x0);_0x44ce4d[_0x48e56f(0x2a4)][_0x48e56f(0x221)](_0x4781c7[_0x48e56f(0x2ad)](!0x0));}if(0x0==_0x44ce4d[_0x48e56f(0x2a4)][_0x48e56f(0x252)]){if(_0x4ddd15[_0x48e56f(0x295)][0x0][_0x48e56f(0x186)]){const _0x15a1ab=_0x244b7e(_0x48e56f(0x20b),_0x4ddd15[_0x48e56f(0x295)][0x0][_0x48e56f(0x186)],_0x2b5c54[_0x48e56f(0x188)]);_0x44ce4d[_0x48e56f(0x2a4)][_0x48e56f(0x217)](_0x15a1ab[_0x48e56f(0x2ad)](!0x0)),_0xc128dd[_0x48e56f(0x2a4)][_0x48e56f(0x217)](_0x15a1ab[_0x48e56f(0x2ad)](!0x0)),_0x15a1ab[_0x48e56f(0x1ce)]&&(_0x44ce4d[_0x48e56f(0x2a4)][_0x48e56f(0x221)](_0x15a1ab[_0x48e56f(0x1ce)][_0x48e56f(0x2ad)](!0x0)),_0xc128dd[_0x48e56f(0x2a4)][_0x48e56f(0x221)](_0x15a1ab[_0x48e56f(0x1ce)][_0x48e56f(0x2ad)](!0x0)));}else{const _0x5ec94f=_0x2b5c54[_0x48e56f(0x188)][_0x48e56f(0x2a4)][0x0];if(!_0x5ec94f)return null;_0x44ce4d[_0x48e56f(0x2a4)][_0x48e56f(0x221)](_0x5ec94f[_0x48e56f(0x2ad)](!0x0)),_0xc128dd[_0x48e56f(0x2a4)][_0x48e56f(0x221)](_0x5ec94f[_0x48e56f(0x2ad)](!0x0));}}const _0x12867d=_0x5b58b3[_0x48e56f(0x265)](),_0xc8b9f4=_0x4a9e87[_0x48e56f(0x2a6)][_0x48e56f(0x2b1)](_0x12867d[_0x48e56f(0x28a)]),_0x273056=_0x9af624(_0x44ce4d),_0x413ccf=_0x4a9e87[_0x48e56f(0x2a6)][_0x48e56f(0x2b1)](_0x273056),_0x435523=_0x4a9e87[_0x48e56f(0x2a6)][_0x48e56f(0x2b1)](_0x273056),_0x45746b=_0x4a9e87[_0x48e56f(0x219)][_0x48e56f(0x1be)](_0x413ccf,0x0),_0x2c3460=_0x9af624(_0xc128dd),_0xf683da={'anchor':_0x45746b,'markDeletions':!0x1},_0x498a0e=_0x4a9e87[_0x48e56f(0x268)][_0x48e56f(0x283)](_0x1e0fe3)[_0x48e56f(0x1a8)](_0x273056,_0x2c3460,_0xf683da)[_0x48e56f(0x187)]();if(!_0x498a0e[_0x48e56f(0x252)])return null;_0x4a9e87[_0x48e56f(0x219)][_0x48e56f(0x24d)](_0x4bb215=>{const _0x4121e8=_0x48e56f;for(const _0x5045a9 of _0x498a0e)if(_0x4121e8(0x194)==_0x5045a9[_0x4121e8(0x184)]){const _0x3c84a7=_0x5045a9[_0x4121e8(0x2aa)],_0x5b1183=_0x5045a9[_0x4121e8(0x17f)],_0x3a1810=new _0x347c6f(_0x3c84a7,_0x5b1183);_0x4bb215[_0x4121e8(0x2d1)][_0x4121e8(0x1fa)](_0x3a1810),_0x4a9e87[_0x4121e8(0x219)][_0x4121e8(0x1f6)](_0x3a1810);}else _0x4121e8(0x22b)!==_0x5045a9[_0x4121e8(0x184)]&&(_0x5045a9[_0x4121e8(0x262)]=null,_0x5045a9[_0x4121e8(0x1fc)]=!0x1,_0x4bb215[_0x4121e8(0x2d1)][_0x4121e8(0x1fa)](_0x5045a9),_0x4a9e87[_0x4121e8(0x219)][_0x4121e8(0x1f6)](_0x5045a9));});const _0x5143cc=_0x136d73(_0x4a9e87,_0x498a0e,_0x413ccf);_0x118718(_0x4a9e87[_0x48e56f(0x219)],_0x5143cc);const _0x5bfd41=_0x5143cc[_0x48e56f(0x297)]()[_0x48e56f(0x1c6)][_0x48e56f(0x2bc)][_0x48e56f(0x2c9)](),_0x11f23a=_0x5143cc[_0x48e56f(0x297)]()[_0x48e56f(0x208)][_0x48e56f(0x2bc)][_0x48e56f(0x2c9)](),_0x42563c=[];let _0x581d4d=_0x413ccf,_0x5ca588=_0x435523;for(let _0x9196c4=0x0;_0x9196c4<_0x11f23a[_0x48e56f(0x252)];_0x9196c4++){const _0x53abcb=_0x581d4d[_0x48e56f(0x281)]-_0x11f23a[_0x9196c4];_0x42563c[_0x9196c4]=_0x5ca588[_0x48e56f(0x281)]-_0x53abcb,_0x581d4d=_0x581d4d[_0x48e56f(0x1f8)](_0x11f23a[_0x9196c4]),_0x5ca588=_0x5ca588[_0x48e56f(0x1f8)](_0x42563c[_0x9196c4]);}const _0x4bc16b=_0x4a9e87[_0x48e56f(0x219)][_0x48e56f(0x1a3)](_0x4a9e87[_0x48e56f(0x219)][_0x48e56f(0x259)](_0x435523,_0x5bfd41),_0x4a9e87[_0x48e56f(0x219)][_0x48e56f(0x259)](_0x435523,_0x42563c)),_0x589a70=_0x435523[_0x48e56f(0x27e)](0x0)[_0x48e56f(0x1ea)](_0x47a7f5),_0x4a2b4d=Array[_0x48e56f(0x2d2)](_0xc8b9f4[_0x48e56f(0x197)]())[_0x48e56f(0x2c2)](_0x46d76f=>_0x46d76f[_0x48e56f(0x1ea)](_0x47a7f5)==_0x589a70)[_0x48e56f(0x2cb)](),_0x5abb3f=_0x4bc16b[_0x48e56f(0x1c6)][_0x48e56f(0x2bc)][_0x48e56f(0x2c9)](),_0x182e3e=_0x4bc16b[_0x48e56f(0x208)][_0x48e56f(0x2bc)][_0x48e56f(0x2c9)]();_0x5abb3f[0x0]=_0x4a2b4d[0x0]+_0x5abb3f[0x0],_0x182e3e[0x0]=_0x4a2b4d[0x0]+_0x182e3e[0x0];let _0x46b3c4=_0x4a9e87[_0x48e56f(0x219)][_0x48e56f(0x1a3)](_0x4a9e87[_0x48e56f(0x219)][_0x48e56f(0x259)](_0x4a9e87[_0x48e56f(0x219)][_0x48e56f(0x1d2)][_0x48e56f(0x2da)](),_0x5abb3f),_0x4a9e87[_0x48e56f(0x219)][_0x48e56f(0x259)](_0x4a9e87[_0x48e56f(0x219)][_0x48e56f(0x1d2)][_0x48e56f(0x2da)](),_0x182e3e));const _0x52fe54=_0x4a9e87[_0x48e56f(0x219)][_0x48e56f(0x1d2)][_0x48e56f(0x240)][_0x48e56f(0x187)](_0x12867d[_0x48e56f(0x1ca)]);for(const _0x31df42 of _0x52fe54)_0x46b3c4=_0x419998[_0x48e56f(0x237)](_0x46b3c4[_0x48e56f(0x1ed)](_0x31df42));return{'range':_0x46b3c4,'currentIndex':_0x1cd73e};}[_0x722d79(0x1ef)](_0x2ad5c2){const _0x696c87=_0x722d79;if(!_0x2ad5c2[_0x696c87(0x268)][_0x696c87(0x17d)](_0x696c87(0x206)))return;const _0x3a3d81=_0x2ad5c2[_0x696c87(0x226)][_0x696c87(0x283)](_0x696c87(0x270)),_0x1fdfce=_0x2ad5c2[_0x696c87(0x226)][_0x696c87(0x283)](_0x696c87(0x291));this[_0x696c87(0x21a)](_0x3a3d81,_0x696c87(0x192),(_0x16ab0d,_0x1202d6,_0x2dfe7e)=>{const _0x3e5fb4=_0x696c87,_0x489e4a=this[_0x3e5fb4(0x1c7)][_0x3e5fb4(0x283)](_0x1202d6);if(!_0x489e4a)return;const _0x18dcab=this[_0x3e5fb4(0x2cf)][_0x3e5fb4(0x29f)](_0x489e4a[_0x3e5fb4(0x274)])[_0x3e5fb4(0x1cc)](_0x489e4a[_0x3e5fb4(0x2c5)]);_0x489e4a[_0x3e5fb4(0x229)][_0x3e5fb4(0x267)](_0x35536b=>_0x18dcab[_0x3e5fb4(0x22e)](_0x35536b,_0x3e5fb4(0x2ca))),this[_0x3e5fb4(0x1c7)][_0x3e5fb4(0x234)](_0x1202d6),this[_0x3e5fb4(0x1c7)][_0x3e5fb4(0x254)](_0x2dfe7e,_0x489e4a);}),this[_0x696c87(0x21a)](_0x1fdfce,_0x696c87(0x192),(_0x17ec5e,_0x262c7b,_0x3c468d)=>{const _0x269c32=_0x696c87,_0x124478=this[_0x269c32(0x1c7)][_0x269c32(0x283)](_0x262c7b);if(!_0x124478)return;const _0x43a86b=this[_0x269c32(0x2cf)][_0x269c32(0x29f)](_0x124478[_0x269c32(0x274)])[_0x269c32(0x1cc)](_0x124478[_0x269c32(0x2c5)]);_0x124478[_0x269c32(0x229)][_0x269c32(0x267)](_0x23e2b7=>_0x43a86b[_0x269c32(0x22e)](_0x23e2b7,_0x269c32(0x2a0))),this[_0x269c32(0x1c7)][_0x269c32(0x234)](_0x262c7b),this[_0x269c32(0x1c7)][_0x269c32(0x254)](_0x3c468d,_0x124478);});}async[_0x722d79(0x271)](_0x2ceff9){const _0x52fb31=_0x722d79;this[_0x52fb31(0x1c0)][_0x52fb31(0x268)][_0x52fb31(0x283)](_0x1641f1)[_0x52fb31(0x220)](),this[_0x52fb31(0x2d8)][_0x52fb31(0x2d6)](_0x52fb31(0x25f)),this[_0x52fb31(0x2d8)][_0x52fb31(0x282)](!0x0),await this[_0x52fb31(0x2d4)]();try{await this[_0x52fb31(0x1e1)][_0x52fb31(0x24f)](_0x2ceff9)[_0x52fb31(0x16e)](),await this[_0x52fb31(0x23f)](_0x2ceff9),this[_0x52fb31(0x24b)]('\x20');const {sessionId:_0x57161d}=this[_0x52fb31(0x2db)][_0x52fb31(0x18e)]();await this[_0x52fb31(0x2cf)][_0x52fb31(0x29b)](_0x2ceff9,_0x57161d),this[_0x52fb31(0x2cf)][_0x52fb31(0x228)]()&&this[_0x52fb31(0x2cf)][_0x52fb31(0x2a8)](_0xc3a8c(this[_0x52fb31(0x1c0)][_0x52fb31(0x248)],_0x52fb31(0x2bf)));}catch(_0x8f46ee){this[_0x52fb31(0x2d8)][_0x52fb31(0x296)]({'errorMessage':_0xc3a8c(this[_0x52fb31(0x1c0)][_0x52fb31(0x248)],_0x52fb31(0x1ff)),'id':_0x2ceff9}),this[_0x52fb31(0x198)](new _0x56bfe4(_0x52fb31(0x1e9),this,{'error':_0x8f46ee}));}finally{this[_0x52fb31(0x1c0)][_0x52fb31(0x268)][_0x52fb31(0x283)](_0x15b59e)[_0x52fb31(0x205)][_0x52fb31(0x222)](_0x52fb31(0x1f5)),this[_0x52fb31(0x2d8)][_0x52fb31(0x223)](),this[_0x52fb31(0x2d8)][_0x52fb31(0x2d6)](_0x52fb31(0x286)),this[_0x52fb31(0x2d8)][_0x52fb31(0x282)](!0x1);}}[_0x722d79(0x280)](_0x532ab0){const _0x3161ec=_0x722d79;this[_0x3161ec(0x2cf)]['id']===_0x532ab0&&this[_0x3161ec(0x23f)]();}async[_0x722d79(0x1c4)](){const _0x4994d4=_0x722d79,_0x14b5f5=this[_0x4994d4(0x2db)][_0x4994d4(0x207)]();this[_0x4994d4(0x2cf)]?.[_0x4994d4(0x260)](_0x14b5f5),this[_0x4994d4(0x2cf)]?.[_0x4994d4(0x2a8)](_0xc3a8c(this[_0x4994d4(0x1c0)][_0x4994d4(0x248)],_0x4994d4(0x2bf)));}[_0x722d79(0x176)](){const _0x53bbac=_0x722d79;this[_0x53bbac(0x2cf)]?.[_0x53bbac(0x292)]();}[_0x722d79(0x17b)](){const _0x4ee3c5=_0x722d79;this[_0x4ee3c5(0x2d8)][_0x4ee3c5(0x17b)]();}async[_0x722d79(0x2bb)](){const _0x56ec38=_0x722d79;await this[_0x56ec38(0x23f)]();}async[_0x722d79(0x22a)]({message:_0x17fbb5,quickActionData:_0x3d2618}){const _0x4203f3=_0x722d79;await this[_0x4203f3(0x243)]({'userMessage':_0x17fbb5,'quickActionData':_0x3d2618});}[_0x722d79(0x1a5)](){const _0x159ef0=_0x722d79,_0x45ba49=this[_0x159ef0(0x1c0)][_0x159ef0(0x2d9)][_0x159ef0(0x283)](_0x159ef0(0x178));if(!_0x45ba49)throw new _0x56bfe4(_0x159ef0(0x22c),this);return _0x45ba49;}async[_0x722d79(0x23f)](_0x2becc3){const _0xae89b7=_0x722d79;try{this[_0xae89b7(0x2d8)][_0xae89b7(0x287)](),await this[_0xae89b7(0x1e2)](_0x2becc3);}catch(_0x529e8a){this[_0xae89b7(0x2d8)][_0xae89b7(0x296)]({'errorMessage':_0xc3a8c(this[_0xae89b7(0x1c0)][_0xae89b7(0x248)],_0xae89b7(0x236)),'id':_0x2becc3||_0x567464()}),console[_0xae89b7(0x27b)](_0x529e8a),this[_0xae89b7(0x2cf)]=void 0x0,this[_0xae89b7(0x2d8)][_0xae89b7(0x21b)]();}}async[_0x722d79(0x1e2)](_0x3c06d5){const _0x4d62d8=_0x722d79,_0x5cdb87=this[_0x4d62d8(0x1c0)][_0x4d62d8(0x268)][_0x4d62d8(0x283)](_0x1641f1);let _0x358ce5;_0x5cdb87[_0x4d62d8(0x1f2)]&&_0x5cdb87[_0x4d62d8(0x220)](),_0x3c06d5||!this[_0x4d62d8(0x2cf)]?_0x358ce5=this[_0x4d62d8(0x1c0)][_0x4d62d8(0x2d9)][_0x4d62d8(0x283)](_0x4d62d8(0x1a0)):this[_0x4d62d8(0x2d8)][_0x4d62d8(0x225)]&&(_0x358ce5=this[_0x4d62d8(0x2cf)][_0x4d62d8(0x2c6)]['id']),await this[_0x4d62d8(0x2d4)]();const _0x288bae=this[_0x4d62d8(0x1a5)](),_0xd58aad=_0x3c06d5||_0x567464();this[_0x4d62d8(0x2cf)]=new _0x5188f9({'connector':this[_0x4d62d8(0x1e1)],'chatModels':this[_0x4d62d8(0x2d7)],'selectedModelId':_0x358ce5,'conversationId':_0xd58aad,'group':_0x288bae,'getEditor':()=>_0x4dfe45(this[_0x4d62d8(0x1c0)])}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x26a),(_0x285196,_0x3f819e)=>{const _0x197386=_0x4d62d8;this[_0x197386(0x2d8)][_0x197386(0x269)](_0x3f819e),this[_0x197386(0x2d8)][_0x197386(0x1e6)](),this[_0x197386(0x2d8)][_0x197386(0x18d)](),this[_0x197386(0x2d8)][_0x197386(0x185)](),_0x3c06d5||(this[_0x197386(0x2d8)][_0x197386(0x278)](),this[_0x197386(0x2cf)]?.[_0x197386(0x2a8)](_0xc3a8c(this[_0x197386(0x1c0)][_0x197386(0x248)],_0x197386(0x2bf))));}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x290),(_0x2d303e,_0x1cc6aa)=>{const _0x1d0a67=_0x4d62d8;this[_0x1d0a67(0x2d8)][_0x1d0a67(0x2d5)](_0x1cc6aa[_0x1d0a67(0x1ac)]);}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x239),(_0xd36c16,_0x5e69bc)=>{const _0x267bb3=_0x4d62d8;this[_0x267bb3(0x2d8)][_0x267bb3(0x1cd)](_0x5e69bc);}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x279),()=>{const _0x4be888=_0x4d62d8;this[_0x4be888(0x2d8)][_0x4be888(0x1ad)]({'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x1d4),()=>{const _0x1ef360=_0x4d62d8;this[_0x1ef360(0x2d8)][_0x1ef360(0x1ad)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x26b),(_0x5bdf12,_0x391539)=>{const _0x3a4bde=_0x4d62d8;this[_0x3a4bde(0x2d8)][_0x3a4bde(0x1d9)](_0x391539,{'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x1c2),(_0x1d5d69,_0x5e2852)=>{const _0x3917b8=_0x4d62d8;this[_0x3917b8(0x2d8)][_0x3917b8(0x1d9)](_0x5e2852,{'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x191),()=>{const _0x3a0744=_0x4d62d8;this[_0x3a0744(0x2d8)][_0x3a0744(0x17e)]();}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x20e),async()=>{const _0x4c1c27=_0x4d62d8;await this[_0x4c1c27(0x2d8)][_0x4c1c27(0x28d)]();}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x1fb),(_0x233241,_0x30f8c2)=>{const _0x42be1f=_0x4d62d8;this[_0x42be1f(0x2d8)][_0x42be1f(0x18a)](_0x30f8c2['id']);}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x1bd),(_0x39e732,_0x28e810,_0x57efc6)=>{const _0x5b1781=_0x4d62d8;this[_0x5b1781(0x24b)](_0x28e810,_0x57efc6);}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x284),(_0x593f27,_0x97793e)=>{const _0xe15472=_0x4d62d8;_0xe15472(0x24a)===_0x97793e[_0xe15472(0x184)]?this[_0xe15472(0x2d8)][_0xe15472(0x1dd)](_0x97793e):this[_0xe15472(0x2d8)][_0xe15472(0x1b1)](_0x97793e);}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x1e5),async(_0x54a1c4,_0x41488a)=>{const _0x17bed8=_0x4d62d8;await this[_0x17bed8(0x235)]({'reply':_0x41488a});}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x2d0),(_0x4c36b2,{reply:_0x5289f5,index:_0x388256,state:_0x545549})=>{const _0x53faec=_0x4d62d8;this[_0x53faec(0x2d8)][_0x53faec(0x2b8)]({'id':_0x5289f5['id'],'index':_0x388256,'state':_0x545549});}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x1d7),(_0x231bf8,_0x2ef5a0)=>{const _0x320339=_0x4d62d8;if(this[_0x320339(0x2d8)][_0x320339(0x179)](_0x2ef5a0[_0x320339(0x1d6)],_0x2ef5a0[_0x320339(0x1f0)]),_0x320339(0x2c3)===_0x2ef5a0[_0x320339(0x1d6)][_0x320339(0x184)]){const _0x3599b=[..._0x4dfe45(this[_0x320339(0x1c0)])[_0x320339(0x219)][_0x320339(0x1d2)][_0x320339(0x2c3)][_0x320339(0x23d)]()];this[_0x320339(0x2db)][_0x320339(0x258)](_0x3599b,_0x320339(0x299)+this[_0x320339(0x2cf)]?.['id']);}}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x23e),(_0x874a2e,_0x126e1b)=>{const _0x4ab692=_0x4d62d8;this[_0x4ab692(0x2d8)][_0x4ab692(0x245)](_0x126e1b[_0x4ab692(0x1b2)]),_0x4ab692(0x182)==_0x126e1b[_0x4ab692(0x1b2)]&&this[_0x4ab692(0x176)](),_0x4ab692(0x2c3)===_0x126e1b[_0x4ab692(0x184)]&&this[_0x4ab692(0x2db)][_0x4ab692(0x257)](_0x4ab692(0x299)+this[_0x4ab692(0x2cf)]?.['id']);}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x2c4),(_0x5a76ec,_0x38d602)=>{const _0x142ad3=_0x4d62d8;this[_0x142ad3(0x2d8)][_0x142ad3(0x247)](_0x38d602[_0x142ad3(0x1d6)][_0x142ad3(0x1b2)],_0x38d602[_0x142ad3(0x1f0)]);}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x224),(_0xd267ae,_0x2fcb30)=>{const _0x465554=_0x4d62d8;this[_0x465554(0x2d8)][_0x465554(0x2b7)](_0x2fcb30[_0x465554(0x1d1)]);}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x22d),(_0xf7c780,_0x2809c3)=>{const _0x3dee0c=_0x4d62d8;this[_0x3dee0c(0x2d8)][_0x3dee0c(0x2b0)](_0x2809c3[_0x3dee0c(0x241)]);}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x1b0),(_0x18f45e,_0x5e63aa)=>{const _0x5e3b0b=_0x4d62d8;this[_0x5e3b0b(0x2d8)][_0x5e3b0b(0x175)](_0x5e63aa[_0x5e3b0b(0x1c3)],_0x5e63aa[_0x5e3b0b(0x24c)],_0x5e63aa[_0x5e3b0b(0x2cd)],_0x5e63aa[_0x5e3b0b(0x172)]);}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x213),(_0x9a7b4f,_0x56780a)=>{const _0x1d8af9=_0x4d62d8;this[_0x1d8af9(0x2d8)][_0x1d8af9(0x244)](_0x56780a[_0x1d8af9(0x1c3)],_0x56780a[_0x1d8af9(0x2c1)],_0x56780a[_0x1d8af9(0x2b4)]);}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x26e),(_0x2a574d,_0x1f8f6c)=>{const _0x443196=_0x4d62d8;this[_0x443196(0x2d8)][_0x443196(0x1bc)](_0x1f8f6c);}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x275),(_0x2ebfb1,_0x2a6562)=>{const _0x535438=_0x4d62d8;this[_0x535438(0x2d8)][_0x535438(0x216)](_0x2a6562[_0x535438(0x2c6)],_0x2a6562[_0x535438(0x289)]);}),this[_0x4d62d8(0x2cf)]['on'](_0x4d62d8(0x27b),(_0x4df066,{error:_0x4ab6f6,interactionId:_0x44e184,fileName:_0x2ca375,url:_0x168999,sourceId:_0x23afe0,sourceLabel:_0x21ed11})=>{const _0xa8bc5e=_0x4d62d8,_0x476423=_0x44e184?_0x44e184+':'+_0x567464():_0x567464();_0x4ab6f6[_0xa8bc5e(0x173)][_0xa8bc5e(0x218)](_0xa8bc5e(0x1cf))?this[_0xa8bc5e(0x2d8)][_0xa8bc5e(0x28e)]({'staticMessage':_0xc3a8c(this[_0xa8bc5e(0x1c0)][_0xa8bc5e(0x248)],_0xa8bc5e(0x230)),'id':_0x476423}):_0x4ab6f6[_0xa8bc5e(0x173)][_0xa8bc5e(0x218)](_0xa8bc5e(0x1f1))||_0x4ab6f6[_0xa8bc5e(0x173)][_0xa8bc5e(0x218)](_0xa8bc5e(0x1fe))?(this[_0xa8bc5e(0x2d8)][_0xa8bc5e(0x296)]({'errorMessage':_0xc3a8c(this[_0xa8bc5e(0x1c0)][_0xa8bc5e(0x248)],_0xa8bc5e(0x236)),'id':_0x476423}),this[_0xa8bc5e(0x198)](_0x4ab6f6)):_0x4ab6f6[_0xa8bc5e(0x173)][_0xa8bc5e(0x218)](_0xa8bc5e(0x273))?this[_0xa8bc5e(0x2d8)][_0xa8bc5e(0x296)]({'errorMessage':_0xc3a8c(this[_0xa8bc5e(0x1c0)][_0xa8bc5e(0x248)],_0xa8bc5e(0x29d),_0x2ca375),'id':_0x476423}):_0x4ab6f6[_0xa8bc5e(0x173)][_0xa8bc5e(0x218)](_0xa8bc5e(0x16f))?this[_0xa8bc5e(0x2d8)][_0xa8bc5e(0x296)]({'errorMessage':_0xc3a8c(this[_0xa8bc5e(0x1c0)][_0xa8bc5e(0x248)],_0xa8bc5e(0x1b4),_0x168999),'id':_0x476423}):_0x4ab6f6[_0xa8bc5e(0x173)][_0xa8bc5e(0x218)](_0xa8bc5e(0x1de))?this[_0xa8bc5e(0x2d8)][_0xa8bc5e(0x296)]({'errorMessage':_0xc3a8c(this[_0xa8bc5e(0x1c0)][_0xa8bc5e(0x248)],_0xa8bc5e(0x1e7)),'id':_0x476423}):_0x4ab6f6[_0xa8bc5e(0x173)][_0xa8bc5e(0x218)](_0xa8bc5e(0x2c8))?this[_0xa8bc5e(0x2d8)][_0xa8bc5e(0x296)]({'errorMessage':_0xc3a8c(this[_0xa8bc5e(0x1c0)][_0xa8bc5e(0x248)],_0xa8bc5e(0x2a7)),'id':_0x476423}):_0x4ab6f6[_0xa8bc5e(0x173)][_0xa8bc5e(0x218)](_0xa8bc5e(0x189))?(_0x23afe0&&this[_0xa8bc5e(0x2d8)][_0xa8bc5e(0x1eb)](_0x23afe0),this[_0xa8bc5e(0x2d8)][_0xa8bc5e(0x296)]({'errorMessage':_0xc3a8c(this[_0xa8bc5e(0x1c0)][_0xa8bc5e(0x248)],_0xa8bc5e(0x249),_0x21ed11||_0xa8bc5e(0x24c)),'id':_0x476423}),this[_0xa8bc5e(0x198)](_0x4ab6f6)):_0x4ab6f6[_0xa8bc5e(0x173)][_0xa8bc5e(0x218)](_0xa8bc5e(0x1f4))?(this[_0xa8bc5e(0x2d8)][_0xa8bc5e(0x296)]({'errorMessage':_0xc3a8c(this[_0xa8bc5e(0x1c0)][_0xa8bc5e(0x248)],_0xa8bc5e(0x1f9)),'id':_0x476423}),this[_0xa8bc5e(0x198)](_0x4ab6f6)):_0x4ab6f6[_0xa8bc5e(0x173)][_0xa8bc5e(0x218)](_0xa8bc5e(0x20a))?(this[_0xa8bc5e(0x2d8)][_0xa8bc5e(0x296)]({'errorMessage':_0xc3a8c(this[_0xa8bc5e(0x1c0)][_0xa8bc5e(0x248)],_0xa8bc5e(0x180)),'id':_0x476423}),this[_0xa8bc5e(0x198)](_0x4ab6f6)):_0x4ab6f6[_0xa8bc5e(0x173)][_0xa8bc5e(0x218)](_0xa8bc5e(0x227))?(this[_0xa8bc5e(0x2d8)][_0xa8bc5e(0x296)]({'errorMessage':_0xc3a8c(this[_0xa8bc5e(0x1c0)][_0xa8bc5e(0x248)],_0xa8bc5e(0x211)),'id':_0x476423}),this[_0xa8bc5e(0x198)](_0x4ab6f6)):_0x4ab6f6[_0xa8bc5e(0x173)][_0xa8bc5e(0x218)](_0xa8bc5e(0x24e))?(this[_0xa8bc5e(0x2d8)][_0xa8bc5e(0x296)]({'errorMessage':_0xc3a8c(this[_0xa8bc5e(0x1c0)][_0xa8bc5e(0x248)],_0xa8bc5e(0x2ab)),'id':_0x476423}),this[_0xa8bc5e(0x198)](_0x4ab6f6)):_0x4ab6f6[_0xa8bc5e(0x173)][_0xa8bc5e(0x218)](_0xa8bc5e(0x1ae))?(this[_0xa8bc5e(0x2d8)][_0xa8bc5e(0x296)]({'errorMessage':_0xc3a8c(this[_0xa8bc5e(0x1c0)][_0xa8bc5e(0x248)],_0xa8bc5e(0x21c)),'id':_0x476423}),this[_0xa8bc5e(0x198)](_0x4ab6f6)):_0x4ab6f6[_0xa8bc5e(0x173)][_0xa8bc5e(0x218)](_0xa8bc5e(0x232))?(this[_0xa8bc5e(0x2d8)][_0xa8bc5e(0x296)]({'errorMessage':_0xc3a8c(this[_0xa8bc5e(0x1c0)][_0xa8bc5e(0x248)],_0xa8bc5e(0x2bd)),'id':_0x476423}),this[_0xa8bc5e(0x198)](_0x4ab6f6)):(this[_0xa8bc5e(0x2d8)][_0xa8bc5e(0x296)]({'errorMessage':_0xc3a8c(this[_0xa8bc5e(0x1c0)][_0xa8bc5e(0x248)],_0xa8bc5e(0x238)),'id':_0x476423}),this[_0xa8bc5e(0x198)](_0x4ab6f6));}),await this[_0x4d62d8(0x2cf)][_0x4d62d8(0x276)](this[_0x4d62d8(0x1c0)][_0x4d62d8(0x2d9)][_0x4d62d8(0x283)](_0x4d62d8(0x27d))),_0x3c06d5||await this[_0x4d62d8(0x2cf)][_0x4d62d8(0x1c6)]();}async[_0x722d79(0x243)]({userMessage:_0x3dce6e,quickActionData:_0x192eca}){const _0x189823=_0x722d79;if(!this[_0x189823(0x2cf)])throw new _0x56bfe4(_0x189823(0x255));this[_0x189823(0x2cf)][_0x189823(0x1ec)]()&&await this[_0x189823(0x2cf)][_0x189823(0x1d8)](this[_0x189823(0x2db)][_0x189823(0x18e)]()),this[_0x189823(0x2cf)]['id']&&this[_0x189823(0x2cf)][_0x189823(0x1b8)]&&await this[_0x189823(0x2cf)][_0x189823(0x193)]({'userMessage':_0x3dce6e,'quickActionData':_0x192eca}),this[_0x189823(0x1cb)]();}[_0x722d79(0x1cb)](){const _0x273841=_0x722d79,_0x37e2d3=_0x4dfe45(this[_0x273841(0x1c0)])[_0x273841(0x219)],_0x51b00b=Array[_0x273841(0x2d2)](_0x37e2d3[_0x273841(0x1df)][_0x273841(0x2ae)](_0x5dc995));_0x37e2d3[_0x273841(0x24d)](_0x5e9259=>{const _0x385e72=_0x273841;_0x51b00b[_0x385e72(0x267)](_0x22f235=>_0x5e9259[_0x385e72(0x19d)](_0x22f235));});}[_0x722d79(0x23c)](){const _0x1c210a=_0x722d79;console[_0x1c210a(0x25c)](_0x1c210a(0x25d));}[_0x722d79(0x25b)](_0x391aa8){const _0x47a1a4=_0x722d79;this[_0x47a1a4(0x2d8)][_0x47a1a4(0x214)](_0x391aa8);}[_0x722d79(0x198)](_0x581436){const _0x16f589=_0x722d79;_0x403c82(_0x581436[_0x16f589(0x173)]);}[_0x722d79(0x183)](_0x6ac715){const _0x7bcc6e=_0x722d79;this[_0x7bcc6e(0x2cf)]?.[_0x7bcc6e(0x277)](_0x6ac715);}[_0x722d79(0x1db)](){const _0x4a3b01=_0x722d79;this[_0x4a3b01(0x2cf)]?.[_0x4a3b01(0x204)]();}[_0x722d79(0x29c)](){const _0xd70395=_0x722d79;this[_0xd70395(0x2cf)]?.[_0xd70395(0x28c)]();}[_0x722d79(0x250)](_0x494b92){const _0x439c1f=_0x722d79,[_0x16df74,_0x3e227f]=_0x494b92[_0x439c1f(0x190)](':'),_0x529875=this[_0x439c1f(0x2cf)][_0x439c1f(0x29f)](_0x16df74),_0x56b986=_0x529875[_0x439c1f(0x1cc)](_0x3e227f);return{'interaction':_0x529875,'reply':_0x56b986};}[_0x722d79(0x27c)](_0x559926,_0x323829=!0x1){const _0x157b72=_0x722d79,_0x24885d=_0x4dfe45(this[_0x157b72(0x1c0)]),_0x347750={'target':_0x24885d[_0x157b72(0x242)][_0x157b72(0x205)][_0x157b72(0x2b3)][_0x157b72(0x20d)](_0x24885d[_0x157b72(0x242)][_0x157b72(0x1c1)][_0x157b72(0x29e)](_0x559926)),'viewportOffset':{'top':0x96,'left':0x0,'bottom':0x32,'right':0x0},'ancestorOffset':0x14,'alignToTop':_0x323829};_0x323829&&(_0x347750[_0x157b72(0x215)]=!0x0),_0x2ac001(_0x347750);}[_0x722d79(0x24b)](_0x1b1057,_0x4546f7=!0x1){const _0x503f90=_0x722d79;this[_0x503f90(0x2d8)][_0x503f90(0x1bd)](_0x1b1057||_0xc3a8c(this[_0x503f90(0x1c0)][_0x503f90(0x248)],_0x503f90(0x272)),_0x4546f7);}async[_0x722d79(0x235)]({reply:_0xed8c28,renderingStrategy:_0x56fe87}){const _0x227434=_0x722d79,{id:_0x3b0f36,isDone:_0x274593,type:_0x1476d9,parsedContent:_0x1fc6ef}=_0xed8c28;if(_0x227434(0x2b9)===_0x1476d9){const _0x575f0b=_0xed8c28[_0x227434(0x27a)]({'showDiff':this[_0x227434(0x2d8)][_0x227434(0x294)]});await this[_0x227434(0x2d8)][_0x227434(0x1a4)]({'id':_0x3b0f36,'parts':_0x575f0b,'renderingStrategy':_0x56fe87,'isDone':_0x274593});}else _0x227434(0x24a)===_0x1476d9&&await this[_0x227434(0x2d8)][_0x227434(0x1bb)]({'id':_0x3b0f36,'parsedContent':_0x1fc6ef,'renderingStrategy':_0x56fe87,'isDone':_0x274593});_0x274593&&_0xed8c28[_0x227434(0x181)][_0x227434(0x252)]>0x0&&this[_0x227434(0x2d8)][_0x227434(0x1f3)](_0x3b0f36,_0xed8c28[_0x227434(0x181)]);}async[_0x722d79(0x2d4)](){const _0xb7df21=_0x722d79,_0x5c52d2=this[_0xb7df21(0x2cf)]?.[_0xb7df21(0x293)];_0x5c52d2&&(_0x5c52d2[_0xb7df21(0x1b7)](),this[_0xb7df21(0x2d8)][_0xb7df21(0x288)](_0x5c52d2));}async[_0x722d79(0x23a)](){const _0x4f0751=_0x722d79,_0x5c737c=this[_0x4f0751(0x2cf)]?.[_0x4f0751(0x293)];if(_0x5c737c){for await(const _0x54df9e of _0x5c737c[_0x4f0751(0x2be)])await this[_0x4f0751(0x235)]({'reply':_0x54df9e,'renderingStrategy':_0x4f0751(0x25f)});}}[_0x722d79(0x199)](_0x2c7197){const _0x4626d0=_0x722d79,_0x403d95={'positiveCount':_0x2c7197[_0x4626d0(0x2a5)][_0x4626d0(0x174)](_0x5147ee=>_0x4626d0(0x2a0)===_0x5147ee[_0x4626d0(0x251)])[_0x4626d0(0x252)],'totalCount':_0x2c7197[_0x4626d0(0x2a5)][_0x4626d0(0x252)],'modificationId':_0x2c7197['id']},_0x5810e2=this[_0x4626d0(0x2cf)][_0x4626d0(0x29f)](_0x2c7197[_0x4626d0(0x274)])[_0x4626d0(0x1e0)];this[_0x4626d0(0x1e1)][_0x4626d0(0x1b6)](this[_0x4626d0(0x2cf)]['id'],_0x5810e2,_0x403d95);}}
|
|
23
|
+
const _0x32f9e9=_0x1a1c;(function(_0x403cfb,_0x5842ec){const _0x505420=_0x1a1c,_0x55b1fb=_0x403cfb();while(!![]){try{const _0x2c9135=-parseInt(_0x505420(0x10e))/0x1*(-parseInt(_0x505420(0xb7))/0x2)+-parseInt(_0x505420(0x124))/0x3*(parseInt(_0x505420(0x192))/0x4)+parseInt(_0x505420(0xe5))/0x5*(-parseInt(_0x505420(0xd1))/0x6)+parseInt(_0x505420(0x12b))/0x7*(parseInt(_0x505420(0x152))/0x8)+-parseInt(_0x505420(0x1d0))/0x9+-parseInt(_0x505420(0x133))/0xa*(parseInt(_0x505420(0xb2))/0xb)+parseInt(_0x505420(0xbd))/0xc;if(_0x2c9135===_0x5842ec)break;else _0x55b1fb['push'](_0x55b1fb['shift']());}catch(_0x2d569b){_0x55b1fb['push'](_0x55b1fb['shift']());}}}(_0x434b,0x9c37a));import{ContextPlugin as _0x160e9f,Editor as _0x5c9320}from'ckeditor5/src/core.js';import{CKEditorError as _0x4f662e,logError as _0x402656,scrollViewportToShowTarget as _0x4d71d9,uid as _0x53bca2}from'ckeditor5/src/utils.js';import{AIConnector as _0x4da528}from'../aicore/aiconnector.js';import{AITabs as _0x18e5e0}from'../aitabs/aitabs.js';function _0x1a1c(_0x23520a,_0x255263){const _0x434b30=_0x434b();return _0x1a1c=function(_0x1a1ce4,_0xdeee1a){_0x1a1ce4=_0x1a1ce4-0x95;let _0x4cbaf6=_0x434b30[_0x1a1ce4];return _0x4cbaf6;},_0x1a1c(_0x23520a,_0x255263);}import{AIChatConversation as _0x3dfc61}from'./model/aichatconversation.js';import{getTranslation as _0x293a47}from'../aicore/utils/common-translations.js';import{AI_VISUAL_SELECTION_MARKER_NAME as _0x4452cb}from'../aicore/aiediting.js';import{AI_REPLY_ACTIONS as _0x54810b}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';import{AIChatModels as _0x373b10}from'./model/aichatmodels.js';import{getEditorFromContext as _0x2fb4d2}from'../aicore/utils/geteditorfromcontext.js';import{DocumentCompare as _0x45a94c,DATA_ID_MODEL_ATTRIBUTE as _0x1de6ee}from'ckeditor5-collaboration/src/collaboration-core.js';import{fixMarkerOperationOldRange as _0x96fa53,getOperationsFromReply as _0x35d81a}from'../aicore/utils/getoperationsfromreply.js';import{expandSelectionWithContext as _0x2d8db0,getMinimalSelection as _0x3c6251}from'../aicore/utils/getsuggestionpartsfromreply.js';import{ModelRange as _0xa4175c,_DetachOperation as _0x5a552b}from'ckeditor5/src/engine.js';import{findOne as _0x2682e8,getAttribute as _0x582ccb,serialize as _0x4229f4,Document as _0x30b153,findByAttribute as _0x1082e2}from'../aicore/utils/htmlparser.js';import{IconAI as _0x230613}from'@ckeditor/ckeditor5-icons';import{AISuggestionContainerView as _0x30c4c1}from'../aicore/ui/suggestioncontainer/aisuggestioncontainerview.js';import{AIBalloon as _0x22f8df}from'../aiballoon/aiballoon.js';export class AIChatController extends _0x160e9f{[_0x32f9e9(0x1b9)];[_0x32f9e9(0x1c2)];[_0x32f9e9(0xb6)];[_0x32f9e9(0xdd)];[_0x32f9e9(0x117)]=new Map();[_0x32f9e9(0x179)]=null;[_0x32f9e9(0x112)]=!0x1;static get[_0x32f9e9(0x17c)](){return[_0x4da528,_0x22f8df,_0x45a94c];}static get[_0x32f9e9(0xdc)](){const _0x3e5d26=_0x32f9e9;return _0x3e5d26(0x1c6);}static get[_0x32f9e9(0xf6)](){return!0x0;}static get[_0x32f9e9(0xcf)](){return!0x0;}[_0x32f9e9(0x1ff)](){const _0x5ed0cc=_0x32f9e9;this[_0x5ed0cc(0x1c2)]=this[_0x5ed0cc(0x11a)][_0x5ed0cc(0x167)][_0x5ed0cc(0x190)](_0x5ed0cc(0xb0)),this[_0x5ed0cc(0xb6)]=this[_0x5ed0cc(0x11a)][_0x5ed0cc(0x167)][_0x5ed0cc(0x190)](_0x5ed0cc(0x12d)),this[_0x5ed0cc(0x1b9)]=this[_0x5ed0cc(0x11a)][_0x5ed0cc(0x167)][_0x5ed0cc(0x190)](_0x5ed0cc(0x19a)),this[_0x5ed0cc(0xdd)]=new _0x373b10({'connector':this[_0x5ed0cc(0x1c2)],'availableModels':this[_0x5ed0cc(0x11a)][_0x5ed0cc(0x156)][_0x5ed0cc(0x190)](_0x5ed0cc(0x123)),'defaultModelId':this[_0x5ed0cc(0x11a)][_0x5ed0cc(0x156)][_0x5ed0cc(0x190)](_0x5ed0cc(0xa0))});const _0x1c1316=this[_0x5ed0cc(0x11a)][_0x5ed0cc(0x167)][_0x5ed0cc(0x190)](_0x5ed0cc(0x1a3));this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0x15a),()=>{const _0x12530a=_0x5ed0cc;this[_0x12530a(0x149)]();}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0x139),(_0x5df8d3,_0x44282e)=>{const _0x52edf7=_0x5ed0cc;this[_0x52edf7(0x1b4)]({'userMessage':_0x44282e});}),this[_0x5ed0cc(0x1b8)](_0x1c1316,_0x5ed0cc(0xa1),(_0xea4b7d,_0x4506bd)=>{const _0x33f2a1=_0x5ed0cc;this[_0x33f2a1(0x108)](_0x4506bd);}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0x1a1),()=>{const _0x3d4817=_0x5ed0cc;_0x1c1316[_0x3d4817(0x103)]();}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0x1fb),async()=>{const _0x2959cb=_0x5ed0cc;await this[_0x2959cb(0xfb)](),await this[_0x2959cb(0xa9)](),this[_0x2959cb(0x155)]();}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0xa6),()=>{const _0x478ff9=_0x5ed0cc;this[_0x478ff9(0x1bf)]?.[_0x478ff9(0x1f8)](_0x293a47(this[_0x478ff9(0x11a)][_0x478ff9(0xf9)],_0x478ff9(0x107)));}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0x12f),(_0x1db14f,_0x9dbc4)=>{const _0x2145f6=_0x5ed0cc;this[_0x2145f6(0x1bf)]?.[_0x2145f6(0xc8)](Array[_0x2145f6(0x18a)](_0x9dbc4));}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0x170),(_0x4938c9,_0x1c3c24)=>{const _0x5ecda5=_0x5ed0cc;this[_0x5ecda5(0x1bf)]?.[_0x5ecda5(0x170)](_0x1c3c24);}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0x127),(_0x11f501,_0x9fd166)=>{const _0x2a2592=_0x5ed0cc;this[_0x2a2592(0x1bf)]?.[_0x2a2592(0x127)](_0x9fd166[_0x2a2592(0x119)],_0x9fd166[_0x2a2592(0xc1)]);}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0x95),(_0x406fae,_0xfe2e96)=>{const _0x27d782=_0x5ed0cc;this[_0x27d782(0xde)](_0xfe2e96);}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0x1b0),(_0x5e7e9d,_0x5442d9)=>{const _0x358a4a=_0x5ed0cc;this[_0x358a4a(0x1bf)]?.[_0x358a4a(0x1b0)](_0x5442d9[_0x358a4a(0x15d)],_0x5442d9[_0x358a4a(0xec)],_0x5442d9[_0x358a4a(0x1f1)]);}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0xe8),()=>{const _0x830bf2=_0x5ed0cc;this[_0x830bf2(0x172)]();}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0x13f),()=>{const _0x49cabe=_0x5ed0cc;this[_0x49cabe(0x194)]();}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0x199),(_0x1fefff,_0x40025a)=>{const _0x5b6a23=_0x5ed0cc;this[_0x5b6a23(0x1bf)]?.[_0x5b6a23(0xc0)](_0x40025a);}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0xe0),(_0x5237fc,{replyId:_0x45ef48})=>{const _0xe1cc1f=_0x5ed0cc;console[_0xe1cc1f(0x171)](_0xe1cc1f(0xd7),_0x45ef48);}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0x9b),(_0x305241,{replyId:_0x24b007})=>{const _0x158926=_0x5ed0cc;console[_0x158926(0x171)](_0x158926(0xbf),_0x24b007);}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0x1d2),(_0x4f7822,_0x53fa9c)=>{const _0x4a5053=_0x5ed0cc;this[_0x4a5053(0x11a)][_0x4a5053(0x167)][_0x4a5053(0x190)](_0x22f8df)[_0x4a5053(0x1ae)](),this[_0x4a5053(0x148)](_0x53fa9c);}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0x145),(_0x164307,{replyId:_0x631187,partIndex:_0x1f1965})=>{const _0x1895e7=_0x5ed0cc;this[_0x1895e7(0x112)]=this[_0x1895e7(0xb6)][_0x1895e7(0x189)],this[_0x1895e7(0x110)](_0x631187,_0x1f1965);}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0xa5),(_0x472c00,{replyId:_0x228133,partIndex:_0x583b7b})=>{const _0x54f4c3=_0x5ed0cc,_0x579dfe=this[_0x54f4c3(0x1ea)](_0x228133,_0x583b7b);_0x579dfe&&_0x54f4c3(0xb5)!=_0x579dfe[_0x54f4c3(0x128)][_0x54f4c3(0x1ab)][_0x54f4c3(0x1d7)]&&this[_0x54f4c3(0x1b9)][_0x54f4c3(0x1d1)]([_0x579dfe[_0x54f4c3(0x128)]],_0x54f4c3(0xd2));}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0xa4),()=>{const _0x4b6eaa=_0x5ed0cc;this[_0x4b6eaa(0x1b9)][_0x4b6eaa(0x144)](_0x4b6eaa(0xd2));}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0x147),(_0x25572d,_0x146a18)=>{const _0x526c81=_0x5ed0cc;this[_0x526c81(0x11a)][_0x526c81(0x167)][_0x526c81(0x190)](_0x22f8df)[_0x526c81(0x1ae)](),this[_0x526c81(0x1e2)](_0x146a18);}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0x9c),async(_0x2a8a33,{replyId:_0xf613f4,showDiff:_0x402253})=>{const _0x21ed25=_0x5ed0cc,{reply:_0x183b5a}=this[_0x21ed25(0x9f)](_0xf613f4),_0x2f80f0=_0x183b5a[_0x21ed25(0x104)]({'showDiff':_0x402253});await this[_0x21ed25(0xb6)][_0x21ed25(0x1c8)]({'id':_0x183b5a['id'],'parts':_0x2f80f0,'renderingStrategy':_0x21ed25(0xbb)});}),this[_0x5ed0cc(0x1b8)](this[_0x5ed0cc(0xb6)],_0x5ed0cc(0xe6),(_0x2e544d,{replyId:_0x16643d,partIndex:_0x475b79})=>{const _0x2fd448=_0x5ed0cc;this[_0x2fd448(0x179)]?.[_0x2fd448(0xdf)]==_0x16643d&&this[_0x2fd448(0x179)]?.[_0x2fd448(0x19e)]==_0x475b79&&this[_0x2fd448(0x11a)][_0x2fd448(0x167)][_0x2fd448(0x190)](_0x22f8df)[_0x2fd448(0x1ae)]();const {reply:_0x46a2b1}=this[_0x2fd448(0x9f)](_0x16643d);_0x46a2b1[_0x2fd448(0x14d)](_0x475b79,_0x2fd448(0x15f)),this[_0x2fd448(0x1b9)][_0x2fd448(0x144)](_0x2fd448(0xd2));});}async[_0x32f9e9(0x1d3)](){const _0x1d87e9=_0x32f9e9;this[_0x1d87e9(0x11a)]instanceof _0x5c9320?this[_0x1d87e9(0x1f4)](this[_0x1d87e9(0x11a)]):this[_0x1d87e9(0x1b8)](this[_0x1d87e9(0x11a)][_0x1d87e9(0xd6)],_0x1d87e9(0xef),(_0x3df279,_0x248598)=>{const _0x550825=_0x1d87e9;_0x248598['on'](_0x550825(0x1d8),()=>{const _0x466d7c=_0x550825;this[_0x466d7c(0x1f4)](_0x248598);});}),await this[_0x1d87e9(0x149)]();}[_0x32f9e9(0x148)](_0x31194c){const _0x26359d=_0x32f9e9,_0x2bc6a0=_0x2fb4d2(this[_0x26359d(0x11a)]);if(!_0x2bc6a0[_0x26359d(0x167)][_0x26359d(0x1ba)](_0x26359d(0x14b)))throw new _0x4f662e(_0x26359d(0x137),null);const _0x1b7c62=this[_0x26359d(0x11a)][_0x26359d(0x167)][_0x26359d(0x190)](_0x26359d(0xeb)),{reply:_0x4d0f51,interaction:_0x518445}=this[_0x26359d(0x9f)](_0x31194c[_0x26359d(0xdf)]),_0xdb7311=this[_0x26359d(0x1ea)](_0x31194c[_0x26359d(0xdf)],_0x31194c[_0x26359d(0x19e)]),_0x35bcb3=void 0x0!==_0x31194c[_0x26359d(0x19e)]?[_0x4d0f51[_0x26359d(0xab)][_0x31194c[_0x26359d(0x19e)]]]:_0x4d0f51[_0x26359d(0xab)][_0x26359d(0xc7)](_0xdee74c=>_0x26359d(0x159)==_0xdee74c[_0x26359d(0x132)]),_0x40371f=_0x35bcb3[_0x26359d(0x114)](_0x2c0c93=>_0x4d0f51[_0x26359d(0xab)][_0x26359d(0x105)](_0x2c0c93));if(!_0xdb7311||_0x26359d(0xb5)==_0xdb7311[_0x26359d(0x128)][_0x26359d(0x1ab)][_0x26359d(0x1d7)])return void _0x40371f[_0x26359d(0x10b)](_0xa05894=>_0x4d0f51[_0x26359d(0x14d)](_0xa05894,_0x26359d(0x13a)));_0x40371f[_0x26359d(0x10b)](_0x543267=>_0x4d0f51[_0x26359d(0x14d)](_0x543267,_0x26359d(0xcc)));const _0xa5f620=_0x35d81a({'editor':_0x2bc6a0,'reply':_0x4d0f51,'interaction':_0x518445,'groups':_0x35bcb3,'transform':!0x0,'documentCompare':_0x1b7c62,'documentCompareOptions':{'anchor':_0x26359d(0x11d),'markDeletions':!0x0}});let _0x5eb937;_0xdb7311&&this[_0x26359d(0x166)](_0xdb7311[_0x26359d(0x128)]),_0x2bc6a0[_0x26359d(0xfe)][_0x26359d(0x1a9)](_0x101aa7=>{const _0x474654=_0x26359d;_0x5eb937=_0x101aa7[_0x474654(0x1a8)],_0x2bc6a0[_0x474654(0x167)][_0x474654(0x190)](_0x474654(0xb9))[_0x474654(0x11f)](_0xa5f620),this[_0x474654(0x1b9)][_0x474654(0x144)](_0x474654(0xd2));}),this[_0x26359d(0x117)][_0x26359d(0x16a)](_0x5eb937,{'interactionId':_0x518445['id'],'replyId':_0x4d0f51['id'],'indexes':_0x40371f[_0x26359d(0x17a)]()}),this[_0x26359d(0x14a)](_0x4d0f51);}[_0x32f9e9(0x1e2)](_0xfab59c){const _0x3acdf2=_0x32f9e9,_0x4d81a3=_0x2fb4d2(this[_0x3acdf2(0x11a)]),_0x5aefd7=this[_0x3acdf2(0x11a)][_0x3acdf2(0x167)][_0x3acdf2(0x190)](_0x45a94c),{reply:_0x5afff5,interaction:_0x188790}=this[_0x3acdf2(0x9f)](_0xfab59c[_0x3acdf2(0xdf)]),_0x2ed696=this[_0x3acdf2(0x1ea)](_0xfab59c[_0x3acdf2(0xdf)],_0xfab59c[_0x3acdf2(0x19e)]),_0x1b5983=void 0x0!==_0xfab59c[_0x3acdf2(0x19e)]?[_0x5afff5[_0x3acdf2(0xab)][_0xfab59c[_0x3acdf2(0x19e)]]]:_0x5afff5[_0x3acdf2(0xab)][_0x3acdf2(0xc7)](_0x938059=>_0x3acdf2(0x159)==_0x938059[_0x3acdf2(0x132)]),_0x40831b=_0x1b5983[_0x3acdf2(0x114)](_0x39011f=>_0x5afff5[_0x3acdf2(0xab)][_0x3acdf2(0x105)](_0x39011f));if(!_0x2ed696||_0x3acdf2(0xb5)==_0x2ed696[_0x3acdf2(0x128)][_0x3acdf2(0x1ab)][_0x3acdf2(0x1d7)])return void _0x40831b[_0x3acdf2(0x10b)](_0x45bede=>_0x5afff5[_0x3acdf2(0x14d)](_0x45bede,_0x3acdf2(0x13a)));_0x40831b[_0x3acdf2(0x10b)](_0x186b18=>_0x5afff5[_0x3acdf2(0x14d)](_0x186b18,_0x3acdf2(0xcc)));const _0x3aad44=_0x35d81a({'editor':_0x4d81a3,'reply':_0x5afff5,'interaction':_0x188790,'groups':_0x1b5983,'transform':!0x0,'documentCompare':_0x5aefd7,'documentCompareOptions':{'anchor':_0x3acdf2(0x11d),'markDeletions':!0x1}});let _0x3df717;_0x2ed696&&this[_0x3acdf2(0x166)](_0x2ed696[_0x3acdf2(0x128)]),_0x4d81a3[_0x3acdf2(0xfe)][_0x3acdf2(0x1a9)](_0x1070b5=>{const _0x2be9e9=_0x3acdf2;_0x3df717=_0x1070b5[_0x2be9e9(0x1a8)];for(const _0x3aa8a7 of _0x3aad44)_0x3aa8a7[_0x2be9e9(0xb3)]=_0x4d81a3[_0x2be9e9(0xfe)][_0x2be9e9(0x1a0)][_0x2be9e9(0x183)],_0x96fa53(_0x4d81a3,_0x3aa8a7),_0x1070b5[_0x2be9e9(0x1a8)][_0x2be9e9(0xf0)](_0x3aa8a7),_0x4d81a3[_0x2be9e9(0xfe)][_0x2be9e9(0x168)](_0x3aa8a7);}),this[_0x3acdf2(0x117)][_0x3acdf2(0x16a)](_0x3df717,{'interactionId':_0x188790['id'],'replyId':_0x5afff5['id'],'indexes':_0x40831b[_0x3acdf2(0x17a)]()}),this[_0x3acdf2(0x14a)](_0x5afff5);}[_0x32f9e9(0x110)](_0x4567f2,_0x3f77bc){const _0x7139e=_0x32f9e9,_0x7493b1=_0x2fb4d2(this[_0x7139e(0x11a)]),_0x104d92=this[_0x7139e(0x1ea)](_0x4567f2,_0x3f77bc),_0x3783aa=this[_0x7139e(0x11a)][_0x7139e(0x167)][_0x7139e(0x190)](_0x22f8df);if(!_0x104d92)return void _0x3783aa[_0x7139e(0x1ae)]();const {range:_0x551a0b,currentIndex:_0x85c36b}=_0x104d92;if(_0x7139e(0xb5)==_0x551a0b[_0x7139e(0x1ab)][_0x7139e(0x1d7)]){const {reply:_0x510304}=this[_0x7139e(0x9f)](_0x4567f2);return _0x510304[_0x7139e(0x14d)](_0x85c36b,_0x7139e(0x13a)),void _0x3783aa[_0x7139e(0x1ae)]();}if(this[_0x7139e(0x179)]?.[_0x7139e(0xdf)]==_0x4567f2&&this[_0x7139e(0x179)]?.[_0x7139e(0x19e)]==_0x85c36b)return;this[_0x7139e(0xc6)](_0x3783aa),this[_0x7139e(0x179)]={'replyId':_0x4567f2,'partIndex':_0x85c36b};let _0x2d1bca=_0x7493b1[_0x7139e(0x156)][_0x7139e(0x190)](_0x7139e(0xce))||[..._0x54810b];_0x7493b1[_0x7139e(0x167)][_0x7139e(0x1ba)](_0x7139e(0x14b))||(_0x2d1bca=_0x2d1bca[_0x7139e(0xc7)](_0x4a2af9=>_0x7139e(0x1d2)!=_0x4a2af9));const _0x2592e0=new _0x30c4c1(_0x7493b1[_0x7139e(0xf9)],{'showDiff':this[_0x7139e(0x112)],'areActionsDisabled':!0x1,'miniToolbarConfig':{'showChanges':_0x7139e(0x1cf)},'hideHeader':!0x0,'availableActions':_0x2d1bca});this[_0x7139e(0xc6)](_0x2592e0);const {reply:_0x3557c3}=this[_0x7139e(0x9f)](_0x4567f2),_0x858b07=_0x3557c3[_0x7139e(0x104)]({'showDiff':this[_0x7139e(0x112)]})[_0x7139e(0xc7)](_0x4007e9=>_0x4007e9[_0x7139e(0x1d4)]),_0x42d217=_0x858b07[_0x7139e(0xe1)](_0x4802e0=>_0x4802e0[_0x7139e(0x1e4)]==_0x85c36b);if(-0x1==_0x42d217)return;const _0x3e0fbc=_0x858b07[_0x42d217],_0x234d49=_0x858b07['at']((_0x42d217-0x1)%_0x858b07[_0x7139e(0x1e1)])?.[_0x7139e(0x1e4)],_0x4321cb=_0x858b07['at']((_0x42d217+0x1)%_0x858b07[_0x7139e(0x1e1)])?.[_0x7139e(0x1e4)];_0x2592e0[_0x7139e(0x1f0)]({'parts':[_0x3e0fbc],'renderingStrategy':_0x7139e(0xbb)});const _0xc566af=_0x85c36b!==_0x234d49;this[_0x7139e(0x166)](_0x551a0b,!0x0),_0x3783aa[_0x7139e(0x10a)]({'index':_0x85c36b,'title':_0x293a47(this[_0x7139e(0x11a)][_0x7139e(0xf9)],_0x7139e(0xbc),(_0x42d217+0x1)[_0x7139e(0xb4)]()),'icon':_0x230613,'mainView':_0x2592e0,'showRotator':_0xc566af,'showApplyButton':!0x0,'showSuggestButton':_0x7493b1[_0x7139e(0x167)][_0x7139e(0x1ba)](_0x7139e(0x14b)),'ranges':[_0x551a0b]}),this[_0x7139e(0xb6)][_0x7139e(0x10d)](_0x4567f2,_0x85c36b),this[_0x7139e(0x1b8)](_0x2592e0,_0x7139e(0x9c),(_0x15b850,{showDiff:_0x33d99c})=>{const _0x1e969e=_0x7139e;this[_0x1e969e(0x112)]=_0x33d99c;const {reply:_0x1cff89}=this[_0x1e969e(0x9f)](_0x4567f2),_0x39b829=_0x1cff89[_0x1e969e(0x104)]({'showDiff':_0x33d99c,'groupIndex':_0x85c36b});_0x2592e0[_0x1e969e(0x1f0)]({'parts':_0x39b829,'renderingStrategy':_0x1e969e(0xbb)});}),this[_0x7139e(0x1b8)](_0x3783aa,_0x7139e(0x147),()=>{const _0x302dae=_0x7139e;this[_0x302dae(0x1e2)]({'replyId':_0x4567f2,'partIndex':_0x85c36b}),_0xc566af?this[_0x302dae(0x110)](_0x4567f2,_0x4321cb):_0x3783aa[_0x302dae(0x1ae)]();}),this[_0x7139e(0x1b8)](_0x3783aa,_0x7139e(0x1d2),()=>{const _0x4294e3=_0x7139e;this[_0x4294e3(0x148)]({'replyId':_0x4567f2,'partIndex':_0x85c36b}),_0xc566af?this[_0x4294e3(0x110)](_0x4567f2,_0x4321cb):_0x3783aa[_0x4294e3(0x1ae)]();}),_0xc566af&&(this[_0x7139e(0x1b8)](_0x3783aa,_0x7139e(0x173),()=>{const _0x307d1a=_0x7139e;this[_0x307d1a(0x110)](_0x4567f2,_0x4321cb);}),this[_0x7139e(0x1b8)](_0x3783aa,_0x7139e(0x18c),()=>{const _0x8b05c5=_0x7139e;this[_0x8b05c5(0x110)](_0x4567f2,_0x234d49);})),this[_0x7139e(0x1b8)](_0x3783aa,_0x7139e(0x120),()=>{const _0x5843f0=_0x7139e;this[_0x5843f0(0xc6)](_0x3783aa),this[_0x5843f0(0xc6)](_0x2592e0),this[_0x5843f0(0x179)]=null;});}[_0x32f9e9(0x1ea)](_0x21f80c,_0x5e895e){const _0xa1cea6=_0x32f9e9,_0x800cd5=_0x2fb4d2(this[_0xa1cea6(0x11a)]),{reply:_0x30c464,interaction:_0x87906e}=this[_0xa1cea6(0x9f)](_0x21f80c),_0x17f7ce=_0x30c464[_0xa1cea6(0xab)][_0xa1cea6(0xc7)](_0x40efd5=>_0xa1cea6(0x159)==_0x40efd5[_0xa1cea6(0x132)]),_0x299a13=_0x17f7ce[_0xa1cea6(0x114)](_0xd2f051=>_0x30c464[_0xa1cea6(0xab)][_0xa1cea6(0x105)](_0xd2f051));void 0x0===_0x5e895e&&(_0x5e895e=_0x299a13[0x0]);const _0x499bd4=_0x299a13[_0xa1cea6(0x105)](_0x5e895e);if(-0x1==_0x499bd4)return null;const _0x4b0e98=_0x17f7ce[_0x499bd4],_0x26ec43=new _0x30b153([]),_0x2f5416=new _0x30b153([]);for(const _0x253aa7 of _0x4b0e98[_0xa1cea6(0x165)])if(_0xa1cea6(0x181)!=_0x253aa7[_0xa1cea6(0x184)]&&_0x2f5416[_0xa1cea6(0x1af)][_0xa1cea6(0x154)](_0x253aa7[_0xa1cea6(0xee)][_0xa1cea6(0x1bd)](!0x0)),_0xa1cea6(0x13c)!=_0x253aa7[_0xa1cea6(0x184)]){const _0xd51655=_0x2682e8(_0x36de38=>_0x582ccb(_0x36de38,_0xa1cea6(0x14f))==_0x253aa7['id'],_0x30c464[_0xa1cea6(0x1bb)],!0x0);_0x26ec43[_0xa1cea6(0x1af)][_0xa1cea6(0x154)](_0xd51655[_0xa1cea6(0x1bd)](!0x0));}if(0x0==_0x26ec43[_0xa1cea6(0x1af)][_0xa1cea6(0x1e1)]){if(_0x4b0e98[_0xa1cea6(0x165)][0x0][_0xa1cea6(0x1bc)]){const _0x2ea799=_0x1082e2(_0xa1cea6(0x14f),_0x4b0e98[_0xa1cea6(0x165)][0x0][_0xa1cea6(0x1bc)],_0x30c464[_0xa1cea6(0x1bb)]);_0x26ec43[_0xa1cea6(0x1af)][_0xa1cea6(0x195)](_0x2ea799[_0xa1cea6(0x1bd)](!0x0)),_0x2f5416[_0xa1cea6(0x1af)][_0xa1cea6(0x195)](_0x2ea799[_0xa1cea6(0x1bd)](!0x0)),_0x2ea799[_0xa1cea6(0x121)]&&(_0x26ec43[_0xa1cea6(0x1af)][_0xa1cea6(0x154)](_0x2ea799[_0xa1cea6(0x121)][_0xa1cea6(0x1bd)](!0x0)),_0x2f5416[_0xa1cea6(0x1af)][_0xa1cea6(0x154)](_0x2ea799[_0xa1cea6(0x121)][_0xa1cea6(0x1bd)](!0x0)));}else{const _0x2f489a=_0x30c464[_0xa1cea6(0x1bb)][_0xa1cea6(0x1af)][0x0];if(!_0x2f489a)return null;_0x26ec43[_0xa1cea6(0x1af)][_0xa1cea6(0x154)](_0x2f489a[_0xa1cea6(0x1bd)](!0x0)),_0x2f5416[_0xa1cea6(0x1af)][_0xa1cea6(0x154)](_0x2f489a[_0xa1cea6(0x1bd)](!0x0));}}const _0x50d59a=_0x87906e[_0xa1cea6(0xf5)](),_0x1eccf5=_0x800cd5[_0xa1cea6(0xb1)][_0xa1cea6(0x1f7)](_0x50d59a[_0xa1cea6(0xda)]),_0x588f94=_0x4229f4(_0x26ec43),_0x3f0b35=_0x800cd5[_0xa1cea6(0xb1)][_0xa1cea6(0x1f7)](_0x588f94),_0x18ef41=_0x800cd5[_0xa1cea6(0xb1)][_0xa1cea6(0x1f7)](_0x588f94),_0x21a2e7=_0x800cd5[_0xa1cea6(0xfe)][_0xa1cea6(0x11c)](_0x3f0b35,0x0),_0xe72e12=_0x4229f4(_0x2f5416),_0x2dc7d6={'anchor':_0x21a2e7,'markDeletions':!0x1},_0x445ff3=_0x800cd5[_0xa1cea6(0x167)][_0xa1cea6(0x190)](_0x45a94c)[_0xa1cea6(0x101)](_0x588f94,_0xe72e12,_0x2dc7d6)[_0xa1cea6(0x19f)]();if(!_0x445ff3[_0xa1cea6(0x1e1)])return null;_0x800cd5[_0xa1cea6(0xfe)][_0xa1cea6(0x1a9)](_0x2f42c4=>{const _0x252a41=_0xa1cea6;for(const _0xba971f of _0x445ff3)if(_0x252a41(0xad)==_0xba971f[_0x252a41(0x184)]){const _0xd9b304=_0xba971f[_0x252a41(0xa7)],_0x383bf3=_0xba971f[_0x252a41(0x1ce)],_0x47821c=new _0x5a552b(_0xd9b304,_0x383bf3);_0x2f42c4[_0x252a41(0x1a8)][_0x252a41(0xf0)](_0x47821c),_0x800cd5[_0x252a41(0xfe)][_0x252a41(0x168)](_0x47821c);}else _0x252a41(0xac)!==_0xba971f[_0x252a41(0x184)]&&(_0xba971f[_0x252a41(0xb3)]=null,_0xba971f[_0x252a41(0x11e)]=!0x1,_0x2f42c4[_0x252a41(0x1a8)][_0x252a41(0xf0)](_0xba971f),_0x800cd5[_0x252a41(0xfe)][_0x252a41(0x168)](_0xba971f));});const _0x5ddbd2=_0x3c6251(_0x800cd5,_0x445ff3,_0x3f0b35);_0x2d8db0(_0x800cd5[_0xa1cea6(0xfe)],_0x5ddbd2);const _0x5cdae0=_0x5ddbd2[_0xa1cea6(0x1c5)]()[_0xa1cea6(0x113)][_0xa1cea6(0x1ee)][_0xa1cea6(0x17a)](),_0x42962c=_0x5ddbd2[_0xa1cea6(0x1c5)]()[_0xa1cea6(0x13d)][_0xa1cea6(0x1ee)][_0xa1cea6(0x17a)](),_0x17553f=[];let _0x381db3=_0x3f0b35,_0xc695a8=_0x18ef41;for(let _0x1dbd8c=0x0;_0x1dbd8c<_0x42962c[_0xa1cea6(0x1e1)];_0x1dbd8c++){const _0x2687f6=_0x381db3[_0xa1cea6(0x198)]-_0x42962c[_0x1dbd8c];_0x17553f[_0x1dbd8c]=_0xc695a8[_0xa1cea6(0x198)]-_0x2687f6,_0x381db3=_0x381db3[_0xa1cea6(0x1eb)](_0x42962c[_0x1dbd8c]),_0xc695a8=_0xc695a8[_0xa1cea6(0x1eb)](_0x17553f[_0x1dbd8c]);}const _0x4aca38=_0x800cd5[_0xa1cea6(0xfe)][_0xa1cea6(0x111)](_0x800cd5[_0xa1cea6(0xfe)][_0xa1cea6(0xc4)](_0x18ef41,_0x5cdae0),_0x800cd5[_0xa1cea6(0xfe)][_0xa1cea6(0xc4)](_0x18ef41,_0x17553f)),_0x387b02=_0x18ef41[_0xa1cea6(0x1fe)](0x0)[_0xa1cea6(0x135)](_0x1de6ee),_0x33b9de=Array[_0xa1cea6(0x18a)](_0x1eccf5[_0xa1cea6(0x1d9)]())[_0xa1cea6(0xa2)](_0x4a481e=>_0x4a481e[_0xa1cea6(0x135)](_0x1de6ee)==_0x387b02)[_0xa1cea6(0x141)](),_0x58c549=_0x4aca38[_0xa1cea6(0x113)][_0xa1cea6(0x1ee)][_0xa1cea6(0x17a)](),_0x53ee6b=_0x4aca38[_0xa1cea6(0x13d)][_0xa1cea6(0x1ee)][_0xa1cea6(0x17a)]();_0x58c549[0x0]=_0x33b9de[0x0]+_0x58c549[0x0],_0x53ee6b[0x0]=_0x33b9de[0x0]+_0x53ee6b[0x0];let _0x3bc8eb=_0x800cd5[_0xa1cea6(0xfe)][_0xa1cea6(0x111)](_0x800cd5[_0xa1cea6(0xfe)][_0xa1cea6(0xc4)](_0x800cd5[_0xa1cea6(0xfe)][_0xa1cea6(0x1a0)][_0xa1cea6(0x187)](),_0x58c549),_0x800cd5[_0xa1cea6(0xfe)][_0xa1cea6(0xc4)](_0x800cd5[_0xa1cea6(0xfe)][_0xa1cea6(0x1a0)][_0xa1cea6(0x187)](),_0x53ee6b));const _0x213892=_0x800cd5[_0xa1cea6(0xfe)][_0xa1cea6(0x1a0)][_0xa1cea6(0xa8)][_0xa1cea6(0x19f)](_0x50d59a[_0xa1cea6(0x183)]);for(const _0x110599 of _0x213892)_0x3bc8eb=_0xa4175c[_0xa1cea6(0x186)](_0x3bc8eb[_0xa1cea6(0x201)](_0x110599));return{'range':_0x3bc8eb,'currentIndex':_0x5e895e};}[_0x32f9e9(0x1f4)](_0x390375){const _0x4e96fb=_0x32f9e9;if(!_0x390375[_0x4e96fb(0x167)][_0x4e96fb(0x1ba)](_0x4e96fb(0x16d)))return;const _0x42c250=_0x390375[_0x4e96fb(0x12e)][_0x4e96fb(0x190)](_0x4e96fb(0x98)),_0x1fc142=_0x390375[_0x4e96fb(0x12e)][_0x4e96fb(0x190)](_0x4e96fb(0xdb));this[_0x4e96fb(0x1b8)](_0x42c250,_0x4e96fb(0xf8),(_0xc9d956,_0x1d8daa,_0x333382)=>{const _0x56048f=_0x4e96fb,_0xd52e84=this[_0x56048f(0x117)][_0x56048f(0x190)](_0x1d8daa);if(!_0xd52e84)return;const _0x1e9cae=this[_0x56048f(0x1bf)][_0x56048f(0x1e0)](_0xd52e84[_0x56048f(0x19c)])[_0x56048f(0xfa)](_0xd52e84[_0x56048f(0xdf)]);_0xd52e84[_0x56048f(0x1dd)][_0x56048f(0x10b)](_0xe9299f=>_0x1e9cae[_0x56048f(0x14d)](_0xe9299f,_0x56048f(0x159))),this[_0x56048f(0x117)][_0x56048f(0x1c1)](_0x1d8daa),this[_0x56048f(0x117)][_0x56048f(0x16a)](_0x333382,_0xd52e84);}),this[_0x4e96fb(0x1b8)](_0x1fc142,_0x4e96fb(0xf8),(_0x565824,_0x5f5219,_0x2b2108)=>{const _0x6e3f7e=_0x4e96fb,_0x4949f4=this[_0x6e3f7e(0x117)][_0x6e3f7e(0x190)](_0x5f5219);if(!_0x4949f4)return;const _0x46ae1b=this[_0x6e3f7e(0x1bf)][_0x6e3f7e(0x1e0)](_0x4949f4[_0x6e3f7e(0x19c)])[_0x6e3f7e(0xfa)](_0x4949f4[_0x6e3f7e(0xdf)]);_0x4949f4[_0x6e3f7e(0x1dd)][_0x6e3f7e(0x10b)](_0x34b13c=>_0x46ae1b[_0x6e3f7e(0x14d)](_0x34b13c,_0x6e3f7e(0xcc))),this[_0x6e3f7e(0x117)][_0x6e3f7e(0x1c1)](_0x5f5219),this[_0x6e3f7e(0x117)][_0x6e3f7e(0x16a)](_0x2b2108,_0x4949f4);});}async[_0x32f9e9(0x1e8)](_0x2ef91e){const _0x24793a=_0x32f9e9;this[_0x24793a(0x11a)][_0x24793a(0x167)][_0x24793a(0x190)](_0x22f8df)[_0x24793a(0x1ae)](),this[_0x24793a(0xb6)][_0x24793a(0x18b)](_0x24793a(0xbb)),this[_0x24793a(0xb6)][_0x24793a(0x1a7)](!0x0),await this[_0x24793a(0xfb)]();try{await this[_0x24793a(0x1c2)][_0x24793a(0x118)](_0x2ef91e)[_0x24793a(0x1be)](),await this[_0x24793a(0x149)](_0x2ef91e),this[_0x24793a(0x163)]('\x20');const {sessionId:_0x52a45d}=this[_0x24793a(0x1b9)][_0x24793a(0x1e7)]();await this[_0x24793a(0x1bf)][_0x24793a(0xae)](_0x2ef91e,_0x52a45d),this[_0x24793a(0x1bf)][_0x24793a(0x1ac)]()&&this[_0x24793a(0x1bf)][_0x24793a(0x1f8)](_0x293a47(this[_0x24793a(0x11a)][_0x24793a(0xf9)],_0x24793a(0x107)));}catch(_0x576299){this[_0x24793a(0xb6)][_0x24793a(0x136)]({'errorMessage':_0x293a47(this[_0x24793a(0x11a)][_0x24793a(0xf9)],_0x24793a(0x1b6)),'id':_0x2ef91e}),this[_0x24793a(0x197)](new _0x4f662e(_0x24793a(0x1e6),this,{'error':_0x576299}));}finally{this[_0x24793a(0x11a)][_0x24793a(0x167)][_0x24793a(0x190)](_0x18e5e0)[_0x24793a(0x1a5)][_0x24793a(0x174)](_0x24793a(0x1e9)),this[_0x24793a(0xb6)][_0x24793a(0xe9)](),this[_0x24793a(0xb6)][_0x24793a(0x18b)](_0x24793a(0x17e)),this[_0x24793a(0xb6)][_0x24793a(0x1a7)](!0x1);}}[_0x32f9e9(0x142)](_0x4726d4){const _0x1babe=_0x32f9e9;this[_0x1babe(0x1bf)]['id']===_0x4726d4&&this[_0x1babe(0x149)]();}async[_0x32f9e9(0xfc)](){const _0x63c7ea=_0x32f9e9,_0x55e52c=this[_0x63c7ea(0x1b9)][_0x63c7ea(0x1b5)]();this[_0x63c7ea(0x1bf)]?.[_0x63c7ea(0xc9)](_0x55e52c),this[_0x63c7ea(0x1bf)]?.[_0x63c7ea(0x1f8)](_0x293a47(this[_0x63c7ea(0x11a)][_0x63c7ea(0xf9)],_0x63c7ea(0x107)));}[_0x32f9e9(0x155)](){const _0x36e45d=_0x32f9e9;this[_0x36e45d(0x1bf)]?.[_0x36e45d(0xf4)]();}[_0x32f9e9(0x1cc)](){const _0x431c6f=_0x32f9e9;this[_0x431c6f(0xb6)][_0x431c6f(0x1cc)]();}async[_0x32f9e9(0x15a)](){const _0xb795b6=_0x32f9e9;await this[_0xb795b6(0x149)]();}async[_0x32f9e9(0x9a)]({message:_0x348676,quickActionData:_0x760c3d}){const _0x46dfb1=_0x32f9e9;await this[_0x46dfb1(0x1b4)]({'userMessage':_0x348676,'quickActionData':_0x760c3d});}[_0x32f9e9(0xd8)](){const _0x19652b=_0x32f9e9,_0x342356=this[_0x19652b(0x11a)][_0x19652b(0x156)][_0x19652b(0x190)](_0x19652b(0x138));if(!_0x342356)throw new _0x4f662e(_0x19652b(0x1b3),this);return _0x342356;}async[_0x32f9e9(0x149)](_0x1c08c0){const _0x321bb0=_0x32f9e9;try{this[_0x321bb0(0xb6)][_0x321bb0(0x191)](),await this[_0x321bb0(0x164)](_0x1c08c0);}catch(_0x4e103d){this[_0x321bb0(0xb6)][_0x321bb0(0x136)]({'errorMessage':_0x293a47(this[_0x321bb0(0x11a)][_0x321bb0(0xf9)],_0x321bb0(0x129)),'id':_0x1c08c0||_0x53bca2()}),console[_0x321bb0(0xd5)](_0x4e103d),this[_0x321bb0(0x1bf)]=void 0x0,this[_0x321bb0(0xb6)][_0x321bb0(0x1a4)]();}}async[_0x32f9e9(0x164)](_0x21cd6e){const _0x4a365e=_0x32f9e9,_0x59c459=this[_0x4a365e(0x11a)][_0x4a365e(0x167)][_0x4a365e(0x190)](_0x22f8df);let _0x48caa6;_0x59c459[_0x4a365e(0x13e)]&&_0x59c459[_0x4a365e(0x1ae)](),_0x21cd6e||!this[_0x4a365e(0x1bf)]?_0x48caa6=this[_0x4a365e(0x11a)][_0x4a365e(0x156)][_0x4a365e(0x190)](_0x4a365e(0xa0)):this[_0x4a365e(0xb6)][_0x4a365e(0x17d)]&&(_0x48caa6=this[_0x4a365e(0x1bf)][_0x4a365e(0x14c)]['id']),await this[_0x4a365e(0xfb)]();const _0x115889=this[_0x4a365e(0xd8)](),_0x3b5b63=_0x21cd6e||_0x53bca2();this[_0x4a365e(0x1bf)]=new _0x3dfc61({'connector':this[_0x4a365e(0x1c2)],'chatModels':this[_0x4a365e(0xdd)],'selectedModelId':_0x48caa6,'conversationId':_0x3b5b63,'group':_0x115889,'getEditor':()=>_0x2fb4d2(this[_0x4a365e(0x11a)])}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0xba),(_0x157398,_0x351898)=>{const _0x7574ad=_0x4a365e;this[_0x7574ad(0xb6)][_0x7574ad(0x1e5)](_0x351898),this[_0x7574ad(0xb6)][_0x7574ad(0x188)](),this[_0x7574ad(0xb6)][_0x7574ad(0x106)](),this[_0x7574ad(0xb6)][_0x7574ad(0x162)](),_0x21cd6e||(this[_0x7574ad(0xb6)][_0x7574ad(0x140)](),this[_0x7574ad(0x1bf)]?.[_0x7574ad(0x1f8)](_0x293a47(this[_0x7574ad(0x11a)][_0x7574ad(0xf9)],_0x7574ad(0x107))));}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0xc5),(_0x1406e6,_0x1ef51d)=>{const _0x281bed=_0x4a365e;this[_0x281bed(0xb6)][_0x281bed(0xbe)](_0x1ef51d[_0x281bed(0xe7)]);}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0x1aa),(_0x320968,_0x243258)=>{const _0x1c5c06=_0x4a365e;this[_0x1c5c06(0xb6)][_0x1c5c06(0x153)](_0x243258);}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0x1da),()=>{const _0x422ca0=_0x4a365e;this[_0x422ca0(0xb6)][_0x422ca0(0x202)]({'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0x1c7),()=>{const _0x5343a0=_0x4a365e;this[_0x5343a0(0xb6)][_0x5343a0(0x202)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0x1a6),(_0x417a58,_0x2224eb)=>{const _0x114d9b=_0x4a365e;this[_0x114d9b(0xb6)][_0x114d9b(0x1db)](_0x2224eb,{'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0x182),(_0xa2d69c,_0x42bad9)=>{const _0xaf86e3=_0x4a365e;this[_0xaf86e3(0xb6)][_0xaf86e3(0x1db)](_0x42bad9,{'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0x16e),()=>{const _0x2ba7da=_0x4a365e;this[_0x2ba7da(0xb6)][_0x2ba7da(0xea)]();}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0x17f),async()=>{const _0x2a3be9=_0x4a365e;await this[_0x2a3be9(0xb6)][_0x2a3be9(0x18d)]();}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0x1c9),(_0xafdb84,_0x213527)=>{const _0x5dc8d3=_0x4a365e;this[_0x5dc8d3(0xb6)][_0x5dc8d3(0x1cd)](_0x213527['id']);}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0x134),(_0x133742,_0xcc921,_0x33aab3)=>{const _0x1ba7ab=_0x4a365e;this[_0x1ba7ab(0x163)](_0xcc921,_0x33aab3);}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0x160),(_0x10e535,_0x1cc8a7)=>{const _0x50337b=_0x4a365e;_0x50337b(0x1fd)===_0x1cc8a7[_0x50337b(0x184)]?this[_0x50337b(0xb6)][_0x50337b(0x102)](_0x1cc8a7):this[_0x50337b(0xb6)][_0x50337b(0x157)](_0x1cc8a7);}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0xd4),async(_0x374515,_0xd6a922)=>{const _0x5a4a67=_0x4a365e;await this[_0x5a4a67(0x131)]({'reply':_0xd6a922});}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0x1f6),(_0x2ccdbf,{reply:_0x217359,index:_0x589d0a,state:_0x459095})=>{const _0x3f4c56=_0x4a365e;this[_0x3f4c56(0xb6)][_0x3f4c56(0x180)]({'id':_0x217359['id'],'index':_0x589d0a,'state':_0x459095});}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0x19d),(_0x1f4923,_0x2c4f1b)=>{const _0x575aaa=_0x4a365e;if(this[_0x575aaa(0xb6)][_0x575aaa(0x1f2)](_0x2c4f1b[_0x575aaa(0xc3)],_0x2c4f1b[_0x575aaa(0x151)]),_0x575aaa(0x17b)===_0x2c4f1b[_0x575aaa(0xc3)][_0x575aaa(0x184)]){const _0x43091f=[..._0x2fb4d2(this[_0x575aaa(0x11a)])[_0x575aaa(0xfe)][_0x575aaa(0x1a0)][_0x575aaa(0x17b)][_0x575aaa(0x99)]()];this[_0x575aaa(0x1b9)][_0x575aaa(0x1d1)](_0x43091f,_0x575aaa(0xd9)+this[_0x575aaa(0x1bf)]?.['id']);}}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0x1cb),(_0x589c52,_0x59858d)=>{const _0x2a0152=_0x4a365e;this[_0x2a0152(0xb6)][_0x2a0152(0x95)](_0x59858d[_0x2a0152(0x1f9)]),_0x2a0152(0x14e)==_0x59858d[_0x2a0152(0x1f9)]&&this[_0x2a0152(0x155)](),_0x2a0152(0x17b)===_0x59858d[_0x2a0152(0x184)]&&this[_0x2a0152(0x1b9)][_0x2a0152(0x144)](_0x2a0152(0xd9)+this[_0x2a0152(0x1bf)]?.['id']);}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0x1ad),(_0x4bf7c1,_0x2610b7)=>{const _0x472131=_0x4a365e;this[_0x472131(0xb6)][_0x472131(0x12a)](_0x2610b7[_0x472131(0xc3)][_0x472131(0x1f9)],_0x2610b7[_0x472131(0x151)]);}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0x1d6),(_0x69c0,_0x7eacf2)=>{const _0x14f2c3=_0x4a365e;this[_0x14f2c3(0xb6)][_0x14f2c3(0x15e)](_0x7eacf2[_0x14f2c3(0x100)]);}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0xd0),(_0x19460d,_0x2cb975)=>{const _0x7e07f3=_0x4a365e;this[_0x7e07f3(0xb6)][_0x7e07f3(0x10c)](_0x2cb975[_0x7e07f3(0x176)]);}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0xfd),(_0x5bb55f,_0x43f0c2)=>{const _0x492899=_0x4a365e;this[_0x492899(0xb6)][_0x492899(0xb8)](_0x43f0c2[_0x492899(0x15d)],_0x43f0c2[_0x492899(0x119)],_0x43f0c2[_0x492899(0x1a2)],_0x43f0c2[_0x492899(0x1f1)]);}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0xaa),(_0x46dcfb,_0x3ee352)=>{const _0x25f699=_0x4a365e;this[_0x25f699(0xb6)][_0x25f699(0xcd)](_0x3ee352[_0x25f699(0x15d)],_0x3ee352[_0x25f699(0xf3)],_0x3ee352[_0x25f699(0x1ec)]);}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0x158),(_0xd848d1,_0x337a1c)=>{const _0x1edf38=_0x4a365e;this[_0x1edf38(0xb6)][_0x1edf38(0xd3)](_0x337a1c);}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0x1c0),(_0x42b549,_0x55a80f)=>{const _0x563b97=_0x4a365e;this[_0x563b97(0xb6)][_0x563b97(0x1ef)](_0x55a80f[_0x563b97(0x14c)],_0x55a80f[_0x563b97(0x9e)]);}),this[_0x4a365e(0x1bf)]['on'](_0x4a365e(0xd5),(_0xab4d1f,{error:_0x1b1993,interactionId:_0x1edf63,fileName:_0x19d4a7,url:_0x331383,sourceId:_0x859444,sourceLabel:_0x4133d5})=>{const _0x10b5f1=_0x4a365e,_0x21caf7=_0x1edf63?_0x1edf63+':'+_0x53bca2():_0x53bca2();_0x1b1993[_0x10b5f1(0x175)][_0x10b5f1(0x161)](_0x10b5f1(0x1b7))?this[_0x10b5f1(0xb6)][_0x10b5f1(0xff)]({'staticMessage':_0x293a47(this[_0x10b5f1(0x11a)][_0x10b5f1(0xf9)],_0x10b5f1(0x1f3)),'id':_0x21caf7}):_0x1b1993[_0x10b5f1(0x175)][_0x10b5f1(0x161)](_0x10b5f1(0xe2))||_0x1b1993[_0x10b5f1(0x175)][_0x10b5f1(0x161)](_0x10b5f1(0x146))?(this[_0x10b5f1(0xb6)][_0x10b5f1(0x136)]({'errorMessage':_0x293a47(this[_0x10b5f1(0x11a)][_0x10b5f1(0xf9)],_0x10b5f1(0x129)),'id':_0x21caf7}),this[_0x10b5f1(0x197)](_0x1b1993)):_0x1b1993[_0x10b5f1(0x175)][_0x10b5f1(0x161)](_0x10b5f1(0x126))?this[_0x10b5f1(0xb6)][_0x10b5f1(0x136)]({'errorMessage':_0x293a47(this[_0x10b5f1(0x11a)][_0x10b5f1(0xf9)],_0x10b5f1(0x177),_0x19d4a7),'id':_0x21caf7}):_0x1b1993[_0x10b5f1(0x175)][_0x10b5f1(0x161)](_0x10b5f1(0x1df))?this[_0x10b5f1(0xb6)][_0x10b5f1(0x136)]({'errorMessage':_0x293a47(this[_0x10b5f1(0x11a)][_0x10b5f1(0xf9)],_0x10b5f1(0x18f),_0x331383),'id':_0x21caf7}):_0x1b1993[_0x10b5f1(0x175)][_0x10b5f1(0x161)](_0x10b5f1(0x115))?this[_0x10b5f1(0xb6)][_0x10b5f1(0x136)]({'errorMessage':_0x293a47(this[_0x10b5f1(0x11a)][_0x10b5f1(0xf9)],_0x10b5f1(0xa3)),'id':_0x21caf7}):_0x1b1993[_0x10b5f1(0x175)][_0x10b5f1(0x161)](_0x10b5f1(0xcb))?this[_0x10b5f1(0xb6)][_0x10b5f1(0x136)]({'errorMessage':_0x293a47(this[_0x10b5f1(0x11a)][_0x10b5f1(0xf9)],_0x10b5f1(0x1dc)),'id':_0x21caf7}):_0x1b1993[_0x10b5f1(0x175)][_0x10b5f1(0x161)](_0x10b5f1(0xf1))?(_0x859444&&this[_0x10b5f1(0xb6)][_0x10b5f1(0x16b)](_0x859444),this[_0x10b5f1(0xb6)][_0x10b5f1(0x136)]({'errorMessage':_0x293a47(this[_0x10b5f1(0x11a)][_0x10b5f1(0xf9)],_0x10b5f1(0x18e),_0x4133d5||_0x10b5f1(0x119)),'id':_0x21caf7}),this[_0x10b5f1(0x197)](_0x1b1993)):_0x1b1993[_0x10b5f1(0x175)][_0x10b5f1(0x161)](_0x10b5f1(0x1d5))?(this[_0x10b5f1(0xb6)][_0x10b5f1(0x136)]({'errorMessage':_0x293a47(this[_0x10b5f1(0x11a)][_0x10b5f1(0xf9)],_0x10b5f1(0xca)),'id':_0x21caf7}),this[_0x10b5f1(0x197)](_0x1b1993)):_0x1b1993[_0x10b5f1(0x175)][_0x10b5f1(0x161)](_0x10b5f1(0x116))?(this[_0x10b5f1(0xb6)][_0x10b5f1(0x136)]({'errorMessage':_0x293a47(this[_0x10b5f1(0x11a)][_0x10b5f1(0xf9)],_0x10b5f1(0x1de)),'id':_0x21caf7}),this[_0x10b5f1(0x197)](_0x1b1993)):_0x1b1993[_0x10b5f1(0x175)][_0x10b5f1(0x161)](_0x10b5f1(0x11b))?(this[_0x10b5f1(0xb6)][_0x10b5f1(0x136)]({'errorMessage':_0x293a47(this[_0x10b5f1(0x11a)][_0x10b5f1(0xf9)],_0x10b5f1(0xed)),'id':_0x21caf7}),this[_0x10b5f1(0x197)](_0x1b1993)):_0x1b1993[_0x10b5f1(0x175)][_0x10b5f1(0x161)](_0x10b5f1(0x1c4))?(this[_0x10b5f1(0xb6)][_0x10b5f1(0x136)]({'errorMessage':_0x293a47(this[_0x10b5f1(0x11a)][_0x10b5f1(0xf9)],_0x10b5f1(0xe4)),'id':_0x21caf7}),this[_0x10b5f1(0x197)](_0x1b1993)):_0x1b1993[_0x10b5f1(0x175)][_0x10b5f1(0x161)](_0x10b5f1(0x9d))?(this[_0x10b5f1(0xb6)][_0x10b5f1(0x136)]({'errorMessage':_0x293a47(this[_0x10b5f1(0x11a)][_0x10b5f1(0xf9)],_0x10b5f1(0xf7)),'id':_0x21caf7}),this[_0x10b5f1(0x197)](_0x1b1993)):_0x1b1993[_0x10b5f1(0x175)][_0x10b5f1(0x161)](_0x10b5f1(0x196))?(this[_0x10b5f1(0xb6)][_0x10b5f1(0x136)]({'errorMessage':_0x293a47(this[_0x10b5f1(0x11a)][_0x10b5f1(0xf9)],_0x10b5f1(0xaf)),'id':_0x21caf7}),this[_0x10b5f1(0x197)](_0x1b1993)):(this[_0x10b5f1(0xb6)][_0x10b5f1(0x136)]({'errorMessage':_0x293a47(this[_0x10b5f1(0x11a)][_0x10b5f1(0xf9)],_0x10b5f1(0x97)),'id':_0x21caf7}),this[_0x10b5f1(0x197)](_0x1b1993));}),await this[_0x4a365e(0x1bf)][_0x4a365e(0x1ff)](this[_0x4a365e(0x11a)][_0x4a365e(0x156)][_0x4a365e(0x190)](_0x4a365e(0x193))),_0x21cd6e||await this[_0x4a365e(0x1bf)][_0x4a365e(0x113)]();}async[_0x32f9e9(0x1b4)]({userMessage:_0xe98774,quickActionData:_0x50136b}){const _0x20e20b=_0x32f9e9;if(!this[_0x20e20b(0x1bf)])throw new _0x4f662e(_0x20e20b(0x1c3));this[_0x20e20b(0x1bf)][_0x20e20b(0x1b1)]()&&await this[_0x20e20b(0x1bf)][_0x20e20b(0x185)](this[_0x20e20b(0x1b9)][_0x20e20b(0x1e7)]()),this[_0x20e20b(0x1bf)]['id']&&this[_0x20e20b(0x1bf)][_0x20e20b(0x200)]&&await this[_0x20e20b(0x1bf)][_0x20e20b(0xf2)]({'userMessage':_0xe98774,'quickActionData':_0x50136b}),this[_0x20e20b(0x150)]();}[_0x32f9e9(0x150)](){const _0x24d952=_0x32f9e9,_0x5dab0e=_0x2fb4d2(this[_0x24d952(0x11a)])[_0x24d952(0xfe)],_0x34dd6f=Array[_0x24d952(0x18a)](_0x5dab0e[_0x24d952(0x12c)][_0x24d952(0x96)](_0x4452cb));_0x5dab0e[_0x24d952(0x1a9)](_0x1f981d=>{const _0x4bb638=_0x24d952;_0x34dd6f[_0x4bb638(0x10b)](_0x3ca3d5=>_0x1f981d[_0x4bb638(0x13b)](_0x3ca3d5));});}[_0x32f9e9(0x1e3)](){const _0x3a1ebb=_0x32f9e9;console[_0x3a1ebb(0x171)](_0x3a1ebb(0x19b));}[_0x32f9e9(0x108)](_0x88cdbb){const _0x2dccf3=_0x32f9e9;this[_0x2dccf3(0xb6)][_0x2dccf3(0x122)](_0x88cdbb);}[_0x32f9e9(0x197)](_0x9e7b08){const _0x58384d=_0x32f9e9;_0x402656(_0x9e7b08[_0x58384d(0x175)]);}[_0x32f9e9(0xde)](_0x537c52){const _0x54b05c=_0x32f9e9;this[_0x54b05c(0x1bf)]?.[_0x54b05c(0x169)](_0x537c52);}[_0x32f9e9(0x172)](){const _0x3a5943=_0x32f9e9;this[_0x3a5943(0x1bf)]?.[_0x3a5943(0xe8)]();}[_0x32f9e9(0x194)](){const _0x42f6ea=_0x32f9e9;this[_0x42f6ea(0x1bf)]?.[_0x42f6ea(0x13f)]();}[_0x32f9e9(0x9f)](_0x4e0df3){const _0x3a7d1c=_0x32f9e9,[_0x3dae6b,_0x2d56eb]=_0x4e0df3[_0x3a7d1c(0x1fc)](':'),_0x51ee12=this[_0x3a7d1c(0x1bf)][_0x3a7d1c(0x1e0)](_0x3dae6b),_0x4a7349=_0x51ee12[_0x3a7d1c(0xfa)](_0x2d56eb);return{'interaction':_0x51ee12,'reply':_0x4a7349};}[_0x32f9e9(0x166)](_0x10888a,_0x1fbfaf=!0x1){const _0x36eed8=_0x32f9e9,_0x4e028a=_0x2fb4d2(this[_0x36eed8(0x11a)]),_0x3ef968={'target':_0x4e028a[_0x36eed8(0x143)][_0x36eed8(0x1a5)][_0x36eed8(0x125)][_0x36eed8(0x130)](_0x4e028a[_0x36eed8(0x143)][_0x36eed8(0x10f)][_0x36eed8(0xc2)](_0x10888a)),'viewportOffset':{'top':0x96,'left':0x0,'bottom':0x32,'right':0x0},'ancestorOffset':0x14,'alignToTop':_0x1fbfaf};_0x1fbfaf&&(_0x3ef968[_0x36eed8(0x178)]=!0x0),_0x4d71d9(_0x3ef968);}[_0x32f9e9(0x163)](_0x4b3ff2,_0x39d61f=!0x1){const _0x581714=_0x32f9e9;this[_0x581714(0xb6)][_0x581714(0x134)](_0x4b3ff2||_0x293a47(this[_0x581714(0x11a)][_0x581714(0xf9)],_0x581714(0x16f)),_0x39d61f);}async[_0x32f9e9(0x131)]({reply:_0x4df877,renderingStrategy:_0x44f19e}){const _0x26ce6b=_0x32f9e9,{id:_0x1cc209,isDone:_0x40c1e3,type:_0x521003,parsedContent:_0x11ad92}=_0x4df877;if(_0x26ce6b(0x1ca)===_0x521003){const _0x18007b=_0x4df877[_0x26ce6b(0x104)]({'showDiff':this[_0x26ce6b(0xb6)][_0x26ce6b(0x189)]});await this[_0x26ce6b(0xb6)][_0x26ce6b(0x1c8)]({'id':_0x1cc209,'parts':_0x18007b,'renderingStrategy':_0x44f19e,'isDone':_0x40c1e3});}else _0x26ce6b(0x1fd)===_0x521003&&await this[_0x26ce6b(0xb6)][_0x26ce6b(0x1fa)]({'id':_0x1cc209,'parsedContent':_0x11ad92,'renderingStrategy':_0x44f19e,'isDone':_0x40c1e3});_0x40c1e3&&_0x4df877[_0x26ce6b(0x1f5)][_0x26ce6b(0x1e1)]>0x0&&this[_0x26ce6b(0xb6)][_0x26ce6b(0x109)](_0x1cc209,_0x4df877[_0x26ce6b(0x1f5)]);}async[_0x32f9e9(0xfb)](){const _0x5b7d48=_0x32f9e9,_0x2c861f=this[_0x5b7d48(0x1bf)]?.[_0x5b7d48(0x15b)];_0x2c861f&&(_0x2c861f[_0x5b7d48(0xe3)](),this[_0x5b7d48(0xb6)][_0x5b7d48(0x1ed)](_0x2c861f));}async[_0x32f9e9(0xa9)](){const _0x136919=_0x32f9e9,_0x495e0a=this[_0x136919(0x1bf)]?.[_0x136919(0x15b)];if(_0x495e0a){for await(const _0x3106d6 of _0x495e0a[_0x136919(0x16c)])await this[_0x136919(0x131)]({'reply':_0x3106d6,'renderingStrategy':_0x136919(0xbb)});}}[_0x32f9e9(0x14a)](_0x26679c){const _0x24ace5=_0x32f9e9,_0x261638={'positiveCount':_0x26679c[_0x24ace5(0xab)][_0x24ace5(0xc7)](_0x543c59=>_0x24ace5(0xcc)===_0x543c59[_0x24ace5(0x132)])[_0x24ace5(0x1e1)],'totalCount':_0x26679c[_0x24ace5(0xab)][_0x24ace5(0x1e1)],'modificationId':_0x26679c['id']},_0x4c7703=this[_0x24ace5(0x1bf)][_0x24ace5(0x1e0)](_0x26679c[_0x24ace5(0x19c)])[_0x24ace5(0x1b2)];this[_0x24ace5(0x1c2)][_0x24ace5(0x15c)](this[_0x24ace5(0x1bf)]['id'],_0x4c7703,_0x261638);}}function _0x434b(){const _0x5a5eb6=['_removeAISelectionMarkers','isLoading','2295416KbjpeD','addFeedItemUserMessage','push','removeSelectionFromChatContext','config','addFeedItemAISuggestion','capabilitiesUpdated','pending','startConversation','lastInteraction','upsertAIChatRating','sourceId','setConversationContext','rejected','replyCreated','startsWith','clearConversationContextUI','updateConversationTitle','_handleStartConversation','changes','_scrollToSuggestionRange','plugins','applyOperation','removeFromContext','set','closeSourceResourceBalloon','replies','Undo','interactionStarted','AI_CHAT_UNTITLED_CONVERSATION','addUrlToContext','log','_toggleWebSearch','showNext','activateTab','message','options','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_FILE','alignToTop','_previewedChangeGroup','slice','selection','requires','isModelAvailable','streaming','interactionFinished','updateFeedItemAIReplySuggestionPartState','removed','reasoningFinished','version','type','updateCurrentDocumentInContext','_createFromRanges','getRoot','resetMessageInput','showDiff','from','setFeedItemRenderingStrategy','showPrevious','finishInteraction','AI_CHAT_CONTEXT_UNABLE_TO_LOAD_RESOURCES','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_URL','get','enableControls','316sWzidB','ai.chat.context','_toggleReasoning','unshift','ai-chat-context-form-data-size-limits-exceeded','_logError','maxOffset','selectModel','AIEditing','Showing\x20conversation\x20history...','interactionId','contextItemAdded','partIndex','getOperations','document','resizeTabs','resources','AITabs','disableControls','view','webSearchFinished','toggleLoadingSkeleton','batch','change','interactionCreated','root','isCurrentDocumentInConversation','contextItemLoadingEnded','close','children','loadSourceResources','isCurrentDocumentInContext','messageId','ai-chat-missing-channel-id','_handleUIUserMessage','getSelectionText','AI_CHAT_UNABLE_TO_LOAD_CONVERSATION','ai-request-aborted','listenTo','_aiEditing','has','documentContextContent','anchorId','cloneNode','getConversation','activeConversation','modelSelected','delete','_aiConnector','ai-chat-controller-no-active-conversation','ai-chat-context-file-too-large','getFirstRange','AIChatController','reasoningStarted','updateFeedItemAIReplySuggestionContent','interactionDestroyed','modification-delta','contextItemRemoved','focusPromptInput','removeFeedInteraction','howMany','full','8025237pJNRBL','showFakeVisualSelection','insertSuggestion','afterInit','hasChanges','ai-chat-resource-load-failed','contextSent','rootName','ready','getChildren','webSearchStarted','addFeedInteractionHeader','AI_CHAT_CONTEXT_UNSUPPORTED_TYPE','indexes','AI_CHAT_INVALID_REQUEST','ai-chat-url-upload-failed','getInteraction','length','_applySuggestion','_showConversationHistory','index','createConversation','ai-chat-conversation-not-found','getDocumentData','loadConversation','chat','_getDocumentRangeForReplyChanges','getChildAtOffset','isInContext','stopInteraction','path','setSelectedModel','updateContent','uid','addContextItem','AI_CHAT_ABORTED_MESSAGE','_integrateEditor','sources','replyChangeGroupStateUpdated','parse','addCurrentDocumentToContext','uiId','updateFeedItemAIReplyContent','abortPromptStream','split','text-delta','getChild','init','isStarted','getTransformedByOperation','setLoadingMessage','removeContextItem','getMarkersGroup','AI_CHAT_GENERIC_ERROR','undo','getRanges','sendMessage','dislike','toggleSuggestionDisplayMode','ai-chat-context-file-too-many-pages','isDisabled','getInteractionAndReplyById','ai.chat.models.defaultModelId','resizedTabs','find','AI_CHAT_CONTEXT_INVALID_DATA','mouseLeaveSuggestion','mouseOverSuggestion','addDocumentToContext','sourcePosition','history','_flushLastInteractionUI','resourceStateChanged','changeGroups','marker','remove','load','AI_CHAT_CONTEXT_FORM_DATA_SIZE_LIMITS_EXCEEDED','AIConnector','data','85558FTLPqO','baseVersion','toString','$graveyard','_aiChatUi','46974laPLzM','populateSourceResourceBalloon','TrackChangesEditing','conversationInitialized','static','AI_BALLOON_HEADER_TITLE','34372296ELWEYD','setIsUploadInProgress','Disliked\x20response','setModel','resource','toViewRange','contextItem','createPositionFromPath','uploadProgressChanged','stopListening','filter','addFilesToContext','addSelectionToContext','AI_CHAT_RESOURCE_LOAD_FAILED','ai-chat-context-unsupported-type','accepted','updateResourceState','ai.availableReplyActions','isPremiumPlugin','addContextOptionsChanged','315624kzTmMq','ai-chat-controller-mouse-over','updateCapabilities','replyContentUpdated','error','editors','Liked\x20response','getGroupId','ai-conversation-','content','redo','pluginName','_aiChatModels','_removeFromContext','replyId','like','findIndex','ai-chat-conversation-init-failed','stop','AI_CHAT_CONTEXT_FILE_TOO_LARGE','50AqFObq','rejectSuggestion','isUploadInProgress','toggleWebSearch','startAutoScroll','startInteraction','DocumentCompare','query','AI_CHAT_CONTEXT_UNSUPPORTED_FILE_TYPE','node','add','addOperation','ai-chat-source-resources-load-failed','handleUserInteraction','resourceId','removeSelectionFromContext','getDocumentContext','isOfficialPlugin','AI_CHAT_CONTEXT_FILE_TOO_MANY_PAGES','revert','locale','getReply','_stopLastInteraction','addSelectionToChatContext','sourceResourcesLoaded','model','addFeedItemStaticMessage','contextItems','getDiff','addFeedItemAIReply','resize','getContentParts','indexOf','clearPendingContextUI','AI_CHAT_CONTEXT_CURRENT_DOCUMENT','_setIsMaximized','updateFeedItemAIReplySources','open','forEach','setAddContextOptions','scrollFeedToSuggestion','5eojETa','mapper','_openBalloonFor','createRange','_balloonShowDiff','start','map','ai-chat-context-invalid-data','ai-chat-invalid-request','_batchToChanges','fetchConversation','source','context','ai-chat-context-unsupported-file-type','createPositionAt','main','isDocumentOperation','_applyOperationsAsSuggestions','dialogClosed','nextSibling','setIsMaximized','ai.chat.models.displayedModels','43629UlkHEo','domConverter','ai-chat-file-upload-failed','addResourceToContext','range','AI_CHAT_UNABLE_TO_START_CONVERSATION','setContextItemLoading','7AtcLEz','markers','AIChatUI','commands','addFileToContext','viewRangeToDom','_updateReplyContent','state','80crgjri','setConversationTitle','getAttribute','addFeedItemError','ai-no-track-changes','collaboration.channelId','sendUserMessage','outdated','removeMarker','new','end','isOpen','toggleReasoning','resetConversationTitle','getPath','handleRemovedConversation','editing','hideFakeVisualSelection','showChangeInText','ai-chat-conversation-start-failed','applySuggestion','_insertSuggestion','_startConversationSafely','_updateRatings','TrackChanges','selectedModel','setChangeGroupState','current-document','data-id'];_0x434b=function(){return _0x5a5eb6;};return _0x434b();}
|
package/src/aichat/aichatui.js
CHANGED
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const _0x20bb56=_0x505e;function _0x505e(_0x479c1a,_0x409360){const _0x525887=_0x5258();return _0x505e=function(_0x505e62,_0x42d0fd){_0x505e62=_0x505e62-0x12e;let _0x382a38=_0x525887[_0x505e62];return _0x382a38;},_0x505e(_0x479c1a,_0x409360);}function _0x5258(){const _0x5f3b38=['_interactionPromiseResolver','areActionsDisabled','4314150tElMuc','populateSourceResourceBalloon','streaming','interactionId','setFeedItemRenderingStrategy','scrollToSuggestion','_promiseQueue','isLoading','stopInteraction','AI_CHAT_FEED_LOADING_MESSAGE_REASONING','_getLoadingMessage','addFeedItemUserMessage','setContextItemLoading','forEach','removeFeedInteraction','addFeedInteractionHeader','setIsUploadInProgress','_getInputPlaceholder','last','clearPendingContextUI','AI_CHAT_WELCOME_MESSAGE','ai.availableReplyActions','length','removeContextItem','destroy','_animateConversationTitle','14724XVhdyT','conversation-start','isMaximized','88jMWlUF','config','chat','setLoadingMessage','view','feedItemRenderingStrategy','insertSuggestion','updateWebSources','_view','toggleSuggestionDisplayMode','ai-reply','resetMessageInput','setAddContextOptions','updateFeedInteractionHeader','updateSuggestionPartState','closeSourceResourceBalloon','setInputPlaceholder','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH','values','delegate','remove','addFeedItemAIReply','startAutoScroll','disableModelSelector','setConversationContext','updateFeedItemAIReplyContent','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH_REASONING','clear','1516419ivXSak','interaction-header','set','startInteraction','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH','markFeedItemAsDone','5189268qmledL','isModelAvailable','isWebSearchEnabled','userMessage','AI_CHAT_FEED_LOADING_MESSAGE_REGULAR','isReasoningEnabled','trackChanges','scrollFeedToSuggestion','</p>','children','label','has','isTrackChangesOn','showDiff','addFeedItemError','user-message','addTab','pluginName','chatHeader','quickActionData','showResizeButton','capabilities','value','isDone','displayedPrompt','AI_CHAT_HEADING','updateFeedItemAIReplySuggestionPartState','isPremiumPlugin','isDisabled','queueEmptyPromise','stopAutoScroll','bind','TrackChanges','setReasoning','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REASONING','commands','<p>','setSelectedModel','setWebSearch','resetConversationTitle','addFeedItemStaticMessage','updateCapabilities','655TWpgtL','locale','focusPromptInput','contextItems','options','isPending','setModelList','121155ZwzXEz','isVisible','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH_REASONING','addFeedItemAISuggestion','find','markItemAsDone','setModel','filter','disableControls','enableModelSelector','chatFeed','createConversation','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REGULAR','chatControls','plugins','addItem','finishInteraction','3293900Hltciv','AIChatUI','isOfficialPlugin','availableModels','error-message','removeItem','updateFeedItemAIReplySuggestionContent','_isTrackChangesCommandValueBound','AITabs','renderingStrategy','toggleLoadingSkeleton','ai-suggestion-reply','updateResourceState','168881kokTMx','setConversationTitle','ai.chat.models.modelSelectorAlwaysVisible','requires','updateReplyItem','startsWith','ai.chat.context.searchInputVisibleFrom','6OJkqeC','get','context','8OoTzSP','enableControls','isBusy','clearConversationContextUI','then','updateSuggestionItem','from','enqueue','_titleAnimationInterval','getItemIds','abort','setIsMaximized','updateFeedItemAIReplySources','addContextItem'];_0x5258=function(){return _0x5f3b38;};return _0x5258();}(function(_0x1a7ab7,_0x452ffd){const _0x31d71a=_0x505e,_0x3bfb4a=_0x1a7ab7();while(!![]){try{const _0x196694=-parseInt(_0x31d71a(0x185))/0x1*(parseInt(_0x31d71a(0x18c))/0x2)+parseInt(_0x31d71a(0x167))/0x3+parseInt(_0x31d71a(0x1b9))/0x4*(-parseInt(_0x31d71a(0x160))/0x5)+-parseInt(_0x31d71a(0x19f))/0x6+-parseInt(_0x31d71a(0x136))/0x7+-parseInt(_0x31d71a(0x18f))/0x8*(-parseInt(_0x31d71a(0x130))/0x9)+parseInt(_0x31d71a(0x178))/0xa*(parseInt(_0x31d71a(0x1bc))/0xb);if(_0x196694===_0x452ffd)break;else _0x3bfb4a['push'](_0x3bfb4a['shift']());}catch(_0x12ada4){_0x3bfb4a['push'](_0x3bfb4a['shift']());}}}(_0x5258,0x60629));import{ContextPlugin as _0x25ff34}from'ckeditor5/src/core.js';import{_isMotionReduced as _0x52e168}from'ckeditor5/src/utils.js';import{AIChatView as _0x49cec3}from'./ui/aichatview.js';import{AITabs as _0x5265e0}from'../aitabs/aitabs.js';import{getTranslation as _0x45c9d6}from'../aicore/utils/common-translations.js';import{IconAIChat as _0x22c53c}from'ckeditor5/src/icons.js';import{AIChatFeedInteractionHeaderView as _0x1530dc}from'./ui/feed/aichatfeedinteractionheaderview.js';import{PromiseQueue as _0x2949d2}from'./utils/promisequeue.js';import{AI_CHAT_UI_EVENT_NAMES as _0x4d811d}from'./utils/eventnames.js';import'../../theme/aichat/aichat.css';import{getEditorFromContext as _0x334a5a}from'../aicore/utils/geteditorfromcontext.js';import{AI_REPLY_ACTIONS as _0x1011f5}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';export class AIChatUI extends _0x25ff34{static get[_0x20bb56(0x188)](){return[_0x5265e0];}[_0x20bb56(0x1c4)];static get[_0x20bb56(0x147)](){const _0x3626b2=_0x20bb56;return _0x3626b2(0x179);}static get[_0x20bb56(0x17a)](){return!0x0;}static get[_0x20bb56(0x151)](){return!0x0;}[_0x20bb56(0x1c1)]=_0x20bb56(0x1a1);[_0x20bb56(0x143)]=!0x0;[_0x20bb56(0x1a5)];[_0x20bb56(0x19d)];[_0x20bb56(0x197)]=void 0x0;[_0x20bb56(0x17f)]=!0x1;constructor(_0x4242ee){const _0x4fb6f1=_0x20bb56;super(_0x4242ee);const _0xb6479c=this[_0x4fb6f1(0x18e)][_0x4fb6f1(0x175)][_0x4fb6f1(0x18d)](_0x4fb6f1(0x180));this[_0x4fb6f1(0x132)](_0x4fb6f1(0x191),!0x1),this[_0x4fb6f1(0x1a5)]=new _0x2949d2(),this[_0x4fb6f1(0x1c4)]=new _0x49cec3(this[_0x4fb6f1(0x18e)][_0x4fb6f1(0x161)],{'showResizeButton':_0xb6479c[_0x4fb6f1(0x14a)],'contextResourcesSearchInputVisibleFrom':this[_0x4fb6f1(0x18e)][_0x4fb6f1(0x1bd)][_0x4fb6f1(0x18d)](_0x4fb6f1(0x18b))}),this[_0x4fb6f1(0x1c4)][_0x4fb6f1(0x1cf)](..._0x4d811d)['to'](this),this[_0x4fb6f1(0x1c4)]['on'](_0x4fb6f1(0x1c5),(_0x48135f,{showDiff:_0x664736})=>{const _0x177666=_0x4fb6f1;this[_0x177666(0x143)]=_0x664736;}),_0xb6479c[_0x4fb6f1(0x1c0)][_0x4fb6f1(0x146)]({'id':_0x4fb6f1(0x1be),'buttonLabel':_0x45c9d6(this[_0x4fb6f1(0x18e)][_0x4fb6f1(0x161)],_0x4fb6f1(0x14f)),'buttonIcon':_0x22c53c,'order':0x0,'content':this[_0x4fb6f1(0x1c4)]}),this[_0x4fb6f1(0x1c4)][_0x4fb6f1(0x174)][_0x4fb6f1(0x155)](_0x4fb6f1(0x1a6))['to'](this,_0x4fb6f1(0x191),_0x344481=>_0x344481),this[_0x4fb6f1(0x1c4)][_0x4fb6f1(0x171)][_0x4fb6f1(0x155)](_0x4fb6f1(0x165))['to'](this,_0x4fb6f1(0x191),_0x3278a0=>_0x3278a0),this[_0x4fb6f1(0x1c4)][_0x4fb6f1(0x174)][_0x4fb6f1(0x1cc)](this[_0x4fb6f1(0x1b0)]()),this[_0x4fb6f1(0x155)](_0x4fb6f1(0x137))['to'](this[_0x4fb6f1(0x1c4)][_0x4fb6f1(0x174)],_0x4fb6f1(0x137));}[_0x20bb56(0x1b7)](){const _0x3eb909=_0x20bb56;super[_0x3eb909(0x1b7)](),this[_0x3eb909(0x197)]&&clearInterval(this[_0x3eb909(0x197)]);}[_0x20bb56(0x172)](_0x1812a0){const _0x1fc1ee=_0x20bb56;this[_0x1fc1ee(0x1c4)][_0x1fc1ee(0x171)][_0x1fc1ee(0x12f)](),this[_0x1fc1ee(0x1c4)][_0x1fc1ee(0x174)][_0x1fc1ee(0x170)](),this[_0x1fc1ee(0x1c4)][_0x1fc1ee(0x174)][_0x1fc1ee(0x166)](_0x1812a0[_0x1fc1ee(0x17b)],!this[_0x1fc1ee(0x18e)][_0x1fc1ee(0x1bd)][_0x1fc1ee(0x18d)](_0x1fc1ee(0x187))),this[_0x1fc1ee(0x15e)]({'id':_0x1fc1ee(0x1ba),'staticMessage':_0x45c9d6(this[_0x1fc1ee(0x18e)][_0x1fc1ee(0x161)],_0x1fc1ee(0x1b3))});}[_0x20bb56(0x15e)]({id:_0x433e3e,staticMessage:_0x892ec5}){const _0x1e8de6=_0x20bb56;this[_0x1e8de6(0x1c4)][_0x1e8de6(0x171)][_0x1e8de6(0x176)](_0x1e8de6(0x1c6),{'id':_0x433e3e,'initialContent':_0x1e8de6(0x15a)+_0x892ec5+_0x1e8de6(0x13e)});}[_0x20bb56(0x1aa)](_0x94e623){const _0x281fe0=_0x20bb56,_0x262eb2=_0x94e623[_0x281fe0(0x149)]?.[_0x281fe0(0x14e)]||_0x94e623[_0x281fe0(0x139)];this[_0x281fe0(0x1c4)][_0x281fe0(0x171)][_0x281fe0(0x176)](_0x281fe0(0x145),{'contextItems':Array[_0x281fe0(0x195)](_0x94e623[_0x281fe0(0x163)][_0x281fe0(0x1ce)]()),'initialContent':_0x281fe0(0x15a)+_0x262eb2+_0x281fe0(0x13e),'id':_0x94e623['id']});}[_0x20bb56(0x144)]({errorMessage:_0xfeba6d,id:_0x251383}){const _0x163a22=_0x20bb56;this[_0x163a22(0x1c4)][_0x163a22(0x171)][_0x163a22(0x176)](_0x163a22(0x17c),{'initialContent':_0x163a22(0x15a)+_0xfeba6d+_0x163a22(0x13e),'id':_0x251383});}[_0x20bb56(0x1d1)](_0x468de0){const _0x104b31=_0x20bb56;return this[_0x104b31(0x1a5)][_0x104b31(0x196)](async()=>{const _0x137744=_0x104b31;this[_0x137744(0x1c4)][_0x137744(0x171)][_0x137744(0x176)](_0x137744(0x1c6),{'id':_0x468de0[_0x137744(0x1a2)]+':'+_0x468de0['id']}),this[_0x137744(0x1bf)](null);});}async[_0x20bb56(0x16a)](_0x327d48){const _0x17c5ae=_0x20bb56,_0xb05434=_0x334a5a(this[_0x17c5ae(0x18e)]);let _0x877f21=_0xb05434[_0x17c5ae(0x1bd)][_0x17c5ae(0x18d)](_0x17c5ae(0x1b4))||[..._0x1011f5];if(_0xb05434[_0x17c5ae(0x175)][_0x17c5ae(0x141)](_0x17c5ae(0x156))){if(!this[_0x17c5ae(0x17f)]){this[_0x17c5ae(0x17f)]=!0x0;const _0xb8fd49=_0xb05434[_0x17c5ae(0x159)][_0x17c5ae(0x18d)](_0x17c5ae(0x13c));this[_0x17c5ae(0x1c4)][_0x17c5ae(0x171)][_0x17c5ae(0x155)](_0x17c5ae(0x142))['to'](_0xb8fd49,_0x17c5ae(0x14c));}}else _0x877f21=_0x877f21[_0x17c5ae(0x16e)](_0x553ad4=>_0x17c5ae(0x1c2)!=_0x553ad4);return this[_0x17c5ae(0x1a5)][_0x17c5ae(0x196)](async()=>{const _0x4467fb=_0x17c5ae;this[_0x4467fb(0x1c4)][_0x4467fb(0x171)][_0x4467fb(0x176)](_0x4467fb(0x183),{'id':_0x327d48[_0x4467fb(0x1a2)]+':'+_0x327d48['id'],'areActionsDisabled':_0x327d48[_0x4467fb(0x19e)],'showDiff':this[_0x4467fb(0x143)],'availableActions':_0x877f21}),this[_0x4467fb(0x1bf)](null);});}[_0x20bb56(0x1ae)](_0x8f22df,_0x290588){const _0x35fb6b=_0x20bb56,_0x2907bb=this[_0x35fb6b(0x1c4)][_0x35fb6b(0x171)][_0x35fb6b(0x13f)][_0x35fb6b(0x1b1)];if(_0x2907bb instanceof _0x1530dc)return this[_0x35fb6b(0x1c4)][_0x35fb6b(0x171)][_0x35fb6b(0x13f)][_0x35fb6b(0x1d0)](_0x2907bb),void this[_0x35fb6b(0x1c4)][_0x35fb6b(0x171)][_0x35fb6b(0x176)](_0x35fb6b(0x131),{'id':_0x8f22df['id'],'capabilities':{'isWebSearchEnabled':_0x2907bb[_0x35fb6b(0x14b)][_0x35fb6b(0x138)]||_0x290588[_0x35fb6b(0x138)],'isReasoningEnabled':_0x2907bb[_0x35fb6b(0x14b)][_0x35fb6b(0x13b)]||_0x290588[_0x35fb6b(0x13b)]}});this[_0x35fb6b(0x1c4)][_0x35fb6b(0x171)][_0x35fb6b(0x176)](_0x35fb6b(0x131),{'id':_0x8f22df['id'],'capabilities':_0x290588});}[_0x20bb56(0x1c9)](_0x3981d3){const _0x535cb6=_0x20bb56,_0x57063c=this[_0x535cb6(0x1c4)][_0x535cb6(0x171)][_0x535cb6(0x13f)][_0x535cb6(0x16b)](_0x512ac1=>_0x512ac1[_0x535cb6(0x164)]['id']==_0x3981d3['id']&&_0x512ac1 instanceof _0x1530dc);_0x57063c&&_0x57063c[_0x535cb6(0x132)](_0x535cb6(0x168),_0x3981d3[_0x535cb6(0x168)]);}async[_0x20bb56(0x1d5)](_0x46da36){const _0x5128e8=_0x20bb56,_0x697156=_0x46da36[_0x5128e8(0x181)]||this[_0x5128e8(0x1c1)];return this[_0x5128e8(0x1a5)][_0x5128e8(0x196)](async _0x5c0420=>{const _0x8fbf4=_0x5128e8;await this[_0x8fbf4(0x1c4)][_0x8fbf4(0x171)][_0x8fbf4(0x189)]({..._0x46da36,'abortSignal':_0x5c0420,'renderingStrategy':_0x697156}),_0x46da36[_0x8fbf4(0x14d)]&&this[_0x8fbf4(0x135)](_0x46da36['id']);});}[_0x20bb56(0x19b)](_0x5749c8,_0x28620d){const _0x28ac0f=_0x20bb56;this[_0x28ac0f(0x1c4)][_0x28ac0f(0x171)][_0x28ac0f(0x1c3)](_0x5749c8,_0x28620d);}async[_0x20bb56(0x17e)](_0x5b434f){const _0x33e2b7=_0x20bb56,_0x491746=_0x5b434f[_0x33e2b7(0x181)]||this[_0x33e2b7(0x1c1)];return this[_0x33e2b7(0x1a5)][_0x33e2b7(0x196)](async _0x3cfd4d=>{const _0x146473=_0x33e2b7;await this[_0x146473(0x1c4)][_0x146473(0x171)][_0x146473(0x194)]({..._0x5b434f,'abortSignal':_0x3cfd4d,'renderingStrategy':_0x491746}),_0x5b434f[_0x146473(0x14d)]&&this[_0x146473(0x135)](_0x5b434f['id']);});}[_0x20bb56(0x150)](_0x45e0db){const _0x51e2c2=_0x20bb56;this[_0x51e2c2(0x1c4)][_0x51e2c2(0x171)][_0x51e2c2(0x1ca)](_0x45e0db);}[_0x20bb56(0x135)](_0x142f72){const _0x126656=_0x20bb56;this[_0x126656(0x1c4)][_0x126656(0x171)][_0x126656(0x16c)](_0x142f72);}[_0x20bb56(0x1ad)](_0x422bc0){const _0x39c38b=_0x20bb56;this[_0x39c38b(0x1c4)][_0x39c38b(0x171)][_0x39c38b(0x198)]()[_0x39c38b(0x16e)](_0x47d875=>_0x47d875[_0x39c38b(0x18a)](_0x422bc0))[_0x39c38b(0x1ac)](_0x2cd652=>this[_0x39c38b(0x1c4)][_0x39c38b(0x171)][_0x39c38b(0x17d)](_0x2cd652));}[_0x20bb56(0x133)](){const _0x5d5a38=_0x20bb56;this[_0x5d5a38(0x1bf)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x1}),this[_0x5d5a38(0x1c4)][_0x5d5a38(0x174)][_0x5d5a38(0x1d3)](!this[_0x5d5a38(0x18e)][_0x5d5a38(0x1bd)][_0x5d5a38(0x18d)](_0x5d5a38(0x187))),this[_0x5d5a38(0x191)]=!0x0,this[_0x5d5a38(0x1c4)][_0x5d5a38(0x171)][_0x5d5a38(0x1d2)]();}[_0x20bb56(0x1a7)](_0x41c39d){const _0x4eac0e=_0x20bb56;this[_0x4eac0e(0x1a5)][_0x4eac0e(0x199)](),this[_0x4eac0e(0x1c4)][_0x4eac0e(0x171)][_0x4eac0e(0x198)]()[_0x4eac0e(0x16e)](_0x32b9c8=>_0x32b9c8[_0x4eac0e(0x18a)](_0x41c39d['id']))[_0x4eac0e(0x1ac)](_0x41b1be=>this[_0x4eac0e(0x135)](_0x41b1be)),this[_0x4eac0e(0x191)]=!0x1,this[_0x4eac0e(0x1c4)][_0x4eac0e(0x171)][_0x4eac0e(0x154)]();}async[_0x20bb56(0x177)](){const _0x2ce2eb=_0x20bb56;return this[_0x2ce2eb(0x1a5)][_0x2ce2eb(0x153)][_0x2ce2eb(0x193)](()=>{const _0x4ca036=_0x2ce2eb;this[_0x4ca036(0x191)]=!0x1,this[_0x4ca036(0x1c4)][_0x4ca036(0x171)][_0x4ca036(0x154)]();});}[_0x20bb56(0x19c)](_0x4ca866,_0x26a2db){const _0x342c18=_0x20bb56;this[_0x342c18(0x1c4)][_0x342c18(0x174)][_0x342c18(0x19c)](_0x4ca866,_0x26a2db);}[_0x20bb56(0x1b6)](_0x1b4ebb){const _0x5ce19f=_0x20bb56;this[_0x5ce19f(0x1c4)][_0x5ce19f(0x174)][_0x5ce19f(0x1b6)](_0x1b4ebb);}[_0x20bb56(0x1ab)](_0x58f8af,_0x495bc2){const _0x190860=_0x20bb56;this[_0x190860(0x1c4)][_0x190860(0x174)][_0x190860(0x1ab)](_0x58f8af,_0x495bc2);}[_0x20bb56(0x1af)](_0x3a97a3){const _0x1adf57=_0x20bb56;this[_0x1adf57(0x1c4)][_0x1adf57(0x174)][_0x1adf57(0x1af)](_0x3a97a3);}[_0x20bb56(0x1d4)](_0x54da62){const _0x392add=_0x20bb56;this[_0x392add(0x1c4)][_0x392add(0x174)][_0x392add(0x1d4)](_0x54da62);}[_0x20bb56(0x1b2)](){const _0x826b6b=_0x20bb56;this[_0x826b6b(0x1c4)][_0x826b6b(0x174)][_0x826b6b(0x1b2)]();}[_0x20bb56(0x192)](){const _0xaf8c20=_0x20bb56;this[_0xaf8c20(0x1c4)][_0xaf8c20(0x174)][_0xaf8c20(0x192)]();}[_0x20bb56(0x184)](_0x2374ae,_0x555357,_0x2f4d04){const _0x38b663=_0x20bb56;this[_0x38b663(0x1c4)][_0x38b663(0x174)][_0x38b663(0x184)](_0x2374ae,_0x555357,_0x2f4d04);}[_0x20bb56(0x1c7)](){const _0x4a6e55=_0x20bb56;this[_0x4a6e55(0x1c4)][_0x4a6e55(0x174)][_0x4a6e55(0x1c7)](),this[_0x4a6e55(0x1c4)][_0x4a6e55(0x174)][_0x4a6e55(0x1cc)](this[_0x4a6e55(0x1b0)]());}[_0x20bb56(0x1c8)](_0x12a690){const _0x5d063d=_0x20bb56;this[_0x5d063d(0x1c4)][_0x5d063d(0x174)][_0x5d063d(0x1c8)](_0x12a690);}[_0x20bb56(0x15f)](_0x36d572){const _0x70a8c1=_0x20bb56;this[_0x70a8c1(0x1c4)][_0x70a8c1(0x174)][_0x70a8c1(0x15c)](_0x36d572[_0x70a8c1(0x138)]),this[_0x70a8c1(0x1c4)][_0x70a8c1(0x174)][_0x70a8c1(0x157)](_0x36d572[_0x70a8c1(0x13b)]),this[_0x70a8c1(0x1c4)][_0x70a8c1(0x174)][_0x70a8c1(0x1cc)](this[_0x70a8c1(0x1b0)](_0x36d572));}[_0x20bb56(0x15b)](_0x4ac1a3,_0x1e8262){const _0x411d67=_0x20bb56;this[_0x411d67(0x1c4)][_0x411d67(0x174)][_0x411d67(0x16d)](_0x4ac1a3),_0x1e8262&&this[_0x411d67(0x1c4)][_0x411d67(0x174)][_0x411d67(0x1d3)](!0x1);}[_0x20bb56(0x1a3)](_0x1016a3){const _0x3b346d=_0x20bb56;this[_0x3b346d(0x1c1)]=_0x1016a3;}[_0x20bb56(0x182)](_0x5dbf77){const _0x54e18d=_0x20bb56;this[_0x54e18d(0x1c4)][_0x54e18d(0x171)][_0x54e18d(0x182)](_0x5dbf77);}[_0x20bb56(0x15d)](){const _0x2cb1d7=_0x20bb56;this[_0x2cb1d7(0x186)](_0x45c9d6(this[_0x2cb1d7(0x18e)][_0x2cb1d7(0x161)],_0x2cb1d7(0x14f)));}[_0x20bb56(0x186)](_0x443160,_0x5596a9=!0x1){const _0x596544=_0x20bb56;if(_0x5596a9&&!_0x52e168()&&_0x443160[_0x596544(0x1b5)])return this[_0x596544(0x1c4)][_0x596544(0x148)][_0x596544(0x140)]='',void this[_0x596544(0x1b8)](_0x443160);this[_0x596544(0x1c4)][_0x596544(0x148)][_0x596544(0x140)]=_0x443160;}[_0x20bb56(0x1bf)](_0x38aa60){const _0x1fc7f3=_0x20bb56,_0x2707d2=this[_0x1fc7f3(0x1a9)](_0x38aa60);this[_0x1fc7f3(0x1c4)][_0x1fc7f3(0x171)][_0x1fc7f3(0x1bf)](_0x2707d2);}[_0x20bb56(0x1b8)](_0xe309a6){const _0x1d52c0=_0x20bb56;let _0x461e03=0x0;clearInterval(this[_0x1d52c0(0x197)]),this[_0x1d52c0(0x197)]=setInterval(()=>{const _0x13a8c6=_0x1d52c0;this[_0x13a8c6(0x1c4)][_0x13a8c6(0x148)][_0x13a8c6(0x140)]=this[_0x13a8c6(0x1c4)][_0x13a8c6(0x148)][_0x13a8c6(0x140)]+_0xe309a6[_0x461e03],_0x461e03++,_0x461e03===_0xe309a6[_0x13a8c6(0x1b5)]&&clearInterval(this[_0x13a8c6(0x197)]);},0x1e);}[_0x20bb56(0x19a)](_0xd4fbaf){const _0x4103ac=_0x20bb56;this[_0x4103ac(0x1c4)][_0x4103ac(0x148)][_0x4103ac(0x1bb)]=_0xd4fbaf;}[_0x20bb56(0x1a9)](_0x515e9d){const _0x19fb40=_0x20bb56;return _0x515e9d?_0x515e9d[_0x19fb40(0x138)]&&_0x515e9d[_0x19fb40(0x13b)]?_0x45c9d6(this[_0x19fb40(0x18e)][_0x19fb40(0x161)],_0x19fb40(0x12e)):_0x515e9d[_0x19fb40(0x138)]?_0x45c9d6(this[_0x19fb40(0x18e)][_0x19fb40(0x161)],_0x19fb40(0x134)):_0x515e9d[_0x19fb40(0x13b)]?_0x45c9d6(this[_0x19fb40(0x18e)][_0x19fb40(0x161)],_0x19fb40(0x1a8)):_0x45c9d6(this[_0x19fb40(0x18e)][_0x19fb40(0x161)],_0x19fb40(0x13a)):'';}[_0x20bb56(0x1b0)](_0x2b72c8){const _0x4d8362=_0x20bb56;return _0x2b72c8?_0x2b72c8[_0x4d8362(0x138)]&&_0x2b72c8[_0x4d8362(0x13b)]?_0x45c9d6(this[_0x4d8362(0x18e)][_0x4d8362(0x161)],_0x4d8362(0x169)):_0x2b72c8[_0x4d8362(0x138)]?_0x45c9d6(this[_0x4d8362(0x18e)][_0x4d8362(0x161)],_0x4d8362(0x1cd)):_0x2b72c8[_0x4d8362(0x13b)]?_0x45c9d6(this[_0x4d8362(0x18e)][_0x4d8362(0x161)],_0x4d8362(0x158)):_0x45c9d6(this[_0x4d8362(0x18e)][_0x4d8362(0x161)],_0x4d8362(0x173)):_0x45c9d6(this[_0x4d8362(0x18e)][_0x4d8362(0x161)],_0x4d8362(0x173));}[_0x20bb56(0x1a0)](_0xcdd90,_0x168cdc,_0x1cd633,_0x244b32){const _0x11c6aa=_0x20bb56;this[_0x11c6aa(0x1c4)][_0x11c6aa(0x1a0)](_0xcdd90,_0x168cdc,_0x1cd633,_0x244b32);}[_0x20bb56(0x1cb)](_0x27d383){const _0x218861=_0x20bb56;this[_0x218861(0x1c4)][_0x218861(0x1cb)](_0x27d383);}[_0x20bb56(0x162)](){const _0x2785f2=_0x20bb56;this[_0x2785f2(0x1c4)][_0x2785f2(0x174)][_0x2785f2(0x162)]();}[_0x20bb56(0x13d)](_0x5a147a,_0x4689b4){const _0x3490a3=_0x20bb56;this[_0x3490a3(0x1c4)][_0x3490a3(0x171)][_0x3490a3(0x1a4)](_0x5a147a,_0x4689b4);}[_0x20bb56(0x1d2)](){const _0xda573=_0x20bb56;this[_0xda573(0x1c4)][_0xda573(0x171)][_0xda573(0x1d2)]();}[_0x20bb56(0x16f)](){const _0x16fe8d=_0x20bb56;this[_0x16fe8d(0x1c4)][_0x16fe8d(0x174)][_0x16fe8d(0x152)]=!0x0;}[_0x20bb56(0x190)](){const _0x1043a1=_0x20bb56;this[_0x1043a1(0x1c4)][_0x1043a1(0x174)][_0x1043a1(0x152)]=!0x1;}}
|
|
23
|
+
const _0x2dbc2b=_0x5a3f;(function(_0x33d7a8,_0xb311bd){const _0x1acae1=_0x5a3f,_0x136551=_0x33d7a8();while(!![]){try{const _0x45e577=-parseInt(_0x1acae1(0x203))/0x1*(parseInt(_0x1acae1(0x192))/0x2)+-parseInt(_0x1acae1(0x172))/0x3*(parseInt(_0x1acae1(0x1d1))/0x4)+parseInt(_0x1acae1(0x1f5))/0x5+-parseInt(_0x1acae1(0x17d))/0x6*(parseInt(_0x1acae1(0x1b1))/0x7)+parseInt(_0x1acae1(0x1d0))/0x8*(parseInt(_0x1acae1(0x1dd))/0x9)+-parseInt(_0x1acae1(0x1a0))/0xa*(parseInt(_0x1acae1(0x179))/0xb)+parseInt(_0x1acae1(0x166))/0xc*(parseInt(_0x1acae1(0x1c9))/0xd);if(_0x45e577===_0xb311bd)break;else _0x136551['push'](_0x136551['shift']());}catch(_0x4c9ab4){_0x136551['push'](_0x136551['shift']());}}}(_0x4bbb,0xd92e6));import{ContextPlugin as _0x45d7cd}from'ckeditor5/src/core.js';import{_isMotionReduced as _0x28d2fa}from'ckeditor5/src/utils.js';import{AIChatView as _0x1e4a78}from'./ui/aichatview.js';import{AITabs as _0x42f081}from'../aitabs/aitabs.js';import{getTranslation as _0x515d47}from'../aicore/utils/common-translations.js';import{IconAIChat as _0x96cb73}from'ckeditor5/src/icons.js';function _0x5a3f(_0xb185d7,_0x148dca){const _0x4bbb14=_0x4bbb();return _0x5a3f=function(_0x5a3f6b,_0x1ef179){_0x5a3f6b=_0x5a3f6b-0x162;let _0x9702d6=_0x4bbb14[_0x5a3f6b];return _0x9702d6;},_0x5a3f(_0xb185d7,_0x148dca);}import{AIChatFeedInteractionHeaderView as _0x2a5d2f}from'./ui/feed/aichatfeedinteractionheaderview.js';import{PromiseQueue as _0x8cc8de}from'./utils/promisequeue.js';function _0x4bbb(){const _0x22f2a8=['delegate','toggleLoadingSkeleton','startAutoScroll','chatControls','focusPromptInput','updateSuggestionItem','value','then','markFeedItemAsDone','ai-suggestion-reply','isOfficialPlugin','90toNOFF','addFeedInteractionHeader','_titleAnimationInterval','setModel','isWebSearchEnabled','_animateConversationTitle','find','conversation-start','get','_getLoadingMessage','AI_CHAT_WELCOME_MESSAGE','updateFeedItemAIReplySuggestionContent','showResizeButton','AI_CHAT_FEED_LOADING_MESSAGE_REGULAR','1590QtMEHT','plugins','queueEmptyPromise','availableModels','startsWith','resetMessageInput','remove','populateSourceResourceBalloon','stopInteraction','disableModelSelector','setReasoning','last','isModelAvailable','addFeedItemAIReply','enableControls','clearPendingContextUI','addFeedItemAISuggestion','7jQWFZh','destroy','_view','from','removeItem','setModelList','updateFeedItemAIReplySources','startInteraction','chatHeader','removeContextItem','TrackChanges','updateReplyItem','ai.availableReplyActions','showDiff','getItemIds','bind','displayedPrompt','AIChatUI','scrollFeedToSuggestion','config','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH_REASONING','pluginName','addFeedItemError','ai-reply','50024QCKubv','createConversation','context','setAddContextOptions','removeFeedInteraction','clearConversationContextUI','error-message','1484968KAOzkW','80488lCXqwg','interaction-header','contextItems','isTrackChangesOn','setSelectedModel','chatFeed','updateSuggestionPartState','capabilities','AITabs','commands','children','quickActionData','9hXaflt','scrollToSuggestion','<p>','addItem','_getInputPlaceholder','isLoading','finishInteraction','forEach','isDisabled','isPending','addFeedItemUserMessage','updateFeedItemAIReplySuggestionPartState','setIsMaximized','isVisible','enqueue','setConversationContext','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REGULAR','abort','requires','disableControls','updateWebSources','updateFeedInteractionHeader','has','setLoadingMessage','4509985KbsYhX','updateCapabilities','renderingStrategy','clear','setWebSearch','stopAutoScroll','isMaximized','options','areActionsDisabled','updateFeedItemAIReplyContent','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH','AI_CHAT_HEADING','updateResourceState','setConversationTitle','26669uvfTkk','user-message','_promiseQueue','filter','setIsUploadInProgress','streaming','length','closeSourceResourceBalloon','_interactionPromiseResolver','addFeedItemStaticMessage','isPremiumPlugin','chat','markItemAsDone','7800bqVHsU','interactionId','AI_CHAT_FEED_LOADING_MESSAGE_REASONING','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH_REASONING','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH','ai.chat.models.modelSelectorAlwaysVisible','label','</p>','toggleSuggestionDisplayMode','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REASONING','locale','view','87NIXekK','userMessage','setContextItemLoading','isDone','feedItemRenderingStrategy','ai.chat.context.searchInputVisibleFrom','isBusy','38654gHJjMC','insertSuggestion','setFeedItemRenderingStrategy','resetConversationTitle','2141250qkvJTl','addContextItem','_isTrackChangesCommandValueBound','values','addTab','isReasoningEnabled','trackChanges','set','enableModelSelector','setInputPlaceholder'];_0x4bbb=function(){return _0x22f2a8;};return _0x4bbb();}import{AI_CHAT_UI_EVENT_NAMES as _0x3502c8}from'./utils/eventnames.js';import'../../theme/aichat/aichat.css';import{getEditorFromContext as _0x2cded5}from'../aicore/utils/geteditorfromcontext.js';import{AI_REPLY_ACTIONS as _0x2c79ab}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';export class AIChatUI extends _0x45d7cd{static get[_0x2dbc2b(0x1ef)](){return[_0x42f081];}[_0x2dbc2b(0x1b3)];static get[_0x2dbc2b(0x1c6)](){const _0xc87111=_0x2dbc2b;return _0xc87111(0x1c2);}static get[_0x2dbc2b(0x191)](){return!0x0;}static get[_0x2dbc2b(0x163)](){return!0x0;}[_0x2dbc2b(0x176)]=_0x2dbc2b(0x208);[_0x2dbc2b(0x1be)]=!0x0;[_0x2dbc2b(0x205)];[_0x2dbc2b(0x20b)];[_0x2dbc2b(0x194)]=void 0x0;[_0x2dbc2b(0x17f)]=!0x1;constructor(_0x595e8f){const _0x2212f9=_0x2dbc2b;super(_0x595e8f);const _0x2115f4=this[_0x2212f9(0x1cb)][_0x2212f9(0x1a1)][_0x2212f9(0x19a)](_0x2212f9(0x1d9));this[_0x2212f9(0x184)](_0x2212f9(0x178),!0x1),this[_0x2212f9(0x205)]=new _0x8cc8de(),this[_0x2212f9(0x1b3)]=new _0x1e4a78(this[_0x2212f9(0x1cb)][_0x2212f9(0x170)],{'showResizeButton':_0x2115f4[_0x2212f9(0x19e)],'contextResourcesSearchInputVisibleFrom':this[_0x2212f9(0x1cb)][_0x2212f9(0x1c4)][_0x2212f9(0x19a)](_0x2212f9(0x177))}),this[_0x2212f9(0x1b3)][_0x2212f9(0x187)](..._0x3502c8)['to'](this),this[_0x2212f9(0x1b3)]['on'](_0x2212f9(0x16e),(_0x5dc0d9,{showDiff:_0x506b4e})=>{const _0x53d0a7=_0x2212f9;this[_0x53d0a7(0x1be)]=_0x506b4e;}),_0x2115f4[_0x2212f9(0x171)][_0x2212f9(0x181)]({'id':_0x2212f9(0x164),'buttonLabel':_0x515d47(this[_0x2212f9(0x1cb)][_0x2212f9(0x170)],_0x2212f9(0x200)),'buttonIcon':_0x96cb73,'order':0x0,'content':this[_0x2212f9(0x1b3)]}),this[_0x2212f9(0x1b3)][_0x2212f9(0x18a)][_0x2212f9(0x1c0)](_0x2212f9(0x1e2))['to'](this,_0x2212f9(0x178),_0x34a110=>_0x34a110),this[_0x2212f9(0x1b3)][_0x2212f9(0x1d6)][_0x2212f9(0x1c0)](_0x2212f9(0x1e6))['to'](this,_0x2212f9(0x178),_0x5ce88f=>_0x5ce88f),this[_0x2212f9(0x1b3)][_0x2212f9(0x18a)][_0x2212f9(0x186)](this[_0x2212f9(0x1e1)]()),this[_0x2212f9(0x1c0)](_0x2212f9(0x1ac))['to'](this[_0x2212f9(0x1b3)][_0x2212f9(0x18a)],_0x2212f9(0x1ac));}[_0x2dbc2b(0x1b2)](){const _0x573330=_0x2dbc2b;super[_0x573330(0x1b2)](),this[_0x573330(0x194)]&&clearInterval(this[_0x573330(0x194)]);}[_0x2dbc2b(0x1ca)](_0x14c639){const _0x41e848=_0x2dbc2b;this[_0x41e848(0x1b3)][_0x41e848(0x1d6)][_0x41e848(0x1f8)](),this[_0x41e848(0x1b3)][_0x41e848(0x18a)][_0x41e848(0x185)](),this[_0x41e848(0x1b3)][_0x41e848(0x18a)][_0x41e848(0x1b6)](_0x14c639[_0x41e848(0x1a3)],!this[_0x41e848(0x1cb)][_0x41e848(0x1c4)][_0x41e848(0x19a)](_0x41e848(0x16b))),this[_0x41e848(0x162)]({'id':_0x41e848(0x199),'staticMessage':_0x515d47(this[_0x41e848(0x1cb)][_0x41e848(0x170)],_0x41e848(0x19c))});}[_0x2dbc2b(0x162)]({id:_0x10f8fb,staticMessage:_0xfdb511}){const _0x4802e9=_0x2dbc2b;this[_0x4802e9(0x1b3)][_0x4802e9(0x1d6)][_0x4802e9(0x1e0)](_0x4802e9(0x1c8),{'id':_0x10f8fb,'initialContent':_0x4802e9(0x1df)+_0xfdb511+_0x4802e9(0x16d)});}[_0x2dbc2b(0x1e7)](_0x4c6bdb){const _0x560a3a=_0x2dbc2b,_0x52a25d=_0x4c6bdb[_0x560a3a(0x1dc)]?.[_0x560a3a(0x1c1)]||_0x4c6bdb[_0x560a3a(0x173)];this[_0x560a3a(0x1b3)][_0x560a3a(0x1d6)][_0x560a3a(0x1e0)](_0x560a3a(0x204),{'contextItems':Array[_0x560a3a(0x1b4)](_0x4c6bdb[_0x560a3a(0x1d3)][_0x560a3a(0x180)]()),'initialContent':_0x560a3a(0x1df)+_0x52a25d+_0x560a3a(0x16d),'id':_0x4c6bdb['id']});}[_0x2dbc2b(0x1c7)]({errorMessage:_0x4d1a89,id:_0x3c9de7}){const _0xe5c56e=_0x2dbc2b;this[_0xe5c56e(0x1b3)][_0xe5c56e(0x1d6)][_0xe5c56e(0x1e0)](_0xe5c56e(0x1cf),{'initialContent':_0xe5c56e(0x1df)+_0x4d1a89+_0xe5c56e(0x16d),'id':_0x3c9de7});}[_0x2dbc2b(0x1ad)](_0x292fc6){const _0x29b1d2=_0x2dbc2b;return this[_0x29b1d2(0x205)][_0x29b1d2(0x1eb)](async()=>{const _0x2d7caa=_0x29b1d2;this[_0x2d7caa(0x1b3)][_0x2d7caa(0x1d6)][_0x2d7caa(0x1e0)](_0x2d7caa(0x1c8),{'id':_0x292fc6[_0x2d7caa(0x167)]+':'+_0x292fc6['id']}),this[_0x2d7caa(0x1f4)](null);});}async[_0x2dbc2b(0x1b0)](_0xc37d1a){const _0x1cc637=_0x2dbc2b,_0x404742=_0x2cded5(this[_0x1cc637(0x1cb)]);let _0x3994bd=_0x404742[_0x1cc637(0x1c4)][_0x1cc637(0x19a)](_0x1cc637(0x1bd))||[..._0x2c79ab];if(_0x404742[_0x1cc637(0x1a1)][_0x1cc637(0x1f3)](_0x1cc637(0x1bb))){if(!this[_0x1cc637(0x17f)]){this[_0x1cc637(0x17f)]=!0x0;const _0x16cfca=_0x404742[_0x1cc637(0x1da)][_0x1cc637(0x19a)](_0x1cc637(0x183));this[_0x1cc637(0x1b3)][_0x1cc637(0x1d6)][_0x1cc637(0x1c0)](_0x1cc637(0x1d4))['to'](_0x16cfca,_0x1cc637(0x18d));}}else _0x3994bd=_0x3994bd[_0x1cc637(0x206)](_0x32d7d1=>_0x1cc637(0x17a)!=_0x32d7d1);return this[_0x1cc637(0x205)][_0x1cc637(0x1eb)](async()=>{const _0x3c1d7d=_0x1cc637;this[_0x3c1d7d(0x1b3)][_0x3c1d7d(0x1d6)][_0x3c1d7d(0x1e0)](_0x3c1d7d(0x190),{'id':_0xc37d1a[_0x3c1d7d(0x167)]+':'+_0xc37d1a['id'],'areActionsDisabled':_0xc37d1a[_0x3c1d7d(0x1fd)],'showDiff':this[_0x3c1d7d(0x1be)],'availableActions':_0x3994bd}),this[_0x3c1d7d(0x1f4)](null);});}[_0x2dbc2b(0x193)](_0x4983ac,_0xb38f4f){const _0xb5b057=_0x2dbc2b,_0x2e7239=this[_0xb5b057(0x1b3)][_0xb5b057(0x1d6)][_0xb5b057(0x1db)][_0xb5b057(0x1ab)];if(_0x2e7239 instanceof _0x2a5d2f)return this[_0xb5b057(0x1b3)][_0xb5b057(0x1d6)][_0xb5b057(0x1db)][_0xb5b057(0x1a6)](_0x2e7239),void this[_0xb5b057(0x1b3)][_0xb5b057(0x1d6)][_0xb5b057(0x1e0)](_0xb5b057(0x1d2),{'id':_0x4983ac['id'],'capabilities':{'isWebSearchEnabled':_0x2e7239[_0xb5b057(0x1d8)][_0xb5b057(0x196)]||_0xb38f4f[_0xb5b057(0x196)],'isReasoningEnabled':_0x2e7239[_0xb5b057(0x1d8)][_0xb5b057(0x182)]||_0xb38f4f[_0xb5b057(0x182)]}});this[_0xb5b057(0x1b3)][_0xb5b057(0x1d6)][_0xb5b057(0x1e0)](_0xb5b057(0x1d2),{'id':_0x4983ac['id'],'capabilities':_0xb38f4f});}[_0x2dbc2b(0x1f2)](_0x152413){const _0x54ee83=_0x2dbc2b,_0x4fbd81=this[_0x54ee83(0x1b3)][_0x54ee83(0x1d6)][_0x54ee83(0x1db)][_0x54ee83(0x198)](_0x2e5ab6=>_0x2e5ab6[_0x54ee83(0x1fc)]['id']==_0x152413['id']&&_0x2e5ab6 instanceof _0x2a5d2f);_0x4fbd81&&_0x4fbd81[_0x54ee83(0x184)](_0x54ee83(0x1ea),_0x152413[_0x54ee83(0x1ea)]);}async[_0x2dbc2b(0x1fe)](_0x537c56){const _0x27ae6f=_0x2dbc2b,_0x200ce6=_0x537c56[_0x27ae6f(0x1f7)]||this[_0x27ae6f(0x176)];return this[_0x27ae6f(0x205)][_0x27ae6f(0x1eb)](async _0x37bc90=>{const _0x2adea9=_0x27ae6f;await this[_0x2adea9(0x1b3)][_0x2adea9(0x1d6)][_0x2adea9(0x1bc)]({..._0x537c56,'abortSignal':_0x37bc90,'renderingStrategy':_0x200ce6}),_0x537c56[_0x2adea9(0x175)]&&this[_0x2adea9(0x18f)](_0x537c56['id']);});}[_0x2dbc2b(0x1b7)](_0x5a651a,_0x1a7b57){const _0x1b2394=_0x2dbc2b;this[_0x1b2394(0x1b3)][_0x1b2394(0x1d6)][_0x1b2394(0x1f1)](_0x5a651a,_0x1a7b57);}async[_0x2dbc2b(0x19d)](_0x342906){const _0x4958cf=_0x2dbc2b,_0x555c0c=_0x342906[_0x4958cf(0x1f7)]||this[_0x4958cf(0x176)];return this[_0x4958cf(0x205)][_0x4958cf(0x1eb)](async _0x20cde0=>{const _0x5dcba4=_0x4958cf;await this[_0x5dcba4(0x1b3)][_0x5dcba4(0x1d6)][_0x5dcba4(0x18c)]({..._0x342906,'abortSignal':_0x20cde0,'renderingStrategy':_0x555c0c}),_0x342906[_0x5dcba4(0x175)]&&this[_0x5dcba4(0x18f)](_0x342906['id']);});}[_0x2dbc2b(0x1e8)](_0x5a2c4f){const _0x59d932=_0x2dbc2b;this[_0x59d932(0x1b3)][_0x59d932(0x1d6)][_0x59d932(0x1d7)](_0x5a2c4f);}[_0x2dbc2b(0x18f)](_0x2e83fa){const _0x4d0290=_0x2dbc2b;this[_0x4d0290(0x1b3)][_0x4d0290(0x1d6)][_0x4d0290(0x165)](_0x2e83fa);}[_0x2dbc2b(0x1cd)](_0x4745be){const _0x5cc10f=_0x2dbc2b;this[_0x5cc10f(0x1b3)][_0x5cc10f(0x1d6)][_0x5cc10f(0x1bf)]()[_0x5cc10f(0x206)](_0x50368e=>_0x50368e[_0x5cc10f(0x1a4)](_0x4745be))[_0x5cc10f(0x1e4)](_0x1f7f55=>this[_0x5cc10f(0x1b3)][_0x5cc10f(0x1d6)][_0x5cc10f(0x1b5)](_0x1f7f55));}[_0x2dbc2b(0x1b8)](){const _0x555b65=_0x2dbc2b;this[_0x555b65(0x1f4)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x1}),this[_0x555b65(0x1b3)][_0x555b65(0x18a)][_0x555b65(0x1a9)](!this[_0x555b65(0x1cb)][_0x555b65(0x1c4)][_0x555b65(0x19a)](_0x555b65(0x16b))),this[_0x555b65(0x178)]=!0x0,this[_0x555b65(0x1b3)][_0x555b65(0x1d6)][_0x555b65(0x189)]();}[_0x2dbc2b(0x1a8)](_0x325cb5){const _0x36c418=_0x2dbc2b;this[_0x36c418(0x205)][_0x36c418(0x1ee)](),this[_0x36c418(0x1b3)][_0x36c418(0x1d6)][_0x36c418(0x1bf)]()[_0x36c418(0x206)](_0x1d37df=>_0x1d37df[_0x36c418(0x1a4)](_0x325cb5['id']))[_0x36c418(0x1e4)](_0x56d749=>this[_0x36c418(0x18f)](_0x56d749)),this[_0x36c418(0x178)]=!0x1,this[_0x36c418(0x1b3)][_0x36c418(0x1d6)][_0x36c418(0x1fa)]();}async[_0x2dbc2b(0x1e3)](){const _0x3ed061=_0x2dbc2b;return this[_0x3ed061(0x205)][_0x3ed061(0x1a2)][_0x3ed061(0x18e)](()=>{const _0x2f2c7a=_0x3ed061;this[_0x2f2c7a(0x178)]=!0x1,this[_0x2f2c7a(0x1b3)][_0x2f2c7a(0x1d6)][_0x2f2c7a(0x1fa)]();});}[_0x2dbc2b(0x17e)](_0x17142f,_0x2c9009){const _0xfdb452=_0x2dbc2b;this[_0xfdb452(0x1b3)][_0xfdb452(0x18a)][_0xfdb452(0x17e)](_0x17142f,_0x2c9009);}[_0x2dbc2b(0x1ba)](_0x5c273b){const _0x3926e3=_0x2dbc2b;this[_0x3926e3(0x1b3)][_0x3926e3(0x18a)][_0x3926e3(0x1ba)](_0x5c273b);}[_0x2dbc2b(0x174)](_0xcfe8f0,_0x2f8af1){const _0x51f918=_0x2dbc2b;this[_0x51f918(0x1b3)][_0x51f918(0x18a)][_0x51f918(0x174)](_0xcfe8f0,_0x2f8af1);}[_0x2dbc2b(0x207)](_0x4f2527){const _0x43fd30=_0x2dbc2b;this[_0x43fd30(0x1b3)][_0x43fd30(0x18a)][_0x43fd30(0x207)](_0x4f2527);}[_0x2dbc2b(0x1ec)](_0x1dcc9d){const _0x3ca2d8=_0x2dbc2b;this[_0x3ca2d8(0x1b3)][_0x3ca2d8(0x18a)][_0x3ca2d8(0x1ec)](_0x1dcc9d);}[_0x2dbc2b(0x1af)](){const _0x8fcd6b=_0x2dbc2b;this[_0x8fcd6b(0x1b3)][_0x8fcd6b(0x18a)][_0x8fcd6b(0x1af)]();}[_0x2dbc2b(0x1ce)](){const _0x522189=_0x2dbc2b;this[_0x522189(0x1b3)][_0x522189(0x18a)][_0x522189(0x1ce)]();}[_0x2dbc2b(0x201)](_0x3e6e07,_0x777877,_0x11f89a){const _0x28e706=_0x2dbc2b;this[_0x28e706(0x1b3)][_0x28e706(0x18a)][_0x28e706(0x201)](_0x3e6e07,_0x777877,_0x11f89a);}[_0x2dbc2b(0x1a5)](){const _0x3ce95b=_0x2dbc2b;this[_0x3ce95b(0x1b3)][_0x3ce95b(0x18a)][_0x3ce95b(0x1a5)](),this[_0x3ce95b(0x1b3)][_0x3ce95b(0x18a)][_0x3ce95b(0x186)](this[_0x3ce95b(0x1e1)]());}[_0x2dbc2b(0x1cc)](_0x403f88){const _0x32441e=_0x2dbc2b;this[_0x32441e(0x1b3)][_0x32441e(0x18a)][_0x32441e(0x1cc)](_0x403f88);}[_0x2dbc2b(0x1f6)](_0x128d5d){const _0x48e078=_0x2dbc2b;this[_0x48e078(0x1b3)][_0x48e078(0x18a)][_0x48e078(0x1f9)](_0x128d5d[_0x48e078(0x196)]),this[_0x48e078(0x1b3)][_0x48e078(0x18a)][_0x48e078(0x1aa)](_0x128d5d[_0x48e078(0x182)]),this[_0x48e078(0x1b3)][_0x48e078(0x18a)][_0x48e078(0x186)](this[_0x48e078(0x1e1)](_0x128d5d));}[_0x2dbc2b(0x1d5)](_0x46f7f4,_0x230fc2){const _0x4d8ba3=_0x2dbc2b;this[_0x4d8ba3(0x1b3)][_0x4d8ba3(0x18a)][_0x4d8ba3(0x195)](_0x46f7f4),_0x230fc2&&this[_0x4d8ba3(0x1b3)][_0x4d8ba3(0x18a)][_0x4d8ba3(0x1a9)](!0x1);}[_0x2dbc2b(0x17b)](_0x4b45ba){const _0x30fb81=_0x2dbc2b;this[_0x30fb81(0x176)]=_0x4b45ba;}[_0x2dbc2b(0x188)](_0x401be6){const _0x5e11ab=_0x2dbc2b;this[_0x5e11ab(0x1b3)][_0x5e11ab(0x1d6)][_0x5e11ab(0x188)](_0x401be6);}[_0x2dbc2b(0x17c)](){const _0x39b6f2=_0x2dbc2b;this[_0x39b6f2(0x202)](_0x515d47(this[_0x39b6f2(0x1cb)][_0x39b6f2(0x170)],_0x39b6f2(0x200)));}[_0x2dbc2b(0x202)](_0x545987,_0x24b843=!0x1){const _0x4fcbac=_0x2dbc2b;if(_0x24b843&&!_0x28d2fa()&&_0x545987[_0x4fcbac(0x209)])return this[_0x4fcbac(0x1b3)][_0x4fcbac(0x1b9)][_0x4fcbac(0x16c)]='',void this[_0x4fcbac(0x197)](_0x545987);this[_0x4fcbac(0x1b3)][_0x4fcbac(0x1b9)][_0x4fcbac(0x16c)]=_0x545987;}[_0x2dbc2b(0x1f4)](_0x5e8f56){const _0x473a6d=_0x2dbc2b,_0xa3cc75=this[_0x473a6d(0x19b)](_0x5e8f56);this[_0x473a6d(0x1b3)][_0x473a6d(0x1d6)][_0x473a6d(0x1f4)](_0xa3cc75);}[_0x2dbc2b(0x197)](_0x10bba2){const _0x51003d=_0x2dbc2b;let _0x591a07=0x0;clearInterval(this[_0x51003d(0x194)]),this[_0x51003d(0x194)]=setInterval(()=>{const _0x493934=_0x51003d;this[_0x493934(0x1b3)][_0x493934(0x1b9)][_0x493934(0x16c)]=this[_0x493934(0x1b3)][_0x493934(0x1b9)][_0x493934(0x16c)]+_0x10bba2[_0x591a07],_0x591a07++,_0x591a07===_0x10bba2[_0x493934(0x209)]&&clearInterval(this[_0x493934(0x194)]);},0x1e);}[_0x2dbc2b(0x1e9)](_0x3ce2b0){const _0x3e6325=_0x2dbc2b;this[_0x3e6325(0x1b3)][_0x3e6325(0x1b9)][_0x3e6325(0x1fb)]=_0x3ce2b0;}[_0x2dbc2b(0x19b)](_0x127277){const _0x5de9b4=_0x2dbc2b;return _0x127277?_0x127277[_0x5de9b4(0x196)]&&_0x127277[_0x5de9b4(0x182)]?_0x515d47(this[_0x5de9b4(0x1cb)][_0x5de9b4(0x170)],_0x5de9b4(0x169)):_0x127277[_0x5de9b4(0x196)]?_0x515d47(this[_0x5de9b4(0x1cb)][_0x5de9b4(0x170)],_0x5de9b4(0x1ff)):_0x127277[_0x5de9b4(0x182)]?_0x515d47(this[_0x5de9b4(0x1cb)][_0x5de9b4(0x170)],_0x5de9b4(0x168)):_0x515d47(this[_0x5de9b4(0x1cb)][_0x5de9b4(0x170)],_0x5de9b4(0x19f)):'';}[_0x2dbc2b(0x1e1)](_0x2d750b){const _0x42634e=_0x2dbc2b;return _0x2d750b?_0x2d750b[_0x42634e(0x196)]&&_0x2d750b[_0x42634e(0x182)]?_0x515d47(this[_0x42634e(0x1cb)][_0x42634e(0x170)],_0x42634e(0x1c5)):_0x2d750b[_0x42634e(0x196)]?_0x515d47(this[_0x42634e(0x1cb)][_0x42634e(0x170)],_0x42634e(0x16a)):_0x2d750b[_0x42634e(0x182)]?_0x515d47(this[_0x42634e(0x1cb)][_0x42634e(0x170)],_0x42634e(0x16f)):_0x515d47(this[_0x42634e(0x1cb)][_0x42634e(0x170)],_0x42634e(0x1ed)):_0x515d47(this[_0x42634e(0x1cb)][_0x42634e(0x170)],_0x42634e(0x1ed));}[_0x2dbc2b(0x1a7)](_0x13fa8a,_0x2069a1,_0x2cffd4,_0x13a728){const _0x1e9b4e=_0x2dbc2b;this[_0x1e9b4e(0x1b3)][_0x1e9b4e(0x1a7)](_0x13fa8a,_0x2069a1,_0x2cffd4,_0x13a728);}[_0x2dbc2b(0x20a)](_0x59177d){const _0x3ddd11=_0x2dbc2b;this[_0x3ddd11(0x1b3)][_0x3ddd11(0x20a)](_0x59177d);}[_0x2dbc2b(0x18b)](){const _0x25f228=_0x2dbc2b;this[_0x25f228(0x1b3)][_0x25f228(0x18a)][_0x25f228(0x18b)]();}[_0x2dbc2b(0x1c3)](_0x15231f,_0x5de3f9){const _0x543749=_0x2dbc2b;this[_0x543749(0x1b3)][_0x543749(0x1d6)][_0x543749(0x1de)](_0x15231f,_0x5de3f9);}[_0x2dbc2b(0x189)](){const _0x432d50=_0x2dbc2b;this[_0x432d50(0x1b3)][_0x432d50(0x1d6)][_0x432d50(0x189)]();}[_0x2dbc2b(0x1f0)](){const _0x3110ae=_0x2dbc2b;this[_0x3110ae(0x1b3)][_0x3110ae(0x18a)][_0x3110ae(0x1e5)]=!0x0;}[_0x2dbc2b(0x1ae)](){const _0x59d142=_0x2dbc2b;this[_0x59d142(0x1b3)][_0x59d142(0x18a)][_0x59d142(0x1e5)]=!0x1;}}
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const _0x328029=_0x18de;(function(_0x1970f0,_0x4796aa){const _0x26bea5=_0x18de,_0x70e460=_0x1970f0();while(!![]){try{const _0x53654f=parseInt(_0x26bea5(0x13b))/0x1+parseInt(_0x26bea5(0xf8))/0x2+parseInt(_0x26bea5(0xdc))/0x3*(parseInt(_0x26bea5(0xef))/0x4)+parseInt(_0x26bea5(0x137))/0x5+-parseInt(_0x26bea5(0x14c))/0x6*(-parseInt(_0x26bea5(0xd8))/0x7)+parseInt(_0x26bea5(0x156))/0x8+parseInt(_0x26bea5(0xf7))/0x9*(-parseInt(_0x26bea5(0xf9))/0xa);if(_0x53654f===_0x4796aa)break;else _0x70e460['push'](_0x70e460['shift']());}catch(_0x48c524){_0x70e460['push'](_0x70e460['shift']());}}}(_0x3177,0x4fac8));import{CKEditorError as _0x9e7702,ObservableMixin as _0x45dd7b,uid as _0x1f91d7}from'ckeditor5/src/utils.js';import{AIContextItemType as _0x558573,AIContextTextResourceType as _0x26de67}from'../../aicore/model/aicontext.js';import{escape as _0x3b1600}from'es-toolkit/compat';function _0x3177(){const _0x2360d7=['all','_finishUploadOperation','addUrlToContext','populateFromMessage','1608712jhTQPq','ai-chat-resource-load-failed','HTML','abort','object','set','_createContextItemFromContent','Current\x20document','code','isHidden','contextItemLoadingEnded','contextItemAdded','stack','isSelectionInContext','start','removeSelectionFromContext','size','3702202wGJeNL','resourceStateChanged','addCurrentDocumentToContext','getId','39oVejZR','url','enabled','uploadFile','_addContextItem','attributes','length','urls','uploadDocument','removeFromContext','_ongoingUploadOperations','SELECTION','FILE','File','string','error','_removeContextItem','document','clearPendingContextItems','88524IkzoXy','uploadProgressChanged','current-document','hidden','ai-chat-file-upload-failed','end','mapContextItemsToRequestData','map','9tPBoWg','883578MQXZXY','16422660CZwLDe','ai-chat-document-upload-failed','getDocument','ai-chat-context-invalid-data','type','_connector','getSentContextItems','ai-chat-source-not-found','fetchDocument','file-','_ownerId','text/html','ai-chat-source-resources-load-failed','addContextOptionsChanged','from','_conversationContextItems','DOCUMENT','_startUploadOperation','URL','startsWith','ai-chat-resource-no-data','addSelectionToContext','_isResourceInContext','_findSourceIdsByResourceId','_pendingContextItems','loadSourceResources','forEach','_addContextOptionsState','content','ai-chat-url-upload-failed','getData','resources','sources','MARKDOWN','fire','_config','isCurrentDocumentInConversation','uploadUrl','addFilesToContext','isInContext','_finishContextItemLoading','_getCustomSourcesInitialState','message','resourceId','addToConversationContext','_setAddContextOptionsDefaultState','updateCurrentDocument','_convertTextResourceToFile','uiId','data','TEXT','sourceResourcesLoaded','init','selection','_updateResourceInContextState','label','url-','getResources','ai-request-aborted','filter','text/plain','ai-chat-context-unsupported-type','424930uqGFbl','files','find','name','424157Fnzbpi','contextItemRemoved','isCurrentDocumentInContext','push','_addToConversationContextItem','_toggleAddCurrentDocumentOptionVisibility','has','files-','_mapContextItemToRequestData','version','abortController','isReadOnly','object\x20with\x20content\x20and\x20type\x20properties','delete','get','getPendingContextItems','sessionId','6PwSKKE','text/markdown','addResourceToContext','_ongoingUploads','contextSent','values'];_0x3177=function(){return _0x2360d7;};return _0x3177();}import{errorsMap as _0x431612}from'../../errorsmap.js';function _0x18de(_0x390cf1,_0x3d3b35){const _0x317707=_0x3177();return _0x18de=function(_0x18de3d,_0x416491){_0x18de3d=_0x18de3d-0xd0;let _0x175e69=_0x317707[_0x18de3d];return _0x175e69;},_0x18de(_0x390cf1,_0x3d3b35);}export const AI_CONTEXT_MODEL_EVENT_NAMES=[_0x328029(0xd2),_0x328029(0x13c),_0x328029(0xd1),_0x328029(0x150),_0x328029(0xeb),_0x328029(0x106),_0x328029(0x12c),_0x328029(0xd9),_0x328029(0xf0)];export class AIChatContext extends _0x45dd7b(){[_0x328029(0xfe)];[_0x328029(0x11c)];[_0x328029(0x103)];constructor({connector:_0x19d7f1,config:_0x24d00d,ownerId:_0x386b14}){const _0x1212d6=_0x328029;super(),this[_0x1212d6(0xfe)]=_0x19d7f1,this[_0x1212d6(0x11c)]=_0x24d00d,this[_0x1212d6(0x103)]=_0x386b14;}[_0x328029(0x12d)](){const _0x528fbe=_0x328029;this[_0x528fbe(0x111)]=new Map(),this[_0x528fbe(0x108)]=new Map(),this[_0x528fbe(0x14f)]=new Map(),this[_0x528fbe(0xe6)]=new Map(),this[_0x528fbe(0x126)]();}[_0x328029(0x14a)](){const _0x3e9fff=_0x328029;return this[_0x3e9fff(0x111)];}async[_0x328029(0x155)](_0x488c13){const _0x427fa1=_0x328029,_0x5ad11a=await this[_0x427fa1(0x15c)](_0x488c13);return this[_0x427fa1(0x13f)](_0x5ad11a),_0x427fa1(0xf1)===_0x5ad11a[_0x427fa1(0x129)]&&this[_0x427fa1(0x140)](),_0x5ad11a;}async[_0x328029(0x15c)](_0x239e0d){const _0x52ec24=_0x328029;if(_0x239e0d[_0x52ec24(0xfd)]===_0x558573[_0x52ec24(0x109)]){const _0x4b8e3a=await this[_0x52ec24(0xfe)][_0x52ec24(0x101)](this[_0x52ec24(0x103)],_0x239e0d['id'])[_0x52ec24(0xfb)]();return{'id':_0x52ec24(0xf1),'uiId':_0x52ec24(0xf1),'label':_0x52ec24(0x15d),'type':_0x239e0d[_0x52ec24(0xfd)],'content':_0x4b8e3a[_0x52ec24(0x115)],'hidden':this[_0x52ec24(0x108)][_0x52ec24(0x141)](_0x52ec24(0xf1)),'version':_0x4b8e3a[_0x52ec24(0xe1)]?.[_0x52ec24(0x144)],'sessionId':_0x4b8e3a[_0x52ec24(0xe1)]?.[_0x52ec24(0x14b)]};}return{'id':_0x239e0d['id'],'uiId':_0x239e0d['id'],'label':_0x239e0d[_0x52ec24(0xe1)]?.[_0x52ec24(0x130)]||_0x239e0d[_0x52ec24(0x13a)]||_0x239e0d[_0x52ec24(0xdd)]||_0x239e0d['id'],'type':_0x239e0d[_0x52ec24(0xfd)],..._0x239e0d?.[_0x52ec24(0xe1)]?.[_0x52ec24(0x124)]?{'resourceId':_0x239e0d[_0x52ec24(0xe1)]?.[_0x52ec24(0x124)]}:{}};}[_0x328029(0xff)](){const _0x3fa13b=_0x328029;return new Map(this[_0x3fa13b(0x108)]);}[_0x328029(0xe5)](_0x4b09bd){const _0x4c6225=_0x328029,_0x56b343=this[_0x4c6225(0x111)][_0x4c6225(0x149)](_0x4b09bd);_0x56b343?.[_0x4c6225(0x146)]||this[_0x4c6225(0xec)](_0x4b09bd);}[_0x328029(0xee)](){const _0x2cfd62=_0x328029;if(0x0===this[_0x2cfd62(0x111)][_0x2cfd62(0xd7)])return;for(const _0x281deb of this[_0x2cfd62(0x111)][_0x2cfd62(0x151)]())this[_0x2cfd62(0xec)](_0x281deb[_0x2cfd62(0x129)]);const _0x11f564=this[_0x2cfd62(0x108)][_0x2cfd62(0x149)](_0x2cfd62(0xf1))||this[_0x2cfd62(0x111)][_0x2cfd62(0x149)](_0x2cfd62(0xf1));_0x11f564&&this[_0x2cfd62(0xe0)]({..._0x11f564,'isReadOnly':!0x0,'hidden':!0x0});}[_0x328029(0x125)](_0x265e5b){const _0x30dfcd=_0x328029;for(const _0x4d4c94 of _0x265e5b[_0x30dfcd(0x151)]())this[_0x30dfcd(0x13f)](_0x4d4c94);this[_0x30dfcd(0xee)](),this[_0x30dfcd(0x11b)](_0x30dfcd(0x150),{'contextItems':Array[_0x30dfcd(0x107)](this[_0x30dfcd(0xff)]()[_0x30dfcd(0x151)]())});}[_0x328029(0x13d)](){const _0x9212b8=_0x328029;return this[_0x9212b8(0x111)][_0x9212b8(0x141)](_0x9212b8(0xf1));}[_0x328029(0xd4)](){const _0x435128=_0x328029;return this[_0x435128(0x111)][_0x435128(0x141)](_0x435128(0x12e));}[_0x328029(0x11d)](){const _0x279cbf=_0x328029;return this[_0x279cbf(0x108)][_0x279cbf(0x141)](_0x279cbf(0xf1));}static[_0x328029(0xf5)](_0x122ab4){const _0x313ced=_0x328029;return Array[_0x313ced(0x107)](_0x122ab4[_0x313ced(0x151)]())[_0x313ced(0xf6)](_0x1863e4=>this[_0x313ced(0x143)](_0x1863e4))[_0x313ced(0x134)](_0x459969=>null!==_0x459969);}async[_0x328029(0x11f)](_0x160151,_0x236309,_0x1d1465=_0x558573[_0x328029(0xe8)]){const _0x47cd6f=_0x328029,_0x454644=_0x47cd6f(0x142)+_0x1f91d7();this[_0x47cd6f(0x10a)](_0x454644);try{await Promise[_0x47cd6f(0x152)](_0x160151[_0x47cd6f(0xf6)](async _0x265a77=>{const _0x393cf6=_0x47cd6f,_0x417fce=_0x393cf6(0x102)+_0x1f91d7(),_0x2a4bfd=_0x3b1600(_0x265a77[_0x393cf6(0x13a)]);try{this[_0x393cf6(0xe0)]({'type':_0x1d1465,'label':_0x236309?.[_0x393cf6(0x130)]||_0x2a4bfd,'uiId':_0x417fce,'resourceId':_0x236309?.[_0x393cf6(0x124)]},!0x0);const _0x1f5a15=this[_0x393cf6(0xfe)][_0x393cf6(0xdf)](this[_0x393cf6(0x103)],_0x265a77,_0x236309);this[_0x393cf6(0x14f)][_0x393cf6(0x15b)](_0x417fce,_0x1f5a15[_0x393cf6(0x145)]);const {id:_0x2949c2}=await _0x1f5a15[_0x393cf6(0xdb)]();this[_0x393cf6(0x14f)][_0x393cf6(0x148)](_0x417fce),this[_0x393cf6(0x121)]({'type':_0x1d1465,'id':_0x2949c2,'label':_0x236309?.[_0x393cf6(0x130)]||_0x2a4bfd,'uiId':_0x417fce,'resourceId':_0x236309?.[_0x393cf6(0x124)]},!0x1);}catch(_0x5f061a){this[_0x393cf6(0x14f)][_0x393cf6(0x148)](_0x417fce);if(!(_0x5f061a instanceof _0x9e7702&&_0x5f061a[_0x393cf6(0x123)][_0x393cf6(0x10c)](_0x393cf6(0x133)))){const _0x473ff9=_0x431612[_0x393cf6(0x149)](_0x5f061a[_0x393cf6(0x15e)])||_0x393cf6(0xf3),_0x55c76f=new _0x9e7702(_0x473ff9,null,{'fileName':_0x2a4bfd,..._0x5f061a});_0x55c76f[_0x393cf6(0xd3)]=_0x5f061a[_0x393cf6(0xd3)],this[_0x393cf6(0x11b)](_0x393cf6(0xeb),{'error':_0x55c76f});}this[_0x393cf6(0xec)](_0x417fce);}}));}finally{this[_0x47cd6f(0x153)](_0x454644);}}[_0x328029(0xda)](_0x2d8fd0){const _0x300689=_0x328029;if(this[_0x300689(0x13d)]())return;const _0x4bc1fb={'type':_0x558573[_0x300689(0x109)],'uiId':_0x300689(0xf1),'label':_0x2d8fd0,'isReadOnly':this[_0x300689(0x108)][_0x300689(0x141)](_0x300689(0xf1)),'hidden':this[_0x300689(0x108)][_0x300689(0x141)](_0x300689(0xf1))};this[_0x300689(0xe0)](_0x4bc1fb);}async[_0x328029(0x127)](_0x27ed3b,_0x467322,_0x2133ca,_0x29f726){const _0x41187=_0x328029,_0x5a3cf5=this[_0x41187(0x111)][_0x41187(0x149)](_0x41187(0xf1));if(_0x5a3cf5&&_0x27ed3b){_0x5a3cf5[_0x41187(0x12e)]=_0x29f726?_0x29f726[_0x41187(0xf6)](_0x46f580=>({'start':_0x46f580[_0x41187(0xd5)],'end':_0x46f580[_0x41187(0xf4)]})):[];try{if(_0x5a3cf5[_0x41187(0x144)]===_0x467322)return;const {id:_0x1ff82d}=await this[_0x41187(0xfe)][_0x41187(0xe4)](this[_0x41187(0x103)],_0x27ed3b,{'version':_0x467322,'sessionId':_0x2133ca})[_0x41187(0xdb)]();_0x5a3cf5['id']=_0x1ff82d,_0x5a3cf5[_0x41187(0x115)]=_0x27ed3b,_0x5a3cf5[_0x41187(0x144)]=_0x467322,_0x5a3cf5[_0x41187(0x14b)]=_0x2133ca;}catch(_0x3b2bf){const _0x55f1b3=new _0x9e7702(_0x41187(0xfa),null);_0x55f1b3[_0x41187(0xd3)]=_0x3b2bf[_0x41187(0xd3)],this[_0x41187(0x11b)](_0x41187(0xeb),{'error':_0x55f1b3});}}}[_0x328029(0x10e)](_0x100f82){const _0x12e799=_0x328029;this[_0x12e799(0xe0)]({'type':_0x558573[_0x12e799(0xe7)],'label':_0x100f82,'uiId':_0x12e799(0x12e),'content':_0x100f82});}[_0x328029(0xd6)](){const _0xfa50fe=_0x328029;this[_0xfa50fe(0xec)](_0xfa50fe(0x12e));}async[_0x328029(0x154)](_0x21cc9d,_0x4556ef){const _0x4a5478=_0x328029,_0xb635f4=_0x4a5478(0x131)+_0x1f91d7();this[_0x4a5478(0x10a)](_0xb635f4);const _0x25b629=_0x4a5478(0x131)+_0x1f91d7();try{this[_0x4a5478(0xe0)]({'type':_0x558573[_0x4a5478(0x10b)],'label':_0x4556ef?.[_0x4a5478(0x130)]||_0x21cc9d,'uiId':_0x25b629,'resourceId':_0x4556ef?.[_0x4a5478(0x124)]},!0x0);const _0x5a7df0=this[_0x4a5478(0xfe)][_0x4a5478(0x11e)](this[_0x4a5478(0x103)],_0x21cc9d,_0x4556ef);this[_0x4a5478(0x14f)][_0x4a5478(0x15b)](_0x25b629,_0x5a7df0[_0x4a5478(0x145)]);const {id:_0xf2ab11}=await _0x5a7df0[_0x4a5478(0xdb)]();this[_0x4a5478(0x14f)][_0x4a5478(0x148)](_0x25b629),this[_0x4a5478(0x121)]({'type':_0x558573[_0x4a5478(0x10b)],'id':_0xf2ab11,'label':_0x4556ef?.[_0x4a5478(0x130)]||_0x21cc9d,'uiId':_0x25b629,'resourceId':_0x4556ef?.[_0x4a5478(0x124)]},!0x1);}catch(_0x589515){this[_0x4a5478(0x14f)][_0x4a5478(0x148)](_0x25b629),(_0x589515[_0x4a5478(0x123)][_0x4a5478(0x10c)](_0x4a5478(0x133))||this[_0x4a5478(0x11b)](_0x4a5478(0xeb),{'error':new _0x9e7702(_0x4a5478(0x116),this,{'url':_0x21cc9d,'originalError':_0x589515}),'url':_0x21cc9d}),this[_0x4a5478(0xec)](_0x25b629));}finally{this[_0x4a5478(0x153)](_0xb635f4);}}async[_0x328029(0x112)](_0xfc85cb,_0x5b8e10,_0x41d45b){const _0x49c821=_0x328029,_0x56ed5e=this[_0x49c821(0x114)][_0x49c821(0x119)][_0x49c821(0x139)](_0x21f39c=>_0x21f39c['id']===_0xfc85cb);if(!_0x56ed5e)return this[_0x49c821(0x11b)](_0x49c821(0xeb),{'error':new _0x9e7702(_0x49c821(0x100),this,{'sourceId':_0xfc85cb}),'sourceId':_0xfc85cb}),[];try{const _0x5085f8=(await _0x56ed5e[_0x49c821(0x132)](_0x5b8e10))[_0x49c821(0xf6)](_0x3d63a3=>{const _0x3088f2=_0x49c821,_0x42b1b1=this[_0x3088f2(0x10f)](_0x3d63a3['id']);return{..._0x3d63a3,'isInContext':_0x42b1b1};});return _0x56ed5e[_0x49c821(0x118)]=_0x5085f8,this[_0x49c821(0x11b)](_0x49c821(0x12c),{'sourceId':_0xfc85cb,'source':_0x56ed5e,'resources':_0x5085f8,'uid':_0x41d45b}),_0x5085f8;}catch(_0x1c5ea7){return this[_0x49c821(0x11b)](_0x49c821(0xeb),{'error':new _0x9e7702(_0x49c821(0x105),this,{'sourceId':_0xfc85cb,'originalError':_0x1c5ea7}),'sourceId':_0xfc85cb,'sourceLabel':_0x56ed5e[_0x49c821(0x130)]}),[];}}async[_0x328029(0x14e)](_0x36c45f,_0x2b7f40){const _0x4743=_0x328029;if(this[_0x4743(0x10f)](_0x2b7f40['id']))return;let _0x795d29=_0x2b7f40[_0x4743(0x12a)];if(!_0x795d29&&_0x36c45f[_0x4743(0x117)])try{_0x795d29=await _0x36c45f[_0x4743(0x117)](_0x2b7f40['id']);}catch(_0x341e60){return void this[_0x4743(0x11b)](_0x4743(0xeb),{'error':new _0x9e7702(_0x4743(0x157),this,{'resourceId':_0x2b7f40['id'],'sourceId':_0x36c45f['id'],'originalError':_0x341e60}),'resourceId':_0x2b7f40['id'],'sourceId':_0x36c45f['id']});}if(_0x795d29)switch(_0x2b7f40[_0x4743(0xfd)]){case _0x558573[_0x4743(0x10b)]:if(_0x4743(0xea)!=typeof _0x795d29)return void this[_0x4743(0x11b)](_0x4743(0xeb),{'error':new _0x9e7702(_0x4743(0xfc),this,{'resourceId':_0x2b7f40['id'],'sourceId':_0x36c45f['id'],'expectedType':_0x4743(0xea),'actualType':typeof _0x795d29}),'resourceId':_0x2b7f40['id'],'sourceId':_0x36c45f['id']});await this[_0x4743(0x154)](_0x795d29,{'label':_0x2b7f40[_0x4743(0x130)],'resourceId':_0x2b7f40['id']});break;case _0x558573[_0x4743(0xe8)]:if(!(_0x795d29 instanceof File))return void this[_0x4743(0x11b)](_0x4743(0xeb),{'error':new _0x9e7702(_0x4743(0xfc),this,{'resourceId':_0x2b7f40['id'],'sourceId':_0x36c45f['id'],'expectedType':_0x4743(0xe9),'actualType':typeof _0x795d29}),'resourceId':_0x2b7f40['id'],'sourceId':_0x36c45f['id']});await this[_0x4743(0x11f)]([_0x795d29],{'label':_0x2b7f40[_0x4743(0x130)],'resourceId':_0x2b7f40['id']});break;case _0x558573[_0x4743(0x12b)]:if(_0x4743(0x15a)!=typeof _0x795d29||!(_0x4743(0x115)in _0x795d29)||!(_0x4743(0xfd)in _0x795d29))return void this[_0x4743(0x11b)](_0x4743(0xeb),{'error':new _0x9e7702(_0x4743(0xfc),this,{'resourceId':_0x2b7f40['id'],'sourceId':_0x36c45f['id'],'expectedType':_0x4743(0x147),'actualType':typeof _0x795d29}),'resourceId':_0x2b7f40['id'],'sourceId':_0x36c45f['id']});_0x795d29=AIChatContext[_0x4743(0x128)](_0x795d29,_0x2b7f40[_0x4743(0x130)]),await this[_0x4743(0x11f)]([_0x795d29],{'label':_0x2b7f40[_0x4743(0x130)],'resourceId':_0x2b7f40['id']},_0x558573[_0x4743(0x12b)]);break;default:this[_0x4743(0x11b)](_0x4743(0xeb),{'error':new _0x9e7702(_0x4743(0x136),this,{'resourceId':_0x2b7f40['id'],'sourceId':_0x36c45f['id'],'resourceType':_0x2b7f40[_0x4743(0xfd)]}),'resourceId':_0x2b7f40['id'],'sourceId':_0x36c45f['id']});}else this[_0x4743(0x11b)](_0x4743(0xeb),{'error':new _0x9e7702(_0x4743(0x10d),this,{'resourceId':_0x2b7f40['id'],'sourceId':_0x36c45f['id']}),'resourceId':_0x2b7f40['id'],'sourceId':_0x36c45f['id']});}static[_0x328029(0x128)](_0x5ddc72,_0x4d38c8){const _0xa547ee=_0x328029;switch(_0x5ddc72[_0xa547ee(0xfd)]){case _0x26de67[_0xa547ee(0x11a)]:return new File([_0x5ddc72[_0xa547ee(0x115)]],_0x4d38c8,{'type':_0xa547ee(0x14d)});case _0x26de67[_0xa547ee(0x158)]:return new File([_0x5ddc72[_0xa547ee(0x115)]],_0x4d38c8,{'type':_0xa547ee(0x104)});default:return new File([_0x5ddc72[_0xa547ee(0x115)]],_0x4d38c8,{'type':_0xa547ee(0x135)});}}static[_0x328029(0x143)](_0x41d732){const _0x1d6540=_0x328029;switch(_0x41d732[_0x1d6540(0xfd)]){case _0x558573[_0x1d6540(0xe8)]:return{'type':_0x558573[_0x1d6540(0xe8)],'id':_0x41d732['id']};case _0x558573[_0x1d6540(0x10b)]:return{'type':_0x558573[_0x1d6540(0x10b)],'id':_0x41d732['id']};case _0x558573[_0x1d6540(0x109)]:return{'type':_0x558573[_0x1d6540(0x109)],'id':_0x41d732['id'],..._0x41d732[_0x1d6540(0x12e)]?.[_0x1d6540(0xe2)]&&{'selection':_0x41d732[_0x1d6540(0x12e)]}};case _0x558573[_0x1d6540(0x12b)]:return{'type':_0x558573[_0x1d6540(0xe8)],'id':_0x41d732['id']};default:return null;}}[_0x328029(0xe0)](_0x8e1315,_0x3689a9=!0x1){const _0x25c0d1=_0x328029;if(this[_0x25c0d1(0x111)][_0x25c0d1(0x15b)](_0x8e1315[_0x25c0d1(0x129)],_0x8e1315),_0x8e1315[_0x25c0d1(0xf2)]||this[_0x25c0d1(0x11b)](_0x25c0d1(0xd2),{'contextItem':_0x8e1315,'isLoading':_0x3689a9}),_0x25c0d1(0xf1)===_0x8e1315[_0x25c0d1(0x129)]&&this[_0x25c0d1(0x140)](),_0x8e1315[_0x25c0d1(0x124)]){const _0xbc0c2b=this[_0x25c0d1(0x110)](_0x8e1315[_0x25c0d1(0x124)]);_0xbc0c2b&&_0xbc0c2b[_0x25c0d1(0x113)](_0x64505e=>{const _0x5d2841=_0x25c0d1;this[_0x5d2841(0x12f)](_0x64505e,_0x8e1315[_0x5d2841(0x124)],!0x0);});}}[_0x328029(0xec)](_0x524b33){const _0x1671b4=_0x328029,_0x2632bb=this[_0x1671b4(0x111)][_0x1671b4(0x149)](_0x524b33),_0x9d3c4c=this[_0x1671b4(0x14f)][_0x1671b4(0x149)](_0x524b33);if(_0x9d3c4c&&(_0x9d3c4c[_0x1671b4(0x159)](),this[_0x1671b4(0x14f)][_0x1671b4(0x148)](_0x524b33)),_0x2632bb?.[_0x1671b4(0x124)]){const _0x111510=this[_0x1671b4(0x110)](_0x2632bb[_0x1671b4(0x124)]);_0x111510&&_0x111510[_0x1671b4(0x113)](_0x17eb71=>{const _0x587937=_0x1671b4;this[_0x587937(0x12f)](_0x17eb71,_0x2632bb[_0x587937(0x124)],!0x1);});}this[_0x1671b4(0x111)][_0x1671b4(0x148)](_0x524b33),this[_0x1671b4(0x11b)](_0x1671b4(0x13c),{'uiId':_0x524b33,'type':_0x2632bb?.[_0x1671b4(0xfd)]}),_0x1671b4(0xf1)===_0x524b33&&this[_0x1671b4(0x140)]();}[_0x328029(0x121)](_0x4d3d29,_0x555a3e){const _0x51d026=_0x328029;if(this[_0x51d026(0x111)][_0x51d026(0x141)](_0x4d3d29[_0x51d026(0x129)])&&(this[_0x51d026(0x111)][_0x51d026(0x15b)](_0x4d3d29[_0x51d026(0x129)],_0x4d3d29),this[_0x51d026(0x11b)](_0x51d026(0xd1),{'contextItem':_0x4d3d29,'isLoading':_0x555a3e}),_0x4d3d29[_0x51d026(0x124)])){const _0x2e8397=this[_0x51d026(0x110)](_0x4d3d29[_0x51d026(0x124)]);_0x2e8397&&_0x2e8397[_0x51d026(0x113)](_0x18c406=>{const _0xe8f18d=_0x51d026;this[_0xe8f18d(0x12f)](_0x18c406,_0x4d3d29[_0xe8f18d(0x124)],!0x0);});}}[_0x328029(0x13f)](_0x46cc90){const _0x159f0e=_0x328029;this[_0x159f0e(0x108)][_0x159f0e(0x15b)](_0x46cc90[_0x159f0e(0x129)],_0x46cc90);}[_0x328029(0x126)](){const _0x342a7a=_0x328029;this[_0x342a7a(0x114)]={'document':{'enabled':!0x1!==this[_0x342a7a(0x11c)]?.[_0x342a7a(0xed)]?.[_0x342a7a(0xde)],'isHidden':!0x1},'urls':{'enabled':!0x1!==this[_0x342a7a(0x11c)]?.[_0x342a7a(0xe3)]?.[_0x342a7a(0xde)]},'files':{'enabled':!0x1!==this[_0x342a7a(0x11c)]?.[_0x342a7a(0x138)]?.[_0x342a7a(0xde)]},'sources':this[_0x342a7a(0x122)]()},this[_0x342a7a(0x11b)](_0x342a7a(0x106),{'options':this[_0x342a7a(0x114)]});}[_0x328029(0x122)](){const _0x71cbbc=_0x328029;return this[_0x71cbbc(0x11c)]?.[_0x71cbbc(0x119)]?.[_0x71cbbc(0xf6)](_0x2f41be=>({..._0x2f41be,'resources':[]}))??[];}[_0x328029(0x140)](){const _0x5cd7ad=_0x328029,_0x338526=this[_0x5cd7ad(0x13d)]()||this[_0x5cd7ad(0x11d)]();this[_0x5cd7ad(0x114)][_0x5cd7ad(0xed)][_0x5cd7ad(0xd0)]=_0x338526,this[_0x5cd7ad(0x11b)](_0x5cd7ad(0x106),{'options':this[_0x5cd7ad(0x114)]});}[_0x328029(0x10f)](_0x4311fa){const _0x1e627c=_0x328029;for(const _0x242a2a of this[_0x1e627c(0x111)][_0x1e627c(0x151)]())if(_0x242a2a[_0x1e627c(0x124)]===_0x4311fa)return!0x0;for(const _0x23502a of this[_0x1e627c(0x108)][_0x1e627c(0x151)]())if(_0x23502a[_0x1e627c(0x124)]===_0x4311fa)return!0x0;return!0x1;}[_0x328029(0x110)](_0x5a91f9){const _0x23ebdb=_0x328029,_0x263a84=[];for(const _0x3619c9 of this[_0x23ebdb(0x114)][_0x23ebdb(0x119)]){_0x3619c9[_0x23ebdb(0x118)][_0x23ebdb(0x139)](_0x2d7990=>_0x2d7990['id']===_0x5a91f9)&&_0x263a84[_0x23ebdb(0x13e)](_0x3619c9['id']);}return 0x0===_0x263a84[_0x23ebdb(0xe2)]?null:_0x263a84;}[_0x328029(0x12f)](_0x19beec,_0x4d658f,_0xa8b99d){const _0x55eac0=_0x328029,_0x18d192=this[_0x55eac0(0x114)][_0x55eac0(0x119)][_0x55eac0(0x139)](_0x22992d=>_0x22992d['id']===_0x19beec);if(!_0x18d192)return;const _0x3bff72=_0x18d192[_0x55eac0(0x118)][_0x55eac0(0x139)](_0x14934d=>_0x14934d['id']===_0x4d658f);_0x3bff72&&(_0x3bff72[_0x55eac0(0x120)]=_0xa8b99d,this[_0x55eac0(0x11b)](_0x55eac0(0xd9),{'sourceId':_0x19beec,'resourceId':_0x4d658f,'isInContext':_0xa8b99d}));}[_0x328029(0x10a)](_0x5509ea){const _0x55cadc=_0x328029;this[_0x55cadc(0xe6)][_0x55cadc(0x15b)](_0x5509ea,!0x0),this[_0x55cadc(0xe6)][_0x55cadc(0xd7)]&&this[_0x55cadc(0x11b)](_0x55cadc(0xf0),{'isUploadInProgress':!0x0});}[_0x328029(0x153)](_0x37b479){const _0x4d90a1=_0x328029;this[_0x4d90a1(0xe6)][_0x4d90a1(0x148)](_0x37b479),0x0===this[_0x4d90a1(0xe6)][_0x4d90a1(0xd7)]&&this[_0x4d90a1(0x11b)](_0x4d90a1(0xf0),{'isUploadInProgress':!0x1});}}
|
|
23
|
+
const _0xbb7b3c=_0x1fbd;(function(_0x140180,_0x81a41f){const _0x1de040=_0x1fbd,_0x59ecbd=_0x140180();while(!![]){try{const _0x1fcf35=parseInt(_0x1de040(0x1a7))/0x1*(parseInt(_0x1de040(0x134))/0x2)+-parseInt(_0x1de040(0x13d))/0x3*(-parseInt(_0x1de040(0x16f))/0x4)+parseInt(_0x1de040(0x1b0))/0x5+-parseInt(_0x1de040(0x1b1))/0x6+parseInt(_0x1de040(0x19c))/0x7+parseInt(_0x1de040(0x12a))/0x8+-parseInt(_0x1de040(0x181))/0x9;if(_0x1fcf35===_0x81a41f)break;else _0x59ecbd['push'](_0x59ecbd['shift']());}catch(_0x1eabcd){_0x59ecbd['push'](_0x59ecbd['shift']());}}}(_0x1e02,0x83d37));function _0x1fbd(_0x4a886a,_0x469974){const _0x1e025e=_0x1e02();return _0x1fbd=function(_0x1fbd52,_0x13c29e){_0x1fbd52=_0x1fbd52-0x126;let _0x862754=_0x1e025e[_0x1fbd52];return _0x862754;},_0x1fbd(_0x4a886a,_0x469974);}function _0x1e02(){const _0xcdd6dd=['sessionId','abort','ai-request-aborted','url','uploadUrl','file-','urls','_getCustomSourcesInitialState','_updateResourceInContextState','_pendingContextItems','fire','contextItemRemoved','_setAddContextOptionsDefaultState','selection','ai-chat-file-upload-failed','ai-chat-context-unsupported-type','string','get','files-','from','removeFromContext','2695084qVzhTc','_toggleAddCurrentDocumentOptionVisibility','loadSourceResources','object\x20with\x20content\x20and\x20type\x20properties','delete','ai-chat-resource-load-failed','MARKDOWN','all','_createContextItemFromContent','document','_addContextOptionsState','6adlgNb','HTML','_conversationContextItems','uploadProgressChanged','text/plain','getResources','ai-chat-source-resources-load-failed','map','find','576295ioUQEe','3467664fCxqvG','isCurrentDocumentInConversation','data','ai-chat-document-upload-failed','_finishUploadOperation','length','addUrlToContext','7623808YHJzFC','ai-chat-source-not-found','_startUploadOperation','sources','name','contextItemAdded','clearPendingContextItems','addCurrentDocumentToContext','abortController','isReadOnly','256694TCYPlX','_finishContextItemLoading','ai-chat-context-invalid-data','isHidden','type','end','TEXT','start','resources','10791QrHVlk','getId','values','addResourceToContext','updateCurrentDocument','uploadDocument','addSelectionToContext','code','resourceId','url-','getDocument','_connector','ai-chat-resource-no-data','_findSourceIdsByResourceId','message','getData','forEach','size','contextSent','_addToConversationContextItem','filter','stack','error','ai-chat-url-upload-failed','object','_ongoingUploadOperations','_ongoingUploads','mapContextItemsToRequestData','attributes','Current\x20document','label','getPendingContextItems','addContextOptionsChanged','addToConversationContext','has','File','set','_ownerId','isCurrentDocumentInContext','_config','uiId','push','hidden','FILE','sourceResourcesLoaded','getSentContextItems','_removeContextItem','resourceStateChanged','fetchDocument','isInContext','940VcGPkJ','isSelectionInContext','current-document','text/html','text/markdown','SELECTION','init','uploadFile','startsWith','_addContextItem','_convertTextResourceToFile','populateFromMessage','enabled','URL','removeSelectionFromContext','_mapContextItemToRequestData','contextItemLoadingEnded','files','17556489FQgtRi','DOCUMENT','content','version','_isResourceInContext','addFilesToContext'];_0x1e02=function(){return _0xcdd6dd;};return _0x1e02();}import{CKEditorError as _0x3ef10f,ObservableMixin as _0x55e1ec,uid as _0x427bda}from'ckeditor5/src/utils.js';import{AIContextItemType as _0x4a9210,AIContextTextResourceType as _0x2f602c}from'../../aicore/model/aicontext.js';import{escape as _0x2c3987}from'es-toolkit/compat';import{errorsMap as _0x1616ab}from'../../errorsmap.js';export const AI_CONTEXT_MODEL_EVENT_NAMES=[_0xbb7b3c(0x12f),_0xbb7b3c(0x192),_0xbb7b3c(0x17f),_0xbb7b3c(0x14f),_0xbb7b3c(0x153),_0xbb7b3c(0x15d),_0xbb7b3c(0x169),_0xbb7b3c(0x16c),_0xbb7b3c(0x1aa)];export class AIChatContext extends _0x55e1ec(){[_0xbb7b3c(0x148)];[_0xbb7b3c(0x164)];[_0xbb7b3c(0x162)];constructor({connector:_0x45de1b,config:_0x4fb355,ownerId:_0x53fd12}){const _0x30d61d=_0xbb7b3c;super(),this[_0x30d61d(0x148)]=_0x45de1b,this[_0x30d61d(0x164)]=_0x4fb355,this[_0x30d61d(0x162)]=_0x53fd12;}[_0xbb7b3c(0x175)](){const _0x4e26a4=_0xbb7b3c;this[_0x4e26a4(0x190)]=new Map(),this[_0x4e26a4(0x1a9)]=new Map(),this[_0x4e26a4(0x157)]=new Map(),this[_0x4e26a4(0x156)]=new Map(),this[_0x4e26a4(0x193)]();}[_0xbb7b3c(0x15c)](){const _0x29e9c5=_0xbb7b3c;return this[_0x29e9c5(0x190)];}async[_0xbb7b3c(0x17a)](_0x35edf6){const _0x53ff24=_0xbb7b3c,_0x3375d3=await this[_0x53ff24(0x1a4)](_0x35edf6);return this[_0x53ff24(0x150)](_0x3375d3),_0x53ff24(0x171)===_0x3375d3[_0x53ff24(0x165)]&&this[_0x53ff24(0x19d)](),_0x3375d3;}async[_0xbb7b3c(0x1a4)](_0x1e8b74){const _0x2a2d5d=_0xbb7b3c;if(_0x1e8b74[_0x2a2d5d(0x138)]===_0x4a9210[_0x2a2d5d(0x182)]){const _0x47af18=await this[_0x2a2d5d(0x148)][_0x2a2d5d(0x16d)](this[_0x2a2d5d(0x162)],_0x1e8b74['id'])[_0x2a2d5d(0x147)]();return{'id':_0x2a2d5d(0x171),'uiId':_0x2a2d5d(0x171),'label':_0x2a2d5d(0x15a),'type':_0x1e8b74[_0x2a2d5d(0x138)],'content':_0x47af18[_0x2a2d5d(0x183)],'hidden':this[_0x2a2d5d(0x1a9)][_0x2a2d5d(0x15f)](_0x2a2d5d(0x171)),'version':_0x47af18[_0x2a2d5d(0x159)]?.[_0x2a2d5d(0x184)],'sessionId':_0x47af18[_0x2a2d5d(0x159)]?.[_0x2a2d5d(0x187)]};}return{'id':_0x1e8b74['id'],'uiId':_0x1e8b74['id'],'label':_0x1e8b74[_0x2a2d5d(0x159)]?.[_0x2a2d5d(0x15b)]||_0x1e8b74[_0x2a2d5d(0x12e)]||_0x1e8b74[_0x2a2d5d(0x18a)]||_0x1e8b74['id'],'type':_0x1e8b74[_0x2a2d5d(0x138)],..._0x1e8b74?.[_0x2a2d5d(0x159)]?.[_0x2a2d5d(0x145)]?{'resourceId':_0x1e8b74[_0x2a2d5d(0x159)]?.[_0x2a2d5d(0x145)]}:{}};}[_0xbb7b3c(0x16a)](){const _0x828ddc=_0xbb7b3c;return new Map(this[_0x828ddc(0x1a9)]);}[_0xbb7b3c(0x19b)](_0x5c6081){const _0xa13f08=_0xbb7b3c,_0x86e0bf=this[_0xa13f08(0x190)][_0xa13f08(0x198)](_0x5c6081);_0x86e0bf?.[_0xa13f08(0x133)]||this[_0xa13f08(0x16b)](_0x5c6081);}[_0xbb7b3c(0x130)](){const _0x395b74=_0xbb7b3c;if(0x0===this[_0x395b74(0x190)][_0x395b74(0x14e)])return;for(const _0x2f52de of this[_0x395b74(0x190)][_0x395b74(0x13f)]())this[_0x395b74(0x16b)](_0x2f52de[_0x395b74(0x165)]);const _0xa35fb7=this[_0x395b74(0x1a9)][_0x395b74(0x198)](_0x395b74(0x171))||this[_0x395b74(0x190)][_0x395b74(0x198)](_0x395b74(0x171));_0xa35fb7&&this[_0x395b74(0x178)]({..._0xa35fb7,'isReadOnly':!0x0,'hidden':!0x0});}[_0xbb7b3c(0x15e)](_0x36251c){const _0x4cfcfc=_0xbb7b3c;for(const _0x11c8f5 of _0x36251c[_0x4cfcfc(0x13f)]())this[_0x4cfcfc(0x150)](_0x11c8f5);this[_0x4cfcfc(0x130)](),this[_0x4cfcfc(0x191)](_0x4cfcfc(0x14f),{'contextItems':Array[_0x4cfcfc(0x19a)](this[_0x4cfcfc(0x16a)]()[_0x4cfcfc(0x13f)]())});}[_0xbb7b3c(0x163)](){const _0x5a6fc2=_0xbb7b3c;return this[_0x5a6fc2(0x190)][_0x5a6fc2(0x15f)](_0x5a6fc2(0x171));}[_0xbb7b3c(0x170)](){const _0xbdb4f5=_0xbb7b3c;return this[_0xbdb4f5(0x190)][_0xbdb4f5(0x15f)](_0xbdb4f5(0x194));}[_0xbb7b3c(0x1b2)](){const _0x28dba3=_0xbb7b3c;return this[_0x28dba3(0x1a9)][_0x28dba3(0x15f)](_0x28dba3(0x171));}static[_0xbb7b3c(0x158)](_0x283c7a){const _0x5d350e=_0xbb7b3c;return Array[_0x5d350e(0x19a)](_0x283c7a[_0x5d350e(0x13f)]())[_0x5d350e(0x1ae)](_0x4ad786=>this[_0x5d350e(0x17e)](_0x4ad786))[_0x5d350e(0x151)](_0x3776c6=>null!==_0x3776c6);}async[_0xbb7b3c(0x186)](_0x334e8f,_0x150df7,_0x2b373f=_0x4a9210[_0xbb7b3c(0x168)]){const _0x3cdbc4=_0xbb7b3c,_0x5b2eaa=_0x3cdbc4(0x199)+_0x427bda();this[_0x3cdbc4(0x12c)](_0x5b2eaa);try{await Promise[_0x3cdbc4(0x1a3)](_0x334e8f[_0x3cdbc4(0x1ae)](async _0x18505f=>{const _0x58e02e=_0x3cdbc4,_0x2fe767=_0x58e02e(0x18c)+_0x427bda(),_0x7fdde3=_0x2c3987(_0x18505f[_0x58e02e(0x12e)]);try{this[_0x58e02e(0x178)]({'type':_0x2b373f,'label':_0x150df7?.[_0x58e02e(0x15b)]||_0x7fdde3,'uiId':_0x2fe767,'resourceId':_0x150df7?.[_0x58e02e(0x145)]},!0x0);const _0x234382=this[_0x58e02e(0x148)][_0x58e02e(0x176)](this[_0x58e02e(0x162)],_0x18505f,_0x150df7);this[_0x58e02e(0x157)][_0x58e02e(0x161)](_0x2fe767,_0x234382[_0x58e02e(0x132)]);const {id:_0x17dbc0}=await _0x234382[_0x58e02e(0x13e)]();this[_0x58e02e(0x157)][_0x58e02e(0x1a0)](_0x2fe767),this[_0x58e02e(0x135)]({'type':_0x2b373f,'id':_0x17dbc0,'label':_0x150df7?.[_0x58e02e(0x15b)]||_0x7fdde3,'uiId':_0x2fe767,'resourceId':_0x150df7?.[_0x58e02e(0x145)]},!0x1);}catch(_0xf85efd){this[_0x58e02e(0x157)][_0x58e02e(0x1a0)](_0x2fe767);if(!(_0xf85efd instanceof _0x3ef10f&&_0xf85efd[_0x58e02e(0x14b)][_0x58e02e(0x177)](_0x58e02e(0x189)))){const _0x3744ff=_0x1616ab[_0x58e02e(0x198)](_0xf85efd[_0x58e02e(0x144)])||_0x58e02e(0x195),_0x417374=new _0x3ef10f(_0x3744ff,null,{'fileName':_0x7fdde3,..._0xf85efd});_0x417374[_0x58e02e(0x152)]=_0xf85efd[_0x58e02e(0x152)],this[_0x58e02e(0x191)](_0x58e02e(0x153),{'error':_0x417374});}this[_0x58e02e(0x16b)](_0x2fe767);}}));}finally{this[_0x3cdbc4(0x127)](_0x5b2eaa);}}[_0xbb7b3c(0x131)](_0x1ca40b){const _0x4e0e77=_0xbb7b3c;if(this[_0x4e0e77(0x163)]())return;const _0x155b4f={'type':_0x4a9210[_0x4e0e77(0x182)],'uiId':_0x4e0e77(0x171),'label':_0x1ca40b,'isReadOnly':this[_0x4e0e77(0x1a9)][_0x4e0e77(0x15f)](_0x4e0e77(0x171)),'hidden':this[_0x4e0e77(0x1a9)][_0x4e0e77(0x15f)](_0x4e0e77(0x171))};this[_0x4e0e77(0x178)](_0x155b4f);}async[_0xbb7b3c(0x141)](_0xde3b5c,_0x57b6cb,_0x35ee60,_0x153f46){const _0x54f432=_0xbb7b3c,_0x204523=this[_0x54f432(0x190)][_0x54f432(0x198)](_0x54f432(0x171));if(_0x204523&&_0xde3b5c){_0x204523[_0x54f432(0x194)]=_0x153f46?_0x153f46[_0x54f432(0x1ae)](_0x2518ea=>({'start':_0x2518ea[_0x54f432(0x13b)],'end':_0x2518ea[_0x54f432(0x139)]})):[];try{if(_0x204523[_0x54f432(0x184)]===_0x57b6cb)return;const {id:_0x22ce16}=await this[_0x54f432(0x148)][_0x54f432(0x142)](this[_0x54f432(0x162)],_0xde3b5c,{'version':_0x57b6cb,'sessionId':_0x35ee60})[_0x54f432(0x13e)]();_0x204523['id']=_0x22ce16,_0x204523[_0x54f432(0x183)]=_0xde3b5c,_0x204523[_0x54f432(0x184)]=_0x57b6cb,_0x204523[_0x54f432(0x187)]=_0x35ee60;}catch(_0x2bf903){const _0x55a9e6=new _0x3ef10f(_0x54f432(0x126),null);_0x55a9e6[_0x54f432(0x152)]=_0x2bf903[_0x54f432(0x152)],this[_0x54f432(0x191)](_0x54f432(0x153),{'error':_0x55a9e6});}}}[_0xbb7b3c(0x143)](_0x43883e){const _0x3e764d=_0xbb7b3c;this[_0x3e764d(0x178)]({'type':_0x4a9210[_0x3e764d(0x174)],'label':_0x43883e,'uiId':_0x3e764d(0x194),'content':_0x43883e});}[_0xbb7b3c(0x17d)](){const _0x596234=_0xbb7b3c;this[_0x596234(0x16b)](_0x596234(0x194));}async[_0xbb7b3c(0x129)](_0x158e4a,_0x1ae8c6){const _0x4d801e=_0xbb7b3c,_0x294833=_0x4d801e(0x146)+_0x427bda();this[_0x4d801e(0x12c)](_0x294833);const _0x56435f=_0x4d801e(0x146)+_0x427bda();try{this[_0x4d801e(0x178)]({'type':_0x4a9210[_0x4d801e(0x17c)],'label':_0x1ae8c6?.[_0x4d801e(0x15b)]||_0x158e4a,'uiId':_0x56435f,'resourceId':_0x1ae8c6?.[_0x4d801e(0x145)]},!0x0);const _0x23c1b7=this[_0x4d801e(0x148)][_0x4d801e(0x18b)](this[_0x4d801e(0x162)],_0x158e4a,_0x1ae8c6);this[_0x4d801e(0x157)][_0x4d801e(0x161)](_0x56435f,_0x23c1b7[_0x4d801e(0x132)]);const {id:_0x290414}=await _0x23c1b7[_0x4d801e(0x13e)]();this[_0x4d801e(0x157)][_0x4d801e(0x1a0)](_0x56435f),this[_0x4d801e(0x135)]({'type':_0x4a9210[_0x4d801e(0x17c)],'id':_0x290414,'label':_0x1ae8c6?.[_0x4d801e(0x15b)]||_0x158e4a,'uiId':_0x56435f,'resourceId':_0x1ae8c6?.[_0x4d801e(0x145)]},!0x1);}catch(_0x4b38fa){this[_0x4d801e(0x157)][_0x4d801e(0x1a0)](_0x56435f),(_0x4b38fa[_0x4d801e(0x14b)][_0x4d801e(0x177)](_0x4d801e(0x189))||this[_0x4d801e(0x191)](_0x4d801e(0x153),{'error':new _0x3ef10f(_0x4d801e(0x154),this,{'url':_0x158e4a,'originalError':_0x4b38fa}),'url':_0x158e4a}),this[_0x4d801e(0x16b)](_0x56435f));}finally{this[_0x4d801e(0x127)](_0x294833);}}async[_0xbb7b3c(0x19e)](_0x246b47,_0x51ec6d,_0x552109){const _0x1fdfd4=_0xbb7b3c,_0x71726c=this[_0x1fdfd4(0x1a6)][_0x1fdfd4(0x12d)][_0x1fdfd4(0x1af)](_0x2f71b3=>_0x2f71b3['id']===_0x246b47);if(!_0x71726c)return this[_0x1fdfd4(0x191)](_0x1fdfd4(0x153),{'error':new _0x3ef10f(_0x1fdfd4(0x12b),this,{'sourceId':_0x246b47}),'sourceId':_0x246b47}),[];try{const _0x15a373=(await _0x71726c[_0x1fdfd4(0x1ac)](_0x51ec6d))[_0x1fdfd4(0x1ae)](_0x20798d=>{const _0x71d84d=_0x1fdfd4,_0x338a60=this[_0x71d84d(0x185)](_0x20798d['id']);return{..._0x20798d,'isInContext':_0x338a60};});return _0x71726c[_0x1fdfd4(0x13c)]=_0x15a373,this[_0x1fdfd4(0x191)](_0x1fdfd4(0x169),{'sourceId':_0x246b47,'source':_0x71726c,'resources':_0x15a373,'uid':_0x552109}),_0x15a373;}catch(_0x368c71){return this[_0x1fdfd4(0x191)](_0x1fdfd4(0x153),{'error':new _0x3ef10f(_0x1fdfd4(0x1ad),this,{'sourceId':_0x246b47,'originalError':_0x368c71}),'sourceId':_0x246b47,'sourceLabel':_0x71726c[_0x1fdfd4(0x15b)]}),[];}}async[_0xbb7b3c(0x140)](_0x45b820,_0x3e1a12){const _0x8f934b=_0xbb7b3c;if(this[_0x8f934b(0x185)](_0x3e1a12['id']))return;let _0x66144c=_0x3e1a12[_0x8f934b(0x1b3)];if(!_0x66144c&&_0x45b820[_0x8f934b(0x14c)])try{_0x66144c=await _0x45b820[_0x8f934b(0x14c)](_0x3e1a12['id']);}catch(_0x4243b9){return void this[_0x8f934b(0x191)](_0x8f934b(0x153),{'error':new _0x3ef10f(_0x8f934b(0x1a1),this,{'resourceId':_0x3e1a12['id'],'sourceId':_0x45b820['id'],'originalError':_0x4243b9}),'resourceId':_0x3e1a12['id'],'sourceId':_0x45b820['id']});}if(_0x66144c)switch(_0x3e1a12[_0x8f934b(0x138)]){case _0x4a9210[_0x8f934b(0x17c)]:if(_0x8f934b(0x197)!=typeof _0x66144c)return void this[_0x8f934b(0x191)](_0x8f934b(0x153),{'error':new _0x3ef10f(_0x8f934b(0x136),this,{'resourceId':_0x3e1a12['id'],'sourceId':_0x45b820['id'],'expectedType':_0x8f934b(0x197),'actualType':typeof _0x66144c}),'resourceId':_0x3e1a12['id'],'sourceId':_0x45b820['id']});await this[_0x8f934b(0x129)](_0x66144c,{'label':_0x3e1a12[_0x8f934b(0x15b)],'resourceId':_0x3e1a12['id']});break;case _0x4a9210[_0x8f934b(0x168)]:if(!(_0x66144c instanceof File))return void this[_0x8f934b(0x191)](_0x8f934b(0x153),{'error':new _0x3ef10f(_0x8f934b(0x136),this,{'resourceId':_0x3e1a12['id'],'sourceId':_0x45b820['id'],'expectedType':_0x8f934b(0x160),'actualType':typeof _0x66144c}),'resourceId':_0x3e1a12['id'],'sourceId':_0x45b820['id']});await this[_0x8f934b(0x186)]([_0x66144c],{'label':_0x3e1a12[_0x8f934b(0x15b)],'resourceId':_0x3e1a12['id']});break;case _0x4a9210[_0x8f934b(0x13a)]:if(_0x8f934b(0x155)!=typeof _0x66144c||!(_0x8f934b(0x183)in _0x66144c)||!(_0x8f934b(0x138)in _0x66144c))return void this[_0x8f934b(0x191)](_0x8f934b(0x153),{'error':new _0x3ef10f(_0x8f934b(0x136),this,{'resourceId':_0x3e1a12['id'],'sourceId':_0x45b820['id'],'expectedType':_0x8f934b(0x19f),'actualType':typeof _0x66144c}),'resourceId':_0x3e1a12['id'],'sourceId':_0x45b820['id']});_0x66144c=AIChatContext[_0x8f934b(0x179)](_0x66144c,_0x3e1a12[_0x8f934b(0x15b)]),await this[_0x8f934b(0x186)]([_0x66144c],{'label':_0x3e1a12[_0x8f934b(0x15b)],'resourceId':_0x3e1a12['id']},_0x4a9210[_0x8f934b(0x13a)]);break;default:this[_0x8f934b(0x191)](_0x8f934b(0x153),{'error':new _0x3ef10f(_0x8f934b(0x196),this,{'resourceId':_0x3e1a12['id'],'sourceId':_0x45b820['id'],'resourceType':_0x3e1a12[_0x8f934b(0x138)]}),'resourceId':_0x3e1a12['id'],'sourceId':_0x45b820['id']});}else this[_0x8f934b(0x191)](_0x8f934b(0x153),{'error':new _0x3ef10f(_0x8f934b(0x149),this,{'resourceId':_0x3e1a12['id'],'sourceId':_0x45b820['id']}),'resourceId':_0x3e1a12['id'],'sourceId':_0x45b820['id']});}static[_0xbb7b3c(0x179)](_0x2876f1,_0x513cba){const _0x30d71c=_0xbb7b3c;switch(_0x2876f1[_0x30d71c(0x138)]){case _0x2f602c[_0x30d71c(0x1a2)]:return new File([_0x2876f1[_0x30d71c(0x183)]],_0x513cba,{'type':_0x30d71c(0x173)});case _0x2f602c[_0x30d71c(0x1a8)]:return new File([_0x2876f1[_0x30d71c(0x183)]],_0x513cba,{'type':_0x30d71c(0x172)});default:return new File([_0x2876f1[_0x30d71c(0x183)]],_0x513cba,{'type':_0x30d71c(0x1ab)});}}static[_0xbb7b3c(0x17e)](_0x4029ed){const _0x2f5303=_0xbb7b3c;switch(_0x4029ed[_0x2f5303(0x138)]){case _0x4a9210[_0x2f5303(0x168)]:return{'type':_0x4a9210[_0x2f5303(0x168)],'id':_0x4029ed['id']};case _0x4a9210[_0x2f5303(0x17c)]:return{'type':_0x4a9210[_0x2f5303(0x17c)],'id':_0x4029ed['id']};case _0x4a9210[_0x2f5303(0x182)]:return{'type':_0x4a9210[_0x2f5303(0x182)],'id':_0x4029ed['id'],..._0x4029ed[_0x2f5303(0x194)]?.[_0x2f5303(0x128)]&&{'selection':_0x4029ed[_0x2f5303(0x194)]}};case _0x4a9210[_0x2f5303(0x13a)]:return{'type':_0x4a9210[_0x2f5303(0x168)],'id':_0x4029ed['id']};default:return null;}}[_0xbb7b3c(0x178)](_0x658b3d,_0x548990=!0x1){const _0x28cc92=_0xbb7b3c;if(this[_0x28cc92(0x190)][_0x28cc92(0x161)](_0x658b3d[_0x28cc92(0x165)],_0x658b3d),_0x658b3d[_0x28cc92(0x167)]||this[_0x28cc92(0x191)](_0x28cc92(0x12f),{'contextItem':_0x658b3d,'isLoading':_0x548990}),_0x28cc92(0x171)===_0x658b3d[_0x28cc92(0x165)]&&this[_0x28cc92(0x19d)](),_0x658b3d[_0x28cc92(0x145)]){const _0x3c13f9=this[_0x28cc92(0x14a)](_0x658b3d[_0x28cc92(0x145)]);_0x3c13f9&&_0x3c13f9[_0x28cc92(0x14d)](_0x17868e=>{const _0x23048d=_0x28cc92;this[_0x23048d(0x18f)](_0x17868e,_0x658b3d[_0x23048d(0x145)],!0x0);});}}[_0xbb7b3c(0x16b)](_0x41329f){const _0x4b12da=_0xbb7b3c,_0x22efd8=this[_0x4b12da(0x190)][_0x4b12da(0x198)](_0x41329f),_0x282502=this[_0x4b12da(0x157)][_0x4b12da(0x198)](_0x41329f);if(_0x282502&&(_0x282502[_0x4b12da(0x188)](),this[_0x4b12da(0x157)][_0x4b12da(0x1a0)](_0x41329f)),_0x22efd8?.[_0x4b12da(0x145)]){const _0x3e40b2=this[_0x4b12da(0x14a)](_0x22efd8[_0x4b12da(0x145)]);_0x3e40b2&&_0x3e40b2[_0x4b12da(0x14d)](_0x214675=>{const _0x1190de=_0x4b12da;this[_0x1190de(0x18f)](_0x214675,_0x22efd8[_0x1190de(0x145)],!0x1);});}this[_0x4b12da(0x190)][_0x4b12da(0x1a0)](_0x41329f),this[_0x4b12da(0x191)](_0x4b12da(0x192),{'uiId':_0x41329f,'type':_0x22efd8?.[_0x4b12da(0x138)]}),_0x4b12da(0x171)===_0x41329f&&this[_0x4b12da(0x19d)]();}[_0xbb7b3c(0x135)](_0x21ef3f,_0x197c98){const _0x5bccf4=_0xbb7b3c;if(this[_0x5bccf4(0x190)][_0x5bccf4(0x15f)](_0x21ef3f[_0x5bccf4(0x165)])&&(this[_0x5bccf4(0x190)][_0x5bccf4(0x161)](_0x21ef3f[_0x5bccf4(0x165)],_0x21ef3f),this[_0x5bccf4(0x191)](_0x5bccf4(0x17f),{'contextItem':_0x21ef3f,'isLoading':_0x197c98}),_0x21ef3f[_0x5bccf4(0x145)])){const _0x570a0b=this[_0x5bccf4(0x14a)](_0x21ef3f[_0x5bccf4(0x145)]);_0x570a0b&&_0x570a0b[_0x5bccf4(0x14d)](_0x5dcf23=>{const _0x9f8154=_0x5bccf4;this[_0x9f8154(0x18f)](_0x5dcf23,_0x21ef3f[_0x9f8154(0x145)],!0x0);});}}[_0xbb7b3c(0x150)](_0x170b5f){const _0x21bacd=_0xbb7b3c;this[_0x21bacd(0x1a9)][_0x21bacd(0x161)](_0x170b5f[_0x21bacd(0x165)],_0x170b5f);}[_0xbb7b3c(0x193)](){const _0x334c44=_0xbb7b3c;this[_0x334c44(0x1a6)]={'document':{'enabled':!0x1!==this[_0x334c44(0x164)]?.[_0x334c44(0x1a5)]?.[_0x334c44(0x17b)],'isHidden':!0x1},'urls':{'enabled':!0x1!==this[_0x334c44(0x164)]?.[_0x334c44(0x18d)]?.[_0x334c44(0x17b)]},'files':{'enabled':!0x1!==this[_0x334c44(0x164)]?.[_0x334c44(0x180)]?.[_0x334c44(0x17b)]},'sources':this[_0x334c44(0x18e)]()},this[_0x334c44(0x191)](_0x334c44(0x15d),{'options':this[_0x334c44(0x1a6)]});}[_0xbb7b3c(0x18e)](){const _0x5c6fa6=_0xbb7b3c;return this[_0x5c6fa6(0x164)]?.[_0x5c6fa6(0x12d)]?.[_0x5c6fa6(0x1ae)](_0x2633b4=>({..._0x2633b4,'resources':[]}))??[];}[_0xbb7b3c(0x19d)](){const _0x19ec12=_0xbb7b3c,_0x2c6c1d=this[_0x19ec12(0x163)]()||this[_0x19ec12(0x1b2)]();this[_0x19ec12(0x1a6)][_0x19ec12(0x1a5)][_0x19ec12(0x137)]=_0x2c6c1d,this[_0x19ec12(0x191)](_0x19ec12(0x15d),{'options':this[_0x19ec12(0x1a6)]});}[_0xbb7b3c(0x185)](_0x13b32f){const _0x3823b4=_0xbb7b3c;for(const _0x3514a7 of this[_0x3823b4(0x190)][_0x3823b4(0x13f)]())if(_0x3514a7[_0x3823b4(0x145)]===_0x13b32f)return!0x0;for(const _0x134ce7 of this[_0x3823b4(0x1a9)][_0x3823b4(0x13f)]())if(_0x134ce7[_0x3823b4(0x145)]===_0x13b32f)return!0x0;return!0x1;}[_0xbb7b3c(0x14a)](_0x3b42aa){const _0x56f859=_0xbb7b3c,_0x10d512=[];for(const _0x1724ad of this[_0x56f859(0x1a6)][_0x56f859(0x12d)]){_0x1724ad[_0x56f859(0x13c)][_0x56f859(0x1af)](_0x9542f9=>_0x9542f9['id']===_0x3b42aa)&&_0x10d512[_0x56f859(0x166)](_0x1724ad['id']);}return 0x0===_0x10d512[_0x56f859(0x128)]?null:_0x10d512;}[_0xbb7b3c(0x18f)](_0x3cee4d,_0x111dcc,_0x7246c5){const _0x283ae0=_0xbb7b3c,_0x16901f=this[_0x283ae0(0x1a6)][_0x283ae0(0x12d)][_0x283ae0(0x1af)](_0xb8cc24=>_0xb8cc24['id']===_0x3cee4d);if(!_0x16901f)return;const _0x571eb5=_0x16901f[_0x283ae0(0x13c)][_0x283ae0(0x1af)](_0x510211=>_0x510211['id']===_0x111dcc);_0x571eb5&&(_0x571eb5[_0x283ae0(0x16e)]=_0x7246c5,this[_0x283ae0(0x191)](_0x283ae0(0x16c),{'sourceId':_0x3cee4d,'resourceId':_0x111dcc,'isInContext':_0x7246c5}));}[_0xbb7b3c(0x12c)](_0x4299de){const _0x1489d3=_0xbb7b3c;this[_0x1489d3(0x156)][_0x1489d3(0x161)](_0x4299de,!0x0),this[_0x1489d3(0x156)][_0x1489d3(0x14e)]&&this[_0x1489d3(0x191)](_0x1489d3(0x1aa),{'isUploadInProgress':!0x0});}[_0xbb7b3c(0x127)](_0x301da1){const _0x2333dc=_0xbb7b3c;this[_0x2333dc(0x156)][_0x2333dc(0x1a0)](_0x301da1),0x0===this[_0x2333dc(0x156)][_0x2333dc(0x14e)]&&this[_0x2333dc(0x191)](_0x2333dc(0x1aa),{'isUploadInProgress':!0x1});}}
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const _0x2918e4=_0x1fb5;(function(_0x154c83,_0x572e8a){const _0x81527c=_0x1fb5,_0x4505b5=_0x154c83();while(!![]){try{const _0x5dbff6=-parseInt(_0x81527c(0x146))/0x1*(-parseInt(_0x81527c(0x12b))/0x2)+-parseInt(_0x81527c(0x17d))/0x3*(-parseInt(_0x81527c(0x11e))/0x4)+parseInt(_0x81527c(0x16c))/0x5*(parseInt(_0x81527c(0x13f))/0x6)+-parseInt(_0x81527c(0x148))/0x7+parseInt(_0x81527c(0x15e))/0x8*(-parseInt(_0x81527c(0x142))/0x9)+-parseInt(_0x81527c(0x164))/0xa*(-parseInt(_0x81527c(0x170))/0xb)+parseInt(_0x81527c(0x144))/0xc*(-parseInt(_0x81527c(0x136))/0xd);if(_0x5dbff6===_0x572e8a)break;else _0x4505b5['push'](_0x4505b5['shift']());}catch(_0x264982){_0x4505b5['push'](_0x4505b5['shift']());}}}(_0x4104,0xd3842));import{CKEditorError as _0x252a34,EmitterMixin as _0x15519f,logWarning as _0x6acb}from'ckeditor5/src/utils.js';import{AI_MODEL_EVENT_NAMES as _0x13ace8}from'../../aicore/model/aiinteraction.js';import{AIChatContext as _0x4a912c,AI_CONTEXT_MODEL_EVENT_NAMES as _0x2af3da}from'./aichatcontext.js';import{AICapabilities as _0x3b6257,CAPABILITIES_MODEL_EVENT_NAMES as _0x272746}from'../../aicore/model/aicapabilities.js';function _0x1fb5(_0x436924,_0x50806f){const _0x4104d1=_0x4104();return _0x1fb5=function(_0x1fb5b5,_0x393841){_0x1fb5b5=_0x1fb5b5-0x10c;let _0x3fbe1d=_0x4104d1[_0x1fb5b5];return _0x3fbe1d;},_0x1fb5(_0x436924,_0x50806f);}import{AIChatInteraction as _0x11a905}from'./aichatinteraction.js';import{errorsMap as _0x2d0718}from'../../errorsmap.js';export class AIChatConversation extends _0x15519f(){['id'];[_0x2918e4(0x14b)]=!0x1;[_0x2918e4(0x10f)]=[];[_0x2918e4(0x119)];[_0x2918e4(0x156)];[_0x2918e4(0x11d)];[_0x2918e4(0x125)];constructor(_0x25a574){const _0x545f5f=_0x2918e4;super(),this[_0x545f5f(0x125)]=_0x25a574,this[_0x545f5f(0x11d)]=_0x25a574[_0x545f5f(0x11d)],this[_0x545f5f(0x13d)]=_0x25a574[_0x545f5f(0x13d)],this['id']=_0x25a574[_0x545f5f(0x130)];}async[_0x2918e4(0x179)](_0x5d7c3d){const _0x11d1fe=_0x2918e4;try{this[_0x11d1fe(0x14e)]=new _0x4a912c({'connector':this[_0x11d1fe(0x11d)],'config':_0x5d7c3d,'ownerId':this['id']}),this[_0x11d1fe(0x14e)][_0x11d1fe(0x13e)](..._0x2af3da)['to'](this),this[_0x11d1fe(0x14e)][_0x11d1fe(0x179)](),this[_0x11d1fe(0x14c)]=new _0x3b6257(),this[_0x11d1fe(0x14c)][_0x11d1fe(0x13e)](..._0x272746)['to'](this),this[_0x11d1fe(0x14c)][_0x11d1fe(0x179)]();const _0x1868c8=await this[_0x11d1fe(0x13d)][_0x11d1fe(0x157)]();this[_0x11d1fe(0x114)](_0x11d1fe(0x153),{'availableModels':_0x1868c8});const _0x309348=await this[_0x11d1fe(0x13d)][_0x11d1fe(0x12c)](this[_0x11d1fe(0x125)][_0x11d1fe(0x14d)]);_0x309348&&await this[_0x11d1fe(0x16f)](_0x309348);}catch(_0x6e673e){const _0x52f86d=new _0x252a34(_0x11d1fe(0x173),null,{'message':_0x6e673e[_0x11d1fe(0x14a)]||_0x6e673e});_0x52f86d[_0x11d1fe(0x181)]=_0x6e673e[_0x11d1fe(0x181)],this[_0x11d1fe(0x114)](_0x11d1fe(0x112),{'error':_0x52f86d});}}async[_0x2918e4(0x15a)](){const _0xff85=_0x2918e4;if(this[_0xff85(0x14b)])throw new _0x252a34(_0xff85(0x163),null,{'conversation':this});if(!this[_0xff85(0x156)])throw new _0x252a34(_0xff85(0x16d),null,{'conversation':this});try{const {id:_0x3eee04}=await this[_0xff85(0x11d)][_0xff85(0x147)](this['id'],this[_0xff85(0x125)][_0xff85(0x13a)])[_0xff85(0x11f)]();this['id']=_0x3eee04,this[_0xff85(0x14b)]=!0x0,this[_0xff85(0x114)](_0xff85(0x160),{'conversationId':this['id'],'selectedModel':this[_0xff85(0x156)]});}catch(_0xbc480){const _0x19cc18=new _0x252a34(_0xff85(0x11b),null,{'message':_0xbc480[_0xff85(0x14a)],'conversationId':this['id']});throw _0x19cc18[_0xff85(0x181)]=_0xbc480[_0xff85(0x181)],this[_0xff85(0x114)](_0xff85(0x112),{'error':_0x19cc18}),_0x19cc18;}}async[_0x2918e4(0x17b)](_0x84635e,_0x2f5678){const _0x5dd5c1=_0x2918e4;try{const _0x24ec61=await this[_0x5dd5c1(0x11d)][_0x5dd5c1(0x171)](_0x84635e)[_0x5dd5c1(0x11f)](),_0x2cec1b=await this[_0x5dd5c1(0x11d)][_0x5dd5c1(0x155)](_0x84635e)[_0x5dd5c1(0x124)](),_0x27531b=_0x2cec1b[0x0][_0x5dd5c1(0x127)];this[_0x5dd5c1(0x14b)]=!0x0,this['id']=_0x24ec61['id'],_0x5dd5c1(0x117)in _0x24ec61?this[_0x5dd5c1(0x114)](_0x5dd5c1(0x135),_0x24ec61[_0x5dd5c1(0x117)],!0x0):this[_0x5dd5c1(0x114)](_0x5dd5c1(0x135),'',!0x0);const _0xeddf9b=(await this[_0x5dd5c1(0x13d)][_0x5dd5c1(0x149)]())[_0x5dd5c1(0x169)](_0x24ee58=>_0x24ee58['id'][_0x5dd5c1(0x172)]()===_0x27531b[_0x5dd5c1(0x172)]());return this[_0x5dd5c1(0x156)]=_0xeddf9b,this[_0x5dd5c1(0x114)](_0x5dd5c1(0x17f),{'selectedModel':_0xeddf9b,'isDisabled':!0x0}),await this[_0x5dd5c1(0x12e)](_0x2cec1b,_0x2f5678,_0x27531b),this[_0x5dd5c1(0x119)]=void 0x0,this;}catch(_0x4c8050){const _0x101985=new _0x252a34(_0x5dd5c1(0x16e),null,{'message':_0x4c8050[_0x5dd5c1(0x14a)],'conversationId':_0x84635e});throw _0x101985[_0x5dd5c1(0x181)]=_0x4c8050[_0x5dd5c1(0x181)],this[_0x5dd5c1(0x114)](_0x5dd5c1(0x112),{'error':_0x101985}),_0x101985;}}async[_0x2918e4(0x12e)](_0x376e15,_0xb33f85,_0x255820){const _0x16bf6b=_0x2918e4;let _0x3a068e;for(const _0x28cff7 of _0x376e15)if(_0x16bf6b(0x161)===_0x28cff7[_0x16bf6b(0x12d)]){const _0x4ab91d=await this[_0x16bf6b(0x165)](_0x28cff7),_0x7ee4f7={'isReasoningEnabled':Object[_0x16bf6b(0x16b)](_0x28cff7[_0x16bf6b(0x178)],_0x16bf6b(0x118)),'isWebSearchEnabled':Object[_0x16bf6b(0x16b)](_0x28cff7[_0x16bf6b(0x178)],_0x16bf6b(0x122))};_0x3a068e=this[_0x16bf6b(0x111)]({'userMessage':_0x28cff7[_0x16bf6b(0x162)],'contextItems':_0x4ab91d,'capabilities':_0x7ee4f7,'modelId':_0x255820,'quickActionData':_0x28cff7[_0x16bf6b(0x123)]?.[_0x16bf6b(0x150)]}),this[_0x16bf6b(0x119)]=_0x3a068e,this[_0x16bf6b(0x14e)][_0x16bf6b(0x129)](this[_0x16bf6b(0x119)][_0x16bf6b(0x133)]);}else{if(_0x16bf6b(0x131)===_0x28cff7[_0x16bf6b(0x12d)]&&_0x3a068e)for(const _0xd82aee of _0x28cff7[_0x16bf6b(0x132)]){const _0x1d4b91=_0x16bf6b(0x137)===_0xd82aee[_0x16bf6b(0x11a)]?_0x16bf6b(0x17e):_0x16bf6b(0x134),_0x1b0c1c=_0x3a068e[_0x16bf6b(0x10d)]()?.[_0x16bf6b(0x15b)]!==_0xb33f85;_0x3a068e[_0x16bf6b(0x10e)]=_0x3a068e[_0x16bf6b(0x143)]({'type':_0x1d4b91,'isDone':!0x0,'interactionId':_0x3a068e['id'],'areActionsDisabled':_0x1b0c1c}),_0x3a068e[_0x16bf6b(0x10e)][_0x16bf6b(0x175)](_0xd82aee[_0x16bf6b(0x132)]);}}}async[_0x2918e4(0x165)](_0x3a561e){const _0x632ec9=_0x2918e4,_0x40b6ee=new Map();if(!_0x3a561e[_0x632ec9(0x132)])return _0x40b6ee;for(const _0x5cdf1b of _0x3a561e[_0x632ec9(0x132)]){const _0x5df87f=await this[_0x632ec9(0x14e)][_0x632ec9(0x184)](_0x5cdf1b);_0x5df87f&&_0x40b6ee[_0x632ec9(0x158)](_0x5df87f['id'],_0x5df87f);}return _0x40b6ee;}async[_0x2918e4(0x138)]({userMessage:_0x21f69a,quickActionData:_0x134939}){const _0x584238=_0x2918e4;if(!this[_0x584238(0x14b)])throw new _0x252a34(_0x584238(0x168),null,{'conversation':this});if(this[_0x584238(0x119)])throw new _0x252a34(_0x584238(0x183),null,{'conversation':this});try{const _0x48e59b=this[_0x584238(0x14e)][_0x584238(0x174)](),_0x300c01=this[_0x584238(0x14c)][_0x584238(0x14f)](),_0xf68374=this[_0x584238(0x156)]['id'];this[_0x584238(0x119)]=this[_0x584238(0x111)]({'userMessage':_0x21f69a,'contextItems':_0x48e59b,'capabilities':_0x300c01,'modelId':_0xf68374,'quickActionData':_0x134939}),await this[_0x584238(0x119)][_0x584238(0x15a)](),this[_0x584238(0x14e)][_0x584238(0x129)](this[_0x584238(0x119)][_0x584238(0x133)]);}catch(_0x1ad73e){if(_0x1ad73e instanceof _0x252a34)this[_0x584238(0x114)](_0x584238(0x112),{'interactionId':this[_0x584238(0x119)]?this[_0x584238(0x119)]['id']:void 0x0,'error':_0x1ad73e});else{const _0x73f883=_0x2d0718[_0x584238(0x139)](_0x1ad73e[_0x584238(0x116)])||_0x584238(0x154);this[_0x584238(0x114)](_0x584238(0x112),{'interactionId':this[_0x584238(0x119)]?this[_0x584238(0x119)]['id']:void 0x0,'error':new _0x252a34(_0x73f883,null,{'error':_0x1ad73e})});}}finally{this[_0x584238(0x119)]?.[_0x584238(0x152)](),this[_0x584238(0x119)]=void 0x0;}}[_0x2918e4(0x111)]({userMessage:_0x3805ca,contextItems:_0x57bbf0,capabilities:_0x2f4a28,modelId:_0x218459,quickActionData:_0x1e91c6}){const _0x255876=_0x2918e4,_0x5ab138=new _0x11a905({'userMessage':_0x3805ca,'contextItems':_0x57bbf0,'capabilities':_0x2f4a28,'conversationId':this['id'],'connector':this[_0x255876(0x11d)],'editor':this[_0x255876(0x125)][_0x255876(0x13c)]&&this[_0x255876(0x125)][_0x255876(0x13c)](),'model':_0x218459,'quickActionData':_0x1e91c6});return _0x5ab138[_0x255876(0x13e)](..._0x13ace8)['to'](this),this[_0x255876(0x10f)][_0x255876(0x121)](_0x5ab138),this[_0x255876(0x114)](_0x255876(0x140),_0x5ab138),_0x5ab138;}[_0x2918e4(0x15f)](_0x1046b0){const _0x5aca5c=_0x2918e4;return this[_0x5aca5c(0x10f)][_0x5aca5c(0x169)](_0x298693=>_0x298693['id']===_0x1046b0);}[_0x2918e4(0x180)](_0x535d50){const _0x482345=_0x2918e4,_0x244630=this[_0x482345(0x15f)](_0x535d50);_0x244630&&(_0x244630[_0x482345(0x126)](),this[_0x482345(0x10f)][_0x482345(0x110)](this[_0x482345(0x10f)][_0x482345(0x141)](_0x244630),0x1));}get[_0x2918e4(0x115)](){const _0x2ad3ad=_0x2918e4;return this[_0x2ad3ad(0x10f)][this[_0x2ad3ad(0x10f)][_0x2ad3ad(0x15c)]-0x1];}[_0x2918e4(0x120)](_0x2ad8fa){const _0x5cb8bf=_0x2918e4;this[_0x5cb8bf(0x14e)][_0x5cb8bf(0x120)](_0x2ad8fa);}async[_0x2918e4(0x145)]({content:_0x16fc31,version:_0x16a91a,sessionId:_0x1c8515,selections:_0x52d347}){const _0xc3988=_0x2918e4;await this[_0xc3988(0x14e)][_0xc3988(0x166)](_0x16fc31,_0x16a91a,_0x1c8515,_0x52d347);}[_0x2918e4(0x128)](){const _0x273a86=_0x2918e4;return this[_0x273a86(0x119)]?.[_0x273a86(0x10d)]()?.[_0x273a86(0x132)]||'';}[_0x2918e4(0x12f)](_0x1c39b8){const _0x1d9eac=_0x2918e4;this[_0x1d9eac(0x14e)][_0x1d9eac(0x12f)](_0x1c39b8);}[_0x2918e4(0x159)](){const _0x18130d=_0x2918e4;this[_0x18130d(0x14e)][_0x18130d(0x159)]();}[_0x2918e4(0x12a)](_0x7e563){const _0x19c2d9=_0x2918e4;this[_0x19c2d9(0x14e)][_0x19c2d9(0x12a)](_0x7e563);}[_0x2918e4(0x13b)](_0x2abd1d){const _0xd89449=_0x2918e4;this[_0xd89449(0x14e)][_0xd89449(0x13b)](_0x2abd1d);}[_0x2918e4(0x167)](_0x17968f,_0x3c6973){const _0x4c66b9=_0x2918e4;this[_0x4c66b9(0x14e)][_0x4c66b9(0x167)](_0x17968f,_0x3c6973);}[_0x2918e4(0x151)](_0x5a92fd,_0x55f181,_0x145e7d){const _0x4dbe07=_0x2918e4;return this[_0x4dbe07(0x14e)][_0x4dbe07(0x151)](_0x5a92fd,_0x55f181,_0x145e7d);}[_0x2918e4(0x176)](_0x3d3d31){const _0x3addb8=_0x2918e4;this[_0x3addb8(0x14e)][_0x3addb8(0x176)](_0x3d3d31);}[_0x2918e4(0x113)](){const _0x9e3997=_0x2918e4;this[_0x9e3997(0x14c)][_0x9e3997(0x113)]();}[_0x2918e4(0x17a)](){const _0x36e64d=_0x2918e4;this[_0x36e64d(0x14c)][_0x36e64d(0x17a)]();}[_0x2918e4(0x177)](){const _0xa639e7=_0x2918e4;return this[_0xa639e7(0x14e)][_0xa639e7(0x177)]();}[_0x2918e4(0x15d)](){const _0x46fef2=_0x2918e4;return this[_0x46fef2(0x14e)][_0x46fef2(0x15d)]();}[_0x2918e4(0x11c)](){const _0x303138=_0x2918e4;return this[_0x303138(0x14e)][_0x303138(0x11c)]();}async[_0x2918e4(0x16f)](_0x14f78a){const _0x1f3738=_0x2918e4;_0x14f78a?!0x1===await this[_0x1f3738(0x13d)][_0x1f3738(0x16a)](_0x14f78a)&&(_0x6acb(_0x1f3738(0x182),{'conversation':this,'model':_0x14f78a}),_0x14f78a=(await this[_0x1f3738(0x13d)][_0x1f3738(0x157)]())[0x0]):(_0x6acb(_0x1f3738(0x10c),{'conversation':this}),_0x14f78a=(await this[_0x1f3738(0x13d)][_0x1f3738(0x157)]())[0x0]),_0x14f78a['id']!==this[_0x1f3738(0x156)]?.['id']&&(this[_0x1f3738(0x156)]=_0x14f78a,this[_0x1f3738(0x14c)][_0x1f3738(0x17c)](),this[_0x1f3738(0x114)](_0x1f3738(0x17f),{'selectedModel':_0x14f78a}));}}function _0x4104(){const _0x3bd68d=['interactions','splice','createInteraction','error','toggleWebSearch','fire','lastInteraction','code','title','reasoning','currentInteraction','type','ai-chat-conversation-start-failed','isSelectionInContext','connector','24884QomPAZ','getConversation','addCurrentDocumentToContext','push','webSearch','attributes','getMessages','options','destroy','model','getCurrentDocumentContext','addToConversationContext','addFilesToContext','19340PJetIj','getModel','role','_processMessagesToInteractions','addSelectionToContext','conversationId','assistant','content','contextItems','modification-delta','setConversationTitle','923XLLPgW','text','handleUserInteraction','get','group','addUrlToContext','getEditor','chatModels','delegate','821388jtXIhF','interactionCreated','indexOf','3951NXWlra','createReply','341148BmXcXV','updateCurrentDocumentInContext','147ONWOoq','startConversation','1326262BmipOf','getAll','message','isStarted','chatCapabilities','selectedModelId','chatContext','getCapabilitiesConfig','quickActionData','loadSourceResources','stop','conversationInitialized','ai-chat-handle-user-interaction-start-failed','fetchConversationMessages','selectedModel','getAvailableModels','set','removeSelectionFromContext','start','sessionId','length','isCurrentDocumentInConversation','14008TareRi','getInteraction','conversationStarted','user','prompt','ai-chat-conversation-already-started','11147600XzdbjA','_extractContextItems','updateCurrentDocument','addResourceToContext','ai-chat-handle-user-conversation-not-initialized','find','isAvailable','hasOwn','45YYARJd','ai-chat-conversation-start-no-model-selected','ai-chat-conversation-init-from-id-failed','setModel','11OCqInR','fetchConversation','toLowerCase','ai-chat-conversation-init-failed','getPendingContextItems','appendContent','removeFromContext','isCurrentDocumentInContext','capabilities','init','toggleReasoning','load','reset','36LQnwyP','text-delta','modelSelected','removeInteraction','stack','ai-chat-conversation-set-model-not-available','ai-chat-handle-user-interaction-already-in-progress','populateFromMessage','ai-chat-conversation-set-model-null','getDocumentContext','currentReply'];_0x4104=function(){return _0x3bd68d;};return _0x4104();}
|
|
23
|
+
const _0x462782=_0x2aee;(function(_0x16efdb,_0x2c3461){const _0xb9fc8d=_0x2aee,_0x37616a=_0x16efdb();while(!![]){try{const _0x44f70e=-parseInt(_0xb9fc8d(0x1ca))/0x1*(parseInt(_0xb9fc8d(0x1cf))/0x2)+-parseInt(_0xb9fc8d(0x1c2))/0x3*(parseInt(_0xb9fc8d(0x1a7))/0x4)+parseInt(_0xb9fc8d(0x209))/0x5+-parseInt(_0xb9fc8d(0x207))/0x6+parseInt(_0xb9fc8d(0x1f1))/0x7*(parseInt(_0xb9fc8d(0x1a6))/0x8)+-parseInt(_0xb9fc8d(0x1aa))/0x9*(-parseInt(_0xb9fc8d(0x1e0))/0xa)+parseInt(_0xb9fc8d(0x1ed))/0xb;if(_0x44f70e===_0x2c3461)break;else _0x37616a['push'](_0x37616a['shift']());}catch(_0x4e1295){_0x37616a['push'](_0x37616a['shift']());}}}(_0x2935,0x61702));import{CKEditorError as _0x4f6274,EmitterMixin as _0x1b7764,logWarning as _0x49e2ae}from'ckeditor5/src/utils.js';import{AI_MODEL_EVENT_NAMES as _0x786540}from'../../aicore/model/aiinteraction.js';import{AIChatContext as _0x36d193,AI_CONTEXT_MODEL_EVENT_NAMES as _0x447374}from'./aichatcontext.js';import{AICapabilities as _0x49baab,CAPABILITIES_MODEL_EVENT_NAMES as _0x20ddf4}from'../../aicore/model/aicapabilities.js';function _0x2935(){const _0x1b8818=['lastInteraction','assistant','8900045eobuhT','createInteraction','selectedModelId','setModel','21YlNjXw','ai-chat-handle-user-interaction-start-failed','selectedModel','length','contextItems','init','push','conversationStarted','interactions','addToConversationContext','fetchConversation','toggleReasoning','attributes','ai-chat-conversation-init-failed','getCapabilitiesConfig','chatModels','splice','options','ai-chat-conversation-set-model-null','isCurrentDocumentInContext','title','getAll','1816794bwkGAn','webSearch','2360050rOGaRF','getModel','modelSelected','getMessages','stop','toggleWebSearch','chatCapabilities','find','removeSelectionFromContext','getInteraction','chatContext','interactionCreated','modification-delta','getEditor','currentReply','getPendingContextItems','toLowerCase','addFilesToContext','reasoning','addResourceToContext','355176BQBztt','58772hYzrdl','quickActionData','populateFromMessage','918ryKIoC','currentInteraction','fire','content','isAvailable','message','ai-chat-conversation-start-no-model-selected','ai-chat-handle-user-conversation-not-initialized','set','_extractContextItems','loadSourceResources','updateCurrentDocument','role','appendContent','ai-chat-conversation-start-failed','handleUserInteraction','load','getCurrentDocumentContext','sessionId','capabilities','model','indexOf','delegate','ai-chat-handle-user-interaction-already-in-progress','117YoPIux','createReply','getDocumentContext','type','addUrlToContext','_processMessagesToInteractions','conversationInitialized','prompt','326110yPeETP','isSelectionInContext','user','conversationId','text','4UuIfsq','ai-chat-conversation-already-started','ai-chat-conversation-init-from-id-failed','updateCurrentDocumentInContext','addCurrentDocumentToContext','connector','ai-chat-conversation-set-model-not-available','fetchConversationMessages','start','getAvailableModels','addSelectionToContext','text-delta','reset','removeInteraction','code','stack','destroy','50280ULAkfK','startConversation','isStarted','hasOwn','group','get','isCurrentDocumentInConversation','getConversation','error','setConversationTitle','removeFromContext'];_0x2935=function(){return _0x1b8818;};return _0x2935();}import{AIChatInteraction as _0xb5d3a0}from'./aichatinteraction.js';function _0x2aee(_0x338dd5,_0xc1321b){const _0x293564=_0x2935();return _0x2aee=function(_0x2aee46,_0x5987ca){_0x2aee46=_0x2aee46-0x19c;let _0x23c685=_0x293564[_0x2aee46];return _0x23c685;},_0x2aee(_0x338dd5,_0xc1321b);}import{errorsMap as _0x3b3143}from'../../errorsmap.js';export class AIChatConversation extends _0x1b7764(){['id'];[_0x462782(0x1e2)]=!0x1;[_0x462782(0x1f9)]=[];[_0x462782(0x1ab)];[_0x462782(0x1f3)];[_0x462782(0x1d4)];[_0x462782(0x202)];constructor(_0x575a24){const _0x5a023c=_0x462782;super(),this[_0x5a023c(0x202)]=_0x575a24,this[_0x5a023c(0x1d4)]=_0x575a24[_0x5a023c(0x1d4)],this[_0x5a023c(0x200)]=_0x575a24[_0x5a023c(0x200)],this['id']=_0x575a24[_0x5a023c(0x1cd)];}async[_0x462782(0x1f6)](_0x51d141){const _0x4f9cca=_0x462782;try{this[_0x4f9cca(0x19c)]=new _0x36d193({'connector':this[_0x4f9cca(0x1d4)],'config':_0x51d141,'ownerId':this['id']}),this[_0x4f9cca(0x19c)][_0x4f9cca(0x1c0)](..._0x447374)['to'](this),this[_0x4f9cca(0x19c)][_0x4f9cca(0x1f6)](),this[_0x4f9cca(0x20f)]=new _0x49baab(),this[_0x4f9cca(0x20f)][_0x4f9cca(0x1c0)](..._0x20ddf4)['to'](this),this[_0x4f9cca(0x20f)][_0x4f9cca(0x1f6)]();const _0x52d52e=await this[_0x4f9cca(0x200)][_0x4f9cca(0x1d8)]();this[_0x4f9cca(0x1ac)](_0x4f9cca(0x1c8),{'availableModels':_0x52d52e});const _0x440fca=await this[_0x4f9cca(0x200)][_0x4f9cca(0x20a)](this[_0x4f9cca(0x202)][_0x4f9cca(0x1ef)]);_0x440fca&&await this[_0x4f9cca(0x1f0)](_0x440fca);}catch(_0x3b91b7){const _0x51e0d5=new _0x4f6274(_0x4f9cca(0x1fe),null,{'message':_0x3b91b7[_0x4f9cca(0x1af)]||_0x3b91b7});_0x51e0d5[_0x4f9cca(0x1de)]=_0x3b91b7[_0x4f9cca(0x1de)],this[_0x4f9cca(0x1ac)](_0x4f9cca(0x1e8),{'error':_0x51e0d5});}}async[_0x462782(0x1d7)](){const _0x1862cc=_0x462782;if(this[_0x1862cc(0x1e2)])throw new _0x4f6274(_0x1862cc(0x1d0),null,{'conversation':this});if(!this[_0x1862cc(0x1f3)])throw new _0x4f6274(_0x1862cc(0x1b0),null,{'conversation':this});try{const {id:_0xa73be1}=await this[_0x1862cc(0x1d4)][_0x1862cc(0x1e1)](this['id'],this[_0x1862cc(0x202)][_0x1862cc(0x1e4)])[_0x1862cc(0x1e7)]();this['id']=_0xa73be1,this[_0x1862cc(0x1e2)]=!0x0,this[_0x1862cc(0x1ac)](_0x1862cc(0x1f8),{'conversationId':this['id'],'selectedModel':this[_0x1862cc(0x1f3)]});}catch(_0x1cd5f4){const _0x53c1ec=new _0x4f6274(_0x1862cc(0x1b8),null,{'message':_0x1cd5f4[_0x1862cc(0x1af)],'conversationId':this['id']});throw _0x53c1ec[_0x1862cc(0x1de)]=_0x1cd5f4[_0x1862cc(0x1de)],this[_0x1862cc(0x1ac)](_0x1862cc(0x1e8),{'error':_0x53c1ec}),_0x53c1ec;}}async[_0x462782(0x1ba)](_0x591a20,_0x1499e0){const _0x190475=_0x462782;try{const _0x521ff8=await this[_0x190475(0x1d4)][_0x190475(0x1fb)](_0x591a20)[_0x190475(0x1e7)](),_0x486162=await this[_0x190475(0x1d4)][_0x190475(0x1d6)](_0x591a20)[_0x190475(0x20c)](),_0x38e2a9=_0x486162[0x0][_0x190475(0x1be)];this[_0x190475(0x1e2)]=!0x0,this['id']=_0x521ff8['id'],_0x190475(0x205)in _0x521ff8?this[_0x190475(0x1ac)](_0x190475(0x1e9),_0x521ff8[_0x190475(0x205)],!0x0):this[_0x190475(0x1ac)](_0x190475(0x1e9),'',!0x0);const _0x20e019=(await this[_0x190475(0x200)][_0x190475(0x206)]())[_0x190475(0x210)](_0x212a1f=>_0x212a1f['id'][_0x190475(0x1a2)]()===_0x38e2a9[_0x190475(0x1a2)]());return this[_0x190475(0x1f3)]=_0x20e019,this[_0x190475(0x1ac)](_0x190475(0x20b),{'selectedModel':_0x20e019,'isDisabled':!0x0}),await this[_0x190475(0x1c7)](_0x486162,_0x1499e0,_0x38e2a9),this[_0x190475(0x1ab)]=void 0x0,this;}catch(_0x10ff39){const _0x319e2a=new _0x4f6274(_0x190475(0x1d1),null,{'message':_0x10ff39[_0x190475(0x1af)],'conversationId':_0x591a20});throw _0x319e2a[_0x190475(0x1de)]=_0x10ff39[_0x190475(0x1de)],this[_0x190475(0x1ac)](_0x190475(0x1e8),{'error':_0x319e2a}),_0x319e2a;}}async[_0x462782(0x1c7)](_0x5cde5b,_0x2d0fed,_0x48b396){const _0x1c62f7=_0x462782;let _0x3c08f5;for(const _0x45e8a3 of _0x5cde5b)if(_0x1c62f7(0x1cc)===_0x45e8a3[_0x1c62f7(0x1b6)]){const _0x411247=await this[_0x1c62f7(0x1b3)](_0x45e8a3),_0x2dc265={'isReasoningEnabled':Object[_0x1c62f7(0x1e3)](_0x45e8a3[_0x1c62f7(0x1bd)],_0x1c62f7(0x1a4)),'isWebSearchEnabled':Object[_0x1c62f7(0x1e3)](_0x45e8a3[_0x1c62f7(0x1bd)],_0x1c62f7(0x208))};_0x3c08f5=this[_0x1c62f7(0x1ee)]({'userMessage':_0x45e8a3[_0x1c62f7(0x1c9)],'contextItems':_0x411247,'capabilities':_0x2dc265,'modelId':_0x48b396,'quickActionData':_0x45e8a3[_0x1c62f7(0x1fd)]?.[_0x1c62f7(0x1a8)]}),this[_0x1c62f7(0x1ab)]=_0x3c08f5,this[_0x1c62f7(0x19c)][_0x1c62f7(0x1fa)](this[_0x1c62f7(0x1ab)][_0x1c62f7(0x1f5)]);}else{if(_0x1c62f7(0x1ec)===_0x45e8a3[_0x1c62f7(0x1b6)]&&_0x3c08f5)for(const _0x1406ff of _0x45e8a3[_0x1c62f7(0x1ad)]){const _0x169c0b=_0x1c62f7(0x1ce)===_0x1406ff[_0x1c62f7(0x1c5)]?_0x1c62f7(0x1da):_0x1c62f7(0x19e),_0x34d19f=_0x3c08f5[_0x1c62f7(0x1c4)]()?.[_0x1c62f7(0x1bc)]!==_0x2d0fed;_0x3c08f5[_0x1c62f7(0x1a0)]=_0x3c08f5[_0x1c62f7(0x1c3)]({'type':_0x169c0b,'isDone':!0x0,'interactionId':_0x3c08f5['id'],'areActionsDisabled':_0x34d19f}),_0x3c08f5[_0x1c62f7(0x1a0)][_0x1c62f7(0x1b7)](_0x1406ff[_0x1c62f7(0x1ad)]);}}}async[_0x462782(0x1b3)](_0xe87cb9){const _0x3fddac=_0x462782,_0x27b3ab=new Map();if(!_0xe87cb9[_0x3fddac(0x1ad)])return _0x27b3ab;for(const _0x56caaf of _0xe87cb9[_0x3fddac(0x1ad)]){const _0x1b7d99=await this[_0x3fddac(0x19c)][_0x3fddac(0x1a9)](_0x56caaf);_0x1b7d99&&_0x27b3ab[_0x3fddac(0x1b2)](_0x1b7d99['id'],_0x1b7d99);}return _0x27b3ab;}async[_0x462782(0x1b9)]({userMessage:_0x3ec330,quickActionData:_0x3f6153}){const _0xe97bff=_0x462782;if(!this[_0xe97bff(0x1e2)])throw new _0x4f6274(_0xe97bff(0x1b1),null,{'conversation':this});if(this[_0xe97bff(0x1ab)])throw new _0x4f6274(_0xe97bff(0x1c1),null,{'conversation':this});try{const _0xdfa37f=this[_0xe97bff(0x19c)][_0xe97bff(0x1a1)](),_0xfafe76=this[_0xe97bff(0x20f)][_0xe97bff(0x1ff)](),_0x61963c=this[_0xe97bff(0x1f3)]['id'];this[_0xe97bff(0x1ab)]=this[_0xe97bff(0x1ee)]({'userMessage':_0x3ec330,'contextItems':_0xdfa37f,'capabilities':_0xfafe76,'modelId':_0x61963c,'quickActionData':_0x3f6153}),await this[_0xe97bff(0x1ab)][_0xe97bff(0x1d7)](),this[_0xe97bff(0x19c)][_0xe97bff(0x1fa)](this[_0xe97bff(0x1ab)][_0xe97bff(0x1f5)]);}catch(_0x26629f){if(_0x26629f instanceof _0x4f6274)this[_0xe97bff(0x1ac)](_0xe97bff(0x1e8),{'interactionId':this[_0xe97bff(0x1ab)]?this[_0xe97bff(0x1ab)]['id']:void 0x0,'error':_0x26629f});else{const _0x1dd677=_0x3b3143[_0xe97bff(0x1e5)](_0x26629f[_0xe97bff(0x1dd)])||_0xe97bff(0x1f2);this[_0xe97bff(0x1ac)](_0xe97bff(0x1e8),{'interactionId':this[_0xe97bff(0x1ab)]?this[_0xe97bff(0x1ab)]['id']:void 0x0,'error':new _0x4f6274(_0x1dd677,null,{'error':_0x26629f})});}}finally{this[_0xe97bff(0x1ab)]?.[_0xe97bff(0x20d)](),this[_0xe97bff(0x1ab)]=void 0x0;}}[_0x462782(0x1ee)]({userMessage:_0x420a88,contextItems:_0x1e8691,capabilities:_0x37e7af,modelId:_0x1e3761,quickActionData:_0x46c759}){const _0x26f933=_0x462782,_0x44bab2=new _0xb5d3a0({'userMessage':_0x420a88,'contextItems':_0x1e8691,'capabilities':_0x37e7af,'conversationId':this['id'],'connector':this[_0x26f933(0x1d4)],'editor':this[_0x26f933(0x202)][_0x26f933(0x19f)]&&this[_0x26f933(0x202)][_0x26f933(0x19f)](),'model':_0x1e3761,'quickActionData':_0x46c759});return _0x44bab2[_0x26f933(0x1c0)](..._0x786540)['to'](this),this[_0x26f933(0x1f9)][_0x26f933(0x1f7)](_0x44bab2),this[_0x26f933(0x1ac)](_0x26f933(0x19d),_0x44bab2),_0x44bab2;}[_0x462782(0x212)](_0x236b1c){const _0xaaa64c=_0x462782;return this[_0xaaa64c(0x1f9)][_0xaaa64c(0x210)](_0x158d4c=>_0x158d4c['id']===_0x236b1c);}[_0x462782(0x1dc)](_0x2692a6){const _0x315fb3=_0x462782,_0x5a6fb5=this[_0x315fb3(0x212)](_0x2692a6);_0x5a6fb5&&(_0x5a6fb5[_0x315fb3(0x1df)](),this[_0x315fb3(0x1f9)][_0x315fb3(0x201)](this[_0x315fb3(0x1f9)][_0x315fb3(0x1bf)](_0x5a6fb5),0x1));}get[_0x462782(0x1eb)](){const _0x567776=_0x462782;return this[_0x567776(0x1f9)][this[_0x567776(0x1f9)][_0x567776(0x1f4)]-0x1];}[_0x462782(0x1d3)](_0x46789c){const _0x54fa57=_0x462782;this[_0x54fa57(0x19c)][_0x54fa57(0x1d3)](_0x46789c);}async[_0x462782(0x1d2)]({content:_0x703bab,version:_0x3df005,sessionId:_0x409a15,selections:_0xaf0ce0}){const _0x153cef=_0x462782;await this[_0x153cef(0x19c)][_0x153cef(0x1b5)](_0x703bab,_0x3df005,_0x409a15,_0xaf0ce0);}[_0x462782(0x1bb)](){const _0xf484e9=_0x462782;return this[_0xf484e9(0x1ab)]?.[_0xf484e9(0x1c4)]()?.[_0xf484e9(0x1ad)]||'';}[_0x462782(0x1d9)](_0x2c6e50){const _0xeebd6d=_0x462782;this[_0xeebd6d(0x19c)][_0xeebd6d(0x1d9)](_0x2c6e50);}[_0x462782(0x211)](){const _0x560dbd=_0x462782;this[_0x560dbd(0x19c)][_0x560dbd(0x211)]();}[_0x462782(0x1a3)](_0x7061b1){const _0x19b799=_0x462782;this[_0x19b799(0x19c)][_0x19b799(0x1a3)](_0x7061b1);}[_0x462782(0x1c6)](_0x2941c0){const _0x1c4769=_0x462782;this[_0x1c4769(0x19c)][_0x1c4769(0x1c6)](_0x2941c0);}[_0x462782(0x1a5)](_0xab79f8,_0x26714e){const _0x382282=_0x462782;this[_0x382282(0x19c)][_0x382282(0x1a5)](_0xab79f8,_0x26714e);}[_0x462782(0x1b4)](_0x561af5,_0x1a8408,_0x49b070){const _0x3d0267=_0x462782;return this[_0x3d0267(0x19c)][_0x3d0267(0x1b4)](_0x561af5,_0x1a8408,_0x49b070);}[_0x462782(0x1ea)](_0x48d2dc){const _0x2674c9=_0x462782;this[_0x2674c9(0x19c)][_0x2674c9(0x1ea)](_0x48d2dc);}[_0x462782(0x20e)](){const _0x8d6fc4=_0x462782;this[_0x8d6fc4(0x20f)][_0x8d6fc4(0x20e)]();}[_0x462782(0x1fc)](){const _0x53cfb7=_0x462782;this[_0x53cfb7(0x20f)][_0x53cfb7(0x1fc)]();}[_0x462782(0x204)](){const _0x2c856f=_0x462782;return this[_0x2c856f(0x19c)][_0x2c856f(0x204)]();}[_0x462782(0x1e6)](){const _0x531097=_0x462782;return this[_0x531097(0x19c)][_0x531097(0x1e6)]();}[_0x462782(0x1cb)](){const _0x591f38=_0x462782;return this[_0x591f38(0x19c)][_0x591f38(0x1cb)]();}async[_0x462782(0x1f0)](_0x567229){const _0x55b9b7=_0x462782;_0x567229?!0x1===await this[_0x55b9b7(0x200)][_0x55b9b7(0x1ae)](_0x567229)&&(_0x49e2ae(_0x55b9b7(0x1d5),{'conversation':this,'model':_0x567229}),_0x567229=(await this[_0x55b9b7(0x200)][_0x55b9b7(0x1d8)]())[0x0]):(_0x49e2ae(_0x55b9b7(0x203),{'conversation':this}),_0x567229=(await this[_0x55b9b7(0x200)][_0x55b9b7(0x1d8)]())[0x0]),_0x567229['id']!==this[_0x55b9b7(0x1f3)]?.['id']&&(this[_0x55b9b7(0x1f3)]=_0x567229,this[_0x55b9b7(0x20f)][_0x55b9b7(0x1db)](),this[_0x55b9b7(0x1ac)](_0x55b9b7(0x20b),{'selectedModel':_0x567229}));}}
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
var
|
|
23
|
+
var _0xa0d1be=_0x1101;(function(_0x4fc4c7,_0x56852c){var _0x506d71=_0x1101,_0x7da897=_0x4fc4c7();while(!![]){try{var _0x29712d=parseInt(_0x506d71(0x1bc))/0x1*(-parseInt(_0x506d71(0x1b8))/0x2)+parseInt(_0x506d71(0x1a7))/0x3+parseInt(_0x506d71(0x1ad))/0x4+-parseInt(_0x506d71(0x1b9))/0x5*(-parseInt(_0x506d71(0x1ac))/0x6)+parseInt(_0x506d71(0x1a9))/0x7+-parseInt(_0x506d71(0x1a8))/0x8+-parseInt(_0x506d71(0x1b5))/0x9;if(_0x29712d===_0x56852c)break;else _0x7da897['push'](_0x7da897['shift']());}catch(_0x4cb68a){_0x7da897['push'](_0x7da897['shift']());}}}(_0x52f0,0xa7769));import{AICapabilities as _0x1a756a}from'../../aicore/model/aicapabilities.js';import{AIInteraction as _0x1c5631}from'../../aicore/model/aiinteraction.js';function _0x1101(_0x35b672,_0x10fae7){var _0x52f02c=_0x52f0();return _0x1101=function(_0x1101b0,_0x340f3b){_0x1101b0=_0x1101b0-0x1a6;var _0x5d5774=_0x52f02c[_0x1101b0];return _0x5d5774;},_0x1101(_0x35b672,_0x10fae7);}import{AIChatContext as _0x4a24d1}from'./aichatcontext.js';function _0x52f0(){var _0x1b8723=['current-document','capabilities','userMessage','getDocumentContext','model','queryAssistant','14132169hDgfxA','quickActionData','sendRequest','2YtDvUR','10YEIXGS','mapContextItemsToRequestData','getCapabilitiesRequestData','154006GESNni','get','3449196VkmgdU','3580328eBLbmg','6556858wvlevm','conversationId','contextItems','1529646LUTaPe','1045636HqOzLh','connector'];_0x52f0=function(){return _0x1b8723;};return _0x52f0();}export class AIChatInteraction extends _0x1c5631{[_0xa0d1be(0x1b1)];[_0xa0d1be(0x1aa)];[_0xa0d1be(0x1ab)]=new Map();[_0xa0d1be(0x1b3)];[_0xa0d1be(0x1b6)];constructor(_0x3c8cce){var _0x1bd4d8=_0xa0d1be;super(_0x3c8cce),this[_0x1bd4d8(0x1aa)]=_0x3c8cce[_0x1bd4d8(0x1aa)],this[_0x1bd4d8(0x1ab)]=_0x3c8cce[_0x1bd4d8(0x1ab)],this[_0x1bd4d8(0x1b0)]=_0x3c8cce[_0x1bd4d8(0x1b0)],this[_0x1bd4d8(0x1b1)]=_0x3c8cce[_0x1bd4d8(0x1b1)],this[_0x1bd4d8(0x1b3)]=_0x3c8cce[_0x1bd4d8(0x1b3)],this[_0x1bd4d8(0x1b6)]=_0x3c8cce[_0x1bd4d8(0x1b6)];}async[_0xa0d1be(0x1b7)](){var _0x4541ea=_0xa0d1be;return this[_0x4541ea(0x1ae)][_0x4541ea(0x1b4)]({'message':this[_0x4541ea(0x1b1)],'conversationId':this[_0x4541ea(0x1aa)],'parts':_0x4a24d1[_0x4541ea(0x1ba)](this[_0x4541ea(0x1ab)]),'capabilities':_0x1a756a[_0x4541ea(0x1bb)](this[_0x4541ea(0x1b0)]),'model':this[_0x4541ea(0x1b3)],'quickActionData':this[_0x4541ea(0x1b6)]});}[_0xa0d1be(0x1b2)](){var _0x101162=_0xa0d1be;return this[_0x101162(0x1ab)][_0x101162(0x1a6)](_0x101162(0x1af));}}
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
function _0x5997(_0x313fdf,_0x1a6ba8){const _0x1ed5af=_0x1ed5();return _0x5997=function(_0x5997df,_0x6579e3){_0x5997df=_0x5997df-0x128;let _0x1f4728=_0x1ed5af[_0x5997df];return _0x1f4728;},_0x5997(_0x313fdf,_0x1a6ba8);}function _0x1ed5(){const _0x76b2da=['capabilities','96827uhVEMv','264770WLkYiP','29424VFoCdJ','sort','enabled','110huJWNE','3411KhZeFv','filter','5304kTOxfc','6rKpgue','332035YCjPZb','1077566qyWjnn','113074HjYQGe','getAll','28zwTkvk','values','length'];_0x1ed5=function(){return _0x76b2da;};return _0x1ed5();}const _0x1fdd04=_0x5997;(function(_0x20682d,_0x584e98){const _0x486822=_0x5997,_0x5bd062=_0x20682d();while(!![]){try{const _0x209ddd=-parseInt(_0x486822(0x130))/0x1+parseInt(_0x486822(0x12a))/0x2+parseInt(_0x486822(0x132))/0x3*(parseInt(_0x486822(0x12c))/0x4)+-parseInt(_0x486822(0x128))/0x5+-parseInt(_0x486822(0x139))/0x6*(-parseInt(_0x486822(0x129))/0x7)+-parseInt(_0x486822(0x138))/0x8*(parseInt(_0x486822(0x136))/0x9)+-parseInt(_0x486822(0x131))/0xa*(-parseInt(_0x486822(0x135))/0xb);if(_0x209ddd===_0x584e98)break;else _0x5bd062['push'](_0x5bd062['shift']());}catch(_0x57c7f6){_0x5bd062['push'](_0x5bd062['shift']());}}}(_0x1ed5,0x1f96e));import{AIModels as _0x58b48a}from'../../aicore/model/aimodels.js';export class AIChatModels extends _0x58b48a{async[_0x1fdd04(0x12b)](){const _0x36d3f8=_0x1fdd04;return(await super[_0x36d3f8(0x12b)]())[_0x36d3f8(0x133)]((_0x4bb19c,_0xa9f2f0)=>{const _0x1713a1=_0x36d3f8,_0x27a5d8=Object[_0x1713a1(0x12d)](_0x4bb19c[_0x1713a1(0x12f)])[_0x1713a1(0x137)](_0x1e05b0=>_0x1e05b0[_0x1713a1(0x134)])[_0x1713a1(0x12e)];return Object[_0x1713a1(0x12d)](_0xa9f2f0[_0x1713a1(0x12f)])[_0x1713a1(0x137)](_0x356fe1=>_0x356fe1[_0x1713a1(0x134)])[_0x1713a1(0x12e)]-_0x27a5d8;});}}
|