@univerjs-pro/collaboration-client-node 1.0.0-alpha.4 → 1.0.0-alpha.5

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 _0x4e52e5=_0x5866;(function(_0xda1155,_0x51f188){const _0x406282=_0x5866,_0x2d6ab3=_0xda1155();while(!![]){try{const _0x4efcf0=parseInt(_0x406282(0xaa))/0x1+-parseInt(_0x406282(0x95))/0x2*(parseInt(_0x406282(0x8f))/0x3)+parseInt(_0x406282(0x86))/0x4+-parseInt(_0x406282(0x7b))/0x5*(parseInt(_0x406282(0x9b))/0x6)+parseInt(_0x406282(0x94))/0x7+parseInt(_0x406282(0xa3))/0x8*(-parseInt(_0x406282(0xa6))/0x9)+parseInt(_0x406282(0x75))/0xa*(parseInt(_0x406282(0xb1))/0xb);if(_0x4efcf0===_0x51f188)break;else _0x2d6ab3['push'](_0x2d6ab3['shift']());}catch(_0x2e7596){_0x2d6ab3['push'](_0x2d6ab3['shift']());}}}(_0x35d5,0x41348),Object[_0x4e52e5(0x80)](exports,Symbol['toStringTag'],{'value':_0x4e52e5(0x93)}));let e=require('@univerjs-pro/collaboration-client'),t=require('@univerjs/core'),n=require('@univerjs/network'),r=require('rxjs'),i=require('ws'),a=require('@univerjs-pro/collaboration');function _0x35d5(){const _0x26566d=['collaboration-client-node.config','NodeCollaborationSocketService','UniverCollaborationClientNodePlugin','dispose','setConfig','Injector','pluginName','decorate','packageName','5707180mVoOJZ','IConfigService','default','open','_injector','symbol','85JEPqvb','function','addEventListener','Inject','UNIVER_COLLABORATION_CLIENT_NODE_PLUGIN','defineProperty','object','call','_httpService','version','merge','473048XaycwK','registerDependencies','string','ISocketService','_configService','close','@univerjs-pro/collaboration-client-node','getConfig','_registerDependencies','15ewpZgX','pipe','CollaborationSocketService','COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY','Module','2511236egIjok','115438PNHzzB','createSocket','ILogService','Disposable','customHeaders','removeEventListener','97068ZBGFrE','send','share','_config','error','registerHTTPInterceptor','_doCreateSocket','UniverCollaborationClientPlugin','8JbPkjy','HTTPService','next','2384631sBUHoc','toPrimitive','message','length','47932PezmAm','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','add','toDisposable','set','Observable','headers','11YaLmAD'];_0x35d5=function(){return _0x26566d;};return _0x35d5();}var o=_0x4e52e5(0x8c),s='1.0.0-alpha.4';const c={};function l(_0x50f6d6,_0x2ba7fc){return function(_0x405c0a,_0x24e999){_0x2ba7fc(_0x405c0a,_0x24e999,_0x50f6d6);};}function u(_0x121c4f,_0x88e79b,_0x9ea0a4,_0x27dcd3){const _0x34536f=_0x4e52e5;var _0x5771a4=arguments['length'],_0x4ee2fb=_0x5771a4<0x3?_0x88e79b:_0x27dcd3===null?_0x27dcd3=Object['getOwnPropertyDescriptor'](_0x88e79b,_0x9ea0a4):_0x27dcd3,_0xe215d2;if(typeof Reflect==_0x34536f(0x81)&&typeof Reflect[_0x34536f(0x73)]=='function')_0x4ee2fb=Reflect[_0x34536f(0x73)](_0x121c4f,_0x88e79b,_0x9ea0a4,_0x27dcd3);else{for(var _0x477aef=_0x121c4f[_0x34536f(0xa9)]-0x1;_0x477aef>=0x0;_0x477aef--)(_0xe215d2=_0x121c4f[_0x477aef])&&(_0x4ee2fb=(_0x5771a4<0x3?_0xe215d2(_0x4ee2fb):_0x5771a4>0x3?_0xe215d2(_0x88e79b,_0x9ea0a4,_0x4ee2fb):_0xe215d2(_0x88e79b,_0x9ea0a4))||_0x4ee2fb);}return _0x5771a4>0x3&&_0x4ee2fb&&Object['defineProperty'](_0x88e79b,_0x9ea0a4,_0x4ee2fb),_0x4ee2fb;}let d=class extends t[_0x4e52e5(0x98)]{constructor(_0xb98865){const _0x396148=_0x4e52e5;super(),this[_0x396148(0x8a)]=_0xb98865;}[_0x4e52e5(0x96)](_0x44c42b){const _0x5dc784=_0x4e52e5;var _0x58c9c7;let _0x36de05=((_0x58c9c7=this[_0x5dc784(0x8a)][_0x5dc784(0x8d)](e['COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY']))==null?void 0x0:_0x58c9c7[_0x5dc784(0x99)])||{};try{let _0xb34855=new i['WebSocket'](_0x44c42b,{'headers':{..._0x36de05}}),_0x16748f=new t['DisposableCollection']();return{'URL':_0x44c42b,'close':(_0x520901,_0x2ea3a7)=>{const _0x5a37bb=_0x5dc784;_0xb34855[_0x5a37bb(0x8b)](_0x520901,_0x2ea3a7),_0x16748f[_0x5a37bb(0x6f)]();},'send':_0x2c0079=>{const _0x4046e8=_0x5dc784;_0xb34855[_0x4046e8(0x9c)](_0x2c0079);},'open$':new r[(_0x5dc784(0xaf))](_0x3ac6f9=>{const _0x2c826c=_0x5dc784;let _0x8651d0=_0x3efab1=>_0x3ac6f9[_0x2c826c(0xa5)](_0x3efab1);_0xb34855[_0x2c826c(0x7d)](_0x2c826c(0x78),_0x8651d0),_0x16748f['add']((0x0,t[_0x2c826c(0xad)])(()=>_0xb34855['removeEventListener'](_0x2c826c(0x78),_0x8651d0)));})['pipe']((0x0,r['share'])()),'close$':new r[(_0x5dc784(0xaf))](_0x314d5a=>{const _0x5ee0d6=_0x5dc784;let _0x3a9892=_0x46c029=>_0x314d5a['next'](_0x46c029);_0xb34855[_0x5ee0d6(0x7d)](_0x5ee0d6(0x8b),_0x3a9892),_0x16748f[_0x5ee0d6(0xac)]((0x0,t[_0x5ee0d6(0xad)])(()=>_0xb34855[_0x5ee0d6(0x9a)](_0x5ee0d6(0x8b),_0x3a9892)));})[_0x5dc784(0x90)]((0x0,r[_0x5dc784(0x9d)])()),'error$':new r[(_0x5dc784(0xaf))](_0x5ea0d5=>{const _0x3e831a=_0x5dc784;let _0xde9a75=_0x271453=>_0x5ea0d5[_0x3e831a(0xa5)](_0x271453);_0xb34855[_0x3e831a(0x7d)](_0x3e831a(0x9f),_0xde9a75),_0x16748f[_0x3e831a(0xac)]((0x0,t[_0x3e831a(0xad)])(()=>_0xb34855['removeEventListener']('error',_0xde9a75)));})['pipe']((0x0,r[_0x5dc784(0x9d)])()),'message$':new r[(_0x5dc784(0xaf))](_0x409bab=>{const _0x59c373=_0x5dc784;let _0x9bde1f=_0x3c87fc=>_0x409bab['next'](_0x3c87fc);_0xb34855[_0x59c373(0x7d)](_0x59c373(0xa8),_0x9bde1f),_0x16748f[_0x59c373(0xac)]((0x0,t[_0x59c373(0xad)])(()=>_0xb34855['removeEventListener'](_0x59c373(0xa8),_0x9bde1f)));})[_0x5dc784(0x90)]((0x0,r[_0x5dc784(0x9d)])())};}catch(_0x2c786c){return console[_0x5dc784(0x9f)](_0x2c786c),null;}}};d=u([l(0x0,t[_0x4e52e5(0x76)])],d);function f(_0x2e6163){'@babel/helpers - typeof';const _0x4c05ff=_0x4e52e5;return f=typeof Symbol==_0x4c05ff(0x7c)&&typeof Symbol['iterator']=='symbol'?function(_0x47337e){return typeof _0x47337e;}:function(_0x290c27){const _0x48ab9c=_0x4c05ff;return _0x290c27&&typeof Symbol==_0x48ab9c(0x7c)&&_0x290c27['constructor']===Symbol&&_0x290c27!==Symbol['prototype']?_0x48ab9c(0x7a):typeof _0x290c27;},f(_0x2e6163);}function p(_0x16ea83,_0x192747){const _0x9267ea=_0x4e52e5;if(f(_0x16ea83)!=_0x9267ea(0x81)||!_0x16ea83)return _0x16ea83;var _0x3ce328=_0x16ea83[Symbol[_0x9267ea(0xa7)]];if(_0x3ce328!==void 0x0){var _0x504d3b=_0x3ce328[_0x9267ea(0x82)](_0x16ea83,_0x192747||_0x9267ea(0x77));if(f(_0x504d3b)!=_0x9267ea(0x81))return _0x504d3b;throw TypeError(_0x9267ea(0xab));}return(_0x192747===_0x9267ea(0x88)?String:Number)(_0x16ea83);}function m(_0x4fd0ec){const _0x2102ce=_0x4e52e5;var _0x2eb727=p(_0x4fd0ec,_0x2102ce(0x88));return f(_0x2eb727)=='symbol'?_0x2eb727:_0x2eb727+'';}function h(_0x56c6ce,_0xa8e267,_0x5a1c0d){const _0xbee145=_0x4e52e5;return(_0xa8e267=m(_0xa8e267))in _0x56c6ce?Object[_0xbee145(0x80)](_0x56c6ce,_0xa8e267,{'value':_0x5a1c0d,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x56c6ce[_0xa8e267]=_0x5a1c0d,_0x56c6ce;}let g=class extends t['Plugin']{constructor(_0x400df6=c,_0x36e340,_0x4b7f46){const _0x1aae3e=_0x4e52e5;super(),this[_0x1aae3e(0x9e)]=_0x400df6,this[_0x1aae3e(0x8a)]=_0x36e340,this[_0x1aae3e(0x79)]=_0x4b7f46;let {..._0x57a018}=(0x0,t[_0x1aae3e(0x85)])({},c,this[_0x1aae3e(0x9e)]);this[_0x1aae3e(0x8a)][_0x1aae3e(0x70)](_0x1aae3e(0xb2),_0x57a018);}['onStarting'](){const _0x244f68=_0x4e52e5;this[_0x244f68(0x8e)]();}['_registerDependencies'](){const _0x449f04=_0x4e52e5;(0x0,t[_0x449f04(0x87)])(this[_0x449f04(0x79)],[[n[_0x449f04(0x89)],{'useClass':d}]]);}};h(g,_0x4e52e5(0x72),_0x4e52e5(0x7f)),h(g,_0x4e52e5(0x74),o),h(g,_0x4e52e5(0x84),s),g=u([(0x0,t['DependentOn'])(e[_0x4e52e5(0xa2)]),l(0x1,t['IConfigService']),l(0x2,(0x0,t[_0x4e52e5(0x7e)])(t['Injector']))],g);function _0x5866(_0x3d4013,_0x5dd379){_0x3d4013=_0x3d4013-0x6d;const _0x35d5bd=_0x35d5();let _0x5866df=_0x35d5bd[_0x3d4013];return _0x5866df;}let _=class extends e[_0x4e52e5(0x91)]{constructor(_0x4d6484,_0x3e1644,_0x1e29c9,_0x153cb4,_0x40396e){const _0x50f2ba=_0x4e52e5;super(_0x4d6484,_0x3e1644,_0x1e29c9,_0x153cb4,_0x40396e);let _0x5b3b29=this['_configService'][_0x50f2ba(0x8d)](e[_0x50f2ba(0x92)]);this[_0x50f2ba(0x83)][_0x50f2ba(0xa0)]({'interceptor':(_0x1cfe79,_0x5d0a6f)=>{const _0x438ce2=_0x50f2ba;let _0x8f989f=_0x1cfe79[_0x438ce2(0xb0)];if(_0x5b3b29!=null&&_0x5b3b29[_0x438ce2(0x99)]){for(let _0x258d09 in _0x5b3b29[_0x438ce2(0x99)])_0x8f989f[_0x438ce2(0xae)](_0x258d09,_0x5b3b29[_0x438ce2(0x99)][_0x258d09]);}return _0x5d0a6f(_0x1cfe79);}});}async['createSocket'](_0x56d8c2){const _0x6886af=_0x4e52e5;return this[_0x6886af(0xa1)](_0x56d8c2);}};_=u([l(0x0,(0x0,t[_0x4e52e5(0x7e)])(t[_0x4e52e5(0x71)])),l(0x1,(0x0,t[_0x4e52e5(0x7e)])(n[_0x4e52e5(0xa4)])),l(0x2,t[_0x4e52e5(0x76)]),l(0x3,t[_0x4e52e5(0x97)]),l(0x4,a['ISnapshotServerService'])],_),Object[_0x4e52e5(0x80)](exports,_0x4e52e5(0x6d),{'enumerable':!0x0,'get':function(){return _;}}),Object['defineProperty'](exports,_0x4e52e5(0x6e),{'enumerable':!0x0,'get':function(){return g;}});
1
+ const _0x210a58=_0x5e4f;(function(_0x2cf506,_0x499bd2){const _0x20b424=_0x5e4f,_0x75a733=_0x2cf506();while(!![]){try{const _0x46ec84=-parseInt(_0x20b424(0x176))/0x1+parseInt(_0x20b424(0x171))/0x2*(parseInt(_0x20b424(0x151))/0x3)+-parseInt(_0x20b424(0x159))/0x4*(-parseInt(_0x20b424(0x15f))/0x5)+-parseInt(_0x20b424(0x156))/0x6*(parseInt(_0x20b424(0x154))/0x7)+-parseInt(_0x20b424(0x152))/0x8+parseInt(_0x20b424(0x174))/0x9+parseInt(_0x20b424(0x179))/0xa;if(_0x46ec84===_0x499bd2)break;else _0x75a733['push'](_0x75a733['shift']());}catch(_0x465feb){_0x75a733['push'](_0x75a733['shift']());}}}(_0x5a34,0x549e4),Object[_0x210a58(0x194)](exports,Symbol[_0x210a58(0x153)],{'value':'Module'}));function _0x5a34(){const _0x145901=['packageName','addEventListener','pipe','object','toDisposable','error','registerHTTPInterceptor','Injector','IConfigService','_doCreateSocket','@univerjs-pro/collaboration-client-node','createSocket','_configService','setConfig','WebSocket','NodeCollaborationSocketService','add','version','open','symbol','COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY','CollaborationSocketService','defineProperty','UNIVER_COLLABORATION_CLIENT_NODE_PLUGIN','ISocketService','822393yhmPTj','2775760KFwbqO','toStringTag','311906evXyVK','_config','36vQYBvJ','ILogService','Disposable','20232ZprTHs','1.0.0-alpha.5','customHeaders','close','string','set','15UIihMj','_registerDependencies','registerDependencies','message','dispose','pluginName','prototype','call','length','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','onStarting','share','getOwnPropertyDescriptor','function','DisposableCollection','headers','Observable','default','2XQGRVZ','Inject','removeEventListener','5479677BRMuXf','send','449812gWXinA','decorate','HTTPService','5125680AEBthM','UniverCollaborationClientNodePlugin','ISnapshotServerService','_injector','getConfig'];_0x5a34=function(){return _0x145901;};return _0x5a34();}let e=require('@univerjs-pro/collaboration-client'),t=require('@univerjs/core'),n=require('@univerjs/network'),r=require('rxjs'),i=require('ws'),a=require('@univerjs-pro/collaboration');var o=_0x210a58(0x188),s=_0x210a58(0x15a);function _0x5e4f(_0x5a0855,_0x302fae){_0x5a0855=_0x5a0855-0x151;const _0x5a34b3=_0x5a34();let _0x5e4f57=_0x5a34b3[_0x5a0855];return _0x5e4f57;}const c={};function l(_0x4164ce,_0x359747){return function(_0x290289,_0x1b42d2){_0x359747(_0x290289,_0x1b42d2,_0x4164ce);};}function u(_0x25a205,_0x4ebc69,_0x2f4686,_0x1e253b){const _0x557c75=_0x210a58;var _0x397e01=arguments[_0x557c75(0x167)],_0x2aa7a5=_0x397e01<0x3?_0x4ebc69:_0x1e253b===null?_0x1e253b=Object[_0x557c75(0x16b)](_0x4ebc69,_0x2f4686):_0x1e253b,_0x109652;if(typeof Reflect=='object'&&typeof Reflect[_0x557c75(0x177)]==_0x557c75(0x16c))_0x2aa7a5=Reflect[_0x557c75(0x177)](_0x25a205,_0x4ebc69,_0x2f4686,_0x1e253b);else{for(var _0x209181=_0x25a205[_0x557c75(0x167)]-0x1;_0x209181>=0x0;_0x209181--)(_0x109652=_0x25a205[_0x209181])&&(_0x2aa7a5=(_0x397e01<0x3?_0x109652(_0x2aa7a5):_0x397e01>0x3?_0x109652(_0x4ebc69,_0x2f4686,_0x2aa7a5):_0x109652(_0x4ebc69,_0x2f4686))||_0x2aa7a5);}return _0x397e01>0x3&&_0x2aa7a5&&Object[_0x557c75(0x194)](_0x4ebc69,_0x2f4686,_0x2aa7a5),_0x2aa7a5;}let d=class extends t[_0x210a58(0x158)]{constructor(_0x1f80ff){const _0x3cb950=_0x210a58;super(),this[_0x3cb950(0x18a)]=_0x1f80ff;}[_0x210a58(0x189)](_0x4a8d4f){const _0x307dce=_0x210a58;var _0x45131a;let _0x5dd1a2=((_0x45131a=this[_0x307dce(0x18a)][_0x307dce(0x17d)](e[_0x307dce(0x192)]))==null?void 0x0:_0x45131a[_0x307dce(0x15b)])||{};try{let _0x34a099=new i[(_0x307dce(0x18c))](_0x4a8d4f,{'headers':{..._0x5dd1a2}}),_0x5b454d=new t[(_0x307dce(0x16d))]();return{'URL':_0x4a8d4f,'close':(_0x28bd0a,_0x4aef49)=>{const _0x410aa7=_0x307dce;_0x34a099[_0x410aa7(0x15c)](_0x28bd0a,_0x4aef49),_0x5b454d[_0x410aa7(0x163)]();},'send':_0x2ab81f=>{const _0x50c44f=_0x307dce;_0x34a099[_0x50c44f(0x175)](_0x2ab81f);},'open$':new r[(_0x307dce(0x16f))](_0xfbce2c=>{const _0x495cf7=_0x307dce;let _0x261104=_0x16b34f=>_0xfbce2c['next'](_0x16b34f);_0x34a099[_0x495cf7(0x17f)](_0x495cf7(0x190),_0x261104),_0x5b454d['add']((0x0,t[_0x495cf7(0x182)])(()=>_0x34a099[_0x495cf7(0x173)](_0x495cf7(0x190),_0x261104)));})['pipe']((0x0,r[_0x307dce(0x16a)])()),'close$':new r[(_0x307dce(0x16f))](_0x34273d=>{const _0x4ebdf6=_0x307dce;let _0xe3fb1a=_0x50c1ff=>_0x34273d['next'](_0x50c1ff);_0x34a099[_0x4ebdf6(0x17f)](_0x4ebdf6(0x15c),_0xe3fb1a),_0x5b454d[_0x4ebdf6(0x18e)]((0x0,t['toDisposable'])(()=>_0x34a099[_0x4ebdf6(0x173)](_0x4ebdf6(0x15c),_0xe3fb1a)));})[_0x307dce(0x180)]((0x0,r[_0x307dce(0x16a)])()),'error$':new r[(_0x307dce(0x16f))](_0x4d6219=>{const _0x6477f4=_0x307dce;let _0x285975=_0x338a81=>_0x4d6219['next'](_0x338a81);_0x34a099[_0x6477f4(0x17f)](_0x6477f4(0x183),_0x285975),_0x5b454d[_0x6477f4(0x18e)]((0x0,t[_0x6477f4(0x182)])(()=>_0x34a099['removeEventListener'](_0x6477f4(0x183),_0x285975)));})[_0x307dce(0x180)]((0x0,r[_0x307dce(0x16a)])()),'message$':new r[(_0x307dce(0x16f))](_0x5da6b9=>{const _0x2b1188=_0x307dce;let _0x229444=_0x188a9a=>_0x5da6b9['next'](_0x188a9a);_0x34a099[_0x2b1188(0x17f)]('message',_0x229444),_0x5b454d[_0x2b1188(0x18e)]((0x0,t['toDisposable'])(()=>_0x34a099[_0x2b1188(0x173)](_0x2b1188(0x162),_0x229444)));})[_0x307dce(0x180)]((0x0,r[_0x307dce(0x16a)])())};}catch(_0x31a56f){return console['error'](_0x31a56f),null;}}};d=u([l(0x0,t['IConfigService'])],d);function f(_0x3a3115){'@babel/helpers - typeof';const _0x2345c0=_0x210a58;return f=typeof Symbol==_0x2345c0(0x16c)&&typeof Symbol['iterator']==_0x2345c0(0x191)?function(_0x1cc8ce){return typeof _0x1cc8ce;}:function(_0x5223a3){const _0x3c3dfc=_0x2345c0;return _0x5223a3&&typeof Symbol=='function'&&_0x5223a3['constructor']===Symbol&&_0x5223a3!==Symbol[_0x3c3dfc(0x165)]?_0x3c3dfc(0x191):typeof _0x5223a3;},f(_0x3a3115);}function p(_0x298b24,_0x32eb92){const _0x4f7179=_0x210a58;if(f(_0x298b24)!=_0x4f7179(0x181)||!_0x298b24)return _0x298b24;var _0x35771=_0x298b24[Symbol['toPrimitive']];if(_0x35771!==void 0x0){var _0x1ff50c=_0x35771[_0x4f7179(0x166)](_0x298b24,_0x32eb92||_0x4f7179(0x170));if(f(_0x1ff50c)!=_0x4f7179(0x181))return _0x1ff50c;throw TypeError(_0x4f7179(0x168));}return(_0x32eb92===_0x4f7179(0x15d)?String:Number)(_0x298b24);}function m(_0x3d7377){const _0xccca9a=_0x210a58;var _0x4713dd=p(_0x3d7377,_0xccca9a(0x15d));return f(_0x4713dd)==_0xccca9a(0x191)?_0x4713dd:_0x4713dd+'';}function h(_0x3302c2,_0x256118,_0x51008b){return(_0x256118=m(_0x256118))in _0x3302c2?Object['defineProperty'](_0x3302c2,_0x256118,{'value':_0x51008b,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x3302c2[_0x256118]=_0x51008b,_0x3302c2;}let g=class extends t['Plugin']{constructor(_0xc18c3c=c,_0x2678b3,_0x349d4a){const _0x68e454=_0x210a58;super(),this[_0x68e454(0x155)]=_0xc18c3c,this[_0x68e454(0x18a)]=_0x2678b3,this[_0x68e454(0x17c)]=_0x349d4a;let {..._0x7a563e}=(0x0,t['merge'])({},c,this[_0x68e454(0x155)]);this[_0x68e454(0x18a)][_0x68e454(0x18b)]('collaboration-client-node.config',_0x7a563e);}[_0x210a58(0x169)](){const _0x258bcd=_0x210a58;this[_0x258bcd(0x160)]();}[_0x210a58(0x160)](){const _0x465c75=_0x210a58;(0x0,t[_0x465c75(0x161)])(this['_injector'],[[n[_0x465c75(0x196)],{'useClass':d}]]);}};h(g,_0x210a58(0x164),_0x210a58(0x195)),h(g,_0x210a58(0x17e),o),h(g,_0x210a58(0x18f),s),g=u([(0x0,t['DependentOn'])(e['UniverCollaborationClientPlugin']),l(0x1,t[_0x210a58(0x186)]),l(0x2,(0x0,t[_0x210a58(0x172)])(t[_0x210a58(0x185)]))],g);let _=class extends e[_0x210a58(0x193)]{constructor(_0x57a535,_0x440d87,_0x2c4325,_0x11c58a,_0x37df0e){const _0x416972=_0x210a58;super(_0x57a535,_0x440d87,_0x2c4325,_0x11c58a,_0x37df0e);let _0x575fc0=this['_configService'][_0x416972(0x17d)](e[_0x416972(0x192)]);this['_httpService'][_0x416972(0x184)]({'interceptor':(_0x35cd2d,_0x35d22b)=>{const _0x342491=_0x416972;let _0x2659d7=_0x35cd2d[_0x342491(0x16e)];if(_0x575fc0!=null&&_0x575fc0[_0x342491(0x15b)]){for(let _0x1d709b in _0x575fc0[_0x342491(0x15b)])_0x2659d7[_0x342491(0x15e)](_0x1d709b,_0x575fc0[_0x342491(0x15b)][_0x1d709b]);}return _0x35d22b(_0x35cd2d);}});}async['createSocket'](_0x19d481){const _0x28ca53=_0x210a58;return this[_0x28ca53(0x187)](_0x19d481);}};_=u([l(0x0,(0x0,t[_0x210a58(0x172)])(t[_0x210a58(0x185)])),l(0x1,(0x0,t[_0x210a58(0x172)])(n[_0x210a58(0x178)])),l(0x2,t[_0x210a58(0x186)]),l(0x3,t[_0x210a58(0x157)]),l(0x4,a[_0x210a58(0x17b)])],_),Object[_0x210a58(0x194)](exports,_0x210a58(0x18d),{'enumerable':!0x0,'get':function(){return _;}}),Object['defineProperty'](exports,_0x210a58(0x17a),{'enumerable':!0x0,'get':function(){return g;}});
package/lib/es/index.js CHANGED
@@ -1 +1 @@
1
- const _0x38a325=_0x3c85;function _0x3c85(_0x533b41,_0x22113f){_0x533b41=_0x533b41-0x87;const _0xfd140f=_0xfd14();let _0x3c8521=_0xfd140f[_0x533b41];return _0x3c8521;}(function(_0x349876,_0x530780){const _0x2df364=_0x3c85,_0x138bce=_0x349876();while(!![]){try{const _0x14446c=-parseInt(_0x2df364(0xa1))/0x1+-parseInt(_0x2df364(0x94))/0x2+parseInt(_0x2df364(0xa2))/0x3*(-parseInt(_0x2df364(0xb0))/0x4)+-parseInt(_0x2df364(0x8f))/0x5+parseInt(_0x2df364(0x98))/0x6+parseInt(_0x2df364(0x8c))/0x7*(-parseInt(_0x2df364(0x9a))/0x8)+parseInt(_0x2df364(0xb2))/0x9;if(_0x14446c===_0x530780)break;else _0x138bce['push'](_0x138bce['shift']());}catch(_0x4a0246){_0x138bce['push'](_0x138bce['shift']());}}}(_0xfd14,0x22bbc));import{COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY as _0x4e3118,CollaborationSocketService as _0x5e933c,UniverCollaborationClientPlugin as _0x18cd7e}from'@univerjs-pro/collaboration-client';function _0xfd14(){const _0x2f5555=['removeEventListener','customHeaders','function','constructor','dispose','pipe','set','249244bhrNio','send','6744294uWSujf','prototype','headers','onStarting','defineProperty','getConfig','_registerDependencies','error','symbol','28KintsN','_configService','_doCreateSocket','365025BgBJfS','getOwnPropertyDescriptor','call','_injector','decorate','190862EBhcRr','UNIVER_COLLABORATION_CLIENT_NODE_PLUGIN','pluginName','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','536868KtzbLQ','string','472712KjCUEe','version','_httpService','add','length','message','next','229473EhvwId','3nIwHjf','_config','open','close','setConfig','addEventListener','object'];_0xfd14=function(){return _0x2f5555;};return _0xfd14();}import{DependentOn as _0x22b7ce,Disposable as _0x3bf9dd,DisposableCollection as _0x529636,IConfigService as _0x3968df,ILogService as _0x56462f,Inject as _0x1d2b31,Injector as _0x411600,Plugin as _0x3cfb58,merge as _0x366c6f,registerDependencies as _0x4c09cc,toDisposable as _0x527e8f}from'@univerjs/core';import{HTTPService as _0x6c90c6,ISocketService as _0x484a9b}from'@univerjs/network';import{Observable as _0x51b3c1,share as _0x22da56}from'rxjs';import{WebSocket as _0x1c91ad}from'ws';import{ISnapshotServerService as _0x1fd8cc}from'@univerjs-pro/collaboration';var b='@univerjs-pro/collaboration-client-node',x='1.0.0-alpha.4';const S={};function C(_0x5d2684,_0x2a8c0c){return function(_0xa59add,_0x333a14){_0x2a8c0c(_0xa59add,_0x333a14,_0x5d2684);};}function w(_0x2b1395,_0x4c1c90,_0x5ecb91,_0x13b562){const _0x439716=_0x3c85;var _0x3c6a5d=arguments[_0x439716(0x9e)],_0x3c2327=_0x3c6a5d<0x3?_0x4c1c90:_0x13b562===null?_0x13b562=Object[_0x439716(0x90)](_0x4c1c90,_0x5ecb91):_0x13b562,_0x927407;if(typeof Reflect==_0x439716(0xa8)&&typeof Reflect[_0x439716(0x93)]==_0x439716(0xab))_0x3c2327=Reflect['decorate'](_0x2b1395,_0x4c1c90,_0x5ecb91,_0x13b562);else{for(var _0x8ba523=_0x2b1395[_0x439716(0x9e)]-0x1;_0x8ba523>=0x0;_0x8ba523--)(_0x927407=_0x2b1395[_0x8ba523])&&(_0x3c2327=(_0x3c6a5d<0x3?_0x927407(_0x3c2327):_0x3c6a5d>0x3?_0x927407(_0x4c1c90,_0x5ecb91,_0x3c2327):_0x927407(_0x4c1c90,_0x5ecb91))||_0x3c2327);}return _0x3c6a5d>0x3&&_0x3c2327&&Object[_0x439716(0x87)](_0x4c1c90,_0x5ecb91,_0x3c2327),_0x3c2327;}let T=class extends _0x3bf9dd{constructor(_0x2a4771){super(),this['_configService']=_0x2a4771;}['createSocket'](_0x454122){const _0xbc6b85=_0x3c85;var _0x21a9c9;let _0x29b624=((_0x21a9c9=this[_0xbc6b85(0x8d)][_0xbc6b85(0x88)](_0x4e3118))==null?void 0x0:_0x21a9c9[_0xbc6b85(0xaa)])||{};try{let _0x95e8fc=new _0x1c91ad(_0x454122,{'headers':{..._0x29b624}}),_0x2f90cc=new _0x529636();return{'URL':_0x454122,'close':(_0x17b156,_0x497038)=>{const _0x87048f=_0xbc6b85;_0x95e8fc[_0x87048f(0xa5)](_0x17b156,_0x497038),_0x2f90cc[_0x87048f(0xad)]();},'send':_0x90a167=>{const _0x57e8d4=_0xbc6b85;_0x95e8fc[_0x57e8d4(0xb1)](_0x90a167);},'open$':new _0x51b3c1(_0x59ee8a=>{const _0x19fdc8=_0xbc6b85;let _0x498a55=_0x573f40=>_0x59ee8a['next'](_0x573f40);_0x95e8fc['addEventListener'](_0x19fdc8(0xa4),_0x498a55),_0x2f90cc[_0x19fdc8(0x9d)](_0x527e8f(()=>_0x95e8fc['removeEventListener'](_0x19fdc8(0xa4),_0x498a55)));})[_0xbc6b85(0xae)](_0x22da56()),'close$':new _0x51b3c1(_0x6d4154=>{const _0x3d944f=_0xbc6b85;let _0x54a2cb=_0x26835b=>_0x6d4154[_0x3d944f(0xa0)](_0x26835b);_0x95e8fc[_0x3d944f(0xa7)](_0x3d944f(0xa5),_0x54a2cb),_0x2f90cc[_0x3d944f(0x9d)](_0x527e8f(()=>_0x95e8fc[_0x3d944f(0xa9)](_0x3d944f(0xa5),_0x54a2cb)));})['pipe'](_0x22da56()),'error$':new _0x51b3c1(_0x266e4d=>{const _0x54c342=_0xbc6b85;let _0x45afae=_0x11a7db=>_0x266e4d[_0x54c342(0xa0)](_0x11a7db);_0x95e8fc['addEventListener']('error',_0x45afae),_0x2f90cc['add'](_0x527e8f(()=>_0x95e8fc[_0x54c342(0xa9)]('error',_0x45afae)));})[_0xbc6b85(0xae)](_0x22da56()),'message$':new _0x51b3c1(_0x2a88c1=>{const _0x4a6e37=_0xbc6b85;let _0x577ded=_0x313f66=>_0x2a88c1['next'](_0x313f66);_0x95e8fc['addEventListener'](_0x4a6e37(0x9f),_0x577ded),_0x2f90cc[_0x4a6e37(0x9d)](_0x527e8f(()=>_0x95e8fc[_0x4a6e37(0xa9)](_0x4a6e37(0x9f),_0x577ded)));})[_0xbc6b85(0xae)](_0x22da56())};}catch(_0x3fa4e8){return console[_0xbc6b85(0x8a)](_0x3fa4e8),null;}}};T=w([C(0x0,_0x3968df)],T);function E(_0x2f0ebc){'@babel/helpers - typeof';const _0x2a067b=_0x3c85;return E=typeof Symbol==_0x2a067b(0xab)&&typeof Symbol['iterator']==_0x2a067b(0x8b)?function(_0x15b0ee){return typeof _0x15b0ee;}:function(_0x45857a){const _0x4ef3cc=_0x2a067b;return _0x45857a&&typeof Symbol==_0x4ef3cc(0xab)&&_0x45857a[_0x4ef3cc(0xac)]===Symbol&&_0x45857a!==Symbol[_0x4ef3cc(0xb3)]?_0x4ef3cc(0x8b):typeof _0x45857a;},E(_0x2f0ebc);}function D(_0x35391e,_0x192854){const _0x54dcba=_0x3c85;if(E(_0x35391e)!=_0x54dcba(0xa8)||!_0x35391e)return _0x35391e;var _0x46b014=_0x35391e[Symbol['toPrimitive']];if(_0x46b014!==void 0x0){var _0x2dbe13=_0x46b014[_0x54dcba(0x91)](_0x35391e,_0x192854||'default');if(E(_0x2dbe13)!=_0x54dcba(0xa8))return _0x2dbe13;throw TypeError(_0x54dcba(0x97));}return(_0x192854===_0x54dcba(0x99)?String:Number)(_0x35391e);}function O(_0x5c1462){var _0x271500=D(_0x5c1462,'string');return E(_0x271500)=='symbol'?_0x271500:_0x271500+'';}function k(_0x1181e9,_0x705673,_0x1ee1a0){const _0x39d2be=_0x3c85;return(_0x705673=O(_0x705673))in _0x1181e9?Object[_0x39d2be(0x87)](_0x1181e9,_0x705673,{'value':_0x1ee1a0,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x1181e9[_0x705673]=_0x1ee1a0,_0x1181e9;}let A=class extends _0x3cfb58{constructor(_0x41d8e6=S,_0x5901d9,_0x222d91){const _0x51b3d1=_0x3c85;super(),this['_config']=_0x41d8e6,this[_0x51b3d1(0x8d)]=_0x5901d9,this[_0x51b3d1(0x92)]=_0x222d91;let {..._0x2e67ed}=_0x366c6f({},S,this[_0x51b3d1(0xa3)]);this['_configService'][_0x51b3d1(0xa6)]('collaboration-client-node.config',_0x2e67ed);}[_0x38a325(0xb5)](){const _0x18a548=_0x38a325;this[_0x18a548(0x89)]();}[_0x38a325(0x89)](){const _0x45112d=_0x38a325;_0x4c09cc(this[_0x45112d(0x92)],[[_0x484a9b,{'useClass':T}]]);}};k(A,_0x38a325(0x96),_0x38a325(0x95)),k(A,'packageName',b),k(A,_0x38a325(0x9b),x),A=w([_0x22b7ce(_0x18cd7e),C(0x1,_0x3968df),C(0x2,_0x1d2b31(_0x411600))],A);let j=class extends _0x5e933c{constructor(_0x3fc0e0,_0x304ad2,_0x3b2d27,_0x1f8281,_0x6bbb9e){const _0x4db6c8=_0x38a325;super(_0x3fc0e0,_0x304ad2,_0x3b2d27,_0x1f8281,_0x6bbb9e);let _0x22b7fa=this[_0x4db6c8(0x8d)]['getConfig'](_0x4e3118);this[_0x4db6c8(0x9c)]['registerHTTPInterceptor']({'interceptor':(_0x10ee17,_0x10c50f)=>{const _0x400991=_0x4db6c8;let _0x5fd8c9=_0x10ee17[_0x400991(0xb4)];if(_0x22b7fa!=null&&_0x22b7fa['customHeaders']){for(let _0x2bc82d in _0x22b7fa[_0x400991(0xaa)])_0x5fd8c9[_0x400991(0xaf)](_0x2bc82d,_0x22b7fa['customHeaders'][_0x2bc82d]);}return _0x10c50f(_0x10ee17);}});}async['createSocket'](_0xcb9cb5){const _0x11443b=_0x38a325;return this[_0x11443b(0x8e)](_0xcb9cb5);}};j=w([C(0x0,_0x1d2b31(_0x411600)),C(0x1,_0x1d2b31(_0x6c90c6)),C(0x2,_0x3968df),C(0x3,_0x56462f),C(0x4,_0x1fd8cc)],j);export{j as NodeCollaborationSocketService,A as UniverCollaborationClientNodePlugin};
1
+ const _0x6f2f3f=_0x5431;(function(_0xee31c2,_0x463552){const _0x473698=_0x5431,_0x23de25=_0xee31c2();while(!![]){try{const _0x559b5b=-parseInt(_0x473698(0xe6))/0x1+parseInt(_0x473698(0xd9))/0x2+-parseInt(_0x473698(0xd1))/0x3*(-parseInt(_0x473698(0xbc))/0x4)+-parseInt(_0x473698(0xb9))/0x5+parseInt(_0x473698(0xbe))/0x6+-parseInt(_0x473698(0xe9))/0x7*(parseInt(_0x473698(0xc1))/0x8)+-parseInt(_0x473698(0xcb))/0x9;if(_0x559b5b===_0x463552)break;else _0x23de25['push'](_0x23de25['shift']());}catch(_0x13acf9){_0x23de25['push'](_0x23de25['shift']());}}}(_0x457c,0x3ee4d));import{COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY as _0x5e7c43,CollaborationSocketService as _0x259f6f,UniverCollaborationClientPlugin as _0x3e3489}from'@univerjs-pro/collaboration-client';import{DependentOn as _0x2f5f78,Disposable as _0x1ebedc,DisposableCollection as _0x2b3acc,IConfigService as _0x3a7a90,ILogService as _0x34b83e,Inject as _0x3babd1,Injector as _0x5d8c04,Plugin as _0xa4996a,merge as _0x53778d,registerDependencies as _0x5d402c,toDisposable as _0x239723}from'@univerjs/core';import{HTTPService as _0x377abe,ISocketService as _0x460b5a}from'@univerjs/network';import{Observable as _0x165fc0,share as _0x5b23a5}from'rxjs';import{WebSocket as _0x1c8900}from'ws';import{ISnapshotServerService as _0x6cc045}from'@univerjs-pro/collaboration';var b=_0x6f2f3f(0xd5),x=_0x6f2f3f(0xd2);const S={};function C(_0x2c933e,_0xf31fbf){return function(_0x4b96b8,_0x404b68){_0xf31fbf(_0x4b96b8,_0x404b68,_0x2c933e);};}function _0x457c(){const _0x4687de=['addEventListener','registerHTTPInterceptor','_config','54JErpus','1.0.0-alpha.5','createSocket','dispose','@univerjs-pro/collaboration-client-node','defineProperty','object','send','859200lEVDrm','string','decorate','customHeaders','packageName','getOwnPropertyDescriptor','_registerDependencies','_httpService','length','_configService','open','_injector','toPrimitive','354695TdpVvj','getConfig','iterator','105dOnAjL','message','pipe','setConfig','1161305OqhFpu','set','_doCreateSocket','51836wJuoSj','version','2967714TXlsvX','pluginName','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','33048XrkbuD','function','error','next','removeEventListener','close','call','prototype','add','onStarting','2258523CpAIZW','constructor','UNIVER_COLLABORATION_CLIENT_NODE_PLUGIN'];_0x457c=function(){return _0x4687de;};return _0x457c();}function w(_0x498a7c,_0x4ad69f,_0x33b57a,_0xc6a8cb){const _0x3cd78f=_0x6f2f3f;var _0xa49b6a=arguments['length'],_0xa2969c=_0xa49b6a<0x3?_0x4ad69f:_0xc6a8cb===null?_0xc6a8cb=Object[_0x3cd78f(0xde)](_0x4ad69f,_0x33b57a):_0xc6a8cb,_0x1053dd;if(typeof Reflect==_0x3cd78f(0xd7)&&typeof Reflect[_0x3cd78f(0xdb)]=='function')_0xa2969c=Reflect['decorate'](_0x498a7c,_0x4ad69f,_0x33b57a,_0xc6a8cb);else{for(var _0x3314b=_0x498a7c[_0x3cd78f(0xe1)]-0x1;_0x3314b>=0x0;_0x3314b--)(_0x1053dd=_0x498a7c[_0x3314b])&&(_0xa2969c=(_0xa49b6a<0x3?_0x1053dd(_0xa2969c):_0xa49b6a>0x3?_0x1053dd(_0x4ad69f,_0x33b57a,_0xa2969c):_0x1053dd(_0x4ad69f,_0x33b57a))||_0xa2969c);}return _0xa49b6a>0x3&&_0xa2969c&&Object[_0x3cd78f(0xd6)](_0x4ad69f,_0x33b57a,_0xa2969c),_0xa2969c;}let T=class extends _0x1ebedc{constructor(_0x1b5837){const _0x13e1f7=_0x6f2f3f;super(),this[_0x13e1f7(0xe2)]=_0x1b5837;}[_0x6f2f3f(0xd3)](_0x458cc6){const _0x43b61b=_0x6f2f3f;var _0xb62a0f;let _0x1441d1=((_0xb62a0f=this[_0x43b61b(0xe2)][_0x43b61b(0xe7)](_0x5e7c43))==null?void 0x0:_0xb62a0f['customHeaders'])||{};try{let _0x369b96=new _0x1c8900(_0x458cc6,{'headers':{..._0x1441d1}}),_0x47ef5b=new _0x2b3acc();return{'URL':_0x458cc6,'close':(_0x281e7b,_0x53ff8d)=>{const _0x354183=_0x43b61b;_0x369b96['close'](_0x281e7b,_0x53ff8d),_0x47ef5b[_0x354183(0xd4)]();},'send':_0x2601e1=>{const _0x5d3c57=_0x43b61b;_0x369b96[_0x5d3c57(0xd8)](_0x2601e1);},'open$':new _0x165fc0(_0x3f3171=>{const _0x3c8ac6=_0x43b61b;let _0x42780a=_0x1afd47=>_0x3f3171[_0x3c8ac6(0xc4)](_0x1afd47);_0x369b96[_0x3c8ac6(0xce)]('open',_0x42780a),_0x47ef5b[_0x3c8ac6(0xc9)](_0x239723(()=>_0x369b96[_0x3c8ac6(0xc5)](_0x3c8ac6(0xe3),_0x42780a)));})[_0x43b61b(0xb7)](_0x5b23a5()),'close$':new _0x165fc0(_0x53da4b=>{const _0x4e28af=_0x43b61b;let _0x5906b7=_0x4c3a92=>_0x53da4b[_0x4e28af(0xc4)](_0x4c3a92);_0x369b96[_0x4e28af(0xce)](_0x4e28af(0xc6),_0x5906b7),_0x47ef5b['add'](_0x239723(()=>_0x369b96[_0x4e28af(0xc5)](_0x4e28af(0xc6),_0x5906b7)));})['pipe'](_0x5b23a5()),'error$':new _0x165fc0(_0x1da99e=>{const _0x2922c5=_0x43b61b;let _0x3d268e=_0x182e66=>_0x1da99e[_0x2922c5(0xc4)](_0x182e66);_0x369b96[_0x2922c5(0xce)]('error',_0x3d268e),_0x47ef5b['add'](_0x239723(()=>_0x369b96[_0x2922c5(0xc5)]('error',_0x3d268e)));})[_0x43b61b(0xb7)](_0x5b23a5()),'message$':new _0x165fc0(_0x239cfd=>{const _0x705346=_0x43b61b;let _0x4cda38=_0xb4469f=>_0x239cfd['next'](_0xb4469f);_0x369b96['addEventListener'](_0x705346(0xb6),_0x4cda38),_0x47ef5b[_0x705346(0xc9)](_0x239723(()=>_0x369b96[_0x705346(0xc5)](_0x705346(0xb6),_0x4cda38)));})[_0x43b61b(0xb7)](_0x5b23a5())};}catch(_0x1c57db){return console[_0x43b61b(0xc3)](_0x1c57db),null;}}};T=w([C(0x0,_0x3a7a90)],T);function E(_0x30d0b6){'@babel/helpers - typeof';const _0x44f5f8=_0x6f2f3f;return E=typeof Symbol==_0x44f5f8(0xc2)&&typeof Symbol[_0x44f5f8(0xe8)]=='symbol'?function(_0x2454bc){return typeof _0x2454bc;}:function(_0x31642d){const _0x251c4e=_0x44f5f8;return _0x31642d&&typeof Symbol=='function'&&_0x31642d[_0x251c4e(0xcc)]===Symbol&&_0x31642d!==Symbol[_0x251c4e(0xc8)]?'symbol':typeof _0x31642d;},E(_0x30d0b6);}function D(_0x282819,_0x38763a){const _0x4e1f3c=_0x6f2f3f;if(E(_0x282819)!=_0x4e1f3c(0xd7)||!_0x282819)return _0x282819;var _0x168bc1=_0x282819[Symbol[_0x4e1f3c(0xe5)]];if(_0x168bc1!==void 0x0){var _0x5a28d6=_0x168bc1[_0x4e1f3c(0xc7)](_0x282819,_0x38763a||'default');if(E(_0x5a28d6)!=_0x4e1f3c(0xd7))return _0x5a28d6;throw TypeError(_0x4e1f3c(0xc0));}return(_0x38763a===_0x4e1f3c(0xda)?String:Number)(_0x282819);}function O(_0x1bdd37){const _0x2dbaeb=_0x6f2f3f;var _0x4958bc=D(_0x1bdd37,_0x2dbaeb(0xda));return E(_0x4958bc)=='symbol'?_0x4958bc:_0x4958bc+'';}function k(_0x28bff3,_0x57ecc3,_0x4989bf){const _0x3a962f=_0x6f2f3f;return(_0x57ecc3=O(_0x57ecc3))in _0x28bff3?Object[_0x3a962f(0xd6)](_0x28bff3,_0x57ecc3,{'value':_0x4989bf,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x28bff3[_0x57ecc3]=_0x4989bf,_0x28bff3;}function _0x5431(_0xa831ad,_0x4e5666){_0xa831ad=_0xa831ad-0xb6;const _0x457cb0=_0x457c();let _0x543115=_0x457cb0[_0xa831ad];return _0x543115;}let A=class extends _0xa4996a{constructor(_0x370fd9=S,_0x91d76b,_0x299f02){const _0x2e8fb5=_0x6f2f3f;super(),this[_0x2e8fb5(0xd0)]=_0x370fd9,this[_0x2e8fb5(0xe2)]=_0x91d76b,this['_injector']=_0x299f02;let {..._0x39d796}=_0x53778d({},S,this[_0x2e8fb5(0xd0)]);this[_0x2e8fb5(0xe2)][_0x2e8fb5(0xb8)]('collaboration-client-node.config',_0x39d796);}[_0x6f2f3f(0xca)](){const _0x3aaaee=_0x6f2f3f;this[_0x3aaaee(0xdf)]();}[_0x6f2f3f(0xdf)](){const _0x48b367=_0x6f2f3f;_0x5d402c(this[_0x48b367(0xe4)],[[_0x460b5a,{'useClass':T}]]);}};k(A,_0x6f2f3f(0xbf),_0x6f2f3f(0xcd)),k(A,_0x6f2f3f(0xdd),b),k(A,_0x6f2f3f(0xbd),x),A=w([_0x2f5f78(_0x3e3489),C(0x1,_0x3a7a90),C(0x2,_0x3babd1(_0x5d8c04))],A);let j=class extends _0x259f6f{constructor(_0x5c11cd,_0x1a8288,_0x591763,_0x15dd77,_0x55ccaa){const _0x5548f4=_0x6f2f3f;super(_0x5c11cd,_0x1a8288,_0x591763,_0x15dd77,_0x55ccaa);let _0x31d715=this[_0x5548f4(0xe2)][_0x5548f4(0xe7)](_0x5e7c43);this[_0x5548f4(0xe0)][_0x5548f4(0xcf)]({'interceptor':(_0x1f5039,_0x5ace85)=>{const _0x5c8153=_0x5548f4;let _0x1480c2=_0x1f5039['headers'];if(_0x31d715!=null&&_0x31d715[_0x5c8153(0xdc)]){for(let _0x4f5b1c in _0x31d715[_0x5c8153(0xdc)])_0x1480c2[_0x5c8153(0xba)](_0x4f5b1c,_0x31d715[_0x5c8153(0xdc)][_0x4f5b1c]);}return _0x5ace85(_0x1f5039);}});}async[_0x6f2f3f(0xd3)](_0x2b905a){const _0x4712d1=_0x6f2f3f;return this[_0x4712d1(0xbb)](_0x2b905a);}};j=w([C(0x0,_0x3babd1(_0x5d8c04)),C(0x1,_0x3babd1(_0x377abe)),C(0x2,_0x3a7a90),C(0x3,_0x34b83e),C(0x4,_0x6cc045)],j);export{j as NodeCollaborationSocketService,A as UniverCollaborationClientNodePlugin};
package/lib/index.js CHANGED
@@ -1 +1 @@
1
- const _0x38a325=_0x3c85;function _0x3c85(_0x533b41,_0x22113f){_0x533b41=_0x533b41-0x87;const _0xfd140f=_0xfd14();let _0x3c8521=_0xfd140f[_0x533b41];return _0x3c8521;}(function(_0x349876,_0x530780){const _0x2df364=_0x3c85,_0x138bce=_0x349876();while(!![]){try{const _0x14446c=-parseInt(_0x2df364(0xa1))/0x1+-parseInt(_0x2df364(0x94))/0x2+parseInt(_0x2df364(0xa2))/0x3*(-parseInt(_0x2df364(0xb0))/0x4)+-parseInt(_0x2df364(0x8f))/0x5+parseInt(_0x2df364(0x98))/0x6+parseInt(_0x2df364(0x8c))/0x7*(-parseInt(_0x2df364(0x9a))/0x8)+parseInt(_0x2df364(0xb2))/0x9;if(_0x14446c===_0x530780)break;else _0x138bce['push'](_0x138bce['shift']());}catch(_0x4a0246){_0x138bce['push'](_0x138bce['shift']());}}}(_0xfd14,0x22bbc));import{COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY as _0x4e3118,CollaborationSocketService as _0x5e933c,UniverCollaborationClientPlugin as _0x18cd7e}from'@univerjs-pro/collaboration-client';function _0xfd14(){const _0x2f5555=['removeEventListener','customHeaders','function','constructor','dispose','pipe','set','249244bhrNio','send','6744294uWSujf','prototype','headers','onStarting','defineProperty','getConfig','_registerDependencies','error','symbol','28KintsN','_configService','_doCreateSocket','365025BgBJfS','getOwnPropertyDescriptor','call','_injector','decorate','190862EBhcRr','UNIVER_COLLABORATION_CLIENT_NODE_PLUGIN','pluginName','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','536868KtzbLQ','string','472712KjCUEe','version','_httpService','add','length','message','next','229473EhvwId','3nIwHjf','_config','open','close','setConfig','addEventListener','object'];_0xfd14=function(){return _0x2f5555;};return _0xfd14();}import{DependentOn as _0x22b7ce,Disposable as _0x3bf9dd,DisposableCollection as _0x529636,IConfigService as _0x3968df,ILogService as _0x56462f,Inject as _0x1d2b31,Injector as _0x411600,Plugin as _0x3cfb58,merge as _0x366c6f,registerDependencies as _0x4c09cc,toDisposable as _0x527e8f}from'@univerjs/core';import{HTTPService as _0x6c90c6,ISocketService as _0x484a9b}from'@univerjs/network';import{Observable as _0x51b3c1,share as _0x22da56}from'rxjs';import{WebSocket as _0x1c91ad}from'ws';import{ISnapshotServerService as _0x1fd8cc}from'@univerjs-pro/collaboration';var b='@univerjs-pro/collaboration-client-node',x='1.0.0-alpha.4';const S={};function C(_0x5d2684,_0x2a8c0c){return function(_0xa59add,_0x333a14){_0x2a8c0c(_0xa59add,_0x333a14,_0x5d2684);};}function w(_0x2b1395,_0x4c1c90,_0x5ecb91,_0x13b562){const _0x439716=_0x3c85;var _0x3c6a5d=arguments[_0x439716(0x9e)],_0x3c2327=_0x3c6a5d<0x3?_0x4c1c90:_0x13b562===null?_0x13b562=Object[_0x439716(0x90)](_0x4c1c90,_0x5ecb91):_0x13b562,_0x927407;if(typeof Reflect==_0x439716(0xa8)&&typeof Reflect[_0x439716(0x93)]==_0x439716(0xab))_0x3c2327=Reflect['decorate'](_0x2b1395,_0x4c1c90,_0x5ecb91,_0x13b562);else{for(var _0x8ba523=_0x2b1395[_0x439716(0x9e)]-0x1;_0x8ba523>=0x0;_0x8ba523--)(_0x927407=_0x2b1395[_0x8ba523])&&(_0x3c2327=(_0x3c6a5d<0x3?_0x927407(_0x3c2327):_0x3c6a5d>0x3?_0x927407(_0x4c1c90,_0x5ecb91,_0x3c2327):_0x927407(_0x4c1c90,_0x5ecb91))||_0x3c2327);}return _0x3c6a5d>0x3&&_0x3c2327&&Object[_0x439716(0x87)](_0x4c1c90,_0x5ecb91,_0x3c2327),_0x3c2327;}let T=class extends _0x3bf9dd{constructor(_0x2a4771){super(),this['_configService']=_0x2a4771;}['createSocket'](_0x454122){const _0xbc6b85=_0x3c85;var _0x21a9c9;let _0x29b624=((_0x21a9c9=this[_0xbc6b85(0x8d)][_0xbc6b85(0x88)](_0x4e3118))==null?void 0x0:_0x21a9c9[_0xbc6b85(0xaa)])||{};try{let _0x95e8fc=new _0x1c91ad(_0x454122,{'headers':{..._0x29b624}}),_0x2f90cc=new _0x529636();return{'URL':_0x454122,'close':(_0x17b156,_0x497038)=>{const _0x87048f=_0xbc6b85;_0x95e8fc[_0x87048f(0xa5)](_0x17b156,_0x497038),_0x2f90cc[_0x87048f(0xad)]();},'send':_0x90a167=>{const _0x57e8d4=_0xbc6b85;_0x95e8fc[_0x57e8d4(0xb1)](_0x90a167);},'open$':new _0x51b3c1(_0x59ee8a=>{const _0x19fdc8=_0xbc6b85;let _0x498a55=_0x573f40=>_0x59ee8a['next'](_0x573f40);_0x95e8fc['addEventListener'](_0x19fdc8(0xa4),_0x498a55),_0x2f90cc[_0x19fdc8(0x9d)](_0x527e8f(()=>_0x95e8fc['removeEventListener'](_0x19fdc8(0xa4),_0x498a55)));})[_0xbc6b85(0xae)](_0x22da56()),'close$':new _0x51b3c1(_0x6d4154=>{const _0x3d944f=_0xbc6b85;let _0x54a2cb=_0x26835b=>_0x6d4154[_0x3d944f(0xa0)](_0x26835b);_0x95e8fc[_0x3d944f(0xa7)](_0x3d944f(0xa5),_0x54a2cb),_0x2f90cc[_0x3d944f(0x9d)](_0x527e8f(()=>_0x95e8fc[_0x3d944f(0xa9)](_0x3d944f(0xa5),_0x54a2cb)));})['pipe'](_0x22da56()),'error$':new _0x51b3c1(_0x266e4d=>{const _0x54c342=_0xbc6b85;let _0x45afae=_0x11a7db=>_0x266e4d[_0x54c342(0xa0)](_0x11a7db);_0x95e8fc['addEventListener']('error',_0x45afae),_0x2f90cc['add'](_0x527e8f(()=>_0x95e8fc[_0x54c342(0xa9)]('error',_0x45afae)));})[_0xbc6b85(0xae)](_0x22da56()),'message$':new _0x51b3c1(_0x2a88c1=>{const _0x4a6e37=_0xbc6b85;let _0x577ded=_0x313f66=>_0x2a88c1['next'](_0x313f66);_0x95e8fc['addEventListener'](_0x4a6e37(0x9f),_0x577ded),_0x2f90cc[_0x4a6e37(0x9d)](_0x527e8f(()=>_0x95e8fc[_0x4a6e37(0xa9)](_0x4a6e37(0x9f),_0x577ded)));})[_0xbc6b85(0xae)](_0x22da56())};}catch(_0x3fa4e8){return console[_0xbc6b85(0x8a)](_0x3fa4e8),null;}}};T=w([C(0x0,_0x3968df)],T);function E(_0x2f0ebc){'@babel/helpers - typeof';const _0x2a067b=_0x3c85;return E=typeof Symbol==_0x2a067b(0xab)&&typeof Symbol['iterator']==_0x2a067b(0x8b)?function(_0x15b0ee){return typeof _0x15b0ee;}:function(_0x45857a){const _0x4ef3cc=_0x2a067b;return _0x45857a&&typeof Symbol==_0x4ef3cc(0xab)&&_0x45857a[_0x4ef3cc(0xac)]===Symbol&&_0x45857a!==Symbol[_0x4ef3cc(0xb3)]?_0x4ef3cc(0x8b):typeof _0x45857a;},E(_0x2f0ebc);}function D(_0x35391e,_0x192854){const _0x54dcba=_0x3c85;if(E(_0x35391e)!=_0x54dcba(0xa8)||!_0x35391e)return _0x35391e;var _0x46b014=_0x35391e[Symbol['toPrimitive']];if(_0x46b014!==void 0x0){var _0x2dbe13=_0x46b014[_0x54dcba(0x91)](_0x35391e,_0x192854||'default');if(E(_0x2dbe13)!=_0x54dcba(0xa8))return _0x2dbe13;throw TypeError(_0x54dcba(0x97));}return(_0x192854===_0x54dcba(0x99)?String:Number)(_0x35391e);}function O(_0x5c1462){var _0x271500=D(_0x5c1462,'string');return E(_0x271500)=='symbol'?_0x271500:_0x271500+'';}function k(_0x1181e9,_0x705673,_0x1ee1a0){const _0x39d2be=_0x3c85;return(_0x705673=O(_0x705673))in _0x1181e9?Object[_0x39d2be(0x87)](_0x1181e9,_0x705673,{'value':_0x1ee1a0,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x1181e9[_0x705673]=_0x1ee1a0,_0x1181e9;}let A=class extends _0x3cfb58{constructor(_0x41d8e6=S,_0x5901d9,_0x222d91){const _0x51b3d1=_0x3c85;super(),this['_config']=_0x41d8e6,this[_0x51b3d1(0x8d)]=_0x5901d9,this[_0x51b3d1(0x92)]=_0x222d91;let {..._0x2e67ed}=_0x366c6f({},S,this[_0x51b3d1(0xa3)]);this['_configService'][_0x51b3d1(0xa6)]('collaboration-client-node.config',_0x2e67ed);}[_0x38a325(0xb5)](){const _0x18a548=_0x38a325;this[_0x18a548(0x89)]();}[_0x38a325(0x89)](){const _0x45112d=_0x38a325;_0x4c09cc(this[_0x45112d(0x92)],[[_0x484a9b,{'useClass':T}]]);}};k(A,_0x38a325(0x96),_0x38a325(0x95)),k(A,'packageName',b),k(A,_0x38a325(0x9b),x),A=w([_0x22b7ce(_0x18cd7e),C(0x1,_0x3968df),C(0x2,_0x1d2b31(_0x411600))],A);let j=class extends _0x5e933c{constructor(_0x3fc0e0,_0x304ad2,_0x3b2d27,_0x1f8281,_0x6bbb9e){const _0x4db6c8=_0x38a325;super(_0x3fc0e0,_0x304ad2,_0x3b2d27,_0x1f8281,_0x6bbb9e);let _0x22b7fa=this[_0x4db6c8(0x8d)]['getConfig'](_0x4e3118);this[_0x4db6c8(0x9c)]['registerHTTPInterceptor']({'interceptor':(_0x10ee17,_0x10c50f)=>{const _0x400991=_0x4db6c8;let _0x5fd8c9=_0x10ee17[_0x400991(0xb4)];if(_0x22b7fa!=null&&_0x22b7fa['customHeaders']){for(let _0x2bc82d in _0x22b7fa[_0x400991(0xaa)])_0x5fd8c9[_0x400991(0xaf)](_0x2bc82d,_0x22b7fa['customHeaders'][_0x2bc82d]);}return _0x10c50f(_0x10ee17);}});}async['createSocket'](_0xcb9cb5){const _0x11443b=_0x38a325;return this[_0x11443b(0x8e)](_0xcb9cb5);}};j=w([C(0x0,_0x1d2b31(_0x411600)),C(0x1,_0x1d2b31(_0x6c90c6)),C(0x2,_0x3968df),C(0x3,_0x56462f),C(0x4,_0x1fd8cc)],j);export{j as NodeCollaborationSocketService,A as UniverCollaborationClientNodePlugin};
1
+ const _0x6f2f3f=_0x5431;(function(_0xee31c2,_0x463552){const _0x473698=_0x5431,_0x23de25=_0xee31c2();while(!![]){try{const _0x559b5b=-parseInt(_0x473698(0xe6))/0x1+parseInt(_0x473698(0xd9))/0x2+-parseInt(_0x473698(0xd1))/0x3*(-parseInt(_0x473698(0xbc))/0x4)+-parseInt(_0x473698(0xb9))/0x5+parseInt(_0x473698(0xbe))/0x6+-parseInt(_0x473698(0xe9))/0x7*(parseInt(_0x473698(0xc1))/0x8)+-parseInt(_0x473698(0xcb))/0x9;if(_0x559b5b===_0x463552)break;else _0x23de25['push'](_0x23de25['shift']());}catch(_0x13acf9){_0x23de25['push'](_0x23de25['shift']());}}}(_0x457c,0x3ee4d));import{COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY as _0x5e7c43,CollaborationSocketService as _0x259f6f,UniverCollaborationClientPlugin as _0x3e3489}from'@univerjs-pro/collaboration-client';import{DependentOn as _0x2f5f78,Disposable as _0x1ebedc,DisposableCollection as _0x2b3acc,IConfigService as _0x3a7a90,ILogService as _0x34b83e,Inject as _0x3babd1,Injector as _0x5d8c04,Plugin as _0xa4996a,merge as _0x53778d,registerDependencies as _0x5d402c,toDisposable as _0x239723}from'@univerjs/core';import{HTTPService as _0x377abe,ISocketService as _0x460b5a}from'@univerjs/network';import{Observable as _0x165fc0,share as _0x5b23a5}from'rxjs';import{WebSocket as _0x1c8900}from'ws';import{ISnapshotServerService as _0x6cc045}from'@univerjs-pro/collaboration';var b=_0x6f2f3f(0xd5),x=_0x6f2f3f(0xd2);const S={};function C(_0x2c933e,_0xf31fbf){return function(_0x4b96b8,_0x404b68){_0xf31fbf(_0x4b96b8,_0x404b68,_0x2c933e);};}function _0x457c(){const _0x4687de=['addEventListener','registerHTTPInterceptor','_config','54JErpus','1.0.0-alpha.5','createSocket','dispose','@univerjs-pro/collaboration-client-node','defineProperty','object','send','859200lEVDrm','string','decorate','customHeaders','packageName','getOwnPropertyDescriptor','_registerDependencies','_httpService','length','_configService','open','_injector','toPrimitive','354695TdpVvj','getConfig','iterator','105dOnAjL','message','pipe','setConfig','1161305OqhFpu','set','_doCreateSocket','51836wJuoSj','version','2967714TXlsvX','pluginName','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','33048XrkbuD','function','error','next','removeEventListener','close','call','prototype','add','onStarting','2258523CpAIZW','constructor','UNIVER_COLLABORATION_CLIENT_NODE_PLUGIN'];_0x457c=function(){return _0x4687de;};return _0x457c();}function w(_0x498a7c,_0x4ad69f,_0x33b57a,_0xc6a8cb){const _0x3cd78f=_0x6f2f3f;var _0xa49b6a=arguments['length'],_0xa2969c=_0xa49b6a<0x3?_0x4ad69f:_0xc6a8cb===null?_0xc6a8cb=Object[_0x3cd78f(0xde)](_0x4ad69f,_0x33b57a):_0xc6a8cb,_0x1053dd;if(typeof Reflect==_0x3cd78f(0xd7)&&typeof Reflect[_0x3cd78f(0xdb)]=='function')_0xa2969c=Reflect['decorate'](_0x498a7c,_0x4ad69f,_0x33b57a,_0xc6a8cb);else{for(var _0x3314b=_0x498a7c[_0x3cd78f(0xe1)]-0x1;_0x3314b>=0x0;_0x3314b--)(_0x1053dd=_0x498a7c[_0x3314b])&&(_0xa2969c=(_0xa49b6a<0x3?_0x1053dd(_0xa2969c):_0xa49b6a>0x3?_0x1053dd(_0x4ad69f,_0x33b57a,_0xa2969c):_0x1053dd(_0x4ad69f,_0x33b57a))||_0xa2969c);}return _0xa49b6a>0x3&&_0xa2969c&&Object[_0x3cd78f(0xd6)](_0x4ad69f,_0x33b57a,_0xa2969c),_0xa2969c;}let T=class extends _0x1ebedc{constructor(_0x1b5837){const _0x13e1f7=_0x6f2f3f;super(),this[_0x13e1f7(0xe2)]=_0x1b5837;}[_0x6f2f3f(0xd3)](_0x458cc6){const _0x43b61b=_0x6f2f3f;var _0xb62a0f;let _0x1441d1=((_0xb62a0f=this[_0x43b61b(0xe2)][_0x43b61b(0xe7)](_0x5e7c43))==null?void 0x0:_0xb62a0f['customHeaders'])||{};try{let _0x369b96=new _0x1c8900(_0x458cc6,{'headers':{..._0x1441d1}}),_0x47ef5b=new _0x2b3acc();return{'URL':_0x458cc6,'close':(_0x281e7b,_0x53ff8d)=>{const _0x354183=_0x43b61b;_0x369b96['close'](_0x281e7b,_0x53ff8d),_0x47ef5b[_0x354183(0xd4)]();},'send':_0x2601e1=>{const _0x5d3c57=_0x43b61b;_0x369b96[_0x5d3c57(0xd8)](_0x2601e1);},'open$':new _0x165fc0(_0x3f3171=>{const _0x3c8ac6=_0x43b61b;let _0x42780a=_0x1afd47=>_0x3f3171[_0x3c8ac6(0xc4)](_0x1afd47);_0x369b96[_0x3c8ac6(0xce)]('open',_0x42780a),_0x47ef5b[_0x3c8ac6(0xc9)](_0x239723(()=>_0x369b96[_0x3c8ac6(0xc5)](_0x3c8ac6(0xe3),_0x42780a)));})[_0x43b61b(0xb7)](_0x5b23a5()),'close$':new _0x165fc0(_0x53da4b=>{const _0x4e28af=_0x43b61b;let _0x5906b7=_0x4c3a92=>_0x53da4b[_0x4e28af(0xc4)](_0x4c3a92);_0x369b96[_0x4e28af(0xce)](_0x4e28af(0xc6),_0x5906b7),_0x47ef5b['add'](_0x239723(()=>_0x369b96[_0x4e28af(0xc5)](_0x4e28af(0xc6),_0x5906b7)));})['pipe'](_0x5b23a5()),'error$':new _0x165fc0(_0x1da99e=>{const _0x2922c5=_0x43b61b;let _0x3d268e=_0x182e66=>_0x1da99e[_0x2922c5(0xc4)](_0x182e66);_0x369b96[_0x2922c5(0xce)]('error',_0x3d268e),_0x47ef5b['add'](_0x239723(()=>_0x369b96[_0x2922c5(0xc5)]('error',_0x3d268e)));})[_0x43b61b(0xb7)](_0x5b23a5()),'message$':new _0x165fc0(_0x239cfd=>{const _0x705346=_0x43b61b;let _0x4cda38=_0xb4469f=>_0x239cfd['next'](_0xb4469f);_0x369b96['addEventListener'](_0x705346(0xb6),_0x4cda38),_0x47ef5b[_0x705346(0xc9)](_0x239723(()=>_0x369b96[_0x705346(0xc5)](_0x705346(0xb6),_0x4cda38)));})[_0x43b61b(0xb7)](_0x5b23a5())};}catch(_0x1c57db){return console[_0x43b61b(0xc3)](_0x1c57db),null;}}};T=w([C(0x0,_0x3a7a90)],T);function E(_0x30d0b6){'@babel/helpers - typeof';const _0x44f5f8=_0x6f2f3f;return E=typeof Symbol==_0x44f5f8(0xc2)&&typeof Symbol[_0x44f5f8(0xe8)]=='symbol'?function(_0x2454bc){return typeof _0x2454bc;}:function(_0x31642d){const _0x251c4e=_0x44f5f8;return _0x31642d&&typeof Symbol=='function'&&_0x31642d[_0x251c4e(0xcc)]===Symbol&&_0x31642d!==Symbol[_0x251c4e(0xc8)]?'symbol':typeof _0x31642d;},E(_0x30d0b6);}function D(_0x282819,_0x38763a){const _0x4e1f3c=_0x6f2f3f;if(E(_0x282819)!=_0x4e1f3c(0xd7)||!_0x282819)return _0x282819;var _0x168bc1=_0x282819[Symbol[_0x4e1f3c(0xe5)]];if(_0x168bc1!==void 0x0){var _0x5a28d6=_0x168bc1[_0x4e1f3c(0xc7)](_0x282819,_0x38763a||'default');if(E(_0x5a28d6)!=_0x4e1f3c(0xd7))return _0x5a28d6;throw TypeError(_0x4e1f3c(0xc0));}return(_0x38763a===_0x4e1f3c(0xda)?String:Number)(_0x282819);}function O(_0x1bdd37){const _0x2dbaeb=_0x6f2f3f;var _0x4958bc=D(_0x1bdd37,_0x2dbaeb(0xda));return E(_0x4958bc)=='symbol'?_0x4958bc:_0x4958bc+'';}function k(_0x28bff3,_0x57ecc3,_0x4989bf){const _0x3a962f=_0x6f2f3f;return(_0x57ecc3=O(_0x57ecc3))in _0x28bff3?Object[_0x3a962f(0xd6)](_0x28bff3,_0x57ecc3,{'value':_0x4989bf,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x28bff3[_0x57ecc3]=_0x4989bf,_0x28bff3;}function _0x5431(_0xa831ad,_0x4e5666){_0xa831ad=_0xa831ad-0xb6;const _0x457cb0=_0x457c();let _0x543115=_0x457cb0[_0xa831ad];return _0x543115;}let A=class extends _0xa4996a{constructor(_0x370fd9=S,_0x91d76b,_0x299f02){const _0x2e8fb5=_0x6f2f3f;super(),this[_0x2e8fb5(0xd0)]=_0x370fd9,this[_0x2e8fb5(0xe2)]=_0x91d76b,this['_injector']=_0x299f02;let {..._0x39d796}=_0x53778d({},S,this[_0x2e8fb5(0xd0)]);this[_0x2e8fb5(0xe2)][_0x2e8fb5(0xb8)]('collaboration-client-node.config',_0x39d796);}[_0x6f2f3f(0xca)](){const _0x3aaaee=_0x6f2f3f;this[_0x3aaaee(0xdf)]();}[_0x6f2f3f(0xdf)](){const _0x48b367=_0x6f2f3f;_0x5d402c(this[_0x48b367(0xe4)],[[_0x460b5a,{'useClass':T}]]);}};k(A,_0x6f2f3f(0xbf),_0x6f2f3f(0xcd)),k(A,_0x6f2f3f(0xdd),b),k(A,_0x6f2f3f(0xbd),x),A=w([_0x2f5f78(_0x3e3489),C(0x1,_0x3a7a90),C(0x2,_0x3babd1(_0x5d8c04))],A);let j=class extends _0x259f6f{constructor(_0x5c11cd,_0x1a8288,_0x591763,_0x15dd77,_0x55ccaa){const _0x5548f4=_0x6f2f3f;super(_0x5c11cd,_0x1a8288,_0x591763,_0x15dd77,_0x55ccaa);let _0x31d715=this[_0x5548f4(0xe2)][_0x5548f4(0xe7)](_0x5e7c43);this[_0x5548f4(0xe0)][_0x5548f4(0xcf)]({'interceptor':(_0x1f5039,_0x5ace85)=>{const _0x5c8153=_0x5548f4;let _0x1480c2=_0x1f5039['headers'];if(_0x31d715!=null&&_0x31d715[_0x5c8153(0xdc)]){for(let _0x4f5b1c in _0x31d715[_0x5c8153(0xdc)])_0x1480c2[_0x5c8153(0xba)](_0x4f5b1c,_0x31d715[_0x5c8153(0xdc)][_0x4f5b1c]);}return _0x5ace85(_0x1f5039);}});}async[_0x6f2f3f(0xd3)](_0x2b905a){const _0x4712d1=_0x6f2f3f;return this[_0x4712d1(0xbb)](_0x2b905a);}};j=w([C(0x0,_0x3babd1(_0x5d8c04)),C(0x1,_0x3babd1(_0x377abe)),C(0x2,_0x3a7a90),C(0x3,_0x34b83e),C(0x4,_0x6cc045)],j);export{j as NodeCollaborationSocketService,A as UniverCollaborationClientNodePlugin};
package/lib/umd/index.js CHANGED
@@ -1 +1 @@
1
- function _0x1edc(_0x13e9d1,_0x440ec5){_0x13e9d1=_0x13e9d1-0x1a8;const _0x468800=_0x4688();let _0x1edcb5=_0x468800[_0x13e9d1];return _0x1edcb5;}(function(_0x5b8cba,_0x586db7){const _0x5f4510=_0x1edc,_0x4b25a8=_0x5b8cba();while(!![]){try{const _0x4b5a61=parseInt(_0x5f4510(0x1ed))/0x1+-parseInt(_0x5f4510(0x1df))/0x2+-parseInt(_0x5f4510(0x1c5))/0x3+parseInt(_0x5f4510(0x1a8))/0x4*(parseInt(_0x5f4510(0x1f2))/0x5)+parseInt(_0x5f4510(0x1d1))/0x6*(-parseInt(_0x5f4510(0x1d7))/0x7)+-parseInt(_0x5f4510(0x1d6))/0x8*(-parseInt(_0x5f4510(0x1c8))/0x9)+-parseInt(_0x5f4510(0x1eb))/0xa;if(_0x4b5a61===_0x586db7)break;else _0x4b25a8['push'](_0x4b25a8['shift']());}catch(_0x3bac48){_0x4b25a8['push'](_0x4b25a8['shift']());}}}(_0x4688,0xe8e9e),function(_0x155683,_0x6417e5){const _0xed34f4=_0x1edc;typeof exports==_0xed34f4(0x1bf)&&typeof module<'u'?_0x6417e5(exports,require('@univerjs-pro/collaboration-client'),require('@univerjs/core'),require('@univerjs/network'),require('rxjs'),require('@univerjs-pro/collaboration')):typeof define==_0xed34f4(0x1cb)&&define[_0xed34f4(0x1b8)]?define([_0xed34f4(0x1cf),'@univerjs-pro/collaboration-client',_0xed34f4(0x1ce),'@univerjs/network',_0xed34f4(0x1d0),_0xed34f4(0x1d9)],_0x6417e5):(_0x155683=typeof globalThis<'u'?globalThis:_0x155683||self,_0x6417e5(_0x155683[_0xed34f4(0x1b4)]={},_0x155683['UniverProCollaborationClient'],_0x155683['UniverCore'],_0x155683['UniverNetwork'],_0x155683['rxjs'],_0x155683['UniverProCollaboration']));}(this,function(_0x343940,_0x421c50,_0x2502f9,_0x1651f9,_0x39ba74,_0x30cbda){const _0x221ec9=_0x1edc;Object[_0x221ec9(0x1ec)](_0x343940,Symbol[_0x221ec9(0x1e6)],{'value':_0x221ec9(0x1e8)});var _0x25b16e=(_0x2bd488,_0x140c9d)=>()=>(_0x140c9d||(_0x2bd488((_0x140c9d={'exports':{}})[_0x221ec9(0x1cf)],_0x140c9d),_0x2bd488=null),_0x140c9d['exports']),_0x3a03f9=_0x221ec9(0x1a9),_0x35ae66=_0x221ec9(0x1ae);let _0x523178={};var _0x40af84=_0x25b16e((_0xaf1992,_0xbbdcd6)=>{_0xbbdcd6['exports']=function(){const _0x40cc46=_0x1edc;throw Error(_0x40cc46(0x1e2));};})();function _0x36b007(_0x56310d,_0x2b4975){return function(_0x3815a4,_0xa2a20d){_0x2b4975(_0x3815a4,_0xa2a20d,_0x56310d);};}function _0x41b19e(_0x10872e,_0x19d855,_0x4dadaa,_0x154aae){const _0x275312=_0x221ec9;var _0x15b1f7=arguments['length'],_0x21cbd8=_0x15b1f7<0x3?_0x19d855:_0x154aae===null?_0x154aae=Object[_0x275312(0x1ab)](_0x19d855,_0x4dadaa):_0x154aae,_0x33c2e1;if(typeof Reflect==_0x275312(0x1bf)&&typeof Reflect[_0x275312(0x1f1)]==_0x275312(0x1cb))_0x21cbd8=Reflect['decorate'](_0x10872e,_0x19d855,_0x4dadaa,_0x154aae);else{for(var _0x2ad23f=_0x10872e['length']-0x1;_0x2ad23f>=0x0;_0x2ad23f--)(_0x33c2e1=_0x10872e[_0x2ad23f])&&(_0x21cbd8=(_0x15b1f7<0x3?_0x33c2e1(_0x21cbd8):_0x15b1f7>0x3?_0x33c2e1(_0x19d855,_0x4dadaa,_0x21cbd8):_0x33c2e1(_0x19d855,_0x4dadaa))||_0x21cbd8);}return _0x15b1f7>0x3&&_0x21cbd8&&Object[_0x275312(0x1ec)](_0x19d855,_0x4dadaa,_0x21cbd8),_0x21cbd8;}let _0x418721=class extends _0x2502f9[_0x221ec9(0x1dc)]{constructor(_0x509adc){const _0x1ff7b5=_0x221ec9;super(),this[_0x1ff7b5(0x1c7)]=_0x509adc;}[_0x221ec9(0x1ac)](_0x4f9f84){const _0xa0e02d=_0x221ec9;var _0xc923d9;let _0x343483=((_0xc923d9=this[_0xa0e02d(0x1c7)][_0xa0e02d(0x1e1)](_0x421c50[_0xa0e02d(0x1b2)]))==null?void 0x0:_0xc923d9[_0xa0e02d(0x1e3)])||{};try{let _0x5a127b=new _0x40af84[(_0xa0e02d(0x1e5))](_0x4f9f84,{'headers':{..._0x343483}}),_0x1ca337=new _0x2502f9[(_0xa0e02d(0x1b5))]();return{'URL':_0x4f9f84,'close':(_0xfd46ef,_0x5bccdf)=>{const _0x358ac5=_0xa0e02d;_0x5a127b[_0x358ac5(0x1d4)](_0xfd46ef,_0x5bccdf),_0x1ca337['dispose']();},'send':_0x501ad1=>{const _0x23c3dd=_0xa0e02d;_0x5a127b[_0x23c3dd(0x1c6)](_0x501ad1);},'open$':new _0x39ba74['Observable'](_0x2075ca=>{const _0x464da8=_0xa0e02d;let _0x308500=_0xd0d1b3=>_0x2075ca[_0x464da8(0x1d3)](_0xd0d1b3);_0x5a127b['addEventListener']('open',_0x308500),_0x1ca337[_0x464da8(0x1d5)]((0x0,_0x2502f9['toDisposable'])(()=>_0x5a127b[_0x464da8(0x1de)]('open',_0x308500)));})['pipe']((0x0,_0x39ba74[_0xa0e02d(0x1c1)])()),'close$':new _0x39ba74[(_0xa0e02d(0x1e9))](_0x60ad1c=>{const _0x24c62c=_0xa0e02d;let _0x237524=_0x1972dd=>_0x60ad1c[_0x24c62c(0x1d3)](_0x1972dd);_0x5a127b['addEventListener']('close',_0x237524),_0x1ca337['add']((0x0,_0x2502f9['toDisposable'])(()=>_0x5a127b['removeEventListener']('close',_0x237524)));})[_0xa0e02d(0x1b6)]((0x0,_0x39ba74['share'])()),'error$':new _0x39ba74[(_0xa0e02d(0x1e9))](_0x349b11=>{const _0x13ffed=_0xa0e02d;let _0xd4649b=_0x499d1e=>_0x349b11[_0x13ffed(0x1d3)](_0x499d1e);_0x5a127b[_0x13ffed(0x1af)](_0x13ffed(0x1ea),_0xd4649b),_0x1ca337[_0x13ffed(0x1d5)]((0x0,_0x2502f9[_0x13ffed(0x1c2)])(()=>_0x5a127b[_0x13ffed(0x1de)](_0x13ffed(0x1ea),_0xd4649b)));})['pipe']((0x0,_0x39ba74[_0xa0e02d(0x1c1)])()),'message$':new _0x39ba74[(_0xa0e02d(0x1e9))](_0x346a8c=>{const _0x3063e7=_0xa0e02d;let _0xcca695=_0x3e5fec=>_0x346a8c[_0x3063e7(0x1d3)](_0x3e5fec);_0x5a127b['addEventListener'](_0x3063e7(0x1ca),_0xcca695),_0x1ca337[_0x3063e7(0x1d5)]((0x0,_0x2502f9['toDisposable'])(()=>_0x5a127b[_0x3063e7(0x1de)](_0x3063e7(0x1ca),_0xcca695)));})[_0xa0e02d(0x1b6)]((0x0,_0x39ba74['share'])())};}catch(_0x3f99bc){return console['error'](_0x3f99bc),null;}}};_0x418721=_0x41b19e([_0x36b007(0x0,_0x2502f9[_0x221ec9(0x1b1)])],_0x418721);function _0x37c14f(_0x3ffe3d){'@babel/helpers - typeof';const _0x3eb48d=_0x221ec9;return _0x37c14f=typeof Symbol==_0x3eb48d(0x1cb)&&typeof Symbol[_0x3eb48d(0x1bb)]==_0x3eb48d(0x1be)?function(_0x3cb755){return typeof _0x3cb755;}:function(_0x1d3567){const _0x1c235a=_0x3eb48d;return _0x1d3567&&typeof Symbol==_0x1c235a(0x1cb)&&_0x1d3567[_0x1c235a(0x1d8)]===Symbol&&_0x1d3567!==Symbol[_0x1c235a(0x1f0)]?_0x1c235a(0x1be):typeof _0x1d3567;},_0x37c14f(_0x3ffe3d);}function _0x3932dd(_0x4ab01b,_0x4c5f3d){const _0x1ec4bd=_0x221ec9;if(_0x37c14f(_0x4ab01b)!=_0x1ec4bd(0x1bf)||!_0x4ab01b)return _0x4ab01b;var _0x15dc2a=_0x4ab01b[Symbol[_0x1ec4bd(0x1b7)]];if(_0x15dc2a!==void 0x0){var _0x3f473b=_0x15dc2a['call'](_0x4ab01b,_0x4c5f3d||'default');if(_0x37c14f(_0x3f473b)!=_0x1ec4bd(0x1bf))return _0x3f473b;throw TypeError('@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.');}return(_0x4c5f3d==='string'?String:Number)(_0x4ab01b);}function _0x2393c8(_0x2c1540){var _0x2a6486=_0x3932dd(_0x2c1540,'string');return _0x37c14f(_0x2a6486)=='symbol'?_0x2a6486:_0x2a6486+'';}function _0x4ce961(_0x3034b3,_0x5f436b,_0x97107c){const _0x902f5d=_0x221ec9;return(_0x5f436b=_0x2393c8(_0x5f436b))in _0x3034b3?Object[_0x902f5d(0x1ec)](_0x3034b3,_0x5f436b,{'value':_0x97107c,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x3034b3[_0x5f436b]=_0x97107c,_0x3034b3;}let _0x3af2a3=class extends _0x2502f9['Plugin']{constructor(_0x4b4a33=_0x523178,_0x68346d,_0x4e227d){const _0x47565e=_0x221ec9;super(),this['_config']=_0x4b4a33,this['_configService']=_0x68346d,this[_0x47565e(0x1c0)]=_0x4e227d;let {..._0x595cab}=(0x0,_0x2502f9[_0x47565e(0x1c3)])({},_0x523178,this[_0x47565e(0x1ef)]);this[_0x47565e(0x1c7)]['setConfig'](_0x47565e(0x1c9),_0x595cab);}['onStarting'](){const _0x553743=_0x221ec9;this[_0x553743(0x1cd)]();}[_0x221ec9(0x1cd)](){const _0x36b454=_0x221ec9;(0x0,_0x2502f9[_0x36b454(0x1d2)])(this[_0x36b454(0x1c0)],[[_0x1651f9[_0x36b454(0x1ee)],{'useClass':_0x418721}]]);}};_0x4ce961(_0x3af2a3,_0x221ec9(0x1ba),_0x221ec9(0x1cc)),_0x4ce961(_0x3af2a3,_0x221ec9(0x1b3),_0x3a03f9),_0x4ce961(_0x3af2a3,_0x221ec9(0x1e7),_0x35ae66),_0x3af2a3=_0x41b19e([(0x0,_0x2502f9[_0x221ec9(0x1da)])(_0x421c50[_0x221ec9(0x1e0)]),_0x36b007(0x1,_0x2502f9[_0x221ec9(0x1b1)]),_0x36b007(0x2,(0x0,_0x2502f9[_0x221ec9(0x1dd)])(_0x2502f9['Injector']))],_0x3af2a3);let _0x3573a4=class extends _0x421c50[_0x221ec9(0x1b9)]{constructor(_0x26d6ab,_0x1277c8,_0x1258a7,_0x45b7af,_0x582ce0){const _0x21acf3=_0x221ec9;super(_0x26d6ab,_0x1277c8,_0x1258a7,_0x45b7af,_0x582ce0);let _0x44cd70=this[_0x21acf3(0x1c7)][_0x21acf3(0x1e1)](_0x421c50[_0x21acf3(0x1b2)]);this[_0x21acf3(0x1e4)][_0x21acf3(0x1bd)]({'interceptor':(_0x3d3f20,_0xc35d88)=>{const _0x13bea1=_0x21acf3;let _0x3a426f=_0x3d3f20[_0x13bea1(0x1c4)];if(_0x44cd70!=null&&_0x44cd70['customHeaders']){for(let _0x699328 in _0x44cd70[_0x13bea1(0x1e3)])_0x3a426f[_0x13bea1(0x1aa)](_0x699328,_0x44cd70['customHeaders'][_0x699328]);}return _0xc35d88(_0x3d3f20);}});}async[_0x221ec9(0x1ac)](_0x56c628){const _0x36b062=_0x221ec9;return this[_0x36b062(0x1ad)](_0x56c628);}};_0x3573a4=_0x41b19e([_0x36b007(0x0,(0x0,_0x2502f9[_0x221ec9(0x1dd)])(_0x2502f9['Injector'])),_0x36b007(0x1,(0x0,_0x2502f9[_0x221ec9(0x1dd)])(_0x1651f9[_0x221ec9(0x1db)])),_0x36b007(0x2,_0x2502f9[_0x221ec9(0x1b1)]),_0x36b007(0x3,_0x2502f9['ILogService']),_0x36b007(0x4,_0x30cbda[_0x221ec9(0x1b0)])],_0x3573a4),Object[_0x221ec9(0x1ec)](_0x343940,_0x221ec9(0x1bc),{'enumerable':!0x0,'get':function(){return _0x3573a4;}}),Object[_0x221ec9(0x1ec)](_0x343940,'UniverCollaborationClientNodePlugin',{'enumerable':!0x0,'get':function(){return _0x3af2a3;}});}));function _0x4688(){const _0xdc550f=['pluginName','iterator','NodeCollaborationSocketService','registerHTTPInterceptor','symbol','object','_injector','share','toDisposable','merge','headers','554748TfheGu','send','_configService','3220605ofTWYZ','collaboration-client-node.config','message','function','UNIVER_COLLABORATION_CLIENT_NODE_PLUGIN','_registerDependencies','@univerjs/core','exports','rxjs','1518MTDWbm','registerDependencies','next','close','add','24AVburg','17857VJLdhO','constructor','@univerjs-pro/collaboration','DependentOn','HTTPService','Disposable','Inject','removeEventListener','1064042grpAQS','UniverCollaborationClientPlugin','getConfig','ws\x20does\x20not\x20work\x20in\x20the\x20browser.\x20Browser\x20clients\x20must\x20use\x20the\x20native\x20WebSocket\x20object','customHeaders','_httpService','WebSocket','toStringTag','version','Module','Observable','error','13168950YEEAuB','defineProperty','1782992MhqhLV','ISocketService','_config','prototype','decorate','5aCKxNu','3106888fSGUrc','@univerjs-pro/collaboration-client-node','set','getOwnPropertyDescriptor','createSocket','_doCreateSocket','1.0.0-alpha.4','addEventListener','ISnapshotServerService','IConfigService','COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY','packageName','UniverProCollaborationClientNode','DisposableCollection','pipe','toPrimitive','amd','CollaborationSocketService'];_0x4688=function(){return _0xdc550f;};return _0x4688();}
1
+ function _0x2ea0(_0x446478,_0x3aab32){_0x446478=_0x446478-0x1e7;const _0x37bad0=_0x37ba();let _0x2ea0f0=_0x37bad0[_0x446478];return _0x2ea0f0;}function _0x37ba(){const _0x4ad392=['_injector','createSocket','toStringTag','length','1108095unDxjh','toPrimitive','6226947EjXqrA','ISnapshotServerService','IConfigService','dispose','default','60nxRwwG','iterator','setConfig','collaboration-client-node.config','COLLABORATION_CLIENT_PLUGIN_CONFIG_KEY','_configService','UniverCore','Observable','@univerjs/core','customHeaders','30mtvUwg','Module','HTTPService','removeEventListener','UNIVER_COLLABORATION_CLIENT_NODE_PLUGIN','_doCreateSocket','570792SroFyJ','addEventListener','_config','2128680dLpYOA','share','UniverProCollaborationClientNode','open','string','object','onStarting','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','DependentOn','toDisposable','send','close','@univerjs-pro/collaboration-client','16CXksQz','message','Inject','getConfig','function','6671252OeFeZx','merge','amd','next','registerDependencies','UniverProCollaborationClient','defineProperty','DisposableCollection','rxjs','pipe','Disposable','UniverNetwork','114388QHfnuY','add','Injector','ILogService','Plugin','symbol','WebSocket','pluginName','error','prototype','decorate','ws\x20does\x20not\x20work\x20in\x20the\x20browser.\x20Browser\x20clients\x20must\x20use\x20the\x20native\x20WebSocket\x20object','exports','_registerDependencies','134600btJYxV'];_0x37ba=function(){return _0x4ad392;};return _0x37ba();}(function(_0x162eb4,_0x1850d4){const _0x32b71d=_0x2ea0,_0x24fbe3=_0x162eb4();while(!![]){try{const _0x21d482=-parseInt(_0x32b71d(0x217))/0x1*(parseInt(_0x32b71d(0x206))/0x2)+-parseInt(_0x32b71d(0x22a))/0x3+parseInt(_0x32b71d(0x1f6))/0x4+parseInt(_0x32b71d(0x225))/0x5*(parseInt(_0x32b71d(0x231))/0x6)+-parseInt(_0x32b71d(0x20b))/0x7+parseInt(_0x32b71d(0x1f9))/0x8+parseInt(_0x32b71d(0x22c))/0x9*(parseInt(_0x32b71d(0x1f0))/0xa);if(_0x21d482===_0x1850d4)break;else _0x24fbe3['push'](_0x24fbe3['shift']());}catch(_0x21b257){_0x24fbe3['push'](_0x24fbe3['shift']());}}}(_0x37ba,0x7e01f),function(_0x5d3e28,_0xaa32e1){const _0x10f1ce=_0x2ea0;typeof exports==_0x10f1ce(0x1fe)&&typeof module<'u'?_0xaa32e1(exports,require('@univerjs-pro/collaboration-client'),require('@univerjs/core'),require('@univerjs/network'),require('rxjs'),require('@univerjs-pro/collaboration')):typeof define==_0x10f1ce(0x20a)&&define[_0x10f1ce(0x20d)]?define([_0x10f1ce(0x223),_0x10f1ce(0x205),_0x10f1ce(0x1ee),'@univerjs/network',_0x10f1ce(0x213),'@univerjs-pro/collaboration'],_0xaa32e1):(_0x5d3e28=typeof globalThis<'u'?globalThis:_0x5d3e28||self,_0xaa32e1(_0x5d3e28[_0x10f1ce(0x1fb)]={},_0x5d3e28[_0x10f1ce(0x210)],_0x5d3e28[_0x10f1ce(0x1ec)],_0x5d3e28[_0x10f1ce(0x216)],_0x5d3e28[_0x10f1ce(0x213)],_0x5d3e28['UniverProCollaboration']));}(this,function(_0x54a4f6,_0x46bc4b,_0xfc9632,_0x2cca83,_0xe44bf7,_0x5b26f2){const _0x35adfa=_0x2ea0;Object['defineProperty'](_0x54a4f6,Symbol[_0x35adfa(0x228)],{'value':_0x35adfa(0x1f1)});var _0x2bd88b=(_0x476c27,_0xc8950e)=>()=>(_0xc8950e||(_0x476c27((_0xc8950e={'exports':{}})[_0x35adfa(0x223)],_0xc8950e),_0x476c27=null),_0xc8950e[_0x35adfa(0x223)]),_0x29acd5='@univerjs-pro/collaboration-client-node',_0x349fa4='1.0.0-alpha.5';let _0x3c254c={};var _0x3aab01=_0x2bd88b((_0x597f3e,_0x13102a)=>{const _0x95244a=_0x35adfa;_0x13102a[_0x95244a(0x223)]=function(){const _0xf3630e=_0x95244a;throw Error(_0xf3630e(0x222));};})();function _0x1637a0(_0x5d203c,_0x35afa6){return function(_0x3043f1,_0x596712){_0x35afa6(_0x3043f1,_0x596712,_0x5d203c);};}function _0x38a54a(_0x5d92f9,_0x178bb8,_0x1e0619,_0x2be593){const _0x4e9825=_0x35adfa;var _0x5bd34f=arguments['length'],_0x3d1b25=_0x5bd34f<0x3?_0x178bb8:_0x2be593===null?_0x2be593=Object['getOwnPropertyDescriptor'](_0x178bb8,_0x1e0619):_0x2be593,_0x546032;if(typeof Reflect=='object'&&typeof Reflect['decorate']==_0x4e9825(0x20a))_0x3d1b25=Reflect[_0x4e9825(0x221)](_0x5d92f9,_0x178bb8,_0x1e0619,_0x2be593);else{for(var _0x17935d=_0x5d92f9[_0x4e9825(0x229)]-0x1;_0x17935d>=0x0;_0x17935d--)(_0x546032=_0x5d92f9[_0x17935d])&&(_0x3d1b25=(_0x5bd34f<0x3?_0x546032(_0x3d1b25):_0x5bd34f>0x3?_0x546032(_0x178bb8,_0x1e0619,_0x3d1b25):_0x546032(_0x178bb8,_0x1e0619))||_0x3d1b25);}return _0x5bd34f>0x3&&_0x3d1b25&&Object[_0x4e9825(0x211)](_0x178bb8,_0x1e0619,_0x3d1b25),_0x3d1b25;}let _0x507bf0=class extends _0xfc9632[_0x35adfa(0x215)]{constructor(_0x473ce8){const _0x51919a=_0x35adfa;super(),this[_0x51919a(0x1eb)]=_0x473ce8;}[_0x35adfa(0x227)](_0x5e189f){const _0x11696b=_0x35adfa;var _0x3e62dd;let _0x3a59cb=((_0x3e62dd=this['_configService'][_0x11696b(0x209)](_0x46bc4b[_0x11696b(0x1ea)]))==null?void 0x0:_0x3e62dd[_0x11696b(0x1ef)])||{};try{let _0x5e3646=new _0x3aab01[(_0x11696b(0x21d))](_0x5e189f,{'headers':{..._0x3a59cb}}),_0x329f32=new _0xfc9632[(_0x11696b(0x212))]();return{'URL':_0x5e189f,'close':(_0x427e30,_0x17d894)=>{const _0x21d7f4=_0x11696b;_0x5e3646[_0x21d7f4(0x204)](_0x427e30,_0x17d894),_0x329f32[_0x21d7f4(0x22f)]();},'send':_0x3e1c52=>{const _0x125f69=_0x11696b;_0x5e3646[_0x125f69(0x203)](_0x3e1c52);},'open$':new _0xe44bf7[(_0x11696b(0x1ed))](_0x24aaae=>{const _0x117761=_0x11696b;let _0x266fd9=_0x3691e7=>_0x24aaae[_0x117761(0x20e)](_0x3691e7);_0x5e3646['addEventListener'](_0x117761(0x1fc),_0x266fd9),_0x329f32['add']((0x0,_0xfc9632[_0x117761(0x202)])(()=>_0x5e3646[_0x117761(0x1f3)](_0x117761(0x1fc),_0x266fd9)));})[_0x11696b(0x214)]((0x0,_0xe44bf7[_0x11696b(0x1fa)])()),'close$':new _0xe44bf7['Observable'](_0x5656c9=>{const _0x951365=_0x11696b;let _0x51af4d=_0x362f58=>_0x5656c9[_0x951365(0x20e)](_0x362f58);_0x5e3646[_0x951365(0x1f7)](_0x951365(0x204),_0x51af4d),_0x329f32[_0x951365(0x218)]((0x0,_0xfc9632[_0x951365(0x202)])(()=>_0x5e3646[_0x951365(0x1f3)](_0x951365(0x204),_0x51af4d)));})[_0x11696b(0x214)]((0x0,_0xe44bf7[_0x11696b(0x1fa)])()),'error$':new _0xe44bf7[(_0x11696b(0x1ed))](_0x480095=>{const _0x23bb22=_0x11696b;let _0x20ade6=_0x553b74=>_0x480095[_0x23bb22(0x20e)](_0x553b74);_0x5e3646['addEventListener'](_0x23bb22(0x21f),_0x20ade6),_0x329f32[_0x23bb22(0x218)]((0x0,_0xfc9632[_0x23bb22(0x202)])(()=>_0x5e3646[_0x23bb22(0x1f3)](_0x23bb22(0x21f),_0x20ade6)));})[_0x11696b(0x214)]((0x0,_0xe44bf7[_0x11696b(0x1fa)])()),'message$':new _0xe44bf7[(_0x11696b(0x1ed))](_0x4701d2=>{const _0x5c7c13=_0x11696b;let _0x4b24a7=_0x45634b=>_0x4701d2[_0x5c7c13(0x20e)](_0x45634b);_0x5e3646[_0x5c7c13(0x1f7)](_0x5c7c13(0x207),_0x4b24a7),_0x329f32['add']((0x0,_0xfc9632[_0x5c7c13(0x202)])(()=>_0x5e3646[_0x5c7c13(0x1f3)](_0x5c7c13(0x207),_0x4b24a7)));})[_0x11696b(0x214)]((0x0,_0xe44bf7[_0x11696b(0x1fa)])())};}catch(_0x31388e){return console[_0x11696b(0x21f)](_0x31388e),null;}}};_0x507bf0=_0x38a54a([_0x1637a0(0x0,_0xfc9632['IConfigService'])],_0x507bf0);function _0x858994(_0x49c856){'@babel/helpers - typeof';const _0x5b3da8=_0x35adfa;return _0x858994=typeof Symbol==_0x5b3da8(0x20a)&&typeof Symbol[_0x5b3da8(0x1e7)]==_0x5b3da8(0x21c)?function(_0x56665b){return typeof _0x56665b;}:function(_0x2bcfbe){const _0x2414ae=_0x5b3da8;return _0x2bcfbe&&typeof Symbol=='function'&&_0x2bcfbe['constructor']===Symbol&&_0x2bcfbe!==Symbol[_0x2414ae(0x220)]?_0x2414ae(0x21c):typeof _0x2bcfbe;},_0x858994(_0x49c856);}function _0xd1d2f6(_0x241a91,_0x5a306c){const _0x466d1d=_0x35adfa;if(_0x858994(_0x241a91)!=_0x466d1d(0x1fe)||!_0x241a91)return _0x241a91;var _0x4b72f4=_0x241a91[Symbol[_0x466d1d(0x22b)]];if(_0x4b72f4!==void 0x0){var _0x3852f=_0x4b72f4['call'](_0x241a91,_0x5a306c||_0x466d1d(0x230));if(_0x858994(_0x3852f)!=_0x466d1d(0x1fe))return _0x3852f;throw TypeError(_0x466d1d(0x200));}return(_0x5a306c===_0x466d1d(0x1fd)?String:Number)(_0x241a91);}function _0x38ee8e(_0x20b529){const _0x131a71=_0x35adfa;var _0x1253a9=_0xd1d2f6(_0x20b529,_0x131a71(0x1fd));return _0x858994(_0x1253a9)=='symbol'?_0x1253a9:_0x1253a9+'';}function _0x230d77(_0x4bddf2,_0x4a33df,_0x4f4b5c){const _0x2efcab=_0x35adfa;return(_0x4a33df=_0x38ee8e(_0x4a33df))in _0x4bddf2?Object[_0x2efcab(0x211)](_0x4bddf2,_0x4a33df,{'value':_0x4f4b5c,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x4bddf2[_0x4a33df]=_0x4f4b5c,_0x4bddf2;}let _0x1a39a9=class extends _0xfc9632[_0x35adfa(0x21b)]{constructor(_0x2d0c39=_0x3c254c,_0xb423d8,_0x1fb19e){const _0x48f9ee=_0x35adfa;super(),this[_0x48f9ee(0x1f8)]=_0x2d0c39,this['_configService']=_0xb423d8,this[_0x48f9ee(0x226)]=_0x1fb19e;let {..._0x435e77}=(0x0,_0xfc9632[_0x48f9ee(0x20c)])({},_0x3c254c,this[_0x48f9ee(0x1f8)]);this[_0x48f9ee(0x1eb)][_0x48f9ee(0x1e8)](_0x48f9ee(0x1e9),_0x435e77);}[_0x35adfa(0x1ff)](){const _0x484b76=_0x35adfa;this[_0x484b76(0x224)]();}['_registerDependencies'](){const _0x9c995e=_0x35adfa;(0x0,_0xfc9632[_0x9c995e(0x20f)])(this[_0x9c995e(0x226)],[[_0x2cca83['ISocketService'],{'useClass':_0x507bf0}]]);}};_0x230d77(_0x1a39a9,_0x35adfa(0x21e),_0x35adfa(0x1f4)),_0x230d77(_0x1a39a9,'packageName',_0x29acd5),_0x230d77(_0x1a39a9,'version',_0x349fa4),_0x1a39a9=_0x38a54a([(0x0,_0xfc9632[_0x35adfa(0x201)])(_0x46bc4b['UniverCollaborationClientPlugin']),_0x1637a0(0x1,_0xfc9632[_0x35adfa(0x22e)]),_0x1637a0(0x2,(0x0,_0xfc9632[_0x35adfa(0x208)])(_0xfc9632[_0x35adfa(0x219)]))],_0x1a39a9);let _0x18b547=class extends _0x46bc4b['CollaborationSocketService']{constructor(_0x22748b,_0x38ac0c,_0x46018f,_0x265df4,_0x278adc){const _0x21fc84=_0x35adfa;super(_0x22748b,_0x38ac0c,_0x46018f,_0x265df4,_0x278adc);let _0x13b0af=this['_configService'][_0x21fc84(0x209)](_0x46bc4b[_0x21fc84(0x1ea)]);this['_httpService']['registerHTTPInterceptor']({'interceptor':(_0x33399d,_0x14df56)=>{const _0x4a2ab7=_0x21fc84;let _0x10a476=_0x33399d['headers'];if(_0x13b0af!=null&&_0x13b0af['customHeaders']){for(let _0x4b4833 in _0x13b0af[_0x4a2ab7(0x1ef)])_0x10a476['set'](_0x4b4833,_0x13b0af[_0x4a2ab7(0x1ef)][_0x4b4833]);}return _0x14df56(_0x33399d);}});}async[_0x35adfa(0x227)](_0x172809){const _0x46b724=_0x35adfa;return this[_0x46b724(0x1f5)](_0x172809);}};_0x18b547=_0x38a54a([_0x1637a0(0x0,(0x0,_0xfc9632[_0x35adfa(0x208)])(_0xfc9632[_0x35adfa(0x219)])),_0x1637a0(0x1,(0x0,_0xfc9632['Inject'])(_0x2cca83[_0x35adfa(0x1f2)])),_0x1637a0(0x2,_0xfc9632['IConfigService']),_0x1637a0(0x3,_0xfc9632[_0x35adfa(0x21a)]),_0x1637a0(0x4,_0x5b26f2[_0x35adfa(0x22d)])],_0x18b547),Object[_0x35adfa(0x211)](_0x54a4f6,'NodeCollaborationSocketService',{'enumerable':!0x0,'get':function(){return _0x18b547;}}),Object[_0x35adfa(0x211)](_0x54a4f6,'UniverCollaborationClientNodePlugin',{'enumerable':!0x0,'get':function(){return _0x1a39a9;}});}));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@univerjs-pro/collaboration-client-node",
3
- "version": "1.0.0-alpha.4",
3
+ "version": "1.0.0-alpha.5",
4
4
  "private": false,
5
5
  "description": "Node.js collaboration client plugin for Univer Pro.",
6
6
  "author": "DreamNum Co., Ltd. <developer@univer.ai>",
@@ -52,17 +52,17 @@
52
52
  },
53
53
  "dependencies": {
54
54
  "ws": "8.21.0",
55
- "@univerjs-pro/collaboration": "1.0.0-alpha.4",
56
- "@univerjs-pro/collaboration-client": "1.0.0-alpha.4",
57
- "@univerjs/core": "1.0.0-alpha.4",
58
- "@univerjs/network": "1.0.0-alpha.4"
55
+ "@univerjs-pro/collaboration": "1.0.0-alpha.5",
56
+ "@univerjs-pro/collaboration-client": "1.0.0-alpha.5",
57
+ "@univerjs/core": "1.0.0-alpha.5",
58
+ "@univerjs/network": "1.0.0-alpha.5"
59
59
  },
60
60
  "devDependencies": {
61
61
  "@types/ws": "8.18.1",
62
62
  "rxjs": "7.8.2",
63
63
  "typescript": "^6.0.3",
64
64
  "vitest": "^4.1.10",
65
- "@univerjs-infra/shared": "1.0.0-alpha.4"
65
+ "@univerjs-infra/shared": "1.0.0-alpha.5"
66
66
  },
67
67
  "scripts": {
68
68
  "test": "vitest run",