@univerjs-pro/mcp 0.14.0 → 0.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/umd/facade.js CHANGED
@@ -1 +1 @@
1
- (function(_0x11a935,_0x4898f4){const _0xb2e45b=_0x2940,_0x5cf14a=_0x11a935();while(!![]){try{const _0x4def3c=-parseInt(_0xb2e45b(0x1aa))/0x1+parseInt(_0xb2e45b(0x1b2))/0x2+parseInt(_0xb2e45b(0x1a3))/0x3*(parseInt(_0xb2e45b(0x1b1))/0x4)+-parseInt(_0xb2e45b(0x1b7))/0x5*(-parseInt(_0xb2e45b(0x1d6))/0x6)+-parseInt(_0xb2e45b(0x1d3))/0x7*(-parseInt(_0xb2e45b(0x1ae))/0x8)+parseInt(_0xb2e45b(0x1ab))/0x9+-parseInt(_0xb2e45b(0x1a4))/0xa;if(_0x4def3c===_0x4898f4)break;else _0x5cf14a['push'](_0x5cf14a['shift']());}catch(_0x26b0c2){_0x5cf14a['push'](_0x5cf14a['shift']());}}}(_0x19ee,0xb208c),function(_0x3e5d6f,_0x417a14){const _0x4bfd95=_0x2940;typeof exports==_0x4bfd95(0x1d0)&&typeof module<'u'?_0x417a14(require('@univerjs-pro/mcp'),require('@univerjs/core/facade'),require('@univerjs/core')):typeof define==_0x4bfd95(0x1c8)&&define[_0x4bfd95(0x1c7)]?define([_0x4bfd95(0x1cd),_0x4bfd95(0x1bf),_0x4bfd95(0x1cc)],_0x417a14):(_0x3e5d6f=typeof globalThis<'u'?globalThis:_0x3e5d6f||self,_0x417a14(_0x3e5d6f[_0x4bfd95(0x1b3)],_0x3e5d6f[_0x4bfd95(0x1cb)],_0x3e5d6f[_0x4bfd95(0x1c1)]));}(this,function(_0x20215d,_0x1f2af2,_0x2895ed){'use strict';const _0x4c0204=_0x2940;class _0x2a2843{get[_0x4c0204(0x1a2)](){const _0x4b5345=_0x4c0204;return _0x20215d[_0x4b5345(0x1c3)][_0x4b5345(0x1a2)];}get[_0x4c0204(0x1b4)](){const _0x11277c=_0x4c0204;return _0x20215d[_0x11277c(0x1c3)][_0x11277c(0x1b4)];}get[_0x4c0204(0x1af)](){const _0x4b233b=_0x4c0204;return _0x20215d[_0x4b233b(0x1c3)][_0x4b233b(0x1af)];}get[_0x4c0204(0x1c4)](){const _0x50a597=_0x4c0204;return _0x20215d[_0x50a597(0x1c3)]['McpToolCallFailed'];}}_0x1f2af2[_0x4c0204(0x1b5)][_0x4c0204(0x1b0)](_0x2a2843);class _0x38261b extends _0x1f2af2[_0x4c0204(0x1a7)]{[_0x4c0204(0x1a6)](_0xd30f43){const _0x2895b2=_0x4c0204;this[_0x2895b2(0x1bb)](_0xd30f43);}['_registerMCPFacadeEvents'](_0x6e08bb){const _0x265425=_0x4c0204,_0x4e5314=_0x6e08bb[_0x265425(0x1be)](_0x20215d[_0x265425(0x1ba)]);this[_0x265425(0x1ad)](this[_0x265425(0x1c6)][_0x265425(0x1a2)],()=>_0x2895ed[_0x265425(0x1d4)](_0x4e5314[_0x265425(0x1ac)][_0x265425(0x1b9)](_0x2f02ea=>{const _0x1cd34c=_0x265425;_0x2f02ea['type']===_0x20215d[_0x1cd34c(0x1c3)][_0x1cd34c(0x1a2)]&&this[_0x1cd34c(0x1b6)](this['Event'][_0x1cd34c(0x1a2)],_0x2f02ea[_0x1cd34c(0x1c0)]);}))),this[_0x265425(0x1ad)](this[_0x265425(0x1c6)]['McpToolCallReceived'],()=>_0x2895ed[_0x265425(0x1d4)](_0x4e5314[_0x265425(0x1ac)]['subscribe'](_0x39f8d2=>{const _0x2c6e57=_0x265425;_0x39f8d2[_0x2c6e57(0x1ce)]===_0x20215d['MCPEventId'][_0x2c6e57(0x1b4)]&&this[_0x2c6e57(0x1b6)](this['Event'][_0x2c6e57(0x1b4)],_0x39f8d2[_0x2c6e57(0x1c0)]);}))),this[_0x265425(0x1ad)](this[_0x265425(0x1c6)][_0x265425(0x1af)],()=>_0x2895ed[_0x265425(0x1d4)](_0x4e5314[_0x265425(0x1ac)]['subscribe'](_0x1f6f90=>{const _0x55d9c9=_0x265425;_0x1f6f90[_0x55d9c9(0x1ce)]===_0x20215d[_0x55d9c9(0x1c3)][_0x55d9c9(0x1af)]&&this['fireEvent'](this[_0x55d9c9(0x1c6)][_0x55d9c9(0x1af)],_0x1f6f90[_0x55d9c9(0x1c0)]);}))),this[_0x265425(0x1ad)](this[_0x265425(0x1c6)]['McpToolCallFailed'],()=>_0x2895ed[_0x265425(0x1d4)](_0x4e5314[_0x265425(0x1ac)][_0x265425(0x1b9)](_0x1b1e36=>{const _0x2152d0=_0x265425;_0x1b1e36['type']===_0x20215d['MCPEventId'][_0x2152d0(0x1c4)]&&this[_0x2152d0(0x1b6)](this[_0x2152d0(0x1c6)][_0x2152d0(0x1c4)],_0x1b1e36[_0x2152d0(0x1c0)]);})));}[_0x4c0204(0x1c5)](_0x3ffc7d,_0x1420b7){const _0x5330e6=_0x4c0204;return this['_injector'][_0x5330e6(0x1be)](_0x20215d[_0x5330e6(0x1d2)])['validateToolCall'](_0x3ffc7d,_0x1420b7);}[_0x4c0204(0x1c9)](){const _0x34e6cf=_0x4c0204;return this[_0x34e6cf(0x1d1)]['get'](_0x20215d[_0x34e6cf(0x1d2)])[_0x34e6cf(0x1a5)]();}[_0x4c0204(0x1d5)](_0x3b4b97,_0x2f21e8){const _0x26b00c=_0x4c0204;return this[_0x26b00c(0x1d1)][_0x26b00c(0x1be)](_0x20215d[_0x26b00c(0x1d2)])[_0x26b00c(0x1a9)](_0x3b4b97,_0x2f21e8);}[_0x4c0204(0x1a8)](){const _0x555c72=_0x4c0204;return this['_injector'][_0x555c72(0x1be)](_0x20215d[_0x555c72(0x1cf)])[_0x555c72(0x1c2)]();}[_0x4c0204(0x1ca)](){const _0x5097b8=_0x4c0204;this[_0x5097b8(0x1d1)][_0x5097b8(0x1be)](_0x20215d[_0x5097b8(0x1cf)])[_0x5097b8(0x1bd)]();}[_0x4c0204(0x1b8)](){const _0x5132c2=_0x4c0204;this[_0x5132c2(0x1d1)][_0x5132c2(0x1be)](_0x20215d['MCPConnectionController'])[_0x5132c2(0x1bc)]();}}_0x1f2af2[_0x4c0204(0x1a7)][_0x4c0204(0x1b0)](_0x38261b);}));function _0x2940(_0x29a655,_0x40bf1b){_0x29a655=_0x29a655-0x1a2;const _0x19ee08=_0x19ee();let _0x29406c=_0x19ee08[_0x29a655];return _0x29406c;}function _0x19ee(){const _0x406cc4=['subscribe','MCPEventService','_registerMCPFacadeEvents','disconnect','connect','get','@univerjs/core/facade','data','UniverCore','getConnectionStatus','MCPEventId','McpToolCallFailed','validateMCPToolCall','Event','amd','function','getAllMCPTools','connectMCP','UniverCoreFacade','@univerjs/core','@univerjs-pro/mcp','type','MCPConnectionController','object','_injector','IMCPToolRegistry','1631VGwEFg','toDisposable','callMCPTool','12SKHCen','McpConnectionStatusChanged','5067FDYiMR','37584750IWsfKK','getAllTools','_initialize','FUniver','getMCPConnectionStatus','executeTool','22087pFoOIt','12262167OWkDPl','event$','registerEventHandler','31184rcZOPw','McpToolCallExecuted','extend','2756WLzvrE','739808KvrrlO','UniverProMcp','McpToolCallReceived','FEventName','fireEvent','1763670vMcXPz','disconnectMCP'];_0x19ee=function(){return _0x406cc4;};return _0x19ee();}
1
+ function _0x925e(_0x8139d1,_0x5cf76d){_0x8139d1=_0x8139d1-0xff;const _0x31e81e=_0x31e8();let _0x925e03=_0x31e81e[_0x8139d1];return _0x925e03;}function _0x31e8(){const _0x37b737=['MCPEventService','509RSNNXt','_injector','object','4923630CybKSQ','McpToolCallReceived','IMCPToolRegistry','connect','UniverProMcp','connectMCP','getAllTools','get','McpConnectionStatusChanged','McpToolCallFailed','FEventName','event$','extend','208313foaIgJ','@univerjs/core/facade','396aPhQHb','MCPConnectionController','callMCPTool','_registerMCPFacadeEvents','4384280llGYCE','data','FUniver','amd','@univerjs/core','MCPEventId','Event','validateMCPToolCall','disconnect','16gyPtpp','UniverCore','registerEventHandler','getMCPConnectionStatus','getAllMCPTools','3755SlvcLd','toDisposable','executeTool','337300awRmIw','type','function','899481LvmgCt','_initialize','794FPnUjm','fireEvent','disconnectMCP','McpToolCallExecuted','subscribe'];_0x31e8=function(){return _0x37b737;};return _0x31e8();}(function(_0x3b04a4,_0x5661c8){const _0x53f88c=_0x925e,_0x3a742b=_0x3b04a4();while(!![]){try{const _0x31b8bc=parseInt(_0x53f88c(0x122))/0x1*(-parseInt(_0x53f88c(0x11c))/0x2)+-parseInt(_0x53f88c(0x11a))/0x3+-parseInt(_0x53f88c(0x117))/0x4+parseInt(_0x53f88c(0x114))/0x5*(-parseInt(_0x53f88c(0x102))/0x6)+-parseInt(_0x53f88c(0x100))/0x7*(parseInt(_0x53f88c(0x10f))/0x8)+parseInt(_0x53f88c(0x125))/0x9+parseInt(_0x53f88c(0x106))/0xa;if(_0x31b8bc===_0x5661c8)break;else _0x3a742b['push'](_0x3a742b['shift']());}catch(_0x383f60){_0x3a742b['push'](_0x3a742b['shift']());}}}(_0x31e8,0x46d8d),function(_0x11a6b4,_0x4e0861){const _0x1ded4a=_0x925e;typeof exports==_0x1ded4a(0x124)&&typeof module<'u'?_0x4e0861(require('@univerjs-pro/mcp'),require('@univerjs/core/facade'),require('@univerjs/core')):typeof define==_0x1ded4a(0x119)&&define[_0x1ded4a(0x109)]?define(['@univerjs-pro/mcp',_0x1ded4a(0x101),_0x1ded4a(0x10a)],_0x4e0861):(_0x11a6b4=typeof globalThis<'u'?globalThis:_0x11a6b4||self,_0x4e0861(_0x11a6b4[_0x1ded4a(0x129)],_0x11a6b4['UniverCoreFacade'],_0x11a6b4[_0x1ded4a(0x110)]));}(this,function(_0x597554,_0x4d2e59,_0x6c2663){'use strict';const _0x2770f3=_0x925e;class _0x27ef41{get[_0x2770f3(0x12d)](){return _0x597554['MCPEventId']['McpConnectionStatusChanged'];}get[_0x2770f3(0x126)](){const _0x335c15=_0x2770f3;return _0x597554[_0x335c15(0x10b)][_0x335c15(0x126)];}get[_0x2770f3(0x11f)](){const _0x200b52=_0x2770f3;return _0x597554[_0x200b52(0x10b)]['McpToolCallExecuted'];}get[_0x2770f3(0x12e)](){const _0x65b601=_0x2770f3;return _0x597554[_0x65b601(0x10b)][_0x65b601(0x12e)];}}_0x4d2e59[_0x2770f3(0x12f)][_0x2770f3(0xff)](_0x27ef41);class _0x3c6c12 extends _0x4d2e59[_0x2770f3(0x108)]{[_0x2770f3(0x11b)](_0x1fa7f6){const _0x4f7b01=_0x2770f3;this[_0x4f7b01(0x105)](_0x1fa7f6);}[_0x2770f3(0x105)](_0x4cd919){const _0x2f0a10=_0x2770f3,_0x379da9=_0x4cd919[_0x2f0a10(0x12c)](_0x597554[_0x2f0a10(0x121)]);this['registerEventHandler'](this[_0x2f0a10(0x10c)][_0x2f0a10(0x12d)],()=>_0x6c2663[_0x2f0a10(0x115)](_0x379da9['event$'][_0x2f0a10(0x120)](_0xc69235=>{const _0x3910c4=_0x2f0a10;_0xc69235[_0x3910c4(0x118)]===_0x597554[_0x3910c4(0x10b)][_0x3910c4(0x12d)]&&this[_0x3910c4(0x11d)](this[_0x3910c4(0x10c)][_0x3910c4(0x12d)],_0xc69235[_0x3910c4(0x107)]);}))),this[_0x2f0a10(0x111)](this[_0x2f0a10(0x10c)][_0x2f0a10(0x126)],()=>_0x6c2663[_0x2f0a10(0x115)](_0x379da9[_0x2f0a10(0x130)][_0x2f0a10(0x120)](_0x25d909=>{const _0x411463=_0x2f0a10;_0x25d909[_0x411463(0x118)]===_0x597554[_0x411463(0x10b)][_0x411463(0x126)]&&this[_0x411463(0x11d)](this[_0x411463(0x10c)][_0x411463(0x126)],_0x25d909['data']);}))),this[_0x2f0a10(0x111)](this[_0x2f0a10(0x10c)][_0x2f0a10(0x11f)],()=>_0x6c2663[_0x2f0a10(0x115)](_0x379da9[_0x2f0a10(0x130)][_0x2f0a10(0x120)](_0xc0f32d=>{const _0x231b8f=_0x2f0a10;_0xc0f32d['type']===_0x597554[_0x231b8f(0x10b)][_0x231b8f(0x11f)]&&this[_0x231b8f(0x11d)](this[_0x231b8f(0x10c)]['McpToolCallExecuted'],_0xc0f32d[_0x231b8f(0x107)]);}))),this['registerEventHandler'](this[_0x2f0a10(0x10c)]['McpToolCallFailed'],()=>_0x6c2663[_0x2f0a10(0x115)](_0x379da9[_0x2f0a10(0x130)][_0x2f0a10(0x120)](_0x3736f7=>{const _0x30ad05=_0x2f0a10;_0x3736f7[_0x30ad05(0x118)]===_0x597554[_0x30ad05(0x10b)][_0x30ad05(0x12e)]&&this['fireEvent'](this['Event'][_0x30ad05(0x12e)],_0x3736f7[_0x30ad05(0x107)]);})));}[_0x2770f3(0x10d)](_0x215b48,_0x23c408){const _0x5ab423=_0x2770f3;return this[_0x5ab423(0x123)][_0x5ab423(0x12c)](_0x597554[_0x5ab423(0x127)])['validateToolCall'](_0x215b48,_0x23c408);}[_0x2770f3(0x113)](){const _0x4fc381=_0x2770f3;return this[_0x4fc381(0x123)]['get'](_0x597554[_0x4fc381(0x127)])[_0x4fc381(0x12b)]();}[_0x2770f3(0x104)](_0x1a40eb,_0x54e21b){const _0x25041d=_0x2770f3;return this[_0x25041d(0x123)][_0x25041d(0x12c)](_0x597554[_0x25041d(0x127)])[_0x25041d(0x116)](_0x1a40eb,_0x54e21b);}[_0x2770f3(0x112)](){const _0x38c45d=_0x2770f3;return this['_injector']['get'](_0x597554[_0x38c45d(0x103)])['getConnectionStatus']();}[_0x2770f3(0x12a)](){const _0x98c65f=_0x2770f3;this[_0x98c65f(0x123)]['get'](_0x597554[_0x98c65f(0x103)])[_0x98c65f(0x128)]();}[_0x2770f3(0x11e)](){const _0x2a7546=_0x2770f3;this[_0x2a7546(0x123)]['get'](_0x597554[_0x2a7546(0x103)])[_0x2a7546(0x10e)]();}}_0x4d2e59[_0x2770f3(0x108)][_0x2770f3(0xff)](_0x3c6c12);}));