@ckeditor/ckeditor5-ai 47.3.0-alpha.1 → 47.3.0-alpha.2
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-editor.css +0 -4
- package/dist/index.css +0 -4
- 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
- package/theme/aiquickactions/aiquickactions.css +0 -4
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
function _0x356a(){const _0x292d02=['getGroupId','_aiChatUi','removeSelectionFromContext','isOpen','add','setLoadingMessage','config','split','close','ai-no-track-changes','removeSelectionFromChatContext','map','_startConversationSafely','resource','mouseLeaveSuggestion','ai-chat-conversation-not-found','setSelectedModel','uiId','showFakeVisualSelection','ai-chat-invalid-request','_removeAISelectionMarkers','handleRemovedConversation','collaboration.channelId','_logError','AI_CHAT_UNTITLED_CONVERSATION','uid','_updateRatings','viewRangeToDom','TrackChanges','addCurrentDocumentToContext','marker','undo','modelSelected','replies','interactionStarted','addFeedItemAISuggestion','7622490NPnGuA','resourceId','setChangeGroupState','198rCjXfh','content','sourcePosition','query','ai-chat-context-file-too-large','contextItem','AI_CHAT_CONTEXT_INVALID_DATA','addFeedItemAIReply','fetchConversation','getDocumentContext','_toggleReasoning','ai-chat-conversation-init-failed','showPrevious','contextSent','_flushLastInteractionUI','activeConversation','options','removeContextItem','source','updateResourceState','node','push','findIndex','AI_CHAT_CONTEXT_FORM_DATA_SIZE_LIMITS_EXCEEDED','getChild','unshift','removeFeedInteraction','root','AI_CHAT_CONTEXT_FILE_TOO_MANY_PAGES','AI_CHAT_CONTEXT_UNABLE_TO_LOAD_RESOURCES','ai-chat-context-file-too-many-pages','init','_updateReplyContent','howMany','updateCapabilities','slice','addResourceToContext','like','isPremiumPlugin','_aiEditing','updateFeedItemAIReplySources','showDiff','getTransformedByOperation','AI_CHAT_UNABLE_TO_START_CONVERSATION','setFeedItemRenderingStrategy','capabilitiesUpdated','range','AI_CHAT_INVALID_REQUEST','_showConversationHistory','chat','_scrollToSuggestionRange','children','toString','28XhPYSl','ai.chat.context','dialogClosed','_batchToChanges','sendMessage','type','afterInit','stop','isCurrentDocumentInContext','toggleSuggestionDisplayMode','184FzFJAh','_aiChatModels','addFeedInteractionHeader','getSelectionText','AI_CHAT_RESOURCE_LOAD_FAILED','getAttribute','closeSourceResourceBalloon','ai-chat-controller-mouse-over','setContextItemLoading','interactionCreated','stopInteraction','scrollFeedToSuggestion','_previewedChangeGroup','createPositionFromPath','mapper','indexes','3440jDBslH','sendUserMessage','isCurrentDocumentInConversation','addFeedItemUserMessage','_createFromRanges','version','log','AI_CHAT_UNABLE_TO_LOAD_CONVERSATION','state','addSelectionToChatContext','updateFeedItemAIReplySuggestionContent','pending','interactionDestroyed','index','AI_CHAT_CONTEXT_UNSUPPORTED_FILE_TYPE','accepted','markers','412093AeougK','cloneNode','editing','_handleStartConversation','resources','open','isOfficialPlugin','1437828PHWXdb','_removeFromContext','isDisabled','_getDocumentRangeForReplyChanges','replyChangeGroupStateUpdated','pluginName','resizedTabs','partIndex','text-delta','clearPendingContextUI','updateConversationTitle','updateCurrentDocumentInContext','isDocumentOperation','AIEditing','uploadProgressChanged','start','getReply','anchorId','addDocumentToContext','ai-chat-conversation-start-failed','ai-chat-context-unsupported-type','sources','domConverter','current-document','createConversation','DocumentCompare','addOperation','ai-chat-context-unsupported-file-type','ai-chat-controller-no-active-conversation','view','rejected','streaming','getOperations','AI_CHAT_CONTEXT_FILE_TOO_LARGE','getRoot','commands','_applyOperationsAsSuggestions','history','ai-chat-file-upload-failed','setIsMaximized','setModel','startInteraction','baseVersion','revert','contextItemLoadingEnded','set','TrackChangesEditing','toViewRange','contextItems','activateTab','new','updateContent','rejectSuggestion','path','find','remove','removeFromContext','ai-chat-url-upload-failed','AI_CHAT_CONTEXT_CURRENT_DOCUMENT','_applySuggestion','getPath','documentContextContent','modification-delta','startConversation','getConversation','ready','conversationInitialized','main','forEach','ai-chat-context-form-data-size-limits-exceeded','AI_CHAT_CONTEXT_UNSUPPORTED_TYPE','showNext','resizeTabs','interactionId','144856kNltsS','model','hasChanges','document','hideFakeVisualSelection','replyId','context','getRanges','loadSourceResources','getContentParts','handleUserInteraction','selectModel','has','reasoningFinished','Liked\x20response','full','AI_CHAT_GENERIC_ERROR','alignToTop','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_FILE','redo','disableControls','filter','resetConversationTitle','changes','AITabs','contextItemRemoved','clearConversationContextUI','489422lWBvmg','updateFeedItemAIReplyContent','toggleWebSearch','interactionFinished','isInContext','error','Showing\x20conversation\x20history...','length','startAutoScroll','editors','ai-conversation-','ai.chat.models.defaultModelId','2YfjJsa','getFirstRange','addFeedItemStaticMessage','parse','ai-chat-resource-load-failed','_handleUIUserMessage','messageId','static','abortPromptStream','467886OacNSr','data','contextItemAdded','indexOf','nextSibling','from','setIsUploadInProgress','locale','resetMessageInput','_aiConnector','108gqkwDB','updateFeedItemAIReplySuggestionPartState','addContextOptionsChanged','getChildren','change','showChangeInText','data-id','toggleReasoning','toggleLoadingSkeleton','startsWith','ai-chat-missing-channel-id','stopListening','removed','ai-chat-context-invalid-data','focusPromptInput','sourceId','webSearchFinished','sourceResourcesLoaded','removeMarker','outdated','AI_BALLOON_HEADER_TITLE','ai.chat.models.displayedModels','ai-request-aborted','getDocumentData','getMarkersGroup','addFileToContext','_integrateEditor','_insertSuggestion','upsertAIChatRating','setAddContextOptions','_setIsMaximized','_balloonShowDiff','get','resize','rootName','selection','dislike','addContextItem','addFeedItemError','mouseOverSuggestion','message','finishInteraction','resourceStateChanged','loadConversation','Disliked\x20response','changeGroups','maxOffset','insertSuggestion','plugins','getChildAtOffset','applyOperation','_toggleWebSearch','AIConnector','addUrlToContext','isLoading','replyContentUpdated','selectedModel','AI_CHAT_ABORTED_MESSAGE','applySuggestion','ai.availableReplyActions','batch','addSelectionToContext','reasoningStarted','isUploadInProgress','setConversationContext','lastInteraction','webSearchStarted','setConversationTitle','$graveyard','createRange','AIChatUI','ai-chat-source-resources-load-failed','isModelAvailable','getInteractionAndReplyById','listenTo','getInteraction','populateSourceResourceBalloon','addFilesToContext','requires','getDiff','createPositionAt','_stopLastInteraction','enableControls','_openBalloonFor','AIChatController','end','delete','Undo','replyCreated','isStarted','load','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_URL'];_0x356a=function(){return _0x292d02;};return _0x356a();}const _0x1c0dea=_0x23a1;(function(_0x1350f8,_0x3c7929){const _0x15a389=_0x23a1,_0x425829=_0x1350f8();while(!![]){try{const _0x433b0e=parseInt(_0x15a389(0x258))/0x1*(-parseInt(_0x15a389(0x264))/0x2)+parseInt(_0x15a389(0x1f3))/0x3+-parseInt(_0x15a389(0x1cb))/0x4*(-parseInt(_0x15a389(0x1db))/0x5)+-parseInt(_0x15a389(0x26d))/0x6*(parseInt(_0x15a389(0x1c1))/0x7)+-parseInt(_0x15a389(0x23d))/0x8*(parseInt(_0x15a389(0x18c))/0x9)+parseInt(_0x15a389(0x189))/0xa+parseInt(_0x15a389(0x1ec))/0xb*(parseInt(_0x15a389(0x277))/0xc);if(_0x433b0e===_0x3c7929)break;else _0x425829['push'](_0x425829['shift']());}catch(_0xef9b7b){_0x425829['push'](_0x425829['shift']());}}}(_0x356a,0x64410));import{ContextPlugin as _0x3e87f6,Editor as _0x150232}from'ckeditor5/src/core.js';import{CKEditorError as _0xde8b51,logError as _0x30dde1,scrollViewportToShowTarget as _0x195785,uid as _0x449e24}from'ckeditor5/src/utils.js';import{AIConnector as _0x2e5232}from'../aicore/aiconnector.js';import{AITabs as _0x31b171}from'../aitabs/aitabs.js';import{AIChatConversation as _0x104747}from'./model/aichatconversation.js';import{getTranslation as _0xe4444a}from'../aicore/utils/common-translations.js';import{AI_VISUAL_SELECTION_MARKER_NAME as _0x49b4f9}from'../aicore/aiediting.js';import{AI_REPLY_ACTIONS as _0x5cac65}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';import{AIChatModels as _0x4be469}from'./model/aichatmodels.js';import{getEditorFromContext as _0x630f5f}from'../aicore/utils/geteditorfromcontext.js';import{DocumentCompare as _0x19255f,DATA_ID_MODEL_ATTRIBUTE as _0x58cf59}from'ckeditor5-collaboration/src/collaboration-core.js';import{fixMarkerOperationOldRange as _0x2cc6bc,getOperationsFromReply as _0x37b396}from'../aicore/utils/getoperationsfromreply.js';import{expandSelectionWithContext as _0x135333,getMinimalSelection as _0x2becb9}from'../aicore/utils/getsuggestionpartsfromreply.js';function _0x23a1(_0x32d790,_0x2763c6){const _0x356a09=_0x356a();return _0x23a1=function(_0x23a1a1,_0x5c99bb){_0x23a1a1=_0x23a1a1-0x144;let _0x58524d=_0x356a09[_0x23a1a1];return _0x58524d;},_0x23a1(_0x32d790,_0x2763c6);}import{ModelRange as _0x36cd98,_DetachOperation as _0xb1e712}from'ckeditor5/src/engine.js';import{findOne as _0xbce80a,getAttribute as _0x3f796b,serialize as _0x339428,Document as _0x429fd2,findByAttribute as _0x2805af}from'../aicore/utils/htmlparser.js';import{IconAI as _0x3c6a93}from'@ckeditor/ckeditor5-icons';import{AISuggestionContainerView as _0x33e40a}from'../aicore/ui/suggestioncontainer/aisuggestioncontainerview.js';import{AIBalloon as _0x3cc98e}from'../aiballoon/aiballoon.js';export class AIChatController extends _0x3e87f6{[_0x1c0dea(0x1b3)];[_0x1c0dea(0x276)];[_0x1c0dea(0x166)];[_0x1c0dea(0x1cc)];[_0x1c0dea(0x1c4)]=new Map();[_0x1c0dea(0x1d7)]=null;[_0x1c0dea(0x296)]=!0x1;static get[_0x1c0dea(0x157)](){return[_0x2e5232,_0x3cc98e,_0x19255f];}static get[_0x1c0dea(0x1f8)](){const _0x1eec80=_0x1c0dea;return _0x1eec80(0x15d);}static get[_0x1c0dea(0x1f2)](){return!0x0;}static get[_0x1c0dea(0x1b2)](){return!0x0;}[_0x1c0dea(0x1ab)](){const _0x1e4fb3=_0x1c0dea;this[_0x1e4fb3(0x276)]=this[_0x1e4fb3(0x243)][_0x1e4fb3(0x2a7)][_0x1e4fb3(0x297)](_0x1e4fb3(0x2ab)),this[_0x1e4fb3(0x166)]=this[_0x1e4fb3(0x243)][_0x1e4fb3(0x2a7)][_0x1e4fb3(0x297)](_0x1e4fb3(0x14f)),this[_0x1e4fb3(0x1b3)]=this[_0x1e4fb3(0x243)][_0x1e4fb3(0x2a7)][_0x1e4fb3(0x297)](_0x1e4fb3(0x200)),this[_0x1e4fb3(0x1cc)]=new _0x4be469({'connector':this[_0x1e4fb3(0x276)],'availableModels':this[_0x1e4fb3(0x243)][_0x1e4fb3(0x16b)][_0x1e4fb3(0x297)](_0x1e4fb3(0x28c)),'defaultModelId':this[_0x1e4fb3(0x243)][_0x1e4fb3(0x16b)][_0x1e4fb3(0x297)](_0x1e4fb3(0x263))});const _0x57b26e=this[_0x1e4fb3(0x243)][_0x1e4fb3(0x2a7)][_0x1e4fb3(0x297)](_0x1e4fb3(0x255));this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x232),()=>{const _0x6f4ffb=_0x1e4fb3;this[_0x6f4ffb(0x171)]();}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x1dc),(_0x276226,_0x2d42d3)=>{const _0x103211=_0x1e4fb3;this[_0x103211(0x269)]({'userMessage':_0x2d42d3});}),this[_0x1e4fb3(0x153)](_0x57b26e,_0x1e4fb3(0x1f9),(_0x28f411,_0x10f7da)=>{const _0x2b5838=_0x1e4fb3;this[_0x2b5838(0x295)](_0x10f7da);}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x23b),()=>{const _0x55b61a=_0x1e4fb3;_0x57b26e[_0x55b61a(0x298)]();}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x26c),async()=>{const _0x330e98=_0x1e4fb3;await this[_0x330e98(0x15a)](),await this[_0x330e98(0x19a)](),this[_0x330e98(0x16f)]();}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x205),()=>{const _0x34c680=_0x1e4fb3;this[_0x34c680(0x19b)]?.[_0x34c680(0x182)](_0xe4444a(this[_0x34c680(0x243)][_0x34c680(0x274)],_0x34c680(0x22d)));}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x290),(_0x3a0207,_0x44dff8)=>{const _0xd91dfa=_0x1e4fb3;this[_0xd91dfa(0x19b)]?.[_0xd91dfa(0x156)](Array[_0xd91dfa(0x272)](_0x44dff8));}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x2ac),(_0x147102,_0x5c0cda)=>{const _0x1d9c6c=_0x1e4fb3;this[_0x1d9c6c(0x19b)]?.[_0x1d9c6c(0x2ac)](_0x5c0cda);}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x1b0),(_0x199487,_0x5835b9)=>{const _0x153546=_0x1e4fb3;this[_0x153546(0x19b)]?.[_0x153546(0x1b0)](_0x5835b9[_0x153546(0x19e)],_0x5835b9[_0x153546(0x172)]);}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x19d),(_0xe8ef5c,_0x252503)=>{const _0x2ff56d=_0x1e4fb3;this[_0x2ff56d(0x1f4)](_0x252503);}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x245),(_0x1da2fe,_0x1022ff)=>{const _0x5e5a0a=_0x1e4fb3;this[_0x5e5a0a(0x19b)]?.[_0x5e5a0a(0x245)](_0x1022ff[_0x5e5a0a(0x286)],_0x1022ff[_0x5e5a0a(0x18f)],_0x1022ff[_0x5e5a0a(0x17e)]);}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x25a),()=>{const _0x1a5da2=_0x1e4fb3;this[_0x1a5da2(0x2aa)]();}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x27e),()=>{const _0x3e6ee8=_0x1e4fb3;this[_0x3e6ee8(0x196)]();}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x248),(_0x1ad8a9,_0x1952be)=>{const _0x209e4b=_0x1e4fb3;this[_0x209e4b(0x19b)]?.[_0x209e4b(0x21b)](_0x1952be);}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x1b1),(_0x147e52,{replyId:_0x4c1f16})=>{const _0x4ddb22=_0x1e4fb3;console[_0x4ddb22(0x1e1)](_0x4ddb22(0x24b),_0x4c1f16);}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x29b),(_0x39947f,{replyId:_0x1cce5e})=>{const _0x4d5450=_0x1e4fb3;console[_0x4d5450(0x1e1)](_0x4d5450(0x2a3),_0x1cce5e);}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x2a6),(_0x22cf15,_0x5d5a4d)=>{const _0x55cf4a=_0x1e4fb3;this[_0x55cf4a(0x243)][_0x55cf4a(0x2a7)][_0x55cf4a(0x297)](_0x3cc98e)[_0x55cf4a(0x16d)](),this[_0x55cf4a(0x292)](_0x5d5a4d);}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x27c),(_0x1eb6ba,{replyId:_0x2e4e37,partIndex:_0x1afd93})=>{const _0x4c795c=_0x1e4fb3;this[_0x4c795c(0x296)]=this[_0x4c795c(0x166)][_0x4c795c(0x1b5)],this[_0x4c795c(0x15c)](_0x2e4e37,_0x1afd93);}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x29e),(_0x2d0e8b,{replyId:_0x186f81,partIndex:_0x738561})=>{const _0x5cfb04=_0x1e4fb3,_0x2d6356=this[_0x5cfb04(0x1f6)](_0x186f81,_0x738561);_0x2d6356&&_0x5cfb04(0x14d)!=_0x2d6356[_0x5cfb04(0x1ba)][_0x5cfb04(0x1a7)][_0x5cfb04(0x299)]&&this[_0x5cfb04(0x1b3)][_0x5cfb04(0x177)]([_0x2d6356[_0x5cfb04(0x1ba)]],_0x5cfb04(0x1d2));}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x173),()=>{const _0xe75a3b=_0x1e4fb3;this[_0xe75a3b(0x1b3)][_0xe75a3b(0x241)](_0xe75a3b(0x1d2));}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x2b1),(_0x1572c1,_0x576a88)=>{const _0x4ada5d=_0x1e4fb3;this[_0x4ada5d(0x243)][_0x4ada5d(0x2a7)][_0x4ada5d(0x297)](_0x3cc98e)[_0x4ada5d(0x16d)](),this[_0x4ada5d(0x22e)](_0x576a88);}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x1ca),async(_0x5a3286,{replyId:_0x29392e,showDiff:_0x45a523})=>{const _0x271cc2=_0x1e4fb3,{reply:_0x351946}=this[_0x271cc2(0x152)](_0x29392e),_0x5838bf=_0x351946[_0x271cc2(0x246)]({'showDiff':_0x45a523});await this[_0x271cc2(0x166)][_0x271cc2(0x1e5)]({'id':_0x351946['id'],'parts':_0x5838bf,'renderingStrategy':_0x271cc2(0x26b)});}),this[_0x1e4fb3(0x153)](this[_0x1e4fb3(0x166)],_0x1e4fb3(0x227),(_0x1e882f,{replyId:_0x3816df,partIndex:_0x275d42})=>{const _0x2ea22e=_0x1e4fb3;this[_0x2ea22e(0x1d7)]?.[_0x2ea22e(0x242)]==_0x3816df&&this[_0x2ea22e(0x1d7)]?.[_0x2ea22e(0x1fa)]==_0x275d42&&this[_0x2ea22e(0x243)][_0x2ea22e(0x2a7)][_0x2ea22e(0x297)](_0x3cc98e)[_0x2ea22e(0x16d)]();const {reply:_0x3bce64}=this[_0x2ea22e(0x152)](_0x3816df);_0x3bce64[_0x2ea22e(0x18b)](_0x275d42,_0x2ea22e(0x211)),this[_0x2ea22e(0x1b3)][_0x2ea22e(0x241)](_0x2ea22e(0x1d2));});}async[_0x1c0dea(0x1c7)](){const _0x5e2c74=_0x1c0dea;this[_0x5e2c74(0x243)]instanceof _0x150232?this[_0x5e2c74(0x291)](this[_0x5e2c74(0x243)]):this[_0x5e2c74(0x153)](this[_0x5e2c74(0x243)][_0x5e2c74(0x261)],_0x5e2c74(0x169),(_0x367a2b,_0x4c7b3d)=>{const _0x4dabcd=_0x5e2c74;_0x4c7b3d['on'](_0x4dabcd(0x234),()=>{const _0x36a4c5=_0x4dabcd;this[_0x36a4c5(0x291)](_0x4c7b3d);});}),await this[_0x5e2c74(0x171)]();}[_0x1c0dea(0x292)](_0x9b418c){const _0x4d1d7c=_0x1c0dea,_0x1d6942=_0x630f5f(this[_0x4d1d7c(0x243)]);if(!_0x1d6942[_0x4d1d7c(0x2a7)][_0x4d1d7c(0x249)](_0x4d1d7c(0x181)))throw new _0xde8b51(_0x4d1d7c(0x16e),null);const _0x4a7a85=this[_0x4d1d7c(0x243)][_0x4d1d7c(0x2a7)][_0x4d1d7c(0x297)](_0x4d1d7c(0x20c)),{reply:_0x32c314,interaction:_0x309934}=this[_0x4d1d7c(0x152)](_0x9b418c[_0x4d1d7c(0x242)]),_0x7cedeb=this[_0x4d1d7c(0x1f6)](_0x9b418c[_0x4d1d7c(0x242)],_0x9b418c[_0x4d1d7c(0x1fa)]),_0x146433=void 0x0!==_0x9b418c[_0x4d1d7c(0x1fa)]?[_0x32c314[_0x4d1d7c(0x2a4)][_0x9b418c[_0x4d1d7c(0x1fa)]]]:_0x32c314[_0x4d1d7c(0x2a4)][_0x4d1d7c(0x252)](_0x45cfd6=>_0x4d1d7c(0x1e6)==_0x45cfd6[_0x4d1d7c(0x1e3)]),_0x325bf4=_0x146433[_0x4d1d7c(0x170)](_0x541829=>_0x32c314[_0x4d1d7c(0x2a4)][_0x4d1d7c(0x270)](_0x541829));if(!_0x7cedeb||_0x4d1d7c(0x14d)==_0x7cedeb[_0x4d1d7c(0x1ba)][_0x4d1d7c(0x1a7)][_0x4d1d7c(0x299)])return void _0x325bf4[_0x4d1d7c(0x237)](_0x438b8d=>_0x32c314[_0x4d1d7c(0x18b)](_0x438b8d,_0x4d1d7c(0x28a)));_0x325bf4[_0x4d1d7c(0x237)](_0x1976e9=>_0x32c314[_0x4d1d7c(0x18b)](_0x1976e9,_0x4d1d7c(0x1ea)));const _0x4003fa=_0x37b396({'editor':_0x1d6942,'reply':_0x32c314,'interaction':_0x309934,'groups':_0x146433,'transform':!0x0,'documentCompare':_0x4a7a85,'documentCompareOptions':{'anchor':_0x4d1d7c(0x236),'markDeletions':!0x0}});let _0x35d0a2;_0x7cedeb&&this[_0x4d1d7c(0x1be)](_0x7cedeb[_0x4d1d7c(0x1ba)]),_0x1d6942[_0x4d1d7c(0x23e)][_0x4d1d7c(0x27b)](_0x204878=>{const _0x5489ef=_0x4d1d7c;_0x35d0a2=_0x204878[_0x5489ef(0x145)],_0x1d6942[_0x5489ef(0x2a7)][_0x5489ef(0x297)](_0x5489ef(0x221))[_0x5489ef(0x217)](_0x4003fa),this[_0x5489ef(0x1b3)][_0x5489ef(0x241)](_0x5489ef(0x1d2));}),this[_0x4d1d7c(0x1c4)][_0x4d1d7c(0x220)](_0x35d0a2,{'interactionId':_0x309934['id'],'replyId':_0x32c314['id'],'indexes':_0x325bf4[_0x4d1d7c(0x1af)]()}),this[_0x4d1d7c(0x17f)](_0x32c314);}[_0x1c0dea(0x22e)](_0x569f69){const _0x36283c=_0x1c0dea,_0x1d3be8=_0x630f5f(this[_0x36283c(0x243)]),_0x4a1712=this[_0x36283c(0x243)][_0x36283c(0x2a7)][_0x36283c(0x297)](_0x19255f),{reply:_0x4a58f5,interaction:_0x43c42e}=this[_0x36283c(0x152)](_0x569f69[_0x36283c(0x242)]),_0x326494=this[_0x36283c(0x1f6)](_0x569f69[_0x36283c(0x242)],_0x569f69[_0x36283c(0x1fa)]),_0x37ba4e=void 0x0!==_0x569f69[_0x36283c(0x1fa)]?[_0x4a58f5[_0x36283c(0x2a4)][_0x569f69[_0x36283c(0x1fa)]]]:_0x4a58f5[_0x36283c(0x2a4)][_0x36283c(0x252)](_0x22e344=>_0x36283c(0x1e6)==_0x22e344[_0x36283c(0x1e3)]),_0x4a564b=_0x37ba4e[_0x36283c(0x170)](_0x427c34=>_0x4a58f5[_0x36283c(0x2a4)][_0x36283c(0x270)](_0x427c34));if(!_0x326494||_0x36283c(0x14d)==_0x326494[_0x36283c(0x1ba)][_0x36283c(0x1a7)][_0x36283c(0x299)])return void _0x4a564b[_0x36283c(0x237)](_0x50e6d7=>_0x4a58f5[_0x36283c(0x18b)](_0x50e6d7,_0x36283c(0x28a)));_0x4a564b[_0x36283c(0x237)](_0x2b7614=>_0x4a58f5[_0x36283c(0x18b)](_0x2b7614,_0x36283c(0x1ea)));const _0x326b5d=_0x37b396({'editor':_0x1d3be8,'reply':_0x4a58f5,'interaction':_0x43c42e,'groups':_0x37ba4e,'transform':!0x0,'documentCompare':_0x4a1712,'documentCompareOptions':{'anchor':_0x36283c(0x236),'markDeletions':!0x1}});let _0xcd870b;_0x326494&&this[_0x36283c(0x1be)](_0x326494[_0x36283c(0x1ba)]),_0x1d3be8[_0x36283c(0x23e)][_0x36283c(0x27b)](_0xca6ec0=>{const _0x39030d=_0x36283c;_0xcd870b=_0xca6ec0[_0x39030d(0x145)];for(const _0x16dfff of _0x326b5d)_0x16dfff[_0x39030d(0x21d)]=_0x1d3be8[_0x39030d(0x23e)][_0x39030d(0x240)][_0x39030d(0x1e0)],_0x2cc6bc(_0x1d3be8,_0x16dfff),_0xca6ec0[_0x39030d(0x145)][_0x39030d(0x20d)](_0x16dfff),_0x1d3be8[_0x39030d(0x23e)][_0x39030d(0x2a9)](_0x16dfff);}),this[_0x36283c(0x1c4)][_0x36283c(0x220)](_0xcd870b,{'interactionId':_0x43c42e['id'],'replyId':_0x4a58f5['id'],'indexes':_0x4a564b[_0x36283c(0x1af)]()}),this[_0x36283c(0x17f)](_0x4a58f5);}[_0x1c0dea(0x15c)](_0x586108,_0x146cb7){const _0x53e154=_0x1c0dea,_0x9b2f8d=_0x630f5f(this[_0x53e154(0x243)]),_0x284de4=this[_0x53e154(0x1f6)](_0x586108,_0x146cb7),_0x35eede=this[_0x53e154(0x243)][_0x53e154(0x2a7)][_0x53e154(0x297)](_0x3cc98e);if(!_0x284de4)return void _0x35eede[_0x53e154(0x16d)]();const {range:_0x2d6f03,currentIndex:_0x4f8bbf}=_0x284de4;if(_0x53e154(0x14d)==_0x2d6f03[_0x53e154(0x1a7)][_0x53e154(0x299)]){const {reply:_0x2ecba2}=this[_0x53e154(0x152)](_0x586108);return _0x2ecba2[_0x53e154(0x18b)](_0x4f8bbf,_0x53e154(0x28a)),void _0x35eede[_0x53e154(0x16d)]();}if(this[_0x53e154(0x1d7)]?.[_0x53e154(0x242)]==_0x586108&&this[_0x53e154(0x1d7)]?.[_0x53e154(0x1fa)]==_0x4f8bbf)return;this[_0x53e154(0x282)](_0x35eede),this[_0x53e154(0x1d7)]={'replyId':_0x586108,'partIndex':_0x4f8bbf};let _0x184bb2=_0x9b2f8d[_0x53e154(0x16b)][_0x53e154(0x297)](_0x53e154(0x144))||[..._0x5cac65];_0x9b2f8d[_0x53e154(0x2a7)][_0x53e154(0x249)](_0x53e154(0x181))||(_0x184bb2=_0x184bb2[_0x53e154(0x252)](_0x1d33e4=>_0x53e154(0x2a6)!=_0x1d33e4));const _0x3d1ff6=new _0x33e40a(_0x9b2f8d[_0x53e154(0x274)],{'showDiff':this[_0x53e154(0x296)],'areActionsDisabled':!0x1,'miniToolbarConfig':{'showChanges':_0x53e154(0x24c)},'hideHeader':!0x0,'availableActions':_0x184bb2});this[_0x53e154(0x282)](_0x3d1ff6);const {reply:_0x4b8439}=this[_0x53e154(0x152)](_0x586108),_0x3588d7=_0x4b8439[_0x53e154(0x246)]({'showDiff':this[_0x53e154(0x296)]})[_0x53e154(0x252)](_0x13a9fc=>_0x13a9fc[_0x53e154(0x23f)]),_0x8f720b=_0x3588d7[_0x53e154(0x1a2)](_0x3e5ed7=>_0x3e5ed7[_0x53e154(0x1e8)]==_0x4f8bbf);if(-0x1==_0x8f720b)return;const _0xc103c6=_0x3588d7[_0x8f720b],_0x3cf9ed=_0x3588d7['at']((_0x8f720b-0x1)%_0x3588d7[_0x53e154(0x25f)])?.[_0x53e154(0x1e8)],_0x328b7d=_0x3588d7['at']((_0x8f720b+0x1)%_0x3588d7[_0x53e154(0x25f)])?.[_0x53e154(0x1e8)];_0x3d1ff6[_0x53e154(0x226)]({'parts':[_0xc103c6],'renderingStrategy':_0x53e154(0x26b)});const _0x1ece30=_0x4f8bbf!==_0x3cf9ed;this[_0x53e154(0x1be)](_0x2d6f03,!0x0),_0x35eede[_0x53e154(0x1f1)]({'index':_0x4f8bbf,'title':_0xe4444a(this[_0x53e154(0x243)][_0x53e154(0x274)],_0x53e154(0x28b),(_0x8f720b+0x1)[_0x53e154(0x1c0)]()),'icon':_0x3c6a93,'mainView':_0x3d1ff6,'showRotator':_0x1ece30,'showApplyButton':!0x0,'showSuggestButton':_0x9b2f8d[_0x53e154(0x2a7)][_0x53e154(0x249)](_0x53e154(0x181)),'ranges':[_0x2d6f03]}),this[_0x53e154(0x166)][_0x53e154(0x1d6)](_0x586108,_0x4f8bbf),this[_0x53e154(0x153)](_0x3d1ff6,_0x53e154(0x1ca),(_0x554788,{showDiff:_0x551b9e})=>{const _0x4a49a3=_0x53e154;this[_0x4a49a3(0x296)]=_0x551b9e;const {reply:_0x1138d7}=this[_0x4a49a3(0x152)](_0x586108),_0x3e6f5d=_0x1138d7[_0x4a49a3(0x246)]({'showDiff':_0x551b9e,'groupIndex':_0x4f8bbf});_0x3d1ff6[_0x4a49a3(0x226)]({'parts':_0x3e6f5d,'renderingStrategy':_0x4a49a3(0x26b)});}),this[_0x53e154(0x153)](_0x35eede,_0x53e154(0x2b1),()=>{const _0x305460=_0x53e154;this[_0x305460(0x22e)]({'replyId':_0x586108,'partIndex':_0x4f8bbf}),_0x1ece30?this[_0x305460(0x15c)](_0x586108,_0x328b7d):_0x35eede[_0x305460(0x16d)]();}),this[_0x53e154(0x153)](_0x35eede,_0x53e154(0x2a6),()=>{const _0x1a7585=_0x53e154;this[_0x1a7585(0x292)]({'replyId':_0x586108,'partIndex':_0x4f8bbf}),_0x1ece30?this[_0x1a7585(0x15c)](_0x586108,_0x328b7d):_0x35eede[_0x1a7585(0x16d)]();}),_0x1ece30&&(this[_0x53e154(0x153)](_0x35eede,_0x53e154(0x23a),()=>{const _0x3cd660=_0x53e154;this[_0x3cd660(0x15c)](_0x586108,_0x328b7d);}),this[_0x53e154(0x153)](_0x35eede,_0x53e154(0x198),()=>{const _0x272a27=_0x53e154;this[_0x272a27(0x15c)](_0x586108,_0x3cf9ed);})),this[_0x53e154(0x153)](_0x35eede,_0x53e154(0x1c3),()=>{const _0x5a254c=_0x53e154;this[_0x5a254c(0x282)](_0x35eede),this[_0x5a254c(0x282)](_0x3d1ff6),this[_0x5a254c(0x1d7)]=null;});}[_0x1c0dea(0x1f6)](_0x11c1f4,_0x207ce7){const _0x1dcb54=_0x1c0dea,_0x5d8b7=_0x630f5f(this[_0x1dcb54(0x243)]),{reply:_0x5b3fd8,interaction:_0x12a2ef}=this[_0x1dcb54(0x152)](_0x11c1f4),_0x15e587=_0x5b3fd8[_0x1dcb54(0x2a4)][_0x1dcb54(0x252)](_0x5b2a14=>_0x1dcb54(0x1e6)==_0x5b2a14[_0x1dcb54(0x1e3)]),_0x294180=_0x15e587[_0x1dcb54(0x170)](_0x2d30fe=>_0x5b3fd8[_0x1dcb54(0x2a4)][_0x1dcb54(0x270)](_0x2d30fe));void 0x0===_0x207ce7&&(_0x207ce7=_0x294180[0x0]);const _0x2852f4=_0x294180[_0x1dcb54(0x270)](_0x207ce7);if(-0x1==_0x2852f4)return null;const _0x4452d9=_0x15e587[_0x2852f4],_0x49b4c6=new _0x429fd2([]),_0x224a6c=new _0x429fd2([]);for(const _0x39b9d1 of _0x4452d9[_0x1dcb54(0x254)])if(_0x1dcb54(0x283)!=_0x39b9d1[_0x1dcb54(0x1c6)]&&_0x224a6c[_0x1dcb54(0x1bf)][_0x1dcb54(0x1a1)](_0x39b9d1[_0x1dcb54(0x1a0)][_0x1dcb54(0x1ed)](!0x0)),_0x1dcb54(0x225)!=_0x39b9d1[_0x1dcb54(0x1c6)]){const _0xdeaedf=_0xbce80a(_0x50a3eb=>_0x3f796b(_0x50a3eb,_0x1dcb54(0x27d))==_0x39b9d1['id'],_0x5b3fd8[_0x1dcb54(0x230)],!0x0);_0x49b4c6[_0x1dcb54(0x1bf)][_0x1dcb54(0x1a1)](_0xdeaedf[_0x1dcb54(0x1ed)](!0x0));}if(0x0==_0x49b4c6[_0x1dcb54(0x1bf)][_0x1dcb54(0x25f)]){if(_0x4452d9[_0x1dcb54(0x254)][0x0][_0x1dcb54(0x204)]){const _0x52249f=_0x2805af(_0x1dcb54(0x27d),_0x4452d9[_0x1dcb54(0x254)][0x0][_0x1dcb54(0x204)],_0x5b3fd8[_0x1dcb54(0x230)]);_0x49b4c6[_0x1dcb54(0x1bf)][_0x1dcb54(0x1a5)](_0x52249f[_0x1dcb54(0x1ed)](!0x0)),_0x224a6c[_0x1dcb54(0x1bf)][_0x1dcb54(0x1a5)](_0x52249f[_0x1dcb54(0x1ed)](!0x0)),_0x52249f[_0x1dcb54(0x271)]&&(_0x49b4c6[_0x1dcb54(0x1bf)][_0x1dcb54(0x1a1)](_0x52249f[_0x1dcb54(0x271)][_0x1dcb54(0x1ed)](!0x0)),_0x224a6c[_0x1dcb54(0x1bf)][_0x1dcb54(0x1a1)](_0x52249f[_0x1dcb54(0x271)][_0x1dcb54(0x1ed)](!0x0)));}else{const _0x16f464=_0x5b3fd8[_0x1dcb54(0x230)][_0x1dcb54(0x1bf)][0x0];if(!_0x16f464)return null;_0x49b4c6[_0x1dcb54(0x1bf)][_0x1dcb54(0x1a1)](_0x16f464[_0x1dcb54(0x1ed)](!0x0)),_0x224a6c[_0x1dcb54(0x1bf)][_0x1dcb54(0x1a1)](_0x16f464[_0x1dcb54(0x1ed)](!0x0));}}const _0x2576ac=_0x12a2ef[_0x1dcb54(0x195)](),_0x3079c9=_0x5d8b7[_0x1dcb54(0x26e)][_0x1dcb54(0x267)](_0x2576ac[_0x1dcb54(0x18d)]),_0x56cd95=_0x339428(_0x49b4c6),_0x14dfe3=_0x5d8b7[_0x1dcb54(0x26e)][_0x1dcb54(0x267)](_0x56cd95),_0x2698c1=_0x5d8b7[_0x1dcb54(0x26e)][_0x1dcb54(0x267)](_0x56cd95),_0x384cc7=_0x5d8b7[_0x1dcb54(0x23e)][_0x1dcb54(0x159)](_0x14dfe3,0x0),_0x35f6b7=_0x339428(_0x224a6c),_0x495f87={'anchor':_0x384cc7,'markDeletions':!0x1},_0x594f1b=_0x5d8b7[_0x1dcb54(0x2a7)][_0x1dcb54(0x297)](_0x19255f)[_0x1dcb54(0x158)](_0x56cd95,_0x35f6b7,_0x495f87)[_0x1dcb54(0x213)]();if(!_0x594f1b[_0x1dcb54(0x25f)])return null;_0x5d8b7[_0x1dcb54(0x23e)][_0x1dcb54(0x27b)](_0x49fcb0=>{const _0x240dc7=_0x1dcb54;for(const _0x44451d of _0x594f1b)if(_0x240dc7(0x22a)==_0x44451d[_0x240dc7(0x1c6)]){const _0x56be69=_0x44451d[_0x240dc7(0x18e)],_0x55af39=_0x44451d[_0x240dc7(0x1ad)],_0x3a84f8=new _0xb1e712(_0x56be69,_0x55af39);_0x49fcb0[_0x240dc7(0x145)][_0x240dc7(0x20d)](_0x3a84f8),_0x5d8b7[_0x240dc7(0x23e)][_0x240dc7(0x2a9)](_0x3a84f8);}else _0x240dc7(0x183)!==_0x44451d[_0x240dc7(0x1c6)]&&(_0x44451d[_0x240dc7(0x21d)]=null,_0x44451d[_0x240dc7(0x1ff)]=!0x1,_0x49fcb0[_0x240dc7(0x145)][_0x240dc7(0x20d)](_0x44451d),_0x5d8b7[_0x240dc7(0x23e)][_0x240dc7(0x2a9)](_0x44451d));});const _0x496563=_0x2becb9(_0x5d8b7,_0x594f1b,_0x14dfe3);_0x135333(_0x5d8b7[_0x1dcb54(0x23e)],_0x496563);const _0x50b4b1=_0x496563[_0x1dcb54(0x265)]()[_0x1dcb54(0x202)][_0x1dcb54(0x228)][_0x1dcb54(0x1af)](),_0x50741d=_0x496563[_0x1dcb54(0x265)]()[_0x1dcb54(0x15e)][_0x1dcb54(0x228)][_0x1dcb54(0x1af)](),_0x2a891f=[];let _0x371d95=_0x14dfe3,_0x9f74e1=_0x2698c1;for(let _0x5c0b0e=0x0;_0x5c0b0e<_0x50741d[_0x1dcb54(0x25f)];_0x5c0b0e++){const _0x493d28=_0x371d95[_0x1dcb54(0x2a5)]-_0x50741d[_0x5c0b0e];_0x2a891f[_0x5c0b0e]=_0x9f74e1[_0x1dcb54(0x2a5)]-_0x493d28,_0x371d95=_0x371d95[_0x1dcb54(0x2a8)](_0x50741d[_0x5c0b0e]),_0x9f74e1=_0x9f74e1[_0x1dcb54(0x2a8)](_0x2a891f[_0x5c0b0e]);}const _0x55cd10=_0x5d8b7[_0x1dcb54(0x23e)][_0x1dcb54(0x14e)](_0x5d8b7[_0x1dcb54(0x23e)][_0x1dcb54(0x1d8)](_0x2698c1,_0x50b4b1),_0x5d8b7[_0x1dcb54(0x23e)][_0x1dcb54(0x1d8)](_0x2698c1,_0x2a891f)),_0x4b01b1=_0x2698c1[_0x1dcb54(0x1a4)](0x0)[_0x1dcb54(0x1d0)](_0x58cf59),_0x1e0470=Array[_0x1dcb54(0x272)](_0x3079c9[_0x1dcb54(0x27a)]())[_0x1dcb54(0x229)](_0x2cf97f=>_0x2cf97f[_0x1dcb54(0x1d0)](_0x58cf59)==_0x4b01b1)[_0x1dcb54(0x22f)](),_0x3298da=_0x55cd10[_0x1dcb54(0x202)][_0x1dcb54(0x228)][_0x1dcb54(0x1af)](),_0x1e9a78=_0x55cd10[_0x1dcb54(0x15e)][_0x1dcb54(0x228)][_0x1dcb54(0x1af)]();_0x3298da[0x0]=_0x1e0470[0x0]+_0x3298da[0x0],_0x1e9a78[0x0]=_0x1e0470[0x0]+_0x1e9a78[0x0];let _0x8f465d=_0x5d8b7[_0x1dcb54(0x23e)][_0x1dcb54(0x14e)](_0x5d8b7[_0x1dcb54(0x23e)][_0x1dcb54(0x1d8)](_0x5d8b7[_0x1dcb54(0x23e)][_0x1dcb54(0x240)][_0x1dcb54(0x215)](),_0x3298da),_0x5d8b7[_0x1dcb54(0x23e)][_0x1dcb54(0x1d8)](_0x5d8b7[_0x1dcb54(0x23e)][_0x1dcb54(0x240)][_0x1dcb54(0x215)](),_0x1e9a78));const _0x12a310=_0x5d8b7[_0x1dcb54(0x23e)][_0x1dcb54(0x240)][_0x1dcb54(0x218)][_0x1dcb54(0x213)](_0x2576ac[_0x1dcb54(0x1e0)]);for(const _0x3bd789 of _0x12a310)_0x8f465d=_0x36cd98[_0x1dcb54(0x1df)](_0x8f465d[_0x1dcb54(0x1b6)](_0x3bd789));return{'range':_0x8f465d,'currentIndex':_0x207ce7};}[_0x1c0dea(0x291)](_0x797ea5){const _0x2d1727=_0x1c0dea;if(!_0x797ea5[_0x2d1727(0x2a7)][_0x2d1727(0x249)](_0x2d1727(0x160)))return;const _0x357dfc=_0x797ea5[_0x2d1727(0x216)][_0x2d1727(0x297)](_0x2d1727(0x184)),_0x1bb580=_0x797ea5[_0x2d1727(0x216)][_0x2d1727(0x297)](_0x2d1727(0x250));this[_0x2d1727(0x153)](_0x357dfc,_0x2d1727(0x21e),(_0x46fe00,_0x471949,_0x27da0f)=>{const _0x12ae45=_0x2d1727,_0x14ede2=this[_0x12ae45(0x1c4)][_0x12ae45(0x297)](_0x471949);if(!_0x14ede2)return;const _0x328958=this[_0x12ae45(0x19b)][_0x12ae45(0x154)](_0x14ede2[_0x12ae45(0x23c)])[_0x12ae45(0x203)](_0x14ede2[_0x12ae45(0x242)]);_0x14ede2[_0x12ae45(0x1da)][_0x12ae45(0x237)](_0x560658=>_0x328958[_0x12ae45(0x18b)](_0x560658,_0x12ae45(0x1e6))),this[_0x12ae45(0x1c4)][_0x12ae45(0x15f)](_0x471949),this[_0x12ae45(0x1c4)][_0x12ae45(0x220)](_0x27da0f,_0x14ede2);}),this[_0x2d1727(0x153)](_0x1bb580,_0x2d1727(0x21e),(_0x48bea1,_0x5d2ed2,_0x417f64)=>{const _0x4fe5fa=_0x2d1727,_0x20e140=this[_0x4fe5fa(0x1c4)][_0x4fe5fa(0x297)](_0x5d2ed2);if(!_0x20e140)return;const _0x2b67cf=this[_0x4fe5fa(0x19b)][_0x4fe5fa(0x154)](_0x20e140[_0x4fe5fa(0x23c)])[_0x4fe5fa(0x203)](_0x20e140[_0x4fe5fa(0x242)]);_0x20e140[_0x4fe5fa(0x1da)][_0x4fe5fa(0x237)](_0x2e0249=>_0x2b67cf[_0x4fe5fa(0x18b)](_0x2e0249,_0x4fe5fa(0x1ea))),this[_0x4fe5fa(0x1c4)][_0x4fe5fa(0x15f)](_0x5d2ed2),this[_0x4fe5fa(0x1c4)][_0x4fe5fa(0x220)](_0x417f64,_0x20e140);});}async[_0x1c0dea(0x2a2)](_0x213b0a){const _0x3cab02=_0x1c0dea;this[_0x3cab02(0x243)][_0x3cab02(0x2a7)][_0x3cab02(0x297)](_0x3cc98e)[_0x3cab02(0x16d)](),this[_0x3cab02(0x166)][_0x3cab02(0x1b8)](_0x3cab02(0x26b)),this[_0x3cab02(0x166)][_0x3cab02(0x27f)](!0x0),await this[_0x3cab02(0x15a)]();try{await this[_0x3cab02(0x276)][_0x3cab02(0x194)](_0x213b0a)[_0x3cab02(0x233)](),await this[_0x3cab02(0x171)](_0x213b0a),this[_0x3cab02(0x1fd)]('\x20');const {sessionId:_0x2fe4bf}=this[_0x3cab02(0x1b3)][_0x3cab02(0x28e)]();await this[_0x3cab02(0x19b)][_0x3cab02(0x163)](_0x213b0a,_0x2fe4bf),this[_0x3cab02(0x19b)][_0x3cab02(0x1dd)]()&&this[_0x3cab02(0x19b)][_0x3cab02(0x182)](_0xe4444a(this[_0x3cab02(0x243)][_0x3cab02(0x274)],_0x3cab02(0x22d)));}catch(_0x2ca17f){this[_0x3cab02(0x166)][_0x3cab02(0x29d)]({'errorMessage':_0xe4444a(this[_0x3cab02(0x243)][_0x3cab02(0x274)],_0x3cab02(0x1e2)),'id':_0x213b0a}),this[_0x3cab02(0x17c)](new _0xde8b51(_0x3cab02(0x174),this,{'error':_0x2ca17f}));}finally{this[_0x3cab02(0x243)][_0x3cab02(0x2a7)][_0x3cab02(0x297)](_0x31b171)[_0x3cab02(0x210)][_0x3cab02(0x224)](_0x3cab02(0x1bd)),this[_0x3cab02(0x166)][_0x3cab02(0x260)](),this[_0x3cab02(0x166)][_0x3cab02(0x1b8)](_0x3cab02(0x212)),this[_0x3cab02(0x166)][_0x3cab02(0x27f)](!0x1);}}[_0x1c0dea(0x17a)](_0x8cd76d){const _0x4c4959=_0x1c0dea;this[_0x4c4959(0x19b)]['id']===_0x8cd76d&&this[_0x4c4959(0x171)]();}async[_0x1c0dea(0x1e4)](){const _0x37ccfd=_0x1c0dea,_0x324d11=this[_0x37ccfd(0x1b3)][_0x37ccfd(0x1ce)]();this[_0x37ccfd(0x19b)]?.[_0x37ccfd(0x146)](_0x324d11),this[_0x37ccfd(0x19b)]?.[_0x37ccfd(0x182)](_0xe4444a(this[_0x37ccfd(0x243)][_0x37ccfd(0x274)],_0x37ccfd(0x22d)));}[_0x1c0dea(0x16f)](){const _0x1daae2=_0x1c0dea;this[_0x1daae2(0x19b)]?.[_0x1daae2(0x167)]();}[_0x1c0dea(0x285)](){const _0xd14d68=_0x1c0dea;this[_0xd14d68(0x166)][_0xd14d68(0x285)]();}async[_0x1c0dea(0x232)](){const _0x6b7cde=_0x1c0dea;await this[_0x6b7cde(0x171)]();}async[_0x1c0dea(0x1c5)]({message:_0x387394,quickActionData:_0x14aeac}){const _0x490cd7=_0x1c0dea;await this[_0x490cd7(0x269)]({'userMessage':_0x387394,'quickActionData':_0x14aeac});}[_0x1c0dea(0x165)](){const _0x1e74af=_0x1c0dea,_0x47f271=this[_0x1e74af(0x243)][_0x1e74af(0x16b)][_0x1e74af(0x297)](_0x1e74af(0x17b));if(!_0x47f271)throw new _0xde8b51(_0x1e74af(0x281),this);return _0x47f271;}async[_0x1c0dea(0x171)](_0xaac946){const _0x2f713=_0x1c0dea;try{this[_0x2f713(0x166)][_0x2f713(0x15b)](),await this[_0x2f713(0x1ef)](_0xaac946);}catch(_0x431171){_0x30dde1(_0x2f713(0x206),_0x431171),this[_0x2f713(0x19b)]=void 0x0,this[_0x2f713(0x166)][_0x2f713(0x251)]();}}async[_0x1c0dea(0x1ef)](_0x6eb69e){const _0x2f7be9=_0x1c0dea,_0x488da7=this[_0x2f7be9(0x243)][_0x2f7be9(0x2a7)][_0x2f7be9(0x297)](_0x3cc98e);let _0x4520c4;_0x488da7[_0x2f7be9(0x168)]&&_0x488da7[_0x2f7be9(0x16d)](),_0x6eb69e||!this[_0x2f7be9(0x19b)]?_0x4520c4=this[_0x2f7be9(0x243)][_0x2f7be9(0x16b)][_0x2f7be9(0x297)](_0x2f7be9(0x263)):this[_0x2f7be9(0x166)][_0x2f7be9(0x151)]&&(_0x4520c4=this[_0x2f7be9(0x19b)][_0x2f7be9(0x2af)]['id']),await this[_0x2f7be9(0x15a)]();const _0x1be92a=this[_0x2f7be9(0x165)](),_0x2bd169=_0x6eb69e||_0x449e24();this[_0x2f7be9(0x19b)]=new _0x104747({'connector':this[_0x2f7be9(0x276)],'chatModels':this[_0x2f7be9(0x1cc)],'selectedModelId':_0x4520c4,'conversationId':_0x2bd169,'group':_0x1be92a,'getEditor':()=>_0x630f5f(this[_0x2f7be9(0x243)])}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x235),(_0x133c01,_0x226755)=>{const _0x12de3b=_0x2f7be9;this[_0x12de3b(0x166)][_0x12de3b(0x20b)](_0x226755),this[_0x12de3b(0x166)][_0x12de3b(0x275)](),this[_0x12de3b(0x166)][_0x12de3b(0x1fc)](),this[_0x12de3b(0x166)][_0x12de3b(0x257)](),_0x6eb69e||(this[_0x12de3b(0x166)][_0x12de3b(0x253)](),this[_0x12de3b(0x19b)]?.[_0x12de3b(0x182)](_0xe4444a(this[_0x12de3b(0x243)][_0x12de3b(0x274)],_0x12de3b(0x22d))));}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x201),(_0x152dbf,_0x55ccdf)=>{const _0x16a52d=_0x2f7be9;this[_0x16a52d(0x166)][_0x16a52d(0x273)](_0x55ccdf[_0x16a52d(0x148)]);}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x1d4),(_0x5d3147,_0x3ff7d5)=>{const _0x49c38f=_0x2f7be9;this[_0x49c38f(0x166)][_0x49c38f(0x1de)](_0x3ff7d5);}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x14b),()=>{const _0x53be67=_0x2f7be9;this[_0x53be67(0x166)][_0x53be67(0x16a)]({'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x147),()=>{const _0x1aa01d=_0x2f7be9;this[_0x1aa01d(0x166)][_0x1aa01d(0x16a)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x287),(_0x935ee5,_0x57ec94)=>{const _0x41b6a9=_0x2f7be9;this[_0x41b6a9(0x166)][_0x41b6a9(0x1cd)](_0x57ec94,{'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x24a),(_0x5d011f,_0xe15c96)=>{const _0x483361=_0x2f7be9;this[_0x483361(0x166)][_0x483361(0x1cd)](_0xe15c96,{'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x187),()=>{const _0x4d655c=_0x2f7be9;this[_0x4d655c(0x166)][_0x4d655c(0x21c)]();}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x25b),async()=>{const _0x485e6a=_0x2f7be9;await this[_0x485e6a(0x166)][_0x485e6a(0x2a0)]();}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x1e7),(_0x3b7a77,_0xa186f6)=>{const _0x34982e=_0x2f7be9;this[_0x34982e(0x166)][_0x34982e(0x1a6)](_0xa186f6['id']);}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x14c),(_0x320ffe,_0x50ac59,_0x3e8901)=>{const _0x20fa22=_0x2f7be9;this[_0x20fa22(0x1fd)](_0x50ac59,_0x3e8901);}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x161),(_0xb840ce,_0x10bd1f)=>{const _0x2c8de3=_0x2f7be9;_0x2c8de3(0x1fb)===_0x10bd1f[_0x2c8de3(0x1c6)]?this[_0x2c8de3(0x166)][_0x2c8de3(0x193)](_0x10bd1f):this[_0x2c8de3(0x166)][_0x2c8de3(0x188)](_0x10bd1f);}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x2ae),async(_0x25fa0d,_0x540c31)=>{const _0x425a93=_0x2f7be9;await this[_0x425a93(0x1ac)]({'reply':_0x540c31});}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x1f7),(_0x47de61,{reply:_0x2d38cd,index:_0x132358,state:_0x1a4ac4})=>{const _0x3debf9=_0x2f7be9;this[_0x3debf9(0x166)][_0x3debf9(0x278)]({'id':_0x2d38cd['id'],'index':_0x132358,'state':_0x1a4ac4});}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x26f),(_0x481223,_0x48e54c)=>{const _0x25acbd=_0x2f7be9;if(this[_0x25acbd(0x166)][_0x25acbd(0x29c)](_0x48e54c[_0x25acbd(0x191)],_0x48e54c[_0x25acbd(0x2ad)]),_0x25acbd(0x29a)===_0x48e54c[_0x25acbd(0x191)][_0x25acbd(0x1c6)]){const _0x40da1b=[..._0x630f5f(this[_0x25acbd(0x243)])[_0x25acbd(0x23e)][_0x25acbd(0x240)][_0x25acbd(0x29a)][_0x25acbd(0x244)]()];this[_0x25acbd(0x1b3)][_0x25acbd(0x177)](_0x40da1b,_0x25acbd(0x262)+this[_0x25acbd(0x19b)]?.['id']);}}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x256),(_0x4f415b,_0x22b519)=>{const _0x5e397e=_0x2f7be9;this[_0x5e397e(0x166)][_0x5e397e(0x19d)](_0x22b519[_0x5e397e(0x176)]),_0x5e397e(0x20a)==_0x22b519[_0x5e397e(0x176)]&&this[_0x5e397e(0x16f)](),_0x5e397e(0x29a)===_0x22b519[_0x5e397e(0x1c6)]&&this[_0x5e397e(0x1b3)][_0x5e397e(0x241)](_0x5e397e(0x262)+this[_0x5e397e(0x19b)]?.['id']);}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x21f),(_0x3e9d0a,_0x550cb8)=>{const _0x53a457=_0x2f7be9;this[_0x53a457(0x166)][_0x53a457(0x1d3)](_0x550cb8[_0x53a457(0x191)][_0x53a457(0x176)],_0x550cb8[_0x53a457(0x2ad)]);}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x199),(_0xcda1c9,_0x1c03eb)=>{const _0x436501=_0x2f7be9;this[_0x436501(0x166)][_0x436501(0x149)](_0x1c03eb[_0x436501(0x223)]);}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x279),(_0x1e213d,_0x4f916c)=>{const _0x1930cb=_0x2f7be9;this[_0x1930cb(0x166)][_0x1930cb(0x294)](_0x4f916c[_0x1930cb(0x19c)]);}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x288),(_0x5a62cc,_0x3cd9f8)=>{const _0x363df3=_0x2f7be9;this[_0x363df3(0x166)][_0x363df3(0x155)](_0x3cd9f8[_0x363df3(0x286)],_0x3cd9f8[_0x363df3(0x19e)],_0x3cd9f8[_0x363df3(0x1f0)],_0x3cd9f8[_0x363df3(0x17e)]);}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x2a1),(_0x5d4e95,_0x2d7b61)=>{const _0xd3fe24=_0x2f7be9;this[_0xd3fe24(0x166)][_0xd3fe24(0x19f)](_0x2d7b61[_0xd3fe24(0x286)],_0x2d7b61[_0xd3fe24(0x18a)],_0x2d7b61[_0xd3fe24(0x25c)]);}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x1b9),(_0x57e82d,_0x3cd582)=>{const _0x3eec08=_0x2f7be9;this[_0x3eec08(0x166)][_0x3eec08(0x1ae)](_0x3cd582);}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x185),(_0xa2128d,_0x55e311)=>{const _0xf7b66=_0x2f7be9;this[_0xf7b66(0x166)][_0xf7b66(0x175)](_0x55e311[_0xf7b66(0x2af)],_0x55e311[_0xf7b66(0x1f5)]);}),this[_0x2f7be9(0x19b)]['on'](_0x2f7be9(0x25d),(_0x54598a,{error:_0x46280f,interactionId:_0x3f4ce2,fileName:_0x114f8f,url:_0x4b234d,sourceId:_0x4b33cd,sourceLabel:_0x508bf8})=>{const _0x57d8cd=_0x2f7be9,_0x370041=_0x3f4ce2?_0x3f4ce2+':'+_0x449e24():_0x449e24();_0x46280f[_0x57d8cd(0x29f)][_0x57d8cd(0x280)](_0x57d8cd(0x28d))?this[_0x57d8cd(0x166)][_0x57d8cd(0x266)]({'staticMessage':_0xe4444a(this[_0x57d8cd(0x243)][_0x57d8cd(0x274)],_0x57d8cd(0x2b0)),'id':_0x370041}):_0x46280f[_0x57d8cd(0x29f)][_0x57d8cd(0x280)](_0x57d8cd(0x197))||_0x46280f[_0x57d8cd(0x29f)][_0x57d8cd(0x280)](_0x57d8cd(0x206))?(this[_0x57d8cd(0x166)][_0x57d8cd(0x29d)]({'errorMessage':_0xe4444a(this[_0x57d8cd(0x243)][_0x57d8cd(0x274)],_0x57d8cd(0x1b7)),'id':_0x370041}),this[_0x57d8cd(0x17c)](_0x46280f)):_0x46280f[_0x57d8cd(0x29f)][_0x57d8cd(0x280)](_0x57d8cd(0x219))?this[_0x57d8cd(0x166)][_0x57d8cd(0x29d)]({'errorMessage':_0xe4444a(this[_0x57d8cd(0x243)][_0x57d8cd(0x274)],_0x57d8cd(0x24f),_0x114f8f),'id':_0x370041}):_0x46280f[_0x57d8cd(0x29f)][_0x57d8cd(0x280)](_0x57d8cd(0x22c))?this[_0x57d8cd(0x166)][_0x57d8cd(0x29d)]({'errorMessage':_0xe4444a(this[_0x57d8cd(0x243)][_0x57d8cd(0x274)],_0x57d8cd(0x164),_0x4b234d),'id':_0x370041}):_0x46280f[_0x57d8cd(0x29f)][_0x57d8cd(0x280)](_0x57d8cd(0x284))?this[_0x57d8cd(0x166)][_0x57d8cd(0x29d)]({'errorMessage':_0xe4444a(this[_0x57d8cd(0x243)][_0x57d8cd(0x274)],_0x57d8cd(0x192)),'id':_0x370041}):_0x46280f[_0x57d8cd(0x29f)][_0x57d8cd(0x280)](_0x57d8cd(0x207))?this[_0x57d8cd(0x166)][_0x57d8cd(0x29d)]({'errorMessage':_0xe4444a(this[_0x57d8cd(0x243)][_0x57d8cd(0x274)],_0x57d8cd(0x239)),'id':_0x370041}):_0x46280f[_0x57d8cd(0x29f)][_0x57d8cd(0x280)](_0x57d8cd(0x150))?(_0x4b33cd&&this[_0x57d8cd(0x166)][_0x57d8cd(0x1d1)](_0x4b33cd),this[_0x57d8cd(0x166)][_0x57d8cd(0x29d)]({'errorMessage':_0xe4444a(this[_0x57d8cd(0x243)][_0x57d8cd(0x274)],_0x57d8cd(0x1a9),_0x508bf8||_0x57d8cd(0x19e)),'id':_0x370041}),this[_0x57d8cd(0x17c)](_0x46280f)):_0x46280f[_0x57d8cd(0x29f)][_0x57d8cd(0x280)](_0x57d8cd(0x268))?(this[_0x57d8cd(0x166)][_0x57d8cd(0x29d)]({'errorMessage':_0xe4444a(this[_0x57d8cd(0x243)][_0x57d8cd(0x274)],_0x57d8cd(0x1cf)),'id':_0x370041}),this[_0x57d8cd(0x17c)](_0x46280f)):_0x46280f[_0x57d8cd(0x29f)][_0x57d8cd(0x280)](_0x57d8cd(0x178))?(this[_0x57d8cd(0x166)][_0x57d8cd(0x29d)]({'errorMessage':_0xe4444a(this[_0x57d8cd(0x243)][_0x57d8cd(0x274)],_0x57d8cd(0x1bb)),'id':_0x370041}),this[_0x57d8cd(0x17c)](_0x46280f)):_0x46280f[_0x57d8cd(0x29f)][_0x57d8cd(0x280)](_0x57d8cd(0x20e))?(this[_0x57d8cd(0x166)][_0x57d8cd(0x29d)]({'errorMessage':_0xe4444a(this[_0x57d8cd(0x243)][_0x57d8cd(0x274)],_0x57d8cd(0x1e9)),'id':_0x370041}),this[_0x57d8cd(0x17c)](_0x46280f)):_0x46280f[_0x57d8cd(0x29f)][_0x57d8cd(0x280)](_0x57d8cd(0x190))?(this[_0x57d8cd(0x166)][_0x57d8cd(0x29d)]({'errorMessage':_0xe4444a(this[_0x57d8cd(0x243)][_0x57d8cd(0x274)],_0x57d8cd(0x214)),'id':_0x370041}),this[_0x57d8cd(0x17c)](_0x46280f)):_0x46280f[_0x57d8cd(0x29f)][_0x57d8cd(0x280)](_0x57d8cd(0x1aa))?(this[_0x57d8cd(0x166)][_0x57d8cd(0x29d)]({'errorMessage':_0xe4444a(this[_0x57d8cd(0x243)][_0x57d8cd(0x274)],_0x57d8cd(0x1a8)),'id':_0x370041}),this[_0x57d8cd(0x17c)](_0x46280f)):_0x46280f[_0x57d8cd(0x29f)][_0x57d8cd(0x280)](_0x57d8cd(0x238))?(this[_0x57d8cd(0x166)][_0x57d8cd(0x29d)]({'errorMessage':_0xe4444a(this[_0x57d8cd(0x243)][_0x57d8cd(0x274)],_0x57d8cd(0x1a3)),'id':_0x370041}),this[_0x57d8cd(0x17c)](_0x46280f)):(this[_0x57d8cd(0x166)][_0x57d8cd(0x29d)]({'errorMessage':_0xe4444a(this[_0x57d8cd(0x243)][_0x57d8cd(0x274)],_0x57d8cd(0x24d)),'id':_0x370041}),this[_0x57d8cd(0x17c)](_0x46280f));}),await this[_0x2f7be9(0x19b)][_0x2f7be9(0x1ab)](this[_0x2f7be9(0x243)][_0x2f7be9(0x16b)][_0x2f7be9(0x297)](_0x2f7be9(0x1c2))),_0x6eb69e||await this[_0x2f7be9(0x19b)][_0x2f7be9(0x202)]();}async[_0x1c0dea(0x269)]({userMessage:_0x571a01,quickActionData:_0x17bc18}){const _0x5e3414=_0x1c0dea;if(!this[_0x5e3414(0x19b)])throw new _0xde8b51(_0x5e3414(0x20f));this[_0x5e3414(0x19b)][_0x5e3414(0x1c9)]()&&await this[_0x5e3414(0x19b)][_0x5e3414(0x1fe)](this[_0x5e3414(0x1b3)][_0x5e3414(0x28e)]()),this[_0x5e3414(0x19b)]['id']&&this[_0x5e3414(0x19b)][_0x5e3414(0x162)]&&await this[_0x5e3414(0x19b)][_0x5e3414(0x247)]({'userMessage':_0x571a01,'quickActionData':_0x17bc18}),this[_0x5e3414(0x179)]();}[_0x1c0dea(0x179)](){const _0x4a6f6f=_0x1c0dea,_0x99991b=_0x630f5f(this[_0x4a6f6f(0x243)])[_0x4a6f6f(0x23e)],_0x3c031e=Array[_0x4a6f6f(0x272)](_0x99991b[_0x4a6f6f(0x1eb)][_0x4a6f6f(0x28f)](_0x49b4f9));_0x99991b[_0x4a6f6f(0x27b)](_0x27125e=>{const _0x47146e=_0x4a6f6f;_0x3c031e[_0x47146e(0x237)](_0x3881cd=>_0x27125e[_0x47146e(0x289)](_0x3881cd));});}[_0x1c0dea(0x1bc)](){const _0x207e4d=_0x1c0dea;console[_0x207e4d(0x1e1)](_0x207e4d(0x25e));}[_0x1c0dea(0x295)](_0xc659d8){const _0x1021f6=_0x1c0dea;this[_0x1021f6(0x166)][_0x1021f6(0x21a)](_0xc659d8);}[_0x1c0dea(0x17c)](_0xf6f25){const _0x4e5894=_0x1c0dea;_0x30dde1(_0xf6f25[_0x4e5894(0x29f)]);}[_0x1c0dea(0x1f4)](_0x1fa83d){const _0x29a8cf=_0x1c0dea;this[_0x29a8cf(0x19b)]?.[_0x29a8cf(0x22b)](_0x1fa83d);}[_0x1c0dea(0x2aa)](){const _0x14d23d=_0x1c0dea;this[_0x14d23d(0x19b)]?.[_0x14d23d(0x25a)]();}[_0x1c0dea(0x196)](){const _0x391502=_0x1c0dea;this[_0x391502(0x19b)]?.[_0x391502(0x27e)]();}[_0x1c0dea(0x152)](_0xf9ab32){const _0x194009=_0x1c0dea,[_0x5ce954,_0x52419a]=_0xf9ab32[_0x194009(0x16c)](':'),_0x297a47=this[_0x194009(0x19b)][_0x194009(0x154)](_0x5ce954),_0x3b368d=_0x297a47[_0x194009(0x203)](_0x52419a);return{'interaction':_0x297a47,'reply':_0x3b368d};}[_0x1c0dea(0x1be)](_0x561acf,_0x4f5ea5=!0x1){const _0x539912=_0x1c0dea,_0x2f804d=_0x630f5f(this[_0x539912(0x243)]),_0x17185f={'target':_0x2f804d[_0x539912(0x1ee)][_0x539912(0x210)][_0x539912(0x209)][_0x539912(0x180)](_0x2f804d[_0x539912(0x1ee)][_0x539912(0x1d9)][_0x539912(0x222)](_0x561acf)),'viewportOffset':{'top':0x96,'left':0x0,'bottom':0x32,'right':0x0},'ancestorOffset':0x14,'alignToTop':_0x4f5ea5};_0x4f5ea5&&(_0x17185f[_0x539912(0x24e)]=!0x0),_0x195785(_0x17185f);}[_0x1c0dea(0x1fd)](_0x150e04,_0x5b7162=!0x1){const _0x36242e=_0x1c0dea;this[_0x36242e(0x166)][_0x36242e(0x14c)](_0x150e04||_0xe4444a(this[_0x36242e(0x243)][_0x36242e(0x274)],_0x36242e(0x17d)),_0x5b7162);}async[_0x1c0dea(0x1ac)]({reply:_0xb2322d,renderingStrategy:_0x27f597}){const _0x5ada58=_0x1c0dea,{id:_0x519f9d,isDone:_0x5242c3,type:_0x140c92,parsedContent:_0x451563}=_0xb2322d;if(_0x5ada58(0x231)===_0x140c92){const _0x558b64=_0xb2322d[_0x5ada58(0x246)]({'showDiff':this[_0x5ada58(0x166)][_0x5ada58(0x1b5)]});await this[_0x5ada58(0x166)][_0x5ada58(0x1e5)]({'id':_0x519f9d,'parts':_0x558b64,'renderingStrategy':_0x27f597,'isDone':_0x5242c3});}else _0x5ada58(0x1fb)===_0x140c92&&await this[_0x5ada58(0x166)][_0x5ada58(0x259)]({'id':_0x519f9d,'parsedContent':_0x451563,'renderingStrategy':_0x27f597,'isDone':_0x5242c3});_0x5242c3&&_0xb2322d[_0x5ada58(0x208)][_0x5ada58(0x25f)]>0x0&&this[_0x5ada58(0x166)][_0x5ada58(0x1b4)](_0x519f9d,_0xb2322d[_0x5ada58(0x208)]);}async[_0x1c0dea(0x15a)](){const _0x407ce2=_0x1c0dea,_0x7e1bb3=this[_0x407ce2(0x19b)]?.[_0x407ce2(0x14a)];_0x7e1bb3&&(_0x7e1bb3[_0x407ce2(0x1c8)](),this[_0x407ce2(0x166)][_0x407ce2(0x1d5)](_0x7e1bb3));}async[_0x1c0dea(0x19a)](){const _0x997306=_0x1c0dea,_0x112e9e=this[_0x997306(0x19b)]?.[_0x997306(0x14a)];if(_0x112e9e){for await(const _0x14b8d6 of _0x112e9e[_0x997306(0x186)])await this[_0x997306(0x1ac)]({'reply':_0x14b8d6,'renderingStrategy':_0x997306(0x26b)});}}[_0x1c0dea(0x17f)](_0x268826){const _0x8eaccf=_0x1c0dea,_0x40440d={'positiveCount':_0x268826[_0x8eaccf(0x2a4)][_0x8eaccf(0x252)](_0x20d8f5=>_0x8eaccf(0x1ea)===_0x20d8f5[_0x8eaccf(0x1e3)])[_0x8eaccf(0x25f)],'totalCount':_0x268826[_0x8eaccf(0x2a4)][_0x8eaccf(0x25f)],'modificationId':_0x268826['id']},_0x523ad6=this[_0x8eaccf(0x19b)][_0x8eaccf(0x154)](_0x268826[_0x8eaccf(0x23c)])[_0x8eaccf(0x26a)];this[_0x8eaccf(0x276)][_0x8eaccf(0x293)](this[_0x8eaccf(0x19b)]['id'],_0x523ad6,_0x40440d);}}
|
|
23
|
+
const _0x2bebe0=_0x134b;(function(_0x1dc91e,_0x4c3355){const _0x2c7892=_0x134b,_0x4ad028=_0x1dc91e();while(!![]){try{const _0x592e18=-parseInt(_0x2c7892(0x223))/0x1*(parseInt(_0x2c7892(0x2ec))/0x2)+-parseInt(_0x2c7892(0x2c2))/0x3*(parseInt(_0x2c7892(0x20f))/0x4)+-parseInt(_0x2c7892(0x2f8))/0x5*(parseInt(_0x2c7892(0x237))/0x6)+-parseInt(_0x2c7892(0x29d))/0x7*(-parseInt(_0x2c7892(0x206))/0x8)+parseInt(_0x2c7892(0x2e3))/0x9*(-parseInt(_0x2c7892(0x2ff))/0xa)+parseInt(_0x2c7892(0x30a))/0xb*(-parseInt(_0x2c7892(0x2b9))/0xc)+parseInt(_0x2c7892(0x20c))/0xd;if(_0x592e18===_0x4c3355)break;else _0x4ad028['push'](_0x4ad028['shift']());}catch(_0x2c2107){_0x4ad028['push'](_0x4ad028['shift']());}}}(_0x2fa2,0xd3998));import{ContextPlugin as _0x145d9a,Editor as _0x5c386c}from'ckeditor5/src/core.js';function _0x2fa2(){const _0xfaaec9=['setSelectedModel','replyChangeGroupStateUpdated','nextSibling','toViewRange','log','AI_CHAT_INVALID_REQUEST','addUrlToContext','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_FILE','ai-chat-context-unsupported-type','addOperation','ai-chat-conversation-init-failed','pluginName','redo','rootName','_updateRatings','activeConversation','addContextItem','isLoading','getChildAtOffset','removeFromContext','getAttribute','length','batch','getChildren','21kTTSGs','webSearchFinished','AIConnector','change','contextItemLoadingEnded','showDiff','node','ai-chat-url-upload-failed','ai-chat-missing-channel-id','addFeedItemStaticMessage','changeGroups','root','createPositionAt','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_URL','ai-conversation-','context','applyOperation','activateTab','like','markers','startConversation','_aiConnector','stopInteraction','selection','interactionDestroyed','isDisabled','addResourceToContext','AI_CHAT_CONTEXT_FORM_DATA_SIZE_LIMITS_EXCEEDED','12mJsFAL','_stopLastInteraction','partIndex','removeFeedInteraction','interactionId','addFeedItemAISuggestion','TrackChangesEditing','start','addFileToContext','1431081ASvqja','reasoningStarted','_toggleWebSearch','toggleReasoning','AI_CHAT_UNTITLED_CONVERSATION','rejected','addCurrentDocumentToContext','filter','getChild','setAddContextOptions','uiId','state','documentContextContent','getReply','slice','showFakeVisualSelection','getRoot','addFeedItemError','disableControls','upsertAIChatRating','showNext','_logError','showPrevious','showChangeInText','getTransformedByOperation','mapper','close','type','ai.availableReplyActions','_insertSuggestion','ai-chat-context-file-too-many-pages','getFirstRange','new','1007829KDIqwa','reasoningFinished','setConversationTitle','uploadProgressChanged','contextSent','streaming','options','addFeedItemUserMessage','AI_CHAT_CONTEXT_UNSUPPORTED_TYPE','775468peeAhN','sourceResourcesLoaded','handleUserInteraction','createConversation','isDocumentOperation','_startConversationSafely','query','rejectSuggestion','ai-chat-controller-mouse-over','accepted','cloneNode','TrackChanges','6974105FEjjYg','addFeedInteractionHeader','resetConversationTitle','lastInteraction','isCurrentDocumentInConversation','createRange','sources','140QYaUBW','AIChatUI','AI_CHAT_CONTEXT_UNSUPPORTED_FILE_TYPE','ai.chat.models.defaultModelId','applySuggestion','_handleStartConversation','anchorId','dislike','removeSelectionFromChatContext','_batchToChanges','populateSourceResourceBalloon','16203121mDhpnQ','startAutoScroll','clearConversationContextUI','addContextOptionsChanged','toString','modelSelected','interactionStarted','config','_previewedChangeGroup','sourceId','hasChanges','plugins','static','setModel','AI_CHAT_CONTEXT_FILE_TOO_MANY_PAGES','AI_CHAT_UNABLE_TO_START_CONVERSATION','startInteraction','replyContentUpdated','addFilesToContext','stopListening','history','mouseLeaveSuggestion','resizedTabs','unshift','resourceStateChanged','addDocumentToContext','interactionFinished','model','handleRemovedConversation','split','forEach','_showConversationHistory','ai-chat-context-invalid-data','alignToTop','replies','setLoadingMessage','getDocumentContext','afterInit','removeMarker','messageId','load','selectedModel','contextItems','_setIsMaximized','updateCurrentDocumentInContext','resetMessageInput','data','revert','get','getConversation','end','AI_CHAT_RESOURCE_LOAD_FAILED','viewRangeToDom','sourcePosition','$graveyard','toggleWebSearch','isCurrentDocumentInContext','addSelectionToContext','DocumentCompare','howMany','_flushLastInteractionUI','stop','init','setFeedItemRenderingStrategy','getPath','ai.chat.context','ai-chat-source-resources-load-failed','resourceId','AI_CHAT_ABORTED_MESSAGE','open','from','loadConversation','getMarkersGroup','AI_BALLOON_HEADER_TITLE','Liked\x20response','children','view','capabilitiesUpdated','isStarted','contextItemAdded','ai-chat-context-file-too-large','updateFeedItemAIReplySuggestionContent','AITabs','_openBalloonFor','isOpen','content','enableControls','loadSourceResources','isModelAvailable','insertSuggestion','commands','sendMessage','resizeTabs','source','updateContent','_aiEditing','setIsUploadInProgress','AI_CHAT_GENERIC_ERROR','_removeFromContext','set','updateFeedItemAIReplySuggestionPartState','findIndex','sendUserMessage','error','resource','isInContext','_removeAISelectionMarkers','4325624HUnMhJ','setConversationContext','resize','contextItem','changes','_toggleReasoning','71486792eyNxDX','_handleUIUserMessage','fetchConversation','12HcjgYt','indexOf','delete','ai-chat-controller-no-active-conversation','AI_CHAT_CONTEXT_UNABLE_TO_LOAD_RESOURCES','locale','scrollFeedToSuggestion','AI_CHAT_CONTEXT_FILE_TOO_LARGE','updateConversationTitle','ready','ai-chat-conversation-start-failed','ai-chat-context-form-data-size-limits-exceeded','document','getDocumentData','undo','index','updateFeedItemAIReplySources','AIChatController','pending','AI_CHAT_CONTEXT_CURRENT_DOCUMENT','1vgXGHA','_createFromRanges','version','setIsMaximized','isPremiumPlugin','ai-chat-resource-load-failed','_updateReplyContent','createPositionFromPath','chat','closeSourceResourceBalloon','full','startsWith','toggleSuggestionDisplayMode','getGroupId','ai-chat-context-unsupported-file-type','listenTo','AI_CHAT_CONTEXT_INVALID_DATA','editing','add','ai-chat-invalid-request','6abbnLT','getOperations','replyId','finishInteraction','getInteractionAndReplyById','push','getDiff','marker','addSelectionToChatContext','removeContextItem','abortPromptStream','ai.chat.models.displayedModels','maxOffset','modification-delta','toggleLoadingSkeleton','editors','getRanges','isUploadInProgress','focusPromptInput','webSearchStarted','contextItemRemoved','updateResourceState','collaboration.channelId','current-document','mouseOverSuggestion','isOfficialPlugin','indexes','updateCapabilities','_applyOperationsAsSuggestions','_scrollToSuggestionRange','removed','getContentParts','replyCreated','main','range','Disliked\x20response','Undo','dialogClosed','_integrateEditor','requires','conversationInitialized','resources','domConverter','has','setContextItemLoading','AIEditing','AI_CHAT_UNABLE_TO_LOAD_CONVERSATION','_getDocumentRangeForReplyChanges','ai-chat-file-upload-failed','_balloonShowDiff','remove','ai-no-track-changes','selectModel','removeSelectionFromContext','setChangeGroupState','text-delta','ai-chat-conversation-not-found','find','getSelectionText','Showing\x20conversation\x20history...','interactionCreated','outdated','parse','addFeedItemAIReply','message','map','baseVersion','_aiChatModels','uid','clearPendingContextUI','data-id','_applySuggestion','ai-request-aborted','_aiChatUi','path','updateFeedItemAIReplyContent','getInteraction','hideFakeVisualSelection'];_0x2fa2=function(){return _0xfaaec9;};return _0x2fa2();}import{CKEditorError as _0x467613,logError as _0x533e07,scrollViewportToShowTarget as _0x12e565,uid as _0x5f3022}from'ckeditor5/src/utils.js';import{AIConnector as _0x1be0a9}from'../aicore/aiconnector.js';import{AITabs as _0x47d958}from'../aitabs/aitabs.js';import{AIChatConversation as _0x303e02}from'./model/aichatconversation.js';import{getTranslation as _0x48e9f1}from'../aicore/utils/common-translations.js';import{AI_VISUAL_SELECTION_MARKER_NAME as _0x3b7459}from'../aicore/aiediting.js';import{AI_REPLY_ACTIONS as _0x1b7888}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';import{AIChatModels as _0x3ef6e5}from'./model/aichatmodels.js';import{getEditorFromContext as _0x2b7d60}from'../aicore/utils/geteditorfromcontext.js';import{DocumentCompare as _0xf9b9a3,DATA_ID_MODEL_ATTRIBUTE as _0x193346}from'ckeditor5-collaboration/src/collaboration-core.js';import{fixMarkerOperationOldRange as _0x4bcf55,getOperationsFromReply as _0x2f4b70}from'../aicore/utils/getoperationsfromreply.js';import{expandSelectionWithContext as _0x4fc5ba,getMinimalSelection as _0x38fec4}from'../aicore/utils/getsuggestionpartsfromreply.js';function _0x134b(_0x4efc8f,_0x13edd2){const _0x2fa29e=_0x2fa2();return _0x134b=function(_0x134bcd,_0x5ac1c8){_0x134bcd=_0x134bcd-0x1da;let _0x13600c=_0x2fa29e[_0x134bcd];return _0x13600c;},_0x134b(_0x4efc8f,_0x13edd2);}import{ModelRange as _0x2f8406,_DetachOperation as _0x5b77b1}from'ckeditor5/src/engine.js';import{findOne as _0x552680,getAttribute as _0x1879c2,serialize as _0x5cf332,Document as _0x4b6cd4,findByAttribute as _0x1deead}from'../aicore/utils/htmlparser.js';import{IconAI as _0x16cb59}from'@ckeditor/ckeditor5-icons';import{AISuggestionContainerView as _0x33fc6e}from'../aicore/ui/suggestioncontainer/aisuggestioncontainerview.js';import{AIBalloon as _0x22b587}from'../aiballoon/aiballoon.js';export class AIChatController extends _0x145d9a{[_0x2bebe0(0x1fa)];[_0x2bebe0(0x2b2)];[_0x2bebe0(0x280)];[_0x2bebe0(0x27a)];[_0x2bebe0(0x308)]=new Map();[_0x2bebe0(0x312)]=null;[_0x2bebe0(0x268)]=!0x1;static get[_0x2bebe0(0x25e)](){return[_0x1be0a9,_0x22b587,_0xf9b9a3];}static get[_0x2bebe0(0x290)](){const _0x2e7049=_0x2bebe0;return _0x2e7049(0x220);}static get[_0x2bebe0(0x250)](){return!0x0;}static get[_0x2bebe0(0x227)](){return!0x0;}[_0x2bebe0(0x348)](){const _0x5bca80=_0x2bebe0;this[_0x5bca80(0x2b2)]=this[_0x5bca80(0x2ac)][_0x5bca80(0x315)][_0x5bca80(0x33a)](_0x5bca80(0x29f)),this[_0x5bca80(0x280)]=this[_0x5bca80(0x2ac)][_0x5bca80(0x315)][_0x5bca80(0x33a)](_0x5bca80(0x300)),this[_0x5bca80(0x1fa)]=this[_0x5bca80(0x2ac)][_0x5bca80(0x315)][_0x5bca80(0x33a)](_0x5bca80(0x264)),this[_0x5bca80(0x27a)]=new _0x3ef6e5({'connector':this[_0x5bca80(0x2b2)],'availableModels':this[_0x5bca80(0x2ac)][_0x5bca80(0x311)][_0x5bca80(0x33a)](_0x5bca80(0x242)),'defaultModelId':this[_0x5bca80(0x2ac)][_0x5bca80(0x311)][_0x5bca80(0x33a)](_0x5bca80(0x302))});const _0x86174c=this[_0x5bca80(0x2ac)][_0x5bca80(0x315)][_0x5bca80(0x33a)](_0x5bca80(0x1ed));this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x2b1),()=>{const _0x1be438=_0x5bca80;this[_0x1be438(0x2f1)]();}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x201),(_0x2a204c,_0x48f0e3)=>{const _0x42d994=_0x5bca80;this[_0x42d994(0x20d)]({'userMessage':_0x48f0e3});}),this[_0x5bca80(0x232)](_0x86174c,_0x5bca80(0x320),(_0x216d97,_0x5684a6)=>{const _0x5b168e=_0x5bca80;this[_0x5b168e(0x335)](_0x5684a6);}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x1f7),()=>{const _0x42d0bd=_0x5bca80;_0x86174c[_0x42d0bd(0x208)]();}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x241),async()=>{const _0x29132e=_0x5bca80;await this[_0x29132e(0x2ba)](),await this[_0x29132e(0x346)](),this[_0x29132e(0x307)]();}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x323),()=>{const _0xb20886=_0x5bca80;this[_0xb20886(0x294)]?.[_0xb20886(0x2c8)](_0x48e9f1(this[_0xb20886(0x2ac)][_0xb20886(0x214)],_0xb20886(0x222)));}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x2c1),(_0x1f47e3,_0x4d7233)=>{const _0x5c5fbf=_0x5bca80;this[_0x5c5fbf(0x294)]?.[_0x5c5fbf(0x31c)](Array[_0x5c5fbf(0x1e1)](_0x4d7233));}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x28b),(_0x4b4035,_0x7985a8)=>{const _0x522c4a=_0x5bca80;this[_0x522c4a(0x294)]?.[_0x522c4a(0x28b)](_0x7985a8);}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x2b7),(_0x506142,_0x3f772d)=>{const _0x48de17=_0x5bca80;this[_0x48de17(0x294)]?.[_0x48de17(0x2b7)](_0x3f772d[_0x48de17(0x1f8)],_0x3f772d[_0x48de17(0x203)]);}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x240),(_0x31e323,_0x1a4eb0)=>{const _0x1c3ee6=_0x5bca80;this[_0x1c3ee6(0x1fd)](_0x1a4eb0);}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x1f2),(_0x501876,_0x230664)=>{const _0x1a9c48=_0x5bca80;this[_0x1a9c48(0x294)]?.[_0x1a9c48(0x1f2)](_0x230664[_0x1a9c48(0x313)],_0x230664[_0x1a9c48(0x2f2)],_0x230664[_0x1a9c48(0x27b)]);}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x341),()=>{const _0x302640=_0x5bca80;this[_0x302640(0x2c4)]();}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x2c5),()=>{const _0x147e2c=_0x5bca80;this[_0x147e2c(0x20b)]();}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x26b),(_0x4372ec,_0x5bdb19)=>{const _0x4ab1c2=_0x5bca80;this[_0x4ab1c2(0x294)]?.[_0x4ab1c2(0x317)](_0x5bdb19);}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x2af),(_0x4d685f,{replyId:_0x32847d})=>{const _0x11e57a=_0x5bca80;console[_0x11e57a(0x289)](_0x11e57a(0x1e5),_0x32847d);}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x306),(_0xb942ce,{replyId:_0x138d39})=>{const _0x88e99d=_0x5bca80;console[_0x88e99d(0x289)](_0x88e99d(0x25a),_0x138d39);}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x1f4),(_0x24f529,_0x35fa11)=>{const _0x18f1a6=_0x5bca80;this[_0x18f1a6(0x2ac)][_0x18f1a6(0x315)][_0x18f1a6(0x33a)](_0x22b587)[_0x18f1a6(0x2dc)](),this[_0x18f1a6(0x2df)](_0x35fa11);}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x2d9),(_0x33f043,{replyId:_0x2d7de0,partIndex:_0x40338b})=>{const _0x54fd67=_0x5bca80;this[_0x54fd67(0x268)]=this[_0x54fd67(0x280)][_0x54fd67(0x2a2)],this[_0x54fd67(0x1ee)](_0x2d7de0,_0x40338b);}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x24f),(_0x41ab60,{replyId:_0x462bb1,partIndex:_0x5c3dd0})=>{const _0x591519=_0x5bca80,_0x502146=this[_0x591519(0x266)](_0x462bb1,_0x5c3dd0);_0x502146&&_0x591519(0x340)!=_0x502146[_0x591519(0x259)][_0x591519(0x2a8)][_0x591519(0x292)]&&this[_0x591519(0x1fa)][_0x591519(0x2d1)]([_0x502146[_0x591519(0x259)]],_0x591519(0x2f4));}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x31f),()=>{const _0x3967be=_0x5bca80;this[_0x3967be(0x1fa)][_0x3967be(0x284)](_0x3967be(0x2f4));}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x303),(_0x10eafb,_0x46e24e)=>{const _0x4640a7=_0x5bca80;this[_0x4640a7(0x2ac)][_0x4640a7(0x315)][_0x4640a7(0x33a)](_0x22b587)[_0x4640a7(0x2dc)](),this[_0x4640a7(0x27e)](_0x46e24e);}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x22f),async(_0xbcf4d8,{replyId:_0x37d695,showDiff:_0x186f19})=>{const _0x5bcf3d=_0x5bca80,{reply:_0xc523fe}=this[_0x5bcf3d(0x23b)](_0x37d695),_0x42caa7=_0xc523fe[_0x5bcf3d(0x256)]({'showDiff':_0x186f19});await this[_0x5bcf3d(0x280)][_0x5bcf3d(0x1ec)]({'id':_0xc523fe['id'],'parts':_0x42caa7,'renderingStrategy':_0x5bcf3d(0x316)});}),this[_0x5bca80(0x232)](this[_0x5bca80(0x280)],_0x5bca80(0x2f3),(_0x3dc6c6,{replyId:_0xe84c72,partIndex:_0x27dab0})=>{const _0x53c027=_0x5bca80;this[_0x53c027(0x312)]?.[_0x53c027(0x239)]==_0xe84c72&&this[_0x53c027(0x312)]?.[_0x53c027(0x2bb)]==_0x27dab0&&this[_0x53c027(0x2ac)][_0x53c027(0x315)][_0x53c027(0x33a)](_0x22b587)[_0x53c027(0x2dc)]();const {reply:_0x1c6dd7}=this[_0x53c027(0x23b)](_0xe84c72);_0x1c6dd7[_0x53c027(0x26d)](_0x27dab0,_0x53c027(0x2c7)),this[_0x53c027(0x1fa)][_0x53c027(0x284)](_0x53c027(0x2f4));});}async[_0x2bebe0(0x32f)](){const _0x3efee2=_0x2bebe0;this[_0x3efee2(0x2ac)]instanceof _0x5c386c?this[_0x3efee2(0x25d)](this[_0x3efee2(0x2ac)]):this[_0x3efee2(0x232)](this[_0x3efee2(0x2ac)][_0x3efee2(0x246)],_0x3efee2(0x235),(_0x202ef2,_0x269c11)=>{const _0x2ed093=_0x3efee2;_0x269c11['on'](_0x2ed093(0x218),()=>{const _0x2ebe28=_0x2ed093;this[_0x2ebe28(0x25d)](_0x269c11);});}),await this[_0x3efee2(0x2f1)]();}[_0x2bebe0(0x2df)](_0x4aea4a){const _0x5eb6b4=_0x2bebe0,_0x125b69=_0x2b7d60(this[_0x5eb6b4(0x2ac)]);if(!_0x125b69[_0x5eb6b4(0x315)][_0x5eb6b4(0x262)](_0x5eb6b4(0x2f7)))throw new _0x467613(_0x5eb6b4(0x26a),null);const _0x7bf533=this[_0x5eb6b4(0x2ac)][_0x5eb6b4(0x315)][_0x5eb6b4(0x33a)](_0x5eb6b4(0x344)),{reply:_0x36e0a0,interaction:_0x47376a}=this[_0x5eb6b4(0x23b)](_0x4aea4a[_0x5eb6b4(0x239)]),_0x220e02=this[_0x5eb6b4(0x266)](_0x4aea4a[_0x5eb6b4(0x239)],_0x4aea4a[_0x5eb6b4(0x2bb)]),_0x5470bb=void 0x0!==_0x4aea4a[_0x5eb6b4(0x2bb)]?[_0x36e0a0[_0x5eb6b4(0x2a7)][_0x4aea4a[_0x5eb6b4(0x2bb)]]]:_0x36e0a0[_0x5eb6b4(0x2a7)][_0x5eb6b4(0x2c9)](_0x404d6b=>_0x5eb6b4(0x221)==_0x404d6b[_0x5eb6b4(0x2cd)]),_0x475d72=_0x5470bb[_0x5eb6b4(0x278)](_0x100fe8=>_0x36e0a0[_0x5eb6b4(0x2a7)][_0x5eb6b4(0x210)](_0x100fe8));if(!_0x220e02||_0x5eb6b4(0x340)==_0x220e02[_0x5eb6b4(0x259)][_0x5eb6b4(0x2a8)][_0x5eb6b4(0x292)])return void _0x475d72[_0x5eb6b4(0x328)](_0x5a5a32=>_0x36e0a0[_0x5eb6b4(0x26d)](_0x5a5a32,_0x5eb6b4(0x274)));_0x475d72[_0x5eb6b4(0x328)](_0x551df9=>_0x36e0a0[_0x5eb6b4(0x26d)](_0x551df9,_0x5eb6b4(0x2f5)));const _0x157fd1=_0x2f4b70({'editor':_0x125b69,'reply':_0x36e0a0,'interaction':_0x47376a,'groups':_0x5470bb,'transform':!0x0,'documentCompare':_0x7bf533,'documentCompareOptions':{'anchor':_0x5eb6b4(0x258),'markDeletions':!0x0}});let _0x568f92;_0x220e02&&this[_0x5eb6b4(0x254)](_0x220e02[_0x5eb6b4(0x259)]),_0x125b69[_0x5eb6b4(0x325)][_0x5eb6b4(0x2a0)](_0x59b530=>{const _0x566724=_0x5eb6b4;_0x568f92=_0x59b530[_0x566724(0x29b)],_0x125b69[_0x566724(0x315)][_0x566724(0x33a)](_0x566724(0x2bf))[_0x566724(0x253)](_0x157fd1),this[_0x566724(0x1fa)][_0x566724(0x284)](_0x566724(0x2f4));}),this[_0x5eb6b4(0x308)][_0x5eb6b4(0x1fe)](_0x568f92,{'interactionId':_0x47376a['id'],'replyId':_0x36e0a0['id'],'indexes':_0x475d72[_0x5eb6b4(0x2d0)]()}),this[_0x5eb6b4(0x293)](_0x36e0a0);}[_0x2bebe0(0x27e)](_0x3b6967){const _0x1a95ce=_0x2bebe0,_0x4472f7=_0x2b7d60(this[_0x1a95ce(0x2ac)]),_0x320512=this[_0x1a95ce(0x2ac)][_0x1a95ce(0x315)][_0x1a95ce(0x33a)](_0xf9b9a3),{reply:_0x19b0e1,interaction:_0x4f30fb}=this[_0x1a95ce(0x23b)](_0x3b6967[_0x1a95ce(0x239)]),_0x1eb3bf=this[_0x1a95ce(0x266)](_0x3b6967[_0x1a95ce(0x239)],_0x3b6967[_0x1a95ce(0x2bb)]),_0x28f387=void 0x0!==_0x3b6967[_0x1a95ce(0x2bb)]?[_0x19b0e1[_0x1a95ce(0x2a7)][_0x3b6967[_0x1a95ce(0x2bb)]]]:_0x19b0e1[_0x1a95ce(0x2a7)][_0x1a95ce(0x2c9)](_0x155ef6=>_0x1a95ce(0x221)==_0x155ef6[_0x1a95ce(0x2cd)]),_0x291a53=_0x28f387[_0x1a95ce(0x278)](_0x1c8720=>_0x19b0e1[_0x1a95ce(0x2a7)][_0x1a95ce(0x210)](_0x1c8720));if(!_0x1eb3bf||_0x1a95ce(0x340)==_0x1eb3bf[_0x1a95ce(0x259)][_0x1a95ce(0x2a8)][_0x1a95ce(0x292)])return void _0x291a53[_0x1a95ce(0x328)](_0x35d013=>_0x19b0e1[_0x1a95ce(0x26d)](_0x35d013,_0x1a95ce(0x274)));_0x291a53[_0x1a95ce(0x328)](_0x2601f5=>_0x19b0e1[_0x1a95ce(0x26d)](_0x2601f5,_0x1a95ce(0x2f5)));const _0x493be0=_0x2f4b70({'editor':_0x4472f7,'reply':_0x19b0e1,'interaction':_0x4f30fb,'groups':_0x28f387,'transform':!0x0,'documentCompare':_0x320512,'documentCompareOptions':{'anchor':_0x1a95ce(0x258),'markDeletions':!0x1}});let _0xb05391;_0x1eb3bf&&this[_0x1a95ce(0x254)](_0x1eb3bf[_0x1a95ce(0x259)]),_0x4472f7[_0x1a95ce(0x325)][_0x1a95ce(0x2a0)](_0xa60dee=>{const _0x24187f=_0x1a95ce;_0xb05391=_0xa60dee[_0x24187f(0x29b)];for(const _0x2b1110 of _0x493be0)_0x2b1110[_0x24187f(0x279)]=_0x4472f7[_0x24187f(0x325)][_0x24187f(0x21b)][_0x24187f(0x225)],_0x4bcf55(_0x4472f7,_0x2b1110),_0xa60dee[_0x24187f(0x29b)][_0x24187f(0x28e)](_0x2b1110),_0x4472f7[_0x24187f(0x325)][_0x24187f(0x2ad)](_0x2b1110);}),this[_0x1a95ce(0x308)][_0x1a95ce(0x1fe)](_0xb05391,{'interactionId':_0x4f30fb['id'],'replyId':_0x19b0e1['id'],'indexes':_0x291a53[_0x1a95ce(0x2d0)]()}),this[_0x1a95ce(0x293)](_0x19b0e1);}[_0x2bebe0(0x1ee)](_0x91d214,_0x3ab1ae){const _0x3415a9=_0x2bebe0,_0x53e93d=_0x2b7d60(this[_0x3415a9(0x2ac)]),_0x4951cf=this[_0x3415a9(0x266)](_0x91d214,_0x3ab1ae),_0x1a37d3=this[_0x3415a9(0x2ac)][_0x3415a9(0x315)][_0x3415a9(0x33a)](_0x22b587);if(!_0x4951cf)return void _0x1a37d3[_0x3415a9(0x2dc)]();const {range:_0x2bf425,currentIndex:_0x38ae17}=_0x4951cf;if(_0x3415a9(0x340)==_0x2bf425[_0x3415a9(0x2a8)][_0x3415a9(0x292)]){const {reply:_0xd6700e}=this[_0x3415a9(0x23b)](_0x91d214);return _0xd6700e[_0x3415a9(0x26d)](_0x38ae17,_0x3415a9(0x274)),void _0x1a37d3[_0x3415a9(0x2dc)]();}if(this[_0x3415a9(0x312)]?.[_0x3415a9(0x239)]==_0x91d214&&this[_0x3415a9(0x312)]?.[_0x3415a9(0x2bb)]==_0x38ae17)return;this[_0x3415a9(0x31d)](_0x1a37d3),this[_0x3415a9(0x312)]={'replyId':_0x91d214,'partIndex':_0x38ae17};let _0x461fbd=_0x53e93d[_0x3415a9(0x311)][_0x3415a9(0x33a)](_0x3415a9(0x2de))||[..._0x1b7888];_0x53e93d[_0x3415a9(0x315)][_0x3415a9(0x262)](_0x3415a9(0x2f7))||(_0x461fbd=_0x461fbd[_0x3415a9(0x2c9)](_0xada24c=>_0x3415a9(0x1f4)!=_0xada24c));const _0x4b6825=new _0x33fc6e(_0x53e93d[_0x3415a9(0x214)],{'showDiff':this[_0x3415a9(0x268)],'areActionsDisabled':!0x1,'miniToolbarConfig':{'showChanges':_0x3415a9(0x22d)},'hideHeader':!0x0,'availableActions':_0x461fbd});this[_0x3415a9(0x31d)](_0x4b6825);const {reply:_0x1eda2e}=this[_0x3415a9(0x23b)](_0x91d214),_0x4080b8=_0x1eda2e[_0x3415a9(0x256)]({'showDiff':this[_0x3415a9(0x268)]})[_0x3415a9(0x2c9)](_0x236692=>_0x236692[_0x3415a9(0x314)]),_0x27168b=_0x4080b8[_0x3415a9(0x200)](_0x1a6133=>_0x1a6133[_0x3415a9(0x21e)]==_0x38ae17);if(-0x1==_0x27168b)return;const _0x16e168=_0x4080b8[_0x27168b],_0x1caefe=_0x4080b8['at']((_0x27168b-0x1)%_0x4080b8[_0x3415a9(0x29a)])?.[_0x3415a9(0x21e)],_0x5146d3=_0x4080b8['at']((_0x27168b+0x1)%_0x4080b8[_0x3415a9(0x29a)])?.[_0x3415a9(0x21e)];_0x4b6825[_0x3415a9(0x1f9)]({'parts':[_0x16e168],'renderingStrategy':_0x3415a9(0x316)});const _0x1ad306=_0x38ae17!==_0x1caefe;this[_0x3415a9(0x254)](_0x2bf425,!0x0),_0x1a37d3[_0x3415a9(0x1e0)]({'index':_0x38ae17,'title':_0x48e9f1(this[_0x3415a9(0x2ac)][_0x3415a9(0x214)],_0x3415a9(0x1e4),(_0x27168b+0x1)[_0x3415a9(0x30e)]()),'icon':_0x16cb59,'mainView':_0x4b6825,'showRotator':_0x1ad306,'showApplyButton':!0x0,'showSuggestButton':_0x53e93d[_0x3415a9(0x315)][_0x3415a9(0x262)](_0x3415a9(0x2f7)),'ranges':[_0x2bf425]}),this[_0x3415a9(0x280)][_0x3415a9(0x215)](_0x91d214,_0x38ae17),this[_0x3415a9(0x232)](_0x4b6825,_0x3415a9(0x22f),(_0x3d540e,{showDiff:_0x2120eb})=>{const _0x53c10a=_0x3415a9;this[_0x53c10a(0x268)]=_0x2120eb;const {reply:_0x4f41f8}=this[_0x53c10a(0x23b)](_0x91d214),_0x1fcd02=_0x4f41f8[_0x53c10a(0x256)]({'showDiff':_0x2120eb,'groupIndex':_0x38ae17});_0x4b6825[_0x53c10a(0x1f9)]({'parts':_0x1fcd02,'renderingStrategy':_0x53c10a(0x316)});}),this[_0x3415a9(0x232)](_0x1a37d3,_0x3415a9(0x303),()=>{const _0x378bd1=_0x3415a9;this[_0x378bd1(0x27e)]({'replyId':_0x91d214,'partIndex':_0x38ae17}),_0x1ad306?this[_0x378bd1(0x1ee)](_0x91d214,_0x5146d3):_0x1a37d3[_0x378bd1(0x2dc)]();}),this[_0x3415a9(0x232)](_0x1a37d3,_0x3415a9(0x1f4),()=>{const _0x8d9dea=_0x3415a9;this[_0x8d9dea(0x2df)]({'replyId':_0x91d214,'partIndex':_0x38ae17}),_0x1ad306?this[_0x8d9dea(0x1ee)](_0x91d214,_0x5146d3):_0x1a37d3[_0x8d9dea(0x2dc)]();}),_0x1ad306&&(this[_0x3415a9(0x232)](_0x1a37d3,_0x3415a9(0x2d6),()=>{const _0x1b077c=_0x3415a9;this[_0x1b077c(0x1ee)](_0x91d214,_0x5146d3);}),this[_0x3415a9(0x232)](_0x1a37d3,_0x3415a9(0x2d8),()=>{const _0x4622ae=_0x3415a9;this[_0x4622ae(0x1ee)](_0x91d214,_0x1caefe);})),this[_0x3415a9(0x232)](_0x1a37d3,_0x3415a9(0x25c),()=>{const _0xec71a9=_0x3415a9;this[_0xec71a9(0x31d)](_0x1a37d3),this[_0xec71a9(0x31d)](_0x4b6825),this[_0xec71a9(0x312)]=null;});}[_0x2bebe0(0x266)](_0x5cf1a7,_0x4280c0){const _0x542bd1=_0x2bebe0,_0x4f3190=_0x2b7d60(this[_0x542bd1(0x2ac)]),{reply:_0x12830a,interaction:_0x328765}=this[_0x542bd1(0x23b)](_0x5cf1a7),_0x8fdd65=_0x12830a[_0x542bd1(0x2a7)][_0x542bd1(0x2c9)](_0x23362f=>_0x542bd1(0x221)==_0x23362f[_0x542bd1(0x2cd)]),_0x186037=_0x8fdd65[_0x542bd1(0x278)](_0x44cbd2=>_0x12830a[_0x542bd1(0x2a7)][_0x542bd1(0x210)](_0x44cbd2));void 0x0===_0x4280c0&&(_0x4280c0=_0x186037[0x0]);const _0x2bdf98=_0x186037[_0x542bd1(0x210)](_0x4280c0);if(-0x1==_0x2bdf98)return null;const _0x351c2f=_0x8fdd65[_0x2bdf98],_0x4b9636=new _0x4b6cd4([]),_0x31470e=new _0x4b6cd4([]);for(const _0x65679a of _0x351c2f[_0x542bd1(0x20a)])if(_0x542bd1(0x255)!=_0x65679a[_0x542bd1(0x2dd)]&&_0x31470e[_0x542bd1(0x1e6)][_0x542bd1(0x23c)](_0x65679a[_0x542bd1(0x2a3)][_0x542bd1(0x2f6)](!0x0)),_0x542bd1(0x2e2)!=_0x65679a[_0x542bd1(0x2dd)]){const _0x7c1b5a=_0x552680(_0x23163e=>_0x1879c2(_0x23163e,_0x542bd1(0x27d))==_0x65679a['id'],_0x12830a[_0x542bd1(0x2ce)],!0x0);_0x4b9636[_0x542bd1(0x1e6)][_0x542bd1(0x23c)](_0x7c1b5a[_0x542bd1(0x2f6)](!0x0));}if(0x0==_0x4b9636[_0x542bd1(0x1e6)][_0x542bd1(0x29a)]){if(_0x351c2f[_0x542bd1(0x20a)][0x0][_0x542bd1(0x305)]){const _0x338493=_0x1deead(_0x542bd1(0x27d),_0x351c2f[_0x542bd1(0x20a)][0x0][_0x542bd1(0x305)],_0x12830a[_0x542bd1(0x2ce)]);_0x4b9636[_0x542bd1(0x1e6)][_0x542bd1(0x321)](_0x338493[_0x542bd1(0x2f6)](!0x0)),_0x31470e[_0x542bd1(0x1e6)][_0x542bd1(0x321)](_0x338493[_0x542bd1(0x2f6)](!0x0)),_0x338493[_0x542bd1(0x287)]&&(_0x4b9636[_0x542bd1(0x1e6)][_0x542bd1(0x23c)](_0x338493[_0x542bd1(0x287)][_0x542bd1(0x2f6)](!0x0)),_0x31470e[_0x542bd1(0x1e6)][_0x542bd1(0x23c)](_0x338493[_0x542bd1(0x287)][_0x542bd1(0x2f6)](!0x0)));}else{const _0x27b65d=_0x12830a[_0x542bd1(0x2ce)][_0x542bd1(0x1e6)][0x0];if(!_0x27b65d)return null;_0x4b9636[_0x542bd1(0x1e6)][_0x542bd1(0x23c)](_0x27b65d[_0x542bd1(0x2f6)](!0x0)),_0x31470e[_0x542bd1(0x1e6)][_0x542bd1(0x23c)](_0x27b65d[_0x542bd1(0x2f6)](!0x0));}}const _0xc13eca=_0x328765[_0x542bd1(0x32e)](),_0xb95629=_0x4f3190[_0x542bd1(0x338)][_0x542bd1(0x275)](_0xc13eca[_0x542bd1(0x1f0)]),_0x1d8515=_0x5cf332(_0x4b9636),_0x4c6cc1=_0x4f3190[_0x542bd1(0x338)][_0x542bd1(0x275)](_0x1d8515),_0x3a9e30=_0x4f3190[_0x542bd1(0x338)][_0x542bd1(0x275)](_0x1d8515),_0x5750f0=_0x4f3190[_0x542bd1(0x325)][_0x542bd1(0x2a9)](_0x4c6cc1,0x0),_0x6080cb=_0x5cf332(_0x31470e),_0x254f3d={'anchor':_0x5750f0,'markDeletions':!0x1},_0x249291=_0x4f3190[_0x542bd1(0x315)][_0x542bd1(0x33a)](_0xf9b9a3)[_0x542bd1(0x23d)](_0x1d8515,_0x6080cb,_0x254f3d)[_0x542bd1(0x238)]();if(!_0x249291[_0x542bd1(0x29a)])return null;_0x4f3190[_0x542bd1(0x325)][_0x542bd1(0x2a0)](_0x5a0f2a=>{const _0x4840de=_0x542bd1;for(const _0x463838 of _0x249291)if(_0x4840de(0x269)==_0x463838[_0x4840de(0x2dd)]){const _0x41d4c7=_0x463838[_0x4840de(0x33f)],_0x2f84c0=_0x463838[_0x4840de(0x345)],_0x172ba3=new _0x5b77b1(_0x41d4c7,_0x2f84c0);_0x5a0f2a[_0x4840de(0x29b)][_0x4840de(0x28e)](_0x172ba3),_0x4f3190[_0x4840de(0x325)][_0x4840de(0x2ad)](_0x172ba3);}else _0x4840de(0x23e)!==_0x463838[_0x4840de(0x2dd)]&&(_0x463838[_0x4840de(0x279)]=null,_0x463838[_0x4840de(0x2f0)]=!0x1,_0x5a0f2a[_0x4840de(0x29b)][_0x4840de(0x28e)](_0x463838),_0x4f3190[_0x4840de(0x325)][_0x4840de(0x2ad)](_0x463838));});const _0x2a1baa=_0x38fec4(_0x4f3190,_0x249291,_0x4c6cc1);_0x4fc5ba(_0x4f3190[_0x542bd1(0x325)],_0x2a1baa);const _0x26d7c8=_0x2a1baa[_0x542bd1(0x2e1)]()[_0x542bd1(0x2c0)][_0x542bd1(0x281)][_0x542bd1(0x2d0)](),_0x1bffc5=_0x2a1baa[_0x542bd1(0x2e1)]()[_0x542bd1(0x33c)][_0x542bd1(0x281)][_0x542bd1(0x2d0)](),_0x5d9850=[];let _0x2a418a=_0x4c6cc1,_0x3340bb=_0x3a9e30;for(let _0x4aabe7=0x0;_0x4aabe7<_0x1bffc5[_0x542bd1(0x29a)];_0x4aabe7++){const _0x2044bb=_0x2a418a[_0x542bd1(0x243)]-_0x1bffc5[_0x4aabe7];_0x5d9850[_0x4aabe7]=_0x3340bb[_0x542bd1(0x243)]-_0x2044bb,_0x2a418a=_0x2a418a[_0x542bd1(0x297)](_0x1bffc5[_0x4aabe7]),_0x3340bb=_0x3340bb[_0x542bd1(0x297)](_0x5d9850[_0x4aabe7]);}const _0x2dd431=_0x4f3190[_0x542bd1(0x325)][_0x542bd1(0x2fd)](_0x4f3190[_0x542bd1(0x325)][_0x542bd1(0x22a)](_0x3a9e30,_0x26d7c8),_0x4f3190[_0x542bd1(0x325)][_0x542bd1(0x22a)](_0x3a9e30,_0x5d9850)),_0x3a3360=_0x3a9e30[_0x542bd1(0x2ca)](0x0)[_0x542bd1(0x299)](_0x193346),_0x10397f=Array[_0x542bd1(0x1e1)](_0xb95629[_0x542bd1(0x29c)]())[_0x542bd1(0x270)](_0x27d421=>_0x27d421[_0x542bd1(0x299)](_0x193346)==_0x3a3360)[_0x542bd1(0x1db)](),_0xc4a352=_0x2dd431[_0x542bd1(0x2c0)][_0x542bd1(0x281)][_0x542bd1(0x2d0)](),_0x22c1ee=_0x2dd431[_0x542bd1(0x33c)][_0x542bd1(0x281)][_0x542bd1(0x2d0)]();_0xc4a352[0x0]=_0x10397f[0x0]+_0xc4a352[0x0],_0x22c1ee[0x0]=_0x10397f[0x0]+_0x22c1ee[0x0];let _0x1102bb=_0x4f3190[_0x542bd1(0x325)][_0x542bd1(0x2fd)](_0x4f3190[_0x542bd1(0x325)][_0x542bd1(0x22a)](_0x4f3190[_0x542bd1(0x325)][_0x542bd1(0x21b)][_0x542bd1(0x2d2)](),_0xc4a352),_0x4f3190[_0x542bd1(0x325)][_0x542bd1(0x22a)](_0x4f3190[_0x542bd1(0x325)][_0x542bd1(0x21b)][_0x542bd1(0x2d2)](),_0x22c1ee));const _0x3ecc4a=_0x4f3190[_0x542bd1(0x325)][_0x542bd1(0x21b)][_0x542bd1(0x31e)][_0x542bd1(0x238)](_0xc13eca[_0x542bd1(0x225)]);for(const _0x277abd of _0x3ecc4a)_0x1102bb=_0x2f8406[_0x542bd1(0x224)](_0x1102bb[_0x542bd1(0x2da)](_0x277abd));return{'range':_0x1102bb,'currentIndex':_0x4280c0};}[_0x2bebe0(0x25d)](_0x1fac8c){const _0x4c0b5d=_0x2bebe0;if(!_0x1fac8c[_0x4c0b5d(0x315)][_0x4c0b5d(0x262)](_0x4c0b5d(0x25b)))return;const _0x30fff7=_0x1fac8c[_0x4c0b5d(0x1f5)][_0x4c0b5d(0x33a)](_0x4c0b5d(0x21d)),_0xbdadc0=_0x1fac8c[_0x4c0b5d(0x1f5)][_0x4c0b5d(0x33a)](_0x4c0b5d(0x291));this[_0x4c0b5d(0x232)](_0x30fff7,_0x4c0b5d(0x339),(_0x1f8bf2,_0x4bc94c,_0x301eb2)=>{const _0x20181f=_0x4c0b5d,_0x3547e9=this[_0x20181f(0x308)][_0x20181f(0x33a)](_0x4bc94c);if(!_0x3547e9)return;const _0x55e5b2=this[_0x20181f(0x294)][_0x20181f(0x283)](_0x3547e9[_0x20181f(0x2bd)])[_0x20181f(0x2cf)](_0x3547e9[_0x20181f(0x239)]);_0x3547e9[_0x20181f(0x251)][_0x20181f(0x328)](_0x35d3bb=>_0x55e5b2[_0x20181f(0x26d)](_0x35d3bb,_0x20181f(0x221))),this[_0x20181f(0x308)][_0x20181f(0x211)](_0x4bc94c),this[_0x20181f(0x308)][_0x20181f(0x1fe)](_0x301eb2,_0x3547e9);}),this[_0x4c0b5d(0x232)](_0xbdadc0,_0x4c0b5d(0x339),(_0x282186,_0x26887f,_0x5b1d90)=>{const _0x3b9a10=_0x4c0b5d,_0x4de195=this[_0x3b9a10(0x308)][_0x3b9a10(0x33a)](_0x26887f);if(!_0x4de195)return;const _0x2130c8=this[_0x3b9a10(0x294)][_0x3b9a10(0x283)](_0x4de195[_0x3b9a10(0x2bd)])[_0x3b9a10(0x2cf)](_0x4de195[_0x3b9a10(0x239)]);_0x4de195[_0x3b9a10(0x251)][_0x3b9a10(0x328)](_0x40df1e=>_0x2130c8[_0x3b9a10(0x26d)](_0x40df1e,_0x3b9a10(0x2f5))),this[_0x3b9a10(0x308)][_0x3b9a10(0x211)](_0x26887f),this[_0x3b9a10(0x308)][_0x3b9a10(0x1fe)](_0x5b1d90,_0x4de195);});}async[_0x2bebe0(0x1e2)](_0x498b6c){const _0x55349d=_0x2bebe0;this[_0x55349d(0x2ac)][_0x55349d(0x315)][_0x55349d(0x33a)](_0x22b587)[_0x55349d(0x2dc)](),this[_0x55349d(0x280)][_0x55349d(0x1da)](_0x55349d(0x316)),this[_0x55349d(0x280)][_0x55349d(0x245)](!0x0),await this[_0x55349d(0x2ba)]();try{await this[_0x55349d(0x2b2)][_0x55349d(0x20e)](_0x498b6c)[_0x55349d(0x33b)](),await this[_0x55349d(0x2f1)](_0x498b6c),this[_0x55349d(0x217)]('\x20');const {sessionId:_0x5f4140}=this[_0x55349d(0x1fa)][_0x55349d(0x21c)]();await this[_0x55349d(0x294)][_0x55349d(0x332)](_0x498b6c,_0x5f4140),this[_0x55349d(0x294)][_0x55349d(0x2fc)]()&&this[_0x55349d(0x294)][_0x55349d(0x2c8)](_0x48e9f1(this[_0x55349d(0x2ac)][_0x55349d(0x214)],_0x55349d(0x222)));}catch(_0x5841ed){this[_0x55349d(0x280)][_0x55349d(0x2d3)]({'errorMessage':_0x48e9f1(this[_0x55349d(0x2ac)][_0x55349d(0x214)],_0x55349d(0x265)),'id':_0x498b6c}),this[_0x55349d(0x2d7)](new _0x467613(_0x55349d(0x26f),this,{'error':_0x5841ed}));}finally{this[_0x55349d(0x2ac)][_0x55349d(0x315)][_0x55349d(0x33a)](_0x47d958)[_0x55349d(0x1e7)][_0x55349d(0x2ae)](_0x55349d(0x22b)),this[_0x55349d(0x280)][_0x55349d(0x30b)](),this[_0x55349d(0x280)][_0x55349d(0x1da)](_0x55349d(0x2e8)),this[_0x55349d(0x280)][_0x55349d(0x245)](!0x1);}}[_0x2bebe0(0x326)](_0x524017){const _0x488a50=_0x2bebe0;this[_0x488a50(0x294)]['id']===_0x524017&&this[_0x488a50(0x2f1)]();}async[_0x2bebe0(0x23f)](){const _0x1bf4b3=_0x2bebe0,_0x465c5f=this[_0x1bf4b3(0x1fa)][_0x1bf4b3(0x271)]();this[_0x1bf4b3(0x294)]?.[_0x1bf4b3(0x343)](_0x465c5f),this[_0x1bf4b3(0x294)]?.[_0x1bf4b3(0x2c8)](_0x48e9f1(this[_0x1bf4b3(0x2ac)][_0x1bf4b3(0x214)],_0x1bf4b3(0x222)));}[_0x2bebe0(0x307)](){const _0xacef4b=_0x2bebe0;this[_0xacef4b(0x294)]?.[_0xacef4b(0x26c)]();}[_0x2bebe0(0x249)](){const _0x4d611f=_0x2bebe0;this[_0x4d611f(0x280)][_0x4d611f(0x249)]();}async[_0x2bebe0(0x2b1)](){const _0x576d15=_0x2bebe0;await this[_0x576d15(0x2f1)]();}async[_0x2bebe0(0x1f6)]({message:_0x2e5fe6,quickActionData:_0x284483}){const _0x31ca0b=_0x2bebe0;await this[_0x31ca0b(0x20d)]({'userMessage':_0x2e5fe6,'quickActionData':_0x284483});}[_0x2bebe0(0x230)](){const _0x11ac47=_0x2bebe0,_0x517092=this[_0x11ac47(0x2ac)][_0x11ac47(0x311)][_0x11ac47(0x33a)](_0x11ac47(0x24d));if(!_0x517092)throw new _0x467613(_0x11ac47(0x2a5),this);return _0x517092;}async[_0x2bebe0(0x2f1)](_0x2af3f8){const _0x3ad3ea=_0x2bebe0;try{this[_0x3ad3ea(0x280)][_0x3ad3ea(0x1f1)](),await this[_0x3ad3ea(0x304)](_0x2af3f8);}catch(_0x18b8d5){_0x533e07(_0x3ad3ea(0x219),_0x18b8d5),this[_0x3ad3ea(0x294)]=void 0x0,this[_0x3ad3ea(0x280)][_0x3ad3ea(0x2d4)]();}}async[_0x2bebe0(0x304)](_0x62d1e2){const _0x13802d=_0x2bebe0,_0x1c4a1b=this[_0x13802d(0x2ac)][_0x13802d(0x315)][_0x13802d(0x33a)](_0x22b587);let _0x210e55;_0x1c4a1b[_0x13802d(0x1ef)]&&_0x1c4a1b[_0x13802d(0x2dc)](),_0x62d1e2||!this[_0x13802d(0x294)]?_0x210e55=this[_0x13802d(0x2ac)][_0x13802d(0x311)][_0x13802d(0x33a)](_0x13802d(0x302)):this[_0x13802d(0x280)][_0x13802d(0x1f3)]&&(_0x210e55=this[_0x13802d(0x294)][_0x13802d(0x333)]['id']),await this[_0x13802d(0x2ba)]();const _0xb3dc0e=this[_0x13802d(0x230)](),_0xc03ed=_0x62d1e2||_0x5f3022();this[_0x13802d(0x294)]=new _0x303e02({'connector':this[_0x13802d(0x2b2)],'chatModels':this[_0x13802d(0x27a)],'selectedModelId':_0x210e55,'conversationId':_0xc03ed,'group':_0xb3dc0e,'getEditor':()=>_0x2b7d60(this[_0x13802d(0x2ac)])}),this[_0x13802d(0x294)]['on'](_0x13802d(0x25f),(_0x4e3633,_0xaa8d82)=>{const _0x27ce9b=_0x13802d;this[_0x27ce9b(0x280)][_0x27ce9b(0x2ef)](_0xaa8d82),this[_0x27ce9b(0x280)][_0x27ce9b(0x337)](),this[_0x27ce9b(0x280)][_0x27ce9b(0x27c)](),this[_0x27ce9b(0x280)][_0x27ce9b(0x30c)](),_0x62d1e2||(this[_0x27ce9b(0x280)][_0x27ce9b(0x2fa)](),this[_0x27ce9b(0x294)]?.[_0x27ce9b(0x2c8)](_0x48e9f1(this[_0x27ce9b(0x2ac)][_0x27ce9b(0x214)],_0x27ce9b(0x222))));}),this[_0x13802d(0x294)]['on'](_0x13802d(0x2e6),(_0x399f55,_0x29146b)=>{const _0x1aef3c=_0x13802d;this[_0x1aef3c(0x280)][_0x1aef3c(0x1fb)](_0x29146b[_0x1aef3c(0x248)]);}),this[_0x13802d(0x294)]['on'](_0x13802d(0x273),(_0x2e56e7,_0x556a88)=>{const _0x1d5f99=_0x13802d;this[_0x1d5f99(0x280)][_0x1d5f99(0x2ea)](_0x556a88);}),this[_0x13802d(0x294)]['on'](_0x13802d(0x24a),()=>{const _0x2692a6=_0x13802d;this[_0x2692a6(0x280)][_0x2692a6(0x32d)]({'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x13802d(0x294)]['on'](_0x13802d(0x2c3),()=>{const _0x411c0d=_0x13802d;this[_0x411c0d(0x280)][_0x411c0d(0x32d)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x13802d(0x294)]['on'](_0x13802d(0x29e),(_0x3d4c8f,_0x1579df)=>{const _0x37149f=_0x13802d;this[_0x37149f(0x280)][_0x37149f(0x2f9)](_0x1579df,{'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x13802d(0x294)]['on'](_0x13802d(0x2e4),(_0x5646f7,_0x46d862)=>{const _0x3a8ece=_0x13802d;this[_0x3a8ece(0x280)][_0x3a8ece(0x2f9)](_0x46d862,{'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x13802d(0x294)]['on'](_0x13802d(0x310),()=>{const _0x25ba01=_0x13802d;this[_0x25ba01(0x280)][_0x25ba01(0x31a)]();}),this[_0x13802d(0x294)]['on'](_0x13802d(0x324),async()=>{const _0x335d1c=_0x13802d;await this[_0x335d1c(0x280)][_0x335d1c(0x23a)]();}),this[_0x13802d(0x294)]['on'](_0x13802d(0x2b5),(_0x4f26ae,_0x3eee1e)=>{const _0x1fb4bd=_0x13802d;this[_0x1fb4bd(0x280)][_0x1fb4bd(0x2bc)](_0x3eee1e['id']);}),this[_0x13802d(0x294)]['on'](_0x13802d(0x2e5),(_0x197318,_0x58f128,_0x3125f3)=>{const _0x3136aa=_0x13802d;this[_0x3136aa(0x217)](_0x58f128,_0x3125f3);}),this[_0x13802d(0x294)]['on'](_0x13802d(0x257),(_0x420771,_0x24736e)=>{const _0x587a68=_0x13802d;_0x587a68(0x26e)===_0x24736e[_0x587a68(0x2dd)]?this[_0x587a68(0x280)][_0x587a68(0x276)](_0x24736e):this[_0x587a68(0x280)][_0x587a68(0x2be)](_0x24736e);}),this[_0x13802d(0x294)]['on'](_0x13802d(0x31b),async(_0x3c07ee,_0x4629eb)=>{const _0x4f40df=_0x13802d;await this[_0x4f40df(0x229)]({'reply':_0x4629eb});}),this[_0x13802d(0x294)]['on'](_0x13802d(0x286),(_0x5cebe1,{reply:_0x249a18,index:_0x4fbf96,state:_0x318dbb})=>{const _0x308ae8=_0x13802d;this[_0x308ae8(0x280)][_0x308ae8(0x1ff)]({'id':_0x249a18['id'],'index':_0x4fbf96,'state':_0x318dbb});}),this[_0x13802d(0x294)]['on'](_0x13802d(0x1ea),(_0x9aca1,_0xfd6813)=>{const _0x246971=_0x13802d;if(this[_0x246971(0x280)][_0x246971(0x295)](_0xfd6813[_0x246971(0x209)],_0xfd6813[_0x246971(0x296)]),_0x246971(0x2b4)===_0xfd6813[_0x246971(0x209)][_0x246971(0x2dd)]){const _0x1a46f4=[..._0x2b7d60(this[_0x246971(0x2ac)])[_0x246971(0x325)][_0x246971(0x21b)][_0x246971(0x2b4)][_0x246971(0x247)]()];this[_0x246971(0x1fa)][_0x246971(0x2d1)](_0x1a46f4,_0x246971(0x2ab)+this[_0x246971(0x294)]?.['id']);}}),this[_0x13802d(0x294)]['on'](_0x13802d(0x24b),(_0x4b5146,_0x5c7414)=>{const _0x2d961f=_0x13802d;this[_0x2d961f(0x280)][_0x2d961f(0x240)](_0x5c7414[_0x2d961f(0x2cc)]),_0x2d961f(0x24e)==_0x5c7414[_0x2d961f(0x2cc)]&&this[_0x2d961f(0x307)](),_0x2d961f(0x2b4)===_0x5c7414[_0x2d961f(0x2dd)]&&this[_0x2d961f(0x1fa)][_0x2d961f(0x284)](_0x2d961f(0x2ab)+this[_0x2d961f(0x294)]?.['id']);}),this[_0x13802d(0x294)]['on'](_0x13802d(0x2a1),(_0x5e024f,_0x9f54b7)=>{const _0x23acf1=_0x13802d;this[_0x23acf1(0x280)][_0x23acf1(0x263)](_0x9f54b7[_0x23acf1(0x209)][_0x23acf1(0x2cc)],_0x9f54b7[_0x23acf1(0x296)]);}),this[_0x13802d(0x294)]['on'](_0x13802d(0x2e7),(_0x4248eb,_0x465a4c)=>{const _0xd4fc92=_0x13802d;this[_0xd4fc92(0x280)][_0xd4fc92(0x207)](_0x465a4c[_0xd4fc92(0x334)]);}),this[_0x13802d(0x294)]['on'](_0x13802d(0x30d),(_0x14b715,_0x422100)=>{const _0xf282d0=_0x13802d;this[_0xf282d0(0x280)][_0xf282d0(0x2cb)](_0x422100[_0xf282d0(0x2e9)]);}),this[_0x13802d(0x294)]['on'](_0x13802d(0x2ed),(_0x19c34d,_0x36f1fc)=>{const _0x2c71b0=_0x13802d;this[_0x2c71b0(0x280)][_0x2c71b0(0x309)](_0x36f1fc[_0x2c71b0(0x313)],_0x36f1fc[_0x2c71b0(0x1f8)],_0x36f1fc[_0x2c71b0(0x260)],_0x36f1fc[_0x2c71b0(0x27b)]);}),this[_0x13802d(0x294)]['on'](_0x13802d(0x322),(_0x5bf621,_0x3bdf9b)=>{const _0x3a6e9f=_0x13802d;this[_0x3a6e9f(0x280)][_0x3a6e9f(0x24c)](_0x3bdf9b[_0x3a6e9f(0x313)],_0x3bdf9b[_0x3a6e9f(0x1de)],_0x3bdf9b[_0x3a6e9f(0x204)]);}),this[_0x13802d(0x294)]['on'](_0x13802d(0x1e8),(_0x32c273,_0x4c90eb)=>{const _0x33af46=_0x13802d;this[_0x33af46(0x280)][_0x33af46(0x252)](_0x4c90eb);}),this[_0x13802d(0x294)]['on'](_0x13802d(0x30f),(_0x1246fa,_0x3d3062)=>{const _0x9aebb6=_0x13802d;this[_0x9aebb6(0x280)][_0x9aebb6(0x285)](_0x3d3062[_0x9aebb6(0x333)],_0x3d3062[_0x9aebb6(0x2b6)]);}),this[_0x13802d(0x294)]['on'](_0x13802d(0x202),(_0x2a4e74,{error:_0x241d04,interactionId:_0x1641c1,fileName:_0x5f3d2d,url:_0x3971a1,sourceId:_0x3fee28,sourceLabel:_0x59768d})=>{const _0x3c8035=_0x13802d,_0x6adfe8=_0x1641c1?_0x1641c1+':'+_0x5f3022():_0x5f3022();_0x241d04[_0x3c8035(0x277)][_0x3c8035(0x22e)](_0x3c8035(0x27f))?this[_0x3c8035(0x280)][_0x3c8035(0x2a6)]({'staticMessage':_0x48e9f1(this[_0x3c8035(0x2ac)][_0x3c8035(0x214)],_0x3c8035(0x1df)),'id':_0x6adfe8}):_0x241d04[_0x3c8035(0x277)][_0x3c8035(0x22e)](_0x3c8035(0x28f))||_0x241d04[_0x3c8035(0x277)][_0x3c8035(0x22e)](_0x3c8035(0x219))?(this[_0x3c8035(0x280)][_0x3c8035(0x2d3)]({'errorMessage':_0x48e9f1(this[_0x3c8035(0x2ac)][_0x3c8035(0x214)],_0x3c8035(0x319)),'id':_0x6adfe8}),this[_0x3c8035(0x2d7)](_0x241d04)):_0x241d04[_0x3c8035(0x277)][_0x3c8035(0x22e)](_0x3c8035(0x267))?this[_0x3c8035(0x280)][_0x3c8035(0x2d3)]({'errorMessage':_0x48e9f1(this[_0x3c8035(0x2ac)][_0x3c8035(0x214)],_0x3c8035(0x28c),_0x5f3d2d),'id':_0x6adfe8}):_0x241d04[_0x3c8035(0x277)][_0x3c8035(0x22e)](_0x3c8035(0x2a4))?this[_0x3c8035(0x280)][_0x3c8035(0x2d3)]({'errorMessage':_0x48e9f1(this[_0x3c8035(0x2ac)][_0x3c8035(0x214)],_0x3c8035(0x2aa),_0x3971a1),'id':_0x6adfe8}):_0x241d04[_0x3c8035(0x277)][_0x3c8035(0x22e)](_0x3c8035(0x32a))?this[_0x3c8035(0x280)][_0x3c8035(0x2d3)]({'errorMessage':_0x48e9f1(this[_0x3c8035(0x2ac)][_0x3c8035(0x214)],_0x3c8035(0x233)),'id':_0x6adfe8}):_0x241d04[_0x3c8035(0x277)][_0x3c8035(0x22e)](_0x3c8035(0x28d))?this[_0x3c8035(0x280)][_0x3c8035(0x2d3)]({'errorMessage':_0x48e9f1(this[_0x3c8035(0x2ac)][_0x3c8035(0x214)],_0x3c8035(0x2eb)),'id':_0x6adfe8}):_0x241d04[_0x3c8035(0x277)][_0x3c8035(0x22e)](_0x3c8035(0x1dd))?(_0x3fee28&&this[_0x3c8035(0x280)][_0x3c8035(0x22c)](_0x3fee28),this[_0x3c8035(0x280)][_0x3c8035(0x2d3)]({'errorMessage':_0x48e9f1(this[_0x3c8035(0x2ac)][_0x3c8035(0x214)],_0x3c8035(0x213),_0x59768d||_0x3c8035(0x1f8)),'id':_0x6adfe8}),this[_0x3c8035(0x2d7)](_0x241d04)):_0x241d04[_0x3c8035(0x277)][_0x3c8035(0x22e)](_0x3c8035(0x228))?(this[_0x3c8035(0x280)][_0x3c8035(0x2d3)]({'errorMessage':_0x48e9f1(this[_0x3c8035(0x2ac)][_0x3c8035(0x214)],_0x3c8035(0x33d)),'id':_0x6adfe8}),this[_0x3c8035(0x2d7)](_0x241d04)):_0x241d04[_0x3c8035(0x277)][_0x3c8035(0x22e)](_0x3c8035(0x236))?(this[_0x3c8035(0x280)][_0x3c8035(0x2d3)]({'errorMessage':_0x48e9f1(this[_0x3c8035(0x2ac)][_0x3c8035(0x214)],_0x3c8035(0x28a)),'id':_0x6adfe8}),this[_0x3c8035(0x2d7)](_0x241d04)):_0x241d04[_0x3c8035(0x277)][_0x3c8035(0x22e)](_0x3c8035(0x231))?(this[_0x3c8035(0x280)][_0x3c8035(0x2d3)]({'errorMessage':_0x48e9f1(this[_0x3c8035(0x2ac)][_0x3c8035(0x214)],_0x3c8035(0x301)),'id':_0x6adfe8}),this[_0x3c8035(0x2d7)](_0x241d04)):_0x241d04[_0x3c8035(0x277)][_0x3c8035(0x22e)](_0x3c8035(0x1eb))?(this[_0x3c8035(0x280)][_0x3c8035(0x2d3)]({'errorMessage':_0x48e9f1(this[_0x3c8035(0x2ac)][_0x3c8035(0x214)],_0x3c8035(0x216)),'id':_0x6adfe8}),this[_0x3c8035(0x2d7)](_0x241d04)):_0x241d04[_0x3c8035(0x277)][_0x3c8035(0x22e)](_0x3c8035(0x2e0))?(this[_0x3c8035(0x280)][_0x3c8035(0x2d3)]({'errorMessage':_0x48e9f1(this[_0x3c8035(0x2ac)][_0x3c8035(0x214)],_0x3c8035(0x318)),'id':_0x6adfe8}),this[_0x3c8035(0x2d7)](_0x241d04)):_0x241d04[_0x3c8035(0x277)][_0x3c8035(0x22e)](_0x3c8035(0x21a))?(this[_0x3c8035(0x280)][_0x3c8035(0x2d3)]({'errorMessage':_0x48e9f1(this[_0x3c8035(0x2ac)][_0x3c8035(0x214)],_0x3c8035(0x2b8)),'id':_0x6adfe8}),this[_0x3c8035(0x2d7)](_0x241d04)):(this[_0x3c8035(0x280)][_0x3c8035(0x2d3)]({'errorMessage':_0x48e9f1(this[_0x3c8035(0x2ac)][_0x3c8035(0x214)],_0x3c8035(0x1fc)),'id':_0x6adfe8}),this[_0x3c8035(0x2d7)](_0x241d04));}),await this[_0x13802d(0x294)][_0x13802d(0x348)](this[_0x13802d(0x2ac)][_0x13802d(0x311)][_0x13802d(0x33a)](_0x13802d(0x1dc))),_0x62d1e2||await this[_0x13802d(0x294)][_0x13802d(0x2c0)]();}async[_0x2bebe0(0x20d)]({userMessage:_0x6d2500,quickActionData:_0x1e9b39}){const _0x129501=_0x2bebe0;if(!this[_0x129501(0x294)])throw new _0x467613(_0x129501(0x212));this[_0x129501(0x294)][_0x129501(0x342)]()&&await this[_0x129501(0x294)][_0x129501(0x336)](this[_0x129501(0x1fa)][_0x129501(0x21c)]()),this[_0x129501(0x294)]['id']&&this[_0x129501(0x294)][_0x129501(0x1e9)]&&await this[_0x129501(0x294)][_0x129501(0x2ee)]({'userMessage':_0x6d2500,'quickActionData':_0x1e9b39}),this[_0x129501(0x205)]();}[_0x2bebe0(0x205)](){const _0x54492b=_0x2bebe0,_0x20e647=_0x2b7d60(this[_0x54492b(0x2ac)])[_0x54492b(0x325)],_0x571b62=Array[_0x54492b(0x1e1)](_0x20e647[_0x54492b(0x2b0)][_0x54492b(0x1e3)](_0x3b7459));_0x20e647[_0x54492b(0x2a0)](_0x4474c8=>{const _0x58c734=_0x54492b;_0x571b62[_0x58c734(0x328)](_0x375beb=>_0x4474c8[_0x58c734(0x330)](_0x375beb));});}[_0x2bebe0(0x329)](){const _0x57c277=_0x2bebe0;console[_0x57c277(0x289)](_0x57c277(0x272));}[_0x2bebe0(0x335)](_0x5b8df9){const _0x1dbd1a=_0x2bebe0;this[_0x1dbd1a(0x280)][_0x1dbd1a(0x226)](_0x5b8df9);}[_0x2bebe0(0x2d7)](_0x438125){const _0x2563e3=_0x2bebe0;_0x533e07(_0x438125[_0x2563e3(0x277)]);}[_0x2bebe0(0x1fd)](_0x2f1c7d){const _0xf2df7=_0x2bebe0;this[_0xf2df7(0x294)]?.[_0xf2df7(0x298)](_0x2f1c7d);}[_0x2bebe0(0x2c4)](){const _0x2b4da4=_0x2bebe0;this[_0x2b4da4(0x294)]?.[_0x2b4da4(0x341)]();}[_0x2bebe0(0x20b)](){const _0x4a64d4=_0x2bebe0;this[_0x4a64d4(0x294)]?.[_0x4a64d4(0x2c5)]();}[_0x2bebe0(0x23b)](_0x32033f){const _0x58020e=_0x2bebe0,[_0x710cf,_0x443f2e]=_0x32033f[_0x58020e(0x327)](':'),_0x36a6bc=this[_0x58020e(0x294)][_0x58020e(0x283)](_0x710cf),_0xd85726=_0x36a6bc[_0x58020e(0x2cf)](_0x443f2e);return{'interaction':_0x36a6bc,'reply':_0xd85726};}[_0x2bebe0(0x254)](_0x58cf66,_0x2bcc2a=!0x1){const _0x4c88d3=_0x2bebe0,_0x43aa6a=_0x2b7d60(this[_0x4c88d3(0x2ac)]),_0x32dd32={'target':_0x43aa6a[_0x4c88d3(0x234)][_0x4c88d3(0x1e7)][_0x4c88d3(0x261)][_0x4c88d3(0x33e)](_0x43aa6a[_0x4c88d3(0x234)][_0x4c88d3(0x2db)][_0x4c88d3(0x288)](_0x58cf66)),'viewportOffset':{'top':0x96,'left':0x0,'bottom':0x32,'right':0x0},'ancestorOffset':0x14,'alignToTop':_0x2bcc2a};_0x2bcc2a&&(_0x32dd32[_0x4c88d3(0x32b)]=!0x0),_0x12e565(_0x32dd32);}[_0x2bebe0(0x217)](_0x3a7434,_0x59c2e6=!0x1){const _0xd2fc3e=_0x2bebe0;this[_0xd2fc3e(0x280)][_0xd2fc3e(0x2e5)](_0x3a7434||_0x48e9f1(this[_0xd2fc3e(0x2ac)][_0xd2fc3e(0x214)],_0xd2fc3e(0x2c6)),_0x59c2e6);}async[_0x2bebe0(0x229)]({reply:_0xdd0a77,renderingStrategy:_0x436df3}){const _0x2f9b49=_0x2bebe0,{id:_0x56d0ff,isDone:_0x20ea97,type:_0x470d53,parsedContent:_0xe88ee5}=_0xdd0a77;if(_0x2f9b49(0x244)===_0x470d53){const _0x446327=_0xdd0a77[_0x2f9b49(0x256)]({'showDiff':this[_0x2f9b49(0x280)][_0x2f9b49(0x2a2)]});await this[_0x2f9b49(0x280)][_0x2f9b49(0x1ec)]({'id':_0x56d0ff,'parts':_0x446327,'renderingStrategy':_0x436df3,'isDone':_0x20ea97});}else _0x2f9b49(0x26e)===_0x470d53&&await this[_0x2f9b49(0x280)][_0x2f9b49(0x282)]({'id':_0x56d0ff,'parsedContent':_0xe88ee5,'renderingStrategy':_0x436df3,'isDone':_0x20ea97});_0x20ea97&&_0xdd0a77[_0x2f9b49(0x2fe)][_0x2f9b49(0x29a)]>0x0&&this[_0x2f9b49(0x280)][_0x2f9b49(0x21f)](_0x56d0ff,_0xdd0a77[_0x2f9b49(0x2fe)]);}async[_0x2bebe0(0x2ba)](){const _0x3dd414=_0x2bebe0,_0x4781fa=this[_0x3dd414(0x294)]?.[_0x3dd414(0x2fb)];_0x4781fa&&(_0x4781fa[_0x3dd414(0x347)](),this[_0x3dd414(0x280)][_0x3dd414(0x2b3)](_0x4781fa));}async[_0x2bebe0(0x346)](){const _0x339c48=_0x2bebe0,_0x30ddbd=this[_0x339c48(0x294)]?.[_0x339c48(0x2fb)];if(_0x30ddbd){for await(const _0x24c971 of _0x30ddbd[_0x339c48(0x32c)])await this[_0x339c48(0x229)]({'reply':_0x24c971,'renderingStrategy':_0x339c48(0x316)});}}[_0x2bebe0(0x293)](_0x230f31){const _0x46a62e=_0x2bebe0,_0x23a568={'positiveCount':_0x230f31[_0x46a62e(0x2a7)][_0x46a62e(0x2c9)](_0x5e524c=>_0x46a62e(0x2f5)===_0x5e524c[_0x46a62e(0x2cd)])[_0x46a62e(0x29a)],'totalCount':_0x230f31[_0x46a62e(0x2a7)][_0x46a62e(0x29a)],'modificationId':_0x230f31['id']},_0xe41ab5=this[_0x46a62e(0x294)][_0x46a62e(0x283)](_0x230f31[_0x46a62e(0x2bd)])[_0x46a62e(0x331)];this[_0x46a62e(0x2b2)][_0x46a62e(0x2d5)](this[_0x46a62e(0x294)]['id'],_0xe41ab5,_0x23a568);}}
|
package/src/aichat/aichatui.js
CHANGED
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const _0x331da1=_0x363b;(function(_0x1a9e56,_0x4aecb3){const _0x199098=_0x363b,_0x2b425b=_0x1a9e56();while(!![]){try{const _0x87b6f5=parseInt(_0x199098(0x11c))/0x1*(-parseInt(_0x199098(0x11d))/0x2)+-parseInt(_0x199098(0xa0))/0x3*(parseInt(_0x199098(0xe0))/0x4)+parseInt(_0x199098(0xeb))/0x5*(parseInt(_0x199098(0xff))/0x6)+-parseInt(_0x199098(0x101))/0x7*(-parseInt(_0x199098(0x109))/0x8)+parseInt(_0x199098(0x10f))/0x9+-parseInt(_0x199098(0xd0))/0xa+-parseInt(_0x199098(0xd1))/0xb;if(_0x87b6f5===_0x4aecb3)break;else _0x2b425b['push'](_0x2b425b['shift']());}catch(_0x23fced){_0x2b425b['push'](_0x2b425b['shift']());}}}(_0xe230,0x3a938));import{ContextPlugin as _0x5b4a69}from'ckeditor5/src/core.js';import{_isMotionReduced as _0xf36c22}from'ckeditor5/src/utils.js';import{AIChatView as _0x88a969}from'./ui/aichatview.js';import{AITabs as _0x50e4e9}from'../aitabs/aitabs.js';import{getTranslation as _0x2b4081}from'../aicore/utils/common-translations.js';import{IconAIChat as _0x44f840}from'ckeditor5/src/icons.js';import{AIChatFeedInteractionHeaderView as _0x53b28e}from'./ui/feed/aichatfeedinteractionheaderview.js';import{PromiseQueue as _0x10d33a}from'./utils/promisequeue.js';import{AI_CHAT_UI_EVENT_NAMES as _0x2031a8}from'./utils/eventnames.js';import'../../theme/aichat/aichat.css';import{getEditorFromContext as _0x1f097f}from'../aicore/utils/geteditorfromcontext.js';function _0x363b(_0x4c8c8b,_0xa08fa3){const _0xe230a2=_0xe230();return _0x363b=function(_0x363bf3,_0x3c7017){_0x363bf3=_0x363bf3-0x7f;let _0x290270=_0xe230a2[_0x363bf3];return _0x290270;},_0x363b(_0x4c8c8b,_0xa08fa3);}import{AI_REPLY_ACTIONS as _0x290b9f}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';export class AIChatUI extends _0x5b4a69{static get[_0x331da1(0x94)](){return[_0x50e4e9];}[_0x331da1(0x82)];static get[_0x331da1(0xc7)](){const _0x5a94aa=_0x331da1;return _0x5a94aa(0x10e);}static get[_0x331da1(0xef)](){return!0x0;}static get[_0x331da1(0x10b)](){return!0x0;}[_0x331da1(0xc1)]=_0x331da1(0xa1);[_0x331da1(0x8f)]=!0x0;[_0x331da1(0xac)];[_0x331da1(0xf8)];[_0x331da1(0x117)]=void 0x0;[_0x331da1(0xd7)]=!0x1;constructor(_0x4027c1){const _0x28c27d=_0x331da1;super(_0x4027c1);const _0xe23e41=this[_0x28c27d(0x102)][_0x28c27d(0xdb)][_0x28c27d(0xa7)](_0x28c27d(0xfe));this[_0x28c27d(0x11f)](_0x28c27d(0x92),!0x1),this[_0x28c27d(0xac)]=new _0x10d33a(),this[_0x28c27d(0x82)]=new _0x88a969(this[_0x28c27d(0x102)][_0x28c27d(0x116)],{'showResizeButton':_0xe23e41[_0x28c27d(0x9e)],'contextResourcesSearchInputVisibleFrom':this[_0x28c27d(0x102)][_0x28c27d(0x99)][_0x28c27d(0xa7)](_0x28c27d(0x91))}),this[_0x28c27d(0x82)][_0x28c27d(0x118)](..._0x2031a8)['to'](this),this[_0x28c27d(0x82)]['on'](_0x28c27d(0xb7),(_0x319d19,{showDiff:_0x5977b2})=>{const _0x65f06=_0x28c27d;this[_0x65f06(0x8f)]=_0x5977b2;}),_0xe23e41[_0x28c27d(0xa5)][_0x28c27d(0x81)]({'id':_0x28c27d(0xf7),'buttonLabel':_0x2b4081(this[_0x28c27d(0x102)][_0x28c27d(0x116)],_0x28c27d(0x8e)),'buttonIcon':_0x44f840,'order':0x0,'content':this[_0x28c27d(0x82)]}),this[_0x28c27d(0x82)][_0x28c27d(0xb6)][_0x28c27d(0xe5)](_0x28c27d(0xb9))['to'](this,_0x28c27d(0x92),_0x530fd5=>_0x530fd5),this[_0x28c27d(0x82)][_0x28c27d(0xfb)][_0x28c27d(0xe5)](_0x28c27d(0xb5))['to'](this,_0x28c27d(0x92),_0x27bed8=>_0x27bed8),this[_0x28c27d(0x82)][_0x28c27d(0xb6)][_0x28c27d(0x9f)](this[_0x28c27d(0x122)]()),this[_0x28c27d(0xe5)](_0x28c27d(0x98))['to'](this[_0x28c27d(0x82)][_0x28c27d(0xb6)],_0x28c27d(0x98));}[_0x331da1(0x83)](){const _0x15e8d7=_0x331da1;super[_0x15e8d7(0x83)](),this[_0x15e8d7(0x117)]&&clearInterval(this[_0x15e8d7(0x117)]);}[_0x331da1(0xd5)](_0xf1f907){const _0x1f538d=_0x331da1;this[_0x1f538d(0x82)][_0x1f538d(0xfb)][_0x1f538d(0xb8)](),this[_0x1f538d(0x82)][_0x1f538d(0xb6)][_0x1f538d(0x84)](),this[_0x1f538d(0x82)][_0x1f538d(0xb6)][_0x1f538d(0xc6)](_0xf1f907[_0x1f538d(0x8a)],!this[_0x1f538d(0x102)][_0x1f538d(0x99)][_0x1f538d(0xa7)](_0x1f538d(0xa4))),this[_0x1f538d(0xba)]({'id':_0x1f538d(0x113),'staticMessage':_0x2b4081(this[_0x1f538d(0x102)][_0x1f538d(0x116)],_0x1f538d(0x11a))});}[_0x331da1(0xba)]({id:_0x144169,staticMessage:_0x12787a}){const _0x42c1bc=_0x331da1;this[_0x42c1bc(0x82)][_0x42c1bc(0xfb)][_0x42c1bc(0x96)](_0x42c1bc(0xc0),{'id':_0x144169,'initialContent':_0x42c1bc(0xc4)+_0x12787a+_0x42c1bc(0xbb)});}[_0x331da1(0xe4)](_0x48c072){const _0x45983e=_0x331da1,_0x3f0498=_0x48c072[_0x45983e(0x11b)]?.[_0x45983e(0x103)]||_0x48c072[_0x45983e(0x87)];this[_0x45983e(0x82)][_0x45983e(0xfb)][_0x45983e(0x96)](_0x45983e(0x9d),{'contextItems':Array[_0x45983e(0x7f)](_0x48c072[_0x45983e(0xaf)][_0x45983e(0x86)]()),'initialContent':_0x45983e(0xc4)+_0x3f0498+_0x45983e(0xbb),'id':_0x48c072['id']});}[_0x331da1(0xcd)]({errorMessage:_0xa3f011,id:_0x3ca8ea}){const _0x4e2d58=_0x331da1;this[_0x4e2d58(0x82)][_0x4e2d58(0xfb)][_0x4e2d58(0x96)](_0x4e2d58(0xb4),{'initialContent':_0x4e2d58(0xc4)+_0xa3f011+_0x4e2d58(0xbb),'id':_0x3ca8ea});}[_0x331da1(0x9c)](_0x3e855b){const _0x15e9c9=_0x331da1;return this[_0x15e9c9(0xac)][_0x15e9c9(0x10c)](async()=>{const _0x5b1f62=_0x15e9c9;this[_0x5b1f62(0x82)][_0x5b1f62(0xfb)][_0x5b1f62(0x96)](_0x5b1f62(0xc0),{'id':_0x3e855b[_0x5b1f62(0x10a)]+':'+_0x3e855b['id']}),this[_0x5b1f62(0x107)](null);});}async[_0x331da1(0xaa)](_0x27c70d){const _0xc5e107=_0x331da1,_0x4b53e8=_0x1f097f(this[_0xc5e107(0x102)]);let _0x2afc47=_0x4b53e8[_0xc5e107(0x99)][_0xc5e107(0xa7)](_0xc5e107(0x124))||[..._0x290b9f];if(_0x4b53e8[_0xc5e107(0xdb)][_0xc5e107(0xdc)](_0xc5e107(0xda))){if(!this[_0xc5e107(0xd7)]){this[_0xc5e107(0xd7)]=!0x0;const _0x5e6f58=_0x4b53e8[_0xc5e107(0x11e)][_0xc5e107(0xa7)](_0xc5e107(0xf6));this[_0xc5e107(0x82)][_0xc5e107(0xfb)][_0xc5e107(0xe5)](_0xc5e107(0x115))['to'](_0x5e6f58,_0xc5e107(0xfa));}}else _0x2afc47=_0x2afc47[_0xc5e107(0x8b)](_0x4171a5=>_0xc5e107(0xd3)!=_0x4171a5);return this[_0xc5e107(0xac)][_0xc5e107(0x10c)](async()=>{const _0x90d0c8=_0xc5e107;this[_0x90d0c8(0x82)][_0x90d0c8(0xfb)][_0x90d0c8(0x96)](_0x90d0c8(0x126),{'id':_0x27c70d[_0x90d0c8(0x10a)]+':'+_0x27c70d['id'],'areActionsDisabled':_0x27c70d[_0x90d0c8(0xf1)],'showDiff':this[_0x90d0c8(0x8f)],'availableActions':_0x2afc47}),this[_0x90d0c8(0x107)](null);});}[_0x331da1(0xe2)](_0xbea4d,_0x31363e){const _0x295471=_0x331da1,_0xbf90ab=this[_0x295471(0x82)][_0x295471(0xfb)][_0x295471(0x111)][_0x295471(0xdf)];if(_0xbf90ab instanceof _0x53b28e)return this[_0x295471(0x82)][_0x295471(0xfb)][_0x295471(0x111)][_0x295471(0xcc)](_0xbf90ab),void this[_0x295471(0x82)][_0x295471(0xfb)][_0x295471(0x96)](_0x295471(0xe8),{'id':_0xbea4d['id'],'capabilities':{'isWebSearchEnabled':_0xbf90ab[_0x295471(0xed)][_0x295471(0xa8)]||_0x31363e[_0x295471(0xa8)],'isReasoningEnabled':_0xbf90ab[_0x295471(0xed)][_0x295471(0x8c)]||_0x31363e[_0x295471(0x8c)]}});this[_0x295471(0x82)][_0x295471(0xfb)][_0x295471(0x96)](_0x295471(0xe8),{'id':_0xbea4d['id'],'capabilities':_0x31363e});}[_0x331da1(0x110)](_0x250d4f){const _0x15f3c9=_0x331da1,_0xfa1578=this[_0x15f3c9(0x82)][_0x15f3c9(0xfb)][_0x15f3c9(0x111)][_0x15f3c9(0x121)](_0x1b70bc=>_0x1b70bc[_0x15f3c9(0xde)]['id']==_0x250d4f['id']&&_0x1b70bc instanceof _0x53b28e);_0xfa1578&&_0xfa1578[_0x15f3c9(0x11f)](_0x15f3c9(0x9a),_0x250d4f[_0x15f3c9(0x9a)]);}async[_0x331da1(0xf0)](_0x550ad8){const _0x205f92=_0x331da1,_0x2fa2f8=_0x550ad8[_0x205f92(0xd4)]||this[_0x205f92(0xc1)];return this[_0x205f92(0xac)][_0x205f92(0x10c)](async _0x4dd045=>{const _0x266191=_0x205f92;await this[_0x266191(0x82)][_0x266191(0xfb)][_0x266191(0x89)]({..._0x550ad8,'abortSignal':_0x4dd045,'renderingStrategy':_0x2fa2f8}),_0x550ad8[_0x266191(0x88)]&&this[_0x266191(0xc9)](_0x550ad8['id']);});}[_0x331da1(0x97)](_0x351703,_0x42a135){const _0x1e6ece=_0x331da1;this[_0x1e6ece(0x82)][_0x1e6ece(0xfb)][_0x1e6ece(0xc8)](_0x351703,_0x42a135);}async[_0x331da1(0x9b)](_0x2845c6){const _0x45e5cc=_0x331da1,_0x137836=_0x2845c6[_0x45e5cc(0xd4)]||this[_0x45e5cc(0xc1)];return this[_0x45e5cc(0xac)][_0x45e5cc(0x10c)](async _0x42dbe9=>{const _0x4485a2=_0x45e5cc;await this[_0x4485a2(0x82)][_0x4485a2(0xfb)][_0x4485a2(0xbe)]({..._0x2845c6,'abortSignal':_0x42dbe9,'renderingStrategy':_0x137836}),_0x2845c6[_0x4485a2(0x88)]&&this[_0x4485a2(0xc9)](_0x2845c6['id']);});}[_0x331da1(0x123)](_0x12cc35){const _0x3ddbdb=_0x331da1;this[_0x3ddbdb(0x82)][_0x3ddbdb(0xfb)][_0x3ddbdb(0x106)](_0x12cc35);}[_0x331da1(0xc9)](_0x23c6e9){const _0x140935=_0x331da1;this[_0x140935(0x82)][_0x140935(0xfb)][_0x140935(0xfd)](_0x23c6e9);}[_0x331da1(0xe7)](_0x1a8705){const _0x27ae17=_0x331da1;this[_0x27ae17(0x82)][_0x27ae17(0xfb)][_0x27ae17(0xc5)]()[_0x27ae17(0x8b)](_0x16367a=>_0x16367a[_0x27ae17(0xf5)](_0x1a8705))[_0x27ae17(0xc3)](_0x5566ef=>this[_0x27ae17(0x82)][_0x27ae17(0xfb)][_0x27ae17(0x105)](_0x5566ef));}[_0x331da1(0x108)](){const _0x36ce31=_0x331da1;this[_0x36ce31(0x107)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x1}),this[_0x36ce31(0x82)][_0x36ce31(0xb6)][_0x36ce31(0xfc)](!this[_0x36ce31(0x102)][_0x36ce31(0x99)][_0x36ce31(0xa7)](_0x36ce31(0xa4))),this[_0x36ce31(0x92)]=!0x0,this[_0x36ce31(0x82)][_0x36ce31(0xfb)][_0x36ce31(0xea)]();}[_0x331da1(0x120)](_0x3bc757){const _0x42e262=_0x331da1;this[_0x42e262(0xac)][_0x42e262(0x119)](),this[_0x42e262(0x82)][_0x42e262(0xfb)][_0x42e262(0xc5)]()[_0x42e262(0x8b)](_0x43a629=>_0x43a629[_0x42e262(0xf5)](_0x3bc757['id']))[_0x42e262(0xc3)](_0x19b227=>this[_0x42e262(0xc9)](_0x19b227)),this[_0x42e262(0x92)]=!0x1,this[_0x42e262(0x82)][_0x42e262(0xfb)][_0x42e262(0x114)]();}async[_0x331da1(0x100)](){const _0x47efcb=_0x331da1;return this[_0x47efcb(0xac)][_0x47efcb(0xae)][_0x47efcb(0xe1)](()=>{const _0x2c01f3=_0x47efcb;this[_0x2c01f3(0x92)]=!0x1,this[_0x2c01f3(0x82)][_0x2c01f3(0xfb)][_0x2c01f3(0x114)]();});}[_0x331da1(0xbc)](_0x23246a,_0xa930a2){const _0x37df21=_0x331da1;this[_0x37df21(0x82)][_0x37df21(0xb6)][_0x37df21(0xbc)](_0x23246a,_0xa930a2);}[_0x331da1(0xd8)](_0x1ef5de){const _0x1c6182=_0x331da1;this[_0x1c6182(0x82)][_0x1c6182(0xb6)][_0x1c6182(0xd8)](_0x1ef5de);}[_0x331da1(0xd9)](_0x1a768b,_0x372c00){const _0xc661a4=_0x331da1;this[_0xc661a4(0x82)][_0xc661a4(0xb6)][_0xc661a4(0xd9)](_0x1a768b,_0x372c00);}[_0x331da1(0x85)](_0x200907){const _0x2ef318=_0x331da1;this[_0x2ef318(0x82)][_0x2ef318(0xb6)][_0x2ef318(0x85)](_0x200907);}[_0x331da1(0xcb)](_0x1a4df7){const _0x406102=_0x331da1;this[_0x406102(0x82)][_0x406102(0xb6)][_0x406102(0xcb)](_0x1a4df7);}[_0x331da1(0xec)](){const _0xe2829=_0x331da1;this[_0xe2829(0x82)][_0xe2829(0xb6)][_0xe2829(0xec)]();}[_0x331da1(0xbf)](){const _0x379b90=_0x331da1;this[_0x379b90(0x82)][_0x379b90(0xb6)][_0x379b90(0xbf)]();}[_0x331da1(0xa3)](_0x227336,_0x3b7603,_0x121f4f){const _0x204a2e=_0x331da1;this[_0x204a2e(0x82)][_0x204a2e(0xb6)][_0x204a2e(0xa3)](_0x227336,_0x3b7603,_0x121f4f);}[_0x331da1(0xb0)](){const _0xa3f9f0=_0x331da1;this[_0xa3f9f0(0x82)][_0xa3f9f0(0xb6)][_0xa3f9f0(0xb0)](),this[_0xa3f9f0(0x82)][_0xa3f9f0(0xb6)][_0xa3f9f0(0x9f)](this[_0xa3f9f0(0x122)]());}[_0x331da1(0xe3)](_0x1cba6b){const _0x27add5=_0x331da1;this[_0x27add5(0x82)][_0x27add5(0xb6)][_0x27add5(0xe3)](_0x1cba6b);}[_0x331da1(0xd6)](_0x5a4646){const _0x2991bc=_0x331da1;this[_0x2991bc(0x82)][_0x2991bc(0xb6)][_0x2991bc(0xab)](_0x5a4646[_0x2991bc(0xa8)]),this[_0x2991bc(0x82)][_0x2991bc(0xb6)][_0x2991bc(0x104)](_0x5a4646[_0x2991bc(0x8c)]),this[_0x2991bc(0x82)][_0x2991bc(0xb6)][_0x2991bc(0x9f)](this[_0x2991bc(0x122)](_0x5a4646));}[_0x331da1(0xf3)](_0x4d18ab,_0x16b4f0){const _0x596140=_0x331da1;this[_0x596140(0x82)][_0x596140(0xb6)][_0x596140(0xee)](_0x4d18ab),_0x16b4f0&&this[_0x596140(0x82)][_0x596140(0xb6)][_0x596140(0xfc)](!0x1);}[_0x331da1(0x95)](_0x5acd2a){const _0x1c0497=_0x331da1;this[_0x1c0497(0xc1)]=_0x5acd2a;}[_0x331da1(0xa6)](_0xf4f356){const _0x57362b=_0x331da1;this[_0x57362b(0x82)][_0x57362b(0xfb)][_0x57362b(0xa6)](_0xf4f356);}[_0x331da1(0x8d)](){const _0x2e1d81=_0x331da1;this[_0x2e1d81(0xf2)](_0x2b4081(this[_0x2e1d81(0x102)][_0x2e1d81(0x116)],_0x2e1d81(0x8e)));}[_0x331da1(0xf2)](_0x1eb35a,_0x9fc9e8=!0x1){const _0x52ccbc=_0x331da1;if(_0x9fc9e8&&!_0xf36c22()&&_0x1eb35a[_0x52ccbc(0xcf)])return this[_0x52ccbc(0x82)][_0x52ccbc(0xad)][_0x52ccbc(0xd2)]='',void this[_0x52ccbc(0xf4)](_0x1eb35a);this[_0x52ccbc(0x82)][_0x52ccbc(0xad)][_0x52ccbc(0xd2)]=_0x1eb35a;}[_0x331da1(0x107)](_0x1c8cc4){const _0x3ea3b6=_0x331da1,_0x516464=this[_0x3ea3b6(0xdd)](_0x1c8cc4);this[_0x3ea3b6(0x82)][_0x3ea3b6(0xfb)][_0x3ea3b6(0x107)](_0x516464);}[_0x331da1(0xf4)](_0x21c002){const _0x21a1ef=_0x331da1;let _0x1467dd=0x0;clearInterval(this[_0x21a1ef(0x117)]),this[_0x21a1ef(0x117)]=setInterval(()=>{const _0x2da4f3=_0x21a1ef;this[_0x2da4f3(0x82)][_0x2da4f3(0xad)][_0x2da4f3(0xd2)]=this[_0x2da4f3(0x82)][_0x2da4f3(0xad)][_0x2da4f3(0xd2)]+_0x21c002[_0x1467dd],_0x1467dd++,_0x1467dd===_0x21c002[_0x2da4f3(0xcf)]&&clearInterval(this[_0x2da4f3(0x117)]);},0x1e);}[_0x331da1(0xe6)](_0x25c090){const _0x512dcd=_0x331da1;this[_0x512dcd(0x82)][_0x512dcd(0xad)][_0x512dcd(0x125)]=_0x25c090;}[_0x331da1(0xdd)](_0x51294a){const _0x49a047=_0x331da1;return _0x51294a?_0x51294a[_0x49a047(0xa8)]&&_0x51294a[_0x49a047(0x8c)]?_0x2b4081(this[_0x49a047(0x102)][_0x49a047(0x116)],_0x49a047(0xb1)):_0x51294a[_0x49a047(0xa8)]?_0x2b4081(this[_0x49a047(0x102)][_0x49a047(0x116)],_0x49a047(0xce)):_0x51294a[_0x49a047(0x8c)]?_0x2b4081(this[_0x49a047(0x102)][_0x49a047(0x116)],_0x49a047(0x90)):_0x2b4081(this[_0x49a047(0x102)][_0x49a047(0x116)],_0x49a047(0xb2)):'';}[_0x331da1(0x122)](_0x724e13){const _0x10aff5=_0x331da1;return _0x724e13?_0x724e13[_0x10aff5(0xa8)]&&_0x724e13[_0x10aff5(0x8c)]?_0x2b4081(this[_0x10aff5(0x102)][_0x10aff5(0x116)],_0x10aff5(0xf9)):_0x724e13[_0x10aff5(0xa8)]?_0x2b4081(this[_0x10aff5(0x102)][_0x10aff5(0x116)],_0x10aff5(0xc2)):_0x724e13[_0x10aff5(0x8c)]?_0x2b4081(this[_0x10aff5(0x102)][_0x10aff5(0x116)],_0x10aff5(0xa9)):_0x2b4081(this[_0x10aff5(0x102)][_0x10aff5(0x116)],_0x10aff5(0xe9)):_0x2b4081(this[_0x10aff5(0x102)][_0x10aff5(0x116)],_0x10aff5(0xe9));}[_0x331da1(0xa2)](_0x2c842c,_0xa7eae3,_0x146c4e,_0x54006f){const _0x1832d9=_0x331da1;this[_0x1832d9(0x82)][_0x1832d9(0xa2)](_0x2c842c,_0xa7eae3,_0x146c4e,_0x54006f);}[_0x331da1(0x10d)](_0x191ce9){const _0x113118=_0x331da1;this[_0x113118(0x82)][_0x113118(0x10d)](_0x191ce9);}[_0x331da1(0x93)](){const _0x105a21=_0x331da1;this[_0x105a21(0x82)][_0x105a21(0xb6)][_0x105a21(0x93)]();}[_0x331da1(0xb3)](_0x54e9ee,_0x2cb79f){const _0x4b2c56=_0x331da1;this[_0x4b2c56(0x82)][_0x4b2c56(0xfb)][_0x4b2c56(0xbd)](_0x54e9ee,_0x2cb79f);}[_0x331da1(0xea)](){const _0xcf07a2=_0x331da1;this[_0xcf07a2(0x82)][_0xcf07a2(0xfb)][_0xcf07a2(0xea)]();}[_0x331da1(0x80)](){const _0x254318=_0x331da1;this[_0x254318(0x82)][_0x254318(0xb6)][_0x254318(0xca)]=!0x0;}[_0x331da1(0x112)](){const _0x422acd=_0x331da1;this[_0x422acd(0x82)][_0x422acd(0xb6)][_0x422acd(0xca)]=!0x1;}}function _0xe230(){const _0x3f4b64=['ai-reply','feedItemRenderingStrategy','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH','forEach','<p>','getItemIds','setModelList','pluginName','updateWebSources','markFeedItemAsDone','isDisabled','setConversationContext','remove','addFeedItemError','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH','length','856530SBFXnc','5416620RPoZpD','label','insertSuggestion','renderingStrategy','createConversation','updateCapabilities','_isTrackChangesCommandValueBound','removeContextItem','setContextItemLoading','TrackChanges','plugins','has','_getLoadingMessage','options','last','665032NdkCfh','then','addFeedInteractionHeader','setAddContextOptions','addFeedItemUserMessage','bind','setIsMaximized','removeFeedInteraction','interaction-header','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REGULAR','startAutoScroll','50KUwXqw','clearPendingContextUI','capabilities','setModel','isOfficialPlugin','updateFeedItemAIReplyContent','areActionsDisabled','setConversationTitle','setSelectedModel','_animateConversationTitle','startsWith','trackChanges','chat','_interactionPromiseResolver','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH_REASONING','value','chatFeed','disableModelSelector','markItemAsDone','AITabs','233886SeUGNn','finishInteraction','96775wyUKEf','context','displayedPrompt','setReasoning','removeItem','updateSuggestionPartState','setLoadingMessage','startInteraction','208lfDJJP','interactionId','isPremiumPlugin','enqueue','closeSourceResourceBalloon','AIChatUI','3528009QnwCqK','updateFeedInteractionHeader','children','enableControls','conversation-start','stopAutoScroll','isTrackChangesOn','locale','_titleAnimationInterval','delegate','abort','AI_CHAT_WELCOME_MESSAGE','quickActionData','26167pZjKYu','12QThpPk','commands','set','stopInteraction','find','_getInputPlaceholder','updateFeedItemAIReplySuggestionPartState','ai.availableReplyActions','isMaximized','ai-suggestion-reply','from','disableControls','addTab','_view','destroy','enableModelSelector','setIsUploadInProgress','values','userMessage','isDone','updateReplyItem','availableModels','filter','isReasoningEnabled','resetConversationTitle','AI_CHAT_HEADING','showDiff','AI_CHAT_FEED_LOADING_MESSAGE_REASONING','ai.chat.context.searchInputVisibleFrom','isBusy','focusPromptInput','requires','setFeedItemRenderingStrategy','addItem','updateFeedItemAIReplySources','isModelAvailable','config','isVisible','updateFeedItemAIReplySuggestionContent','addFeedItemAIReply','user-message','showResizeButton','setInputPlaceholder','3MJOims','streaming','populateSourceResourceBalloon','updateResourceState','ai.chat.models.modelSelectorAlwaysVisible','view','toggleLoadingSkeleton','get','isWebSearchEnabled','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REASONING','addFeedItemAISuggestion','setWebSearch','_promiseQueue','chatHeader','queueEmptyPromise','contextItems','resetMessageInput','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH_REASONING','AI_CHAT_FEED_LOADING_MESSAGE_REGULAR','scrollFeedToSuggestion','error-message','isPending','chatControls','toggleSuggestionDisplayMode','clear','isLoading','addFeedItemStaticMessage','</p>','addContextItem','scrollToSuggestion','updateSuggestionItem','clearConversationContextUI'];_0xe230=function(){return _0x3f4b64;};return _0xe230();}
|
|
23
|
+
const _0x16874d=_0x7ba9;(function(_0x5b3a85,_0x358f3d){const _0x34ca06=_0x7ba9,_0x127a77=_0x5b3a85();while(!![]){try{const _0x123781=parseInt(_0x34ca06(0x1f0))/0x1*(parseInt(_0x34ca06(0x24b))/0x2)+-parseInt(_0x34ca06(0x1ed))/0x3+-parseInt(_0x34ca06(0x258))/0x4+-parseInt(_0x34ca06(0x202))/0x5*(parseInt(_0x34ca06(0x200))/0x6)+-parseInt(_0x34ca06(0x22f))/0x7*(-parseInt(_0x34ca06(0x26b))/0x8)+parseInt(_0x34ca06(0x1dc))/0x9*(parseInt(_0x34ca06(0x24e))/0xa)+-parseInt(_0x34ca06(0x1e2))/0xb*(-parseInt(_0x34ca06(0x1f8))/0xc);if(_0x123781===_0x358f3d)break;else _0x127a77['push'](_0x127a77['shift']());}catch(_0x44ee26){_0x127a77['push'](_0x127a77['shift']());}}}(_0x4a65,0x8d8b4));function _0x7ba9(_0x53c6e2,_0x1a5998){const _0x4a6539=_0x4a65();return _0x7ba9=function(_0x7ba91a,_0x551572){_0x7ba91a=_0x7ba91a-0x1cb;let _0x7ef5e7=_0x4a6539[_0x7ba91a];return _0x7ef5e7;},_0x7ba9(_0x53c6e2,_0x1a5998);}import{ContextPlugin as _0x5660e1}from'ckeditor5/src/core.js';import{_isMotionReduced as _0x235c00}from'ckeditor5/src/utils.js';import{AIChatView as _0x5049d0}from'./ui/aichatview.js';import{AITabs as _0x175cbf}from'../aitabs/aitabs.js';import{getTranslation as _0x1d7aed}from'../aicore/utils/common-translations.js';import{IconAIChat as _0x409e49}from'ckeditor5/src/icons.js';import{AIChatFeedInteractionHeaderView as _0x5875ea}from'./ui/feed/aichatfeedinteractionheaderview.js';import{PromiseQueue as _0xd2def3}from'./utils/promisequeue.js';import{AI_CHAT_UI_EVENT_NAMES as _0xa96303}from'./utils/eventnames.js';import'../../theme/aichat/aichat.css';import{getEditorFromContext as _0x130c64}from'../aicore/utils/geteditorfromcontext.js';import{AI_REPLY_ACTIONS as _0x111072}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';export class AIChatUI extends _0x5660e1{static get[_0x16874d(0x1f3)](){return[_0x175cbf];}[_0x16874d(0x242)];static get[_0x16874d(0x20b)](){const _0xdd4ae4=_0x16874d;return _0xdd4ae4(0x26e);}static get[_0x16874d(0x209)](){return!0x0;}static get[_0x16874d(0x245)](){return!0x0;}[_0x16874d(0x1cb)]=_0x16874d(0x1ea);[_0x16874d(0x24f)]=!0x0;[_0x16874d(0x266)];[_0x16874d(0x22c)];[_0x16874d(0x207)]=void 0x0;[_0x16874d(0x217)]=!0x1;constructor(_0x5ed250){const _0x5c8b74=_0x16874d;super(_0x5ed250);const _0x24467a=this[_0x5c8b74(0x25a)][_0x5c8b74(0x271)][_0x5c8b74(0x203)](_0x5c8b74(0x243));this[_0x5c8b74(0x1f2)](_0x5c8b74(0x26d),!0x1),this[_0x5c8b74(0x266)]=new _0xd2def3(),this[_0x5c8b74(0x242)]=new _0x5049d0(this[_0x5c8b74(0x25a)][_0x5c8b74(0x222)],{'showResizeButton':_0x24467a[_0x5c8b74(0x20d)],'contextResourcesSearchInputVisibleFrom':this[_0x5c8b74(0x25a)][_0x5c8b74(0x221)][_0x5c8b74(0x203)](_0x5c8b74(0x238))}),this[_0x5c8b74(0x242)][_0x5c8b74(0x219)](..._0xa96303)['to'](this),this[_0x5c8b74(0x242)]['on'](_0x5c8b74(0x1f6),(_0x38fd1f,{showDiff:_0x536bcf})=>{const _0x359cb4=_0x5c8b74;this[_0x359cb4(0x24f)]=_0x536bcf;}),_0x24467a[_0x5c8b74(0x227)][_0x5c8b74(0x257)]({'id':_0x5c8b74(0x22e),'buttonLabel':_0x1d7aed(this[_0x5c8b74(0x25a)][_0x5c8b74(0x222)],_0x5c8b74(0x255)),'buttonIcon':_0x409e49,'order':0x0,'content':this[_0x5c8b74(0x242)]}),this[_0x5c8b74(0x242)][_0x5c8b74(0x263)][_0x5c8b74(0x1fa)](_0x5c8b74(0x23f))['to'](this,_0x5c8b74(0x26d),_0x2bd7bb=>_0x2bd7bb),this[_0x5c8b74(0x242)][_0x5c8b74(0x220)][_0x5c8b74(0x1fa)](_0x5c8b74(0x25b))['to'](this,_0x5c8b74(0x26d),_0x4eb5ec=>_0x4eb5ec),this[_0x5c8b74(0x242)][_0x5c8b74(0x263)][_0x5c8b74(0x1da)](this[_0x5c8b74(0x1f4)]()),this[_0x5c8b74(0x1fa)](_0x5c8b74(0x251))['to'](this[_0x5c8b74(0x242)][_0x5c8b74(0x263)],_0x5c8b74(0x251));}[_0x16874d(0x223)](){const _0x186b7d=_0x16874d;super[_0x186b7d(0x223)](),this[_0x186b7d(0x207)]&&clearInterval(this[_0x186b7d(0x207)]);}[_0x16874d(0x230)](_0x387664){const _0x248cdb=_0x16874d;this[_0x248cdb(0x242)][_0x248cdb(0x220)][_0x248cdb(0x1e6)](),this[_0x248cdb(0x242)][_0x248cdb(0x263)][_0x248cdb(0x225)](),this[_0x248cdb(0x242)][_0x248cdb(0x263)][_0x248cdb(0x1d3)](_0x387664[_0x248cdb(0x1e7)],!this[_0x248cdb(0x25a)][_0x248cdb(0x221)][_0x248cdb(0x203)](_0x248cdb(0x24d))),this[_0x248cdb(0x272)]({'id':_0x248cdb(0x21e),'staticMessage':_0x1d7aed(this[_0x248cdb(0x25a)][_0x248cdb(0x222)],_0x248cdb(0x235))});}[_0x16874d(0x272)]({id:_0x292170,staticMessage:_0x4af071}){const _0x1aab1d=_0x16874d;this[_0x1aab1d(0x242)][_0x1aab1d(0x220)][_0x1aab1d(0x1ce)](_0x1aab1d(0x25d),{'id':_0x292170,'initialContent':_0x1aab1d(0x1d0)+_0x4af071+_0x1aab1d(0x267)});}[_0x16874d(0x21f)](_0x1d0698){const _0xeab08e=_0x16874d,_0x1d3521=_0x1d0698[_0xeab08e(0x273)]?.[_0xeab08e(0x1e5)]||_0x1d0698[_0xeab08e(0x241)];this[_0xeab08e(0x242)][_0xeab08e(0x220)][_0xeab08e(0x1ce)](_0xeab08e(0x1ee),{'contextItems':Array[_0xeab08e(0x24c)](_0x1d0698[_0xeab08e(0x1cc)][_0xeab08e(0x204)]()),'initialContent':_0xeab08e(0x1d0)+_0x1d3521+_0xeab08e(0x267),'id':_0x1d0698['id']});}[_0x16874d(0x201)]({errorMessage:_0xc19911,id:_0x1ee1e9}){const _0x44f848=_0x16874d;this[_0x44f848(0x242)][_0x44f848(0x220)][_0x44f848(0x1ce)](_0x44f848(0x21b),{'initialContent':_0x44f848(0x1d0)+_0xc19911+_0x44f848(0x267),'id':_0x1ee1e9});}[_0x16874d(0x208)](_0x45de60){const _0x5f9491=_0x16874d;return this[_0x5f9491(0x266)][_0x5f9491(0x21a)](async()=>{const _0x3ba356=_0x5f9491;this[_0x3ba356(0x242)][_0x3ba356(0x220)][_0x3ba356(0x1ce)](_0x3ba356(0x25d),{'id':_0x45de60[_0x3ba356(0x1e1)]+':'+_0x45de60['id']}),this[_0x3ba356(0x20c)](null);});}async[_0x16874d(0x1d9)](_0x395489){const _0x473cca=_0x16874d,_0x40ff16=_0x130c64(this[_0x473cca(0x25a)]);let _0x5630ea=_0x40ff16[_0x473cca(0x221)][_0x473cca(0x203)](_0x473cca(0x25e))||[..._0x111072];if(_0x40ff16[_0x473cca(0x271)][_0x473cca(0x237)](_0x473cca(0x23e))){if(!this[_0x473cca(0x217)]){this[_0x473cca(0x217)]=!0x0;const _0x3e21d9=_0x40ff16[_0x473cca(0x22a)][_0x473cca(0x203)](_0x473cca(0x211));this[_0x473cca(0x242)][_0x473cca(0x220)][_0x473cca(0x1fa)](_0x473cca(0x212))['to'](_0x3e21d9,_0x473cca(0x218));}}else _0x5630ea=_0x5630ea[_0x473cca(0x1f9)](_0x29a294=>_0x473cca(0x261)!=_0x29a294);return this[_0x473cca(0x266)][_0x473cca(0x21a)](async()=>{const _0x57001d=_0x473cca;this[_0x57001d(0x242)][_0x57001d(0x220)][_0x57001d(0x1ce)](_0x57001d(0x269),{'id':_0x395489[_0x57001d(0x1e1)]+':'+_0x395489['id'],'areActionsDisabled':_0x395489[_0x57001d(0x259)],'showDiff':this[_0x57001d(0x24f)],'availableActions':_0x5630ea}),this[_0x57001d(0x20c)](null);});}[_0x16874d(0x1e8)](_0x57b1f1,_0x57dea0){const _0x2c08d0=_0x16874d,_0x164c3f=this[_0x2c08d0(0x242)][_0x2c08d0(0x220)][_0x2c08d0(0x22d)][_0x2c08d0(0x21c)];if(_0x164c3f instanceof _0x5875ea)return this[_0x2c08d0(0x242)][_0x2c08d0(0x220)][_0x2c08d0(0x22d)][_0x2c08d0(0x25c)](_0x164c3f),void this[_0x2c08d0(0x242)][_0x2c08d0(0x220)][_0x2c08d0(0x1ce)](_0x2c08d0(0x213),{'id':_0x57b1f1['id'],'capabilities':{'isWebSearchEnabled':_0x164c3f[_0x2c08d0(0x214)][_0x2c08d0(0x23b)]||_0x57dea0[_0x2c08d0(0x23b)],'isReasoningEnabled':_0x164c3f[_0x2c08d0(0x214)][_0x2c08d0(0x1d5)]||_0x57dea0[_0x2c08d0(0x1d5)]}});this[_0x2c08d0(0x242)][_0x2c08d0(0x220)][_0x2c08d0(0x1ce)](_0x2c08d0(0x213),{'id':_0x57b1f1['id'],'capabilities':_0x57dea0});}[_0x16874d(0x26f)](_0x25e8c2){const _0x3f37d3=_0x16874d,_0x36365e=this[_0x3f37d3(0x242)][_0x3f37d3(0x220)][_0x3f37d3(0x22d)][_0x3f37d3(0x210)](_0x21a62e=>_0x21a62e[_0x3f37d3(0x25f)]['id']==_0x25e8c2['id']&&_0x21a62e instanceof _0x5875ea);_0x36365e&&_0x36365e[_0x3f37d3(0x1f2)](_0x3f37d3(0x1eb),_0x25e8c2[_0x3f37d3(0x1eb)]);}async[_0x16874d(0x1f7)](_0xf18282){const _0x25d95f=_0x16874d,_0x186250=_0xf18282[_0x25d95f(0x1d4)]||this[_0x25d95f(0x1cb)];return this[_0x25d95f(0x266)][_0x25d95f(0x21a)](async _0x3296c0=>{const _0x4a261b=_0x25d95f;await this[_0x4a261b(0x242)][_0x4a261b(0x220)][_0x4a261b(0x234)]({..._0xf18282,'abortSignal':_0x3296c0,'renderingStrategy':_0x186250}),_0xf18282[_0x4a261b(0x1e3)]&&this[_0x4a261b(0x26c)](_0xf18282['id']);});}[_0x16874d(0x1f1)](_0x57f399,_0x132488){const _0x399309=_0x16874d;this[_0x399309(0x242)][_0x399309(0x220)][_0x399309(0x1d2)](_0x57f399,_0x132488);}async[_0x16874d(0x1d8)](_0x4d9904){const _0x42ea9c=_0x16874d,_0x59d54a=_0x4d9904[_0x42ea9c(0x1d4)]||this[_0x42ea9c(0x1cb)];return this[_0x42ea9c(0x266)][_0x42ea9c(0x21a)](async _0x2fae03=>{const _0x5341ac=_0x42ea9c;await this[_0x5341ac(0x242)][_0x5341ac(0x220)][_0x5341ac(0x254)]({..._0x4d9904,'abortSignal':_0x2fae03,'renderingStrategy':_0x59d54a}),_0x4d9904[_0x5341ac(0x1e3)]&&this[_0x5341ac(0x26c)](_0x4d9904['id']);});}[_0x16874d(0x224)](_0x166726){const _0x4271ef=_0x16874d;this[_0x4271ef(0x242)][_0x4271ef(0x220)][_0x4271ef(0x24a)](_0x166726);}[_0x16874d(0x26c)](_0x479d83){const _0x52d562=_0x16874d;this[_0x52d562(0x242)][_0x52d562(0x220)][_0x52d562(0x239)](_0x479d83);}[_0x16874d(0x253)](_0x547b73){const _0x48727b=_0x16874d;this[_0x48727b(0x242)][_0x48727b(0x220)][_0x48727b(0x233)]()[_0x48727b(0x1f9)](_0x2d3d23=>_0x2d3d23[_0x48727b(0x268)](_0x547b73))[_0x48727b(0x265)](_0xf3c739=>this[_0x48727b(0x242)][_0x48727b(0x220)][_0x48727b(0x26a)](_0xf3c739));}[_0x16874d(0x236)](){const _0x10753a=_0x16874d;this[_0x10753a(0x20c)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x1}),this[_0x10753a(0x242)][_0x10753a(0x263)][_0x10753a(0x1df)](!this[_0x10753a(0x25a)][_0x10753a(0x221)][_0x10753a(0x203)](_0x10753a(0x24d))),this[_0x10753a(0x26d)]=!0x0,this[_0x10753a(0x242)][_0x10753a(0x220)][_0x10753a(0x226)]();}[_0x16874d(0x229)](_0x399fe6){const _0x1b361a=_0x16874d;this[_0x1b361a(0x266)][_0x1b361a(0x20f)](),this[_0x1b361a(0x242)][_0x1b361a(0x220)][_0x1b361a(0x233)]()[_0x1b361a(0x1f9)](_0x103c8e=>_0x103c8e[_0x1b361a(0x268)](_0x399fe6['id']))[_0x1b361a(0x265)](_0xc90d24=>this[_0x1b361a(0x26c)](_0xc90d24)),this[_0x1b361a(0x26d)]=!0x1,this[_0x1b361a(0x242)][_0x1b361a(0x220)][_0x1b361a(0x252)]();}async[_0x16874d(0x1fb)](){const _0x48defc=_0x16874d;return this[_0x48defc(0x266)][_0x48defc(0x246)][_0x48defc(0x247)](()=>{const _0x387daa=_0x48defc;this[_0x387daa(0x26d)]=!0x1,this[_0x387daa(0x242)][_0x387daa(0x220)][_0x387daa(0x252)]();});}[_0x16874d(0x216)](_0x3b20c4,_0x404179){const _0x1d6ae2=_0x16874d;this[_0x1d6ae2(0x242)][_0x1d6ae2(0x263)][_0x1d6ae2(0x216)](_0x3b20c4,_0x404179);}[_0x16874d(0x1de)](_0x146eb3){const _0x3a4b92=_0x16874d;this[_0x3a4b92(0x242)][_0x3a4b92(0x263)][_0x3a4b92(0x1de)](_0x146eb3);}[_0x16874d(0x1e4)](_0x2fa1d6,_0x3cfd82){const _0x49aae3=_0x16874d;this[_0x49aae3(0x242)][_0x49aae3(0x263)][_0x49aae3(0x1e4)](_0x2fa1d6,_0x3cfd82);}[_0x16874d(0x1ff)](_0x40c7b7){const _0x49e8e1=_0x16874d;this[_0x49e8e1(0x242)][_0x49e8e1(0x263)][_0x49e8e1(0x1ff)](_0x40c7b7);}[_0x16874d(0x1db)](_0x7bac38){const _0x187bf0=_0x16874d;this[_0x187bf0(0x242)][_0x187bf0(0x263)][_0x187bf0(0x1db)](_0x7bac38);}[_0x16874d(0x249)](){const _0x229c4e=_0x16874d;this[_0x229c4e(0x242)][_0x229c4e(0x263)][_0x229c4e(0x249)]();}[_0x16874d(0x21d)](){const _0x374b44=_0x16874d;this[_0x374b44(0x242)][_0x374b44(0x263)][_0x374b44(0x21d)]();}[_0x16874d(0x248)](_0x5d0105,_0x16940f,_0x2e36e4){const _0x9472fc=_0x16874d;this[_0x9472fc(0x242)][_0x9472fc(0x263)][_0x9472fc(0x248)](_0x5d0105,_0x16940f,_0x2e36e4);}[_0x16874d(0x1fc)](){const _0x14d6ef=_0x16874d;this[_0x14d6ef(0x242)][_0x14d6ef(0x263)][_0x14d6ef(0x1fc)](),this[_0x14d6ef(0x242)][_0x14d6ef(0x263)][_0x14d6ef(0x1da)](this[_0x14d6ef(0x1f4)]());}[_0x16874d(0x1d6)](_0x1ba8f3){const _0x1cdb55=_0x16874d;this[_0x1cdb55(0x242)][_0x1cdb55(0x263)][_0x1cdb55(0x1d6)](_0x1ba8f3);}[_0x16874d(0x1fe)](_0x37f512){const _0xe542c0=_0x16874d;this[_0xe542c0(0x242)][_0xe542c0(0x263)][_0xe542c0(0x1e9)](_0x37f512[_0xe542c0(0x23b)]),this[_0xe542c0(0x242)][_0xe542c0(0x263)][_0xe542c0(0x250)](_0x37f512[_0xe542c0(0x1d5)]),this[_0xe542c0(0x242)][_0xe542c0(0x263)][_0xe542c0(0x1da)](this[_0xe542c0(0x1f4)](_0x37f512));}[_0x16874d(0x260)](_0x1baf1e,_0x37007a){const _0x5dc50f=_0x16874d;this[_0x5dc50f(0x242)][_0x5dc50f(0x263)][_0x5dc50f(0x262)](_0x1baf1e),_0x37007a&&this[_0x5dc50f(0x242)][_0x5dc50f(0x263)][_0x5dc50f(0x1df)](!0x1);}[_0x16874d(0x22b)](_0x3b33f0){const _0x15dcf7=_0x16874d;this[_0x15dcf7(0x1cb)]=_0x3b33f0;}[_0x16874d(0x215)](_0x297f86){const _0x538c35=_0x16874d;this[_0x538c35(0x242)][_0x538c35(0x220)][_0x538c35(0x215)](_0x297f86);}[_0x16874d(0x1dd)](){const _0x4b16e7=_0x16874d;this[_0x4b16e7(0x240)](_0x1d7aed(this[_0x4b16e7(0x25a)][_0x4b16e7(0x222)],_0x4b16e7(0x255)));}[_0x16874d(0x240)](_0x18c675,_0x1fb5b3=!0x1){const _0x29dfb7=_0x16874d;if(_0x1fb5b3&&!_0x235c00()&&_0x18c675[_0x29dfb7(0x1f5)])return this[_0x29dfb7(0x242)][_0x29dfb7(0x1d7)][_0x29dfb7(0x20a)]='',void this[_0x29dfb7(0x1e0)](_0x18c675);this[_0x29dfb7(0x242)][_0x29dfb7(0x1d7)][_0x29dfb7(0x20a)]=_0x18c675;}[_0x16874d(0x20c)](_0x5c53ba){const _0x2c7b53=_0x16874d,_0x451ee7=this[_0x2c7b53(0x1d1)](_0x5c53ba);this[_0x2c7b53(0x242)][_0x2c7b53(0x220)][_0x2c7b53(0x20c)](_0x451ee7);}[_0x16874d(0x1e0)](_0x55a9c9){const _0xff5cf6=_0x16874d;let _0x534a99=0x0;clearInterval(this[_0xff5cf6(0x207)]),this[_0xff5cf6(0x207)]=setInterval(()=>{const _0x3d743b=_0xff5cf6;this[_0x3d743b(0x242)][_0x3d743b(0x1d7)][_0x3d743b(0x20a)]=this[_0x3d743b(0x242)][_0x3d743b(0x1d7)][_0x3d743b(0x20a)]+_0x55a9c9[_0x534a99],_0x534a99++,_0x534a99===_0x55a9c9[_0x3d743b(0x1f5)]&&clearInterval(this[_0x3d743b(0x207)]);},0x1e);}[_0x16874d(0x232)](_0x17b212){const _0xecd03d=_0x16874d;this[_0xecd03d(0x242)][_0xecd03d(0x1d7)][_0xecd03d(0x1fd)]=_0x17b212;}[_0x16874d(0x1d1)](_0x5a003d){const _0x1a4753=_0x16874d;return _0x5a003d?_0x5a003d[_0x1a4753(0x23b)]&&_0x5a003d[_0x1a4753(0x1d5)]?_0x1d7aed(this[_0x1a4753(0x25a)][_0x1a4753(0x222)],_0x1a4753(0x23d)):_0x5a003d[_0x1a4753(0x23b)]?_0x1d7aed(this[_0x1a4753(0x25a)][_0x1a4753(0x222)],_0x1a4753(0x244)):_0x5a003d[_0x1a4753(0x1d5)]?_0x1d7aed(this[_0x1a4753(0x25a)][_0x1a4753(0x222)],_0x1a4753(0x270)):_0x1d7aed(this[_0x1a4753(0x25a)][_0x1a4753(0x222)],_0x1a4753(0x23c)):'';}[_0x16874d(0x1f4)](_0x230280){const _0x5e7d17=_0x16874d;return _0x230280?_0x230280[_0x5e7d17(0x23b)]&&_0x230280[_0x5e7d17(0x1d5)]?_0x1d7aed(this[_0x5e7d17(0x25a)][_0x5e7d17(0x222)],_0x5e7d17(0x231)):_0x230280[_0x5e7d17(0x23b)]?_0x1d7aed(this[_0x5e7d17(0x25a)][_0x5e7d17(0x222)],_0x5e7d17(0x1cd)):_0x230280[_0x5e7d17(0x1d5)]?_0x1d7aed(this[_0x5e7d17(0x25a)][_0x5e7d17(0x222)],_0x5e7d17(0x1ef)):_0x1d7aed(this[_0x5e7d17(0x25a)][_0x5e7d17(0x222)],_0x5e7d17(0x205)):_0x1d7aed(this[_0x5e7d17(0x25a)][_0x5e7d17(0x222)],_0x5e7d17(0x205));}[_0x16874d(0x1ec)](_0x186b2f,_0xe73f21,_0x451419,_0x3f1f29){const _0x19e450=_0x16874d;this[_0x19e450(0x242)][_0x19e450(0x1ec)](_0x186b2f,_0xe73f21,_0x451419,_0x3f1f29);}[_0x16874d(0x206)](_0x1558d2){const _0x9546ae=_0x16874d;this[_0x9546ae(0x242)][_0x9546ae(0x206)](_0x1558d2);}[_0x16874d(0x228)](){const _0x5c1f43=_0x16874d;this[_0x5c1f43(0x242)][_0x5c1f43(0x263)][_0x5c1f43(0x228)]();}[_0x16874d(0x256)](_0x8a940c,_0x1ce572){const _0x6e5af4=_0x16874d;this[_0x6e5af4(0x242)][_0x6e5af4(0x220)][_0x6e5af4(0x264)](_0x8a940c,_0x1ce572);}[_0x16874d(0x226)](){const _0x5220df=_0x16874d;this[_0x5220df(0x242)][_0x5220df(0x220)][_0x5220df(0x226)]();}[_0x16874d(0x23a)](){const _0x427091=_0x16874d;this[_0x427091(0x242)][_0x427091(0x263)][_0x427091(0x1cf)]=!0x0;}[_0x16874d(0x20e)](){const _0x20e308=_0x16874d;this[_0x20e308(0x242)][_0x20e308(0x263)][_0x20e308(0x1cf)]=!0x1;}}function _0x4a65(){const _0xd532fa=['value','delegate','enqueue','error-message','last','clearConversationContextUI','conversation-start','addFeedItemUserMessage','chatFeed','config','locale','destroy','updateFeedItemAIReplySuggestionPartState','enableModelSelector','startAutoScroll','view','focusPromptInput','stopInteraction','commands','setFeedItemRenderingStrategy','_interactionPromiseResolver','children','chat','95494gpaqFz','createConversation','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH_REASONING','setIsMaximized','getItemIds','updateReplyItem','AI_CHAT_WELCOME_MESSAGE','startInteraction','has','ai.chat.context.searchInputVisibleFrom','markItemAsDone','disableControls','isWebSearchEnabled','AI_CHAT_FEED_LOADING_MESSAGE_REGULAR','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH_REASONING','TrackChanges','isLoading','setConversationTitle','userMessage','_view','AITabs','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH','isPremiumPlugin','queueEmptyPromise','then','updateResourceState','clearPendingContextUI','updateSuggestionPartState','10ckxoub','from','ai.chat.models.modelSelectorAlwaysVisible','10HCopNn','showDiff','setReasoning','isModelAvailable','stopAutoScroll','removeFeedInteraction','updateSuggestionItem','AI_CHAT_HEADING','scrollFeedToSuggestion','addTab','3217840VDMIul','areActionsDisabled','context','isPending','remove','ai-reply','ai.availableReplyActions','options','setSelectedModel','insertSuggestion','setModel','chatControls','scrollToSuggestion','forEach','_promiseQueue','</p>','startsWith','ai-suggestion-reply','removeItem','88tfKBCc','markFeedItemAsDone','isBusy','AIChatUI','updateFeedInteractionHeader','AI_CHAT_FEED_LOADING_MESSAGE_REASONING','plugins','addFeedItemStaticMessage','quickActionData','feedItemRenderingStrategy','contextItems','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH','addItem','isDisabled','<p>','_getLoadingMessage','updateWebSources','setModelList','renderingStrategy','isReasoningEnabled','setAddContextOptions','chatHeader','updateFeedItemAIReplySuggestionContent','addFeedItemAISuggestion','setInputPlaceholder','setConversationContext','2542941TudlfL','resetConversationTitle','removeContextItem','disableModelSelector','_animateConversationTitle','interactionId','135179QJvRTK','isDone','setContextItemLoading','displayedPrompt','clear','availableModels','addFeedInteractionHeader','setWebSearch','streaming','isVisible','populateSourceResourceBalloon','3106488LYVlUI','user-message','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REASONING','138615OhVKrz','updateFeedItemAIReplySources','set','requires','_getInputPlaceholder','length','toggleSuggestionDisplayMode','updateFeedItemAIReplyContent','1728ZHoQAV','filter','bind','finishInteraction','resetMessageInput','isMaximized','updateCapabilities','setIsUploadInProgress','12sVjSTJ','addFeedItemError','1188955QDAzyv','get','values','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REGULAR','closeSourceResourceBalloon','_titleAnimationInterval','addFeedItemAIReply','isOfficialPlugin','label','pluginName','setLoadingMessage','showResizeButton','enableControls','abort','find','trackChanges','isTrackChangesOn','interaction-header','capabilities','toggleLoadingSkeleton','addContextItem','_isTrackChangesCommandValueBound'];_0x4a65=function(){return _0xd532fa;};return _0x4a65();}
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const _0x5ce0f0=_0x45a4;(function(_0x3a93d8,_0x55c02a){const _0x2278da=_0x45a4,_0x3663d4=_0x3a93d8();while(!![]){try{const _0x54275e=-parseInt(_0x2278da(0xd5))/0x1*(-parseInt(_0x2278da(0xb5))/0x2)+-parseInt(_0x2278da(0x73))/0x3*(parseInt(_0x2278da(0x75))/0x4)+parseInt(_0x2278da(0xb0))/0x5*(-parseInt(_0x2278da(0xcf))/0x6)+-parseInt(_0x2278da(0x9e))/0x7+-parseInt(_0x2278da(0xd9))/0x8*(-parseInt(_0x2278da(0xc8))/0x9)+-parseInt(_0x2278da(0xb6))/0xa*(parseInt(_0x2278da(0x92))/0xb)+parseInt(_0x2278da(0xc6))/0xc;if(_0x54275e===_0x55c02a)break;else _0x3663d4['push'](_0x3663d4['shift']());}catch(_0x44829c){_0x3663d4['push'](_0x3663d4['shift']());}}}(_0x59b8,0x52d8a));import{CKEditorError as _0x5e1efc,ObservableMixin as _0x3c1da4,uid as _0x17380f}from'ckeditor5/src/utils.js';import{AIContextItemType as _0x32bff9,AIContextTextResourceType as _0x293d37}from'../../aicore/model/aicontext.js';import{escape as _0x18f612}from'es-toolkit/compat';import{errorsMap as _0xe1bb0}from'../../errorsmap.js';function _0x45a4(_0x590ce9,_0x1bf571){const _0x59b8d7=_0x59b8();return _0x45a4=function(_0x45a44a,_0x560bf0){_0x45a44a=_0x45a44a-0x6a;let _0x57a681=_0x59b8d7[_0x45a44a];return _0x57a681;},_0x45a4(_0x590ce9,_0x1bf571);}export const AI_CONTEXT_MODEL_EVENT_NAMES=[_0x5ce0f0(0x99),_0x5ce0f0(0xca),_0x5ce0f0(0xa1),_0x5ce0f0(0xf2),_0x5ce0f0(0xcb),_0x5ce0f0(0xd8),_0x5ce0f0(0xea),_0x5ce0f0(0xde),_0x5ce0f0(0x90)];export class AIChatContext extends _0x3c1da4(){[_0x5ce0f0(0xeb)];[_0x5ce0f0(0xf0)];[_0x5ce0f0(0x6e)];constructor({connector:_0x290833,config:_0x45997b,ownerId:_0x32f2bd}){const _0x34ead0=_0x5ce0f0;super(),this[_0x34ead0(0xeb)]=_0x290833,this[_0x34ead0(0xf0)]=_0x45997b,this[_0x34ead0(0x6e)]=_0x32f2bd;}[_0x5ce0f0(0xb1)](){const _0x1d4065=_0x5ce0f0;this[_0x1d4065(0x8b)]=new Map(),this[_0x1d4065(0xa2)]=new Map(),this[_0x1d4065(0xaf)]=new Map(),this[_0x1d4065(0xd2)]=new Map(),this[_0x1d4065(0xbc)]();}[_0x5ce0f0(0xce)](){const _0x3c58fb=_0x5ce0f0;return this[_0x3c58fb(0x8b)];}async[_0x5ce0f0(0xe8)](_0x12e0b3){const _0x25eed9=_0x5ce0f0,_0x2086bc=await this[_0x25eed9(0x79)](_0x12e0b3);return this[_0x25eed9(0xe9)](_0x2086bc),_0x25eed9(0xc7)===_0x2086bc[_0x25eed9(0xe5)]&&this[_0x25eed9(0xb4)](),_0x2086bc;}async[_0x5ce0f0(0x79)](_0x516a92){const _0x3bd660=_0x5ce0f0;if(_0x516a92[_0x3bd660(0xd6)]===_0x32bff9[_0x3bd660(0xee)]){const _0x421076=await this[_0x3bd660(0xeb)][_0x3bd660(0xd7)](this[_0x3bd660(0x6e)],_0x516a92['id'])[_0x3bd660(0x94)]();return{'id':_0x3bd660(0xc7),'uiId':_0x3bd660(0xc7),'label':_0x3bd660(0x6b),'type':_0x516a92[_0x3bd660(0xd6)],'content':_0x421076[_0x3bd660(0x86)],'hidden':this[_0x3bd660(0xa2)][_0x3bd660(0x83)](_0x3bd660(0xc7)),'version':_0x421076[_0x3bd660(0x7c)]?.[_0x3bd660(0x9c)],'sessionId':_0x421076[_0x3bd660(0x7c)]?.[_0x3bd660(0x7f)]};}return{'id':_0x516a92['id'],'uiId':_0x516a92['id'],'label':_0x516a92[_0x3bd660(0x7c)]?.[_0x3bd660(0x88)]||_0x516a92[_0x3bd660(0x9a)]||_0x516a92[_0x3bd660(0xab)]||_0x516a92['id'],'type':_0x516a92[_0x3bd660(0xd6)],..._0x516a92?.[_0x3bd660(0x7c)]?.[_0x3bd660(0xf6)]?{'resourceId':_0x516a92[_0x3bd660(0x7c)]?.[_0x3bd660(0xf6)]}:{}};}[_0x5ce0f0(0xa8)](){const _0x2ed147=_0x5ce0f0;return new Map(this[_0x2ed147(0xa2)]);}[_0x5ce0f0(0xa6)](_0x211f22){const _0x1a6f53=_0x5ce0f0,_0x1eb927=this[_0x1a6f53(0x8b)][_0x1a6f53(0x77)](_0x211f22);_0x1eb927?.[_0x1a6f53(0x8e)]||this[_0x1a6f53(0x8d)](_0x211f22);}[_0x5ce0f0(0xdb)](){const _0x5427bc=_0x5ce0f0;if(0x0===this[_0x5427bc(0x8b)][_0x5427bc(0x78)])return;for(const _0x4aa6c4 of this[_0x5427bc(0x8b)][_0x5427bc(0x91)]())this[_0x5427bc(0x8d)](_0x4aa6c4[_0x5427bc(0xe5)]);const _0x30c07d=this[_0x5427bc(0xa2)][_0x5427bc(0x77)](_0x5427bc(0xc7))||this[_0x5427bc(0x8b)][_0x5427bc(0x77)](_0x5427bc(0xc7));_0x30c07d&&this[_0x5427bc(0xe1)]({..._0x30c07d,'isReadOnly':!0x0,'hidden':!0x0});}[_0x5ce0f0(0xef)](_0x178788){const _0x5481c8=_0x5ce0f0;for(const _0x5a62e5 of _0x178788[_0x5481c8(0x91)]())this[_0x5481c8(0xe9)](_0x5a62e5);this[_0x5481c8(0xdb)](),this[_0x5481c8(0x85)](_0x5481c8(0xf2),{'contextItems':Array[_0x5481c8(0x9b)](this[_0x5481c8(0xa8)]()[_0x5481c8(0x91)]())});}[_0x5ce0f0(0xe3)](){const _0x50aa6a=_0x5ce0f0;return this[_0x50aa6a(0x8b)][_0x50aa6a(0x83)](_0x50aa6a(0xc7));}[_0x5ce0f0(0xe6)](){const _0x27a4cf=_0x5ce0f0;return this[_0x27a4cf(0x8b)][_0x27a4cf(0x83)](_0x27a4cf(0xe7));}[_0x5ce0f0(0x93)](){const _0xa2a01=_0x5ce0f0;return this[_0xa2a01(0xa2)][_0xa2a01(0x83)](_0xa2a01(0xc7));}static[_0x5ce0f0(0xe2)](_0x435acb){const _0x1473df=_0x5ce0f0;return Array[_0x1473df(0x9b)](_0x435acb[_0x1473df(0x91)]())[_0x1473df(0xf8)](_0x9803d0=>this[_0x1473df(0xf5)](_0x9803d0))[_0x1473df(0xbf)](_0x56d212=>null!==_0x56d212);}async[_0x5ce0f0(0x8f)](_0x234e7f,_0x116ccc,_0x13aa9f=_0x32bff9[_0x5ce0f0(0xae)]){const _0x36b668=_0x5ce0f0,_0x119316=_0x36b668(0x96)+_0x17380f();this[_0x36b668(0x9f)](_0x119316);try{await Promise[_0x36b668(0xa5)](_0x234e7f[_0x36b668(0xf8)](async _0x5df6b8=>{const _0x3d98fc=_0x36b668,_0x50e96e=_0x3d98fc(0x70)+_0x17380f(),_0x122c7a=_0x18f612(_0x5df6b8[_0x3d98fc(0x9a)]);try{this[_0x3d98fc(0xe1)]({'type':_0x13aa9f,'label':_0x116ccc?.[_0x3d98fc(0x88)]||_0x122c7a,'uiId':_0x50e96e,'resourceId':_0x116ccc?.[_0x3d98fc(0xf6)]},!0x0);const _0x4173dc=this[_0x3d98fc(0xeb)][_0x3d98fc(0x81)](this[_0x3d98fc(0x6e)],_0x5df6b8,_0x116ccc);this[_0x3d98fc(0xaf)][_0x3d98fc(0x74)](_0x50e96e,_0x4173dc[_0x3d98fc(0xc2)]);const {id:_0x1f8dae}=await _0x4173dc[_0x3d98fc(0xc4)]();this[_0x3d98fc(0xaf)][_0x3d98fc(0xa4)](_0x50e96e),this[_0x3d98fc(0xe0)]({'type':_0x13aa9f,'id':_0x1f8dae,'label':_0x116ccc?.[_0x3d98fc(0x88)]||_0x122c7a,'uiId':_0x50e96e,'resourceId':_0x116ccc?.[_0x3d98fc(0xf6)]},!0x1);}catch(_0x13591a){this[_0x3d98fc(0xaf)][_0x3d98fc(0xa4)](_0x50e96e);if(!(_0x13591a instanceof _0x5e1efc&&_0x13591a[_0x3d98fc(0xec)][_0x3d98fc(0xd1)](_0x3d98fc(0xba)))){const _0x72a024=_0xe1bb0[_0x3d98fc(0x77)](_0x13591a[_0x3d98fc(0x7d)])||_0x3d98fc(0xa3),_0x301e29=new _0x5e1efc(_0x72a024,null,{'fileName':_0x122c7a,..._0x13591a});_0x301e29[_0x3d98fc(0x72)]=_0x13591a[_0x3d98fc(0x72)],this[_0x3d98fc(0x85)](_0x3d98fc(0xcb),{'error':_0x301e29});}this[_0x3d98fc(0x8d)](_0x50e96e);}}));}finally{this[_0x36b668(0xdc)](_0x119316);}}[_0x5ce0f0(0xc1)](_0x1f3a6f){const _0x418401=_0x5ce0f0;if(this[_0x418401(0xe3)]())return;const _0x2f62b3={'type':_0x32bff9[_0x418401(0xee)],'uiId':_0x418401(0xc7),'label':_0x1f3a6f,'isReadOnly':this[_0x418401(0xa2)][_0x418401(0x83)](_0x418401(0xc7)),'hidden':this[_0x418401(0xa2)][_0x418401(0x83)](_0x418401(0xc7))};this[_0x418401(0xe1)](_0x2f62b3);}async[_0x5ce0f0(0x80)](_0x273bf9,_0x538aae,_0x5210fa,_0x227d51){const _0x24daed=_0x5ce0f0,_0x38ff2c=this[_0x24daed(0x8b)][_0x24daed(0x77)](_0x24daed(0xc7));if(_0x38ff2c&&_0x273bf9){_0x38ff2c[_0x24daed(0xe7)]=_0x227d51?_0x227d51[_0x24daed(0xf8)](_0x26a352=>({'start':_0x26a352[_0x24daed(0xd3)],'end':_0x26a352[_0x24daed(0xc9)]})):[];try{if(_0x38ff2c[_0x24daed(0x9c)]===_0x538aae)return;const {id:_0x5ed7a7}=await this[_0x24daed(0xeb)][_0x24daed(0x7e)](this[_0x24daed(0x6e)],_0x273bf9,{'version':_0x538aae,'sessionId':_0x5210fa})[_0x24daed(0xc4)]();_0x38ff2c['id']=_0x5ed7a7,_0x38ff2c[_0x24daed(0x86)]=_0x273bf9,_0x38ff2c[_0x24daed(0x9c)]=_0x538aae,_0x38ff2c[_0x24daed(0x7f)]=_0x5210fa;}catch(_0x380cca){const _0x30dd13=new _0x5e1efc(_0x24daed(0xbe),null);_0x30dd13[_0x24daed(0x72)]=_0x380cca[_0x24daed(0x72)],this[_0x24daed(0x85)](_0x24daed(0xcb),{'error':_0x30dd13});}}}[_0x5ce0f0(0xa9)](_0x2c4ece){const _0x2a84e4=_0x5ce0f0;this[_0x2a84e4(0xe1)]({'type':_0x32bff9[_0x2a84e4(0xac)],'label':_0x2c4ece,'uiId':_0x2a84e4(0xe7),'content':_0x2c4ece});}[_0x5ce0f0(0x95)](){const _0x1f4c1a=_0x5ce0f0;this[_0x1f4c1a(0x8d)](_0x1f4c1a(0xe7));}async[_0x5ce0f0(0xfa)](_0x365655,_0xb33c2){const _0x173c8c=_0x5ce0f0,_0x291077=_0x173c8c(0xb9)+_0x17380f();this[_0x173c8c(0x9f)](_0x291077);const _0x56a663=_0x173c8c(0xb9)+_0x17380f();try{this[_0x173c8c(0xe1)]({'type':_0x32bff9[_0x173c8c(0xb7)],'label':_0xb33c2?.[_0x173c8c(0x88)]||_0x365655,'uiId':_0x56a663,'resourceId':_0xb33c2?.[_0x173c8c(0xf6)]},!0x0);const _0x469abc=this[_0x173c8c(0xeb)][_0x173c8c(0x87)](this[_0x173c8c(0x6e)],_0x365655,_0xb33c2);this[_0x173c8c(0xaf)][_0x173c8c(0x74)](_0x56a663,_0x469abc[_0x173c8c(0xc2)]);const {id:_0x3eec96}=await _0x469abc[_0x173c8c(0xc4)]();this[_0x173c8c(0xaf)][_0x173c8c(0xa4)](_0x56a663),this[_0x173c8c(0xe0)]({'type':_0x32bff9[_0x173c8c(0xb7)],'id':_0x3eec96,'label':_0xb33c2?.[_0x173c8c(0x88)]||_0x365655,'uiId':_0x56a663,'resourceId':_0xb33c2?.[_0x173c8c(0xf6)]},!0x1);}catch(_0x11ca3a){this[_0x173c8c(0xaf)][_0x173c8c(0xa4)](_0x56a663),(_0x11ca3a[_0x173c8c(0xec)][_0x173c8c(0xd1)](_0x173c8c(0xba))||this[_0x173c8c(0x85)](_0x173c8c(0xcb),{'error':new _0x5e1efc(_0x173c8c(0x97),this,{'url':_0x365655,'originalError':_0x11ca3a}),'url':_0x365655}),this[_0x173c8c(0x8d)](_0x56a663));}finally{this[_0x173c8c(0xdc)](_0x291077);}}async[_0x5ce0f0(0xf4)](_0x5a12c1,_0x20a3dc,_0x461cd4){const _0x1ae0de=_0x5ce0f0,_0x3a2d11=this[_0x1ae0de(0xc0)][_0x1ae0de(0xed)][_0x1ae0de(0xb3)](_0x3c663c=>_0x3c663c['id']===_0x5a12c1);if(!_0x3a2d11)return this[_0x1ae0de(0x85)](_0x1ae0de(0xcb),{'error':new _0x5e1efc(_0x1ae0de(0xf1),this,{'sourceId':_0x5a12c1}),'sourceId':_0x5a12c1}),[];try{const _0x441a84=(await _0x3a2d11[_0x1ae0de(0xb2)](_0x20a3dc))[_0x1ae0de(0xf8)](_0x24704a=>{const _0x29842e=_0x1ae0de,_0x40ae4e=this[_0x29842e(0xcd)](_0x24704a['id']);return{..._0x24704a,'isInContext':_0x40ae4e};});return _0x3a2d11[_0x1ae0de(0xe4)]=_0x441a84,this[_0x1ae0de(0x85)](_0x1ae0de(0xea),{'sourceId':_0x5a12c1,'source':_0x3a2d11,'resources':_0x441a84,'uid':_0x461cd4}),_0x441a84;}catch(_0xec4b17){return this[_0x1ae0de(0x85)](_0x1ae0de(0xcb),{'error':new _0x5e1efc(_0x1ae0de(0x6c),this,{'sourceId':_0x5a12c1,'originalError':_0xec4b17}),'sourceId':_0x5a12c1,'sourceLabel':_0x3a2d11[_0x1ae0de(0x88)]}),[];}}async[_0x5ce0f0(0xf7)](_0x3b382c,_0x204bb6){const _0x3c73da=_0x5ce0f0;if(this[_0x3c73da(0xcd)](_0x204bb6['id']))return;let _0x1f3fdf=_0x204bb6[_0x3c73da(0xbb)];if(!_0x1f3fdf&&_0x3b382c[_0x3c73da(0xc3)])try{_0x1f3fdf=await _0x3b382c[_0x3c73da(0xc3)](_0x204bb6['id']);}catch(_0xbe0f41){return void this[_0x3c73da(0x85)](_0x3c73da(0xcb),{'error':new _0x5e1efc(_0x3c73da(0x84),this,{'resourceId':_0x204bb6['id'],'sourceId':_0x3b382c['id'],'originalError':_0xbe0f41}),'resourceId':_0x204bb6['id'],'sourceId':_0x3b382c['id']});}if(_0x1f3fdf)switch(_0x204bb6[_0x3c73da(0xd6)]){case _0x32bff9[_0x3c73da(0xb7)]:if(_0x3c73da(0xb8)!=typeof _0x1f3fdf)return void this[_0x3c73da(0x85)](_0x3c73da(0xcb),{'error':new _0x5e1efc(_0x3c73da(0xd0),this,{'resourceId':_0x204bb6['id'],'sourceId':_0x3b382c['id'],'expectedType':_0x3c73da(0xb8),'actualType':typeof _0x1f3fdf}),'resourceId':_0x204bb6['id'],'sourceId':_0x3b382c['id']});await this[_0x3c73da(0xfa)](_0x1f3fdf,{'label':_0x204bb6[_0x3c73da(0x88)],'resourceId':_0x204bb6['id']});break;case _0x32bff9[_0x3c73da(0xae)]:if(!(_0x1f3fdf instanceof File))return void this[_0x3c73da(0x85)](_0x3c73da(0xcb),{'error':new _0x5e1efc(_0x3c73da(0xd0),this,{'resourceId':_0x204bb6['id'],'sourceId':_0x3b382c['id'],'expectedType':_0x3c73da(0x7b),'actualType':typeof _0x1f3fdf}),'resourceId':_0x204bb6['id'],'sourceId':_0x3b382c['id']});await this[_0x3c73da(0x8f)]([_0x1f3fdf],{'label':_0x204bb6[_0x3c73da(0x88)],'resourceId':_0x204bb6['id']});break;case _0x32bff9[_0x3c73da(0x6a)]:if(_0x3c73da(0xad)!=typeof _0x1f3fdf||!(_0x3c73da(0x86)in _0x1f3fdf)||!(_0x3c73da(0xd6)in _0x1f3fdf))return void this[_0x3c73da(0x85)](_0x3c73da(0xcb),{'error':new _0x5e1efc(_0x3c73da(0xd0),this,{'resourceId':_0x204bb6['id'],'sourceId':_0x3b382c['id'],'expectedType':_0x3c73da(0xbd),'actualType':typeof _0x1f3fdf}),'resourceId':_0x204bb6['id'],'sourceId':_0x3b382c['id']});_0x1f3fdf=AIChatContext[_0x3c73da(0x76)](_0x1f3fdf,_0x204bb6[_0x3c73da(0x88)]),await this[_0x3c73da(0x8f)]([_0x1f3fdf],{'label':_0x204bb6[_0x3c73da(0x88)],'resourceId':_0x204bb6['id']},_0x32bff9[_0x3c73da(0x6a)]);break;default:this[_0x3c73da(0x85)](_0x3c73da(0xcb),{'error':new _0x5e1efc(_0x3c73da(0xaa),this,{'resourceId':_0x204bb6['id'],'sourceId':_0x3b382c['id'],'resourceType':_0x204bb6[_0x3c73da(0xd6)]}),'resourceId':_0x204bb6['id'],'sourceId':_0x3b382c['id']});}else this[_0x3c73da(0x85)](_0x3c73da(0xcb),{'error':new _0x5e1efc(_0x3c73da(0xa7),this,{'resourceId':_0x204bb6['id'],'sourceId':_0x3b382c['id']}),'resourceId':_0x204bb6['id'],'sourceId':_0x3b382c['id']});}static[_0x5ce0f0(0x76)](_0x2ede53,_0x54972b){const _0x53cdc9=_0x5ce0f0;switch(_0x2ede53[_0x53cdc9(0xd6)]){case _0x293d37[_0x53cdc9(0xcc)]:return new File([_0x2ede53[_0x53cdc9(0x86)]],_0x54972b,{'type':_0x53cdc9(0x6d)});case _0x293d37[_0x53cdc9(0x8c)]:return new File([_0x2ede53[_0x53cdc9(0x86)]],_0x54972b,{'type':_0x53cdc9(0x6f)});default:return new File([_0x2ede53[_0x53cdc9(0x86)]],_0x54972b,{'type':_0x53cdc9(0x89)});}}static[_0x5ce0f0(0xf5)](_0x11523c){const _0x36d79e=_0x5ce0f0;switch(_0x11523c[_0x36d79e(0xd6)]){case _0x32bff9[_0x36d79e(0xae)]:return{'type':_0x32bff9[_0x36d79e(0xae)],'id':_0x11523c['id']};case _0x32bff9[_0x36d79e(0xb7)]:return{'type':_0x32bff9[_0x36d79e(0xb7)],'id':_0x11523c['id']};case _0x32bff9[_0x36d79e(0xee)]:return{'type':_0x32bff9[_0x36d79e(0xee)],'id':_0x11523c['id'],..._0x11523c[_0x36d79e(0xe7)]?.[_0x36d79e(0x9d)]&&{'selection':_0x11523c[_0x36d79e(0xe7)]}};case _0x32bff9[_0x36d79e(0x6a)]:return{'type':_0x32bff9[_0x36d79e(0xae)],'id':_0x11523c['id']};default:return null;}}[_0x5ce0f0(0xe1)](_0x411e2d,_0xbdd385=!0x1){const _0x2a2b9c=_0x5ce0f0;if(this[_0x2a2b9c(0x8b)][_0x2a2b9c(0x74)](_0x411e2d[_0x2a2b9c(0xe5)],_0x411e2d),_0x411e2d[_0x2a2b9c(0x98)]||this[_0x2a2b9c(0x85)](_0x2a2b9c(0x99),{'contextItem':_0x411e2d,'isLoading':_0xbdd385}),_0x2a2b9c(0xc7)===_0x411e2d[_0x2a2b9c(0xe5)]&&this[_0x2a2b9c(0xb4)](),_0x411e2d[_0x2a2b9c(0xf6)]){const _0x12ac38=this[_0x2a2b9c(0xd4)](_0x411e2d[_0x2a2b9c(0xf6)]);_0x12ac38&&_0x12ac38[_0x2a2b9c(0xda)](_0x58c110=>{const _0x5817ac=_0x2a2b9c;this[_0x5817ac(0xdd)](_0x58c110,_0x411e2d[_0x5817ac(0xf6)],!0x0);});}}[_0x5ce0f0(0x8d)](_0x3172be){const _0x3cac1a=_0x5ce0f0,_0xc941cd=this[_0x3cac1a(0x8b)][_0x3cac1a(0x77)](_0x3172be),_0x7f079=this[_0x3cac1a(0xaf)][_0x3cac1a(0x77)](_0x3172be);if(_0x7f079&&(_0x7f079[_0x3cac1a(0x71)](),this[_0x3cac1a(0xaf)][_0x3cac1a(0xa4)](_0x3172be)),_0xc941cd?.[_0x3cac1a(0xf6)]){const _0x29ac75=this[_0x3cac1a(0xd4)](_0xc941cd[_0x3cac1a(0xf6)]);_0x29ac75&&_0x29ac75[_0x3cac1a(0xda)](_0x5d2b3b=>{const _0x419f3e=_0x3cac1a;this[_0x419f3e(0xdd)](_0x5d2b3b,_0xc941cd[_0x419f3e(0xf6)],!0x1);});}this[_0x3cac1a(0x8b)][_0x3cac1a(0xa4)](_0x3172be),this[_0x3cac1a(0x85)](_0x3cac1a(0xca),{'uiId':_0x3172be,'type':_0xc941cd?.[_0x3cac1a(0xd6)]}),_0x3cac1a(0xc7)===_0x3172be&&this[_0x3cac1a(0xb4)]();}[_0x5ce0f0(0xe0)](_0x41b308,_0x1607af){const _0x454435=_0x5ce0f0;if(this[_0x454435(0x8b)][_0x454435(0x83)](_0x41b308[_0x454435(0xe5)])&&(this[_0x454435(0x8b)][_0x454435(0x74)](_0x41b308[_0x454435(0xe5)],_0x41b308),this[_0x454435(0x85)](_0x454435(0xa1),{'contextItem':_0x41b308,'isLoading':_0x1607af}),_0x41b308[_0x454435(0xf6)])){const _0x5dc04a=this[_0x454435(0xd4)](_0x41b308[_0x454435(0xf6)]);_0x5dc04a&&_0x5dc04a[_0x454435(0xda)](_0x5920c2=>{const _0x109a7b=_0x454435;this[_0x109a7b(0xdd)](_0x5920c2,_0x41b308[_0x109a7b(0xf6)],!0x0);});}}[_0x5ce0f0(0xe9)](_0x5809fe){const _0x2218c3=_0x5ce0f0;this[_0x2218c3(0xa2)][_0x2218c3(0x74)](_0x5809fe[_0x2218c3(0xe5)],_0x5809fe);}[_0x5ce0f0(0xbc)](){const _0x29be3d=_0x5ce0f0;this[_0x29be3d(0xc0)]={'document':{'enabled':!0x1!==this[_0x29be3d(0xf0)]?.[_0x29be3d(0x82)]?.[_0x29be3d(0x8a)],'isHidden':!0x1},'urls':{'enabled':!0x1!==this[_0x29be3d(0xf0)]?.[_0x29be3d(0xdf)]?.[_0x29be3d(0x8a)]},'files':{'enabled':!0x1!==this[_0x29be3d(0xf0)]?.[_0x29be3d(0xa0)]?.[_0x29be3d(0x8a)]},'sources':this[_0x29be3d(0xf3)]()},this[_0x29be3d(0x85)](_0x29be3d(0xd8),{'options':this[_0x29be3d(0xc0)]});}[_0x5ce0f0(0xf3)](){const _0x31278f=_0x5ce0f0;return this[_0x31278f(0xf0)]?.[_0x31278f(0xed)]?.[_0x31278f(0xf8)](_0x26465c=>({..._0x26465c,'resources':[]}))??[];}[_0x5ce0f0(0xb4)](){const _0x3f293e=_0x5ce0f0,_0x43b2fb=this[_0x3f293e(0xe3)]()||this[_0x3f293e(0x93)]();this[_0x3f293e(0xc0)][_0x3f293e(0x82)][_0x3f293e(0xf9)]=_0x43b2fb,this[_0x3f293e(0x85)](_0x3f293e(0xd8),{'options':this[_0x3f293e(0xc0)]});}[_0x5ce0f0(0xcd)](_0x542750){const _0x56ba63=_0x5ce0f0;for(const _0x506cbc of this[_0x56ba63(0x8b)][_0x56ba63(0x91)]())if(_0x506cbc[_0x56ba63(0xf6)]===_0x542750)return!0x0;for(const _0x4e3b83 of this[_0x56ba63(0xa2)][_0x56ba63(0x91)]())if(_0x4e3b83[_0x56ba63(0xf6)]===_0x542750)return!0x0;return!0x1;}[_0x5ce0f0(0xd4)](_0x59bd9f){const _0xafb8c8=_0x5ce0f0,_0x39bb09=[];for(const _0x22a7e0 of this[_0xafb8c8(0xc0)][_0xafb8c8(0xed)]){_0x22a7e0[_0xafb8c8(0xe4)][_0xafb8c8(0xb3)](_0x14158d=>_0x14158d['id']===_0x59bd9f)&&_0x39bb09[_0xafb8c8(0xc5)](_0x22a7e0['id']);}return 0x0===_0x39bb09[_0xafb8c8(0x9d)]?null:_0x39bb09;}[_0x5ce0f0(0xdd)](_0x15c3bf,_0xcde8ca,_0x2bed1f){const _0x564b11=_0x5ce0f0,_0x17508b=this[_0x564b11(0xc0)][_0x564b11(0xed)][_0x564b11(0xb3)](_0x1253bd=>_0x1253bd['id']===_0x15c3bf);if(!_0x17508b)return;const _0x2dbec6=_0x17508b[_0x564b11(0xe4)][_0x564b11(0xb3)](_0x2a1520=>_0x2a1520['id']===_0xcde8ca);_0x2dbec6&&(_0x2dbec6[_0x564b11(0x7a)]=_0x2bed1f,this[_0x564b11(0x85)](_0x564b11(0xde),{'sourceId':_0x15c3bf,'resourceId':_0xcde8ca,'isInContext':_0x2bed1f}));}[_0x5ce0f0(0x9f)](_0x122a39){const _0x318972=_0x5ce0f0;this[_0x318972(0xd2)][_0x318972(0x74)](_0x122a39,!0x0),this[_0x318972(0xd2)][_0x318972(0x78)]&&this[_0x318972(0x85)](_0x318972(0x90),{'isUploadInProgress':!0x0});}[_0x5ce0f0(0xdc)](_0x3ae59c){const _0x18d0ef=_0x5ce0f0;this[_0x18d0ef(0xd2)][_0x18d0ef(0xa4)](_0x3ae59c),0x0===this[_0x18d0ef(0xd2)][_0x18d0ef(0x78)]&&this[_0x18d0ef(0x85)](_0x18d0ef(0x90),{'isUploadInProgress':!0x1});}}function _0x59b8(){const _0x3e32ca=['ai-chat-context-invalid-data','startsWith','_ongoingUploadOperations','start','_findSourceIdsByResourceId','26XPvPJs','type','fetchDocument','addContextOptionsChanged','15568hUCDsc','forEach','clearPendingContextItems','_finishUploadOperation','_updateResourceInContextState','resourceStateChanged','urls','_finishContextItemLoading','_addContextItem','mapContextItemsToRequestData','isCurrentDocumentInContext','resources','uiId','isSelectionInContext','selection','populateFromMessage','_addToConversationContextItem','sourceResourcesLoaded','_connector','message','sources','DOCUMENT','addToConversationContext','_config','ai-chat-source-not-found','contextSent','_getCustomSourcesInitialState','loadSourceResources','_mapContextItemToRequestData','resourceId','addResourceToContext','map','isHidden','addUrlToContext','TEXT','Current\x20document','ai-chat-source-resources-load-failed','text/markdown','_ownerId','text/html','file-','abort','stack','2631ycLpsV','set','2432oDUreN','_convertTextResourceToFile','get','size','_createContextItemFromContent','isInContext','File','attributes','code','uploadDocument','sessionId','updateCurrentDocument','uploadFile','document','has','ai-chat-resource-load-failed','fire','content','uploadUrl','label','text/plain','enabled','_pendingContextItems','HTML','_removeContextItem','isReadOnly','addFilesToContext','uploadProgressChanged','values','143vWbfID','isCurrentDocumentInConversation','getDocument','removeSelectionFromContext','files-','ai-chat-url-upload-failed','hidden','contextItemAdded','name','from','version','length','2419291wsTwFF','_startUploadOperation','files','contextItemLoadingEnded','_conversationContextItems','ai-chat-file-upload-failed','delete','all','removeFromContext','ai-chat-resource-no-data','getSentContextItems','addSelectionToContext','ai-chat-context-unsupported-type','url','SELECTION','object','FILE','_ongoingUploads','417580rNtUeg','init','getResources','find','_toggleAddCurrentDocumentOptionVisibility','15034tJaERk','277870JZexHb','URL','string','url-','ai-request-aborted','data','_setAddContextOptionsDefaultState','object\x20with\x20content\x20and\x20type\x20properties','ai-chat-document-upload-failed','filter','_addContextOptionsState','addCurrentDocumentToContext','abortController','getData','getId','push','20380776XHXNXy','current-document','477ukQwKn','end','contextItemRemoved','error','MARKDOWN','_isResourceInContext','getPendingContextItems','30WSHTkm'];_0x59b8=function(){return _0x3e32ca;};return _0x59b8();}
|
|
23
|
+
const _0x52d18f=_0x3f67;(function(_0x5b0ce9,_0x1c8ab1){const _0x89daf8=_0x3f67,_0x1b01c9=_0x5b0ce9();while(!![]){try{const _0x238e9d=-parseInt(_0x89daf8(0x21a))/0x1+-parseInt(_0x89daf8(0x22b))/0x2*(parseInt(_0x89daf8(0x1f2))/0x3)+-parseInt(_0x89daf8(0x242))/0x4*(-parseInt(_0x89daf8(0x1f7))/0x5)+parseInt(_0x89daf8(0x1fb))/0x6+-parseInt(_0x89daf8(0x24c))/0x7+parseInt(_0x89daf8(0x265))/0x8+parseInt(_0x89daf8(0x23e))/0x9;if(_0x238e9d===_0x1c8ab1)break;else _0x1b01c9['push'](_0x1b01c9['shift']());}catch(_0x2b100d){_0x1b01c9['push'](_0x1b01c9['shift']());}}}(_0x565e,0x7bcf8));import{CKEditorError as _0x3dbe0e,ObservableMixin as _0x991414,uid as _0x29edad}from'ckeditor5/src/utils.js';import{AIContextItemType as _0x24af84,AIContextTextResourceType as _0x470c61}from'../../aicore/model/aicontext.js';import{escape as _0x51f37a}from'es-toolkit/compat';import{errorsMap as _0x4a8de0}from'../../errorsmap.js';function _0x3f67(_0x53e296,_0x235847){const _0x565e76=_0x565e();return _0x3f67=function(_0x3f67bd,_0x416d80){_0x3f67bd=_0x3f67bd-0x1db;let _0x884b3d=_0x565e76[_0x3f67bd];return _0x884b3d;},_0x3f67(_0x53e296,_0x235847);}export const AI_CONTEXT_MODEL_EVENT_NAMES=[_0x52d18f(0x1e5),_0x52d18f(0x1f0),_0x52d18f(0x213),_0x52d18f(0x1fe),_0x52d18f(0x20d),_0x52d18f(0x1ee),_0x52d18f(0x24d),_0x52d18f(0x259),_0x52d18f(0x1e1)];function _0x565e(){const _0x29b085=['isHidden','abort','startsWith','_getCustomSourcesInitialState','5497030GAcBKw','sourceResourcesLoaded','getSentContextItems','getId','MARKDOWN','attributes','removeFromContext','Current\x20document','populateFromMessage','getData','object\x20with\x20content\x20and\x20type\x20properties','_startUploadOperation','getDocument','resourceStateChanged','filter','all','has','map','addResourceToContext','addCurrentDocumentToContext','_pendingContextItems','uploadDocument','_mapContextItemToRequestData','version','sources','3973912hKlJDr','start','_finishContextItemLoading','HTML','name','ai-chat-document-upload-failed','urls','uiId','_ownerId','text/html','uploadProgressChanged','push','addFilesToContext','ai-chat-context-invalid-data','contextItemAdded','_addContextOptionsState','FILE','ai-chat-context-unsupported-type','from','code','_removeContextItem','find','mapContextItemsToRequestData','addContextOptionsChanged','selection','contextItemRemoved','clearPendingContextItems','7626UdlXUH','init','url','TEXT','addToConversationContext','1316835EdTuQF','addSelectionToContext','file-','files','1532712KzENIt','end','_toggleAddCurrentDocumentOptionVisibility','contextSent','enabled','forEach','_addToConversationContextItem','ai-chat-source-not-found','_connector','_addContextItem','uploadUrl','uploadFile','abortController','_convertTextResourceToFile','resources','content','length','ai-chat-url-upload-failed','error','resourceId','removeSelectionFromContext','set','isSelectionInContext','values','contextItemLoadingEnded','ai-chat-resource-no-data','message','hidden','size','document','object','275597zHhHYe','isCurrentDocumentInContext','text/markdown','_ongoingUploads','File','_isResourceInContext','ai-chat-file-upload-failed','isReadOnly','fetchDocument','sessionId','files-','label','ai-request-aborted','_ongoingUploadOperations','_config','type','text/plain','530CysiPn','url-','_findSourceIdsByResourceId','_setAddContextOptionsDefaultState','get','_updateResourceInContextState','DOCUMENT','isCurrentDocumentInConversation','fire','current-document','string','_createContextItemFromContent','updateCurrentDocument','_finishUploadOperation','addUrlToContext','delete','getPendingContextItems','ai-chat-source-resources-load-failed','URL','8664480pucSON','data','stack','isInContext','8ELuWmX','SELECTION','loadSourceResources','_conversationContextItems','ai-chat-resource-load-failed','getResources'];_0x565e=function(){return _0x29b085;};return _0x565e();}export class AIChatContext extends _0x991414(){[_0x52d18f(0x203)];[_0x52d18f(0x228)];[_0x52d18f(0x1df)];constructor({connector:_0x3a7f42,config:_0x2d2a37,ownerId:_0xfa571a}){const _0x2b0796=_0x52d18f;super(),this[_0x2b0796(0x203)]=_0x3a7f42,this[_0x2b0796(0x228)]=_0x2d2a37,this[_0x2b0796(0x1df)]=_0xfa571a;}[_0x52d18f(0x1f3)](){const _0x52e019=_0x52d18f;this[_0x52e019(0x260)]=new Map(),this[_0x52e019(0x245)]=new Map(),this[_0x52e019(0x21d)]=new Map(),this[_0x52e019(0x227)]=new Map(),this[_0x52e019(0x22e)]();}[_0x52d18f(0x23b)](){const _0x6f3671=_0x52d18f;return this[_0x6f3671(0x260)];}async[_0x52d18f(0x254)](_0x394817){const _0x13aad7=_0x52d18f,_0x2f4148=await this[_0x13aad7(0x236)](_0x394817);return this[_0x13aad7(0x201)](_0x2f4148),_0x13aad7(0x234)===_0x2f4148[_0x13aad7(0x1de)]&&this[_0x13aad7(0x1fd)](),_0x2f4148;}async[_0x52d18f(0x236)](_0x8ef278){const _0xddd98d=_0x52d18f;if(_0x8ef278[_0xddd98d(0x229)]===_0x24af84[_0xddd98d(0x231)]){const _0x47a949=await this[_0xddd98d(0x203)][_0xddd98d(0x222)](this[_0xddd98d(0x1df)],_0x8ef278['id'])[_0xddd98d(0x258)]();return{'id':_0xddd98d(0x234),'uiId':_0xddd98d(0x234),'label':_0xddd98d(0x253),'type':_0x8ef278[_0xddd98d(0x229)],'content':_0x47a949[_0xddd98d(0x20a)],'hidden':this[_0xddd98d(0x245)][_0xddd98d(0x25c)](_0xddd98d(0x234)),'version':_0x47a949[_0xddd98d(0x251)]?.[_0xddd98d(0x263)],'sessionId':_0x47a949[_0xddd98d(0x251)]?.[_0xddd98d(0x223)]};}return{'id':_0x8ef278['id'],'uiId':_0x8ef278['id'],'label':_0x8ef278[_0xddd98d(0x251)]?.[_0xddd98d(0x225)]||_0x8ef278[_0xddd98d(0x1db)]||_0x8ef278[_0xddd98d(0x1f4)]||_0x8ef278['id'],'type':_0x8ef278[_0xddd98d(0x229)],..._0x8ef278?.[_0xddd98d(0x251)]?.[_0xddd98d(0x20e)]?{'resourceId':_0x8ef278[_0xddd98d(0x251)]?.[_0xddd98d(0x20e)]}:{}};}[_0x52d18f(0x24e)](){const _0x3e8ba3=_0x52d18f;return new Map(this[_0x3e8ba3(0x245)]);}[_0x52d18f(0x252)](_0x7dd20a){const _0xfff085=_0x52d18f,_0x3641fc=this[_0xfff085(0x260)][_0xfff085(0x22f)](_0x7dd20a);_0x3641fc?.[_0xfff085(0x221)]||this[_0xfff085(0x1eb)](_0x7dd20a);}[_0x52d18f(0x1f1)](){const _0x55b2c4=_0x52d18f;if(0x0===this[_0x55b2c4(0x260)][_0x55b2c4(0x217)])return;for(const _0x12b789 of this[_0x55b2c4(0x260)][_0x55b2c4(0x212)]())this[_0x55b2c4(0x1eb)](_0x12b789[_0x55b2c4(0x1de)]);const _0x1f572e=this[_0x55b2c4(0x245)][_0x55b2c4(0x22f)](_0x55b2c4(0x234))||this[_0x55b2c4(0x260)][_0x55b2c4(0x22f)](_0x55b2c4(0x234));_0x1f572e&&this[_0x55b2c4(0x204)]({..._0x1f572e,'isReadOnly':!0x0,'hidden':!0x0});}[_0x52d18f(0x1f6)](_0x53133b){const _0x458135=_0x52d18f;for(const _0x34667f of _0x53133b[_0x458135(0x212)]())this[_0x458135(0x201)](_0x34667f);this[_0x458135(0x1f1)](),this[_0x458135(0x233)](_0x458135(0x1fe),{'contextItems':Array[_0x458135(0x1e9)](this[_0x458135(0x24e)]()[_0x458135(0x212)]())});}[_0x52d18f(0x21b)](){const _0x1c6bf9=_0x52d18f;return this[_0x1c6bf9(0x260)][_0x1c6bf9(0x25c)](_0x1c6bf9(0x234));}[_0x52d18f(0x211)](){const _0x538715=_0x52d18f;return this[_0x538715(0x260)][_0x538715(0x25c)](_0x538715(0x1ef));}[_0x52d18f(0x232)](){const _0x264bb9=_0x52d18f;return this[_0x264bb9(0x245)][_0x264bb9(0x25c)](_0x264bb9(0x234));}static[_0x52d18f(0x1ed)](_0x3cdb5e){const _0x209c05=_0x52d18f;return Array[_0x209c05(0x1e9)](_0x3cdb5e[_0x209c05(0x212)]())[_0x209c05(0x25d)](_0x406658=>this[_0x209c05(0x262)](_0x406658))[_0x209c05(0x25a)](_0x3eb2b1=>null!==_0x3eb2b1);}async[_0x52d18f(0x1e3)](_0x119234,_0x28fef5,_0x3a785e=_0x24af84[_0x52d18f(0x1e7)]){const _0x44e356=_0x52d18f,_0xb6ebad=_0x44e356(0x224)+_0x29edad();this[_0x44e356(0x257)](_0xb6ebad);try{await Promise[_0x44e356(0x25b)](_0x119234[_0x44e356(0x25d)](async _0x30a02a=>{const _0x35f772=_0x44e356,_0x2176ed=_0x35f772(0x1f9)+_0x29edad(),_0x2f9b63=_0x51f37a(_0x30a02a[_0x35f772(0x1db)]);try{this[_0x35f772(0x204)]({'type':_0x3a785e,'label':_0x28fef5?.[_0x35f772(0x225)]||_0x2f9b63,'uiId':_0x2176ed,'resourceId':_0x28fef5?.[_0x35f772(0x20e)]},!0x0);const _0x124d42=this[_0x35f772(0x203)][_0x35f772(0x206)](this[_0x35f772(0x1df)],_0x30a02a,_0x28fef5);this[_0x35f772(0x21d)][_0x35f772(0x210)](_0x2176ed,_0x124d42[_0x35f772(0x207)]);const {id:_0xe18858}=await _0x124d42[_0x35f772(0x24f)]();this[_0x35f772(0x21d)][_0x35f772(0x23a)](_0x2176ed),this[_0x35f772(0x267)]({'type':_0x3a785e,'id':_0xe18858,'label':_0x28fef5?.[_0x35f772(0x225)]||_0x2f9b63,'uiId':_0x2176ed,'resourceId':_0x28fef5?.[_0x35f772(0x20e)]},!0x1);}catch(_0x352373){this[_0x35f772(0x21d)][_0x35f772(0x23a)](_0x2176ed);if(!(_0x352373 instanceof _0x3dbe0e&&_0x352373[_0x35f772(0x215)][_0x35f772(0x24a)](_0x35f772(0x226)))){const _0x5f489d=_0x4a8de0[_0x35f772(0x22f)](_0x352373[_0x35f772(0x1ea)])||_0x35f772(0x220),_0x58d453=new _0x3dbe0e(_0x5f489d,null,{'fileName':_0x2f9b63,..._0x352373});_0x58d453[_0x35f772(0x240)]=_0x352373[_0x35f772(0x240)],this[_0x35f772(0x233)](_0x35f772(0x20d),{'error':_0x58d453});}this[_0x35f772(0x1eb)](_0x2176ed);}}));}finally{this[_0x44e356(0x238)](_0xb6ebad);}}[_0x52d18f(0x25f)](_0x5563f8){const _0x55c168=_0x52d18f;if(this[_0x55c168(0x21b)]())return;const _0x15016c={'type':_0x24af84[_0x55c168(0x231)],'uiId':_0x55c168(0x234),'label':_0x5563f8,'isReadOnly':this[_0x55c168(0x245)][_0x55c168(0x25c)](_0x55c168(0x234)),'hidden':this[_0x55c168(0x245)][_0x55c168(0x25c)](_0x55c168(0x234))};this[_0x55c168(0x204)](_0x15016c);}async[_0x52d18f(0x237)](_0x2240eb,_0x2460f0,_0x39d8e1,_0x254997){const _0x4e3796=_0x52d18f,_0x547e85=this[_0x4e3796(0x260)][_0x4e3796(0x22f)](_0x4e3796(0x234));if(_0x547e85&&_0x2240eb){_0x547e85[_0x4e3796(0x1ef)]=_0x254997?_0x254997[_0x4e3796(0x25d)](_0x556a24=>({'start':_0x556a24[_0x4e3796(0x266)],'end':_0x556a24[_0x4e3796(0x1fc)]})):[];try{if(_0x547e85[_0x4e3796(0x263)]===_0x2460f0)return;const {id:_0xd4ef93}=await this[_0x4e3796(0x203)][_0x4e3796(0x261)](this[_0x4e3796(0x1df)],_0x2240eb,{'version':_0x2460f0,'sessionId':_0x39d8e1})[_0x4e3796(0x24f)]();_0x547e85['id']=_0xd4ef93,_0x547e85[_0x4e3796(0x20a)]=_0x2240eb,_0x547e85[_0x4e3796(0x263)]=_0x2460f0,_0x547e85[_0x4e3796(0x223)]=_0x39d8e1;}catch(_0x1a2a6f){const _0x103e86=new _0x3dbe0e(_0x4e3796(0x1dc),null);_0x103e86[_0x4e3796(0x240)]=_0x1a2a6f[_0x4e3796(0x240)],this[_0x4e3796(0x233)](_0x4e3796(0x20d),{'error':_0x103e86});}}}[_0x52d18f(0x1f8)](_0x3eb614){const _0xd520a1=_0x52d18f;this[_0xd520a1(0x204)]({'type':_0x24af84[_0xd520a1(0x243)],'label':_0x3eb614,'uiId':_0xd520a1(0x1ef),'content':_0x3eb614});}[_0x52d18f(0x20f)](){const _0x545cd3=_0x52d18f;this[_0x545cd3(0x1eb)](_0x545cd3(0x1ef));}async[_0x52d18f(0x239)](_0x1e549f,_0x51b452){const _0x5bb1ba=_0x52d18f,_0x5bceef=_0x5bb1ba(0x22c)+_0x29edad();this[_0x5bb1ba(0x257)](_0x5bceef);const _0x58ce9a=_0x5bb1ba(0x22c)+_0x29edad();try{this[_0x5bb1ba(0x204)]({'type':_0x24af84[_0x5bb1ba(0x23d)],'label':_0x51b452?.[_0x5bb1ba(0x225)]||_0x1e549f,'uiId':_0x58ce9a,'resourceId':_0x51b452?.[_0x5bb1ba(0x20e)]},!0x0);const _0x560504=this[_0x5bb1ba(0x203)][_0x5bb1ba(0x205)](this[_0x5bb1ba(0x1df)],_0x1e549f,_0x51b452);this[_0x5bb1ba(0x21d)][_0x5bb1ba(0x210)](_0x58ce9a,_0x560504[_0x5bb1ba(0x207)]);const {id:_0x246249}=await _0x560504[_0x5bb1ba(0x24f)]();this[_0x5bb1ba(0x21d)][_0x5bb1ba(0x23a)](_0x58ce9a),this[_0x5bb1ba(0x267)]({'type':_0x24af84[_0x5bb1ba(0x23d)],'id':_0x246249,'label':_0x51b452?.[_0x5bb1ba(0x225)]||_0x1e549f,'uiId':_0x58ce9a,'resourceId':_0x51b452?.[_0x5bb1ba(0x20e)]},!0x1);}catch(_0x5c24c3){this[_0x5bb1ba(0x21d)][_0x5bb1ba(0x23a)](_0x58ce9a),(_0x5c24c3[_0x5bb1ba(0x215)][_0x5bb1ba(0x24a)](_0x5bb1ba(0x226))||this[_0x5bb1ba(0x233)](_0x5bb1ba(0x20d),{'error':new _0x3dbe0e(_0x5bb1ba(0x20c),this,{'url':_0x1e549f,'originalError':_0x5c24c3}),'url':_0x1e549f}),this[_0x5bb1ba(0x1eb)](_0x58ce9a));}finally{this[_0x5bb1ba(0x238)](_0x5bceef);}}async[_0x52d18f(0x244)](_0x4ac5cb,_0x149813,_0x3358a4){const _0x71a3d9=_0x52d18f,_0x233168=this[_0x71a3d9(0x1e6)][_0x71a3d9(0x264)][_0x71a3d9(0x1ec)](_0x476f6d=>_0x476f6d['id']===_0x4ac5cb);if(!_0x233168)return this[_0x71a3d9(0x233)](_0x71a3d9(0x20d),{'error':new _0x3dbe0e(_0x71a3d9(0x202),this,{'sourceId':_0x4ac5cb}),'sourceId':_0x4ac5cb}),[];try{const _0x34bedb=(await _0x233168[_0x71a3d9(0x247)](_0x149813))[_0x71a3d9(0x25d)](_0x300453=>{const _0x1a5f0b=_0x71a3d9,_0x407103=this[_0x1a5f0b(0x21f)](_0x300453['id']);return{..._0x300453,'isInContext':_0x407103};});return _0x233168[_0x71a3d9(0x209)]=_0x34bedb,this[_0x71a3d9(0x233)](_0x71a3d9(0x24d),{'sourceId':_0x4ac5cb,'source':_0x233168,'resources':_0x34bedb,'uid':_0x3358a4}),_0x34bedb;}catch(_0x7eabe5){return this[_0x71a3d9(0x233)](_0x71a3d9(0x20d),{'error':new _0x3dbe0e(_0x71a3d9(0x23c),this,{'sourceId':_0x4ac5cb,'originalError':_0x7eabe5}),'sourceId':_0x4ac5cb,'sourceLabel':_0x233168[_0x71a3d9(0x225)]}),[];}}async[_0x52d18f(0x25e)](_0x5a3c54,_0x11d782){const _0x2cf41c=_0x52d18f;if(this[_0x2cf41c(0x21f)](_0x11d782['id']))return;let _0x659bd=_0x11d782[_0x2cf41c(0x23f)];if(!_0x659bd&&_0x5a3c54[_0x2cf41c(0x255)])try{_0x659bd=await _0x5a3c54[_0x2cf41c(0x255)](_0x11d782['id']);}catch(_0x4a0138){return void this[_0x2cf41c(0x233)](_0x2cf41c(0x20d),{'error':new _0x3dbe0e(_0x2cf41c(0x246),this,{'resourceId':_0x11d782['id'],'sourceId':_0x5a3c54['id'],'originalError':_0x4a0138}),'resourceId':_0x11d782['id'],'sourceId':_0x5a3c54['id']});}if(_0x659bd)switch(_0x11d782[_0x2cf41c(0x229)]){case _0x24af84[_0x2cf41c(0x23d)]:if(_0x2cf41c(0x235)!=typeof _0x659bd)return void this[_0x2cf41c(0x233)](_0x2cf41c(0x20d),{'error':new _0x3dbe0e(_0x2cf41c(0x1e4),this,{'resourceId':_0x11d782['id'],'sourceId':_0x5a3c54['id'],'expectedType':_0x2cf41c(0x235),'actualType':typeof _0x659bd}),'resourceId':_0x11d782['id'],'sourceId':_0x5a3c54['id']});await this[_0x2cf41c(0x239)](_0x659bd,{'label':_0x11d782[_0x2cf41c(0x225)],'resourceId':_0x11d782['id']});break;case _0x24af84[_0x2cf41c(0x1e7)]:if(!(_0x659bd instanceof File))return void this[_0x2cf41c(0x233)](_0x2cf41c(0x20d),{'error':new _0x3dbe0e(_0x2cf41c(0x1e4),this,{'resourceId':_0x11d782['id'],'sourceId':_0x5a3c54['id'],'expectedType':_0x2cf41c(0x21e),'actualType':typeof _0x659bd}),'resourceId':_0x11d782['id'],'sourceId':_0x5a3c54['id']});await this[_0x2cf41c(0x1e3)]([_0x659bd],{'label':_0x11d782[_0x2cf41c(0x225)],'resourceId':_0x11d782['id']});break;case _0x24af84[_0x2cf41c(0x1f5)]:if(_0x2cf41c(0x219)!=typeof _0x659bd||!(_0x2cf41c(0x20a)in _0x659bd)||!(_0x2cf41c(0x229)in _0x659bd))return void this[_0x2cf41c(0x233)](_0x2cf41c(0x20d),{'error':new _0x3dbe0e(_0x2cf41c(0x1e4),this,{'resourceId':_0x11d782['id'],'sourceId':_0x5a3c54['id'],'expectedType':_0x2cf41c(0x256),'actualType':typeof _0x659bd}),'resourceId':_0x11d782['id'],'sourceId':_0x5a3c54['id']});_0x659bd=AIChatContext[_0x2cf41c(0x208)](_0x659bd,_0x11d782[_0x2cf41c(0x225)]),await this[_0x2cf41c(0x1e3)]([_0x659bd],{'label':_0x11d782[_0x2cf41c(0x225)],'resourceId':_0x11d782['id']},_0x24af84[_0x2cf41c(0x1f5)]);break;default:this[_0x2cf41c(0x233)](_0x2cf41c(0x20d),{'error':new _0x3dbe0e(_0x2cf41c(0x1e8),this,{'resourceId':_0x11d782['id'],'sourceId':_0x5a3c54['id'],'resourceType':_0x11d782[_0x2cf41c(0x229)]}),'resourceId':_0x11d782['id'],'sourceId':_0x5a3c54['id']});}else this[_0x2cf41c(0x233)](_0x2cf41c(0x20d),{'error':new _0x3dbe0e(_0x2cf41c(0x214),this,{'resourceId':_0x11d782['id'],'sourceId':_0x5a3c54['id']}),'resourceId':_0x11d782['id'],'sourceId':_0x5a3c54['id']});}static[_0x52d18f(0x208)](_0x4c383c,_0x5833ac){const _0x3aba1f=_0x52d18f;switch(_0x4c383c[_0x3aba1f(0x229)]){case _0x470c61[_0x3aba1f(0x250)]:return new File([_0x4c383c[_0x3aba1f(0x20a)]],_0x5833ac,{'type':_0x3aba1f(0x21c)});case _0x470c61[_0x3aba1f(0x268)]:return new File([_0x4c383c[_0x3aba1f(0x20a)]],_0x5833ac,{'type':_0x3aba1f(0x1e0)});default:return new File([_0x4c383c[_0x3aba1f(0x20a)]],_0x5833ac,{'type':_0x3aba1f(0x22a)});}}static[_0x52d18f(0x262)](_0x208708){const _0x1923d6=_0x52d18f;switch(_0x208708[_0x1923d6(0x229)]){case _0x24af84[_0x1923d6(0x1e7)]:return{'type':_0x24af84[_0x1923d6(0x1e7)],'id':_0x208708['id']};case _0x24af84[_0x1923d6(0x23d)]:return{'type':_0x24af84[_0x1923d6(0x23d)],'id':_0x208708['id']};case _0x24af84[_0x1923d6(0x231)]:return{'type':_0x24af84[_0x1923d6(0x231)],'id':_0x208708['id'],..._0x208708[_0x1923d6(0x1ef)]?.[_0x1923d6(0x20b)]&&{'selection':_0x208708[_0x1923d6(0x1ef)]}};case _0x24af84[_0x1923d6(0x1f5)]:return{'type':_0x24af84[_0x1923d6(0x1e7)],'id':_0x208708['id']};default:return null;}}[_0x52d18f(0x204)](_0xbd68aa,_0x2d0bfc=!0x1){const _0x268685=_0x52d18f;if(this[_0x268685(0x260)][_0x268685(0x210)](_0xbd68aa[_0x268685(0x1de)],_0xbd68aa),_0xbd68aa[_0x268685(0x216)]||this[_0x268685(0x233)](_0x268685(0x1e5),{'contextItem':_0xbd68aa,'isLoading':_0x2d0bfc}),_0x268685(0x234)===_0xbd68aa[_0x268685(0x1de)]&&this[_0x268685(0x1fd)](),_0xbd68aa[_0x268685(0x20e)]){const _0xd8e32d=this[_0x268685(0x22d)](_0xbd68aa[_0x268685(0x20e)]);_0xd8e32d&&_0xd8e32d[_0x268685(0x200)](_0xd6850=>{const _0x480cc6=_0x268685;this[_0x480cc6(0x230)](_0xd6850,_0xbd68aa[_0x480cc6(0x20e)],!0x0);});}}[_0x52d18f(0x1eb)](_0x5877c0){const _0x34f397=_0x52d18f,_0x1db11b=this[_0x34f397(0x260)][_0x34f397(0x22f)](_0x5877c0),_0x3b8430=this[_0x34f397(0x21d)][_0x34f397(0x22f)](_0x5877c0);if(_0x3b8430&&(_0x3b8430[_0x34f397(0x249)](),this[_0x34f397(0x21d)][_0x34f397(0x23a)](_0x5877c0)),_0x1db11b?.[_0x34f397(0x20e)]){const _0x168608=this[_0x34f397(0x22d)](_0x1db11b[_0x34f397(0x20e)]);_0x168608&&_0x168608[_0x34f397(0x200)](_0x4e8b6b=>{const _0x365771=_0x34f397;this[_0x365771(0x230)](_0x4e8b6b,_0x1db11b[_0x365771(0x20e)],!0x1);});}this[_0x34f397(0x260)][_0x34f397(0x23a)](_0x5877c0),this[_0x34f397(0x233)](_0x34f397(0x1f0),{'uiId':_0x5877c0,'type':_0x1db11b?.[_0x34f397(0x229)]}),_0x34f397(0x234)===_0x5877c0&&this[_0x34f397(0x1fd)]();}[_0x52d18f(0x267)](_0x4931e6,_0x19309d){const _0x37e78b=_0x52d18f;if(this[_0x37e78b(0x260)][_0x37e78b(0x25c)](_0x4931e6[_0x37e78b(0x1de)])&&(this[_0x37e78b(0x260)][_0x37e78b(0x210)](_0x4931e6[_0x37e78b(0x1de)],_0x4931e6),this[_0x37e78b(0x233)](_0x37e78b(0x213),{'contextItem':_0x4931e6,'isLoading':_0x19309d}),_0x4931e6[_0x37e78b(0x20e)])){const _0x4f6be5=this[_0x37e78b(0x22d)](_0x4931e6[_0x37e78b(0x20e)]);_0x4f6be5&&_0x4f6be5[_0x37e78b(0x200)](_0x529105=>{const _0x3c6c28=_0x37e78b;this[_0x3c6c28(0x230)](_0x529105,_0x4931e6[_0x3c6c28(0x20e)],!0x0);});}}[_0x52d18f(0x201)](_0x447224){const _0x22847a=_0x52d18f;this[_0x22847a(0x245)][_0x22847a(0x210)](_0x447224[_0x22847a(0x1de)],_0x447224);}[_0x52d18f(0x22e)](){const _0x492959=_0x52d18f;this[_0x492959(0x1e6)]={'document':{'enabled':!0x1!==this[_0x492959(0x228)]?.[_0x492959(0x218)]?.[_0x492959(0x1ff)],'isHidden':!0x1},'urls':{'enabled':!0x1!==this[_0x492959(0x228)]?.[_0x492959(0x1dd)]?.[_0x492959(0x1ff)]},'files':{'enabled':!0x1!==this[_0x492959(0x228)]?.[_0x492959(0x1fa)]?.[_0x492959(0x1ff)]},'sources':this[_0x492959(0x24b)]()},this[_0x492959(0x233)](_0x492959(0x1ee),{'options':this[_0x492959(0x1e6)]});}[_0x52d18f(0x24b)](){const _0x4fbf5a=_0x52d18f;return this[_0x4fbf5a(0x228)]?.[_0x4fbf5a(0x264)]?.[_0x4fbf5a(0x25d)](_0x409d03=>({..._0x409d03,'resources':[]}))??[];}[_0x52d18f(0x1fd)](){const _0x130fb9=_0x52d18f,_0xe2456d=this[_0x130fb9(0x21b)]()||this[_0x130fb9(0x232)]();this[_0x130fb9(0x1e6)][_0x130fb9(0x218)][_0x130fb9(0x248)]=_0xe2456d,this[_0x130fb9(0x233)](_0x130fb9(0x1ee),{'options':this[_0x130fb9(0x1e6)]});}[_0x52d18f(0x21f)](_0x4b338c){const _0x3f256b=_0x52d18f;for(const _0x3cbc8b of this[_0x3f256b(0x260)][_0x3f256b(0x212)]())if(_0x3cbc8b[_0x3f256b(0x20e)]===_0x4b338c)return!0x0;for(const _0x211597 of this[_0x3f256b(0x245)][_0x3f256b(0x212)]())if(_0x211597[_0x3f256b(0x20e)]===_0x4b338c)return!0x0;return!0x1;}[_0x52d18f(0x22d)](_0x13684c){const _0xd6dd76=_0x52d18f,_0x2f48d9=[];for(const _0x25f421 of this[_0xd6dd76(0x1e6)][_0xd6dd76(0x264)]){_0x25f421[_0xd6dd76(0x209)][_0xd6dd76(0x1ec)](_0x3db8bf=>_0x3db8bf['id']===_0x13684c)&&_0x2f48d9[_0xd6dd76(0x1e2)](_0x25f421['id']);}return 0x0===_0x2f48d9[_0xd6dd76(0x20b)]?null:_0x2f48d9;}[_0x52d18f(0x230)](_0x4c1679,_0x4e2a0a,_0x3d2bc9){const _0x2f6a3f=_0x52d18f,_0x1533a4=this[_0x2f6a3f(0x1e6)][_0x2f6a3f(0x264)][_0x2f6a3f(0x1ec)](_0x147ed3=>_0x147ed3['id']===_0x4c1679);if(!_0x1533a4)return;const _0x944b59=_0x1533a4[_0x2f6a3f(0x209)][_0x2f6a3f(0x1ec)](_0x2dabc2=>_0x2dabc2['id']===_0x4e2a0a);_0x944b59&&(_0x944b59[_0x2f6a3f(0x241)]=_0x3d2bc9,this[_0x2f6a3f(0x233)](_0x2f6a3f(0x259),{'sourceId':_0x4c1679,'resourceId':_0x4e2a0a,'isInContext':_0x3d2bc9}));}[_0x52d18f(0x257)](_0x57da27){const _0x27ae57=_0x52d18f;this[_0x27ae57(0x227)][_0x27ae57(0x210)](_0x57da27,!0x0),this[_0x27ae57(0x227)][_0x27ae57(0x217)]&&this[_0x27ae57(0x233)](_0x27ae57(0x1e1),{'isUploadInProgress':!0x0});}[_0x52d18f(0x238)](_0x22c95a){const _0x5554a6=_0x52d18f;this[_0x5554a6(0x227)][_0x5554a6(0x23a)](_0x22c95a),0x0===this[_0x5554a6(0x227)][_0x5554a6(0x217)]&&this[_0x5554a6(0x233)](_0x5554a6(0x1e1),{'isUploadInProgress':!0x1});}}
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const _0x300448=_0x2a1a;(function(_0x2f810b,_0x26dc24){const _0x19fc33=_0x2a1a,_0x4cae77=_0x2f810b();while(!![]){try{const _0x23fc62=parseInt(_0x19fc33(0x16f))/0x1*(-parseInt(_0x19fc33(0x18c))/0x2)+parseInt(_0x19fc33(0x195))/0x3+parseInt(_0x19fc33(0x159))/0x4*(-parseInt(_0x19fc33(0x1b0))/0x5)+-parseInt(_0x19fc33(0x17b))/0x6*(parseInt(_0x19fc33(0x188))/0x7)+parseInt(_0x19fc33(0x183))/0x8*(parseInt(_0x19fc33(0x151))/0x9)+parseInt(_0x19fc33(0x15f))/0xa+parseInt(_0x19fc33(0x158))/0xb;if(_0x23fc62===_0x26dc24)break;else _0x4cae77['push'](_0x4cae77['shift']());}catch(_0x325ec4){_0x4cae77['push'](_0x4cae77['shift']());}}}(_0x648d,0x63458));import{CKEditorError as _0x20794c,EmitterMixin as _0x42e186,logWarning as _0x1be831}from'ckeditor5/src/utils.js';import{AI_MODEL_EVENT_NAMES as _0x4c8bba}from'../../aicore/model/aiinteraction.js';import{AIChatContext as _0x1250c8,AI_CONTEXT_MODEL_EVENT_NAMES as _0x19287a}from'./aichatcontext.js';import{AICapabilities as _0x109a37,CAPABILITIES_MODEL_EVENT_NAMES as _0x2accd0}from'../../aicore/model/aicapabilities.js';import{AIChatInteraction as _0x571219}from'./aichatinteraction.js';import{errorsMap as _0x2a96f5}from'../../errorsmap.js';function _0x648d(){const _0x142c38=['prompt','interactions','handleUserInteraction','selectedModel','text','init','interactionCreated','removeInteraction','startConversation','text-delta','removeSelectionFromContext','webSearch','_processMessagesToInteractions','destroy','getConversation','updateCurrentDocumentInContext','isCurrentDocumentInConversation','ai-chat-conversation-init-from-id-failed','currentInteraction','addSelectionToContext','createInteraction','chatModels','conversationId','getCapabilitiesConfig','ai-chat-conversation-start-no-model-selected','addCurrentDocumentToContext','5ULKtTh','setModel','contextItems','title','start','getPendingContextItems','reasoning','addResourceToContext','error','getAvailableModels','hasOwn','options','updateCurrentDocument','modelSelected','ai-chat-handle-user-interaction-already-in-progress','chatCapabilities','removeFromContext','splice','getMessages','setConversationTitle','addUrlToContext','role','fetchConversationMessages','populateFromMessage','117mGSkRg','appendContent','ai-chat-conversation-set-model-not-available','fire','type','stop','addFilesToContext','3122361wqWTke','1481544fdzhgn','user','find','getDocumentContext','ai-chat-conversation-already-started','chatContext','3401590DjgMBx','model','indexOf','ai-chat-conversation-set-model-null','get','toggleReasoning','isAvailable','capabilities','fetchConversation','conversationInitialized','getModel','getInteraction','load','addToConversationContext','set','createReply','54myhcXb','ai-chat-handle-user-conversation-not-initialized','getEditor','attributes','currentReply','ai-chat-handle-user-interaction-start-failed','code','push','modification-delta','length','group','getAll','132SqEoOk','selectedModelId','getCurrentDocumentContext','message','content','lastInteraction','isSelectionInContext','isStarted','44072SUFOhc','assistant','loadSourceResources','ai-chat-conversation-init-failed','quickActionData','145831FKtcVN','delegate','toLowerCase','conversationStarted','6818hGvpwR','_extractContextItems','stack','toggleWebSearch','connector','ai-chat-conversation-start-failed','sessionId','reset','isCurrentDocumentInContext','2171361apskSB'];_0x648d=function(){return _0x142c38;};return _0x648d();}function _0x2a1a(_0x1551f7,_0x125c6b){const _0x648d98=_0x648d();return _0x2a1a=function(_0x2a1a58,_0xd36036){_0x2a1a58=_0x2a1a58-0x13c;let _0x448984=_0x648d98[_0x2a1a58];return _0x448984;},_0x2a1a(_0x1551f7,_0x125c6b);}export class AIChatConversation extends _0x42e186(){['id'];[_0x300448(0x182)]=!0x1;[_0x300448(0x197)]=[];[_0x300448(0x1a8)];[_0x300448(0x199)];[_0x300448(0x190)];[_0x300448(0x144)];constructor(_0x4a84d8){const _0x5b1596=_0x300448;super(),this[_0x5b1596(0x144)]=_0x4a84d8,this[_0x5b1596(0x190)]=_0x4a84d8[_0x5b1596(0x190)],this[_0x5b1596(0x1ab)]=_0x4a84d8[_0x5b1596(0x1ab)],this['id']=_0x4a84d8[_0x5b1596(0x1ac)];}async[_0x300448(0x19b)](_0x22dbc6){const _0x4b591a=_0x300448;try{this[_0x4b591a(0x15e)]=new _0x1250c8({'connector':this[_0x4b591a(0x190)],'config':_0x22dbc6,'ownerId':this['id']}),this[_0x4b591a(0x15e)][_0x4b591a(0x189)](..._0x19287a)['to'](this),this[_0x4b591a(0x15e)][_0x4b591a(0x19b)](),this[_0x4b591a(0x148)]=new _0x109a37(),this[_0x4b591a(0x148)][_0x4b591a(0x189)](..._0x2accd0)['to'](this),this[_0x4b591a(0x148)][_0x4b591a(0x19b)]();const _0x5b37b0=await this[_0x4b591a(0x1ab)][_0x4b591a(0x142)]();this[_0x4b591a(0x154)](_0x4b591a(0x168),{'availableModels':_0x5b37b0});const _0x57b841=await this[_0x4b591a(0x1ab)][_0x4b591a(0x169)](this[_0x4b591a(0x144)][_0x4b591a(0x17c)]);_0x57b841&&await this[_0x4b591a(0x1b1)](_0x57b841);}catch(_0x722074){const _0x5a05a2=new _0x20794c(_0x4b591a(0x186),null,{'message':_0x722074[_0x4b591a(0x17e)]||_0x722074});_0x5a05a2[_0x4b591a(0x18e)]=_0x722074[_0x4b591a(0x18e)],this[_0x4b591a(0x154)](_0x4b591a(0x141),{'error':_0x5a05a2});}}async[_0x300448(0x13d)](){const _0x13b2cc=_0x300448;if(this[_0x13b2cc(0x182)])throw new _0x20794c(_0x13b2cc(0x15d),null,{'conversation':this});if(!this[_0x13b2cc(0x199)])throw new _0x20794c(_0x13b2cc(0x1ae),null,{'conversation':this});try{const {id:_0x238a66}=await this[_0x13b2cc(0x190)][_0x13b2cc(0x19e)](this['id'],this[_0x13b2cc(0x144)][_0x13b2cc(0x179)])[_0x13b2cc(0x1a4)]();this['id']=_0x238a66,this[_0x13b2cc(0x182)]=!0x0,this[_0x13b2cc(0x154)](_0x13b2cc(0x18b),{'conversationId':this['id'],'selectedModel':this[_0x13b2cc(0x199)]});}catch(_0x296e46){const _0x1e06ec=new _0x20794c(_0x13b2cc(0x191),null,{'message':_0x296e46[_0x13b2cc(0x17e)],'conversationId':this['id']});throw _0x1e06ec[_0x13b2cc(0x18e)]=_0x296e46[_0x13b2cc(0x18e)],this[_0x13b2cc(0x154)](_0x13b2cc(0x141),{'error':_0x1e06ec}),_0x1e06ec;}}async[_0x300448(0x16b)](_0x5d1f59,_0x2ce869){const _0x588562=_0x300448;try{const _0x14e1f4=await this[_0x588562(0x190)][_0x588562(0x167)](_0x5d1f59)[_0x588562(0x1a4)](),_0x5c6893=await this[_0x588562(0x190)][_0x588562(0x14f)](_0x5d1f59)[_0x588562(0x14b)](),_0x1815c5=_0x5c6893[0x0][_0x588562(0x160)];this[_0x588562(0x182)]=!0x0,this['id']=_0x14e1f4['id'],_0x588562(0x13c)in _0x14e1f4?this[_0x588562(0x154)](_0x588562(0x14c),_0x14e1f4[_0x588562(0x13c)],!0x0):this[_0x588562(0x154)](_0x588562(0x14c),'',!0x0);const _0x25e721=(await this[_0x588562(0x1ab)][_0x588562(0x17a)]())[_0x588562(0x15b)](_0x55a2b5=>_0x55a2b5['id'][_0x588562(0x18a)]()===_0x1815c5[_0x588562(0x18a)]());return this[_0x588562(0x199)]=_0x25e721,this[_0x588562(0x154)](_0x588562(0x146),{'selectedModel':_0x25e721,'isDisabled':!0x0}),await this[_0x588562(0x1a2)](_0x5c6893,_0x2ce869,_0x1815c5),this[_0x588562(0x1a8)]=void 0x0,this;}catch(_0x5f3447){const _0x184b1e=new _0x20794c(_0x588562(0x1a7),null,{'message':_0x5f3447[_0x588562(0x17e)],'conversationId':_0x5d1f59});throw _0x184b1e[_0x588562(0x18e)]=_0x5f3447[_0x588562(0x18e)],this[_0x588562(0x154)](_0x588562(0x141),{'error':_0x184b1e}),_0x184b1e;}}async[_0x300448(0x1a2)](_0x2b9104,_0x4f04cf,_0x3763e4){const _0xc380e1=_0x300448;let _0x40ac90;for(const _0x55e17e of _0x2b9104)if(_0xc380e1(0x15a)===_0x55e17e[_0xc380e1(0x14e)]){const _0x362aaa=await this[_0xc380e1(0x18d)](_0x55e17e),_0x531a9c={'isReasoningEnabled':Object[_0xc380e1(0x143)](_0x55e17e[_0xc380e1(0x166)],_0xc380e1(0x13f)),'isWebSearchEnabled':Object[_0xc380e1(0x143)](_0x55e17e[_0xc380e1(0x166)],_0xc380e1(0x1a1))};_0x40ac90=this[_0xc380e1(0x1aa)]({'userMessage':_0x55e17e[_0xc380e1(0x196)],'contextItems':_0x362aaa,'capabilities':_0x531a9c,'modelId':_0x3763e4,'quickActionData':_0x55e17e[_0xc380e1(0x172)]?.[_0xc380e1(0x187)]}),this[_0xc380e1(0x1a8)]=_0x40ac90,this[_0xc380e1(0x15e)][_0xc380e1(0x16c)](this[_0xc380e1(0x1a8)][_0xc380e1(0x1b2)]);}else{if(_0xc380e1(0x184)===_0x55e17e[_0xc380e1(0x14e)]&&_0x40ac90)for(const _0x2084bb of _0x55e17e[_0xc380e1(0x17f)]){const _0x2cafa0=_0xc380e1(0x19a)===_0x2084bb[_0xc380e1(0x155)]?_0xc380e1(0x19f):_0xc380e1(0x177),_0x28941d=_0x40ac90[_0xc380e1(0x15c)]()?.[_0xc380e1(0x192)]!==_0x4f04cf;_0x40ac90[_0xc380e1(0x173)]=_0x40ac90[_0xc380e1(0x16e)]({'type':_0x2cafa0,'isDone':!0x0,'interactionId':_0x40ac90['id'],'areActionsDisabled':_0x28941d}),_0x40ac90[_0xc380e1(0x173)][_0xc380e1(0x152)](_0x2084bb[_0xc380e1(0x17f)]);}}}async[_0x300448(0x18d)](_0x12868c){const _0x58b10e=_0x300448,_0x10256a=new Map();if(!_0x12868c[_0x58b10e(0x17f)])return _0x10256a;for(const _0x49ebb6 of _0x12868c[_0x58b10e(0x17f)]){const _0x110a32=await this[_0x58b10e(0x15e)][_0x58b10e(0x150)](_0x49ebb6);_0x110a32&&_0x10256a[_0x58b10e(0x16d)](_0x110a32['id'],_0x110a32);}return _0x10256a;}async[_0x300448(0x198)]({userMessage:_0x1c225e,quickActionData:_0x405446}){const _0x2d725e=_0x300448;if(!this[_0x2d725e(0x182)])throw new _0x20794c(_0x2d725e(0x170),null,{'conversation':this});if(this[_0x2d725e(0x1a8)])throw new _0x20794c(_0x2d725e(0x147),null,{'conversation':this});try{const _0x14a31b=this[_0x2d725e(0x15e)][_0x2d725e(0x13e)](),_0x14247a=this[_0x2d725e(0x148)][_0x2d725e(0x1ad)](),_0x2cd9af=this[_0x2d725e(0x199)]['id'];this[_0x2d725e(0x1a8)]=this[_0x2d725e(0x1aa)]({'userMessage':_0x1c225e,'contextItems':_0x14a31b,'capabilities':_0x14247a,'modelId':_0x2cd9af,'quickActionData':_0x405446}),await this[_0x2d725e(0x1a8)][_0x2d725e(0x13d)](),this[_0x2d725e(0x15e)][_0x2d725e(0x16c)](this[_0x2d725e(0x1a8)][_0x2d725e(0x1b2)]);}catch(_0x3bbe65){if(_0x3bbe65 instanceof _0x20794c)this[_0x2d725e(0x154)](_0x2d725e(0x141),{'interactionId':this[_0x2d725e(0x1a8)]?this[_0x2d725e(0x1a8)]['id']:void 0x0,'error':_0x3bbe65});else{const _0x5ab661=_0x2a96f5[_0x2d725e(0x163)](_0x3bbe65[_0x2d725e(0x175)])||_0x2d725e(0x174);this[_0x2d725e(0x154)](_0x2d725e(0x141),{'interactionId':this[_0x2d725e(0x1a8)]?this[_0x2d725e(0x1a8)]['id']:void 0x0,'error':new _0x20794c(_0x5ab661,null,{'error':_0x3bbe65})});}}finally{this[_0x2d725e(0x1a8)]?.[_0x2d725e(0x156)](),this[_0x2d725e(0x1a8)]=void 0x0;}}[_0x300448(0x1aa)]({userMessage:_0x3f504d,contextItems:_0x2ff6eb,capabilities:_0x4792c4,modelId:_0x316c50,quickActionData:_0x2278a7}){const _0x13a023=_0x300448,_0xa136cc=new _0x571219({'userMessage':_0x3f504d,'contextItems':_0x2ff6eb,'capabilities':_0x4792c4,'conversationId':this['id'],'connector':this[_0x13a023(0x190)],'editor':this[_0x13a023(0x144)][_0x13a023(0x171)]&&this[_0x13a023(0x144)][_0x13a023(0x171)](),'model':_0x316c50,'quickActionData':_0x2278a7});return _0xa136cc[_0x13a023(0x189)](..._0x4c8bba)['to'](this),this[_0x13a023(0x197)][_0x13a023(0x176)](_0xa136cc),this[_0x13a023(0x154)](_0x13a023(0x19c),_0xa136cc),_0xa136cc;}[_0x300448(0x16a)](_0x12c0ef){const _0x1cd5b6=_0x300448;return this[_0x1cd5b6(0x197)][_0x1cd5b6(0x15b)](_0x3b96d3=>_0x3b96d3['id']===_0x12c0ef);}[_0x300448(0x19d)](_0x38aab8){const _0x5de581=_0x300448,_0x3d7ee3=this[_0x5de581(0x16a)](_0x38aab8);_0x3d7ee3&&(_0x3d7ee3[_0x5de581(0x1a3)](),this[_0x5de581(0x197)][_0x5de581(0x14a)](this[_0x5de581(0x197)][_0x5de581(0x161)](_0x3d7ee3),0x1));}get[_0x300448(0x180)](){const _0x1cbbc4=_0x300448;return this[_0x1cbbc4(0x197)][this[_0x1cbbc4(0x197)][_0x1cbbc4(0x178)]-0x1];}[_0x300448(0x1af)](_0x3e91a8){const _0x36461a=_0x300448;this[_0x36461a(0x15e)][_0x36461a(0x1af)](_0x3e91a8);}async[_0x300448(0x1a5)]({content:_0x11be5c,version:_0x22ab38,sessionId:_0x413023,selections:_0xfcd026}){const _0x1f920c=_0x300448;await this[_0x1f920c(0x15e)][_0x1f920c(0x145)](_0x11be5c,_0x22ab38,_0x413023,_0xfcd026);}[_0x300448(0x17d)](){const _0x102193=_0x300448;return this[_0x102193(0x1a8)]?.[_0x102193(0x15c)]()?.[_0x102193(0x17f)]||'';}[_0x300448(0x1a9)](_0x45ea40){const _0x46262a=_0x300448;this[_0x46262a(0x15e)][_0x46262a(0x1a9)](_0x45ea40);}[_0x300448(0x1a0)](){const _0x49822c=_0x300448;this[_0x49822c(0x15e)][_0x49822c(0x1a0)]();}[_0x300448(0x157)](_0x279d2b){const _0x1c74a6=_0x300448;this[_0x1c74a6(0x15e)][_0x1c74a6(0x157)](_0x279d2b);}[_0x300448(0x14d)](_0x119e09){const _0x512cff=_0x300448;this[_0x512cff(0x15e)][_0x512cff(0x14d)](_0x119e09);}[_0x300448(0x140)](_0x531981,_0x7e55ef){const _0x5691e5=_0x300448;this[_0x5691e5(0x15e)][_0x5691e5(0x140)](_0x531981,_0x7e55ef);}[_0x300448(0x185)](_0x31e2cb,_0x2a3e26,_0x9ccc79){const _0x9dbf88=_0x300448;return this[_0x9dbf88(0x15e)][_0x9dbf88(0x185)](_0x31e2cb,_0x2a3e26,_0x9ccc79);}[_0x300448(0x149)](_0x1dd3a9){const _0x338364=_0x300448;this[_0x338364(0x15e)][_0x338364(0x149)](_0x1dd3a9);}[_0x300448(0x18f)](){const _0x536808=_0x300448;this[_0x536808(0x148)][_0x536808(0x18f)]();}[_0x300448(0x164)](){const _0x15bfd8=_0x300448;this[_0x15bfd8(0x148)][_0x15bfd8(0x164)]();}[_0x300448(0x194)](){const _0x10dde0=_0x300448;return this[_0x10dde0(0x15e)][_0x10dde0(0x194)]();}[_0x300448(0x1a6)](){const _0x5818f9=_0x300448;return this[_0x5818f9(0x15e)][_0x5818f9(0x1a6)]();}[_0x300448(0x181)](){const _0x2e8ecc=_0x300448;return this[_0x2e8ecc(0x15e)][_0x2e8ecc(0x181)]();}async[_0x300448(0x1b1)](_0x30bfe0){const _0x321ce7=_0x300448;_0x30bfe0?!0x1===await this[_0x321ce7(0x1ab)][_0x321ce7(0x165)](_0x30bfe0)&&(_0x1be831(_0x321ce7(0x153),{'conversation':this,'model':_0x30bfe0}),_0x30bfe0=(await this[_0x321ce7(0x1ab)][_0x321ce7(0x142)]())[0x0]):(_0x1be831(_0x321ce7(0x162),{'conversation':this}),_0x30bfe0=(await this[_0x321ce7(0x1ab)][_0x321ce7(0x142)]())[0x0]),_0x30bfe0['id']!==this[_0x321ce7(0x199)]?.['id']&&(this[_0x321ce7(0x199)]=_0x30bfe0,this[_0x321ce7(0x148)][_0x321ce7(0x193)](),this[_0x321ce7(0x154)](_0x321ce7(0x146),{'selectedModel':_0x30bfe0}));}}
|
|
23
|
+
function _0x56de(_0x2107dc,_0x17c60c){const _0x2466a5=_0x2466();return _0x56de=function(_0x56de19,_0x3602f7){_0x56de19=_0x56de19-0x105;let _0x458a72=_0x2466a5[_0x56de19];return _0x458a72;},_0x56de(_0x2107dc,_0x17c60c);}const _0x467859=_0x56de;(function(_0x2850bb,_0x51e222){const _0x333fdf=_0x56de,_0x39dc75=_0x2850bb();while(!![]){try{const _0x53bd07=parseInt(_0x333fdf(0x167))/0x1+-parseInt(_0x333fdf(0x153))/0x2*(parseInt(_0x333fdf(0x136))/0x3)+-parseInt(_0x333fdf(0x112))/0x4+parseInt(_0x333fdf(0x14b))/0x5+-parseInt(_0x333fdf(0x10f))/0x6*(-parseInt(_0x333fdf(0x135))/0x7)+-parseInt(_0x333fdf(0x10c))/0x8*(-parseInt(_0x333fdf(0x169))/0x9)+-parseInt(_0x333fdf(0x149))/0xa*(parseInt(_0x333fdf(0x12c))/0xb);if(_0x53bd07===_0x51e222)break;else _0x39dc75['push'](_0x39dc75['shift']());}catch(_0x2b9c09){_0x39dc75['push'](_0x39dc75['shift']());}}}(_0x2466,0x2f672));import{CKEditorError as _0x4e667b,EmitterMixin as _0x3f49b0,logWarning as _0x5d9628}from'ckeditor5/src/utils.js';import{AI_MODEL_EVENT_NAMES as _0x369196}from'../../aicore/model/aiinteraction.js';import{AIChatContext as _0x5a39c3,AI_CONTEXT_MODEL_EVENT_NAMES as _0x3cc6a0}from'./aichatcontext.js';import{AICapabilities as _0x4859c4,CAPABILITIES_MODEL_EVENT_NAMES as _0x47bf47}from'../../aicore/model/aicapabilities.js';import{AIChatInteraction as _0x5e6e38}from'./aichatinteraction.js';import{errorsMap as _0x551e46}from'../../errorsmap.js';function _0x2466(){const _0x38bcaf=['selectedModel','fire','attributes','appendContent','getModel','setConversationTitle','getDocumentContext','addResourceToContext','isSelectionInContext','role','indexOf','6782350MsiKqA','populateFromMessage','652720eFdPHs','createInteraction','start','isStarted','isCurrentDocumentInConversation','conversationInitialized','length','webSearch','112054FWecwW','lastInteraction','removeInteraction','isCurrentDocumentInContext','set','find','chatCapabilities','assistant','prompt','getConversation','code','hasOwn','ai-chat-conversation-set-model-null','quickActionData','chatContext','error','setModel','conversationId','ai-chat-conversation-already-started','ai-chat-conversation-set-model-not-available','340664XxBThA','message','9dyCkyk','interactions','text','modelSelected','options','_extractContextItems','fetchConversation','sessionId','push','modification-delta','createReply','reasoning','chatModels','stop','contextItems','fetchConversationMessages','init','delegate','_processMessagesToInteractions','getCapabilitiesConfig','conversationStarted','loadSourceResources','updateCurrentDocument','interactionCreated','ai-chat-handle-user-conversation-not-initialized','getAvailableModels','2389880kwFPRr','ai-chat-conversation-start-no-model-selected','getPendingContextItems','1670802enruOg','getAll','getCurrentDocumentContext','31728NqaNAm','removeSelectionFromContext','isAvailable','title','getMessages','handleUserInteraction','stack','model','addSelectionToContext','capabilities','addFilesToContext','toggleReasoning','currentReply','removeFromContext','text-delta','updateCurrentDocumentInContext','currentInteraction','ai-chat-conversation-init-failed','getInteraction','ai-chat-conversation-init-from-id-failed','type','toLowerCase','content','user','splice','ai-chat-conversation-start-failed','11riuyho','selectedModelId','ai-chat-handle-user-interaction-already-in-progress','ai-chat-handle-user-interaction-start-failed','load','addUrlToContext','reset','get','group','7prZhAk','9JkNGCR','connector','addCurrentDocumentToContext','addToConversationContext','startConversation','getEditor','destroy','toggleWebSearch'];_0x2466=function(){return _0x38bcaf;};return _0x2466();}export class AIChatConversation extends _0x3f49b0(){['id'];[_0x467859(0x14e)]=!0x1;[_0x467859(0x16a)]=[];[_0x467859(0x122)];[_0x467859(0x13e)];[_0x467859(0x137)];[_0x467859(0x16d)];constructor(_0x540919){const _0x1bb0ed=_0x467859;super(),this[_0x1bb0ed(0x16d)]=_0x540919,this[_0x1bb0ed(0x137)]=_0x540919[_0x1bb0ed(0x137)],this[_0x1bb0ed(0x175)]=_0x540919[_0x1bb0ed(0x175)],this['id']=_0x540919[_0x1bb0ed(0x164)];}async[_0x467859(0x179)](_0x4d5e74){const _0x12c87f=_0x467859;try{this[_0x12c87f(0x161)]=new _0x5a39c3({'connector':this[_0x12c87f(0x137)],'config':_0x4d5e74,'ownerId':this['id']}),this[_0x12c87f(0x161)][_0x12c87f(0x17a)](..._0x3cc6a0)['to'](this),this[_0x12c87f(0x161)][_0x12c87f(0x179)](),this[_0x12c87f(0x159)]=new _0x4859c4(),this[_0x12c87f(0x159)][_0x12c87f(0x17a)](..._0x47bf47)['to'](this),this[_0x12c87f(0x159)][_0x12c87f(0x179)]();const _0x1ecf7a=await this[_0x12c87f(0x175)][_0x12c87f(0x10b)]();this[_0x12c87f(0x13f)](_0x12c87f(0x150),{'availableModels':_0x1ecf7a});const _0x5dbef0=await this[_0x12c87f(0x175)][_0x12c87f(0x142)](this[_0x12c87f(0x16d)][_0x12c87f(0x12d)]);_0x5dbef0&&await this[_0x12c87f(0x163)](_0x5dbef0);}catch(_0x18e09e){const _0x2f4930=new _0x4e667b(_0x12c87f(0x123),null,{'message':_0x18e09e[_0x12c87f(0x168)]||_0x18e09e});_0x2f4930[_0x12c87f(0x118)]=_0x18e09e[_0x12c87f(0x118)],this[_0x12c87f(0x13f)](_0x12c87f(0x162),{'error':_0x2f4930});}}async[_0x467859(0x14d)](){const _0xaf75f5=_0x467859;if(this[_0xaf75f5(0x14e)])throw new _0x4e667b(_0xaf75f5(0x165),null,{'conversation':this});if(!this[_0xaf75f5(0x13e)])throw new _0x4e667b(_0xaf75f5(0x10d),null,{'conversation':this});try{const {id:_0x49e1d9}=await this[_0xaf75f5(0x137)][_0xaf75f5(0x13a)](this['id'],this[_0xaf75f5(0x16d)][_0xaf75f5(0x134)])[_0xaf75f5(0x15c)]();this['id']=_0x49e1d9,this[_0xaf75f5(0x14e)]=!0x0,this[_0xaf75f5(0x13f)](_0xaf75f5(0x106),{'conversationId':this['id'],'selectedModel':this[_0xaf75f5(0x13e)]});}catch(_0x1413bb){const _0x196327=new _0x4e667b(_0xaf75f5(0x12b),null,{'message':_0x1413bb[_0xaf75f5(0x168)],'conversationId':this['id']});throw _0x196327[_0xaf75f5(0x118)]=_0x1413bb[_0xaf75f5(0x118)],this[_0xaf75f5(0x13f)](_0xaf75f5(0x162),{'error':_0x196327}),_0x196327;}}async[_0x467859(0x130)](_0x2bb8a7,_0x3eefd0){const _0x8e6328=_0x467859;try{const _0x21886e=await this[_0x8e6328(0x137)][_0x8e6328(0x16f)](_0x2bb8a7)[_0x8e6328(0x15c)](),_0x3db912=await this[_0x8e6328(0x137)][_0x8e6328(0x178)](_0x2bb8a7)[_0x8e6328(0x116)](),_0x4b44d3=_0x3db912[0x0][_0x8e6328(0x119)];this[_0x8e6328(0x14e)]=!0x0,this['id']=_0x21886e['id'],_0x8e6328(0x115)in _0x21886e?this[_0x8e6328(0x13f)](_0x8e6328(0x143),_0x21886e[_0x8e6328(0x115)],!0x0):this[_0x8e6328(0x13f)](_0x8e6328(0x143),'',!0x0);const _0xb7eb37=(await this[_0x8e6328(0x175)][_0x8e6328(0x110)]())[_0x8e6328(0x158)](_0x4c3743=>_0x4c3743['id'][_0x8e6328(0x127)]()===_0x4b44d3[_0x8e6328(0x127)]());return this[_0x8e6328(0x13e)]=_0xb7eb37,this[_0x8e6328(0x13f)](_0x8e6328(0x16c),{'selectedModel':_0xb7eb37,'isDisabled':!0x0}),await this[_0x8e6328(0x17b)](_0x3db912,_0x3eefd0,_0x4b44d3),this[_0x8e6328(0x122)]=void 0x0,this;}catch(_0x26b750){const _0x101e66=new _0x4e667b(_0x8e6328(0x125),null,{'message':_0x26b750[_0x8e6328(0x168)],'conversationId':_0x2bb8a7});throw _0x101e66[_0x8e6328(0x118)]=_0x26b750[_0x8e6328(0x118)],this[_0x8e6328(0x13f)](_0x8e6328(0x162),{'error':_0x101e66}),_0x101e66;}}async[_0x467859(0x17b)](_0x45c301,_0x3cc7d0,_0x1e5392){const _0x1068f4=_0x467859;let _0x213a8f;for(const _0x1e1628 of _0x45c301)if(_0x1068f4(0x129)===_0x1e1628[_0x1068f4(0x147)]){const _0x22fdc4=await this[_0x1068f4(0x16e)](_0x1e1628),_0x56f4c6={'isReasoningEnabled':Object[_0x1068f4(0x15e)](_0x1e1628[_0x1068f4(0x11b)],_0x1068f4(0x174)),'isWebSearchEnabled':Object[_0x1068f4(0x15e)](_0x1e1628[_0x1068f4(0x11b)],_0x1068f4(0x152))};_0x213a8f=this[_0x1068f4(0x14c)]({'userMessage':_0x1e1628[_0x1068f4(0x15b)],'contextItems':_0x22fdc4,'capabilities':_0x56f4c6,'modelId':_0x1e5392,'quickActionData':_0x1e1628[_0x1068f4(0x140)]?.[_0x1068f4(0x160)]}),this[_0x1068f4(0x122)]=_0x213a8f,this[_0x1068f4(0x161)][_0x1068f4(0x139)](this[_0x1068f4(0x122)][_0x1068f4(0x177)]);}else{if(_0x1068f4(0x15a)===_0x1e1628[_0x1068f4(0x147)]&&_0x213a8f)for(const _0x25c69c of _0x1e1628[_0x1068f4(0x128)]){const _0x477908=_0x1068f4(0x16b)===_0x25c69c[_0x1068f4(0x126)]?_0x1068f4(0x120):_0x1068f4(0x172),_0x2dd1da=_0x213a8f[_0x1068f4(0x144)]()?.[_0x1068f4(0x170)]!==_0x3cc7d0;_0x213a8f[_0x1068f4(0x11e)]=_0x213a8f[_0x1068f4(0x173)]({'type':_0x477908,'isDone':!0x0,'interactionId':_0x213a8f['id'],'areActionsDisabled':_0x2dd1da}),_0x213a8f[_0x1068f4(0x11e)][_0x1068f4(0x141)](_0x25c69c[_0x1068f4(0x128)]);}}}async[_0x467859(0x16e)](_0x30b2ff){const _0x4ce6a1=_0x467859,_0x5ab797=new Map();if(!_0x30b2ff[_0x4ce6a1(0x128)])return _0x5ab797;for(const _0x412391 of _0x30b2ff[_0x4ce6a1(0x128)]){const _0x8bb4ef=await this[_0x4ce6a1(0x161)][_0x4ce6a1(0x14a)](_0x412391);_0x8bb4ef&&_0x5ab797[_0x4ce6a1(0x157)](_0x8bb4ef['id'],_0x8bb4ef);}return _0x5ab797;}async[_0x467859(0x117)]({userMessage:_0x3c0465,quickActionData:_0x53e04c}){const _0x296ed4=_0x467859;if(!this[_0x296ed4(0x14e)])throw new _0x4e667b(_0x296ed4(0x10a),null,{'conversation':this});if(this[_0x296ed4(0x122)])throw new _0x4e667b(_0x296ed4(0x12e),null,{'conversation':this});try{const _0x5cc714=this[_0x296ed4(0x161)][_0x296ed4(0x10e)](),_0x262d1c=this[_0x296ed4(0x159)][_0x296ed4(0x105)](),_0x2ba825=this[_0x296ed4(0x13e)]['id'];this[_0x296ed4(0x122)]=this[_0x296ed4(0x14c)]({'userMessage':_0x3c0465,'contextItems':_0x5cc714,'capabilities':_0x262d1c,'modelId':_0x2ba825,'quickActionData':_0x53e04c}),await this[_0x296ed4(0x122)][_0x296ed4(0x14d)](),this[_0x296ed4(0x161)][_0x296ed4(0x139)](this[_0x296ed4(0x122)][_0x296ed4(0x177)]);}catch(_0x26aa84){if(_0x26aa84 instanceof _0x4e667b)this[_0x296ed4(0x13f)](_0x296ed4(0x162),{'interactionId':this[_0x296ed4(0x122)]?this[_0x296ed4(0x122)]['id']:void 0x0,'error':_0x26aa84});else{const _0x480061=_0x551e46[_0x296ed4(0x133)](_0x26aa84[_0x296ed4(0x15d)])||_0x296ed4(0x12f);this[_0x296ed4(0x13f)](_0x296ed4(0x162),{'interactionId':this[_0x296ed4(0x122)]?this[_0x296ed4(0x122)]['id']:void 0x0,'error':new _0x4e667b(_0x480061,null,{'error':_0x26aa84})});}}finally{this[_0x296ed4(0x122)]?.[_0x296ed4(0x176)](),this[_0x296ed4(0x122)]=void 0x0;}}[_0x467859(0x14c)]({userMessage:_0x344cf5,contextItems:_0x100704,capabilities:_0x66308,modelId:_0x52f354,quickActionData:_0x46249b}){const _0x29fe20=_0x467859,_0x41410c=new _0x5e6e38({'userMessage':_0x344cf5,'contextItems':_0x100704,'capabilities':_0x66308,'conversationId':this['id'],'connector':this[_0x29fe20(0x137)],'editor':this[_0x29fe20(0x16d)][_0x29fe20(0x13b)]&&this[_0x29fe20(0x16d)][_0x29fe20(0x13b)](),'model':_0x52f354,'quickActionData':_0x46249b});return _0x41410c[_0x29fe20(0x17a)](..._0x369196)['to'](this),this[_0x29fe20(0x16a)][_0x29fe20(0x171)](_0x41410c),this[_0x29fe20(0x13f)](_0x29fe20(0x109),_0x41410c),_0x41410c;}[_0x467859(0x124)](_0x6ea84d){const _0x338fa9=_0x467859;return this[_0x338fa9(0x16a)][_0x338fa9(0x158)](_0x3e5749=>_0x3e5749['id']===_0x6ea84d);}[_0x467859(0x155)](_0x3b950d){const _0x39eac1=_0x467859,_0x501191=this[_0x39eac1(0x124)](_0x3b950d);_0x501191&&(_0x501191[_0x39eac1(0x13c)](),this[_0x39eac1(0x16a)][_0x39eac1(0x12a)](this[_0x39eac1(0x16a)][_0x39eac1(0x148)](_0x501191),0x1));}get[_0x467859(0x154)](){const _0x435bd2=_0x467859;return this[_0x435bd2(0x16a)][this[_0x435bd2(0x16a)][_0x435bd2(0x151)]-0x1];}[_0x467859(0x138)](_0x4ccb5b){const _0xf0dee4=_0x467859;this[_0xf0dee4(0x161)][_0xf0dee4(0x138)](_0x4ccb5b);}async[_0x467859(0x121)]({content:_0x15f54c,version:_0x1451ef,sessionId:_0x1a34b0,selections:_0x18c03b}){const _0x4d1921=_0x467859;await this[_0x4d1921(0x161)][_0x4d1921(0x108)](_0x15f54c,_0x1451ef,_0x1a34b0,_0x18c03b);}[_0x467859(0x111)](){const _0x4bbb5c=_0x467859;return this[_0x4bbb5c(0x122)]?.[_0x4bbb5c(0x144)]()?.[_0x4bbb5c(0x128)]||'';}[_0x467859(0x11a)](_0x5b6a98){const _0x5bd313=_0x467859;this[_0x5bd313(0x161)][_0x5bd313(0x11a)](_0x5b6a98);}[_0x467859(0x113)](){const _0x4f01bd=_0x467859;this[_0x4f01bd(0x161)][_0x4f01bd(0x113)]();}[_0x467859(0x11c)](_0x49a893){const _0x51e26e=_0x467859;this[_0x51e26e(0x161)][_0x51e26e(0x11c)](_0x49a893);}[_0x467859(0x131)](_0x596cb5){const _0x404e69=_0x467859;this[_0x404e69(0x161)][_0x404e69(0x131)](_0x596cb5);}[_0x467859(0x145)](_0x1c2487,_0x12d142){const _0x5aee59=_0x467859;this[_0x5aee59(0x161)][_0x5aee59(0x145)](_0x1c2487,_0x12d142);}[_0x467859(0x107)](_0x3781d1,_0x4cc084,_0x587fab){const _0x4301e9=_0x467859;return this[_0x4301e9(0x161)][_0x4301e9(0x107)](_0x3781d1,_0x4cc084,_0x587fab);}[_0x467859(0x11f)](_0x61d1cb){const _0x1a3af4=_0x467859;this[_0x1a3af4(0x161)][_0x1a3af4(0x11f)](_0x61d1cb);}[_0x467859(0x13d)](){const _0x4110d6=_0x467859;this[_0x4110d6(0x159)][_0x4110d6(0x13d)]();}[_0x467859(0x11d)](){const _0x57f30e=_0x467859;this[_0x57f30e(0x159)][_0x57f30e(0x11d)]();}[_0x467859(0x156)](){const _0xeb05ae=_0x467859;return this[_0xeb05ae(0x161)][_0xeb05ae(0x156)]();}[_0x467859(0x14f)](){const _0x56ad98=_0x467859;return this[_0x56ad98(0x161)][_0x56ad98(0x14f)]();}[_0x467859(0x146)](){const _0x625329=_0x467859;return this[_0x625329(0x161)][_0x625329(0x146)]();}async[_0x467859(0x163)](_0x3e24d1){const _0x1df9ad=_0x467859;_0x3e24d1?!0x1===await this[_0x1df9ad(0x175)][_0x1df9ad(0x114)](_0x3e24d1)&&(_0x5d9628(_0x1df9ad(0x166),{'conversation':this,'model':_0x3e24d1}),_0x3e24d1=(await this[_0x1df9ad(0x175)][_0x1df9ad(0x10b)]())[0x0]):(_0x5d9628(_0x1df9ad(0x15f),{'conversation':this}),_0x3e24d1=(await this[_0x1df9ad(0x175)][_0x1df9ad(0x10b)]())[0x0]),_0x3e24d1['id']!==this[_0x1df9ad(0x13e)]?.['id']&&(this[_0x1df9ad(0x13e)]=_0x3e24d1,this[_0x1df9ad(0x159)][_0x1df9ad(0x132)](),this[_0x1df9ad(0x13f)](_0x1df9ad(0x16c),{'selectedModel':_0x3e24d1}));}}
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
var
|
|
23
|
+
var _0x57e58d=_0x49a5;(function(_0x20803c,_0x1ebac6){var _0xbe10ca=_0x49a5,_0x2a72be=_0x20803c();while(!![]){try{var _0x3544b0=parseInt(_0xbe10ca(0x86))/0x1+-parseInt(_0xbe10ca(0x90))/0x2+-parseInt(_0xbe10ca(0x8b))/0x3+-parseInt(_0xbe10ca(0x8f))/0x4+-parseInt(_0xbe10ca(0x95))/0x5+-parseInt(_0xbe10ca(0x99))/0x6*(-parseInt(_0xbe10ca(0x9a))/0x7)+parseInt(_0xbe10ca(0x9b))/0x8;if(_0x3544b0===_0x1ebac6)break;else _0x2a72be['push'](_0x2a72be['shift']());}catch(_0x3cc8ec){_0x2a72be['push'](_0x2a72be['shift']());}}}(_0x6fc9,0x9c2f2));import{AICapabilities as _0x2b5bf9}from'../../aicore/model/aicapabilities.js';import{AIInteraction as _0xf34ee1}from'../../aicore/model/aiinteraction.js';function _0x6fc9(){var _0x37222d=['1884qulMCQ','15064BOHMMp','17802904MhUfJv','451370quJGte','quickActionData','model','sendRequest','contextItems','3833907SbhXuV','userMessage','current-document','get','627092MHtRmz','1120832hKuxEj','connector','conversationId','mapContextItemsToRequestData','capabilities','3587865IEzpXN','getDocumentContext','getCapabilitiesRequestData','queryAssistant'];_0x6fc9=function(){return _0x37222d;};return _0x6fc9();}import{AIChatContext as _0x3964a2}from'./aichatcontext.js';function _0x49a5(_0x46957a,_0x18e619){var _0x6fc9ee=_0x6fc9();return _0x49a5=function(_0x49a5cd,_0x49278b){_0x49a5cd=_0x49a5cd-0x86;var _0x106d1=_0x6fc9ee[_0x49a5cd];return _0x106d1;},_0x49a5(_0x46957a,_0x18e619);}export class AIChatInteraction extends _0xf34ee1{[_0x57e58d(0x8c)];[_0x57e58d(0x92)];[_0x57e58d(0x8a)]=new Map();[_0x57e58d(0x88)];[_0x57e58d(0x87)];constructor(_0x466ead){var _0xe5b515=_0x57e58d;super(_0x466ead),this[_0xe5b515(0x92)]=_0x466ead[_0xe5b515(0x92)],this[_0xe5b515(0x8a)]=_0x466ead[_0xe5b515(0x8a)],this[_0xe5b515(0x94)]=_0x466ead[_0xe5b515(0x94)],this[_0xe5b515(0x8c)]=_0x466ead[_0xe5b515(0x8c)],this[_0xe5b515(0x88)]=_0x466ead[_0xe5b515(0x88)],this[_0xe5b515(0x87)]=_0x466ead[_0xe5b515(0x87)];}async[_0x57e58d(0x89)](){var _0x3c61ee=_0x57e58d;return this[_0x3c61ee(0x91)][_0x3c61ee(0x98)]({'message':this[_0x3c61ee(0x8c)],'conversationId':this[_0x3c61ee(0x92)],'parts':_0x3964a2[_0x3c61ee(0x93)](this[_0x3c61ee(0x8a)]),'capabilities':_0x2b5bf9[_0x3c61ee(0x97)](this[_0x3c61ee(0x94)]),'model':this[_0x3c61ee(0x88)],'quickActionData':this[_0x3c61ee(0x87)]});}[_0x57e58d(0x96)](){var _0x1a32cc=_0x57e58d;return this[_0x1a32cc(0x8a)][_0x1a32cc(0x8e)](_0x1a32cc(0x8d));}}
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x5d7554=_0x3d8e;(function(_0x266d11,_0x3b412b){const _0x222890=_0x3d8e,_0x1ee7c0=_0x266d11();while(!![]){try{const _0x3b19eb=-parseInt(_0x222890(0x13d))/0x1*(parseInt(_0x222890(0x14a))/0x2)+parseInt(_0x222890(0x14d))/0x3*(-parseInt(_0x222890(0x145))/0x4)+-parseInt(_0x222890(0x14c))/0x5*(-parseInt(_0x222890(0x146))/0x6)+-parseInt(_0x222890(0x144))/0x7*(parseInt(_0x222890(0x141))/0x8)+-parseInt(_0x222890(0x149))/0x9+parseInt(_0x222890(0x13e))/0xa+-parseInt(_0x222890(0x142))/0xb*(-parseInt(_0x222890(0x147))/0xc);if(_0x3b19eb===_0x3b412b)break;else _0x1ee7c0['push'](_0x1ee7c0['shift']());}catch(_0x2639ab){_0x1ee7c0['push'](_0x1ee7c0['shift']());}}}(_0x2ed9,0x59d97));import{AIModels as _0x466e23}from'../../aicore/model/aimodels.js';function _0x3d8e(_0x5c0220,_0x489bcc){const _0x2ed979=_0x2ed9();return _0x3d8e=function(_0x3d8e4f,_0xab6ba2){_0x3d8e4f=_0x3d8e4f-0x13b;let _0x1b3770=_0x2ed979[_0x3d8e4f];return _0x1b3770;},_0x3d8e(_0x5c0220,_0x489bcc);}function _0x2ed9(){const _0x43bb5d=['16MFhByU','sort','15FLWQmZ','139155SPEGMC','length','enabled','86206ODirwR','4917240MXtTtW','filter','getAll','2600344uTYluk','33fzdAIf','values','7CvHVKq','4JdWPMP','978018Mnvkqy','1818876PvrkGB','capabilities','57177vhkGPR'];_0x2ed9=function(){return _0x43bb5d;};return _0x2ed9();}export class AIChatModels extends _0x466e23{async[_0x5d7554(0x140)](){const _0x18ba45=_0x5d7554;return(await super[_0x18ba45(0x140)]())[_0x18ba45(0x14b)]((_0x525fee,_0x3e23c4)=>{const _0x525429=_0x18ba45,_0x3cdca6=Object[_0x525429(0x143)](_0x525fee[_0x525429(0x148)])[_0x525429(0x13f)](_0x1b989c=>_0x1b989c[_0x525429(0x13c)])[_0x525429(0x13b)];return Object[_0x525429(0x143)](_0x3e23c4[_0x525429(0x148)])[_0x525429(0x13f)](_0x1f14a8=>_0x1f14a8[_0x525429(0x13c)])[_0x525429(0x13b)]-_0x3cdca6;});}}
|