@univerjs-pro/mcp 0.15.1-insiders.20260117-8ce4a01 → 0.15.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/facade.js CHANGED
@@ -1 +1 @@
1
- const _0x561c1a=_0x36bb;(function(_0x223892,_0x124b43){const _0x573566=_0x36bb,_0x185add=_0x223892();while(!![]){try{const _0x2cc72a=parseInt(_0x573566(0x148))/0x1*(parseInt(_0x573566(0x15e))/0x2)+-parseInt(_0x573566(0x159))/0x3*(parseInt(_0x573566(0x144))/0x4)+parseInt(_0x573566(0x145))/0x5+parseInt(_0x573566(0x14f))/0x6+-parseInt(_0x573566(0x15b))/0x7+parseInt(_0x573566(0x149))/0x8*(parseInt(_0x573566(0x14e))/0x9)+-parseInt(_0x573566(0x146))/0xa;if(_0x2cc72a===_0x124b43)break;else _0x185add['push'](_0x185add['shift']());}catch(_0x31bef0){_0x185add['push'](_0x185add['shift']());}}}(_0x540e,0x44213));import{MCPEventId as _0x1f58fc,MCPEventService as _0x4bfdd9,IMCPToolRegistry as _0x2c086c,MCPConnectionController as _0x4b9d5e}from'@univerjs-pro/mcp';function _0x540e(){const _0x30e03d=['event$','fireEvent','McpToolCallExecuted','extend','disconnectMCP','288654JkrWSQ','data','3583734zmxOgL','validateMCPToolCall','_injector','2fomdRj','subscribe','McpConnectionStatusChanged','McpToolCallFailed','Event','connect','executeTool','_registerMCPFacadeEvents','20kxXoiv','2636820yBBkPt','3352920VTmknG','registerEventHandler','371251PbeDLy','2462864YbkYvt','McpToolCallReceived','getConnectionStatus','getAllMCPTools','type','9oaUXEW','2405580xBFWIT','validateToolCall','callMCPTool','getAllTools','get'];_0x540e=function(){return _0x30e03d;};return _0x540e();}import{FEventName as _0x588d45,FUniver as _0x28df5f}from'@univerjs/core/facade';import{toDisposable as _0x2001cf}from'@univerjs/core';function _0x36bb(_0x2a8465,_0xef5dc4){_0x2a8465=_0x2a8465-0x13f;const _0x540e6e=_0x540e();let _0x36bb1a=_0x540e6e[_0x2a8465];return _0x36bb1a;}class d{get[_0x561c1a(0x160)](){const _0x4833dd=_0x561c1a;return _0x1f58fc[_0x4833dd(0x160)];}get[_0x561c1a(0x14a)](){const _0x3e7a4d=_0x561c1a;return _0x1f58fc[_0x3e7a4d(0x14a)];}get[_0x561c1a(0x156)](){return _0x1f58fc['McpToolCallExecuted'];}get['McpToolCallFailed'](){return _0x1f58fc['McpToolCallFailed'];}}_0x588d45[_0x561c1a(0x157)](d);class M extends _0x28df5f{['_initialize'](_0x395c47){const _0xaaf02b=_0x561c1a;this[_0xaaf02b(0x143)](_0x395c47);}[_0x561c1a(0x143)](_0x443255){const _0x598910=_0x561c1a,_0x286ebd=_0x443255[_0x598910(0x153)](_0x4bfdd9);this[_0x598910(0x147)](this[_0x598910(0x140)]['McpConnectionStatusChanged'],()=>_0x2001cf(_0x286ebd[_0x598910(0x154)]['subscribe'](_0x5487cf=>{const _0x1e8bf0=_0x598910;_0x5487cf[_0x1e8bf0(0x14d)]===_0x1f58fc[_0x1e8bf0(0x160)]&&this[_0x1e8bf0(0x155)](this['Event'][_0x1e8bf0(0x160)],_0x5487cf[_0x1e8bf0(0x15a)]);}))),this['registerEventHandler'](this[_0x598910(0x140)][_0x598910(0x14a)],()=>_0x2001cf(_0x286ebd['event$'][_0x598910(0x15f)](_0x4dc21d=>{const _0xd55937=_0x598910;_0x4dc21d['type']===_0x1f58fc[_0xd55937(0x14a)]&&this['fireEvent'](this[_0xd55937(0x140)][_0xd55937(0x14a)],_0x4dc21d[_0xd55937(0x15a)]);}))),this[_0x598910(0x147)](this[_0x598910(0x140)][_0x598910(0x156)],()=>_0x2001cf(_0x286ebd[_0x598910(0x154)][_0x598910(0x15f)](_0x1fab3d=>{const _0x1e768f=_0x598910;_0x1fab3d[_0x1e768f(0x14d)]===_0x1f58fc['McpToolCallExecuted']&&this['fireEvent'](this['Event'][_0x1e768f(0x156)],_0x1fab3d[_0x1e768f(0x15a)]);}))),this['registerEventHandler'](this[_0x598910(0x140)][_0x598910(0x13f)],()=>_0x2001cf(_0x286ebd[_0x598910(0x154)][_0x598910(0x15f)](_0x1a536d=>{const _0x3b2a89=_0x598910;_0x1a536d[_0x3b2a89(0x14d)]===_0x1f58fc[_0x3b2a89(0x13f)]&&this[_0x3b2a89(0x155)](this[_0x3b2a89(0x140)][_0x3b2a89(0x13f)],_0x1a536d['data']);})));}[_0x561c1a(0x15c)](_0x51852a,_0x38b08b){const _0xe94755=_0x561c1a;return this[_0xe94755(0x15d)][_0xe94755(0x153)](_0x2c086c)[_0xe94755(0x150)](_0x51852a,_0x38b08b);}[_0x561c1a(0x14c)](){const _0x4d444d=_0x561c1a;return this[_0x4d444d(0x15d)][_0x4d444d(0x153)](_0x2c086c)[_0x4d444d(0x152)]();}[_0x561c1a(0x151)](_0x1bea69,_0x428454){const _0x41e034=_0x561c1a;return this['_injector'][_0x41e034(0x153)](_0x2c086c)[_0x41e034(0x142)](_0x1bea69,_0x428454);}['getMCPConnectionStatus'](){const _0xc2d33d=_0x561c1a;return this[_0xc2d33d(0x15d)]['get'](_0x4b9d5e)[_0xc2d33d(0x14b)]();}['connectMCP'](){const _0x1c171e=_0x561c1a;this[_0x1c171e(0x15d)][_0x1c171e(0x153)](_0x4b9d5e)[_0x1c171e(0x141)]();}[_0x561c1a(0x158)](){this['_injector']['get'](_0x4b9d5e)['disconnect']();}}_0x28df5f[_0x561c1a(0x157)](M);
1
+ const _0x26d105=_0x3df6;(function(_0x23ca3e,_0x19bbe2){const _0x4a50a0=_0x3df6,_0x4c28f2=_0x23ca3e();while(!![]){try{const _0x2c84b6=-parseInt(_0x4a50a0(0x1eb))/0x1+parseInt(_0x4a50a0(0x1f9))/0x2+-parseInt(_0x4a50a0(0x1f3))/0x3+parseInt(_0x4a50a0(0x203))/0x4+-parseInt(_0x4a50a0(0x1f5))/0x5*(-parseInt(_0x4a50a0(0x200))/0x6)+-parseInt(_0x4a50a0(0x1e3))/0x7*(-parseInt(_0x4a50a0(0x1f2))/0x8)+-parseInt(_0x4a50a0(0x201))/0x9*(parseInt(_0x4a50a0(0x1f4))/0xa);if(_0x2c84b6===_0x19bbe2)break;else _0x4c28f2['push'](_0x4c28f2['shift']());}catch(_0x5dc2ab){_0x4c28f2['push'](_0x4c28f2['shift']());}}}(_0x5aae,0x353a6));import{MCPEventId as _0x220a1f,MCPEventService as _0x12b2f5,IMCPToolRegistry as _0x582e6d,MCPConnectionController as _0x7d7fc0}from'@univerjs-pro/mcp';import{FEventName as _0x26102b,FUniver as _0x312d24}from'@univerjs/core/facade';import{toDisposable as _0x1aaf28}from'@univerjs/core';class d{get[_0x26d105(0x1e6)](){return _0x220a1f['McpConnectionStatusChanged'];}get[_0x26d105(0x1ff)](){return _0x220a1f['McpToolCallReceived'];}get[_0x26d105(0x1e5)](){const _0x5c9df3=_0x26d105;return _0x220a1f[_0x5c9df3(0x1e5)];}get[_0x26d105(0x1f1)](){const _0x5b4f8c=_0x26d105;return _0x220a1f[_0x5b4f8c(0x1f1)];}}function _0x3df6(_0x1c638a,_0x21f219){_0x1c638a=_0x1c638a-0x1e3;const _0x5aaec4=_0x5aae();let _0x3df6b9=_0x5aaec4[_0x1c638a];return _0x3df6b9;}function _0x5aae(){const _0x31ba06=['279636gMyfJU','callMCPTool','event$','get','3787WQMMEt','data','McpToolCallExecuted','McpConnectionStatusChanged','connect','disconnectMCP','registerEventHandler','getMCPConnectionStatus','182572eMBMwf','Event','getConnectionStatus','getAllMCPTools','_registerMCPFacadeEvents','extend','McpToolCallFailed','5192ByzZVo','669033KQuGeQ','36710BltxFY','232855HxDRIq','disconnect','fireEvent','validateMCPToolCall','815896mVCtyX','subscribe','_initialize','_injector','type','executeTool','McpToolCallReceived','18QiVCeZ','846MAzgac','getAllTools'];_0x5aae=function(){return _0x31ba06;};return _0x5aae();}_0x26102b[_0x26d105(0x1f0)](d);class M extends _0x312d24{[_0x26d105(0x1fb)](_0x3fca7c){const _0x5b7b25=_0x26d105;this[_0x5b7b25(0x1ef)](_0x3fca7c);}[_0x26d105(0x1ef)](_0x14edfd){const _0x55b05d=_0x26d105,_0x343fd1=_0x14edfd[_0x55b05d(0x206)](_0x12b2f5);this[_0x55b05d(0x1e9)](this[_0x55b05d(0x1ec)][_0x55b05d(0x1e6)],()=>_0x1aaf28(_0x343fd1['event$'][_0x55b05d(0x1fa)](_0x14a000=>{const _0x1ffedd=_0x55b05d;_0x14a000['type']===_0x220a1f['McpConnectionStatusChanged']&&this[_0x1ffedd(0x1f7)](this[_0x1ffedd(0x1ec)]['McpConnectionStatusChanged'],_0x14a000[_0x1ffedd(0x1e4)]);}))),this[_0x55b05d(0x1e9)](this[_0x55b05d(0x1ec)][_0x55b05d(0x1ff)],()=>_0x1aaf28(_0x343fd1[_0x55b05d(0x205)][_0x55b05d(0x1fa)](_0x198a6d=>{const _0x3a9c30=_0x55b05d;_0x198a6d[_0x3a9c30(0x1fd)]===_0x220a1f[_0x3a9c30(0x1ff)]&&this[_0x3a9c30(0x1f7)](this[_0x3a9c30(0x1ec)][_0x3a9c30(0x1ff)],_0x198a6d[_0x3a9c30(0x1e4)]);}))),this[_0x55b05d(0x1e9)](this[_0x55b05d(0x1ec)][_0x55b05d(0x1e5)],()=>_0x1aaf28(_0x343fd1[_0x55b05d(0x205)][_0x55b05d(0x1fa)](_0x5e92cc=>{const _0x286eac=_0x55b05d;_0x5e92cc[_0x286eac(0x1fd)]===_0x220a1f[_0x286eac(0x1e5)]&&this[_0x286eac(0x1f7)](this[_0x286eac(0x1ec)]['McpToolCallExecuted'],_0x5e92cc['data']);}))),this[_0x55b05d(0x1e9)](this[_0x55b05d(0x1ec)]['McpToolCallFailed'],()=>_0x1aaf28(_0x343fd1['event$'][_0x55b05d(0x1fa)](_0x52cc6c=>{const _0x394454=_0x55b05d;_0x52cc6c[_0x394454(0x1fd)]===_0x220a1f['McpToolCallFailed']&&this[_0x394454(0x1f7)](this[_0x394454(0x1ec)][_0x394454(0x1f1)],_0x52cc6c[_0x394454(0x1e4)]);})));}[_0x26d105(0x1f8)](_0x238151,_0xbda2f3){const _0x579e34=_0x26d105;return this[_0x579e34(0x1fc)][_0x579e34(0x206)](_0x582e6d)['validateToolCall'](_0x238151,_0xbda2f3);}[_0x26d105(0x1ee)](){const _0x8e27c4=_0x26d105;return this['_injector'][_0x8e27c4(0x206)](_0x582e6d)[_0x8e27c4(0x202)]();}[_0x26d105(0x204)](_0x37c58b,_0x3fe93f){const _0x48a8f=_0x26d105;return this['_injector']['get'](_0x582e6d)[_0x48a8f(0x1fe)](_0x37c58b,_0x3fe93f);}[_0x26d105(0x1ea)](){const _0x3ca90e=_0x26d105;return this[_0x3ca90e(0x1fc)]['get'](_0x7d7fc0)[_0x3ca90e(0x1ed)]();}['connectMCP'](){const _0x4c52be=_0x26d105;this[_0x4c52be(0x1fc)][_0x4c52be(0x206)](_0x7d7fc0)[_0x4c52be(0x1e7)]();}[_0x26d105(0x1e8)](){const _0x1189f1=_0x26d105;this[_0x1189f1(0x1fc)][_0x1189f1(0x206)](_0x7d7fc0)[_0x1189f1(0x1f6)]();}}_0x312d24[_0x26d105(0x1f0)](M);