@ckeditor/ckeditor5-ai 47.4.0-alpha.0 → 47.4.0-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (120) hide show
  1. package/build/ai.js +1 -1
  2. package/dist/index.js +5 -5
  3. package/package.json +15 -15
  4. package/src/aiactions/aiactions.js +1 -1
  5. package/src/aiactions/model/aiactionsinteraction.js +1 -1
  6. package/src/aiactions/model/aiactionsreply.js +1 -1
  7. package/src/aiassistant/adapters/aiadapter.js +1 -1
  8. package/src/aiassistant/adapters/aitextadapter.js +1 -1
  9. package/src/aiassistant/adapters/awstextadapter.js +1 -1
  10. package/src/aiassistant/adapters/openaitextadapter.js +1 -1
  11. package/src/aiassistant/aiassistant.js +1 -1
  12. package/src/aiassistant/aiassistantediting.js +1 -1
  13. package/src/aiassistant/aiassistantui.js +1 -1
  14. package/src/aiassistant/ui/aiassistantcontroller.js +2 -2
  15. package/src/aiassistant/ui/form/aiformcontentarea.js +1 -1
  16. package/src/aiassistant/ui/form/aiformerrorview.js +1 -1
  17. package/src/aiassistant/ui/form/aiformpromptview.js +1 -1
  18. package/src/aiassistant/ui/form/aiformtoolbarview.js +1 -1
  19. package/src/aiassistant/ui/form/aiformview.js +1 -1
  20. package/src/aiassistant/ui/form/aihistorylistitemview.js +1 -1
  21. package/src/aiassistant/ui/form/aihistorylistview.js +1 -1
  22. package/src/aiassistant/ui/form/prompthistory.js +1 -1
  23. package/src/aiassistant/ui/showaiassistantcommand.js +1 -1
  24. package/src/aiballoon/aiballoon.js +1 -1
  25. package/src/aiballoon/ui/aiballoondisclaimerview.js +1 -1
  26. package/src/aiballoon/ui/aiballoontoolbarview.js +1 -1
  27. package/src/aiballoon/ui/aiballoonview.js +1 -1
  28. package/src/aichat/aichat.js +1 -1
  29. package/src/aichat/aichatcontroller.js +1 -1
  30. package/src/aichat/aichatui.js +1 -1
  31. package/src/aichat/model/aichatcontext.js +1 -1
  32. package/src/aichat/model/aichatconversation.js +1 -1
  33. package/src/aichat/model/aichatinteraction.js +1 -1
  34. package/src/aichat/ui/aichatcontrolsview.js +1 -1
  35. package/src/aichat/ui/aichatfeedview.js +1 -1
  36. package/src/aichat/ui/aichatheaderview.js +1 -1
  37. package/src/aichat/ui/aichatview.js +1 -1
  38. package/src/aichat/ui/controls/aichatchipsoverflowmanager.js +1 -1
  39. package/src/aichat/ui/controls/aichatcontextitembuttonview.js +1 -1
  40. package/src/aichat/ui/controls/aichatcontextpanelurlinputview.js +1 -1
  41. package/src/aichat/ui/controls/aichatcontextpanelview.js +1 -1
  42. package/src/aichat/ui/controls/aichatcontrolsloaderview.js +1 -1
  43. package/src/aichat/ui/controls/aichatpromptcapabilitiesview.js +1 -1
  44. package/src/aichat/ui/controls/aichatpromptinputview.js +1 -1
  45. package/src/aichat/ui/controls/resources/aichatcontextresourcesview.js +1 -1
  46. package/src/aichat/ui/controls/resources/aichatresourcelistitemview.js +1 -1
  47. package/src/aichat/ui/controls/resources/aichatresourcesballoonview.js +1 -1
  48. package/src/aichat/ui/controls/resources/aichatresourcessearchinputview.js +1 -1
  49. package/src/aichat/ui/feed/aichatfeedcontextchipsview.js +1 -1
  50. package/src/aichat/ui/feed/aichatfeedinteractionheaderview.js +1 -1
  51. package/src/aichat/ui/feed/aichatfeeditemview.js +1 -1
  52. package/src/aichat/ui/feed/aichatfeedreplyitemview.js +1 -1
  53. package/src/aichat/ui/feed/aichatfeedsuggestionitemactionsview.js +1 -1
  54. package/src/aichat/ui/feed/aichatfeedsuggestionitemview.js +1 -1
  55. package/src/aichat/ui/feed/aichatfeedusermessageitem.js +1 -1
  56. package/src/aichat/utils/promisequeue.js +1 -1
  57. package/src/aichathistory/aichathistory.js +1 -1
  58. package/src/aichathistory/aichathistorycontroller.js +1 -1
  59. package/src/aichathistory/aichathistoryui.js +1 -1
  60. package/src/aichathistory/model/aichathistoryconversations.js +1 -1
  61. package/src/aichathistory/model/aichathistoryitem.js +1 -1
  62. package/src/aichathistory/ui/aichathistorylistitemview.js +2 -2
  63. package/src/aichathistory/ui/aichathistorylistview.js +1 -1
  64. package/src/aichathistory/ui/aichathistoryview.js +1 -1
  65. package/src/aicore/aiconnector.js +1 -1
  66. package/src/aicore/aiediting.js +1 -1
  67. package/src/aicore/model/aicapabilities.js +1 -1
  68. package/src/aicore/model/aiinteraction.js +1 -1
  69. package/src/aicore/model/aimodels.js +1 -1
  70. package/src/aicore/model/aireply.js +1 -1
  71. package/src/aicore/pipeline/airesponseapplier.js +2 -2
  72. package/src/aicore/pipeline/airesponseparser.js +2 -2
  73. package/src/aicore/ui/aidisclaimerview.js +1 -1
  74. package/src/aicore/ui/aiskeleton.js +1 -1
  75. package/src/aicore/ui/suggestioncontainer/aiminitoolbarview.js +1 -1
  76. package/src/aicore/ui/suggestioncontainer/aisuggestionbodyview.js +1 -1
  77. package/src/aicore/ui/suggestioncontainer/aisuggestioncontainerview.js +1 -1
  78. package/src/aicore/ui/suggestioncontainer/aisuggestioncontentpartview.js +1 -1
  79. package/src/aicore/ui/suggestioncontainer/aisuggestionheaderview.js +1 -1
  80. package/src/aicore/utils/createresizebutton.js +1 -1
  81. package/src/aicore/utils/documentrange.js +1 -1
  82. package/src/aicore/utils/geteditorfromcontext.js +1 -1
  83. package/src/aicore/utils/getoperationsfromreply.js +1 -1
  84. package/src/aicore/utils/getsuggestionpartsfromreply.js +1 -1
  85. package/src/aicore/utils/htmlparser.js +1 -1
  86. package/src/aicore/utils/htmlstreamer.js +1 -1
  87. package/src/aieditorintegration/aieditorintegration.js +1 -1
  88. package/src/aieditorintegration/aitogglebutton/aitogglebuttonui.js +1 -1
  89. package/src/aieditorintegration/aitogglebutton/toggleaicommand.js +1 -1
  90. package/src/aiquickactions/aiquickactions.js +1 -1
  91. package/src/aiquickactions/aiquickactionscommand.js +1 -1
  92. package/src/aiquickactions/aiquickactionsediting.js +1 -1
  93. package/src/aiquickactions/aiquickactionsui.js +1 -1
  94. package/src/aiquickactions/ui/aiquickactionsbuttoncreator.js +1 -1
  95. package/src/aiquickactions/ui/aiquickactionsdropdowncontentview.js +1 -1
  96. package/src/aiquickactions/ui/aiquickactionsdropdowncreator.js +1 -1
  97. package/src/aiquickactions/ui/dropdownmenubuttonwithhighlightview.js +1 -1
  98. package/src/aireviewmode/aireviewmode.js +1 -1
  99. package/src/aireviewmode/aireviewmodecontroller.js +1 -1
  100. package/src/aireviewmode/aireviewmodeediting.js +1 -1
  101. package/src/aireviewmode/aireviewmodeui.js +1 -1
  102. package/src/aireviewmode/model/aireviewcheckresult.js +1 -1
  103. package/src/aireviewmode/model/aireviewcheckrun.js +1 -1
  104. package/src/aireviewmode/ui/aireviemodepromptinputview.js +1 -1
  105. package/src/aireviewmode/ui/aireviewmodeballoonsuggestionview.js +1 -1
  106. package/src/aireviewmode/ui/aireviewmodechecklistitemresultview.js +1 -1
  107. package/src/aireviewmode/ui/aireviewmodecustomcheckview.js +1 -1
  108. package/src/aireviewmode/ui/aireviewmodefinishreviewbuttonview.js +1 -1
  109. package/src/aireviewmode/ui/aireviewmodegeneralerrorview.js +1 -1
  110. package/src/aireviewmode/ui/aireviewmodereviewchecklistview.js +1 -1
  111. package/src/aireviewmode/ui/aireviewmodereviewcheckresultsview.js +1 -1
  112. package/src/aireviewmode/ui/aireviewmodereviewcommandlistitemview.js +1 -1
  113. package/src/aireviewmode/ui/aireviewmodereviewcompletedview.js +1 -1
  114. package/src/aireviewmode/ui/aireviewmodeview.js +1 -1
  115. package/src/aireviewmode/ui/form/aireviewmodeformdropdown.js +1 -1
  116. package/src/aireviewmode/ui/form/aireviewmodeformmanager.js +1 -1
  117. package/src/aitabs/aitabs.js +1 -1
  118. package/src/aitabs/tabs/aitabsview.js +1 -1
  119. package/src/aitabs/tabs/tabbuttonview.js +1 -1
  120. package/src/aitabs/tabs/tabpanelview.js +1 -1
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x380a5b=_0x2578;(function(_0x18d22d,_0x94c1cd){const _0x52ad06=_0x2578,_0x4e7903=_0x18d22d();while(!![]){try{const _0x42851=-parseInt(_0x52ad06(0x245))/0x1*(-parseInt(_0x52ad06(0x1b1))/0x2)+parseInt(_0x52ad06(0x262))/0x3+-parseInt(_0x52ad06(0x22b))/0x4+parseInt(_0x52ad06(0x1e8))/0x5*(parseInt(_0x52ad06(0x282))/0x6)+parseInt(_0x52ad06(0x2a1))/0x7+parseInt(_0x52ad06(0x273))/0x8+-parseInt(_0x52ad06(0x1c5))/0x9*(parseInt(_0x52ad06(0x21f))/0xa);if(_0x42851===_0x94c1cd)break;else _0x4e7903['push'](_0x4e7903['shift']());}catch(_0x153ecc){_0x4e7903['push'](_0x4e7903['shift']());}}}(_0x5e7c,0x3cb6f));import{ContextPlugin as _0x5d6eb1,Editor as _0x268d61}from'ckeditor5/src/core.js';import{BodyCollection as _0x2e7136}from'ckeditor5/src/ui.js';import{CKEditorError as _0xb8924f,logError as _0x1eb88a,scrollViewportToShowTarget as _0x59bc32,uid as _0x31c287}from'ckeditor5/src/utils.js';import{AIConnector as _0x3d8712}from'../aicore/aiconnector.js';import{AITabs as _0x29b001}from'../aitabs/aitabs.js';import{AIChatConversation as _0x49fb89}from'./model/aichatconversation.js';import{getTranslation as _0x3c35c3}from'../aicore/utils/common-translations.js';import{AI_VISUAL_SELECTION_MARKER_NAME as _0x5a2f18}from'../aicore/aiediting.js';import{AI_REPLY_ACTIONS as _0x37616d}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';import{AIModels as _0x36e4f1}from'../aicore/model/aimodels.js';import{getEditorFromContext as _0x260be3}from'../aicore/utils/geteditorfromcontext.js';import{DocumentCompare as _0x1fcfbc,DATA_ID_MODEL_ATTRIBUTE as _0x54cb6e}from'ckeditor5-collaboration/src/collaboration-core.js';function _0x2578(_0x50b514,_0x4a97d7){const _0x5e7cc6=_0x5e7c();return _0x2578=function(_0x25780b,_0x5526f9){_0x25780b=_0x25780b-0x17f;let _0x59b420=_0x5e7cc6[_0x25780b];return _0x59b420;},_0x2578(_0x50b514,_0x4a97d7);}import{fixMarkerOperationOldRange as _0xec59ff,getOperationsFromReply as _0x2556e1}from'../aicore/utils/getoperationsfromreply.js';import{expandSelectionWithContext as _0x42ac67,getMinimalSelection as _0x4ab0b5}from'../aicore/utils/getsuggestionpartsfromreply.js';import{ModelRange as _0x30994b,_DetachOperation as _0x4d8793}from'ckeditor5/src/engine.js';import{findOne as _0x3ca4fe,getAttribute as _0x2a6712,serialize as _0x3acb67,Document as _0x554c05,findByAttribute as _0x48bf17}from'../aicore/utils/htmlparser.js';import{IconAI as _0x15e824}from'@ckeditor/ckeditor5-icons';import{AISuggestionContainerView as _0x52a448}from'../aicore/ui/suggestioncontainer/aisuggestioncontainerview.js';import{AIBalloon as _0x24b349}from'../aiballoon/aiballoon.js';function _0x5e7c(){const _0x4f704d=['_batchToChanges','addSelectionToContext','_logError','AI_CHAT_CONTEXT_UNSUPPORTED_TYPE','sources','interactionCreated','reasoningFinished','ai-request-aborted','AIChatUI','showFakeVisualSelection','error','alignToTop','editing','setLoadingMessage','start','message','_handleStartConversation','580350xmoCyC','contextItemAdded','batch','interactionStarted','ai-chat-context-invalid-data','like','ai.chat.context','_scrollToSuggestionRange','addContextOptionsChanged','createPositionAt','replyCreated','getContentParts','1283900rKEhLN','AITabs','interactionFinished','clearPendingContextUI','addFeedItemError','nextSibling','resource','AI_CHAT_CONTEXT_INVALID_DATA','uploadProgressChanged','addOperation','AI_CHAT_ABORTED_MESSAGE','findIndex','_openBalloonFor','AI_CHAT_UNABLE_TO_LOAD_CONVERSATION','AI_CHAT_CONTEXT_FORM_DATA_SIZE_LIMITS_EXCEEDED','toString','setIsUploadInProgress','getDocumentContext','_handleUIUserMessage','afterInit','_insertSuggestion','messageId','ai.chat.models.displayedModels','Showing\x20conversation\x20history...','removeSelectionFromContext','rejectSuggestion','8191tvWgRh','ai-chat-conversation-start-failed','AI_CHAT_CONTEXT_CURRENT_DOCUMENT','context','pending','AI_CHAT_CONTEXT_UNSUPPORTED_FILE_TYPE','_flushLastInteractionUI','updateContent','attachToDom','_aiChatUi','toggleWebSearch','domConverter','redo','ai-chat-invalid-request','log','add','get','replyContentUpdated','TrackChanges','ai-chat-context-unsupported-file-type','AI_CHAT_INVALID_REQUEST','_balloonShowDiff','range','contextItemLoadingEnded','_setIsMaximized','closeSourceResourceBalloon','getChildren','ai-chat-missing-channel-id','selection','41148hImLIZ','isPremiumPlugin','query','contextItemRemoved','finishInteraction','_integrateEditor','maxOffset','getConversation','setConversationTitle','webSearchFinished','rootName','indexOf','updateFeedItemAIReplySuggestionContent','conversationInitialized','showChangeInText','requires','updateFeedItemAIReplyContent','3414824LCElwJ','ai-chat-conversation-init-failed','text-delta','getGroupId','current-document','remove','type','ai-chat-context-file-too-large','_toggleReasoning','chat','modification-delta','disableControls','split','_updateRatings','new','233652fphFGx','resourceStateChanged','getOperations','slice','sendUserMessage','node','baseVersion','AIEditing','length','changes','close','addFileToContext','ai-chat-controller-mouse-over','updateCurrentDocumentInContext','startConversation','addFeedInteractionHeader','$graveyard','AI_CHAT_UNTITLED_CONVERSATION','addCurrentDocumentToContext','focusPromptInput','_bodyCollection','filter','push','getAttribute','addFeedItemAISuggestion','_aiEditing','loadConversation','isOpen','stopInteraction','map','history','1687714tMcger','version','updateFeedItemAIReplySuggestionPartState','addUrlToContext','contextItem','getFirstRange','toggleSuggestionDisplayMode','marker','createRange','load','setFeedItemRenderingStrategy','insertSuggestion','getChild','upsertAIChatRating','resize','_removeAISelectionMarkers','AI_CHAT_CONTEXT_FILE_TOO_MANY_PAGES','selectModel','find','streaming','view','getInteractionAndReplyById','capabilitiesUpdated','collaboration.channelId','toggleReasoning','createConversation','static','config','changeGroups','populateSourceResourceBalloon','getMarkersGroup','modelSelected','ai.availableReplyActions','addSelectionToChatContext','Disliked\x20response','root','interactionDestroyed','_stopLastInteraction','content','ai-chat-controller-no-active-conversation','removeContextItem','sourceResourcesLoaded','addResourceToContext','children','_aiChatModels','getPath','addFilesToContext','activateTab','addFeedItemStaticMessage','$root','unshift','ai-chat-context-unsupported-type','Undo','editors','handleRemovedConversation','AI_CHAT_GENERIC_ERROR','open','ai-chat-url-upload-failed','setAddContextOptions','main','isLoading','startInteraction','path','viewRangeToDom','removed','toggleLoadingSkeleton','AI_CHAT_CONTEXT_UNABLE_TO_LOAD_RESOURCES','forEach','_previewedChangeGroup','index','handleUserInteraction','getTransformedByOperation','document','contextItems','setSelectedModel','delete','Liked\x20response','isModelAvailable','_startConversationSafely','anchorId','AI_CHAT_UNABLE_TO_START_CONVERSATION','_applySuggestion','state','isUploadInProgress','accepted','source','pluginName','enableControls','showPrevious','hasChanges','model','resizedTabs','resources','loadSourceResources','stop','isCurrentDocumentInConversation','init','hideFakeVisualSelection','DocumentCompare','sourceId','setIsMaximized','toViewRange','getDiff','documentContextContent','ai-chat-resource-load-failed','removeMarker','setContextItemLoading','startAutoScroll','applySuggestion','updateFeedItemAIReplySources','getReply','mouseLeaveSuggestion','isCurrentDocumentInContext','setChangeGroupState','isDocumentOperation','data-id','isInContext','AI_CHAT_CONTEXT_FILE_TOO_LARGE','_getDocumentRangeForReplyChanges','addDocumentToContext','end','replies','sendMessage','_applyOperationsAsSuggestions','_toggleWebSearch','indexes','isStarted','isDisabled','markers','100GBJDxL','getDocumentData','detachFromDom','startsWith','AIChatController','change','replyChangeGroupStateUpdated','updateResourceState','showNext','plugins','has','getRoot','_removeFromContext','fetchConversation','cloneNode','destroy','data','lastInteraction','getChildAtOffset','getSelectionText','99BIiziD','mouseOverSuggestion','from','uiId','isOfficialPlugin','showDiff','sourcePosition','resizeTabs','stopListening','activeConversation','ai-chat-context-form-data-size-limits-exceeded','resourceId','ready','scrollFeedToSuggestion','_createFromRanges','resetMessageInput','parse','createPositionFromPath','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_URL','ai.chat.models.defaultModelId','ai-conversation-','getInteraction','contextSent','webSearchStarted','updateCapabilities','setConversationContext','addFeedItemUserMessage','reasoningStarted','addContextItem','_showConversationHistory','removeFeedInteraction','addFeedItemAIReply','partIndex','rejected','ai-no-track-changes','15hYEsXx','selectedModel','clearConversationContextUI','howMany','applyOperation','ai-chat-conversation-not-found','undo','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_FILE','getRanges','_updateReplyContent','ai-chat-file-upload-failed','replyId','mapper','uid','options','AI_CHAT_RESOURCE_LOAD_FAILED','AI_BALLOON_HEADER_TITLE','full','abortPromptStream','commands','removeFromContext','updateConversationTitle','dialogClosed','setModel','revert','outdated','ai-chat-context-file-too-many-pages','locale','set','removeSelectionFromChatContext','listenTo','AIConnector','ai-chat-source-resources-load-failed','dislike','TrackChangesEditing','_aiConnector','interactionId','resetConversationTitle'];_0x5e7c=function(){return _0x4f704d;};return _0x5e7c();}export class AIChatController extends _0x5d6eb1{[_0x380a5b(0x29b)];[_0x380a5b(0x20b)];[_0x380a5b(0x24e)];[_0x380a5b(0x2cd)];[_0x380a5b(0x20e)]=new Map();[_0x380a5b(0x2e5)]=null;[_0x380a5b(0x25a)]=!0x1;[_0x380a5b(0x296)];static get[_0x380a5b(0x271)](){return[_0x3d8712,_0x24b349,_0x1fcfbc];}static get[_0x380a5b(0x186)](){const _0x1efe8b=_0x380a5b;return _0x1efe8b(0x1b5);}static get[_0x380a5b(0x1c9)](){return!0x0;}static get[_0x380a5b(0x263)](){return!0x0;}[_0x380a5b(0x190)](){const _0x4ff454=_0x380a5b;this[_0x4ff454(0x296)]=new _0x2e7136(this[_0x4ff454(0x248)][_0x4ff454(0x203)]),this[_0x4ff454(0x296)][_0x4ff454(0x24d)](),this[_0x4ff454(0x20b)]=this[_0x4ff454(0x248)][_0x4ff454(0x1ba)][_0x4ff454(0x255)](_0x4ff454(0x207)),this[_0x4ff454(0x24e)]=this[_0x4ff454(0x248)][_0x4ff454(0x1ba)][_0x4ff454(0x255)](_0x4ff454(0x216)),this[_0x4ff454(0x29b)]=this[_0x4ff454(0x248)][_0x4ff454(0x1ba)][_0x4ff454(0x255)](_0x4ff454(0x289)),this[_0x4ff454(0x2cd)]=new _0x36e4f1({'connector':this[_0x4ff454(0x20b)],'availableModels':this[_0x4ff454(0x248)][_0x4ff454(0x2bc)][_0x4ff454(0x255)](_0x4ff454(0x241)),'defaultModelId':this[_0x4ff454(0x248)][_0x4ff454(0x2bc)][_0x4ff454(0x255)](_0x4ff454(0x1d8)),'locale':this[_0x4ff454(0x248)][_0x4ff454(0x203)]});const _0x40603b=this[_0x4ff454(0x248)][_0x4ff454(0x1ba)][_0x4ff454(0x255)](_0x4ff454(0x22c));this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x290),()=>{const _0xeecb75=_0x4ff454;this[_0xeecb75(0x2ef)]();}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x286),(_0x25ee8f,_0x1000c4)=>{const _0x3c814c=_0x4ff454;this[_0x3c814c(0x23d)]({'userMessage':_0x1000c4});}),this[_0x4ff454(0x206)](_0x40603b,_0x4ff454(0x18b),(_0x1c6417,_0x3ecf2b)=>{const _0x5df022=_0x4ff454;this[_0x5df022(0x25d)](_0x3ecf2b);}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x1cc),()=>{const _0x4ab61e=_0x4ff454;_0x40603b[_0x4ab61e(0x2af)]();}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x1fa),async()=>{const _0x1f2f82=_0x4ff454;await this[_0x1f2f82(0x2c6)](),await this[_0x1f2f82(0x24b)](),this[_0x1f2f82(0x205)]();}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x1a7),()=>{const _0x132f8c=_0x4ff454;this[_0x132f8c(0x1ce)]?.[_0x132f8c(0x294)](_0x3c35c3(this[_0x132f8c(0x248)][_0x132f8c(0x203)],_0x132f8c(0x247)));}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x28d),(_0x5e8463,_0x34df28)=>{const _0x3dd0dd=_0x4ff454;this[_0x3dd0dd(0x1ce)]?.[_0x3dd0dd(0x2cf)](Array[_0x3dd0dd(0x1c7)](_0x34df28));}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x2a4),(_0xda9bb,_0xe6a369)=>{const _0x38a068=_0x4ff454;this[_0x38a068(0x1ce)]?.[_0x38a068(0x2a4)](_0xe6a369);}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x2cb),(_0x2fee23,_0x39946e)=>{const _0x823782=_0x4ff454;this[_0x823782(0x1ce)]?.[_0x823782(0x2cb)](_0x39946e[_0x823782(0x185)],_0x39946e[_0x823782(0x231)]);}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x2c9),(_0x53b420,_0x3edb38)=>{const _0x53007a=_0x4ff454;this[_0x53007a(0x1bd)](_0x3edb38);}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x18d),(_0x3e5437,_0x20f586)=>{const _0x34f0e2=_0x4ff454;this[_0x34f0e2(0x1ce)]?.[_0x34f0e2(0x18d)](_0x20f586[_0x34f0e2(0x193)],_0x20f586[_0x34f0e2(0x264)],_0x20f586[_0x34f0e2(0x1f5)]);}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x24f),()=>{const _0x375128=_0x4ff454;this[_0x375128(0x1ac)]();}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x2b9),()=>{const _0x46a6c2=_0x4ff454;this[_0x46a6c2(0x27b)]();}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x2b2),(_0x1b91d,_0x116394)=>{const _0x1c0605=_0x4ff454;this[_0x1c0605(0x1ce)]?.[_0x1c0605(0x1ff)](_0x116394);}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x224),(_0x5e9c0c,{replyId:_0xa4fdc7})=>{const _0x405f2f=_0x4ff454;console[_0x405f2f(0x253)](_0x405f2f(0x2ed),_0xa4fdc7);}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x209),(_0xceedbf,{replyId:_0x110315})=>{const _0x5d6145=_0x4ff454;console[_0x5d6145(0x253)](_0x5d6145(0x2c3),_0x110315);}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x2ac),(_0x4e15ff,_0x48e4cc)=>{const _0x534464=_0x4ff454;this[_0x534464(0x248)][_0x534464(0x1ba)][_0x534464(0x255)](_0x24b349)[_0x534464(0x28c)](),this[_0x534464(0x23f)](_0x48e4cc);}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x270),(_0x33c772,{replyId:_0x11426c,partIndex:_0x3a81c2})=>{const _0x1dbe46=_0x4ff454;this[_0x1dbe46(0x25a)]=this[_0x1dbe46(0x24e)][_0x1dbe46(0x1ca)],this[_0x1dbe46(0x237)](_0x11426c,_0x3a81c2);}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x1c6),(_0x5d3eb4,{replyId:_0xc8d3f6,partIndex:_0xa79564})=>{const _0x4164dc=_0x4ff454,_0x5b09dd=this[_0x4164dc(0x1a6)](_0xc8d3f6,_0xa79564);_0x5b09dd&&_0x4164dc(0x292)!=_0x5b09dd[_0x4164dc(0x25b)][_0x4164dc(0x2c4)][_0x4164dc(0x26c)]&&this[_0x4164dc(0x29b)][_0x4164dc(0x217)]([_0x5b09dd[_0x4164dc(0x25b)]],_0x4164dc(0x28e));}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x19f),()=>{const _0x19ba33=_0x4ff454;this[_0x19ba33(0x29b)][_0x19ba33(0x191)](_0x19ba33(0x28e));}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x19c),(_0xe1e7ca,_0x22ef90)=>{const _0x57b6a5=_0x4ff454;this[_0x57b6a5(0x248)][_0x57b6a5(0x1ba)][_0x57b6a5(0x255)](_0x24b349)[_0x57b6a5(0x28c)](),this[_0x57b6a5(0x181)](_0x22ef90);}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x2a7),async(_0x495244,{replyId:_0x36f26c,showDiff:_0xaddf03})=>{const _0x30ad45=_0x4ff454,{reply:_0x18ff86}=this[_0x30ad45(0x2b6)](_0x36f26c),_0x4155e4=_0x18ff86[_0x30ad45(0x22a)]({'showDiff':_0xaddf03});await this[_0x30ad45(0x24e)][_0x30ad45(0x26e)]({'id':_0x18ff86['id'],'parts':_0x4155e4,'renderingStrategy':_0x30ad45(0x2bb)});}),this[_0x4ff454(0x206)](this[_0x4ff454(0x24e)],_0x4ff454(0x244),(_0x1c707b,{replyId:_0x3596a5,partIndex:_0x2ae9cf})=>{const _0x57e2a1=_0x4ff454;this[_0x57e2a1(0x2e5)]?.[_0x57e2a1(0x1f3)]==_0x3596a5&&this[_0x57e2a1(0x2e5)]?.[_0x57e2a1(0x1e5)]==_0x2ae9cf&&this[_0x57e2a1(0x248)][_0x57e2a1(0x1ba)][_0x57e2a1(0x255)](_0x24b349)[_0x57e2a1(0x28c)]();const {reply:_0x1d0aea}=this[_0x57e2a1(0x2b6)](_0x3596a5);_0x1d0aea[_0x57e2a1(0x1a1)](_0x2ae9cf,_0x57e2a1(0x1e6)),this[_0x57e2a1(0x29b)][_0x57e2a1(0x191)](_0x57e2a1(0x28e));});}async[_0x380a5b(0x23e)](){const _0x1bcd19=_0x380a5b;this[_0x1bcd19(0x248)]instanceof _0x268d61?this[_0x1bcd19(0x267)](this[_0x1bcd19(0x248)]):this[_0x1bcd19(0x206)](this[_0x1bcd19(0x248)][_0x1bcd19(0x2d6)],_0x1bcd19(0x254),(_0x220f7a,_0x5b9509)=>{const _0x349c4e=_0x1bcd19;_0x5b9509['on'](_0x349c4e(0x1d1),()=>{const _0x3da119=_0x349c4e;this[_0x3da119(0x267)](_0x5b9509);});}),await this[_0x1bcd19(0x2ef)]();}[_0x380a5b(0x1c0)](){const _0x465172=_0x380a5b;this[_0x465172(0x296)][_0x465172(0x1b3)](),super[_0x465172(0x1c0)]();}[_0x380a5b(0x23f)](_0x4bafc6){const _0x12d13c=_0x380a5b,_0x5c4b63=_0x260be3(this[_0x12d13c(0x248)]);if(!_0x5c4b63[_0x12d13c(0x1ba)][_0x12d13c(0x1bb)](_0x12d13c(0x257)))throw new _0xb8924f(_0x12d13c(0x1e7),null);const _0x4ba7ee=this[_0x12d13c(0x248)][_0x12d13c(0x1ba)][_0x12d13c(0x255)](_0x12d13c(0x192)),{reply:_0x9ce45a,interaction:_0x565792}=this[_0x12d13c(0x2b6)](_0x4bafc6[_0x12d13c(0x1f3)]),_0x5b6c31=this[_0x12d13c(0x1a6)](_0x4bafc6[_0x12d13c(0x1f3)],_0x4bafc6[_0x12d13c(0x1e5)]),_0x1cc014=void 0x0!==_0x4bafc6[_0x12d13c(0x1e5)]?[_0x9ce45a[_0x12d13c(0x2bd)][_0x4bafc6[_0x12d13c(0x1e5)]]]:_0x9ce45a[_0x12d13c(0x2bd)][_0x12d13c(0x297)](_0x5de9d9=>_0x12d13c(0x249)==_0x5de9d9[_0x12d13c(0x182)]),_0x151aee=_0x1cc014[_0x12d13c(0x29f)](_0x3c41f3=>_0x9ce45a[_0x12d13c(0x2bd)][_0x12d13c(0x26d)](_0x3c41f3));if(!_0x5b6c31||_0x12d13c(0x292)==_0x5b6c31[_0x12d13c(0x25b)][_0x12d13c(0x2c4)][_0x12d13c(0x26c)])return void _0x151aee[_0x12d13c(0x2e4)](_0x347c86=>_0x9ce45a[_0x12d13c(0x1a1)](_0x347c86,_0x12d13c(0x201)));_0x151aee[_0x12d13c(0x2e4)](_0x3e26bf=>_0x9ce45a[_0x12d13c(0x1a1)](_0x3e26bf,_0x12d13c(0x184)));const _0x2990f6=_0x2556e1({'editor':_0x5c4b63,'reply':_0x9ce45a,'interaction':_0x565792,'groups':_0x1cc014,'transform':!0x0,'documentCompare':_0x4ba7ee,'documentCompareOptions':{'anchor':_0x12d13c(0x2dc),'markDeletions':!0x0}});let _0x6a7004;_0x5b6c31&&this[_0x12d13c(0x226)](_0x5b6c31[_0x12d13c(0x25b)]),_0x5c4b63[_0x12d13c(0x18a)][_0x12d13c(0x1b6)](_0x2ea6b7=>{const _0x1ea2cb=_0x12d13c;_0x6a7004=_0x2ea6b7[_0x1ea2cb(0x221)],_0x5c4b63[_0x1ea2cb(0x1ba)][_0x1ea2cb(0x255)](_0x1ea2cb(0x20a))[_0x1ea2cb(0x1ab)](_0x2990f6),this[_0x1ea2cb(0x29b)][_0x1ea2cb(0x191)](_0x1ea2cb(0x28e));}),this[_0x12d13c(0x20e)][_0x12d13c(0x204)](_0x6a7004,{'interactionId':_0x565792['id'],'replyId':_0x9ce45a['id'],'indexes':_0x151aee[_0x12d13c(0x285)]()}),this[_0x12d13c(0x280)](_0x9ce45a);}[_0x380a5b(0x181)](_0x173ff6){const _0x19d8b5=_0x380a5b,_0x53e34a=_0x260be3(this[_0x19d8b5(0x248)]),_0x5277c3=this[_0x19d8b5(0x248)][_0x19d8b5(0x1ba)][_0x19d8b5(0x255)](_0x1fcfbc),{reply:_0x123f54,interaction:_0x43ab94}=this[_0x19d8b5(0x2b6)](_0x173ff6[_0x19d8b5(0x1f3)]),_0x17edbe=this[_0x19d8b5(0x1a6)](_0x173ff6[_0x19d8b5(0x1f3)],_0x173ff6[_0x19d8b5(0x1e5)]),_0x1e06c5=void 0x0!==_0x173ff6[_0x19d8b5(0x1e5)]?[_0x123f54[_0x19d8b5(0x2bd)][_0x173ff6[_0x19d8b5(0x1e5)]]]:_0x123f54[_0x19d8b5(0x2bd)][_0x19d8b5(0x297)](_0x3d318c=>_0x19d8b5(0x249)==_0x3d318c[_0x19d8b5(0x182)]),_0x2aa56e=_0x1e06c5[_0x19d8b5(0x29f)](_0x40296b=>_0x123f54[_0x19d8b5(0x2bd)][_0x19d8b5(0x26d)](_0x40296b));if(!_0x17edbe||_0x19d8b5(0x292)==_0x17edbe[_0x19d8b5(0x25b)][_0x19d8b5(0x2c4)][_0x19d8b5(0x26c)])return void _0x2aa56e[_0x19d8b5(0x2e4)](_0x5ed2ab=>_0x123f54[_0x19d8b5(0x1a1)](_0x5ed2ab,_0x19d8b5(0x201)));_0x2aa56e[_0x19d8b5(0x2e4)](_0x3554e4=>_0x123f54[_0x19d8b5(0x1a1)](_0x3554e4,_0x19d8b5(0x184)));const _0x116480=_0x2556e1({'editor':_0x53e34a,'reply':_0x123f54,'interaction':_0x43ab94,'groups':_0x1e06c5,'transform':!0x0,'documentCompare':_0x5277c3,'documentCompareOptions':{'anchor':_0x19d8b5(0x2dc),'markDeletions':!0x1}});let _0x3cb626;_0x17edbe&&this[_0x19d8b5(0x226)](_0x17edbe[_0x19d8b5(0x25b)]),_0x53e34a[_0x19d8b5(0x18a)][_0x19d8b5(0x1b6)](_0x14d638=>{const _0x47d883=_0x19d8b5;_0x3cb626=_0x14d638[_0x47d883(0x221)];for(const _0x3524ca of _0x116480)_0x3524ca[_0x47d883(0x288)]=_0x53e34a[_0x47d883(0x18a)][_0x47d883(0x2e9)][_0x47d883(0x2a2)],_0xec59ff(_0x53e34a,_0x3524ca),_0x14d638[_0x47d883(0x221)][_0x47d883(0x234)](_0x3524ca),_0x53e34a[_0x47d883(0x18a)][_0x47d883(0x1ec)](_0x3524ca);}),this[_0x19d8b5(0x20e)][_0x19d8b5(0x204)](_0x3cb626,{'interactionId':_0x43ab94['id'],'replyId':_0x123f54['id'],'indexes':_0x2aa56e[_0x19d8b5(0x285)]()}),this[_0x19d8b5(0x280)](_0x123f54);}[_0x380a5b(0x237)](_0x5a6908,_0x1b594a){const _0x1ad5c0=_0x380a5b,_0x24e3d7=_0x260be3(this[_0x1ad5c0(0x248)]),_0x1fdbc2=this[_0x1ad5c0(0x1a6)](_0x5a6908,_0x1b594a),_0x46152a=this[_0x1ad5c0(0x248)][_0x1ad5c0(0x1ba)][_0x1ad5c0(0x255)](_0x24b349);if(!_0x1fdbc2)return void _0x46152a[_0x1ad5c0(0x28c)]();const {range:_0x4ca1dd,currentIndex:_0x24ae19}=_0x1fdbc2;if(_0x1ad5c0(0x292)==_0x4ca1dd[_0x1ad5c0(0x2c4)][_0x1ad5c0(0x26c)]){const {reply:_0x224f53}=this[_0x1ad5c0(0x2b6)](_0x5a6908);return _0x224f53[_0x1ad5c0(0x1a1)](_0x24ae19,_0x1ad5c0(0x201)),void _0x46152a[_0x1ad5c0(0x28c)]();}if(this[_0x1ad5c0(0x2e5)]?.[_0x1ad5c0(0x1f3)]==_0x5a6908&&this[_0x1ad5c0(0x2e5)]?.[_0x1ad5c0(0x1e5)]==_0x24ae19)return;this[_0x1ad5c0(0x1cd)](_0x46152a),this[_0x1ad5c0(0x2e5)]={'replyId':_0x5a6908,'partIndex':_0x24ae19};let _0x5cdedf=_0x24e3d7[_0x1ad5c0(0x2bc)][_0x1ad5c0(0x255)](_0x1ad5c0(0x2c1))||[..._0x37616d];_0x24e3d7[_0x1ad5c0(0x1ba)][_0x1ad5c0(0x1bb)](_0x1ad5c0(0x257))||(_0x5cdedf=_0x5cdedf[_0x1ad5c0(0x297)](_0x4d7648=>_0x1ad5c0(0x2ac)!=_0x4d7648));const _0x1d92b6=new _0x52a448(_0x24e3d7[_0x1ad5c0(0x203)],{'showDiff':this[_0x1ad5c0(0x25a)],'areActionsDisabled':!0x1,'miniToolbarConfig':{'showChanges':_0x1ad5c0(0x1f9)},'hideHeader':!0x0,'availableActions':_0x5cdedf},this[_0x1ad5c0(0x296)]);this[_0x1ad5c0(0x1cd)](_0x1d92b6);const {reply:_0x467a7c}=this[_0x1ad5c0(0x2b6)](_0x5a6908),_0x19b6d7=_0x467a7c[_0x1ad5c0(0x22a)]({'showDiff':this[_0x1ad5c0(0x25a)]})[_0x1ad5c0(0x297)](_0x3203db=>_0x3203db[_0x1ad5c0(0x189)]),_0x67bf50=_0x19b6d7[_0x1ad5c0(0x236)](_0x5ab349=>_0x5ab349[_0x1ad5c0(0x2e6)]==_0x24ae19);if(-0x1==_0x67bf50)return;const _0x528030=_0x19b6d7[_0x67bf50],_0x213030=_0x19b6d7['at']((_0x67bf50-0x1)%_0x19b6d7[_0x1ad5c0(0x28a)])?.[_0x1ad5c0(0x2e6)],_0x21aff0=_0x19b6d7['at']((_0x67bf50+0x1)%_0x19b6d7[_0x1ad5c0(0x28a)])?.[_0x1ad5c0(0x2e6)];_0x1d92b6[_0x1ad5c0(0x24c)]({'parts':[_0x528030],'renderingStrategy':_0x1ad5c0(0x2bb)});const _0x39cd71=_0x24ae19!==_0x213030;this[_0x1ad5c0(0x226)](_0x4ca1dd,!0x0),_0x46152a[_0x1ad5c0(0x2d9)]({'index':_0x24ae19,'title':_0x3c35c3(this[_0x1ad5c0(0x248)][_0x1ad5c0(0x203)],_0x1ad5c0(0x1f8),(_0x67bf50+0x1)[_0x1ad5c0(0x23a)]()),'icon':_0x15e824,'mainView':_0x1d92b6,'showRotator':_0x39cd71,'showApplyButton':!0x0,'showSuggestButton':_0x24e3d7[_0x1ad5c0(0x1ba)][_0x1ad5c0(0x1bb)](_0x1ad5c0(0x257)),'ranges':[_0x4ca1dd]}),this[_0x1ad5c0(0x24e)][_0x1ad5c0(0x1d2)](_0x5a6908,_0x24ae19),this[_0x1ad5c0(0x206)](_0x1d92b6,_0x1ad5c0(0x2a7),(_0x5b4fb9,{showDiff:_0x4ae9d9})=>{const _0xf55f0f=_0x1ad5c0;this[_0xf55f0f(0x25a)]=_0x4ae9d9;const {reply:_0x494b75}=this[_0xf55f0f(0x2b6)](_0x5a6908),_0xbddcf7=_0x494b75[_0xf55f0f(0x22a)]({'showDiff':_0x4ae9d9,'groupIndex':_0x24ae19});_0x1d92b6[_0xf55f0f(0x24c)]({'parts':_0xbddcf7,'renderingStrategy':_0xf55f0f(0x2bb)});}),this[_0x1ad5c0(0x206)](_0x46152a,_0x1ad5c0(0x19c),()=>{const _0xea5852=_0x1ad5c0;this[_0xea5852(0x181)]({'replyId':_0x5a6908,'partIndex':_0x24ae19}),_0x39cd71?this[_0xea5852(0x237)](_0x5a6908,_0x21aff0):_0x46152a[_0xea5852(0x28c)]();}),this[_0x1ad5c0(0x206)](_0x46152a,_0x1ad5c0(0x2ac),()=>{const _0x57bb39=_0x1ad5c0;this[_0x57bb39(0x23f)]({'replyId':_0x5a6908,'partIndex':_0x24ae19}),_0x39cd71?this[_0x57bb39(0x237)](_0x5a6908,_0x21aff0):_0x46152a[_0x57bb39(0x28c)]();}),_0x39cd71&&(this[_0x1ad5c0(0x206)](_0x46152a,_0x1ad5c0(0x1b9),()=>{const _0x357adb=_0x1ad5c0;this[_0x357adb(0x237)](_0x5a6908,_0x21aff0);}),this[_0x1ad5c0(0x206)](_0x46152a,_0x1ad5c0(0x188),()=>{const _0x1a24e5=_0x1ad5c0;this[_0x1a24e5(0x237)](_0x5a6908,_0x213030);})),this[_0x1ad5c0(0x206)](_0x46152a,_0x1ad5c0(0x1fe),()=>{const _0x5dff68=_0x1ad5c0;this[_0x5dff68(0x1cd)](_0x46152a),this[_0x5dff68(0x1cd)](_0x1d92b6),this[_0x5dff68(0x2e5)]=null;});}[_0x380a5b(0x1a6)](_0x3e5c1a,_0x2ee292){const _0x485b7a=_0x380a5b,_0x4ee51d=_0x260be3(this[_0x485b7a(0x248)]),{reply:_0xb39533,interaction:_0x44f1e2}=this[_0x485b7a(0x2b6)](_0x3e5c1a),_0x1b0da2=_0xb39533[_0x485b7a(0x2bd)][_0x485b7a(0x297)](_0x17e6e2=>_0x485b7a(0x249)==_0x17e6e2[_0x485b7a(0x182)]),_0x487081=_0x1b0da2[_0x485b7a(0x29f)](_0x28dbfe=>_0xb39533[_0x485b7a(0x2bd)][_0x485b7a(0x26d)](_0x28dbfe));void 0x0===_0x2ee292&&(_0x2ee292=_0x487081[0x0]);const _0x1000f4=_0x487081[_0x485b7a(0x26d)](_0x2ee292);if(-0x1==_0x1000f4)return null;const _0x4bd086=_0x1b0da2[_0x1000f4],_0x37ab71=new _0x554c05([]),_0xf6c0ca=new _0x554c05([]);for(const _0x2100a2 of _0x4bd086[_0x485b7a(0x28b)])if(_0x485b7a(0x2e1)!=_0x2100a2[_0x485b7a(0x279)]&&_0xf6c0ca[_0x485b7a(0x2cc)][_0x485b7a(0x298)](_0x2100a2[_0x485b7a(0x287)][_0x485b7a(0x1bf)](!0x0)),_0x485b7a(0x281)!=_0x2100a2[_0x485b7a(0x279)]){const _0x5df56d=_0x3ca4fe(_0x13c14b=>_0x2a6712(_0x13c14b,_0x485b7a(0x1a3))==_0x2100a2['id'],_0xb39533[_0x485b7a(0x197)],!0x0);_0x37ab71[_0x485b7a(0x2cc)][_0x485b7a(0x298)](_0x5df56d[_0x485b7a(0x1bf)](!0x0));}if(0x0==_0x37ab71[_0x485b7a(0x2cc)][_0x485b7a(0x28a)]){if(_0x4bd086[_0x485b7a(0x28b)][0x0][_0x485b7a(0x17f)]){const _0x2e82b4=_0x48bf17(_0x485b7a(0x1a3),_0x4bd086[_0x485b7a(0x28b)][0x0][_0x485b7a(0x17f)],_0xb39533[_0x485b7a(0x197)]);_0x37ab71[_0x485b7a(0x2cc)][_0x485b7a(0x2d3)](_0x2e82b4[_0x485b7a(0x1bf)](!0x0)),_0xf6c0ca[_0x485b7a(0x2cc)][_0x485b7a(0x2d3)](_0x2e82b4[_0x485b7a(0x1bf)](!0x0)),_0x2e82b4[_0x485b7a(0x230)]&&(_0x37ab71[_0x485b7a(0x2cc)][_0x485b7a(0x298)](_0x2e82b4[_0x485b7a(0x230)][_0x485b7a(0x1bf)](!0x0)),_0xf6c0ca[_0x485b7a(0x2cc)][_0x485b7a(0x298)](_0x2e82b4[_0x485b7a(0x230)][_0x485b7a(0x1bf)](!0x0)));}else{const _0x3e99cc=_0xb39533[_0x485b7a(0x197)][_0x485b7a(0x2cc)][0x0];if(!_0x3e99cc)return null;_0x37ab71[_0x485b7a(0x2cc)][_0x485b7a(0x298)](_0x3e99cc[_0x485b7a(0x1bf)](!0x0)),_0xf6c0ca[_0x485b7a(0x2cc)][_0x485b7a(0x298)](_0x3e99cc[_0x485b7a(0x1bf)](!0x0));}}const _0x54eeda=_0x44f1e2[_0x485b7a(0x23c)](),_0x19cc12=_0x4ee51d[_0x485b7a(0x1c1)][_0x485b7a(0x1d5)](_0x54eeda[_0x485b7a(0x2c7)],_0x485b7a(0x2d2)),_0x114398=_0x3acb67(_0x37ab71),_0x524754=_0x4ee51d[_0x485b7a(0x1c1)][_0x485b7a(0x1d5)](_0x114398),_0x1a0651=_0x4ee51d[_0x485b7a(0x1c1)][_0x485b7a(0x1d5)](_0x114398),_0x94382=_0x4ee51d[_0x485b7a(0x18a)][_0x485b7a(0x228)](_0x524754,0x0),_0x3d0b68=_0x3acb67(_0xf6c0ca),_0x4e9559={'anchor':_0x94382,'markDeletions':!0x1,'context':_0x485b7a(0x2d2)},_0x2d69b8=_0x4ee51d[_0x485b7a(0x1ba)][_0x485b7a(0x255)](_0x1fcfbc)[_0x485b7a(0x196)](_0x114398,_0x3d0b68,_0x4e9559)[_0x485b7a(0x284)]();if(!_0x2d69b8[_0x485b7a(0x28a)])return null;_0x4ee51d[_0x485b7a(0x18a)][_0x485b7a(0x1b6)](_0x3c3f06=>{const _0x286bd4=_0x485b7a;for(const _0x220271 of _0x2d69b8)if(_0x286bd4(0x278)==_0x220271[_0x286bd4(0x279)]){const _0xe9435a=_0x220271[_0x286bd4(0x1cb)],_0x2e21ba=_0x220271[_0x286bd4(0x1eb)],_0xc0270=new _0x4d8793(_0xe9435a,_0x2e21ba);_0x3c3f06[_0x286bd4(0x221)][_0x286bd4(0x234)](_0xc0270),_0x4ee51d[_0x286bd4(0x18a)][_0x286bd4(0x1ec)](_0xc0270);}else _0x286bd4(0x2a8)!==_0x220271[_0x286bd4(0x279)]&&(_0x220271[_0x286bd4(0x288)]=null,_0x220271[_0x286bd4(0x1a2)]=!0x1,_0x3c3f06[_0x286bd4(0x221)][_0x286bd4(0x234)](_0x220271),_0x4ee51d[_0x286bd4(0x18a)][_0x286bd4(0x1ec)](_0x220271));});const _0x1901a5=_0x4ab0b5(_0x4ee51d,_0x2d69b8,_0x524754);_0x42ac67(_0x4ee51d[_0x485b7a(0x18a)],_0x1901a5);const _0x5d1c1f=_0x1901a5[_0x485b7a(0x2a6)]()[_0x485b7a(0x21c)][_0x485b7a(0x2df)][_0x485b7a(0x285)](),_0x124619=_0x1901a5[_0x485b7a(0x2a6)]()[_0x485b7a(0x1a8)][_0x485b7a(0x2df)][_0x485b7a(0x285)](),_0x4366d0=[];let _0x3372f0=_0x524754,_0x5be970=_0x1a0651;for(let _0x37459b=0x0;_0x37459b<_0x124619[_0x485b7a(0x28a)];_0x37459b++){const _0xf23949=_0x3372f0[_0x485b7a(0x268)]-_0x124619[_0x37459b];_0x4366d0[_0x37459b]=_0x5be970[_0x485b7a(0x268)]-_0xf23949,_0x3372f0=_0x3372f0[_0x485b7a(0x1c3)](_0x124619[_0x37459b]),_0x5be970=_0x5be970[_0x485b7a(0x1c3)](_0x4366d0[_0x37459b]);}const _0xed5392=_0x4ee51d[_0x485b7a(0x18a)][_0x485b7a(0x2a9)](_0x4ee51d[_0x485b7a(0x18a)][_0x485b7a(0x1d6)](_0x1a0651,_0x5d1c1f),_0x4ee51d[_0x485b7a(0x18a)][_0x485b7a(0x1d6)](_0x1a0651,_0x4366d0)),_0xbb733f=_0x1a0651[_0x485b7a(0x2ad)](0x0)[_0x485b7a(0x299)](_0x54cb6e),_0x49e760=Array[_0x485b7a(0x1c7)](_0x19cc12[_0x485b7a(0x25f)]())[_0x485b7a(0x2b3)](_0x16cb60=>_0x16cb60[_0x485b7a(0x299)](_0x54cb6e)==_0xbb733f)[_0x485b7a(0x2ce)](),_0x468b9d=_0xed5392[_0x485b7a(0x21c)][_0x485b7a(0x2df)][_0x485b7a(0x285)](),_0x13f54e=_0xed5392[_0x485b7a(0x1a8)][_0x485b7a(0x2df)][_0x485b7a(0x285)]();_0x468b9d[0x0]=_0x49e760[0x0]+_0x468b9d[0x0],_0x13f54e[0x0]=_0x49e760[0x0]+_0x13f54e[0x0];let _0x5b0b49=_0x4ee51d[_0x485b7a(0x18a)][_0x485b7a(0x2a9)](_0x4ee51d[_0x485b7a(0x18a)][_0x485b7a(0x1d6)](_0x4ee51d[_0x485b7a(0x18a)][_0x485b7a(0x2e9)][_0x485b7a(0x1bc)](),_0x468b9d),_0x4ee51d[_0x485b7a(0x18a)][_0x485b7a(0x1d6)](_0x4ee51d[_0x485b7a(0x18a)][_0x485b7a(0x2e9)][_0x485b7a(0x1bc)](),_0x13f54e));const _0x5583f9=_0x4ee51d[_0x485b7a(0x18a)][_0x485b7a(0x2e9)][_0x485b7a(0x2a0)][_0x485b7a(0x284)](_0x54eeda[_0x485b7a(0x2a2)]);for(const _0x3d56f0 of _0x5583f9)_0x5b0b49=_0x30994b[_0x485b7a(0x1d3)](_0x5b0b49[_0x485b7a(0x2e8)](_0x3d56f0));return{'range':_0x5b0b49,'currentIndex':_0x2ee292};}[_0x380a5b(0x267)](_0x87e0c1){const _0x5d2670=_0x380a5b;if(!_0x87e0c1[_0x5d2670(0x1ba)][_0x5d2670(0x1bb)](_0x5d2670(0x2d5)))return;const _0x51ef1f=_0x87e0c1[_0x5d2670(0x1fb)][_0x5d2670(0x255)](_0x5d2670(0x1ee)),_0x532db5=_0x87e0c1[_0x5d2670(0x1fb)][_0x5d2670(0x255)](_0x5d2670(0x251));this[_0x5d2670(0x206)](_0x51ef1f,_0x5d2670(0x200),(_0x433fcf,_0x3eeb30,_0xfe39b2)=>{const _0xa271d2=_0x5d2670,_0x3178dc=this[_0xa271d2(0x20e)][_0xa271d2(0x255)](_0x3eeb30);if(!_0x3178dc)return;const _0x363cef=this[_0xa271d2(0x1ce)][_0xa271d2(0x1da)](_0x3178dc[_0xa271d2(0x20c)])[_0xa271d2(0x19e)](_0x3178dc[_0xa271d2(0x1f3)]);_0x3178dc[_0xa271d2(0x1ad)][_0xa271d2(0x2e4)](_0x579665=>_0x363cef[_0xa271d2(0x1a1)](_0x579665,_0xa271d2(0x249))),this[_0xa271d2(0x20e)][_0xa271d2(0x2ec)](_0x3eeb30),this[_0xa271d2(0x20e)][_0xa271d2(0x204)](_0xfe39b2,_0x3178dc);}),this[_0x5d2670(0x206)](_0x532db5,_0x5d2670(0x200),(_0x55cba4,_0x26a79c,_0x4285aa)=>{const _0x1dde81=_0x5d2670,_0xe08681=this[_0x1dde81(0x20e)][_0x1dde81(0x255)](_0x26a79c);if(!_0xe08681)return;const _0x373413=this[_0x1dde81(0x1ce)][_0x1dde81(0x1da)](_0xe08681[_0x1dde81(0x20c)])[_0x1dde81(0x19e)](_0xe08681[_0x1dde81(0x1f3)]);_0xe08681[_0x1dde81(0x1ad)][_0x1dde81(0x2e4)](_0x4f4402=>_0x373413[_0x1dde81(0x1a1)](_0x4f4402,_0x1dde81(0x184))),this[_0x1dde81(0x20e)][_0x1dde81(0x2ec)](_0x26a79c),this[_0x1dde81(0x20e)][_0x1dde81(0x204)](_0x4285aa,_0xe08681);});}async[_0x380a5b(0x29c)](_0x1d5b1e){const _0x50a81d=_0x380a5b;this[_0x50a81d(0x248)][_0x50a81d(0x1ba)][_0x50a81d(0x255)](_0x24b349)[_0x50a81d(0x28c)](),this[_0x50a81d(0x24e)][_0x50a81d(0x2ab)](_0x50a81d(0x2bb)),this[_0x50a81d(0x24e)][_0x50a81d(0x2e2)](!0x0),await this[_0x50a81d(0x2c6)]();try{await this[_0x50a81d(0x20b)][_0x50a81d(0x1be)](_0x1d5b1e)[_0x50a81d(0x269)](),await this[_0x50a81d(0x2ef)](_0x1d5b1e),this[_0x50a81d(0x1fd)]('\x20');const {sessionId:_0x967187}=this[_0x50a81d(0x29b)][_0x50a81d(0x1b2)]();await this[_0x50a81d(0x1ce)][_0x50a81d(0x2aa)](_0x1d5b1e,_0x967187),this[_0x50a81d(0x1ce)][_0x50a81d(0x18f)]()&&this[_0x50a81d(0x1ce)][_0x50a81d(0x294)](_0x3c35c3(this[_0x50a81d(0x248)][_0x50a81d(0x203)],_0x50a81d(0x247)));}catch(_0x35e162){this[_0x50a81d(0x24e)][_0x50a81d(0x22f)]({'errorMessage':_0x3c35c3(this[_0x50a81d(0x248)][_0x50a81d(0x203)],_0x50a81d(0x238)),'id':_0x1d5b1e}),this[_0x50a81d(0x210)](new _0xb8924f(_0x50a81d(0x1ed),this,{'error':_0x35e162}));}finally{this[_0x50a81d(0x248)][_0x50a81d(0x1ba)][_0x50a81d(0x255)](_0x29b001)[_0x50a81d(0x2b5)][_0x50a81d(0x2d0)](_0x50a81d(0x27c)),this[_0x50a81d(0x24e)][_0x50a81d(0x19b)](),this[_0x50a81d(0x24e)][_0x50a81d(0x2ab)](_0x50a81d(0x2b4)),this[_0x50a81d(0x24e)][_0x50a81d(0x2e2)](!0x1);}}[_0x380a5b(0x2d7)](_0x38d68a){const _0xafaca1=_0x380a5b;this[_0xafaca1(0x1ce)]['id']===_0x38d68a&&this[_0xafaca1(0x2ef)]();}async[_0x380a5b(0x2c2)](){const _0x69716d=_0x380a5b,_0x111fca=this[_0x69716d(0x29b)][_0x69716d(0x1c4)]();this[_0x69716d(0x1ce)]?.[_0x69716d(0x20f)](_0x111fca),this[_0x69716d(0x1ce)]?.[_0x69716d(0x294)](_0x3c35c3(this[_0x69716d(0x248)][_0x69716d(0x203)],_0x69716d(0x247)));}[_0x380a5b(0x205)](){const _0x32d70e=_0x380a5b;this[_0x32d70e(0x1ce)]?.[_0x32d70e(0x243)]();}[_0x380a5b(0x295)](){const _0x5cd3c2=_0x380a5b;this[_0x5cd3c2(0x24e)][_0x5cd3c2(0x295)]();}async[_0x380a5b(0x290)](){const _0x31dde5=_0x380a5b;await this[_0x31dde5(0x2ef)]();}async[_0x380a5b(0x1aa)]({message:_0x204e8f,quickActionData:_0x249aae}){const _0x32cc46=_0x380a5b;await this[_0x32cc46(0x23d)]({'userMessage':_0x204e8f,'quickActionData':_0x249aae});}[_0x380a5b(0x276)](){const _0x3695a6=_0x380a5b,_0x5e7825=this[_0x3695a6(0x248)][_0x3695a6(0x2bc)][_0x3695a6(0x255)](_0x3695a6(0x2b8));if(!_0x5e7825)throw new _0xb8924f(_0x3695a6(0x260),this);return _0x5e7825;}async[_0x380a5b(0x2ef)](_0x3cd0a1){const _0x10ea76=_0x380a5b;try{this[_0x10ea76(0x24e)][_0x10ea76(0x187)](),await this[_0x10ea76(0x21e)](_0x3cd0a1);}catch(_0x2acfa9){this[_0x10ea76(0x24e)][_0x10ea76(0x22f)]({'errorMessage':_0x3c35c3(this[_0x10ea76(0x248)][_0x10ea76(0x203)],_0x10ea76(0x180)),'id':_0x3cd0a1||_0x31c287()}),console[_0x10ea76(0x218)](_0x2acfa9),this[_0x10ea76(0x1ce)]=void 0x0,this[_0x10ea76(0x24e)][_0x10ea76(0x27e)]();}}async[_0x380a5b(0x21e)](_0x183999){const _0x4e7ada=_0x380a5b,_0x59e5d4=this[_0x4e7ada(0x248)][_0x4e7ada(0x1ba)][_0x4e7ada(0x255)](_0x24b349);let _0x3426e5;_0x59e5d4[_0x4e7ada(0x29d)]&&_0x59e5d4[_0x4e7ada(0x28c)](),_0x183999||!this[_0x4e7ada(0x1ce)]?_0x3426e5=this[_0x4e7ada(0x248)][_0x4e7ada(0x2bc)][_0x4e7ada(0x255)](_0x4e7ada(0x1d8)):this[_0x4e7ada(0x24e)][_0x4e7ada(0x2ee)]&&(_0x3426e5=this[_0x4e7ada(0x1ce)][_0x4e7ada(0x1e9)]['id']),await this[_0x4e7ada(0x2c6)]();const _0x23447a=this[_0x4e7ada(0x276)](),_0x39d277=_0x183999||_0x31c287();this[_0x4e7ada(0x1ce)]=new _0x49fb89({'connector':this[_0x4e7ada(0x20b)],'chatModels':this[_0x4e7ada(0x2cd)],'selectedModelId':_0x3426e5,'conversationId':_0x39d277,'group':_0x23447a,'getEditor':()=>_0x260be3(this[_0x4e7ada(0x248)])}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x26f),(_0x3581ca,_0x13cf41)=>{const _0x689cb8=_0x4e7ada;this[_0x689cb8(0x24e)][_0x689cb8(0x2ba)](_0x13cf41),this[_0x689cb8(0x24e)][_0x689cb8(0x1d4)](),this[_0x689cb8(0x24e)][_0x689cb8(0x22e)](),this[_0x689cb8(0x24e)][_0x689cb8(0x1ea)](),_0x183999||(this[_0x689cb8(0x24e)][_0x689cb8(0x20d)](),this[_0x689cb8(0x1ce)]?.[_0x689cb8(0x294)](_0x3c35c3(this[_0x689cb8(0x248)][_0x689cb8(0x203)],_0x689cb8(0x247))));}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x233),(_0x4b9247,_0x31b51d)=>{const _0x19f082=_0x4e7ada;this[_0x19f082(0x24e)][_0x19f082(0x23b)](_0x31b51d[_0x19f082(0x183)]);}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x213),(_0x115b2d,_0x1c4fbb)=>{const _0x444895=_0x4e7ada;this[_0x444895(0x24e)][_0x444895(0x1df)](_0x1c4fbb);}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x1dc),()=>{const _0x4a6b98=_0x4e7ada;this[_0x4a6b98(0x24e)][_0x4a6b98(0x21b)]({'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x1e0),()=>{const _0x19fb35=_0x4e7ada;this[_0x19fb35(0x24e)][_0x19fb35(0x21b)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x26b),(_0x3720df,_0x15b69c)=>{const _0x11d7f3=_0x4e7ada;this[_0x11d7f3(0x24e)][_0x11d7f3(0x291)](_0x15b69c,{'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x214),(_0x1d8abc,_0x5d3857)=>{const _0x126440=_0x4e7ada;this[_0x126440(0x24e)][_0x126440(0x291)](_0x5d3857,{'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x222),()=>{const _0x292e7a=_0x4e7ada;this[_0x292e7a(0x24e)][_0x292e7a(0x2de)]();}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x22d),async()=>{const _0x5ca0e6=_0x4e7ada;await this[_0x5ca0e6(0x24e)][_0x5ca0e6(0x266)]();}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x2c5),(_0x3a3873,_0x40e640)=>{const _0xd83900=_0x4e7ada;this[_0xd83900(0x24e)][_0xd83900(0x1e3)](_0x40e640['id']);}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x26a),(_0xfe3ee1,_0x20cc47,_0x401214)=>{const _0x4fa541=_0x4e7ada;this[_0x4fa541(0x1fd)](_0x20cc47,_0x401214);}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x229),(_0x325ff0,_0x51910d)=>{const _0x2433a8=_0x4e7ada;_0x2433a8(0x275)===_0x51910d[_0x2433a8(0x279)]?this[_0x2433a8(0x24e)][_0x2433a8(0x1e4)](_0x51910d):this[_0x2433a8(0x24e)][_0x2433a8(0x29a)](_0x51910d);}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x256),async(_0x1e831d,_0x3b020c)=>{const _0x13f2d2=_0x4e7ada;await this[_0x13f2d2(0x1f1)]({'reply':_0x3b020c});}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x1b7),(_0x2ce86d,{reply:_0x4596f8,index:_0x135c33,state:_0x23e30d})=>{const _0x1d5fcb=_0x4e7ada;this[_0x1d5fcb(0x24e)][_0x1d5fcb(0x2a3)]({'id':_0x4596f8['id'],'index':_0x135c33,'state':_0x23e30d});}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x220),(_0x5ed33f,_0x30e8c9)=>{const _0x2d43bb=_0x4e7ada;if(this[_0x2d43bb(0x24e)][_0x2d43bb(0x1e1)](_0x30e8c9[_0x2d43bb(0x2a5)],_0x30e8c9[_0x2d43bb(0x2dd)]),_0x2d43bb(0x261)===_0x30e8c9[_0x2d43bb(0x2a5)][_0x2d43bb(0x279)]){const _0x8c0de3=[..._0x260be3(this[_0x2d43bb(0x248)])[_0x2d43bb(0x18a)][_0x2d43bb(0x2e9)][_0x2d43bb(0x261)][_0x2d43bb(0x1f0)]()];this[_0x2d43bb(0x29b)][_0x2d43bb(0x217)](_0x8c0de3,_0x2d43bb(0x1d9)+this[_0x2d43bb(0x1ce)]?.['id']);}}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x265),(_0x416488,_0x25a038)=>{const _0x4ff678=_0x4e7ada;this[_0x4ff678(0x24e)][_0x4ff678(0x2c9)](_0x25a038[_0x4ff678(0x1c8)]),_0x4ff678(0x277)==_0x25a038[_0x4ff678(0x1c8)]&&this[_0x4ff678(0x205)](),_0x4ff678(0x261)===_0x25a038[_0x4ff678(0x279)]&&this[_0x4ff678(0x29b)][_0x4ff678(0x191)](_0x4ff678(0x1d9)+this[_0x4ff678(0x1ce)]?.['id']);}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x25c),(_0x522c44,_0x11451b)=>{const _0x4626db=_0x4e7ada;this[_0x4626db(0x24e)][_0x4626db(0x19a)](_0x11451b[_0x4626db(0x2a5)][_0x4626db(0x1c8)],_0x11451b[_0x4626db(0x2dd)]);}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x1db),(_0x222f6e,_0x3ccea4)=>{const _0x3d51c1=_0x4e7ada;this[_0x3d51c1(0x24e)][_0x3d51c1(0x1de)](_0x3ccea4[_0x3d51c1(0x2ea)]);}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x227),(_0x48708a,_0x2f9a4d)=>{const _0x561edc=_0x4e7ada;this[_0x561edc(0x24e)][_0x561edc(0x2db)](_0x2f9a4d[_0x561edc(0x1f6)]);}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x2ca),(_0xbd0981,_0x76b496)=>{const _0x5d4440=_0x4e7ada;this[_0x5d4440(0x24e)][_0x5d4440(0x2be)](_0x76b496[_0x5d4440(0x193)],_0x76b496[_0x5d4440(0x185)],_0x76b496[_0x5d4440(0x18c)],_0x76b496[_0x5d4440(0x1f5)]);}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x283),(_0x420d47,_0x389e06)=>{const _0x3cd2bc=_0x4e7ada;this[_0x3cd2bc(0x24e)][_0x3cd2bc(0x1b8)](_0x389e06[_0x3cd2bc(0x193)],_0x389e06[_0x3cd2bc(0x1d0)],_0x389e06[_0x3cd2bc(0x1a4)]);}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x2b7),(_0x1fd3c9,_0x580de5)=>{const _0x47d1db=_0x4e7ada;this[_0x47d1db(0x24e)][_0x47d1db(0x1dd)](_0x580de5);}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x2c0),(_0x50b41a,_0x58936d)=>{const _0x2d1814=_0x4e7ada;this[_0x2d1814(0x24e)][_0x2d1814(0x2eb)](_0x58936d[_0x2d1814(0x1e9)],_0x58936d[_0x2d1814(0x1af)]);}),this[_0x4e7ada(0x1ce)]['on'](_0x4e7ada(0x218),(_0x30c541,{error:_0x56d85e,interactionId:_0x53735f,fileName:_0x36c02d,url:_0x4df199,sourceId:_0x4dec1e,sourceLabel:_0x288a2d})=>{const _0x3e0480=_0x4e7ada,_0x266aba=_0x53735f?_0x53735f+':'+_0x31c287():_0x31c287();_0x56d85e[_0x3e0480(0x21d)][_0x3e0480(0x1b4)](_0x3e0480(0x215))?this[_0x3e0480(0x24e)][_0x3e0480(0x2d1)]({'staticMessage':_0x3c35c3(this[_0x3e0480(0x248)][_0x3e0480(0x203)],_0x3e0480(0x235)),'id':_0x266aba}):_0x56d85e[_0x3e0480(0x21d)][_0x3e0480(0x1b4)](_0x3e0480(0x274))||_0x56d85e[_0x3e0480(0x21d)][_0x3e0480(0x1b4)](_0x3e0480(0x246))?(this[_0x3e0480(0x24e)][_0x3e0480(0x22f)]({'errorMessage':_0x3c35c3(this[_0x3e0480(0x248)][_0x3e0480(0x203)],_0x3e0480(0x180)),'id':_0x266aba}),this[_0x3e0480(0x210)](_0x56d85e)):_0x56d85e[_0x3e0480(0x21d)][_0x3e0480(0x1b4)](_0x3e0480(0x1f2))?this[_0x3e0480(0x24e)][_0x3e0480(0x22f)]({'errorMessage':_0x3c35c3(this[_0x3e0480(0x248)][_0x3e0480(0x203)],_0x3e0480(0x1ef),_0x36c02d),'id':_0x266aba}):_0x56d85e[_0x3e0480(0x21d)][_0x3e0480(0x1b4)](_0x3e0480(0x2da))?this[_0x3e0480(0x24e)][_0x3e0480(0x22f)]({'errorMessage':_0x3c35c3(this[_0x3e0480(0x248)][_0x3e0480(0x203)],_0x3e0480(0x1d7),_0x4df199),'id':_0x266aba}):_0x56d85e[_0x3e0480(0x21d)][_0x3e0480(0x1b4)](_0x3e0480(0x223))?this[_0x3e0480(0x24e)][_0x3e0480(0x22f)]({'errorMessage':_0x3c35c3(this[_0x3e0480(0x248)][_0x3e0480(0x203)],_0x3e0480(0x232)),'id':_0x266aba}):_0x56d85e[_0x3e0480(0x21d)][_0x3e0480(0x1b4)](_0x3e0480(0x2d4))?this[_0x3e0480(0x24e)][_0x3e0480(0x22f)]({'errorMessage':_0x3c35c3(this[_0x3e0480(0x248)][_0x3e0480(0x203)],_0x3e0480(0x211)),'id':_0x266aba}):_0x56d85e[_0x3e0480(0x21d)][_0x3e0480(0x1b4)](_0x3e0480(0x208))?(_0x4dec1e&&this[_0x3e0480(0x24e)][_0x3e0480(0x25e)](_0x4dec1e),this[_0x3e0480(0x24e)][_0x3e0480(0x22f)]({'errorMessage':_0x3c35c3(this[_0x3e0480(0x248)][_0x3e0480(0x203)],_0x3e0480(0x2e3),_0x288a2d||_0x3e0480(0x185)),'id':_0x266aba}),this[_0x3e0480(0x210)](_0x56d85e)):_0x56d85e[_0x3e0480(0x21d)][_0x3e0480(0x1b4)](_0x3e0480(0x198))?(this[_0x3e0480(0x24e)][_0x3e0480(0x22f)]({'errorMessage':_0x3c35c3(this[_0x3e0480(0x248)][_0x3e0480(0x203)],_0x3e0480(0x1f7)),'id':_0x266aba}),this[_0x3e0480(0x210)](_0x56d85e)):_0x56d85e[_0x3e0480(0x21d)][_0x3e0480(0x1b4)](_0x3e0480(0x252))?(this[_0x3e0480(0x24e)][_0x3e0480(0x22f)]({'errorMessage':_0x3c35c3(this[_0x3e0480(0x248)][_0x3e0480(0x203)],_0x3e0480(0x259)),'id':_0x266aba}),this[_0x3e0480(0x210)](_0x56d85e)):_0x56d85e[_0x3e0480(0x21d)][_0x3e0480(0x1b4)](_0x3e0480(0x258))?(this[_0x3e0480(0x24e)][_0x3e0480(0x22f)]({'errorMessage':_0x3c35c3(this[_0x3e0480(0x248)][_0x3e0480(0x203)],_0x3e0480(0x24a)),'id':_0x266aba}),this[_0x3e0480(0x210)](_0x56d85e)):_0x56d85e[_0x3e0480(0x21d)][_0x3e0480(0x1b4)](_0x3e0480(0x27a))?(this[_0x3e0480(0x24e)][_0x3e0480(0x22f)]({'errorMessage':_0x3c35c3(this[_0x3e0480(0x248)][_0x3e0480(0x203)],_0x3e0480(0x1a5)),'id':_0x266aba}),this[_0x3e0480(0x210)](_0x56d85e)):_0x56d85e[_0x3e0480(0x21d)][_0x3e0480(0x1b4)](_0x3e0480(0x202))?(this[_0x3e0480(0x24e)][_0x3e0480(0x22f)]({'errorMessage':_0x3c35c3(this[_0x3e0480(0x248)][_0x3e0480(0x203)],_0x3e0480(0x2b1)),'id':_0x266aba}),this[_0x3e0480(0x210)](_0x56d85e)):_0x56d85e[_0x3e0480(0x21d)][_0x3e0480(0x1b4)](_0x3e0480(0x1cf))?(this[_0x3e0480(0x24e)][_0x3e0480(0x22f)]({'errorMessage':_0x3c35c3(this[_0x3e0480(0x248)][_0x3e0480(0x203)],_0x3e0480(0x239)),'id':_0x266aba}),this[_0x3e0480(0x210)](_0x56d85e)):(this[_0x3e0480(0x24e)][_0x3e0480(0x22f)]({'errorMessage':_0x3c35c3(this[_0x3e0480(0x248)][_0x3e0480(0x203)],_0x3e0480(0x2d8)),'id':_0x266aba}),this[_0x3e0480(0x210)](_0x56d85e));}),await this[_0x4e7ada(0x1ce)][_0x4e7ada(0x190)](this[_0x4e7ada(0x248)][_0x4e7ada(0x2bc)][_0x4e7ada(0x255)](_0x4e7ada(0x225))),_0x183999||await this[_0x4e7ada(0x1ce)][_0x4e7ada(0x21c)]();}async[_0x380a5b(0x23d)]({userMessage:_0x5d417f,quickActionData:_0x35a227}){const _0x4fa060=_0x380a5b;if(!this[_0x4fa060(0x1ce)])throw new _0xb8924f(_0x4fa060(0x2c8));this[_0x4fa060(0x1ce)][_0x4fa060(0x1a0)]()&&await this[_0x4fa060(0x1ce)][_0x4fa060(0x28f)](this[_0x4fa060(0x29b)][_0x4fa060(0x1b2)]()),this[_0x4fa060(0x1ce)]['id']&&this[_0x4fa060(0x1ce)][_0x4fa060(0x1ae)]&&await this[_0x4fa060(0x1ce)][_0x4fa060(0x2e7)]({'userMessage':_0x5d417f,'quickActionData':_0x35a227}),this[_0x4fa060(0x2b0)]();}[_0x380a5b(0x2b0)](){const _0x3b89ce=_0x380a5b,_0x3a2d65=_0x260be3(this[_0x3b89ce(0x248)])[_0x3b89ce(0x18a)],_0x282232=Array[_0x3b89ce(0x1c7)](_0x3a2d65[_0x3b89ce(0x1b0)][_0x3b89ce(0x2bf)](_0x5a2f18));_0x3a2d65[_0x3b89ce(0x1b6)](_0x4e2ed5=>{const _0x3ad550=_0x3b89ce;_0x282232[_0x3ad550(0x2e4)](_0xb67edc=>_0x4e2ed5[_0x3ad550(0x199)](_0xb67edc));});}[_0x380a5b(0x1e2)](){const _0x2cbce8=_0x380a5b;console[_0x2cbce8(0x253)](_0x2cbce8(0x242));}[_0x380a5b(0x25d)](_0x5eb1c3){const _0x28003b=_0x380a5b;this[_0x28003b(0x24e)][_0x28003b(0x194)](_0x5eb1c3);}[_0x380a5b(0x210)](_0x4d5fd4){const _0x6decf0=_0x380a5b;_0x1eb88a(_0x4d5fd4[_0x6decf0(0x21d)]);}[_0x380a5b(0x1bd)](_0xac5e77){const _0x576745=_0x380a5b;this[_0x576745(0x1ce)]?.[_0x576745(0x1fc)](_0xac5e77);}[_0x380a5b(0x1ac)](){const _0x185a4d=_0x380a5b;this[_0x185a4d(0x1ce)]?.[_0x185a4d(0x24f)]();}[_0x380a5b(0x27b)](){const _0x352c47=_0x380a5b;this[_0x352c47(0x1ce)]?.[_0x352c47(0x2b9)]();}[_0x380a5b(0x2b6)](_0x1d1ed8){const _0x3cb641=_0x380a5b,[_0x26db5b,_0x304667]=_0x1d1ed8[_0x3cb641(0x27f)](':'),_0x3a9fbd=this[_0x3cb641(0x1ce)][_0x3cb641(0x1da)](_0x26db5b),_0x9e9e9=_0x3a9fbd[_0x3cb641(0x19e)](_0x304667);return{'interaction':_0x3a9fbd,'reply':_0x9e9e9};}[_0x380a5b(0x226)](_0xb5fac8,_0x1d2e6c=!0x1){const _0x3170ed=_0x380a5b,_0x4aac99=_0x260be3(this[_0x3170ed(0x248)]),_0x44fd11={'target':_0x4aac99[_0x3170ed(0x21a)][_0x3170ed(0x2b5)][_0x3170ed(0x250)][_0x3170ed(0x2e0)](_0x4aac99[_0x3170ed(0x21a)][_0x3170ed(0x1f4)][_0x3170ed(0x195)](_0xb5fac8)),'viewportOffset':{'top':0x96,'left':0x0,'bottom':0x32,'right':0x0},'ancestorOffset':0x14,'alignToTop':_0x1d2e6c};_0x1d2e6c&&(_0x44fd11[_0x3170ed(0x219)]=!0x0),_0x59bc32(_0x44fd11);}[_0x380a5b(0x1fd)](_0xb82e9a,_0x1dc49a=!0x1){const _0x4b649e=_0x380a5b;this[_0x4b649e(0x24e)][_0x4b649e(0x26a)](_0xb82e9a||_0x3c35c3(this[_0x4b649e(0x248)][_0x4b649e(0x203)],_0x4b649e(0x293)),_0x1dc49a);}async[_0x380a5b(0x1f1)]({reply:_0x241e82,renderingStrategy:_0x5d0306}){const _0x3c5ebe=_0x380a5b,{id:_0x4040bd,isDone:_0x3b5061,type:_0x264d16,parsedContent:_0xb67df8}=_0x241e82;if(_0x3c5ebe(0x27d)===_0x264d16){const _0x5647ec=_0x241e82[_0x3c5ebe(0x22a)]({'showDiff':this[_0x3c5ebe(0x24e)][_0x3c5ebe(0x1ca)]});await this[_0x3c5ebe(0x24e)][_0x3c5ebe(0x26e)]({'id':_0x4040bd,'parts':_0x5647ec,'renderingStrategy':_0x5d0306,'isDone':_0x3b5061});}else _0x3c5ebe(0x275)===_0x264d16&&await this[_0x3c5ebe(0x24e)][_0x3c5ebe(0x272)]({'id':_0x4040bd,'parsedContent':_0xb67df8,'renderingStrategy':_0x5d0306,'isDone':_0x3b5061});_0x3b5061&&_0x241e82[_0x3c5ebe(0x212)][_0x3c5ebe(0x28a)]>0x0&&this[_0x3c5ebe(0x24e)][_0x3c5ebe(0x19d)](_0x4040bd,_0x241e82[_0x3c5ebe(0x212)]);}async[_0x380a5b(0x2c6)](){const _0x16a980=_0x380a5b,_0x4c3df9=this[_0x16a980(0x1ce)]?.[_0x16a980(0x1c2)];_0x4c3df9&&(_0x4c3df9[_0x16a980(0x18e)](),this[_0x16a980(0x24e)][_0x16a980(0x29e)](_0x4c3df9));}async[_0x380a5b(0x24b)](){const _0x56e4f9=_0x380a5b,_0x3bed24=this[_0x56e4f9(0x1ce)]?.[_0x56e4f9(0x1c2)];if(_0x3bed24){for await(const _0x14b857 of _0x3bed24[_0x56e4f9(0x1a9)])await this[_0x56e4f9(0x1f1)]({'reply':_0x14b857,'renderingStrategy':_0x56e4f9(0x2bb)});}}[_0x380a5b(0x280)](_0x8a3758){const _0x248d20=_0x380a5b,_0x155607={'positiveCount':_0x8a3758[_0x248d20(0x2bd)][_0x248d20(0x297)](_0x1ed89b=>_0x248d20(0x184)===_0x1ed89b[_0x248d20(0x182)])[_0x248d20(0x28a)],'totalCount':_0x8a3758[_0x248d20(0x2bd)][_0x248d20(0x28a)],'modificationId':_0x8a3758['id']},_0x3d7939=this[_0x248d20(0x1ce)][_0x248d20(0x1da)](_0x8a3758[_0x248d20(0x20c)])[_0x248d20(0x240)];this[_0x248d20(0x20b)][_0x248d20(0x2ae)](this[_0x248d20(0x1ce)]['id'],_0x3d7939,_0x155607);}}
23
+ const _0x87b24e=_0x3cf6;function _0x7d54(){const _0x329a46=['isOpen','attachToDom','static','isCurrentDocumentInConversation','findIndex','context','domConverter','AI_BALLOON_HEADER_TITLE','_logError','changes','replyCreated','interactionCreated','removeFeedInteraction','lastInteraction','uiId','Undo','mouseOverSuggestion','focusPromptInput','hideFakeVisualSelection','isDocumentOperation','path','ai-chat-context-unsupported-type','ai-chat-url-upload-failed','updateFeedItemAIReplySuggestionPartState','pending','loadConversation','updateFeedItemAIReplyContent','pluginName','ai-chat-context-form-data-size-limits-exceeded','getAttribute','contextItemLoadingEnded','ai-chat-source-resources-load-failed','selectModel','_startConversationSafely','ai-chat-context-unsupported-file-type','upsertAIChatRating','mouseLeaveSuggestion','sourceResourcesLoaded','alignToTop','_aiEditing','addFeedItemAIReply','rejected','replies','addSelectionToContext','_flushLastInteractionUI','resources','ai.chat.models.displayedModels','updateFeedItemAIReplySuggestionContent','getChild','AI_CHAT_UNABLE_TO_LOAD_CONVERSATION','current-document','ai-chat-context-invalid-data','editors','_aiChatModels','ai-chat-invalid-request','_toggleReasoning','getDocumentData','afterInit','_previewedChangeGroup','startInteraction','sourceId','filter','AI_CHAT_CONTEXT_INVALID_DATA','mapper','error','isInContext','destroy','state','ai-chat-controller-no-active-conversation','addFeedItemStaticMessage','set','accepted','addResourceToContext','isOfficialPlugin','ready','$graveyard','history','replyChangeGroupStateUpdated','like','content','capabilitiesUpdated','toString','enableControls','uid','find','addSelectionToChatContext','stopListening','root','_handleUIUserMessage','updateCurrentDocumentInContext','config','Liked\x20response','replyContentUpdated','reasoningStarted','ai.chat.context','length','getReply','markers','_toggleWebSearch','_integrateEditor','interactionId','1222371tyVacY','sendUserMessage','resource','abortPromptStream','rejectSuggestion','getInteractionAndReplyById','interactionStarted','_aiConnector','get','interactionFinished','ai-chat-conversation-not-found','data','init','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_URL','maxOffset','load','_aiChatUi','log','webSearchStarted','dialogClosed','resizedTabs','AI_CHAT_CONTEXT_UNABLE_TO_LOAD_RESOURCES','children','hasChanges','$root','outdated','addFeedItemAISuggestion','activeConversation','addOperation','documentContextContent','change','ai-no-track-changes','split','Showing\x20conversation\x20history...','setFeedItemRenderingStrategy','setModel','_insertSuggestion','range','ai-chat-controller-mouse-over','ai-chat-file-upload-failed','new','resizeTabs','removed','Disliked\x20response','AI_CHAT_GENERIC_ERROR','addFeedInteractionHeader','conversationInitialized','addFeedItemUserMessage','updateConversationTitle','ai.chat.models.defaultModelId','webSearchFinished','applySuggestion','getInteraction','contextSent','setSelectedModel','listenTo','showPrevious','_updateReplyContent','contextItemAdded','_balloonShowDiff','has','AI_CHAT_RESOURCE_LOAD_FAILED','model','removeSelectionFromChatContext','baseVersion','removeMarker','_removeAISelectionMarkers','setAddContextOptions','getConversation','_handleStartConversation','AI_CHAT_CONTEXT_FILE_TOO_MANY_PAGES','stop','sendMessage','getChildAtOffset','AITabs','setContextItemLoading','indexOf','stopInteraction','AI_CHAT_UNTITLED_CONVERSATION','ai-chat-context-file-too-large','editing','42104mUtSdd','addDocumentToContext','resourceId','viewRangeToDom','5805822phWqYP','requires','ai-chat-resource-load-failed','contextItemRemoved','resetMessageInput','AI_CHAT_CONTEXT_FILE_TOO_LARGE','getPath','handleRemovedConversation','marker','document','getMarkersGroup','from','parse','2061715OLYQyQ','changeGroups','push','isPremiumPlugin','updateCapabilities','redo','messageId','ai-chat-conversation-init-failed','toggleReasoning','collaboration.channelId','isDisabled','showFakeVisualSelection','dislike','removeSelectionFromContext','AIChatController','full','79513cQAuAw','source','toggleWebSearch','setLoadingMessage','getGroupId','_removeFromContext','getSelectionText','selection','locale','_applyOperationsAsSuggestions','2ItVcVz','selectedModel','view','anchorId','rootName','addContextItem','uploadProgressChanged','setIsMaximized','batch','main','setChangeGroupState','commands','ai-chat-missing-channel-id','AI_CHAT_INVALID_REQUEST','removeFromContext','startAutoScroll','setConversationContext','AI_CHAT_CONTEXT_FORM_DATA_SIZE_LIMITS_EXCEEDED','_stopLastInteraction','_openBalloonFor','47820wrFXIK','addFeedItemError','addFileToContext','981CqzIzo','replyId','query','isStarted','getChildren','delete','closeSourceResourceBalloon','node','slice','getContentParts','modelSelected','start','startConversation','activateTab','populateSourceResourceBalloon','resize','disableControls','DocumentCompare','12GonztD','toggleSuggestionDisplayMode','revert','applyOperation','startsWith','resetConversationTitle','TrackChangesEditing','version','_bodyCollection','options','insertSuggestion','TrackChanges','undo','handleUserInteraction','updateFeedItemAIReplySources','indexes','detachFromDom','_updateRatings','finishInteraction','_createFromRanges','addContextOptionsChanged','createRange','setIsUploadInProgress','isModelAvailable','showDiff','remove','getRanges','clearPendingContextUI','_setIsMaximized','_batchToChanges','addFilesToContext','clearConversationContextUI','partIndex','toViewRange','51448CNmdHA','addCurrentDocumentToContext','_showConversationHistory','isCurrentDocumentInContext','add','AIChatUI','isLoading','nextSibling','index','fetchConversation','AIConnector','interactionDestroyed','chat','updateResourceState','10FeAdAE','unshift','getTransformedByOperation','toggleLoadingSkeleton','ai-chat-context-file-too-many-pages','AI_CHAT_ABORTED_MESSAGE','reasoningFinished','ai-chat-conversation-start-failed','getOperations','AI_CHAT_CONTEXT_UNSUPPORTED_TYPE','ai.availableReplyActions','end','_applySuggestion','getDiff','loadSourceResources','showChangeInText','getRoot','close','plugins','message','howMany','data-id','ai-request-aborted','getDocumentContext','modification-delta','_scrollToSuggestionRange','map','sourcePosition','removeContextItem','createPositionAt','streaming','AI_CHAT_CONTEXT_UNSUPPORTED_FILE_TYPE','contextItem','updateContent','type','resourceStateChanged','sources','forEach','open','scrollFeedToSuggestion','addUrlToContext','getFirstRange','contextItems','isUploadInProgress','text-delta','_getDocumentRangeForReplyChanges','ai-conversation-','setConversationTitle','AI_CHAT_CONTEXT_CURRENT_DOCUMENT','cloneNode','showNext','createConversation','AI_CHAT_UNABLE_TO_START_CONVERSATION','createPositionFromPath','AIEditing','AI_CHAT_CONTEXT_UNABLE_TO_UPLOAD_FILE'];_0x7d54=function(){return _0x329a46;};return _0x7d54();}(function(_0x388e1c,_0x2b262d){const _0x21ab2f=_0x3cf6,_0x2ee9a1=_0x388e1c();while(!![]){try{const _0x14cbf7=-parseInt(_0x21ab2f(0x248))/0x1*(-parseInt(_0x21ab2f(0x234))/0x2)+-parseInt(_0x21ab2f(0x32a))/0x3+-parseInt(_0x21ab2f(0x27f))/0x4+parseInt(_0x21ab2f(0x21a))/0x5*(parseInt(_0x21ab2f(0x25d))/0x6)+-parseInt(_0x21ab2f(0x22a))/0x7+parseInt(_0x21ab2f(0x209))/0x8*(parseInt(_0x21ab2f(0x24b))/0x9)+parseInt(_0x21ab2f(0x28d))/0xa*(-parseInt(_0x21ab2f(0x20d))/0xb);if(_0x14cbf7===_0x2b262d)break;else _0x2ee9a1['push'](_0x2ee9a1['shift']());}catch(_0x53c516){_0x2ee9a1['push'](_0x2ee9a1['shift']());}}}(_0x7d54,0x76d25));import{ContextPlugin as _0x24bfcf,Editor as _0x13c25a}from'ckeditor5/src/core.js';import{BodyCollection as _0x37d39e}from'ckeditor5/src/ui.js';import{CKEditorError as _0x219767,logError as _0x456fd9,scrollViewportToShowTarget as _0x5724a9,uid as _0x489566}from'ckeditor5/src/utils.js';import{AIConnector as _0x5573f5}from'../aicore/aiconnector.js';import{AITabs as _0x1ab538}from'../aitabs/aitabs.js';import{AIChatConversation as _0x57bac1}from'./model/aichatconversation.js';import{getTranslation as _0x381c56}from'../aicore/utils/common-translations.js';import{AI_VISUAL_SELECTION_MARKER_NAME as _0x4cfafd}from'../aicore/aiediting.js';import{AI_REPLY_ACTIONS as _0x55499e}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';import{AIModels as _0x496463}from'../aicore/model/aimodels.js';import{getEditorFromContext as _0x3a659a}from'../aicore/utils/geteditorfromcontext.js';function _0x3cf6(_0x2a6f47,_0x15a157){const _0x7d543f=_0x7d54();return _0x3cf6=function(_0x3cf641,_0x3e3e37){_0x3cf641=_0x3cf641-0x1bc;let _0x5b98ab=_0x7d543f[_0x3cf641];return _0x5b98ab;},_0x3cf6(_0x2a6f47,_0x15a157);}import{DocumentCompare as _0x3622f2,DATA_ID_MODEL_ATTRIBUTE as _0x2f68dc}from'ckeditor5-collaboration/src/collaboration-core.js';import{fixMarkerOperationOldRange as _0x34ee81,getOperationsFromReply as _0x1f9938}from'../aicore/utils/getoperationsfromreply.js';import{expandSelectionWithContext as _0x31428c,getMinimalSelection as _0x262c9d}from'../aicore/utils/getsuggestionpartsfromreply.js';import{ModelRange as _0x2deb97,_DetachOperation as _0x2dcf9a}from'ckeditor5/src/engine.js';import{findOne as _0x279e3f,getAttribute as _0x551ccf,serialize as _0x35f575,Document as _0x3f2ee2,findByAttribute as _0x29c0a4}from'../aicore/utils/htmlparser.js';import{IconAI as _0x47118f}from'@ckeditor/ckeditor5-icons';import{AISuggestionContainerView as _0x2a8017}from'../aicore/ui/suggestioncontainer/aisuggestioncontainerview.js';import{AIBalloon as _0x1169da}from'../aiballoon/aiballoon.js';export class AIChatController extends _0x24bfcf{[_0x87b24e(0x2ec)];[_0x87b24e(0x1bf)];[_0x87b24e(0x1c8)];[_0x87b24e(0x2fa)];[_0x87b24e(0x27a)]=new Map();[_0x87b24e(0x2ff)]=null;[_0x87b24e(0x1f3)]=!0x1;[_0x87b24e(0x265)];static get[_0x87b24e(0x20e)](){return[_0x5573f5,_0x1169da,_0x3622f2];}static get[_0x87b24e(0x2e0)](){const _0x2410f4=_0x87b24e;return _0x2410f4(0x228);}static get[_0x87b24e(0x30e)](){return!0x0;}static get[_0x87b24e(0x21d)](){return!0x0;}[_0x87b24e(0x1c4)](){const _0x2cc2d5=_0x87b24e;this[_0x2cc2d5(0x265)]=new _0x37d39e(this[_0x2cc2d5(0x2ca)][_0x2cc2d5(0x232)]),this[_0x2cc2d5(0x265)][_0x2cc2d5(0x2c6)](),this[_0x2cc2d5(0x1bf)]=this[_0x2cc2d5(0x2ca)][_0x2cc2d5(0x29f)][_0x2cc2d5(0x1c0)](_0x2cc2d5(0x289)),this[_0x2cc2d5(0x1c8)]=this[_0x2cc2d5(0x2ca)][_0x2cc2d5(0x29f)][_0x2cc2d5(0x1c0)](_0x2cc2d5(0x284)),this[_0x2cc2d5(0x2ec)]=this[_0x2cc2d5(0x2ca)][_0x2cc2d5(0x29f)][_0x2cc2d5(0x1c0)](_0x2cc2d5(0x2c3)),this[_0x2cc2d5(0x2fa)]=new _0x496463({'connector':this[_0x2cc2d5(0x1bf)],'availableModels':this[_0x2cc2d5(0x2ca)][_0x2cc2d5(0x31f)][_0x2cc2d5(0x1c0)](_0x2cc2d5(0x2f3)),'defaultModelId':this[_0x2cc2d5(0x2ca)][_0x2cc2d5(0x31f)][_0x2cc2d5(0x1c0)](_0x2cc2d5(0x1e9)),'locale':this[_0x2cc2d5(0x2ca)][_0x2cc2d5(0x232)]});const _0x1fadd4=this[_0x2cc2d5(0x2ca)][_0x2cc2d5(0x29f)][_0x2cc2d5(0x1c0)](_0x2cc2d5(0x202));this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x257),()=>{const _0x1f39ef=_0x2cc2d5;this[_0x1f39ef(0x2e6)]();}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x32b),(_0x41efad,_0x50c0b0)=>{const _0x357b90=_0x2cc2d5;this[_0x357b90(0x31d)]({'userMessage':_0x50c0b0});}),this[_0x2cc2d5(0x1ef)](_0x1fadd4,_0x2cc2d5(0x1cc),(_0x247311,_0x3fe9a0)=>{const _0x2c390b=_0x2cc2d5;this[_0x2c390b(0x279)](_0x3fe9a0);}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x1e1),()=>{const _0x3466af=_0x2cc2d5;_0x1fadd4[_0x3466af(0x25a)]();}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x32d),async()=>{const _0x48179c=_0x2cc2d5;await this[_0x48179c(0x246)](),await this[_0x48179c(0x2f1)](),this[_0x48179c(0x1f7)]();}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x20a),()=>{const _0x1fd0e4=_0x2cc2d5;this[_0x1fd0e4(0x1d3)]?.[_0x1fd0e4(0x280)](_0x381c56(this[_0x1fd0e4(0x2ca)][_0x1fd0e4(0x232)],_0x1fd0e4(0x2bd)));}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x24a),(_0x129c2f,_0x5daaef)=>{const _0x51d08d=_0x2cc2d5;this[_0x51d08d(0x1d3)]?.[_0x51d08d(0x27b)](Array[_0x51d08d(0x218)](_0x5daaef));}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x2b5),(_0x4b8b09,_0x104a88)=>{const _0x3d830a=_0x2cc2d5;this[_0x3d830a(0x1d3)]?.[_0x3d830a(0x2b5)](_0x104a88);}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x30d),(_0x176570,_0x393584)=>{const _0xa07a98=_0x2cc2d5;this[_0xa07a98(0x1d3)]?.[_0xa07a98(0x30d)](_0x393584[_0xa07a98(0x22b)],_0x393584[_0xa07a98(0x32c)]);}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x2a9),(_0x2bf253,_0x4b0e93)=>{const _0x46464e=_0x2cc2d5;this[_0x46464e(0x22f)](_0x4b0e93);}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x29b),(_0x3f6316,_0x47c00f)=>{const _0x4108f8=_0x2cc2d5;this[_0x4108f8(0x1d3)]?.[_0x4108f8(0x29b)](_0x47c00f[_0x4108f8(0x301)],_0x47c00f[_0x4108f8(0x24d)],_0x47c00f[_0x4108f8(0x318)]);}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x22c),()=>{const _0x27b273=_0x2cc2d5;this[_0x27b273(0x327)]();}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x222),()=>{const _0x268d0e=_0x2cc2d5;this[_0x268d0e(0x2fc)]();}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x2e5),(_0xe2e4bf,_0x41158e)=>{const _0x1c5b05=_0x2cc2d5;this[_0x1c5b05(0x1d3)]?.[_0x1c5b05(0x1db)](_0x41158e);}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x313),(_0x516fc2,{replyId:_0x39dba0})=>{const _0x51e676=_0x2cc2d5;console[_0x51e676(0x1c9)](_0x51e676(0x320),_0x39dba0);}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x226),(_0x257739,{replyId:_0x459211})=>{const _0x337659=_0x2cc2d5;console[_0x337659(0x1c9)](_0x337659(0x1e3),_0x459211);}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x267),(_0x38c17a,_0x4e1a7f)=>{const _0x19af7a=_0x2cc2d5;this[_0x19af7a(0x2ca)][_0x19af7a(0x29f)][_0x19af7a(0x1c0)](_0x1169da)[_0x19af7a(0x29e)](),this[_0x19af7a(0x1dc)](_0x4e1a7f);}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x29c),(_0x35c9e2,{replyId:_0x54e3f2,partIndex:_0x23fbdf})=>{const _0x1db273=_0x2cc2d5;this[_0x1db273(0x1f3)]=this[_0x1db273(0x1c8)][_0x1db273(0x275)],this[_0x1db273(0x247)](_0x54e3f2,_0x23fbdf);}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x2d5),(_0x57c955,{replyId:_0xf4470d,partIndex:_0x5e8053})=>{const _0x1f98b5=_0x2cc2d5,_0xac0a41=this[_0x1f98b5(0x2ba)](_0xf4470d,_0x5e8053);_0xac0a41&&_0x1f98b5(0x310)!=_0xac0a41[_0x1f98b5(0x1dd)][_0x1f98b5(0x31c)][_0x1f98b5(0x238)]&&this[_0x1f98b5(0x2ec)][_0x1f98b5(0x225)]([_0xac0a41[_0x1f98b5(0x1dd)]],_0x1f98b5(0x1de));}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x2e9),()=>{const _0x157125=_0x2cc2d5;this[_0x157125(0x2ec)][_0x157125(0x2d7)](_0x157125(0x1de));}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x1eb),(_0x379eb2,_0x1f55b9)=>{const _0x1ae4d8=_0x2cc2d5;this[_0x1ae4d8(0x2ca)][_0x1ae4d8(0x29f)][_0x1ae4d8(0x1c0)](_0x1169da)[_0x1ae4d8(0x29e)](),this[_0x1ae4d8(0x299)](_0x1f55b9);}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x25e),async(_0x107aef,{replyId:_0x508c90,showDiff:_0x42b9a2})=>{const _0x58240c=_0x2cc2d5,{reply:_0x2d3ae0}=this[_0x58240c(0x1bd)](_0x508c90),_0x25e15f=_0x2d3ae0[_0x58240c(0x254)]({'showDiff':_0x42b9a2});await this[_0x58240c(0x1c8)][_0x58240c(0x2f4)]({'id':_0x2d3ae0['id'],'parts':_0x25e15f,'renderingStrategy':_0x58240c(0x2c7)});}),this[_0x2cc2d5(0x1ef)](this[_0x2cc2d5(0x1c8)],_0x2cc2d5(0x1bc),(_0x3c484d,{replyId:_0x2a356b,partIndex:_0x228aeb})=>{const _0x20a075=_0x2cc2d5;this[_0x20a075(0x2ff)]?.[_0x20a075(0x24c)]==_0x2a356b&&this[_0x20a075(0x2ff)]?.[_0x20a075(0x27d)]==_0x228aeb&&this[_0x20a075(0x2ca)][_0x20a075(0x29f)][_0x20a075(0x1c0)](_0x1169da)[_0x20a075(0x29e)]();const {reply:_0x1f96c2}=this[_0x20a075(0x1bd)](_0x2a356b);_0x1f96c2[_0x20a075(0x23e)](_0x228aeb,_0x20a075(0x2ee)),this[_0x20a075(0x2ec)][_0x20a075(0x2d7)](_0x20a075(0x1de));});}async[_0x87b24e(0x2fe)](){const _0x26d68d=_0x87b24e;this[_0x26d68d(0x2ca)]instanceof _0x13c25a?this[_0x26d68d(0x328)](this[_0x26d68d(0x2ca)]):this[_0x26d68d(0x1ef)](this[_0x26d68d(0x2ca)][_0x26d68d(0x2f9)],_0x26d68d(0x283),(_0x192f3,_0x43f1e7)=>{const _0x394f1f=_0x26d68d;_0x43f1e7['on'](_0x394f1f(0x30f),()=>{const _0x3c70ab=_0x394f1f;this[_0x3c70ab(0x328)](_0x43f1e7);});}),await this[_0x26d68d(0x2e6)]();}[_0x87b24e(0x307)](){const _0x4897f0=_0x87b24e;this[_0x4897f0(0x265)][_0x4897f0(0x26d)](),super[_0x4897f0(0x307)]();}[_0x87b24e(0x1dc)](_0x45b4e4){const _0x155592=_0x87b24e,_0x2351ca=_0x3a659a(this[_0x155592(0x2ca)]);if(!_0x2351ca[_0x155592(0x29f)][_0x155592(0x1f4)](_0x155592(0x268)))throw new _0x219767(_0x155592(0x1d7),null);const _0x575ec5=this[_0x155592(0x2ca)][_0x155592(0x29f)][_0x155592(0x1c0)](_0x155592(0x25c)),{reply:_0x37dc60,interaction:_0x22a000}=this[_0x155592(0x1bd)](_0x45b4e4[_0x155592(0x24c)]),_0x4803e5=this[_0x155592(0x2ba)](_0x45b4e4[_0x155592(0x24c)],_0x45b4e4[_0x155592(0x27d)]),_0x71037=void 0x0!==_0x45b4e4[_0x155592(0x27d)]?[_0x37dc60[_0x155592(0x21b)][_0x45b4e4[_0x155592(0x27d)]]]:_0x37dc60[_0x155592(0x21b)][_0x155592(0x302)](_0x3bc334=>_0x155592(0x2dd)==_0x3bc334[_0x155592(0x308)]),_0x46bde4=_0x71037[_0x155592(0x2a7)](_0x6bc752=>_0x37dc60[_0x155592(0x21b)][_0x155592(0x204)](_0x6bc752));if(!_0x4803e5||_0x155592(0x310)==_0x4803e5[_0x155592(0x1dd)][_0x155592(0x31c)][_0x155592(0x238)])return void _0x46bde4[_0x155592(0x2b2)](_0x44698e=>_0x37dc60[_0x155592(0x23e)](_0x44698e,_0x155592(0x1d1)));_0x46bde4[_0x155592(0x2b2)](_0x32135f=>_0x37dc60[_0x155592(0x23e)](_0x32135f,_0x155592(0x30c)));const _0x493430=_0x1f9938({'editor':_0x2351ca,'reply':_0x37dc60,'interaction':_0x22a000,'groups':_0x71037,'transform':!0x0,'documentCompare':_0x575ec5,'documentCompareOptions':{'anchor':_0x155592(0x23d),'markDeletions':!0x0}});let _0x48a88c;_0x4803e5&&this[_0x155592(0x2a6)](_0x4803e5[_0x155592(0x1dd)]),_0x2351ca[_0x155592(0x1f6)][_0x155592(0x1d6)](_0x1ef02b=>{const _0x45c736=_0x155592;_0x48a88c=_0x1ef02b[_0x45c736(0x23c)],_0x2351ca[_0x45c736(0x29f)][_0x45c736(0x1c0)](_0x45c736(0x263))[_0x45c736(0x233)](_0x493430),this[_0x45c736(0x2ec)][_0x45c736(0x2d7)](_0x45c736(0x1de));}),this[_0x155592(0x27a)][_0x155592(0x30b)](_0x48a88c,{'interactionId':_0x22a000['id'],'replyId':_0x37dc60['id'],'indexes':_0x46bde4[_0x155592(0x253)]()}),this[_0x155592(0x26e)](_0x37dc60);}[_0x87b24e(0x299)](_0x1e43cd){const _0xa770fb=_0x87b24e,_0x5624e1=_0x3a659a(this[_0xa770fb(0x2ca)]),_0x289e38=this[_0xa770fb(0x2ca)][_0xa770fb(0x29f)][_0xa770fb(0x1c0)](_0x3622f2),{reply:_0x1badce,interaction:_0x20dc27}=this[_0xa770fb(0x1bd)](_0x1e43cd[_0xa770fb(0x24c)]),_0x40d0a4=this[_0xa770fb(0x2ba)](_0x1e43cd[_0xa770fb(0x24c)],_0x1e43cd[_0xa770fb(0x27d)]),_0x3529a5=void 0x0!==_0x1e43cd[_0xa770fb(0x27d)]?[_0x1badce[_0xa770fb(0x21b)][_0x1e43cd[_0xa770fb(0x27d)]]]:_0x1badce[_0xa770fb(0x21b)][_0xa770fb(0x302)](_0x115d25=>_0xa770fb(0x2dd)==_0x115d25[_0xa770fb(0x308)]),_0x411819=_0x3529a5[_0xa770fb(0x2a7)](_0x594682=>_0x1badce[_0xa770fb(0x21b)][_0xa770fb(0x204)](_0x594682));if(!_0x40d0a4||_0xa770fb(0x310)==_0x40d0a4[_0xa770fb(0x1dd)][_0xa770fb(0x31c)][_0xa770fb(0x238)])return void _0x411819[_0xa770fb(0x2b2)](_0x247737=>_0x1badce[_0xa770fb(0x23e)](_0x247737,_0xa770fb(0x1d1)));_0x411819[_0xa770fb(0x2b2)](_0x33f6e9=>_0x1badce[_0xa770fb(0x23e)](_0x33f6e9,_0xa770fb(0x30c)));const _0x411767=_0x1f9938({'editor':_0x5624e1,'reply':_0x1badce,'interaction':_0x20dc27,'groups':_0x3529a5,'transform':!0x0,'documentCompare':_0x289e38,'documentCompareOptions':{'anchor':_0xa770fb(0x23d),'markDeletions':!0x1}});let _0x53b2c9;_0x40d0a4&&this[_0xa770fb(0x2a6)](_0x40d0a4[_0xa770fb(0x1dd)]),_0x5624e1[_0xa770fb(0x1f6)][_0xa770fb(0x1d6)](_0x3129eb=>{const _0x64fed7=_0xa770fb;_0x53b2c9=_0x3129eb[_0x64fed7(0x23c)];for(const _0x42079a of _0x411767)_0x42079a[_0x64fed7(0x1f8)]=_0x5624e1[_0x64fed7(0x1f6)][_0x64fed7(0x216)][_0x64fed7(0x264)],_0x34ee81(_0x5624e1,_0x42079a),_0x3129eb[_0x64fed7(0x23c)][_0x64fed7(0x1d4)](_0x42079a),_0x5624e1[_0x64fed7(0x1f6)][_0x64fed7(0x260)](_0x42079a);}),this[_0xa770fb(0x27a)][_0xa770fb(0x30b)](_0x53b2c9,{'interactionId':_0x20dc27['id'],'replyId':_0x1badce['id'],'indexes':_0x411819[_0xa770fb(0x253)]()}),this[_0xa770fb(0x26e)](_0x1badce);}[_0x87b24e(0x247)](_0x26faf0,_0x52bb7b){const _0x3d947b=_0x87b24e,_0x40f860=_0x3a659a(this[_0x3d947b(0x2ca)]),_0x44f656=this[_0x3d947b(0x2ba)](_0x26faf0,_0x52bb7b),_0x5f1f13=this[_0x3d947b(0x2ca)][_0x3d947b(0x29f)][_0x3d947b(0x1c0)](_0x1169da);if(!_0x44f656)return void _0x5f1f13[_0x3d947b(0x29e)]();const {range:_0x56b9b9,currentIndex:_0x49b864}=_0x44f656;if(_0x3d947b(0x310)==_0x56b9b9[_0x3d947b(0x31c)][_0x3d947b(0x238)]){const {reply:_0x34c336}=this[_0x3d947b(0x1bd)](_0x26faf0);return _0x34c336[_0x3d947b(0x23e)](_0x49b864,_0x3d947b(0x1d1)),void _0x5f1f13[_0x3d947b(0x29e)]();}if(this[_0x3d947b(0x2ff)]?.[_0x3d947b(0x24c)]==_0x26faf0&&this[_0x3d947b(0x2ff)]?.[_0x3d947b(0x27d)]==_0x49b864)return;this[_0x3d947b(0x31b)](_0x5f1f13),this[_0x3d947b(0x2ff)]={'replyId':_0x26faf0,'partIndex':_0x49b864};let _0x4632b7=_0x40f860[_0x3d947b(0x31f)][_0x3d947b(0x1c0)](_0x3d947b(0x297))||[..._0x55499e];_0x40f860[_0x3d947b(0x29f)][_0x3d947b(0x1f4)](_0x3d947b(0x268))||(_0x4632b7=_0x4632b7[_0x3d947b(0x302)](_0x455cfd=>_0x3d947b(0x267)!=_0x455cfd));const _0x28cb64=new _0x2a8017(_0x40f860[_0x3d947b(0x232)],{'showDiff':this[_0x3d947b(0x1f3)],'areActionsDisabled':!0x1,'miniToolbarConfig':{'showChanges':_0x3d947b(0x229)},'hideHeader':!0x0,'availableActions':_0x4632b7},this[_0x3d947b(0x265)]);this[_0x3d947b(0x31b)](_0x28cb64);const {reply:_0x2bc259}=this[_0x3d947b(0x1bd)](_0x26faf0),_0x23059e=_0x2bc259[_0x3d947b(0x254)]({'showDiff':this[_0x3d947b(0x1f3)]})[_0x3d947b(0x302)](_0x5d4a20=>_0x5d4a20[_0x3d947b(0x1cf)]),_0x56aa07=_0x23059e[_0x3d947b(0x2c9)](_0x9fd558=>_0x9fd558[_0x3d947b(0x287)]==_0x49b864);if(-0x1==_0x56aa07)return;const _0x5a009d=_0x23059e[_0x56aa07],_0x57c016=_0x23059e['at']((_0x56aa07-0x1)%_0x23059e[_0x3d947b(0x324)])?.[_0x3d947b(0x287)],_0x2664f5=_0x23059e['at']((_0x56aa07+0x1)%_0x23059e[_0x3d947b(0x324)])?.[_0x3d947b(0x287)];_0x28cb64[_0x3d947b(0x2ae)]({'parts':[_0x5a009d],'renderingStrategy':_0x3d947b(0x2c7)});const _0x5e8836=_0x49b864!==_0x57c016;this[_0x3d947b(0x2a6)](_0x56b9b9,!0x0),_0x5f1f13[_0x3d947b(0x2b3)]({'index':_0x49b864,'title':_0x381c56(this[_0x3d947b(0x2ca)][_0x3d947b(0x232)],_0x3d947b(0x2cc),(_0x56aa07+0x1)[_0x3d947b(0x316)]()),'icon':_0x47118f,'mainView':_0x28cb64,'showRotator':_0x5e8836,'showApplyButton':!0x0,'showSuggestButton':_0x40f860[_0x3d947b(0x29f)][_0x3d947b(0x1f4)](_0x3d947b(0x268)),'ranges':[_0x56b9b9]}),this[_0x3d947b(0x1c8)][_0x3d947b(0x2b4)](_0x26faf0,_0x49b864),this[_0x3d947b(0x1ef)](_0x28cb64,_0x3d947b(0x25e),(_0x4663c7,{showDiff:_0x1cbd91})=>{const _0x4f9621=_0x3d947b;this[_0x4f9621(0x1f3)]=_0x1cbd91;const {reply:_0x50affc}=this[_0x4f9621(0x1bd)](_0x26faf0),_0x2b3959=_0x50affc[_0x4f9621(0x254)]({'showDiff':_0x1cbd91,'groupIndex':_0x49b864});_0x28cb64[_0x4f9621(0x2ae)]({'parts':_0x2b3959,'renderingStrategy':_0x4f9621(0x2c7)});}),this[_0x3d947b(0x1ef)](_0x5f1f13,_0x3d947b(0x1eb),()=>{const _0x344d53=_0x3d947b;this[_0x344d53(0x299)]({'replyId':_0x26faf0,'partIndex':_0x49b864}),_0x5e8836?this[_0x344d53(0x247)](_0x26faf0,_0x2664f5):_0x5f1f13[_0x344d53(0x29e)]();}),this[_0x3d947b(0x1ef)](_0x5f1f13,_0x3d947b(0x267),()=>{const _0x292d9f=_0x3d947b;this[_0x292d9f(0x1dc)]({'replyId':_0x26faf0,'partIndex':_0x49b864}),_0x5e8836?this[_0x292d9f(0x247)](_0x26faf0,_0x2664f5):_0x5f1f13[_0x292d9f(0x29e)]();}),_0x5e8836&&(this[_0x3d947b(0x1ef)](_0x5f1f13,_0x3d947b(0x2bf),()=>{const _0x9dc6c7=_0x3d947b;this[_0x9dc6c7(0x247)](_0x26faf0,_0x2664f5);}),this[_0x3d947b(0x1ef)](_0x5f1f13,_0x3d947b(0x1f0),()=>{const _0x5685c8=_0x3d947b;this[_0x5685c8(0x247)](_0x26faf0,_0x57c016);})),this[_0x3d947b(0x1ef)](_0x5f1f13,_0x3d947b(0x1cb),()=>{const _0x42cf7c=_0x3d947b;this[_0x42cf7c(0x31b)](_0x5f1f13),this[_0x42cf7c(0x31b)](_0x28cb64),this[_0x42cf7c(0x2ff)]=null;});}[_0x87b24e(0x2ba)](_0x331890,_0x2b9266){const _0xfc67ad=_0x87b24e,_0xd793b5=_0x3a659a(this[_0xfc67ad(0x2ca)]),{reply:_0x4e4818,interaction:_0x199aa9}=this[_0xfc67ad(0x1bd)](_0x331890),_0x8b912a=_0x4e4818[_0xfc67ad(0x21b)][_0xfc67ad(0x302)](_0xdb5195=>_0xfc67ad(0x2dd)==_0xdb5195[_0xfc67ad(0x308)]),_0x27f8cc=_0x8b912a[_0xfc67ad(0x2a7)](_0x3ed68b=>_0x4e4818[_0xfc67ad(0x21b)][_0xfc67ad(0x204)](_0x3ed68b));void 0x0===_0x2b9266&&(_0x2b9266=_0x27f8cc[0x0]);const _0x370354=_0x27f8cc[_0xfc67ad(0x204)](_0x2b9266);if(-0x1==_0x370354)return null;const _0x24d89d=_0x8b912a[_0x370354],_0x3c0f95=new _0x3f2ee2([]),_0x3b3836=new _0x3f2ee2([]);for(const _0x542be3 of _0x24d89d[_0xfc67ad(0x2ce)])if(_0xfc67ad(0x1e2)!=_0x542be3[_0xfc67ad(0x2af)]&&_0x3b3836[_0xfc67ad(0x1ce)][_0xfc67ad(0x21c)](_0x542be3[_0xfc67ad(0x252)][_0xfc67ad(0x2be)](!0x0)),_0xfc67ad(0x1e0)!=_0x542be3[_0xfc67ad(0x2af)]){const _0x45aeb5=_0x279e3f(_0x512d6e=>_0x551ccf(_0x512d6e,_0xfc67ad(0x2a2))==_0x542be3['id'],_0x4e4818[_0xfc67ad(0x1d5)],!0x0);_0x3c0f95[_0xfc67ad(0x1ce)][_0xfc67ad(0x21c)](_0x45aeb5[_0xfc67ad(0x2be)](!0x0));}if(0x0==_0x3c0f95[_0xfc67ad(0x1ce)][_0xfc67ad(0x324)]){if(_0x24d89d[_0xfc67ad(0x2ce)][0x0][_0xfc67ad(0x237)]){const _0x10796b=_0x29c0a4(_0xfc67ad(0x2a2),_0x24d89d[_0xfc67ad(0x2ce)][0x0][_0xfc67ad(0x237)],_0x4e4818[_0xfc67ad(0x1d5)]);_0x3c0f95[_0xfc67ad(0x1ce)][_0xfc67ad(0x28e)](_0x10796b[_0xfc67ad(0x2be)](!0x0)),_0x3b3836[_0xfc67ad(0x1ce)][_0xfc67ad(0x28e)](_0x10796b[_0xfc67ad(0x2be)](!0x0)),_0x10796b[_0xfc67ad(0x286)]&&(_0x3c0f95[_0xfc67ad(0x1ce)][_0xfc67ad(0x21c)](_0x10796b[_0xfc67ad(0x286)][_0xfc67ad(0x2be)](!0x0)),_0x3b3836[_0xfc67ad(0x1ce)][_0xfc67ad(0x21c)](_0x10796b[_0xfc67ad(0x286)][_0xfc67ad(0x2be)](!0x0)));}else{const _0x41762f=_0x4e4818[_0xfc67ad(0x1d5)][_0xfc67ad(0x1ce)][0x0];if(!_0x41762f)return null;_0x3c0f95[_0xfc67ad(0x1ce)][_0xfc67ad(0x21c)](_0x41762f[_0xfc67ad(0x2be)](!0x0)),_0x3b3836[_0xfc67ad(0x1ce)][_0xfc67ad(0x21c)](_0x41762f[_0xfc67ad(0x2be)](!0x0));}}const _0x462e77=_0x199aa9[_0xfc67ad(0x2a4)](),_0x4638ff=_0xd793b5[_0xfc67ad(0x1c3)][_0xfc67ad(0x219)](_0x462e77[_0xfc67ad(0x314)],_0xfc67ad(0x1d0)),_0x43cca7=_0x35f575(_0x3c0f95),_0x576c46=_0xd793b5[_0xfc67ad(0x1c3)][_0xfc67ad(0x219)](_0x43cca7),_0x41c10f=_0xd793b5[_0xfc67ad(0x1c3)][_0xfc67ad(0x219)](_0x43cca7),_0x5e663c=_0xd793b5[_0xfc67ad(0x1f6)][_0xfc67ad(0x2aa)](_0x576c46,0x0),_0x5ebce1=_0x35f575(_0x3b3836),_0x4e8855={'anchor':_0x5e663c,'markDeletions':!0x1,'context':_0xfc67ad(0x1d0)},_0x20aba7=_0xd793b5[_0xfc67ad(0x29f)][_0xfc67ad(0x1c0)](_0x3622f2)[_0xfc67ad(0x29a)](_0x43cca7,_0x5ebce1,_0x4e8855)[_0xfc67ad(0x295)]();if(!_0x20aba7[_0xfc67ad(0x324)])return null;_0xd793b5[_0xfc67ad(0x1f6)][_0xfc67ad(0x1d6)](_0x443a91=>{const _0x1ee71a=_0xfc67ad;for(const _0xa91141 of _0x20aba7)if(_0x1ee71a(0x276)==_0xa91141[_0x1ee71a(0x2af)]){const _0x431b18=_0xa91141[_0x1ee71a(0x2a8)],_0x2375b4=_0xa91141[_0x1ee71a(0x2a1)],_0xf8d829=new _0x2dcf9a(_0x431b18,_0x2375b4);_0x443a91[_0x1ee71a(0x23c)][_0x1ee71a(0x1d4)](_0xf8d829),_0xd793b5[_0x1ee71a(0x1f6)][_0x1ee71a(0x260)](_0xf8d829);}else _0x1ee71a(0x215)!==_0xa91141[_0x1ee71a(0x2af)]&&(_0xa91141[_0x1ee71a(0x1f8)]=null,_0xa91141[_0x1ee71a(0x2d8)]=!0x1,_0x443a91[_0x1ee71a(0x23c)][_0x1ee71a(0x1d4)](_0xa91141),_0xd793b5[_0x1ee71a(0x1f6)][_0x1ee71a(0x260)](_0xa91141));});const _0x472ff9=_0x262c9d(_0xd793b5,_0x20aba7,_0x576c46);_0x31428c(_0xd793b5[_0xfc67ad(0x1f6)],_0x472ff9);const _0x5a2438=_0x472ff9[_0xfc67ad(0x2b6)]()[_0xfc67ad(0x256)][_0xfc67ad(0x2d9)][_0xfc67ad(0x253)](),_0x3f522e=_0x472ff9[_0xfc67ad(0x2b6)]()[_0xfc67ad(0x298)][_0xfc67ad(0x2d9)][_0xfc67ad(0x253)](),_0x53642a=[];let _0x3b78e4=_0x576c46,_0x1166b9=_0x41c10f;for(let _0x1980d4=0x0;_0x1980d4<_0x3f522e[_0xfc67ad(0x324)];_0x1980d4++){const _0x576b4c=_0x3b78e4[_0xfc67ad(0x1c6)]-_0x3f522e[_0x1980d4];_0x53642a[_0x1980d4]=_0x1166b9[_0xfc67ad(0x1c6)]-_0x576b4c,_0x3b78e4=_0x3b78e4[_0xfc67ad(0x201)](_0x3f522e[_0x1980d4]),_0x1166b9=_0x1166b9[_0xfc67ad(0x201)](_0x53642a[_0x1980d4]);}const _0x544cc4=_0xd793b5[_0xfc67ad(0x1f6)][_0xfc67ad(0x272)](_0xd793b5[_0xfc67ad(0x1f6)][_0xfc67ad(0x2c2)](_0x41c10f,_0x5a2438),_0xd793b5[_0xfc67ad(0x1f6)][_0xfc67ad(0x2c2)](_0x41c10f,_0x53642a)),_0x4e3898=_0x41c10f[_0xfc67ad(0x2f5)](0x0)[_0xfc67ad(0x2e2)](_0x2f68dc),_0x525ea2=Array[_0xfc67ad(0x218)](_0x4638ff[_0xfc67ad(0x24f)]())[_0xfc67ad(0x319)](_0x1bfb63=>_0x1bfb63[_0xfc67ad(0x2e2)](_0x2f68dc)==_0x4e3898)[_0xfc67ad(0x213)](),_0xb00f0e=_0x544cc4[_0xfc67ad(0x256)][_0xfc67ad(0x2d9)][_0xfc67ad(0x253)](),_0x377ad5=_0x544cc4[_0xfc67ad(0x298)][_0xfc67ad(0x2d9)][_0xfc67ad(0x253)]();_0xb00f0e[0x0]=_0x525ea2[0x0]+_0xb00f0e[0x0],_0x377ad5[0x0]=_0x525ea2[0x0]+_0x377ad5[0x0];let _0x546cfe=_0xd793b5[_0xfc67ad(0x1f6)][_0xfc67ad(0x272)](_0xd793b5[_0xfc67ad(0x1f6)][_0xfc67ad(0x2c2)](_0xd793b5[_0xfc67ad(0x1f6)][_0xfc67ad(0x216)][_0xfc67ad(0x29d)](),_0xb00f0e),_0xd793b5[_0xfc67ad(0x1f6)][_0xfc67ad(0x2c2)](_0xd793b5[_0xfc67ad(0x1f6)][_0xfc67ad(0x216)][_0xfc67ad(0x29d)](),_0x377ad5));const _0x3df4db=_0xd793b5[_0xfc67ad(0x1f6)][_0xfc67ad(0x216)][_0xfc67ad(0x311)][_0xfc67ad(0x295)](_0x462e77[_0xfc67ad(0x264)]);for(const _0x79baa6 of _0x3df4db)_0x546cfe=_0x2deb97[_0xfc67ad(0x270)](_0x546cfe[_0xfc67ad(0x28f)](_0x79baa6));return{'range':_0x546cfe,'currentIndex':_0x2b9266};}[_0x87b24e(0x328)](_0x26c33c){const _0x2b054a=_0x87b24e;if(!_0x26c33c[_0x2b054a(0x29f)][_0x2b054a(0x1f4)](_0x2b054a(0x2d4)))return;const _0x3096e0=_0x26c33c[_0x2b054a(0x23f)][_0x2b054a(0x1c0)](_0x2b054a(0x269)),_0x5d0d5e=_0x26c33c[_0x2b054a(0x23f)][_0x2b054a(0x1c0)](_0x2b054a(0x21f));this[_0x2b054a(0x1ef)](_0x3096e0,_0x2b054a(0x25f),(_0x19ab3c,_0x1dd2c9,_0x3a1839)=>{const _0x4d1506=_0x2b054a,_0x301412=this[_0x4d1506(0x27a)][_0x4d1506(0x1c0)](_0x1dd2c9);if(!_0x301412)return;const _0xbf037b=this[_0x4d1506(0x1d3)][_0x4d1506(0x1ec)](_0x301412[_0x4d1506(0x329)])[_0x4d1506(0x325)](_0x301412[_0x4d1506(0x24c)]);_0x301412[_0x4d1506(0x26c)][_0x4d1506(0x2b2)](_0x4fa426=>_0xbf037b[_0x4d1506(0x23e)](_0x4fa426,_0x4d1506(0x2dd))),this[_0x4d1506(0x27a)][_0x4d1506(0x250)](_0x1dd2c9),this[_0x4d1506(0x27a)][_0x4d1506(0x30b)](_0x3a1839,_0x301412);}),this[_0x2b054a(0x1ef)](_0x5d0d5e,_0x2b054a(0x25f),(_0x31af8e,_0x4c21d9,_0xf537)=>{const _0x17ae63=_0x2b054a,_0x474c1d=this[_0x17ae63(0x27a)][_0x17ae63(0x1c0)](_0x4c21d9);if(!_0x474c1d)return;const _0x40fe2c=this[_0x17ae63(0x1d3)][_0x17ae63(0x1ec)](_0x474c1d[_0x17ae63(0x329)])[_0x17ae63(0x325)](_0x474c1d[_0x17ae63(0x24c)]);_0x474c1d[_0x17ae63(0x26c)][_0x17ae63(0x2b2)](_0x356544=>_0x40fe2c[_0x17ae63(0x23e)](_0x356544,_0x17ae63(0x30c))),this[_0x17ae63(0x27a)][_0x17ae63(0x250)](_0x4c21d9),this[_0x17ae63(0x27a)][_0x17ae63(0x30b)](_0xf537,_0x474c1d);});}async[_0x87b24e(0x2de)](_0x1e0e2a){const _0x26de04=_0x87b24e;this[_0x26de04(0x2ca)][_0x26de04(0x29f)][_0x26de04(0x1c0)](_0x1169da)[_0x26de04(0x29e)](),this[_0x26de04(0x1c8)][_0x26de04(0x1da)](_0x26de04(0x2c7)),this[_0x26de04(0x1c8)][_0x26de04(0x290)](!0x0),await this[_0x26de04(0x246)]();try{await this[_0x26de04(0x1bf)][_0x26de04(0x288)](_0x1e0e2a)[_0x26de04(0x1fc)](),await this[_0x26de04(0x2e6)](_0x1e0e2a),this[_0x26de04(0x1e8)]('\x20');const {sessionId:_0x24cc2c}=this[_0x26de04(0x2ec)][_0x26de04(0x2fd)]();await this[_0x26de04(0x1d3)][_0x26de04(0x1c7)](_0x1e0e2a,_0x24cc2c),this[_0x26de04(0x1d3)][_0x26de04(0x2c8)]()&&this[_0x26de04(0x1d3)][_0x26de04(0x280)](_0x381c56(this[_0x26de04(0x2ca)][_0x26de04(0x232)],_0x26de04(0x2bd)));}catch(_0x522287){this[_0x26de04(0x1c8)][_0x26de04(0x249)]({'errorMessage':_0x381c56(this[_0x26de04(0x2ca)][_0x26de04(0x232)],_0x26de04(0x2f6)),'id':_0x1e0e2a}),this[_0x26de04(0x2cd)](new _0x219767(_0x26de04(0x1c2),this,{'error':_0x522287}));}finally{this[_0x26de04(0x2ca)][_0x26de04(0x29f)][_0x26de04(0x1c0)](_0x1ab538)[_0x26de04(0x236)][_0x26de04(0x258)](_0x26de04(0x28b)),this[_0x26de04(0x1c8)][_0x26de04(0x243)](),this[_0x26de04(0x1c8)][_0x26de04(0x1da)](_0x26de04(0x2ab)),this[_0x26de04(0x1c8)][_0x26de04(0x290)](!0x1);}}[_0x87b24e(0x214)](_0x2003f3){const _0x16c07e=_0x87b24e;this[_0x16c07e(0x1d3)]['id']===_0x2003f3&&this[_0x16c07e(0x2e6)]();}async[_0x87b24e(0x31a)](){const _0x4b1bf1=_0x87b24e,_0x2e7985=this[_0x4b1bf1(0x2ec)][_0x4b1bf1(0x230)]();this[_0x4b1bf1(0x1d3)]?.[_0x4b1bf1(0x2f0)](_0x2e7985),this[_0x4b1bf1(0x1d3)]?.[_0x4b1bf1(0x280)](_0x381c56(this[_0x4b1bf1(0x2ca)][_0x4b1bf1(0x232)],_0x4b1bf1(0x2bd)));}[_0x87b24e(0x1f7)](){const _0x20e153=_0x87b24e;this[_0x20e153(0x1d3)]?.[_0x20e153(0x227)]();}[_0x87b24e(0x2d6)](){const _0x1cf838=_0x87b24e;this[_0x1cf838(0x1c8)][_0x1cf838(0x2d6)]();}async[_0x87b24e(0x257)](){const _0x178043=_0x87b24e;await this[_0x178043(0x2e6)]();}async[_0x87b24e(0x200)]({message:_0x5b54e2,quickActionData:_0x31fce9}){const _0x509ae3=_0x87b24e;await this[_0x509ae3(0x31d)]({'userMessage':_0x5b54e2,'quickActionData':_0x31fce9});}[_0x87b24e(0x22e)](){const _0x2959ba=_0x87b24e,_0x165ac3=this[_0x2959ba(0x2ca)][_0x2959ba(0x31f)][_0x2959ba(0x1c0)](_0x2959ba(0x223));if(!_0x165ac3)throw new _0x219767(_0x2959ba(0x240),this);return _0x165ac3;}async[_0x87b24e(0x2e6)](_0x19ef6e){const _0x844007=_0x87b24e;try{this[_0x844007(0x1c8)][_0x844007(0x317)](),await this[_0x844007(0x1fd)](_0x19ef6e);}catch(_0x1877c5){this[_0x844007(0x1c8)][_0x844007(0x249)]({'errorMessage':_0x381c56(this[_0x844007(0x2ca)][_0x844007(0x232)],_0x844007(0x2c1)),'id':_0x19ef6e||_0x489566()}),console[_0x844007(0x305)](_0x1877c5),this[_0x844007(0x1d3)]=void 0x0,this[_0x844007(0x1c8)][_0x844007(0x25b)]();}}async[_0x87b24e(0x1fd)](_0x5793b4){const _0x3c6bd6=_0x87b24e,_0x3024ca=this[_0x3c6bd6(0x2ca)][_0x3c6bd6(0x29f)][_0x3c6bd6(0x1c0)](_0x1169da);let _0x2e1858;_0x3024ca[_0x3c6bd6(0x2c5)]&&_0x3024ca[_0x3c6bd6(0x29e)](),_0x5793b4||!this[_0x3c6bd6(0x1d3)]?_0x2e1858=this[_0x3c6bd6(0x2ca)][_0x3c6bd6(0x31f)][_0x3c6bd6(0x1c0)](_0x3c6bd6(0x1e9)):this[_0x3c6bd6(0x1c8)][_0x3c6bd6(0x274)]&&(_0x2e1858=this[_0x3c6bd6(0x1d3)][_0x3c6bd6(0x235)]['id']),await this[_0x3c6bd6(0x246)]();const _0x51bc06=this[_0x3c6bd6(0x22e)](),_0x328a3d=_0x5793b4||_0x489566();this[_0x3c6bd6(0x1d3)]=new _0x57bac1({'connector':this[_0x3c6bd6(0x1bf)],'chatModels':this[_0x3c6bd6(0x2fa)],'selectedModelId':_0x2e1858,'conversationId':_0x328a3d,'group':_0x51bc06,'getEditor':()=>_0x3a659a(this[_0x3c6bd6(0x2ca)])}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x1e6),(_0x290681,_0x138fa8)=>{const _0x4b1d4d=_0x3c6bd6;this[_0x4b1d4d(0x1c8)][_0x4b1d4d(0x2c0)](_0x138fa8),this[_0x4b1d4d(0x1c8)][_0x4b1d4d(0x211)](),this[_0x4b1d4d(0x1c8)][_0x4b1d4d(0x278)](),this[_0x4b1d4d(0x1c8)][_0x4b1d4d(0x27c)](),_0x5793b4||(this[_0x4b1d4d(0x1c8)][_0x4b1d4d(0x262)](),this[_0x4b1d4d(0x1d3)]?.[_0x4b1d4d(0x280)](_0x381c56(this[_0x4b1d4d(0x2ca)][_0x4b1d4d(0x232)],_0x4b1d4d(0x2bd))));}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x23a),(_0xf15c1f,_0x15f8f0)=>{const _0x33c851=_0x3c6bd6;this[_0x33c851(0x1c8)][_0x33c851(0x273)](_0x15f8f0[_0x33c851(0x2b8)]);}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x2d0),(_0x36454b,_0x5a0855)=>{const _0x1328e6=_0x3c6bd6;this[_0x1328e6(0x1c8)][_0x1328e6(0x1e7)](_0x5a0855);}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x1ca),()=>{const _0x79e03f=_0x3c6bd6;this[_0x79e03f(0x1c8)][_0x79e03f(0x22d)]({'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x322),()=>{const _0x41af16=_0x3c6bd6;this[_0x41af16(0x1c8)][_0x41af16(0x22d)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x1ea),(_0x33885f,_0x165120)=>{const _0x3c0190=_0x3c6bd6;this[_0x3c0190(0x1c8)][_0x3c0190(0x1e5)](_0x165120,{'isWebSearchEnabled':!0x0,'isReasoningEnabled':!0x1});}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x293),(_0x2366b4,_0x4b31ad)=>{const _0x4be6de=_0x3c6bd6;this[_0x4be6de(0x1c8)][_0x4be6de(0x1e5)](_0x4b31ad,{'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x0});}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x1be),()=>{const _0xb5d3d2=_0x3c6bd6;this[_0xb5d3d2(0x1c8)][_0xb5d3d2(0x300)]();}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x1c1),async()=>{const _0xde3449=_0x3c6bd6;await this[_0xde3449(0x1c8)][_0xde3449(0x26f)]();}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x28a),(_0x1a8da0,_0x428f7d)=>{const _0x5c1ecd=_0x3c6bd6;this[_0x5c1ecd(0x1c8)][_0x5c1ecd(0x2d1)](_0x428f7d['id']);}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x2bc),(_0x52f994,_0x6b0bf4,_0x5d0f48)=>{const _0x2d53f9=_0x3c6bd6;this[_0x2d53f9(0x1e8)](_0x6b0bf4,_0x5d0f48);}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x2cf),(_0x17b933,_0xc8865d)=>{const _0x4e69fe=_0x3c6bd6;_0x4e69fe(0x2b9)===_0xc8865d[_0x4e69fe(0x2af)]?this[_0x4e69fe(0x1c8)][_0x4e69fe(0x2ed)](_0xc8865d):this[_0x4e69fe(0x1c8)][_0x4e69fe(0x1d2)](_0xc8865d);}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x321),async(_0x542d0e,_0x5ddac3)=>{const _0x2eb71a=_0x3c6bd6;await this[_0x2eb71a(0x1f1)]({'reply':_0x5ddac3});}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x312),(_0x5dec24,{reply:_0x4365e7,index:_0x484655,state:_0x243774})=>{const _0x305cfc=_0x3c6bd6;this[_0x305cfc(0x1c8)][_0x305cfc(0x2dc)]({'id':_0x4365e7['id'],'index':_0x484655,'state':_0x243774});}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x1f2),(_0x19a230,_0x4e6d2a)=>{const _0x54811b=_0x3c6bd6;if(this[_0x54811b(0x1c8)][_0x54811b(0x239)](_0x4e6d2a[_0x54811b(0x2ad)],_0x4e6d2a[_0x54811b(0x285)]),_0x54811b(0x231)===_0x4e6d2a[_0x54811b(0x2ad)][_0x54811b(0x2af)]){const _0xc01c87=[..._0x3a659a(this[_0x54811b(0x2ca)])[_0x54811b(0x1f6)][_0x54811b(0x216)][_0x54811b(0x231)][_0x54811b(0x277)]()];this[_0x54811b(0x2ec)][_0x54811b(0x225)](_0xc01c87,_0x54811b(0x2bb)+this[_0x54811b(0x1d3)]?.['id']);}}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x210),(_0x42d13a,_0x596823)=>{const _0x46096a=_0x3c6bd6;this[_0x46096a(0x1c8)][_0x46096a(0x2a9)](_0x596823[_0x46096a(0x2d3)]),_0x46096a(0x2f7)==_0x596823[_0x46096a(0x2d3)]&&this[_0x46096a(0x1f7)](),_0x46096a(0x231)===_0x596823[_0x46096a(0x2af)]&&this[_0x46096a(0x2ec)][_0x46096a(0x2d7)](_0x46096a(0x2bb)+this[_0x46096a(0x1d3)]?.['id']);}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x2e3),(_0x35e2d9,_0x515749)=>{const _0x2767d6=_0x3c6bd6;this[_0x2767d6(0x1c8)][_0x2767d6(0x203)](_0x515749[_0x2767d6(0x2ad)][_0x2767d6(0x2d3)],_0x515749[_0x2767d6(0x285)]);}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x1ed),(_0x331df5,_0x17da0a)=>{const _0x2e0578=_0x3c6bd6;this[_0x2e0578(0x1c8)][_0x2e0578(0x244)](_0x17da0a[_0x2e0578(0x2b7)]);}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x271),(_0x51204b,_0x2c16fe)=>{const _0x4cc95f=_0x3c6bd6;this[_0x4cc95f(0x1c8)][_0x4cc95f(0x1fb)](_0x2c16fe[_0x4cc95f(0x266)]);}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x2ea),(_0x381ff5,_0x5cfa48)=>{const _0x251d88=_0x3c6bd6;this[_0x251d88(0x1c8)][_0x251d88(0x259)](_0x5cfa48[_0x251d88(0x301)],_0x5cfa48[_0x251d88(0x22b)],_0x5cfa48[_0x251d88(0x2f2)],_0x5cfa48[_0x251d88(0x318)]);}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x2b0),(_0x5d89d4,_0x51cee6)=>{const _0x136e98=_0x3c6bd6;this[_0x136e98(0x1c8)][_0x136e98(0x28c)](_0x51cee6[_0x136e98(0x301)],_0x51cee6[_0x136e98(0x20b)],_0x51cee6[_0x136e98(0x306)]);}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x315),(_0x4c9718,_0x223e90)=>{const _0x1d1507=_0x3c6bd6;this[_0x1d1507(0x1c8)][_0x1d1507(0x21e)](_0x223e90);}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x255),(_0x22b281,_0x483184)=>{const _0x3f72d1=_0x3c6bd6;this[_0x3f72d1(0x1c8)][_0x3f72d1(0x1ee)](_0x483184[_0x3f72d1(0x235)],_0x483184[_0x3f72d1(0x224)]);}),this[_0x3c6bd6(0x1d3)]['on'](_0x3c6bd6(0x305),(_0x26d7ec,{error:_0x3cc773,interactionId:_0x35d769,fileName:_0x3cc028,url:_0x2009f9,sourceId:_0x55711b,sourceLabel:_0x85a1eb})=>{const _0x1f4724=_0x3c6bd6,_0x78cc82=_0x35d769?_0x35d769+':'+_0x489566():_0x489566();_0x3cc773[_0x1f4724(0x2a0)][_0x1f4724(0x261)](_0x1f4724(0x2a3))?this[_0x1f4724(0x1c8)][_0x1f4724(0x30a)]({'staticMessage':_0x381c56(this[_0x1f4724(0x2ca)][_0x1f4724(0x232)],_0x1f4724(0x292)),'id':_0x78cc82}):_0x3cc773[_0x1f4724(0x2a0)][_0x1f4724(0x261)](_0x1f4724(0x221))||_0x3cc773[_0x1f4724(0x2a0)][_0x1f4724(0x261)](_0x1f4724(0x294))?(this[_0x1f4724(0x1c8)][_0x1f4724(0x249)]({'errorMessage':_0x381c56(this[_0x1f4724(0x2ca)][_0x1f4724(0x232)],_0x1f4724(0x2c1)),'id':_0x78cc82}),this[_0x1f4724(0x2cd)](_0x3cc773)):_0x3cc773[_0x1f4724(0x2a0)][_0x1f4724(0x261)](_0x1f4724(0x1df))?this[_0x1f4724(0x1c8)][_0x1f4724(0x249)]({'errorMessage':_0x381c56(this[_0x1f4724(0x2ca)][_0x1f4724(0x232)],_0x1f4724(0x2c4),_0x3cc028),'id':_0x78cc82}):_0x3cc773[_0x1f4724(0x2a0)][_0x1f4724(0x261)](_0x1f4724(0x2db))?this[_0x1f4724(0x1c8)][_0x1f4724(0x249)]({'errorMessage':_0x381c56(this[_0x1f4724(0x2ca)][_0x1f4724(0x232)],_0x1f4724(0x1c5),_0x2009f9),'id':_0x78cc82}):_0x3cc773[_0x1f4724(0x2a0)][_0x1f4724(0x261)](_0x1f4724(0x2f8))?this[_0x1f4724(0x1c8)][_0x1f4724(0x249)]({'errorMessage':_0x381c56(this[_0x1f4724(0x2ca)][_0x1f4724(0x232)],_0x1f4724(0x303)),'id':_0x78cc82}):_0x3cc773[_0x1f4724(0x2a0)][_0x1f4724(0x261)](_0x1f4724(0x2da))?this[_0x1f4724(0x1c8)][_0x1f4724(0x249)]({'errorMessage':_0x381c56(this[_0x1f4724(0x2ca)][_0x1f4724(0x232)],_0x1f4724(0x296)),'id':_0x78cc82}):_0x3cc773[_0x1f4724(0x2a0)][_0x1f4724(0x261)](_0x1f4724(0x2e4))?(_0x55711b&&this[_0x1f4724(0x1c8)][_0x1f4724(0x251)](_0x55711b),this[_0x1f4724(0x1c8)][_0x1f4724(0x249)]({'errorMessage':_0x381c56(this[_0x1f4724(0x2ca)][_0x1f4724(0x232)],_0x1f4724(0x1cd),_0x85a1eb||_0x1f4724(0x22b)),'id':_0x78cc82}),this[_0x1f4724(0x2cd)](_0x3cc773)):_0x3cc773[_0x1f4724(0x2a0)][_0x1f4724(0x261)](_0x1f4724(0x20f))?(this[_0x1f4724(0x1c8)][_0x1f4724(0x249)]({'errorMessage':_0x381c56(this[_0x1f4724(0x2ca)][_0x1f4724(0x232)],_0x1f4724(0x1f5)),'id':_0x78cc82}),this[_0x1f4724(0x2cd)](_0x3cc773)):_0x3cc773[_0x1f4724(0x2a0)][_0x1f4724(0x261)](_0x1f4724(0x2fb))?(this[_0x1f4724(0x1c8)][_0x1f4724(0x249)]({'errorMessage':_0x381c56(this[_0x1f4724(0x2ca)][_0x1f4724(0x232)],_0x1f4724(0x241)),'id':_0x78cc82}),this[_0x1f4724(0x2cd)](_0x3cc773)):_0x3cc773[_0x1f4724(0x2a0)][_0x1f4724(0x261)](_0x1f4724(0x2e7))?(this[_0x1f4724(0x1c8)][_0x1f4724(0x249)]({'errorMessage':_0x381c56(this[_0x1f4724(0x2ca)][_0x1f4724(0x232)],_0x1f4724(0x2ac)),'id':_0x78cc82}),this[_0x1f4724(0x2cd)](_0x3cc773)):_0x3cc773[_0x1f4724(0x2a0)][_0x1f4724(0x261)](_0x1f4724(0x207))?(this[_0x1f4724(0x1c8)][_0x1f4724(0x249)]({'errorMessage':_0x381c56(this[_0x1f4724(0x2ca)][_0x1f4724(0x232)],_0x1f4724(0x212)),'id':_0x78cc82}),this[_0x1f4724(0x2cd)](_0x3cc773)):_0x3cc773[_0x1f4724(0x2a0)][_0x1f4724(0x261)](_0x1f4724(0x291))?(this[_0x1f4724(0x1c8)][_0x1f4724(0x249)]({'errorMessage':_0x381c56(this[_0x1f4724(0x2ca)][_0x1f4724(0x232)],_0x1f4724(0x1fe)),'id':_0x78cc82}),this[_0x1f4724(0x2cd)](_0x3cc773)):_0x3cc773[_0x1f4724(0x2a0)][_0x1f4724(0x261)](_0x1f4724(0x2e1))?(this[_0x1f4724(0x1c8)][_0x1f4724(0x249)]({'errorMessage':_0x381c56(this[_0x1f4724(0x2ca)][_0x1f4724(0x232)],_0x1f4724(0x245)),'id':_0x78cc82}),this[_0x1f4724(0x2cd)](_0x3cc773)):(this[_0x1f4724(0x1c8)][_0x1f4724(0x249)]({'errorMessage':_0x381c56(this[_0x1f4724(0x2ca)][_0x1f4724(0x232)],_0x1f4724(0x1e4)),'id':_0x78cc82}),this[_0x1f4724(0x2cd)](_0x3cc773));}),await this[_0x3c6bd6(0x1d3)][_0x3c6bd6(0x1c4)](this[_0x3c6bd6(0x2ca)][_0x3c6bd6(0x31f)][_0x3c6bd6(0x1c0)](_0x3c6bd6(0x323))),_0x5793b4||await this[_0x3c6bd6(0x1d3)][_0x3c6bd6(0x256)]();}async[_0x87b24e(0x31d)]({userMessage:_0xd3358f,quickActionData:_0x28cad6}){const _0x67d9f6=_0x87b24e;if(!this[_0x67d9f6(0x1d3)])throw new _0x219767(_0x67d9f6(0x309));this[_0x67d9f6(0x1d3)][_0x67d9f6(0x282)]()&&await this[_0x67d9f6(0x1d3)][_0x67d9f6(0x31e)](this[_0x67d9f6(0x2ec)][_0x67d9f6(0x2fd)]()),this[_0x67d9f6(0x1d3)]['id']&&this[_0x67d9f6(0x1d3)][_0x67d9f6(0x24e)]&&await this[_0x67d9f6(0x1d3)][_0x67d9f6(0x26a)]({'userMessage':_0xd3358f,'quickActionData':_0x28cad6}),this[_0x67d9f6(0x1fa)]();}[_0x87b24e(0x1fa)](){const _0x1947d8=_0x87b24e,_0x477500=_0x3a659a(this[_0x1947d8(0x2ca)])[_0x1947d8(0x1f6)],_0x57990a=Array[_0x1947d8(0x218)](_0x477500[_0x1947d8(0x326)][_0x1947d8(0x217)](_0x4cfafd));_0x477500[_0x1947d8(0x1d6)](_0x45505e=>{const _0x3b1701=_0x1947d8;_0x57990a[_0x3b1701(0x2b2)](_0x402ff1=>_0x45505e[_0x3b1701(0x1f9)](_0x402ff1));});}[_0x87b24e(0x281)](){const _0xf628df=_0x87b24e;console[_0xf628df(0x1c9)](_0xf628df(0x1d9));}[_0x87b24e(0x279)](_0x280e86){const _0x1fc6f3=_0x87b24e;this[_0x1fc6f3(0x1c8)][_0x1fc6f3(0x23b)](_0x280e86);}[_0x87b24e(0x2cd)](_0x2550c7){const _0x53e238=_0x87b24e;_0x456fd9(_0x2550c7[_0x53e238(0x2a0)]);}[_0x87b24e(0x22f)](_0x496e93){const _0x3108d0=_0x87b24e;this[_0x3108d0(0x1d3)]?.[_0x3108d0(0x242)](_0x496e93);}[_0x87b24e(0x327)](){const _0x12f07f=_0x87b24e;this[_0x12f07f(0x1d3)]?.[_0x12f07f(0x22c)]();}[_0x87b24e(0x2fc)](){const _0x3051df=_0x87b24e;this[_0x3051df(0x1d3)]?.[_0x3051df(0x222)]();}[_0x87b24e(0x1bd)](_0x388fe3){const _0x9c109d=_0x87b24e,[_0x4d6a41,_0x208747]=_0x388fe3[_0x9c109d(0x1d8)](':'),_0x2b4f4b=this[_0x9c109d(0x1d3)][_0x9c109d(0x1ec)](_0x4d6a41),_0x117206=_0x2b4f4b[_0x9c109d(0x325)](_0x208747);return{'interaction':_0x2b4f4b,'reply':_0x117206};}[_0x87b24e(0x2a6)](_0x1ed912,_0x161f4f=!0x1){const _0x5ac4fd=_0x87b24e,_0x3f92a1=_0x3a659a(this[_0x5ac4fd(0x2ca)]),_0xdf7b2c={'target':_0x3f92a1[_0x5ac4fd(0x208)][_0x5ac4fd(0x236)][_0x5ac4fd(0x2cb)][_0x5ac4fd(0x20c)](_0x3f92a1[_0x5ac4fd(0x208)][_0x5ac4fd(0x304)][_0x5ac4fd(0x27e)](_0x1ed912)),'viewportOffset':{'top':0x96,'left':0x0,'bottom':0x32,'right':0x0},'ancestorOffset':0x14,'alignToTop':_0x161f4f};_0x161f4f&&(_0xdf7b2c[_0x5ac4fd(0x2eb)]=!0x0),_0x5724a9(_0xdf7b2c);}[_0x87b24e(0x1e8)](_0x37a6ef,_0x4c2e1d=!0x1){const _0x1bfcb9=_0x87b24e;this[_0x1bfcb9(0x1c8)][_0x1bfcb9(0x2bc)](_0x37a6ef||_0x381c56(this[_0x1bfcb9(0x2ca)][_0x1bfcb9(0x232)],_0x1bfcb9(0x206)),_0x4c2e1d);}async[_0x87b24e(0x1f1)]({reply:_0x254cfb,renderingStrategy:_0x2d3c6c}){const _0x38787d=_0x87b24e,{id:_0x12aec5,isDone:_0x5b0a5c,type:_0x3868d8,parsedContent:_0xadc5b3}=_0x254cfb;if(_0x38787d(0x2a5)===_0x3868d8){const _0x443170=_0x254cfb[_0x38787d(0x254)]({'showDiff':this[_0x38787d(0x1c8)][_0x38787d(0x275)]});await this[_0x38787d(0x1c8)][_0x38787d(0x2f4)]({'id':_0x12aec5,'parts':_0x443170,'renderingStrategy':_0x2d3c6c,'isDone':_0x5b0a5c});}else _0x38787d(0x2b9)===_0x3868d8&&await this[_0x38787d(0x1c8)][_0x38787d(0x2df)]({'id':_0x12aec5,'parsedContent':_0xadc5b3,'renderingStrategy':_0x2d3c6c,'isDone':_0x5b0a5c});_0x5b0a5c&&_0x254cfb[_0x38787d(0x2b1)][_0x38787d(0x324)]>0x0&&this[_0x38787d(0x1c8)][_0x38787d(0x26b)](_0x12aec5,_0x254cfb[_0x38787d(0x2b1)]);}async[_0x87b24e(0x246)](){const _0xfb5e13=_0x87b24e,_0xc9eaf0=this[_0xfb5e13(0x1d3)]?.[_0xfb5e13(0x2d2)];_0xc9eaf0&&(_0xc9eaf0[_0xfb5e13(0x1ff)](),this[_0xfb5e13(0x1c8)][_0xfb5e13(0x205)](_0xc9eaf0));}async[_0x87b24e(0x2f1)](){const _0x51b021=_0x87b24e,_0xa164d6=this[_0x51b021(0x1d3)]?.[_0x51b021(0x2d2)];if(_0xa164d6){for await(const _0x4b4aec of _0xa164d6[_0x51b021(0x2ef)])await this[_0x51b021(0x1f1)]({'reply':_0x4b4aec,'renderingStrategy':_0x51b021(0x2c7)});}}[_0x87b24e(0x26e)](_0x6bbc5e){const _0x481e53=_0x87b24e,_0x25a00d={'positiveCount':_0x6bbc5e[_0x481e53(0x21b)][_0x481e53(0x302)](_0x3aa3bb=>_0x481e53(0x30c)===_0x3aa3bb[_0x481e53(0x308)])[_0x481e53(0x324)],'totalCount':_0x6bbc5e[_0x481e53(0x21b)][_0x481e53(0x324)],'modificationId':_0x6bbc5e['id']},_0x3e1395=this[_0x481e53(0x1d3)][_0x481e53(0x1ec)](_0x6bbc5e[_0x481e53(0x329)])[_0x481e53(0x220)];this[_0x481e53(0x1bf)][_0x481e53(0x2e8)](this[_0x481e53(0x1d3)]['id'],_0x3e1395,_0x25a00d);}}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x24ff1c=_0xb60d;function _0x3680(){const _0x53ea09=['removeItem','plugins','toggleSuggestionDisplayMode','contextItems','createConversation','clear','3197922tysUZQ','_interactionPromiseResolver','TrackChanges','streaming','423067BaFIpA','AIChatUI','renderingStrategy','clearConversationContextUI','showDiff','addFeedItemUserMessage','updateSuggestionPartState','updateFeedItemAIReplySources','addContextItem','requires','options','enableControls','get','ai.availableReplyActions','abort','length','has','last','disableControls','setLoadingMessage','_promiseQueue','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REGULAR','8wepRIR','setModelList','removeFeedInteraction','stopInteraction','addItem','filter','pluginName','isDone','addFeedItemAISuggestion','quickActionData','remove','focusPromptInput','ai-suggestion-reply','interaction-header','updateCapabilities','isVisible','value','addTab','setIsMaximized','capabilities','setConversationContext','isOfficialPlugin','startInteraction','updateFeedInteractionHeader','availableModels','setModel','isPending','set','_getInputPlaceholder','locale','userMessage','setFeedItemRenderingStrategy','674451CeLLxR','_getLoadingMessage','clearPendingContextUI','label','AI_CHAT_HEADING','context','isWebSearchEnabled','trackChanges','scrollToSuggestion','values','enableModelSelector','startAutoScroll','_isTrackChangesCommandValueBound','markFeedItemAsDone','setContextItemLoading','resetMessageInput','disableModelSelector','showResizeButton','displayedPrompt','config','chatHeader','setSelectedModel','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH','addFeedItemAIReply','stopAutoScroll','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH','feedItemRenderingStrategy','delegate','updateReplyItem','50reHPvg','setConversationTitle','closeSourceResourceBalloon','isModelAvailable','setInputPlaceholder','updateWebSources','updateFeedItemAIReplyContent','setWebSearch','isLoading','AI_CHAT_FEED_LOADING_MESSAGE_REASONING','_view','updateFeedItemAIReplySuggestionPartState','enqueue','isMaximized','then','ai.chat.context.searchInputVisibleFrom','removeContextItem','<p>','addFeedItemStaticMessage','isReasoningEnabled','AI_CHAT_WELCOME_MESSAGE','chatFeed','interactionId','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH_REASONING','_animateConversationTitle','resetConversationTitle','commands','AITabs','ai.chat.models.modelSelectorAlwaysVisible','populateSourceResourceBalloon','setReasoning','getItemIds','updateFeedItemAIReplySuggestionContent','from','chatControls','user-message','addFeedInteractionHeader','finishInteraction','toggleLoadingSkeleton','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH_REASONING','markItemAsDone','6vrXwNx','children','AI_CHAT_FEED_LOADING_MESSAGE_REGULAR','setIsUploadInProgress','1612416mAqtYZ','view','bind','chat','isBusy','setAddContextOptions','areActionsDisabled','addFeedItemError','updateResourceState','updateSuggestionItem','conversation-start','1179130IcReyy','isTrackChangesOn','destroy','forEach','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REASONING','find','</p>','isDisabled','error-message','_titleAnimationInterval','queueEmptyPromise','2098816iaYnDD','insertSuggestion','scrollFeedToSuggestion','2690862VQFARn','isPremiumPlugin','startsWith','ai-reply'];_0x3680=function(){return _0x53ea09;};return _0x3680();}function _0xb60d(_0x33f073,_0x31abea){const _0x368018=_0x3680();return _0xb60d=function(_0xb60d76,_0xf0a1a5){_0xb60d76=_0xb60d76-0xc2;let _0x115a8b=_0x368018[_0xb60d76];return _0x115a8b;},_0xb60d(_0x33f073,_0x31abea);}(function(_0x1c60f3,_0x3f77d2){const _0x39b7e1=_0xb60d,_0x17866d=_0x1c60f3();while(!![]){try{const _0x2e8e85=-parseInt(_0x39b7e1(0x14d))/0x1+parseInt(_0x39b7e1(0x126))/0x2+parseInt(_0x39b7e1(0x13f))/0x3+parseInt(_0x39b7e1(0x163))/0x4*(-parseInt(_0x39b7e1(0x131))/0x5)+parseInt(_0x39b7e1(0x122))/0x6*(-parseInt(_0x39b7e1(0x149))/0x7)+-parseInt(_0x39b7e1(0x13c))/0x8+parseInt(_0x39b7e1(0xdc))/0x9*(parseInt(_0x39b7e1(0xf9))/0xa);if(_0x2e8e85===_0x3f77d2)break;else _0x17866d['push'](_0x17866d['shift']());}catch(_0x12152d){_0x17866d['push'](_0x17866d['shift']());}}}(_0x3680,0x71444));import{ContextPlugin as _0x15a0e6}from'ckeditor5/src/core.js';import{_isMotionReduced as _0x33ed22}from'ckeditor5/src/utils.js';import{AIChatView as _0x4ebbf3}from'./ui/aichatview.js';import{AITabs as _0x308e0a}from'../aitabs/aitabs.js';import{getTranslation as _0x434553}from'../aicore/utils/common-translations.js';import{IconAIChat as _0x4115a4}from'ckeditor5/src/icons.js';import{AIChatFeedInteractionHeaderView as _0x557a84}from'./ui/feed/aichatfeedinteractionheaderview.js';import{PromiseQueue as _0x2bd74b}from'./utils/promisequeue.js';import{AI_CHAT_UI_EVENT_NAMES as _0x4aab44}from'./utils/eventnames.js';import'../../theme/aichat/aichat.css';import{getEditorFromContext as _0x5c2e4a}from'../aicore/utils/geteditorfromcontext.js';import{AI_REPLY_ACTIONS as _0x37a15a}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';export class AIChatUI extends _0x15a0e6{static get[_0x24ff1c(0x156)](){return[_0x308e0a];}[_0x24ff1c(0x103)];static get[_0x24ff1c(0xc2)](){const _0xd7aeaf=_0x24ff1c;return _0xd7aeaf(0x14e);}static get[_0x24ff1c(0xd1)](){return!0x0;}static get[_0x24ff1c(0x140)](){return!0x0;}[_0x24ff1c(0xf6)]=_0x24ff1c(0x14c);[_0x24ff1c(0x151)]=!0x0;[_0x24ff1c(0x161)];[_0x24ff1c(0x14a)];[_0x24ff1c(0x13a)]=void 0x0;[_0x24ff1c(0xe8)]=!0x1;constructor(_0x1ebfd5){const _0x18934c=_0x24ff1c;super(_0x1ebfd5);const _0x362792=this[_0x18934c(0xe1)][_0x18934c(0x144)][_0x18934c(0x159)](_0x18934c(0x114));this[_0x18934c(0xd7)](_0x18934c(0x12a),!0x1),this[_0x18934c(0x161)]=new _0x2bd74b(),this[_0x18934c(0x103)]=new _0x4ebbf3(this[_0x18934c(0xe1)][_0x18934c(0xd9)],{'showResizeButton':_0x362792[_0x18934c(0xed)],'contextResourcesSearchInputVisibleFrom':this[_0x18934c(0xe1)][_0x18934c(0xef)][_0x18934c(0x159)](_0x18934c(0x108))}),this[_0x18934c(0x103)][_0x18934c(0xf7)](..._0x4aab44)['to'](this),this[_0x18934c(0x103)]['on'](_0x18934c(0x145),(_0x743aba,{showDiff:_0x4dba20})=>{const _0x589b9d=_0x18934c;this[_0x589b9d(0x151)]=_0x4dba20;}),_0x362792[_0x18934c(0x127)][_0x18934c(0xcd)]({'id':_0x18934c(0x129),'buttonLabel':_0x434553(this[_0x18934c(0xe1)][_0x18934c(0xd9)],_0x18934c(0xe0)),'buttonIcon':_0x4115a4,'order':0x0,'content':this[_0x18934c(0x103)]}),this[_0x18934c(0x103)][_0x18934c(0x11b)][_0x18934c(0x128)](_0x18934c(0x101))['to'](this,_0x18934c(0x12a),_0x31b68f=>_0x31b68f),this[_0x18934c(0x103)][_0x18934c(0x10e)][_0x18934c(0x128)](_0x18934c(0xd6))['to'](this,_0x18934c(0x12a),_0x3dab1a=>_0x3dab1a),this[_0x18934c(0x103)][_0x18934c(0x11b)][_0x18934c(0xfd)](this[_0x18934c(0xd8)]()),this[_0x18934c(0x128)](_0x18934c(0xfc))['to'](this[_0x18934c(0x103)][_0x18934c(0x11b)],_0x18934c(0xfc));}[_0x24ff1c(0x133)](){const _0x3b0ec2=_0x24ff1c;super[_0x3b0ec2(0x133)](),this[_0x3b0ec2(0x13a)]&&clearInterval(this[_0x3b0ec2(0x13a)]);}[_0x24ff1c(0x147)](_0x3a6ed6){const _0x169573=_0x24ff1c;this[_0x169573(0x103)][_0x169573(0x10e)][_0x169573(0x148)](),this[_0x169573(0x103)][_0x169573(0x11b)][_0x169573(0xe6)](),this[_0x169573(0x103)][_0x169573(0x11b)][_0x169573(0x164)](_0x3a6ed6[_0x169573(0xd4)],!this[_0x169573(0xe1)][_0x169573(0xef)][_0x169573(0x159)](_0x169573(0x115))),this[_0x169573(0x10b)]({'id':_0x169573(0x130),'staticMessage':_0x434553(this[_0x169573(0xe1)][_0x169573(0xd9)],_0x169573(0x10d))});}[_0x24ff1c(0x10b)]({id:_0x5f3ba4,staticMessage:_0x42d5b0}){const _0x2ed933=_0x24ff1c;this[_0x2ed933(0x103)][_0x2ed933(0x10e)][_0x2ed933(0x167)](_0x2ed933(0x142),{'id':_0x5f3ba4,'initialContent':_0x2ed933(0x10a)+_0x42d5b0+_0x2ed933(0x137)});}[_0x24ff1c(0x152)](_0x481eb3){const _0x345cf6=_0x24ff1c,_0x24c2b0=_0x481eb3[_0x345cf6(0xc5)]?.[_0x345cf6(0xee)]||_0x481eb3[_0x345cf6(0xda)];this[_0x345cf6(0x103)][_0x345cf6(0x10e)][_0x345cf6(0x167)](_0x345cf6(0x11c),{'contextItems':Array[_0x345cf6(0x11a)](_0x481eb3[_0x345cf6(0x146)][_0x345cf6(0xe5)]()),'initialContent':_0x345cf6(0x10a)+_0x24c2b0+_0x345cf6(0x137),'id':_0x481eb3['id']});}[_0x24ff1c(0x12d)]({errorMessage:_0x45848f,id:_0x222d3d}){const _0x3728cc=_0x24ff1c;this[_0x3728cc(0x103)][_0x3728cc(0x10e)][_0x3728cc(0x167)](_0x3728cc(0x139),{'initialContent':_0x3728cc(0x10a)+_0x45848f+_0x3728cc(0x137),'id':_0x222d3d});}[_0x24ff1c(0xf3)](_0x3a7f97){const _0x75609d=_0x24ff1c;return this[_0x75609d(0x161)][_0x75609d(0x105)](async()=>{const _0x4f2370=_0x75609d;this[_0x4f2370(0x103)][_0x4f2370(0x10e)][_0x4f2370(0x167)](_0x4f2370(0x142),{'id':_0x3a7f97[_0x4f2370(0x10f)]+':'+_0x3a7f97['id']}),this[_0x4f2370(0x160)](null);});}async[_0x24ff1c(0xc4)](_0x591202){const _0x1ca7fb=_0x24ff1c,_0x1a0708=_0x5c2e4a(this[_0x1ca7fb(0xe1)]);let _0x4de701=_0x1a0708[_0x1ca7fb(0xef)][_0x1ca7fb(0x159)](_0x1ca7fb(0x15a))||[..._0x37a15a];if(_0x1a0708[_0x1ca7fb(0x144)][_0x1ca7fb(0x15d)](_0x1ca7fb(0x14b))){if(!this[_0x1ca7fb(0xe8)]){this[_0x1ca7fb(0xe8)]=!0x0;const _0x439395=_0x1a0708[_0x1ca7fb(0x113)][_0x1ca7fb(0x159)](_0x1ca7fb(0xe3));this[_0x1ca7fb(0x103)][_0x1ca7fb(0x10e)][_0x1ca7fb(0x128)](_0x1ca7fb(0x132))['to'](_0x439395,_0x1ca7fb(0xcc));}}else _0x4de701=_0x4de701[_0x1ca7fb(0x168)](_0x2b8919=>_0x1ca7fb(0x13d)!=_0x2b8919);return this[_0x1ca7fb(0x161)][_0x1ca7fb(0x105)](async()=>{const _0x56e499=_0x1ca7fb;this[_0x56e499(0x103)][_0x56e499(0x10e)][_0x56e499(0x167)](_0x56e499(0xc8),{'id':_0x591202[_0x56e499(0x10f)]+':'+_0x591202['id'],'areActionsDisabled':_0x591202[_0x56e499(0x12c)],'showDiff':this[_0x56e499(0x151)],'availableActions':_0x4de701}),this[_0x56e499(0x160)](null);});}[_0x24ff1c(0x11d)](_0x3d8ebd,_0x1252f7){const _0x370b42=_0x24ff1c,_0x25a83f=this[_0x370b42(0x103)][_0x370b42(0x10e)][_0x370b42(0x123)][_0x370b42(0x15e)];if(_0x25a83f instanceof _0x557a84)return this[_0x370b42(0x103)][_0x370b42(0x10e)][_0x370b42(0x123)][_0x370b42(0xc6)](_0x25a83f),void this[_0x370b42(0x103)][_0x370b42(0x10e)][_0x370b42(0x167)](_0x370b42(0xc9),{'id':_0x3d8ebd['id'],'capabilities':{'isWebSearchEnabled':_0x25a83f[_0x370b42(0xcf)][_0x370b42(0xe2)]||_0x1252f7[_0x370b42(0xe2)],'isReasoningEnabled':_0x25a83f[_0x370b42(0xcf)][_0x370b42(0x10c)]||_0x1252f7[_0x370b42(0x10c)]}});this[_0x370b42(0x103)][_0x370b42(0x10e)][_0x370b42(0x167)](_0x370b42(0xc9),{'id':_0x3d8ebd['id'],'capabilities':_0x1252f7});}[_0x24ff1c(0xd3)](_0x22262c){const _0x5671df=_0x24ff1c,_0x22c404=this[_0x5671df(0x103)][_0x5671df(0x10e)][_0x5671df(0x123)][_0x5671df(0x136)](_0x44a4eb=>_0x44a4eb[_0x5671df(0x157)]['id']==_0x22262c['id']&&_0x44a4eb instanceof _0x557a84);_0x22c404&&_0x22c404[_0x5671df(0xd7)](_0x5671df(0xcb),_0x22262c[_0x5671df(0xcb)]);}async[_0x24ff1c(0xff)](_0x34022e){const _0x413d75=_0x24ff1c,_0x5008e2=_0x34022e[_0x413d75(0x14f)]||this[_0x413d75(0xf6)];return this[_0x413d75(0x161)][_0x413d75(0x105)](async _0xc6a22b=>{const _0x542428=_0x413d75;await this[_0x542428(0x103)][_0x542428(0x10e)][_0x542428(0xf8)]({..._0x34022e,'abortSignal':_0xc6a22b,'renderingStrategy':_0x5008e2}),_0x34022e[_0x542428(0xc3)]&&this[_0x542428(0xe9)](_0x34022e['id']);});}[_0x24ff1c(0x154)](_0x38a473,_0x2a2ab8){const _0x4bcbfa=_0x24ff1c;this[_0x4bcbfa(0x103)][_0x4bcbfa(0x10e)][_0x4bcbfa(0xfe)](_0x38a473,_0x2a2ab8);}async[_0x24ff1c(0x119)](_0x18d56e){const _0x73f52d=_0x24ff1c,_0x41ea26=_0x18d56e[_0x73f52d(0x14f)]||this[_0x73f52d(0xf6)];return this[_0x73f52d(0x161)][_0x73f52d(0x105)](async _0x3c0b4f=>{const _0x4889ee=_0x73f52d;await this[_0x4889ee(0x103)][_0x4889ee(0x10e)][_0x4889ee(0x12f)]({..._0x18d56e,'abortSignal':_0x3c0b4f,'renderingStrategy':_0x41ea26}),_0x18d56e[_0x4889ee(0xc3)]&&this[_0x4889ee(0xe9)](_0x18d56e['id']);});}[_0x24ff1c(0x104)](_0x4c6ab1){const _0x20c1ba=_0x24ff1c;this[_0x20c1ba(0x103)][_0x20c1ba(0x10e)][_0x20c1ba(0x153)](_0x4c6ab1);}[_0x24ff1c(0xe9)](_0x4e3d90){const _0x52d667=_0x24ff1c;this[_0x52d667(0x103)][_0x52d667(0x10e)][_0x52d667(0x121)](_0x4e3d90);}[_0x24ff1c(0x165)](_0x334db0){const _0xb9dd38=_0x24ff1c;this[_0xb9dd38(0x103)][_0xb9dd38(0x10e)][_0xb9dd38(0x118)]()[_0xb9dd38(0x168)](_0x1cd066=>_0x1cd066[_0xb9dd38(0x141)](_0x334db0))[_0xb9dd38(0x134)](_0xd2f69=>this[_0xb9dd38(0x103)][_0xb9dd38(0x10e)][_0xb9dd38(0x143)](_0xd2f69));}[_0x24ff1c(0xd2)](){const _0x1502b4=_0x24ff1c;this[_0x1502b4(0x160)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x1}),this[_0x1502b4(0x103)][_0x1502b4(0x11b)][_0x1502b4(0xec)](!this[_0x1502b4(0xe1)][_0x1502b4(0xef)][_0x1502b4(0x159)](_0x1502b4(0x115))),this[_0x1502b4(0x12a)]=!0x0,this[_0x1502b4(0x103)][_0x1502b4(0x10e)][_0x1502b4(0xe7)]();}[_0x24ff1c(0x166)](_0x43f629){const _0x322022=_0x24ff1c;this[_0x322022(0x161)][_0x322022(0x15b)](),this[_0x322022(0x103)][_0x322022(0x10e)][_0x322022(0x118)]()[_0x322022(0x168)](_0x1efeae=>_0x1efeae[_0x322022(0x141)](_0x43f629['id']))[_0x322022(0x134)](_0xff4f95=>this[_0x322022(0xe9)](_0xff4f95)),this[_0x322022(0x12a)]=!0x1,this[_0x322022(0x103)][_0x322022(0x10e)][_0x322022(0xf4)]();}async[_0x24ff1c(0x11e)](){const _0x1883f8=_0x24ff1c;return this[_0x1883f8(0x161)][_0x1883f8(0x13b)][_0x1883f8(0x107)](()=>{const _0x4bb367=_0x1883f8;this[_0x4bb367(0x12a)]=!0x1,this[_0x4bb367(0x103)][_0x4bb367(0x10e)][_0x4bb367(0xf4)]();});}[_0x24ff1c(0x155)](_0x2e5db6,_0x4a3a3e){const _0x25d39a=_0x24ff1c;this[_0x25d39a(0x103)][_0x25d39a(0x11b)][_0x25d39a(0x155)](_0x2e5db6,_0x4a3a3e);}[_0x24ff1c(0x109)](_0x1a4fd9){const _0x32dbf8=_0x24ff1c;this[_0x32dbf8(0x103)][_0x32dbf8(0x11b)][_0x32dbf8(0x109)](_0x1a4fd9);}[_0x24ff1c(0xea)](_0x5612d2,_0x3935a7){const _0x24694e=_0x24ff1c;this[_0x24694e(0x103)][_0x24694e(0x11b)][_0x24694e(0xea)](_0x5612d2,_0x3935a7);}[_0x24ff1c(0x125)](_0x430d4f){const _0x5ccc9a=_0x24ff1c;this[_0x5ccc9a(0x103)][_0x5ccc9a(0x11b)][_0x5ccc9a(0x125)](_0x430d4f);}[_0x24ff1c(0xd0)](_0x282294){const _0x536880=_0x24ff1c;this[_0x536880(0x103)][_0x536880(0x11b)][_0x536880(0xd0)](_0x282294);}[_0x24ff1c(0xde)](){const _0x53180e=_0x24ff1c;this[_0x53180e(0x103)][_0x53180e(0x11b)][_0x53180e(0xde)]();}[_0x24ff1c(0x150)](){const _0x516b65=_0x24ff1c;this[_0x516b65(0x103)][_0x516b65(0x11b)][_0x516b65(0x150)]();}[_0x24ff1c(0x12e)](_0x41721d,_0x40a5e9,_0x905ff0){const _0x16298e=_0x24ff1c;this[_0x16298e(0x103)][_0x16298e(0x11b)][_0x16298e(0x12e)](_0x41721d,_0x40a5e9,_0x905ff0);}[_0x24ff1c(0xeb)](){const _0x380427=_0x24ff1c;this[_0x380427(0x103)][_0x380427(0x11b)][_0x380427(0xeb)](),this[_0x380427(0x103)][_0x380427(0x11b)][_0x380427(0xfd)](this[_0x380427(0xd8)]());}[_0x24ff1c(0x12b)](_0x29eed2){const _0x39a226=_0x24ff1c;this[_0x39a226(0x103)][_0x39a226(0x11b)][_0x39a226(0x12b)](_0x29eed2);}[_0x24ff1c(0xca)](_0x877475){const _0xb42d02=_0x24ff1c;this[_0xb42d02(0x103)][_0xb42d02(0x11b)][_0xb42d02(0x100)](_0x877475[_0xb42d02(0xe2)]),this[_0xb42d02(0x103)][_0xb42d02(0x11b)][_0xb42d02(0x117)](_0x877475[_0xb42d02(0x10c)]),this[_0xb42d02(0x103)][_0xb42d02(0x11b)][_0xb42d02(0xfd)](this[_0xb42d02(0xd8)](_0x877475));}[_0x24ff1c(0xf1)](_0x25342d,_0x2bd575){const _0x362ef8=_0x24ff1c;this[_0x362ef8(0x103)][_0x362ef8(0x11b)][_0x362ef8(0xd5)](_0x25342d),_0x2bd575&&this[_0x362ef8(0x103)][_0x362ef8(0x11b)][_0x362ef8(0xec)](!0x1);}[_0x24ff1c(0xdb)](_0x3fe981){const _0x4759bd=_0x24ff1c;this[_0x4759bd(0xf6)]=_0x3fe981;}[_0x24ff1c(0x11f)](_0x27f734){const _0x5dcbb4=_0x24ff1c;this[_0x5dcbb4(0x103)][_0x5dcbb4(0x10e)][_0x5dcbb4(0x11f)](_0x27f734);}[_0x24ff1c(0x112)](){const _0x340d44=_0x24ff1c;this[_0x340d44(0xfa)](_0x434553(this[_0x340d44(0xe1)][_0x340d44(0xd9)],_0x340d44(0xe0)));}[_0x24ff1c(0xfa)](_0x39a87c,_0x54df46=!0x1){const _0x1bbbea=_0x24ff1c;if(_0x54df46&&!_0x33ed22()&&_0x39a87c[_0x1bbbea(0x15c)])return this[_0x1bbbea(0x103)][_0x1bbbea(0xf0)][_0x1bbbea(0xdf)]='',void this[_0x1bbbea(0x111)](_0x39a87c);this[_0x1bbbea(0x103)][_0x1bbbea(0xf0)][_0x1bbbea(0xdf)]=_0x39a87c;}[_0x24ff1c(0x160)](_0x2b8463){const _0x1131e9=_0x24ff1c,_0x18b26b=this[_0x1131e9(0xdd)](_0x2b8463);this[_0x1131e9(0x103)][_0x1131e9(0x10e)][_0x1131e9(0x160)](_0x18b26b);}[_0x24ff1c(0x111)](_0xe70ec2){const _0x14eb94=_0x24ff1c;let _0xd0d36b=0x0;clearInterval(this[_0x14eb94(0x13a)]),this[_0x14eb94(0x13a)]=setInterval(()=>{const _0x401ce7=_0x14eb94;this[_0x401ce7(0x103)][_0x401ce7(0xf0)][_0x401ce7(0xdf)]=this[_0x401ce7(0x103)][_0x401ce7(0xf0)][_0x401ce7(0xdf)]+_0xe70ec2[_0xd0d36b],_0xd0d36b++,_0xd0d36b===_0xe70ec2[_0x401ce7(0x15c)]&&clearInterval(this[_0x401ce7(0x13a)]);},0x1e);}[_0x24ff1c(0xce)](_0x5a2570){const _0x4a4424=_0x24ff1c;this[_0x4a4424(0x103)][_0x4a4424(0xf0)][_0x4a4424(0x106)]=_0x5a2570;}[_0x24ff1c(0xdd)](_0x30e63d){const _0x214c67=_0x24ff1c;return _0x30e63d?_0x30e63d[_0x214c67(0xe2)]&&_0x30e63d[_0x214c67(0x10c)]?_0x434553(this[_0x214c67(0xe1)][_0x214c67(0xd9)],_0x214c67(0x110)):_0x30e63d[_0x214c67(0xe2)]?_0x434553(this[_0x214c67(0xe1)][_0x214c67(0xd9)],_0x214c67(0xf2)):_0x30e63d[_0x214c67(0x10c)]?_0x434553(this[_0x214c67(0xe1)][_0x214c67(0xd9)],_0x214c67(0x102)):_0x434553(this[_0x214c67(0xe1)][_0x214c67(0xd9)],_0x214c67(0x124)):'';}[_0x24ff1c(0xd8)](_0x37939b){const _0x4b73e2=_0x24ff1c;return _0x37939b?_0x37939b[_0x4b73e2(0xe2)]&&_0x37939b[_0x4b73e2(0x10c)]?_0x434553(this[_0x4b73e2(0xe1)][_0x4b73e2(0xd9)],_0x4b73e2(0x120)):_0x37939b[_0x4b73e2(0xe2)]?_0x434553(this[_0x4b73e2(0xe1)][_0x4b73e2(0xd9)],_0x4b73e2(0xf5)):_0x37939b[_0x4b73e2(0x10c)]?_0x434553(this[_0x4b73e2(0xe1)][_0x4b73e2(0xd9)],_0x4b73e2(0x135)):_0x434553(this[_0x4b73e2(0xe1)][_0x4b73e2(0xd9)],_0x4b73e2(0x162)):_0x434553(this[_0x4b73e2(0xe1)][_0x4b73e2(0xd9)],_0x4b73e2(0x162));}[_0x24ff1c(0x116)](_0x3adef7,_0x282037,_0x61e14,_0x49ed08){const _0x1e5bbe=_0x24ff1c;this[_0x1e5bbe(0x103)][_0x1e5bbe(0x116)](_0x3adef7,_0x282037,_0x61e14,_0x49ed08);}[_0x24ff1c(0xfb)](_0x394ecb){const _0x17462a=_0x24ff1c;this[_0x17462a(0x103)][_0x17462a(0xfb)](_0x394ecb);}[_0x24ff1c(0xc7)](){const _0x108ea6=_0x24ff1c;this[_0x108ea6(0x103)][_0x108ea6(0x11b)][_0x108ea6(0xc7)]();}[_0x24ff1c(0x13e)](_0x4e90e9,_0x4bf7b7){const _0x533779=_0x24ff1c;this[_0x533779(0x103)][_0x533779(0x10e)][_0x533779(0xe4)](_0x4e90e9,_0x4bf7b7);}[_0x24ff1c(0xe7)](){const _0x4596bd=_0x24ff1c;this[_0x4596bd(0x103)][_0x4596bd(0x10e)][_0x4596bd(0xe7)]();}[_0x24ff1c(0x15f)](){const _0x11b1e2=_0x24ff1c;this[_0x11b1e2(0x103)][_0x11b1e2(0x11b)][_0x11b1e2(0x138)]=!0x0;}[_0x24ff1c(0x158)](){const _0x3c4eb8=_0x24ff1c;this[_0x3c4eb8(0x103)][_0x3c4eb8(0x11b)][_0x3c4eb8(0x138)]=!0x1;}}
23
+ const _0x1807d3=_0x27bc;(function(_0x40e89b,_0x2c5a09){const _0x4c38bf=_0x27bc,_0x1527ad=_0x40e89b();while(!![]){try{const _0x331584=parseInt(_0x4c38bf(0x1d3))/0x1*(-parseInt(_0x4c38bf(0x1f8))/0x2)+-parseInt(_0x4c38bf(0x19d))/0x3+-parseInt(_0x4c38bf(0x1a6))/0x4*(-parseInt(_0x4c38bf(0x18b))/0x5)+-parseInt(_0x4c38bf(0x1aa))/0x6*(parseInt(_0x4c38bf(0x1a9))/0x7)+-parseInt(_0x4c38bf(0x1b7))/0x8*(-parseInt(_0x4c38bf(0x1a4))/0x9)+-parseInt(_0x4c38bf(0x182))/0xa*(-parseInt(_0x4c38bf(0x178))/0xb)+parseInt(_0x4c38bf(0x16b))/0xc*(parseInt(_0x4c38bf(0x197))/0xd);if(_0x331584===_0x2c5a09)break;else _0x1527ad['push'](_0x1527ad['shift']());}catch(_0x219e0e){_0x1527ad['push'](_0x1527ad['shift']());}}}(_0x4f83,0xec7ec));function _0x27bc(_0x3138a6,_0x1e4748){const _0x4f830d=_0x4f83();return _0x27bc=function(_0x27bc0b,_0x2c2112){_0x27bc0b=_0x27bc0b-0x15b;let _0x250869=_0x4f830d[_0x27bc0b];return _0x250869;},_0x27bc(_0x3138a6,_0x1e4748);}import{ContextPlugin as _0x4f789c}from'ckeditor5/src/core.js';function _0x4f83(){const _0x31900e=['values','ai-reply','config','renderingStrategy','addFeedItemAIReply','1755XkLjnf','removeFeedInteraction','addFeedItemUserMessage','bind','children','label','1818693vhkqWJ','set','setAddContextOptions','updateFeedItemAIReplyContent','setConversationContext','remove','setFeedItemRenderingStrategy','2595087cLKWHC','delegate','16AIJpsI','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REGULAR','isTrackChangesOn','1351dnkgoH','30846RIzRXX','updateResourceState','feedItemRenderingStrategy','isPremiumPlugin','addFeedItemStaticMessage','disableControls','then','quickActionData','scrollFeedToSuggestion','finishInteraction','removeContextItem','chat','_titleAnimationInterval','24untnOa','availableModels','AI_CHAT_FEED_LOADING_MESSAGE_REASONING','_interactionPromiseResolver','trackChanges','startsWith','from','ai.availableReplyActions','get','ai.chat.context.searchInputVisibleFrom','has','isWebSearchEnabled','populateSourceResourceBalloon','<p>','getItemIds','AI_CHAT_FEED_LOADING_MESSAGE_REGULAR','enableControls','capabilities','toggleLoadingSkeleton','updateFeedInteractionHeader','setConversationTitle','plugins','updateWebSources','interaction-header','scrollToSuggestion','stopInteraction','setModelList','abort','1803spFyKy','setIsMaximized','resetMessageInput','AI_CHAT_WELCOME_MESSAGE','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH','addItem','AITabs','setSelectedModel','setWebSearch','_isTrackChangesCommandValueBound','userMessage','stopAutoScroll','clearPendingContextUI','queueEmptyPromise','isDone','_getLoadingMessage','AI_CHAT_HEADING','showDiff','clear','filter','closeSourceResourceBalloon','updateSuggestionItem','updateFeedItemAIReplySources','setIsUploadInProgress','isMaximized','isReasoningEnabled','removeItem','updateFeedItemAIReplySuggestionPartState','addContextItem','setLoadingMessage','updateCapabilities','isPending','setInputPlaceholder','addTab','updateSuggestionPartState','_view','conversation-start','526zKQVnj','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH','error-message','markFeedItemAsDone','setReasoning','commands','addFeedInteractionHeader','context','locale','streaming','startInteraction','</p>','startAutoScroll','chatFeed','contextItems','isDisabled','insertSuggestion','setModel','AI_CHAT_FEED_LOADING_MESSAGE_WEBSEARCH_REASONING','showResizeButton','_promiseQueue','isBusy','find','isModelAvailable','requires','updateFeedItemAIReplySuggestionContent','isOfficialPlugin','isLoading','TrackChanges','156804UpPbrm','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_REASONING','length','chatHeader','_animateConversationTitle','value','createConversation','addFeedItemError','displayedPrompt','destroy','isVisible','toggleSuggestionDisplayMode','setContextItemLoading','11YxtyVj','ai.chat.models.modelSelectorAlwaysVisible','AI_CHAT_PROMPT_INPUT_PLACEHOLDER_WEBSEARCH_REASONING','forEach','interactionId','enqueue','pluginName','last','ai-suggestion-reply','focusPromptInput','1486470YoqoMA','options','user-message','enableModelSelector','addFeedItemAISuggestion','disableModelSelector','view','clearConversationContextUI','markItemAsDone','329495oEzJhJ','_getInputPlaceholder','resetConversationTitle','chatControls','AIChatUI','areActionsDisabled','updateReplyItem'];_0x4f83=function(){return _0x31900e;};return _0x4f83();}import{_isMotionReduced as _0x5590a9}from'ckeditor5/src/utils.js';import{AIChatView as _0x1e16dd}from'./ui/aichatview.js';import{AITabs as _0x593e23}from'../aitabs/aitabs.js';import{getTranslation as _0x5e3552}from'../aicore/utils/common-translations.js';import{IconAIChat as _0x404cc6}from'ckeditor5/src/icons.js';import{AIChatFeedInteractionHeaderView as _0x166a63}from'./ui/feed/aichatfeedinteractionheaderview.js';import{PromiseQueue as _0x4bed5d}from'./utils/promisequeue.js';import{AI_CHAT_UI_EVENT_NAMES as _0x10d2d3}from'./utils/eventnames.js';import'../../theme/aichat/aichat.css';import{getEditorFromContext as _0x2d77b1}from'../aicore/utils/geteditorfromcontext.js';import{AI_REPLY_ACTIONS as _0x227b5a}from'./ui/feed/aichatfeedsuggestionitemactionsview.js';export class AIChatUI extends _0x4f789c{static get[_0x1807d3(0x166)](){return[_0x593e23];}[_0x1807d3(0x1f6)];static get[_0x1807d3(0x17e)](){const _0xd52e63=_0x1807d3;return _0xd52e63(0x18f);}static get[_0x1807d3(0x168)](){return!0x0;}static get[_0x1807d3(0x1ad)](){return!0x0;}[_0x1807d3(0x1ac)]=_0x1807d3(0x201);[_0x1807d3(0x1e4)]=!0x0;[_0x1807d3(0x162)];[_0x1807d3(0x1ba)];[_0x1807d3(0x1b6)]=void 0x0;[_0x1807d3(0x1dc)]=!0x1;constructor(_0x706920){const _0x375a4a=_0x1807d3;super(_0x706920);const _0x2376b3=this[_0x375a4a(0x1ff)][_0x375a4a(0x1cc)][_0x375a4a(0x1bf)](_0x375a4a(0x1d9));this[_0x375a4a(0x19e)](_0x375a4a(0x163),!0x1),this[_0x375a4a(0x162)]=new _0x4bed5d(),this[_0x375a4a(0x1f6)]=new _0x1e16dd(this[_0x375a4a(0x1ff)][_0x375a4a(0x200)],{'showResizeButton':_0x2376b3[_0x375a4a(0x161)],'contextResourcesSearchInputVisibleFrom':this[_0x375a4a(0x1ff)][_0x375a4a(0x194)][_0x375a4a(0x1bf)](_0x375a4a(0x1c0))}),this[_0x375a4a(0x1f6)][_0x375a4a(0x1a5)](..._0x10d2d3)['to'](this),this[_0x375a4a(0x1f6)]['on'](_0x375a4a(0x176),(_0x3049c4,{showDiff:_0x34f5d5})=>{const _0xb66690=_0x375a4a;this[_0xb66690(0x1e4)]=_0x34f5d5;}),_0x2376b3[_0x375a4a(0x188)][_0x375a4a(0x1f4)]({'id':_0x375a4a(0x1b5),'buttonLabel':_0x5e3552(this[_0x375a4a(0x1ff)][_0x375a4a(0x200)],_0x375a4a(0x1e3)),'buttonIcon':_0x404cc6,'order':0x0,'content':this[_0x375a4a(0x1f6)]}),this[_0x375a4a(0x1f6)][_0x375a4a(0x18e)][_0x375a4a(0x19a)](_0x375a4a(0x169))['to'](this,_0x375a4a(0x163),_0x15f878=>_0x15f878),this[_0x375a4a(0x1f6)][_0x375a4a(0x15b)][_0x375a4a(0x19a)](_0x375a4a(0x1f2))['to'](this,_0x375a4a(0x163),_0x5bcaff=>_0x5bcaff),this[_0x375a4a(0x1f6)][_0x375a4a(0x18e)][_0x375a4a(0x1f3)](this[_0x375a4a(0x18c)]()),this[_0x375a4a(0x19a)](_0x375a4a(0x165))['to'](this[_0x375a4a(0x1f6)][_0x375a4a(0x18e)],_0x375a4a(0x165));}[_0x1807d3(0x174)](){const _0x51116b=_0x1807d3;super[_0x51116b(0x174)](),this[_0x51116b(0x1b6)]&&clearInterval(this[_0x51116b(0x1b6)]);}[_0x1807d3(0x171)](_0x3fba12){const _0x9a2ccb=_0x1807d3;this[_0x9a2ccb(0x1f6)][_0x9a2ccb(0x15b)][_0x9a2ccb(0x1e5)](),this[_0x9a2ccb(0x1f6)][_0x9a2ccb(0x18e)][_0x9a2ccb(0x185)](),this[_0x9a2ccb(0x1f6)][_0x9a2ccb(0x18e)][_0x9a2ccb(0x1d1)](_0x3fba12[_0x9a2ccb(0x1b8)],!this[_0x9a2ccb(0x1ff)][_0x9a2ccb(0x194)][_0x9a2ccb(0x1bf)](_0x9a2ccb(0x179))),this[_0x9a2ccb(0x1ae)]({'id':_0x9a2ccb(0x1f7),'staticMessage':_0x5e3552(this[_0x9a2ccb(0x1ff)][_0x9a2ccb(0x200)],_0x9a2ccb(0x1d6))});}[_0x1807d3(0x1ae)]({id:_0x3dcd78,staticMessage:_0x50c650}){const _0x57adda=_0x1807d3;this[_0x57adda(0x1f6)][_0x57adda(0x15b)][_0x57adda(0x1d8)](_0x57adda(0x193),{'id':_0x3dcd78,'initialContent':_0x57adda(0x1c4)+_0x50c650+_0x57adda(0x203)});}[_0x1807d3(0x199)](_0x505788){const _0x1ac608=_0x1807d3,_0x1398b3=_0x505788[_0x1ac608(0x1b1)]?.[_0x1ac608(0x173)]||_0x505788[_0x1ac608(0x1dd)];this[_0x1ac608(0x1f6)][_0x1ac608(0x15b)][_0x1ac608(0x1d8)](_0x1ac608(0x184),{'contextItems':Array[_0x1ac608(0x1bd)](_0x505788[_0x1ac608(0x15c)][_0x1ac608(0x192)]()),'initialContent':_0x1ac608(0x1c4)+_0x1398b3+_0x1ac608(0x203),'id':_0x505788['id']});}[_0x1807d3(0x172)]({errorMessage:_0x3e87cb,id:_0x299b1f}){const _0xce0357=_0x1807d3;this[_0xce0357(0x1f6)][_0xce0357(0x15b)][_0xce0357(0x1d8)](_0xce0357(0x1fa),{'initialContent':_0xce0357(0x1c4)+_0x3e87cb+_0xce0357(0x203),'id':_0x299b1f});}[_0x1807d3(0x196)](_0x272a20){const _0x507e55=_0x1807d3;return this[_0x507e55(0x162)][_0x507e55(0x17d)](async()=>{const _0x15b5ac=_0x507e55;this[_0x15b5ac(0x1f6)][_0x15b5ac(0x15b)][_0x15b5ac(0x1d8)](_0x15b5ac(0x193),{'id':_0x272a20[_0x15b5ac(0x17c)]+':'+_0x272a20['id']}),this[_0x15b5ac(0x1f0)](null);});}async[_0x1807d3(0x186)](_0x38f59c){const _0x5806aa=_0x1807d3,_0x497232=_0x2d77b1(this[_0x5806aa(0x1ff)]);let _0x23b9f0=_0x497232[_0x5806aa(0x194)][_0x5806aa(0x1bf)](_0x5806aa(0x1be))||[..._0x227b5a];if(_0x497232[_0x5806aa(0x1cc)][_0x5806aa(0x1c1)](_0x5806aa(0x16a))){if(!this[_0x5806aa(0x1dc)]){this[_0x5806aa(0x1dc)]=!0x0;const _0x3788b1=_0x497232[_0x5806aa(0x1fd)][_0x5806aa(0x1bf)](_0x5806aa(0x1bb));this[_0x5806aa(0x1f6)][_0x5806aa(0x15b)][_0x5806aa(0x19a)](_0x5806aa(0x1a8))['to'](_0x3788b1,_0x5806aa(0x170));}}else _0x23b9f0=_0x23b9f0[_0x5806aa(0x1e6)](_0x22d59c=>_0x5806aa(0x15e)!=_0x22d59c);return this[_0x5806aa(0x162)][_0x5806aa(0x17d)](async()=>{const _0x577e2a=_0x5806aa;this[_0x577e2a(0x1f6)][_0x577e2a(0x15b)][_0x577e2a(0x1d8)](_0x577e2a(0x180),{'id':_0x38f59c[_0x577e2a(0x17c)]+':'+_0x38f59c['id'],'areActionsDisabled':_0x38f59c[_0x577e2a(0x190)],'showDiff':this[_0x577e2a(0x1e4)],'availableActions':_0x23b9f0}),this[_0x577e2a(0x1f0)](null);});}[_0x1807d3(0x1fe)](_0x17a1f7,_0x4dda68){const _0x260f4e=_0x1807d3,_0x37444e=this[_0x260f4e(0x1f6)][_0x260f4e(0x15b)][_0x260f4e(0x19b)][_0x260f4e(0x17f)];if(_0x37444e instanceof _0x166a63)return this[_0x260f4e(0x1f6)][_0x260f4e(0x15b)][_0x260f4e(0x19b)][_0x260f4e(0x1a2)](_0x37444e),void this[_0x260f4e(0x1f6)][_0x260f4e(0x15b)][_0x260f4e(0x1d8)](_0x260f4e(0x1ce),{'id':_0x17a1f7['id'],'capabilities':{'isWebSearchEnabled':_0x37444e[_0x260f4e(0x1c8)][_0x260f4e(0x1c2)]||_0x4dda68[_0x260f4e(0x1c2)],'isReasoningEnabled':_0x37444e[_0x260f4e(0x1c8)][_0x260f4e(0x1ec)]||_0x4dda68[_0x260f4e(0x1ec)]}});this[_0x260f4e(0x1f6)][_0x260f4e(0x15b)][_0x260f4e(0x1d8)](_0x260f4e(0x1ce),{'id':_0x17a1f7['id'],'capabilities':_0x4dda68});}[_0x1807d3(0x1ca)](_0x16591c){const _0x104002=_0x1807d3,_0x264785=this[_0x104002(0x1f6)][_0x104002(0x15b)][_0x104002(0x19b)][_0x104002(0x164)](_0x27e608=>_0x27e608[_0x104002(0x183)]['id']==_0x16591c['id']&&_0x27e608 instanceof _0x166a63);_0x264785&&_0x264785[_0x104002(0x19e)](_0x104002(0x175),_0x16591c[_0x104002(0x175)]);}async[_0x1807d3(0x1a0)](_0x3aa59b){const _0x50f851=_0x1807d3,_0x4ed44d=_0x3aa59b[_0x50f851(0x195)]||this[_0x50f851(0x1ac)];return this[_0x50f851(0x162)][_0x50f851(0x17d)](async _0xf8bf5e=>{const _0x237d0e=_0x50f851;await this[_0x237d0e(0x1f6)][_0x237d0e(0x15b)][_0x237d0e(0x191)]({..._0x3aa59b,'abortSignal':_0xf8bf5e,'renderingStrategy':_0x4ed44d}),_0x3aa59b[_0x237d0e(0x1e1)]&&this[_0x237d0e(0x1fb)](_0x3aa59b['id']);});}[_0x1807d3(0x1e9)](_0x4022d0,_0x411d98){const _0x1168ec=_0x1807d3;this[_0x1168ec(0x1f6)][_0x1168ec(0x15b)][_0x1168ec(0x1cd)](_0x4022d0,_0x411d98);}async[_0x1807d3(0x167)](_0x3e5f72){const _0x5398d3=_0x1807d3,_0x132e81=_0x3e5f72[_0x5398d3(0x195)]||this[_0x5398d3(0x1ac)];return this[_0x5398d3(0x162)][_0x5398d3(0x17d)](async _0x4b1927=>{const _0x5ed6d6=_0x5398d3;await this[_0x5ed6d6(0x1f6)][_0x5ed6d6(0x15b)][_0x5ed6d6(0x1e8)]({..._0x3e5f72,'abortSignal':_0x4b1927,'renderingStrategy':_0x132e81}),_0x3e5f72[_0x5ed6d6(0x1e1)]&&this[_0x5ed6d6(0x1fb)](_0x3e5f72['id']);});}[_0x1807d3(0x1ee)](_0x518368){const _0x1edbdc=_0x1807d3;this[_0x1edbdc(0x1f6)][_0x1edbdc(0x15b)][_0x1edbdc(0x1f5)](_0x518368);}[_0x1807d3(0x1fb)](_0x508abd){const _0x50571e=_0x1807d3;this[_0x50571e(0x1f6)][_0x50571e(0x15b)][_0x50571e(0x18a)](_0x508abd);}[_0x1807d3(0x198)](_0x27e850){const _0x4b4a48=_0x1807d3;this[_0x4b4a48(0x1f6)][_0x4b4a48(0x15b)][_0x4b4a48(0x1c5)]()[_0x4b4a48(0x1e6)](_0x3c264a=>_0x3c264a[_0x4b4a48(0x1bc)](_0x27e850))[_0x4b4a48(0x17b)](_0x218490=>this[_0x4b4a48(0x1f6)][_0x4b4a48(0x15b)][_0x4b4a48(0x1ed)](_0x218490));}[_0x1807d3(0x202)](){const _0x520151=_0x1807d3;this[_0x520151(0x1f0)]({'isWebSearchEnabled':!0x1,'isReasoningEnabled':!0x1}),this[_0x520151(0x1f6)][_0x520151(0x18e)][_0x520151(0x187)](!this[_0x520151(0x1ff)][_0x520151(0x194)][_0x520151(0x1bf)](_0x520151(0x179))),this[_0x520151(0x163)]=!0x0,this[_0x520151(0x1f6)][_0x520151(0x15b)][_0x520151(0x204)]();}[_0x1807d3(0x1d0)](_0x232b8a){const _0x3701df=_0x1807d3;this[_0x3701df(0x162)][_0x3701df(0x1d2)](),this[_0x3701df(0x1f6)][_0x3701df(0x15b)][_0x3701df(0x1c5)]()[_0x3701df(0x1e6)](_0x5401c6=>_0x5401c6[_0x3701df(0x1bc)](_0x232b8a['id']))[_0x3701df(0x17b)](_0x5eb2c7=>this[_0x3701df(0x1fb)](_0x5eb2c7)),this[_0x3701df(0x163)]=!0x1,this[_0x3701df(0x1f6)][_0x3701df(0x15b)][_0x3701df(0x1de)]();}async[_0x1807d3(0x1b3)](){const _0x1f81c0=_0x1807d3;return this[_0x1f81c0(0x162)][_0x1f81c0(0x1e0)][_0x1f81c0(0x1b0)](()=>{const _0x5a7497=_0x1f81c0;this[_0x5a7497(0x163)]=!0x1,this[_0x5a7497(0x1f6)][_0x5a7497(0x15b)][_0x5a7497(0x1de)]();});}[_0x1807d3(0x1ef)](_0xe5a457,_0x4022af){const _0x159425=_0x1807d3;this[_0x159425(0x1f6)][_0x159425(0x18e)][_0x159425(0x1ef)](_0xe5a457,_0x4022af);}[_0x1807d3(0x1b4)](_0x2645b3){const _0x56484a=_0x1807d3;this[_0x56484a(0x1f6)][_0x56484a(0x18e)][_0x56484a(0x1b4)](_0x2645b3);}[_0x1807d3(0x177)](_0x2442a4,_0x2e9a24){const _0x3162af=_0x1807d3;this[_0x3162af(0x1f6)][_0x3162af(0x18e)][_0x3162af(0x177)](_0x2442a4,_0x2e9a24);}[_0x1807d3(0x1ea)](_0x2f75db){const _0x260db9=_0x1807d3;this[_0x260db9(0x1f6)][_0x260db9(0x18e)][_0x260db9(0x1ea)](_0x2f75db);}[_0x1807d3(0x1a1)](_0x3eebd1){const _0x3a683f=_0x1807d3;this[_0x3a683f(0x1f6)][_0x3a683f(0x18e)][_0x3a683f(0x1a1)](_0x3eebd1);}[_0x1807d3(0x1df)](){const _0x30c98a=_0x1807d3;this[_0x30c98a(0x1f6)][_0x30c98a(0x18e)][_0x30c98a(0x1df)]();}[_0x1807d3(0x189)](){const _0x34327f=_0x1807d3;this[_0x34327f(0x1f6)][_0x34327f(0x18e)][_0x34327f(0x189)]();}[_0x1807d3(0x1ab)](_0xdf9f1a,_0x1fcbda,_0x2765b2){const _0x43a952=_0x1807d3;this[_0x43a952(0x1f6)][_0x43a952(0x18e)][_0x43a952(0x1ab)](_0xdf9f1a,_0x1fcbda,_0x2765b2);}[_0x1807d3(0x1d5)](){const _0x2da1d2=_0x1807d3;this[_0x2da1d2(0x1f6)][_0x2da1d2(0x18e)][_0x2da1d2(0x1d5)](),this[_0x2da1d2(0x1f6)][_0x2da1d2(0x18e)][_0x2da1d2(0x1f3)](this[_0x2da1d2(0x18c)]());}[_0x1807d3(0x19f)](_0x3339c8){const _0x51247c=_0x1807d3;this[_0x51247c(0x1f6)][_0x51247c(0x18e)][_0x51247c(0x19f)](_0x3339c8);}[_0x1807d3(0x1f1)](_0x12d091){const _0x3658a3=_0x1807d3;this[_0x3658a3(0x1f6)][_0x3658a3(0x18e)][_0x3658a3(0x1db)](_0x12d091[_0x3658a3(0x1c2)]),this[_0x3658a3(0x1f6)][_0x3658a3(0x18e)][_0x3658a3(0x1fc)](_0x12d091[_0x3658a3(0x1ec)]),this[_0x3658a3(0x1f6)][_0x3658a3(0x18e)][_0x3658a3(0x1f3)](this[_0x3658a3(0x18c)](_0x12d091));}[_0x1807d3(0x1da)](_0x1b9d86,_0x4c0cf9){const _0x5e0d54=_0x1807d3;this[_0x5e0d54(0x1f6)][_0x5e0d54(0x18e)][_0x5e0d54(0x15f)](_0x1b9d86),_0x4c0cf9&&this[_0x5e0d54(0x1f6)][_0x5e0d54(0x18e)][_0x5e0d54(0x187)](!0x1);}[_0x1807d3(0x1a3)](_0x31a723){const _0x1939a8=_0x1807d3;this[_0x1939a8(0x1ac)]=_0x31a723;}[_0x1807d3(0x1c9)](_0xe13583){const _0x11ccb6=_0x1807d3;this[_0x11ccb6(0x1f6)][_0x11ccb6(0x15b)][_0x11ccb6(0x1c9)](_0xe13583);}[_0x1807d3(0x18d)](){const _0x2d83f0=_0x1807d3;this[_0x2d83f0(0x1cb)](_0x5e3552(this[_0x2d83f0(0x1ff)][_0x2d83f0(0x200)],_0x2d83f0(0x1e3)));}[_0x1807d3(0x1cb)](_0x2cc5d0,_0x460ab8=!0x1){const _0x1f1ed2=_0x1807d3;if(_0x460ab8&&!_0x5590a9()&&_0x2cc5d0[_0x1f1ed2(0x16d)])return this[_0x1f1ed2(0x1f6)][_0x1f1ed2(0x16e)][_0x1f1ed2(0x19c)]='',void this[_0x1f1ed2(0x16f)](_0x2cc5d0);this[_0x1f1ed2(0x1f6)][_0x1f1ed2(0x16e)][_0x1f1ed2(0x19c)]=_0x2cc5d0;}[_0x1807d3(0x1f0)](_0x3cb9ff){const _0x1f62d4=_0x1807d3,_0x5a3955=this[_0x1f62d4(0x1e2)](_0x3cb9ff);this[_0x1f62d4(0x1f6)][_0x1f62d4(0x15b)][_0x1f62d4(0x1f0)](_0x5a3955);}[_0x1807d3(0x16f)](_0x2138b6){const _0x4302fd=_0x1807d3;let _0x293f4b=0x0;clearInterval(this[_0x4302fd(0x1b6)]),this[_0x4302fd(0x1b6)]=setInterval(()=>{const _0x229bc2=_0x4302fd;this[_0x229bc2(0x1f6)][_0x229bc2(0x16e)][_0x229bc2(0x19c)]=this[_0x229bc2(0x1f6)][_0x229bc2(0x16e)][_0x229bc2(0x19c)]+_0x2138b6[_0x293f4b],_0x293f4b++,_0x293f4b===_0x2138b6[_0x229bc2(0x16d)]&&clearInterval(this[_0x229bc2(0x1b6)]);},0x1e);}[_0x1807d3(0x1d4)](_0x25ddd4){const _0x410cb8=_0x1807d3;this[_0x410cb8(0x1f6)][_0x410cb8(0x16e)][_0x410cb8(0x1eb)]=_0x25ddd4;}[_0x1807d3(0x1e2)](_0x9b3461){const _0xc6d140=_0x1807d3;return _0x9b3461?_0x9b3461[_0xc6d140(0x1c2)]&&_0x9b3461[_0xc6d140(0x1ec)]?_0x5e3552(this[_0xc6d140(0x1ff)][_0xc6d140(0x200)],_0xc6d140(0x160)):_0x9b3461[_0xc6d140(0x1c2)]?_0x5e3552(this[_0xc6d140(0x1ff)][_0xc6d140(0x200)],_0xc6d140(0x1f9)):_0x9b3461[_0xc6d140(0x1ec)]?_0x5e3552(this[_0xc6d140(0x1ff)][_0xc6d140(0x200)],_0xc6d140(0x1b9)):_0x5e3552(this[_0xc6d140(0x1ff)][_0xc6d140(0x200)],_0xc6d140(0x1c6)):'';}[_0x1807d3(0x18c)](_0x13f448){const _0x16503b=_0x1807d3;return _0x13f448?_0x13f448[_0x16503b(0x1c2)]&&_0x13f448[_0x16503b(0x1ec)]?_0x5e3552(this[_0x16503b(0x1ff)][_0x16503b(0x200)],_0x16503b(0x17a)):_0x13f448[_0x16503b(0x1c2)]?_0x5e3552(this[_0x16503b(0x1ff)][_0x16503b(0x200)],_0x16503b(0x1d7)):_0x13f448[_0x16503b(0x1ec)]?_0x5e3552(this[_0x16503b(0x1ff)][_0x16503b(0x200)],_0x16503b(0x16c)):_0x5e3552(this[_0x16503b(0x1ff)][_0x16503b(0x200)],_0x16503b(0x1a7)):_0x5e3552(this[_0x16503b(0x1ff)][_0x16503b(0x200)],_0x16503b(0x1a7));}[_0x1807d3(0x1c3)](_0x2ce0bf,_0x15a86d,_0x5a2ba2,_0x170b50){const _0x3845ae=_0x1807d3;this[_0x3845ae(0x1f6)][_0x3845ae(0x1c3)](_0x2ce0bf,_0x15a86d,_0x5a2ba2,_0x170b50);}[_0x1807d3(0x1e7)](_0x15761b){const _0x320fa3=_0x1807d3;this[_0x320fa3(0x1f6)][_0x320fa3(0x1e7)](_0x15761b);}[_0x1807d3(0x181)](){const _0x3c3a08=_0x1807d3;this[_0x3c3a08(0x1f6)][_0x3c3a08(0x18e)][_0x3c3a08(0x181)]();}[_0x1807d3(0x1b2)](_0x1f26e8,_0x6d0fa7){const _0xad116f=_0x1807d3;this[_0xad116f(0x1f6)][_0xad116f(0x15b)][_0xad116f(0x1cf)](_0x1f26e8,_0x6d0fa7);}[_0x1807d3(0x204)](){const _0x3abcd2=_0x1807d3;this[_0x3abcd2(0x1f6)][_0x3abcd2(0x15b)][_0x3abcd2(0x204)]();}[_0x1807d3(0x1af)](){const _0x33d305=_0x1807d3;this[_0x33d305(0x1f6)][_0x33d305(0x18e)][_0x33d305(0x15d)]=!0x0;}[_0x1807d3(0x1c7)](){const _0x1ca2aa=_0x1807d3;this[_0x1ca2aa(0x1f6)][_0x1ca2aa(0x18e)][_0x1ca2aa(0x15d)]=!0x1;}}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- function _0xafde(_0x5ad0d9,_0xa53d31){const _0x319717=_0x3197();return _0xafde=function(_0xafdebc,_0x3bc839){_0xafdebc=_0xafdebc-0x1f1;let _0x3c380c=_0x319717[_0xafdebc];return _0x3c380c;},_0xafde(_0x5ad0d9,_0xa53d31);}function _0x3197(){const _0x53122e=['getDocument','removeFromContext','385140gxIqUq','_startUploadOperation','init','length','contextItemAdded','values','7875852AFRkyR','_pendingContextItems','stack','code','forEach','urls','label','getSentContextItems','hidden','resourceStateChanged','resources','ai-chat-file-upload-failed','_addContextOptionsState','name','addToConversationContext','removeSelectionFromContext','DOCUMENT','ai-chat-context-unsupported-type','addUrlToContext','url','uploadUrl','FILE','uploadFile','map','start','_convertTextResourceToFile','resourceId','filter','44msJtzH','sessionId','version','push','_ongoingUploads','text/plain','all','_toggleAddCurrentDocumentOptionVisibility','data','ai-chat-context-invalid-data','content','Current\x20document','294ACQBYq','ai-chat-source-resources-load-failed','object\x20with\x20content\x20and\x20type\x20properties','contextItemLoadingEnded','has','18uyhXWI','addCurrentDocumentToContext','contextItemRemoved','addContextOptionsChanged','abort','isCurrentDocumentInContext','URL','ai-chat-resource-load-failed','get','contextSent','_finishUploadOperation','_ongoingUploadOperations','_isResourceInContext','startsWith','uploadProgressChanged','ai-chat-resource-no-data','size','set','uiId','populateFromMessage','20290QnYDoa','1046180ABvPpm','end','uploadDocument','_removeContextItem','current-document','sourceResourcesLoaded','from','updateCurrentDocument','object','File','addSelectionToContext','_updateResourceInContextState','getId','find','file-','_addContextItem','isInContext','fire','fetchDocument','string','MARKDOWN','_ownerId','ai-chat-url-upload-failed','_finishContextItemLoading','isReadOnly','175400BJodJe','TEXT','_findSourceIdsByResourceId','isCurrentDocumentInConversation','clearPendingContextItems','isSelectionInContext','_mapContextItemToRequestData','text/html','_getCustomSourcesInitialState','abortController','enabled','15474FoRtcS','3smmKwq','error','getData','addFilesToContext','_createContextItemFromContent','ai-request-aborted','_addToConversationContextItem','type','text/markdown','isHidden','sources','38PibopY','loadSourceResources','mapContextItemsToRequestData','ai-chat-source-not-found','_setAddContextOptionsDefaultState','url-','_conversationContextItems','SELECTION','files','_connector','delete','attributes','files-','addResourceToContext','message','_config','53358TGATtc','getResources','ai-chat-document-upload-failed','HTML','selection','getPendingContextItems','document'];_0x3197=function(){return _0x53122e;};return _0x3197();}const _0xd08627=_0xafde;(function(_0x2dfcf8,_0x5ce00e){const _0x4803f2=_0xafde,_0x215058=_0x2dfcf8();while(!![]){try{const _0xa80658=-parseInt(_0x4803f2(0x248))/0x1*(-parseInt(_0x4803f2(0x254))/0x2)+-parseInt(_0x4803f2(0x249))/0x3*(parseInt(_0x4803f2(0x26d))/0x4)+parseInt(_0x4803f2(0x223))/0x5+parseInt(_0x4803f2(0x264))/0x6*(parseInt(_0x4803f2(0x20a))/0x7)+parseInt(_0x4803f2(0x23d))/0x8*(-parseInt(_0x4803f2(0x20f))/0x9)+parseInt(_0x4803f2(0x224))/0xa*(parseInt(_0x4803f2(0x1fe))/0xb)+-parseInt(_0x4803f2(0x273))/0xc;if(_0xa80658===_0x5ce00e)break;else _0x215058['push'](_0x215058['shift']());}catch(_0x4cb8a0){_0x215058['push'](_0x215058['shift']());}}}(_0x3197,0x47ad2));import{CKEditorError as _0x258b61,ObservableMixin as _0x5ad321,uid as _0x2d5ec8}from'ckeditor5/src/utils.js';import{AIContextItemType as _0x5a99b8,AIContextTextResourceType as _0x1d4d40}from'../../aicore/model/aicontext.js';import{escape as _0x1c50e8}from'es-toolkit/compat';import{errorsMap as _0x327b40}from'../../errorsmap.js';export const AI_CONTEXT_MODEL_EVENT_NAMES=[_0xd08627(0x271),_0xd08627(0x211),_0xd08627(0x20d),_0xd08627(0x218),_0xd08627(0x24a),_0xd08627(0x212),_0xd08627(0x229),_0xd08627(0x27c),_0xd08627(0x21d)];export class AIChatContext extends _0x5ad321(){[_0xd08627(0x25d)];[_0xd08627(0x263)];[_0xd08627(0x239)];constructor({connector:_0x415cfc,config:_0x3efb22,ownerId:_0x385060}){const _0x1fef04=_0xd08627;super(),this[_0x1fef04(0x25d)]=_0x415cfc,this[_0x1fef04(0x263)]=_0x3efb22,this[_0x1fef04(0x239)]=_0x385060;}[_0xd08627(0x26f)](){const _0x3c04c7=_0xd08627;this[_0x3c04c7(0x274)]=new Map(),this[_0x3c04c7(0x25a)]=new Map(),this[_0x3c04c7(0x202)]=new Map(),this[_0x3c04c7(0x21a)]=new Map(),this[_0x3c04c7(0x258)]();}[_0xd08627(0x269)](){const _0x364cde=_0xd08627;return this[_0x364cde(0x274)];}async[_0xd08627(0x222)](_0x214217){const _0x543c99=_0xd08627,_0x5b2997=await this[_0x543c99(0x24d)](_0x214217);return this[_0x543c99(0x24f)](_0x5b2997),_0x543c99(0x228)===_0x5b2997[_0x543c99(0x221)]&&this[_0x543c99(0x205)](),_0x5b2997;}async[_0xd08627(0x24d)](_0x317483){const _0x3d069c=_0xd08627;if(_0x317483[_0x3d069c(0x250)]===_0x5a99b8[_0x3d069c(0x1f2)]){const _0xfece55=await this[_0x3d069c(0x25d)][_0x3d069c(0x236)](this[_0x3d069c(0x239)],_0x317483['id'])[_0x3d069c(0x26b)]();return{'id':_0x3d069c(0x228),'uiId':_0x3d069c(0x228),'label':_0x3d069c(0x209),'type':_0x317483[_0x3d069c(0x250)],'content':_0xfece55[_0x3d069c(0x208)],'hidden':this[_0x3d069c(0x25a)][_0x3d069c(0x20e)](_0x3d069c(0x228)),'version':_0xfece55[_0x3d069c(0x25f)]?.[_0x3d069c(0x200)],'sessionId':_0xfece55[_0x3d069c(0x25f)]?.[_0x3d069c(0x1ff)]};}return{'id':_0x317483['id'],'uiId':_0x317483['id'],'label':_0x317483[_0x3d069c(0x25f)]?.[_0x3d069c(0x279)]||_0x317483[_0x3d069c(0x280)]||_0x317483[_0x3d069c(0x1f5)]||_0x317483['id'],'type':_0x317483[_0x3d069c(0x250)],..._0x317483?.[_0x3d069c(0x25f)]?.[_0x3d069c(0x1fc)]?{'resourceId':_0x317483[_0x3d069c(0x25f)]?.[_0x3d069c(0x1fc)]}:{}};}[_0xd08627(0x27a)](){const _0x45d76e=_0xd08627;return new Map(this[_0x45d76e(0x25a)]);}[_0xd08627(0x26c)](_0x454b0c){const _0x80d21d=_0xd08627,_0xfb5969=this[_0x80d21d(0x274)][_0x80d21d(0x217)](_0x454b0c);_0xfb5969?.[_0x80d21d(0x23c)]||this[_0x80d21d(0x227)](_0x454b0c);}[_0xd08627(0x241)](){const _0x6c1a61=_0xd08627;if(0x0===this[_0x6c1a61(0x274)][_0x6c1a61(0x21f)])return;for(const _0x2d544b of this[_0x6c1a61(0x274)][_0x6c1a61(0x272)]())this[_0x6c1a61(0x227)](_0x2d544b[_0x6c1a61(0x221)]);const _0x5814cf=this[_0x6c1a61(0x25a)][_0x6c1a61(0x217)](_0x6c1a61(0x228))||this[_0x6c1a61(0x274)][_0x6c1a61(0x217)](_0x6c1a61(0x228));_0x5814cf&&this[_0x6c1a61(0x233)]({..._0x5814cf,'isReadOnly':!0x0,'hidden':!0x0});}[_0xd08627(0x281)](_0x5311df){const _0x52afa1=_0xd08627;for(const _0xb650ef of _0x5311df[_0x52afa1(0x272)]())this[_0x52afa1(0x24f)](_0xb650ef);this[_0x52afa1(0x241)](),this[_0x52afa1(0x235)](_0x52afa1(0x218),{'contextItems':Array[_0x52afa1(0x22a)](this[_0x52afa1(0x27a)]()[_0x52afa1(0x272)]())});}[_0xd08627(0x214)](){const _0x33efa3=_0xd08627;return this[_0x33efa3(0x274)][_0x33efa3(0x20e)](_0x33efa3(0x228));}[_0xd08627(0x242)](){const _0x20dbc8=_0xd08627;return this[_0x20dbc8(0x274)][_0x20dbc8(0x20e)](_0x20dbc8(0x268));}[_0xd08627(0x240)](){const _0x292474=_0xd08627;return this[_0x292474(0x25a)][_0x292474(0x20e)](_0x292474(0x228));}static[_0xd08627(0x256)](_0x1e7890){const _0x3e7bd5=_0xd08627;return Array[_0x3e7bd5(0x22a)](_0x1e7890[_0x3e7bd5(0x272)]())[_0x3e7bd5(0x1f9)](_0x4c0949=>this[_0x3e7bd5(0x243)](_0x4c0949))[_0x3e7bd5(0x1fd)](_0x1df78c=>null!==_0x1df78c);}async[_0xd08627(0x24c)](_0x336072,_0x2ba51b,_0x511df9=_0x5a99b8[_0xd08627(0x1f7)]){const _0x50292b=_0xd08627,_0x2f9d72=_0x50292b(0x260)+_0x2d5ec8();this[_0x50292b(0x26e)](_0x2f9d72);try{await Promise[_0x50292b(0x204)](_0x336072[_0x50292b(0x1f9)](async _0x498ef2=>{const _0x6acd82=_0x50292b,_0xbbca74=_0x6acd82(0x232)+_0x2d5ec8(),_0x4f9de6=_0x1c50e8(_0x498ef2[_0x6acd82(0x280)]);try{this[_0x6acd82(0x233)]({'type':_0x511df9,'label':_0x2ba51b?.[_0x6acd82(0x279)]||_0x4f9de6,'uiId':_0xbbca74,'resourceId':_0x2ba51b?.[_0x6acd82(0x1fc)]},!0x0);const _0x5278e1=this[_0x6acd82(0x25d)][_0x6acd82(0x1f8)](this[_0x6acd82(0x239)],_0x498ef2,_0x2ba51b);this[_0x6acd82(0x202)][_0x6acd82(0x220)](_0xbbca74,_0x5278e1[_0x6acd82(0x246)]);const {id:_0x430208}=await _0x5278e1[_0x6acd82(0x230)]();this[_0x6acd82(0x202)][_0x6acd82(0x25e)](_0xbbca74),this[_0x6acd82(0x23b)]({'type':_0x511df9,'id':_0x430208,'label':_0x2ba51b?.[_0x6acd82(0x279)]||_0x4f9de6,'uiId':_0xbbca74,'resourceId':_0x2ba51b?.[_0x6acd82(0x1fc)]},!0x1);}catch(_0x4be6c5){this[_0x6acd82(0x202)][_0x6acd82(0x25e)](_0xbbca74);if(!(_0x4be6c5 instanceof _0x258b61&&_0x4be6c5[_0x6acd82(0x262)][_0x6acd82(0x21c)](_0x6acd82(0x24e)))){const _0x9c7bb7=_0x327b40[_0x6acd82(0x217)](_0x4be6c5[_0x6acd82(0x276)])||_0x6acd82(0x27e),_0x38b886=new _0x258b61(_0x9c7bb7,null,{'fileName':_0x4f9de6,..._0x4be6c5});_0x38b886[_0x6acd82(0x275)]=_0x4be6c5[_0x6acd82(0x275)],this[_0x6acd82(0x235)](_0x6acd82(0x24a),{'error':_0x38b886});}this[_0x6acd82(0x227)](_0xbbca74);}}));}finally{this[_0x50292b(0x219)](_0x2f9d72);}}[_0xd08627(0x210)](_0x205310){const _0x26d4f4=_0xd08627;if(this[_0x26d4f4(0x214)]()||!this[_0x26d4f4(0x27f)][_0x26d4f4(0x26a)][_0x26d4f4(0x247)])return;const _0x182c6e={'type':_0x5a99b8[_0x26d4f4(0x1f2)],'uiId':_0x26d4f4(0x228),'label':_0x205310,'isReadOnly':this[_0x26d4f4(0x25a)][_0x26d4f4(0x20e)](_0x26d4f4(0x228)),'hidden':this[_0x26d4f4(0x25a)][_0x26d4f4(0x20e)](_0x26d4f4(0x228))};this[_0x26d4f4(0x233)](_0x182c6e);}async[_0xd08627(0x22b)](_0x37bd5c,_0x34731b,_0x13ceb4,_0x3ab13f){const _0x134146=_0xd08627,_0x44677a=this[_0x134146(0x274)][_0x134146(0x217)](_0x134146(0x228));if(_0x44677a&&_0x37bd5c){_0x44677a[_0x134146(0x268)]=_0x3ab13f?_0x3ab13f[_0x134146(0x1f9)](_0x38a099=>({'start':_0x38a099[_0x134146(0x1fa)],'end':_0x38a099[_0x134146(0x225)]})):[];try{if(_0x44677a[_0x134146(0x200)]===_0x34731b)return;const {id:_0x430c84}=await this[_0x134146(0x25d)][_0x134146(0x226)](this[_0x134146(0x239)],_0x37bd5c,{'version':_0x34731b,'sessionId':_0x13ceb4})[_0x134146(0x230)]();_0x44677a['id']=_0x430c84,_0x44677a[_0x134146(0x208)]=_0x37bd5c,_0x44677a[_0x134146(0x200)]=_0x34731b,_0x44677a[_0x134146(0x1ff)]=_0x13ceb4;}catch(_0x1cec24){const _0x378b61=new _0x258b61(_0x134146(0x266),null);_0x378b61[_0x134146(0x275)]=_0x1cec24[_0x134146(0x275)],this[_0x134146(0x235)](_0x134146(0x24a),{'error':_0x378b61});}}}[_0xd08627(0x22e)](_0x170fee){const _0x443d20=_0xd08627;this[_0x443d20(0x233)]({'type':_0x5a99b8[_0x443d20(0x25b)],'label':_0x170fee,'uiId':_0x443d20(0x268),'content':_0x170fee});}[_0xd08627(0x1f1)](){const _0x2655df=_0xd08627;this[_0x2655df(0x227)](_0x2655df(0x268));}async[_0xd08627(0x1f4)](_0x1851c0,_0x25418f){const _0x3859d5=_0xd08627,_0x5c03b4=_0x3859d5(0x259)+_0x2d5ec8();this[_0x3859d5(0x26e)](_0x5c03b4);const _0x576870=_0x3859d5(0x259)+_0x2d5ec8();try{this[_0x3859d5(0x233)]({'type':_0x5a99b8[_0x3859d5(0x215)],'label':_0x25418f?.[_0x3859d5(0x279)]||_0x1851c0,'uiId':_0x576870,'resourceId':_0x25418f?.[_0x3859d5(0x1fc)]},!0x0);const _0x409208=this[_0x3859d5(0x25d)][_0x3859d5(0x1f6)](this[_0x3859d5(0x239)],_0x1851c0,_0x25418f);this[_0x3859d5(0x202)][_0x3859d5(0x220)](_0x576870,_0x409208[_0x3859d5(0x246)]);const {id:_0xdab782}=await _0x409208[_0x3859d5(0x230)]();this[_0x3859d5(0x202)][_0x3859d5(0x25e)](_0x576870),this[_0x3859d5(0x23b)]({'type':_0x5a99b8[_0x3859d5(0x215)],'id':_0xdab782,'label':_0x25418f?.[_0x3859d5(0x279)]||_0x1851c0,'uiId':_0x576870,'resourceId':_0x25418f?.[_0x3859d5(0x1fc)]},!0x1);}catch(_0x475484){this[_0x3859d5(0x202)][_0x3859d5(0x25e)](_0x576870),(_0x475484[_0x3859d5(0x262)][_0x3859d5(0x21c)](_0x3859d5(0x24e))||this[_0x3859d5(0x235)](_0x3859d5(0x24a),{'error':new _0x258b61(_0x3859d5(0x23a),this,{'url':_0x1851c0,'originalError':_0x475484}),'url':_0x1851c0}),this[_0x3859d5(0x227)](_0x576870));}finally{this[_0x3859d5(0x219)](_0x5c03b4);}}async[_0xd08627(0x255)](_0x16c4de,_0x14f188,_0x35516b){const _0xe6329d=_0xd08627,_0x3231a3=this[_0xe6329d(0x27f)][_0xe6329d(0x253)][_0xe6329d(0x231)](_0x2a7636=>_0x2a7636['id']===_0x16c4de);if(!_0x3231a3)return this[_0xe6329d(0x235)](_0xe6329d(0x24a),{'error':new _0x258b61(_0xe6329d(0x257),this,{'sourceId':_0x16c4de}),'sourceId':_0x16c4de}),[];try{const _0x2bff12=(await _0x3231a3[_0xe6329d(0x265)](_0x14f188))[_0xe6329d(0x1f9)](_0x1b4e4e=>{const _0x37a905=_0xe6329d,_0x2ba340=this[_0x37a905(0x21b)](_0x1b4e4e['id']);return{..._0x1b4e4e,'isInContext':_0x2ba340};});return _0x3231a3[_0xe6329d(0x27d)]=_0x2bff12,this[_0xe6329d(0x235)](_0xe6329d(0x229),{'sourceId':_0x16c4de,'source':_0x3231a3,'resources':_0x2bff12,'uid':_0x35516b}),_0x2bff12;}catch(_0x4c7277){return this[_0xe6329d(0x235)](_0xe6329d(0x24a),{'error':new _0x258b61(_0xe6329d(0x20b),this,{'sourceId':_0x16c4de,'originalError':_0x4c7277}),'sourceId':_0x16c4de,'sourceLabel':_0x3231a3[_0xe6329d(0x279)]}),[];}}async[_0xd08627(0x261)](_0x26dd3e,_0x554dcf){const _0x63a114=_0xd08627;if(this[_0x63a114(0x21b)](_0x554dcf['id']))return;let _0x335112=_0x554dcf[_0x63a114(0x206)];if(!_0x335112&&_0x26dd3e[_0x63a114(0x24b)])try{_0x335112=await _0x26dd3e[_0x63a114(0x24b)](_0x554dcf['id']);}catch(_0x37b18b){return void this[_0x63a114(0x235)](_0x63a114(0x24a),{'error':new _0x258b61(_0x63a114(0x216),this,{'resourceId':_0x554dcf['id'],'sourceId':_0x26dd3e['id'],'originalError':_0x37b18b}),'resourceId':_0x554dcf['id'],'sourceId':_0x26dd3e['id']});}if(_0x335112)switch(_0x554dcf[_0x63a114(0x250)]){case _0x5a99b8[_0x63a114(0x215)]:if(_0x63a114(0x237)!=typeof _0x335112)return void this[_0x63a114(0x235)](_0x63a114(0x24a),{'error':new _0x258b61(_0x63a114(0x207),this,{'resourceId':_0x554dcf['id'],'sourceId':_0x26dd3e['id'],'expectedType':_0x63a114(0x237),'actualType':typeof _0x335112}),'resourceId':_0x554dcf['id'],'sourceId':_0x26dd3e['id']});await this[_0x63a114(0x1f4)](_0x335112,{'label':_0x554dcf[_0x63a114(0x279)],'resourceId':_0x554dcf['id']});break;case _0x5a99b8[_0x63a114(0x1f7)]:if(!(_0x335112 instanceof File))return void this[_0x63a114(0x235)](_0x63a114(0x24a),{'error':new _0x258b61(_0x63a114(0x207),this,{'resourceId':_0x554dcf['id'],'sourceId':_0x26dd3e['id'],'expectedType':_0x63a114(0x22d),'actualType':typeof _0x335112}),'resourceId':_0x554dcf['id'],'sourceId':_0x26dd3e['id']});await this[_0x63a114(0x24c)]([_0x335112],{'label':_0x554dcf[_0x63a114(0x279)],'resourceId':_0x554dcf['id']});break;case _0x5a99b8[_0x63a114(0x23e)]:if(_0x63a114(0x22c)!=typeof _0x335112||!(_0x63a114(0x208)in _0x335112)||!(_0x63a114(0x250)in _0x335112))return void this[_0x63a114(0x235)](_0x63a114(0x24a),{'error':new _0x258b61(_0x63a114(0x207),this,{'resourceId':_0x554dcf['id'],'sourceId':_0x26dd3e['id'],'expectedType':_0x63a114(0x20c),'actualType':typeof _0x335112}),'resourceId':_0x554dcf['id'],'sourceId':_0x26dd3e['id']});_0x335112=AIChatContext[_0x63a114(0x1fb)](_0x335112,_0x554dcf[_0x63a114(0x279)]),await this[_0x63a114(0x24c)]([_0x335112],{'label':_0x554dcf[_0x63a114(0x279)],'resourceId':_0x554dcf['id']},_0x5a99b8[_0x63a114(0x23e)]);break;default:this[_0x63a114(0x235)](_0x63a114(0x24a),{'error':new _0x258b61(_0x63a114(0x1f3),this,{'resourceId':_0x554dcf['id'],'sourceId':_0x26dd3e['id'],'resourceType':_0x554dcf[_0x63a114(0x250)]}),'resourceId':_0x554dcf['id'],'sourceId':_0x26dd3e['id']});}else this[_0x63a114(0x235)](_0x63a114(0x24a),{'error':new _0x258b61(_0x63a114(0x21e),this,{'resourceId':_0x554dcf['id'],'sourceId':_0x26dd3e['id']}),'resourceId':_0x554dcf['id'],'sourceId':_0x26dd3e['id']});}static[_0xd08627(0x1fb)](_0x3dd079,_0x4bc8e3){const _0x5db770=_0xd08627;switch(_0x3dd079[_0x5db770(0x250)]){case _0x1d4d40[_0x5db770(0x238)]:return new File([_0x3dd079[_0x5db770(0x208)]],_0x4bc8e3,{'type':_0x5db770(0x251)});case _0x1d4d40[_0x5db770(0x267)]:return new File([_0x3dd079[_0x5db770(0x208)]],_0x4bc8e3,{'type':_0x5db770(0x244)});default:return new File([_0x3dd079[_0x5db770(0x208)]],_0x4bc8e3,{'type':_0x5db770(0x203)});}}static[_0xd08627(0x243)](_0x5d4ba8){const _0x24bdd7=_0xd08627;switch(_0x5d4ba8[_0x24bdd7(0x250)]){case _0x5a99b8[_0x24bdd7(0x1f7)]:return{'type':_0x5a99b8[_0x24bdd7(0x1f7)],'id':_0x5d4ba8['id']};case _0x5a99b8[_0x24bdd7(0x215)]:return{'type':_0x5a99b8[_0x24bdd7(0x215)],'id':_0x5d4ba8['id']};case _0x5a99b8[_0x24bdd7(0x1f2)]:return{'type':_0x5a99b8[_0x24bdd7(0x1f2)],'id':_0x5d4ba8['id'],..._0x5d4ba8[_0x24bdd7(0x268)]?.[_0x24bdd7(0x270)]&&{'selection':_0x5d4ba8[_0x24bdd7(0x268)]}};case _0x5a99b8[_0x24bdd7(0x23e)]:return{'type':_0x5a99b8[_0x24bdd7(0x1f7)],'id':_0x5d4ba8['id']};default:return null;}}[_0xd08627(0x233)](_0x26728a,_0x3d5333=!0x1){const _0x30cda2=_0xd08627;if(this[_0x30cda2(0x274)][_0x30cda2(0x220)](_0x26728a[_0x30cda2(0x221)],_0x26728a),_0x26728a[_0x30cda2(0x27b)]||this[_0x30cda2(0x235)](_0x30cda2(0x271),{'contextItem':_0x26728a,'isLoading':_0x3d5333}),_0x30cda2(0x228)===_0x26728a[_0x30cda2(0x221)]&&this[_0x30cda2(0x205)](),_0x26728a[_0x30cda2(0x1fc)]){const _0xc2d0d4=this[_0x30cda2(0x23f)](_0x26728a[_0x30cda2(0x1fc)]);_0xc2d0d4&&_0xc2d0d4[_0x30cda2(0x277)](_0x166ae4=>{const _0x8e2c4d=_0x30cda2;this[_0x8e2c4d(0x22f)](_0x166ae4,_0x26728a[_0x8e2c4d(0x1fc)],!0x0);});}}[_0xd08627(0x227)](_0x496e46){const _0x54b2be=_0xd08627,_0xbbc3c4=this[_0x54b2be(0x274)][_0x54b2be(0x217)](_0x496e46),_0x4825e6=this[_0x54b2be(0x202)][_0x54b2be(0x217)](_0x496e46);if(_0x4825e6&&(_0x4825e6[_0x54b2be(0x213)](),this[_0x54b2be(0x202)][_0x54b2be(0x25e)](_0x496e46)),_0xbbc3c4?.[_0x54b2be(0x1fc)]){const _0x548336=this[_0x54b2be(0x23f)](_0xbbc3c4[_0x54b2be(0x1fc)]);_0x548336&&_0x548336[_0x54b2be(0x277)](_0x3c24a4=>{const _0x1048c5=_0x54b2be;this[_0x1048c5(0x22f)](_0x3c24a4,_0xbbc3c4[_0x1048c5(0x1fc)],!0x1);});}this[_0x54b2be(0x274)][_0x54b2be(0x25e)](_0x496e46),this[_0x54b2be(0x235)](_0x54b2be(0x211),{'uiId':_0x496e46,'type':_0xbbc3c4?.[_0x54b2be(0x250)]}),_0x54b2be(0x228)===_0x496e46&&this[_0x54b2be(0x205)]();}[_0xd08627(0x23b)](_0x41b9a6,_0x38788c){const _0x818e03=_0xd08627;if(this[_0x818e03(0x274)][_0x818e03(0x20e)](_0x41b9a6[_0x818e03(0x221)])&&(this[_0x818e03(0x274)][_0x818e03(0x220)](_0x41b9a6[_0x818e03(0x221)],_0x41b9a6),this[_0x818e03(0x235)](_0x818e03(0x20d),{'contextItem':_0x41b9a6,'isLoading':_0x38788c}),_0x41b9a6[_0x818e03(0x1fc)])){const _0xb44d76=this[_0x818e03(0x23f)](_0x41b9a6[_0x818e03(0x1fc)]);_0xb44d76&&_0xb44d76[_0x818e03(0x277)](_0x449525=>{const _0x3310f0=_0x818e03;this[_0x3310f0(0x22f)](_0x449525,_0x41b9a6[_0x3310f0(0x1fc)],!0x0);});}}[_0xd08627(0x24f)](_0x1ef2da){const _0x4ea9b2=_0xd08627;this[_0x4ea9b2(0x25a)][_0x4ea9b2(0x220)](_0x1ef2da[_0x4ea9b2(0x221)],_0x1ef2da);}[_0xd08627(0x258)](){const _0x36db4f=_0xd08627;this[_0x36db4f(0x27f)]={'document':{'enabled':!0x1!==this[_0x36db4f(0x263)]?.[_0x36db4f(0x26a)]?.[_0x36db4f(0x247)],'isHidden':!0x1},'urls':{'enabled':!0x1!==this[_0x36db4f(0x263)]?.[_0x36db4f(0x278)]?.[_0x36db4f(0x247)]},'files':{'enabled':!0x1!==this[_0x36db4f(0x263)]?.[_0x36db4f(0x25c)]?.[_0x36db4f(0x247)]},'sources':this[_0x36db4f(0x245)]()},this[_0x36db4f(0x235)](_0x36db4f(0x212),{'options':this[_0x36db4f(0x27f)]});}[_0xd08627(0x245)](){const _0x2ba166=_0xd08627;return this[_0x2ba166(0x263)]?.[_0x2ba166(0x253)]?.[_0x2ba166(0x1f9)](_0x1e1d13=>({..._0x1e1d13,'resources':[]}))??[];}[_0xd08627(0x205)](){const _0x55d432=_0xd08627,_0x3e3010=this[_0x55d432(0x214)]()||this[_0x55d432(0x240)]();this[_0x55d432(0x27f)][_0x55d432(0x26a)][_0x55d432(0x252)]=_0x3e3010,this[_0x55d432(0x235)](_0x55d432(0x212),{'options':this[_0x55d432(0x27f)]});}[_0xd08627(0x21b)](_0x4e4a70){const _0x944c11=_0xd08627;for(const _0xbefb4a of this[_0x944c11(0x274)][_0x944c11(0x272)]())if(_0xbefb4a[_0x944c11(0x1fc)]===_0x4e4a70)return!0x0;for(const _0x4bae70 of this[_0x944c11(0x25a)][_0x944c11(0x272)]())if(_0x4bae70[_0x944c11(0x1fc)]===_0x4e4a70)return!0x0;return!0x1;}[_0xd08627(0x23f)](_0x59ba0f){const _0x9325b1=_0xd08627,_0x3bd2be=[];for(const _0x5d36f4 of this[_0x9325b1(0x27f)][_0x9325b1(0x253)]){_0x5d36f4[_0x9325b1(0x27d)][_0x9325b1(0x231)](_0x4526e1=>_0x4526e1['id']===_0x59ba0f)&&_0x3bd2be[_0x9325b1(0x201)](_0x5d36f4['id']);}return 0x0===_0x3bd2be[_0x9325b1(0x270)]?null:_0x3bd2be;}[_0xd08627(0x22f)](_0x1fba9d,_0x49dead,_0x5de3a0){const _0x9defaf=_0xd08627,_0x44cb2f=this[_0x9defaf(0x27f)][_0x9defaf(0x253)][_0x9defaf(0x231)](_0x3c5fb7=>_0x3c5fb7['id']===_0x1fba9d);if(!_0x44cb2f)return;const _0x31fc25=_0x44cb2f[_0x9defaf(0x27d)][_0x9defaf(0x231)](_0x40be8a=>_0x40be8a['id']===_0x49dead);_0x31fc25&&(_0x31fc25[_0x9defaf(0x234)]=_0x5de3a0,this[_0x9defaf(0x235)](_0x9defaf(0x27c),{'sourceId':_0x1fba9d,'resourceId':_0x49dead,'isInContext':_0x5de3a0}));}[_0xd08627(0x26e)](_0x4e090e){const _0x6c61ac=_0xd08627;this[_0x6c61ac(0x21a)][_0x6c61ac(0x220)](_0x4e090e,!0x0),this[_0x6c61ac(0x21a)][_0x6c61ac(0x21f)]&&this[_0x6c61ac(0x235)](_0x6c61ac(0x21d),{'isUploadInProgress':!0x0});}[_0xd08627(0x219)](_0x4e7cd1){const _0x4d1626=_0xd08627;this[_0x4d1626(0x21a)][_0x4d1626(0x25e)](_0x4e7cd1),0x0===this[_0x4d1626(0x21a)][_0x4d1626(0x21f)]&&this[_0x4d1626(0x235)](_0x4d1626(0x21d),{'isUploadInProgress':!0x1});}}
23
+ const _0x5b195c=_0x3c6b;(function(_0x61094c,_0x5ebd34){const _0x4225f7=_0x3c6b,_0x4ee7aa=_0x61094c();while(!![]){try{const _0x2b53f4=-parseInt(_0x4225f7(0x18f))/0x1+-parseInt(_0x4225f7(0x149))/0x2*(-parseInt(_0x4225f7(0x11f))/0x3)+parseInt(_0x4225f7(0x119))/0x4*(-parseInt(_0x4225f7(0x146))/0x5)+-parseInt(_0x4225f7(0x192))/0x6+parseInt(_0x4225f7(0x16f))/0x7+-parseInt(_0x4225f7(0x196))/0x8+-parseInt(_0x4225f7(0x124))/0x9*(-parseInt(_0x4225f7(0x180))/0xa);if(_0x2b53f4===_0x5ebd34)break;else _0x4ee7aa['push'](_0x4ee7aa['shift']());}catch(_0x2dabb6){_0x4ee7aa['push'](_0x4ee7aa['shift']());}}}(_0x1906,0x92de4));import{CKEditorError as _0x1ce1c7,ObservableMixin as _0x53a141,uid as _0x296cbb}from'ckeditor5/src/utils.js';import{AIContextItemType as _0x5cd0b3,AIContextTextResourceType as _0x2f4824}from'../../aicore/model/aicontext.js';import{escape as _0x33b9b5}from'es-toolkit/compat';import{errorsMap as _0x51eff4}from'../../errorsmap.js';function _0x3c6b(_0xd4b231,_0x393a1c){const _0x190610=_0x1906();return _0x3c6b=function(_0x3c6ba9,_0x587ae3){_0x3c6ba9=_0x3c6ba9-0x109;let _0x545e49=_0x190610[_0x3c6ba9];return _0x545e49;},_0x3c6b(_0xd4b231,_0x393a1c);}export const AI_CONTEXT_MODEL_EVENT_NAMES=[_0x5b195c(0x144),_0x5b195c(0x179),_0x5b195c(0x15f),_0x5b195c(0x197),_0x5b195c(0x109),_0x5b195c(0x10e),_0x5b195c(0x193),_0x5b195c(0x162),_0x5b195c(0x114)];export class AIChatContext extends _0x53a141(){[_0x5b195c(0x11d)];[_0x5b195c(0x12a)];[_0x5b195c(0x17d)];constructor({connector:_0x120831,config:_0x129f37,ownerId:_0x379154}){const _0x386429=_0x5b195c;super(),this[_0x386429(0x11d)]=_0x120831,this[_0x386429(0x12a)]=_0x129f37,this[_0x386429(0x17d)]=_0x379154;}[_0x5b195c(0x138)](){const _0x38454a=_0x5b195c;this[_0x38454a(0x154)]=new Map(),this[_0x38454a(0x12c)]=new Map(),this[_0x38454a(0x191)]=new Map(),this[_0x38454a(0x14c)]=new Map(),this[_0x38454a(0x153)]();}[_0x5b195c(0x18e)](){const _0x2255f0=_0x5b195c;return this[_0x2255f0(0x154)];}async[_0x5b195c(0x11a)](_0x56cf42){const _0xe3c3f=_0x5b195c,_0x5652a1=await this[_0xe3c3f(0x14f)](_0x56cf42);return this[_0xe3c3f(0x190)](_0x5652a1),_0xe3c3f(0x158)===_0x5652a1[_0xe3c3f(0x166)]&&this[_0xe3c3f(0x169)](),_0x5652a1;}async[_0x5b195c(0x14f)](_0xabe0cf){const _0x4b65f7=_0x5b195c;if(_0xabe0cf[_0x4b65f7(0x187)]===_0x5cd0b3[_0x4b65f7(0x13c)]){const _0x1e611b=await this[_0x4b65f7(0x11d)][_0x4b65f7(0x133)](this[_0x4b65f7(0x17d)],_0xabe0cf['id'])[_0x4b65f7(0x122)]();return{'id':_0x4b65f7(0x158),'uiId':_0x4b65f7(0x158),'label':_0x4b65f7(0x120),'type':_0xabe0cf[_0x4b65f7(0x187)],'content':_0x1e611b[_0x4b65f7(0x140)],'hidden':this[_0x4b65f7(0x12c)][_0x4b65f7(0x16d)](_0x4b65f7(0x158)),'version':_0x1e611b[_0x4b65f7(0x13b)]?.[_0x4b65f7(0x14e)],'sessionId':_0x1e611b[_0x4b65f7(0x13b)]?.[_0x4b65f7(0x173)]};}return{'id':_0xabe0cf['id'],'uiId':_0xabe0cf['id'],'label':_0xabe0cf[_0x4b65f7(0x13b)]?.[_0x4b65f7(0x113)]||_0xabe0cf[_0x4b65f7(0x136)]||_0xabe0cf[_0x4b65f7(0x18b)]||_0xabe0cf['id'],'type':_0xabe0cf[_0x4b65f7(0x187)],..._0xabe0cf?.[_0x4b65f7(0x13b)]?.[_0x4b65f7(0x186)]?{'resourceId':_0xabe0cf[_0x4b65f7(0x13b)]?.[_0x4b65f7(0x186)]}:{}};}[_0x5b195c(0x181)](){const _0x697ef1=_0x5b195c;return new Map(this[_0x697ef1(0x12c)]);}[_0x5b195c(0x167)](_0x3e04f4){const _0x24eea5=_0x5b195c,_0x1fc56d=this[_0x24eea5(0x154)][_0x24eea5(0x15a)](_0x3e04f4);_0x1fc56d?.[_0x24eea5(0x194)]||this[_0x24eea5(0x10a)](_0x3e04f4);}[_0x5b195c(0x147)](){const _0x50f6d5=_0x5b195c;if(0x0===this[_0x50f6d5(0x154)][_0x50f6d5(0x174)])return;for(const _0xff453 of this[_0x50f6d5(0x154)][_0x50f6d5(0x123)]())this[_0x50f6d5(0x10a)](_0xff453[_0x50f6d5(0x166)]);const _0x1e84e6=this[_0x50f6d5(0x12c)][_0x50f6d5(0x15a)](_0x50f6d5(0x158))||this[_0x50f6d5(0x154)][_0x50f6d5(0x15a)](_0x50f6d5(0x158));_0x1e84e6&&this[_0x50f6d5(0x165)]({..._0x1e84e6,'isReadOnly':!0x0,'hidden':!0x0});}[_0x5b195c(0x178)](_0x5422d4){const _0x4d134e=_0x5b195c;for(const _0x4e69a4 of _0x5422d4[_0x4d134e(0x123)]())this[_0x4d134e(0x190)](_0x4e69a4);this[_0x4d134e(0x147)](),this[_0x4d134e(0x171)](_0x4d134e(0x197),{'contextItems':Array[_0x4d134e(0x111)](this[_0x4d134e(0x181)]()[_0x4d134e(0x123)]())});}[_0x5b195c(0x14b)](){const _0x5a91c2=_0x5b195c;return this[_0x5a91c2(0x154)][_0x5a91c2(0x16d)](_0x5a91c2(0x158));}[_0x5b195c(0x125)](){const _0x4342a5=_0x5b195c;return this[_0x4342a5(0x154)][_0x4342a5(0x16d)](_0x4342a5(0x117));}[_0x5b195c(0x176)](){const _0x443d35=_0x5b195c;return this[_0x443d35(0x12c)][_0x443d35(0x16d)](_0x443d35(0x158));}static[_0x5b195c(0x132)](_0x403a9e){const _0x651571=_0x5b195c;return Array[_0x651571(0x111)](_0x403a9e[_0x651571(0x123)]())[_0x651571(0x13a)](_0x6beb56=>this[_0x651571(0x10d)](_0x6beb56))[_0x651571(0x155)](_0x28586a=>null!==_0x28586a);}async[_0x5b195c(0x134)](_0x157a81,_0xcb9223,_0x159672=_0x5cd0b3[_0x5b195c(0x15b)]){const _0xf3d9bd=_0x5b195c,_0x1867d5=_0xf3d9bd(0x18d)+_0x296cbb();this[_0xf3d9bd(0x15c)](_0x1867d5);try{await Promise[_0xf3d9bd(0x126)](_0x157a81[_0xf3d9bd(0x13a)](async _0x492d8a=>{const _0x5c04e0=_0xf3d9bd,_0x3724fe=_0x5c04e0(0x172)+_0x296cbb(),_0x1ba3e=_0x33b9b5(_0x492d8a[_0x5c04e0(0x136)]);try{this[_0x5c04e0(0x165)]({'type':_0x159672,'label':_0xcb9223?.[_0x5c04e0(0x113)]||_0x1ba3e,'uiId':_0x3724fe,'resourceId':_0xcb9223?.[_0x5c04e0(0x186)]},!0x0);const _0x42aacc=this[_0x5c04e0(0x11d)][_0x5c04e0(0x10f)](this[_0x5c04e0(0x17d)],_0x492d8a,_0xcb9223);this[_0x5c04e0(0x191)][_0x5c04e0(0x189)](_0x3724fe,_0x42aacc[_0x5c04e0(0x183)]);const {id:_0x249df4}=await _0x42aacc[_0x5c04e0(0x115)]();this[_0x5c04e0(0x191)][_0x5c04e0(0x12b)](_0x3724fe),this[_0x5c04e0(0x168)]({'type':_0x159672,'id':_0x249df4,'label':_0xcb9223?.[_0x5c04e0(0x113)]||_0x1ba3e,'uiId':_0x3724fe,'resourceId':_0xcb9223?.[_0x5c04e0(0x186)]},!0x1);}catch(_0x1d2b8a){this[_0x5c04e0(0x191)][_0x5c04e0(0x12b)](_0x3724fe);if(!(_0x1d2b8a instanceof _0x1ce1c7&&_0x1d2b8a[_0x5c04e0(0x17b)][_0x5c04e0(0x110)](_0x5c04e0(0x10c)))){const _0x7b2007=_0x51eff4[_0x5c04e0(0x15a)](_0x1d2b8a[_0x5c04e0(0x128)])||_0x5c04e0(0x17c),_0xb402b9=new _0x1ce1c7(_0x7b2007,null,{'fileName':_0x1ba3e,..._0x1d2b8a});_0xb402b9[_0x5c04e0(0x127)]=_0x1d2b8a[_0x5c04e0(0x127)],this[_0x5c04e0(0x171)](_0x5c04e0(0x109),{'error':_0xb402b9});}this[_0x5c04e0(0x10a)](_0x3724fe);}}));}finally{this[_0xf3d9bd(0x17a)](_0x1867d5);}}[_0x5b195c(0x12e)](_0x2ddc83){const _0x40c9f1=_0x5b195c;if(this[_0x40c9f1(0x14b)]()||!this[_0x40c9f1(0x16c)][_0x40c9f1(0x137)][_0x40c9f1(0x135)])return;const _0x5834bb={'type':_0x5cd0b3[_0x40c9f1(0x13c)],'uiId':_0x40c9f1(0x158),'label':_0x2ddc83,'isReadOnly':this[_0x40c9f1(0x12c)][_0x40c9f1(0x16d)](_0x40c9f1(0x158)),'hidden':this[_0x40c9f1(0x12c)][_0x40c9f1(0x16d)](_0x40c9f1(0x158))};this[_0x40c9f1(0x165)](_0x5834bb);}async[_0x5b195c(0x116)](_0x154b96,_0x2ae039,_0x174523,_0x5d9429){const _0x16bf18=_0x5b195c,_0x5ea3ed=this[_0x16bf18(0x154)][_0x16bf18(0x15a)](_0x16bf18(0x158));if(_0x5ea3ed&&_0x154b96){_0x5ea3ed[_0x16bf18(0x117)]=_0x5d9429?_0x5d9429[_0x16bf18(0x13a)](_0x3c5616=>({'start':_0x3c5616[_0x16bf18(0x142)],'end':_0x3c5616[_0x16bf18(0x13d)]})):[];try{if(_0x5ea3ed[_0x16bf18(0x14e)]===_0x2ae039)return;const {id:_0x231997}=await this[_0x16bf18(0x11d)][_0x16bf18(0x14d)](this[_0x16bf18(0x17d)],_0x154b96,{'version':_0x2ae039,'sessionId':_0x174523})[_0x16bf18(0x115)]();_0x5ea3ed['id']=_0x231997,_0x5ea3ed[_0x16bf18(0x140)]=_0x154b96,_0x5ea3ed[_0x16bf18(0x14e)]=_0x2ae039,_0x5ea3ed[_0x16bf18(0x173)]=_0x174523;}catch(_0x4f54dc){const _0x10b887=new _0x1ce1c7(_0x16bf18(0x13f),null);_0x10b887[_0x16bf18(0x127)]=_0x4f54dc[_0x16bf18(0x127)],this[_0x16bf18(0x171)](_0x16bf18(0x109),{'error':_0x10b887});}}}[_0x5b195c(0x163)](_0x2ff99){const _0x228a77=_0x5b195c;this[_0x228a77(0x165)]({'type':_0x5cd0b3[_0x228a77(0x17f)],'label':_0x2ff99,'uiId':_0x228a77(0x117),'content':_0x2ff99});}[_0x5b195c(0x185)](){const _0x3b4a1b=_0x5b195c;this[_0x3b4a1b(0x10a)](_0x3b4a1b(0x117));}async[_0x5b195c(0x11b)](_0x5a967e,_0x5ce318){const _0x2662fd=_0x5b195c,_0x4a17bf=_0x2662fd(0x182)+_0x296cbb();this[_0x2662fd(0x15c)](_0x4a17bf);const _0x2ef27b=_0x2662fd(0x182)+_0x296cbb();try{this[_0x2662fd(0x165)]({'type':_0x5cd0b3[_0x2662fd(0x131)],'label':_0x5ce318?.[_0x2662fd(0x113)]||_0x5a967e,'uiId':_0x2ef27b,'resourceId':_0x5ce318?.[_0x2662fd(0x186)]},!0x0);const _0x506f96=this[_0x2662fd(0x11d)][_0x2662fd(0x16a)](this[_0x2662fd(0x17d)],_0x5a967e,_0x5ce318);this[_0x2662fd(0x191)][_0x2662fd(0x189)](_0x2ef27b,_0x506f96[_0x2662fd(0x183)]);const {id:_0x5ba3af}=await _0x506f96[_0x2662fd(0x115)]();this[_0x2662fd(0x191)][_0x2662fd(0x12b)](_0x2ef27b),this[_0x2662fd(0x168)]({'type':_0x5cd0b3[_0x2662fd(0x131)],'id':_0x5ba3af,'label':_0x5ce318?.[_0x2662fd(0x113)]||_0x5a967e,'uiId':_0x2ef27b,'resourceId':_0x5ce318?.[_0x2662fd(0x186)]},!0x1);}catch(_0x564105){this[_0x2662fd(0x191)][_0x2662fd(0x12b)](_0x2ef27b),(_0x564105[_0x2662fd(0x17b)][_0x2662fd(0x110)](_0x2662fd(0x10c))||this[_0x2662fd(0x171)](_0x2662fd(0x109),{'error':new _0x1ce1c7(_0x2662fd(0x16b),this,{'url':_0x5a967e,'originalError':_0x564105}),'url':_0x5a967e}),this[_0x2662fd(0x10a)](_0x2ef27b));}finally{this[_0x2662fd(0x17a)](_0x4a17bf);}}async[_0x5b195c(0x15e)](_0x5e9ffc,_0x5c8ce0,_0x3f248d){const _0x1eba43=_0x5b195c,_0x3e68c8=this[_0x1eba43(0x16c)][_0x1eba43(0x184)][_0x1eba43(0x188)](_0x418ee3=>_0x418ee3['id']===_0x5e9ffc);if(!_0x3e68c8)return this[_0x1eba43(0x171)](_0x1eba43(0x109),{'error':new _0x1ce1c7(_0x1eba43(0x12f),this,{'sourceId':_0x5e9ffc}),'sourceId':_0x5e9ffc}),[];try{const _0x5b9647=(await _0x3e68c8[_0x1eba43(0x161)](_0x5c8ce0))[_0x1eba43(0x13a)](_0x5aa756=>{const _0x9437a2=_0x1eba43,_0xf96148=this[_0x9437a2(0x145)](_0x5aa756['id']);return{..._0x5aa756,'isInContext':_0xf96148};});return _0x3e68c8[_0x1eba43(0x11e)]=_0x5b9647,this[_0x1eba43(0x171)](_0x1eba43(0x193),{'sourceId':_0x5e9ffc,'source':_0x3e68c8,'resources':_0x5b9647,'uid':_0x3f248d}),_0x5b9647;}catch(_0x12e0dd){return this[_0x1eba43(0x171)](_0x1eba43(0x109),{'error':new _0x1ce1c7(_0x1eba43(0x18c),this,{'sourceId':_0x5e9ffc,'originalError':_0x12e0dd}),'sourceId':_0x5e9ffc,'sourceLabel':_0x3e68c8[_0x1eba43(0x113)]}),[];}}async[_0x5b195c(0x129)](_0x4af14c,_0xaa6106){const _0x596e2a=_0x5b195c;if(this[_0x596e2a(0x145)](_0xaa6106['id']))return;let _0x4fd82a=_0xaa6106[_0x596e2a(0x11c)];if(!_0x4fd82a&&_0x4af14c[_0x596e2a(0x159)])try{_0x4fd82a=await _0x4af14c[_0x596e2a(0x159)](_0xaa6106['id']);}catch(_0x4da5e6){return void this[_0x596e2a(0x171)](_0x596e2a(0x109),{'error':new _0x1ce1c7(_0x596e2a(0x17e),this,{'resourceId':_0xaa6106['id'],'sourceId':_0x4af14c['id'],'originalError':_0x4da5e6}),'resourceId':_0xaa6106['id'],'sourceId':_0x4af14c['id']});}if(_0x4fd82a)switch(_0xaa6106[_0x596e2a(0x187)]){case _0x5cd0b3[_0x596e2a(0x131)]:if(_0x596e2a(0x160)!=typeof _0x4fd82a)return void this[_0x596e2a(0x171)](_0x596e2a(0x109),{'error':new _0x1ce1c7(_0x596e2a(0x156),this,{'resourceId':_0xaa6106['id'],'sourceId':_0x4af14c['id'],'expectedType':_0x596e2a(0x160),'actualType':typeof _0x4fd82a}),'resourceId':_0xaa6106['id'],'sourceId':_0x4af14c['id']});await this[_0x596e2a(0x11b)](_0x4fd82a,{'label':_0xaa6106[_0x596e2a(0x113)],'resourceId':_0xaa6106['id']});break;case _0x5cd0b3[_0x596e2a(0x15b)]:if(!(_0x4fd82a instanceof File))return void this[_0x596e2a(0x171)](_0x596e2a(0x109),{'error':new _0x1ce1c7(_0x596e2a(0x156),this,{'resourceId':_0xaa6106['id'],'sourceId':_0x4af14c['id'],'expectedType':_0x596e2a(0x152),'actualType':typeof _0x4fd82a}),'resourceId':_0xaa6106['id'],'sourceId':_0x4af14c['id']});await this[_0x596e2a(0x134)]([_0x4fd82a],{'label':_0xaa6106[_0x596e2a(0x113)],'resourceId':_0xaa6106['id']});break;case _0x5cd0b3[_0x596e2a(0x118)]:if(_0x596e2a(0x13e)!=typeof _0x4fd82a||!(_0x596e2a(0x140)in _0x4fd82a)||!(_0x596e2a(0x187)in _0x4fd82a))return void this[_0x596e2a(0x171)](_0x596e2a(0x109),{'error':new _0x1ce1c7(_0x596e2a(0x156),this,{'resourceId':_0xaa6106['id'],'sourceId':_0x4af14c['id'],'expectedType':_0x596e2a(0x12d),'actualType':typeof _0x4fd82a}),'resourceId':_0xaa6106['id'],'sourceId':_0x4af14c['id']});_0x4fd82a=AIChatContext[_0x596e2a(0x143)](_0x4fd82a,_0xaa6106[_0x596e2a(0x113)]),await this[_0x596e2a(0x134)]([_0x4fd82a],{'label':_0xaa6106[_0x596e2a(0x113)],'resourceId':_0xaa6106['id']},_0x5cd0b3[_0x596e2a(0x118)]);break;default:this[_0x596e2a(0x171)](_0x596e2a(0x109),{'error':new _0x1ce1c7(_0x596e2a(0x18a),this,{'resourceId':_0xaa6106['id'],'sourceId':_0x4af14c['id'],'resourceType':_0xaa6106[_0x596e2a(0x187)]}),'resourceId':_0xaa6106['id'],'sourceId':_0x4af14c['id']});}else this[_0x596e2a(0x171)](_0x596e2a(0x109),{'error':new _0x1ce1c7(_0x596e2a(0x15d),this,{'resourceId':_0xaa6106['id'],'sourceId':_0x4af14c['id']}),'resourceId':_0xaa6106['id'],'sourceId':_0x4af14c['id']});}static[_0x5b195c(0x143)](_0x59a2be,_0x1bbc9a){const _0x181283=_0x5b195c;switch(_0x59a2be[_0x181283(0x187)]){case _0x2f4824[_0x181283(0x175)]:return new File([_0x59a2be[_0x181283(0x140)]],_0x1bbc9a,{'type':_0x181283(0x148)});case _0x2f4824[_0x181283(0x141)]:return new File([_0x59a2be[_0x181283(0x140)]],_0x1bbc9a,{'type':_0x181283(0x130)});default:return new File([_0x59a2be[_0x181283(0x140)]],_0x1bbc9a,{'type':_0x181283(0x151)});}}static[_0x5b195c(0x10d)](_0x4dd5d4){const _0x4ee142=_0x5b195c;switch(_0x4dd5d4[_0x4ee142(0x187)]){case _0x5cd0b3[_0x4ee142(0x15b)]:return{'type':_0x5cd0b3[_0x4ee142(0x15b)],'id':_0x4dd5d4['id']};case _0x5cd0b3[_0x4ee142(0x131)]:return{'type':_0x5cd0b3[_0x4ee142(0x131)],'id':_0x4dd5d4['id']};case _0x5cd0b3[_0x4ee142(0x13c)]:return{'type':_0x5cd0b3[_0x4ee142(0x13c)],'id':_0x4dd5d4['id'],..._0x4dd5d4[_0x4ee142(0x117)]?.[_0x4ee142(0x150)]&&{'selection':_0x4dd5d4[_0x4ee142(0x117)]}};case _0x5cd0b3[_0x4ee142(0x118)]:return{'type':_0x5cd0b3[_0x4ee142(0x15b)],'id':_0x4dd5d4['id']};default:return null;}}[_0x5b195c(0x165)](_0x82f084,_0xfc87a9=!0x1){const _0x1946f7=_0x5b195c;if(this[_0x1946f7(0x154)][_0x1946f7(0x189)](_0x82f084[_0x1946f7(0x166)],_0x82f084),_0x82f084[_0x1946f7(0x170)]||this[_0x1946f7(0x171)](_0x1946f7(0x144),{'contextItem':_0x82f084,'isLoading':_0xfc87a9}),_0x1946f7(0x158)===_0x82f084[_0x1946f7(0x166)]&&this[_0x1946f7(0x169)](),_0x82f084[_0x1946f7(0x186)]){const _0x361d85=this[_0x1946f7(0x112)](_0x82f084[_0x1946f7(0x186)]);_0x361d85&&_0x361d85[_0x1946f7(0x121)](_0x4804bc=>{const _0x20f169=_0x1946f7;this[_0x20f169(0x10b)](_0x4804bc,_0x82f084[_0x20f169(0x186)],!0x0);});}}[_0x5b195c(0x10a)](_0x39f9a1){const _0x214de5=_0x5b195c,_0x1c2301=this[_0x214de5(0x154)][_0x214de5(0x15a)](_0x39f9a1),_0x359452=this[_0x214de5(0x191)][_0x214de5(0x15a)](_0x39f9a1);if(_0x359452&&(_0x359452[_0x214de5(0x16e)](),this[_0x214de5(0x191)][_0x214de5(0x12b)](_0x39f9a1)),_0x1c2301?.[_0x214de5(0x186)]){const _0x5cb46d=this[_0x214de5(0x112)](_0x1c2301[_0x214de5(0x186)]);_0x5cb46d&&_0x5cb46d[_0x214de5(0x121)](_0x1857cb=>{const _0x4443a7=_0x214de5;this[_0x4443a7(0x10b)](_0x1857cb,_0x1c2301[_0x4443a7(0x186)],!0x1);});}this[_0x214de5(0x154)][_0x214de5(0x12b)](_0x39f9a1),this[_0x214de5(0x171)](_0x214de5(0x179),{'uiId':_0x39f9a1,'type':_0x1c2301?.[_0x214de5(0x187)]}),_0x214de5(0x158)===_0x39f9a1&&this[_0x214de5(0x169)]();}[_0x5b195c(0x168)](_0x3375a9,_0x44dbea){const _0x1eaccb=_0x5b195c;if(this[_0x1eaccb(0x154)][_0x1eaccb(0x16d)](_0x3375a9[_0x1eaccb(0x166)])&&(this[_0x1eaccb(0x154)][_0x1eaccb(0x189)](_0x3375a9[_0x1eaccb(0x166)],_0x3375a9),this[_0x1eaccb(0x171)](_0x1eaccb(0x15f),{'contextItem':_0x3375a9,'isLoading':_0x44dbea}),_0x3375a9[_0x1eaccb(0x186)])){const _0x1e6ce3=this[_0x1eaccb(0x112)](_0x3375a9[_0x1eaccb(0x186)]);_0x1e6ce3&&_0x1e6ce3[_0x1eaccb(0x121)](_0x25e13c=>{const _0x5cc4f6=_0x1eaccb;this[_0x5cc4f6(0x10b)](_0x25e13c,_0x3375a9[_0x5cc4f6(0x186)],!0x0);});}}[_0x5b195c(0x190)](_0x17acc6){const _0x7bb2ce=_0x5b195c;this[_0x7bb2ce(0x12c)][_0x7bb2ce(0x189)](_0x17acc6[_0x7bb2ce(0x166)],_0x17acc6);}[_0x5b195c(0x153)](){const _0x137c91=_0x5b195c;this[_0x137c91(0x16c)]={'document':{'enabled':!0x1!==this[_0x137c91(0x12a)]?.[_0x137c91(0x137)]?.[_0x137c91(0x135)],'isHidden':!0x1},'urls':{'enabled':!0x1!==this[_0x137c91(0x12a)]?.[_0x137c91(0x164)]?.[_0x137c91(0x135)]},'files':{'enabled':!0x1!==this[_0x137c91(0x12a)]?.[_0x137c91(0x139)]?.[_0x137c91(0x135)]},'sources':this[_0x137c91(0x195)]()},this[_0x137c91(0x171)](_0x137c91(0x10e),{'options':this[_0x137c91(0x16c)]});}[_0x5b195c(0x195)](){const _0xae4c2a=_0x5b195c;return this[_0xae4c2a(0x12a)]?.[_0xae4c2a(0x184)]?.[_0xae4c2a(0x13a)](_0x4e189c=>({..._0x4e189c,'resources':[]}))??[];}[_0x5b195c(0x169)](){const _0x13b03c=_0x5b195c,_0x500c6e=this[_0x13b03c(0x14b)]()||this[_0x13b03c(0x176)]();this[_0x13b03c(0x16c)][_0x13b03c(0x137)][_0x13b03c(0x177)]=_0x500c6e,this[_0x13b03c(0x171)](_0x13b03c(0x10e),{'options':this[_0x13b03c(0x16c)]});}[_0x5b195c(0x145)](_0x11ab36){const _0x5a7904=_0x5b195c;for(const _0x245e8a of this[_0x5a7904(0x154)][_0x5a7904(0x123)]())if(_0x245e8a[_0x5a7904(0x186)]===_0x11ab36)return!0x0;for(const _0x1f632c of this[_0x5a7904(0x12c)][_0x5a7904(0x123)]())if(_0x1f632c[_0x5a7904(0x186)]===_0x11ab36)return!0x0;return!0x1;}[_0x5b195c(0x112)](_0x6a1927){const _0x44832a=_0x5b195c,_0x1ec45a=[];for(const _0x591e76 of this[_0x44832a(0x16c)][_0x44832a(0x184)]){_0x591e76[_0x44832a(0x11e)][_0x44832a(0x188)](_0x308e2a=>_0x308e2a['id']===_0x6a1927)&&_0x1ec45a[_0x44832a(0x14a)](_0x591e76['id']);}return 0x0===_0x1ec45a[_0x44832a(0x150)]?null:_0x1ec45a;}[_0x5b195c(0x10b)](_0x1660a7,_0x511c0a,_0x471d54){const _0x4fcc66=_0x5b195c,_0x15deaf=this[_0x4fcc66(0x16c)][_0x4fcc66(0x184)][_0x4fcc66(0x188)](_0x26d566=>_0x26d566['id']===_0x1660a7);if(!_0x15deaf)return;const _0x402f9a=_0x15deaf[_0x4fcc66(0x11e)][_0x4fcc66(0x188)](_0x57f0ec=>_0x57f0ec['id']===_0x511c0a);_0x402f9a&&(_0x402f9a[_0x4fcc66(0x157)]=_0x471d54,this[_0x4fcc66(0x171)](_0x4fcc66(0x162),{'sourceId':_0x1660a7,'resourceId':_0x511c0a,'isInContext':_0x471d54}));}[_0x5b195c(0x15c)](_0x2434e2){const _0x532203=_0x5b195c;this[_0x532203(0x14c)][_0x532203(0x189)](_0x2434e2,!0x0),this[_0x532203(0x14c)][_0x532203(0x174)]&&this[_0x532203(0x171)](_0x532203(0x114),{'isUploadInProgress':!0x0});}[_0x5b195c(0x17a)](_0x2211d4){const _0x4ed849=_0x5b195c;this[_0x4ed849(0x14c)][_0x4ed849(0x12b)](_0x2211d4),0x0===this[_0x4ed849(0x14c)][_0x4ed849(0x174)]&&this[_0x4ed849(0x171)](_0x4ed849(0x114),{'isUploadInProgress':!0x1});}}function _0x1906(){const _0x4ffa37=['getData','get','FILE','_startUploadOperation','ai-chat-resource-no-data','loadSourceResources','contextItemLoadingEnded','string','getResources','resourceStateChanged','addSelectionToContext','urls','_addContextItem','uiId','removeFromContext','_finishContextItemLoading','_toggleAddCurrentDocumentOptionVisibility','uploadUrl','ai-chat-url-upload-failed','_addContextOptionsState','has','abort','5462380SwhqVl','hidden','fire','file-','sessionId','size','MARKDOWN','isCurrentDocumentInConversation','isHidden','addToConversationContext','contextItemRemoved','_finishUploadOperation','message','ai-chat-file-upload-failed','_ownerId','ai-chat-resource-load-failed','SELECTION','20fUswda','getSentContextItems','url-','abortController','sources','removeSelectionFromContext','resourceId','type','find','set','ai-chat-context-unsupported-type','url','ai-chat-source-resources-load-failed','files-','getPendingContextItems','1051539LQbLzB','_addToConversationContextItem','_ongoingUploads','607788aBbRIQ','sourceResourcesLoaded','isReadOnly','_getCustomSourcesInitialState','73408FxKfCE','contextSent','error','_removeContextItem','_updateResourceInContextState','ai-request-aborted','_mapContextItemToRequestData','addContextOptionsChanged','uploadFile','startsWith','from','_findSourceIdsByResourceId','label','uploadProgressChanged','getId','updateCurrentDocument','selection','TEXT','135244PjBUrw','populateFromMessage','addUrlToContext','data','_connector','resources','15szJMJp','Current\x20document','forEach','getDocument','values','7407333VScBLo','isSelectionInContext','all','stack','code','addResourceToContext','_config','delete','_conversationContextItems','object\x20with\x20content\x20and\x20type\x20properties','addCurrentDocumentToContext','ai-chat-source-not-found','text/html','URL','mapContextItemsToRequestData','fetchDocument','addFilesToContext','enabled','name','document','init','files','map','attributes','DOCUMENT','end','object','ai-chat-document-upload-failed','content','HTML','start','_convertTextResourceToFile','contextItemAdded','_isResourceInContext','145GpCrlz','clearPendingContextItems','text/markdown','127076mEVYoW','push','isCurrentDocumentInContext','_ongoingUploadOperations','uploadDocument','version','_createContextItemFromContent','length','text/plain','File','_setAddContextOptionsDefaultState','_pendingContextItems','filter','ai-chat-context-invalid-data','isInContext','current-document'];_0x1906=function(){return _0x4ffa37;};return _0x1906();}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x393da5=_0x541e;(function(_0x2d0a9e,_0x2b3081){const _0x69433c=_0x541e,_0x424785=_0x2d0a9e();while(!![]){try{const _0x4d7de6=parseInt(_0x69433c(0x1bd))/0x1+parseInt(_0x69433c(0x1f7))/0x2+-parseInt(_0x69433c(0x1b8))/0x3+-parseInt(_0x69433c(0x1d7))/0x4*(-parseInt(_0x69433c(0x200))/0x5)+-parseInt(_0x69433c(0x1ca))/0x6+parseInt(_0x69433c(0x20d))/0x7+-parseInt(_0x69433c(0x1e2))/0x8;if(_0x4d7de6===_0x2b3081)break;else _0x424785['push'](_0x424785['shift']());}catch(_0x1e0471){_0x424785['push'](_0x424785['shift']());}}}(_0x32ae,0xc879c));import{CKEditorError as _0x14e2dd,EmitterMixin as _0x3b3df1,logWarning as _0x1f8502}from'ckeditor5/src/utils.js';import{AI_MODEL_EVENT_NAMES as _0x530de8}from'../../aicore/model/aiinteraction.js';import{AIChatContext as _0x23f3d1,AI_CONTEXT_MODEL_EVENT_NAMES as _0x356d4b}from'./aichatcontext.js';import{AICapabilities as _0x48fcb7,CAPABILITIES_MODEL_EVENT_NAMES as _0x124c97}from'../../aicore/model/aicapabilities.js';import{AIChatInteraction as _0x117215}from'./aichatinteraction.js';function _0x541e(_0x4b6295,_0x30f81c){const _0x32ae66=_0x32ae();return _0x541e=function(_0x541e69,_0x40401e){_0x541e69=_0x541e69-0x1ae;let _0x3a41f5=_0x32ae66[_0x541e69];return _0x3a41f5;},_0x541e(_0x4b6295,_0x30f81c);}function _0x32ae(){const _0x3164b7=['addUrlToContext','group','find','sessionId','ai-chat-conversation-set-model-not-available','ai-chat-conversation-init-from-id-failed','options','interactionCreated','assistant','toLowerCase','setModel','removeInteraction','_extractContextItems','user','quickActionData','1652283hBHbYj','ai-chat-conversation-start-failed','set','isAvailable','length','533182owWYjZ','destroy','webSearch','connector','model','code','getModel','handleUserInteraction','removeSelectionFromContext','getCapabilitiesConfig','getAll','addSelectionToContext','updateCurrentDocument','5678580mtRxIv','stop','appendContent','currentReply','push','conversationId','_processMessagesToInteractions','modification-delta','selectedModel','indexOf','ai-chat-conversation-init-failed','chatCapabilities','getDocumentContext','300EmaSTh','get','populateFromMessage','ai-chat-conversation-start-no-model-selected','addResourceToContext','contextItems','fire','removeFromContext','capabilities','content','fetchConversation','2619840CNZhFF','getMessages','reasoning','chatContext','getAvailableModels','fetchConversationMessages','type','ai-chat-conversation-set-model-null','addFilesToContext','load','startConversation','isCurrentDocumentInConversation','stack','title','reset','updateCurrentDocumentInContext','loadSourceResources','text-delta','createInteraction','getCurrentDocumentContext','getInteraction','1473622XQVoAP','modelSelected','prompt','getPendingContextItems','isStarted','splice','ai-chat-handle-user-interaction-already-in-progress','conversationInitialized','ai-chat-handle-user-interaction-start-failed','62165bPIZYn','currentInteraction','hasOwn','toggleReasoning','lastInteraction','isSelectionInContext','attributes','ai-chat-conversation-already-started','role','getConversation','chatModels','getEditor','error','3103457cYGvWQ','delegate','ai-chat-handle-user-conversation-not-initialized','toggleWebSearch','addToConversationContext','text','isCurrentDocumentInContext','interactions','message','setConversationTitle','selectedModelId','createReply','conversationStarted','addCurrentDocumentToContext','init','start'];_0x32ae=function(){return _0x3164b7;};return _0x32ae();}import{errorsMap as _0x478617}from'../../errorsmap.js';export class AIChatConversation extends _0x3b3df1(){['id'];[_0x393da5(0x1fb)]=!0x1;[_0x393da5(0x214)]=[];[_0x393da5(0x201)];[_0x393da5(0x1d2)];[_0x393da5(0x1c0)];[_0x393da5(0x1af)];constructor(_0xb9f27c){const _0x4457df=_0x393da5;super(),this[_0x4457df(0x1af)]=_0xb9f27c,this[_0x4457df(0x1c0)]=_0xb9f27c[_0x4457df(0x1c0)],this[_0x4457df(0x20a)]=_0xb9f27c[_0x4457df(0x20a)],this['id']=_0xb9f27c[_0x4457df(0x1cf)];}async[_0x393da5(0x21b)](_0x2e6405){const _0xfbc81d=_0x393da5;try{this[_0xfbc81d(0x1e5)]=new _0x23f3d1({'connector':this[_0xfbc81d(0x1c0)],'config':_0x2e6405,'ownerId':this['id']}),this[_0xfbc81d(0x1e5)][_0xfbc81d(0x20e)](..._0x356d4b)['to'](this),this[_0xfbc81d(0x1e5)][_0xfbc81d(0x21b)](),this[_0xfbc81d(0x1d5)]=new _0x48fcb7(),this[_0xfbc81d(0x1d5)][_0xfbc81d(0x20e)](..._0x124c97)['to'](this),this[_0xfbc81d(0x1d5)][_0xfbc81d(0x21b)]();const _0x1ea8b4=await this[_0xfbc81d(0x20a)][_0xfbc81d(0x1e6)]();this[_0xfbc81d(0x1dd)](_0xfbc81d(0x1fe),{'availableModels':_0x1ea8b4});const _0x12a163=await this[_0xfbc81d(0x20a)][_0xfbc81d(0x1c3)](this[_0xfbc81d(0x1af)][_0xfbc81d(0x217)]);_0x12a163&&await this[_0xfbc81d(0x1b3)](_0x12a163);}catch(_0x5952ce){const _0x4014e7=new _0x14e2dd(_0xfbc81d(0x1d4),null,{'message':_0x5952ce[_0xfbc81d(0x215)]||_0x5952ce});_0x4014e7[_0xfbc81d(0x1ee)]=_0x5952ce[_0xfbc81d(0x1ee)],this[_0xfbc81d(0x1dd)](_0xfbc81d(0x20c),{'error':_0x4014e7});}}async[_0x393da5(0x21c)](){const _0x3191fa=_0x393da5;if(this[_0x3191fa(0x1fb)])throw new _0x14e2dd(_0x3191fa(0x207),null,{'conversation':this});if(!this[_0x3191fa(0x1d2)])throw new _0x14e2dd(_0x3191fa(0x1da),null,{'conversation':this});try{const {id:_0x4db44c}=await this[_0x3191fa(0x1c0)][_0x3191fa(0x1ec)](this['id'],this[_0x3191fa(0x1af)][_0x3191fa(0x21e)])[_0x3191fa(0x209)]();this['id']=_0x4db44c,this[_0x3191fa(0x1fb)]=!0x0,this[_0x3191fa(0x1dd)](_0x3191fa(0x219),{'conversationId':this['id'],'selectedModel':this[_0x3191fa(0x1d2)]});}catch(_0x120c7a){const _0x6d8538=new _0x14e2dd(_0x3191fa(0x1b9),null,{'message':_0x120c7a[_0x3191fa(0x215)],'conversationId':this['id']});throw _0x6d8538[_0x3191fa(0x1ee)]=_0x120c7a[_0x3191fa(0x1ee)],this[_0x3191fa(0x1dd)](_0x3191fa(0x20c),{'error':_0x6d8538}),_0x6d8538;}}async[_0x393da5(0x1eb)](_0x221348,_0x323b13){const _0x1ba8d0=_0x393da5;try{const _0x32c0b9=await this[_0x1ba8d0(0x1c0)][_0x1ba8d0(0x1e1)](_0x221348)[_0x1ba8d0(0x209)](),_0xb7c7b6=await this[_0x1ba8d0(0x1c0)][_0x1ba8d0(0x1e7)](_0x221348)[_0x1ba8d0(0x1e3)](),_0xa90ac6=_0xb7c7b6[0x0][_0x1ba8d0(0x1c1)];this[_0x1ba8d0(0x1fb)]=!0x0,this['id']=_0x32c0b9['id'],_0x1ba8d0(0x1ef)in _0x32c0b9?this[_0x1ba8d0(0x1dd)](_0x1ba8d0(0x216),_0x32c0b9[_0x1ba8d0(0x1ef)],!0x0):this[_0x1ba8d0(0x1dd)](_0x1ba8d0(0x216),'',!0x0);const _0x4dcef4=(await this[_0x1ba8d0(0x20a)][_0x1ba8d0(0x1c7)]())[_0x1ba8d0(0x21f)](_0x14858f=>_0x14858f['id'][_0x1ba8d0(0x1b2)]()===_0xa90ac6[_0x1ba8d0(0x1b2)]());return this[_0x1ba8d0(0x1d2)]=_0x4dcef4,this[_0x1ba8d0(0x1dd)](_0x1ba8d0(0x1f8),{'selectedModel':_0x4dcef4,'isDisabled':!0x0}),await this[_0x1ba8d0(0x1d0)](_0xb7c7b6,_0x323b13,_0xa90ac6),this[_0x1ba8d0(0x201)]=void 0x0,this;}catch(_0x5d9004){const _0x4c26c5=new _0x14e2dd(_0x1ba8d0(0x1ae),null,{'message':_0x5d9004[_0x1ba8d0(0x215)],'conversationId':_0x221348});throw _0x4c26c5[_0x1ba8d0(0x1ee)]=_0x5d9004[_0x1ba8d0(0x1ee)],this[_0x1ba8d0(0x1dd)](_0x1ba8d0(0x20c),{'error':_0x4c26c5}),_0x4c26c5;}}async[_0x393da5(0x1d0)](_0x106885,_0x4e21ca,_0x2a55e6){const _0x8744fe=_0x393da5;let _0x1a2d26;for(const _0x28d0b7 of _0x106885)if(_0x8744fe(0x1b6)===_0x28d0b7[_0x8744fe(0x208)]){const _0x588403=await this[_0x8744fe(0x1b5)](_0x28d0b7),_0x69ee02={'isReasoningEnabled':Object[_0x8744fe(0x202)](_0x28d0b7[_0x8744fe(0x1df)],_0x8744fe(0x1e4)),'isWebSearchEnabled':Object[_0x8744fe(0x202)](_0x28d0b7[_0x8744fe(0x1df)],_0x8744fe(0x1bf))};_0x1a2d26=this[_0x8744fe(0x1f4)]({'userMessage':_0x28d0b7[_0x8744fe(0x1f9)],'contextItems':_0x588403,'capabilities':_0x69ee02,'modelId':_0x2a55e6,'quickActionData':_0x28d0b7[_0x8744fe(0x206)]?.[_0x8744fe(0x1b7)]}),this[_0x8744fe(0x201)]=_0x1a2d26,this[_0x8744fe(0x1e5)][_0x8744fe(0x211)](this[_0x8744fe(0x201)][_0x8744fe(0x1dc)]);}else{if(_0x8744fe(0x1b1)===_0x28d0b7[_0x8744fe(0x208)]&&_0x1a2d26)for(const _0x48393d of _0x28d0b7[_0x8744fe(0x1e0)]){const _0x242aa5=_0x8744fe(0x212)===_0x48393d[_0x8744fe(0x1e8)]?_0x8744fe(0x1f3):_0x8744fe(0x1d1),_0x3b9e86=_0x1a2d26[_0x8744fe(0x1d6)]()?.[_0x8744fe(0x220)]!==_0x4e21ca;_0x1a2d26[_0x8744fe(0x1cd)]=_0x1a2d26[_0x8744fe(0x218)]({'type':_0x242aa5,'isDone':!0x0,'interactionId':_0x1a2d26['id'],'areActionsDisabled':_0x3b9e86}),_0x1a2d26[_0x8744fe(0x1cd)][_0x8744fe(0x1cc)](_0x48393d[_0x8744fe(0x1e0)]);}}}async[_0x393da5(0x1b5)](_0x4af419){const _0x5283cb=_0x393da5,_0x19466d=new Map();if(!_0x4af419[_0x5283cb(0x1e0)])return _0x19466d;for(const _0x5c0d80 of _0x4af419[_0x5283cb(0x1e0)]){const _0x27c187=await this[_0x5283cb(0x1e5)][_0x5283cb(0x1d9)](_0x5c0d80);_0x27c187&&_0x19466d[_0x5283cb(0x1ba)](_0x27c187['id'],_0x27c187);}return _0x19466d;}async[_0x393da5(0x1c4)]({userMessage:_0x1ad502,quickActionData:_0x275686}){const _0xd44c27=_0x393da5;if(!this[_0xd44c27(0x1fb)])throw new _0x14e2dd(_0xd44c27(0x20f),null,{'conversation':this});if(this[_0xd44c27(0x201)])throw new _0x14e2dd(_0xd44c27(0x1fd),null,{'conversation':this});try{const _0x57a72e=this[_0xd44c27(0x1e5)][_0xd44c27(0x1fa)](),_0xeb974d=this[_0xd44c27(0x1d5)][_0xd44c27(0x1c6)](),_0xee378=this[_0xd44c27(0x1d2)]['id'];this[_0xd44c27(0x201)]=this[_0xd44c27(0x1f4)]({'userMessage':_0x1ad502,'contextItems':_0x57a72e,'capabilities':_0xeb974d,'modelId':_0xee378,'quickActionData':_0x275686}),await this[_0xd44c27(0x201)][_0xd44c27(0x21c)](),this[_0xd44c27(0x1e5)][_0xd44c27(0x211)](this[_0xd44c27(0x201)][_0xd44c27(0x1dc)]);}catch(_0x244947){if(_0x244947 instanceof _0x14e2dd)this[_0xd44c27(0x1dd)](_0xd44c27(0x20c),{'interactionId':this[_0xd44c27(0x201)]?this[_0xd44c27(0x201)]['id']:void 0x0,'error':_0x244947});else{const _0x4269b7=_0x478617[_0xd44c27(0x1d8)](_0x244947[_0xd44c27(0x1c2)])||_0xd44c27(0x1ff);this[_0xd44c27(0x1dd)](_0xd44c27(0x20c),{'interactionId':this[_0xd44c27(0x201)]?this[_0xd44c27(0x201)]['id']:void 0x0,'error':new _0x14e2dd(_0x4269b7,null,{'error':_0x244947})});}}finally{this[_0xd44c27(0x201)]?.[_0xd44c27(0x1cb)](),this[_0xd44c27(0x201)]=void 0x0;}}[_0x393da5(0x1f4)]({userMessage:_0x2e5a3b,contextItems:_0xc97861,capabilities:_0x1d4aa3,modelId:_0x34d2c3,quickActionData:_0x106419}){const _0x105eaf=_0x393da5,_0x3423a9=new _0x117215({'userMessage':_0x2e5a3b,'contextItems':_0xc97861,'capabilities':_0x1d4aa3,'conversationId':this['id'],'connector':this[_0x105eaf(0x1c0)],'editor':this[_0x105eaf(0x1af)][_0x105eaf(0x20b)]&&this[_0x105eaf(0x1af)][_0x105eaf(0x20b)](),'model':_0x34d2c3,'quickActionData':_0x106419});return _0x3423a9[_0x105eaf(0x20e)](..._0x530de8)['to'](this),this[_0x105eaf(0x214)][_0x105eaf(0x1ce)](_0x3423a9),this[_0x105eaf(0x1dd)](_0x105eaf(0x1b0),_0x3423a9),_0x3423a9;}[_0x393da5(0x1f6)](_0x890f28){const _0x30c867=_0x393da5;return this[_0x30c867(0x214)][_0x30c867(0x21f)](_0x4cf64c=>_0x4cf64c['id']===_0x890f28);}[_0x393da5(0x1b4)](_0x195f4e){const _0x215e31=_0x393da5,_0x28653a=this[_0x215e31(0x1f6)](_0x195f4e);_0x28653a&&(_0x28653a[_0x215e31(0x1be)](),this[_0x215e31(0x214)][_0x215e31(0x1fc)](this[_0x215e31(0x214)][_0x215e31(0x1d3)](_0x28653a),0x1));}get[_0x393da5(0x204)](){const _0x109c18=_0x393da5;return this[_0x109c18(0x214)][this[_0x109c18(0x214)][_0x109c18(0x1bc)]-0x1];}[_0x393da5(0x21a)](_0x4da5b0){const _0x1f4ea2=_0x393da5;this[_0x1f4ea2(0x1e5)][_0x1f4ea2(0x21a)](_0x4da5b0);}async[_0x393da5(0x1f1)]({content:_0x52e17e,version:_0x326712,sessionId:_0x4e3a5e,selections:_0x59596f}){const _0x42d9bd=_0x393da5;await this[_0x42d9bd(0x1e5)][_0x42d9bd(0x1c9)](_0x52e17e,_0x326712,_0x4e3a5e,_0x59596f);}[_0x393da5(0x1f5)](){const _0x18ddd2=_0x393da5;return this[_0x18ddd2(0x201)]?.[_0x18ddd2(0x1d6)]()?.[_0x18ddd2(0x1e0)]||'';}[_0x393da5(0x1c8)](_0x3b0764){const _0x3d260a=_0x393da5;this[_0x3d260a(0x1e5)][_0x3d260a(0x1c8)](_0x3b0764);}[_0x393da5(0x1c5)](){const _0x533ba7=_0x393da5;this[_0x533ba7(0x1e5)][_0x533ba7(0x1c5)]();}[_0x393da5(0x1ea)](_0x34ee47){const _0x2cfd56=_0x393da5;this[_0x2cfd56(0x1e5)][_0x2cfd56(0x1ea)](_0x34ee47);}[_0x393da5(0x21d)](_0x150486){const _0x1bc344=_0x393da5;this[_0x1bc344(0x1e5)][_0x1bc344(0x21d)](_0x150486);}[_0x393da5(0x1db)](_0x24a054,_0x128cc3){const _0x4fae7=_0x393da5;this[_0x4fae7(0x1e5)][_0x4fae7(0x1db)](_0x24a054,_0x128cc3);}[_0x393da5(0x1f2)](_0x54f45d,_0x218a84,_0x88efd){const _0x507dcb=_0x393da5;return this[_0x507dcb(0x1e5)][_0x507dcb(0x1f2)](_0x54f45d,_0x218a84,_0x88efd);}[_0x393da5(0x1de)](_0x44c816){const _0x393f77=_0x393da5;this[_0x393f77(0x1e5)][_0x393f77(0x1de)](_0x44c816);}[_0x393da5(0x210)](){const _0x4ad545=_0x393da5;this[_0x4ad545(0x1d5)][_0x4ad545(0x210)]();}[_0x393da5(0x203)](){const _0x2cb437=_0x393da5;this[_0x2cb437(0x1d5)][_0x2cb437(0x203)]();}[_0x393da5(0x213)](){const _0x12202a=_0x393da5;return this[_0x12202a(0x1e5)][_0x12202a(0x213)]();}[_0x393da5(0x1ed)](){const _0x2835be=_0x393da5;return this[_0x2835be(0x1e5)][_0x2835be(0x1ed)]();}[_0x393da5(0x205)](){const _0x4061f4=_0x393da5;return this[_0x4061f4(0x1e5)][_0x4061f4(0x205)]();}async[_0x393da5(0x1b3)](_0x36518f){const _0x56084c=_0x393da5;_0x36518f?!0x1===await this[_0x56084c(0x20a)][_0x56084c(0x1bb)](_0x36518f)&&(_0x1f8502(_0x56084c(0x221),{'conversation':this,'model':_0x36518f}),_0x36518f=(await this[_0x56084c(0x20a)][_0x56084c(0x1e6)]())[0x0]):(_0x1f8502(_0x56084c(0x1e9),{'conversation':this}),_0x36518f=(await this[_0x56084c(0x20a)][_0x56084c(0x1e6)]())[0x0]),_0x36518f['id']!==this[_0x56084c(0x1d2)]?.['id']&&(this[_0x56084c(0x1d2)]=_0x36518f,this[_0x56084c(0x1d5)][_0x56084c(0x1f0)](),this[_0x56084c(0x1dd)](_0x56084c(0x1f8),{'selectedModel':_0x36518f}));}}
23
+ const _0xa4e42=_0x581b;(function(_0x406f51,_0x452903){const _0x1ebb23=_0x581b,_0x58ae33=_0x406f51();while(!![]){try{const _0x26dc56=-parseInt(_0x1ebb23(0xf7))/0x1+-parseInt(_0x1ebb23(0x12a))/0x2+-parseInt(_0x1ebb23(0xf5))/0x3*(-parseInt(_0x1ebb23(0x14d))/0x4)+-parseInt(_0x1ebb23(0x115))/0x5+-parseInt(_0x1ebb23(0x139))/0x6+parseInt(_0x1ebb23(0x11f))/0x7*(-parseInt(_0x1ebb23(0xde))/0x8)+-parseInt(_0x1ebb23(0x136))/0x9*(-parseInt(_0x1ebb23(0x131))/0xa);if(_0x26dc56===_0x452903)break;else _0x58ae33['push'](_0x58ae33['shift']());}catch(_0x1c46d2){_0x58ae33['push'](_0x58ae33['shift']());}}}(_0x1f8c,0x22883));import{CKEditorError as _0x21c9b8,EmitterMixin as _0xd3d689,logWarning as _0x5bed54}from'ckeditor5/src/utils.js';function _0x581b(_0x118524,_0x329bf0){const _0x1f8c8b=_0x1f8c();return _0x581b=function(_0x581b05,_0x423725){_0x581b05=_0x581b05-0xdc;let _0x1126a8=_0x1f8c8b[_0x581b05];return _0x1126a8;},_0x581b(_0x118524,_0x329bf0);}import{AI_MODEL_EVENT_NAMES as _0x1240ce}from'../../aicore/model/aiinteraction.js';import{AIChatContext as _0x3ce10c,AI_CONTEXT_MODEL_EVENT_NAMES as _0x58535d}from'./aichatcontext.js';import{AICapabilities as _0x3b2d76,CAPABILITIES_MODEL_EVENT_NAMES as _0x5b1c76}from'../../aicore/model/aicapabilities.js';import{AIChatInteraction as _0x3914d9}from'./aichatinteraction.js';import{errorsMap as _0x5226d4}from'../../errorsmap.js';function _0x1f8c(){const _0x5916e4=['conversationInitialized','error','getEditor','addSelectionToContext','_extractContextItems','conversationStarted','user','490443AbRuCX','setModel','157630GSeNuq','reasoning','fetchConversation','connector','modelSelected','fetchConversationMessages','sessionId','chatCapabilities','ai-chat-conversation-set-model-null','prompt','content','createInteraction','destroy','options','toggleReasoning','interactionCreated','toggleWebSearch','reset','ai-chat-conversation-init-failed','ai-chat-conversation-start-no-model-selected','appendContent','handleUserInteraction','text-delta','contextItems','loadSourceResources','addUrlToContext','start','stack','get','conversationId','735155rzFNzw','getCurrentDocumentContext','getCapabilitiesConfig','model','ai-chat-conversation-set-model-not-available','init','webSearch','getDocumentContext','createReply','delegate','5299uXhcHm','attributes','selectedModel','push','getPendingContextItems','updateCurrentDocument','isCurrentDocumentInContext','chatContext','isStarted','load','getMessages','470688Vkomtl','indexOf','group','fire','length','ai-chat-conversation-already-started','code','3860460mXKUlD','addFilesToContext','addToConversationContext','addResourceToContext','getAll','18xxVOSK','populateFromMessage','currentInteraction','1265856hOTBaU','ai-chat-conversation-start-failed','selectedModelId','hasOwn','removeSelectionFromContext','interactions','getConversation','quickActionData','isCurrentDocumentInConversation','find','role','set','getModel','currentReply','text','getInteraction','isSelectionInContext','lastInteraction','modification-delta','stop','4RPSIYZ','toLowerCase','ai-chat-conversation-init-from-id-failed','ai-chat-handle-user-interaction-already-in-progress','updateCurrentDocumentInContext','_processMessagesToInteractions','title','456InmQEe','startConversation','ai-chat-handle-user-interaction-start-failed','message','getAvailableModels','capabilities','type','addCurrentDocumentToContext','chatModels','splice','setConversationTitle','removeFromContext','isAvailable','ai-chat-handle-user-conversation-not-initialized','assistant','removeInteraction'];_0x1f8c=function(){return _0x5916e4;};return _0x1f8c();}export class AIChatConversation extends _0xd3d689(){['id'];[_0xa4e42(0x127)]=!0x1;[_0xa4e42(0x13e)]=[];[_0xa4e42(0x138)];[_0xa4e42(0x121)];[_0xa4e42(0xfa)];[_0xa4e42(0x104)];constructor(_0x4920ed){const _0x8bf488=_0xa4e42;super(),this[_0x8bf488(0x104)]=_0x4920ed,this[_0x8bf488(0xfa)]=_0x4920ed[_0x8bf488(0xfa)],this[_0x8bf488(0xe6)]=_0x4920ed[_0x8bf488(0xe6)],this['id']=_0x4920ed[_0x8bf488(0x114)];}async[_0xa4e42(0x11a)](_0x230381){const _0x3adfb9=_0xa4e42;try{this[_0x3adfb9(0x126)]=new _0x3ce10c({'connector':this[_0x3adfb9(0xfa)],'config':_0x230381,'ownerId':this['id']}),this[_0x3adfb9(0x126)][_0x3adfb9(0x11e)](..._0x58535d)['to'](this),this[_0x3adfb9(0x126)][_0x3adfb9(0x11a)](),this[_0x3adfb9(0xfe)]=new _0x3b2d76(),this[_0x3adfb9(0xfe)][_0x3adfb9(0x11e)](..._0x5b1c76)['to'](this),this[_0x3adfb9(0xfe)][_0x3adfb9(0x11a)]();const _0x12739a=await this[_0x3adfb9(0xe6)][_0x3adfb9(0xe2)]();this[_0x3adfb9(0x12d)](_0x3adfb9(0xee),{'availableModels':_0x12739a});const _0x3c2897=await this[_0x3adfb9(0xe6)][_0x3adfb9(0x145)](this[_0x3adfb9(0x104)][_0x3adfb9(0x13b)]);_0x3c2897&&await this[_0x3adfb9(0xf6)](_0x3c2897);}catch(_0x4dc144){const _0x2bc933=new _0x21c9b8(_0x3adfb9(0x109),null,{'message':_0x4dc144[_0x3adfb9(0xe1)]||_0x4dc144});_0x2bc933[_0x3adfb9(0x112)]=_0x4dc144[_0x3adfb9(0x112)],this[_0x3adfb9(0x12d)](_0x3adfb9(0xef),{'error':_0x2bc933});}}async[_0xa4e42(0x111)](){const _0x590975=_0xa4e42;if(this[_0x590975(0x127)])throw new _0x21c9b8(_0x590975(0x12f),null,{'conversation':this});if(!this[_0x590975(0x121)])throw new _0x21c9b8(_0x590975(0x10a),null,{'conversation':this});try{const {id:_0x330671}=await this[_0x590975(0xfa)][_0x590975(0xdf)](this['id'],this[_0x590975(0x104)][_0x590975(0x12c)])[_0x590975(0x13f)]();this['id']=_0x330671,this[_0x590975(0x127)]=!0x0,this[_0x590975(0x12d)](_0x590975(0xf3),{'conversationId':this['id'],'selectedModel':this[_0x590975(0x121)]});}catch(_0x2ff0f3){const _0x426efb=new _0x21c9b8(_0x590975(0x13a),null,{'message':_0x2ff0f3[_0x590975(0xe1)],'conversationId':this['id']});throw _0x426efb[_0x590975(0x112)]=_0x2ff0f3[_0x590975(0x112)],this[_0x590975(0x12d)](_0x590975(0xef),{'error':_0x426efb}),_0x426efb;}}async[_0xa4e42(0x128)](_0x18729b,_0x570148){const _0x2fc34d=_0xa4e42;try{const _0x6e1580=await this[_0x2fc34d(0xfa)][_0x2fc34d(0xf9)](_0x18729b)[_0x2fc34d(0x13f)](),_0x38ccc4=await this[_0x2fc34d(0xfa)][_0x2fc34d(0xfc)](_0x18729b)[_0x2fc34d(0x129)](),_0x6364b2=_0x38ccc4[0x0][_0x2fc34d(0x118)];this[_0x2fc34d(0x127)]=!0x0,this['id']=_0x6e1580['id'],_0x2fc34d(0xdd)in _0x6e1580?this[_0x2fc34d(0x12d)](_0x2fc34d(0xe8),_0x6e1580[_0x2fc34d(0xdd)],!0x0):this[_0x2fc34d(0x12d)](_0x2fc34d(0xe8),'',!0x0);const _0x3317c4=(await this[_0x2fc34d(0xe6)][_0x2fc34d(0x135)]())[_0x2fc34d(0x142)](_0x7132db=>_0x7132db['id'][_0x2fc34d(0x14e)]()===_0x6364b2[_0x2fc34d(0x14e)]());return this[_0x2fc34d(0x121)]=_0x3317c4,this[_0x2fc34d(0x12d)](_0x2fc34d(0xfb),{'selectedModel':_0x3317c4,'isDisabled':!0x0}),await this[_0x2fc34d(0xdc)](_0x38ccc4,_0x570148,_0x6364b2),this[_0x2fc34d(0x138)]=void 0x0,this;}catch(_0x20cd49){const _0x5813b5=new _0x21c9b8(_0x2fc34d(0x14f),null,{'message':_0x20cd49[_0x2fc34d(0xe1)],'conversationId':_0x18729b});throw _0x5813b5[_0x2fc34d(0x112)]=_0x20cd49[_0x2fc34d(0x112)],this[_0x2fc34d(0x12d)](_0x2fc34d(0xef),{'error':_0x5813b5}),_0x5813b5;}}async[_0xa4e42(0xdc)](_0x3c1f38,_0x4c1a9c,_0x426bea){const _0x2baf7c=_0xa4e42;let _0x38dab7;for(const _0x27a10f of _0x3c1f38)if(_0x2baf7c(0xf4)===_0x27a10f[_0x2baf7c(0x143)]){const _0x25d68c=await this[_0x2baf7c(0xf2)](_0x27a10f),_0x4f36b6={'isReasoningEnabled':Object[_0x2baf7c(0x13c)](_0x27a10f[_0x2baf7c(0xe3)],_0x2baf7c(0xf8)),'isWebSearchEnabled':Object[_0x2baf7c(0x13c)](_0x27a10f[_0x2baf7c(0xe3)],_0x2baf7c(0x11b))};_0x38dab7=this[_0x2baf7c(0x102)]({'userMessage':_0x27a10f[_0x2baf7c(0x100)],'contextItems':_0x25d68c,'capabilities':_0x4f36b6,'modelId':_0x426bea,'quickActionData':_0x27a10f[_0x2baf7c(0x120)]?.[_0x2baf7c(0x140)]}),this[_0x2baf7c(0x138)]=_0x38dab7,this[_0x2baf7c(0x126)][_0x2baf7c(0x133)](this[_0x2baf7c(0x138)][_0x2baf7c(0x10e)]);}else{if(_0x2baf7c(0xec)===_0x27a10f[_0x2baf7c(0x143)]&&_0x38dab7)for(const _0x50e057 of _0x27a10f[_0x2baf7c(0x101)]){const _0x1fccb8=_0x2baf7c(0x147)===_0x50e057[_0x2baf7c(0xe4)]?_0x2baf7c(0x10d):_0x2baf7c(0x14b),_0x2f0730=_0x38dab7[_0x2baf7c(0x11c)]()?.[_0x2baf7c(0xfd)]!==_0x4c1a9c;_0x38dab7[_0x2baf7c(0x146)]=_0x38dab7[_0x2baf7c(0x11d)]({'type':_0x1fccb8,'isDone':!0x0,'interactionId':_0x38dab7['id'],'areActionsDisabled':_0x2f0730}),_0x38dab7[_0x2baf7c(0x146)][_0x2baf7c(0x10b)](_0x50e057[_0x2baf7c(0x101)]);}}}async[_0xa4e42(0xf2)](_0x1aab04){const _0x6ef330=_0xa4e42,_0x140fc0=new Map();if(!_0x1aab04[_0x6ef330(0x101)])return _0x140fc0;for(const _0x3d973a of _0x1aab04[_0x6ef330(0x101)]){const _0x56b808=await this[_0x6ef330(0x126)][_0x6ef330(0x137)](_0x3d973a);_0x56b808&&_0x140fc0[_0x6ef330(0x144)](_0x56b808['id'],_0x56b808);}return _0x140fc0;}async[_0xa4e42(0x10c)]({userMessage:_0xd32564,quickActionData:_0x4d36ec}){const _0x12bb99=_0xa4e42;if(!this[_0x12bb99(0x127)])throw new _0x21c9b8(_0x12bb99(0xeb),null,{'conversation':this});if(this[_0x12bb99(0x138)])throw new _0x21c9b8(_0x12bb99(0x150),null,{'conversation':this});try{const _0x332658=this[_0x12bb99(0x126)][_0x12bb99(0x123)](),_0x24c50f=this[_0x12bb99(0xfe)][_0x12bb99(0x117)](),_0x3171f9=this[_0x12bb99(0x121)]['id'];this[_0x12bb99(0x138)]=this[_0x12bb99(0x102)]({'userMessage':_0xd32564,'contextItems':_0x332658,'capabilities':_0x24c50f,'modelId':_0x3171f9,'quickActionData':_0x4d36ec}),await this[_0x12bb99(0x138)][_0x12bb99(0x111)](),this[_0x12bb99(0x126)][_0x12bb99(0x133)](this[_0x12bb99(0x138)][_0x12bb99(0x10e)]);}catch(_0x5ac8fa){if(_0x5ac8fa instanceof _0x21c9b8)this[_0x12bb99(0x12d)](_0x12bb99(0xef),{'interactionId':this[_0x12bb99(0x138)]?this[_0x12bb99(0x138)]['id']:void 0x0,'error':_0x5ac8fa});else{const _0x5d5cf3=_0x5226d4[_0x12bb99(0x113)](_0x5ac8fa[_0x12bb99(0x130)])||_0x12bb99(0xe0);this[_0x12bb99(0x12d)](_0x12bb99(0xef),{'interactionId':this[_0x12bb99(0x138)]?this[_0x12bb99(0x138)]['id']:void 0x0,'error':new _0x21c9b8(_0x5d5cf3,null,{'error':_0x5ac8fa})});}}finally{this[_0x12bb99(0x138)]?.[_0x12bb99(0x14c)](),this[_0x12bb99(0x138)]=void 0x0;}}[_0xa4e42(0x102)]({userMessage:_0x330cf9,contextItems:_0x54b7a7,capabilities:_0x3f2452,modelId:_0x368850,quickActionData:_0x26e091}){const _0x3ec4de=_0xa4e42,_0x5035bd=new _0x3914d9({'userMessage':_0x330cf9,'contextItems':_0x54b7a7,'capabilities':_0x3f2452,'conversationId':this['id'],'connector':this[_0x3ec4de(0xfa)],'editor':this[_0x3ec4de(0x104)][_0x3ec4de(0xf0)]&&this[_0x3ec4de(0x104)][_0x3ec4de(0xf0)](),'model':_0x368850,'quickActionData':_0x26e091});return _0x5035bd[_0x3ec4de(0x11e)](..._0x1240ce)['to'](this),this[_0x3ec4de(0x13e)][_0x3ec4de(0x122)](_0x5035bd),this[_0x3ec4de(0x12d)](_0x3ec4de(0x106),_0x5035bd),_0x5035bd;}[_0xa4e42(0x148)](_0x1de15a){const _0x1dcd9a=_0xa4e42;return this[_0x1dcd9a(0x13e)][_0x1dcd9a(0x142)](_0x41ee19=>_0x41ee19['id']===_0x1de15a);}[_0xa4e42(0xed)](_0x3d25b8){const _0x1ece33=_0xa4e42,_0x51d1c3=this[_0x1ece33(0x148)](_0x3d25b8);_0x51d1c3&&(_0x51d1c3[_0x1ece33(0x103)](),this[_0x1ece33(0x13e)][_0x1ece33(0xe7)](this[_0x1ece33(0x13e)][_0x1ece33(0x12b)](_0x51d1c3),0x1));}get[_0xa4e42(0x14a)](){const _0x179428=_0xa4e42;return this[_0x179428(0x13e)][this[_0x179428(0x13e)][_0x179428(0x12e)]-0x1];}[_0xa4e42(0xe5)](_0x55bda9){const _0x3972b8=_0xa4e42;this[_0x3972b8(0x126)][_0x3972b8(0xe5)](_0x55bda9);}async[_0xa4e42(0x151)]({content:_0x51fc84,version:_0x1fdb91,sessionId:_0x3b20ff,selections:_0x539e3c}){const _0x2db046=_0xa4e42;await this[_0x2db046(0x126)][_0x2db046(0x124)](_0x51fc84,_0x1fdb91,_0x3b20ff,_0x539e3c);}[_0xa4e42(0x116)](){const _0x3c724c=_0xa4e42;return this[_0x3c724c(0x138)]?.[_0x3c724c(0x11c)]()?.[_0x3c724c(0x101)]||'';}[_0xa4e42(0xf1)](_0x3423aa){const _0x359abd=_0xa4e42;this[_0x359abd(0x126)][_0x359abd(0xf1)](_0x3423aa);}[_0xa4e42(0x13d)](){const _0x5ae355=_0xa4e42;this[_0x5ae355(0x126)][_0x5ae355(0x13d)]();}[_0xa4e42(0x132)](_0xccd401){const _0xde6eb2=_0xa4e42;this[_0xde6eb2(0x126)][_0xde6eb2(0x132)](_0xccd401);}[_0xa4e42(0x110)](_0x2c1bbd){const _0x483809=_0xa4e42;this[_0x483809(0x126)][_0x483809(0x110)](_0x2c1bbd);}[_0xa4e42(0x134)](_0x309202,_0x584b9f){const _0x327444=_0xa4e42;this[_0x327444(0x126)][_0x327444(0x134)](_0x309202,_0x584b9f);}[_0xa4e42(0x10f)](_0x3f9453,_0x473127,_0x2bf3e6){const _0x81b5ea=_0xa4e42;return this[_0x81b5ea(0x126)][_0x81b5ea(0x10f)](_0x3f9453,_0x473127,_0x2bf3e6);}[_0xa4e42(0xe9)](_0x6c1c64){const _0x7af457=_0xa4e42;this[_0x7af457(0x126)][_0x7af457(0xe9)](_0x6c1c64);}[_0xa4e42(0x107)](){const _0x797e53=_0xa4e42;this[_0x797e53(0xfe)][_0x797e53(0x107)]();}[_0xa4e42(0x105)](){const _0x5a3b55=_0xa4e42;this[_0x5a3b55(0xfe)][_0x5a3b55(0x105)]();}[_0xa4e42(0x125)](){const _0x31302e=_0xa4e42;return this[_0x31302e(0x126)][_0x31302e(0x125)]();}[_0xa4e42(0x141)](){const _0x2a7b78=_0xa4e42;return this[_0x2a7b78(0x126)][_0x2a7b78(0x141)]();}[_0xa4e42(0x149)](){const _0x5a9520=_0xa4e42;return this[_0x5a9520(0x126)][_0x5a9520(0x149)]();}async[_0xa4e42(0xf6)](_0x35c38a){const _0x20a1f2=_0xa4e42;_0x35c38a?!0x1===await this[_0x20a1f2(0xe6)][_0x20a1f2(0xea)](_0x35c38a)&&(_0x5bed54(_0x20a1f2(0x119),{'conversation':this,'model':_0x35c38a}),_0x35c38a=(await this[_0x20a1f2(0xe6)][_0x20a1f2(0xe2)]())[0x0]):(_0x5bed54(_0x20a1f2(0xff),{'conversation':this}),_0x35c38a=(await this[_0x20a1f2(0xe6)][_0x20a1f2(0xe2)]())[0x0]),_0x35c38a['id']!==this[_0x20a1f2(0x121)]?.['id']&&(this[_0x20a1f2(0x121)]=_0x35c38a,this[_0x20a1f2(0xfe)][_0x20a1f2(0x108)](),this[_0x20a1f2(0x12d)](_0x20a1f2(0xfb),{'selectedModel':_0x35c38a}));}}
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- var _0x824010=_0x36bb;(function(_0x478594,_0x198b39){var _0x59d3d1=_0x36bb,_0x185e93=_0x478594();while(!![]){try{var _0x4503a2=parseInt(_0x59d3d1(0x102))/0x1+parseInt(_0x59d3d1(0xf2))/0x2+parseInt(_0x59d3d1(0xfe))/0x3+-parseInt(_0x59d3d1(0xf3))/0x4+parseInt(_0x59d3d1(0xef))/0x5+parseInt(_0x59d3d1(0xf7))/0x6+-parseInt(_0x59d3d1(0xfa))/0x7*(parseInt(_0x59d3d1(0xf5))/0x8);if(_0x4503a2===_0x198b39)break;else _0x185e93['push'](_0x185e93['shift']());}catch(_0x361fc0){_0x185e93['push'](_0x185e93['shift']());}}}(_0x19c6,0xa65e6));import{AICapabilities as _0x3300e1}from'../../aicore/model/aicapabilities.js';import{AIInteraction as _0x333341}from'../../aicore/model/aiinteraction.js';import{AIChatContext as _0x2769d4}from'./aichatcontext.js';export class AIChatInteraction extends _0x333341{[_0x824010(0x104)];[_0x824010(0xf4)];[_0x824010(0xfd)]=new Map();[_0x824010(0xfc)];[_0x824010(0xf0)];constructor(_0x1364c4){var _0xfffb3a=_0x824010;super(_0x1364c4),this[_0xfffb3a(0xf4)]=_0x1364c4[_0xfffb3a(0xf4)],this[_0xfffb3a(0xfd)]=_0x1364c4[_0xfffb3a(0xfd)],this[_0xfffb3a(0x101)]=_0x1364c4[_0xfffb3a(0x101)],this[_0xfffb3a(0x104)]=_0x1364c4[_0xfffb3a(0x104)],this[_0xfffb3a(0xfc)]=_0x1364c4[_0xfffb3a(0xfc)],this[_0xfffb3a(0xf0)]=_0x1364c4[_0xfffb3a(0xf0)];}async[_0x824010(0x100)](){var _0x3824da=_0x824010;return this[_0x3824da(0xf9)][_0x3824da(0xf6)]({'message':this[_0x3824da(0x104)],'conversationId':this[_0x3824da(0xf4)],'parts':_0x2769d4[_0x3824da(0xfb)](this[_0x3824da(0xfd)]),'capabilities':_0x3300e1[_0x3824da(0xff)](this[_0x3824da(0x101)]),'model':this[_0x3824da(0xfc)],'quickActionData':this[_0x3824da(0xf0)]});}[_0x824010(0xf8)](){var _0x11f073=_0x824010;return this[_0x11f073(0xfd)][_0x11f073(0xf1)](_0x11f073(0x103));}}function _0x36bb(_0x9d0390,_0x5db649){var _0x19c631=_0x19c6();return _0x36bb=function(_0x36bb00,_0x5b4f80){_0x36bb00=_0x36bb00-0xef;var _0x4c4e0e=_0x19c631[_0x36bb00];return _0x4c4e0e;},_0x36bb(_0x9d0390,_0x5db649);}function _0x19c6(){var _0xf3d3fb=['current-document','userMessage','2001940ZdaJMC','quickActionData','get','1486646WVIRFO','5377400OjjSXg','conversationId','6224WkQrkV','queryAssistant','4630842TpvIZU','getDocumentContext','connector','7987SkUBiM','mapContextItemsToRequestData','model','contextItems','981186gOnQsv','getCapabilitiesRequestData','sendRequest','capabilities','670914dyMctJ'];_0x19c6=function(){return _0xf3d3fb;};return _0x19c6();}
23
+ var _0x599604=_0x5448;(function(_0x59691a,_0x18b1f0){var _0x15b2d2=_0x5448,_0x336708=_0x59691a();while(!![]){try{var _0x592a23=parseInt(_0x15b2d2(0xcb))/0x1*(-parseInt(_0x15b2d2(0xe0))/0x2)+-parseInt(_0x15b2d2(0xda))/0x3*(parseInt(_0x15b2d2(0xd6))/0x4)+parseInt(_0x15b2d2(0xcd))/0x5*(parseInt(_0x15b2d2(0xdd))/0x6)+-parseInt(_0x15b2d2(0xd1))/0x7+-parseInt(_0x15b2d2(0xe1))/0x8+-parseInt(_0x15b2d2(0xd7))/0x9+-parseInt(_0x15b2d2(0xde))/0xa*(-parseInt(_0x15b2d2(0xd0))/0xb);if(_0x592a23===_0x18b1f0)break;else _0x336708['push'](_0x336708['shift']());}catch(_0x3ba482){_0x336708['push'](_0x336708['shift']());}}}(_0x4c6c,0xa5622));import{AICapabilities as _0x4a9f99}from'../../aicore/model/aicapabilities.js';function _0x4c6c(){var _0x592c2b=['getCapabilitiesRequestData','363nddrfB','1307712KvFifx','getDocumentContext','contextItems','get','mapContextItemsToRequestData','4RzQBGy','2848185XNmupK','queryAssistant','quickActionData','3137955jBanTH','capabilities','model','6AeBQwz','856880GJryFV','sendRequest','6TPybyn','2089904mqDcQa','conversationId','current-document','153446ZKxUxF','connector','602740tVGubg','userMessage'];_0x4c6c=function(){return _0x592c2b;};return _0x4c6c();}import{AIInteraction as _0x116ca4}from'../../aicore/model/aiinteraction.js';function _0x5448(_0x5c8e60,_0x1301d5){var _0x4c6cbd=_0x4c6c();return _0x5448=function(_0x544863,_0x2e5822){_0x544863=_0x544863-0xc9;var _0x2e7e21=_0x4c6cbd[_0x544863];return _0x2e7e21;},_0x5448(_0x5c8e60,_0x1301d5);}import{AIChatContext as _0x51bf32}from'./aichatcontext.js';export class AIChatInteraction extends _0x116ca4{[_0x599604(0xce)];[_0x599604(0xc9)];[_0x599604(0xd3)]=new Map();[_0x599604(0xdc)];[_0x599604(0xd9)];constructor(_0xba6c01){var _0x20c524=_0x599604;super(_0xba6c01),this[_0x20c524(0xc9)]=_0xba6c01[_0x20c524(0xc9)],this[_0x20c524(0xd3)]=_0xba6c01[_0x20c524(0xd3)],this[_0x20c524(0xdb)]=_0xba6c01[_0x20c524(0xdb)],this[_0x20c524(0xce)]=_0xba6c01[_0x20c524(0xce)],this[_0x20c524(0xdc)]=_0xba6c01[_0x20c524(0xdc)],this[_0x20c524(0xd9)]=_0xba6c01[_0x20c524(0xd9)];}async[_0x599604(0xdf)](){var _0x2be555=_0x599604;return this[_0x2be555(0xcc)][_0x2be555(0xd8)]({'message':this[_0x2be555(0xce)],'conversationId':this[_0x2be555(0xc9)],'parts':_0x51bf32[_0x2be555(0xd5)](this[_0x2be555(0xd3)]),'capabilities':_0x4a9f99[_0x2be555(0xcf)](this[_0x2be555(0xdb)]),'model':this[_0x2be555(0xdc)],'quickActionData':this[_0x2be555(0xd9)]});}[_0x599604(0xd2)](){var _0x185966=_0x599604;return this[_0x185966(0xd3)][_0x185966(0xd4)](_0x185966(0xca));}}