@univerjs-pro/mcp 0.15.2 → 0.15.3-insiders.20260131-cbd5fac

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 _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);
1
+ const _0x3fc1d1=_0x1260;(function(_0x1074f1,_0x4f299f){const _0x38e852=_0x1260,_0x20c2db=_0x1074f1();while(!![]){try{const _0x1b8989=parseInt(_0x38e852(0x135))/0x1*(-parseInt(_0x38e852(0x14a))/0x2)+parseInt(_0x38e852(0x12a))/0x3+-parseInt(_0x38e852(0x146))/0x4*(parseInt(_0x38e852(0x14f))/0x5)+parseInt(_0x38e852(0x147))/0x6+parseInt(_0x38e852(0x12b))/0x7*(parseInt(_0x38e852(0x130))/0x8)+-parseInt(_0x38e852(0x13c))/0x9+-parseInt(_0x38e852(0x14c))/0xa*(-parseInt(_0x38e852(0x14d))/0xb);if(_0x1b8989===_0x4f299f)break;else _0x20c2db['push'](_0x20c2db['shift']());}catch(_0x2e63e6){_0x20c2db['push'](_0x20c2db['shift']());}}}(_0x26a6,0xd1021));import{MCPEventId as _0x511983,MCPEventService as _0xbf61d1,IMCPToolRegistry as _0x4da5e6,MCPConnectionController as _0x415474}from'@univerjs-pro/mcp';import{FEventName as _0x220aa2,FUniver as _0x199a10}from'@univerjs/core/facade';import{toDisposable as _0x1cbdc8}from'@univerjs/core';class d{get[_0x3fc1d1(0x140)](){return _0x511983['McpConnectionStatusChanged'];}get[_0x3fc1d1(0x13a)](){const _0x467147=_0x3fc1d1;return _0x511983[_0x467147(0x13a)];}get[_0x3fc1d1(0x143)](){return _0x511983['McpToolCallExecuted'];}get[_0x3fc1d1(0x142)](){const _0x2f9ae5=_0x3fc1d1;return _0x511983[_0x2f9ae5(0x142)];}}function _0x1260(_0x1301b1,_0x531395){_0x1301b1=_0x1301b1-0x129;const _0x26a610=_0x26a6();let _0x1260b6=_0x26a610[_0x1301b1];return _0x1260b6;}function _0x26a6(){const _0x28855c=['_registerMCPFacadeEvents','getMCPConnectionStatus','115847JdhYvr','_injector','subscribe','data','disconnectMCP','McpToolCallReceived','validateToolCall','14085981sNRjsN','disconnect','executeTool','disposeWithMe','McpConnectionStatusChanged','fireEvent','McpToolCallFailed','McpToolCallExecuted','getConnectionStatus','getAllMCPTools','4VXvZZZ','3289488WijZSw','Event','connectMCP','12LgHwmN','connect','780nVWoeT','243265keYZrF','type','2268535cEMnKE','_initialize','375171YGZGlz','18641fdQbFh','callMCPTool','get','registerEventHandler','extend','3520UVTRtb','getAllTools','event$'];_0x26a6=function(){return _0x28855c;};return _0x26a6();}_0x220aa2['extend'](d);class M extends _0x199a10{[_0x3fc1d1(0x129)](_0x31a8eb){const _0x5b4dd3=_0x3fc1d1;this[_0x5b4dd3(0x133)](_0x31a8eb);}[_0x3fc1d1(0x133)](_0x3b61d3){const _0x26304b=_0x3fc1d1,_0x288d6c=_0x3b61d3[_0x26304b(0x12d)](_0xbf61d1);this[_0x26304b(0x13f)](this['registerEventHandler'](this[_0x26304b(0x148)][_0x26304b(0x140)],()=>_0x1cbdc8(_0x288d6c[_0x26304b(0x132)][_0x26304b(0x137)](_0x47dc23=>{const _0x53fcc8=_0x26304b;_0x47dc23[_0x53fcc8(0x14e)]===_0x511983['McpConnectionStatusChanged']&&this['fireEvent'](this[_0x53fcc8(0x148)][_0x53fcc8(0x140)],_0x47dc23[_0x53fcc8(0x138)]);})))),this[_0x26304b(0x13f)](this[_0x26304b(0x12e)](this['Event'][_0x26304b(0x13a)],()=>_0x1cbdc8(_0x288d6c[_0x26304b(0x132)][_0x26304b(0x137)](_0x3006a8=>{const _0x27449a=_0x26304b;_0x3006a8['type']===_0x511983['McpToolCallReceived']&&this['fireEvent'](this[_0x27449a(0x148)]['McpToolCallReceived'],_0x3006a8[_0x27449a(0x138)]);})))),this[_0x26304b(0x13f)](this[_0x26304b(0x12e)](this[_0x26304b(0x148)][_0x26304b(0x143)],()=>_0x1cbdc8(_0x288d6c['event$'][_0x26304b(0x137)](_0x2d2ca2=>{const _0x56c22a=_0x26304b;_0x2d2ca2['type']===_0x511983[_0x56c22a(0x143)]&&this[_0x56c22a(0x141)](this[_0x56c22a(0x148)]['McpToolCallExecuted'],_0x2d2ca2[_0x56c22a(0x138)]);})))),this[_0x26304b(0x13f)](this[_0x26304b(0x12e)](this['Event'][_0x26304b(0x142)],()=>_0x1cbdc8(_0x288d6c['event$']['subscribe'](_0x5b1fab=>{const _0x466923=_0x26304b;_0x5b1fab[_0x466923(0x14e)]===_0x511983[_0x466923(0x142)]&&this['fireEvent'](this[_0x466923(0x148)][_0x466923(0x142)],_0x5b1fab['data']);}))));}['validateMCPToolCall'](_0x227ebc,_0x341c10){const _0x382552=_0x3fc1d1;return this[_0x382552(0x136)][_0x382552(0x12d)](_0x4da5e6)[_0x382552(0x13b)](_0x227ebc,_0x341c10);}[_0x3fc1d1(0x145)](){const _0x5928f5=_0x3fc1d1;return this[_0x5928f5(0x136)]['get'](_0x4da5e6)[_0x5928f5(0x131)]();}[_0x3fc1d1(0x12c)](_0x1d0bd7,_0x4b3dea){const _0x27c549=_0x3fc1d1;return this[_0x27c549(0x136)][_0x27c549(0x12d)](_0x4da5e6)[_0x27c549(0x13e)](_0x1d0bd7,_0x4b3dea);}[_0x3fc1d1(0x134)](){const _0x28ad4f=_0x3fc1d1;return this[_0x28ad4f(0x136)][_0x28ad4f(0x12d)](_0x415474)[_0x28ad4f(0x144)]();}[_0x3fc1d1(0x149)](){const _0x1aa619=_0x3fc1d1;this[_0x1aa619(0x136)][_0x1aa619(0x12d)](_0x415474)[_0x1aa619(0x14b)]();}[_0x3fc1d1(0x139)](){const _0x529fc0=_0x3fc1d1;this[_0x529fc0(0x136)][_0x529fc0(0x12d)](_0x415474)[_0x529fc0(0x13d)]();}}_0x199a10[_0x3fc1d1(0x12f)](M);