@univerjs-pro/mcp 0.10.9-experimental.20250925-61b61a0 → 0.10.9-nightly.202509260614

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 _0x395a5f=_0x5c59;function _0x5c59(_0x1a6ef8,_0x518b0b){const _0x434055=_0x4340();return _0x5c59=function(_0x5c59b8,_0x5a64ba){_0x5c59b8=_0x5c59b8-0x6a;let _0x54d528=_0x434055[_0x5c59b8];return _0x54d528;},_0x5c59(_0x1a6ef8,_0x518b0b);}(function(_0x3d7ccf,_0x4b9dc5){const _0x361b44=_0x5c59,_0x24355d=_0x3d7ccf();while(!![]){try{const _0x3a69d2=parseInt(_0x361b44(0x77))/0x1+-parseInt(_0x361b44(0x70))/0x2*(parseInt(_0x361b44(0x74))/0x3)+-parseInt(_0x361b44(0x8a))/0x4+-parseInt(_0x361b44(0x6a))/0x5*(-parseInt(_0x361b44(0x78))/0x6)+-parseInt(_0x361b44(0x72))/0x7*(parseInt(_0x361b44(0x82))/0x8)+-parseInt(_0x361b44(0x76))/0x9+-parseInt(_0x361b44(0x83))/0xa*(-parseInt(_0x361b44(0x6e))/0xb);if(_0x3a69d2===_0x4b9dc5)break;else _0x24355d['push'](_0x24355d['shift']());}catch(_0x2e6063){_0x24355d['push'](_0x24355d['shift']());}}}(_0x4340,0xad3d8));function _0x4340(){const _0x3f23c5=['1738990wiVzrh','getAllTools','14efxwDN','executeTool','3QaPYdP','McpConnectionStatusChanged','2420262cwPvSq','647142jlBXJQ','1280946NtWYZL','McpToolCallReceived','_initialize','getAllMCPTools','event$','validateMCPToolCall','subscribe','Event','McpToolCallExecuted','disconnect','2553240RGJpOq','80AgbHoK','_registerMCPFacadeEvents','McpToolCallFailed','_injector','registerEventHandler','validateToolCall','type','779128DEWbvb','extend','fireEvent','getMCPConnectionStatus','5nyqwDH','get','data','getConnectionStatus','2503138FzhJNd','disconnectMCP'];_0x4340=function(){return _0x3f23c5;};return _0x4340();}import{MCPEventId as _0x244de3,MCPEventService as _0x13168f,IMCPToolRegistry as _0x45f8ab,MCPConnectionController as _0x2f966d}from'@univerjs-pro/mcp';import{FEventName as _0x1a0ec8,FUniver as _0x4d6ea6}from'@univerjs/core/facade';import{toDisposable as _0x3dde5a}from'@univerjs/core';class d{get[_0x395a5f(0x75)](){const _0x42bf48=_0x395a5f;return _0x244de3[_0x42bf48(0x75)];}get[_0x395a5f(0x79)](){return _0x244de3['McpToolCallReceived'];}get['McpToolCallExecuted'](){const _0x56b23a=_0x395a5f;return _0x244de3[_0x56b23a(0x80)];}get[_0x395a5f(0x85)](){const _0x326fbc=_0x395a5f;return _0x244de3[_0x326fbc(0x85)];}}_0x1a0ec8[_0x395a5f(0x8b)](d);class M extends _0x4d6ea6{[_0x395a5f(0x7a)](_0x518fa6){this['_registerMCPFacadeEvents'](_0x518fa6);}[_0x395a5f(0x84)](_0x129e62){const _0x22192c=_0x395a5f,_0x309456=_0x129e62[_0x22192c(0x6b)](_0x13168f);this[_0x22192c(0x87)](this[_0x22192c(0x7f)]['McpConnectionStatusChanged'],()=>_0x3dde5a(_0x309456['event$'][_0x22192c(0x7e)](_0x5d559b=>{const _0x5cfea7=_0x22192c;_0x5d559b[_0x5cfea7(0x89)]===_0x244de3[_0x5cfea7(0x75)]&&this[_0x5cfea7(0x8c)](this['Event']['McpConnectionStatusChanged'],_0x5d559b[_0x5cfea7(0x6c)]);}))),this[_0x22192c(0x87)](this[_0x22192c(0x7f)][_0x22192c(0x79)],()=>_0x3dde5a(_0x309456[_0x22192c(0x7c)][_0x22192c(0x7e)](_0x55779a=>{const _0x582074=_0x22192c;_0x55779a[_0x582074(0x89)]===_0x244de3['McpToolCallReceived']&&this[_0x582074(0x8c)](this['Event'][_0x582074(0x79)],_0x55779a[_0x582074(0x6c)]);}))),this[_0x22192c(0x87)](this['Event']['McpToolCallExecuted'],()=>_0x3dde5a(_0x309456[_0x22192c(0x7c)]['subscribe'](_0x4545f8=>{const _0x538b68=_0x22192c;_0x4545f8[_0x538b68(0x89)]===_0x244de3[_0x538b68(0x80)]&&this[_0x538b68(0x8c)](this['Event']['McpToolCallExecuted'],_0x4545f8[_0x538b68(0x6c)]);}))),this['registerEventHandler'](this[_0x22192c(0x7f)]['McpToolCallFailed'],()=>_0x3dde5a(_0x309456[_0x22192c(0x7c)][_0x22192c(0x7e)](_0xa1f228=>{const _0x3c2594=_0x22192c;_0xa1f228[_0x3c2594(0x89)]===_0x244de3[_0x3c2594(0x85)]&&this[_0x3c2594(0x8c)](this[_0x3c2594(0x7f)][_0x3c2594(0x85)],_0xa1f228[_0x3c2594(0x6c)]);})));}[_0x395a5f(0x7d)](_0x2e75db,_0x19e6e0){const _0x9cb65f=_0x395a5f;return this[_0x9cb65f(0x86)][_0x9cb65f(0x6b)](_0x45f8ab)[_0x9cb65f(0x88)](_0x2e75db,_0x19e6e0);}[_0x395a5f(0x7b)](){const _0x860736=_0x395a5f;return this['_injector'][_0x860736(0x6b)](_0x45f8ab)[_0x860736(0x71)]();}['callMCPTool'](_0x5d2d08,_0x725a28){const _0x4133ab=_0x395a5f;return this[_0x4133ab(0x86)][_0x4133ab(0x6b)](_0x45f8ab)[_0x4133ab(0x73)](_0x5d2d08,_0x725a28);}[_0x395a5f(0x8d)](){const _0x3fd5bd=_0x395a5f;return this['_injector'][_0x3fd5bd(0x6b)](_0x2f966d)[_0x3fd5bd(0x6d)]();}['connectMCP'](){const _0x11ad8d=_0x395a5f;this[_0x11ad8d(0x86)][_0x11ad8d(0x6b)](_0x2f966d)['connect']();}[_0x395a5f(0x6f)](){const _0x51593b=_0x395a5f;this[_0x51593b(0x86)][_0x51593b(0x6b)](_0x2f966d)[_0x51593b(0x81)]();}}_0x4d6ea6[_0x395a5f(0x8b)](M);
1
+ const _0x2299f8=_0x7d9e;(function(_0x3a30cc,_0x3abc69){const _0x5c3dc3=_0x7d9e,_0x61291f=_0x3a30cc();while(!![]){try{const _0x5ec740=parseInt(_0x5c3dc3(0xe4))/0x1*(parseInt(_0x5c3dc3(0xfa))/0x2)+-parseInt(_0x5c3dc3(0xfe))/0x3*(-parseInt(_0x5c3dc3(0xf8))/0x4)+parseInt(_0x5c3dc3(0xf2))/0x5*(parseInt(_0x5c3dc3(0x106))/0x6)+-parseInt(_0x5c3dc3(0xf3))/0x7*(-parseInt(_0x5c3dc3(0xe3))/0x8)+parseInt(_0x5c3dc3(0xf9))/0x9+parseInt(_0x5c3dc3(0xe9))/0xa+-parseInt(_0x5c3dc3(0xec))/0xb;if(_0x5ec740===_0x3abc69)break;else _0x61291f['push'](_0x61291f['shift']());}catch(_0x153b69){_0x61291f['push'](_0x61291f['shift']());}}}(_0x47bf,0x36d2c));import{MCPEventId as _0x2c4e1a,MCPEventService as _0x556b05,IMCPToolRegistry as _0x13c6e9,MCPConnectionController as _0x173f51}from'@univerjs-pro/mcp';import{FEventName as _0x26e343,FUniver as _0x5ee23b}from'@univerjs/core/facade';function _0x47bf(){const _0x3550a6=['_injector','Event','getAllTools','executeTool','registerEventHandler','6Zaqkit','getConnectionStatus','8rzKjSb','54652BCGgLz','McpToolCallReceived','type','subscribe','disconnectMCP','3469400YGlxUB','get','getMCPConnectionStatus','11949432jeUkUL','validateMCPToolCall','connectMCP','fireEvent','_registerMCPFacadeEvents','McpToolCallExecuted','570085YzdcuU','806029ZydlBb','data','event$','McpConnectionStatusChanged','getAllMCPTools','26904hHTJgh','3850866bnbuvm','10dTYnhI','connect','extend','callMCPTool','15sKMyvb','McpToolCallFailed','disconnect'];_0x47bf=function(){return _0x3550a6;};return _0x47bf();}import{toDisposable as _0x241d62}from'@univerjs/core';class d{get[_0x2299f8(0xf6)](){const _0x82b291=_0x2299f8;return _0x2c4e1a[_0x82b291(0xf6)];}get[_0x2299f8(0xe5)](){const _0x1dec5d=_0x2299f8;return _0x2c4e1a[_0x1dec5d(0xe5)];}get[_0x2299f8(0xf1)](){const _0x515620=_0x2299f8;return _0x2c4e1a[_0x515620(0xf1)];}get['McpToolCallFailed'](){const _0x4ee76c=_0x2299f8;return _0x2c4e1a[_0x4ee76c(0xff)];}}function _0x7d9e(_0x387b3d,_0x55441d){const _0x47bf0e=_0x47bf();return _0x7d9e=function(_0x7d9e6b,_0x3bfe86){_0x7d9e6b=_0x7d9e6b-0xe2;let _0xae6e5=_0x47bf0e[_0x7d9e6b];return _0xae6e5;},_0x7d9e(_0x387b3d,_0x55441d);}_0x26e343[_0x2299f8(0xfc)](d);class M extends _0x5ee23b{['_initialize'](_0x1a5cbe){const _0x32883d=_0x2299f8;this[_0x32883d(0xf0)](_0x1a5cbe);}[_0x2299f8(0xf0)](_0x50126d){const _0x72adf5=_0x2299f8,_0x31c754=_0x50126d[_0x72adf5(0xea)](_0x556b05);this[_0x72adf5(0x105)](this[_0x72adf5(0x102)][_0x72adf5(0xf6)],()=>_0x241d62(_0x31c754[_0x72adf5(0xf5)][_0x72adf5(0xe7)](_0x1e2ca3=>{const _0x21ca35=_0x72adf5;_0x1e2ca3[_0x21ca35(0xe6)]===_0x2c4e1a[_0x21ca35(0xf6)]&&this[_0x21ca35(0xef)](this[_0x21ca35(0x102)][_0x21ca35(0xf6)],_0x1e2ca3['data']);}))),this[_0x72adf5(0x105)](this['Event'][_0x72adf5(0xe5)],()=>_0x241d62(_0x31c754[_0x72adf5(0xf5)]['subscribe'](_0x1c5ef9=>{const _0x5498b8=_0x72adf5;_0x1c5ef9[_0x5498b8(0xe6)]===_0x2c4e1a[_0x5498b8(0xe5)]&&this[_0x5498b8(0xef)](this[_0x5498b8(0x102)][_0x5498b8(0xe5)],_0x1c5ef9[_0x5498b8(0xf4)]);}))),this[_0x72adf5(0x105)](this['Event'][_0x72adf5(0xf1)],()=>_0x241d62(_0x31c754[_0x72adf5(0xf5)][_0x72adf5(0xe7)](_0x1ddcf5=>{const _0x644b20=_0x72adf5;_0x1ddcf5[_0x644b20(0xe6)]===_0x2c4e1a[_0x644b20(0xf1)]&&this[_0x644b20(0xef)](this[_0x644b20(0x102)][_0x644b20(0xf1)],_0x1ddcf5['data']);}))),this[_0x72adf5(0x105)](this[_0x72adf5(0x102)]['McpToolCallFailed'],()=>_0x241d62(_0x31c754['event$'][_0x72adf5(0xe7)](_0xe27a0d=>{const _0x233286=_0x72adf5;_0xe27a0d[_0x233286(0xe6)]===_0x2c4e1a[_0x233286(0xff)]&&this['fireEvent'](this['Event'][_0x233286(0xff)],_0xe27a0d[_0x233286(0xf4)]);})));}[_0x2299f8(0xed)](_0x4c4224,_0x390968){const _0x3bccb2=_0x2299f8;return this['_injector'][_0x3bccb2(0xea)](_0x13c6e9)['validateToolCall'](_0x4c4224,_0x390968);}[_0x2299f8(0xf7)](){const _0x4b756f=_0x2299f8;return this[_0x4b756f(0x101)][_0x4b756f(0xea)](_0x13c6e9)[_0x4b756f(0x103)]();}[_0x2299f8(0xfd)](_0x5a86e3,_0x4ec339){const _0x924c67=_0x2299f8;return this['_injector'][_0x924c67(0xea)](_0x13c6e9)[_0x924c67(0x104)](_0x5a86e3,_0x4ec339);}[_0x2299f8(0xeb)](){const _0x39f758=_0x2299f8;return this['_injector'][_0x39f758(0xea)](_0x173f51)[_0x39f758(0xe2)]();}[_0x2299f8(0xee)](){const _0x19f835=_0x2299f8;this[_0x19f835(0x101)]['get'](_0x173f51)[_0x19f835(0xfb)]();}[_0x2299f8(0xe8)](){const _0x4f8e60=_0x2299f8;this[_0x4f8e60(0x101)][_0x4f8e60(0xea)](_0x173f51)[_0x4f8e60(0x100)]();}}_0x5ee23b['extend'](M);