@univerjs-pro/collaboration-client-node 1.0.0-rc.0 → 1.0.1

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/cjs/index.js CHANGED
@@ -1 +1 @@
1
- const _0x14e038=_0x23e0;function _0x51f8(){const _0x40d307=['108412VZhuWf','packageName','Injector','toStringTag','registerDependencies','NodeCollaborationSocketService','UniverNetworkPlugin','DependentOn','message','open','Disposable','1.0.0-rc.0','Plugin','6DMPoCD','prototype','1647pIjERs','error','230586yTFkfA','share','set','CollaborationSocketService','40024XRiOaB','string','UniverCollaborationPlugin','UNIVER_COLLABORATION_CLIENT_NODE_PLUGIN','object','registerHTTPInterceptor','ILogService','customHeaders','33740YmEFty','IConfigService','decorate','default','DisposableCollection','_doCreateSocket','Inject','toPrimitive','dispose','UniverCollaborationClientPlugin','pipe','length','version','@univerjs-pro/collaboration-client-node','_configService','pluginName','getConfig','constructor','UniverCollaborationClientNodePlugin','symbol','close','115gqHsIw','defineProperty','headers','_config','setConfig','2382420idTjdk','next','1013142bRSPUI','_injector','UniverLicensePlugin','getOwnPropertyDescriptor','iterator','COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY','addEventListener','call','toDisposable','collaboration-client-node.config','add','7248lKEiXY','function','removeEventListener','Observable','createSocket'];_0x51f8=function(){return _0x40d307;};return _0x51f8();}(function(_0x1dedf2,_0x44651e){const _0x2ad5a8=_0x23e0,_0x23e195=_0x1dedf2();while(!![]){try{const _0x109128=-parseInt(_0x2ad5a8(0x1fa))/0x1+-parseInt(_0x2ad5a8(0x207))/0x2*(-parseInt(_0x2ad5a8(0x20b))/0x3)+parseInt(_0x2ad5a8(0x20f))/0x4*(-parseInt(_0x2ad5a8(0x1e3))/0x5)+parseInt(_0x2ad5a8(0x1ea))/0x6+parseInt(_0x2ad5a8(0x217))/0x7+parseInt(_0x2ad5a8(0x1f5))/0x8*(-parseInt(_0x2ad5a8(0x209))/0x9)+parseInt(_0x2ad5a8(0x1e8))/0xa;if(_0x109128===_0x44651e)break;else _0x23e195['push'](_0x23e195['shift']());}catch(_0x5660d2){_0x23e195['push'](_0x23e195['shift']());}}}(_0x51f8,0x21bad),Object[_0x14e038(0x1e4)](exports,Symbol[_0x14e038(0x1fd)],{'value':'Module'}));let e=require('@univerjs-pro/collaboration'),t=require('@univerjs-pro/collaboration-client'),n=require('@univerjs-pro/license'),r=require('@univerjs/core'),i=require('@univerjs/network'),a=require('rxjs'),o=require('ws');var s=_0x14e038(0x224),c=_0x14e038(0x205);const l={};function _0x23e0(_0x2f099e,_0x83113a){_0x2f099e=_0x2f099e-0x1e0;const _0x51f8e4=_0x51f8();let _0x23e077=_0x51f8e4[_0x2f099e];return _0x23e077;}function u(_0x50e8c5,_0x535e0f){return function(_0x45ec31,_0x61ff18){_0x535e0f(_0x45ec31,_0x61ff18,_0x50e8c5);};}function d(_0x278187,_0x39253c,_0x135acd,_0x1f2804){const _0x5edbc6=_0x14e038;var _0x1d0372=arguments['length'],_0x441e1f=_0x1d0372<0x3?_0x39253c:_0x1f2804===null?_0x1f2804=Object[_0x5edbc6(0x1ed)](_0x39253c,_0x135acd):_0x1f2804,_0x4c51fd;if(typeof Reflect==_0x5edbc6(0x213)&&typeof Reflect['decorate']=='function')_0x441e1f=Reflect[_0x5edbc6(0x219)](_0x278187,_0x39253c,_0x135acd,_0x1f2804);else{for(var _0x471a2c=_0x278187[_0x5edbc6(0x222)]-0x1;_0x471a2c>=0x0;_0x471a2c--)(_0x4c51fd=_0x278187[_0x471a2c])&&(_0x441e1f=(_0x1d0372<0x3?_0x4c51fd(_0x441e1f):_0x1d0372>0x3?_0x4c51fd(_0x39253c,_0x135acd,_0x441e1f):_0x4c51fd(_0x39253c,_0x135acd))||_0x441e1f);}return _0x1d0372>0x3&&_0x441e1f&&Object['defineProperty'](_0x39253c,_0x135acd,_0x441e1f),_0x441e1f;}let f=class extends r[_0x14e038(0x204)]{constructor(_0x4ce461){super(),this['_configService']=_0x4ce461;}['createSocket'](_0x36de3c){const _0xb02e9b=_0x14e038;var _0x9d4d34;let _0x52b6ea=((_0x9d4d34=this[_0xb02e9b(0x225)]['getConfig'](t[_0xb02e9b(0x1ef)]))==null?void 0x0:_0x9d4d34['customHeaders'])||{};try{let _0x317ed9=new o['WebSocket'](_0x36de3c,{'headers':{..._0x52b6ea}}),_0xe4536=new r[(_0xb02e9b(0x21b))]();return{'URL':_0x36de3c,'close':(_0x18aeab,_0x372791)=>{const _0x42344e=_0xb02e9b;_0x317ed9[_0x42344e(0x1e2)](_0x18aeab,_0x372791),_0xe4536[_0x42344e(0x21f)]();},'send':_0x514ceb=>{_0x317ed9['send'](_0x514ceb);},'open$':new a[(_0xb02e9b(0x1f8))](_0x969516=>{const _0x4be9b8=_0xb02e9b;let _0x2bc6ae=_0x20bcfe=>_0x969516['next'](_0x20bcfe);_0x317ed9[_0x4be9b8(0x1f0)](_0x4be9b8(0x203),_0x2bc6ae),_0xe4536[_0x4be9b8(0x1f4)]((0x0,r['toDisposable'])(()=>_0x317ed9[_0x4be9b8(0x1f7)]('open',_0x2bc6ae)));})['pipe']((0x0,a[_0xb02e9b(0x20c)])()),'close$':new a[(_0xb02e9b(0x1f8))](_0x5c183e=>{const _0x2b3c26=_0xb02e9b;let _0x2e2aba=_0x3625ec=>_0x5c183e[_0x2b3c26(0x1e9)](_0x3625ec);_0x317ed9[_0x2b3c26(0x1f0)](_0x2b3c26(0x1e2),_0x2e2aba),_0xe4536['add']((0x0,r[_0x2b3c26(0x1f2)])(()=>_0x317ed9[_0x2b3c26(0x1f7)](_0x2b3c26(0x1e2),_0x2e2aba)));})[_0xb02e9b(0x221)]((0x0,a[_0xb02e9b(0x20c)])()),'error$':new a[(_0xb02e9b(0x1f8))](_0x31f403=>{const _0x2aa91b=_0xb02e9b;let _0xa4b044=_0x3425f1=>_0x31f403['next'](_0x3425f1);_0x317ed9['addEventListener'](_0x2aa91b(0x20a),_0xa4b044),_0xe4536['add']((0x0,r[_0x2aa91b(0x1f2)])(()=>_0x317ed9[_0x2aa91b(0x1f7)](_0x2aa91b(0x20a),_0xa4b044)));})[_0xb02e9b(0x221)]((0x0,a[_0xb02e9b(0x20c)])()),'message$':new a[(_0xb02e9b(0x1f8))](_0x3873d4=>{const _0x5e9457=_0xb02e9b;let _0x40e3a5=_0x2b5b41=>_0x3873d4['next'](_0x2b5b41);_0x317ed9['addEventListener'](_0x5e9457(0x202),_0x40e3a5),_0xe4536[_0x5e9457(0x1f4)]((0x0,r[_0x5e9457(0x1f2)])(()=>_0x317ed9['removeEventListener'](_0x5e9457(0x202),_0x40e3a5)));})[_0xb02e9b(0x221)]((0x0,a[_0xb02e9b(0x20c)])())};}catch(_0x4f2978){return console[_0xb02e9b(0x20a)](_0x4f2978),null;}}};f=d([u(0x0,r[_0x14e038(0x218)])],f);function p(_0x4534f7){'@babel/helpers - typeof';const _0x2fc004=_0x14e038;return p=typeof Symbol==_0x2fc004(0x1f6)&&typeof Symbol[_0x2fc004(0x1ee)]==_0x2fc004(0x1e1)?function(_0x4ae559){return typeof _0x4ae559;}:function(_0x55b57b){const _0x304445=_0x2fc004;return _0x55b57b&&typeof Symbol=='function'&&_0x55b57b[_0x304445(0x228)]===Symbol&&_0x55b57b!==Symbol[_0x304445(0x208)]?_0x304445(0x1e1):typeof _0x55b57b;},p(_0x4534f7);}function m(_0x3953e1,_0x17f6d2){const _0x2f10c1=_0x14e038;if(p(_0x3953e1)!='object'||!_0x3953e1)return _0x3953e1;var _0x36fb6f=_0x3953e1[Symbol[_0x2f10c1(0x21e)]];if(_0x36fb6f!==void 0x0){var _0x3d6daf=_0x36fb6f[_0x2f10c1(0x1f1)](_0x3953e1,_0x17f6d2||_0x2f10c1(0x21a));if(p(_0x3d6daf)!=_0x2f10c1(0x213))return _0x3d6daf;throw TypeError('@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.');}return(_0x17f6d2==='string'?String:Number)(_0x3953e1);}function h(_0x4c2637){const _0x3347b8=_0x14e038;var _0x54a557=m(_0x4c2637,_0x3347b8(0x210));return p(_0x54a557)==_0x3347b8(0x1e1)?_0x54a557:_0x54a557+'';}function g(_0x543521,_0x4af5d5,_0x33fb6d){const _0x3e1f76=_0x14e038;return(_0x4af5d5=h(_0x4af5d5))in _0x543521?Object[_0x3e1f76(0x1e4)](_0x543521,_0x4af5d5,{'value':_0x33fb6d,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x543521[_0x4af5d5]=_0x33fb6d,_0x543521;}let _=class extends r[_0x14e038(0x206)]{constructor(_0x3a678f=l,_0x322c64,_0x359c0b){const _0x3b92bb=_0x14e038;super(),this[_0x3b92bb(0x1e6)]=_0x3a678f,this[_0x3b92bb(0x225)]=_0x322c64,this[_0x3b92bb(0x1eb)]=_0x359c0b;let {..._0x1e0286}=(0x0,r['merge'])({},l,this[_0x3b92bb(0x1e6)]);this[_0x3b92bb(0x225)][_0x3b92bb(0x1e7)](_0x3b92bb(0x1f3),_0x1e0286);}['onStarting'](){this['_registerDependencies']();}['_registerDependencies'](){const _0xe99972=_0x14e038;(0x0,r[_0xe99972(0x1fe)])(this['_injector'],[[i['ISocketService'],{'useClass':f}]]);}};g(_,_0x14e038(0x226),_0x14e038(0x212)),g(_,_0x14e038(0x1fb),s),g(_,_0x14e038(0x223),c),_=d([(0x0,r[_0x14e038(0x201)])(n[_0x14e038(0x1ec)],i[_0x14e038(0x200)],e[_0x14e038(0x211)],t[_0x14e038(0x220)]),u(0x1,r['IConfigService']),u(0x2,(0x0,r[_0x14e038(0x21d)])(r[_0x14e038(0x1fc)]))],_);let v=class extends t[_0x14e038(0x20e)]{constructor(_0xaa6344,_0x3694a3,_0x115079,_0xd2f075,_0x12f000){const _0x319bc4=_0x14e038;super(_0xaa6344,_0x3694a3,_0x115079,_0xd2f075,_0x12f000);let _0x10d928=this[_0x319bc4(0x225)][_0x319bc4(0x227)](t['COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY']);this['_httpService'][_0x319bc4(0x214)]({'interceptor':(_0x202919,_0x235eb8)=>{const _0x30d772=_0x319bc4;let _0xdb73d5=_0x202919[_0x30d772(0x1e5)];if(_0x10d928!=null&&_0x10d928[_0x30d772(0x216)]){for(let _0x3f3191 in _0x10d928[_0x30d772(0x216)])_0xdb73d5[_0x30d772(0x20d)](_0x3f3191,_0x10d928[_0x30d772(0x216)][_0x3f3191]);}return _0x235eb8(_0x202919);}});}async[_0x14e038(0x1f9)](_0x2ca9f2){const _0x1b1196=_0x14e038;return this[_0x1b1196(0x21c)](_0x2ca9f2);}};v=d([u(0x0,(0x0,r[_0x14e038(0x21d)])(r['Injector'])),u(0x1,(0x0,r[_0x14e038(0x21d)])(i['HTTPService'])),u(0x2,r[_0x14e038(0x218)]),u(0x3,r[_0x14e038(0x215)]),u(0x4,e['ISnapshotServerService'])],v),Object[_0x14e038(0x1e4)](exports,_0x14e038(0x1ff),{'enumerable':!0x0,'get':function(){return v;}}),Object[_0x14e038(0x1e4)](exports,_0x14e038(0x1e0),{'enumerable':!0x0,'get':function(){return _;}});
1
+ const _0x1f11ae=_0x31e1;(function(_0x3a13f8,_0x1f0b0e){const _0x5684d6=_0x31e1,_0x5831f0=_0x3a13f8();while(!![]){try{const _0x2f8088=parseInt(_0x5684d6(0x20a))/0x1+-parseInt(_0x5684d6(0x1f9))/0x2*(parseInt(_0x5684d6(0x1f3))/0x3)+parseInt(_0x5684d6(0x20b))/0x4*(parseInt(_0x5684d6(0x1e5))/0x5)+parseInt(_0x5684d6(0x20c))/0x6*(-parseInt(_0x5684d6(0x21f))/0x7)+-parseInt(_0x5684d6(0x203))/0x8+-parseInt(_0x5684d6(0x1f0))/0x9*(-parseInt(_0x5684d6(0x1fc))/0xa)+parseInt(_0x5684d6(0x20d))/0xb;if(_0x2f8088===_0x1f0b0e)break;else _0x5831f0['push'](_0x5831f0['shift']());}catch(_0x522bc5){_0x5831f0['push'](_0x5831f0['shift']());}}}(_0x10df,0x8596d),Object[_0x1f11ae(0x1fa)](exports,Symbol[_0x1f11ae(0x217)],{'value':'Module'}));let e=require('@univerjs-pro/collaboration'),t=require('@univerjs-pro/collaboration-client'),n=require('@univerjs-pro/license'),r=require('@univerjs/core'),i=require('@univerjs/network'),a=require('rxjs'),o=require('ws');var s='@univerjs-pro/collaboration-client-node',c=_0x1f11ae(0x1f1);const l={};function u(_0x5fdd35,_0x1232dc){return function(_0x4ed290,_0x3adc7a){_0x1232dc(_0x4ed290,_0x3adc7a,_0x5fdd35);};}function d(_0xd8d63,_0x3fcc1f,_0x34a6bd,_0x7c4837){const _0x4c1145=_0x1f11ae;var _0x15e4cb=arguments[_0x4c1145(0x1fe)],_0x2f592d=_0x15e4cb<0x3?_0x3fcc1f:_0x7c4837===null?_0x7c4837=Object[_0x4c1145(0x226)](_0x3fcc1f,_0x34a6bd):_0x7c4837,_0x5136cb;if(typeof Reflect=='object'&&typeof Reflect[_0x4c1145(0x213)]==_0x4c1145(0x223))_0x2f592d=Reflect[_0x4c1145(0x213)](_0xd8d63,_0x3fcc1f,_0x34a6bd,_0x7c4837);else{for(var _0x4f5ede=_0xd8d63['length']-0x1;_0x4f5ede>=0x0;_0x4f5ede--)(_0x5136cb=_0xd8d63[_0x4f5ede])&&(_0x2f592d=(_0x15e4cb<0x3?_0x5136cb(_0x2f592d):_0x15e4cb>0x3?_0x5136cb(_0x3fcc1f,_0x34a6bd,_0x2f592d):_0x5136cb(_0x3fcc1f,_0x34a6bd))||_0x2f592d);}return _0x15e4cb>0x3&&_0x2f592d&&Object[_0x4c1145(0x1fa)](_0x3fcc1f,_0x34a6bd,_0x2f592d),_0x2f592d;}let f=class extends r[_0x1f11ae(0x1f4)]{constructor(_0x1ff057){const _0x2e1b25=_0x1f11ae;super(),this[_0x2e1b25(0x1fd)]=_0x1ff057;}['createSocket'](_0x471052){const _0x1cc0e5=_0x1f11ae;var _0x19ad06;let _0x3733c9=((_0x19ad06=this[_0x1cc0e5(0x1fd)][_0x1cc0e5(0x21b)](t[_0x1cc0e5(0x209)]))==null?void 0x0:_0x19ad06['customHeaders'])||{};try{let _0x4597ac=new o[(_0x1cc0e5(0x205))](_0x471052,{'headers':{..._0x3733c9}}),_0x313399=new r[(_0x1cc0e5(0x211))]();return{'URL':_0x471052,'close':(_0xeb2ff3,_0x5a3e6d)=>{const _0x36ba72=_0x1cc0e5;_0x4597ac[_0x36ba72(0x20e)](_0xeb2ff3,_0x5a3e6d),_0x313399[_0x36ba72(0x1e8)]();},'send':_0x4a2232=>{_0x4597ac['send'](_0x4a2232);},'open$':new a['Observable'](_0x21844b=>{const _0xa890cc=_0x1cc0e5;let _0x4284c2=_0x1c46d0=>_0x21844b[_0xa890cc(0x214)](_0x1c46d0);_0x4597ac[_0xa890cc(0x225)](_0xa890cc(0x1f2),_0x4284c2),_0x313399['add']((0x0,r['toDisposable'])(()=>_0x4597ac[_0xa890cc(0x1ee)]('open',_0x4284c2)));})['pipe']((0x0,a[_0x1cc0e5(0x212)])()),'close$':new a[(_0x1cc0e5(0x1dc))](_0x5f35b1=>{const _0x221f9f=_0x1cc0e5;let _0x458fb5=_0x4728b1=>_0x5f35b1[_0x221f9f(0x214)](_0x4728b1);_0x4597ac['addEventListener']('close',_0x458fb5),_0x313399['add']((0x0,r[_0x221f9f(0x1e9)])(()=>_0x4597ac[_0x221f9f(0x1ee)](_0x221f9f(0x20e),_0x458fb5)));})[_0x1cc0e5(0x215)]((0x0,a[_0x1cc0e5(0x212)])()),'error$':new a['Observable'](_0x46fc33=>{const _0xc537f7=_0x1cc0e5;let _0x265190=_0xf1af17=>_0x46fc33['next'](_0xf1af17);_0x4597ac[_0xc537f7(0x225)]('error',_0x265190),_0x313399['add']((0x0,r[_0xc537f7(0x1e9)])(()=>_0x4597ac['removeEventListener'](_0xc537f7(0x220),_0x265190)));})[_0x1cc0e5(0x215)]((0x0,a[_0x1cc0e5(0x212)])()),'message$':new a[(_0x1cc0e5(0x1dc))](_0x25a837=>{const _0x38f96d=_0x1cc0e5;let _0x8a86f5=_0x1a1cc0=>_0x25a837[_0x38f96d(0x214)](_0x1a1cc0);_0x4597ac['addEventListener']('message',_0x8a86f5),_0x313399[_0x38f96d(0x1e1)]((0x0,r[_0x38f96d(0x1e9)])(()=>_0x4597ac['removeEventListener'](_0x38f96d(0x204),_0x8a86f5)));})[_0x1cc0e5(0x215)]((0x0,a['share'])())};}catch(_0x226785){return console[_0x1cc0e5(0x220)](_0x226785),null;}}};function _0x31e1(_0x31e119,_0x507cbb){_0x31e119=_0x31e119-0x1db;const _0x10df6d=_0x10df();let _0x31e17f=_0x10df6d[_0x31e119];return _0x31e17f;}f=d([u(0x0,r['IConfigService'])],f);function p(_0x217eb6){'@babel/helpers - typeof';const _0x2f1efe=_0x1f11ae;return p=typeof Symbol==_0x2f1efe(0x223)&&typeof Symbol['iterator']==_0x2f1efe(0x1ec)?function(_0x2592ba){return typeof _0x2592ba;}:function(_0x345b7a){const _0x178401=_0x2f1efe;return _0x345b7a&&typeof Symbol==_0x178401(0x223)&&_0x345b7a[_0x178401(0x1f7)]===Symbol&&_0x345b7a!==Symbol[_0x178401(0x20f)]?_0x178401(0x1ec):typeof _0x345b7a;},p(_0x217eb6);}function m(_0x3e8705,_0x3a9fdf){const _0x3c73f9=_0x1f11ae;if(p(_0x3e8705)!=_0x3c73f9(0x1e6)||!_0x3e8705)return _0x3e8705;var _0x1217c9=_0x3e8705[Symbol[_0x3c73f9(0x1ea)]];if(_0x1217c9!==void 0x0){var _0x4b0446=_0x1217c9[_0x3c73f9(0x1e7)](_0x3e8705,_0x3a9fdf||_0x3c73f9(0x1e3));if(p(_0x4b0446)!=_0x3c73f9(0x1e6))return _0x4b0446;throw TypeError(_0x3c73f9(0x1dd));}return(_0x3a9fdf===_0x3c73f9(0x221)?String:Number)(_0x3e8705);}function h(_0x2a235f){const _0x35a5e1=_0x1f11ae;var _0x14b63f=m(_0x2a235f,'string');return p(_0x14b63f)==_0x35a5e1(0x1ec)?_0x14b63f:_0x14b63f+'';}function _0x10df(){const _0xb7afd2=['pluginName','setConfig','5999SqyyFp','error','string','Inject','function','UNIVER_COLLABORATION_CLIENT_NODE_PLUGIN','addEventListener','getOwnPropertyDescriptor','HTTPService','Observable','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','packageName','merge','ISnapshotServerService','add','NodeCollaborationSocketService','default','registerDependencies','140870kPLHBn','object','call','dispose','toDisposable','toPrimitive','IConfigService','symbol','headers','removeEventListener','collaboration-client-node.config','9GLJrBV','1.0.1','open','3fxkENe','Disposable','ILogService','_injector','constructor','UniverCollaborationPlugin','1648502tMtzkh','defineProperty','createSocket','8068270taOyuC','_configService','length','version','ISocketService','Plugin','Injector','6847600ftRVLq','message','WebSocket','CollaborationSocketService','UniverCollaborationClientPlugin','UniverLicensePlugin','COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY','341195BubLfH','8iISHcU','1182illznY','13110251qrqfzj','close','prototype','_httpService','DisposableCollection','share','decorate','next','pipe','UniverCollaborationClientNodePlugin','toStringTag','set','UniverNetworkPlugin','_doCreateSocket','getConfig','_config'];_0x10df=function(){return _0xb7afd2;};return _0x10df();}function g(_0x4bf737,_0x4cdbbe,_0x4fb80d){return(_0x4cdbbe=h(_0x4cdbbe))in _0x4bf737?Object['defineProperty'](_0x4bf737,_0x4cdbbe,{'value':_0x4fb80d,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x4bf737[_0x4cdbbe]=_0x4fb80d,_0x4bf737;}let _=class extends r[_0x1f11ae(0x201)]{constructor(_0x2e1fee=l,_0x1eb328,_0x48e5d1){const _0x10d0db=_0x1f11ae;super(),this['_config']=_0x2e1fee,this[_0x10d0db(0x1fd)]=_0x1eb328,this['_injector']=_0x48e5d1;let {..._0x253b16}=(0x0,r[_0x10d0db(0x1df)])({},l,this[_0x10d0db(0x21c)]);this[_0x10d0db(0x1fd)][_0x10d0db(0x21e)](_0x10d0db(0x1ef),_0x253b16);}['onStarting'](){this['_registerDependencies']();}['_registerDependencies'](){const _0x4735a8=_0x1f11ae;(0x0,r[_0x4735a8(0x1e4)])(this[_0x4735a8(0x1f6)],[[i[_0x4735a8(0x200)],{'useClass':f}]]);}};g(_,_0x1f11ae(0x21d),_0x1f11ae(0x224)),g(_,_0x1f11ae(0x1de),s),g(_,_0x1f11ae(0x1ff),c),_=d([(0x0,r['DependentOn'])(n[_0x1f11ae(0x208)],i[_0x1f11ae(0x219)],e[_0x1f11ae(0x1f8)],t[_0x1f11ae(0x207)]),u(0x1,r[_0x1f11ae(0x1eb)]),u(0x2,(0x0,r[_0x1f11ae(0x222)])(r[_0x1f11ae(0x202)]))],_);let v=class extends t[_0x1f11ae(0x206)]{constructor(_0x35bae6,_0x28762c,_0x495407,_0x3985e5,_0x1b3c23){const _0x577ffe=_0x1f11ae;super(_0x35bae6,_0x28762c,_0x495407,_0x3985e5,_0x1b3c23);let _0x228d37=this['_configService'][_0x577ffe(0x21b)](t[_0x577ffe(0x209)]);this[_0x577ffe(0x210)]['registerHTTPInterceptor']({'interceptor':(_0xfcf3fb,_0x53dc69)=>{const _0x4cb765=_0x577ffe;let _0x158657=_0xfcf3fb[_0x4cb765(0x1ed)];if(_0x228d37!=null&&_0x228d37['customHeaders']){for(let _0x1b63e2 in _0x228d37['customHeaders'])_0x158657[_0x4cb765(0x218)](_0x1b63e2,_0x228d37['customHeaders'][_0x1b63e2]);}return _0x53dc69(_0xfcf3fb);}});}async[_0x1f11ae(0x1fb)](_0x186c9f){const _0x3f0560=_0x1f11ae;return this[_0x3f0560(0x21a)](_0x186c9f);}};v=d([u(0x0,(0x0,r[_0x1f11ae(0x222)])(r['Injector'])),u(0x1,(0x0,r[_0x1f11ae(0x222)])(i[_0x1f11ae(0x1db)])),u(0x2,r[_0x1f11ae(0x1eb)]),u(0x3,r[_0x1f11ae(0x1f5)]),u(0x4,e[_0x1f11ae(0x1e0)])],v),Object[_0x1f11ae(0x1fa)](exports,_0x1f11ae(0x1e2),{'enumerable':!0x0,'get':function(){return v;}}),Object[_0x1f11ae(0x1fa)](exports,_0x1f11ae(0x216),{'enumerable':!0x0,'get':function(){return _;}});
package/lib/es/index.js CHANGED
@@ -1 +1 @@
1
- const _0x41e300=_0x3172;(function(_0x5ae645,_0x176beb){const _0x2f81e1=_0x3172,_0x1df91b=_0x5ae645();while(!![]){try{const _0x290d63=-parseInt(_0x2f81e1(0x90))/0x1*(-parseInt(_0x2f81e1(0x96))/0x2)+-parseInt(_0x2f81e1(0x85))/0x3*(parseInt(_0x2f81e1(0x9d))/0x4)+-parseInt(_0x2f81e1(0x93))/0x5+parseInt(_0x2f81e1(0x8c))/0x6+-parseInt(_0x2f81e1(0xa7))/0x7*(parseInt(_0x2f81e1(0x9e))/0x8)+-parseInt(_0x2f81e1(0x99))/0x9*(parseInt(_0x2f81e1(0x86))/0xa)+parseInt(_0x2f81e1(0xa8))/0xb*(parseInt(_0x2f81e1(0xac))/0xc);if(_0x290d63===_0x176beb)break;else _0x1df91b['push'](_0x1df91b['shift']());}catch(_0xd872ff){_0x1df91b['push'](_0x1df91b['shift']());}}}(_0x5ae8,0xdf205));import{ISnapshotServerService as _0x2a8abe,UniverCollaborationPlugin as _0x1ba687}from'@univerjs-pro/collaboration';import{COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY as _0x570415,CollaborationSocketService as _0x21dcb9,UniverCollaborationClientPlugin as _0xdf2d6}from'@univerjs-pro/collaboration-client';import{UniverLicensePlugin as _0x1292ea}from'@univerjs-pro/license';import{DependentOn as _0xf8bf16,Disposable as _0x290b84,DisposableCollection as _0xade28b,IConfigService as _0x11f0b3,ILogService as _0x3556ce,Inject as _0x3dd0dc,Injector as _0x5bb429,Plugin as _0x5ba7ba,merge as _0x5b05fc,registerDependencies as _0x9683c3,toDisposable as _0x2dd926}from'@univerjs/core';import{HTTPService as _0x3df89a,ISocketService as _0x21c2bf,UniverNetworkPlugin as _0xda6645}from'@univerjs/network';import{Observable as _0x4aad1d,share as _0x13d9c2}from'rxjs';import{WebSocket as _0x60ed4d}from'ws';var C='@univerjs-pro/collaboration-client-node',w='1.0.0-rc.0';const T={};function E(_0x2456b0,_0x414a12){return function(_0x5d6889,_0x3fc56d){_0x414a12(_0x5d6889,_0x3fc56d,_0x2456b0);};}function _0x5ae8(){const _0x5f5810=['onStarting','removeEventListener','open','203KHRvtA','11aGyhMU','string','_httpService','close','23388072wSjuCg','_configService','customHeaders','39PaRCwG','228400fPcjyb','headers','send','pipe','version','getConfig','7303218OivGZM','decorate','length','add','14WYmMsv','_doCreateSocket','error','4578975vUmGil','message','pluginName','104710ROTvaD','next','function','117KnEUUC','UNIVER_COLLABORATION_CLIENT_NODE_PLUGIN','_registerDependencies','symbol','501040tHYQtk','39768eHBrcx','addEventListener','dispose','constructor','packageName','object'];_0x5ae8=function(){return _0x5f5810;};return _0x5ae8();}function D(_0x412985,_0x2398f7,_0x3ae36d,_0x59c97a){const _0x1fcfda=_0x3172;var _0x193b75=arguments['length'],_0x268179=_0x193b75<0x3?_0x2398f7:_0x59c97a===null?_0x59c97a=Object['getOwnPropertyDescriptor'](_0x2398f7,_0x3ae36d):_0x59c97a,_0xea00dd;if(typeof Reflect=='object'&&typeof Reflect[_0x1fcfda(0x8d)]==_0x1fcfda(0x98))_0x268179=Reflect[_0x1fcfda(0x8d)](_0x412985,_0x2398f7,_0x3ae36d,_0x59c97a);else{for(var _0x6f4fa7=_0x412985[_0x1fcfda(0x8e)]-0x1;_0x6f4fa7>=0x0;_0x6f4fa7--)(_0xea00dd=_0x412985[_0x6f4fa7])&&(_0x268179=(_0x193b75<0x3?_0xea00dd(_0x268179):_0x193b75>0x3?_0xea00dd(_0x2398f7,_0x3ae36d,_0x268179):_0xea00dd(_0x2398f7,_0x3ae36d))||_0x268179);}return _0x193b75>0x3&&_0x268179&&Object['defineProperty'](_0x2398f7,_0x3ae36d,_0x268179),_0x268179;}let O=class extends _0x290b84{constructor(_0x68b8f0){const _0x25f06e=_0x3172;super(),this[_0x25f06e(0xad)]=_0x68b8f0;}['createSocket'](_0x2ec9ce){const _0x844586=_0x3172;var _0x19bb3b;let _0x2324b3=((_0x19bb3b=this['_configService'][_0x844586(0x8b)](_0x570415))==null?void 0x0:_0x19bb3b['customHeaders'])||{};try{let _0x5dbf79=new _0x60ed4d(_0x2ec9ce,{'headers':{..._0x2324b3}}),_0x4d60ce=new _0xade28b();return{'URL':_0x2ec9ce,'close':(_0x39d43b,_0x276af6)=>{const _0x3a3dc8=_0x844586;_0x5dbf79[_0x3a3dc8(0xab)](_0x39d43b,_0x276af6),_0x4d60ce[_0x3a3dc8(0xa0)]();},'send':_0x455fea=>{const _0x57f8b0=_0x844586;_0x5dbf79[_0x57f8b0(0x88)](_0x455fea);},'open$':new _0x4aad1d(_0x230a99=>{const _0x1b676d=_0x844586;let _0xe0afe3=_0x3e97c8=>_0x230a99['next'](_0x3e97c8);_0x5dbf79['addEventListener'](_0x1b676d(0xa6),_0xe0afe3),_0x4d60ce[_0x1b676d(0x8f)](_0x2dd926(()=>_0x5dbf79[_0x1b676d(0xa5)](_0x1b676d(0xa6),_0xe0afe3)));})[_0x844586(0x89)](_0x13d9c2()),'close$':new _0x4aad1d(_0x1b4db9=>{const _0x3301ce=_0x844586;let _0x21b289=_0x1940f9=>_0x1b4db9[_0x3301ce(0x97)](_0x1940f9);_0x5dbf79['addEventListener']('close',_0x21b289),_0x4d60ce[_0x3301ce(0x8f)](_0x2dd926(()=>_0x5dbf79[_0x3301ce(0xa5)]('close',_0x21b289)));})['pipe'](_0x13d9c2()),'error$':new _0x4aad1d(_0x4bfe44=>{const _0x93c0a0=_0x844586;let _0x1c1d1f=_0xd61569=>_0x4bfe44[_0x93c0a0(0x97)](_0xd61569);_0x5dbf79[_0x93c0a0(0x9f)](_0x93c0a0(0x92),_0x1c1d1f),_0x4d60ce['add'](_0x2dd926(()=>_0x5dbf79[_0x93c0a0(0xa5)](_0x93c0a0(0x92),_0x1c1d1f)));})[_0x844586(0x89)](_0x13d9c2()),'message$':new _0x4aad1d(_0xfb7f53=>{const _0xf78f2c=_0x844586;let _0x220dee=_0x34e9f7=>_0xfb7f53[_0xf78f2c(0x97)](_0x34e9f7);_0x5dbf79['addEventListener'](_0xf78f2c(0x94),_0x220dee),_0x4d60ce[_0xf78f2c(0x8f)](_0x2dd926(()=>_0x5dbf79[_0xf78f2c(0xa5)](_0xf78f2c(0x94),_0x220dee)));})['pipe'](_0x13d9c2())};}catch(_0x21f0e4){return console['error'](_0x21f0e4),null;}}};O=D([E(0x0,_0x11f0b3)],O);function k(_0x3dfa98){'@babel/helpers - typeof';const _0x5e8ef4=_0x3172;return k=typeof Symbol==_0x5e8ef4(0x98)&&typeof Symbol['iterator']=='symbol'?function(_0x40acb1){return typeof _0x40acb1;}:function(_0xead256){const _0x2c2521=_0x5e8ef4;return _0xead256&&typeof Symbol==_0x2c2521(0x98)&&_0xead256[_0x2c2521(0xa1)]===Symbol&&_0xead256!==Symbol['prototype']?'symbol':typeof _0xead256;},k(_0x3dfa98);}function A(_0x5ae429,_0x129d8a){const _0x548781=_0x3172;if(k(_0x5ae429)!=_0x548781(0xa3)||!_0x5ae429)return _0x5ae429;var _0x279197=_0x5ae429[Symbol['toPrimitive']];if(_0x279197!==void 0x0){var _0x4a6b94=_0x279197['call'](_0x5ae429,_0x129d8a||'default');if(k(_0x4a6b94)!=_0x548781(0xa3))return _0x4a6b94;throw TypeError('@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.');}return(_0x129d8a===_0x548781(0xa9)?String:Number)(_0x5ae429);}function _0x3172(_0x2da58c,_0x39d3c3){_0x2da58c=_0x2da58c-0x85;const _0x5ae81e=_0x5ae8();let _0x317281=_0x5ae81e[_0x2da58c];return _0x317281;}function j(_0x3afa2e){const _0x3fdb54=_0x3172;var _0x57e28c=A(_0x3afa2e,'string');return k(_0x57e28c)==_0x3fdb54(0x9c)?_0x57e28c:_0x57e28c+'';}function M(_0x322dc3,_0x19f448,_0x1d46ed){return(_0x19f448=j(_0x19f448))in _0x322dc3?Object['defineProperty'](_0x322dc3,_0x19f448,{'value':_0x1d46ed,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x322dc3[_0x19f448]=_0x1d46ed,_0x322dc3;}let N=class extends _0x5ba7ba{constructor(_0x4d3d26=T,_0x86267a,_0x59ce46){const _0xf7c7f8=_0x3172;super(),this['_config']=_0x4d3d26,this[_0xf7c7f8(0xad)]=_0x86267a,this['_injector']=_0x59ce46;let {..._0xc14034}=_0x5b05fc({},T,this['_config']);this[_0xf7c7f8(0xad)]['setConfig']('collaboration-client-node.config',_0xc14034);}[_0x41e300(0xa4)](){const _0x21b8a4=_0x41e300;this[_0x21b8a4(0x9b)]();}['_registerDependencies'](){_0x9683c3(this['_injector'],[[_0x21c2bf,{'useClass':O}]]);}};M(N,_0x41e300(0x95),_0x41e300(0x9a)),M(N,_0x41e300(0xa2),C),M(N,_0x41e300(0x8a),w),N=D([_0xf8bf16(_0x1292ea,_0xda6645,_0x1ba687,_0xdf2d6),E(0x1,_0x11f0b3),E(0x2,_0x3dd0dc(_0x5bb429))],N);let P=class extends _0x21dcb9{constructor(_0x411041,_0x3fa0ff,_0x52775f,_0x5f1dd5,_0x533595){const _0x535ef6=_0x41e300;super(_0x411041,_0x3fa0ff,_0x52775f,_0x5f1dd5,_0x533595);let _0x593fb=this[_0x535ef6(0xad)][_0x535ef6(0x8b)](_0x570415);this[_0x535ef6(0xaa)]['registerHTTPInterceptor']({'interceptor':(_0x310b56,_0x554580)=>{const _0x329e08=_0x535ef6;let _0x10823d=_0x310b56[_0x329e08(0x87)];if(_0x593fb!=null&&_0x593fb[_0x329e08(0xae)]){for(let _0x45e8e2 in _0x593fb[_0x329e08(0xae)])_0x10823d['set'](_0x45e8e2,_0x593fb[_0x329e08(0xae)][_0x45e8e2]);}return _0x554580(_0x310b56);}});}async['createSocket'](_0x44b8b7){const _0x4104dc=_0x41e300;return this[_0x4104dc(0x91)](_0x44b8b7);}};P=D([E(0x0,_0x3dd0dc(_0x5bb429)),E(0x1,_0x3dd0dc(_0x3df89a)),E(0x2,_0x11f0b3),E(0x3,_0x3556ce),E(0x4,_0x2a8abe)],P);export{P as NodeCollaborationSocketService,N as UniverCollaborationClientNodePlugin};
1
+ const _0x26056b=_0x4bf1;(function(_0x4d96a5,_0x4774df){const _0x5694e8=_0x4bf1,_0x164cdf=_0x4d96a5();while(!![]){try{const _0x4f0d87=parseInt(_0x5694e8(0xe7))/0x1*(-parseInt(_0x5694e8(0x105))/0x2)+-parseInt(_0x5694e8(0xe3))/0x3+-parseInt(_0x5694e8(0xf5))/0x4+parseInt(_0x5694e8(0x104))/0x5*(parseInt(_0x5694e8(0xf3))/0x6)+parseInt(_0x5694e8(0xf9))/0x7+-parseInt(_0x5694e8(0x10e))/0x8*(parseInt(_0x5694e8(0x103))/0x9)+parseInt(_0x5694e8(0x116))/0xa;if(_0x4f0d87===_0x4774df)break;else _0x164cdf['push'](_0x164cdf['shift']());}catch(_0x25c44f){_0x164cdf['push'](_0x164cdf['shift']());}}}(_0x3ff0,0x97a28));import{ISnapshotServerService as _0x20df64,UniverCollaborationPlugin as _0xdd7bdc}from'@univerjs-pro/collaboration';import{COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY as _0x41643a,CollaborationSocketService as _0x2d2aaa,UniverCollaborationClientPlugin as _0x5037e1}from'@univerjs-pro/collaboration-client';import{UniverLicensePlugin as _0x2f9883}from'@univerjs-pro/license';import{DependentOn as _0x51dcbe,Disposable as _0x5bc677,DisposableCollection as _0x4b3bbf,IConfigService as _0x4bbeeb,ILogService as _0x20f274,Inject as _0x47ae56,Injector as _0x334da3,Plugin as _0x2cb4d6,merge as _0x4bf80d,registerDependencies as _0x1b1b9e,toDisposable as _0x56cf8b}from'@univerjs/core';function _0x4bf1(_0x3ca98d,_0x2e75c6){_0x3ca98d=_0x3ca98d-0xe2;const _0x3ff01d=_0x3ff0();let _0x4bf1da=_0x3ff01d[_0x3ca98d];return _0x4bf1da;}import{HTTPService as _0x47f636,ISocketService as _0x1b47cb,UniverNetworkPlugin as _0xbcf9e9}from'@univerjs/network';import{Observable as _0x18856d,share as _0x1e6217}from'rxjs';import{WebSocket as _0x2da334}from'ws';var C=_0x26056b(0x10f),w=_0x26056b(0xef);const T={};function E(_0x26fd43,_0x858797){return function(_0x10e183,_0x2ed891){_0x858797(_0x10e183,_0x2ed891,_0x26fd43);};}function D(_0x288a90,_0x561e39,_0x2290e3,_0x3713a7){const _0x5cde53=_0x26056b;var _0x157974=arguments['length'],_0x35a45a=_0x157974<0x3?_0x561e39:_0x3713a7===null?_0x3713a7=Object[_0x5cde53(0xf2)](_0x561e39,_0x2290e3):_0x3713a7,_0x4b2c1f;if(typeof Reflect==_0x5cde53(0xf8)&&typeof Reflect[_0x5cde53(0x106)]==_0x5cde53(0x112))_0x35a45a=Reflect[_0x5cde53(0x106)](_0x288a90,_0x561e39,_0x2290e3,_0x3713a7);else{for(var _0x18e1ca=_0x288a90[_0x5cde53(0x108)]-0x1;_0x18e1ca>=0x0;_0x18e1ca--)(_0x4b2c1f=_0x288a90[_0x18e1ca])&&(_0x35a45a=(_0x157974<0x3?_0x4b2c1f(_0x35a45a):_0x157974>0x3?_0x4b2c1f(_0x561e39,_0x2290e3,_0x35a45a):_0x4b2c1f(_0x561e39,_0x2290e3))||_0x35a45a);}return _0x157974>0x3&&_0x35a45a&&Object[_0x5cde53(0xf4)](_0x561e39,_0x2290e3,_0x35a45a),_0x35a45a;}let O=class extends _0x5bc677{constructor(_0x4415fb){const _0x4b10ec=_0x26056b;super(),this[_0x4b10ec(0xff)]=_0x4415fb;}[_0x26056b(0x109)](_0x3b5c29){const _0x5990fe=_0x26056b;var _0x1180dc;let _0x4f7d57=((_0x1180dc=this[_0x5990fe(0xff)][_0x5990fe(0xe9)](_0x41643a))==null?void 0x0:_0x1180dc[_0x5990fe(0x10b)])||{};try{let _0x3f2f32=new _0x2da334(_0x3b5c29,{'headers':{..._0x4f7d57}}),_0x502bb7=new _0x4b3bbf();return{'URL':_0x3b5c29,'close':(_0x17b0b7,_0x58fc98)=>{const _0x344e24=_0x5990fe;_0x3f2f32[_0x344e24(0x110)](_0x17b0b7,_0x58fc98),_0x502bb7[_0x344e24(0xea)]();},'send':_0x451349=>{_0x3f2f32['send'](_0x451349);},'open$':new _0x18856d(_0x921071=>{const _0x30d7fe=_0x5990fe;let _0x5687f5=_0x30106b=>_0x921071[_0x30d7fe(0x111)](_0x30106b);_0x3f2f32['addEventListener'](_0x30d7fe(0xfb),_0x5687f5),_0x502bb7[_0x30d7fe(0xe2)](_0x56cf8b(()=>_0x3f2f32[_0x30d7fe(0x114)](_0x30d7fe(0xfb),_0x5687f5)));})[_0x5990fe(0x102)](_0x1e6217()),'close$':new _0x18856d(_0x44ea02=>{const _0x4c3191=_0x5990fe;let _0x511af7=_0x590286=>_0x44ea02[_0x4c3191(0x111)](_0x590286);_0x3f2f32[_0x4c3191(0x10d)](_0x4c3191(0x110),_0x511af7),_0x502bb7[_0x4c3191(0xe2)](_0x56cf8b(()=>_0x3f2f32['removeEventListener'](_0x4c3191(0x110),_0x511af7)));})[_0x5990fe(0x102)](_0x1e6217()),'error$':new _0x18856d(_0x196375=>{const _0x4df8a7=_0x5990fe;let _0x40c4a2=_0x22d218=>_0x196375[_0x4df8a7(0x111)](_0x22d218);_0x3f2f32[_0x4df8a7(0x10d)]('error',_0x40c4a2),_0x502bb7['add'](_0x56cf8b(()=>_0x3f2f32[_0x4df8a7(0x114)](_0x4df8a7(0x10a),_0x40c4a2)));})['pipe'](_0x1e6217()),'message$':new _0x18856d(_0x112f9a=>{const _0x1e891e=_0x5990fe;let _0x2ca950=_0x5bfd1e=>_0x112f9a['next'](_0x5bfd1e);_0x3f2f32[_0x1e891e(0x10d)](_0x1e891e(0xed),_0x2ca950),_0x502bb7[_0x1e891e(0xe2)](_0x56cf8b(()=>_0x3f2f32[_0x1e891e(0x114)](_0x1e891e(0xed),_0x2ca950)));})[_0x5990fe(0x102)](_0x1e6217())};}catch(_0x26381f){return console[_0x5990fe(0x10a)](_0x26381f),null;}}};function _0x3ff0(){const _0x398f18=['registerHTTPInterceptor','_config','object','8478323iqUaEk','version','open','UNIVER_COLLABORATION_CLIENT_NODE_PLUGIN','set','string','_configService','packageName','_httpService','pipe','18MyBXhz','877805IursMI','853266dLluHH','decorate','headers','length','createSocket','error','customHeaders','toPrimitive','addEventListener','4055456JrvDxa','@univerjs-pro/collaboration-client-node','close','next','function','collaboration-client-node.config','removeEventListener','symbol','11841880vImuel','add','2640231yEhkFi','_registerDependencies','default','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','1LlenlB','constructor','getConfig','dispose','onStarting','prototype','message','setConfig','1.0.1','pluginName','call','getOwnPropertyDescriptor','24uBFFKm','defineProperty','623804bgzhZc'];_0x3ff0=function(){return _0x398f18;};return _0x3ff0();}O=D([E(0x0,_0x4bbeeb)],O);function k(_0x1a960f){'@babel/helpers - typeof';const _0x32c61c=_0x26056b;return k=typeof Symbol==_0x32c61c(0x112)&&typeof Symbol['iterator']==_0x32c61c(0x115)?function(_0x6a9ab2){return typeof _0x6a9ab2;}:function(_0x15b846){const _0x7a72a2=_0x32c61c;return _0x15b846&&typeof Symbol=='function'&&_0x15b846[_0x7a72a2(0xe8)]===Symbol&&_0x15b846!==Symbol[_0x7a72a2(0xec)]?_0x7a72a2(0x115):typeof _0x15b846;},k(_0x1a960f);}function A(_0x506547,_0x4a6898){const _0x433bc3=_0x26056b;if(k(_0x506547)!=_0x433bc3(0xf8)||!_0x506547)return _0x506547;var _0x5236f3=_0x506547[Symbol[_0x433bc3(0x10c)]];if(_0x5236f3!==void 0x0){var _0x4e5512=_0x5236f3[_0x433bc3(0xf1)](_0x506547,_0x4a6898||_0x433bc3(0xe5));if(k(_0x4e5512)!=_0x433bc3(0xf8))return _0x4e5512;throw TypeError(_0x433bc3(0xe6));}return(_0x4a6898===_0x433bc3(0xfe)?String:Number)(_0x506547);}function j(_0x524bff){const _0x163722=_0x26056b;var _0x518339=A(_0x524bff,_0x163722(0xfe));return k(_0x518339)=='symbol'?_0x518339:_0x518339+'';}function M(_0x374ebf,_0x2b18f0,_0x86a5b1){return(_0x2b18f0=j(_0x2b18f0))in _0x374ebf?Object['defineProperty'](_0x374ebf,_0x2b18f0,{'value':_0x86a5b1,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x374ebf[_0x2b18f0]=_0x86a5b1,_0x374ebf;}let N=class extends _0x2cb4d6{constructor(_0x414ed4=T,_0x1f5195,_0x5375a5){const _0x427e6=_0x26056b;super(),this[_0x427e6(0xf7)]=_0x414ed4,this['_configService']=_0x1f5195,this['_injector']=_0x5375a5;let {..._0x34f2e0}=_0x4bf80d({},T,this[_0x427e6(0xf7)]);this[_0x427e6(0xff)][_0x427e6(0xee)](_0x427e6(0x113),_0x34f2e0);}[_0x26056b(0xeb)](){const _0x3d4d63=_0x26056b;this[_0x3d4d63(0xe4)]();}[_0x26056b(0xe4)](){_0x1b1b9e(this['_injector'],[[_0x1b47cb,{'useClass':O}]]);}};M(N,_0x26056b(0xf0),_0x26056b(0xfc)),M(N,_0x26056b(0x100),C),M(N,_0x26056b(0xfa),w),N=D([_0x51dcbe(_0x2f9883,_0xbcf9e9,_0xdd7bdc,_0x5037e1),E(0x1,_0x4bbeeb),E(0x2,_0x47ae56(_0x334da3))],N);let P=class extends _0x2d2aaa{constructor(_0x3c0c0d,_0x2f7399,_0x2f747d,_0x1f2c3a,_0x276bda){const _0x317257=_0x26056b;super(_0x3c0c0d,_0x2f7399,_0x2f747d,_0x1f2c3a,_0x276bda);let _0x23b93c=this[_0x317257(0xff)]['getConfig'](_0x41643a);this[_0x317257(0x101)][_0x317257(0xf6)]({'interceptor':(_0xd1d4d1,_0x5b2619)=>{const _0x3da4ec=_0x317257;let _0x543210=_0xd1d4d1[_0x3da4ec(0x107)];if(_0x23b93c!=null&&_0x23b93c[_0x3da4ec(0x10b)]){for(let _0x518d6b in _0x23b93c[_0x3da4ec(0x10b)])_0x543210[_0x3da4ec(0xfd)](_0x518d6b,_0x23b93c[_0x3da4ec(0x10b)][_0x518d6b]);}return _0x5b2619(_0xd1d4d1);}});}async[_0x26056b(0x109)](_0x3acaf1){return this['_doCreateSocket'](_0x3acaf1);}};P=D([E(0x0,_0x47ae56(_0x334da3)),E(0x1,_0x47ae56(_0x47f636)),E(0x2,_0x4bbeeb),E(0x3,_0x20f274),E(0x4,_0x20df64)],P);export{P as NodeCollaborationSocketService,N as UniverCollaborationClientNodePlugin};
package/lib/index.js CHANGED
@@ -1 +1 @@
1
- const _0x41e300=_0x3172;(function(_0x5ae645,_0x176beb){const _0x2f81e1=_0x3172,_0x1df91b=_0x5ae645();while(!![]){try{const _0x290d63=-parseInt(_0x2f81e1(0x90))/0x1*(-parseInt(_0x2f81e1(0x96))/0x2)+-parseInt(_0x2f81e1(0x85))/0x3*(parseInt(_0x2f81e1(0x9d))/0x4)+-parseInt(_0x2f81e1(0x93))/0x5+parseInt(_0x2f81e1(0x8c))/0x6+-parseInt(_0x2f81e1(0xa7))/0x7*(parseInt(_0x2f81e1(0x9e))/0x8)+-parseInt(_0x2f81e1(0x99))/0x9*(parseInt(_0x2f81e1(0x86))/0xa)+parseInt(_0x2f81e1(0xa8))/0xb*(parseInt(_0x2f81e1(0xac))/0xc);if(_0x290d63===_0x176beb)break;else _0x1df91b['push'](_0x1df91b['shift']());}catch(_0xd872ff){_0x1df91b['push'](_0x1df91b['shift']());}}}(_0x5ae8,0xdf205));import{ISnapshotServerService as _0x2a8abe,UniverCollaborationPlugin as _0x1ba687}from'@univerjs-pro/collaboration';import{COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY as _0x570415,CollaborationSocketService as _0x21dcb9,UniverCollaborationClientPlugin as _0xdf2d6}from'@univerjs-pro/collaboration-client';import{UniverLicensePlugin as _0x1292ea}from'@univerjs-pro/license';import{DependentOn as _0xf8bf16,Disposable as _0x290b84,DisposableCollection as _0xade28b,IConfigService as _0x11f0b3,ILogService as _0x3556ce,Inject as _0x3dd0dc,Injector as _0x5bb429,Plugin as _0x5ba7ba,merge as _0x5b05fc,registerDependencies as _0x9683c3,toDisposable as _0x2dd926}from'@univerjs/core';import{HTTPService as _0x3df89a,ISocketService as _0x21c2bf,UniverNetworkPlugin as _0xda6645}from'@univerjs/network';import{Observable as _0x4aad1d,share as _0x13d9c2}from'rxjs';import{WebSocket as _0x60ed4d}from'ws';var C='@univerjs-pro/collaboration-client-node',w='1.0.0-rc.0';const T={};function E(_0x2456b0,_0x414a12){return function(_0x5d6889,_0x3fc56d){_0x414a12(_0x5d6889,_0x3fc56d,_0x2456b0);};}function _0x5ae8(){const _0x5f5810=['onStarting','removeEventListener','open','203KHRvtA','11aGyhMU','string','_httpService','close','23388072wSjuCg','_configService','customHeaders','39PaRCwG','228400fPcjyb','headers','send','pipe','version','getConfig','7303218OivGZM','decorate','length','add','14WYmMsv','_doCreateSocket','error','4578975vUmGil','message','pluginName','104710ROTvaD','next','function','117KnEUUC','UNIVER_COLLABORATION_CLIENT_NODE_PLUGIN','_registerDependencies','symbol','501040tHYQtk','39768eHBrcx','addEventListener','dispose','constructor','packageName','object'];_0x5ae8=function(){return _0x5f5810;};return _0x5ae8();}function D(_0x412985,_0x2398f7,_0x3ae36d,_0x59c97a){const _0x1fcfda=_0x3172;var _0x193b75=arguments['length'],_0x268179=_0x193b75<0x3?_0x2398f7:_0x59c97a===null?_0x59c97a=Object['getOwnPropertyDescriptor'](_0x2398f7,_0x3ae36d):_0x59c97a,_0xea00dd;if(typeof Reflect=='object'&&typeof Reflect[_0x1fcfda(0x8d)]==_0x1fcfda(0x98))_0x268179=Reflect[_0x1fcfda(0x8d)](_0x412985,_0x2398f7,_0x3ae36d,_0x59c97a);else{for(var _0x6f4fa7=_0x412985[_0x1fcfda(0x8e)]-0x1;_0x6f4fa7>=0x0;_0x6f4fa7--)(_0xea00dd=_0x412985[_0x6f4fa7])&&(_0x268179=(_0x193b75<0x3?_0xea00dd(_0x268179):_0x193b75>0x3?_0xea00dd(_0x2398f7,_0x3ae36d,_0x268179):_0xea00dd(_0x2398f7,_0x3ae36d))||_0x268179);}return _0x193b75>0x3&&_0x268179&&Object['defineProperty'](_0x2398f7,_0x3ae36d,_0x268179),_0x268179;}let O=class extends _0x290b84{constructor(_0x68b8f0){const _0x25f06e=_0x3172;super(),this[_0x25f06e(0xad)]=_0x68b8f0;}['createSocket'](_0x2ec9ce){const _0x844586=_0x3172;var _0x19bb3b;let _0x2324b3=((_0x19bb3b=this['_configService'][_0x844586(0x8b)](_0x570415))==null?void 0x0:_0x19bb3b['customHeaders'])||{};try{let _0x5dbf79=new _0x60ed4d(_0x2ec9ce,{'headers':{..._0x2324b3}}),_0x4d60ce=new _0xade28b();return{'URL':_0x2ec9ce,'close':(_0x39d43b,_0x276af6)=>{const _0x3a3dc8=_0x844586;_0x5dbf79[_0x3a3dc8(0xab)](_0x39d43b,_0x276af6),_0x4d60ce[_0x3a3dc8(0xa0)]();},'send':_0x455fea=>{const _0x57f8b0=_0x844586;_0x5dbf79[_0x57f8b0(0x88)](_0x455fea);},'open$':new _0x4aad1d(_0x230a99=>{const _0x1b676d=_0x844586;let _0xe0afe3=_0x3e97c8=>_0x230a99['next'](_0x3e97c8);_0x5dbf79['addEventListener'](_0x1b676d(0xa6),_0xe0afe3),_0x4d60ce[_0x1b676d(0x8f)](_0x2dd926(()=>_0x5dbf79[_0x1b676d(0xa5)](_0x1b676d(0xa6),_0xe0afe3)));})[_0x844586(0x89)](_0x13d9c2()),'close$':new _0x4aad1d(_0x1b4db9=>{const _0x3301ce=_0x844586;let _0x21b289=_0x1940f9=>_0x1b4db9[_0x3301ce(0x97)](_0x1940f9);_0x5dbf79['addEventListener']('close',_0x21b289),_0x4d60ce[_0x3301ce(0x8f)](_0x2dd926(()=>_0x5dbf79[_0x3301ce(0xa5)]('close',_0x21b289)));})['pipe'](_0x13d9c2()),'error$':new _0x4aad1d(_0x4bfe44=>{const _0x93c0a0=_0x844586;let _0x1c1d1f=_0xd61569=>_0x4bfe44[_0x93c0a0(0x97)](_0xd61569);_0x5dbf79[_0x93c0a0(0x9f)](_0x93c0a0(0x92),_0x1c1d1f),_0x4d60ce['add'](_0x2dd926(()=>_0x5dbf79[_0x93c0a0(0xa5)](_0x93c0a0(0x92),_0x1c1d1f)));})[_0x844586(0x89)](_0x13d9c2()),'message$':new _0x4aad1d(_0xfb7f53=>{const _0xf78f2c=_0x844586;let _0x220dee=_0x34e9f7=>_0xfb7f53[_0xf78f2c(0x97)](_0x34e9f7);_0x5dbf79['addEventListener'](_0xf78f2c(0x94),_0x220dee),_0x4d60ce[_0xf78f2c(0x8f)](_0x2dd926(()=>_0x5dbf79[_0xf78f2c(0xa5)](_0xf78f2c(0x94),_0x220dee)));})['pipe'](_0x13d9c2())};}catch(_0x21f0e4){return console['error'](_0x21f0e4),null;}}};O=D([E(0x0,_0x11f0b3)],O);function k(_0x3dfa98){'@babel/helpers - typeof';const _0x5e8ef4=_0x3172;return k=typeof Symbol==_0x5e8ef4(0x98)&&typeof Symbol['iterator']=='symbol'?function(_0x40acb1){return typeof _0x40acb1;}:function(_0xead256){const _0x2c2521=_0x5e8ef4;return _0xead256&&typeof Symbol==_0x2c2521(0x98)&&_0xead256[_0x2c2521(0xa1)]===Symbol&&_0xead256!==Symbol['prototype']?'symbol':typeof _0xead256;},k(_0x3dfa98);}function A(_0x5ae429,_0x129d8a){const _0x548781=_0x3172;if(k(_0x5ae429)!=_0x548781(0xa3)||!_0x5ae429)return _0x5ae429;var _0x279197=_0x5ae429[Symbol['toPrimitive']];if(_0x279197!==void 0x0){var _0x4a6b94=_0x279197['call'](_0x5ae429,_0x129d8a||'default');if(k(_0x4a6b94)!=_0x548781(0xa3))return _0x4a6b94;throw TypeError('@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.');}return(_0x129d8a===_0x548781(0xa9)?String:Number)(_0x5ae429);}function _0x3172(_0x2da58c,_0x39d3c3){_0x2da58c=_0x2da58c-0x85;const _0x5ae81e=_0x5ae8();let _0x317281=_0x5ae81e[_0x2da58c];return _0x317281;}function j(_0x3afa2e){const _0x3fdb54=_0x3172;var _0x57e28c=A(_0x3afa2e,'string');return k(_0x57e28c)==_0x3fdb54(0x9c)?_0x57e28c:_0x57e28c+'';}function M(_0x322dc3,_0x19f448,_0x1d46ed){return(_0x19f448=j(_0x19f448))in _0x322dc3?Object['defineProperty'](_0x322dc3,_0x19f448,{'value':_0x1d46ed,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x322dc3[_0x19f448]=_0x1d46ed,_0x322dc3;}let N=class extends _0x5ba7ba{constructor(_0x4d3d26=T,_0x86267a,_0x59ce46){const _0xf7c7f8=_0x3172;super(),this['_config']=_0x4d3d26,this[_0xf7c7f8(0xad)]=_0x86267a,this['_injector']=_0x59ce46;let {..._0xc14034}=_0x5b05fc({},T,this['_config']);this[_0xf7c7f8(0xad)]['setConfig']('collaboration-client-node.config',_0xc14034);}[_0x41e300(0xa4)](){const _0x21b8a4=_0x41e300;this[_0x21b8a4(0x9b)]();}['_registerDependencies'](){_0x9683c3(this['_injector'],[[_0x21c2bf,{'useClass':O}]]);}};M(N,_0x41e300(0x95),_0x41e300(0x9a)),M(N,_0x41e300(0xa2),C),M(N,_0x41e300(0x8a),w),N=D([_0xf8bf16(_0x1292ea,_0xda6645,_0x1ba687,_0xdf2d6),E(0x1,_0x11f0b3),E(0x2,_0x3dd0dc(_0x5bb429))],N);let P=class extends _0x21dcb9{constructor(_0x411041,_0x3fa0ff,_0x52775f,_0x5f1dd5,_0x533595){const _0x535ef6=_0x41e300;super(_0x411041,_0x3fa0ff,_0x52775f,_0x5f1dd5,_0x533595);let _0x593fb=this[_0x535ef6(0xad)][_0x535ef6(0x8b)](_0x570415);this[_0x535ef6(0xaa)]['registerHTTPInterceptor']({'interceptor':(_0x310b56,_0x554580)=>{const _0x329e08=_0x535ef6;let _0x10823d=_0x310b56[_0x329e08(0x87)];if(_0x593fb!=null&&_0x593fb[_0x329e08(0xae)]){for(let _0x45e8e2 in _0x593fb[_0x329e08(0xae)])_0x10823d['set'](_0x45e8e2,_0x593fb[_0x329e08(0xae)][_0x45e8e2]);}return _0x554580(_0x310b56);}});}async['createSocket'](_0x44b8b7){const _0x4104dc=_0x41e300;return this[_0x4104dc(0x91)](_0x44b8b7);}};P=D([E(0x0,_0x3dd0dc(_0x5bb429)),E(0x1,_0x3dd0dc(_0x3df89a)),E(0x2,_0x11f0b3),E(0x3,_0x3556ce),E(0x4,_0x2a8abe)],P);export{P as NodeCollaborationSocketService,N as UniverCollaborationClientNodePlugin};
1
+ const _0x26056b=_0x4bf1;(function(_0x4d96a5,_0x4774df){const _0x5694e8=_0x4bf1,_0x164cdf=_0x4d96a5();while(!![]){try{const _0x4f0d87=parseInt(_0x5694e8(0xe7))/0x1*(-parseInt(_0x5694e8(0x105))/0x2)+-parseInt(_0x5694e8(0xe3))/0x3+-parseInt(_0x5694e8(0xf5))/0x4+parseInt(_0x5694e8(0x104))/0x5*(parseInt(_0x5694e8(0xf3))/0x6)+parseInt(_0x5694e8(0xf9))/0x7+-parseInt(_0x5694e8(0x10e))/0x8*(parseInt(_0x5694e8(0x103))/0x9)+parseInt(_0x5694e8(0x116))/0xa;if(_0x4f0d87===_0x4774df)break;else _0x164cdf['push'](_0x164cdf['shift']());}catch(_0x25c44f){_0x164cdf['push'](_0x164cdf['shift']());}}}(_0x3ff0,0x97a28));import{ISnapshotServerService as _0x20df64,UniverCollaborationPlugin as _0xdd7bdc}from'@univerjs-pro/collaboration';import{COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY as _0x41643a,CollaborationSocketService as _0x2d2aaa,UniverCollaborationClientPlugin as _0x5037e1}from'@univerjs-pro/collaboration-client';import{UniverLicensePlugin as _0x2f9883}from'@univerjs-pro/license';import{DependentOn as _0x51dcbe,Disposable as _0x5bc677,DisposableCollection as _0x4b3bbf,IConfigService as _0x4bbeeb,ILogService as _0x20f274,Inject as _0x47ae56,Injector as _0x334da3,Plugin as _0x2cb4d6,merge as _0x4bf80d,registerDependencies as _0x1b1b9e,toDisposable as _0x56cf8b}from'@univerjs/core';function _0x4bf1(_0x3ca98d,_0x2e75c6){_0x3ca98d=_0x3ca98d-0xe2;const _0x3ff01d=_0x3ff0();let _0x4bf1da=_0x3ff01d[_0x3ca98d];return _0x4bf1da;}import{HTTPService as _0x47f636,ISocketService as _0x1b47cb,UniverNetworkPlugin as _0xbcf9e9}from'@univerjs/network';import{Observable as _0x18856d,share as _0x1e6217}from'rxjs';import{WebSocket as _0x2da334}from'ws';var C=_0x26056b(0x10f),w=_0x26056b(0xef);const T={};function E(_0x26fd43,_0x858797){return function(_0x10e183,_0x2ed891){_0x858797(_0x10e183,_0x2ed891,_0x26fd43);};}function D(_0x288a90,_0x561e39,_0x2290e3,_0x3713a7){const _0x5cde53=_0x26056b;var _0x157974=arguments['length'],_0x35a45a=_0x157974<0x3?_0x561e39:_0x3713a7===null?_0x3713a7=Object[_0x5cde53(0xf2)](_0x561e39,_0x2290e3):_0x3713a7,_0x4b2c1f;if(typeof Reflect==_0x5cde53(0xf8)&&typeof Reflect[_0x5cde53(0x106)]==_0x5cde53(0x112))_0x35a45a=Reflect[_0x5cde53(0x106)](_0x288a90,_0x561e39,_0x2290e3,_0x3713a7);else{for(var _0x18e1ca=_0x288a90[_0x5cde53(0x108)]-0x1;_0x18e1ca>=0x0;_0x18e1ca--)(_0x4b2c1f=_0x288a90[_0x18e1ca])&&(_0x35a45a=(_0x157974<0x3?_0x4b2c1f(_0x35a45a):_0x157974>0x3?_0x4b2c1f(_0x561e39,_0x2290e3,_0x35a45a):_0x4b2c1f(_0x561e39,_0x2290e3))||_0x35a45a);}return _0x157974>0x3&&_0x35a45a&&Object[_0x5cde53(0xf4)](_0x561e39,_0x2290e3,_0x35a45a),_0x35a45a;}let O=class extends _0x5bc677{constructor(_0x4415fb){const _0x4b10ec=_0x26056b;super(),this[_0x4b10ec(0xff)]=_0x4415fb;}[_0x26056b(0x109)](_0x3b5c29){const _0x5990fe=_0x26056b;var _0x1180dc;let _0x4f7d57=((_0x1180dc=this[_0x5990fe(0xff)][_0x5990fe(0xe9)](_0x41643a))==null?void 0x0:_0x1180dc[_0x5990fe(0x10b)])||{};try{let _0x3f2f32=new _0x2da334(_0x3b5c29,{'headers':{..._0x4f7d57}}),_0x502bb7=new _0x4b3bbf();return{'URL':_0x3b5c29,'close':(_0x17b0b7,_0x58fc98)=>{const _0x344e24=_0x5990fe;_0x3f2f32[_0x344e24(0x110)](_0x17b0b7,_0x58fc98),_0x502bb7[_0x344e24(0xea)]();},'send':_0x451349=>{_0x3f2f32['send'](_0x451349);},'open$':new _0x18856d(_0x921071=>{const _0x30d7fe=_0x5990fe;let _0x5687f5=_0x30106b=>_0x921071[_0x30d7fe(0x111)](_0x30106b);_0x3f2f32['addEventListener'](_0x30d7fe(0xfb),_0x5687f5),_0x502bb7[_0x30d7fe(0xe2)](_0x56cf8b(()=>_0x3f2f32[_0x30d7fe(0x114)](_0x30d7fe(0xfb),_0x5687f5)));})[_0x5990fe(0x102)](_0x1e6217()),'close$':new _0x18856d(_0x44ea02=>{const _0x4c3191=_0x5990fe;let _0x511af7=_0x590286=>_0x44ea02[_0x4c3191(0x111)](_0x590286);_0x3f2f32[_0x4c3191(0x10d)](_0x4c3191(0x110),_0x511af7),_0x502bb7[_0x4c3191(0xe2)](_0x56cf8b(()=>_0x3f2f32['removeEventListener'](_0x4c3191(0x110),_0x511af7)));})[_0x5990fe(0x102)](_0x1e6217()),'error$':new _0x18856d(_0x196375=>{const _0x4df8a7=_0x5990fe;let _0x40c4a2=_0x22d218=>_0x196375[_0x4df8a7(0x111)](_0x22d218);_0x3f2f32[_0x4df8a7(0x10d)]('error',_0x40c4a2),_0x502bb7['add'](_0x56cf8b(()=>_0x3f2f32[_0x4df8a7(0x114)](_0x4df8a7(0x10a),_0x40c4a2)));})['pipe'](_0x1e6217()),'message$':new _0x18856d(_0x112f9a=>{const _0x1e891e=_0x5990fe;let _0x2ca950=_0x5bfd1e=>_0x112f9a['next'](_0x5bfd1e);_0x3f2f32[_0x1e891e(0x10d)](_0x1e891e(0xed),_0x2ca950),_0x502bb7[_0x1e891e(0xe2)](_0x56cf8b(()=>_0x3f2f32[_0x1e891e(0x114)](_0x1e891e(0xed),_0x2ca950)));})[_0x5990fe(0x102)](_0x1e6217())};}catch(_0x26381f){return console[_0x5990fe(0x10a)](_0x26381f),null;}}};function _0x3ff0(){const _0x398f18=['registerHTTPInterceptor','_config','object','8478323iqUaEk','version','open','UNIVER_COLLABORATION_CLIENT_NODE_PLUGIN','set','string','_configService','packageName','_httpService','pipe','18MyBXhz','877805IursMI','853266dLluHH','decorate','headers','length','createSocket','error','customHeaders','toPrimitive','addEventListener','4055456JrvDxa','@univerjs-pro/collaboration-client-node','close','next','function','collaboration-client-node.config','removeEventListener','symbol','11841880vImuel','add','2640231yEhkFi','_registerDependencies','default','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','1LlenlB','constructor','getConfig','dispose','onStarting','prototype','message','setConfig','1.0.1','pluginName','call','getOwnPropertyDescriptor','24uBFFKm','defineProperty','623804bgzhZc'];_0x3ff0=function(){return _0x398f18;};return _0x3ff0();}O=D([E(0x0,_0x4bbeeb)],O);function k(_0x1a960f){'@babel/helpers - typeof';const _0x32c61c=_0x26056b;return k=typeof Symbol==_0x32c61c(0x112)&&typeof Symbol['iterator']==_0x32c61c(0x115)?function(_0x6a9ab2){return typeof _0x6a9ab2;}:function(_0x15b846){const _0x7a72a2=_0x32c61c;return _0x15b846&&typeof Symbol=='function'&&_0x15b846[_0x7a72a2(0xe8)]===Symbol&&_0x15b846!==Symbol[_0x7a72a2(0xec)]?_0x7a72a2(0x115):typeof _0x15b846;},k(_0x1a960f);}function A(_0x506547,_0x4a6898){const _0x433bc3=_0x26056b;if(k(_0x506547)!=_0x433bc3(0xf8)||!_0x506547)return _0x506547;var _0x5236f3=_0x506547[Symbol[_0x433bc3(0x10c)]];if(_0x5236f3!==void 0x0){var _0x4e5512=_0x5236f3[_0x433bc3(0xf1)](_0x506547,_0x4a6898||_0x433bc3(0xe5));if(k(_0x4e5512)!=_0x433bc3(0xf8))return _0x4e5512;throw TypeError(_0x433bc3(0xe6));}return(_0x4a6898===_0x433bc3(0xfe)?String:Number)(_0x506547);}function j(_0x524bff){const _0x163722=_0x26056b;var _0x518339=A(_0x524bff,_0x163722(0xfe));return k(_0x518339)=='symbol'?_0x518339:_0x518339+'';}function M(_0x374ebf,_0x2b18f0,_0x86a5b1){return(_0x2b18f0=j(_0x2b18f0))in _0x374ebf?Object['defineProperty'](_0x374ebf,_0x2b18f0,{'value':_0x86a5b1,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x374ebf[_0x2b18f0]=_0x86a5b1,_0x374ebf;}let N=class extends _0x2cb4d6{constructor(_0x414ed4=T,_0x1f5195,_0x5375a5){const _0x427e6=_0x26056b;super(),this[_0x427e6(0xf7)]=_0x414ed4,this['_configService']=_0x1f5195,this['_injector']=_0x5375a5;let {..._0x34f2e0}=_0x4bf80d({},T,this[_0x427e6(0xf7)]);this[_0x427e6(0xff)][_0x427e6(0xee)](_0x427e6(0x113),_0x34f2e0);}[_0x26056b(0xeb)](){const _0x3d4d63=_0x26056b;this[_0x3d4d63(0xe4)]();}[_0x26056b(0xe4)](){_0x1b1b9e(this['_injector'],[[_0x1b47cb,{'useClass':O}]]);}};M(N,_0x26056b(0xf0),_0x26056b(0xfc)),M(N,_0x26056b(0x100),C),M(N,_0x26056b(0xfa),w),N=D([_0x51dcbe(_0x2f9883,_0xbcf9e9,_0xdd7bdc,_0x5037e1),E(0x1,_0x4bbeeb),E(0x2,_0x47ae56(_0x334da3))],N);let P=class extends _0x2d2aaa{constructor(_0x3c0c0d,_0x2f7399,_0x2f747d,_0x1f2c3a,_0x276bda){const _0x317257=_0x26056b;super(_0x3c0c0d,_0x2f7399,_0x2f747d,_0x1f2c3a,_0x276bda);let _0x23b93c=this[_0x317257(0xff)]['getConfig'](_0x41643a);this[_0x317257(0x101)][_0x317257(0xf6)]({'interceptor':(_0xd1d4d1,_0x5b2619)=>{const _0x3da4ec=_0x317257;let _0x543210=_0xd1d4d1[_0x3da4ec(0x107)];if(_0x23b93c!=null&&_0x23b93c[_0x3da4ec(0x10b)]){for(let _0x518d6b in _0x23b93c[_0x3da4ec(0x10b)])_0x543210[_0x3da4ec(0xfd)](_0x518d6b,_0x23b93c[_0x3da4ec(0x10b)][_0x518d6b]);}return _0x5b2619(_0xd1d4d1);}});}async[_0x26056b(0x109)](_0x3acaf1){return this['_doCreateSocket'](_0x3acaf1);}};P=D([E(0x0,_0x47ae56(_0x334da3)),E(0x1,_0x47ae56(_0x47f636)),E(0x2,_0x4bbeeb),E(0x3,_0x20f274),E(0x4,_0x20df64)],P);export{P as NodeCollaborationSocketService,N as UniverCollaborationClientNodePlugin};
package/lib/umd/index.js CHANGED
@@ -1 +1 @@
1
- function _0x5e80(_0x221563,_0x3a7647){_0x221563=_0x221563-0x1ca;const _0x280aab=_0x280a();let _0x5e8042=_0x280aab[_0x221563];return _0x5e8042;}function _0x280a(){const _0x282294=['Injector','removeEventListener','customHeaders','Plugin','set','1582mbGgHT','getConfig','@univerjs-pro/collaboration-client','UniverProCollaborationClient','Inject','add','string','setConfig','Disposable','UniverCore','@univerjs-pro/collaboration-client-node','_registerDependencies','DisposableCollection','length','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','prototype','collaboration-client-node.config','_doCreateSocket','WebSocket','call','merge','pluginName','version','4308ffzlIs','1220urKHHL','share','UniverNetwork','_configService','iterator','IConfigService','constructor','onStarting','@univerjs/core','NodeCollaborationSocketService','registerDependencies','3163932Jakfeh','rxjs','toDisposable','function','1450YlBjgK','ISocketService','HTTPService','createSocket','18CfJTZT','4494120JJTZOE','decorate','@univerjs-pro/license','_config','1153mOTeBz','ISnapshotServerService','_injector','COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY','open','4025vqfiYR','ILogService','send','object','517GIySTQ','UniverCollaborationPlugin','dispose','registerHTTPInterceptor','defineProperty','Module','exports','message','error','22734VnSnqk','_httpService','addEventListener','next','toStringTag','close','Observable','UniverLicensePlugin','2056663uHwPZL','CollaborationSocketService','pipe','symbol','getOwnPropertyDescriptor','DependentOn','UniverProCollaboration'];_0x280a=function(){return _0x282294;};return _0x280a();}(function(_0x5180ea,_0x49ae76){const _0x1324e6=_0x5e80,_0x338729=_0x5180ea();while(!![]){try{const _0x2174aa=-parseInt(_0x1324e6(0x20d))/0x1*(parseInt(_0x1324e6(0x1dd))/0x2)+parseInt(_0x1324e6(0x200))/0x3+-parseInt(_0x1324e6(0x1f5))/0x4*(parseInt(_0x1324e6(0x212))/0x5)+-parseInt(_0x1324e6(0x208))/0x6*(-parseInt(_0x1324e6(0x1d1))/0x7)+-parseInt(_0x1324e6(0x209))/0x8+parseInt(_0x1324e6(0x21f))/0x9*(parseInt(_0x1324e6(0x204))/0xa)+parseInt(_0x1324e6(0x216))/0xb*(-parseInt(_0x1324e6(0x1f4))/0xc);if(_0x2174aa===_0x49ae76)break;else _0x338729['push'](_0x338729['shift']());}catch(_0x3ace7e){_0x338729['push'](_0x338729['shift']());}}}(_0x280a,0x8a38b),function(_0x56aad6,_0x2e1377){const _0x1da652=_0x5e80;typeof exports==_0x1da652(0x215)&&typeof module<'u'?_0x2e1377(exports,require('@univerjs-pro/collaboration'),require('@univerjs-pro/collaboration-client'),require('@univerjs-pro/license'),require('@univerjs/core'),require('@univerjs/network'),require('rxjs')):typeof define==_0x1da652(0x203)&&define['amd']?define([_0x1da652(0x21c),'@univerjs-pro/collaboration',_0x1da652(0x1df),_0x1da652(0x20b),_0x1da652(0x1fd),'@univerjs/network','rxjs'],_0x2e1377):(_0x56aad6=typeof globalThis<'u'?globalThis:_0x56aad6||self,_0x2e1377(_0x56aad6['UniverProCollaborationClientNode']={},_0x56aad6[_0x1da652(0x1d7)],_0x56aad6[_0x1da652(0x1e0)],_0x56aad6['UniverProLicense'],_0x56aad6[_0x1da652(0x1e6)],_0x56aad6[_0x1da652(0x1f7)],_0x56aad6[_0x1da652(0x201)]));}(this,function(_0x3ead59,_0x11fc18,_0x4cc070,_0x23eaf2,_0x39e6ee,_0x1dd146,_0xf8ea22){const _0x4d0bf9=_0x5e80;Object[_0x4d0bf9(0x21a)](_0x3ead59,Symbol[_0x4d0bf9(0x1cd)],{'value':_0x4d0bf9(0x21b)});var _0x1d2e15=(_0x28e11b,_0x5a157b)=>()=>(_0x5a157b||(_0x28e11b((_0x5a157b={'exports':{}})['exports'],_0x5a157b),_0x28e11b=null),_0x5a157b[_0x4d0bf9(0x21c)]),_0x3d6290=_0x4d0bf9(0x1e7),_0x18dc8b='1.0.0-rc.0';let _0x1dbf9e={};var _0x537e80=_0x1d2e15((_0x146392,_0x481f15)=>{const _0x4d8af9=_0x4d0bf9;_0x481f15[_0x4d8af9(0x21c)]=function(){throw Error('ws\x20does\x20not\x20work\x20in\x20the\x20browser.\x20Browser\x20clients\x20must\x20use\x20the\x20native\x20WebSocket\x20object');};})();function _0x5143e4(_0x700628,_0xe9149f){return function(_0x4d6f8b,_0x439c16){_0xe9149f(_0x4d6f8b,_0x439c16,_0x700628);};}function _0x1bc2a9(_0x2ce9bf,_0x5c58aa,_0x6d5db7,_0x574a98){const _0x337456=_0x4d0bf9;var _0x6105a2=arguments['length'],_0x5bbdeb=_0x6105a2<0x3?_0x5c58aa:_0x574a98===null?_0x574a98=Object[_0x337456(0x1d5)](_0x5c58aa,_0x6d5db7):_0x574a98,_0xc3ce24;if(typeof Reflect==_0x337456(0x215)&&typeof Reflect['decorate']==_0x337456(0x203))_0x5bbdeb=Reflect[_0x337456(0x20a)](_0x2ce9bf,_0x5c58aa,_0x6d5db7,_0x574a98);else{for(var _0x1cb953=_0x2ce9bf[_0x337456(0x1ea)]-0x1;_0x1cb953>=0x0;_0x1cb953--)(_0xc3ce24=_0x2ce9bf[_0x1cb953])&&(_0x5bbdeb=(_0x6105a2<0x3?_0xc3ce24(_0x5bbdeb):_0x6105a2>0x3?_0xc3ce24(_0x5c58aa,_0x6d5db7,_0x5bbdeb):_0xc3ce24(_0x5c58aa,_0x6d5db7))||_0x5bbdeb);}return _0x6105a2>0x3&&_0x5bbdeb&&Object['defineProperty'](_0x5c58aa,_0x6d5db7,_0x5bbdeb),_0x5bbdeb;}let _0x5beed1=class extends _0x39e6ee[_0x4d0bf9(0x1e5)]{constructor(_0x27246a){const _0x10e95a=_0x4d0bf9;super(),this[_0x10e95a(0x1f8)]=_0x27246a;}[_0x4d0bf9(0x207)](_0x49a749){const _0x39b58a=_0x4d0bf9;var _0x3fe7df;let _0x6b5f98=((_0x3fe7df=this['_configService'][_0x39b58a(0x1de)](_0x4cc070['COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY']))==null?void 0x0:_0x3fe7df[_0x39b58a(0x1da)])||{};try{let _0x468bb6=new _0x537e80[(_0x39b58a(0x1ef))](_0x49a749,{'headers':{..._0x6b5f98}}),_0x3ab9e7=new _0x39e6ee[(_0x39b58a(0x1e9))]();return{'URL':_0x49a749,'close':(_0x4fe338,_0x2aec5d)=>{const _0x470bb7=_0x39b58a;_0x468bb6[_0x470bb7(0x1ce)](_0x4fe338,_0x2aec5d),_0x3ab9e7[_0x470bb7(0x218)]();},'send':_0x49b2dd=>{const _0x51f02c=_0x39b58a;_0x468bb6[_0x51f02c(0x214)](_0x49b2dd);},'open$':new _0xf8ea22[(_0x39b58a(0x1cf))](_0x2e5995=>{const _0x45b36d=_0x39b58a;let _0x328d31=_0x47470c=>_0x2e5995['next'](_0x47470c);_0x468bb6[_0x45b36d(0x1cb)](_0x45b36d(0x211),_0x328d31),_0x3ab9e7[_0x45b36d(0x1e2)]((0x0,_0x39e6ee[_0x45b36d(0x202)])(()=>_0x468bb6[_0x45b36d(0x1d9)](_0x45b36d(0x211),_0x328d31)));})['pipe']((0x0,_0xf8ea22[_0x39b58a(0x1f6)])()),'close$':new _0xf8ea22[(_0x39b58a(0x1cf))](_0xdfbd01=>{const _0x3aa647=_0x39b58a;let _0x53f3e6=_0x36e5f9=>_0xdfbd01[_0x3aa647(0x1cc)](_0x36e5f9);_0x468bb6['addEventListener'](_0x3aa647(0x1ce),_0x53f3e6),_0x3ab9e7[_0x3aa647(0x1e2)]((0x0,_0x39e6ee[_0x3aa647(0x202)])(()=>_0x468bb6[_0x3aa647(0x1d9)](_0x3aa647(0x1ce),_0x53f3e6)));})[_0x39b58a(0x1d3)]((0x0,_0xf8ea22[_0x39b58a(0x1f6)])()),'error$':new _0xf8ea22[(_0x39b58a(0x1cf))](_0x5088cb=>{const _0x26e8bb=_0x39b58a;let _0x59e1be=_0x5ed537=>_0x5088cb[_0x26e8bb(0x1cc)](_0x5ed537);_0x468bb6[_0x26e8bb(0x1cb)](_0x26e8bb(0x21e),_0x59e1be),_0x3ab9e7['add']((0x0,_0x39e6ee[_0x26e8bb(0x202)])(()=>_0x468bb6[_0x26e8bb(0x1d9)](_0x26e8bb(0x21e),_0x59e1be)));})[_0x39b58a(0x1d3)]((0x0,_0xf8ea22['share'])()),'message$':new _0xf8ea22[(_0x39b58a(0x1cf))](_0x291ad2=>{const _0x5165b5=_0x39b58a;let _0x4f8e18=_0x35be35=>_0x291ad2[_0x5165b5(0x1cc)](_0x35be35);_0x468bb6[_0x5165b5(0x1cb)]('message',_0x4f8e18),_0x3ab9e7[_0x5165b5(0x1e2)]((0x0,_0x39e6ee[_0x5165b5(0x202)])(()=>_0x468bb6[_0x5165b5(0x1d9)](_0x5165b5(0x21d),_0x4f8e18)));})[_0x39b58a(0x1d3)]((0x0,_0xf8ea22[_0x39b58a(0x1f6)])())};}catch(_0x23db9c){return console['error'](_0x23db9c),null;}}};_0x5beed1=_0x1bc2a9([_0x5143e4(0x0,_0x39e6ee[_0x4d0bf9(0x1fa)])],_0x5beed1);function _0x4e94c7(_0x212bc6){'@babel/helpers - typeof';const _0x443def=_0x4d0bf9;return _0x4e94c7=typeof Symbol==_0x443def(0x203)&&typeof Symbol[_0x443def(0x1f9)]==_0x443def(0x1d4)?function(_0x480495){return typeof _0x480495;}:function(_0x3ebeda){const _0x272068=_0x443def;return _0x3ebeda&&typeof Symbol=='function'&&_0x3ebeda[_0x272068(0x1fb)]===Symbol&&_0x3ebeda!==Symbol[_0x272068(0x1ec)]?_0x272068(0x1d4):typeof _0x3ebeda;},_0x4e94c7(_0x212bc6);}function _0x57ba02(_0x28ba09,_0x271603){const _0x22e596=_0x4d0bf9;if(_0x4e94c7(_0x28ba09)!=_0x22e596(0x215)||!_0x28ba09)return _0x28ba09;var _0x56f8af=_0x28ba09[Symbol['toPrimitive']];if(_0x56f8af!==void 0x0){var _0x36f38f=_0x56f8af[_0x22e596(0x1f0)](_0x28ba09,_0x271603||'default');if(_0x4e94c7(_0x36f38f)!=_0x22e596(0x215))return _0x36f38f;throw TypeError(_0x22e596(0x1eb));}return(_0x271603===_0x22e596(0x1e3)?String:Number)(_0x28ba09);}function _0x5e6b5e(_0x1f32ba){const _0x288b88=_0x4d0bf9;var _0x56a213=_0x57ba02(_0x1f32ba,'string');return _0x4e94c7(_0x56a213)==_0x288b88(0x1d4)?_0x56a213:_0x56a213+'';}function _0xc8f5(_0x8dae0e,_0x326c14,_0x1282c8){const _0xedfbe5=_0x4d0bf9;return(_0x326c14=_0x5e6b5e(_0x326c14))in _0x8dae0e?Object[_0xedfbe5(0x21a)](_0x8dae0e,_0x326c14,{'value':_0x1282c8,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x8dae0e[_0x326c14]=_0x1282c8,_0x8dae0e;}let _0x444e65=class extends _0x39e6ee[_0x4d0bf9(0x1db)]{constructor(_0x58e6e7=_0x1dbf9e,_0x226636,_0x2c84b){const _0x1d8bb1=_0x4d0bf9;super(),this[_0x1d8bb1(0x20c)]=_0x58e6e7,this[_0x1d8bb1(0x1f8)]=_0x226636,this['_injector']=_0x2c84b;let {..._0x58ab55}=(0x0,_0x39e6ee[_0x1d8bb1(0x1f1)])({},_0x1dbf9e,this[_0x1d8bb1(0x20c)]);this[_0x1d8bb1(0x1f8)][_0x1d8bb1(0x1e4)](_0x1d8bb1(0x1ed),_0x58ab55);}[_0x4d0bf9(0x1fc)](){this['_registerDependencies']();}[_0x4d0bf9(0x1e8)](){const _0x555c4f=_0x4d0bf9;(0x0,_0x39e6ee[_0x555c4f(0x1ff)])(this[_0x555c4f(0x20f)],[[_0x1dd146[_0x555c4f(0x205)],{'useClass':_0x5beed1}]]);}};_0xc8f5(_0x444e65,_0x4d0bf9(0x1f2),'UNIVER_COLLABORATION_CLIENT_NODE_PLUGIN'),_0xc8f5(_0x444e65,'packageName',_0x3d6290),_0xc8f5(_0x444e65,_0x4d0bf9(0x1f3),_0x18dc8b),_0x444e65=_0x1bc2a9([(0x0,_0x39e6ee[_0x4d0bf9(0x1d6)])(_0x23eaf2[_0x4d0bf9(0x1d0)],_0x1dd146['UniverNetworkPlugin'],_0x11fc18[_0x4d0bf9(0x217)],_0x4cc070['UniverCollaborationClientPlugin']),_0x5143e4(0x1,_0x39e6ee[_0x4d0bf9(0x1fa)]),_0x5143e4(0x2,(0x0,_0x39e6ee[_0x4d0bf9(0x1e1)])(_0x39e6ee[_0x4d0bf9(0x1d8)]))],_0x444e65);let _0x36bad3=class extends _0x4cc070[_0x4d0bf9(0x1d2)]{constructor(_0x407813,_0x25e89b,_0x1aef89,_0x32af58,_0x5b4283){const _0x1ec08a=_0x4d0bf9;super(_0x407813,_0x25e89b,_0x1aef89,_0x32af58,_0x5b4283);let _0x303aa4=this['_configService'][_0x1ec08a(0x1de)](_0x4cc070[_0x1ec08a(0x210)]);this[_0x1ec08a(0x1ca)][_0x1ec08a(0x219)]({'interceptor':(_0x3ed040,_0x322e31)=>{const _0xe63662=_0x1ec08a;let _0x170ecf=_0x3ed040['headers'];if(_0x303aa4!=null&&_0x303aa4[_0xe63662(0x1da)]){for(let _0x34e74a in _0x303aa4[_0xe63662(0x1da)])_0x170ecf[_0xe63662(0x1dc)](_0x34e74a,_0x303aa4[_0xe63662(0x1da)][_0x34e74a]);}return _0x322e31(_0x3ed040);}});}async[_0x4d0bf9(0x207)](_0x37e509){const _0x2cb8d9=_0x4d0bf9;return this[_0x2cb8d9(0x1ee)](_0x37e509);}};_0x36bad3=_0x1bc2a9([_0x5143e4(0x0,(0x0,_0x39e6ee[_0x4d0bf9(0x1e1)])(_0x39e6ee['Injector'])),_0x5143e4(0x1,(0x0,_0x39e6ee[_0x4d0bf9(0x1e1)])(_0x1dd146[_0x4d0bf9(0x206)])),_0x5143e4(0x2,_0x39e6ee['IConfigService']),_0x5143e4(0x3,_0x39e6ee[_0x4d0bf9(0x213)]),_0x5143e4(0x4,_0x11fc18[_0x4d0bf9(0x20e)])],_0x36bad3),Object[_0x4d0bf9(0x21a)](_0x3ead59,_0x4d0bf9(0x1fe),{'enumerable':!0x0,'get':function(){return _0x36bad3;}}),Object[_0x4d0bf9(0x21a)](_0x3ead59,'UniverCollaborationClientNodePlugin',{'enumerable':!0x0,'get':function(){return _0x444e65;}});}));
1
+ (function(_0x4e9dc0,_0x499d51){const _0x51ac67=_0x2b7d,_0x550cb2=_0x4e9dc0();while(!![]){try{const _0x1ca54f=parseInt(_0x51ac67(0x12d))/0x1+parseInt(_0x51ac67(0xf3))/0x2*(parseInt(_0x51ac67(0x10a))/0x3)+-parseInt(_0x51ac67(0xe7))/0x4+-parseInt(_0x51ac67(0x12c))/0x5+parseInt(_0x51ac67(0x12a))/0x6+-parseInt(_0x51ac67(0x133))/0x7+-parseInt(_0x51ac67(0x10b))/0x8;if(_0x1ca54f===_0x499d51)break;else _0x550cb2['push'](_0x550cb2['shift']());}catch(_0xbfb00){_0x550cb2['push'](_0x550cb2['shift']());}}}(_0x140d,0xd3509),function(_0x1ec351,_0x4825a8){const _0x3e5284=_0x2b7d;typeof exports=='object'&&typeof module<'u'?_0x4825a8(exports,require('@univerjs-pro/collaboration'),require('@univerjs-pro/collaboration-client'),require('@univerjs-pro/license'),require('@univerjs/core'),require('@univerjs/network'),require('rxjs')):typeof define==_0x3e5284(0x129)&&define[_0x3e5284(0x10e)]?define([_0x3e5284(0xeb),'@univerjs-pro/collaboration',_0x3e5284(0x101),_0x3e5284(0x118),_0x3e5284(0x105),_0x3e5284(0xf5),_0x3e5284(0x11d)],_0x4825a8):(_0x1ec351=typeof globalThis<'u'?globalThis:_0x1ec351||self,_0x4825a8(_0x1ec351[_0x3e5284(0x102)]={},_0x1ec351[_0x3e5284(0x127)],_0x1ec351['UniverProCollaborationClient'],_0x1ec351['UniverProLicense'],_0x1ec351[_0x3e5284(0x103)],_0x1ec351[_0x3e5284(0xe2)],_0x1ec351[_0x3e5284(0x11d)]));}(this,function(_0x348602,_0x357f18,_0x2ea384,_0x53db6c,_0x5ee43a,_0x258040,_0x2f0d6a){const _0x51e570=_0x2b7d;Object['defineProperty'](_0x348602,Symbol[_0x51e570(0x114)],{'value':_0x51e570(0x112)});var _0xf4624=(_0x354f33,_0x2fb966)=>()=>(_0x2fb966||(_0x354f33((_0x2fb966={'exports':{}})[_0x51e570(0xeb)],_0x2fb966),_0x354f33=null),_0x2fb966[_0x51e570(0xeb)]),_0x202324='@univerjs-pro/collaboration-client-node',_0x26242d=_0x51e570(0x124);let _0x3e0c7d={};var _0x4be084=_0xf4624((_0x34d31a,_0x3f040c)=>{const _0x32ff13=_0x51e570;_0x3f040c[_0x32ff13(0xeb)]=function(){const _0x5e6473=_0x32ff13;throw Error(_0x5e6473(0x135));};})();function _0x243cbd(_0x48f9f3,_0x5d319a){return function(_0x7c258b,_0x156832){_0x5d319a(_0x7c258b,_0x156832,_0x48f9f3);};}function _0xd5769b(_0x16aea5,_0x5b275d,_0x576e9d,_0x3c49f3){const _0x1d768d=_0x51e570;var _0x18c229=arguments[_0x1d768d(0x11c)],_0x459957=_0x18c229<0x3?_0x5b275d:_0x3c49f3===null?_0x3c49f3=Object[_0x1d768d(0x136)](_0x5b275d,_0x576e9d):_0x3c49f3,_0x24ef9c;if(typeof Reflect==_0x1d768d(0x10d)&&typeof Reflect[_0x1d768d(0x12b)]=='function')_0x459957=Reflect['decorate'](_0x16aea5,_0x5b275d,_0x576e9d,_0x3c49f3);else{for(var _0x2905ab=_0x16aea5[_0x1d768d(0x11c)]-0x1;_0x2905ab>=0x0;_0x2905ab--)(_0x24ef9c=_0x16aea5[_0x2905ab])&&(_0x459957=(_0x18c229<0x3?_0x24ef9c(_0x459957):_0x18c229>0x3?_0x24ef9c(_0x5b275d,_0x576e9d,_0x459957):_0x24ef9c(_0x5b275d,_0x576e9d))||_0x459957);}return _0x18c229>0x3&&_0x459957&&Object[_0x1d768d(0xea)](_0x5b275d,_0x576e9d,_0x459957),_0x459957;}let _0x5deac9=class extends _0x5ee43a['Disposable']{constructor(_0x246ed0){const _0x2dd61e=_0x51e570;super(),this[_0x2dd61e(0xf6)]=_0x246ed0;}[_0x51e570(0x113)](_0x2867c7){const _0x3da422=_0x51e570;var _0x5328be;let _0x10c24b=((_0x5328be=this[_0x3da422(0xf6)][_0x3da422(0x10c)](_0x2ea384['COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY']))==null?void 0x0:_0x5328be[_0x3da422(0xfc)])||{};try{let _0x4d96eb=new _0x4be084[(_0x3da422(0x130))](_0x2867c7,{'headers':{..._0x10c24b}}),_0x505900=new _0x5ee43a[(_0x3da422(0x11f))]();return{'URL':_0x2867c7,'close':(_0x570b65,_0x3d1998)=>{const _0x3c8038=_0x3da422;_0x4d96eb[_0x3c8038(0x123)](_0x570b65,_0x3d1998),_0x505900[_0x3c8038(0x116)]();},'send':_0xa343ad=>{const _0x1b16f2=_0x3da422;_0x4d96eb[_0x1b16f2(0x132)](_0xa343ad);},'open$':new _0x2f0d6a[(_0x3da422(0xf7))](_0x55151e=>{const _0x488ed7=_0x3da422;let _0x37cacf=_0x20d801=>_0x55151e[_0x488ed7(0xe3)](_0x20d801);_0x4d96eb[_0x488ed7(0xfd)](_0x488ed7(0x108),_0x37cacf),_0x505900[_0x488ed7(0x120)]((0x0,_0x5ee43a[_0x488ed7(0xe5)])(()=>_0x4d96eb[_0x488ed7(0x111)]('open',_0x37cacf)));})[_0x3da422(0xe9)]((0x0,_0x2f0d6a[_0x3da422(0x110)])()),'close$':new _0x2f0d6a['Observable'](_0x2759ba=>{const _0x587986=_0x3da422;let _0x10e295=_0x26e821=>_0x2759ba[_0x587986(0xe3)](_0x26e821);_0x4d96eb[_0x587986(0xfd)](_0x587986(0x123),_0x10e295),_0x505900[_0x587986(0x120)]((0x0,_0x5ee43a['toDisposable'])(()=>_0x4d96eb['removeEventListener'](_0x587986(0x123),_0x10e295)));})['pipe']((0x0,_0x2f0d6a[_0x3da422(0x110)])()),'error$':new _0x2f0d6a[(_0x3da422(0xf7))](_0x822ce8=>{const _0x5e2481=_0x3da422;let _0x2b5b39=_0x4cbd55=>_0x822ce8['next'](_0x4cbd55);_0x4d96eb[_0x5e2481(0xfd)](_0x5e2481(0xe8),_0x2b5b39),_0x505900[_0x5e2481(0x120)]((0x0,_0x5ee43a['toDisposable'])(()=>_0x4d96eb[_0x5e2481(0x111)]('error',_0x2b5b39)));})[_0x3da422(0xe9)]((0x0,_0x2f0d6a[_0x3da422(0x110)])()),'message$':new _0x2f0d6a['Observable'](_0x12245b=>{const _0x2d8cf8=_0x3da422;let _0x40cd91=_0x513ab2=>_0x12245b[_0x2d8cf8(0xe3)](_0x513ab2);_0x4d96eb['addEventListener']('message',_0x40cd91),_0x505900[_0x2d8cf8(0x120)]((0x0,_0x5ee43a[_0x2d8cf8(0xe5)])(()=>_0x4d96eb['removeEventListener'](_0x2d8cf8(0x117),_0x40cd91)));})[_0x3da422(0xe9)]((0x0,_0x2f0d6a[_0x3da422(0x110)])())};}catch(_0xd714f8){return console['error'](_0xd714f8),null;}}};_0x5deac9=_0xd5769b([_0x243cbd(0x0,_0x5ee43a[_0x51e570(0xf9)])],_0x5deac9);function _0x4366ff(_0x21f97e){'@babel/helpers - typeof';const _0x1e330a=_0x51e570;return _0x4366ff=typeof Symbol==_0x1e330a(0x129)&&typeof Symbol[_0x1e330a(0x11e)]==_0x1e330a(0x11a)?function(_0x48d658){return typeof _0x48d658;}:function(_0x12fefb){const _0xcd1115=_0x1e330a;return _0x12fefb&&typeof Symbol=='function'&&_0x12fefb[_0xcd1115(0xef)]===Symbol&&_0x12fefb!==Symbol[_0xcd1115(0xf8)]?'symbol':typeof _0x12fefb;},_0x4366ff(_0x21f97e);}function _0x37a100(_0x496ac1,_0x54eb93){const _0x3a2348=_0x51e570;if(_0x4366ff(_0x496ac1)!=_0x3a2348(0x10d)||!_0x496ac1)return _0x496ac1;var _0x513329=_0x496ac1[Symbol[_0x3a2348(0xf0)]];if(_0x513329!==void 0x0){var _0x4cc578=_0x513329[_0x3a2348(0x12e)](_0x496ac1,_0x54eb93||_0x3a2348(0xed));if(_0x4366ff(_0x4cc578)!=_0x3a2348(0x10d))return _0x4cc578;throw TypeError(_0x3a2348(0x121));}return(_0x54eb93===_0x3a2348(0xe6)?String:Number)(_0x496ac1);}function _0xec36de(_0x56ee7b){const _0x1af530=_0x51e570;var _0x8aaabe=_0x37a100(_0x56ee7b,_0x1af530(0xe6));return _0x4366ff(_0x8aaabe)=='symbol'?_0x8aaabe:_0x8aaabe+'';}function _0x5a5234(_0xb85169,_0x52b984,_0x18d57d){const _0x41d4d7=_0x51e570;return(_0x52b984=_0xec36de(_0x52b984))in _0xb85169?Object[_0x41d4d7(0xea)](_0xb85169,_0x52b984,{'value':_0x18d57d,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0xb85169[_0x52b984]=_0x18d57d,_0xb85169;}let _0xd8d114=class extends _0x5ee43a[_0x51e570(0x11b)]{constructor(_0x156a5c=_0x3e0c7d,_0x19308b,_0x30351c){const _0x1af719=_0x51e570;super(),this[_0x1af719(0xff)]=_0x156a5c,this['_configService']=_0x19308b,this['_injector']=_0x30351c;let {..._0x40a709}=(0x0,_0x5ee43a[_0x1af719(0x134)])({},_0x3e0c7d,this[_0x1af719(0xff)]);this['_configService']['setConfig'](_0x1af719(0x128),_0x40a709);}[_0x51e570(0xf2)](){const _0x5cce2a=_0x51e570;this[_0x5cce2a(0xee)]();}[_0x51e570(0xee)](){const _0x44d7d3=_0x51e570;(0x0,_0x5ee43a['registerDependencies'])(this['_injector'],[[_0x258040[_0x44d7d3(0x107)],{'useClass':_0x5deac9}]]);}};_0x5a5234(_0xd8d114,'pluginName',_0x51e570(0x106)),_0x5a5234(_0xd8d114,_0x51e570(0xe4),_0x202324),_0x5a5234(_0xd8d114,'version',_0x26242d),_0xd8d114=_0xd5769b([(0x0,_0x5ee43a[_0x51e570(0x131)])(_0x53db6c[_0x51e570(0xfa)],_0x258040[_0x51e570(0xf1)],_0x357f18[_0x51e570(0xf4)],_0x2ea384[_0x51e570(0x10f)]),_0x243cbd(0x1,_0x5ee43a[_0x51e570(0xf9)]),_0x243cbd(0x2,(0x0,_0x5ee43a[_0x51e570(0x109)])(_0x5ee43a[_0x51e570(0x119)]))],_0xd8d114);let _0x2e997f=class extends _0x2ea384[_0x51e570(0x115)]{constructor(_0x2a4afc,_0x3a3a85,_0x1d16a3,_0x37c3a6,_0x79b1df){const _0x1c21ce=_0x51e570;super(_0x2a4afc,_0x3a3a85,_0x1d16a3,_0x37c3a6,_0x79b1df);let _0x2ee11a=this[_0x1c21ce(0xf6)]['getConfig'](_0x2ea384[_0x1c21ce(0x126)]);this['_httpService'][_0x1c21ce(0xfe)]({'interceptor':(_0x295375,_0x252877)=>{const _0x2d60fa=_0x1c21ce;let _0x29b1f2=_0x295375[_0x2d60fa(0x100)];if(_0x2ee11a!=null&&_0x2ee11a[_0x2d60fa(0xfc)]){for(let _0x510d34 in _0x2ee11a['customHeaders'])_0x29b1f2['set'](_0x510d34,_0x2ee11a[_0x2d60fa(0xfc)][_0x510d34]);}return _0x252877(_0x295375);}});}async[_0x51e570(0x113)](_0x2ecc2f){const _0x2a1d92=_0x51e570;return this[_0x2a1d92(0x12f)](_0x2ecc2f);}};_0x2e997f=_0xd5769b([_0x243cbd(0x0,(0x0,_0x5ee43a['Inject'])(_0x5ee43a[_0x51e570(0x119)])),_0x243cbd(0x1,(0x0,_0x5ee43a[_0x51e570(0x109)])(_0x258040[_0x51e570(0x104)])),_0x243cbd(0x2,_0x5ee43a[_0x51e570(0xf9)]),_0x243cbd(0x3,_0x5ee43a[_0x51e570(0x125)]),_0x243cbd(0x4,_0x357f18[_0x51e570(0xfb)])],_0x2e997f),Object[_0x51e570(0xea)](_0x348602,_0x51e570(0x122),{'enumerable':!0x0,'get':function(){return _0x2e997f;}}),Object['defineProperty'](_0x348602,_0x51e570(0xec),{'enumerable':!0x0,'get':function(){return _0xd8d114;}});}));function _0x2b7d(_0x4cd70e,_0x3114a9){_0x4cd70e=_0x4cd70e-0xe2;const _0x140dbc=_0x140d();let _0x2b7d9f=_0x140dbc[_0x4cd70e];return _0x2b7d9f;}function _0x140d(){const _0x12a1dd=['1.0.1','ILogService','COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY','UniverProCollaboration','collaboration-client-node.config','function','6362298xGMedQ','decorate','82370qeHmdd','427403CxBHAD','call','_doCreateSocket','WebSocket','DependentOn','send','3112445WhyGZo','merge','ws\x20does\x20not\x20work\x20in\x20the\x20browser.\x20Browser\x20clients\x20must\x20use\x20the\x20native\x20WebSocket\x20object','getOwnPropertyDescriptor','UniverNetwork','next','packageName','toDisposable','string','2082376jssQqa','error','pipe','defineProperty','exports','UniverCollaborationClientNodePlugin','default','_registerDependencies','constructor','toPrimitive','UniverNetworkPlugin','onStarting','476plJMfL','UniverCollaborationPlugin','@univerjs/network','_configService','Observable','prototype','IConfigService','UniverLicensePlugin','ISnapshotServerService','customHeaders','addEventListener','registerHTTPInterceptor','_config','headers','@univerjs-pro/collaboration-client','UniverProCollaborationClientNode','UniverCore','HTTPService','@univerjs/core','UNIVER_COLLABORATION_CLIENT_NODE_PLUGIN','ISocketService','open','Inject','9993HiygSx','3466528gzQrHc','getConfig','object','amd','UniverCollaborationClientPlugin','share','removeEventListener','Module','createSocket','toStringTag','CollaborationSocketService','dispose','message','@univerjs-pro/license','Injector','symbol','Plugin','length','rxjs','iterator','DisposableCollection','add','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','NodeCollaborationSocketService','close'];_0x140d=function(){return _0x12a1dd;};return _0x140d();}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@univerjs-pro/collaboration-client-node",
3
- "version": "1.0.0-rc.0",
3
+ "version": "1.0.1",
4
4
  "private": false,
5
5
  "description": "Node.js collaboration client plugin for Univer Pro.",
6
6
  "author": "DreamNum Co., Ltd. <developer@univer.ai>",
@@ -51,19 +51,19 @@
51
51
  "rxjs": ">=7.0.0"
52
52
  },
53
53
  "dependencies": {
54
- "@univerjs-pro/collaboration": "1.0.0-rc.0",
55
- "@univerjs-pro/collaboration-client": "1.0.0-rc.0",
56
- "@univerjs-pro/license": "1.0.0-rc.0",
57
- "@univerjs/core": "1.0.0-rc.0",
58
- "@univerjs/network": "1.0.0-rc.0",
54
+ "@univerjs-pro/collaboration": "1.0.1",
55
+ "@univerjs-pro/collaboration-client": "1.0.1",
56
+ "@univerjs-pro/license": "1.0.1",
57
+ "@univerjs/core": "1.0.1",
58
+ "@univerjs/network": "1.0.1",
59
59
  "ws": "8.21.0"
60
60
  },
61
61
  "devDependencies": {
62
62
  "@types/ws": "8.18.1",
63
- "@univerjs-infra/shared": "1.0.0-rc.0",
63
+ "@univerjs-infra/shared": "1.0.1",
64
64
  "rxjs": "7.8.2",
65
65
  "typescript": "^6.0.3",
66
- "vitest": "^4.1.11"
66
+ "vitest": "^5.0.0"
67
67
  },
68
68
  "scripts": {
69
69
  "test": "vitest run",