@univerjs-pro/mcp 0.13.0 → 0.14.0-insiders.20251227-b250a8d

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/es/facade.js CHANGED
@@ -1 +1 @@
1
- const _0x1ae9d8=_0x2e53;(function(_0x119562,_0x1f6964){const _0x57b1cd=_0x2e53,_0x2b9e4e=_0x119562();while(!![]){try{const _0x2aab13=-parseInt(_0x57b1cd(0x185))/0x1+parseInt(_0x57b1cd(0x17a))/0x2+-parseInt(_0x57b1cd(0x19a))/0x3*(parseInt(_0x57b1cd(0x17b))/0x4)+parseInt(_0x57b1cd(0x199))/0x5*(-parseInt(_0x57b1cd(0x183))/0x6)+-parseInt(_0x57b1cd(0x17f))/0x7*(-parseInt(_0x57b1cd(0x181))/0x8)+parseInt(_0x57b1cd(0x184))/0x9*(-parseInt(_0x57b1cd(0x198))/0xa)+-parseInt(_0x57b1cd(0x17c))/0xb*(-parseInt(_0x57b1cd(0x189))/0xc);if(_0x2aab13===_0x1f6964)break;else _0x2b9e4e['push'](_0x2b9e4e['shift']());}catch(_0xf311ff){_0x2b9e4e['push'](_0x2b9e4e['shift']());}}}(_0x201f,0x7ac21));import{MCPEventId as _0x44ca94,MCPEventService as _0x25bd13,IMCPToolRegistry as _0x5db10e,MCPConnectionController as _0x28d8ab}from'@univerjs-pro/mcp';import{FEventName as _0x354157,FUniver as _0x2e26b5}from'@univerjs/core/facade';import{toDisposable as _0x48dbc3}from'@univerjs/core';function _0x201f(){const _0x5c47b9=['_injector','177338hmHHDA','callMCPTool','288CfMXtT','subscribe','339696mNCjZs','8442333CJlQbR','580287hREfKb','McpConnectionStatusChanged','fireEvent','registerEventHandler','393324kjiBuH','Event','getAllTools','get','executeTool','data','validateToolCall','extend','McpToolCallFailed','connectMCP','event$','disconnectMCP','McpToolCallExecuted','McpToolCallReceived','type','10iAjdci','20gLvMCN','549FcPvIn','getAllMCPTools','disconnect','_registerMCPFacadeEvents','485612gIRiOh','18384aGjTrc','649DbXeZo','getConnectionStatus'];_0x201f=function(){return _0x5c47b9;};return _0x201f();}class d{get[_0x1ae9d8(0x186)](){const _0x23d216=_0x1ae9d8;return _0x44ca94[_0x23d216(0x186)];}get['McpToolCallReceived'](){const _0x26f782=_0x1ae9d8;return _0x44ca94[_0x26f782(0x196)];}get[_0x1ae9d8(0x195)](){const _0x4092ee=_0x1ae9d8;return _0x44ca94[_0x4092ee(0x195)];}get[_0x1ae9d8(0x191)](){const _0x1c047d=_0x1ae9d8;return _0x44ca94[_0x1c047d(0x191)];}}_0x354157[_0x1ae9d8(0x190)](d);function _0x2e53(_0xa488c8,_0x2f2945){_0xa488c8=_0xa488c8-0x17a;const _0x201f50=_0x201f();let _0x2e5378=_0x201f50[_0xa488c8];return _0x2e5378;}class M extends _0x2e26b5{['_initialize'](_0x33e653){this['_registerMCPFacadeEvents'](_0x33e653);}[_0x1ae9d8(0x19d)](_0x544275){const _0x69cadf=_0x1ae9d8,_0x187fa1=_0x544275[_0x69cadf(0x18c)](_0x25bd13);this[_0x69cadf(0x188)](this['Event'][_0x69cadf(0x186)],()=>_0x48dbc3(_0x187fa1['event$']['subscribe'](_0x380874=>{const _0x4c2738=_0x69cadf;_0x380874[_0x4c2738(0x197)]===_0x44ca94[_0x4c2738(0x186)]&&this['fireEvent'](this[_0x4c2738(0x18a)][_0x4c2738(0x186)],_0x380874[_0x4c2738(0x18e)]);}))),this[_0x69cadf(0x188)](this[_0x69cadf(0x18a)][_0x69cadf(0x196)],()=>_0x48dbc3(_0x187fa1[_0x69cadf(0x193)][_0x69cadf(0x182)](_0xd75861=>{const _0x3a4f2b=_0x69cadf;_0xd75861['type']===_0x44ca94['McpToolCallReceived']&&this[_0x3a4f2b(0x187)](this['Event'][_0x3a4f2b(0x196)],_0xd75861[_0x3a4f2b(0x18e)]);}))),this[_0x69cadf(0x188)](this[_0x69cadf(0x18a)][_0x69cadf(0x195)],()=>_0x48dbc3(_0x187fa1[_0x69cadf(0x193)]['subscribe'](_0x15559e=>{const _0x313e71=_0x69cadf;_0x15559e['type']===_0x44ca94[_0x313e71(0x195)]&&this[_0x313e71(0x187)](this[_0x313e71(0x18a)][_0x313e71(0x195)],_0x15559e[_0x313e71(0x18e)]);}))),this[_0x69cadf(0x188)](this['Event'][_0x69cadf(0x191)],()=>_0x48dbc3(_0x187fa1['event$']['subscribe'](_0x534528=>{const _0x16c663=_0x69cadf;_0x534528[_0x16c663(0x197)]===_0x44ca94['McpToolCallFailed']&&this['fireEvent'](this['Event'][_0x16c663(0x191)],_0x534528[_0x16c663(0x18e)]);})));}['validateMCPToolCall'](_0x3e3462,_0x284121){const _0x5119d9=_0x1ae9d8;return this[_0x5119d9(0x17e)][_0x5119d9(0x18c)](_0x5db10e)[_0x5119d9(0x18f)](_0x3e3462,_0x284121);}[_0x1ae9d8(0x19b)](){const _0x5cf355=_0x1ae9d8;return this[_0x5cf355(0x17e)]['get'](_0x5db10e)[_0x5cf355(0x18b)]();}[_0x1ae9d8(0x180)](_0x55ea17,_0x57229b){const _0xf11153=_0x1ae9d8;return this[_0xf11153(0x17e)]['get'](_0x5db10e)[_0xf11153(0x18d)](_0x55ea17,_0x57229b);}['getMCPConnectionStatus'](){const _0x30df96=_0x1ae9d8;return this[_0x30df96(0x17e)][_0x30df96(0x18c)](_0x28d8ab)[_0x30df96(0x17d)]();}[_0x1ae9d8(0x192)](){this['_injector']['get'](_0x28d8ab)['connect']();}[_0x1ae9d8(0x194)](){const _0x4d6a9e=_0x1ae9d8;this[_0x4d6a9e(0x17e)]['get'](_0x28d8ab)[_0x4d6a9e(0x19c)]();}}_0x2e26b5[_0x1ae9d8(0x190)](M);
1
+ const _0x4052bf=_0x5e72;(function(_0x5e2c34,_0xecc40e){const _0x2b7bf9=_0x5e72,_0x4e8f92=_0x5e2c34();while(!![]){try{const _0x5450d9=-parseInt(_0x2b7bf9(0x187))/0x1+parseInt(_0x2b7bf9(0x19a))/0x2*(-parseInt(_0x2b7bf9(0x1a5))/0x3)+parseInt(_0x2b7bf9(0x1a4))/0x4+-parseInt(_0x2b7bf9(0x196))/0x5*(-parseInt(_0x2b7bf9(0x18a))/0x6)+-parseInt(_0x2b7bf9(0x19f))/0x7*(parseInt(_0x2b7bf9(0x192))/0x8)+parseInt(_0x2b7bf9(0x1a8))/0x9+-parseInt(_0x2b7bf9(0x195))/0xa*(-parseInt(_0x2b7bf9(0x194))/0xb);if(_0x5450d9===_0xecc40e)break;else _0x4e8f92['push'](_0x4e8f92['shift']());}catch(_0x245901){_0x4e8f92['push'](_0x4e8f92['shift']());}}}(_0x2f59,0xef978));function _0x5e72(_0x3b5c5d,_0x1cc875){_0x3b5c5d=_0x3b5c5d-0x185;const _0x2f596f=_0x2f59();let _0x5e7225=_0x2f596f[_0x3b5c5d];return _0x5e7225;}import{MCPEventId as _0x530409,MCPEventService as _0x4a8b63,IMCPToolRegistry as _0x1f87c8,MCPConnectionController as _0x4d283b}from'@univerjs-pro/mcp';import{FEventName as _0x558c42,FUniver as _0x4b12b8}from'@univerjs/core/facade';import{toDisposable as _0xe7bab3}from'@univerjs/core';class d{get['McpConnectionStatusChanged'](){const _0x32a4e8=_0x5e72;return _0x530409[_0x32a4e8(0x18c)];}get[_0x4052bf(0x193)](){const _0x50fc86=_0x4052bf;return _0x530409[_0x50fc86(0x193)];}get[_0x4052bf(0x1a0)](){const _0x165330=_0x4052bf;return _0x530409[_0x165330(0x1a0)];}get[_0x4052bf(0x190)](){const _0x47172e=_0x4052bf;return _0x530409[_0x47172e(0x190)];}}function _0x2f59(){const _0x3e3e7d=['getAllTools','get','6sPCTkz','_registerMCPFacadeEvents','McpConnectionStatusChanged','Event','extend','type','McpToolCallFailed','executeTool','11777384imuFBP','McpToolCallReceived','28665131KXicnW','10lnLLfo','6231790EttljR','registerEventHandler','_injector','connect','2pTmmxK','fireEvent','validateToolCall','data','getConnectionStatus','7cBsutV','McpToolCallExecuted','callMCPTool','event$','disconnectMCP','3872544dSiEGQ','2683047kYohBo','disconnect','connectMCP','2809071kKlazc','getAllMCPTools','subscribe','_initialize','getMCPConnectionStatus','1784644vjZQrq'];_0x2f59=function(){return _0x3e3e7d;};return _0x2f59();}_0x558c42[_0x4052bf(0x18e)](d);class M extends _0x4b12b8{[_0x4052bf(0x185)](_0x455a4c){const _0x552801=_0x4052bf;this[_0x552801(0x18b)](_0x455a4c);}['_registerMCPFacadeEvents'](_0x1ca63e){const _0xa777e2=_0x4052bf,_0x941b32=_0x1ca63e[_0xa777e2(0x189)](_0x4a8b63);this['registerEventHandler'](this['Event'][_0xa777e2(0x18c)],()=>_0xe7bab3(_0x941b32[_0xa777e2(0x1a2)][_0xa777e2(0x1aa)](_0x53c070=>{const _0x724256=_0xa777e2;_0x53c070[_0x724256(0x18f)]===_0x530409['McpConnectionStatusChanged']&&this['fireEvent'](this[_0x724256(0x18d)][_0x724256(0x18c)],_0x53c070[_0x724256(0x19d)]);}))),this[_0xa777e2(0x197)](this[_0xa777e2(0x18d)][_0xa777e2(0x193)],()=>_0xe7bab3(_0x941b32['event$'][_0xa777e2(0x1aa)](_0x30bdfb=>{const _0xfe6a23=_0xa777e2;_0x30bdfb[_0xfe6a23(0x18f)]===_0x530409[_0xfe6a23(0x193)]&&this[_0xfe6a23(0x19b)](this[_0xfe6a23(0x18d)][_0xfe6a23(0x193)],_0x30bdfb[_0xfe6a23(0x19d)]);}))),this['registerEventHandler'](this[_0xa777e2(0x18d)][_0xa777e2(0x1a0)],()=>_0xe7bab3(_0x941b32[_0xa777e2(0x1a2)]['subscribe'](_0x4209a1=>{const _0x50ae02=_0xa777e2;_0x4209a1[_0x50ae02(0x18f)]===_0x530409[_0x50ae02(0x1a0)]&&this[_0x50ae02(0x19b)](this[_0x50ae02(0x18d)]['McpToolCallExecuted'],_0x4209a1[_0x50ae02(0x19d)]);}))),this[_0xa777e2(0x197)](this[_0xa777e2(0x18d)][_0xa777e2(0x190)],()=>_0xe7bab3(_0x941b32['event$'][_0xa777e2(0x1aa)](_0x2784c9=>{const _0x58f94b=_0xa777e2;_0x2784c9[_0x58f94b(0x18f)]===_0x530409[_0x58f94b(0x190)]&&this['fireEvent'](this[_0x58f94b(0x18d)][_0x58f94b(0x190)],_0x2784c9['data']);})));}['validateMCPToolCall'](_0x13c98b,_0x17b9e7){const _0x85331=_0x4052bf;return this[_0x85331(0x198)]['get'](_0x1f87c8)[_0x85331(0x19c)](_0x13c98b,_0x17b9e7);}[_0x4052bf(0x1a9)](){const _0x2bd43c=_0x4052bf;return this[_0x2bd43c(0x198)][_0x2bd43c(0x189)](_0x1f87c8)[_0x2bd43c(0x188)]();}[_0x4052bf(0x1a1)](_0x36f16e,_0x586561){const _0x5d5703=_0x4052bf;return this[_0x5d5703(0x198)][_0x5d5703(0x189)](_0x1f87c8)[_0x5d5703(0x191)](_0x36f16e,_0x586561);}[_0x4052bf(0x186)](){const _0x4532b5=_0x4052bf;return this['_injector'][_0x4532b5(0x189)](_0x4d283b)[_0x4532b5(0x19e)]();}[_0x4052bf(0x1a7)](){const _0x4203ea=_0x4052bf;this[_0x4203ea(0x198)]['get'](_0x4d283b)[_0x4203ea(0x199)]();}[_0x4052bf(0x1a3)](){const _0x5a4527=_0x4052bf;this[_0x5a4527(0x198)][_0x5a4527(0x189)](_0x4d283b)[_0x5a4527(0x1a6)]();}}_0x4b12b8[_0x4052bf(0x18e)](M);